Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 19, 2009, 5:31:02 PM (15 years ago)
Author:
rgrieder
Message:

Merged all remaining revisions from core4 back to the trunk.

Location:
code/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/orxonox/gamestates/GSLevel.cc

    r3280 r3327  
    3131
    3232#include "core/input/InputManager.h"
    33 #include "core/input/SimpleInputState.h"
     33#include "core/input/InputState.h"
    3434#include "core/input/KeyBinder.h"
    3535#include "core/Clock.h"
     
    9090        if (GameMode::showsGraphics())
    9191        {
    92             gameInputState_ = InputManager::getInstance().createInputState<SimpleInputState>("game");
     92            gameInputState_ = InputManager::getInstance().createInputState("game");
    9393            keyBinder_ = new KeyBinder();
    9494            keyBinder_->loadBindings("keybindings.ini");
    9595            gameInputState_->setHandler(keyBinder_);
    9696
    97             guiMouseOnlyInputState_ = InputManager::getInstance().createInputState<SimpleInputState>("guiMouseOnly");
     97            guiMouseOnlyInputState_ = InputManager::getInstance().createInputState("guiMouseOnly");
    9898            guiMouseOnlyInputState_->setMouseHandler(GUIManager::getInstancePtr());
    9999
    100             guiKeysOnlyInputState_ = InputManager::getInstance().createInputState<SimpleInputState>("guiKeysOnly");
     100            guiKeysOnlyInputState_ = InputManager::getInstance().createInputState("guiKeysOnly");
    101101            guiKeysOnlyInputState_->setKeyHandler(GUIManager::getInstancePtr());
    102102
     
    134134
    135135            // level is loaded: we can start capturing the input
    136             InputManager::getInstance().requestEnterState("game");
     136            InputManager::getInstance().enterState("game");
    137137        }
    138138    }
     
    144144            GUIManager::getInstance().showGUI("inGameTest");
    145145            GUIManager::getInstance().executeCode("showCursor()");
    146             InputManager::getInstance().requestEnterState("guiMouseOnly");
     146            InputManager::getInstance().enterState("guiMouseOnly");
    147147        }
    148148        else
     
    150150            GUIManager::getInstance().executeCode("hideGUI(\"inGameTest\")");
    151151            GUIManager::getInstance().executeCode("hideCursor()");
    152             InputManager::getInstance().requestLeaveState("guiMouseOnly");
     152            InputManager::getInstance().leaveState("guiMouseOnly");
    153153        }
    154154    }
     
    178178
    179179        if (GameMode::showsGraphics())
    180             InputManager::getInstance().requestLeaveState("game");
     180            InputManager::getInstance().leaveState("game");
    181181
    182182        if (GameMode::isMaster())
     
    218218            guiMouseOnlyInputState_->setHandler(0);
    219219            guiKeysOnlyInputState_->setHandler(0);
    220             InputManager::getInstance().requestDestroyState("game");
     220            InputManager::getInstance().destroyState("game");
    221221            if (this->keyBinder_)
    222222            {
     
    286286                {
    287287                    COUT(0) << "Press any button/key or move a mouse/joystick axis" << std::endl;
    288                     InputManager::getInstance().requestEnterState("detector");
     288                    InputManager::getInstance().enterState("detector");
    289289                    bindingString = command;
    290290                    bTemporarySaved = bTemporary;
     
    301301                    COUT(0) << "Binding string \"" << bindingString << "\" on key '" << name << "'" << std::endl;
    302302                    this->keyBinder_->setBinding(bindingString, name, bTemporarySaved);
    303                     InputManager::getInstance().requestLeaveState("detector");
     303                    InputManager::getInstance().leaveState("detector");
    304304                    bound = true;
    305305                }
Note: See TracChangeset for help on using the changeset viewer.