Save and Load, prefabs?

JohnH

New member
Hi there, very new user here, thank you.

I am trying to get Save/Load working, and mostly it is but was wondering how to Load prefabs from the Save file.

My use case, I have an item on the ground which has an ItemObject attached to it and the ItemObject is linked to the inventory item correctly. When I Save, each of my collections is saved correctly, but when I Load the prefab is not there.

Is that something I need to do manually? That is, after my Load, cycle through each "grounded" item and generate the prefab myself and link ItemObject to it?

many thanks for your help and best wishes from Australia

John
 
Yes, that is indeed the case.
Our Save System is a modular system where you save only the things you want. There are a few Saver components that come built-in, like the "Inventory Saver" or the "Inventory System Manager Item Saver". These allow you to save your items within your inventory.

To save anything else with our save system you will need to create a custom Saver script. All you need is to inherit the SaveBase class and override the "Serialize Save Data" and "Deserialize And Load Save Data" functions.

You can find a simple example in the documentation:
 
Top