Skip to content

Commit

Permalink
Fix enum name used
Browse files Browse the repository at this point in the history
Some enum names have been changed from the new id generation script
  • Loading branch information
Reynald Pader committed Feb 1, 2018
1 parent 9c60adc commit ebfa15a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sc2/bot_ai.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ async def distribute_workers(self):
for x in range(0, deficit):
if worker_pool:
w = worker_pool.pop()
if len(w.orders) == 1 and w.orders[0].ability.id in [AbilityId.HARVESTRETURN]:
if len(w.orders) == 1 and w.orders[0].ability.id in [AbilityId.HARVEST_RETURN]:
await self.do(w.move(g))
await self.do(w.return_resource(queue=True))
else:
Expand All @@ -163,7 +163,7 @@ async def distribute_workers(self):
if worker_pool:
w = worker_pool.pop()
mf = self.state.mineral_field.closest_to(townhall)
if len(w.orders) == 1 and w.orders[0].ability.id in [AbilityId.HARVESTRETURN]:
if len(w.orders) == 1 and w.orders[0].ability.id in [AbilityId.HARVEST_RETURN]:
await self.do(w.move(townhall))
await self.do(w.return_resource(queue=True))
await self.do(w.gather(mf, queue=True))
Expand Down

0 comments on commit ebfa15a

Please sign in to comment.