[Scummvm-cvs-logs] SF.net SVN: scummvm: [32190] scummvm/trunk/engines/kyra/scene_v2.cpp
lordhoto at users.sourceforge.net
lordhoto at users.sourceforge.net
Tue May 20 01:04:52 CEST 2008
Revision: 32190
http://scummvm.svn.sourceforge.net/scummvm/?rev=32190&view=rev
Author: lordhoto
Date: 2008-05-19 16:04:52 -0700 (Mon, 19 May 2008)
Log Message:
-----------
Fixed bug in KyraEngine_v2::directLinePassable. This should fix some pathfinder issues in HoF and MR.
Modified Paths:
--------------
scummvm/trunk/engines/kyra/scene_v2.cpp
Modified: scummvm/trunk/engines/kyra/scene_v2.cpp
===================================================================
--- scummvm/trunk/engines/kyra/scene_v2.cpp 2008-05-19 21:47:42 UTC (rev 32189)
+++ scummvm/trunk/engines/kyra/scene_v2.cpp 2008-05-19 23:04:52 UTC (rev 32190)
@@ -98,7 +98,7 @@
temp = pathfinderInitPositionIndexTable(temp, x, y);
pathfinderFinializePath(moveTable, temp, x, y, moveTableSize);
usePostProcess = false;
- }
+ }
return usePostProcess ? size : getMoveTableSize(moveTable);
}
@@ -106,13 +106,14 @@
debugC(9, kDebugLevelMain, "KyraEngine_v2::directLinePassable(%d, %d, %d, %d)", x, y, toX, toY);
Screen *scr = screen();
- while (x != toX && y != toY) {
+ while (x != toX || y != toY) {
int facing = getFacingFromPointToPoint(x, y, toX, toY);
x += _addXPosTable[facing];
y += _addYPosTable[facing];
if (!scr->getShapeFlag1(x, y))
return false;
}
+
return true;
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list