Disable player input during cutscenes

This commit is contained in:
scawful
2023-08-01 10:26:32 -04:00
parent 75d16817cb
commit 186f9aa33a
2 changed files with 21 additions and 1 deletions

View File

@@ -97,6 +97,7 @@ Sprite_Kydrog_Main:
Kydrog_AttractPlayer: Kydrog_AttractPlayer:
{ {
LDA.w SprTimerA, X : BNE + LDA.w SprTimerA, X : BNE +
LDA #$00 : STA $7EF303
%ShowUnconditionalMessage($21) %ShowUnconditionalMessage($21)
%GotoAction(2) %GotoAction(2)
+ +

View File

@@ -3,6 +3,23 @@
; ;
;============================================================================== ;==============================================================================
InCutScene = $7EF303
org $0083F8
LDA InCutScene : BEQ .notInCutscene
STZ $F0
STZ $F2
STZ $F4
STZ $F6
STZ $F8
STZ $FA ; kill all input
.notInCutscene
RTS
warnpc $00841E
incsrc sprite_macros.asm incsrc sprite_macros.asm
incsrc sprite_functions_hooks.asm incsrc sprite_functions_hooks.asm
@@ -111,6 +128,7 @@ Sprite_Farore_Main:
; 00 ; 00
IntroStart: IntroStart:
{ {
LDA #$01 : STA InCutScene
LDA $B6 : CMP.b #$01 : BEQ .maku_area LDA $B6 : CMP.b #$01 : BEQ .maku_area
CMP.b #$02 : BEQ .waiting CMP.b #$02 : BEQ .waiting
@@ -173,6 +191,7 @@ Sprite_Farore_Main:
LDA.w SprTimerA, X : BNE + LDA.w SprTimerA, X : BNE +
STZ $2F STZ $2F
LDA #$00 : STA InCutScene
%ShowUnconditionalMessage($0E) ; "I am Farore, the Oracle of Secrets." %ShowUnconditionalMessage($0E) ; "I am Farore, the Oracle of Secrets."
%GotoAction(4) %GotoAction(4)
@@ -197,6 +216,7 @@ Sprite_Farore_Main:
; 05 ; 05
FaroreFollowPlayer: FaroreFollowPlayer:
{ {
LDA #$01 : STA InCutScene
LDA WALKSPEED : STA.b $57 ; Slow Link down for the cutscene LDA WALKSPEED : STA.b $57 ; Slow Link down for the cutscene
LDA.b #$08 : STA.b $49 ; Auto-movement north LDA.b #$08 : STA.b $49 ; Auto-movement north
%PlayAnimation(3, 4, 8) %PlayAnimation(3, 4, 8)
@@ -239,7 +259,6 @@ Sprite_Farore_Main:
{ {
%PlayAnimation(5, 5, 8) %PlayAnimation(5, 5, 8)
RTS RTS
} }