- Home /
How to serialize scriptable objects in a way that keeps references/instances of other scriptable objects.
I'm creating a strategy game in the style of fire emblem and I have "Unit" scriptable objects that have an inventory (List) of "Item" scriptable objects. These Items need to be stored as well do to needing to keep track of things like durability and upgrades made to that specific instance of an item. I need to know how to do that properly. Originally I just had the idea of including a "serialization" of that item inside the unit as it was serialized but the documentation basically says that can't happen as I don't know what sort of variable it would be stored as much less if that variable type can be serialized. So now I'm looking for new ways that each item can be stored "Inside" the unit so they can be serialized together. On the alternative, if I'm being stupid and there's a much easier way to fix this problem, please inform me.
Your answer
Follow this Question
Related Questions
Help with scriptableobjects 1 Answer
Saving players progress in ScriptableObject asset 1 Answer
Field is member of a type which is serializable but is of type which is not serializable 0 Answers
Abstract classes in a ScriptableObject 1 Answer
Make the same serialized class as a ScriptableObject? 1 Answer