aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra/script_v2.cpp
diff options
context:
space:
mode:
authorJohannes Schickel2008-03-26 19:58:33 +0000
committerJohannes Schickel2008-03-26 19:58:33 +0000
commitc2df92a9b5079af28dc9debafdbd2ae528db7d71 (patch)
tree2b5644047f73d50075ada93c6da986700816f7ea /engines/kyra/script_v2.cpp
parentb0c6a12c81c949c7f61b6639b509dad2b4fbb862 (diff)
downloadscummvm-rg350-c2df92a9b5079af28dc9debafdbd2ae528db7d71.tar.gz
scummvm-rg350-c2df92a9b5079af28dc9debafdbd2ae528db7d71.tar.bz2
scummvm-rg350-c2df92a9b5079af28dc9debafdbd2ae528db7d71.zip
Added a simple hack which adds delay between animation frames of some scene animations, this prevents some animations from running too fast. See for example bug #1923638 "HoF: Marco missing animation frames".
svn-id: r31245
Diffstat (limited to 'engines/kyra/script_v2.cpp')
-rw-r--r--engines/kyra/script_v2.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/engines/kyra/script_v2.cpp b/engines/kyra/script_v2.cpp
index 0d086c491f..0655da0744 100644
--- a/engines/kyra/script_v2.cpp
+++ b/engines/kyra/script_v2.cpp
@@ -1087,6 +1087,19 @@ int KyraEngine_v2::o2_defineSceneAnim(ScriptState *script) {
int KyraEngine_v2::o2_updateSceneAnim(ScriptState *script) {
debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_updateSceneAnim(%p) (%d, %d)", (const void *)script, stackPos(0), stackPos(1));
updateSceneAnim(stackPos(0), stackPos(1));
+
+ // HACK: Some animations are really too fast because of missing delay times.
+ // Notice that the delay time is purely subjective set here, it could look
+ // slower or maybe faster in the original, but at least this looks OK for
+ // LordHoto.
+ //
+ // We know currently of two different animations where this happens.
+ // - One is where Marco is dangling from the flesh-eating plant (see bug #1923638 "HoF: Marco missing animation frames").
+ // - The other one is after giving the ticket to the captain. He would move very fast (barely noticeable) onto the ship
+ // without this delay.
+ if ((stackPos(0) == 2 && _mainCharacter.sceneId == 3) || (stackPos(0) == 3 && _mainCharacter.sceneId == 33))
+ _sceneSpecialScriptsTimer[_lastProcessedSceneScript] = _system->getMillis() + _tickLength * 2;
+
_specialSceneScriptRunFlag = false;
return 0;
}