public void OnHandClick(GUIHand guiHand) { if (!this.Buildable.constructed) { return; } PdaOverlayManager.StartConnectingToPda(this.Modules); Player main = Player.main; PDA pda = main.GetPDA(); Inventory.main.SetUsedStorage(this.Modules, false); pda.Open(PDATab.Inventory, null, new PDA.OnClose((PDA closingPda) => PdaOverlayManager.DisconnectFromPda()), -1f); }
public static void Postfix(UpgradeConsole __instance) { PDA pda = Player.main.GetPDA(); pda.onClose = new PDA.OnClose((PDA closingPda) => PdaOverlayManager.DisconnectFromPda()); }
/// <summary> /// Opens the player's PDA and displays the equipment module slots.<para/> /// Upgrade Console must be fully constructed to access the equipment slots. /// </summary> protected void OpenEquipmentScreen() { if (!this.Buildable.constructed) { return; } PdaOverlayManager.StartConnectingToPda(this.Modules); Player main = Player.main; global::PDA pda = main.GetPDA(); Inventory.main.SetUsedStorage(this.Modules, false); pda.Open(PDATab.Inventory, null, new global::PDA.OnClose((closingPdaEvent) => PdaOverlayManager.DisconnectFromPda()), -1f); }