summaryrefslogtreecommitdiff
path: root/engine/events
diff options
context:
space:
mode:
authorRangi <remy.oukaour+rangi42@gmail.com>2020-11-03 19:53:07 -0500
committerRangi <remy.oukaour+rangi42@gmail.com>2020-11-03 19:53:07 -0500
commitc88c4a834094e91f1505eab0e22294963e1dd987 (patch)
treeddfc0116b06e1327cf206abf5ed16e79e159fdb4 /engine/events
parent826e070f0443b50ff31a49b4faf7c66577f1e26e (diff)
Identify more uses of wBuffer1-6
Diffstat (limited to 'engine/events')
-rw-r--r--engine/events/daycare.asm4
-rw-r--r--engine/events/heal_machine_anim.asm20
-rw-r--r--engine/events/lucky_number.asm4
-rw-r--r--engine/events/pokecenter_pc.asm24
-rw-r--r--engine/events/treemons.asm6
5 files changed, 29 insertions, 29 deletions
diff --git a/engine/events/daycare.asm b/engine/events/daycare.asm
index 9393ebc93..d5930575e 100644
--- a/engine/events/daycare.asm
+++ b/engine/events/daycare.asm
@@ -616,8 +616,8 @@ DayCare_InitBreeding:
xor a
ld [wEggMonItem], a
ld de, wEggMonMoves
- xor a
- ld [wBuffer1], a
+ xor a ; FALSE
+ ld [wSkipMovesBeforeLevelUp], a
predef FillMoves
farcall InitEggMoves
ld hl, wEggMonID
diff --git a/engine/events/heal_machine_anim.asm b/engine/events/heal_machine_anim.asm
index 166b42b67..6de8c5775 100644
--- a/engine/events/heal_machine_anim.asm
+++ b/engine/events/heal_machine_anim.asm
@@ -17,19 +17,19 @@ HealMachineAnim:
; 1: Left (Elm's Lab)
; 2: Up (Hall of Fame)
ld a, [wScriptVar]
- ld [wBuffer1], a
+ ld [wHealMachineAnimType], a
ldh a, [rOBP1]
- ld [wBuffer2], a
+ ld [wHealMachineTempOBP1], a
call .DoJumptableFunctions
- ld a, [wBuffer2]
+ ld a, [wHealMachineTempOBP1]
call DmgToCgbObjPal1
ret
.DoJumptableFunctions:
xor a
- ld [wBuffer3], a
-.jumpable_loop
- ld a, [wBuffer1]
+ ld [wHealMachineAnimState], a
+.jumptable_loop
+ ld a, [wHealMachineAnimType]
ld e, a
ld d, 0
ld hl, .Pointers
@@ -38,17 +38,17 @@ HealMachineAnim:
ld a, [hli]
ld h, [hl]
ld l, a
- ld a, [wBuffer3]
+ ld a, [wHealMachineAnimState]
ld e, a
inc a
- ld [wBuffer3], a
+ ld [wHealMachineAnimState], a
add hl, de
ld a, [hl]
cp HEALMACHINESTATE_FINISH
jr z, .finish
ld hl, .Jumptable
rst JumpTable
- jr .jumpable_loop
+ jr .jumptable_loop
.finish
ret
@@ -237,7 +237,7 @@ INCLUDE "gfx/overworld/heal_machine.pal"
.PlaceHealingMachineTile:
push bc
- ld a, [wBuffer1]
+ ld a, [wHealMachineAnimType]
bcpixel 2, 4
cp HEALMACHINE_ELMS_LAB
jr z, .okay
diff --git a/engine/events/lucky_number.asm b/engine/events/lucky_number.asm
index f9d17c8a9..66ec205c1 100644
--- a/engine/events/lucky_number.asm
+++ b/engine/events/lucky_number.asm
@@ -125,7 +125,7 @@ CheckForLuckyNumberWinners:
push hl
ld d, h
ld e, l
- ld hl, wBuffer1
+ ld hl, wMonIDDigitsBuffer
lb bc, PRINTNUM_LEADINGZEROS | 2, 5
call PrintNum
ld hl, wLuckyNumberDigitsBuffer
@@ -135,7 +135,7 @@ CheckForLuckyNumberWinners:
ld b, 5
ld c, 0
ld hl, wLuckyNumberDigitsBuffer + 4
- ld de, wBuffer1 + 4
+ ld de, wMonIDDigitsBuffer + 4
.loop
ld a, [de]
cp [hl]
diff --git a/engine/events/pokecenter_pc.asm b/engine/events/pokecenter_pc.asm
index 0503ee6f2..74645a92c 100644
--- a/engine/events/pokecenter_pc.asm
+++ b/engine/events/pokecenter_pc.asm
@@ -361,15 +361,15 @@ PlayerWithdrawItemMenu:
.withdraw
ld a, [wItemQuantityChangeBuffer]
- ld [wBuffer1], a ; quantity
+ ld [wPCItemQuantityChangeBuffer], a
ld a, [wCurItemQuantity]
- ld [wBuffer2], a
+ ld [wPCItemQuantity], a
ld hl, wNumItems
call ReceiveItem
jr nc, .PackFull
- ld a, [wBuffer1]
+ ld a, [wPCItemQuantityChangeBuffer]
ld [wItemQuantityChangeBuffer], a
- ld a, [wBuffer2]
+ ld a, [wPCItemQuantity]
ld [wCurItemQuantity], a
ld hl, wNumPCItems
call TossItem
@@ -490,15 +490,15 @@ PlayerDepositItemMenu:
ret
.tossable
- ld a, [wBuffer1]
+ ld a, [wPCItemQuantityChangeBuffer]
push af
- ld a, [wBuffer2]
+ ld a, [wPCItemQuantity]
push af
call .DepositItem
pop af
- ld [wBuffer2], a
+ ld [wPCItemQuantity], a
pop af
- ld [wBuffer1], a
+ ld [wPCItemQuantityChangeBuffer], a
ret
.DepositItem:
@@ -522,15 +522,15 @@ PlayerDepositItemMenu:
.ContinueDeposit:
ld a, [wItemQuantityChangeBuffer]
- ld [wBuffer1], a
+ ld [wPCItemQuantityChangeBuffer], a
ld a, [wCurItemQuantity]
- ld [wBuffer2], a
+ ld [wPCItemQuantity], a
ld hl, wNumPCItems
call ReceiveItem
jr nc, .NoRoomInPC
- ld a, [wBuffer1]
+ ld a, [wPCItemQuantityChangeBuffer]
ld [wItemQuantityChangeBuffer], a
- ld a, [wBuffer2]
+ ld a, [wPCItemQuantity]
ld [wCurItemQuantity], a
ld hl, wNumItems
call TossItem
diff --git a/engine/events/treemons.asm b/engine/events/treemons.asm
index 9adcdbdc2..231636ea0 100644
--- a/engine/events/treemons.asm
+++ b/engine/events/treemons.asm
@@ -197,11 +197,11 @@ NoTreeMon:
GetTreeScore:
call .CoordScore
- ld [wBuffer1], a
+ ld [wTreeMonCoordScore], a
call .OTIDScore
- ld [wBuffer2], a
+ ld [wTreeMonOTIDScore], a
ld c, a
- ld a, [wBuffer1]
+ ld a, [wTreeMonCoordScore]
sub c
jr z, .rare
jr nc, .ok