diff options
author | Colin Snover | 2016-08-14 16:20:31 -0500 |
---|---|---|
committer | Colin Snover | 2016-08-19 13:57:40 -0500 |
commit | b1d53ca25d8b29dfc7fd42b3684e8548ef315da4 (patch) | |
tree | a25290dbb6d34002b8b429cb15217cc78fbcc960 | |
parent | fdb22904150caf50e6076904e65a29a833173bdd (diff) | |
download | scummvm-rg350-b1d53ca25d8b29dfc7fd42b3684e8548ef315da4.tar.gz scummvm-rg350-b1d53ca25d8b29dfc7fd42b3684e8548ef315da4.tar.bz2 scummvm-rg350-b1d53ca25d8b29dfc7fd42b3684e8548ef315da4.zip |
SCI32: Add kSetNowSeen variant for older SCI32 games
KQ7 2.00b, PQ:SWAT, Phant1, GK2, and Torin are all verified as
using the 'ignore' variant; SQ6 and QFG4CD are verified as using
the 'fail' variant. MGDX and Shivers could not be checked as they
have only Phar Lap Win16 executables, so took a guess based on
their release dates.
-rw-r--r-- | engines/sci/engine/kgraphics32.cpp | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/engines/sci/engine/kgraphics32.cpp b/engines/sci/engine/kgraphics32.cpp index c56aec8c88..182f2cb1f7 100644 --- a/engines/sci/engine/kgraphics32.cpp +++ b/engines/sci/engine/kgraphics32.cpp @@ -100,7 +100,26 @@ reg_t kBaseSetter32(EngineState *s, int argc, reg_t *argv) { } reg_t kSetNowSeen32(EngineState *s, int argc, reg_t *argv) { - return make_reg(0, g_sci->_gfxFrameout->kernelSetNowSeen(argv[0])); + const bool found = g_sci->_gfxFrameout->kernelSetNowSeen(argv[0]); + + // NOTE: MGDX is assumed to use the older kSetNowSeen since it was + // released before SQ6, but this has not been verified since it cannot be + // disassembled at the moment (Phar Lap Windows-only release) + if (getSciVersion() <= SCI_VERSION_2_1_EARLY || + g_sci->getGameId() == GID_SQ6 || + g_sci->getGameId() == GID_MOTHERGOOSEHIRES) { + + if (!found) { + error("kSetNowSeen: Unable to find screen item %04x:%04x", PRINT_REG(argv[0])); + } + return s->r_acc; + } + + if (!found) { + warning("kSetNowSeen: Unable to find screen item %04x:%04x", PRINT_REG(argv[0])); + } + + return make_reg(0, found); } reg_t kSetCursor32(EngineState *s, int argc, reg_t *argv) { |