public abstract class Neutral extends Object
Modifier and Type | Field and Description |
---|---|
protected TilePosition |
topLeft |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object object) |
List<Area> |
getBlockedAreas()
If blocking() == true, returns the set of areas blocked by this Neutral.
|
TilePosition |
getBottomRight()
Returns the bottom right Tile position of this Neutral
|
Position |
getCenter()
Returns the center of this Neutral, in pixels (same as unit()->getInitialPosition()).
|
Neutral |
getLastStacked()
Returns the last Neutral stacked over this Neutral, if ever.
|
Neutral |
getNextStacked()
Returns the next Neutral stacked over this Neutral, if ever.
- To iterate through the whole stack, one can use the following: for (const Neutral * n = BWMap::GetTile(topLeft()).GetNeutral() ; n ; n = n->nextStacked())
|
TilePosition |
getSize()
Returns the size of this Neutral, in Tiles (same as Type()->tileSize())
|
TilePosition |
getTopLeft()
Returns the top left Tile position of this Neutral (same as unit()->getInitialTilePosition()).
|
Unit |
getUnit()
Returns the BWAPI::Unit this Neutral is wrapping around.
|
int |
hashCode() |
boolean |
isBlocking()
Tells whether this Neutral is blocking some ChokePoint.
- This applies to minerals and StaticBuildings only. - For each blocking Neutral, a pseudo ChokePoint (which is blocked()) is created on top of it, with the exception of stacked blocking Neutrals for which only one pseudo ChokePoint is created. - Cf. |
protected TilePosition topLeft
public Unit getUnit()
public Position getCenter()
public TilePosition getTopLeft()
public TilePosition getBottomRight()
public TilePosition getSize()
public boolean isBlocking()
public List<Area> getBlockedAreas()
public Neutral getNextStacked()
for (const Neutral * n = BWMap::GetTile(topLeft()).GetNeutral() ; n ; n = n->nextStacked())
public Neutral getLastStacked()
Copyright © 2022. All rights reserved.