sm64ex: Make the Exclamation Boxes option a Toggle ()

This commit is contained in:
Remy Jette 2024-11-07 01:34:41 -08:00 committed by GitHub
parent a29205b547
commit 639b9598bd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 4 additions and 5 deletions

View File

@ -91,12 +91,11 @@ class BuddyChecks(Toggle):
display_name = "Bob-omb Buddy Checks" display_name = "Bob-omb Buddy Checks"
class ExclamationBoxes(Choice): class ExclamationBoxes(Toggle):
"""Include 1Up Exclamation Boxes during randomization. """Include 1Up Exclamation Boxes during randomization.
Adds 29 locations to the pool.""" Adds 29 locations to the pool."""
display_name = "Randomize 1Up !-Blocks" display_name = "Randomize 1Up !-Blocks"
option_Off = 0 alias_1Ups_Only = 1
option_1Ups_Only = 1
class CompletionType(Choice): class CompletionType(Choice):

View File

@ -55,7 +55,7 @@ class SM64World(World):
for action in self.options.move_rando_actions.value: for action in self.options.move_rando_actions.value:
max_stars -= 1 max_stars -= 1
self.move_rando_bitvec |= (1 << (action_item_table[action] - action_item_table['Double Jump'])) self.move_rando_bitvec |= (1 << (action_item_table[action] - action_item_table['Double Jump']))
if (self.options.exclamation_boxes > 0): if self.options.exclamation_boxes:
max_stars += 29 max_stars += 29
self.number_of_stars = min(self.options.amount_of_stars, max_stars) self.number_of_stars = min(self.options.amount_of_stars, max_stars)
self.filler_count = max_stars - self.number_of_stars self.filler_count = max_stars - self.number_of_stars
@ -133,7 +133,7 @@ class SM64World(World):
self.multiworld.get_location("THI: Bob-omb Buddy", self.player).place_locked_item(self.create_item("Cannon Unlock THI")) self.multiworld.get_location("THI: Bob-omb Buddy", self.player).place_locked_item(self.create_item("Cannon Unlock THI"))
self.multiworld.get_location("RR: Bob-omb Buddy", self.player).place_locked_item(self.create_item("Cannon Unlock RR")) self.multiworld.get_location("RR: Bob-omb Buddy", self.player).place_locked_item(self.create_item("Cannon Unlock RR"))
if (self.options.exclamation_boxes == 0): if not self.options.exclamation_boxes:
self.multiworld.get_location("CCM: 1Up Block Near Snowman", self.player).place_locked_item(self.create_item("1Up Mushroom")) self.multiworld.get_location("CCM: 1Up Block Near Snowman", self.player).place_locked_item(self.create_item("1Up Mushroom"))
self.multiworld.get_location("CCM: 1Up Block Ice Pillar", self.player).place_locked_item(self.create_item("1Up Mushroom")) self.multiworld.get_location("CCM: 1Up Block Ice Pillar", self.player).place_locked_item(self.create_item("1Up Mushroom"))
self.multiworld.get_location("CCM: 1Up Block Secret Slide", self.player).place_locked_item(self.create_item("1Up Mushroom")) self.multiworld.get_location("CCM: 1Up Block Secret Slide", self.player).place_locked_item(self.create_item("1Up Mushroom"))