
Originally Posted by
VBEinc
I use List Object. So much easier and is visual in one location within the Environment you are working on.
Not to mention works in ANDROID and Windows with ease.
Super Mario Example
I.E. File Name = MarioSaveInfo.ABC < List Object understands this is a List File regardless of the Extension end. Which makes it even better as typical users don't understand how to open it.
AUTO SAVE = MarioSaveinfo.ABC is the Same as all Variables. Run this event once when loops. Save List File MarioSaveinfo.ABC
Auto Repair Save = MarioSaveinfo.ABC is Different then all Variables. Change line ?
List File itself
1) Player Lives
2) Player Power
3) PLAYER X Position
4) PLAYER Y Position
5) Player Inventory Mushroom 0-999999999
6) Player Inventory Fire Flower 0-999999999
7) Player Inventory Tail 0-999999999
etc
Then you can link these all to the Environment Variables at the Start, During and End of any Game.
Say the Player picks up a Fire Flower. This would trigger the Variable for the game to change on line 6 and auto save.
1) 3
2) 100
3) 98
4) 102
5) 0
6) 1
7) 0
etc
Player picks up a Mushroom in the same location.
1) 3
2) 100
3) 98
4) 102
5) 1
6) 1
7) 0
etc
Player picks up a Tail in the same Location.
1) 3
2) 100
3) 98
4) 102
5) 1
6) 1
7) 1
etc
Player move and picks up another Mushroom.
1) 3
2) 100
3) 250
4) 102
5) 2
6) 1
7) 1
etc
Last, Player gets Hurt. Lost one life and has inventory change / picked up a mushroom.
1) 2
2) 25
3) 100
4) 102
5) 3
6) 1
7) 1
etc
Thus, when the player Continues this game in the future. They have exactly what they had when they left and are in the Exact Same spot they left off at.
Obviously, you'd need to have a Continue function the user can click to load the savegame MarioSaveinfo.ABC
You could even make numerous Saves by allowing the user to name their Saves. Editbox +".ABC"
You can also add Enemy Positions and Enemies remaining to the save files. This way if the user killed 5 out of 10 enemies. When they continue the game. 5 Specific Enemies would remain in their exact locations.
Not to mention in app Updates you can simply add a line for Player only Specific Data. ( Plan this ahead of time to make it easier / I.E. Make a Player Only Save file and a Default Enemy Save File "EDITBOX"+_ENEMIES.ABC"
This way the Enemies Save info is linked to the Player's Save Info File. Two Files that the user Creates. One for themselves and one hidden for the Enemies.
Just an Idea. I personally never use INI for any saves. I Tried it a few times, but didn't like having to look through the code in order to add or remove something for saving. I also didn't like the layers of Labeling to get to specific Values or Strings.
I also Use this to rewind games during play. However, that is another topic and requires multiple list files.
Hope this gives you another option.