I’m trying to get some fields to save to Json. If I leave the fields public they save no problem. If I mark them with SerializeField and have them private, they do not save. Is this a bug or intended?
According to the documentation, it must be a bug.
If the same rules apply as they do in the Inspector, I’d expect it to serialize private fields via SerializeFieldAttribute.
Hmm created a test project to see if it worked, and it does. Maybe something isn’t setup right in my other project.
I feel quite stupid right now. Was trying to find out what was going on and I found that I’m not even using Json to save my information. Turns out I was using XML, switched over to Json and everything is working fine.
1 Like