SCUMM: Limit Loom CD Choas/Chaos workaround to the appropriate script

This commit is contained in:
Torbjörn Andersson 2021-08-03 09:27:35 +02:00
parent 4fe69dbf2e
commit a5d7d9fdd2

View file

@ -2751,11 +2751,11 @@ void ScummEngine_v5::decodeParseString() {
case 15:{ // SO_TEXTSTRING
const int len = resStrLen(_scriptPointer);
if (_game.id == GID_LOOM && strcmp((const char *) _scriptPointer, "I am Choas.") == 0) {
if (_game.id == GID_LOOM && vm.slot[_currentScript].number == 95 && strcmp((const char *)_scriptPointer, "I am Choas.") == 0) {
// WORKAROUND: This happens when Chaos introduces
// herself to bishop Mandible. Of all the places to put
// a typo...
printString(textSlot, (const byte *) "I am Chaos.");
printString(textSlot, (const byte *)"I am Chaos.");
} else if (_game.id == GID_INDY4 && _roomResource == 23 && vm.slot[_currentScript].number == 167 &&
len == 24 && 0==memcmp(_scriptPointer+16, "pregod", 6)) {
// WORKAROUND for bug #2961.