TorchCraftAI
A bot for machine learning research on StarCraft: Brood War
|
Represents an area on the map. More...
#include <areainfo.h>
Public Attributes | |
int | id = -1 |
ID of BWEM area. This corresponds to the index in the areas vector (+1) More... | |
int | x = 0 |
Center in the area's bounding box in walk tiles. More... | |
int | y = 0 |
Center of the area's bounding box in walk tiles. More... | |
Position | topLeft |
Top left of the area's bounding box in walk tiles. More... | |
Position | bottomRight |
Bottom right of the area's bounding box in walk tiles. More... | |
int | size = 0 |
Area size in walk tiles; includes walkable tiles only. More... | |
std::vector< Position > | baseLocations |
Possible base locations. More... | |
std::vector< Unit * > | liveUnits |
All units in this area that are not dead. This includes gone units. More... | |
std::vector< Unit * > | visibleUnits |
All units in this area that are currently visible. More... | |
std::vector< Unit * > | minerals |
All Minerals in this area. More... | |
std::vector< Unit * > | geysers |
All Geysers/Extractors/Refineries/Assimilators in this area. More... | |
int | groupId = -1 |
All areas that are accessible from/to each other by ground share the same groupId. More... | |
BWEM::Area const * | area |
AreaInfo * | areaInfo = nullptr |
Pointer to container object. More... | |
std::vector< Area * > | neighbors |
Accessible neighbors. More... | |
FrameNum | lastExplored = 0 |
bool | isMyBase = false |
True if this area contains our base (our resource depot has been constructed in one of the base locations at some point). More... | |
bool | isEnemyBase = false |
True if this area contains enemy base (we've seen enemy's resource depot constructed at one of the base locations at some point). More... | |
bool | isPossibleEnemyStartLocation = false |
True if this area may contain enemy's start location. More... | |
bool | wasMyBase = false |
True if we ever had a base at one of the area's baseLocations. More... | |
bool | wasEnemyBase = false |
True if enemy ever had a base at one of the area's baseLocations. More... | |
bool | hasMyBuildings = false |
bool | hasEnemyBuildings = false |
double | myGndStrength = 0 |
Strength of all ground units in this area. More... | |
double | myAirStrength = 0 |
Strength of all air units in this area. More... | |
double | myDetStrength = 0 |
Strength of all detector units in this area. More... | |
double | enemyGndStrength = 0 |
double | enemyAirStrength = 0 |
double | enemyDetStrength = 0 |
Represents an area on the map.
Areas are regions determined by static map analysis using BWEM (Brood War Easy Map). Areas correspond to the respective BWEM::Area. This struct is used to aggregate all game state information (e.g. units, visibility) local to the respective area.
BWEM::Area const* cherrypi::Area::area |
AreaInfo* cherrypi::Area::areaInfo = nullptr |
Pointer to container object.
std::vector<Position> cherrypi::Area::baseLocations |
Possible base locations.
Position cherrypi::Area::bottomRight |
Bottom right of the area's bounding box in walk tiles.
double cherrypi::Area::enemyAirStrength = 0 |
double cherrypi::Area::enemyDetStrength = 0 |
double cherrypi::Area::enemyGndStrength = 0 |
std::vector<Unit*> cherrypi::Area::geysers |
All Geysers/Extractors/Refineries/Assimilators in this area.
int cherrypi::Area::groupId = -1 |
All areas that are accessible from/to each other by ground share the same groupId.
bool cherrypi::Area::hasEnemyBuildings = false |
bool cherrypi::Area::hasMyBuildings = false |
int cherrypi::Area::id = -1 |
ID of BWEM area. This corresponds to the index in the areas vector (+1)
bool cherrypi::Area::isEnemyBase = false |
True if this area contains enemy base (we've seen enemy's resource depot constructed at one of the base locations at some point).
This flag is cleared if the area no longer contains any enemy buildings, or if we guessed that this location should contain enemy base, but haven't seen the resource depot yet.
bool cherrypi::Area::isMyBase = false |
True if this area contains our base (our resource depot has been constructed in one of the base locations at some point).
This flag is cleared if the area no longer contains any our buildings
bool cherrypi::Area::isPossibleEnemyStartLocation = false |
True if this area may contain enemy's start location.
Used only in the beginning of the game to determine the enemy's start location. Once the enemy start location is found, this flag is true only for the corresponding area.
FrameNum cherrypi::Area::lastExplored = 0 |
std::vector<Unit*> cherrypi::Area::liveUnits |
All units in this area that are not dead. This includes gone units.
std::vector<Unit*> cherrypi::Area::minerals |
All Minerals in this area.
double cherrypi::Area::myAirStrength = 0 |
Strength of all air units in this area.
double cherrypi::Area::myDetStrength = 0 |
Strength of all detector units in this area.
double cherrypi::Area::myGndStrength = 0 |
Strength of all ground units in this area.
std::vector<Area*> cherrypi::Area::neighbors |
Accessible neighbors.
int cherrypi::Area::size = 0 |
Area size in walk tiles; includes walkable tiles only.
Position cherrypi::Area::topLeft |
Top left of the area's bounding box in walk tiles.
std::vector<Unit*> cherrypi::Area::visibleUnits |
All units in this area that are currently visible.
bool cherrypi::Area::wasEnemyBase = false |
True if enemy ever had a base at one of the area's baseLocations.
bool cherrypi::Area::wasMyBase = false |
True if we ever had a base at one of the area's baseLocations.
int cherrypi::Area::x = 0 |
Center in the area's bounding box in walk tiles.
int cherrypi::Area::y = 0 |
Center of the area's bounding box in walk tiles.