#Scriptable Object arrays of Vector 2 resetting to 0 after reopening the editor.
1 messages · Page 1 of 1 (latest)
I am actually copying the values of vector2's through a script and later pasting it in the SO through a method in the SO. Every thing is saved and okay until I reopen the unity Editor
Show code
the second one is the script I made to copy the datas from the inspector to SO
For which I had to start the game to trigger the Copy_Line_Datas() Method
If values reset after reopening the editor, that's usually a sign that the fields containing those values are not set dirty/serialized properly.
I am not sure why this would be happening in this case, but ScriptableObjects have always been a bit finnicky when it comes to runtime changes (though people mostly have the opposite problem from you lol).
That being said... I strongly advocate that you get rid of all those underscores.
C# conventionally doesn't use Snake_case. And I've never seen any language use trailing underscores. Hideous 