pokegold-spaceworld/engine/debug/field/toggle_npc_movement.inc
DrippingYellow 030186d4cf
Some checks failed
CI / build (push) Has been cancelled
Labelling and separating bank01.asm (#117)
* Started labelling dumped bank 1 functions, identified movement values

* Changed all NPCs to use the new movement constants

* Updated the rest of the movement constant instances, removed the old movement_constants.asm

* Ready to deal the finishing blow to bank01.asm

* Bank 01 is no more. Other scattered changes.

* Labelled a few flags and matched a few variables with pokegold

* Finished labelling bank02.asm too while I was at it
2025-07-07 19:02:15 -04:00

40 lines
534 B
PHP

FieldDebug_ToggleNPCMovement:
call .ToggleNPCMovement
jr nc, .close
ld a, FIELDDEBUG_RETURN_REOPEN
ret
.close
ld a, FIELDDEBUG_RETURN_CLOSE
ret
.ToggleNPCMovement:
ld hl, .MenuHeader
call GetMenu2
ret c
ld a, [wMenuCursorY]
cp 1
jr nz, .move
; stop NPCs
ld a, PLAYER_OBJECT
call FreezeAllOtherObjects
jr .done
.move
call UnfreezeAllObjects
.done
and a
ret
.MenuHeader:
db MENU_BACKUP_TILES
menu_coords 0, 0, 7, 6
dw .MenuData
db 1
.MenuData:
db STATICMENU_CURSOR
db 2
db "とめる@"
db "うごかす@"