summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRemy Oukaour <remy.oukaour@gmail.com>2018-01-20 12:25:55 -0500
committerRemy Oukaour <remy.oukaour@gmail.com>2018-01-20 12:25:55 -0500
commit05382d3e3c03616d6edf21833e89a8264a8cd10a (patch)
treedf62bed28665b4c1f8e6bc54c07bd4ce8efbccea
parent8127d1fbcfccb7cd5c3e210699dd540e370b6634 (diff)
PARTY_LENGTH; MON_NAME; sgb_border.bin
-rwxr-xr-xconstants/battle_tower_constants.asm6
-rw-r--r--constants/misc_constants.asm2
-rw-r--r--constants/radio_constants.asm4
-rw-r--r--constants/text_constants.asm14
-rw-r--r--docs/bugs_and_glitches.md2
-rw-r--r--engine/battle/core.asm8
-rwxr-xr-xengine/billspc.asm16
-rwxr-xr-xengine/breeding.asm4
-rw-r--r--engine/caught_data.asm4
-rw-r--r--engine/color.asm3
-rwxr-xr-xengine/events/battle_tower/battle_tower.asm24
-rw-r--r--engine/events/battle_tower/load_trainer.asm12
-rw-r--r--engine/events/battle_tower/rules.asm6
-rwxr-xr-xengine/events/daycare.asm4
-rwxr-xr-xengine/events/halloffame.asm6
-rw-r--r--engine/events/name_rater.asm10
-rw-r--r--engine/events/odd_egg.asm4
-rw-r--r--engine/events/poke_seer.asm4
-rwxr-xr-xengine/events/special.asm2
-rwxr-xr-xengine/evolve.asm4
-rw-r--r--engine/item_effects.asm6
-rwxr-xr-xengine/learn.asm2
-rwxr-xr-xengine/link.asm6
-rwxr-xr-xengine/link_trade.asm4
-rwxr-xr-xengine/move_mon.asm22
-rwxr-xr-xengine/move_mon_wo_mail.asm4
-rwxr-xr-xengine/namingscreen.asm2
-rwxr-xr-xengine/npctrade.asm2
-rw-r--r--engine/pack.asm2
-rw-r--r--engine/party_menu.asm2
-rwxr-xr-xengine/pokegear.asm2
-rwxr-xr-xengine/printer.asm8
-rw-r--r--engine/radio.asm2
-rw-r--r--engine/routines/checknickerrors.asm2
-rw-r--r--engine/routines/correcterrorsinplayerparty.asm2
-rw-r--r--engine/routines/initlist.asm2
-rwxr-xr-xengine/start_menu.asm2
-rwxr-xr-xengine/stats_screen.asm2
-rwxr-xr-xengine/wildmons.asm4
-rw-r--r--gfx/sgb/sgb_border.bin (renamed from gfx/sgb/sgb_border.tilemap)0
-rw-r--r--home.asm2
-rw-r--r--home/names.asm10
-rwxr-xr-xmacros/wram.asm14
-rw-r--r--maps/BattleTowerBattleRoom.asm2
-rwxr-xr-xmobile/fixed_words.asm2
-rw-r--r--mobile/mobile_40.asm4
-rw-r--r--mobile/mobile_42.asm2
-rwxr-xr-xmobile/mobile_46.asm8
-rwxr-xr-xmobile/mobile_5c.asm4
-rw-r--r--sram.asm2
-rw-r--r--wram.asm26
51 files changed, 147 insertions, 146 deletions
diff --git a/constants/battle_tower_constants.asm b/constants/battle_tower_constants.asm
index 4083c9d81..71b8de8be 100755
--- a/constants/battle_tower_constants.asm
+++ b/constants/battle_tower_constants.asm
@@ -1,11 +1,11 @@
-BATTLETOWER_PARTY_SIZE EQU 3
-BATTLETOWER_STREAK_SIZE EQU 7
+BATTLETOWER_PARTY_LENGTH EQU 3
+BATTLETOWER_STREAK_LENGTH EQU 7
BATTLETOWER_NUM_UNIQUE_PKMN EQU 21
BATTLETOWER_NUM_UNIQUE_TRAINERS EQU 70
BATTLETOWER_TRAINERDATALENGTH EQU $24
-BATTLE_TOWER_STRUCT_LENGTH EQU $e0 ; NAME_LENGTH + BATTLETOWER_PARTY_SIZE * (PARTYMON_STRUCT_LENGTH + PKMN_NAME_LENGTH) + BATTLETOWER_TRAINERDATALENGTH
+BATTLE_TOWER_STRUCT_LENGTH EQU $e0 ; NAME_LENGTH + BATTLETOWER_PARTY_LENGTH * (PARTYMON_STRUCT_LENGTH + MON_NAME_LENGTH) + BATTLETOWER_TRAINERDATALENGTH
; BattleTowerAction writebyte arguments (see engine/events/battle_tower/battle_tower.asm)
const_def
diff --git a/constants/misc_constants.asm b/constants/misc_constants.asm
index 14c6b313f..adcaf9a49 100644
--- a/constants/misc_constants.asm
+++ b/constants/misc_constants.asm
@@ -50,7 +50,7 @@ MONS_PER_BOX EQU 20
NUM_BOXES EQU 14
; hall of fame
-HOF_MON_LENGTH = 1 + 2 + 2 + 1 + (PKMN_NAME_LENGTH +- 1) ; species, id, dvs, level, nick
+HOF_MON_LENGTH = 1 + 2 + 2 + 1 + (MON_NAME_LENGTH +- 1) ; species, id, dvs, level, nick
HOF_LENGTH = 1 + HOF_MON_LENGTH * PARTY_LENGTH + 1 ; win count, party, terminator
NUM_HOF_TEAMS = 30
diff --git a/constants/radio_constants.asm b/constants/radio_constants.asm
index 03d4ede5a..d3f14e34c 100644
--- a/constants/radio_constants.asm
+++ b/constants/radio_constants.asm
@@ -94,12 +94,12 @@
const POKEDEX_SHOW_7 ; 56
const POKEDEX_SHOW_8 ; 57
-; PlayRadio arguments (see engine/pokegear.asm)
+; PlayRadio.StationPointers indexes (see engine/pokegear.asm)
const_def
const MAPRADIO_POKEMON_CHANNEL
const MAPRADIO_OAKS_MON_TALK
const MAPRADIO_POKEDEX_SHOW
- const MAPRADIO_PKMN_MUSIC
+ const MAPRADIO_POKEMON_MUSIC
const MAPRADIO_LUCKY_CHANNEL
const MAPRADIO_UNOWN
const MAPRADIO_PLACES_PEOPLE
diff --git a/constants/text_constants.asm b/constants/text_constants.asm
index 27c42ed92..a6052065c 100644
--- a/constants/text_constants.asm
+++ b/constants/text_constants.asm
@@ -1,16 +1,16 @@
; name lengths
-NAME_LENGTH EQU 11
-PLAYER_NAME_LENGTH EQU 8
-BOX_NAME_LENGTH EQU 9
-PKMN_NAME_LENGTH EQU 11
-MOVE_NAME_LENGTH EQU 13
-ITEM_NAME_LENGTH EQU 13
+NAME_LENGTH EQU 11
+PLAYER_NAME_LENGTH EQU 8
+BOX_NAME_LENGTH EQU 9
+MON_NAME_LENGTH EQU 11
+MOVE_NAME_LENGTH EQU 13
+ITEM_NAME_LENGTH EQU 13
TRAINER_CLASS_NAME_LENGTH EQU 13
NAME_LENGTH_JAPANESE EQU 6
; GetName types (see home/names.asm)
const_value set 1
- const PKMN_NAME ; 1
+ const MON_NAME ; 1
const MOVE_NAME ; 2
const DUMMY_NAME ; 3
const ITEM_NAME ; 4
diff --git a/docs/bugs_and_glitches.md b/docs/bugs_and_glitches.md
index 2cd47c540..54f22c3df 100644
--- a/docs/bugs_and_glitches.md
+++ b/docs/bugs_and_glitches.md
@@ -746,7 +746,7 @@ Data_DaisyMassage: ; 746b
CopyPokemonName_Buffer1_Buffer3: ; 746e
ld hl, StringBuffer1
ld de, StringBuffer3
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
jp CopyBytes
```
diff --git a/engine/battle/core.asm b/engine/battle/core.asm
index e8abea583..1a58b3df5 100644
--- a/engine/battle/core.asm
+++ b/engine/battle/core.asm
@@ -3989,7 +3989,7 @@ InitBattleMon: ; 3da0d
ld a, [CurBattleMon]
call SkipNames
ld de, BattleMonNick
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ld hl, BattleMonAttack
ld de, PlayerStats
@@ -4074,7 +4074,7 @@ InitEnemyMon: ; 3dabd
ld a, [CurPartyMon]
call SkipNames
ld de, EnemyMonNick
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ld hl, EnemyMonAttack
ld de, EnemyStats
@@ -6578,7 +6578,7 @@ LoadEnemyMon: ; 3e8eb
; Update enemy nick
ld hl, StringBuffer1
ld de, EnemyMonNick
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
; Saw this mon
@@ -7766,7 +7766,7 @@ AnimateExpBar: ; 3f136
call PrintPlayerHUD
ld hl, BattleMonNick
ld de, StringBuffer1
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
call TerminateExpBarSound
ld de, SFX_HIT_END_OF_EXP_BAR
diff --git a/engine/billspc.asm b/engine/billspc.asm
index 458192c3c..5fa590c41 100755
--- a/engine/billspc.asm
+++ b/engine/billspc.asm
@@ -1331,11 +1331,11 @@ BillsPC_RefreshTextboxes: ; e2c2c (38:6c2c)
jr z, .boxfail
ld bc, sBoxMonNicknames - sBox
add hl, bc
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld a, e
call AddNTimes
ld de, StringBuffer1
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
call CloseSRAM
pop hl
@@ -1357,11 +1357,11 @@ BillsPC_RefreshTextboxes: ; e2c2c (38:6c2c)
and a
jr z, .partyfail
ld hl, PartyMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld a, e
call AddNTimes
ld de, StringBuffer1
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
pop hl
ld de, StringBuffer1
@@ -1383,11 +1383,11 @@ BillsPC_RefreshTextboxes: ; e2c2c (38:6c2c)
and a
jr z, .sBoxFail
ld hl, sBoxMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld a, e
call AddNTimes
ld de, StringBuffer1
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
call CloseSRAM
pop hl
@@ -2171,11 +2171,11 @@ CopySpeciesToTemp: ; e3357 (38:7357)
ret
CopyNicknameToTemp: ; e3363 (38:7363)
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld a, [CurPartyMon]
call AddNTimes
ld de, wBufferMonNick
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ret
diff --git a/engine/breeding.asm b/engine/breeding.asm
index 489154f71..b16747089 100755
--- a/engine/breeding.asm
+++ b/engine/breeding.asm
@@ -320,7 +320,7 @@ HatchEggs: ; 16f70 (5:6f70)
call PrintText
ld a, [CurPartyMon]
ld hl, PartyMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call AddNTimes
ld d, h
ld e, l
@@ -345,7 +345,7 @@ HatchEggs: ; 16f70 (5:6f70)
.nonickname
ld hl, StringBuffer1
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
.next ; 1707d (5:707d)
diff --git a/engine/caught_data.asm b/engine/caught_data.asm
index 56ef8a839..9310b7b90 100644
--- a/engine/caught_data.asm
+++ b/engine/caught_data.asm
@@ -42,7 +42,7 @@ Special_CheckPartyFullAfterContest: ; 4d9e5
call GetPokemonName
ld hl, StringBuffer1
ld de, wMonOrItemNameBuffer
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
call GiveANickname_YesNo
jr c, .Party_SkipNickname
@@ -120,7 +120,7 @@ Special_CheckPartyFullAfterContest: ; 4d9e5
ld a, BANK(sBoxMonNicknames)
call GetSRAMBank
ld de, sBoxMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
call CloseSRAM
diff --git a/engine/color.asm b/engine/color.asm
index d0dd0c3c8..485125821 100644
--- a/engine/color.asm
+++ b/engine/color.asm
@@ -1195,7 +1195,8 @@ PredefPals:
INCLUDE "gfx/sgb/predef.pal"
SGBBorderMap:
-INCBIN "gfx/sgb/sgb_border.tilemap"
+; interleaved tile ids and palette ids
+INCBIN "gfx/sgb/sgb_border.bin"
SGBBorderPalettes:
INCLUDE "gfx/sgb/sgb_border.pal"
diff --git a/engine/events/battle_tower/battle_tower.asm b/engine/events/battle_tower/battle_tower.asm
index dcf4d5ccf..94a29cdab 100755
--- a/engine/events/battle_tower/battle_tower.asm
+++ b/engine/events/battle_tower/battle_tower.asm
@@ -285,7 +285,7 @@ ReadBTTrainerParty: ; 1702b7
; Check the nicknames for illegal characters, and replace bad nicknames
; with their species names.
ld de, wBT_OTTempPkmn1Name ; $c643
- ld c, PKMN_NAME_LENGTH
+ ld c, MON_NAME_LENGTH
farcall CheckStringForErrors
jr nc, .skip_mon_1
@@ -295,12 +295,12 @@ ReadBTTrainerParty: ; 1702b7
ld l, e
ld h, d
ld de, wBT_OTTempPkmn1Name ; $c643
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
.skip_mon_1
ld de, wBT_OTTempPkmn2Name ; $c67e
- ld c, PKMN_NAME_LENGTH
+ ld c, MON_NAME_LENGTH
farcall CheckStringForErrors
jr nc, .skip_mon_2
ld a, [wBT_OTTempPkmn2] ; [$c64e]
@@ -309,12 +309,12 @@ ReadBTTrainerParty: ; 1702b7
ld l, e
ld h, d
ld de, wBT_OTTempPkmn2Name ; $c67e
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
.skip_mon_2
ld de, wBT_OTTempPkmn3Name ; $c686 + 51 = $c6b9
- ld c, PKMN_NAME_LENGTH
+ ld c, MON_NAME_LENGTH
farcall CheckStringForErrors
jr nc, .skip_mon_3
ld a, [wBT_OTTempPkmn3] ; [$c689]
@@ -323,7 +323,7 @@ ReadBTTrainerParty: ; 1702b7
ld l, e
ld h, d
ld de, wBT_OTTempPkmn3Name ; $c686 + 51 = $c6b9
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
.skip_mon_3
@@ -363,7 +363,7 @@ ReadBTTrainerParty: ; 1702b7
; Copy Pkmn into Memory from the address in hl
ld de, OTPartyMon1Species
ld bc, OTPartyCount
- ld a, BATTLETOWER_PARTY_SIZE
+ ld a, BATTLETOWER_PARTY_LENGTH
ld [bc], a
inc bc
.otpartymon_loop
@@ -379,7 +379,7 @@ ReadBTTrainerParty: ; 1702b7
ld e, a
ld a, [BGMapBuffer + 1]
ld d, a
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ld a, e
ld [BGMapBuffer], a
@@ -399,7 +399,7 @@ ReadBTTrainerParty: ; 1702b7
ValidateBTParty: ; 170394
; Check for and fix errors in party data
ld hl, wBT_OTTempPkmn1Species
- ld d, BATTLETOWER_PARTY_SIZE
+ ld d, BATTLETOWER_PARTY_LENGTH
.pkmn_loop
push de
push hl
@@ -495,7 +495,7 @@ endr
ld a, [hl]
ld [de], a
pop hl
- ld bc, PARTYMON_STRUCT_LENGTH + PKMN_NAME_LENGTH
+ ld bc, PARTYMON_STRUCT_LENGTH + MON_NAME_LENGTH
add hl, bc
pop de
dec d
@@ -509,7 +509,7 @@ BT_ChrisName: ; 170426
Function17042c: ; 17042c
ld hl, w3_d202TrainerData
- ld a, BATTLETOWER_STREAK_SIZE
+ ld a, BATTLETOWER_STREAK_LENGTH
.loop
push af
push hl
@@ -956,7 +956,7 @@ ResetBattleTowerTrainersSRAM: ; 1706d6 (5c:46d6) BattleTowerAction $1a
ld a, $ff
ld hl, sBTTrainers
- ld bc, BATTLETOWER_STREAK_SIZE
+ ld bc, BATTLETOWER_STREAK_LENGTH
call ByteFill
xor a
diff --git a/engine/events/battle_tower/load_trainer.asm b/engine/events/battle_tower/load_trainer.asm
index a7a978311..e0e4a5ca1 100644
--- a/engine/events/battle_tower/load_trainer.asm
+++ b/engine/events/battle_tower/load_trainer.asm
@@ -41,7 +41,7 @@ endc
ld a, BANK(sBTTrainers)
call GetSRAMBank
- ld c, BATTLETOWER_STREAK_SIZE
+ ld c, BATTLETOWER_STREAK_LENGTH
ld hl, sBTTrainers
.next_trainer
ld a, [hli]
@@ -93,7 +93,7 @@ endc
Function_LoadRandomBattleTowerPkmn: ; 1f8081
- ld c, BATTLETOWER_PARTY_SIZE
+ ld c, BATTLETOWER_PARTY_LENGTH
.loop
push bc
ld a, BANK(sBTPkmnPrevTrainer1)
@@ -123,7 +123,7 @@ Function_LoadRandomBattleTowerPkmn: ; 1f8081
; Check if Pkmn was already loaded before
; Check current and the 2 previous teams
; includes check if item is double at the current team
- ld bc, PARTYMON_STRUCT_LENGTH + PKMN_NAME_LENGTH
+ ld bc, PARTYMON_STRUCT_LENGTH + MON_NAME_LENGTH
call AddNTimes
ld a, [hli]
ld b, a
@@ -166,13 +166,13 @@ Function_LoadRandomBattleTowerPkmn: ; 1f8081
cp b
jr z, .FindARandomBattleTowerPkmn
- ld bc, PARTYMON_STRUCT_LENGTH + PKMN_NAME_LENGTH
+ ld bc, PARTYMON_STRUCT_LENGTH + MON_NAME_LENGTH
call CopyBytes
ld a, [wNamedObjectIndexBuffer]
push af
push de
- ld hl, - (PARTYMON_STRUCT_LENGTH + PKMN_NAME_LENGTH)
+ ld hl, - (PARTYMON_STRUCT_LENGTH + MON_NAME_LENGTH)
add hl, de
ld a, [hl]
ld [wNamedObjectIndexBuffer], a
@@ -183,7 +183,7 @@ Function_LoadRandomBattleTowerPkmn: ; 1f8081
ld h, d
ld l, e
pop de
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
pop de
diff --git a/engine/events/battle_tower/rules.asm b/engine/events/battle_tower/rules.asm
index b41c51078..0e994c27e 100644
--- a/engine/events/battle_tower/rules.asm
+++ b/engine/events/battle_tower/rules.asm
@@ -213,7 +213,7 @@ BattleTower_ExecuteJumptable: ; 8b25b
BattleTower_CheckPartyLengthIs3: ; 8b2bb
ld a, [PartyCount]
- cp BATTLETOWER_PARTY_SIZE
+ cp BATTLETOWER_PARTY_LENGTH
ret
; 8b2c1
@@ -235,13 +235,13 @@ BattleTower_CheckPartyHasThreeMonsThatAreNotEggs: ; 8b2c1
cp b
ret z
ld a, b
- cp BATTLETOWER_PARTY_SIZE
+ cp BATTLETOWER_PARTY_LENGTH
ret
; 8b2da
Function_PartyCountEq3: ; 8b2da
ld a, [PartyCount]
- cp BATTLETOWER_PARTY_SIZE
+ cp BATTLETOWER_PARTY_LENGTH
ret z
scf
ret
diff --git a/engine/events/daycare.asm b/engine/events/daycare.asm
index a7eb565bb..f65464a8d 100755
--- a/engine/events/daycare.asm
+++ b/engine/events/daycare.asm
@@ -531,7 +531,7 @@ DayCare_GiveEgg: ; 169ac
ld [hl], a
ld hl, PartyMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call DayCare_GetCurrentPartyMember
ld hl, wEggNick
call CopyBytes
@@ -620,7 +620,7 @@ DayCare_InitBreeding: ; 16a3b
ld bc, wEggMonEnd - wEggMon
call ByteFill
ld hl, wEggNick
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call ByteFill
ld hl, wEggOT
ld bc, NAME_LENGTH
diff --git a/engine/events/halloffame.asm b/engine/events/halloffame.asm
index ce6e5ddc7..dbd3a2d5a 100755
--- a/engine/events/halloffame.asm
+++ b/engine/events/halloffame.asm
@@ -208,9 +208,9 @@ GetHallOfFameParty: ; 8653f
push bc
ld a, c
ld hl, PartyMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call AddNTimes
- ld bc, PKMN_NAME_LENGTH - 1
+ ld bc, MON_NAME_LENGTH - 1
call CopyBytes
pop bc
@@ -460,7 +460,7 @@ DisplayHOFMon: ; 86748
ld a, [hli]
ld [TempMonLevel], a
ld de, StringBuffer2
- ld bc, PKMN_NAME_LENGTH - 1
+ ld bc, MON_NAME_LENGTH - 1
call CopyBytes
ld a, "@"
ld [StringBuffer2 + 10], a
diff --git a/engine/events/name_rater.asm b/engine/events/name_rater.asm
index 771c5090a..796647f48 100644
--- a/engine/events/name_rater.asm
+++ b/engine/events/name_rater.asm
@@ -45,13 +45,13 @@ NameRater: ; fb6ed
jr c, .samename
; Copy the new name from StringBuffer2
ld hl, PartyMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld a, [CurPartyMon]
call AddNTimes
ld e, l
ld d, h
ld hl, StringBuffer2
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ld hl, NameRaterEvenBetterText
@@ -115,7 +115,7 @@ CheckIfMonIsYourOT: ; fb78a
IsNewNameEmpty: ; fb7be
; Checks to see if the nickname loaded in StringBuffer2 is empty. If so, return carry.
ld hl, StringBuffer2
- ld c, PKMN_NAME_LENGTH - 1
+ ld c, MON_NAME_LENGTH - 1
.loop
ld a, [hli]
cp "@"
@@ -137,7 +137,7 @@ IsNewNameEmpty: ; fb7be
CompareNewToOld: ; fb7d3
; Compares the nickname in StringBuffer2 to the previous nickname. If they are the same, return carry.
ld hl, PartyMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld a, [CurPartyMon]
call AddNTimes
push hl
@@ -178,7 +178,7 @@ GetNicknameLength: ; fb802
ret z
inc c
ld a, c
- cp PKMN_NAME_LENGTH - 1
+ cp MON_NAME_LENGTH - 1
jr nz, .loop
ret
; fb80f
diff --git a/engine/events/odd_egg.asm b/engine/events/odd_egg.asm
index 4cbeb34dc..de3107804 100644
--- a/engine/events/odd_egg.asm
+++ b/engine/events/odd_egg.asm
@@ -43,7 +43,7 @@ GiveOddEgg: ; 1fb4b6
call AddNTimes
ld de, OddEggSpecies
- ld bc, PARTYMON_STRUCT_LENGTH + 2 * PKMN_NAME_LENGTH
+ ld bc, PARTYMON_STRUCT_LENGTH + 2 * MON_NAME_LENGTH
call CopyBytes
ld a, EGG_TICKET
@@ -73,7 +73,7 @@ GiveOddEgg: ; 1fb4b6
; load Odd Egg Name in wTempOddEggNickname
ld hl, .Odd
ld de, wTempOddEggNickname
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
; load pointer to wTempOddEggNickname in wMobileMonOTNamePointerBuffer
diff --git a/engine/events/poke_seer.asm b/engine/events/poke_seer.asm
index c7e6bd5ee..fb9c6d9f9 100644
--- a/engine/events/poke_seer.asm
+++ b/engine/events/poke_seer.asm
@@ -148,10 +148,10 @@ ReadCaughtData: ; 4f134
GetCaughtName: ; 4f176
ld a, [CurPartyMon]
ld hl, PartyMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call AddNTimes
ld de, wSeerNickname
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ret
; 4f18c
diff --git a/engine/events/special.asm b/engine/events/special.asm
index 6238acc44..128e7af29 100755
--- a/engine/events/special.asm
+++ b/engine/events/special.asm
@@ -228,7 +228,7 @@ Data_DaisyMassage: ; 746b
CopyPokemonName_Buffer1_Buffer3: ; 746e
ld hl, StringBuffer1
ld de, StringBuffer3
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
jp CopyBytes
DummyPredef1: ; 747a
diff --git a/engine/evolve.asm b/engine/evolve.asm
index aac0c68eb..2e72320d4 100755
--- a/engine/evolve.asm
+++ b/engine/evolve.asm
@@ -371,7 +371,7 @@ UpdateSpeciesNameIfNotNicknamed: ; 42414
jr nz, .loop
ld a, [CurPartyMon]
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld hl, PartyMonNicknames
call AddNTimes
push hl
@@ -380,7 +380,7 @@ UpdateSpeciesNameIfNotNicknamed: ; 42414
call GetPokemonName
ld hl, StringBuffer1
pop de
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
jp CopyBytes
; 42454
diff --git a/engine/item_effects.asm b/engine/item_effects.asm
index 29815a56e..c2bdd1f61 100644
--- a/engine/item_effects.asm
+++ b/engine/item_effects.asm
@@ -599,7 +599,7 @@ ParkBall: ; e8a2
dec a
ld [CurPartyMon], a
ld hl, PartyMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call AddNTimes
ld d, h
@@ -668,7 +668,7 @@ ParkBall: ; e8a2
ld hl, wMonOrItemNameBuffer
ld de, sBoxMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ld hl, sBoxMonNicknames
@@ -683,7 +683,7 @@ ParkBall: ; e8a2
ld hl, sBoxMonNicknames
ld de, wMonOrItemNameBuffer
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
call CloseSRAM
diff --git a/engine/learn.asm b/engine/learn.asm
index d2751235f..2f1038d7f 100755
--- a/engine/learn.asm
+++ b/engine/learn.asm
@@ -5,7 +5,7 @@ LearnMove: ; 6508
call GetNick
ld hl, StringBuffer1
ld de, wMonOrItemNameBuffer
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
.loop
diff --git a/engine/link.asm b/engine/link.asm
index 19559798d..86a593284 100755
--- a/engine/link.asm
+++ b/engine/link.asm
@@ -831,7 +831,7 @@ Link_PrepPartyData_Gen2: ; 28595
ld bc, PARTY_LENGTH * NAME_LENGTH
call CopyBytes
ld hl, PartyMonNicknames
- ld bc, PARTY_LENGTH * PKMN_NAME_LENGTH
+ ld bc, PARTY_LENGTH * MON_NAME_LENGTH
call CopyBytes
; Okay, we did all that. Now, are we in the trade center?
@@ -978,7 +978,7 @@ Function2868a: ; 2868a
ld bc, PARTY_LENGTH * NAME_LENGTH
call CopyBytes
ld de, OTPartyMonNicknames
- ld bc, PARTY_LENGTH * PKMN_NAME_LENGTH
+ ld bc, PARTY_LENGTH * MON_NAME_LENGTH
jp CopyBytes
; 286ba
@@ -1657,7 +1657,7 @@ LinkTrade: ; 28b87
call GetPokemonName
ld hl, StringBuffer1
ld de, wd004
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ld a, [wd003]
ld hl, OTPartySpecies
diff --git a/engine/link_trade.asm b/engine/link_trade.asm
index ae84a7beb..504dc6d95 100755
--- a/engine/link_trade.asm
+++ b/engine/link_trade.asm
@@ -283,7 +283,7 @@ LinkTradeMenu: ; 16d70c
ld [hl], a
push hl
push bc
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
add hl, bc
ld [hl], a
pop bc
@@ -335,7 +335,7 @@ LinkTradeMenu: ; 16d70c
ld [hl], $1f
push hl
push bc
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
add hl, bc
ld [hl], $1f
pop bc
diff --git a/engine/move_mon.asm b/engine/move_mon.asm
index 91ac2f207..52894359e 100755
--- a/engine/move_mon.asm
+++ b/engine/move_mon.asm
@@ -60,7 +60,7 @@ TryAddMonToParty: ; d88c
ld d, h
ld e, l
ld hl, StringBuffer1
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
.skipnickname
@@ -397,7 +397,7 @@ AddTempmonToParty: ; da96
ld hl, OTPartyMonNicknames
ld a, [CurPartyMon]
call SkipNames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ld a, [CurPartySpecies]
@@ -583,7 +583,7 @@ SendGetPkmnIntoFromBox: ; db3f
call SkipNames
.okay12
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
pop hl
@@ -943,7 +943,7 @@ SendPkmnIntoBox: ; de6e
ld de, sBoxMonNicknames
ld hl, StringBuffer1
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ld hl, EnemyMon
@@ -1044,7 +1044,7 @@ ShiftBoxMon: ; df47
call .shift
ld hl, sBoxMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call .shift
ld hl, sBoxMons
@@ -1240,7 +1240,7 @@ RemoveMonFromPartyOrBox: ; e039
; Shift the OT names
ld d, h
ld e, l
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
add hl, bc
ld bc, PartyMonNicknames
ld a, [wPokemonWithdrawDepositParameter]
@@ -1283,12 +1283,12 @@ RemoveMonFromPartyOrBox: ; e039
jr z, .party6
ld hl, sBoxMonNicknames
.party6
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld a, [CurPartyMon]
call AddNTimes
ld d, h
ld e, l
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
add hl, bc
ld bc, PartyMonNicknamesEnd
ld a, [wPokemonWithdrawDepositParameter]
@@ -1652,7 +1652,7 @@ GivePoke:: ; e277
call GetPokemonName
ld hl, StringBuffer1
ld de, wMonOrItemNameBuffer
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
pop af
and a
@@ -1664,7 +1664,7 @@ GivePoke:: ; e277
push hl
ld a, [ScriptBank]
call GetFarHalfword
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld a, [ScriptBank]
call FarCopyBytes
pop hl
@@ -1764,7 +1764,7 @@ GivePoke:: ; e277
call GetSRAMBank
ld hl, wMonOrItemNameBuffer
ld de, sBoxMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
call CloseSRAM
ld b, $1
diff --git a/engine/move_mon_wo_mail.asm b/engine/move_mon_wo_mail.asm
index c96823d28..e5e1d6e49 100755
--- a/engine/move_mon_wo_mail.asm
+++ b/engine/move_mon_wo_mail.asm
@@ -7,7 +7,7 @@ InsertPokemonIntoBox: ; 51322
dec a
ld [wd265], a
ld hl, sBoxMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld de, wBufferMonNick
call InsertDataIntoBoxOrParty
ld a, [sBoxCount]
@@ -44,7 +44,7 @@ InsertPokemonIntoParty: ; 5138b
dec a
ld [wd265], a
ld hl, PartyMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld de, wBufferMonNick
call InsertDataIntoBoxOrParty
ld a, [PartyCount]
diff --git a/engine/namingscreen.asm b/engine/namingscreen.asm
index 331fff37c..f9832dd98 100755
--- a/engine/namingscreen.asm
+++ b/engine/namingscreen.asm
@@ -254,7 +254,7 @@ NamingScreen: ; 116c1
ret
.StoreMonIconParams: ; 1187b (4:587b)
- ld a, PKMN_NAME_LENGTH - 1
+ ld a, MON_NAME_LENGTH - 1
hlcoord 5, 6
jr .StoreParams
diff --git a/engine/npctrade.asm b/engine/npctrade.asm
index a9055a15d..40f6dd638 100755
--- a/engine/npctrade.asm
+++ b/engine/npctrade.asm
@@ -206,7 +206,7 @@ DoNPCTrade: ; fcc63
call CopyTradeName
ld hl, PartyMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call Trade_GetAttributeOfLastPartymon
ld hl, wOTTrademonNickname
call CopyTradeName
diff --git a/engine/pack.asm b/engine/pack.asm
index f6f67845b..f9c7490af 100644
--- a/engine/pack.asm
+++ b/engine/pack.asm
@@ -630,7 +630,7 @@ GiveItem: ; 103fd
call GetCurNick
ld hl, StringBuffer1
ld de, wMonOrItemNameBuffer
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
call TryGiveItemToPartymon
pop af
diff --git a/engine/party_menu.asm b/engine/party_menu.asm
index 33186170a..5ef9b50de 100644
--- a/engine/party_menu.asm
+++ b/engine/party_menu.asm
@@ -524,7 +524,7 @@ PlacePartyMonMobileBattleSelection: ; 50307
dec c
jr nz, .loop
ld a, l
- ld e, PKMN_NAME_LENGTH
+ ld e, MON_NAME_LENGTH
sub e
ld l, a
ld a, h
diff --git a/engine/pokegear.asm b/engine/pokegear.asm
index 5bb63b897..f65f394be 100755
--- a/engine/pokegear.asm
+++ b/engine/pokegear.asm
@@ -2093,7 +2093,7 @@ PlayRadio: ; 91a53
; 91ab9
.StationPointers: ; 91ab9
-; entries correspond to radio station constants
+; entries correspond to MAPRADIO_* constants
dw .OakOrPnP
dw LoadStation_OaksPokemonTalk
dw LoadStation_PokedexShow
diff --git a/engine/printer.asm b/engine/printer.asm
index 002620606..4479d5d0b 100755
--- a/engine/printer.asm
+++ b/engine/printer.asm
@@ -774,10 +774,10 @@ Printer_PrintBoxListSegment: ; 848e7 (21:48e7)
pop hl
jr z, .ok2
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
add hl, bc
call Printer_GetMonGender
- ld bc, SCREEN_WIDTH - PKMN_NAME_LENGTH
+ ld bc, SCREEN_WIDTH - MON_NAME_LENGTH
add hl, bc
ld a, "/"
ld [hli], a
@@ -795,7 +795,7 @@ Printer_PrintBoxListSegment: ; 848e7 (21:48e7)
ld h, a
ld bc, sBoxMonNicknames - sBox
add hl, bc
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld a, [wWhichBoxMonToPrint]
call AddNTimes
ld e, l
@@ -806,7 +806,7 @@ Printer_PrintBoxListSegment: ; 848e7 (21:48e7)
call PlaceString
pop hl
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
add hl, bc
push hl
ld a, [wAddrOfBoxToPrint]
diff --git a/engine/radio.asm b/engine/radio.asm
index 54da69255..df0d81679 100644
--- a/engine/radio.asm
+++ b/engine/radio.asm
@@ -273,7 +273,7 @@ endr
call GetPokemonName
ld hl, StringBuffer1
ld de, wMonOrItemNameBuffer
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
; Now that we've chosen our wild Pokemon,
diff --git a/engine/routines/checknickerrors.asm b/engine/routines/checknickerrors.asm
index 245c28586..87ebd6bb3 100644
--- a/engine/routines/checknickerrors.asm
+++ b/engine/routines/checknickerrors.asm
@@ -6,7 +6,7 @@ CheckNickErrors:: ; 669f
push bc
push de
- ld b, PKMN_NAME_LENGTH
+ ld b, MON_NAME_LENGTH
.checkchar
; end of nick?
diff --git a/engine/routines/correcterrorsinplayerparty.asm b/engine/routines/correcterrorsinplayerparty.asm
index 639e5c544..42e550900 100644
--- a/engine/routines/correcterrorsinplayerparty.asm
+++ b/engine/routines/correcterrorsinplayerparty.asm
@@ -128,7 +128,7 @@ Unreferenced_CorrectErrorsInPlayerParty:
ld hl, StringBuffer1
.got_nickname
pop de
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
pop bc
diff --git a/engine/routines/initlist.asm b/engine/routines/initlist.asm
index e2b7235ab..b7260e552 100644
--- a/engine/routines/initlist.asm
+++ b/engine/routines/initlist.asm
@@ -21,7 +21,7 @@ InitList: ; 50db9
jr nz, .check_item_name
ld hl, CurMart
ld de, PokemonNames
- ld a, PKMN_NAME
+ ld a, MON_NAME
jr .done
.check_item_name
diff --git a/engine/start_menu.asm b/engine/start_menu.asm
index 88b7ee853..c0c4a38a3 100755
--- a/engine/start_menu.asm
+++ b/engine/start_menu.asm
@@ -798,7 +798,7 @@ GiveTakePartyMonItem: ; 12b60
call GetCurNick
ld hl, StringBuffer1
ld de, wMonOrItemNameBuffer
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ld a, [wMenuCursorY]
cp 1
diff --git a/engine/stats_screen.asm b/engine/stats_screen.asm
index cb677ada4..a65cecc8a 100755
--- a/engine/stats_screen.asm
+++ b/engine/stats_screen.asm
@@ -1117,7 +1117,7 @@ StatsScreen_LoadPageIndicators: ; 4e4cd (13:64cd)
CopyNickname: ; 4e505 (13:6505)
ld de, StringBuffer1
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
jr .okay ; utterly pointless
.okay
ld a, [MonType]
diff --git a/engine/wildmons.asm b/engine/wildmons.asm
index 6634d7586..50d4ea250 100755
--- a/engine/wildmons.asm
+++ b/engine/wildmons.asm
@@ -913,7 +913,7 @@ Special_RandomPhoneWildMon: ; 2a51f
call GetPokemonName
ld hl, StringBuffer1
ld de, StringBuffer4
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
jp CopyBytes
; 2a567
@@ -997,7 +997,7 @@ Special_RandomPhoneMon: ; 2a567
call GetPokemonName
ld hl, StringBuffer1
ld de, StringBuffer4
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
jp CopyBytes
; 2a5e9
diff --git a/gfx/sgb/sgb_border.tilemap b/gfx/sgb/sgb_border.bin
index 362eae929..362eae929 100644
--- a/gfx/sgb/sgb_border.tilemap
+++ b/gfx/sgb/sgb_border.bin
diff --git a/home.asm b/home.asm
index 378f85a14..35968744d 100644
--- a/home.asm
+++ b/home.asm
@@ -1207,7 +1207,7 @@ GetNick:: ; 38a2
ld de, StringBuffer1
push de
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
pop de
diff --git a/home/names.asm b/home/names.asm
index 9c39c0e72..37ce4f37d 100644
--- a/home/names.asm
+++ b/home/names.asm
@@ -1,6 +1,6 @@
NamesPointers:: ; 33ab
; entries correspond to GetName constants (see constants/text_constants.asm)
- dba PokemonNames ; PKMN_NAME (not used; jumps to GetPokemonName)
+ dba PokemonNames ; MON_NAME (not used; jumps to GetPokemonName)
dba MoveNames ; MOVE_NAME
dbw 0, NULL ; DUMMY_NAME
dba ItemNames ; ITEM_NAME
@@ -20,13 +20,13 @@ GetName:: ; 33c3
push de
ld a, [wNamedObjectTypeBuffer]
- cp PKMN_NAME
+ cp MON_NAME
jr nz, .NotPokeName
ld a, [CurSpecies]
ld [wd265], a
call GetPokemonName
- ld hl, PKMN_NAME_LENGTH
+ ld hl, MON_NAME_LENGTH
add hl, de
ld e, l
ld d, h
@@ -140,9 +140,9 @@ GetPokemonName:: ; 343b
; Terminator
ld de, StringBuffer1
push de
- ld bc, PKMN_NAME_LENGTH - 1
+ ld bc, MON_NAME_LENGTH - 1
call CopyBytes
- ld hl, StringBuffer1 + PKMN_NAME_LENGTH - 1
+ ld hl, StringBuffer1 + MON_NAME_LENGTH - 1
ld [hl], "@"
pop de
diff --git a/macros/wram.asm b/macros/wram.asm
index a889193d4..47138e40c 100755
--- a/macros/wram.asm
+++ b/macros/wram.asm
@@ -110,7 +110,7 @@ box: MACRO
\1Mon1:: box_struct \1Mon1
\1Mon2:: ds BOXMON_STRUCT_LENGTH * (MONS_PER_BOX +- 1)
\1MonOT:: ds NAME_LENGTH * MONS_PER_BOX
-\1MonNicknames:: ds PKMN_NAME_LENGTH * MONS_PER_BOX
+\1MonNicknames:: ds MON_NAME_LENGTH * MONS_PER_BOX
\1MonNicknamesEnd::
\1End:: ds 2 ; padding
ENDM
@@ -179,13 +179,13 @@ battle_tower_struct: MACRO
\1Name:: ds NAME_LENGTH +- 1
\1TrainerClass:: ds 1
\1Pkmn1:: party_struct \1Pkmn1
-\1Pkmn1Name:: ds PKMN_NAME_LENGTH
+\1Pkmn1Name:: ds MON_NAME_LENGTH
\1Pkmn1NameEnd::
\1Pkmn2:: party_struct \1Pkmn2
-\1Pkmn2Name:: ds PKMN_NAME_LENGTH
+\1Pkmn2Name:: ds MON_NAME_LENGTH
\1Pkmn2NameEnd::
\1Pkmn3:: party_struct \1Pkmn3
-\1Pkmn3Name:: ds PKMN_NAME_LENGTH
+\1Pkmn3Name:: ds MON_NAME_LENGTH
\1Pkmn3NameEnd::
\1TrainerData:: ds BATTLETOWER_TRAINERDATALENGTH
\1TrainerEnd::
@@ -222,7 +222,7 @@ hof_mon: MACRO
\1ID:: dw
\1DVs:: dw
\1Level:: db
-\1Nickname:: ds PKMN_NAME_LENGTH +- 1
+\1Nickname:: ds MON_NAME_LENGTH +- 1
\1End::
ENDM
@@ -247,8 +247,8 @@ ENDM
trademon: MACRO
\1Species:: db ; wc6d0 | wc702
-\1SpeciesName:: ds PKMN_NAME_LENGTH ; wc6d1 | wc703
-\1Nickname:: ds PKMN_NAME_LENGTH ; wc6dc | wc70e
+\1SpeciesName:: ds MON_NAME_LENGTH ; wc6d1 | wc703
+\1Nickname:: ds MON_NAME_LENGTH ; wc6dc | wc70e
\1SenderName:: ds NAME_LENGTH ; wc6e7 | wc719
\1OTName:: ds NAME_LENGTH ; wc6f2 | wc724
\1DVs:: dw ; wc6fd | wc72f
diff --git a/maps/BattleTowerBattleRoom.asm b/maps/BattleTowerBattleRoom.asm
index 8fcc8dba4..dd8e08e0f 100644
--- a/maps/BattleTowerBattleRoom.asm
+++ b/maps/BattleTowerBattleRoom.asm
@@ -37,7 +37,7 @@ Script_BattleRoomLoop: ; 0x9f425
reloadmap
if_not_equal $0, Script_FailedBattleTowerChallenge
copybytetovar wNrOfBeatenBattleTowerTrainers ; wcf64
- if_equal BATTLETOWER_STREAK_SIZE, Script_BeatenAllTrainers
+ if_equal BATTLETOWER_STREAK_LENGTH, Script_BeatenAllTrainers
applymovement BATTLETOWERBATTLEROOM_YOUNGSTER, MovementData_BattleTowerBattleRoomOpponentWalksOut
warpsound
disappear BATTLETOWERBATTLEROOM_YOUNGSTER
diff --git a/mobile/fixed_words.asm b/mobile/fixed_words.asm
index 922e89455..a57722747 100755
--- a/mobile/fixed_words.asm
+++ b/mobile/fixed_words.asm
@@ -270,7 +270,7 @@ CopyMobileEZChatToC608: ; 11c156
ld [wd265], a
call GetPokemonName
ld hl, StringBuffer1
- ld bc, PKMN_NAME_LENGTH - 1
+ ld bc, MON_NAME_LENGTH - 1
jr .copy_string
; 11c1ab
diff --git a/mobile/mobile_40.asm b/mobile/mobile_40.asm
index 68d554b7e..48751e4fa 100644
--- a/mobile/mobile_40.asm
+++ b/mobile/mobile_40.asm
@@ -2529,7 +2529,7 @@ Unknown_100fc0: ; 100fc0
dbwww $80, PlayerID, 2, OTPlayerID
dbwww $80, PartyMons, PARTYMON_STRUCT_LENGTH * PARTY_LENGTH, OTPartyMons
dbwww $80, PartyMonOT, NAME_LENGTH * PARTY_LENGTH, OTPartyMonOT
- dbwww $80, PartyMonNicknames, PKMN_NAME_LENGTH * PARTY_LENGTH, OTPartyMonNicknames
+ dbwww $80, PartyMonNicknames, MON_NAME_LENGTH * PARTY_LENGTH, OTPartyMonNicknames
db -1
Unknown_100feb: ; 100feb
@@ -2550,7 +2550,7 @@ Unknown_100ff3: ; 100ff3
Unknown_10102c: ; 10102c
dbwww $80, OTPlayerName, NAME_LENGTH, NULL
dbwww $80, OTPlayerID, 2, NULL
- dbwww $80, OTPartyMonNicknames, PKMN_NAME_LENGTH * PARTY_LENGTH, NULL
+ dbwww $80, OTPartyMonNicknames, MON_NAME_LENGTH * PARTY_LENGTH, NULL
dbwww $80, OTPartyMonOT, NAME_LENGTH * PARTY_LENGTH, NULL
dbwww $80, OTPartyMons, PARTYMON_STRUCT_LENGTH * PARTY_LENGTH, NULL
db -1
diff --git a/mobile/mobile_42.asm b/mobile/mobile_42.asm
index 4b09c366c..ff815df3e 100644
--- a/mobile/mobile_42.asm
+++ b/mobile/mobile_42.asm
@@ -337,7 +337,7 @@ MobileTradeAnim_InitSpeciesName: ; 108239
call GetPokemonName
ld hl, StringBuffer1
pop de
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ret
; 10824b
diff --git a/mobile/mobile_46.asm b/mobile/mobile_46.asm
index 05c859622..8090c3a9b 100755
--- a/mobile/mobile_46.asm
+++ b/mobile/mobile_46.asm
@@ -4084,7 +4084,7 @@ BattleTower_UbersCheck: ; 119dd1 (46:5dd1)
call GetPokemonName
ld hl, StringBuffer1
ld de, wcd49
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
call CopyBytes
ld a, $a
ld [wcf66], a
@@ -7839,13 +7839,13 @@ AddMobileMonToParty: ; 11b98f
ld l, a
ld a, [wMobileMonOTNamePointerBuffer + 1]
ld h, a
- ld bc, PKMN_NAME_LENGTH - 1
+ ld bc, MON_NAME_LENGTH - 1
call CopyBytes
ld a, "@"
ld [de], a
ld hl, PartyMonNicknames
- ld bc, PKMN_NAME_LENGTH
+ ld bc, MON_NAME_LENGTH
ld a, [wMobileMonSpeciesBuffer]
.loop4
add hl, bc
@@ -7858,7 +7858,7 @@ AddMobileMonToParty: ; 11b98f
ld l, a
ld a, [wMobileMonNicknamePointerBuffer + 1]
ld h, a
- ld bc, PKMN_NAME_LENGTH - 1
+ ld bc, MON_NAME_LENGTH - 1
call CopyBytes
ld a, "@"
ld [de], a
diff --git a/mobile/mobile_5c.asm b/mobile/mobile_5c.asm
index 1b6c71a3d..cb6589fb0 100755
--- a/mobile/mobile_5c.asm
+++ b/mobile/mobile_5c.asm
@@ -219,7 +219,7 @@ Function170c8b: ; 170c8b
; 170c98
CheckBTMonMovesForErrors: ; 170c98
- ld c, BATTLETOWER_PARTY_SIZE
+ ld c, BATTLETOWER_PARTY_LENGTH
ld hl, wBT_OTTempPkmn1Moves
.loop
push hl
@@ -254,7 +254,7 @@ CheckBTMonMovesForErrors: ; 170c98
.done
pop hl
- ld de, PARTYMON_STRUCT_LENGTH + PKMN_NAME_LENGTH
+ ld de, PARTYMON_STRUCT_LENGTH + MON_NAME_LENGTH
add hl, de
dec c
jr nz, .loop
diff --git a/sram.asm b/sram.asm
index 84d2a8f5a..ddfc6faf6 100644
--- a/sram.asm
+++ b/sram.asm
@@ -203,7 +203,7 @@ sBattleTower:: ; be46
sNrOfBeatenBattleTowerTrainers:: db
sBTChoiceOfLevelGroup:: db
; Battle Tower trainers are saved here, so nobody appears more than once
-sBTTrainers:: ds BATTLETOWER_STREAK_SIZE ; sbe48
+sBTTrainers:: ds BATTLETOWER_STREAK_LENGTH ; sbe48
sBattleTowerSaveFileFlags:: db
sBattleTowerReward:: db
diff --git a/wram.asm b/wram.asm
index 5990ba49c..446f20bec 100644
--- a/wram.asm
+++ b/wram.asm
@@ -368,8 +368,8 @@ wMiscEnd::
NEXTU ; c608
; odd egg
wOddEgg:: party_struct OddEgg
-wOddEggName:: ds PKMN_NAME_LENGTH
-wOddEggOTName:: ds PKMN_NAME_LENGTH
+wOddEggName:: ds MON_NAME_LENGTH
+wOddEggOTName:: ds MON_NAME_LENGTH
NEXTU ; c608
; battle tower temp struct
@@ -398,8 +398,8 @@ wBattle::
wEnemyMoveStruct:: move_struct wEnemyMoveStruct ; c608
wPlayerMoveStruct:: move_struct wPlayerMoveStruct ; c60f
-EnemyMonNick:: ds PKMN_NAME_LENGTH ; c616
-BattleMonNick:: ds PKMN_NAME_LENGTH ; c621
+EnemyMonNick:: ds MON_NAME_LENGTH ; c616
+BattleMonNick:: ds MON_NAME_LENGTH ; c621
BattleMon:: battle_struct BattleMon ; c62c
@@ -954,7 +954,7 @@ wTimeCapsulePartyMon4:: red_party_struct wTimeCapsulePartyMon4
wTimeCapsulePartyMon5:: red_party_struct wTimeCapsulePartyMon5
wTimeCapsulePartyMon6:: red_party_struct wTimeCapsulePartyMon6
wTimeCapsulePartyMonOTNames:: ds PARTY_LENGTH * NAME_LENGTH
-wTimeCapsulePartyMonNicks:: ds PARTY_LENGTH * PKMN_NAME_LENGTH
+wTimeCapsulePartyMonNicks:: ds PARTY_LENGTH * MON_NAME_LENGTH
wTimeCapsulePlayerDataEnd::
NEXTU ; c813
@@ -967,7 +967,7 @@ wLinkPlayerPartyMon4:: party_struct wLinkPlayerPartyMon4
wLinkPlayerPartyMon5:: party_struct wLinkPlayerPartyMon5
wLinkPlayerPartyMon6:: party_struct wLinkPlayerPartyMon6
wLinkPlayerPartyMonOTNames:: ds PARTY_LENGTH * NAME_LENGTH
-wLinkPlayerPartyMonNicks:: ds PARTY_LENGTH * PKMN_NAME_LENGTH
+wLinkPlayerPartyMonNicks:: ds PARTY_LENGTH * MON_NAME_LENGTH
wLinkPlayerDataEnd::
ENDU ; c9b7
@@ -1577,7 +1577,7 @@ wTempMail:: mailmsg wTempMail
NEXTU ; d002
; poke seer
wSeerAction:: db
-wSeerNickname:: ds PKMN_NAME_LENGTH
+wSeerNickname:: ds MON_NAME_LENGTH
wSeerCaughtLocation:: ds 17
wSeerTimeOfDay:: ds NAME_LENGTH
wSeerOTName:: ds NAME_LENGTH
@@ -1589,7 +1589,7 @@ wSeerCaughtGender:: db
NEXTU ; d002
; mon buffer
-wBufferMonNick:: ds PKMN_NAME_LENGTH ; d002
+wBufferMonNick:: ds MON_NAME_LENGTH ; d002
wBufferMonOT:: ds NAME_LENGTH ; d00d
wBufferMon:: party_struct wBufferMon ; d018
ds 8
@@ -2217,7 +2217,7 @@ OTPartyMon6:: party_struct OTPartyMon6 ; d378
OTPartyMonsEnd::
OTPartyMonOT:: ds NAME_LENGTH * PARTY_LENGTH ; d3a8
-OTPartyMonNicknames:: ds PKMN_NAME_LENGTH * PARTY_LENGTH ; d3ea
+OTPartyMonNicknames:: ds MON_NAME_LENGTH * PARTY_LENGTH ; d3ea
OTPartyDataEnd::
ds 4
@@ -2770,7 +2770,7 @@ PartyMon6:: party_struct PartyMon6 ; ddcf
PartyMonOT:: ds NAME_LENGTH * PARTY_LENGTH ; ddff
-PartyMonNicknames:: ds PKMN_NAME_LENGTH * PARTY_LENGTH ; de41
+PartyMonNicknames:: ds MON_NAME_LENGTH * PARTY_LENGTH ; de41
PartyMonNicknamesEnd::
ds 22
@@ -2793,7 +2793,7 @@ wDayCareMan:: ; def5
db
wBreedMon1::
-wBreedMon1Nick:: ds PKMN_NAME_LENGTH ; def6
+wBreedMon1Nick:: ds MON_NAME_LENGTH ; def6
wBreedMon1OT:: ds NAME_LENGTH ; df01
wBreedMon1Stats:: box_struct wBreedMon1 ; df0c
@@ -2810,11 +2810,11 @@ wBreedMotherOrNonDitto:: ; df2e
db
wBreedMon2::
-wBreedMon2Nick:: ds PKMN_NAME_LENGTH ; df2f
+wBreedMon2Nick:: ds MON_NAME_LENGTH ; df2f
wBreedMon2OT:: ds NAME_LENGTH ; df3a
wBreedMon2Stats:: box_struct wBreedMon2 ; df45
-wEggNick:: ds PKMN_NAME_LENGTH ; df65
+wEggNick:: ds MON_NAME_LENGTH ; df65
wEggOT:: ds NAME_LENGTH ; df70
wEggMon:: box_struct wEggMon ; df7b