(svn r13500) [NoAI] -Fix r13497: minor glitch in slope-check (Yexo) noai
authortruebrain
Thu, 12 Jun 2008 21:54:34 +0000
branchnoai
changeset 10946 7ccfbff5698d
parent 10944 588393239ac6
child 10952 d16212cc2394
(svn r13500) [NoAI] -Fix r13497: minor glitch in slope-check (Yexo)
bin/ai/library/pathfinder/road/main.nut
bin/ai/regression/regression.txt
--- a/bin/ai/library/pathfinder/road/main.nut	Thu Jun 12 21:18:09 2008 +0000
+++ b/bin/ai/library/pathfinder/road/main.nut	Thu Jun 12 21:54:34 2008 +0000
@@ -277,10 +277,14 @@
 
 	if (slope == AITile.SLOPE_NS || slope == AITile.SLOPE_EW) return true;
 
-	if (NW && SW && (slope == AITile.SLOPE_E || slope == AITile.SLOPE_NE || slope == AITile.SLOPE_SE)) return false;
-	if (NE && SE && (slope == AITile.SLOPE_W || slope == AITile.SLOPE_NW || slope == AITile.SLOPE_SW)) return false;
-	if (NW && NE && (slope == AITile.SLOPE_S || slope == AITile.SLOPE_SE || slope == AITile.SLOPE_SW)) return false;
-	if (SW && SE && (slope == AITile.SLOPE_N || slope == AITile.SLOPE_NE || slope == AITile.SLOPE_NW)) return false;
+	if (NW && SW && (slope == AITile.SLOPE_E || slope == AITile.SLOPE_NE || slope == AITile.SLOPE_SE ||
+		slope == AITile.SLOPE_S || slope == AITile.SLOPE_N)) return false;
+	if (NE && SE && (slope == AITile.SLOPE_W || slope == AITile.SLOPE_NW || slope == AITile.SLOPE_SW ||
+		slope == AITile.SLOPE_S || slope == AITile.SLOPE_N)) return false;
+	if (NW && NE && (slope == AITile.SLOPE_S || slope == AITile.SLOPE_SE || slope == AITile.SLOPE_SW ||
+		slope == AITile.SLOPE_E || slope == AITile.SLOPE_W)) return false;
+	if (SW && SE && (slope == AITile.SLOPE_N || slope == AITile.SLOPE_NE || slope == AITile.SLOPE_NW ||
+		slope == AITile.SLOPE_E || slope == AITile.SLOPE_W)) return false;
 
 	return true;
 }
--- a/bin/ai/regression/regression.txt	Thu Jun 12 21:18:09 2008 +0000
+++ b/bin/ai/regression/regression.txt	Thu Jun 12 21:54:34 2008 +0000
@@ -5741,12 +5741,12 @@
     Tile 44443
     Tile 44187
     Tile 43931
-    Tile 43675
-    Tile 43674
-    Tile 43673
-    Tile 43672
-    Tile 43671
-    Tile 43670
+    Tile 43930
+    Tile 43929
+    Tile 43928
+    Tile 43927
+    Tile 43926
+    Tile 43925
     Tile 43669
     Tile 43413
     Tile 43157
@@ -6622,7 +6622,7 @@
     GetPopulation(): 276
     GetLocation():   9595
     GetHouseCount(): 14
-    GetRating():     0
+    GetRating():     5
   Town 14
     IsValidTown():   true
     GetName():       Prundinghall