aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
Diffstat (limited to 'engines')
-rw-r--r--engines/supernova/state.cpp3
-rw-r--r--engines/supernova/state.h1
-rw-r--r--engines/supernova/supernova.cpp2
3 files changed, 5 insertions, 1 deletions
diff --git a/engines/supernova/state.cpp b/engines/supernova/state.cpp
index 4fb856a0ad..9bfc4745b8 100644
--- a/engines/supernova/state.cpp
+++ b/engines/supernova/state.cpp
@@ -295,6 +295,7 @@ void GameManager::resetInputState() {
_processInput = false;
_mouseClicked = false;
_key = 0;
+ _keyPressed = false;
_mouseClickType = Common::EVENT_MOUSEMOVE;
processInput();
@@ -543,7 +544,7 @@ void GameManager::mouseInput2() {
while (true) {
_vm->updateEvents();
// TODO: handle key input (e.g. alt+x, F-keys?)
- if (_mouseClicked || _key) {
+ if (_mouseClicked || _keyPressed) {
break;
}
g_system->updateScreen();
diff --git a/engines/supernova/state.h b/engines/supernova/state.h
index 2072d91efe..2c61e153c6 100644
--- a/engines/supernova/state.h
+++ b/engines/supernova/state.h
@@ -106,6 +106,7 @@ public:
uint16 _key;
Common::EventType _mouseClickType;
bool _mouseClicked;
+ bool _keyPressed;
int _mouseX;
int _mouseY;
int _mouseField;
diff --git a/engines/supernova/supernova.cpp b/engines/supernova/supernova.cpp
index d11f85670b..ff2211c1e5 100644
--- a/engines/supernova/supernova.cpp
+++ b/engines/supernova/supernova.cpp
@@ -175,6 +175,7 @@ void SupernovaEngine::updateEvents() {
_gm->_currentRoom->animation();
_gm->_mouseClicked = false;
+ _gm->_keyPressed = false;
while (g_system->getEventManager()->pollEvent(_event)) {
switch (_event.type) {
case Common::EVENT_QUIT:
@@ -183,6 +184,7 @@ void SupernovaEngine::updateEvents() {
break;
case Common::EVENT_KEYDOWN:
+ _gm->_keyPressed = true;
if (_event.kbd.keycode == Common::KEYCODE_d &&
(_event.kbd.flags & Common::KBD_CTRL)) {
_console->attach();