I can't figure out how to program my game so that an object's private variables remain consistent from one layout to the next.
For example, the game is a platformer and let's say I'm collecting coins. I collect 10 coins in level 1, and there would be text that shows this number.
How would I program the game so that when the player reaches the next level/layout, they still have 10 coins?