GT in Kakariko music fix

This fixes music stopping partway up GT when
the player encounters a "PsychoSoldier" (MathOnNapkin's name). Both types
of this sprite sharethe same audio code. They have code to play special
music if chasing link in Kakariko. That is fine in vanilla or item
rando, but if they try to play this music in a dungeon located in
kakariko, this will cause the music to just stop, because that song is
not avaiulable in the dungeon music bank.

This patch fixes this by adding an extra check to make sure we are in
the overworld before playing this song.
This commit is contained in:
Kevin Cathcart
2017-12-16 14:57:45 -05:00
parent bf2b119748
commit 55473a4d01
2 changed files with 14 additions and 0 deletions

View File

@@ -1950,6 +1950,10 @@ org $0282F4 ; <- Bank02.asm:654 (LDY.b #$58 ...)
JML.l PreOverworld_LoadProperties_ChooseMusic
org $028389 ; <- Bank02.asm:763
PreOverworld_LoadProperties_SetSong:
;--------------------------------------------------------------------------------
org $05CC58 ; <- Bank05.asm:1307 (LDA $040A : CMP.b #$18)
JSL PsychoSolder_MusicCheck
NOP #1
;================================================================================
;================================================================================

View File

@@ -77,3 +77,13 @@ PreOverworld_LoadProperties_ChooseMusic:
JML.l PreOverworld_LoadProperties_SetSong
;--------------------------------------------------------------------------------
;--------------------------------------------------------------------------------
;0 = Is Kakariko Overworld
;1 = Not Kakariko Overworld
PsychoSolder_MusicCheck:
LDA $040A : CMP.b #$18 : BNE .done ; thing we overwrote - check if overworld location is Kakariko
LDA $1B ; Also check that we are outdoors
.done
RTL
;--------------------------------------------------------------------------------