remove bad deku flower check code

This commit is contained in:
scawful
2024-06-08 08:53:26 -04:00
parent 27a14ccaf9
commit abb26b4e11

View File

@@ -345,50 +345,31 @@ org $0DA3FD
JML DekuLink_SpinOrRecoil JML DekuLink_SpinOrRecoil
pullpc pullpc
CheckDekuFlowerPresence: PrepareMagicBubble:
{ {
REP #$20 #_07A049: LDA.b $20
PHX #_07A04B: STA.b $72
CLC ; Assume sprite ID $B0 is not present
LDX.b #$10
.x_loop
DEX
LDY.b #$04 #_07A04D: LDA.b $21
.y_loop #_07A04F: STA.b $73
DEY
LDA.w $0E20, X : AND.w #$00FF : CMP.w #$00C0 : BEQ .set_flag
BRA .not_b0
.set_flag #_07A051: LDA.b $22
SEC ; Set flag indicating sprite ID $B0 is present #_07A053: STA.b $74
STX.w $02
BRA .done
.not_b0 #_07A055: LDA.b $23
CPY.b #$00 : BNE .y_loop #_07A057: STA.b $75
CPX.b #$00 : BNE .x_loop
.done #_07A059: LDX.b $2F
PLX
SEP #$20 #_07A05B: LDY.b #$02
RTS #_07A05D: LDA.b #$09 ; ANCILLA 09
#_07A05F: JSL $0990A4 ; AncillaAdd_Arrow
RTL
} }
; Based on LinkItem_Quake.allow_quake ; Based on LinkItem_Quake.allow_quake
PrepareQuakeSpell: PrepareQuakeSpell:
{ {
; Find out if the sprite $C0 is in the room
JSR CheckDekuFlowerPresence : BCC .no_c0
PHX : LDA $02 : TAX
JSL Link_SetupHitBox
; X is now the ID of the sprite $B0
JSL Sprite_SetupHitBox
PLX
JSL CheckIfHitBoxesOverlap : BCC .no_c0
LDA.b #$0A : STA.b $5D ; Set Link to the hover state LDA.b #$0A : STA.b $5D ; Set Link to the hover state
LDA.b #$00 : STA.b $3D ; Clear the animation timer LDA.b #$00 : STA.b $3D ; Clear the animation timer
@@ -403,7 +384,7 @@ PrepareQuakeSpell:
STZ.w $0364 ; Clear Z-coordinate for the jump STZ.w $0364 ; Clear Z-coordinate for the jump
STZ $70 ; Clear bomb drop check flag STZ $70 ; Clear bomb drop check flag
.no_c0
RTL RTL
} }