diff options
author | Max Horn | 2003-05-13 17:55:24 +0000 |
---|---|---|
committer | Max Horn | 2003-05-13 17:55:24 +0000 |
commit | fea9aed00ae4b542cac7a78d097c70e3613f9c7a (patch) | |
tree | 143c54ec4179dc114bbb87df4b19cd1e4920721a /scumm/scummvm.cpp | |
parent | 2838aae2f4e9f94ef5a81770ba5cb7297e8cb3e9 (diff) | |
download | scummvm-rg350-fea9aed00ae4b542cac7a78d097c70e3613f9c7a.tar.gz scummvm-rg350-fea9aed00ae4b542cac7a78d097c70e3613f9c7a.tar.bz2 scummvm-rg350-fea9aed00ae4b542cac7a78d097c70e3613f9c7a.zip |
fixed more illegal var access in COMI
svn-id: r7486
Diffstat (limited to 'scumm/scummvm.cpp')
-rw-r--r-- | scumm/scummvm.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/scumm/scummvm.cpp b/scumm/scummvm.cpp index 892b9bdd56..89fb54ef3d 100644 --- a/scumm/scummvm.cpp +++ b/scumm/scummvm.cpp @@ -809,7 +809,7 @@ void Scumm::initScummVars() { VAR(VAR_SOUNDPARAM) = 0; VAR(VAR_SOUNDPARAM2) = 0; VAR(VAR_SOUNDPARAM3) = 0; - if (_features & GF_AFTER_V6) + if (_features & GF_AFTER_V6 && VAR_V6_EMSSPACE != 0xFF) VAR(VAR_V6_EMSSPACE) = 10000; VAR(VAR_59) = 3; @@ -1103,7 +1103,7 @@ void Scumm::startScene(int room, Actor * a, int objectNr) { } } - if (!(_features & GF_SMALL_HEADER)) // Disable for SH games. Overwrites + if (!(_features & GF_SMALL_HEADER) && VAR_NEW_ROOM != 0xFF) // Disable for SH games. Overwrites VAR(VAR_NEW_ROOM) = room; // gamevars, eg Zak cashcards runExitScript(); @@ -1138,7 +1138,8 @@ void Scumm::startScene(int room, Actor * a, int objectNr) { else _roomResource = room; - VAR(VAR_ROOM_RESOURCE) = _roomResource; + if (VAR_ROOM_RESOURCE != 0xFF) + VAR(VAR_ROOM_RESOURCE) = _roomResource; if (room != 0) ensureResourceLoaded(rtRoom, room); @@ -1165,7 +1166,7 @@ void Scumm::startScene(int room, Actor * a, int objectNr) { camera._cur.y = camera._dest.y = _screenHeight / 2; } - if (_features & GF_AFTER_V6) { + if (_features & GF_AFTER_V6 && VAR_V6_SCREEN_WIDTH != 0xFF) { VAR(VAR_V6_SCREEN_WIDTH) = _roomWidth; VAR(VAR_V6_SCREEN_HEIGHT) = _roomHeight; } |