private void CloseGUI() { showGUI = guiMode.None; exchangeContainer = null; availableContents = null; if (HighLogic.LoadedSceneIsEditor) { EditorLogic.fetch.Unlock("KAS DisableEditorClickthrough"); } }
public void ViewContents() { if (showGUI != guiMode.None) { CloseGUI(); } else { CloseAllGUI(); guiMainWindowPos = new Rect(Screen.width / 2, Screen.height / 2, 10, 10); showGUI = guiMode.View; fxSndOpen.audio.Play(); } }
public void TakeContents(Vessel evaVessel) { if (showGUI != guiMode.None) { CloseGUI(); fxSndClose.audio.Play(); } else { CloseAllGUI(); guiMainWindowPos = new Rect(Screen.width / 2, Screen.height / 2, 10, 10); showGUI = guiMode.Take; fxSndOpen.audio.Play(); } }
public void EditContents() { if (showGUI != guiMode.None) { CloseGUI(); fxSndClose.audio.Play(); } else { CloseAllGUI(); availableContents = GetAvailableContents(); guiMainWindowPos = new Rect(Screen.width / 3, 35, 10, 10); showGUI = guiMode.Edit; fxSndOpen.audio.Play(); } }
public void ExchangeContents(KASModuleContainer moduleContainer) { if (showGUI != guiMode.None) { CloseGUI(); fxSndClose.audio.Play(); } else { CloseAllGUI(); exchangeContainer = moduleContainer; guiMainWindowPos = new Rect(Screen.width / 2, Screen.height / 2, 10, 10); showGUI = guiMode.Exchange; fxSndOpen.audio.Play(); } }
private void CloseGUI() { showGUI = guiMode.None; exchangeContainer = null; availableContents = null; if (HighLogic.LoadedSceneIsEditor) EditorLogic.fetch.Unlock(); }