My favorites | Sign in
Project Home Downloads Wiki Issues Source
Search
for
Race  
Updated Apr 14, 2011 by AHein...@gmail.com

Class header file: BWAPI/Race.h

List of all Races.

Methods:

Non-member methods in Races namespace:

getID

int getID() const;

Returns a unique ID for this race.

getName

std::string getName() const;

Returns the name of the race. For example Races::Terran.getName() will return a std::string object containing "Terran".

getWorker

UnitType getWorker() const;

Returns the worker unit type for the given race. For example Races::Protoss.getWorker() will return UnitTypes::Protoss_Probe.

getCenter

UnitType getCenter() const;

Returns the center unit type for the given race. For example Races::Terran.getCenter() will return UnitTypes::Terran_Command_Center. While there are three center types for Zerg (Hatchery, Lair, and Hive), Races::Zerg.getCenter() will only return UnitTypes::Zerg_Hatchery, since it is the unit type needed to make a new center.

getRefinery

UnitType getRefinery() const;

Returns the refinery unit type for the given race. For example: Races::Zerg.getRefinery() will return UnitTypes::Zerg_Extractor.

getTransport

UnitType getTransport() const;

Returns the transport unit type for the given race. For example: Races::Protoss.getTransport() will return UnitTypes::Protoss_Shuttle.

getSupplyProvider

UnitType getSupplyProvider() const;

Returns the main supply provider unit type for the given race. For example: Races::Terran.getSupplyProvider() will return UnitTypes::Terran_Supply_Depot.

getRace

Race getRace(std::string name);

Given the name of a race, this function will return the race type. For example: Races::getRace("Zerg") will return Races::Zerg.

allRaces

std::set<Race>& allRaces();

Returns the set of all the races, which are listed below.

Races

  • Zerg
  • Terran
  • Protoss
  • Random
  • Other
  • None
  • Unknown

Sign in to add a comment
Powered by Google Project Hosting