Skip to content
2 changes: 1 addition & 1 deletion Goals.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ def replace_goal_names(worlds: list[World]) -> None:
location
for location in world.get_filled_locations()
if location.type == 'Boss'
and (location.name != 'ToT Reward from Rauru' or not world.settings.skip_reward_from_rauru)
and (location.name != 'ToT Reward from Rauru' or world.settings.skip_reward_from_rauru == 'not_free')
]
for category in world.goal_categories.values():
for goal in category.goals:
Expand Down
18 changes: 17 additions & 1 deletion ItemPool.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

from Item import Item, ItemInfo, ItemFactory
from Location import DisableType
from LocationList import location_groups

if TYPE_CHECKING:
from Plandomizer import ItemPoolRecord
Expand Down Expand Up @@ -549,6 +550,7 @@ def get_pool_core(world: World) -> tuple[list[str], dict[str, Item]]:

# Use the vanilla items in the world's locations when appropriate.
vanilla_items_processed = Counter()
rauru_random_location = None
for location in world.get_locations():
if location.vanilla_item is None:
continue
Expand Down Expand Up @@ -810,11 +812,25 @@ def get_pool_core(world: World) -> tuple[list[str], dict[str, Item]]:
if world.settings.shuffle_dungeon_rewards in ('vanilla', 'reward'):
pass # handled in World.fill_bosses
else:
shuffle_item = True
if world.settings.skip_reward_from_rauru != 'free_forced':
shuffle_item = True
else:
if world.settings.shuffle_dungeon_rewards in ('any_dungeon', 'overworld', 'anywhere'):
# Rauru is currently considered a "Boss" by location, may need to change this in the future.
boss_locations = location_groups['Boss']
rauru_random_location: str = random.choice(boss_locations)
item = world.get_location(rauru_random_location).vanilla_item
world.push_item(location, ItemFactory(item, world))
else:
item = location.vanilla_item
world.push_item(location, ItemFactory(item, world))
elif location.type == 'Boss':
if world.settings.shuffle_dungeon_rewards in ('vanilla', 'reward'):
pass # handled in World.fill_bosses
elif world.settings.shuffle_dungeon_rewards in ('any_dungeon', 'overworld', 'regional', 'anywhere'):
# We swap with the dungeon reward that rauru became if it is a guaranteed dungeon reward then shuffle like usual
if rauru_random_location == location.name:
item = world.get_location('ToT Reward from Rauru').vanilla_item
shuffle_item = True
else:
dungeon = Dungeon.from_vanilla_reward(ItemFactory(location.vanilla_item, world))
Expand Down
2 changes: 1 addition & 1 deletion Plandomizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -1090,7 +1090,7 @@ def configure_effective_starting_items(self, worlds: list[World], world: World)

