aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorFilippos Karapetis2010-01-31 00:14:23 +0000
committerFilippos Karapetis2010-01-31 00:14:23 +0000
commit5b7d4305502dd02af32182541f60e82a3c3d1b26 (patch)
tree5a377cca21c3cdc520024967aa1b5c722dd8f5bf /engines
parenta7165c02c1bdd6a8b25fb573726240e8bcd021ec (diff)
downloadscummvm-rg350-5b7d4305502dd02af32182541f60e82a3c3d1b26.tar.gz
scummvm-rg350-5b7d4305502dd02af32182541f60e82a3c3d1b26.tar.bz2
scummvm-rg350-5b7d4305502dd02af32182541f60e82a3c3d1b26.zip
Fixed endless looping in Longbow, when the after market GM patches are used
svn-id: r47731
Diffstat (limited to 'engines')
-rw-r--r--engines/sci/engine/game.cpp2
-rw-r--r--engines/sci/sci.cpp3
2 files changed, 3 insertions, 2 deletions
diff --git a/engines/sci/engine/game.cpp b/engines/sci/engine/game.cpp
index a13e4a6691..b209dfc608 100644
--- a/engines/sci/engine/game.cpp
+++ b/engines/sci/engine/game.cpp
@@ -290,8 +290,6 @@ int game_init(EngineState *s) {
s->_gameObj = s->_segMan->lookupScriptExport(0, 0);
uint32 gameFlags = 0; // unused
s->_gameId = convertSierraGameId(s->_segMan->getObjectName(s->_gameObj), &gameFlags, s->resMan);
- // Add the after market GM patches for the specified game, if they exist
- s->resMan->addNewGMPatch(s->_gameId);
debug(2, " \"%s\" at %04x:%04x", s->_gameId.c_str(), PRINT_REG(s->_gameObj));
diff --git a/engines/sci/sci.cpp b/engines/sci/sci.cpp
index 980b04ed61..1383fb7bda 100644
--- a/engines/sci/sci.cpp
+++ b/engines/sci/sci.cpp
@@ -186,6 +186,9 @@ Common::Error SciEngine::run() {
return Common::kUnknownError;
}
+ // Add the after market GM patches for the specified game, if they exist
+ _resMan->addNewGMPatch(_gamestate->_gameId);
+
script_adjust_opcode_formats(_gamestate);
_kernel->loadKernelNames(getGameID(), _gamestate);