Add sanctuary goal

This commit is contained in:
2025-03-10 08:37:55 -05:00
parent 4a8ab9e02f
commit 9ad70fb3d7
5 changed files with 18 additions and 6 deletions

View File

@@ -3633,7 +3633,7 @@ sword_mode = {"random": 0, "assured": 1, "swordless": 2, "vanilla": 3}
# byte 2: GGGD DFFH (goal, diff, item_func, hints)
goal_mode = {'ganon': 0, 'pedestal': 1, 'dungeons': 2, 'triforcehunt': 3, 'crystals': 4, 'trinity': 5,
'ganonhunt': 6, 'completionist': 7}
'ganonhunt': 6, 'completionist': 7, 'sanctuary': 1}
diff_mode = {"normal": 0, "hard": 1, "expert": 2}
func_mode = {"normal": 0, "hard": 1, "expert": 2}

View File

@@ -185,7 +185,7 @@ def get_custom_array_key(item):
def generate_itempool(world, player):
if (world.difficulty[player] not in ['normal', 'hard', 'expert']
or world.goal[player] not in ['ganon', 'pedestal', 'dungeons', 'triforcehunt', 'trinity', 'crystals',
'ganonhunt', 'completionist']
'ganonhunt', 'completionist', 'sanctuary']
or world.mode[player] not in ['open', 'standard', 'inverted']
or world.timer not in ['none', 'display', 'timed', 'timed-ohko', 'ohko', 'timed-countdown']
or world.progressive not in ['on', 'off', 'random']):
@@ -201,7 +201,7 @@ def generate_itempool(world, player):
location.event = True
location.locked = True
if world.goal[player] in ['pedestal', 'triforcehunt']:
if world.goal[player] in ['pedestal', 'triforcehunt', 'sanctuary']:
set_event_item('Ganon', 'Nothing')
else:
set_event_item('Ganon', 'Triforce')
@@ -1167,6 +1167,8 @@ def get_pool_core(world, player, progressive, shuffle, difficulty, treasure_hunt
# note: massage item pool now handles shrinking the pool appropriately
if goal in ['sanctuary']:
place_item('Sanctuary', 'Triforce')
if goal in ['pedestal', 'trinity'] and swords != 'vanilla':
place_item('Master Sword Pedestal', 'Triforce')
if world.bow_mode[player].startswith('retro'):
@@ -1333,6 +1335,8 @@ def make_custom_item_pool(world, player, progressive, shuffle, difficulty, timer
elif timer == 'ohko':
clock_mode = 'ohko'
if goal in ['sanctuary']:
place_item('Sanctuary', 'Triforce')
if goal in ['pedestal', 'trinity']:
place_item('Master Sword Pedestal', 'Triforce')
@@ -1447,6 +1451,8 @@ def make_customizer_pool(world, player):
elif timer == 'ohko':
clock_mode = 'ohko'
if goal in ['sanctuary']:
place_item('Sanctuary', 'Triforce')
if world.goal[player] in ['pedestal', 'trinity']:
place_item('Master Sword Pedestal', 'Triforce')

6
Rom.py
View File

@@ -1250,7 +1250,7 @@ def patch_rom(world, rom, player, team, is_mystery=False):
(0x02 if 'bombs' in world.escape_assist[player] else 0x00) |
(0x04 if 'magic' in world.escape_assist[player] else 0x00))) # Escape assist
if world.goal[player] in ['pedestal', 'triforcehunt']:
if world.goal[player] in ['pedestal', 'triforcehunt', 'sanctuary']:
rom.write_byte(0x1801A8, 0x01) # make ganon invincible
elif world.goal[player] in ['dungeons']:
rom.write_byte(0x1801A8, 0x02) # make ganon invincible until all dungeons are beat
@@ -2399,6 +2399,10 @@ def write_strings(rom, world, player, team):
tt['ganon_phase_3_alt'] = 'Seriously? Go Away, I will not Die.'
tt['sign_ganon'] = 'Go find the Triforce pieces... Ganon is invincible!'
tt['murahdahla'] = "Hello @. I\nam Murahdahla, brother of\nSahasrahla and Aginah. Behold the power of\ninvisibility.\n\n\n\n… … …\n\nWait! You can see me? I knew I should have\nhidden in a hollow tree. If you bring\n%d triforce pieces, I can reassemble it." % int(world.treasure_hunt_count[player])
elif world.goal[player] in ['sanctuary']:
tt['ganon_fall_in_alt'] = 'Why are you even here?\n You can\'t even hurt me! Your goal is in the sanctuary.'
tt['ganon_phase_3_alt'] = 'Seriously? Go Away, I will not Die.'
tt['sign_ganon'] = 'You need to go to the sanctuary... Ganon is invincible!'
elif world.goal[player] in ['pedestal']:
tt['ganon_fall_in_alt'] = 'Why are you even here?\n You can\'t even hurt me! Your goal is at the pedestal.'
tt['ganon_phase_3_alt'] = 'Seriously? Go Away, I will not Die.'

View File

@@ -71,7 +71,8 @@
"trinity",
"crystals",
"ganonhunt",
"completionist"
"completionist",
"sanctuary"
]
},
"difficulty": {

View File

@@ -122,7 +122,8 @@
" Pedestal, or delivering Triforce Pieces.",
"Ganon Hunt: Places 30 Triforce Pieces in the world, collect",
" 20 of them then defeat Ganon.",
"Completionist: Find everything then defeat Ganon."
"Completionist: Find everything then defeat Ganon.",
"Sanctuary: Places the Trifroce in the Sanctuary."
],
"difficulty": [
"Select game difficulty. Affects available itempool. (default: %(default)s)",