Good solution for store image?

Easy Save 2 has been replaced by Easy Save 3, so is no longer supported.
Locked
leegod
Posts: 18
Joined: Sun Nov 20, 2016 10:42 am

Good solution for store image?

Post by leegod »

I had no problem at save & load when I used Texture2D variables. Image import setting is Sprite though.

Save done very quickly.

But after I changed to Texture2D variables to Sprite, problem occurs, null reference occur, save execution very slow than before,,,

Are there good way to store image?

Of course not store image is best, but I have class that has image variable... and when it is Sprite type, it become null when game loaded.
User avatar
Joel
Moodkie Staff
Posts: 4849
Joined: Wed Nov 07, 2012 10:32 pm

Re: Good solution for store image?

Post by Joel »

Hi there,

As with your previous issue, try deleting your save data to make sure that you're not trying to load Texture2D data using Sprite.

You might also want to check that your Sprite is not null before trying to save it, as this will also cause a NullReferenceException.

If this does not fix your issue, please could you provide me with a simple sample project and some instructions to replicate the error?

All the best,
Joel
Joel @ Moodkie Interactive
Purchase Easy Save | Contact | Guides | Docs | Getting started
Locked