Skip to content

sm64ex: All Bowser Stages Goal #2112

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

Merged
merged 4 commits into from
Oct 28, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
7 changes: 7 additions & 0 deletions worlds/sm64ex/Options.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,12 @@ class ExclamationBoxes(Choice):
option_Off = 0
option_1Ups_Only = 1

class CompletionType(Choice):
"""Set goal for game completion"""
display_name = "Completion Goal"
option_Last_Bowser_Stage = 0
option_All_Bowser_Stages = 1


class ProgressiveKeys(DefaultOnToggle):
"""Keys will first grant you access to the Basement, then to the Secound Floor"""
Expand All @@ -110,4 +116,5 @@ class ProgressiveKeys(DefaultOnToggle):
"death_link": DeathLink,
"BuddyChecks": BuddyChecks,
"ExclamationBoxes": ExclamationBoxes,
"CompletionType" : CompletionType,
}
7 changes: 6 additions & 1 deletion worlds/sm64ex/Rules.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,4 +122,9 @@ def set_rules(world, player: int, area_connections):
add_rule(world.get_location("MIPS 1", player), lambda state: state.can_reach("Basement", 'Region', player) and state.has("Power Star", player, world.MIPS1Cost[player].value))
add_rule(world.get_location("MIPS 2", player), lambda state: state.can_reach("Basement", 'Region', player) and state.has("Power Star", player, world.MIPS2Cost[player].value))

world.completion_condition[player] = lambda state: state.can_reach("Bowser in the Sky", 'Region', player)
if world.CompletionType[player].value == 0:
world.completion_condition[player] = lambda state: state.can_reach("Bowser in the Sky", 'Region', player)
elif world.CompletionType[player].value == 1:
world.completion_condition[player] = lambda state: state.can_reach("Bowser in the Dark World", 'Region', player) and \
state.can_reach("Bowser in the Fire Sea", 'Region', player) and \
state.can_reach("Bowser in the Sky", 'Region', player)
1 change: 1 addition & 0 deletions worlds/sm64ex/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@ def fill_slot_data(self):
"MIPS2Cost": self.multiworld.MIPS2Cost[self.player].value,
"StarsToFinish": self.multiworld.StarsToFinish[self.player].value,
"DeathLink": self.multiworld.death_link[self.player].value,
"CompletionType" : self.multiworld.CompletionType[self.player].value,
}

def generate_output(self, output_directory: str):
Expand Down