Reapply the Zak cashcard var exclusions... two of them somehow vanished

out of the code during rewrites.

svn-id: r4542
This commit is contained in:
James Brown 2002-07-14 03:01:36 +00:00
parent c3c11b79cb
commit c2877866ff
2 changed files with 13 additions and 8 deletions

View File

@ -276,13 +276,16 @@ int Scumm::scummLoop(int delta)
if (_saveLoadFlag) {
if (_saveLoadFlag == 1) {
saveState(_saveLoadSlot, _saveLoadCompatible);
if (_saveLoadCompatible)
// Ender: Disabled for small_header games, as
// can overwrite game variables (eg, Zak256 cashcards)
if (_saveLoadCompatible && !(features & GF_SMALL_HEADER)
_vars[VAR_GAME_LOADED] = 201;
} else {
loadState(_saveLoadSlot, _saveLoadCompatible);
if (_saveLoadCompatible) {
// Ender: Disabled for small_header games, as
// can overwrite game variables (eg, Zak256 cashcards)
if (_saveLoadCompatible && !(features & GF_SMALL_HEADER))
_vars[VAR_GAME_LOADED] = 203;
}
}
_saveLoadFlag = 0;
}
@ -404,7 +407,9 @@ void Scumm::startScene(int room, Actor * a, int objectNr)
}
}
_vars[VAR_NEW_ROOM] = room;
if (!(features & GF_SMALL_HEADER)) // Disable for SH games. Overwrites
_vars[VAR_NEW_ROOM] = room; // gamevars, eg Zak cashcards
runExitScript();
killScriptsAndResources();
clearEnqueue();

View File

@ -88,10 +88,10 @@ void Scumm::setupScummVarsOld()
VAR_SOUNDPARAM3 = 66;
VAR_MOUSEPRESENT = 67;
VAR_PERFORMANCE_1 = 68;
VAR_PERFORMANCE_2 = 69;
VAR_ROOM_FLAG = 70;
VAR_GAME_LOADED = 71;
VAR_NEW_ROOM = 72;
VAR_PERFORMANCE_2 = 69; // Zak256 Note: Cashcard for Zak
VAR_ROOM_FLAG = 70; // Zak256 Note: Cashcard for Annie
VAR_GAME_LOADED = 71; // Zak256 Note: Cashcard for Melissa
VAR_NEW_ROOM = 72; // Zak256 Note: Cashcard for Leslie
VAR_VERSION = 75;
VAR_V5_DRAWFLAGS = 9;