Beispiel #1
0
 void OnDestroy()
 {
     //you must make sure that you unregister the object if the object is destroyed, or else update will be called even if the object no longer exists!
     UpdateMaster.FixedDeregister(this as IUpdateSlave);
 }
Beispiel #2
0
 void OnDisable()
 {
     UpdateMaster.FixedDeregister(this as IUpdateSlave);
 }