aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--scumm/script.cpp10
-rw-r--r--scumm/scummvm.cpp5
-rw-r--r--scumm/smush/smush_player.cpp1
3 files changed, 14 insertions, 2 deletions
diff --git a/scumm/script.cpp b/scumm/script.cpp
index 6cf7673d3e..0058b24274 100644
--- a/scumm/script.cpp
+++ b/scumm/script.cpp
@@ -1130,6 +1130,16 @@ void ScummEngine::abortCutscene() {
VAR(VAR_OVERRIDE) = 1;
vm.cutScenePtr[vm.cutSceneStackPointer] = 0;
+
+ // HACK to fix issues with SMUSH and the way it does keyboard handling.
+ // In particular, normally abortCutscene() is being called while no
+ // scripts are active. But SMUSH runs from *inside* the script engine.
+ // And it calls abortCutscene() if ESC is pressed... not good.
+ // Proper fix might be to let SMUSH/INSANE run from outside the script
+ // engine but that would require lots of changes and may actually have
+ // negative effects, too. So we cheat here, to fix bug #751670.
+ getScriptEntryPoint();
+
}
}
diff --git a/scumm/scummvm.cpp b/scumm/scummvm.cpp
index 3aef8c2a92..7e2666e5cb 100644
--- a/scumm/scummvm.cpp
+++ b/scumm/scummvm.cpp
@@ -1824,6 +1824,8 @@ void ScummEngine::processKbd() {
if (_lastKeyHit == KEY_ALL_SKIP) {
// Skip cutscene
if (_insaneState) {
+ // Eek this is literally shouting for trouble...
+ // Probably should set _lastKey to VAR_CUTSCENEEXIT_KEY instead!
_videoFinished = true;
return;
}
@@ -1873,7 +1875,8 @@ void ScummEngine::processKbd() {
#else
_videoFinished = true;
#endif
- } else
+ }
+ if (!_insaneState || _videoFinished)
abortCutscene();
if (_version <= 2) {
// Ensure that the input script also sees the key press.
diff --git a/scumm/smush/smush_player.cpp b/scumm/smush/smush_player.cpp
index 9c22bba519..e65cbba8e4 100644
--- a/scumm/smush/smush_player.cpp
+++ b/scumm/smush/smush_player.cpp
@@ -306,7 +306,6 @@ void SmushPlayer::deinit() {
_scumm->_mixer->stopChannel(_IACTchannel);
_scumm->_insaneState = false;
- _scumm->abortCutscene();
if (_scumm->_imuseDigital) {
_scumm->_imuseDigital->pause(false);
}