Loading Material

Discussion and help for Easy Save 3
Post Reply
robert.nally
Posts: 6
Joined: Fri Jun 01, 2018 5:34 pm

Loading Material

Post by robert.nally »

Hi,

I'm having an issue where when I load my player's material from Easy Save it loads a Legacy Shader with just a diffuse texture. If I assign the material through a button it comes out alright (shows emission, etc.). Any idea what I might be doing wrong?

playerSkin.material = ES2.Load<Material>("InventoryFile.txt?tag=playerSkinTag");

Is the issue that I'm using Easy Save 2 and not 3? I have Easy Save 3. Would upgrading my existing code be as easy as replacing ES2 with ES3? or might you have any upgrade recommendations?

Thanks,
Rob
User avatar
Joel
Moodkie Staff
Posts: 4826
Joined: Wed Nov 07, 2012 10:32 pm

Re: Loading Material

Post by Joel »

Hi there,

Unfortunately we are unable to provide support for Easy Save 2 as it was depreciated quite a few years ago. Easy Save 3 uses a different format to Easy Save 2, so if you have existing save data you would need to load this using Easy Save 2 and re-save it using Easy Save 3 in order to be able to use it.

If you're able to create a new project with a simple scene using the latest version of Easy Save 3 which replicates this I'm happy to take a look and see what is happening.

All the best,
Joel
Joel @ Moodkie Interactive
Purchase Easy Save | Contact | Guides | Docs | Getting started
robert.nally
Posts: 6
Joined: Fri Jun 01, 2018 5:34 pm

Re: Loading Material

Post by robert.nally »

Do you have any recommendations for updating or upgrading code from Easy Save 2 to 3? Would it be as simple as swapping ES2 with ES3 in lines like this:

ES2.Save (currentScene, "LevelFile.txt?tag=sceneTag");
User avatar
Joel
Moodkie Staff
Posts: 4826
Joined: Wed Nov 07, 2012 10:32 pm

Re: Loading Material

Post by Joel »

Easy Save 3 has a different API to Easy Save 2, so I recommend taking a look at the guides for Easy Save 3:

https://docs.moodkie.com/product/easy-s ... s3-guides/

For example, we no longer use this notation:
"LevelFile.txt?tag=sceneTag"
And instead your line of code would be:

Code: Select all

ES3.Save("sceneTag", currentScene, "LevelFile.txt");
Detailed information for each method can be found in the API reference:

https://docs.moodkie.com/easy-save-3/es3-api/es3-class/

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