Saving a whole scene Question

Discussion and help for Easy Save 3
BTippen
Posts: 25
Joined: Sun Nov 22, 2020 10:58 am

Saving a whole scene Question

Post by BTippen »

So I am trying to save a whole scene. I have hundreds of GameObjects under one parent. Is there a way I can save the parent and include all the children and their positions in the scene? I am aware I can try and loop through each possible GameObject and save its position but looking for a short cut.
BTippen
Posts: 25
Joined: Sun Nov 22, 2020 10:58 am

Re: Saving a whole scene Question

Post by BTippen »

Surely if I am saving a GameObject it will save its position as well?
User avatar
Joel
Moodkie Staff
Posts: 4826
Joined: Wed Nov 07, 2012 10:32 pm

Re: Saving a whole scene Question

Post by Joel »

Hi there,

You can save the entire GameObject with Save GameObject children enabled in settings, but be aware that this will save the entire hierarchy which could be performance intensive for so many GameObjects.

All the best,
Joel
Joel @ Moodkie Interactive
Purchase Easy Save | Contact | Guides | Docs | Getting started
BTippen
Posts: 25
Joined: Sun Nov 22, 2020 10:58 am

Re: Saving a whole scene Question

Post by BTippen »

Joel wrote: Wed Jan 20, 2021 4:21 pm Hi there,

You can save the entire GameObject with Save GameObject children enabled in settings, but be aware that this will save the entire hierarchy which could be performance intensive for so many GameObjects.

All the best,
Joel
Can this be done in code?
User avatar
Joel
Moodkie Staff
Posts: 4826
Joined: Wed Nov 07, 2012 10:32 pm

Re: Saving a whole scene Question

Post by Joel »

Hi there,

This is covered in the Saving and Loading GameObjects guide:
https://docs.moodkie.com/easy-save-3/es ... s-prefabs/

All the best,
Joel
Joel @ Moodkie Interactive
Purchase Easy Save | Contact | Guides | Docs | Getting started
BTippen
Posts: 25
Joined: Sun Nov 22, 2020 10:58 am

Re: Saving a whole scene Question

Post by BTippen »

Joel wrote: Wed Jan 20, 2021 5:40 pm Hi there,

This is covered in the Saving and Loading GameObjects guide:
https://docs.moodkie.com/easy-save-3/es ... s-prefabs/

All the best,
Joel
I had read them. Thank you for this help Joel I really appreciate it. When I save GameOBjects like this and reload them in some of the components are missing like the scripts and the colliders. What do I have to do to make sure they are saved as well? Is there some thig I am missing?
User avatar
Joel
Moodkie Staff
Posts: 4826
Joined: Wed Nov 07, 2012 10:32 pm

Re: Saving a whole scene Question

Post by Joel »

Hi there,

Did you see this is in the guide:
This will save and load the following:

- layer, tag, name and hideFlags.
- Components on the Natively-supported types list, or those which have been manually supported using an ES3Type.
- All of the above for every child of the GameObject.
You can see what types are natively supported, and how to manually add support, in the Supported Types guide:
https://docs.moodkie.com/easy-save-3/es ... ted-types/

All the best,
Joel
Joel @ Moodkie Interactive
Purchase Easy Save | Contact | Guides | Docs | Getting started
BTippen
Posts: 25
Joined: Sun Nov 22, 2020 10:58 am

Re: Saving a whole scene Question

Post by BTippen »

Yes but I have added the [ES3Serializable] to the Scripts but the components are still not saving.

Also why is CircleCollider2D not included in the components saved.
User avatar
Joel
Moodkie Staff
Posts: 4826
Joined: Wed Nov 07, 2012 10:32 pm

Re: Saving a whole scene Question

Post by Joel »

Hi there,

Sorry, I think you may have read the text I quoted incorrectly. You need to create an ES3Type for it to be serialised. I've linked the specific information on this here.

All the best,
Joel
Joel @ Moodkie Interactive
Purchase Easy Save | Contact | Guides | Docs | Getting started
BTippen
Posts: 25
Joined: Sun Nov 22, 2020 10:58 am

Re: Saving a whole scene Question

Post by BTippen »

Yes that worked!!!!

Thank you so much Joel. Great Support!
Post Reply