Simple question, I think. I have a custom class that stores pretty much all of the player data for my game, and I save it with Easy Save 2 by using the Manage Types window and adding support for its properties through that. Saving and Loading of it works fine. I use a custom class since I plan on having multiple saves per install of the game (so multiple copies of the class being saved to different tags or paths).
The problem, though, is that if I update the type when I add a new variable to save, the previous saves do not load. The exact line of code I'm using to load is:
Code: Select all
playerMain = ES2.Load<PlayerStats> ("playerMain");
So, to get around it I just erase the game save and then start it again and it works. It doesn't really bug me all that much having to do that, but then it eventually occurred to me that if I update the class after I release the game, that's a completely unacceptable work around for my end users.
So, my (simple) question is: Am I missing something about how saving custom classes is supposed to work that would solve all my problems, or do I need to save player info in a different manner to accommodate my needs? I wouldn't mind that much just generating unique tags for every variable based on which save slot its suppose to be saving/loading (ex. "playerLevel_save1", "playerLevel_save2", etc.), but the custom class saving seemed perfect for what I wanted at first, though I'll admit I didn't research it too much before using it.
Thank you for any help anyone can provide.