ref: 71db95dc34b82648b36d305efb7ad0f2552439c2
parent: 45e3f6aca90dc4dee962f5aafe4eb5590122361c
author: Rangi <remy.oukaour+rangi42@gmail.com>
date: Fri Apr 19 14:55:04 EDT 2019
Identify a few more WRAM label uses
--- a/engine/gfx/sprite_anims.asm
+++ b/engine/gfx/sprite_anims.asm
@@ -747,7 +747,7 @@
ret
.IntroSuicune
- ld a, [wcf65]
+ ld a, [wIntroSceneTimer]
and a
jr nz, .asm_8d645
ret
--- a/engine/pokemon/bills_pc.asm
+++ b/engine/pokemon/bills_pc.asm
@@ -776,8 +776,8 @@
call ClearSprites
call ClearTileMap
call BillsPC_InitGFX
- ld hl, wBillsPCPokemonList
- ld bc, $338
+ ld hl, wBillsPCData
+ ld bc, wBillsPCDataEnd - wBillsPCData
xor a
call ByteFill
xor a
--- a/engine/pokemon/mon_menu.asm
+++ b/engine/pokemon/mon_menu.asm
@@ -247,12 +247,12 @@
.loop
farcall DepositSellPack
- ld a, [wcf66]
+ ld a, [wPackUsedItem]
and a
jr z, .quit
- ld a, [wcf65]
- cp 2
+ ld a, [wCurPocket]
+ cp KEY_ITEM_POCKET
jr z, .next
call CheckTossableItem
--- a/wram.asm
+++ b/wram.asm
@@ -964,10 +964,24 @@
NEXTU ; c800
; bill's pc data
+wBillsPCData::
wBillsPCPokemonList::
; (species, box number, list index) x30
ds 3 * 30
+ ds 720
+wBillsPC_ScrollPosition:: db
+wBillsPC_CursorPosition:: db
+wBillsPC_NumMonsInBox:: db
+wBillsPC_NumMonsOnScreen:: db
+wBillsPC_LoadedBox:: db ; 0 if party, 1 - 14 if box, 15 if active box
+wBillsPC_BackupScrollPosition:: db
+wBillsPC_BackupCursorPosition:: db
+wBillsPC_BackupLoadedBox:: db
+wBillsPC_MonHasMail:: db
+ ds 5
+wBillsPCDataEnd::
+
NEXTU ; c800
; Hall of Fame data
wHallOfFamePokemonList:: hall_of_fame wHallOfFamePokemonList
@@ -980,9 +994,9 @@
NEXTU ; c800
; link data members
wLinkPlayerName:: ds NAME_LENGTH
-wLinkPartyCount:: db
+wLinkPartyCount:: db
wLinkPartySpecies:: ds PARTY_LENGTH
-wLinkPartyEnd:: db ; older code doesn't check PartyCount
+wLinkPartyEnd:: db ; older code doesn't check PartyCount
UNION ; c813
; time capsule party data
@@ -1095,22 +1109,12 @@
NEXTU ; ca00
; link data
ds 191
-wcabf:: ds 79
-wcb0e:: ds 5
-wcb13:: ds 23
-ENDU ; cb2a
+wcabf:: ds 1
+ENDU ; cb00
-wBillsPC_ScrollPosition:: db
-wBillsPC_CursorPosition:: db
-wBillsPC_NumMonsInBox:: db
-wBillsPC_NumMonsOnScreen:: db
-wBillsPC_LoadedBox:: db ; 0 if party, 1 - 14 if box, 15 if active box
-wBillsPC_BackupScrollPosition:: db
-wBillsPC_BackupCursorPosition:: db
-wBillsPC_BackupLoadedBox:: db
-wBillsPC_MonHasMail:: db
- ds 18
-
+ ds 14
+wcb0e:: ds 5
+wcb13:: ds 50
wcb45:: ds 20
wcb59:: ds 20
wcb6d:: ds 1
@@ -1119,8 +1123,8 @@
wcbe8:: dw
wLinkOTPartyMonTypes:: ds 2 * PARTY_LENGTH
ds 84
-
wcc4a:: ds 22
+
wcc60:: ds 1
wcc61:: ds 1
wcc62:: ds 2