Skip to content

Commit ebfa15a

Browse files
author
Reynald Pader
committed
Fix enum name used
Some enum names have been changed from the new id generation script
1 parent 9c60adc commit ebfa15a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sc2/bot_ai.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ async def distribute_workers(self):
148148
for x in range(0, deficit):
149149
if worker_pool:
150150
w = worker_pool.pop()
151-
if len(w.orders) == 1 and w.orders[0].ability.id in [AbilityId.HARVESTRETURN]:
151+
if len(w.orders) == 1 and w.orders[0].ability.id in [AbilityId.HARVEST_RETURN]:
152152
await self.do(w.move(g))
153153
await self.do(w.return_resource(queue=True))
154154
else:
@@ -163,7 +163,7 @@ async def distribute_workers(self):
163163
if worker_pool:
164164
w = worker_pool.pop()
165165
mf = self.state.mineral_field.closest_to(townhall)
166-
if len(w.orders) == 1 and w.orders[0].ability.id in [AbilityId.HARVESTRETURN]:
166+
if len(w.orders) == 1 and w.orders[0].ability.id in [AbilityId.HARVEST_RETURN]:
167167
await self.do(w.move(townhall))
168168
await self.do(w.return_resource(queue=True))
169169
await self.do(w.gather(mf, queue=True))

0 commit comments

Comments
 (0)