You've already forked pokecrystal-board
mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2025-09-08 08:13:02 -07:00
Upkeep tasks in board menu: auto save game, increase turn, clear wTurnData (#11); also init wCurTurn and wCurSpace in EnterMap
This commit is contained in:
@@ -110,6 +110,7 @@ CheckSpaceEffects:
|
||||
bit 5, [hl]
|
||||
ret
|
||||
|
||||
; on enter overworld loop
|
||||
StartMap:
|
||||
xor a
|
||||
ldh [hScriptVar], a
|
||||
@@ -120,8 +121,15 @@ StartMap:
|
||||
call ByteFill
|
||||
farcall InitCallReceiveDelay
|
||||
call ClearJoypad
|
||||
; initialize board state
|
||||
xor a
|
||||
ld [wCurTurn], a
|
||||
ld [wCurSpace], a
|
||||
ld a, BOARDEVENT_DISPLAY_MENU
|
||||
ldh [hCurBoardEvent], a
|
||||
; fallthrough
|
||||
|
||||
; on map reload (e.g. after battle), warps and connections
|
||||
EnterMap:
|
||||
xor a
|
||||
ld [wXYComparePointer], a
|
||||
|
||||
Reference in New Issue
Block a user