Save progress as a password string

0 favourites
  • 1 posts
From the Asset Store
Progress\Loading Bar
$2.40 USD
40% off
Progress\Loading Bar. Now Load you game like a Professional.
  • Hi!

    I have been trying to think of a simple way of overcoming the webstorage/cookies limitation of the player having to use the same computer every time for the game. I would like to create a system in which the player can pick up the game on any computer.

    I was thinking of storing all the different game variables in a string, then somehow obscuring that string and giving it to the player when he quits. So all the player would need to do is save that string and next time he could use it to restore the game progress. Can you give me your thoughts on such a system? Has anyone tried anything similar?

    To give you a better picture of what I'm thinking about, here is a small example:

    Data to be saved:

    1. Checkpoint number (as a hex-number) 1-16, this determines where the player is positioned, needs one character from the string

    2. Health amount (as a number) 1-9, max health in my game is 9, needs one character from the string

    3. HP amount (as a hex-number) 0-256, needs two characters from the string

    4. Completed tasks, this one is tricky, because there can be several different combinations (let's say I have 20 different tasks that can be completed in any order). Instead of storing 20 different booleans in the string, I'm thinking of creating a map/dictionary of all the possible combinations (I believe 190 in total) and the picking the combination the player has with a 2-digit hex (giving me numbers 0-256).

    All in all the above system would require a string of 1+1+2+2 = 6 characters and it might look something like this D5EACB. Because a clever player might understand that the numbers can be changed in order to cheat, I should come up with some way to scramble the code. I'm not sure what the best approach to that might be though.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)