[Scummvm-git-logs] scummvm master -> ef0d76a2c7c3a061f4322fa29b879b4bdef606ad

athrxx athrxx at scummvm.org
Mon Jun 7 21:52:19 UTC 2021


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
ef0d76a2c7 SCUMM: (INDY3) - properly fix bug no. 1052


Commit: ef0d76a2c7c3a061f4322fa29b879b4bdef606ad
    https://github.com/scummvm/scummvm/commit/ef0d76a2c7c3a061f4322fa29b879b4bdef606ad
Author: athrxx (athrxx at scummvm.org)
Date: 2021-06-07T23:51:32+02:00

Commit Message:
SCUMM: (INDY3) - properly fix bug no. 1052

(minor SCUMM 3 walk code fix)

This fixes it according to disasm, without relying on a hack.

Changed paths:
    engines/scumm/actor.cpp


diff --git a/engines/scumm/actor.cpp b/engines/scumm/actor.cpp
index 4d93ec28db..ddf055f02b 100644
--- a/engines/scumm/actor.cpp
+++ b/engines/scumm/actor.cpp
@@ -485,6 +485,11 @@ int Actor::calcMovementFactor(const Common::Point& next) {
 	diffY = next.y - _pos.y;
 	deltaYFactor = _speedy << 16;
 
+	// These two lines fix bug #1052 (INDY3: Hitler facing wrong directions in the Berlin scene).
+	// I can't see anything like this in the original SCUMM1/2 code, so I limit this to SCUMM3.
+	if (_vm->_game.version == 3 && (int)_speedx > ABS(diffX) && (int)_speedy > ABS(diffY))
+		return 0;
+
 	if (diffY < 0)
 		deltaYFactor = -deltaYFactor;
 
@@ -1419,11 +1424,6 @@ void Actor::setDirection(int direction) {
 	int i;
 	uint16 vald;
 
-	// HACK to fix bug #774783
-	// If Hitler's direction is being set to anything other than 90, set it to 90
-	if ((_vm->_game.id == GID_INDY3) && _vm->_roomResource == 46 && _number == 9 && direction != 90)
-		direction = 90;
-
 	// Do nothing if actor is already facing in the given direction
 	if (_facing == direction)
 		return;




More information about the Scummvm-git-logs mailing list