diff options
author | Martin Kiewitz | 2016-02-09 19:34:50 +0100 |
---|---|---|
committer | Martin Kiewitz | 2016-02-09 19:34:50 +0100 |
commit | 73cf4a80e8b65fda3fe959e10181308622f9da6d (patch) | |
tree | ba8047ff037a425ad9343a09c22b20e75f044494 /engines/agi | |
parent | 142de4fffbf079c46ed7ce3339c0f93a4f1af624 (diff) | |
download | scummvm-rg350-73cf4a80e8b65fda3fe959e10181308622f9da6d.tar.gz scummvm-rg350-73cf4a80e8b65fda3fe959e10181308622f9da6d.tar.bz2 scummvm-rg350-73cf4a80e8b65fda3fe959e10181308622f9da6d.zip |
AGI: Hold-Key: only send stationary for directions
Diffstat (limited to 'engines/agi')
-rw-r--r-- | engines/agi/keyboard.cpp | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/engines/agi/keyboard.cpp b/engines/agi/keyboard.cpp index 9b745b7fbf..ba1b2f5729 100644 --- a/engines/agi/keyboard.cpp +++ b/engines/agi/keyboard.cpp @@ -256,7 +256,28 @@ void AgiEngine::processScummVMEvents() { // Original AGI actually created direction events in here // We don't do that, that's why we create a stationary event instead, which will // result in a direction change to 0 in handleController(). - keyEnqueue(AGI_KEY_STATIONARY); + switch (event.kbd.keycode) { + case Common::KEYCODE_LEFT: + case Common::KEYCODE_RIGHT: + case Common::KEYCODE_UP: + case Common::KEYCODE_DOWN: + case Common::KEYCODE_HOME: + case Common::KEYCODE_END: + case Common::KEYCODE_PAGEUP: + case Common::KEYCODE_PAGEDOWN: + case Common::KEYCODE_KP4: + case Common::KEYCODE_KP6: + case Common::KEYCODE_KP8: + case Common::KEYCODE_KP2: + case Common::KEYCODE_KP9: + case Common::KEYCODE_KP3: + case Common::KEYCODE_KP7: + case Common::KEYCODE_KP1: + keyEnqueue(AGI_KEY_STATIONARY); + break; + default: + break; + } } break; |