From e4ece2a62ca0854dc2fa1fefea25fb1f75a4aa58 Mon Sep 17 00:00:00 2001 From: Matthew Duggan Date: Sat, 11 Sep 2021 13:58:13 +0900 Subject: [PATCH] ULTIMA8: Allow turning while retreating in Crusader The original game allows you to turn while retreating, but that was not previously possible. To make the turn always possible, step() now does not wait for the movement animation. This should work as AvatarMoverProcess::run terminates early if the Avatar is busy. --- .../ultima/ultima8/world/actors/cru_avatar_mover_process.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/engines/ultima/ultima8/world/actors/cru_avatar_mover_process.cpp b/engines/ultima/ultima8/world/actors/cru_avatar_mover_process.cpp index 4359c9064fc..2a3eec1905b 100644 --- a/engines/ultima/ultima8/world/actors/cru_avatar_mover_process.cpp +++ b/engines/ultima/ultima8/world/actors/cru_avatar_mover_process.cpp @@ -67,7 +67,7 @@ void CruAvatarMoverProcess::run() { if (_avatarAngle < 0) { _avatarAngle = Direction_ToCentidegrees(avatar->getDir()); } - if (!hasMovementFlags(MOVE_FORWARD | MOVE_BACK | MOVE_JUMP | MOVE_STEP)) { + if (!hasMovementFlags(MOVE_FORWARD | MOVE_JUMP | MOVE_STEP)) { // See comment on _avatarAngle in header about these constants if (hasMovementFlags(MOVE_TURN_LEFT)) { if (hasMovementFlags(MOVE_RUN)) @@ -509,7 +509,7 @@ void CruAvatarMoverProcess::step(Animation::Sequence action, Direction direction return; //debug(6, "Cru avatar step: picked action %d dir %d (test result %d)", action, direction, res); - waitFor(avatar->doAnim(action, direction)); + avatar->doAnim(action, direction); } void CruAvatarMoverProcess::tryAttack() {