pokecrystal-board/home/player.asm
2024-03-08 18:56:26 +01:00

14 lines
232 B
NASM
Executable File

; return field e in player a
; for one-byte field: in a
; for two-byte field: in hl
GetPlayerField::
ld hl, Players
ld bc, PLAYERDATA_LENGTH
call AddNTimes
ld d, 0
add hl, de
ld a, BANK(Players)
call GetFarWord
ld a, l
ret