Getting weird errors.

Discussion and help for Easy Save 3

Getting weird errors.

Postby NoahB » Wed Mar 18, 2020 5:09 am

Hi when I try to load or save I get the two errors, how would i fix these errors? I don't know what info I should give so here:

Heres the load error:
https://pastebin.com/s5mK7XeX

Heres the save error:
https://pastebin.com/4AhBR1kN

Picture 1:
https://gyazo.com/9732a33a939366d8651dd70bebc570b1

Picture 2:
https://gyazo.com/05dff2eed97311e2c83461bd7ebde58e
NoahB
 
Posts: 4
Joined: Wed Mar 18, 2020 5:01 am

Re: Getting weird errors.

Postby Joel » Wed Mar 18, 2020 7:50 am

Hi there,

The error suggests that the generic parameter you're providing does not match the type of data that you are saving. For example, this would cause the save error:

float myFloat = 123f;
ES3.Save<int>("key", myFloat);


And similarly, this would cause the load error:

float myFloat = 123f;
ES3.Save<float>("key", myFloat);
ES3.Load<int>("key");


Would you be able to show me the code you are using to save and load?

All the best,
Joel
Joel @ Moodkie Interactive
Twitter - Unity - LinkedIn
User avatar
Joel
Moodkie Staff
 
Posts: 2688
Joined: Wed Nov 07, 2012 10:32 pm

Re: Getting weird errors.

Postby NoahB » Wed Mar 18, 2020 5:56 pm

Save & Load Script + Delete: https://pastebin.com/tTgPST10
NoahB
 
Posts: 4
Joined: Wed Mar 18, 2020 5:01 am

Re: Getting weird errors.

Postby Joel » Wed Mar 18, 2020 5:57 pm

Hi there,

There is a mistake in your code. You're trying to load from the same key twice here, once as an int and once as a float:

LevelManager.instance.currentPts = ES3.Load<int>("currentPts");
LevelManager.instance.currentVol = ES3.Load<float>("currentPts");


All the best,
Joel
Joel @ Moodkie Interactive
Twitter - Unity - LinkedIn
User avatar
Joel
Moodkie Staff
 
Posts: 2688
Joined: Wed Nov 07, 2012 10:32 pm

Re: Getting weird errors.

Postby NoahB » Wed Mar 18, 2020 6:00 pm

Actually I fixed that, its still giving me the same errors. https://pastebin.com/nVY27dEY
NoahB
 
Posts: 4
Joined: Wed Mar 18, 2020 5:01 am

Re: Getting weird errors.

Postby Joel » Wed Mar 18, 2020 6:03 pm

Hi there,

Firstly, I would try deleting your existing save data by going to Window > Easy Save 3 > Tools > Open Persistent Data Path, and deleting the data from there.

If this doesn't resolve the issue, please could you private message me a basic project or script which replicates this?

All the best,
Joel
Joel @ Moodkie Interactive
Twitter - Unity - LinkedIn
User avatar
Joel
Moodkie Staff
 
Posts: 2688
Joined: Wed Nov 07, 2012 10:32 pm

Re: Getting weird errors.

Postby NoahB » Wed Mar 18, 2020 6:35 pm

Joel wrote:Hi there,

Firstly, I would try deleting your existing save data by going to Window > Easy Save 3 > Tools > Open Persistent Data Path, and deleting the data from there.

If this doesn't resolve the issue, please could you private message me a basic project or script which replicates this?

All the best,
Joel


Yeah, it still doesn't want to work. So I sent a pm.
NoahB
 
Posts: 4
Joined: Wed Mar 18, 2020 5:01 am


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 2 guests