Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TUNIC: Use fewer parameters in helper functions #3356

Merged
merged 13 commits into from
Jul 5, 2024
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions worlds/tunic/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ def create_items(self) -> None:

# Remove filler to make room for other items
def remove_filler(amount: int) -> None:
for _ in range(0, amount):
for _ in range(amount):
if not available_filler:
fill = "Fool Trap"
else:
Expand Down Expand Up @@ -249,7 +249,7 @@ def remove_filler(amount: int) -> None:
items_to_create["Lantern"] = 0

for item, quantity in items_to_create.items():
for i in range(0, quantity):
for _ in range(quantity):
tunic_item: TunicItem = self.create_item(item)
if item in slot_data_item_names:
self.slot_data_items.append(tunic_item)
Expand Down Expand Up @@ -300,10 +300,10 @@ def create_regions(self) -> None:

def set_rules(self) -> None:
if self.options.entrance_rando or self.options.shuffle_ladders:
set_er_location_rules(self, self.ability_unlocks)
set_er_location_rules(self)
else:
set_region_rules(self, self.ability_unlocks)
set_location_rules(self, self.ability_unlocks)
set_region_rules(self)
set_location_rules(self)

def get_filler_item_name(self) -> str:
return self.random.choice(filler_items)
Expand Down Expand Up @@ -378,7 +378,7 @@ def fill_slot_data(self) -> Dict[str, Any]:
if start_item in slot_data_item_names:
if start_item not in slot_data:
slot_data[start_item] = []
for i in range(0, self.options.start_inventory_from_pool[start_item]):
for _ in range(self.options.start_inventory_from_pool[start_item]):
slot_data[start_item].extend(["Your Pocket", self.player])

for plando_item in self.multiworld.plando_items[self.player]:
Expand Down
Loading
Loading