summaryrefslogtreecommitdiff
path: root/engine/events
diff options
context:
space:
mode:
authorRangi <remy.oukaour+rangi42@gmail.com>2018-07-28 19:27:34 -0400
committerRangi <remy.oukaour+rangi42@gmail.com>2018-07-29 00:25:52 -0400
commit9dec80b07e3638c722b9768a1ca0184edea20392 (patch)
treefdd5e227f20540b838ec45d282e40b083ae56c72 /engine/events
parent2ec900d96c3b6020be0816151b9ad606c04114b5 (diff)
Add meaningful aliases for wd265
Introduce MONICON_* constants Introduce BATTLEPLAYERACTION_* constants
Diffstat (limited to 'engine/events')
-rw-r--r--engine/events/bug_contest/caught_mon.asm4
-rw-r--r--engine/events/bug_contest/display_stats.asm2
-rw-r--r--engine/events/daycare.asm2
-rw-r--r--engine/events/field_moves.asm2
-rw-r--r--engine/events/halloffame.asm4
-rw-r--r--engine/events/happiness_egg.asm12
-rw-r--r--engine/events/lucky_number.asm12
-rw-r--r--engine/events/magikarp.asm8
-rw-r--r--engine/events/move_deleter.asm4
-rw-r--r--engine/events/move_tutor.asm2
-rw-r--r--engine/events/name_rater.asm2
-rw-r--r--engine/events/npc_trade.asm2
-rw-r--r--engine/events/specials.asm4
13 files changed, 30 insertions, 30 deletions
diff --git a/engine/events/bug_contest/caught_mon.asm b/engine/events/bug_contest/caught_mon.asm
index 45212ae3e..fc170cf28 100644
--- a/engine/events/bug_contest/caught_mon.asm
+++ b/engine/events/bug_contest/caught_mon.asm
@@ -2,7 +2,7 @@ BugContest_SetCaughtContestMon:
ld a, [wContestMon]
and a
jr z, .firstcatch
- ld [wd265], a
+ ld [wNamedObjectIndexBuffer], a
farcall DisplayAlreadyCaughtText
farcall DisplayCaughtContestMonStats
lb bc, 14, 7
@@ -12,7 +12,7 @@ BugContest_SetCaughtContestMon:
.firstcatch
call .generatestats
ld a, [wTempEnemyMonSpecies]
- ld [wd265], a
+ ld [wNamedObjectIndexBuffer], a
call GetPokemonName
ld hl, .caughttext
call PrintText
diff --git a/engine/events/bug_contest/display_stats.asm b/engine/events/bug_contest/display_stats.asm
index 94a5e9511..9d92f8fe3 100644
--- a/engine/events/bug_contest/display_stats.asm
+++ b/engine/events/bug_contest/display_stats.asm
@@ -36,7 +36,7 @@ DisplayCaughtContestMonStats:
call PlaceString
ld a, [wContestMon]
- ld [wd265], a
+ ld [wNamedObjectIndexBuffer], a
call GetPokemonName
ld de, wStringBuffer1
hlcoord 1, 2
diff --git a/engine/events/daycare.asm b/engine/events/daycare.asm
index 5904a476d..4e98c5382 100644
--- a/engine/events/daycare.asm
+++ b/engine/events/daycare.asm
@@ -558,7 +558,7 @@ DayCare_InitBreeding:
bit DAYCAREMAN_HAS_MON_F, a
ret z
callfar CheckBreedmonCompatibility
- ld a, [wd265]
+ ld a, [wBreedingCompatibility]
and a
ret z
inc a
diff --git a/engine/events/field_moves.asm b/engine/events/field_moves.asm
index 6adb80ba6..a6edbc08c 100644
--- a/engine/events/field_moves.asm
+++ b/engine/events/field_moves.asm
@@ -407,7 +407,7 @@ FlyFunction_InitGFX:
ld d, 0
add hl, de
ld a, [hl]
- ld [wd265], a
+ ld [wTempIconSpecies], a
ld e, FIELDMOVE_FLY
farcall FlyFunction_GetMonIcon
xor a
diff --git a/engine/events/halloffame.asm b/engine/events/halloffame.asm
index fcbcc1593..752ec965b 100644
--- a/engine/events/halloffame.asm
+++ b/engine/events/halloffame.asm
@@ -462,7 +462,7 @@ DisplayHOFMon:
call TextBox
ld a, [wTempMonSpecies]
ld [wCurPartySpecies], a
- ld [wd265], a
+ ld [wDeciramBuffer], a
ld hl, wTempMonDVs
predef GetUnownLetter
xor a
@@ -477,7 +477,7 @@ DisplayHOFMon:
ld [hli], a
ld [hl], "<DOT>"
hlcoord 3, 13
- ld de, wd265
+ ld de, wDeciramBuffer
lb bc, PRINTNUM_LEADINGZEROS | 1, 3
call PrintNum
call GetBasePokemonName
diff --git a/engine/events/happiness_egg.asm b/engine/events/happiness_egg.asm
index 41f9a4411..1d33edb74 100644
--- a/engine/events/happiness_egg.asm
+++ b/engine/events/happiness_egg.asm
@@ -11,7 +11,7 @@ GetFirstPokemonHappiness:
jr .loop
.done
- ld [wd265], a
+ ld [wNamedObjectIndexBuffer], a
ld a, [hl]
ld [wScriptVar], a
call GetPokemonName
@@ -19,9 +19,9 @@ GetFirstPokemonHappiness:
CheckFirstMonIsEgg:
ld a, [wPartySpecies]
- ld [wd265], a
+ ld [wNamedObjectIndexBuffer], a
cp EGG
- ld a, 1
+ ld a, TRUE
jr z, .egg
xor a
@@ -196,15 +196,15 @@ DayCareStep::
call Random
ld [hl], a
callfar CheckBreedmonCompatibility
- ld a, [wd265]
+ ld a, [wBreedingCompatibility]
cp 230
ld b, 32 percent - 1
jr nc, .okay
- ld a, [wd265]
+ ld a, [wBreedingCompatibility]
cp 170
ld b, 16 percent
jr nc, .okay
- ld a, [wd265]
+ ld a, [wBreedingCompatibility]
cp 110
ld b, 12 percent
jr nc, .okay
diff --git a/engine/events/lucky_number.asm b/engine/events/lucky_number.asm
index c5d6d18e0..f77b3c395 100644
--- a/engine/events/lucky_number.asm
+++ b/engine/events/lucky_number.asm
@@ -1,7 +1,7 @@
CheckForLuckyNumberWinners:
xor a
ld [wScriptVar], a
- ld [wFoundMatchingIDInParty], a
+ ld [wTempByteValue], a
ld a, [wPartyCount]
and a
ret z
@@ -34,8 +34,8 @@ CheckForLuckyNumberWinners:
jr z, .SkipOpenBoxMon
call .CompareLuckyNumberToMonID
jr nc, .SkipOpenBoxMon
- ld a, 1
- ld [wFoundMatchingIDInParty], a
+ ld a, TRUE
+ ld [wTempByteValue], a
.SkipOpenBoxMon:
push bc
@@ -81,8 +81,8 @@ CheckForLuckyNumberWinners:
call .CompareLuckyNumberToMonID ; sets wScriptVar and wCurPartySpecies appropriately
jr nc, .SkipBoxMon
- ld a, 1
- ld [wFoundMatchingIDInParty], a
+ ld a, TRUE
+ ld [wTempByteValue], a
.SkipBoxMon:
push bc
@@ -104,7 +104,7 @@ CheckForLuckyNumberWinners:
and a
ret z ; found nothing
farcall StubbedTrainerRankings_LuckyNumberShow
- ld a, [wFoundMatchingIDInParty]
+ ld a, [wTempByteValue]
and a
push af
ld a, [wCurPartySpecies]
diff --git a/engine/events/magikarp.asm b/engine/events/magikarp.asm
index cf8ad80ba..db415c65e 100644
--- a/engine/events/magikarp.asm
+++ b/engine/events/magikarp.asm
@@ -185,7 +185,7 @@ CalcMagikarpLength:
ld hl, MagikarpLengths
ld a, 2
- ld [wd265], a
+ ld [wTempByteValue], a
.read
ld a, [hli]
@@ -214,7 +214,7 @@ CalcMagikarpLength:
ld [hMultiplicand + 1], a
ld a, 100
ld [hMultiplicand + 2], a
- ld a, [wd265]
+ ld a, [wTempByteValue]
ld [hMultiplier], a
call Multiply
ld b, 0
@@ -228,9 +228,9 @@ CalcMagikarpLength:
.next
inc hl ; align to next triplet
- ld a, [wd265]
+ ld a, [wTempByteValue]
inc a
- ld [wd265], a
+ ld [wTempByteValue], a
cp 16
jr c, .read
diff --git a/engine/events/move_deleter.asm b/engine/events/move_deleter.asm
index f2b827227..c889382c8 100644
--- a/engine/events/move_deleter.asm
+++ b/engine/events/move_deleter.asm
@@ -27,8 +27,8 @@ MoveDeletion:
jr c, .declined
ld a, [wMenuCursorY]
push af
- ld a, [wCurSpecies]
- ld [wd265], a
+ ld a, [wCurMove]
+ ld [wNamedObjectIndexBuffer], a
call GetMoveName
ld hl, .ConfirmDeleteText
call PrintText
diff --git a/engine/events/move_tutor.asm b/engine/events/move_tutor.asm
index 67d0ca528..681dc6adc 100644
--- a/engine/events/move_tutor.asm
+++ b/engine/events/move_tutor.asm
@@ -8,7 +8,7 @@ MoveTutor:
xor a
ld [wItemAttributeParamBuffer], a
call .GetMoveTutorMove
- ld [wd265], a
+ ld [wNamedObjectIndexBuffer], a
ld [wPutativeTMHMMove], a
call GetMoveName
call CopyName1
diff --git a/engine/events/name_rater.asm b/engine/events/name_rater.asm
index 593d51c69..2cdff4bdd 100644
--- a/engine/events/name_rater.asm
+++ b/engine/events/name_rater.asm
@@ -29,7 +29,7 @@ _NameRater:
xor a ; PARTYMON
ld [wMonType], a
ld a, [wCurPartySpecies]
- ld [wd265], a
+ ld [wNamedObjectIndexBuffer], a
ld [wCurSpecies], a
call GetBaseData
ld b, 0
diff --git a/engine/events/npc_trade.asm b/engine/events/npc_trade.asm
index 9cff40a2b..bb71941ed 100644
--- a/engine/events/npc_trade.asm
+++ b/engine/events/npc_trade.asm
@@ -301,7 +301,7 @@ Trade_GetAttributeOfLastPartymon:
GetTradeMonName:
push de
- ld [wd265], a
+ ld [wNamedObjectIndexBuffer], a
call GetBasePokemonName
ld hl, wStringBuffer1
pop de
diff --git a/engine/events/specials.asm b/engine/events/specials.asm
index 35d32dde6..be554f1bc 100644
--- a/engine/events/specials.asm
+++ b/engine/events/specials.asm
@@ -34,7 +34,7 @@ GameCornerPrizeMonCheckDex:
call SetSeenAndCaughtMon
call FadeToMenu
ld a, [wScriptVar]
- ld [wd265], a
+ ld [wNamedObjectIndexBuffer], a
farcall NewPokedexEntry
call ExitAllMenus
ret
@@ -153,7 +153,7 @@ GetMysteryGiftItem:
ld [sMysteryGiftItem], a
call CloseSRAM
ld a, [wCurItem]
- ld [wd265], a
+ ld [wNamedObjectIndexBuffer], a
call GetItemName
ld hl, .ReceiveItemText
call PrintText