Merge remote-tracking branch 'codemann/OWMain' into overworld_kara
This commit is contained in:
@@ -539,9 +539,15 @@ Overworld_ActualScreenID:
|
|||||||
org $02B861
|
org $02B861
|
||||||
Dungeon_SaveRoomQuadrantData:
|
Dungeon_SaveRoomQuadrantData:
|
||||||
|
|
||||||
|
org $02C11D
|
||||||
|
CalculateTransitionLanding:
|
||||||
|
|
||||||
org $02C176
|
org $02C176
|
||||||
Overworld_FinalizeEntryOntoScreen_Data:
|
Overworld_FinalizeEntryOntoScreen_Data:
|
||||||
|
|
||||||
|
org $02D9B9
|
||||||
|
Underworld_LoadSpawnEntrance:
|
||||||
|
|
||||||
org $02E99D
|
org $02E99D
|
||||||
FluteMenu_LoadTransport:
|
FluteMenu_LoadTransport:
|
||||||
|
|
||||||
@@ -707,6 +713,9 @@ OverworldMap_DarkWorldTilemap:
|
|||||||
org $0ABAB9
|
org $0ABAB9
|
||||||
OverworldMap_LoadSprGfx:
|
OverworldMap_LoadSprGfx:
|
||||||
|
|
||||||
|
org $8AE817
|
||||||
|
DungeonMapBossRooms:
|
||||||
|
|
||||||
org $0CD7D1
|
org $0CD7D1
|
||||||
NameFile_MakeScreenVisible:
|
NameFile_MakeScreenVisible:
|
||||||
org $0CDB3E
|
org $0CDB3E
|
||||||
|
|||||||
@@ -37,3 +37,41 @@ WalkDownIntoTavern:
|
|||||||
CMP #$43
|
CMP #$43
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
|
; TurnAroundOnUnderworld
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
|
TurnAroundOnUnderworld:
|
||||||
|
LDA $26 : BEQ .done
|
||||||
|
; turn around if ($010E == #$43) != ($7F5099 == #$43)
|
||||||
|
LDX #$00
|
||||||
|
LDA #$43 : CMP $010E : BEQ +
|
||||||
|
INX
|
||||||
|
+
|
||||||
|
CMP $7F5099 : BEQ +
|
||||||
|
DEX
|
||||||
|
+
|
||||||
|
CPX #$00 : BEQ .done
|
||||||
|
LDA $26 : EOR #$0C : STA $26
|
||||||
|
.done
|
||||||
|
JML $0FFD65 ; what we overwrote
|
||||||
|
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
|
; TurnUpOnOverworld
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
|
TurnUpOnOverworld:
|
||||||
|
LDA.l EntranceTavernBack : CMP #$43 : BEQ .done
|
||||||
|
LDA #$08 : STA $26 ; only fix this glitch if exit not vanilla
|
||||||
|
.done
|
||||||
|
JML $07E68F ; what we overwrote
|
||||||
|
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
|
; WalkUpOnOverworld
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
|
WalkUpOnOverworld:
|
||||||
|
LDA $20 : CMP #$091B : BNE .normal ; hardcoded Y coordinate
|
||||||
|
STZ $2F
|
||||||
|
RTL
|
||||||
|
.normal
|
||||||
|
LDA #$0002 : STA $2F ; what we overwrote
|
||||||
|
RTL
|
||||||
@@ -17,10 +17,24 @@
|
|||||||
incsrc drhooks.asm
|
incsrc drhooks.asm
|
||||||
|
|
||||||
;Main Code
|
;Main Code
|
||||||
org $278000 ;138000
|
org $A78000 ;138000
|
||||||
db $44, $52 ;DR
|
db $44, $52 ;DR
|
||||||
DRMode:
|
DRMode:
|
||||||
dw 0
|
dw 0
|
||||||
|
; xxpg rmse
|
||||||
|
; xxxx xBDM
|
||||||
|
; x - unused
|
||||||
|
|
||||||
|
; p - use the original palette for the dungeon rooms instead of the DR table
|
||||||
|
; g - fix the EG glitch in more places (should be off for no logic)
|
||||||
|
; r - The collection rate flag
|
||||||
|
; m - Whether to display keys Map Info
|
||||||
|
; s - Start with Mirror Scroll
|
||||||
|
; e - GT minibosses marked as defeated instead of spawning heart container in all dungeons
|
||||||
|
|
||||||
|
; B - Big Key doors can displayed and be opened on the "south" side in addition
|
||||||
|
; D - Enabled spawning as a bunny in the Dark World underworld
|
||||||
|
; M - hides the total number in the collection rate
|
||||||
DRFlags:
|
DRFlags:
|
||||||
dw 0
|
dw 0
|
||||||
DRScroll:
|
DRScroll:
|
||||||
@@ -38,7 +52,7 @@ incsrc edges.asm
|
|||||||
incsrc math.asm
|
incsrc math.asm
|
||||||
incsrc hudadditions.asm
|
incsrc hudadditions.asm
|
||||||
incsrc dr_lobby.asm
|
incsrc dr_lobby.asm
|
||||||
warnpc $279C00
|
warnpc $A79C00
|
||||||
|
|
||||||
incsrc doortables.asm
|
incsrc doortables.asm
|
||||||
warnpc $288000
|
warnpc $A88000
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
org $279C00
|
org $A79C00
|
||||||
KeyDoorOffset:
|
KeyDoorOffset:
|
||||||
; 0 1 2 3 4 5 6 7 8 9 a b c d e f --Offset Ruler
|
; 0 1 2 3 4 5 6 7 8 9 a b c d e f --Offset Ruler
|
||||||
dw $0000,$0001,$0003,$0000,$0006,$0000,$000b,$0000,$0000,$0000,$000c,$000d,$0010,$0011,$0012,$0000
|
dw $0000,$0001,$0003,$0000,$0006,$0000,$000b,$0000,$0000,$0000,$000c,$000d,$0010,$0011,$0012,$0000
|
||||||
@@ -18,7 +18,7 @@ dw $01f1,$01f3,$01f7,$0000,$0000,$01f8,$01fa,$0000,$01fd,$0200,$0203,$0204,$0206
|
|||||||
dw $0207
|
dw $0207
|
||||||
|
|
||||||
|
|
||||||
org $279E00
|
org $A79E00
|
||||||
SpiralOffset:
|
SpiralOffset:
|
||||||
; 0 1 2 3 4 5 6 7 8 9 a b c d e f --Offset Ruler
|
; 0 1 2 3 4 5 6 7 8 9 a b c d e f --Offset Ruler
|
||||||
db $00,$01,$02,$00,$03,$00,$00,$04,$00,$05,$07,$00,$08,$00,$0b,$00
|
db $00,$01,$02,$00,$03,$00,$00,$04,$00,$05,$07,$00,$08,$00,$0b,$00
|
||||||
@@ -37,7 +37,7 @@ db $67,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00
|
|||||||
db $6a,$6d,$6e,$00,$00,$00,$00,$00,$00,$00,$6f,$00,$00,$00,$00,$00
|
db $6a,$6d,$6e,$00,$00,$00,$00,$00,$00,$00,$6f,$00,$00,$00,$00,$00
|
||||||
db $70
|
db $70
|
||||||
|
|
||||||
org $279F00
|
org $A79F00
|
||||||
DoorOffset:
|
DoorOffset:
|
||||||
db $00,$01,$02,$00,$03,$00,$04,$00,$00,$00,$00,$00,$9A,$05,$99,$00
|
db $00,$01,$02,$00,$03,$00,$04,$00,$00,$00,$00,$00,$9A,$05,$99,$00
|
||||||
db $00,$06,$07,$08,$09,$0A,$0B,$00,$00,$0C,$0D,$0E,$00,$0F,$10,$11
|
db $00,$06,$07,$08,$09,$0A,$0B,$00,$00,$0C,$0D,$0E,$00,$0F,$10,$11
|
||||||
@@ -56,7 +56,7 @@ db $00,$81,$82,$83,$84,$85,$86,$87,$88,$89,$00,$8A,$8B,$00,$8C,$00
|
|||||||
db $00,$8D,$8E,$00,$00,$8F,$90,$00,$91,$92,$93,$94,$95,$00,$00,$00
|
db $00,$8D,$8E,$00,$00,$8F,$90,$00,$91,$92,$93,$94,$95,$00,$00,$00
|
||||||
db $9f
|
db $9f
|
||||||
|
|
||||||
org $27A000
|
org $A7A000
|
||||||
DoorTable:
|
DoorTable:
|
||||||
;; NW 00 N 01 NE 02 WN 00 W 01 WS 02 SW 00 S 01 SE 02 EN 00 E 01 ES 02 - Door ruler
|
;; NW 00 N 01 NE 02 WN 00 W 01 WS 02 SW 00 S 01 SE 02 EN 00 E 01 ES 02 - Door ruler
|
||||||
dw $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003 ; Default/Garbage row
|
dw $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003 ; Default/Garbage row
|
||||||
@@ -226,7 +226,7 @@ dw $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003, $0003,
|
|||||||
;dw $0072, $4ff8 ; ->HC Map Room
|
;dw $0072, $4ff8 ; ->HC Map Room
|
||||||
;dw $0080, $1f50 ; ->zelda's cellblock
|
;dw $0080, $1f50 ; ->zelda's cellblock
|
||||||
|
|
||||||
org $27B000
|
org $A7B000
|
||||||
SpiralTable: ;113 4 byte entries - should end at 27B1C4
|
SpiralTable: ;113 4 byte entries - should end at 27B1C4
|
||||||
dw $0203, $8080 ;null row
|
dw $0203, $8080 ;null row
|
||||||
dw $0203, $8080 ;HC Backhallway
|
dw $0203, $8080 ;HC Backhallway
|
||||||
@@ -309,7 +309,7 @@ dw $0203, $8080 ;East Attic Start
|
|||||||
dw $0203, $8080 ;Tower Entrance
|
dw $0203, $8080 ;Tower Entrance
|
||||||
|
|
||||||
|
|
||||||
org $27C000 ;ends around 27C418
|
org $A7C000 ;ends around 27C418
|
||||||
PairedDoorTable:
|
PairedDoorTable:
|
||||||
dw $0000 ; the bad template
|
dw $0000 ; the bad template
|
||||||
dw $0000,$0000
|
dw $0000,$0000
|
||||||
@@ -503,7 +503,7 @@ dw $0000,$0000,$0000,$0000
|
|||||||
dw $ffff ; indicates the end - we can drop this
|
dw $ffff ; indicates the end - we can drop this
|
||||||
|
|
||||||
; Edge Transition Table (Target Room, Flags, MultiDiv ratio for edges)
|
; Edge Transition Table (Target Room, Flags, MultiDiv ratio for edges)
|
||||||
org $27C500 ;ends around 27C5F(9) 4 bytes would be 27C649
|
org $A7C500 ;ends around 27C5F(9) 4 bytes would be 27C649
|
||||||
;I kind of want to split the 3rd byte into two
|
;I kind of want to split the 3rd byte into two
|
||||||
NorthOpenEdge:
|
NorthOpenEdge:
|
||||||
db $00,$80,$11, $00,$80,$11, $00,$80,$11, $00,$80,$11
|
db $00,$80,$11, $00,$80,$11, $00,$80,$11, $00,$80,$11
|
||||||
@@ -559,11 +559,11 @@ db $01, $02, $03, $04, $05, $06, $0a, $14
|
|||||||
|
|
||||||
; In-room stairs in North/South pairs. From left to right:
|
; In-room stairs in North/South pairs. From left to right:
|
||||||
; PoD, IP right side, IP Freezor chest and GT
|
; PoD, IP right side, IP Freezor chest and GT
|
||||||
org $27C700
|
org $A7C700
|
||||||
InroomStairsTable:
|
InroomStairsTable:
|
||||||
dw $0003,$0003, $0003,$0003, $0003,$0003, $0003,$0003
|
dw $0003,$0003, $0003,$0003, $0003,$0003, $0003,$0003
|
||||||
|
|
||||||
org $27C720
|
org $A7C720
|
||||||
InroomStairsRoom:
|
InroomStairsRoom:
|
||||||
db $0B,$1B, $3F,$1F, $7E,$5E, $96,$3D
|
db $0B,$1B, $3F,$1F, $7E,$5E, $96,$3D
|
||||||
InroomStairsX:
|
InroomStairsX:
|
||||||
@@ -572,7 +572,7 @@ InroomStairsY:
|
|||||||
dw $0058, $0148, $0198, $0190
|
dw $0058, $0148, $0198, $0190
|
||||||
|
|
||||||
|
|
||||||
org $27E000
|
org $A7E000
|
||||||
CutoffRooms:
|
CutoffRooms:
|
||||||
; TT Alcove, Mire Bridge Left & Right, Mire Bent Bridge, Mire Hub
|
; TT Alcove, Mire Bridge Left & Right, Mire Bent Bridge, Mire Hub
|
||||||
; Pod Falling & Harmless, SW Star Pits, TR Lava Escape & TR Dual Pipes, Bob's Room & GT Big Chest
|
; Pod Falling & Harmless, SW Star Pits, TR Lava Escape & TR Dual Pipes, Bob's Room & GT Big Chest
|
||||||
@@ -588,7 +588,7 @@ dw $ffff
|
|||||||
|
|
||||||
; dungeon tables
|
; dungeon tables
|
||||||
; HC HC EP DP AT SP PD MM SW IP TH TT TR GT
|
; HC HC EP DP AT SP PD MM SW IP TH TT TR GT
|
||||||
org $27f000
|
org $A7f000
|
||||||
CompassBossIndicator:
|
CompassBossIndicator:
|
||||||
dw $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000
|
dw $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000
|
||||||
TotalKeys: ;27f020
|
TotalKeys: ;27f020
|
||||||
@@ -603,13 +603,13 @@ TotalLocationsLow: ;27f080
|
|||||||
db $08, $08, $06, $06, $02, $00, $04, $08, $08, $08, $06, $08, $02, $07, $00, $00
|
db $08, $08, $06, $06, $02, $00, $04, $08, $08, $08, $06, $08, $02, $07, $00, $00
|
||||||
TotalLocationsHigh: ;27f090
|
TotalLocationsHigh: ;27f090
|
||||||
db $00, $00, $00, $00, $00, $01, $01, $00, $00, $00, $00, $00, $01, $02, $00, $00
|
db $00, $00, $00, $00, $00, $01, $01, $00, $00, $00, $00, $00, $01, $02, $00, $00
|
||||||
org $27f0a0
|
org $A7f0a0
|
||||||
TotalLocations:
|
TotalLocations:
|
||||||
db $08, $08, $06, $06, $02, $0a, $0e, $08, $08, $08, $06, $08, $0c, $1b, $00, $00
|
db $08, $08, $06, $06, $02, $0a, $0e, $08, $08, $08, $06, $08, $0c, $1b, $00, $00
|
||||||
; no more room here
|
; no more room here
|
||||||
|
|
||||||
; Vert 0,6,0 Horz 2,0,8
|
; Vert 0,6,0 Horz 2,0,8
|
||||||
org $27f0b0
|
org $A7f0b0
|
||||||
CoordIndex: ; Horizontal 1st
|
CoordIndex: ; Horizontal 1st
|
||||||
db 2, 0 ; Coordinate Index $20-$23
|
db 2, 0 ; Coordinate Index $20-$23
|
||||||
OppCoordIndex:
|
OppCoordIndex:
|
||||||
@@ -631,16 +631,16 @@ dw $00ff, $010b ; Right/Bot camera bounds when not frozen + appropriate low byte
|
|||||||
dw $017f, $0187 ; Right/Bot camera bound when at edge or layout frozen
|
dw $017f, $0187 ; Right/Bot camera bound when at edge or layout frozen
|
||||||
;27f0ce next free byte
|
;27f0ce next free byte
|
||||||
|
|
||||||
org $27f0f0
|
org $A7f0f0
|
||||||
RemoveRainDoorsRoom:
|
RemoveRainDoorsRoom:
|
||||||
dw $0060, $0062, $ffff ; ffff indicates end of list
|
dw $0060, $0062, $ffff ; ffff indicates end of list
|
||||||
RainDoorMatch: ; org $27f0f6 and f8 for now
|
RainDoorMatch: ; org $A7f0f6 and f8 for now
|
||||||
dw $0081, $0061 ; not xba'd
|
dw $0081, $0061 ; not xba'd
|
||||||
BlockSanctuaryDoorInRain: ;27f0fa
|
BlockSanctuaryDoorInRain: ;27f0fa
|
||||||
dw $0000
|
dw $0000
|
||||||
|
|
||||||
|
|
||||||
org $27f100
|
org $A7f100
|
||||||
TilesetTable:
|
TilesetTable:
|
||||||
; 0 1 2 3 4 5 6 7 8 9 a b c d e f --Offset Ruler
|
; 0 1 2 3 4 5 6 7 8 9 a b c d e f --Offset Ruler
|
||||||
db $13,$04,$04,$06,$0d,$ff,$08,$05,$06,$07,$07,$07,$0e,$0e,$0b,$ff
|
db $13,$04,$04,$06,$0d,$ff,$08,$05,$06,$07,$07,$07,$0e,$0e,$0b,$ff
|
||||||
@@ -680,14 +680,14 @@ db $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$14,$20
|
|||||||
db $00,$07,$20,$20,$07,$07,$07,$07,$07,$20,$20,$07,$20,$20,$20,$20
|
db $00,$07,$20,$20,$07,$07,$07,$07,$07,$20,$20,$07,$20,$20,$20,$20
|
||||||
db $07,$07,$02,$02,$02,$02,$07,$07,$07,$20,$20,$07,$20,$20,$20,$07
|
db $07,$07,$02,$02,$02,$02,$07,$07,$07,$20,$20,$07,$20,$20,$20,$07
|
||||||
|
|
||||||
;27f300
|
;A7f300
|
||||||
DungeonTilesets:
|
DungeonTilesets:
|
||||||
db $04,$04,$05,$12,$04,$08,$07,$0C,$09,$0B,$05,$0A,$0D,$0E,$06,$06
|
db $04,$04,$05,$12,$04,$08,$07,$0C,$09,$0B,$05,$0A,$0D,$0E,$06,$06
|
||||||
|
|
||||||
;
|
;
|
||||||
;org $27ff00
|
;org $A7ff00
|
||||||
|
|
||||||
org $27fff0
|
org $A7fff0
|
||||||
LinksHouseDarkWorld:
|
LinksHouseDarkWorld:
|
||||||
dw $ffff
|
dw $ffff
|
||||||
SanctuaryDarkWorld:
|
SanctuaryDarkWorld:
|
||||||
|
|||||||
@@ -1,68 +1,75 @@
|
|||||||
org $02b5c4 ; -- moving right routine 135c4
|
org $82b5c4 ; -- moving right routine 135c4
|
||||||
jsl WarpRight
|
jsl WarpRight
|
||||||
org $02b665 ; -- moving left routine
|
org $82b665 ; -- moving left routine
|
||||||
jsl WarpLeft
|
jsl WarpLeft
|
||||||
org $02b713 ; -- moving down routine
|
org $82b713 ; -- moving down routine
|
||||||
jsl WarpDown
|
jsl WarpDown
|
||||||
org $02b7b4 ; -- moving up routine
|
org $82b7b4 ; -- moving up routine
|
||||||
jsl WarpUp
|
jsl WarpUp
|
||||||
org $02bd80
|
org $82bd80
|
||||||
jsl AdjustTransition
|
jsl AdjustTransition
|
||||||
nop
|
nop
|
||||||
|
|
||||||
;turn off linking doors -- see .notRoomLinkDoor label in Bank02.asm
|
;turn off linking doors -- see .notRoomLinkDoor label in Bank02.asm
|
||||||
org $02b5a8 ; <- 135a8 - Bank02.asm : 8368 (LDA $7EC004 : STA $A0)
|
org $82b5a8 ; <- 135a8 - Bank02.asm : 8368 (LDA $7EC004 : STA $A0)
|
||||||
jsl CheckLinkDoorR
|
jsl CheckLinkDoorR
|
||||||
bcc NotLinkDoor1
|
bcc NotLinkDoor1
|
||||||
org $02b5b6
|
org $82b5b6
|
||||||
NotLinkDoor1:
|
NotLinkDoor1:
|
||||||
org $02b649 ; <- 135a8 - Bank02.asm : 8482 (LDA $7EC004 : STA $A0)
|
org $82b649 ; <- 135a8 - Bank02.asm : 8482 (LDA $7EC004 : STA $A0)
|
||||||
jsl CheckLinkDoorL
|
jsl CheckLinkDoorL
|
||||||
bcc NotLinkDoor2
|
bcc NotLinkDoor2
|
||||||
org $02b657
|
org $82b657
|
||||||
NotLinkDoor2:
|
NotLinkDoor2:
|
||||||
|
|
||||||
|
|
||||||
; Staircase routine
|
; Staircase routine
|
||||||
org $01c3d4 ; <- c3d4 - Bank01.asm : 9762-4 (Dungeon_DetectStaircase-> STA $A0 : LDA $063D, X)
|
org $81c3d4 ; <- c3d4 - Bank01.asm : 9762-4 (Dungeon_DetectStaircase-> STA $A0 : LDA $063D, X)
|
||||||
jsl RecordStairType : nop
|
jsl RecordStairType : nop
|
||||||
org $02a1e7 ;(PC: 121e7)
|
org $82a1e7 ;(PC: 121e7)
|
||||||
jsl SpiralWarp
|
jsl SpiralWarp
|
||||||
|
|
||||||
org $0291b3 ; <- Bank02.asm : 3303 (LDA $0462 : AND.b #$04)
|
org $8291b3 ; <- Bank02.asm : 3303 (LDA $0462 : AND.b #$04)
|
||||||
jsl SpiralPriorityHack : nop
|
jsl SpiralPriorityHack : nop
|
||||||
org $0290f9 ; <- Bank02.asm : 3188 (LDA $0462 : AND.b #$04)
|
org $8290f9 ; <- Bank02.asm : 3188 (LDA $0462 : AND.b #$04)
|
||||||
jsl SpiralPriorityHack : nop
|
jsl SpiralPriorityHack : nop
|
||||||
|
|
||||||
org $029369 ; <- 11369 - Bank02.asm : 3610 (STX $0464 : STY $012E)
|
org $829369 ; <- 11369 - Bank02.asm : 3610 (STX $0464 : STY $012E)
|
||||||
jsl StraightStairsAdj : nop #2
|
jsl StraightStairsAdj : nop #2
|
||||||
org $029383 ; <- 11384 - Bank02.asm : 3629 (.walkingDownStaircase-> ADD $20 : STA $20)
|
org $829383 ; <- 11384 - Bank02.asm : 3629 (.walkingDownStaircase-> ADD $20 : STA $20)
|
||||||
jsl StraightStairsFix : nop
|
jsl StraightStairsFix : nop
|
||||||
org $0293aa ; <- 113aa - Bank02.asm : 3653 (ADD $20 : STA $20)
|
org $8293aa ; <- 113aa - Bank02.asm : 3653 (ADD $20 : STA $20)
|
||||||
jsl StraightStairsFix : nop
|
jsl StraightStairsFix : nop
|
||||||
org $0293d1 ; <- 113d1 - Bank02.asm : 3683 (ADD $20 : STA $20 BRANCH_IOTA)
|
org $8293d1 ; <- 113d1 - Bank02.asm : 3683 (ADD $20 : STA $20 BRANCH_IOTA)
|
||||||
jsl StraightStairsFix : nop
|
jsl StraightStairsFix : nop
|
||||||
org $029396 ; <- 11396 - Bank02.asm : 3641 (LDA $01C322, X)
|
org $829396 ; <- 11396 - Bank02.asm : 3641 (LDA $01C322, X)
|
||||||
jsl StraightStairLayerFix
|
jsl StraightStairLayerFix
|
||||||
org $02c06d ; <- Bank02.asm : 9874 (LDX $0418, CMP.b #$02)
|
org $82c06d ; <- Bank02.asm : 9874 (LDX $0418, CMP.b #$02)
|
||||||
jsl DoorToStraight : nop
|
jsl DoorToStraight : nop
|
||||||
org $02c092 ; STA $0020, Y : LDX #$00
|
org $82c092 ; STA $0020, Y : LDX #$00
|
||||||
jsl DoorToInroom : nop
|
jsl DoorToInroom : nop
|
||||||
org $02c0f8 ; CMP $02C034, X
|
org $82c0f8 ; CMP $02C034, X
|
||||||
jsl DoorToInroomEnd
|
jsl DoorToInroomEnd
|
||||||
org $02941a ; <- Bank02.asm : 3748 module 7.12.11 (LDA $0464 : BNE BRANCH_$11513 : INC $B0 : RTS)
|
org $82941a ; <- Bank02.asm : 3748 module 7.12.11 (LDA $0464 : BNE BRANCH_$11513 : INC $B0 : RTS)
|
||||||
jsl StraightStairsTrapDoor : rts
|
jsl StraightStairsTrapDoor : rts
|
||||||
org $028b54 ; <- Bank02.asm : 2200 (JSL UseImplicitRegIndexedLocalJumpTable)
|
org $828b54 ; <- Bank02.asm : 2200 (JSL UseImplicitRegIndexedLocalJumpTable)
|
||||||
jsl InroomStairsTrapDoor
|
jsl InroomStairsTrapDoor
|
||||||
|
org $82c146
|
||||||
|
jsl HandleSpecialDoorLanding
|
||||||
|
org $82c23a
|
||||||
|
HandleIncomingDoorStateLocal:
|
||||||
|
jsl HandleIncomingDoorState : rts
|
||||||
|
org $82c172
|
||||||
|
jsr HandleIncomingDoorStateLocal
|
||||||
|
|
||||||
org $0289a0 ; JSL $0091C4
|
org $8289a0 ; JSL $0091C4
|
||||||
jsl QuadrantLoadOrderBeforeScroll
|
jsl QuadrantLoadOrderBeforeScroll
|
||||||
org $02bd9c ; JSL $0091C4
|
org $82bd9c ; JSL $0091C4
|
||||||
jsl QuadrantLoadOrderAfterScroll
|
jsl QuadrantLoadOrderAfterScroll
|
||||||
|
|
||||||
|
|
||||||
; Graphics fix
|
; Graphics fix
|
||||||
org $02895d ; Bank 02 line 1812 (JSL Dungeon_LoadRoom : JSL Dungeon_InitStarTileChr : JSL $00D6F9 : INC $B0)
|
org $82895d ; Bank 02 line 1812 (JSL Dungeon_LoadRoom : JSL Dungeon_InitStarTileChr : JSL $00D6F9 : INC $B0)
|
||||||
Splicer:
|
Splicer:
|
||||||
jsl GfxFixer
|
jsl GfxFixer
|
||||||
lda $b1 : beq .done
|
lda $b1 : beq .done
|
||||||
@@ -70,150 +77,143 @@ rts
|
|||||||
nop #5
|
nop #5
|
||||||
.done
|
.done
|
||||||
|
|
||||||
org $01b618 ; Bank01.asm : 7963 Dungeon_LoadHeader (REP #$20 : INY : LDA [$0D], Y)
|
org $81b618 ; Bank01.asm : 7963 Dungeon_LoadHeader (REP #$20 : INY : LDA [$0D], Y)
|
||||||
nop : jsl OverridePaletteHeader
|
nop : jsl OverridePaletteHeader
|
||||||
|
|
||||||
org $02817e ; Bank02.asm : 414 (LDA $02811E, X)
|
org $82817e ; Bank02.asm : 414 (LDA $02811E, X)
|
||||||
jsl FixAnimatedTiles
|
jsl FixAnimatedTiles
|
||||||
|
|
||||||
org $0aef43 ; UnderworldMap_RecoverGFX
|
org $8aef43 ; UnderworldMap_RecoverGFX
|
||||||
jsl FixCloseDungeonMap
|
jsl FixCloseDungeonMap
|
||||||
|
|
||||||
org $028a06 ; Bank02.asm : 1941 Dungeon_ResetTorchBackgroundAndPlayer
|
org $828a06 ; Bank02.asm : 1941 Dungeon_ResetTorchBackgroundAndPlayer
|
||||||
JSL FixWallmasterLamp
|
JSL FixWallmasterLamp
|
||||||
|
|
||||||
org $00d377 ;Bank 00 line 3185
|
org $80d377 ;Bank 00 line 3185
|
||||||
DecompDungAnimatedTiles:
|
DecompDungAnimatedTiles:
|
||||||
org $00fda4 ;Bank 00 line 8882
|
org $80fda4 ;Bank 00 line 8882
|
||||||
Dungeon_InitStarTileCh:
|
Dungeon_InitStarTileCh:
|
||||||
org $00d6ae ;(PC: 56ae)
|
org $80d6ae ;(PC: 56ae)
|
||||||
LoadTransAuxGfx:
|
LoadTransAuxGfx:
|
||||||
org $00d739 ;
|
org $80d739 ;
|
||||||
LoadTransAuxGfx_Alt:
|
LoadTransAuxGfx_Alt:
|
||||||
org $00df5a ;(PC: 5f5a)
|
org $80df5a ;(PC: 5f5a)
|
||||||
PrepTransAuxGfx:
|
PrepTransAuxGfx:
|
||||||
org $0ffd65 ;(PC: 07fd65)
|
org $8ffd65 ;(PC: 07fd65)
|
||||||
Dungeon_LoadCustomTileAttr:
|
Dungeon_LoadCustomTileAttr:
|
||||||
org $01feb0
|
org $81feb0
|
||||||
Dungeon_ApproachFixedColor:
|
Dungeon_ApproachFixedColor:
|
||||||
;org $01fec1
|
;org $01fec1
|
||||||
;Dungeon_ApproachFixedColor_variable:
|
;Dungeon_ApproachFixedColor_variable:
|
||||||
;org $a0f972 ; Rando version
|
;org $a0f972 ; Rando version
|
||||||
;LoadRoomHook:
|
;LoadRoomHook:
|
||||||
org $1bee74 ;(PC: 0dee74)
|
org $9bee74 ;(PC: 0dee74)
|
||||||
Palette_DungBgMain:
|
Palette_DungBgMain:
|
||||||
org $1bec77
|
org $9bec77
|
||||||
Palette_SpriteAux3:
|
Palette_SpriteAux3:
|
||||||
org $1becc5
|
org $9becc5
|
||||||
Palette_SpriteAux2:
|
Palette_SpriteAux2:
|
||||||
org $1bece4
|
org $9bece4
|
||||||
Palette_SpriteAux1:
|
Palette_SpriteAux1:
|
||||||
|
|
||||||
|
|
||||||
org $0DFA53
|
org $828046 ; <- 10046 - Bank02.asm : 217 (JSL EnableForceBlank) (Start of Module_LoadFile)
|
||||||
jsl.l LampCheckOverride
|
jsl OnFileLoadOverride
|
||||||
org $028046 ; <- 10046 - Bank02.asm : 217 (JSL EnableForceBlank) (Start of Module_LoadFile)
|
org $87A93F ; < 3A93F - Bank07.asm 6548 (LDA $8A : AND.b #$40 - Mirror checks)
|
||||||
jsl.l OnFileLoadOverride
|
jsl MirrorCheckOverride
|
||||||
org $07A93F ; < 3A93F - Bank07.asm 6548 (LDA $8A : AND.b #$40 - Mirror checks)
|
|
||||||
jsl.l MirrorCheckOverride
|
|
||||||
|
|
||||||
org $05ef47
|
org $85ef47
|
||||||
Sprite_HeartContainer_Override: ;sprite_heart_upgrades.asm : 96-100 (LDA $040C : CMP.b #$1A : BNE .not_in_ganons_tower)
|
Sprite_HeartContainer_Override: ;sprite_heart_upgrades.asm : 96-100 (LDA $040C : CMP.b #$1A : BNE .not_in_ganons_tower)
|
||||||
jsl GtBossHeartCheckOverride : bcs .not_in_ganons_tower
|
jsl GtBossHeartCheckOverride : bcs .not_in_ganons_tower
|
||||||
nop : stz $0dd0, X : rts
|
nop : stz $0dd0, X : rts
|
||||||
.not_in_ganons_tower
|
.not_in_ganons_tower
|
||||||
|
|
||||||
|
|
||||||
org $07a955 ; <- Bank07.asm : around 6564 (JP is a bit different) (STZ $05FC : STZ $05FD)
|
org $87a955 ; <- Bank07.asm : around 6564 (JP is a bit different) (STZ $05FC : STZ $05FD)
|
||||||
jsl BlockEraseFix
|
jsl BlockEraseFix
|
||||||
nop #2
|
nop #2
|
||||||
|
|
||||||
org $02A0A8
|
org $82A0A8
|
||||||
Mirror_SaveRoomData:
|
Mirror_SaveRoomData:
|
||||||
org $07A95B ; < bank_07.asm ; #_07A95B: JSL Mirror_SaveRoomData
|
org $87A95B ; < bank_07.asm ; #_07A95B: JSL Mirror_SaveRoomData
|
||||||
jsl EGFixOnMirror
|
jsl EGFixOnMirror
|
||||||
|
|
||||||
org $02b82a
|
org $82b82a
|
||||||
jsl FixShopCode
|
jsl FixShopCode
|
||||||
|
|
||||||
org $1ddeea ; <- Bank1D.asm : 286 (JSL Sprite_LoadProperties)
|
org $9ddeea ; <- Bank1D.asm : 286 (JSL Sprite_LoadProperties)
|
||||||
jsl VitreousKeyReset
|
jsl VitreousKeyReset
|
||||||
|
|
||||||
org $1ed024 ; f5024 sprite_guruguru_bar.asm : 27 (LDA $040C : CMP.b #$12 : INY #2
|
org $9ed024 ; f5024 sprite_guruguru_bar.asm : 27 (LDA $040C : CMP.b #$12 : INY #2
|
||||||
jsl GuruguruFix : bra .next
|
jsl GuruguruFix : bra .next
|
||||||
nop #3
|
nop #3
|
||||||
.next
|
.next
|
||||||
|
|
||||||
org $028fc9
|
org $828fc9
|
||||||
nop #2 : jsl BlindAtticFix
|
nop #2 : jsl BlindAtticFix
|
||||||
|
|
||||||
org $028409
|
org $828409
|
||||||
jsl SuctionOverworldFix
|
jsl SuctionOverworldFix
|
||||||
|
|
||||||
org $0ded04 ; <- rando's hooks.asm line 2192 - 6ED04 - equipment.asm : 1963 (REP #$30)
|
org $8ded04 ; <- rando's hooks.asm line 2192 - 6ED04 - equipment.asm : 1963 (REP #$30)
|
||||||
jsl DrHudDungeonItemsAdditions
|
jsl DrHudDungeonItemsAdditions
|
||||||
;org $098638 ; rando's hooks.asm line 2192
|
;org $098638 ; rando's hooks.asm line 2192
|
||||||
;jsl CountChestKeys
|
;jsl CountChestKeys
|
||||||
org $06D192 ; rando's hooks.asm line 457
|
org $86D192 ; rando's hooks.asm line 457
|
||||||
jsl CountAbsorbedKeys
|
jsl CountAbsorbedKeys
|
||||||
; rando's hooks.asm line 1020
|
; rando's hooks.asm line 1020
|
||||||
;org $05FC7E ; <- 2FC7E - sprite_dash_item.asm : 118 (LDA $7EF36F : INC A : STA $7EF36F)
|
;org $05FC7E ; <- 2FC7E - sprite_dash_item.asm : 118 (LDA $7EF36F : INC A : STA $7EF36F)
|
||||||
;jsl CountBonkItem
|
;jsl CountBonkItem
|
||||||
|
|
||||||
org $019dbd ; <- Bank01.asm : 4465 of Object_Draw8xN (LDA $9B52, Y : STA $7E2000, X)
|
org $819dbd ; <- Bank01.asm : 4465 of Object_Draw8xN (LDA $9B52, Y : STA $7E2000, X)
|
||||||
jsl CutoffEntranceRug : bra .nextTile : nop
|
jsl CutoffEntranceRug : bra .nextTile : nop
|
||||||
.nextTile
|
.nextTile
|
||||||
|
|
||||||
;maybe set 02e2 to 0
|
;maybe set 02e2 to 0
|
||||||
|
|
||||||
org $0799de ; <- Bank07.asm : 4088 (LDA.b #$15 : STA $5D)
|
org $8799de ; <- Bank07.asm : 4088 (LDA.b #$15 : STA $5D)
|
||||||
JSL StoreTempBunnyState
|
JSL StoreTempBunnyState
|
||||||
;
|
;
|
||||||
org $08c450 ; <- ancilla_receive_item.asm : 146-148 (STY $5D : STZ $02D8)
|
org $88c450 ; <- ancilla_receive_item.asm : 146-148 (STY $5D : STZ $02D8)
|
||||||
JSL RetrieveBunnyState : NOP
|
JSL RetrieveBunnyState : NOP
|
||||||
|
|
||||||
org $02d9ce ; <- Bank02.asm : Dungeon_LoadEntrance 10829 (STA $A0 : STA $048E)
|
org $82d9ce ; <- Bank02.asm : Dungeon_LoadEntrance 10829 (STA $A0 : STA $048E)
|
||||||
JSL CheckDarkWorldSpawn : NOP
|
JSL CheckDarkWorldSpawn : NOP
|
||||||
|
|
||||||
org $01891e ; <- Bank 01.asm : 991 Dungeon_LoadType2Object (LDA $00 : XBA : AND.w #$00FF)
|
org $81891e ; <- Bank 01.asm : 991 Dungeon_LoadType2Object (LDA $00 : XBA : AND.w #$00FF)
|
||||||
JSL RainPrevention : BCC + : RTS : NOP : +
|
JSL RainPrevention : BCC + : RTS : NOP : +
|
||||||
|
|
||||||
org $1edabf ; <- sprite_energy_ball.asm : 86-7 Sprite_EnergyBall (LDA.b #$10 : LDX.b #$00)
|
org $9edabf ; <- sprite_energy_ball.asm : 86-7 Sprite_EnergyBall (LDA.b #$10 : LDX.b #$00)
|
||||||
JSL StandardAgaDmg
|
JSL StandardAgaDmg
|
||||||
|
|
||||||
|
|
||||||
org $09a681 ; < - similar to talalong.asm : 1157 (JSL Main_ShowTextMessage)
|
org $89a681 ; < - similar to talalong.asm : 1157 (JSL Main_ShowTextMessage)
|
||||||
JSL BlindsAtticHint : NOP #2
|
JSL BlindsAtticHint : NOP #2
|
||||||
org $1cfd69
|
org $9cfd69
|
||||||
Main_ShowTextMessage:
|
Main_ShowTextMessage:
|
||||||
|
|
||||||
; Conditionally disable UW music changes in Door Rando
|
; Conditionally disable UW music changes in Door Rando
|
||||||
org $028ADB ; <- Bank02.asm:2088-2095 (LDX.b #$14 : LDA $A0 ...)
|
org $828ADB ; <- Bank02.asm:2088-2095 (LDX.b #$14 : LDA $A0 ...)
|
||||||
JSL.l Underworld_DoorDown_Entry : CPX #$FF
|
JSL.l Underworld_DoorDown_Entry : CPX #$FF
|
||||||
BEQ + : db $80, $1C ; BRA $028B04
|
BEQ + : db $80, $1C ; BRA $028B04
|
||||||
NOP #6 : +
|
NOP #6 : +
|
||||||
|
|
||||||
org $02C3F2 ; <- Bank02.asm:10521 Unused call
|
org $82C3F2 ; <- Bank02.asm:10521 Unused call
|
||||||
Underworld_DoorDown_Call:
|
Underworld_DoorDown_Call:
|
||||||
org $02C3F3
|
org $82C3F3
|
||||||
dw $8AD9 ; address of Bank02.asm:2085
|
dw $8AD9 ; address of Bank02.asm:2085
|
||||||
|
|
||||||
; These two, if enabled together, have implications for vanilla BK doors in IP/Hera/Mire
|
org $81AA90
|
||||||
; IPBJ is common enough to consider not doing this. Mire is not a concern for vanilla - maybe glitched modes
|
JSL BigKeyDoorCheck : NOP
|
||||||
; Hera BK door back can be seen with Pot clipping - likely useful for no logic seeds
|
|
||||||
|
|
||||||
;Kill big key (1e) check for south doors
|
org $81AAA2
|
||||||
;org $1aa90
|
RoomDraw_OneSidedShutters_South_onesided_shutter_or_big_key_door:
|
||||||
;DontCheck:
|
|
||||||
;bra .done
|
|
||||||
;nop #3
|
|
||||||
;.done
|
|
||||||
|
|
||||||
;Enable south facing bk graphic
|
;Enable south facing bk graphic
|
||||||
;org $00CE24
|
org $80CE24
|
||||||
;dw $2ac8
|
dw $2ac8
|
||||||
|
|
||||||
org $01b714 ; PC: b714
|
org $81b714 ; PC: b714
|
||||||
OpenableDoors:
|
OpenableDoors:
|
||||||
jsl CheckIfDoorsOpen
|
jsl CheckIfDoorsOpen
|
||||||
bcs .normal
|
bcs .normal
|
||||||
|
|||||||
@@ -296,6 +296,7 @@ StraightStairsAdj:
|
|||||||
stz $046d
|
stz $046d
|
||||||
.noScroll
|
.noScroll
|
||||||
jsr GetTileAttribute : tax
|
jsr GetTileAttribute : tax
|
||||||
|
jsl HandleIncomingDoorState
|
||||||
lda $11 : cmp #$12 : beq .goingNorth
|
lda $11 : cmp #$12 : beq .goingNorth
|
||||||
lda $a2 : cmp #$51 : bne ++
|
lda $a2 : cmp #$51 : bne ++
|
||||||
rep #$20 : lda #$0018 : !add $20 : sta $20 : sep #$20 ; special fix for throne room
|
rep #$20 : lda #$0018 : !add $20 : sta $20 : sep #$20 ; special fix for throne room
|
||||||
@@ -324,7 +325,7 @@ GetTileAttribute:
|
|||||||
{
|
{
|
||||||
phk : pea.w .jslrtsreturn-1
|
phk : pea.w .jslrtsreturn-1
|
||||||
pea.w $02802c
|
pea.w $02802c
|
||||||
jml $02c11d ; mucks with x/y sets a to Tile Attribute, I think
|
jml CalculateTransitionLanding ; mucks with x/y sets a to Tile Attribute, I think
|
||||||
.jslrtsreturn
|
.jslrtsreturn
|
||||||
rts
|
rts
|
||||||
}
|
}
|
||||||
@@ -416,4 +417,25 @@ InroomStairsTrapDoor:
|
|||||||
pla : pla : pla
|
pla : pla : pla
|
||||||
jsl StraightStairsTrapDoor_reset
|
jsl StraightStairsTrapDoor_reset
|
||||||
jml $028b15 ; just some RTS in bank 02
|
jml $028b15 ; just some RTS in bank 02
|
||||||
|
}
|
||||||
|
|
||||||
|
HandleSpecialDoorLanding: {
|
||||||
|
LDA.l $7F2000,X ; what we wrote over
|
||||||
|
SEP #$30
|
||||||
|
CMP #$34 : bne + ; inroom stairs
|
||||||
|
PHA : LDA #$26 : STA $045E : PLA
|
||||||
|
+
|
||||||
|
}
|
||||||
|
|
||||||
|
; Y = tiletype, also written to $4E
|
||||||
|
HandleIncomingDoorState:
|
||||||
|
{
|
||||||
|
PHA
|
||||||
|
LDA.l DRMode : BEQ .noDoor
|
||||||
|
CPY.b #$01 : !bge .noDoor
|
||||||
|
LDA.w $0418 : AND.b #$02 : BNE + : INC
|
||||||
|
+ STA.b $6C
|
||||||
|
.noDoor
|
||||||
|
STY.b $4E : TYA ; what we wrote over
|
||||||
|
PLY : RTL
|
||||||
}
|
}
|
||||||
@@ -1,27 +1,3 @@
|
|||||||
;================================================================================
|
|
||||||
; Lamp Mantle & Light Cone Fix
|
|
||||||
;--------------------------------------------------------------------------------
|
|
||||||
; Output: 0 for darkness, 1 for lamp cone
|
|
||||||
;--------------------------------------------------------------------------------
|
|
||||||
LampCheckOverride:
|
|
||||||
LDA $7F50C4 : CMP.b #$01 : BNE + : RTL : +
|
|
||||||
CMP.b #$FF : BNE + : INC : RTL : +
|
|
||||||
|
|
||||||
LDA LampEquipment : BNE .done ; skip if we already have lantern
|
|
||||||
|
|
||||||
LDA CurrentWorld : BNE +
|
|
||||||
.lightWorld
|
|
||||||
LDA $040C : CMP.b #$04 : !BGE ++ ; check if we're in HC
|
|
||||||
LDA LampConeSewers : BRA .done
|
|
||||||
++
|
|
||||||
LDA LampConeLightWorld : BRA .done
|
|
||||||
+
|
|
||||||
.darkWorld
|
|
||||||
LDA LampConeDarkWorld
|
|
||||||
.done
|
|
||||||
;BNE + : STZ $1D : + ; remember to turn cone off after a torch
|
|
||||||
RTL
|
|
||||||
|
|
||||||
GtBossHeartCheckOverride:
|
GtBossHeartCheckOverride:
|
||||||
lda $a0 : cmp #$1c : beq ++
|
lda $a0 : cmp #$1c : beq ++
|
||||||
cmp #$6c : beq ++
|
cmp #$6c : beq ++
|
||||||
@@ -123,7 +99,7 @@ RainPrevention:
|
|||||||
PHA
|
PHA
|
||||||
LDA ProgressIndicator : AND #$00FF : CMP #$0002 : !BGE .done ; only in rain states (0 or 1)
|
LDA ProgressIndicator : AND #$00FF : CMP #$0002 : !BGE .done ; only in rain states (0 or 1)
|
||||||
LDA.l ProgressFlags : AND #$0004 : BNE .done ; zelda's been rescued
|
LDA.l ProgressFlags : AND #$0004 : BNE .done ; zelda's been rescued
|
||||||
LDA.l BlockSanctuaryDoorInRain : BEQ .done ;flagged
|
LDA.l BlockSanctuaryDoorInRain : BEQ + ;flagged
|
||||||
LDA $A0 : CMP #$0012 : BNE + ;we're in the sanctuary
|
LDA $A0 : CMP #$0012 : BNE + ;we're in the sanctuary
|
||||||
LDA.l FollowerIndicator : AND #$00FF : CMP #$0001 : BEQ .done ; zelda is following
|
LDA.l FollowerIndicator : AND #$00FF : CMP #$0001 : BEQ .done ; zelda is following
|
||||||
LDA $00 : AND #$00FF : CMP #$00A1 : BNE .done ; position is a1
|
LDA $00 : AND #$00FF : CMP #$00A1 : BNE .done ; position is a1
|
||||||
@@ -160,3 +136,8 @@ BlindZeldaDespawnFix:
|
|||||||
+ PLA : PLA : PEA.w SpritePrep_BlindMaiden_kill_the_girl-1 : RTL
|
+ PLA : PLA : PEA.w SpritePrep_BlindMaiden_kill_the_girl-1 : RTL
|
||||||
|
|
||||||
|
|
||||||
|
BigKeyDoorCheck:
|
||||||
|
CPY.w #$001E : BNE + ; skip if it isn't a BK door
|
||||||
|
LDA.l DRFlags : AND #$0400 : BNE + ; skip if the flag is set - bk doors can be double-sided
|
||||||
|
PLA : PEA.w RoomDraw_OneSidedShutters_South_onesided_shutter_or_big_key_door-1
|
||||||
|
+ LDA.w #$0000 : RTL
|
||||||
|
|||||||
@@ -207,19 +207,16 @@ InroomStairsWarp: {
|
|||||||
.normal
|
.normal
|
||||||
lda $01 : sta $fe ; trap door
|
lda $01 : sta $fe ; trap door
|
||||||
lda $07 : sta $03 : beq +
|
lda $07 : sta $03 : beq +
|
||||||
ldy $a0 : cpy #$51 : beq .specialFix ; throne room
|
lda $01 : and #$04 : bne .specialFix
|
||||||
cpy #$02 : beq .specialFix ; sewers pull switch
|
lda #$e0 : bra ++
|
||||||
cpy #$71 : beq .specialFix ; castle armory
|
|
||||||
lda #$e0
|
|
||||||
bra ++
|
|
||||||
.specialFix
|
.specialFix
|
||||||
lda #$c8
|
lda #$c8 : bra ++
|
||||||
bra ++
|
|
||||||
+
|
+
|
||||||
%StonewallCheck($43)
|
%StonewallCheck($43)
|
||||||
lda #$1b
|
lda $01 : and #$04 : bne +
|
||||||
++
|
lda #$1b : bra ++
|
||||||
sta $20
|
+ lda #$33
|
||||||
|
++ sta $20
|
||||||
inc $07 : stz $02 : lda #$78 : sta $22
|
inc $07 : stz $02 : lda #$78 : sta $22
|
||||||
lda $01 : and #$03 : beq ++
|
lda $01 : and #$03 : beq ++
|
||||||
cmp #$02 : !bge +
|
cmp #$02 : !bge +
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ DoDungeonMapBossIcon:
|
|||||||
|
|
||||||
; get dungeon boss room
|
; get dungeon boss room
|
||||||
++ REP #$30
|
++ REP #$30
|
||||||
LDA.l $8AE817,X
|
LDA.l DungeonMapBossRooms, X
|
||||||
ASL
|
ASL
|
||||||
TAX
|
TAX
|
||||||
|
|
||||||
|
|||||||
@@ -3,11 +3,11 @@
|
|||||||
; Blind Boss fight
|
; Blind Boss fight
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
|
||||||
org $1DA081 ; Original Code
|
org $9DA081 ; Original Code
|
||||||
JML check_blind_boss_room
|
JML check_blind_boss_room
|
||||||
Check_for_Blind_Fight:
|
Check_for_Blind_Fight:
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
org $1DA090
|
org $9DA090
|
||||||
Initialize_Blind_Fight:
|
Initialize_Blind_Fight:
|
||||||
10
goalitem.asm
10
goalitem.asm
@@ -46,6 +46,7 @@ CheckGanonVulnerability:
|
|||||||
dw .crystals_and_bosses
|
dw .crystals_and_bosses
|
||||||
dw .bosses_only
|
dw .bosses_only
|
||||||
dw .all_dungeons_no_agahnim
|
dw .all_dungeons_no_agahnim
|
||||||
|
dw .completionist
|
||||||
|
|
||||||
; 00 = always vulnerable
|
; 00 = always vulnerable
|
||||||
.vulnerable
|
.vulnerable
|
||||||
@@ -99,6 +100,15 @@ CheckGanonVulnerability:
|
|||||||
.bosses_only
|
.bosses_only
|
||||||
JMP CheckForCrystalBossesDefeated
|
JMP CheckForCrystalBossesDefeated
|
||||||
|
|
||||||
|
; 0a = Check Item counter
|
||||||
|
.completionist
|
||||||
|
REP #$20
|
||||||
|
LDA.l TotalItemCounter : CMP.l MaxItemCounter
|
||||||
|
SEP #$20
|
||||||
|
BCC .fail
|
||||||
|
BRA .all_dungeons
|
||||||
|
|
||||||
|
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
GetRequiredCrystalsForTower:
|
GetRequiredCrystalsForTower:
|
||||||
BEQ + : JSL.l BreakTowerSeal_ExecuteSparkles : + ; thing we wrote over
|
BEQ + : JSL.l BreakTowerSeal_ExecuteSparkles : + ; thing we wrote over
|
||||||
|
|||||||
18
hooks.asm
18
hooks.asm
@@ -2443,6 +2443,9 @@ NOP #6 ; remove check
|
|||||||
org $068841 ; <- 30841 - sprite_prep.asm:269 (LDA $0D00, X : ADD.b #$03 : STA $0D00, X)
|
org $068841 ; <- 30841 - sprite_prep.asm:269 (LDA $0D00, X : ADD.b #$03 : STA $0D00, X)
|
||||||
JSL.l Mantle_CorrectPosition : NOP #2
|
JSL.l Mantle_CorrectPosition : NOP #2
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
org $0297FD ; <- bank02 : Module07_19_MirrorFade (STZ.b $11 : STZ.b $14)
|
||||||
|
JSL MirrorScrollSpawnZelda
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
org $0DFA53 ; <- 6FA53 - hud check for lantern
|
org $0DFA53 ; <- 6FA53 - hud check for lantern
|
||||||
JSL.l LampCheck
|
JSL.l LampCheck
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
@@ -3047,3 +3050,18 @@ if !FEATURE_NEW_TEXT
|
|||||||
org $0EF285
|
org $0EF285
|
||||||
JSL RenderCharSetColorExtended_close : NOP
|
JSL RenderCharSetColorExtended_close : NOP
|
||||||
endif
|
endif
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
|
; Back of tavern fixes
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
|
org $028177 ; JSL Underworld_LoadCustomTileAttributes
|
||||||
|
JSL TurnAroundOnUnderworld
|
||||||
|
|
||||||
|
org $02ABC1 ; JSL Link_HandleMovingAnimation_FullLongEntry
|
||||||
|
JSL TurnUpOnOverworld
|
||||||
|
|
||||||
|
org $02E297 ; LDA.w #$0002 : STA.b $2F
|
||||||
|
JSL WalkUpOnOverworld
|
||||||
|
NOP
|
||||||
|
|
||||||
|
org $02D7D2 ; BEQ .face_up
|
||||||
|
NOP #2 ; this fixes Link's direction after mirroring and falling after entering through back of tavern
|
||||||
|
|||||||
@@ -1205,12 +1205,12 @@ RTL
|
|||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
; A = item id being collected
|
; A = item id being collected
|
||||||
ItemGetAlternateSFX:
|
ItemGetAlternateSFX:
|
||||||
PEA $C567 ; SNES to RTS to in bank 08
|
PEA.w $C567 ; SNES to RTS to in bank 08
|
||||||
LDA.w $0C5E,X : CMP #$4A : BNE +
|
LDA.w $0C5E,X : CMP.b #$4A : BNE +
|
||||||
; collecting pre-activated flute
|
; collecting pre-activated flute
|
||||||
LDA #$13 : JML $088007
|
LDA.b #$13 : JML $088007
|
||||||
+ ; normal itemget sfx
|
+ ; normal itemget sfx
|
||||||
LDA #$0F : JML $08800E ; what we wrote over
|
LDA.b #$0F : JML $08800E ; what we wrote over
|
||||||
|
|
||||||
; A = item id being collected
|
; A = item id being collected
|
||||||
ItemGetOverworldAlternateSFX:
|
ItemGetOverworldAlternateSFX:
|
||||||
|
|||||||
@@ -1,81 +1,88 @@
|
|||||||
; hooks
|
; hooks
|
||||||
org $01E6B0
|
org $81E6B0
|
||||||
JSL RevealPotItem
|
JSL RevealPotItem
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
org $09C2BB
|
org $829C25
|
||||||
|
JSL SetTheSceneFix
|
||||||
|
|
||||||
|
org $89C2BB
|
||||||
JSL ClearSpriteData
|
JSL ClearSpriteData
|
||||||
|
|
||||||
org $09C327
|
org $89C327
|
||||||
JSL LoadSpriteData
|
JSL LoadSpriteData
|
||||||
|
|
||||||
org $06F976
|
org $86F976
|
||||||
JSL RevealSpriteDrop : NOP
|
JSL RevealSpriteDrop : NOP
|
||||||
|
|
||||||
org $06E3C4
|
org $86E3C4
|
||||||
JSL RevealSpriteDrop2 : NOP
|
JSL RevealSpriteDrop2 : NOP
|
||||||
|
|
||||||
org $06926e ; <- 3126e - sprite_prep.asm : 2664 (LDA $0B9B : STA $0CBA, X)
|
org $86926e ; <- 3126e - sprite_prep.asm : 2664 (LDA $0B9B : STA $0CBA, X)
|
||||||
JSL SpriteKeyPrep : NOP #2
|
JSL SpriteKeyPrep : NOP #2
|
||||||
|
|
||||||
org $06d049 ; <- 35049 sprite_absorbable : 31-32 (JSL Sprite_DrawRippleIfInWater : JSR Sprite_DrawAbsorbable)
|
org $86d049 ; <- 35049 sprite_absorbable : 31-32 (JSL Sprite_DrawRippleIfInWater : JSR Sprite_DrawAbsorbable)
|
||||||
JSL SpriteKeyDrawGFX : BRA + : NOP : +
|
JSL SpriteKeyDrawGFX : BRA + : NOP : +
|
||||||
|
|
||||||
org $06d03d
|
org $86d03d
|
||||||
JSL ShouldSpawnItem : NOP #2
|
JSL ShouldSpawnItem : NOP #2
|
||||||
|
|
||||||
org $06D19F
|
org $86D19F
|
||||||
JSL MarkSRAMForItem : NOP #2
|
JSL MarkSRAMForItem : NOP #2
|
||||||
|
|
||||||
org $06d180
|
org $86d180
|
||||||
JSL BigKeyGet : BCS $07 : NOP #5
|
JSL BigKeyGet : BCS $07 : NOP #5
|
||||||
|
|
||||||
org $06d18d ; <- 3518D - sprite_absorbable.asm : 274 (LDA $7EF36F : INC A : STA $7EF36F)
|
org $86d18d ; <- 3518D - sprite_absorbable.asm : 274 (LDA $7EF36F : INC A : STA $7EF36F)
|
||||||
JSL KeyGet
|
JSL KeyGet
|
||||||
|
|
||||||
org $06f9f3 ; bank06.asm : 6732 (JSL Sprite_LoadProperties)
|
org $86f9f3 ; bank06.asm : 6732 (JSL Sprite_LoadProperties)
|
||||||
JSL LoadProperties_PreserveCertainProps
|
JSL LoadProperties_PreserveCertainProps
|
||||||
|
|
||||||
org $008BAA ; NMI hook
|
org $808BAA ; NMI hook
|
||||||
JSL TransferPotGFX
|
JSL TransferPotGFX
|
||||||
|
|
||||||
org $06828A
|
org $86828A
|
||||||
JSL CheckSprite_Spawn
|
JSL CheckSprite_Spawn
|
||||||
|
|
||||||
org $07B169
|
org $87B169
|
||||||
JSL PreventPotSpawn : NOP
|
JSL PreventPotSpawn : NOP
|
||||||
|
|
||||||
org $07B17D
|
org $87B17D
|
||||||
JSL PreventPotSpawn2
|
JSL PreventPotSpawn2
|
||||||
|
|
||||||
org $068275
|
org $868275
|
||||||
JSL SubstitionFlow
|
JSL SubstitionFlow
|
||||||
|
|
||||||
org $00A9DC
|
org $80A9DC
|
||||||
dw $1928, $1938, $5928, $5938 ; change weird ugly black diagonal pot to blue-ish pot
|
dw $1928, $1938, $5928, $5938 ; change weird ugly black diagonal pot to blue-ish pot
|
||||||
|
|
||||||
org $018650
|
org $818650
|
||||||
dw $B395 ; change tile type to normal pot
|
dw $B395 ; change tile type to normal pot
|
||||||
|
|
||||||
org $01B3D5
|
org $81B3D5
|
||||||
JSL CheckIfPotIsSpecial
|
JSL CheckIfPotIsSpecial
|
||||||
|
|
||||||
|
|
||||||
; refs to other functions
|
; refs to other functions
|
||||||
org $0681F4
|
org $8681F4
|
||||||
Sprite_SpawnSecret_pool_ID:
|
Sprite_SpawnSecret_pool_ID:
|
||||||
org $068283
|
org $868283
|
||||||
Sprite_SpawnSecret_NotRandomBush:
|
Sprite_SpawnSecret_NotRandomBush:
|
||||||
org $06828A
|
org $86828A
|
||||||
Sprite_SpawnSecret_SpriteSpawnDynamically:
|
Sprite_SpawnSecret_SpriteSpawnDynamically:
|
||||||
org $06d23a
|
org $86d23a
|
||||||
Sprite_DrawAbsorbable:
|
Sprite_DrawAbsorbable:
|
||||||
org $1eff81
|
org $9eff81
|
||||||
Sprite_DrawRippleIfInWater:
|
Sprite_DrawRippleIfInWater:
|
||||||
org $0db818
|
org $8db818
|
||||||
Sprite_LoadProperties:
|
Sprite_LoadProperties:
|
||||||
org $06D038
|
org $86D038
|
||||||
KeyRoomFlagMasks:
|
KeyRoomFlagMasks:
|
||||||
|
org $80FDEE
|
||||||
|
InitializeMirrorHDMA:
|
||||||
|
org $80E3C4
|
||||||
|
LoadCommonSprites_long:
|
||||||
|
|
||||||
; defines
|
; defines
|
||||||
; Ram usage
|
; Ram usage
|
||||||
@@ -591,6 +598,11 @@ CheckIfPotIsSpecial:
|
|||||||
.specialpot ; zero flag already set, so gtg
|
.specialpot ; zero flag already set, so gtg
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
|
SetTheSceneFix:
|
||||||
|
STZ.b $6C
|
||||||
|
JSL InitializeMirrorHDMA
|
||||||
|
JSL LoadCommonSprites_long
|
||||||
|
RTL
|
||||||
|
|
||||||
incsrc dynamic_si_vram.asm
|
incsrc dynamic_si_vram.asm
|
||||||
|
|
||||||
|
|||||||
@@ -1,181 +0,0 @@
|
|||||||
org $06926e ; <- 3126e - sprite_prep.asm : 2664 (LDA $0B9B : STA $0CBA, X)
|
|
||||||
jsl SpriteKeyPrep : nop #2
|
|
||||||
|
|
||||||
org $06d049 ; <- 35049 sprite_absorbable : 31-32 (JSL Sprite_DrawRippleIfInWater : JSR Sprite_DrawAbsorbable)
|
|
||||||
jsl SpriteKeyDrawGFX : bra + : nop : +
|
|
||||||
|
|
||||||
org $06d180
|
|
||||||
jsl BigKeyGet : bcs $07 : nop #5
|
|
||||||
|
|
||||||
org $06d18d ; <- 3518D - sprite_absorbable.asm : 274 (LDA $7EF36F : INC A : STA $7EF36F)
|
|
||||||
jsl KeyGet
|
|
||||||
|
|
||||||
org $06f9f3 ; bank06.asm : 6732 (JSL Sprite_LoadProperties)
|
|
||||||
jsl LoadProperties_PreserveItemMaybe
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
org $06d23a
|
|
||||||
Sprite_DrawAbsorbable:
|
|
||||||
org $1eff81
|
|
||||||
Sprite_DrawRippleIfInWater:
|
|
||||||
org $0db818
|
|
||||||
Sprite_LoadProperties:
|
|
||||||
|
|
||||||
org $288000 ;140000
|
|
||||||
ShuffleKeyDrops:
|
|
||||||
db 0
|
|
||||||
MultiClientFlagsROM: ; 140001 -> stored in SRAM at 7ef33d
|
|
||||||
db 0
|
|
||||||
|
|
||||||
LootTable: ;PC: 140002
|
|
||||||
db $0e, $00, $24 ;; ice jelly key
|
|
||||||
db $13, $00, $24 ;; pokey 2
|
|
||||||
db $16, $00, $24 ;; swamp waterway pot
|
|
||||||
db $21, $00, $24 ;; key rat
|
|
||||||
db $35, $00, $24 ;; swamp trench 2 pot
|
|
||||||
db $36, $00, $24 ;; hookshot pot
|
|
||||||
db $37, $00, $24 ;; trench 1 pot
|
|
||||||
db $38, $00, $24 ;; pot row pot
|
|
||||||
db $39, $00, $24 ;; skull gibdo
|
|
||||||
db $3d, $00, $24 ;; gt minihelma
|
|
||||||
db $3e, $00, $24 ;; ice conveyor
|
|
||||||
db $3f, $00, $24 ;; ice hammer block ??? is this a dungeon secret?
|
|
||||||
db $43, $00, $24 ;; tiles 2 pot
|
|
||||||
db $53, $00, $24 ;; beamos hall pot
|
|
||||||
db $56, $00, $24 ;; skull west lobby pot
|
|
||||||
db $63, $00, $24 ;; desert tiles 1 pot
|
|
||||||
db $71, $00, $24 ;; boomerang guard
|
|
||||||
db $72, $00, $24 ;; hc map guard
|
|
||||||
db $7b, $00, $24 ;; gt star pits pot
|
|
||||||
db $80, $00, $32 ;; a big key (for the current dungeon)
|
|
||||||
db $8b, $00, $24 ;; gt conv cross block
|
|
||||||
db $9b, $00, $24 ;; gt dlb switch pot
|
|
||||||
db $9f, $00, $24 ;; ice many pots
|
|
||||||
db $99, $00, $24 ;; eastern eyegore
|
|
||||||
db $a1, $00, $24 ;; mire fishbone pot
|
|
||||||
db $ab, $00, $24 ;; tt spike switch pot
|
|
||||||
db $b0, $00, $24 ;; tower circle of pots usain
|
|
||||||
db $b3, $00, $24 ;; mire spikes pot
|
|
||||||
db $b6, $00, $24 ;; pokey 1
|
|
||||||
db $ba, $00, $24 ;; eastern dark pot
|
|
||||||
db $bc, $00, $24 ;; tt hallway pot
|
|
||||||
db $c0, $00, $24 ;; tower dark archer
|
|
||||||
db $c1, $00, $24 ;; mire glitchy jelly
|
|
||||||
db $ff, $00, $ff
|
|
||||||
;140068
|
|
||||||
|
|
||||||
KeyTable:
|
|
||||||
db $a0, $a0, $a2, $a3, $a4, $a5, $a6, $a7, $a8, $a9, $aa, $ab, $ac, $ad
|
|
||||||
|
|
||||||
SpriteKeyPrep:
|
|
||||||
{
|
|
||||||
lda $0b9b : sta $0cba, x ; what we wrote over
|
|
||||||
pha
|
|
||||||
lda.l ShuffleKeyDrops : beq +
|
|
||||||
phx
|
|
||||||
ldx #$fd
|
|
||||||
- inx #3 : lda.l LootTable, x : cmp #$ff : beq ++ : cmp $a0 : bne -
|
|
||||||
inx : lda.l LootTable, x : sta !MULTIWORLD_SPRITEITEM_PLAYER_ID
|
|
||||||
inx : lda.l LootTable, x
|
|
||||||
plx : sta $0e80, x
|
|
||||||
cmp #$24 : bne +++
|
|
||||||
lda $a0 : cmp #$80 : bne + : lda #$24
|
|
||||||
+++ jsl PrepDynamicTile : bra +
|
|
||||||
++ plx : lda #$24 : sta $0e80, x
|
|
||||||
+ pla
|
|
||||||
rtl
|
|
||||||
}
|
|
||||||
|
|
||||||
SpriteKeyDrawGFX:
|
|
||||||
{
|
|
||||||
jsl Sprite_DrawRippleIfInWater
|
|
||||||
pha
|
|
||||||
lda.l ShuffleKeyDrops : bne +
|
|
||||||
- pla
|
|
||||||
phk : pea.w .jslrtsreturn-1
|
|
||||||
pea.w $068014 ; an rtl address - 1 in Bank06
|
|
||||||
jml Sprite_DrawAbsorbable
|
|
||||||
.jslrtsreturn
|
|
||||||
rtl
|
|
||||||
+ lda $0e80, x
|
|
||||||
cmp #$24 : bne +
|
|
||||||
lda $a0 : cmp #$80 : bne - : lda #$24
|
|
||||||
+ jsl DrawDynamicTile ; see DrawHeartPieceGFX if problems
|
|
||||||
cmp #$03 : bne +
|
|
||||||
pha : lda $0e60, x : ora.b #$20 : sta $0E60, x : pla
|
|
||||||
+
|
|
||||||
jsl.l Sprite_DrawShadowLong
|
|
||||||
|
|
||||||
pla : rtl
|
|
||||||
}
|
|
||||||
|
|
||||||
KeyGet:
|
|
||||||
{
|
|
||||||
lda CurrentSmallKeys ; what we wrote over
|
|
||||||
pha
|
|
||||||
lda.l ShuffleKeyDrops : bne +
|
|
||||||
- pla : rtl
|
|
||||||
+ ldy $0e80, x
|
|
||||||
lda $a0 : cmp #$87 : bne +
|
|
||||||
jsr ShouldKeyBeCountedForDungeon : bcc -
|
|
||||||
jsl CountChestKeyLong : bra -
|
|
||||||
+ sty $00
|
|
||||||
jsr KeyGetPlayer : sta !MULTIWORLD_ITEM_PLAYER_ID
|
|
||||||
lda !MULTIWORLD_ITEM_PLAYER_ID : bne .receive
|
|
||||||
phx
|
|
||||||
lda $040c : lsr : tax
|
|
||||||
lda $00 : CMP.l KeyTable, x : bne +
|
|
||||||
- JSL.l FullInventoryExternal : jsl CountChestKeyLong : plx : pla : rtl
|
|
||||||
+ cmp #$af : beq - ; universal key
|
|
||||||
cmp #$24 : beq - ; small key for this dungeon
|
|
||||||
plx
|
|
||||||
.receive
|
|
||||||
jsl.l $0791b3 ; Player_HaltDashAttackLong
|
|
||||||
jsl.l Link_ReceiveItem
|
|
||||||
pla : dec : rtl
|
|
||||||
}
|
|
||||||
|
|
||||||
; Input Y - the item type
|
|
||||||
ShouldKeyBeCountedForDungeon:
|
|
||||||
{
|
|
||||||
phx
|
|
||||||
lda $040c : lsr : tax
|
|
||||||
tya : cmp KeyTable, x : bne +
|
|
||||||
- plx : sec : rts
|
|
||||||
+ cmp #$24 : beq -
|
|
||||||
plx : clc : rts
|
|
||||||
}
|
|
||||||
|
|
||||||
BigKeyGet:
|
|
||||||
{
|
|
||||||
lda.l ShuffleKeyDrops : bne +
|
|
||||||
- stz $02e9 : ldy.b #$32 ; what we wrote over
|
|
||||||
phx : jsl Link_ReceiveItem : plx ; what we wrote over
|
|
||||||
clc : rtl
|
|
||||||
+
|
|
||||||
ldy $0e80, x
|
|
||||||
cpy #$32 : beq -
|
|
||||||
+ sec : rtl
|
|
||||||
}
|
|
||||||
|
|
||||||
KeyGetPlayer:
|
|
||||||
{
|
|
||||||
phx
|
|
||||||
ldx #$fd
|
|
||||||
- inx #3 : lda.l LootTable, x : cmp #$ff : beq ++ : cmp $a0 : bne -
|
|
||||||
++ inx : lda.l LootTable, x
|
|
||||||
plx
|
|
||||||
rts
|
|
||||||
}
|
|
||||||
|
|
||||||
LoadProperties_PreserveItemMaybe:
|
|
||||||
{
|
|
||||||
lda.l ShuffleKeyDrops : bne +
|
|
||||||
JML Sprite_LoadProperties
|
|
||||||
+ lda $0e80, x : pha
|
|
||||||
jsl Sprite_LoadProperties
|
|
||||||
pla : sta $0e80, x
|
|
||||||
rtl
|
|
||||||
}
|
|
||||||
@@ -8,16 +8,13 @@ LampCheck:
|
|||||||
CMP.b #$FF : BNE + : INC : RTL : +
|
CMP.b #$FF : BNE + : INC : RTL : +
|
||||||
|
|
||||||
LDA LampEquipment : BNE .done ; skip if we already have lantern
|
LDA LampEquipment : BNE .done ; skip if we already have lantern
|
||||||
|
|
||||||
LDA CurrentWorld : BNE +
|
LDA $040C : CMP.b #$FF : BEQ +
|
||||||
.lightWorld
|
CMP.b #$04 : BCS + ; check if we're in HC
|
||||||
LDA $040C : BNE ++ ; check if we're in sewers
|
|
||||||
LDA LampConeSewers : BRA .done
|
LDA LampConeSewers : BRA .done
|
||||||
++
|
+ LDA CurrentWorld : BNE +
|
||||||
LDA LampConeLightWorld : BRA .done
|
LDA LampConeLightWorld : BRA .done
|
||||||
+
|
+ LDA LampConeDarkWorld
|
||||||
.darkWorld
|
|
||||||
LDA LampConeDarkWorld
|
|
||||||
.done
|
.done
|
||||||
;BNE + : STZ $1D : + ; remember to turn cone off after a torch
|
;BNE + : STZ $1D : + ; remember to turn cone off after a torch
|
||||||
RTL
|
RTL
|
||||||
|
|||||||
12
mantle.asm
12
mantle.asm
@@ -2,7 +2,9 @@
|
|||||||
; Mantle Object Changes
|
; Mantle Object Changes
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
Mantle_CorrectPosition:
|
Mantle_CorrectPosition:
|
||||||
LDA ProgressFlags : AND.b #$04 : BEQ +
|
LDA.l ProgressFlags : AND.b #$04 : BNE .spawnOpen
|
||||||
|
LDA.l StartingEntrance : CMP.b #$04 : BNE +
|
||||||
|
.spawnOpen
|
||||||
LDA.b #$0A : STA $0D10, X ; just spawn it off to the side where we know it should be
|
LDA.b #$0A : STA $0D10, X ; just spawn it off to the side where we know it should be
|
||||||
LDA.b #$03 : STA $0D30, X
|
LDA.b #$03 : STA $0D30, X
|
||||||
LDA.b #$90 : STA $0ED0, X
|
LDA.b #$90 : STA $0ED0, X
|
||||||
@@ -10,3 +12,11 @@ Mantle_CorrectPosition:
|
|||||||
LDA $0D00, X : !ADD.b #$03 ; thing we did originally
|
LDA $0D00, X : !ADD.b #$03 ; thing we did originally
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
MirrorScrollSpawnZelda:
|
||||||
|
LDA.l MirrorEquipment : CMP.b #$01 : BNE + ;mirror scroll
|
||||||
|
LDA.l StartingEntrance : CMP.b #$02 : BEQ ++ ; zelda's cell
|
||||||
|
CMP.b #$04 : BNE +
|
||||||
|
++ INC $04AA
|
||||||
|
; what we replaced
|
||||||
|
+ STZ.b $11 : STZ.b $14
|
||||||
|
RTL
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
!MC_FLAG = "$7F5420"
|
!MC_FLAG = "$7F5420"
|
||||||
|
|
||||||
; tables
|
; tables
|
||||||
org $0ABDF6
|
org $8ABDF6
|
||||||
WorldMapIcon_posx_vanilla:
|
WorldMapIcon_posx_vanilla:
|
||||||
dw $0F31 ; prize1
|
dw $0F31 ; prize1
|
||||||
dw $08D0 ; prize2
|
dw $08D0 ; prize2
|
||||||
@@ -24,7 +24,7 @@ dw $FFFF ; reserved - not used
|
|||||||
dw $FFFF
|
dw $FFFF
|
||||||
dw $FFFF
|
dw $FFFF
|
||||||
|
|
||||||
org $0ABE16
|
org $8ABE16
|
||||||
WorldMapIcon_posy_vanilla:
|
WorldMapIcon_posy_vanilla:
|
||||||
dw $0620 ; prize1
|
dw $0620 ; prize1
|
||||||
dw $0080 ; prize2
|
dw $0080 ; prize2
|
||||||
@@ -46,7 +46,7 @@ dw $FFFF ; reserved - not used
|
|||||||
dw $FFFF
|
dw $FFFF
|
||||||
dw $FFFF
|
dw $FFFF
|
||||||
|
|
||||||
org $0ABE36
|
org $8ABE36
|
||||||
WorldMapIcon_posx_located:
|
WorldMapIcon_posx_located:
|
||||||
dw $FF00 ; prize1
|
dw $FF00 ; prize1
|
||||||
dw $FF00 ; prize2
|
dw $FF00 ; prize2
|
||||||
@@ -68,7 +68,7 @@ dw $FFFF ; reserved - not used
|
|||||||
dw $FFFF
|
dw $FFFF
|
||||||
dw $FFFF
|
dw $FFFF
|
||||||
|
|
||||||
org $0ABE56
|
org $8ABE56
|
||||||
WorldMapIcon_posy_located:
|
WorldMapIcon_posy_located:
|
||||||
dw $FF00 ; prize1
|
dw $FF00 ; prize1
|
||||||
dw $FF00 ; prize2
|
dw $FF00 ; prize2
|
||||||
@@ -90,7 +90,7 @@ dw $FFFF ; reserved - not used
|
|||||||
dw $FFFF
|
dw $FFFF
|
||||||
dw $FFFF
|
dw $FFFF
|
||||||
|
|
||||||
org $0ABE76
|
org $8ABE76
|
||||||
WorldMapIcon_tile:
|
WorldMapIcon_tile:
|
||||||
db $38, $62 ; green pendant
|
db $38, $62 ; green pendant
|
||||||
db $32, $60 ; red pendant
|
db $32, $60 ; red pendant
|
||||||
@@ -112,30 +112,30 @@ db $00, $00 ; unused red x's
|
|||||||
db $00, $00
|
db $00, $00
|
||||||
db $00, $00
|
db $00, $00
|
||||||
|
|
||||||
org $0ABE96
|
org $8ABE96
|
||||||
CompassExists:
|
CompassExists:
|
||||||
; dw $37FC ; todo: convert to two bytes with masks? so much extra code...
|
; dw $37FC ; todo: convert to two bytes with masks? so much extra code...
|
||||||
; eastern hera desert pod skull trock thieves mire ice swamp gt at escape
|
; eastern hera desert pod skull trock thieves mire ice swamp gt at escape
|
||||||
db $01, $01, $01, $01, $01, $01, $01, $01, $01, $01, $01, $00, $00, $00, $00, $00
|
db $01, $01, $01, $01, $01, $01, $01, $01, $01, $01, $01, $00, $00, $00, $00, $00
|
||||||
|
|
||||||
; 0 = light world, 1 = dark world
|
; 0 = light world, 1 = dark world
|
||||||
org $0ABEA6
|
org $8ABEA6
|
||||||
WorldCompassMask:
|
WorldCompassMask:
|
||||||
db $00, $00, $00, $01, $01, $01, $01, $01, $01, $01, $01, $00, $00, $00, $00, $00
|
db $00, $00, $00, $01, $01, $01, $01, $01, $01, $01, $01, $00, $00, $00, $00, $00
|
||||||
|
|
||||||
; eastern desert hera pod skull trock thieves mire ice swamp gt at escape x1 x2 x3
|
; eastern desert hera pod skull trock thieves mire ice swamp gt at escape x1 x2 x3
|
||||||
|
|
||||||
; refs
|
; refs
|
||||||
org $0AC59B
|
org $8AC59B
|
||||||
WorldMapIcon_AdjustCoordinate:
|
WorldMapIcon_AdjustCoordinate:
|
||||||
org $0AC3B1
|
org $8AC3B1
|
||||||
WorldMap_CalculateOAMCoordinates:
|
WorldMap_CalculateOAMCoordinates:
|
||||||
org $0AC52E
|
org $8AC52E
|
||||||
WorldMap_HandleSpriteBlink:
|
WorldMap_HandleSpriteBlink:
|
||||||
org $0ABF70
|
org $8ABF70
|
||||||
WorldMap_RedXChars:
|
WorldMap_RedXChars:
|
||||||
|
|
||||||
org $0AC02B
|
org $8AC02B
|
||||||
DrawPrizesOverride:
|
DrawPrizesOverride:
|
||||||
LDX.b #$FF
|
LDX.b #$FF
|
||||||
.loopStart
|
.loopStart
|
||||||
@@ -297,4 +297,4 @@ MC_Masks:
|
|||||||
; EP TH DP PD SK TR TT MM
|
; EP TH DP PD SK TR TT MM
|
||||||
db $20, $20, $10, $02, $80, $08, $10, $01, $40, $04, $04, $08, $40
|
db $20, $20, $10, $02, $80, $08, $10, $01, $40, $04, $04, $08, $40
|
||||||
|
|
||||||
warnpc $0AC3B1 ; above code should not exceed the space of the code segment it is overwriting
|
warnpc $8AC3B1 ; above code should not exceed the space of the code segment it is overwriting
|
||||||
@@ -995,6 +995,11 @@ dw #$0000, #$0000
|
|||||||
org $09E3BB ; PC 0x4E3BB
|
org $09E3BB ; PC 0x4E3BB
|
||||||
db $E4 ; Hera Basement Key (Set to programmable HP $EB) (set to $E4 for original hookable/boomable key behavior)
|
db $E4 ; Hera Basement Key (Set to programmable HP $EB) (set to $E4 for original hookable/boomable key behavior)
|
||||||
;================================================================================
|
;================================================================================
|
||||||
|
org $02D7D0 ; PC 0x157D0
|
||||||
|
EntranceTavernBack:
|
||||||
|
dw $0043 ; Overworld door that leads to back of tavern (update this when this entrance is shuffled)
|
||||||
|
; Note: If shuffled, the overworld door on the north side of the tavern is expected to have a Y coordinate of $091B in the exit data (table at $02DDB5)
|
||||||
|
;================================================================================
|
||||||
org $308210 ; PC 0x180210
|
org $308210 ; PC 0x180210
|
||||||
RandomizerSeedType:
|
RandomizerSeedType:
|
||||||
db #$00 ; #$00 = Casual (default) - #$01 = Glitched - #$02 = Speedrunner - #$A0 = Super Metroid Combo - #$FF = Not Randomizer
|
db #$00 ; #$00 = Casual (default) - #$01 = Glitched - #$02 = Speedrunner - #$A0 = Super Metroid Combo - #$FF = Not Randomizer
|
||||||
@@ -1944,3 +1949,7 @@ db $08, $08, $06, $06, $02, $0A, $0E, $08, $08, $08, $06, $08, $0C, $1B, $00, $0
|
|||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
; 0x187010 - 187FFF (unused)
|
; 0x187010 - 187FFF (unused)
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
org $30F010
|
||||||
|
MaxItemCounter:
|
||||||
|
dw $00D8 ; 216 default
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user