[Scummvm-cvs-logs] SF.net SVN: scummvm:[45307] scummvm/trunk/engines/sci/engine/kpathing.cpp

thebluegr at users.sourceforge.net thebluegr at users.sourceforge.net
Wed Oct 21 16:13:08 CEST 2009


Revision: 45307
          http://scummvm.svn.sourceforge.net/scummvm/?rev=45307&view=rev
Author:   thebluegr
Date:     2009-10-21 14:13:08 +0000 (Wed, 21 Oct 2009)

Log Message:
-----------
Fixed self-intersecting pathfinding polygons in SQ1, room 66. This addresses the issue where Roger is able to walk anywhere on screen. However, there is still a separate issue in that room, which makes him stay stuck in one direction (like he's "moonwalking") and it only occurs in the new GUI

Modified Paths:
--------------
    scummvm/trunk/engines/sci/engine/kpathing.cpp

Modified: scummvm/trunk/engines/sci/engine/kpathing.cpp
===================================================================
--- scummvm/trunk/engines/sci/engine/kpathing.cpp	2009-10-21 13:21:26 UTC (rev 45306)
+++ scummvm/trunk/engines/sci/engine/kpathing.cpp	2009-10-21 14:13:08 UTC (rev 45307)
@@ -1267,6 +1267,21 @@
 	}
 
 	for (i = skip; i < size; i++) {
+		if (size == 35 && (i == 20 || i == 21) && s->_gameName == "sq1sci" &&
+			s->currentRoomNumber() == 66) {
+			if (i == 20 && read_point(segMan, points, 20) == Common::Point(0, 104)) {
+				debug(1, "Applying fix for self-intersecting polygon in SQ1, room 66");
+				Vertex *vertex = new Vertex(Common::Point(1, 104));
+				poly->vertices.insertHead(vertex);
+				continue;
+			} else if (i == 21 && read_point(segMan, points, 21) == Common::Point(0, 110)) {
+				debug(1, "Applying fix for self-intersecting polygon in SQ1, room 66");
+				Vertex *vertex = new Vertex(Common::Point(1, 110));
+				poly->vertices.insertHead(vertex);
+				continue;
+			}
+		}
+
 		Vertex *vertex = new Vertex(read_point(segMan, points, i));
 		poly->vertices.insertHead(vertex);
 	}


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