I'm not sure I've explained myself correctly, sorry.
What I meant is that I have a struct that I am using to save my data.
Here is the data written in the .json file:
"InGameMenu": {
"__type": "UI.SavedActionKey,Assembly-CSharp",
"value": {
"Name": "InGameMenu",
"Key1": {
"Key": 27,
"IsCtrl": false,
"IsAlt": false,
"IsShift": false
},
"Key2": {
"Key": 0,
"IsCtrl": false,
"IsAlt": false,
"IsShift": false
}
}
},
As you can see, my struct is called 'SavedActionKey'.
If I rename it in my code to 'SavedAction' for example, then I recompile, and then I launch my game, when it will attempt to load the data the exception I had will occur.
What I have to do is either to rename the type in the file, or to clear it and save it again with the new struct name.
For now it's not a problem for me as I'm still in development, but that would prevent any renaming in a released game.
I understand that you use the name of the type to identify it, but I was just asking if there was a way to read the data anyway as long as the format is compatible.