I have a GameManager class that holds a dictionary of a class TileManager. I have made an ES3Type for TileManager as well as GameManager. When saving GameManager and loading it via loadinto, it works fine with normal types, but when I try to access the dictionary TileManagerDict it returns true on TileManagerDict.Containskey(SceneName), but when accessing that TileManagerClass it throws a null exception error.
I know that the way I am accessing the data isn't an issue because I'm able to access the dictionary during runtime, its only after saving and loading that it returns null exception error.
I made a type TileManagerArray as well but that didn't work either.
Any ideas?
Saving Dictionary of a Class not working
Re: Saving Dictionary of a Class not working
Hi there,
It's not possible for me to tell what is happening from what you've described. Please could you create a basic script which I can drop into a new scene which demonstrates your issue?
All the best,
Joel
It's not possible for me to tell what is happening from what you've described. Please could you create a basic script which I can drop into a new scene which demonstrates your issue?
All the best,
Joel
Re: Saving Dictionary of a Class not working
When I reduced what was saved to exclusively the two dictionaries it did as expected fortunately. Seems I was attempting to save a static reference to an instance which may have been causing an issue to make the entire class save null.
All good, ty for quick reply.
All good, ty for quick reply.