diff options
-rw-r--r-- | engines/mortevielle/utils.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/engines/mortevielle/utils.cpp b/engines/mortevielle/utils.cpp index de184bf254..5ca29d849c 100644 --- a/engines/mortevielle/utils.cpp +++ b/engines/mortevielle/utils.cpp @@ -67,9 +67,10 @@ bool MortevielleEngine::keyPressed() { * @remarks Originally called 'get_ch' */ int MortevielleEngine::getChar() { + bool end = false; // If there isn't any pending keypress, wait until there is - while (!shouldQuit() && _keypresses.empty()) { - keyPressed(); + while (!shouldQuit() && !end) { + end = keyPressed(); } // Return the top keypress |