Gasil
Member
Hello, I'm trying to figure out a dinamic way to accomplish the following.
maxVoli = 2; (This variable starts at 2 and will be added + 1 several times in the course of the game.)
etc
I guess I can amateurly make as much if statements as I need but I think maxVoli will end up with a very big number D':
How do you think I should approach this? With a loop or maybe a formula?
Thank you, please let me know if I didn't explain myself well enough.
maxVoli = 2; (This variable starts at 2 and will be added + 1 several times in the course of the game.)
Code:
if(maxVoli >= 2) and (maxVoli <= 6)
pag = 0;
if(maxVoli >= 6) and (maxVoli <= 10)
pag = 1;
if(maxVoli >= 10) and (maxVoli <= 14)
pag = 2;
if(maxVoli >= 14) and (maxVoli <= 18)
pag = 3;
I guess I can amateurly make as much if statements as I need but I think maxVoli will end up with a very big number D':
How do you think I should approach this? With a loop or maybe a formula?
Thank you, please let me know if I didn't explain myself well enough.