aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/engine
diff options
context:
space:
mode:
authorMartin Kiewitz2010-07-17 13:32:11 +0000
committerMartin Kiewitz2010-07-17 13:32:11 +0000
commit8c31dd7e854ef19b28bc5f5ef8b1e5b5073927bd (patch)
treeca66002ca667b7b049c8a6d61a78fdd98a181832 /engines/sci/engine
parentcb4072f978b46a031b2ffb24e43eee7b76ef815f (diff)
downloadscummvm-rg350-8c31dd7e854ef19b28bc5f5ef8b1e5b5073927bd.tar.gz
scummvm-rg350-8c31dd7e854ef19b28bc5f5ef8b1e5b5073927bd.tar.bz2
scummvm-rg350-8c31dd7e854ef19b28bc5f5ef8b1e5b5073927bd.zip
SCI: added gameid for send() sq4 workaround
svn-id: r50961
Diffstat (limited to 'engines/sci/engine')
-rw-r--r--engines/sci/engine/vm.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/engines/sci/engine/vm.cpp b/engines/sci/engine/vm.cpp
index dd982c2c62..c7909672e5 100644
--- a/engines/sci/engine/vm.cpp
+++ b/engines/sci/engine/vm.cpp
@@ -646,14 +646,15 @@ ExecStack *send_selector(EngineState *s, reg_t send_obj, reg_t work_obj, StackPt
// result of a script bug
const char *objectName = s->_segMan->getObjectName(send_obj);
+ const SciGameId gameId = g_sci->getGameId();
- if (!strcmp(objectName, "Sq4GlobalNarrator") && selector == 606) {
+ if (gameId == GID_SQ4 && !strcmp(objectName, "Sq4GlobalNarrator") && selector == 606) {
// SQ4 has a script bug in the Sq4GlobalNarrator object when invoking the
// returnVal selector, which doesn't affect gameplay, thus don't diplay it
- } else if (!strcmp(objectName, "longSong") && selector == 3 && g_sci->getGameId() == GID_QFG1VGA) {
+ } else if (gameId == GID_QFG1VGA && !strcmp(objectName, "longSong") && selector == 3) {
// QFG1VGA has a script bug in the longSong object when invoking the
// loop selector, which doesn't affect gameplay, thus don't diplay it
- } else if (!strcmp(objectName, "PuzPiece") && selector == 77 && g_sci->getGameId() == GID_CASTLEBRAIN) {
+ } else if (gameId == GID_CASTLEBRAIN && !strcmp(objectName, "PuzPiece") && selector == 77) {
// Castle of Dr. Brain has a script bug in the PuzPiece object when invoking
// the value selector, which doesn't affect gameplay, thus don't display it
} else {