pokered/engine/predefs7.asm

49 lines
806 B
NASM
Raw Normal View History

2015-07-24 04:00:30 +00:00
DisplayElevatorFloorMenu: ; 1c9c6 (7:49c6)
2014-05-22 22:13:20 +00:00
ld hl, WhichFloorText
call PrintText
2015-07-15 06:16:06 +00:00
ld hl, wItemList
2014-05-22 22:13:20 +00:00
ld a, l
2015-07-15 06:16:06 +00:00
ld [wListPointer], a
2014-05-22 22:13:20 +00:00
ld a, h
2015-07-15 06:16:06 +00:00
ld [wListPointer + 1], a
2015-02-08 06:18:42 +00:00
ld a, [wListScrollOffset]
2014-05-22 22:13:20 +00:00
push af
xor a
2015-02-08 06:18:42 +00:00
ld [wCurrentMenuItem], a
ld [wListScrollOffset], a
2015-07-13 06:00:48 +00:00
ld [wPrintItemPrices], a
2015-07-24 04:00:30 +00:00
ld a, SPECIALLISTMENU
2015-02-08 06:18:42 +00:00
ld [wListMenuID], a
2014-05-22 22:13:20 +00:00
call DisplayListMenuID
pop bc
ld a, b
2015-02-08 06:18:42 +00:00
ld [wListScrollOffset], a
2014-05-22 22:13:20 +00:00
ret c
2016-01-03 19:17:10 +00:00
ld hl, wCurrentMapScriptFlags
2014-05-22 22:13:20 +00:00
set 7, [hl]
2015-08-13 05:14:31 +00:00
ld hl, wElevatorWarpMaps
2015-02-08 06:18:42 +00:00
ld a, [wWhichPokemon]
2014-05-22 22:13:20 +00:00
add a
2015-07-24 04:00:30 +00:00
ld d, 0
2014-05-22 22:13:20 +00:00
ld e, a
add hl, de
ld a, [hli]
ld b, a
ld a, [hl]
ld c, a
2014-09-13 07:50:56 +00:00
ld hl, wWarpEntries
2015-07-24 04:00:30 +00:00
call .UpdateWarp
2014-05-22 22:13:20 +00:00
2015-07-24 04:00:30 +00:00
.UpdateWarp
2014-05-22 22:13:20 +00:00
inc hl
inc hl
ld a, b
2015-07-24 04:00:30 +00:00
ld [hli], a ; destination warp ID
2014-05-22 22:13:20 +00:00
ld a, c
2015-07-24 04:00:30 +00:00
ld [hli], a ; destination map ID
2014-05-22 22:13:20 +00:00
ret
WhichFloorText: ; 1ca14 (7:4a14)
TX_FAR _WhichFloorText
db "@"