diff options
author | Thanasis Antoniou | 2019-05-23 00:27:46 +0300 |
---|---|---|
committer | Thanasis Antoniou | 2019-05-23 00:30:03 +0300 |
commit | 17da1f23525f671bc51ff6991fb7c731c3b70c7a (patch) | |
tree | 001a1f5aeb83bd86a43dee1ea134c0422c53fe16 /engines/bladerunner | |
parent | 479a1d12ca09f5378a474e573f7b64de4486677f (diff) | |
download | scummvm-rg350-17da1f23525f671bc51ff6991fb7c731c3b70c7a.tar.gz scummvm-rg350-17da1f23525f671bc51ff6991fb7c731c3b70c7a.tar.bz2 scummvm-rg350-17da1f23525f671bc51ff6991fb7c731c3b70c7a.zip |
BLADERUNNER: Fix for McCoy resuming combat resting pose
In the original McCoy becomes "frozen" in a single targeting frame if shot at an enemy
Diffstat (limited to 'engines/bladerunner')
-rw-r--r-- | engines/bladerunner/mouse.cpp | 6 | ||||
-rw-r--r-- | engines/bladerunner/script/ai/mccoy.cpp | 8 |
2 files changed, 11 insertions, 3 deletions
diff --git a/engines/bladerunner/mouse.cpp b/engines/bladerunner/mouse.cpp index 6a6f94f978..fcaafe00bc 100644 --- a/engines/bladerunner/mouse.cpp +++ b/engines/bladerunner/mouse.cpp @@ -387,7 +387,7 @@ void Mouse::tick(int x, int y) { int actorId = Actor::findTargetUnderMouse(_vm, x, y); int itemId = _vm->_items->findTargetUnderMouse(x, y); - bool isObject = isTarget && sceneObjectId >= kSceneObjectOffsetObjects && sceneObjectId <= 293; + bool isObject = isTarget && sceneObjectId >= kSceneObjectOffsetObjects && sceneObjectId <= (95 + kSceneObjectOffsetObjects); if (!_vm->_playerActor->isMoving()) { if (actorId >= 0) { @@ -412,7 +412,7 @@ void Mouse::tick(int x, int y) { break; } - if (!_vm->_playerActor->isMoving() && animationMode != kAnimationModeCombatAim && animationMode != 22 && animationMode != 49) { + if (!_vm->_playerActor->isMoving() && animationMode != kAnimationModeCombatAim && animationMode != kAnimationModeCombatHit && animationMode != kAnimationModeCombatDie) { _vm->_playerActor->changeAnimationMode(kAnimationModeCombatAim, false); } } else { @@ -427,7 +427,7 @@ void Mouse::tick(int x, int y) { cursorId = 10; break; } - if (!_vm->_playerActor->isMoving() && animationMode != kAnimationModeCombatIdle && animationMode != 22 && animationMode != 49) { + if (!_vm->_playerActor->isMoving() && animationMode != kAnimationModeCombatIdle && animationMode != kAnimationModeCombatHit && animationMode != kAnimationModeCombatDie) { _vm->_playerActor->changeAnimationMode(kAnimationModeCombatIdle, false); } } diff --git a/engines/bladerunner/script/ai/mccoy.cpp b/engines/bladerunner/script/ai/mccoy.cpp index 1fd268451f..070c3f200b 100644 --- a/engines/bladerunner/script/ai/mccoy.cpp +++ b/engines/bladerunner/script/ai/mccoy.cpp @@ -767,6 +767,8 @@ bool AIScriptMcCoy::UpdateAnimation(int *animation, int *frame) { break; case 17: + // this is just frame 0 always, McCoy doesn't animated shoot in this animation State + // animation state 21 is for the full shooting animation *animation = kModelAnimationMcCoyWithGunShooting; _animationFrame = 0; // weird, but thats in game code @@ -809,6 +811,12 @@ bool AIScriptMcCoy::UpdateAnimation(int *animation, int *frame) { _animationState = 17; _animationFrame = 0; *animation = kModelAnimationMcCoyWithGunShooting; +#if BLADERUNNER_ORIGINAL_BUGS +#else + // Resume combat idle position even when shot at a target -- if it's no longer a target (dead or moved) + ChangeAnimationMode(kAnimationModeCombatIdle); +#endif // BLADERUNNER_ORIGINAL_BUGS + if (Actor_Query_Goal_Number(kActorMcCoy) == kGoalMcCoyNR11Shoot) { _animationFrame = 0; _animationState = 21; |