Disallow Minish form during intro
This commit is contained in:
@@ -27,43 +27,40 @@ pullpc
|
|||||||
LinkState_CheckForMinishForm:
|
LinkState_CheckForMinishForm:
|
||||||
{
|
{
|
||||||
SEP #$30
|
SEP #$30
|
||||||
|
LDA.l GAMESTATE : BEQ .return
|
||||||
|
JSL $0FF979 ; AncillaSpawn_SwordChargeSparkle
|
||||||
|
|
||||||
JSL $0FF979 ; AncillaSpawn_SwordChargeSparkle
|
; Check for the R button (like minish cap)
|
||||||
|
JSL CheckNewRButtonPress : BCC .return
|
||||||
|
|
||||||
; Check for the R button (like minish cap)
|
; Skip the code if you have a mask item out
|
||||||
JSL CheckNewRButtonPress : BCC .return
|
LDA $0202
|
||||||
|
|
||||||
; Skip the code if you have a mask item out
|
; Check if the value in A (from $0202) is LT $13.
|
||||||
LDA $0202
|
CMP.b #$13 : BCC .continue
|
||||||
|
|
||||||
; Check if the value in A (from $0202) is LT $13.
|
; Check if the value in A (from $0202) is GTE to $16.
|
||||||
CMP.b #$13 : BCC .continue
|
CMP.b #$17 : BCS .continue
|
||||||
|
LDA.b #$3C : STA.w $012E ; Error beep
|
||||||
|
JMP .return
|
||||||
|
.continue
|
||||||
|
|
||||||
; Check if the value in A (from $0202) is GTE to $16.
|
LDA !CurrentMask
|
||||||
CMP.b #$17 : BCS .continue
|
CMP.b #$05 : BEQ .already_minish ; return to human form
|
||||||
|
CMP.b #$00 : BEQ .transform
|
||||||
|
CMP.b #$06 : BCC .return ; don't transform if not human
|
||||||
|
.transform
|
||||||
|
%PlayerTransform()
|
||||||
|
|
||||||
LDA.b #$3C : STA.w $012E ; Error beep
|
LDA #$39 : STA $BC ; Change link's sprite
|
||||||
JMP .return
|
LDA #$05 : STA $02B2 ; Set the current mask form
|
||||||
|
BRA .return
|
||||||
|
|
||||||
.continue
|
.already_minish
|
||||||
|
%PlayerTransform()
|
||||||
LDA !CurrentMask
|
%ResetToLinkGraphics()
|
||||||
CMP.b #$05 : BEQ .already_minish ; return to human form
|
|
||||||
CMP.b #$00 : BEQ .transform
|
|
||||||
CMP.b #$06 : BCC .return ; don't transform if not human
|
|
||||||
.transform
|
|
||||||
%PlayerTransform()
|
|
||||||
|
|
||||||
LDA #$39 : STA $BC ; Change link's sprite
|
|
||||||
LDA #$05 : STA $02B2 ; Set the current mask form
|
|
||||||
BRA .return
|
|
||||||
|
|
||||||
.already_minish
|
|
||||||
%PlayerTransform()
|
|
||||||
%ResetToLinkGraphics()
|
|
||||||
|
|
||||||
.return
|
|
||||||
|
|
||||||
|
.return
|
||||||
REP #$30
|
REP #$30
|
||||||
RTS
|
RTS
|
||||||
}
|
}
|
||||||
@@ -72,16 +69,16 @@ LinkState_CheckForMinishForm:
|
|||||||
|
|
||||||
LinkState_CheckMinishTile:
|
LinkState_CheckMinishTile:
|
||||||
{
|
{
|
||||||
LDA $02B2 : BEQ .blocked ; no form
|
LDA $02B2 : BEQ .blocked ; no form
|
||||||
CMP.w #$0007 : BEQ .allowed ; moosh can fly over
|
CMP.w #$0007 : BEQ .allowed ; moosh can fly over
|
||||||
CMP.w #$0005 : BNE .blocked ; not minish
|
CMP.w #$0005 : BNE .blocked ; not minish
|
||||||
.allowed
|
.allowed
|
||||||
LDA $0A : TSB $0343
|
LDA $0A : TSB $0343
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.blocked
|
.blocked
|
||||||
LDA $0A : TSB $0E ; Blocked
|
LDA $0A : TSB $0E ; Blocked
|
||||||
RTS
|
RTS
|
||||||
}
|
}
|
||||||
|
|
||||||
; Prevent lifting while minish
|
; Prevent lifting while minish
|
||||||
|
|||||||
Reference in New Issue
Block a user