BWAPI
Public Member Functions | Protected Member Functions | Protected Attributes
StructureAgent Class Reference

#include <StructureAgent.h>

Inheritance diagram for StructureAgent:
Inheritance graph
[legend]
Collaboration diagram for StructureAgent:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 StructureAgent ()
 StructureAgent (Unit *mUnit)
virtual void computeActions ()
bool canMorphInto (UnitType type)
void sendWorkers ()
string getTypeName ()
virtual void printInfo ()

Protected Member Functions

bool canBuildUnit (UnitType type)
bool canEvolveUnit (UnitType type)
TilePosition getNextScanLocation ()

Protected Attributes

bool repairing
vector< UpgradeTypeupgradeOrder
vector< TechTyperesearchOrder
vector< TilePositionhasScanned

Detailed Description

The StructureAgent is the base agent class for all agents handling buildings. If a building is created and no specific agent for that type is found, the building is assigned to a StructureAgent. StructureAgents are typically agents without logic, for example supply depots. To add logic to a building, for example Terran Academy researching stim packs, an agent implementation for that unit type must be created.

Author: Johan Hagelback (johan.hagelback@gmail.com)


Constructor & Destructor Documentation

Here is the call graph for this function:


Member Function Documentation

bool StructureAgent::canBuildUnit ( UnitType  type) [protected]

Here is the call graph for this function:

Here is the caller graph for this function:

bool StructureAgent::canEvolveUnit ( UnitType  type) [protected]

Here is the call graph for this function:

Checks if the agent can morph into the specified type. Zerg only.

Here is the call graph for this function:

Here is the caller graph for this function:

void StructureAgent::computeActions ( ) [virtual]

Called each update to issue orders.

Reimplemented from BaseAgent.

Reimplemented in BunkerAgent, HatcheryAgent, CommandCenterAgent, FleetBeaconAgent, NexusAgent, and RefineryAgent.

Here is the call graph for this function:

Here is the call graph for this function:

Here is the caller graph for this function:

string StructureAgent::getTypeName ( ) [virtual]

Returns the unique type name for structure agents.

Reimplemented from BaseAgent.

Reimplemented in BunkerAgent, HatcheryAgent, CommandCenterAgent, FleetBeaconAgent, NexusAgent, and RefineryAgent.

Here is the caller graph for this function:

void StructureAgent::printInfo ( ) [virtual]

Used to print info about this agent to the screen.

Reimplemented from BaseAgent.

Reimplemented in BunkerAgent.

Here is the call graph for this function:

Sends a number of workers to a newly constructed base.

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

bool StructureAgent::repairing [protected]

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Defines