Board menu: implement preliminary Party, Bag, Pokegear, and Exit submenus (#11)

This commit is contained in:
xCrystal
2023-09-22 23:12:05 +02:00
parent c11c53e0d7
commit ca919cdf98
19 changed files with 275 additions and 59 deletions

View File

@@ -104,6 +104,37 @@ CancelPokemonAction:
ld a, 1
ret
Party::
.choosemenu
xor a
ld [wPartyMenuActionText], a ; Choose a POKéMON.
call ClearBGPalettes
.menu
farcall LoadPartyMenuGFX
farcall InitPartyMenuWithCancel
farcall InitPartyMenuGFX
.menunoreload
farcall WritePartyMenuTilemap
farcall PlacePartyMenuText
call WaitBGMap
call SetPalettes ; load regular palettes?
call DelayFrame
farcall PartyMenuSelect
ret c ; if cancelled or pressed B
call PokemonActionSubmenu
and 3
cp 3
jr z, .menu
cp 0
jr z, .choosemenu
cp 1
jr z, .menunoreload
and a ; must be 2, which means quit after using field move
ret ; nc
PokemonActionSubmenu:
hlcoord 1, 15
lb bc, 2, 18