void OnDestroy() { GameEvents.onGUIApplicationLauncherReady.Remove(OnGUIAppLauncherReady); if (this.axis != null) { EditorLogic.DestroyObject(this.axis); } if (KVVButton != null) { ApplicationLauncher.Instance.RemoveModApplication(KVVButton); } }
void OnDestroy() { log.debug("OnDestroy"); if (this.axis != null) { EditorLogic.DestroyObject(this.axis); } toolbarControl.OnDestroy(); Destroy(toolbarControl); Resources.UnloadUnusedAssets();//fix memory leak? }
void onAppLaunchToggleOff() { EditorLogic.DestroyObject(this.axis); visible = false; }
void onAppLaunchToggleOff() { this.control.Config.Revert(); EditorLogic.DestroyObject(this.axis); visible = false; }