HOG2
|
A simple map-based unit. More...
#include <AbsMapUnit.h>
Public Member Functions | |
AbsMapUnit (int x, int y) | |
virtual | ~AbsMapUnit () |
virtual const char * | GetName ()=0 |
virtual bool | MakeMove (AbsMapEnvironment *, OccupancyInterface< xyLoc, tDirection > *, AbsMapSimulationInfo *, tDirection &)=0 |
virtual void | UpdateLocation (AbsMapEnvironment *, xyLoc &l, bool, AbsMapSimulationInfo *) |
virtual void | GetLocation (xyLoc &l) |
virtual void | GetGoal (xyLoc &s)=0 |
virtual void | OpenGLDraw (const AbsMapEnvironment *, const AbsMapSimulationInfo *) const |
Public Member Functions inherited from Unit< state, action, environment > | |
Unit () | |
virtual | ~Unit () |
virtual bool | MakeMove (environment *, OccupancyInterface< state, action > *, SimulationInfo< state, action, environment > *, action &a)=0 |
virtual void | UpdateLocation (environment *, state &, bool success, SimulationInfo< state, action, environment > *)=0 |
virtual void | GetLocation (state &)=0 |
virtual void | OpenGLDraw (const environment *, const SimulationInfo< state, action, environment > *) const =0 |
virtual void | GetGoal (state &s) |
virtual bool | Done () |
virtual double | GetSpeed () |
void | SetSpeed (double s) |
virtual void | LogStats (StatCollection *) |
log an stats that may have been computed during the last run More... | |
virtual void | LogFinalStats (StatCollection *) |
log any final one-time stats before a simulation is ended More... | |
virtual void | SetColor (GLfloat _r, GLfloat _g, GLfloat _b) |
virtual void | GetColor (GLfloat &_r, GLfloat &_g, GLfloat &_b) const |
UnitGroup< state, action, environment > * | GetUnitGroup () |
void | SetUnitGroup (UnitGroup< state, action, environment > *_group) |
virtual unsigned int | GetNum () |
virtual void | SetNum (unsigned int num) |
virtual void | StartNewTrial (StatCollection *) |
virtual int | GetPriority () |
virtual void | SetPriority (int val) |
Protected Attributes | |
GLfloat | r |
GLfloat | g |
GLfloat | b |
xyLoc | loc |
A simple map-based unit.
Definition at line 24 of file AbsMapUnit.h.
|
inline |
Definition at line 26 of file AbsMapUnit.h.
|
inlinevirtual |
Definition at line 28 of file AbsMapUnit.h.
|
pure virtual |
Implemented in SearchUnit.
|
inlinevirtual |
Definition at line 34 of file AbsMapUnit.h.
References loc.
Referenced by SearchUnit::GetGoal(), SearchUnit::makeMove(), and SearchUnit::OpenGLDraw().
|
pure virtual |
Implements Unit< state, action, environment >.
Implemented in SearchUnit, and praStarUnit.
|
pure virtual |
Implemented in SearchUnit.
|
virtual |
Reimplemented in SearchUnit.
Definition at line 12 of file AbsMapUnit.cpp.
References b, DrawSphere(), g, Map::GetMapHeight(), Map::GetMapWidth(), Map::GetOpenGLCoord(), r, loc::x, and loc::y.
|
inlinevirtual |
Reimplemented in SearchUnit.
Definition at line 32 of file AbsMapUnit.h.
|
protected |
Definition at line 42 of file AbsMapUnit.h.
Referenced by AbsMapUnit(), OpenGLDraw(), and SearchUnit::OpenGLDraw().
|
protected |
Definition at line 42 of file AbsMapUnit.h.
Referenced by AbsMapUnit(), OpenGLDraw(), and SearchUnit::OpenGLDraw().
|
protected |
Definition at line 43 of file AbsMapUnit.h.
Referenced by GetLocation().
|
protected |
Definition at line 42 of file AbsMapUnit.h.
Referenced by AbsMapUnit(), OpenGLDraw(), and SearchUnit::OpenGLDraw().