BWAPI
|
#include <TechType.h>
Public Member Functions | |
TechType () | |
TechType (int id) | |
TechType (const TechType &other) | |
TechType & | operator= (const TechType &other) |
operator int () const | |
int | getID () const |
std::string | getName () const |
Race | getRace () const |
int | mineralPrice () const |
int | gasPrice () const |
int | researchTime () const |
int | energyUsed () const |
UnitType | whatResearches () const |
WeaponType | getWeapon () const |
bool | targetsUnit () const |
bool | targetsPosition () const |
const std::set< UnitType > & | whatUses () const |
Order | getOrder () const |
Private Attributes | |
int | id |
Definition at line 11 of file TechType.h.
BWAPI::TechType::TechType | ( | int | id | ) |
BWAPI::TechType::TechType | ( | const TechType & | other | ) |
int BWAPI::TechType::energyUsed | ( | ) | const |
Returns the amount of energy used each time this tech type is used.
Referenced by BasicUnitAction::update(), and PsiStormAction::update().
int BWAPI::TechType::gasPrice | ( | ) | const |
Returns the vespene gas price of the tech type.
Referenced by TechTask::giveUnit(), TechTask::returnUnit(), TechTask::update(), and TechTask::updateRequirements().
int BWAPI::TechType::getID | ( | ) | const |
Returns the unique ID for this tech type.
std::string BWAPI::TechType::getName | ( | ) | const |
Returns the name of the tech type.
Referenced by MacroItem::getDebugInfo(), and TechTask::getOutputName().
Order BWAPI::TechType::getOrder | ( | ) | const |
Returns the order used to execute this tech type as an action.
Race BWAPI::TechType::getRace | ( | ) | const |
Returns the race that uses the TechType. For example, TechTypes::Scanner_Sweep?.getRace() will return Races::Terran.
WeaponType BWAPI::TechType::getWeapon | ( | ) | const |
Returns the corresponding weapon for this tech type, or TechTypes::None if no corresponding weapon exists. For example, TechTypes::Dark_Swarm.getWeapon() will return a pointer to WeaponTypes::Dark_Swarm.
Referenced by ArbiterAction::update(), PsiStormAction::update(), and BasicUnitAction::update().
int BWAPI::TechType::mineralPrice | ( | ) | const |
Returns the mineral cost of the tech type.
Referenced by TechTask::giveUnit(), TechTask::returnUnit(), TechTask::update(), and TechTask::updateRequirements().
BWAPI::TechType::operator int | ( | ) | const |
int BWAPI::TechType::researchTime | ( | ) | const |
Returns the number of frames needed to research the tech type.
Referenced by TechTask::getEndTime(), and TechTask::updateRequirements().
bool BWAPI::TechType::targetsPosition | ( | ) | const |
Returns true if this tech type must be specified a position (i.e. Dark Swarm)
bool BWAPI::TechType::targetsUnit | ( | ) | const |
Returns true if this tech type must be used on another unit (i.e. Irradiate)
UnitType BWAPI::TechType::whatResearches | ( | ) | const |
Returns the type of unit that researches this tech type. If this tech type is available for free (does not need to be researched), then this method will return UnitTypes::None.
Referenced by Requirement::earliestTime(), MacroManagerClass::getNeededUnits(), TechTask::giveUnit(), MacroManagerClass::hasRequirements(), MacroManagerClass::onTechTask(), and TechTask::updateRequirements().
const std::set<UnitType>& BWAPI::TechType::whatUses | ( | ) | const |
Returns the set of units that can use this tech type. Usually this will just be a set of one unit type, however in some cases, such as TechTypes::Burrowing, several unit types will be returned.
int BWAPI::TechType::id [private] |
Definition at line 65 of file TechType.h.