Skip to content

Commit

Permalink
Merge pull request ArchipelagoMW#16 from Ziktofel/kerrigan_level_items
Browse files Browse the repository at this point in the history
Fix Kerrigan level items
  • Loading branch information
Salzkorn authored Apr 1, 2023
2 parents 010fb91 + af9f9b7 commit b927d62
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions worlds/sc2hots/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -282,11 +282,11 @@ def fill_pool_with_kerrigan_levels(multiworld: MultiWorld, player: int, item_poo
or total_levels == 0:
return

def add_kerrigan_level_items(tier: int, amount: int):
name = f"{tier + 1} Kerrigan Level"
if tier > 0:
def add_kerrigan_level_items(level_amount: int, item_amount: int):
name = f"{level_amount} Kerrigan Level"
if level_amount > 1:
name += "s"
for _ in range(amount):
for _ in range(item_amount):
item_pool.append(create_item_with_correct_settings(player, name))

sizes = [70, 35, 14, 10, 7, 5, 2, 1]
Expand All @@ -298,7 +298,7 @@ def add_kerrigan_level_items(tier: int, amount: int):
elif option == 1: # smooth
distribution = [0, 0, 0, 1, 1, 2, 2, 2, 1, 1]
for tier in range(len(distribution)):
add_kerrigan_level_items(tier, distribution[tier])
add_kerrigan_level_items(tier + 1, distribution[tier])
else:
size = sizes[option - 2]
round_func = round
Expand Down

0 comments on commit b927d62

Please sign in to comment.