Browse Source

SectorMap: remember all visitable objects in sector for wandering

Arseniy Shestakov 9 years ago
parent
commit
aabf4808da
2 changed files with 2 additions and 5 deletions
  1. 1 4
      AI/VCAI/VCAI.cpp
  2. 1 1
      AI/VCAI/VCAI.h

+ 1 - 4
AI/VCAI/VCAI.cpp

@@ -3045,10 +3045,7 @@ void SectorMap::exploreNewSector(crint3 pos, int num, CCallback * cbp)
 					if(t->visitable)
 					{
 						auto obj = t->visitableObjects.front();
-						if (vstd::contains(ai->knownSubterraneanGates, obj))
-						{
-							s.subterraneanGates.push_back (obj);
-						}
+						s.visitableObjs.push_back(obj);
 					}
 				}
 			}

+ 1 - 1
AI/VCAI/VCAI.h

@@ -79,7 +79,7 @@ struct SectorMap
 		int id;
 		std::vector<int3> tiles;
 		std::vector<int3> embarkmentPoints; //tiles of other sectors onto which we can (dis)embark
-		std::vector<const CGObjectInstance *> subterraneanGates;
+		std::vector<const CGObjectInstance *> visitableObjs;
 		bool water; //all tiles of sector are land or water
 		Sector()
 		{