how do you get the player to save numbers for money or other items and then load them when you come back or from level to level.
Let me introduce you to…
SAVES
How do saves work?
Well, it has TWO properties. Save and Load. Save saves the number or text in your cache (basically your search history), and load gets that text or number. In order for saves to work, it has to be the same name.
For example, lets use money.
Let’s say that I have a program that adds one to a number everytime I press space. This would most likely be a space connected to a one connected to the plus of a number. In this case, I would connect the out of this number to the Save of this save block. In this case, I name the block Money.
Now, if I wanted to load this money, I would add a once and another save block to this code. I would connect the once to the Load of the save block and name the save block Money, because I want to load the money save. I would connect the out to the save of the number being added to.
Globals if you’re just doing in between levels, because globals are easier to keep track of and easier to understand.
Use a save if you want everything to save when the player gets back into the game.
Thanks I have been using this a lot.