Changeset 6024 for code/branches/menu/src/orxonox
- Timestamp:
- Nov 4, 2009, 2:14:53 PM (15 years ago)
- Location:
- code/branches/menu
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/menu
- Property svn:mergeinfo changed
/code/branches/ingamemenu (added) merged: 6003,6018-6020,6022-6023
- Property svn:mergeinfo changed
-
code/branches/menu/src/orxonox/gamestates/GSGraphics.cc
r5929 r6024 64 64 void GSGraphics::activate() 65 65 { 66 // add console command to toggle GUI 67 CommandExecutor::addConsoleCommandShortcut(createConsoleCommand(createFunctor(&GSGraphics::toggleGUI, this), "toggleGUI")); 66 68 67 } 69 68 … … 78 77 } 79 78 80 /**81 @brief82 Toggles the visibility of the current GUI83 84 This function just executes a Lua function in the main script of the GUI by accessing the GUIManager.85 For more details on this function check out the Lua code.86 */87 void GSGraphics::toggleGUI()88 {89 GUIManager::getInstance().executeCode("toggleGUI()");90 }91 92 79 void GSGraphics::update(const Clock& time) 93 80 { -
code/branches/menu/src/orxonox/gamestates/GSGraphics.h
r5929 r6024 57 57 void update(const Clock& time); 58 58 59 void toggleGUI();60 61 59 private: 62 60 }; -
code/branches/menu/src/orxonox/gamestates/GSLevel.cc
r5929 r6024 101 101 if (show) 102 102 { 103 GUIManager::getInstance().showGUI("inGameTest"); 104 GUIManager::getInstance().executeCode("showCursor()"); 105 InputManager::getInstance().enterState("guiMouseOnly"); 103 GUIManager::showGUI("inGameTest"); 106 104 } 107 105 else 108 106 { 109 GUIManager::getInstance().executeCode("hideGUI(\"inGameTest\")"); 110 GUIManager::getInstance().executeCode("hideCursor()"); 111 InputManager::getInstance().leaveState("guiMouseOnly"); 107 GUIManager::hideGUI("inGameTest"); 112 108 } 113 109 } -
code/branches/menu/src/orxonox/gamestates/GSMainMenu.cc
r5929 r6024 82 82 { 83 83 // show main menu 84 GUIManager::getInstance().showGUI("MainMenu" );84 GUIManager::getInstance().showGUI("MainMenu", false); 85 85 GUIManager::getInstance().setCamera(this->camera_); 86 86 GraphicsManager::getInstance().setCamera(this->camera_); … … 113 113 114 114 GUIManager::getInstance().setCamera(0); 115 GUIManager::hideGUI("MainMenu"); 115 116 GraphicsManager::getInstance().setCamera(0); 116 117 } -
code/branches/menu/src/orxonox/pickup/PickupInventory.cc
r5781 r6024 86 86 { 87 87 if(PickupInventory::getSingleton()->isVisible()) { 88 GUIManager::getInstance().executeCode("hideGUI(\"PickupInventory\")"); 89 GUIManager::getInstance().executeCode("hideCursor()"); 90 InputManager::getInstance().leaveState("guiMouseOnly"); 91 } 92 else 93 { 94 GUIManager::getInstance().showGUI("PickupInventory"); 95 GUIManager::getInstance().executeCode("showCursor()"); 96 InputManager::getInstance().enterState("guiMouseOnly"); 88 GUIManager::hideGUI("PickupInventory"); 89 } 90 else 91 { 92 GUIManager::showGUI("PickupInventory"); 97 93 } 98 94 PickupInventory::getSingleton()->setVisible(!PickupInventory::getSingleton()->isVisible()); -
code/branches/menu/src/orxonox/pickup/PickupSpawner.cc
r5929 r6024 96 96 // & load the GUI itself too, along with some empty windows 97 97 // = even less delays 98 GUIManager:: getInstance().showGUI("PickupInventory");99 GUIManager:: getInstance().executeCode("hideGUI(\"PickupInventory\")");98 GUIManager::showGUI("PickupInventory"); 99 GUIManager::hideGUI("PickupInventory"); 100 100 PickupInventory::getSingleton(); 101 101 }
Note: See TracChangeset
for help on using the changeset viewer.