J
J
JTester2021-12-10 16:48:03
Mathematics
JTester, 2021-12-10 16:48:03

How to get a number?

Hello! I want to make a ProgressBar, but I can't count.

Krch, there is such data:
XP: 200
STEP_EXP: 600

Also, ProgressBar takes the maximum value, this is 1.0.

1.0 - this ProgressBar is full, it rises by 1 unit, that is, like this 0.1, 0.2, 0.3 and so on until

1.0 , if I have exp = step_exp, it means 1.0 for me.

Thank you!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
R
rPman, 2021-12-10
@rPman

(current_value - min_value) / (max_value - min_value)=[0..1]

M
mathrep, 2021-12-12
@mathrep

EXP / STEP_EXP and round to tenths.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question