aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Sandulenko2016-09-02 17:23:20 +0200
committerEugene Sandulenko2016-09-02 17:25:31 +0200
commitfce9e495f93f47333cc75830986844244f1cce6f (patch)
tree2d9b92acf1c68cc3d4c1ed0700dc1e39df1d698d
parented41bbaca7c253d1e9b1f32e01b6cc767131e4c0 (diff)
downloadscummvm-rg350-fce9e495f93f47333cc75830986844244f1cce6f.tar.gz
scummvm-rg350-fce9e495f93f47333cc75830986844244f1cce6f.tar.bz2
scummvm-rg350-fce9e495f93f47333cc75830986844244f1cce6f.zip
DIRECTOR: Added basic keycode mapping
-rw-r--r--engines/director/score.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/engines/director/score.cpp b/engines/director/score.cpp
index 69d974a21c..49ec050dc1 100644
--- a/engines/director/score.cpp
+++ b/engines/director/score.cpp
@@ -842,6 +842,23 @@ void Score::processEvents() {
if (event.type == Common::EVENT_KEYDOWN) {
_vm->_keyCode = event.kbd.keycode;
+ switch (_vm->_keyCode) {
+ case Common::KEYCODE_LEFT:
+ _vm->_keyCode = 123;
+ break;
+ case Common::KEYCODE_RIGHT:
+ _vm->_keyCode = 124;
+ break;
+ case Common::KEYCODE_DOWN:
+ _vm->_keyCode = 125;
+ break;
+ case Common::KEYCODE_UP:
+ _vm->_keyCode = 126;
+ break;
+ default:
+ warning("Keycode: %d", _vm->_keyCode);
+ }
+
_lingo->processEvent(kEventKeyDown, 0);
}
}