As our game gets more complex, we'd like to be able to start the game at any point with different variables and quest state settings that we have prescribed.
I'm looking for the best way to do this. Should we save these out via Save System or Easy Save and load these back in when we need them or is there a better way of doing this?
Load different state configuration at any point
Re: Load different state configuration at any point
Hi,
If you're already using the Save System, you can save and load saved games. Or, if you don't want to actually save the game, you can tell the Save System to record the current game state:
and then later apply that data back into the game:
If you're not using the Save System and you only want to save variables and quest states, you can use the PersistentDataManager class:
and:
If you're already using the Save System, you can save and load saved games. Or, if you don't want to actually save the game, you can tell the Save System to record the current game state:
Code: Select all
SavedGameData data = PixelCrushers.SaveSystem.RecordSavedGameData();
Code: Select all
PixelCrushers.SaveSystem.ApplySavedGameData(data);
Code: Select all
string s = PersistentDataManager.GetSaveData();
Code: Select all
PersistentDataManager.ApplySaveData(s);
Re: Load different state configuration at any point
Thanks. That helps a lot.
Re: Load different state configuration at any point
Happy to help!