Selaa lähdekoodia

tool trickerey
label the editor buttons with thier respective hotkeys, and hide them if the ToolsModule doesn't exist

AzaezelX 3 vuotta sitten
vanhempi
commit
8f1b98a4d6
1 muutettua tiedostoa jossa 6 lisäystä ja 2 poistoa
  1. 6 2
      Templates/BaseGame/game/data/UI/guis/MainMenuButtons.gui

+ 6 - 2
Templates/BaseGame/game/data/UI/guis/MainMenuButtons.gui

@@ -52,20 +52,24 @@ $guiContent = new GuiControl(MainMenuButtons) {
          tooltipProfile = "GuiToolTipProfile";
       };
       new GuiButtonCtrl(MainMenuWorldEditBtn) {
-         text = "Open World Editor";
+         text = "Open World Editor (F11)";
          position = "0 280";
          extent = "400 55";
          profile = "GuiMenuButtonProfile";
          command = "openWorldEditorBtn();";
          tooltipProfile = "GuiToolTipProfile";
+         enabled = (ModuleDatabase.findModule("ToolsModule") !$= "");
+         visible = (ModuleDatabase.findModule("ToolsModule") !$= "");
       };
       new GuiButtonCtrl(MainMenuGuiEditBtn) {
-         text = "Open GUI Editor";
+         text = "Open GUI Editor (F10)";
          position = "0 350";
          extent = "400 55";
          profile = "GuiMenuButtonProfile";
          command = "openGUIEditorBtn();";
          tooltipProfile = "GuiToolTipProfile";
+         enabled = (ModuleDatabase.findModule("ToolsModule") !$= "");
+         visible = (ModuleDatabase.findModule("ToolsModule") !$= "");
       };
       new GuiButtonCtrl(MainMenuExitBtn) {
          text = "Exit";