I am currently saving my data as JSON. Whenever I switch to Binary_Alpha OR encryption, I start to get errors. (I always make sure I delete the currrent game save file...so it's not a wrong format issue).
I've given up on encryption...so I just need help getting it to work with Binary_Alpha.
When I switch to Binary_Alpha...my code fails on the IF condition when the below code is run. Apparently a new consumbablesIds is not created when its missing in the file. I know I can do a null check on consumableIds...but WHY is it failing when switching formats? Is saving dictionaries allowed with binary files? If not, why doesn't the document state that?
Code: Select all
Dictionary<string, string> consumableIds = ES3.Load("CONSUMEABLE_DICTIONARY", GameSettings.Instance.gameSaveFile, new Dictionary<string, string>());
if (consumableIds.ContainsKey(id)) {
Buffer Size ...Why or when would I need to increase this?
Serialize Unity Object Fields
Why would I use Ref?
Why would I use Value?
Why would I use Ref And Value?
Serialzation Depth...Why or when would I need to increase this?
I've attached an example of the gameSave file.