mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 12:11:33 -06:00
Reenable Chest Size Matches Contents
This commit is contained in:
@@ -1624,10 +1624,15 @@ def patch_rom(world, rom):
|
||||
chest_name = 'Spirit Temple Compass Chest'
|
||||
chest_address = 0x2B6B07C
|
||||
location = world.get_location(chest_name)
|
||||
item = read_rom_item(rom, location.item.index)
|
||||
if item['chest_type'] in (1, 3):
|
||||
rom.write_int16(chest_address + 2, 0x0190) # X pos
|
||||
rom.write_int16(chest_address + 6, 0xFABC) # Z pos
|
||||
if location.item.game == 'Ocarina of Time':
|
||||
item = read_rom_item(rom, location.item.index)
|
||||
if item['chest_type'] in (1, 3):
|
||||
rom.write_int16(chest_address + 2, 0x0190) # X pos
|
||||
rom.write_int16(chest_address + 6, 0xFABC) # Z pos
|
||||
else:
|
||||
if location.item.advancement:
|
||||
rom.write_int16(chest_address + 2, 0x0190) # X pos
|
||||
rom.write_int16(chest_address + 6, 0xFABC) # Z pos
|
||||
|
||||
# Move Silver Gauntlets chest if it is small so it is reachable from Spirit Hover Seam
|
||||
if world.logic_rules != 'glitchless':
|
||||
@@ -1635,10 +1640,15 @@ def patch_rom(world, rom):
|
||||
chest_address_0 = 0x21A02D0 # Address in setup 0
|
||||
chest_address_2 = 0x21A06E4 # Address in setup 2
|
||||
location = world.get_location(chest_name)
|
||||
item = read_rom_item(rom, location.item.index)
|
||||
if item['chest_type'] in (1, 3):
|
||||
rom.write_int16(chest_address_0 + 6, 0x0172) # Z pos
|
||||
rom.write_int16(chest_address_2 + 6, 0x0172) # Z pos
|
||||
if location.item.game == 'Ocarina of Time':
|
||||
item = read_rom_item(rom, location.item.index)
|
||||
if item['chest_type'] in (1, 3):
|
||||
rom.write_int16(chest_address_0 + 6, 0x0172) # Z pos
|
||||
rom.write_int16(chest_address_2 + 6, 0x0172) # Z pos
|
||||
else:
|
||||
if location.item.advancement:
|
||||
rom.write_int16(chest_address_0 + 6, 0x0172) # Z pos
|
||||
rom.write_int16(chest_address_2 + 6, 0x0172) # Z pos
|
||||
|
||||
# give dungeon items the correct messages
|
||||
add_item_messages(messages, shop_items, world)
|
||||
|
Reference in New Issue
Block a user