Fix a TT open edge (getting caught by door code)
Try to fix Skull exit again Fix Hera stair key Some vanilla fixes
This commit is contained in:
@@ -42,6 +42,7 @@ def link_doors(world, player):
|
||||
connect_two_way(world, entrance, ext, player)
|
||||
for ent, ext in default_one_way_connections:
|
||||
connect_one_way(world, ent, ext, player)
|
||||
world.key_logic[player] = {} # todo: actual vanilla key logic
|
||||
elif world.doorShuffle == 'basic':
|
||||
within_dungeon(world, player)
|
||||
elif world.doorShuffle == 'crossed':
|
||||
@@ -1062,7 +1063,11 @@ def reassign_key_doors(current_doors, proposal, world, player):
|
||||
while len(queue) > 0:
|
||||
d = queue.pop()
|
||||
if d.type is DoorType.SpiralStairs and d not in proposal:
|
||||
world.get_room(d.roomIndex, player).change(d.doorListPos, DoorKind.Waterfall)
|
||||
room = world.get_room(d.roomIndex, player)
|
||||
if room.doorList[d.doorListPos][1] == DoorKind.StairKeyLow:
|
||||
room.delete(d.doorListPos)
|
||||
else:
|
||||
room.change(d.doorListPos, DoorKind.Waterfall)
|
||||
d.smallKey = False
|
||||
elif d.type is DoorType.Interior and d not in flat_proposal and d.dest not in flat_proposal:
|
||||
world.get_room(d.roomIndex, player).change(d.doorListPos, DoorKind.Normal)
|
||||
@@ -1716,7 +1721,7 @@ default_door_connections = [
|
||||
('Eastern Courtyard Ledge W', 'Eastern West Wing E'),
|
||||
('Eastern Courtyard Ledge E', 'Eastern East Wing W'),
|
||||
('Eastern Hint Tile EN', 'Eastern Courtyard WN'),
|
||||
('Eastern Big Key NE', 'Eastern Hint Tile Blocked Path SW'),
|
||||
('Eastern Big Key NE', 'Eastern Hint Tile Blocked Path SE'),
|
||||
('Eastern Courtyard EN', 'Eastern Map Valley WN'),
|
||||
('Eastern Courtyard N', 'Eastern Darkness S'),
|
||||
('Eastern Map Valley SW', 'Eastern Dark Square NW'),
|
||||
@@ -1766,7 +1771,7 @@ default_door_connections = [
|
||||
('Ice Conveyor SW', 'Ice Bomb Jump NW'),
|
||||
('Ice Pengator Trap NE', 'Ice Spike Cross SE'),
|
||||
('Ice Spike Cross ES', 'Ice Spike Room WS'),
|
||||
('Ice Tall Hint SE', 'Ice Lonely Freezor NW'),
|
||||
('Ice Tall Hint SE', 'Ice Lonely Freezor NE'),
|
||||
('Ice Tall Hint EN', 'Ice Hookshot Ledge WN'),
|
||||
('Iced T EN', 'Ice Catwalk WN'),
|
||||
('Ice Catwalk NW', 'Ice Many Pots SW'),
|
||||
|
||||
2
Doors.py
2
Doors.py
@@ -231,7 +231,7 @@ def create_doors(world, player):
|
||||
|
||||
# Hera
|
||||
create_door(player, 'Hera Lobby Down Stairs', Sprl).dir(Dn, 0x77, 3, HTL).ss(Z, 0x21, 0x90, False, True),
|
||||
create_door(player, 'Hera Lobby Key Stairs', Sprl).dir(Dn, 0x77, 1, HTL).ss(A, 0x12, 0x80).small_key().pos(0),
|
||||
create_door(player, 'Hera Lobby Key Stairs', Sprl).dir(Dn, 0x77, 1, HTL).ss(A, 0x12, 0x80).small_key().pos(1),
|
||||
create_door(player, 'Hera Lobby Up Stairs', Sprl).dir(Up, 0x77, 2, HTL).ss(X, 0x2b, 0x5c, False, True),
|
||||
create_door(player, 'Hera Basement Cage Up Stairs', Sprl).dir(Up, 0x87, 3, LTH).ss(Z, 0x42, 0x7c, True, True),
|
||||
create_door(player, 'Hera Tile Room Up Stairs', Sprl).dir(Up, 0x87, 1, LTH).ss(A, 0x32, 0x6c, True, True),
|
||||
|
||||
8
Rom.py
8
Rom.py
@@ -14,11 +14,11 @@ from Text import Uncle_texts, Ganon1_texts, TavernMan_texts, Sahasrahla2_texts,
|
||||
from Text import KingsReturn_texts, Sanctuary_texts, Kakariko_texts, Blacksmiths_texts, DeathMountain_texts, LostWoods_texts, WishingWell_texts, DesertPalace_texts, MountainTower_texts, LinksHouse_texts, Lumberjacks_texts, SickKid_texts, FluteBoy_texts, Zora_texts, MagicShop_texts, Sahasrahla_names
|
||||
from Utils import output_path, local_path, int16_as_bytes, int32_as_bytes, snes_to_pc
|
||||
from Items import ItemFactory, item_table
|
||||
from EntranceShuffle import door_addresses
|
||||
from EntranceShuffle import door_addresses, exit_ids
|
||||
|
||||
|
||||
JAP10HASH = '03a63945398191337e896e5771f77173'
|
||||
RANDOMIZERBASEHASH = '08d53b2249fc1598be1b94c537d0feb5'
|
||||
RANDOMIZERBASEHASH = 'f3f4b3e897857cc5fa9c138bfc4d3da0'
|
||||
|
||||
|
||||
class JsonRom(object):
|
||||
@@ -506,6 +506,7 @@ def patch_rom(world, player, rom):
|
||||
rom.write_int16(0x15DB5 + 2 * offset, link_y) # same as final else
|
||||
elif room_id == 0x0059 and world.fix_skullwoods_exit:
|
||||
rom.write_int16(0x15DB5 + 2 * offset, 0x00F8)
|
||||
world.fix_skullwoods_exit = False
|
||||
elif room_id == 0x004a and world.fix_palaceofdarkness_exit:
|
||||
rom.write_int16(0x15DB5 + 2 * offset, 0x0640)
|
||||
elif room_id == 0x00d6 and world.fix_trock_exit:
|
||||
@@ -542,6 +543,9 @@ def patch_rom(world, player, rom):
|
||||
for paired_door in world.paired_doors[player]:
|
||||
rom.write_bytes(paired_door.address_a(world, player), paired_door.rom_data_a(world, player))
|
||||
rom.write_bytes(paired_door.address_b(world, player), paired_door.rom_data_b(world, player))
|
||||
if world.fix_skullwoods_exit:
|
||||
rom.write_int16(0x15DB5 + 2 * exit_ids['Skull Woods Final Section Exit'][1], 0x00F8)
|
||||
# todo: fix other exits if ER enabled and similar situation happens
|
||||
|
||||
write_custom_shops(rom, world, player)
|
||||
|
||||
|
||||
@@ -235,7 +235,9 @@ def create_rooms(world, player):
|
||||
# fix some wonky things
|
||||
world.get_room(0x60, player).swap(2, 4) # puts the exit at pos 2 - enables pos 3
|
||||
world.get_room(0x61, player).swap(1, 6) # puts the WN door at pos 1 - enables it
|
||||
world.get_room(0x61, player).swap(5, 6) # puts the Incognito Entrance at the end, so it can be deleted
|
||||
world.get_room(0x62, player).swap(1, 4) # puts the exit at pos 1 - enables pos 3
|
||||
world.get_room(0x77, player).swap(0, 1) # fixes Hera Lobby Key Stairs - entrance now at pos 0
|
||||
|
||||
|
||||
class Room(object):
|
||||
@@ -262,6 +264,9 @@ class Room(object):
|
||||
self.doorList[idx2] = item1
|
||||
self.modified = True
|
||||
|
||||
def delete(self, list_idx):
|
||||
self.doorList[list_idx] = (0xff, 0xff)
|
||||
|
||||
def address(self):
|
||||
return self.doorListAddress
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@ Cleanup:
|
||||
; This sets A (00,02,04) and stores half that at $04 for later use, (src door)
|
||||
CalcIndex: ; A->low byte of Link's Coord, X-> Link's quadrant, DoorOffset x 2 -> A, DoorOffset -> $04 (vert/horz agnostic)
|
||||
cpx.b #00 : bne .largeDoor
|
||||
cmp.b #$90 : bcc .smallDoor
|
||||
cmp.b #$d0 : bcc .smallDoor
|
||||
lda #$01 : bra .done ; Middle Door
|
||||
.smallDoor lda #$00 : bra .done
|
||||
.largeDoor lda #$02
|
||||
|
||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user