[Scummvm-cvs-logs] SF.net SVN: scummvm: [20595] scummvm/trunk/engines/scumm/actor.cpp

kirben at users.sourceforge.net kirben at users.sourceforge.net
Sat Feb 11 23:04:13 CET 2006


Revision: 20595
Author:   kirben
Date:     2006-02-11 23:03:04 -0800 (Sat, 11 Feb 2006)
ViewCVS:  http://svn.sourceforge.net/scummvm?rev=20595&view=rev

Log Message:
-----------
Actually that should be before all code

Modified Paths:
--------------
    scummvm/trunk/engines/scumm/actor.cpp
Modified: scummvm/trunk/engines/scumm/actor.cpp
===================================================================
--- scummvm/trunk/engines/scumm/actor.cpp	2006-02-12 06:43:42 UTC (rev 20594)
+++ scummvm/trunk/engines/scumm/actor.cpp	2006-02-12 07:03:04 UTC (rev 20595)
@@ -1575,6 +1575,11 @@
 void Actor::startWalkActor(int destX, int destY, int dir) {
 	AdjustBoxResult abr;
 
+	if (!isInCurrentRoom() && _vm->_version >= 7) {
+		debug(0, "startWalkActor: attempting to walk actor %d who is not in this room", _number);
+		return;
+	}
+
 	if (_vm->_version <= 3) {
 		abr.x = destX;
 		abr.y = destY;
@@ -1582,15 +1587,11 @@
 		abr = adjustXYToBeInBox(destX, destY);
 	}
 
-	if (!isInCurrentRoom()) {
-		if (_vm->_version <= 6) {
-			_pos.x = abr.x;
-			_pos.y = abr.y;
-			if (_ignoreTurns == false && dir != -1)
-				_facing = dir;
-		} else {
-			debug(0, "startWalkActor: attempting to walk actor %d who is not in this room", _number);
-		}
+	if (!isInCurrentRoom() && _vm->_version <= 6) {
+		_pos.x = abr.x;
+		_pos.y = abr.y;
+		if (_ignoreTurns == false && dir != -1)
+			_facing = dir;
 		return;
 	}
 







More information about the Scummvm-git-logs mailing list