]> git.localhorst.tv Git - l2e.git/blobdiff - src/battle/states/SelectMoveAction.cpp
added timer facility
[l2e.git] / src / battle / states / SelectMoveAction.cpp
index 5631e69856f166b930cb1fb7023eb97987ff2e97..de8e97b4db066fca0b316cfcc767094470f8bc89 100644 (file)
@@ -8,6 +8,7 @@
 #include "SelectMoveAction.h"
 
 #include "SelectAttackType.h"
+#include "SwapHeroes.h"
 #include "../BattleState.h"
 #include "../MoveMenu.h"
 #include "../../app/Application.h"
@@ -43,7 +44,7 @@ void SelectMoveAction::Resize(int width, int height) {
 }
 
 
-void SelectMoveAction::HandleInput(const app::Input &input) {
+void SelectMoveAction::HandleInput(const Input &input) {
        if (input.IsDown(Input::PAD_UP)) {
                battle->GetMoveMenu().Select(MoveMenu::CHANGE);
        } else if (input.IsDown(Input::PAD_DOWN)) {
@@ -59,7 +60,7 @@ void SelectMoveAction::HandleInput(const app::Input &input) {
                                battle->NextHero();
                                break;
                        case MoveMenu::CHANGE:
-                               // TODO: switch to change state
+                               ctrl->PushState(new SwapHeroes(battle, this));
                                break;
                        case MoveMenu::RUN:
                                // TODO: switch to run state