D
D
Dmitry2021-07-06 22:03:29
Java
Dmitry, 2021-07-06 22:03:29

How to customize ProgressBar change?

The brain has gone beyond the mind.

I have a ProgressBar with a starting maximum value, for example ProgressBar.setMax(20), the value of the level (int lvl) and points (int exp).

When a new level is reached, say 2, I set ProgressBar.setMax(50).
The progress bar should reset to 0 and the score should start from the minimum value, from the leftmost position. Points must not be reset. For me, the scale simply increases by +30 and the reference point becomes somewhere around 1/3.

How can this be fixed?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander Prokhorovich, 2021-07-07
@Starv

ProgressBar.setMin(20)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question