Hopefully right this time, last change caused a cheat (Free air travel)

svn-id: r11003
This commit is contained in:
Travis Howell 2003-10-29 10:24:03 +00:00
parent 774b847a87
commit 2a11383523
2 changed files with 7 additions and 13 deletions

View file

@ -143,6 +143,13 @@ int ScummEngine::getState(int obj) {
if (_gameId == GID_MANIAC && (obj == 182 || obj == 193)) if (_gameId == GID_MANIAC && (obj == 182 || obj == 193))
_objectStateTable[obj] |= 0x08; _objectStateTable[obj] |= 0x08;
// The Enchanced version of Zak McKracken included in the
// SelectWare Classic Collection bundle has no copy protection
// and doesn't include the codes.
if (_gameId == GID_ZAK && obj == 213)
_objectStateTable[obj] |= 0x08;
#endif #endif
return _objectStateTable[obj]; return _objectStateTable[obj];

View file

@ -428,25 +428,12 @@ void ScummEngine_v2::decodeParseString() {
actorTalk(); actorTalk();
} }
#ifndef BYPASS_COPY_PROT
#define BYPASS_COPY_PROT
#endif
int ScummEngine_v2::readVar(uint var) { int ScummEngine_v2::readVar(uint var) {
if (var >= 14 && var <= 16) if (var >= 14 && var <= 16)
var = _scummVars[var]; var = _scummVars[var];
checkRange(_numVariables - 1, 0, var, "Variable %d out of range(r)"); checkRange(_numVariables - 1, 0, var, "Variable %d out of range(r)");
debug(6, "readvar(%d) = %d", var, _scummVars[var]); debug(6, "readvar(%d) = %d", var, _scummVars[var]);
#if defined(BYPASS_COPY_PROT)
// The Enchanced version of Zak McKracken included in the
// SelectWare Classic Collection bundle has no copy protection
// and doesn't include the codes.
if (_gameId == GID_ZAK && var == 244)
return 0;
#endif
return _scummVars[var]; return _scummVars[var];
} }