Hi, I’m wondering if there are some common rules for deleting objects in Unity. For example I read that it’s a good idea to add the OnDestroy method to any MonoBehaviour and set all the class member to null to avoid “memory leak” and to be sure that an automatic destructor is not called (similar to C++). Am I wrong or there’s truth?
And what about classes that are not MonoBehaviour can I write a destructor that force the ref. counting to zero?
Thanks in advance.