for iter_world in worlds:
skipped_locations: list[Location] = []
if iter_world.settings.skip_reward_from_rauru:
if iter_world.settings.skip_reward_from_rauru in ('free', 'free_forced'):
skipped_locations.append(iter_world.get_location('ToT Reward from Rauru'))
if iter_world.skip_child_zelda:
skipped_locations += [iter_world.get_location('HC Zeldas Letter'), iter_world.get_location('Song from Impa')]
Expand Down
2 changes: 1 addition & 1 deletion SaveContext.py
Original file line number Diff line number Diff line change
Expand Up @@ -1694,7 +1694,7 @@ def write_settings_dependent_save_context_flags(save_context: SaveContext, world
save_context.write_permanent_flag(Scenes.DEATH_MOUNTAIN_TRAIL, FlagType.SWITCH, 0x3, 0x40) # Plant Death Mountain Trail bean
save_context.write_permanent_flag(Scenes.DEATH_MOUNTAIN_CRATER, FlagType.SWITCH, 0x3, 0x08) # Plant Death Mountain Crater bean

if world.settings.skip_reward_from_rauru:
if world.settings.skip_reward_from_rauru in ('free', 'free_forced'):
save_context.write_bits(0x0EDD, 0x20) # "Pulled Master Sword from Pedestal"

if world.settings.ruto_already_f1_jabu and not world.dungeon_mq['Jabu Jabus Belly']:
Expand Down
20 changes: 19 additions & 1 deletion SettingsList.py
Original file line number Diff line number Diff line change
Expand Up @@ -3299,12 +3299,30 @@ class SettingInfos:

# Other

skip_reward_from_rauru = Checkbutton(
skip_reward_from_rauru = Combobox(
gui_text = 'Free Reward from Rauru',
default = 'not_free',
choices = {
'not_free': 'No',
'free': 'Yes',
'free_forced': 'Yes (Forced)',
},
gui_tooltip = '''\
The item given by Rauru beyond the Door of Time
(the Light Medallion in the vanilla game) is
given as a starting item instead.

'No': Rauru gives reward when you go beyond
the Door of Time.

'Yes': You begin the game with the reward Rauru
normally gives beyond the Door of Time. If dungeon
rewards are shuffled then this will be as well.

'Yes (Forced)': You begin the game with the
reward Rauru normally gives beyond the Door of Time,
if dungeon rewards are shuffled you will still
get a random Spiritual Stone or Medallion.
''',
shared = True,
)
Expand Down
24 changes: 12 additions & 12 deletions data/presets_default.json
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@
"start_with_consumables": true,
"start_with_rupees": true,
"starting_hearts": 3,
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free",
"no_escape_sequence": true,
"no_guard_stealth": true,
"no_epona_race": true,
Expand Down Expand Up @@ -346,7 +346,7 @@
"start_with_consumables": true,
"start_with_rupees": false,
"starting_hearts": 3,
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free",
"no_escape_sequence": true,
"no_guard_stealth": true,
"no_epona_race": true,
Expand Down Expand Up @@ -563,7 +563,7 @@
"start_with_consumables": true,
"start_with_rupees": false,
"starting_hearts": 3,
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free",
"no_escape_sequence": true,
"no_guard_stealth": true,
"no_epona_race": true,
Expand Down Expand Up @@ -776,7 +776,7 @@
"start_with_consumables": false,
"start_with_rupees": false,
"starting_hearts": 3,
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free",
"no_escape_sequence": true,
"no_guard_stealth": true,
"no_epona_race": true,
Expand Down Expand Up @@ -1009,7 +1009,7 @@
"start_with_consumables": true,
"start_with_rupees": false,
"starting_hearts": 3,
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free",
"no_escape_sequence": true,
"no_guard_stealth": true,
"no_epona_race": true,
Expand Down Expand Up @@ -1225,7 +1225,7 @@
"start_with_consumables": true,
"start_with_rupees": true,
"starting_hearts": 3,
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free",
"no_escape_sequence": true,
"no_guard_stealth": true,
"no_epona_race": true,
Expand Down Expand Up @@ -1451,7 +1451,7 @@
"start_with_consumables": true,
"start_with_rupees": false,
"starting_hearts": 3,
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free",
"no_escape_sequence": true,
"no_guard_stealth": true,
"no_epona_race": true,
Expand Down Expand Up @@ -1853,7 +1853,7 @@
"start_with_consumables": false,
"start_with_rupees": false,
"starting_hearts": 3,
"skip_reward_from_rauru": false,
"skip_reward_from_rauru": "not_free",
"no_escape_sequence": false,
"no_guard_stealth": false,
"no_epona_race": false,
Expand Down Expand Up @@ -2054,7 +2054,7 @@
"start_with_consumables": false,
"start_with_rupees": false,
"starting_hearts": 3,
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free",
"no_escape_sequence": true,
"no_guard_stealth": false,
"no_epona_race": false,
Expand Down Expand Up @@ -2276,7 +2276,7 @@
"start_with_consumables": true,
"start_with_rupees": true,
"starting_hearts": 3,
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free",
"no_escape_sequence": true,
"no_guard_stealth": true,
"no_epona_race": true,
Expand Down Expand Up @@ -2466,7 +2466,7 @@
"start_with_consumables": false,
"start_with_rupees": true,
"starting_hearts": 3,
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free",
"no_escape_sequence": true,
"no_guard_stealth": true,
"no_epona_race": true,
Expand Down Expand Up @@ -2738,7 +2738,7 @@
"start_with_consumables": false,
"start_with_rupees": false,
"starting_hearts": 3,
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free",
"no_escape_sequence": true,
"no_guard_stealth": true,
"no_epona_race": true,
Expand Down
2 changes: 1 addition & 1 deletion tests/plando/one-hint-per-goal-dungeons.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"tokensanity": "all",
"mq_dungeons_mode": "vanilla",
"disabled_locations": [],
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free_forced",
"hint_dist_user": {
"name": "goal_coverage_unit_test",
"gui_name": "Goal Coverage Unit Test",
Expand Down
2 changes: 1 addition & 1 deletion tests/plando/one-hint-per-goal-hearts.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"tokensanity": "all",
"mq_dungeons_mode": "vanilla",
"disabled_locations": [],
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free_forced",
"hint_dist_user": {
"name": "goal_coverage_unit_test",
"gui_name": "Goal Coverage Unit Test",
Expand Down
2 changes: 1 addition & 1 deletion tests/plando/one-hint-per-goal-medallions.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"tokensanity": "all",
"mq_dungeons_mode": "vanilla",
"disabled_locations": [],
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free_forced",
"hint_dist_user": {
"name": "goal_coverage_unit_test",
"gui_name": "Goal Coverage Unit Test",
Expand Down
2 changes: 1 addition & 1 deletion tests/plando/one-hint-per-goal-skulls.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"tokensanity": "all",
"mq_dungeons_mode": "vanilla",
"disabled_locations": [],
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free_forced",
"hint_dist_user": {
"name": "goal_coverage_unit_test",
"gui_name": "Goal Coverage Unit Test",
Expand Down
2 changes: 1 addition & 1 deletion tests/plando/one-hint-per-goal-stones.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"tokensanity": "all",
"mq_dungeons_mode": "vanilla",
"disabled_locations": [],
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free_forced",
"hint_dist_user": {
"name": "goal_coverage_unit_test",
"gui_name": "Goal Coverage Unit Test",
Expand Down
2 changes: 1 addition & 1 deletion tests/plando/one-hint-per-goal-triforce-hunt.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"tokensanity": "all",
"mq_dungeons_mode": "vanilla",
"disabled_locations": [],
"skip_reward_from_rauru": true,
"skip_reward_from_rauru": "free_forced",
"hint_dist_user": {
"name": "goal_coverage_unit_test",
"gui_name": "Goal Coverage Unit Test",
Expand Down