Skip to content

Commit

Permalink
SC2: Fix Kerrigan Primal Form on Half Completion (#3419)
Browse files Browse the repository at this point in the history
  • Loading branch information
Salzkorn authored May 30, 2024
1 parent 6f6bf3c commit 2fe8c43
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions worlds/sc2/Client.py
Original file line number Diff line number Diff line change
Expand Up @@ -966,8 +966,8 @@ def kerrigan_primal(ctx: SC2Context, kerrigan_level: int) -> bool:
return kerrigan_level >= 35
elif ctx.kerrigan_primal_status == KerriganPrimalStatus.option_half_completion:
total_missions = len(ctx.mission_id_to_location_ids)
completed = len([(mission_id * VICTORY_MODULO + get_location_offset(mission_id)) in ctx.checked_locations
for mission_id in ctx.mission_id_to_location_ids])
completed = sum((mission_id * VICTORY_MODULO + get_location_offset(mission_id)) in ctx.checked_locations
for mission_id in ctx.mission_id_to_location_ids)
return completed >= (total_missions / 2)
elif ctx.kerrigan_primal_status == KerriganPrimalStatus.option_item:
codes = [item.item for item in ctx.items_received]
Expand Down

0 comments on commit 2fe8c43

Please sign in to comment.