Add config option that can disable respawning at pyramid after death to ganon if he happens to be shuffled to elsewhere. Slightly untested, but should cause no harm.

This commit is contained in:
LLCoolDave 2017-08-01 19:08:46 +02:00
parent abff299f25
commit 7187d63108
5 changed files with 10 additions and 0 deletions

View File

@ -28,6 +28,7 @@ class World(object):
self.place_dungeon_items = place_dungeon_items # configurable in future
self.shuffle_bonk_prizes = False
self.swamp_patch_required = False
self.ganon_at_pyramid = True
self.sewer_light_cone = mode == 'standard'
self.light_world_light_cone = False
self.dark_world_light_cone = False

View File

@ -646,6 +646,10 @@ def link_entrances(world):
if world.get_entrance('Dam').connected_region.name != 'Dam' or world.get_entrance('Swamp Palace').connected_region.name != 'Swamp Palace (Entrance)':
world.swamp_patch_required = True
# check for ganon location
if world.get_entrance('Pyramid Hole').connected_region.name != 'Pyramid':
world.ganon_at_pyramid = False
def connect_simple(world, exitname, regionname):
world.get_entrance(exitname).connect(world.get_region(regionname))

View File

@ -523,6 +523,7 @@ def copy_world(world):
ret = World(world.shuffle, world.logic, world.mode, world.difficulty, world.goal, world.algorithm, world.place_dungeon_items, world.check_beatable_only, world.shuffle_ganon)
ret.required_medallions = list(world.required_medallions)
ret.swamp_patch_required = world.swamp_patch_required
ret.ganon_at_pyramid = world.ganon_at_pyramid
ret.treasure_hunt_count = world.treasure_hunt_count
ret.treasure_hunt_icon = world.treasure_hunt_icon
ret.sewer_light_cone = world.sewer_light_cone

View File

@ -150,6 +150,9 @@ def fill_world(world, plando, text_patches):
elif line.startswith('!check_beatable_only'):
_, chkbtstr = line.split(':', 1)
world.check_beatable_only = chkbtstr.strip().lower() == 'true'
elif line.startswith('!ganon_death_pyramid_respawn'):
_, gnpstr = line.split(':', 1)
world.ganon_at_pyramid = gnpstr.strip().lower() == 'true'
elif line.startswith('!save_quit_boss'):
_, sqbstr = line.split(':', 1)
world.save_and_quite_from_boss = sqbstr.strip().lower() == 'true'

1
Rom.py
View File

@ -282,6 +282,7 @@ def patch_rom(world, rom, hashtable, quickswap=False, beep='normal', sprite=None
rom.write_byte(0x180030, 0x00) # Disable SRAM trace
rom.write_byte(0x180036, 0x0A) # Rupoor negative value
rom.write_byte(0x180169, 0x01 if world.lock_aga_door_in_escape else 0x00) # Lock or unlock aga tower door during escape sequence.
rom.write_byte(0x180170, 0x01 if world.ganon_at_pyramid else 0x00) # Enable respawning on pyramid after ganon death
rom.write_byte(0x180086, 0x00 if world.aga_randomness else 0x01) # set blue ball and ganon warp randomness
rom.write_byte(0x1800A1, 0x01) # enable overworld screen transition draining for water level inside swamp
if world.goal in ['ganon']: