Okay so as far as I understood the lecture, OnBeforeSerialize
is a callback when it will get executed before serialization occurs, on of the moment when serialization occurs is when we save our project (Ctrl + S).
And I’m kinda curious when it’s exactly the callback is getting called outside saving project, so I put Debug.Log
in OnBeforeSerialize
and I realized it happened too when hot reload.
But a strange thing happened, it happened too when I opened the dialogue editor window, and I clicked the area inside but not the node. It got called repeatedly (maybe per a half-second) but when I click the node, it stops calling. And I have no idea about that. What’s really happened? How many times and when the serialization will occur? @sampattuzzi