- Home /
Question by
Faestus · Apr 04, 2015 at 08:34 PM ·
xmlxmlserializer
Serialize a class that extends as a serializable class?
Ok so I have this class:
public class Candy {
public float Sweetnes;
}
And another one
public class LoliPop:Candy {
LoliPop() {
Sweetnes=0
}
}
When I try to XML serialize this class, I get a error saying my class is not a primitive. Is it possible to serialize like this?
Comment
Your answer
![](https://koobas.hobune.stream/wayback/20220613192151im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
DataContract serialization not compatible with Unity? 0 Answers
Serialization and XML 1 Answer
Unity Serialization with XML Root problem: 'Does Not Denote Valid Type' 0 Answers
Columns in XML serialization 0 Answers
XML Serialization in Windows phone 8 2 Answers