Good afternoon
In general, I managed to configure saving system with Easy Save, but I ran into a problem.
I have an object A, which is instantiated from a prefab at runtime (production building). It contains several lists of objects B, which are also instantiated from prefabs by script (for example, production resources).
When some resource ends (Object B), its game object destroys and its also removes from the list.
When I do loading, all my resources are loading correct, but those whose game objects were removed earlier are not added to the list.
Also, new resource wich was instantiated after game was saven - isn'd deleted.
I hope screenshots will help to explain the situation.
Perhaps I am doing something wrong, or the plugin does not support such an opportunity. Thank you in advance!
Losing connections with prefabs
Re: Losing connections with prefabs
Hi there, and take for getting in contact.
First it's important to know that Easy Save can't load a reference to something which doesn't exist, so you must ensure that all objects are loaded before trying to load references to them. Sometimes it's easiest to load twice in this case: once to load all objects, and again to load references to those objects.
If this doesn't resolve you issue, please could you replicate this in a new project with a simple scene and private message it to me with instructions.
All the best,
Joel
First it's important to know that Easy Save can't load a reference to something which doesn't exist, so you must ensure that all objects are loaded before trying to load references to them. Sometimes it's easiest to load twice in this case: once to load all objects, and again to load references to those objects.
If this doesn't resolve you issue, please could you replicate this in a new project with a simple scene and private message it to me with instructions.
This is expected behaviour because there's no indication in the save data that this object would need to be deleted. In this case you would need to manually delete the prefab yourself before our after loading.Also, new resource wich was instantiated after game was saven - isn'd deleted.
All the best,
Joel
Re: Losing connections with prefabs
Double load did the trick!
Thanks a lot!
Thanks a lot!