summaryrefslogtreecommitdiff
path: root/ui/manualCameraController.cpp
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2021-12-28 15:42:50 +0000
committerDan Goodliffe <dan@randomdan.homeip.net>2021-12-28 15:42:50 +0000
commitde9909df038d1b6bb47bcc82fea5f8dc9dec2491 (patch)
treeb1f1337603c1bda68760d3f5f5147bc345e3e77f /ui/manualCameraController.cpp
parentComponent position mouse click check should only match mouse button events (diff)
downloadilt-de9909df038d1b6bb47bcc82fea5f8dc9dec2491.tar.bz2
ilt-de9909df038d1b6bb47bcc82fea5f8dc9dec2491.tar.xz
ilt-de9909df038d1b6bb47bcc82fea5f8dc9dec2491.zip
Initial implementation for being able to click in the main window to select something
Diffstat (limited to 'ui/manualCameraController.cpp')
-rw-r--r--ui/manualCameraController.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/ui/manualCameraController.cpp b/ui/manualCameraController.cpp
index 568c547..74b526b 100644
--- a/ui/manualCameraController.cpp
+++ b/ui/manualCameraController.cpp
@@ -22,6 +22,18 @@ ManualCameraController::handleInput(const SDL_Event & e, const Position &)
case SDLK_RCTRL:
ctrl = false;
return true;
+ case SDLK_KP_8:
+ direction = 0;
+ break;
+ case SDLK_KP_4:
+ direction = -half_pi;
+ break;
+ case SDLK_KP_6:
+ direction = half_pi;
+ break;
+ case SDLK_KP_2:
+ direction = pi;
+ break;
}
break;
case SDL_MOUSEBUTTONDOWN: