Adds Chest Key counters to $7EF4E0-F

This commit is contained in:
aerinon
2020-08-25 12:05:49 -06:00
committed by aerinon
parent af7cce9ae5
commit f565fc93be
3 changed files with 42 additions and 4 deletions

View File

@@ -2,6 +2,12 @@
; Item Downgrade Fix
;--------------------------------------------------------------------------------
ItemDowngradeFix:
JSR ItemDowngradeFixMain
JSR CountChestKey
RTL
ItemDowngradeFixMain:
JSL.l AddInventory
BMI .dontWrite ; thing we wrote over part 1
@@ -27,7 +33,7 @@ ItemDowngradeFix:
.done
STA [$00] ; thing we wrote over part 2
.dontWrite
RTL
RTS
.isPowerGloves
.isBlueShield
.isRedShield
@@ -36,7 +42,7 @@ RTL
.isBowAndArrows
CMP [$00] : !BGE .done ; finished if we're upgrading
LDA [$00] ; reload old value
RTL
RTS
.isSilverArrowBow
.isRedBoomerang
.isMagicPowder
@@ -47,10 +53,10 @@ RTL
LDA [$00] : BNE + ; don't upgrade if we already have the toggle for it
PLA
STA [$00]
RTL
RTS
+
PLA
RTL
RTS
.isFightersSword
.isMasterSword
.isTemperedSword