Skip to content

Commit

Permalink
A Short Hike: Add option to customize filler coin count (ArchipelagoM…
Browse files Browse the repository at this point in the history
…W#3004)


Co-authored-by: Exempt-Medic <[email protected]>
  • Loading branch information
chandler05 and Exempt-Medic authored Mar 22, 2024
1 parent ca549df commit 96d93c1
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 4 deletions.
16 changes: 16 additions & 0 deletions worlds/shorthike/Options.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,21 @@ class CostMultiplier(Range):
range_end = 200
default = 100

class FillerCoinAmount(Choice):
"""The number of coins that will be in each filler coin item."""
display_name = "Coins per Filler Item"
option_7_coins = 0
option_13_coins = 1
option_15_coins = 2
option_18_coins = 3
option_21_coins = 4
option_25_coins = 5
option_27_coins = 6
option_32_coins = 7
option_33_coins = 8
option_50_coins = 9
default = 1

@dataclass
class ShortHikeOptions(PerGameCommonOptions):
start_inventory_from_pool: StartInventoryPool
Expand All @@ -71,3 +86,4 @@ class ShortHikeOptions(PerGameCommonOptions):
buckets: Buckets
golden_feather_progression: GoldenFeatherProgression
cost_multiplier: CostMultiplier
filler_coin_amount: FillerCoinAmount
5 changes: 1 addition & 4 deletions worlds/shorthike/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,8 @@ class ShortHikeWorld(World):

required_client_version = (0, 4, 4)

def __init__(self, multiworld, player):
super(ShortHikeWorld, self).__init__(multiworld, player)

def get_filler_item_name(self) -> str:
return "13 Coins"
return self.options.filler_coin_amount.current_option_name

def create_item(self, name: str) -> "ShortHikeItem":
item_id: int = self.item_name_to_id[name]
Expand Down

0 comments on commit 96d93c1

Please sign in to comment.