Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Apr 16, 2010, 1:07:57 PM (14 years ago)
Author:
rgrieder
Message:
  • Bugfix in keyESC.
  • Default behaviour for GUI sheet InputStates is now not to handle keyboard input —> KeyBinder is used.
  • Added some temporary hackery to GSMainMenu to enable the use of Keys in the MainMenu.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/gamestates2/src/orxonox/gamestates/GSMainMenu.cc

    r6741 r6743  
    4040#include "Scene.h"
    4141#include "sound/AmbientSound.h"
     42// HACK
     43#include "core/input/InputManager.h"
     44#include "core/input/InputState.h"
    4245
    4346namespace orxonox
     
    4952    {
    5053        RegisterRootObject(GSMainMenu);
     54
     55        InputManager::getInstance().createInputState("MainMenuHackery")->setKeyHandler(KeyBinderManager::getInstance().getDefaultAsHandler());
    5156
    5257        // create an empty Scene
     
    6873            this->ambient_->destroy();
    6974
     75        InputManager::getInstance().destroyState("MainMenuHackery");
     76
    7077        this->scene_->getSceneManager()->destroyCamera(this->camera_);
    7178        this->scene_->destroy();
     
    7986        GUIManager::getInstance().setBackgroundImage("MainMenuBackground", "Background");
    8087        GraphicsManager::getInstance().setCamera(this->camera_);
     88
     89        InputManager::getInstance().enterState("MainMenuHackery");
    8190
    8291        CommandExecutor::addConsoleCommandShortcut(createConsoleCommand(createFunctor(&GSMainMenu::startStandalone), "startGame"));
     
    106115            this->ambient_->stop();
    107116        }
     117
     118        InputManager::getInstance().leaveState("MainMenuHackery");
    108119
    109120        GUIManager::getInstance().setCamera(0);
Note: See TracChangeset for help on using the changeset viewer.