(svn r13483) [NoAI] -Fix: oops... IsBuildable thought trees were not buildable, silly of course (tnx Yexo) noai
authortruebrain
Thu, 12 Jun 2008 10:14:05 +0000
branchnoai
changeset 10930 8e2c924c7077
parent 10921 f50864092014
child 10931 df70e29d4c23
(svn r13483) [NoAI] -Fix: oops... IsBuildable thought trees were not buildable, silly of course (tnx Yexo)
bin/ai/regression/regression.txt
src/ai/api/ai_tile.cpp
--- a/bin/ai/regression/regression.txt	Wed Jun 11 15:35:21 2008 +0000
+++ b/bin/ai/regression/regression.txt	Thu Jun 12 10:14:05 2008 +0000
@@ -6040,37 +6040,42 @@
     41383 => 0
   Buildable():         done
   KeepValue(1):        done
-  Count():             23
+  Count():             26
   BuildableRectangle(3, 3) ListDump:
+    42415 => 1
+    42414 => 1
+    42413 => 1
     42410 => 1
+    42159 => 1
+    42158 => 1
+    42157 => 1
+    42156 => 1
+    41903 => 1
+    41902 => 1
+    41901 => 1
+    41900 => 1
+    41899 => 1
     41647 => 1
     41646 => 1
+    41645 => 1
+    41644 => 1
+    41643 => 1
+    41641 => 1
     41391 => 1
     41390 => 1
     41389 => 1
     41388 => 1
     41387 => 1
-    42414 => 0
-    42413 => 0
-    42159 => 0
-    42158 => 0
-    42156 => 0
-    41903 => 0
-    41902 => 0
-    41901 => 0
-    41900 => 0
-    41899 => 0
+    42153 => 0
     41897 => 0
-    41645 => 0
-    41644 => 0
-    41643 => 0
-    41641 => 0
   DistanceManhattanToTile(30000) ListDump:
+    42415 => 175
     42414 => 174
     42159 => 174
     42413 => 173
     42158 => 173
     41903 => 173
+    42157 => 172
     41902 => 172
     41647 => 172
     42156 => 171
@@ -6084,12 +6089,14 @@
     41899 => 169
     41644 => 169
     41389 => 169
+    42153 => 168
     41643 => 168
     41388 => 168
     41897 => 167
     41387 => 167
     41641 => 166
   DistanceSquareToTile(30000) ListDump:
+    42415 => 18433
     42159 => 18338
     41903 => 18245
     42414 => 18180
@@ -6099,6 +6106,7 @@
     41902 => 17992
     42413 => 17929
     41646 => 17901
+    42157 => 17834
     41390 => 17812
     41901 => 17741
     41645 => 17650
@@ -6111,15 +6119,19 @@
     42410 => 17188
     41643 => 17154
     41387 => 17065
+    42153 => 16850
     41897 => 16757
     41641 => 16666
   GetOwner() ListDump:
+    42415 => -1
     42414 => -1
     42413 => -1
     42410 => -1
     42159 => -1
     42158 => -1
+    42157 => -1
     42156 => -1
+    42153 => -1
     41903 => -1
     41902 => -1
     41901 => -1
@@ -6139,10 +6151,11 @@
     41387 => -1
   CargoAcceptance():   done
   KeepAboveValue(10):  done
-  Count():             6
+  Count():             7
   ListDump:
     41897 => 41
     41641 => 35
+    42153 => 33
     41899 => 29
     41387 => 29
     41643 => 26
--- a/src/ai/api/ai_tile.cpp	Wed Jun 11 15:35:21 2008 +0000
+++ b/src/ai/api/ai_tile.cpp	Thu Jun 12 10:14:05 2008 +0000
@@ -22,6 +22,7 @@
 	switch (::GetTileType(tile)) {
 		default: return false;
 		case MP_CLEAR: return true;
+		case MP_TREES: return true;
 		case MP_ROAD:
 			/* Depots aren't considered buildable */
 			if (::GetRoadTileType(tile) == ROAD_TILE_DEPOT) return false;