Hi guys.
I have a small little prototype for a client. Its basically virtual bubble wrap that you pop with your mouse, So I need to calculate the percentage of bubble's popped.
I know there is 300 bubbles, So I have a variable called Total_Bubble's.
I also have a variable called Total_Popped.
I have a instance Boolean on the bubble to determine weather it has been popped or not.
Then when clicked Bubble is clicked, if popped = false, set frame to 1, set popped to true and add 1 to total popped.
Everything is right so far is it not?
So then to calculate the percentage im doing this:
I have a variable called Percentage
System.EveryTick
->Total_Popped * 100/Total_Bubbles
But I get something like 112% popped when thats not correct.
Is it something im doing wrong? Do i need to round the number?
Thanks.