- Home /
Does XML Serialization Support "Class Object" Arrays?
Hi there i'm having a complete headache with XML Serialization, I'm trying to store a load of data across various class object within other class objects etc etc, storing each up through an array, but I keep getting The type of the argument object is not primitive
error.
Any ideas? - Caius
I've been reading about Deep Serialization, anyone encountered this and successfully implemented the serialization of a complex object within Unity?
Answer by Dreamora · Jul 13, 2011 at 08:25 PM
Serialization is no problem.
Are you sure that the class you try to serialize is marked as serializable? because you need to have serializable classes. The SerializeObject / DeserializeObject functions on the unifycommunity give you a good start on a function to serialize from and to XML