Merge in beta changes to pikit mode #4

Open
karafruit wants to merge 36 commits from pikit_mode_merge into pikit_mode
3 changed files with 39 additions and 15 deletions
Showing only changes of commit b58641ad90 - Show all commits
+34 -12
View File
@@ -1,5 +1,6 @@
!BlankTile = $207F !BlankTile = $207F
!SlashTile = $2830 !SlashTile = $2830
!PlusTile = $2404
!HyphenTile = $2405 !HyphenTile = $2405
!LTile = $2D68 !LTile = $2D68
!DTile = $2D60 !DTile = $2D60
@@ -77,7 +78,7 @@ DRHUD_DrawCurrentDungeonIndicator: ; mX
STY.w HUDCurrentDungeonWorld STY.w HUDCurrentDungeonWorld
DRHUD_DrawKeyCounter: DRHUD_DrawKeyCounter:
LDA.l DRFlags : AND.b #$04 : BEQ DRHUD_Finished LDA.l DRFlags : AND.b #$04 : BEQ .to_finished
LDA.l CompassMode : BIT.b #$03 : BEQ DRHUD_Finished LDA.l CompassMode : BIT.b #$03 : BEQ DRHUD_Finished
REP #$20 REP #$20
BIT.w #$0002 : BNE .skip_map_check BIT.w #$0002 : BNE .skip_map_check
@@ -90,8 +91,17 @@ DRHUD_DrawKeyCounter:
LDA.l GenericKeys : LSR : BCS .total_only LDA.l GenericKeys : LSR : BCS .total_only
LDA.w DungeonCollectedKeys, X : JSR ConvertToDisplay : STA.w HUDKeysObtained LDA.w DungeonCollectedKeys, X : JSR ConvertToDisplay : STA.w HUDKeysObtained
LDA.w #!SlashTile : STA.w HUDKeysSlash LDA.w #!SlashTile : STA.w HUDKeysSlash
LDA.l ExtraChestKeys, X : AND.w #$00FF : BEQ .total_only
JSR ConvertToDisplay : STA.w HUDKeysExtraCount
LDA.w #!PlusTile : STA.w HUDKeysExtraPlus
.total_only .total_only
LDA.l ChestKeys, x : JSR ConvertToDisplay : STA.w HUDKeysTotal SEP #$20
LDA.l ChestKeys, X : SEC : SBC.l ExtraChestKeys, X
REP #$20
JSR ConvertToDisplay : STA.w HUDKeysTotal
.to_finished
JMP DRHUD_Finished JMP DRHUD_Finished
OWRHUD_DrawWorldIndicator: OWRHUD_DrawWorldIndicator:
@@ -292,17 +302,29 @@ BossStatus:
; default palette 3 - white ; default palette 3 - white
LDA.l DungeonReminderTable, X : RTS LDA.l DungeonReminderTable, X : RTS
ConvertToDisplay: ConvertToDisplay: ; transparent background
and.w #$00ff : cmp.w #$000a : !BLT + AND.w #$00FF
!ADD.w #$2519 : rts CMP.w #$000A : BCC .under10
+ !ADD.w #$2490 : rts CMP.w #$000C : BCC .under12
.over11
CLC : ADC.w #$2553 : RTS
.under12
CLC : ADC.w #$2519 : RTS
.under10
CLC : ADC.w #$2490 : RTS
ConvertToDisplay2: ConvertToDisplay2: ; solid background
and.w #$00ff : beq ++ AND.w #$00FF : BEQ .zero
cmp.w #$000a : !BLT + CMP.w #$000A : BCC .under10
!ADD.w #$2517 : rts ; 2580 with 258A as "A" for non transparent digits CMP.w #$000C : BCC .under12
+ !ADD.w #$2816 : rts .over11
++ lda.w #$2827 : rts ; 0/O for 0 or placeholder digit ;2483 CLC : ADC.w #$2580 : RTS
.under12
CLC : ADC.w #$2517 : RTS
.under10
CLC : ADC.w #$2816 : RTS
.zero
LDA.w #$2827 : RTS
CountAbsorbedKeys: CountAbsorbedKeys:
JML IncrementSmallKeysNoPrimary JML IncrementSmallKeysNoPrimary
+2
View File
@@ -597,6 +597,8 @@ HUDMultiIndicator = $7EC790 ;
HUDKeysObtained = $7EC7A2 ; HUDKeysObtained = $7EC7A2 ;
HUDKeysSlash = $7EC7A4 ; HUDKeysSlash = $7EC7A4 ;
HUDKeysTotal = $7EC7A6 ; HUDKeysTotal = $7EC7A6 ;
HUDKeysExtraPlus = $7EC7E4 ;
HUDKeysExtraCount = $7EC7E6 ;
; ;
BigRAM = $7EC900 ; Big buffer of free ram (0x1F00) BigRAM = $7EC900 ; Big buffer of free ram (0x1F00)
ItemGFXStack = $7ECB00 ; Pointers to source of decompressed item tiles deferred to NMI loading. ItemGFXStack = $7ECB00 ; Pointers to source of decompressed item tiles deferred to NMI loading.
+3 -3
View File
@@ -2686,9 +2686,9 @@ org $B0EFFF ; PC 0x186FFF
BallNChainDungeon: ; Dungeon ID where ball n chain guard is located. Write BallNChainDungeon: ; Dungeon ID where ball n chain guard is located. Write
db $02 ; $FF to count ball and chain item for collection stats. db $02 ; $FF to count ball and chain item for collection stats.
;-------------------------------------------------------------------------------- org $B0F000
; 0x187000 - 18700F (unused) ExtraChestKeys: ; PC 0x187000-0x18700F
;-------------------------------------------------------------------------------- db $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
org $B0F010 org $B0F010
ChestKeys: ; PC 0x187010-0x18701F ChestKeys: ; PC 0x187010-0x18701F