From 50b163a106fba1dea763030727765f4f3fe311bb Mon Sep 17 00:00:00 2001 From: Martin Kiewitz Date: Sat, 24 Jul 2010 20:36:36 +0000 Subject: SCI: adding workaround for castle of dr. brain room 420, alien card game svn-id: r51257 --- engines/sci/engine/kernel_tables.h | 2 +- engines/sci/engine/workarounds.cpp | 6 ++++++ engines/sci/engine/workarounds.h | 1 + 3 files changed, 8 insertions(+), 1 deletion(-) (limited to 'engines') diff --git a/engines/sci/engine/kernel_tables.h b/engines/sci/engine/kernel_tables.h index 8a7de85cbe..ed507e5736 100644 --- a/engines/sci/engine/kernel_tables.h +++ b/engines/sci/engine/kernel_tables.h @@ -178,7 +178,7 @@ static const SciKernelMapSubEntry kGraph_subops[] = { { SIG_SCIALL, 4, MAP_CALL(GraphDrawLine), "iiiii(i)(i)", kGraphDrawLine_workarounds }, // 5 - nop // 6 - draw pattern - { SIG_SCIALL, 7, MAP_CALL(GraphSaveBox), "iiiii", NULL }, + { SIG_SCIALL, 7, MAP_CALL(GraphSaveBox), "iiiii", kGraphSaveBox_workarounds }, { SIG_SCIALL, 8, MAP_CALL(GraphRestoreBox), "[r0!]", kGraphRestoreBox_workarounds }, // ^ this may get called with invalid references, we check them within restoreBits() and sierra sci behaves the same { SIG_SCIALL, 9, MAP_CALL(GraphFillBoxBackground), "iiii", NULL }, diff --git a/engines/sci/engine/workarounds.cpp b/engines/sci/engine/workarounds.cpp index b107373702..8ce2b0e72c 100644 --- a/engines/sci/engine/workarounds.cpp +++ b/engines/sci/engine/workarounds.cpp @@ -133,6 +133,12 @@ const SciWorkaroundEntry kGraphDrawLine_workarounds[] = { SCI_WORKAROUNDENTRY_TERMINATOR }; +// gameID, room,script,lvl, object-name, method-name, call,index, workaround +const SciWorkaroundEntry kGraphSaveBox_workarounds[] = { + { GID_CASTLEBRAIN, 420, 427, 0, "alienIcon", "select", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when selecting a card during the alien card game, gets called with 1 extra parameter + SCI_WORKAROUNDENTRY_TERMINATOR +}; + // gameID, room,script,lvl, object-name, method-name, call,index, workaround const SciWorkaroundEntry kGraphRestoreBox_workarounds[] = { { GID_LSL6, -1, 85, 0, "rScroller", "hide", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // happens when restoring (sometimes), same as the one below diff --git a/engines/sci/engine/workarounds.h b/engines/sci/engine/workarounds.h index ab88505103..11d3824c83 100644 --- a/engines/sci/engine/workarounds.h +++ b/engines/sci/engine/workarounds.h @@ -76,6 +76,7 @@ extern const SciWorkaroundEntry kDisplay_workarounds[]; extern const SciWorkaroundEntry kDisposeScript_workarounds[]; extern const SciWorkaroundEntry kDoSoundFade_workarounds[]; extern const SciWorkaroundEntry kGraphDrawLine_workarounds[]; +extern const SciWorkaroundEntry kGraphSaveBox_workarounds[]; extern const SciWorkaroundEntry kGraphRestoreBox_workarounds[]; extern const SciWorkaroundEntry kGraphFillBoxForeground_workarounds[]; extern const SciWorkaroundEntry kGraphFillBoxAny_workarounds[]; -- cgit v1.2.3