aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorNicola Mettifogo2009-03-02 09:16:03 +0000
committerNicola Mettifogo2009-03-02 09:16:03 +0000
commit310036788af846adb818ab12b42aaf425ebde03d (patch)
treee82b91f551c21587e77ee5d35e8327d08e4f942f /engines
parent2d9705311e9acafd01f5f8fa1b617915c1cd6fb0 (diff)
downloadscummvm-rg350-310036788af846adb818ab12b42aaf425ebde03d.tar.gz
scummvm-rg350-310036788af846adb818ab12b42aaf425ebde03d.tar.bz2
scummvm-rg350-310036788af846adb818ab12b42aaf425ebde03d.zip
Enabled walking delay for follower animation.
svn-id: r39067
Diffstat (limited to 'engines')
-rw-r--r--engines/parallaction/walk.cpp16
1 files changed, 7 insertions, 9 deletions
diff --git a/engines/parallaction/walk.cpp b/engines/parallaction/walk.cpp
index 2a412fb8a2..fc8447f20e 100644
--- a/engines/parallaction/walk.cpp
+++ b/engines/parallaction/walk.cpp
@@ -422,6 +422,7 @@ void PathWalker_BR::setCharacterPath(AnimationPtr a, uint16 x, uint16 y) {
_character._a = a;
_character._first = true;
_character._fieldC = 1;
+ _character._walkDelay = 0;
buildPath(_character, x, y);
_character._active = true;
}
@@ -585,19 +586,16 @@ void PathWalker_BR::doWalk(State &s) {
debugC(3, kDebugWalk, "PathWalker_BR::doWalk(%s)", s._a->_name);
-#if 0
- // TODO: support delays in walking. This requires extending Input::walkIo().
- if (ch._walkDelay > 0) {
- ch._walkDelay--;
- if (ch._walkDelay == 0 && _ch._ani->_scriptName) {
+ if (s._walkDelay > 0) {
+ s._walkDelay--;
+ if (s._walkDelay == 0 && s._a->_scriptName) {
// stop script and reset
- _ch._ani->_flags &= ~kFlagsActing;
- Script *script = findScript(_ch._ani->_scriptName);
- script->_nextCommand = script->firstCommand;
+ s._a->_flags &= ~kFlagsActing;
+// _vm->_programExec->resetProgram(s._a->_scriptName);
}
return;
}
-#endif
+
if (s._fieldC == 0) {
s._walkPath.erase(s._walkPath.begin());