Save games
Posted: Sat Jan 20, 2018 5:48 am
Good morning all.
Im having some issues getting my head around save games. ive read a bit of documentation but the penny hasnt dropped yet.
I understand that in order to keep save files small and save time short, the game only saves variables whose value have changed since the game loaded.
I also understand that the default command was added to allow coders to tell renpy "if no other value is assigned to this variable, use this value"
I am having some issues getting my head around implementation though. In my mind, all of my variables are important, it's why i declared them in the first place, so when I load a game and S**t is going mental because half of the values the game needs are no longer defined it sorta throws me off.
I declare all of my variables and their starting values in one function which Is the first thing called in the start()
The function defines a few classes and then declares all the variables with their default values of which there are currently only about 40 but i need the values of all of these variables to be saved so that when the game loads, it is in exactly the same state as it was when it was saved otherwise there isn't much point saving.
Anyone with a good handle on this able to break it down a bit and maybe help explain what I need to do?
Much obliged
Im having some issues getting my head around save games. ive read a bit of documentation but the penny hasnt dropped yet.
I understand that in order to keep save files small and save time short, the game only saves variables whose value have changed since the game loaded.
I also understand that the default command was added to allow coders to tell renpy "if no other value is assigned to this variable, use this value"
I am having some issues getting my head around implementation though. In my mind, all of my variables are important, it's why i declared them in the first place, so when I load a game and S**t is going mental because half of the values the game needs are no longer defined it sorta throws me off.
I declare all of my variables and their starting values in one function which Is the first thing called in the start()
The function defines a few classes and then declares all the variables with their default values of which there are currently only about 40 but i need the values of all of these variables to be saved so that when the game loads, it is in exactly the same state as it was when it was saved otherwise there isn't much point saving.
Anyone with a good handle on this able to break it down a bit and maybe help explain what I need to do?
Much obliged