game_data.py
- class sc2.game_data.GameData(data)
- class sc2.game_data.AbilityData(game_data, proto)
- property button_name: str
For Stimpack this returns ‘Stimpack’
- Return type
str
- property friendly_name: str
For Stimpack this returns ‘Research Stimpack’
- Return type
str
- property id: AbilityId
Returns the generic remap ID. See sc2/dicts/generic_redirect_abilities.py
- Return type
- property link_name: str
For Stimpack this returns ‘BarracksTechLabResearch’
- Return type
str
- class sc2.game_data.UnitTypeData(game_data, proto)
- property cargo_size: int
How much cargo this unit uses up in cargo_space
- Return type
int
- property cost_zerg_corrected: Cost
This returns 25 for extractor and 200 for spawning pool instead of 75 and 250 respectively
- Return type
- property footprint_radius: Optional[float]
See unit.py footprint_radius
- Return type
Optional
[float
]
- property morph_cost: Optional[Cost]
This returns 150 minerals for OrbitalCommand instead of 550
- Return type
Optional
[Cost
]
- property tech_alias: Optional[List[UnitTypeId]]
Building tech equality, e.g. OrbitalCommand is the same as CommandCenter Building tech equality, e.g. Hive is the same as Lair and Hatchery For Hive, this returns [UnitTypeId.Hatchery, UnitTypeId.Lair] For SCV, this returns None
- Return type
Optional
[List
[UnitTypeId
]]
- property tech_requirement: Optional[UnitTypeId]
Tech-building requirement of buildings - may work for units but unreliably
- Return type
Optional
[UnitTypeId
]
- property unit_alias: Optional[UnitTypeId]
Building type equality, e.g. FlyingOrbitalCommand is the same as OrbitalCommand
- Return type
Optional
[UnitTypeId
]
- class sc2.game_data.UpgradeData(game_data, proto)
- class sc2.game_data.Cost(minerals, vespene, time=None)
The cost of an action, a structure, a unit or a research upgrade. The time is given in frames (22.4 frames per game second).