aboutsummaryrefslogtreecommitdiff
path: root/engines/griffon
diff options
context:
space:
mode:
Diffstat (limited to 'engines/griffon')
-rw-r--r--engines/griffon/engine.cpp1
-rw-r--r--engines/griffon/input.cpp6
2 files changed, 4 insertions, 3 deletions
diff --git a/engines/griffon/engine.cpp b/engines/griffon/engine.cpp
index 291076cdaa..5c0a28d791 100644
--- a/engines/griffon/engine.cpp
+++ b/engines/griffon/engine.cpp
@@ -80,7 +80,6 @@ void GriffonEngine::mainLoop() {
void GriffonEngine::updateEngine() {
g_system->updateScreen();
- g_system->getEventManager()->pollEvent(_event);
_ticksPassed = _ticks;
_ticks = g_system->getMillis();
diff --git a/engines/griffon/input.cpp b/engines/griffon/input.cpp
index 4b2ea5cff4..cc6a48dee7 100644
--- a/engines/griffon/input.cpp
+++ b/engines/griffon/input.cpp
@@ -43,8 +43,10 @@ namespace Griffon {
void GriffonEngine::checkInputs() {
int ntickdelay = 175;
+ bool _keyPressed = false;
- g_system->getEventManager()->pollEvent(_event);
+ if (g_system->getEventManager()->pollEvent(_event))
+ _keyPressed = true;
_postInfoNbr = 0;
@@ -307,7 +309,7 @@ __exit_do:
_curEnemy = _lastNpc + _postInfoNbr;
}
} else {
- if (_itemTicks < _ticks) {
+ if (_keyPressed && _event.type == Common::EVENT_KEYDOWN) {
if (_event.kbd.keycode == Common::KEYCODE_UP) {
_curItem = _curItem - 1;
_itemTicks = _ticks + ntickdelay;