Merge branch 'main' into kara
This commit is contained in:
@@ -4,22 +4,13 @@
|
||||
; Output: 0 for darkness, 1 for lamp cone
|
||||
;--------------------------------------------------------------------------------
|
||||
LampCheck:
|
||||
LDA LightConeModifier : 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 : BNE ++ ; check if we're in sewers
|
||||
LDA LampConeSewers : BRA .done
|
||||
++
|
||||
LDA LampConeLightWorld : BRA .done
|
||||
+
|
||||
.darkWorld
|
||||
LDA LampConeDarkWorld
|
||||
.done
|
||||
;BNE + : STZ $1D : + ; remember to turn cone off after a torch
|
||||
LDA.l LightConeModifier : CMP.b #$01 : BNE + : RTL : +
|
||||
CMP.b #$FF : BNE + : INC : RTL : +
|
||||
LDA.l LampEquipment : BNE .lamp ; skip if we already have lantern
|
||||
LDA.w DungeonID : BNE + ; check if we're in sewers
|
||||
LDA.l LampConeSewers : RTL
|
||||
+ : TDC
|
||||
.lamp
|
||||
RTL
|
||||
;================================================================================
|
||||
;--------------------------------------------------------------------------------
|
||||
@@ -30,13 +21,22 @@ CheckForZelda:
|
||||
LDA.b #$01 ; pretend we have zelda anyway
|
||||
RTL
|
||||
+
|
||||
LDA FollowerIndicator
|
||||
LDA.l FollowerIndicator
|
||||
RTL
|
||||
;================================================================================
|
||||
;--------------------------------------------------------------------------------
|
||||
SetOverlayIfLamp:
|
||||
JSL.l LampCheck
|
||||
STA $1D ; write it directly to the overlay, this isn't a terrible idea at all
|
||||
STA.b SUBDESQ ; write it directly to the overlay, this isn't a terrible idea at all
|
||||
RTL
|
||||
;================================================================================
|
||||
;LDA CurrentWorld : EOR #$40 : LSR #6 : AND #$01 ; return the same result as having the lantern in the light world
|
||||
; Mantle Object Changes
|
||||
;--------------------------------------------------------------------------------
|
||||
Mantle_CorrectPosition:
|
||||
LDA.l ProgressFlags : AND.b #$04 : BEQ +
|
||||
LDA.b #$0A : STA.w SpritePosXLow, X ; just spawn it off to the side where we know it should be
|
||||
LDA.b #$03 : STA.w SpritePosXHigh, X
|
||||
LDA.b #$90 : STA.w SpriteSpawnStep, X
|
||||
+
|
||||
LDA.w SpritePosYLow, X : !ADD.b #$03 ; thing we did originally
|
||||
RTL
|
||||
;--------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user