I'm making a game with a till that you might use in a shop
The till will work out how much change the customer is due and then displays both the number and pictures of the coins that they should receive
I am wondering if there is an easier way to calculate what coins are due rather than 100's of if statements saying:
IF change=1 then create object 1pSprite on layer 0
IF change=2 then create object 2pSprite on layer 0
IF change=3 then create object 1pSprite & 2pSprite on layer 0
IF change=4 then create object 2pSprite & 2pSprite on layer 0
IF change=5 then create object 5pSprite on layer 0
etc...
I have attached a basic capx attempt that will hopefully explain what i mean a little better...
https://www.dropbox.com/s/3mdjl8l0bh6b1jw/visual_change_calc.capx?dl=0
Many thanks