aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorAdrian Frühwirth2018-02-25 18:33:13 +0100
committerAdrian Frühwirth2018-02-25 20:15:25 +0100
commit842c67fc34fdc1ff932c8cf70c768e6ad8157038 (patch)
tree61efcf1b8056e056ccdbad10593414c235541d72 /engines
parentc55ee3f967be191c4b7ca481b266ee55f7b437b8 (diff)
downloadscummvm-rg350-842c67fc34fdc1ff932c8cf70c768e6ad8157038.tar.gz
scummvm-rg350-842c67fc34fdc1ff932c8cf70c768e6ad8157038.tar.bz2
scummvm-rg350-842c67fc34fdc1ff932c8cf70c768e6ad8157038.zip
TUCKER: Allow skipping speech
Escape, period or right mouse click skips one sentence at a time.
Diffstat (limited to 'engines')
-rw-r--r--engines/tucker/tucker.cpp11
-rw-r--r--engines/tucker/tucker.h3
2 files changed, 13 insertions, 1 deletions
diff --git a/engines/tucker/tucker.cpp b/engines/tucker/tucker.cpp
index d4640a8927..8e11e2279b 100644
--- a/engines/tucker/tucker.cpp
+++ b/engines/tucker/tucker.cpp
@@ -653,6 +653,10 @@ void TuckerEngine::parseEvents() {
break;
case Common::KEYCODE_ESCAPE:
_inputKeys[kInputKeyEscape] = true;
+ _inputKeys[kInputKeySkipSpeech] = true;
+ break;
+ case Common::KEYCODE_PERIOD:
+ _inputKeys[kInputKeySkipSpeech] = true;
break;
case Common::KEYCODE_d:
if (ev.kbd.hasFlags(Common::KBD_CTRL)) {
@@ -678,6 +682,7 @@ void TuckerEngine::parseEvents() {
case Common::EVENT_RBUTTONDOWN:
updateCursorPos(ev.mouse.x, ev.mouse.y);
_mouseButtonsMask |= 2;
+ _inputKeys[kInputKeySkipSpeech] = true;
break;
case Common::EVENT_RBUTTONUP:
updateCursorPos(ev.mouse.x, ev.mouse.y);
@@ -692,6 +697,12 @@ void TuckerEngine::parseEvents() {
break;
}
}
+ if (_inputKeys[kInputKeySkipSpeech]) {
+ if (isSpeechSoundPlaying()) {
+ stopSpeechSound();
+ }
+ _inputKeys[kInputKeySkipSpeech] = false;
+ }
_quitGame = shouldQuit();
}
diff --git a/engines/tucker/tucker.h b/engines/tucker/tucker.h
index fd508c1abe..d458d80835 100644
--- a/engines/tucker/tucker.h
+++ b/engines/tucker/tucker.h
@@ -212,7 +212,8 @@ enum InputKey {
kInputKeyToggleInventory,
kInputKeyToggleTextSpeech,
kInputKeyHelp,
- kInputKeyCount
+ kInputKeyCount,
+ kInputKeySkipSpeech
};
enum GameFlag {