|
TechType
Class header file: BWAPI/TechType.h List of all TechTypes. Methods:
Non-member methods in TechTypes namespace: getIDint getID() const; Returns the unique ID for this tech type. getNamestd::string getName() const; Returns the name of the tech type. getRaceRace getRace() const; Returns the race that uses the TechType. For example, TechTypes::Scanner_Sweep.getRace() will return Races::Terran. mineralPriceint mineralPrice() const; Returns the mineral cost of the tech type. gasPriceint gasPrice() const; Returns the vespene gas price of the tech type. researchTimeint researchTime() const; Returns the number of frames needed to research this tech type. energyUsedint energyUsed() const; Returns the amount of energy used each time this tech type is used. whatResearchesUnitType 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. getWeaponWeaponType 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 WeaponTypes::Dark_Swarm. targetsUnitbool targetsUnit() const; Returns true if this tech type must be used on another unit (i.e. Irradiate). targetsPositionbool targetsPosition() const; Returns true if this tech type must be used at a specified a position (i.e. Dark Swarm). whatUsesconst std::set<UnitType>& 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. getTechTypeTechType getTechType(std::string name); Given a string, this will return the tech type. allTechTypesstd::set<TechType>& allTechTypes(); Returns the set of all the TechTypes. | |