What do you mean by “already once hit the 200”?
If you hit 200 twice that is 400 so if you subtract 200 you have 200 remain and not 0. Are you certain the remaining balance is 0 or you just think it is 0?
It is just a simple math operation
0 is not > 99. So it is very likely not 0 but 200?
The screenshots are a little different than what I described in my post, my bad.
I will be more specific as per the content in the screenshots.
Right now in my developing game, when the player hits an asteroid, he can get a minimum of $250.
With the $250 he is able to buy upgrade 1 (cost $100) and also upgrade 2 (cost $222).
Let’s say he buys upgrade 2. He has $250 and the amount of $222 will be substracted leaving $28 on his account. This all works perfectly fine.
The $28 should not be enough to buy upgrade 1 (costs are $100). However in the game he is still able to buy this upgrade.
I think it is because the global variable already surpassed the 100 earlier, even though the translated amount in the text object reads 28.
This is the problem I am trying to find an answer for.
Oh, wait, you set the animation of the button for upgrade 1 to be clickable when you have $250 but when you buy upgrade 2 you don’t reset the button for upgrade 1 and that is why you can click it even though you don’t have the money but the button is clickable.
So when you buy upgrade 2, you need to reset the button for upgrade 1 too to be not clickable. And then it should set the button back to clickable again if you still have enough money.
And do the same for upgrade 2 also if you can buy upgrade 1 multiple times.