public void OnDestroy() { Instance = null; try { GameEvents.onGUIApplicationLauncherReady.Remove(this.OnGuiAppLauncherReady); if (button != null) { ApplicationLauncher.Instance.RemoveModApplication(button); } } catch (Exception ex) { Logging.LogException(ex); } }
public void Start() { if (Instance != null) { Destroy(this); return; } Instance = this; masterWindow = new ksp_ris.UI.MasterWindow(server); if (ScenarioRIS.Instance != null) { Load(ScenarioRIS.Instance.node); } server.monitor = monitor; Logging.Log("RISCore loaded successfully."); }