aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorlukaslw2014-08-07 02:20:52 +0200
committerlukaslw2014-08-07 02:20:52 +0200
commit4dbcdd19ec40b8b3d6ed416421eaff11a74181cf (patch)
tree39c0a69c5a87803ad4203500cef84e5bcc8fc148 /engines
parenta85a93f8886ef750e704302eabf1bfafc068206e (diff)
downloadscummvm-rg350-4dbcdd19ec40b8b3d6ed416421eaff11a74181cf.tar.gz
scummvm-rg350-4dbcdd19ec40b8b3d6ed416421eaff11a74181cf.tar.bz2
scummvm-rg350-4dbcdd19ec40b8b3d6ed416421eaff11a74181cf.zip
PRINCE: showNormAnims() fix
Diffstat (limited to 'engines')
-rw-r--r--engines/prince/prince.cpp5
-rw-r--r--engines/prince/script.cpp8
-rw-r--r--engines/prince/script.h2
3 files changed, 13 insertions, 2 deletions
diff --git a/engines/prince/prince.cpp b/engines/prince/prince.cpp
index 905862998e..9026e53c5b 100644
--- a/engines/prince/prince.cpp
+++ b/engines/prince/prince.cpp
@@ -1390,8 +1390,9 @@ void PrinceEngine::showNormAnims() {
} else {
anim._frame++;
}
- if (anim._frame < phaseCount - 1) {
- anim._showFrame = anim._frame;
+ anim._showFrame = anim._frame;
+ if (anim._showFrame >= phaseCount) {
+ anim._showFrame = phaseCount - 1;
}
showAnim(anim);
}
diff --git a/engines/prince/script.cpp b/engines/prince/script.cpp
index 061d86c848..dc8bb91674 100644
--- a/engines/prince/script.cpp
+++ b/engines/prince/script.cpp
@@ -643,6 +643,14 @@ void Interpreter::O_SHOWANIM() {
delete anim._shadowData;
anim._shadowData = nullptr;
}
+
+ // WALKAROUND: fix for turning off bard's wife background animation
+ // in front of bard's house (location 7) after giving her poem (item 33)
+ // in script: GiveLetter (line 11082)
+ if (_currentInstruction == kGiveLetterScriptFix) {
+ _vm->_backAnimList[1].backAnims[0]._state = 1;
+ }
+
debugInterpreter("O_SHOWANIM slot %d, animId %d", slot, animId);
}
diff --git a/engines/prince/script.h b/engines/prince/script.h
index 9c397b0d1f..196a19512d 100644
--- a/engines/prince/script.h
+++ b/engines/prince/script.h
@@ -252,6 +252,8 @@ private:
typedef void (Interpreter::*OpcodeFunc)();
static OpcodeFunc _opcodes[];
+ static const int kGiveLetterScriptFix = 79002;
+
// Keep opcode handlers names as they are in original code
// it easier to switch back and forth
void O_WAITFOREVER();