I have a generic container, Container<T> that contains a single data (reference or value type). If I have a MonoBehaviour property, eg. an int, and change it to Container<int>, all the previously serializied values are lost. Now I tried to make a custom DataFormatter, so it is serialized just as it would be without the container. But it seems to be not possible, because value and reference types are handled separately.
Is there any way I could acomplish this with Odin? It was possible with other frameworks.
First of all, there could be an option, that makes Odin serialize everything that Unity does. Yes, everything will be serialized twice, but rather this, than not being able to change the property type.
Second, can Container<int> be serialized as if it would be a simple int?