Serialization abstract class and it's child's into xml

I'm making component system for my game engine (and have no idea what I'm doing, lol). I need to serialize my SceneData structure with all the entity datas and it's components. I'll probably go crazy doing this:
[XmlInclude(typeof(SomeComponent))]
public abstract class Component
{
...
}
[XmlInclude(typeof(SomeComponent))]
public abstract class Component
{
...
}
So, is there other ways to serialize all the Component childs (RigidBody, MeshRenderer, LightSource etc)?
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server