|
19 | 19 | UNIT_LOOKUP[str_id] = title
|
20 | 20 |
|
21 | 21 |
|
22 |
| -# TODO: Update these dicts for HotS |
| 22 | +# TODO: Costs need to be version stats. Not here |
23 | 23 | unit_lookup = {'Protoss':{
|
24 | 24 | 'probe':dict(cost=[50,0,1],is_worker=True),
|
25 | 25 | 'zealot':dict(cost=[100,0,2],is_army=True),
|
|
34 | 34 | 'warpprism':dict(cost=[200,0,2],is_army=True),
|
35 | 35 | 'phoenix':dict(cost=[150,100,2],is_army=True),
|
36 | 36 | 'voidray':dict(cost=[250,150,2],is_army=True),
|
| 37 | + 'tempest':dict(cost=[300,200,4],is_army=True), |
| 38 | + 'oracle':dict(cost=[150,150,3],is_army=True), |
37 | 39 | 'carrier':dict(cost=[350,250,6],is_army=True),
|
38 | 40 | 'mothership':dict(cost=[400,400,6],is_army=True),
|
39 |
| - 'mothershipcore':dict(cost=[50,50,0],is_army=True), |
| 41 | + 'mothershipcore':dict(cost=[100,100,2],is_army=True), |
40 | 42 | #'interceptor':[25,0,0], # This is technically a army unit
|
41 | 43 |
|
42 | 44 | 'photoncannon':dict(cost=[150,0,0],is_building=True),
|
|
64 | 66 | 'ghost':dict(cost=[200,100,2],is_army=True),
|
65 | 67 | 'hellion':dict(cost=[100,0,2],is_army=True),
|
66 | 68 | 'battlehellion':dict(cost=[100,0,2],is_army=True),
|
| 69 | + 'warhound':dict(cost=[150,75,2],is_army=True), |
| 70 | + 'widowmine':dict(cost=[75,25,2],is_army=True), |
67 | 71 | 'siegetank':dict(cost=[150,125,2],is_army=True),
|
68 | 72 | 'thor':dict(cost=[300,200,6],is_army=True),
|
69 | 73 | 'viking':dict(cost=[150,75,2],is_army=True),
|
|
87 | 91 | 'starport':dict(cost=[150,100,0],is_building=True),
|
88 | 92 | 'fusioncore':dict(cost=[150,150,0],is_building=True),
|
89 | 93 | 'armory':dict(cost=[150,100,0],is_building=True),
|
90 |
| - # TODO: tech labs and reactors and flyings! |
| 94 | + # TODO: tech labs and reactors and flyings? |
91 | 95 |
|
92 | 96 | },'Zerg':{
|
93 | 97 | # Cumulative costs, including drone costs
|
|
100 | 104 | 'overseer':dict(cost=[150,50,0],is_army=True),
|
101 | 105 | 'hydralisk':dict(cost=[100,50,2],is_army=True),
|
102 | 106 | 'mutalisk':dict(cost=[100,100,2],is_army=True),
|
| 107 | + 'viper':dict(cost=[100,200,3],is_army=True), |
103 | 108 | 'corruptor':dict(cost=[150,100,2],is_army=True),
|
104 | 109 | 'broodlord':dict(cost=[300,250,4],is_army=True),
|
105 | 110 | 'broodling':dict(cost=[0,0,0],is_army=True),
|
106 | 111 | 'infestor':dict(cost=[100,150,2],is_army=True),
|
107 | 112 | 'infestedterran':dict(cost=[0,0,0],is_army=True),
|
| 113 | + 'swarmhost':dict(cost=[200,100,3],is_army=True), |
| 114 | + 'locust':dict(cost=[0,0,0],is_army=True), |
108 | 115 | 'ultralisk':dict(cost=[300,200,6],is_army=True),
|
109 | 116 | 'spinecrawler':dict(cost=[150,0,0],is_building=True),
|
110 | 117 | 'sporecrawler':dict(cost=[125,0,0],is_building=True),
|
|
130 | 137 |
|
131 | 138 | # There are known to be duplicate ability names now. Hrm
|
132 | 139 | train_commands = {
|
133 |
| - 'RavenBuildPointDefenseDrone': ('PointDefenseDrone',0), |
| 140 | + 'BuildPointDefenseDrone': ('PointDefenseDrone',0), |
134 | 141 | 'CalldownMULE': ('MULE',0),
|
135 | 142 | 'BuildCommandCenter': ('CommandCenter',100),
|
136 | 143 | 'BuildSupplyDepot': ('SupplyDepot',30),
|
|
145 | 152 | 'BuildStarport': ('Starport',50),
|
146 | 153 | 'BuildArmory': ('Armory',65),
|
147 | 154 | 'BuildFusionCore': ('FusionCore',65),
|
148 |
| - 'RavenBuildAutoTurret': ('AutoTurret',0), |
| 155 | + 'BuildAutoTurret': ('AutoTurret',0), |
149 | 156 | 'TrainSCV': ('SCV',17),
|
150 | 157 | 'TrainMarine': ('Marine',25),
|
151 | 158 | 'TrainReaper': ('Reaper',45),
|
152 | 159 | 'TrainGhost': ('Ghost',40),
|
153 | 160 | 'TrainMarauder': ('Marauder',30),
|
154 | 161 | 'BuildSiegeTank': ('SiegeTank',45),
|
155 | 162 | 'BuildThor': ('Thor',60),
|
| 163 | + 'BuildwarHound': ('WarHound',45), |
| 164 | + 'BuildWidowMine': ('WidowMine',40), |
156 | 165 | 'BuildHellion': ('Hellion',30),
|
| 166 | + 'BuildBattleHellion': ('BattleHellion',30), |
157 | 167 | 'TrainMedivac': ('Medivac',42),
|
158 | 168 | 'TrainBanshee': ('Banshee',60),
|
159 | 169 | 'TrainRaven': ('Raven',60),
|
160 | 170 | 'TrainBattlecruiser': ('Battlecruiser',90),
|
161 | 171 | 'TrainViking': ('VikingFighter',42),
|
162 |
| - 'MorphToPlanetaryFortress': ('PlanetaryFortress',50), |
163 |
| - 'MorphToOrbitalCommand': ('OrbitalCommand',35), |
| 172 | + 'UpgradeToPlanetaryFortress': ('PlanetaryFortress',50), |
| 173 | + 'UpgradeToOrbitalCommand': ('OrbitalCommand',35), |
164 | 174 |
|
165 | 175 | 'TrainMothership': ('Mothership',160),
|
| 176 | + 'TrainMothershipCore': ('MothershipCore',30), |
166 | 177 | 'BuildNexus': ('Nexus',100),
|
167 | 178 | 'BuildPylon': ('Pylon',25),
|
168 | 179 | 'BuildAssimilator': ('Assimilator',30),
|
|
183 | 194 | 'TrainDarkTemplar': ('DarkTemplar',55),
|
184 | 195 | 'TrainSentry': ('Sentry',37),
|
185 | 196 | 'TrainPhoenix': ('Phoenix',35),
|
| 197 | + 'TrainTempest': ('Tempest',75), |
| 198 | + 'TrainOracle': ('Oracle',60), |
186 | 199 | 'TrainCarrier': ('Carrier',120),
|
187 | 200 | 'TrainVoidRay': ('VoidRay',60),
|
188 | 201 | 'TrainWarpPrism': ('WarpPrism',50),
|
|
197 | 210 | 'WarpInDarkTemplar': ('DarkTemplar',30),
|
198 | 211 | 'WarpInSentry': ('Sentry',21.3),
|
199 | 212 | 'MorphToWarpGate': ('WarpGate',10),
|
200 |
| - 'MergeArchon': ('Archon',12), |
| 213 | + 'ArchonWarpSelection': ('Archon',12), |
| 214 | + 'ArchonWarpTarget': ('Archon',12), |
201 | 215 | 'SentryHallucinationArchon': ('HallucinatedArchon',0),
|
202 | 216 | 'SentryHallucinationColossus': ('HallucinatedColossus',0),
|
203 | 217 | 'SentryHallucinationHighTemplar': ('HallucinatedHighTemplar',0),
|
|
235 | 249 | 'MorphUltralisk': ('Ultralisk',55),
|
236 | 250 | 'MorphRoach': ('Roach',27),
|
237 | 251 | 'MorphInfestor': ('Infestor',50),
|
| 252 | + 'MorphSwarmHost': ('SwarmHost',40), |
| 253 | + 'MorphViper': ('Viper',40), |
238 | 254 | 'MorphCorruptor': ('Corruptor',40),
|
239 | 255 | 'MorphToBroodLord': ('BroodLord',34),
|
240 | 256 | 'MorphToOverseer': ('Overseer',17),
|
@@ -341,9 +357,14 @@ def load_build(data_dir, version):
|
341 | 357 | for ability in abilities.values():
|
342 | 358 | if ability.name in train_commands:
|
343 | 359 | unit_name, build_time = train_commands[ability.name]
|
344 |
| - ability.is_build = True |
345 |
| - ability.build_time = build_time |
346 |
| - ability.build_unit = getattr(data,unit_name) |
| 360 | + # Side affect of using the same ability lookup for all versions |
| 361 | + # BuildBattleHellion will register for all versions because if FactoryTrain |
| 362 | + # This shouldn't hurt though because the ability can't actually be used |
| 363 | + # and will never be looked up in the ability dictionary. |
| 364 | + if hasattr(data,unit_name): |
| 365 | + ability.is_build = True |
| 366 | + ability.build_time = build_time |
| 367 | + ability.build_unit = getattr(data,unit_name) |
347 | 368 | setattr(data, ability.name, ability)
|
348 | 369 |
|
349 | 370 | return data
|
|
0 commit comments