Skip to content

Commit

Permalink
Use LOAD for LCD functions
Browse files Browse the repository at this point in the history
  • Loading branch information
ElectroDeoxys committed Jul 13, 2024
1 parent ed9e1bf commit bb5b3ec
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/engine/bank20.asm
Original file line number Diff line number Diff line change
Expand Up @@ -5902,6 +5902,7 @@ UnreferencedLCD_82729:
ret

.func
LOAD UNION "LCD Function", WRAM0
push af
push bc
push de
Expand All @@ -5920,6 +5921,7 @@ UnreferencedLCD_82729:
pop bc
pop af
reti
ENDL
.func_end

; unreferenced
Expand All @@ -5931,7 +5933,9 @@ UnreferencedLCD_82754:
ret

.func
LOAD UNION "LCD Function", WRAM0
reti
ENDL
.func_end

HandleBottomBar:
Expand Down
4 changes: 4 additions & 0 deletions src/layout.link
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,10 @@ ROMX $7f
"Wario OAM 2"
WRAM0
"WRAM0"
"wVBlankFunc"
"wLCDFunc"
"LCD Function"
"Room Block Tiles"
"Progress WRAM"
"Level WRAM"
org $cc00
Expand Down
10 changes: 9 additions & 1 deletion src/wram.asm
Original file line number Diff line number Diff line change
Expand Up @@ -369,13 +369,21 @@ wc1ca::

ds $35

SECTION "wVBlankFunc", WRAM0

; function called on V-Blank
wVBlankFunc::
ds $200

SECTION "wLCDFunc", WRAM0

; function called on LCD
wLCDFunc::
ds $1ff
; "LCD Function" goes here

SECTION "Room Block Tiles", WRAM0

ds $1e0

wROMBank::
db
Expand Down

0 comments on commit bb5b3ec

Please sign in to comment.