Page 1 of 1

State of saved data after app update

Posted: Sun Nov 24, 2019 8:25 pm
by teq
Hi there! I am saving purchased items states with ES3 like "pro_version", "no_ads" and other common used ones.
Users complain, that after purchase it work ok (so state is saved correctly), but after they open app again sometimes(not for all users) state of, for example, "pro_version" becomes false again. I can't find why is this happening. It works for me fine. And in all these cases after my advice to reinstall the app, the problem is gone. Therefore, I decided that maybe something could break the storage system exactly when updating the application?

Re: State of saved data after app update

Posted: Tue Nov 26, 2019 7:51 am
by Joel
Hi there,

We store data to Unity'sApplication.persistentDataPath by default. Their documentation states:
Files in this location are not erased by app updates. The files can still be erased by users directly.
So no changes should be made to the file upon updating. If the file is being changed, it suggests that there is a bug at Unity's end, the file has been tampered with, the device's file system has become corrupt or the app's GUID name has changed between updates.

If Easy Save encounters difficulties when loading, it will throw an exception to the log file, so you might want to see if you can get hold of a log file to see what is happening.

All the best,
Joel

Re: State of saved data after app update

Posted: Tue Nov 26, 2019 12:18 pm
by teq
Joel wrote:Hi there,

We store data to Unity'sApplication.persistentDataPath by default. Their documentation states:
Files in this location are not erased by app updates. The files can still be erased by users directly.
So no changes should be made to the file upon updating. If the file is being changed, it suggests that there is a bug at Unity's end, the file has been tampered with, the device's file system has become corrupt or the app's GUID name has changed between updates.

If Easy Save encounters difficulties when loading, it will throw an exception to the log file, so you might want to see if you can get hold of a log file to see what is happening.

All the best,
Joel
Thanks for feedback. But i am using playerprefs.

Re: State of saved data after app update

Posted: Tue Nov 26, 2019 7:02 pm
by Joel
Hi there,

The same should also apply to PlayerPrefs, as it simply stores a file on the file system or within the registry.

All the best,
Joel

Re: State of saved data after app update

Posted: Thu Dec 12, 2019 12:55 pm
by teq
Joel wrote:Hi there,

The same should also apply to PlayerPrefs, as it simply stores a file on the file system or within the registry.

All the best,
Joel
Hi! Another moment...if another user app uses ES, will it overwrite my player prefs file, so should i generate unique name for this?

Re: State of saved data after app update

Posted: Thu Dec 12, 2019 4:52 pm
by Joel
Hi there,

Different apps use different PlayerPrefs areas, so the file will not be overwritten in this case.

If having users of the same app, you’ll need to add their username to the file name to make it specific to each user.

All the best,
Joel