Skip to content

Commit

Permalink
Adds an option to have pot pieces placed local/non-local/anywhere
Browse files Browse the repository at this point in the history
Shivers nearly always finishes last in multiworld games due to the fact you need all 20 pot pieces to win and the pot pieces open very few location checks. This option allows the pieces to be placed locally. This should allow Shivers to be finished earlier.
  • Loading branch information
GodlFire committed Dec 3, 2023
1 parent f8718fa commit 0875771
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
11 changes: 11 additions & 0 deletions worlds/shivers/Options.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,16 @@ class EarlyLightning(Toggle):
"""Allows lightning to be captured at any point in the game. You will still need to capture all ten Ixupi for victory."""
display_name = "Early Lightning"

class LocationPotPieces(Choice):
"""Chooses where pot pieces will be located within the multiworld.
- Own World: Pot pieces will be located within your own world
- Different World: Pot pieces will be located in another world
- Any World: Pot pieces will be located in any world"""
display_name = "Location of Pot Pieces"
option_own_world = 0
option_different_world = 1
option_any_world = 2


@dataclass
class ShiversOptions(PerGameCommonOptions):
Expand All @@ -48,3 +58,4 @@ class ShiversOptions(PerGameCommonOptions):
elevators_stay_solved: ElevatorsStaySolved
early_beth: EarlyBeth
early_lightning: EarlyLightning
location_pot_pieces: LocationPotPieces
6 changes: 6 additions & 0 deletions worlds/shivers/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,12 @@ def create_items(self) -> None:
elif lobby_access_keys == 2:
self.multiworld.local_early_items[self.player]["Key for Front Door"] = 1

#Pot piece shuffle location:
if self.options.location_pot_pieces == 0:
self.multiworld.local_items[self.player].value.update({name for name, data in item_table.items() if data.type == "pot"})
if self.options.location_pot_pieces == 1:
self.multiworld.non_local_items[self.player].value.update({name for name, data in item_table.items() if data.type == "pot"})

def pre_fill(self) -> None:
# Prefills event storage locations with duplicate pots
storagelocs = []
Expand Down

0 comments on commit 0875771

Please sign in to comment.