simulation
Class AStarGoalBase
in AStarEngine.h
- Direct Known Subclasses:
- AStarGoalLowLevel
- class AStarGoalBase
An A* goal consists of a destination tile and a radius within which a
unit must get to the destination. The radius is necessary because for
actions on a target unit, like attacking or building, the destination
tile is obstructed by that unit and what we really want is not to get
to that tile but to get close enough to perform our action.
AStarGoalBase
public AStarGoalBase();
DistanceToGoal
public virtual float DistanceToGoal( const CVector2D& )= 0;
GetCoord
public virtual CVector2D GetCoord( const CVector2D& )= 0;
GetNeighbors
public virtual std::vector< CVector2D > GetNeighbors( const CVector2D&, HEntity entity )= 0;
GetRadius
public virtual float GetRadius()= 0;
GetTile
public virtual CVector2D GetTile( const CVector2D& )= 0;
GetTileCost
public virtual float GetTileCost( const CVector2D&, const CVector2D& )= 0;
IsAtGoal
public virtual bool IsAtGoal( const CVector2D& )= 0;
IsPassable
public virtual bool IsPassable( const CVector2D&, HEntity entity )= 0;
SetDestination
public virtual void SetDestination( const CVector2D& )= 0;
SetRadius
public virtual void SetRadius( float r )= 0;