40 #define AAS_FILEID "DewmAAS"
41 #define AAS_FILEVERSION "1.07"
44 #define TFL_INVALID BIT(0) // not valid
45 #define TFL_WALK BIT(1) // walking
46 #define TFL_CROUCH BIT(2) // crouching
47 #define TFL_WALKOFFLEDGE BIT(3) // walking of a ledge
48 #define TFL_BARRIERJUMP BIT(4) // jumping onto a barrier
49 #define TFL_JUMP BIT(5) // jumping
50 #define TFL_LADDER BIT(6) // climbing a ladder
51 #define TFL_SWIM BIT(7) // swimming
52 #define TFL_WATERJUMP BIT(8) // jump out of the water
53 #define TFL_TELEPORT BIT(9) // teleportation
54 #define TFL_ELEVATOR BIT(10) // travel by elevator
55 #define TFL_FLY BIT(11) // fly
56 #define TFL_SPECIAL BIT(12) // special
57 #define TFL_WATER BIT(21) // travel through water
58 #define TFL_AIR BIT(22) // travel through air
61 #define FACE_SOLID BIT(0) // solid at the other side
62 #define FACE_LADDER BIT(1) // ladder surface
63 #define FACE_FLOOR BIT(2) // standing on floor when on this face
64 #define FACE_LIQUID BIT(3) // face seperating two areas with liquid
65 #define FACE_LIQUIDSURFACE BIT(4) // face seperating liquid and air
68 #define AREA_FLOOR BIT(0) // AI can stand on the floor in this area
69 #define AREA_GAP BIT(1) // area has a gap
70 #define AREA_LEDGE BIT(2) // if entered the AI bbox partly floats above a ledge
71 #define AREA_LADDER BIT(3) // area contains one or more ladder faces
72 #define AREA_LIQUID BIT(4) // area contains a liquid
73 #define AREA_CROUCH BIT(5) // AI cannot walk but can only crouch in this area
74 #define AREA_REACHABLE_WALK BIT(6) // area is reachable by walking or swimming
75 #define AREA_REACHABLE_FLY BIT(7) // area is reachable by flying
78 #define AREACONTENTS_SOLID BIT(0) // solid, not a valid area
79 #define AREACONTENTS_WATER BIT(1) // area contains water
80 #define AREACONTENTS_CLUSTERPORTAL BIT(2) // area is a cluster portal
81 #define AREACONTENTS_OBSTACLE BIT(3) // area contains (part of) a dynamic obstacle
82 #define AREACONTENTS_TELEPORTER BIT(4) // area contains (part of) a teleporter trigger
85 #define AREACONTENTS_BBOX_BIT 24
87 #define MAX_REACH_PER_AREA 256
88 #define MAX_AAS_TREE_DEPTH 128
90 #define MAX_AAS_BOUNDING_BOXES 4
331 virtual void PrintInfo(
void )
const = 0;
GLsizei const GLfloat * points
virtual bool Trace(aasTrace_t &trace, const idVec3 &start, const idVec3 &end) const =0
unsigned short maxAreaTravelTime
int GetNumFaceIndexes(void) const
int GetNumVertices(void) const
const idAASSettings & GetSettings(void) const
bool ParseInt(idLexer &src, int &i)
void CopyBase(idReachability &reach)
const aasEdge_t & GetEdge(int index) const
idReachability * rev_next
bool ValidForBounds(const idBounds &bounds) const
int GetNumEdges(void) const
const aasFace_t & GetFace(int index) const
struct aasArea_s aasArea_t
const aasPortal_t & GetPortal(int index)
bool ParseBBoxes(idLexer &src)
int GetNumNodes(void) const
bool ValidEntity(const char *classname) const
int GetNumPlanes(void) const
idList< aasNode_t > nodes
bool allowSwimReachabilities
virtual int BoundsReachableAreaNum(const idBounds &bounds, const int areaFlags, const int excludeTravelFlags) const =0
idList< aasCluster_t > clusters
const aasVertex_t & GetVertex(int index) const
const char * GetName(void) const
const aasCluster_t & GetCluster(int index) const
bool ParseBool(idLexer &src, bool &b)
int GetNumEdgeIndexes(void) const
bool FromDict(const char *name, const idDict *dict)
idBounds boundingBoxes[MAX_AAS_BOUNDING_BOXES]
const aasIndex_t & GetEdgeIndex(int index) const
struct aasPortal_s aasPortal_t
idList< aasIndex_t > faceIndex
bool ParseFloat(idLexer &src, float &f)
unsigned short * areaTravelTimes
int GetNumPortals(void) const
struct aasFace_s aasFace_t
void SetAreaTravelFlag(int index, int flag)
idList< aasIndex_t > edgeIndex
bool ParseVector(idLexer &src, idVec3 &vec)
unsigned short travelTime
struct aasEdge_s aasEdge_t
const aasNode_t & GetNode(int index) const
idList< aasFace_t > faces
idList< aasPortal_t > portals
bool FromFile(const idStr &fileName)
virtual idVec3 AreaCenter(int areaNum) const =0
const aasIndex_t & GetFaceIndex(int index) const
bool allowFlyReachabilities
int GetNumAreas(void) const
virtual void PrintInfo(void) const =0
virtual void PushPointIntoAreaNum(int areaNum, idVec3 &point) const =0
virtual idBounds EdgeBounds(int edgeNum) const =0
unsigned int GetCRC(void) const
void SetPortalMaxTravelTime(int index, int time)
int GetNumFaces(void) const
virtual int PointAreaNum(const idVec3 &origin) const =0
const aasIndex_t & GetPortalIndex(int index) const
bool FromParser(idLexer &src)
virtual idBounds AreaBounds(int areaNum) const =0
#define MAX_AAS_BOUNDING_BOXES
virtual idVec3 EdgeCenter(int edgeNum) const =0
virtual idBounds FaceBounds(int faceNum) const =0
struct aasTrace_s aasTrace_t
idList< aasEdge_t > edges
idList< aasVertex_t > vertices
idReachability * rev_reach
int GetNumPortalIndexes(void) const
void RemoveAreaTravelFlag(int index, int flag)
idList< aasArea_t > areas
virtual idVec3 FaceCenter(int faceNum) const =0
bool WriteToFile(idFile *fp) const
virtual int PointReachableAreaNum(const idVec3 &origin, const idBounds &searchBounds, const int areaFlags, const int excludeTravelFlags) const =0
idList< aasIndex_t > portalIndex
struct aasNode_s aasNode_t
const idPlane & GetPlane(int index) const
int GetNumClusters(void) const
const aasArea_t & GetArea(int index)
struct aasCluster_s aasCluster_t