pokered/scripts/RedsHouse2F.asm
vulcandth d001ced41b
Add macros, constants, and labels for map scripts and text (#367)
This introduces `def_script_pointers`, `def_text_pointers`, and `object_const_def` macros, and applies them to all maps. Most other map labels have also been identified.
2023-07-13 21:27:56 -04:00

27 lines
582 B
NASM

RedsHouse2F_Script:
call EnableAutoTextBoxDrawing
ld hl, RedsHouse2F_ScriptPointers
ld a, [wRedsHouse2FCurScript]
jp CallFunctionInTable
RedsHouse2F_ScriptPointers:
def_script_pointers
dw_const RedsHouse2FDefaultScript, SCRIPT_REDSHOUSE2F_DEFAULT
dw_const RedsHouse2FNoopScript, SCRIPT_REDSHOUSE2F_NOOP
RedsHouse2FDefaultScript:
xor a
ldh [hJoyHeld], a
ld a, PLAYER_DIR_UP
ld [wPlayerMovingDirection], a
ld a, SCRIPT_REDSHOUSE2F_NOOP
ld [wRedsHouse2FCurScript], a
ret
RedsHouse2FNoopScript:
ret
RedsHouse2F_TextPointers:
def_text_pointers
text_end ; unused