diff --git a/hooks.asm b/hooks.asm index c08a240..0a4ad48 100644 --- a/hooks.asm +++ b/hooks.asm @@ -1406,18 +1406,24 @@ org $8DFB29 : BRA UpdateHUDBuffer_update_item_check_arrows ;-------------------------------------------------------------------------------- org $8DF1AB : JSR.w RebuildHUD_update org $8DDFC8 : JSR.w RebuildHUD_update -org $8DDB85 -JSR.w RebuildHUD : BRA + : NOP : + +org $8DDB85 : JSR.w RefreshIcon_UpdateHUD : BRA + : NOP : + ;-------------------------------------------------------------------------------- org $87A205 : JSL.l RebuildHUD_update_long -org $8AEF62 : JSL.l RebuildHUD_update_long org $87A1A4 : JSL.l RebuildHUD_update_long org $87A1CF : JSL.l RebuildHUD_update_long +org $87A21D : JSL.l RebuildHUD_update_long org $87A235 : JSL.l RebuildHUD_update_long +org $8AEF62 : JSL.l RebuildHUD_update_long ;-------------------------------------------------------------------------------- org $8DFFE1 RebuildHUD_update_long: JSR.w RebuildHUD_update : RTL + +RefreshIcon_UpdateHUD: +INC.w UpdateHUDFlag +JSR.w RebuildHUD +JSR.w UpdateEquippedItem +RTS warnpc $8E8000 ;-------------------------------------------------------------------------------- org $8DEDE8 diff --git a/newitems.asm b/newitems.asm index 2d2f824..a173e04 100644 --- a/newitems.asm +++ b/newitems.asm @@ -276,8 +276,8 @@ ItemBehavior: RTS .silversbow + LDA.l BowTracking : ORA.b #$40 : STA.l BowTracking LDA.l SilverArrowsUseRestriction : BNE + - LDA.l BowTracking : ORA.b #$40 : STA.l BowTracking LDA.b #03 : STA.l BowEquipment ; set bow to silver + LDA.b #$01 : STA.l BowEquipment @@ -338,8 +338,8 @@ ItemBehavior: RTS .silver_bow + LDA.b #$40 : ORA.l BowTracking : STA.l BowTracking LDA.l SilverArrowsUseRestriction : BNE .noequip - LDA.b #$40 : ORA.l BowTracking : STA.l BowTracking LDA.l SilverArrowsAutoEquip : AND.b #$01 : BEQ .noequip LDA.l CurrentArrows : BNE + ; check arrows LDA.b #$03 : BRA ++ ; bow without arrow @@ -414,8 +414,8 @@ ItemBehavior: RTS .silver_arrows + LDA.l BowTracking : ORA.b #$40 : STA.l BowTracking LDA.l SilverArrowsUseRestriction : BNE ++ - LDA.l BowTracking : ORA.b #$40 : STA.l BowTracking LDA.l SilverArrowsAutoEquip : AND.b #$01 : BEQ ++ LDA.l BowEquipment : BEQ ++ : CMP.b #$03 : !BGE + !ADD.b #$02 : STA.l BowEquipment ; switch to silver bow diff --git a/npcitems.asm b/npcitems.asm index 3206fe5..b4a7fa5 100644 --- a/npcitems.asm +++ b/npcitems.asm @@ -51,8 +51,8 @@ ItemCheck_TreeKid: RTL ItemCheck_TreeKid2: - LDA.l NpcFlags : AND.b #$08 : CMP.b #$08 - TDC ; ?? TODO + LDA.l NpcFlags : AND.b #$08 + LSR #2 RTL ItemCheck_TreeKid3: diff --git a/sram.asm b/sram.asm index 9bc5846..9e86afd 100644 --- a/sram.asm +++ b/sram.asm @@ -177,7 +177,7 @@ InventoryTracking: skip 2 ; - - - - - - o q b r m p n s k f (bitfield) ; p = Magic Powder | n = Mushroom Past | s = Shovel ; k = Inactive Flute | f = Active Flute | o = Any bomb acquired ; q = Quickswap locked -BowTracking: skip 2 ; b s p f - - - - - - - - - - - - (bitfield) +BowTracking: skip 2 ; - - - - - - - - b s p f - - - - (bitfield) ; b = Any Bow | s = Silver Arrows Upgrade | p = Second Progressive Bow ; f = First progressive bow ; The front end writes two distinct progressive bow items. p diff --git a/vanillalabels.asm b/vanillalabels.asm index 4e53dcf..3b77d99 100644 --- a/vanillalabels.asm +++ b/vanillalabels.asm @@ -153,6 +153,7 @@ Ancilla29_MilestoneItemReceipt_no_sparkle = $88CB2E Ancilla_SetOAM_XY = $88F6F3 Ancilla_AddAncilla = $899CCE UpdateHUD = $8DDFA9 +UpdateEquippedItem = $8DDFAF DrawProgressIcons = $8DE9C8 ItemMenu_DrawEquippedYItem = $8DEB3A ItemMenu_DrawEquippedYItem_exit = $8DECE6