Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
pret
GitHub Repository: pret/pokered
Path: blob/master/engine/overworld/clear_variables.asm
1271 views
1
ClearVariablesOnEnterMap::
2
ld a, SCREEN_HEIGHT_PX
3
ldh [hWY], a
4
ldh [rWY], a
5
xor a
6
ldh [hAutoBGTransferEnabled], a
7
ld [wStepCounter], a
8
ld [wLoneAttackNo], a
9
ldh [hJoyPressed], a
10
ldh [hJoyReleased], a
11
ldh [hJoyHeld], a
12
ld [wActionResultOrTookBattleTurn], a
13
ld [wUnusedMapVariable], a
14
ld hl, wCardKeyDoorY
15
ld [hli], a
16
ld [hl], a
17
ld hl, wWhichTrade
18
ld bc, wStandingOnWarpPadOrHole - wWhichTrade
19
call FillMemory
20
ret
21
22