Merge branch 'master' of https://github.com/pret/pokeemerald into pePret

This commit is contained in:
LOuroboros 2022-04-11 01:23:18 -03:00
commit 446bcd3181
24 changed files with 843 additions and 740 deletions

View File

@ -305,6 +305,20 @@ Then proceed to [Choosing where to store pokeemerald (Linux)](#choosing-where-to
> then you will have to install devkitARM. Install all the above packages except binutils-arm-none-eabi, and follow the instructions to > then you will have to install devkitARM. Install all the above packages except binutils-arm-none-eabi, and follow the instructions to
> [install devkitARM on Debian/Ubuntu-based distributions](#installing-devkitarm-on-debianubuntu-based-distributions). > [install devkitARM on Debian/Ubuntu-based distributions](#installing-devkitarm-on-debianubuntu-based-distributions).
</details> </details>
### Arch Linux
Run this command as root to install the necessary packages:
```bash
pacman -S base-devel arm-none-eabi-binutils git libpng
```
Then proceed to [Choosing where to store pokeemerald (Linux)](#choosing-where-to-store-pokeemerald-linux).
<details>
<summary><i>Note for legacy repos...</i></summary>
> If the repository you plan to build has an **[older revision of the INSTALL.md](https://github.com/pret/pokeemerald/blob/571c598/INSTALL.md)**,
> then you will have to install devkitARM. Install all the above packages except binutils-arm-none-eabi, and follow the instructions to
> [install devkitARM on Arch Linux](#installing-devkitarm-on-arch-linux).
</details>
### Other distributions ### Other distributions
_(Specific instructions for other distributions would be greatly appreciated!)_ _(Specific instructions for other distributions would be greatly appreciated!)_
@ -520,6 +534,24 @@ devkitARM is now installed.
devkitARM is now installed. devkitARM is now installed.
## Installing devkitARM on Arch Linux
1. Follow [devkitPro's instructions](https://devkitpro.org/wiki/devkitPro_pacman#Customising_Existing_Pacman_Install) to configure `pacman` to download devkitPro packages.
2. Install `gba-dev`: run the following command as root.
```console
pacman -S gba-dev
```
This will ask for the selection of packages to install. Just press Enter to install all of them, followed by entering Y to proceed with the installation.
3. Run the following command to set devkitPro related environment variables (alternatively, close and re-open the Terminal):
```bash
source /etc/profile.d/devkit-env.sh
```
devkitARM is now installed.
## Other toolchains ## Other toolchains
To build using a toolchain other than devkitARM, override the `TOOLCHAIN` environment variable with the path to your toolchain, which must contain the subdirectory `bin`. To build using a toolchain other than devkitARM, override the `TOOLCHAIN` environment variable with the path to your toolchain, which must contain the subdirectory `bin`.

View File

@ -828,10 +828,10 @@
.endm .endm
@ Sets the movement type (MOVEMENT_TYPE_*) for an object's template. @ Sets the movement type (MOVEMENT_TYPE_*) for an object's template.
.macro setobjectmovementtype word:req, byte:req .macro setobjectmovementtype localId:req, movementType:req
.byte 0x65 .byte 0x65
.2byte \word .2byte \localId
.byte \byte .byte \movementType
.endm .endm
@ If a standard message box (or its text) is being drawn on-screen, this command blocks script execution until the @ If a standard message box (or its text) is being drawn on-screen, this command blocks script execution until the
@ -1451,48 +1451,48 @@
.endm .endm
@ Equivalent to goto using the relative address set by setvaddress. @ Equivalent to goto using the relative address set by setvaddress.
.macro vgoto pointer:req .macro vgoto destination:req
.byte 0xb9 .byte 0xb9
.4byte \pointer .4byte \destination
.endm .endm
@ Equivalent to call using the relative address set by setvaddress. @ Equivalent to call using the relative address set by setvaddress.
.macro vcall pointer:req .macro vcall destination:req
.byte 0xba .byte 0xba
.4byte \pointer .4byte \destination
.endm .endm
@ Equivalent to goto_if using the relative address set by setvaddress. @ Equivalent to goto_if using the relative address set by setvaddress.
.macro vgoto_if byte:req, pointer:req .macro vgoto_if condition:req, destination:req
.byte 0xbb .byte 0xbb
.byte \byte .byte \condition
.4byte \pointer .4byte \destination
.endm .endm
@ Equivalent to call_if using the relative address set by setvaddress. @ Equivalent to call_if using the relative address set by setvaddress.
.macro vcall_if byte:req, pointer:req .macro vcall_if condition:req, destination:req
.byte 0xbc .byte 0xbc
.byte \byte .byte \condition
.4byte \pointer .4byte \destination
.endm .endm
@ Equivalent to message using the relative address set by setvaddress. @ Equivalent to message using the relative address set by setvaddress.
.macro vmessage pointer:req .macro vmessage text:req
.byte 0xbd .byte 0xbd
.4byte \pointer .4byte \text
.endm .endm
@ Expands the given text at the pointer (- the relative address set by setvaddress) into gStringVar4 @ Expands the given text at the pointer (- the relative address set by setvaddress) into gStringVar4
.macro vbuffermessage ptr:req .macro vbuffermessage text:req
.byte 0xbe .byte 0xbe
.4byte \ptr .4byte \text
.endm .endm
@ Equivalent to bufferstring using the relative address set by setvaddress. @ Equivalent to bufferstring using the relative address set by setvaddress.
.macro vbufferstring stringVarIndex:req, pointer:req .macro vbufferstring stringVarIndex:req, text:req
.byte 0xbf .byte 0xbf
stringvar \stringVarIndex stringvar \stringVarIndex
.4byte \pointer .4byte \text
.endm .endm
@ Create a window showing how many Coins the player has. @ Create a window showing how many Coins the player has.
@ -1549,9 +1549,9 @@
.endm .endm
@ Used only in FireRed/LeafGreen, does nothing in Emerald. @ Used only in FireRed/LeafGreen, does nothing in Emerald.
.macro loadhelp pointer:req .macro loadhelp text:req
.byte 0xc8 .byte 0xc8
.4byte \pointer .4byte \text
.endm .endm
@ Used only in FireRed/LeafGreen, does nothing in Emerald. @ Used only in FireRed/LeafGreen, does nothing in Emerald.

View File

Before

Width:  |  Height:  |  Size: 567 B

After

Width:  |  Height:  |  Size: 567 B

View File

Before

Width:  |  Height:  |  Size: 469 B

After

Width:  |  Height:  |  Size: 469 B

View File

Before

Width:  |  Height:  |  Size: 189 B

After

Width:  |  Height:  |  Size: 189 B

View File

@ -6,7 +6,7 @@ u8 BattleArena_ShowJudgmentWindow(u8 *state);
void BattleArena_InitPoints(void); void BattleArena_InitPoints(void);
void BattleArena_AddMindPoints(u8 battler); void BattleArena_AddMindPoints(u8 battler);
void BattleArena_AddSkillPoints(u8 battler); void BattleArena_AddSkillPoints(u8 battler);
void BattleArena_DeductMindPoints(u8 battler, u16 stringId); void BattleArena_DeductSkillPoints(u8 battler, u16 stringId);
void DrawArenaRefereeTextBox(void); void DrawArenaRefereeTextBox(void);
void EraseArenaRefereeTextBox(void); void EraseArenaRefereeTextBox(void);

View File

@ -3,7 +3,7 @@
void CallBattleFactoryFunction(void); void CallBattleFactoryFunction(void);
bool8 InBattleFactory(void); bool8 InBattleFactory(void);
u8 GetFactoryMonFixedIV(u8 arg0, u8 arg1); u8 GetFactoryMonFixedIV(u8 challengeNum, bool8 isLastBattle);
void FillFactoryBrainParty(void); void FillFactoryBrainParty(void);
u8 GetNumPastRentalsRank(u8 battleMode, u8 lvlMode); u8 GetNumPastRentalsRank(u8 battleMode, u8 lvlMode);
u32 GetAiScriptsInBattleFactory(void); u32 GetAiScriptsInBattleFactory(void);

View File

@ -1,10 +1,6 @@
#ifndef GUARD_CONSTANTS_BATTLE_STRING_IDS_H #ifndef GUARD_CONSTANTS_BATTLE_STRING_IDS_H
#define GUARD_CONSTANTS_BATTLE_STRING_IDS_H #define GUARD_CONSTANTS_BATTLE_STRING_IDS_H
#define BATTLESTRINGS_COUNT 369
#define BATTLESTRINGS_ID_ADDER 12 // all battlestrings have its ID + 12, because first 5 are reserved
#define STRINGID_INTROMSG 0 #define STRINGID_INTROMSG 0
#define STRINGID_INTROSENDOUT 1 #define STRINGID_INTROSENDOUT 1
#define STRINGID_RETURNMON 2 #define STRINGID_RETURNMON 2
@ -383,6 +379,12 @@
#define STRINGID_TRAINER1WINTEXT 379 #define STRINGID_TRAINER1WINTEXT 379
#define STRINGID_TRAINER2WINTEXT 380 #define STRINGID_TRAINER2WINTEXT 380
#define BATTLESTRINGS_COUNT 381
// This is the string id that gBattleStringsTable starts with.
// String ids before this (e.g. STRINGID_INTROMSG) are not in the table,
// and are instead handled explicitly by BufferStringBattle.
#define BATTLESTRINGS_TABLE_START STRINGID_TRAINER1LOSETEXT
// The below IDs are all indexes into battle message tables, // The below IDs are all indexes into battle message tables,
// used to determine which of a set of messages to print. // used to determine which of a set of messages to print.

View File

@ -273,14 +273,14 @@
#define ANIM_RUN_WEST (ANIM_STD_COUNT + 2) #define ANIM_RUN_WEST (ANIM_STD_COUNT + 2)
#define ANIM_RUN_EAST (ANIM_STD_COUNT + 3) #define ANIM_RUN_EAST (ANIM_STD_COUNT + 3)
#define ANIM_BUNNY_HOPPY_BACK_WHEEL_SOUTH (ANIM_STD_COUNT + 0) #define ANIM_BUNNY_HOP_BACK_WHEEL_SOUTH (ANIM_STD_COUNT + 0)
#define ANIM_BUNNY_HOPPY_BACK_WHEEL_NORTH (ANIM_STD_COUNT + 1) #define ANIM_BUNNY_HOP_BACK_WHEEL_NORTH (ANIM_STD_COUNT + 1)
#define ANIM_BUNNY_HOPPY_BACK_WHEEL_WEST (ANIM_STD_COUNT + 2) #define ANIM_BUNNY_HOP_BACK_WHEEL_WEST (ANIM_STD_COUNT + 2)
#define ANIM_BUNNY_HOPPY_BACK_WHEEL_EAST (ANIM_STD_COUNT + 3) #define ANIM_BUNNY_HOP_BACK_WHEEL_EAST (ANIM_STD_COUNT + 3)
#define ANIM_BUNNY_HOPPY_FRONT_WHEEL_SOUTH (ANIM_STD_COUNT + 4) #define ANIM_BUNNY_HOP_FRONT_WHEEL_SOUTH (ANIM_STD_COUNT + 4)
#define ANIM_BUNNY_HOPPY_FRONT_WHEEL_NORTH (ANIM_STD_COUNT + 5) #define ANIM_BUNNY_HOP_FRONT_WHEEL_NORTH (ANIM_STD_COUNT + 5)
#define ANIM_BUNNY_HOPPY_FRONT_WHEEL_WEST (ANIM_STD_COUNT + 6) #define ANIM_BUNNY_HOP_FRONT_WHEEL_WEST (ANIM_STD_COUNT + 6)
#define ANIM_BUNNY_HOPPY_FRONT_WHEEL_EAST (ANIM_STD_COUNT + 7) #define ANIM_BUNNY_HOP_FRONT_WHEEL_EAST (ANIM_STD_COUNT + 7)
#define ANIM_STANDING_WHEELIE_BACK_WHEEL_SOUTH (ANIM_STD_COUNT + 8) #define ANIM_STANDING_WHEELIE_BACK_WHEEL_SOUTH (ANIM_STD_COUNT + 8)
#define ANIM_STANDING_WHEELIE_BACK_WHEEL_NORTH (ANIM_STD_COUNT + 9) #define ANIM_STANDING_WHEELIE_BACK_WHEEL_NORTH (ANIM_STD_COUNT + 9)
#define ANIM_STANDING_WHEELIE_BACK_WHEEL_WEST (ANIM_STD_COUNT + 10) #define ANIM_STANDING_WHEELIE_BACK_WHEEL_WEST (ANIM_STD_COUNT + 10)

View File

@ -636,7 +636,7 @@ $(FLDEFFGFXDIR)/tall_grass.4bpp: %.4bpp: %.png
$(FLDEFFGFXDIR)/tree_disguise.4bpp: %.4bpp: %.png $(FLDEFFGFXDIR)/tree_disguise.4bpp: %.4bpp: %.png
$(GFX) $< $@ -mwidth 2 -mheight 4 $(GFX) $< $@ -mwidth 2 -mheight 4
$(FLDEFFGFXDIR)/unknown_16.4bpp: %.4bpp: %.png $(FLDEFFGFXDIR)/jump_long_grass.4bpp: %.4bpp: %.png
$(GFX) $< $@ -mwidth 2 -mheight 2 $(GFX) $< $@ -mwidth 2 -mheight 2
$(FLDEFFGFXDIR)/unknown_17.4bpp: %.4bpp: %.png $(FLDEFFGFXDIR)/unknown_17.4bpp: %.4bpp: %.png

View File

@ -741,7 +741,7 @@ void BattleArena_AddSkillPoints(u8 battler)
} }
} }
void BattleArena_DeductMindPoints(u8 battler, u16 stringId) void BattleArena_DeductSkillPoints(u8 battler, u16 stringId)
{ {
s8 *skillPoints = gBattleStruct->arenaSkillPoints; s8 *skillPoints = gBattleStruct->arenaSkillPoints;

View File

@ -1522,7 +1522,7 @@ static void OpponentHandlePrintString(void)
BufferStringBattle(*stringId); BufferStringBattle(*stringId);
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gBattlerControllerFuncs[gActiveBattler] = CompleteOnInactiveTextPrinter; gBattlerControllerFuncs[gActiveBattler] = CompleteOnInactiveTextPrinter;
BattleArena_DeductMindPoints(gActiveBattler, *stringId); BattleArena_DeductSkillPoints(gActiveBattler, *stringId);
} }
static void OpponentHandlePrintSelectionString(void) static void OpponentHandlePrintSelectionString(void)

View File

@ -2550,7 +2550,7 @@ static void PlayerHandlePrintString(void)
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gBattlerControllerFuncs[gActiveBattler] = CompleteOnInactiveTextPrinter2; gBattlerControllerFuncs[gActiveBattler] = CompleteOnInactiveTextPrinter2;
BattleTv_SetDataBasedOnString(*stringId); BattleTv_SetDataBasedOnString(*stringId);
BattleArena_DeductMindPoints(gActiveBattler, *stringId); BattleArena_DeductSkillPoints(gActiveBattler, *stringId);
} }
static void PlayerHandlePrintSelectionString(void) static void PlayerHandlePrintSelectionString(void)

View File

@ -720,17 +720,25 @@ static void RestorePlayerPartyHeldItems(void)
} }
} }
u8 GetFactoryMonFixedIV(u8 arg0, u8 arg1) // Get the IV to use for the opponent's pokémon.
// The IVs get higher for each subsequent challenge and for
// the last trainer in each challenge. Noland is an exception
// to this, as he uses the IVs that would be used by the regular
// trainers 2 challenges ahead of the current one.
// Due to a mistake in FillFactoryFrontierTrainerParty, the
// challenge number used to determine the IVs for regular trainers
// is Battle Tower's instead of Battle Factory's.
u8 GetFactoryMonFixedIV(u8 challengeNum, bool8 isLastBattle)
{ {
u8 a1; u8 ivSet;
u8 a2 = (arg1 != 0) ? 1 : 0; bool8 useHigherIV = isLastBattle ? TRUE : FALSE;
if (arg0 > 8) if (challengeNum > 8)
a1 = 7; ivSet = 7;
else else
a1 = arg0; ivSet = challengeNum;
return sFixedIVTable[a1][a2]; return sFixedIVTable[ivSet][useHigherIV];
} }
void FillFactoryBrainParty(void) void FillFactoryBrainParty(void)
@ -746,7 +754,7 @@ void FillFactoryBrainParty(void)
u8 lvlMode = gSaveBlock2Ptr->frontier.lvlMode; u8 lvlMode = gSaveBlock2Ptr->frontier.lvlMode;
u8 battleMode = VarGet(VAR_FRONTIER_BATTLE_MODE); u8 battleMode = VarGet(VAR_FRONTIER_BATTLE_MODE);
u8 challengeNum = gSaveBlock2Ptr->frontier.factoryWinStreaks[battleMode][lvlMode] / 7; u8 challengeNum = gSaveBlock2Ptr->frontier.factoryWinStreaks[battleMode][lvlMode] / 7;
fixedIV = GetFactoryMonFixedIV(challengeNum + 2, 0); fixedIV = GetFactoryMonFixedIV(challengeNum + 2, FALSE);
monLevel = SetFacilityPtrsGetLevel(); monLevel = SetFacilityPtrsGetLevel();
i = 0; i = 0;
otId = T1_READ_32(gSaveBlock2Ptr->playerTrainerId); otId = T1_READ_32(gSaveBlock2Ptr->playerTrainerId);

View File

@ -514,377 +514,377 @@ static const u8 sText_Trainer2WinText[];
static const u8 sText_TwoInGameTrainersDefeated[]; static const u8 sText_TwoInGameTrainersDefeated[];
static const u8 sText_Trainer2LoseText[]; static const u8 sText_Trainer2LoseText[];
const u8 * const gBattleStringsTable[BATTLESTRINGS_COUNT] = const u8 * const gBattleStringsTable[BATTLESTRINGS_COUNT - BATTLESTRINGS_TABLE_START] =
{ {
[STRINGID_TRAINER1LOSETEXT - 12] = sText_Trainer1LoseText, [STRINGID_TRAINER1LOSETEXT - BATTLESTRINGS_TABLE_START] = sText_Trainer1LoseText,
[STRINGID_PKMNGAINEDEXP - 12] = sText_PkmnGainedEXP, [STRINGID_PKMNGAINEDEXP - BATTLESTRINGS_TABLE_START] = sText_PkmnGainedEXP,
[STRINGID_PKMNGREWTOLV - 12] = sText_PkmnGrewToLv, [STRINGID_PKMNGREWTOLV - BATTLESTRINGS_TABLE_START] = sText_PkmnGrewToLv,
[STRINGID_PKMNLEARNEDMOVE - 12] = sText_PkmnLearnedMove, [STRINGID_PKMNLEARNEDMOVE - BATTLESTRINGS_TABLE_START] = sText_PkmnLearnedMove,
[STRINGID_TRYTOLEARNMOVE1 - 12] = sText_TryToLearnMove1, [STRINGID_TRYTOLEARNMOVE1 - BATTLESTRINGS_TABLE_START] = sText_TryToLearnMove1,
[STRINGID_TRYTOLEARNMOVE2 - 12] = sText_TryToLearnMove2, [STRINGID_TRYTOLEARNMOVE2 - BATTLESTRINGS_TABLE_START] = sText_TryToLearnMove2,
[STRINGID_TRYTOLEARNMOVE3 - 12] = sText_TryToLearnMove3, [STRINGID_TRYTOLEARNMOVE3 - BATTLESTRINGS_TABLE_START] = sText_TryToLearnMove3,
[STRINGID_PKMNFORGOTMOVE - 12] = sText_PkmnForgotMove, [STRINGID_PKMNFORGOTMOVE - BATTLESTRINGS_TABLE_START] = sText_PkmnForgotMove,
[STRINGID_STOPLEARNINGMOVE - 12] = sText_StopLearningMove, [STRINGID_STOPLEARNINGMOVE - BATTLESTRINGS_TABLE_START] = sText_StopLearningMove,
[STRINGID_DIDNOTLEARNMOVE - 12] = sText_DidNotLearnMove, [STRINGID_DIDNOTLEARNMOVE - BATTLESTRINGS_TABLE_START] = sText_DidNotLearnMove,
[STRINGID_PKMNLEARNEDMOVE2 - 12] = sText_PkmnLearnedMove2, [STRINGID_PKMNLEARNEDMOVE2 - BATTLESTRINGS_TABLE_START] = sText_PkmnLearnedMove2,
[STRINGID_ATTACKMISSED - 12] = sText_AttackMissed, [STRINGID_ATTACKMISSED - BATTLESTRINGS_TABLE_START] = sText_AttackMissed,
[STRINGID_PKMNPROTECTEDITSELF - 12] = sText_PkmnProtectedItself, [STRINGID_PKMNPROTECTEDITSELF - BATTLESTRINGS_TABLE_START] = sText_PkmnProtectedItself,
[STRINGID_STATSWONTINCREASE2 - 12] = sText_StatsWontIncrease2, [STRINGID_STATSWONTINCREASE2 - BATTLESTRINGS_TABLE_START] = sText_StatsWontIncrease2,
[STRINGID_AVOIDEDDAMAGE - 12] = sText_AvoidedDamage, [STRINGID_AVOIDEDDAMAGE - BATTLESTRINGS_TABLE_START] = sText_AvoidedDamage,
[STRINGID_ITDOESNTAFFECT - 12] = sText_ItDoesntAffect, [STRINGID_ITDOESNTAFFECT - BATTLESTRINGS_TABLE_START] = sText_ItDoesntAffect,
[STRINGID_ATTACKERFAINTED - 12] = sText_AttackerFainted, [STRINGID_ATTACKERFAINTED - BATTLESTRINGS_TABLE_START] = sText_AttackerFainted,
[STRINGID_TARGETFAINTED - 12] = sText_TargetFainted, [STRINGID_TARGETFAINTED - BATTLESTRINGS_TABLE_START] = sText_TargetFainted,
[STRINGID_PLAYERGOTMONEY - 12] = sText_PlayerGotMoney, [STRINGID_PLAYERGOTMONEY - BATTLESTRINGS_TABLE_START] = sText_PlayerGotMoney,
[STRINGID_PLAYERWHITEOUT - 12] = sText_PlayerWhiteout, [STRINGID_PLAYERWHITEOUT - BATTLESTRINGS_TABLE_START] = sText_PlayerWhiteout,
[STRINGID_PLAYERWHITEOUT2 - 12] = sText_PlayerWhiteout2, [STRINGID_PLAYERWHITEOUT2 - BATTLESTRINGS_TABLE_START] = sText_PlayerWhiteout2,
[STRINGID_PREVENTSESCAPE - 12] = sText_PreventsEscape, [STRINGID_PREVENTSESCAPE - BATTLESTRINGS_TABLE_START] = sText_PreventsEscape,
[STRINGID_HITXTIMES - 12] = sText_HitXTimes, [STRINGID_HITXTIMES - BATTLESTRINGS_TABLE_START] = sText_HitXTimes,
[STRINGID_PKMNFELLASLEEP - 12] = sText_PkmnFellAsleep, [STRINGID_PKMNFELLASLEEP - BATTLESTRINGS_TABLE_START] = sText_PkmnFellAsleep,
[STRINGID_PKMNMADESLEEP - 12] = sText_PkmnMadeSleep, [STRINGID_PKMNMADESLEEP - BATTLESTRINGS_TABLE_START] = sText_PkmnMadeSleep,
[STRINGID_PKMNALREADYASLEEP - 12] = sText_PkmnAlreadyAsleep, [STRINGID_PKMNALREADYASLEEP - BATTLESTRINGS_TABLE_START] = sText_PkmnAlreadyAsleep,
[STRINGID_PKMNALREADYASLEEP2 - 12] = sText_PkmnAlreadyAsleep2, [STRINGID_PKMNALREADYASLEEP2 - BATTLESTRINGS_TABLE_START] = sText_PkmnAlreadyAsleep2,
[STRINGID_PKMNWASNTAFFECTED - 12] = sText_PkmnWasntAffected, [STRINGID_PKMNWASNTAFFECTED - BATTLESTRINGS_TABLE_START] = sText_PkmnWasntAffected,
[STRINGID_PKMNWASPOISONED - 12] = sText_PkmnWasPoisoned, [STRINGID_PKMNWASPOISONED - BATTLESTRINGS_TABLE_START] = sText_PkmnWasPoisoned,
[STRINGID_PKMNPOISONEDBY - 12] = sText_PkmnPoisonedBy, [STRINGID_PKMNPOISONEDBY - BATTLESTRINGS_TABLE_START] = sText_PkmnPoisonedBy,
[STRINGID_PKMNHURTBYPOISON - 12] = sText_PkmnHurtByPoison, [STRINGID_PKMNHURTBYPOISON - BATTLESTRINGS_TABLE_START] = sText_PkmnHurtByPoison,
[STRINGID_PKMNALREADYPOISONED - 12] = sText_PkmnAlreadyPoisoned, [STRINGID_PKMNALREADYPOISONED - BATTLESTRINGS_TABLE_START] = sText_PkmnAlreadyPoisoned,
[STRINGID_PKMNBADLYPOISONED - 12] = sText_PkmnBadlyPoisoned, [STRINGID_PKMNBADLYPOISONED - BATTLESTRINGS_TABLE_START] = sText_PkmnBadlyPoisoned,
[STRINGID_PKMNENERGYDRAINED - 12] = sText_PkmnEnergyDrained, [STRINGID_PKMNENERGYDRAINED - BATTLESTRINGS_TABLE_START] = sText_PkmnEnergyDrained,
[STRINGID_PKMNWASBURNED - 12] = sText_PkmnWasBurned, [STRINGID_PKMNWASBURNED - BATTLESTRINGS_TABLE_START] = sText_PkmnWasBurned,
[STRINGID_PKMNBURNEDBY - 12] = sText_PkmnBurnedBy, [STRINGID_PKMNBURNEDBY - BATTLESTRINGS_TABLE_START] = sText_PkmnBurnedBy,
[STRINGID_PKMNHURTBYBURN - 12] = sText_PkmnHurtByBurn, [STRINGID_PKMNHURTBYBURN - BATTLESTRINGS_TABLE_START] = sText_PkmnHurtByBurn,
[STRINGID_PKMNWASFROZEN - 12] = sText_PkmnWasFrozen, [STRINGID_PKMNWASFROZEN - BATTLESTRINGS_TABLE_START] = sText_PkmnWasFrozen,
[STRINGID_PKMNFROZENBY - 12] = sText_PkmnFrozenBy, [STRINGID_PKMNFROZENBY - BATTLESTRINGS_TABLE_START] = sText_PkmnFrozenBy,
[STRINGID_PKMNISFROZEN - 12] = sText_PkmnIsFrozen, [STRINGID_PKMNISFROZEN - BATTLESTRINGS_TABLE_START] = sText_PkmnIsFrozen,
[STRINGID_PKMNWASDEFROSTED - 12] = sText_PkmnWasDefrosted, [STRINGID_PKMNWASDEFROSTED - BATTLESTRINGS_TABLE_START] = sText_PkmnWasDefrosted,
[STRINGID_PKMNWASDEFROSTED2 - 12] = sText_PkmnWasDefrosted2, [STRINGID_PKMNWASDEFROSTED2 - BATTLESTRINGS_TABLE_START] = sText_PkmnWasDefrosted2,
[STRINGID_PKMNWASDEFROSTEDBY - 12] = sText_PkmnWasDefrostedBy, [STRINGID_PKMNWASDEFROSTEDBY - BATTLESTRINGS_TABLE_START] = sText_PkmnWasDefrostedBy,
[STRINGID_PKMNWASPARALYZED - 12] = sText_PkmnWasParalyzed, [STRINGID_PKMNWASPARALYZED - BATTLESTRINGS_TABLE_START] = sText_PkmnWasParalyzed,
[STRINGID_PKMNWASPARALYZEDBY - 12] = sText_PkmnWasParalyzedBy, [STRINGID_PKMNWASPARALYZEDBY - BATTLESTRINGS_TABLE_START] = sText_PkmnWasParalyzedBy,
[STRINGID_PKMNISPARALYZED - 12] = sText_PkmnIsParalyzed, [STRINGID_PKMNISPARALYZED - BATTLESTRINGS_TABLE_START] = sText_PkmnIsParalyzed,
[STRINGID_PKMNISALREADYPARALYZED - 12] = sText_PkmnIsAlreadyParalyzed, [STRINGID_PKMNISALREADYPARALYZED - BATTLESTRINGS_TABLE_START] = sText_PkmnIsAlreadyParalyzed,
[STRINGID_PKMNHEALEDPARALYSIS - 12] = sText_PkmnHealedParalysis, [STRINGID_PKMNHEALEDPARALYSIS - BATTLESTRINGS_TABLE_START] = sText_PkmnHealedParalysis,
[STRINGID_PKMNDREAMEATEN - 12] = sText_PkmnDreamEaten, [STRINGID_PKMNDREAMEATEN - BATTLESTRINGS_TABLE_START] = sText_PkmnDreamEaten,
[STRINGID_STATSWONTINCREASE - 12] = sText_StatsWontIncrease, [STRINGID_STATSWONTINCREASE - BATTLESTRINGS_TABLE_START] = sText_StatsWontIncrease,
[STRINGID_STATSWONTDECREASE - 12] = sText_StatsWontDecrease, [STRINGID_STATSWONTDECREASE - BATTLESTRINGS_TABLE_START] = sText_StatsWontDecrease,
[STRINGID_TEAMSTOPPEDWORKING - 12] = sText_TeamStoppedWorking, [STRINGID_TEAMSTOPPEDWORKING - BATTLESTRINGS_TABLE_START] = sText_TeamStoppedWorking,
[STRINGID_FOESTOPPEDWORKING - 12] = sText_FoeStoppedWorking, [STRINGID_FOESTOPPEDWORKING - BATTLESTRINGS_TABLE_START] = sText_FoeStoppedWorking,
[STRINGID_PKMNISCONFUSED - 12] = sText_PkmnIsConfused, [STRINGID_PKMNISCONFUSED - BATTLESTRINGS_TABLE_START] = sText_PkmnIsConfused,
[STRINGID_PKMNHEALEDCONFUSION - 12] = sText_PkmnHealedConfusion, [STRINGID_PKMNHEALEDCONFUSION - BATTLESTRINGS_TABLE_START] = sText_PkmnHealedConfusion,
[STRINGID_PKMNWASCONFUSED - 12] = sText_PkmnWasConfused, [STRINGID_PKMNWASCONFUSED - BATTLESTRINGS_TABLE_START] = sText_PkmnWasConfused,
[STRINGID_PKMNALREADYCONFUSED - 12] = sText_PkmnAlreadyConfused, [STRINGID_PKMNALREADYCONFUSED - BATTLESTRINGS_TABLE_START] = sText_PkmnAlreadyConfused,
[STRINGID_PKMNFELLINLOVE - 12] = sText_PkmnFellInLove, [STRINGID_PKMNFELLINLOVE - BATTLESTRINGS_TABLE_START] = sText_PkmnFellInLove,
[STRINGID_PKMNINLOVE - 12] = sText_PkmnInLove, [STRINGID_PKMNINLOVE - BATTLESTRINGS_TABLE_START] = sText_PkmnInLove,
[STRINGID_PKMNIMMOBILIZEDBYLOVE - 12] = sText_PkmnImmobilizedByLove, [STRINGID_PKMNIMMOBILIZEDBYLOVE - BATTLESTRINGS_TABLE_START] = sText_PkmnImmobilizedByLove,
[STRINGID_PKMNBLOWNAWAY - 12] = sText_PkmnBlownAway, [STRINGID_PKMNBLOWNAWAY - BATTLESTRINGS_TABLE_START] = sText_PkmnBlownAway,
[STRINGID_PKMNCHANGEDTYPE - 12] = sText_PkmnChangedType, [STRINGID_PKMNCHANGEDTYPE - BATTLESTRINGS_TABLE_START] = sText_PkmnChangedType,
[STRINGID_PKMNFLINCHED - 12] = sText_PkmnFlinched, [STRINGID_PKMNFLINCHED - BATTLESTRINGS_TABLE_START] = sText_PkmnFlinched,
[STRINGID_PKMNREGAINEDHEALTH - 12] = sText_PkmnRegainedHealth, [STRINGID_PKMNREGAINEDHEALTH - BATTLESTRINGS_TABLE_START] = sText_PkmnRegainedHealth,
[STRINGID_PKMNHPFULL - 12] = sText_PkmnHPFull, [STRINGID_PKMNHPFULL - BATTLESTRINGS_TABLE_START] = sText_PkmnHPFull,
[STRINGID_PKMNRAISEDSPDEF - 12] = sText_PkmnRaisedSpDef, [STRINGID_PKMNRAISEDSPDEF - BATTLESTRINGS_TABLE_START] = sText_PkmnRaisedSpDef,
[STRINGID_PKMNRAISEDDEF - 12] = sText_PkmnRaisedDef, [STRINGID_PKMNRAISEDDEF - BATTLESTRINGS_TABLE_START] = sText_PkmnRaisedDef,
[STRINGID_PKMNCOVEREDBYVEIL - 12] = sText_PkmnCoveredByVeil, [STRINGID_PKMNCOVEREDBYVEIL - BATTLESTRINGS_TABLE_START] = sText_PkmnCoveredByVeil,
[STRINGID_PKMNUSEDSAFEGUARD - 12] = sText_PkmnUsedSafeguard, [STRINGID_PKMNUSEDSAFEGUARD - BATTLESTRINGS_TABLE_START] = sText_PkmnUsedSafeguard,
[STRINGID_PKMNSAFEGUARDEXPIRED - 12] = sText_PkmnSafeguardExpired, [STRINGID_PKMNSAFEGUARDEXPIRED - BATTLESTRINGS_TABLE_START] = sText_PkmnSafeguardExpired,
[STRINGID_PKMNWENTTOSLEEP - 12] = sText_PkmnWentToSleep, [STRINGID_PKMNWENTTOSLEEP - BATTLESTRINGS_TABLE_START] = sText_PkmnWentToSleep,
[STRINGID_PKMNSLEPTHEALTHY - 12] = sText_PkmnSleptHealthy, [STRINGID_PKMNSLEPTHEALTHY - BATTLESTRINGS_TABLE_START] = sText_PkmnSleptHealthy,
[STRINGID_PKMNWHIPPEDWHIRLWIND - 12] = sText_PkmnWhippedWhirlwind, [STRINGID_PKMNWHIPPEDWHIRLWIND - BATTLESTRINGS_TABLE_START] = sText_PkmnWhippedWhirlwind,
[STRINGID_PKMNTOOKSUNLIGHT - 12] = sText_PkmnTookSunlight, [STRINGID_PKMNTOOKSUNLIGHT - BATTLESTRINGS_TABLE_START] = sText_PkmnTookSunlight,
[STRINGID_PKMNLOWEREDHEAD - 12] = sText_PkmnLoweredHead, [STRINGID_PKMNLOWEREDHEAD - BATTLESTRINGS_TABLE_START] = sText_PkmnLoweredHead,
[STRINGID_PKMNISGLOWING - 12] = sText_PkmnIsGlowing, [STRINGID_PKMNISGLOWING - BATTLESTRINGS_TABLE_START] = sText_PkmnIsGlowing,
[STRINGID_PKMNFLEWHIGH - 12] = sText_PkmnFlewHigh, [STRINGID_PKMNFLEWHIGH - BATTLESTRINGS_TABLE_START] = sText_PkmnFlewHigh,
[STRINGID_PKMNDUGHOLE - 12] = sText_PkmnDugHole, [STRINGID_PKMNDUGHOLE - BATTLESTRINGS_TABLE_START] = sText_PkmnDugHole,
[STRINGID_PKMNSQUEEZEDBYBIND - 12] = sText_PkmnSqueezedByBind, [STRINGID_PKMNSQUEEZEDBYBIND - BATTLESTRINGS_TABLE_START] = sText_PkmnSqueezedByBind,
[STRINGID_PKMNTRAPPEDINVORTEX - 12] = sText_PkmnTrappedInVortex, [STRINGID_PKMNTRAPPEDINVORTEX - BATTLESTRINGS_TABLE_START] = sText_PkmnTrappedInVortex,
[STRINGID_PKMNWRAPPEDBY - 12] = sText_PkmnWrappedBy, [STRINGID_PKMNWRAPPEDBY - BATTLESTRINGS_TABLE_START] = sText_PkmnWrappedBy,
[STRINGID_PKMNCLAMPED - 12] = sText_PkmnClamped, [STRINGID_PKMNCLAMPED - BATTLESTRINGS_TABLE_START] = sText_PkmnClamped,
[STRINGID_PKMNHURTBY - 12] = sText_PkmnHurtBy, [STRINGID_PKMNHURTBY - BATTLESTRINGS_TABLE_START] = sText_PkmnHurtBy,
[STRINGID_PKMNFREEDFROM - 12] = sText_PkmnFreedFrom, [STRINGID_PKMNFREEDFROM - BATTLESTRINGS_TABLE_START] = sText_PkmnFreedFrom,
[STRINGID_PKMNCRASHED - 12] = sText_PkmnCrashed, [STRINGID_PKMNCRASHED - BATTLESTRINGS_TABLE_START] = sText_PkmnCrashed,
[STRINGID_PKMNSHROUDEDINMIST - 12] = gText_PkmnShroudedInMist, [STRINGID_PKMNSHROUDEDINMIST - BATTLESTRINGS_TABLE_START] = gText_PkmnShroudedInMist,
[STRINGID_PKMNPROTECTEDBYMIST - 12] = sText_PkmnProtectedByMist, [STRINGID_PKMNPROTECTEDBYMIST - BATTLESTRINGS_TABLE_START] = sText_PkmnProtectedByMist,
[STRINGID_PKMNGETTINGPUMPED - 12] = gText_PkmnGettingPumped, [STRINGID_PKMNGETTINGPUMPED - BATTLESTRINGS_TABLE_START] = gText_PkmnGettingPumped,
[STRINGID_PKMNHITWITHRECOIL - 12] = sText_PkmnHitWithRecoil, [STRINGID_PKMNHITWITHRECOIL - BATTLESTRINGS_TABLE_START] = sText_PkmnHitWithRecoil,
[STRINGID_PKMNPROTECTEDITSELF2 - 12] = sText_PkmnProtectedItself2, [STRINGID_PKMNPROTECTEDITSELF2 - BATTLESTRINGS_TABLE_START] = sText_PkmnProtectedItself2,
[STRINGID_PKMNBUFFETEDBYSANDSTORM - 12] = sText_PkmnBuffetedBySandstorm, [STRINGID_PKMNBUFFETEDBYSANDSTORM - BATTLESTRINGS_TABLE_START] = sText_PkmnBuffetedBySandstorm,
[STRINGID_PKMNPELTEDBYHAIL - 12] = sText_PkmnPeltedByHail, [STRINGID_PKMNPELTEDBYHAIL - BATTLESTRINGS_TABLE_START] = sText_PkmnPeltedByHail,
[STRINGID_PKMNSEEDED - 12] = sText_PkmnSeeded, [STRINGID_PKMNSEEDED - BATTLESTRINGS_TABLE_START] = sText_PkmnSeeded,
[STRINGID_PKMNEVADEDATTACK - 12] = sText_PkmnEvadedAttack, [STRINGID_PKMNEVADEDATTACK - BATTLESTRINGS_TABLE_START] = sText_PkmnEvadedAttack,
[STRINGID_PKMNSAPPEDBYLEECHSEED - 12] = sText_PkmnSappedByLeechSeed, [STRINGID_PKMNSAPPEDBYLEECHSEED - BATTLESTRINGS_TABLE_START] = sText_PkmnSappedByLeechSeed,
[STRINGID_PKMNFASTASLEEP - 12] = sText_PkmnFastAsleep, [STRINGID_PKMNFASTASLEEP - BATTLESTRINGS_TABLE_START] = sText_PkmnFastAsleep,
[STRINGID_PKMNWOKEUP - 12] = sText_PkmnWokeUp, [STRINGID_PKMNWOKEUP - BATTLESTRINGS_TABLE_START] = sText_PkmnWokeUp,
[STRINGID_PKMNUPROARKEPTAWAKE - 12] = sText_PkmnUproarKeptAwake, [STRINGID_PKMNUPROARKEPTAWAKE - BATTLESTRINGS_TABLE_START] = sText_PkmnUproarKeptAwake,
[STRINGID_PKMNWOKEUPINUPROAR - 12] = sText_PkmnWokeUpInUproar, [STRINGID_PKMNWOKEUPINUPROAR - BATTLESTRINGS_TABLE_START] = sText_PkmnWokeUpInUproar,
[STRINGID_PKMNCAUSEDUPROAR - 12] = sText_PkmnCausedUproar, [STRINGID_PKMNCAUSEDUPROAR - BATTLESTRINGS_TABLE_START] = sText_PkmnCausedUproar,
[STRINGID_PKMNMAKINGUPROAR - 12] = sText_PkmnMakingUproar, [STRINGID_PKMNMAKINGUPROAR - BATTLESTRINGS_TABLE_START] = sText_PkmnMakingUproar,
[STRINGID_PKMNCALMEDDOWN - 12] = sText_PkmnCalmedDown, [STRINGID_PKMNCALMEDDOWN - BATTLESTRINGS_TABLE_START] = sText_PkmnCalmedDown,
[STRINGID_PKMNCANTSLEEPINUPROAR - 12] = sText_PkmnCantSleepInUproar, [STRINGID_PKMNCANTSLEEPINUPROAR - BATTLESTRINGS_TABLE_START] = sText_PkmnCantSleepInUproar,
[STRINGID_PKMNSTOCKPILED - 12] = sText_PkmnStockpiled, [STRINGID_PKMNSTOCKPILED - BATTLESTRINGS_TABLE_START] = sText_PkmnStockpiled,
[STRINGID_PKMNCANTSTOCKPILE - 12] = sText_PkmnCantStockpile, [STRINGID_PKMNCANTSTOCKPILE - BATTLESTRINGS_TABLE_START] = sText_PkmnCantStockpile,
[STRINGID_PKMNCANTSLEEPINUPROAR2 - 12] = sText_PkmnCantSleepInUproar2, [STRINGID_PKMNCANTSLEEPINUPROAR2 - BATTLESTRINGS_TABLE_START] = sText_PkmnCantSleepInUproar2,
[STRINGID_UPROARKEPTPKMNAWAKE - 12] = sText_UproarKeptPkmnAwake, [STRINGID_UPROARKEPTPKMNAWAKE - BATTLESTRINGS_TABLE_START] = sText_UproarKeptPkmnAwake,
[STRINGID_PKMNSTAYEDAWAKEUSING - 12] = sText_PkmnStayedAwakeUsing, [STRINGID_PKMNSTAYEDAWAKEUSING - BATTLESTRINGS_TABLE_START] = sText_PkmnStayedAwakeUsing,
[STRINGID_PKMNSTORINGENERGY - 12] = sText_PkmnStoringEnergy, [STRINGID_PKMNSTORINGENERGY - BATTLESTRINGS_TABLE_START] = sText_PkmnStoringEnergy,
[STRINGID_PKMNUNLEASHEDENERGY - 12] = sText_PkmnUnleashedEnergy, [STRINGID_PKMNUNLEASHEDENERGY - BATTLESTRINGS_TABLE_START] = sText_PkmnUnleashedEnergy,
[STRINGID_PKMNFATIGUECONFUSION - 12] = sText_PkmnFatigueConfusion, [STRINGID_PKMNFATIGUECONFUSION - BATTLESTRINGS_TABLE_START] = sText_PkmnFatigueConfusion,
[STRINGID_PLAYERPICKEDUPMONEY - 12] = sText_PlayerPickedUpMoney, [STRINGID_PLAYERPICKEDUPMONEY - BATTLESTRINGS_TABLE_START] = sText_PlayerPickedUpMoney,
[STRINGID_PKMNUNAFFECTED - 12] = sText_PkmnUnaffected, [STRINGID_PKMNUNAFFECTED - BATTLESTRINGS_TABLE_START] = sText_PkmnUnaffected,
[STRINGID_PKMNTRANSFORMEDINTO - 12] = sText_PkmnTransformedInto, [STRINGID_PKMNTRANSFORMEDINTO - BATTLESTRINGS_TABLE_START] = sText_PkmnTransformedInto,
[STRINGID_PKMNMADESUBSTITUTE - 12] = sText_PkmnMadeSubstitute, [STRINGID_PKMNMADESUBSTITUTE - BATTLESTRINGS_TABLE_START] = sText_PkmnMadeSubstitute,
[STRINGID_PKMNHASSUBSTITUTE - 12] = sText_PkmnHasSubstitute, [STRINGID_PKMNHASSUBSTITUTE - BATTLESTRINGS_TABLE_START] = sText_PkmnHasSubstitute,
[STRINGID_SUBSTITUTEDAMAGED - 12] = sText_SubstituteDamaged, [STRINGID_SUBSTITUTEDAMAGED - BATTLESTRINGS_TABLE_START] = sText_SubstituteDamaged,
[STRINGID_PKMNSUBSTITUTEFADED - 12] = sText_PkmnSubstituteFaded, [STRINGID_PKMNSUBSTITUTEFADED - BATTLESTRINGS_TABLE_START] = sText_PkmnSubstituteFaded,
[STRINGID_PKMNMUSTRECHARGE - 12] = sText_PkmnMustRecharge, [STRINGID_PKMNMUSTRECHARGE - BATTLESTRINGS_TABLE_START] = sText_PkmnMustRecharge,
[STRINGID_PKMNRAGEBUILDING - 12] = sText_PkmnRageBuilding, [STRINGID_PKMNRAGEBUILDING - BATTLESTRINGS_TABLE_START] = sText_PkmnRageBuilding,
[STRINGID_PKMNMOVEWASDISABLED - 12] = sText_PkmnMoveWasDisabled, [STRINGID_PKMNMOVEWASDISABLED - BATTLESTRINGS_TABLE_START] = sText_PkmnMoveWasDisabled,
[STRINGID_PKMNMOVEISDISABLED - 12] = sText_PkmnMoveIsDisabled, [STRINGID_PKMNMOVEISDISABLED - BATTLESTRINGS_TABLE_START] = sText_PkmnMoveIsDisabled,
[STRINGID_PKMNMOVEDISABLEDNOMORE - 12] = sText_PkmnMoveDisabledNoMore, [STRINGID_PKMNMOVEDISABLEDNOMORE - BATTLESTRINGS_TABLE_START] = sText_PkmnMoveDisabledNoMore,
[STRINGID_PKMNGOTENCORE - 12] = sText_PkmnGotEncore, [STRINGID_PKMNGOTENCORE - BATTLESTRINGS_TABLE_START] = sText_PkmnGotEncore,
[STRINGID_PKMNENCOREENDED - 12] = sText_PkmnEncoreEnded, [STRINGID_PKMNENCOREENDED - BATTLESTRINGS_TABLE_START] = sText_PkmnEncoreEnded,
[STRINGID_PKMNTOOKAIM - 12] = sText_PkmnTookAim, [STRINGID_PKMNTOOKAIM - BATTLESTRINGS_TABLE_START] = sText_PkmnTookAim,
[STRINGID_PKMNSKETCHEDMOVE - 12] = sText_PkmnSketchedMove, [STRINGID_PKMNSKETCHEDMOVE - BATTLESTRINGS_TABLE_START] = sText_PkmnSketchedMove,
[STRINGID_PKMNTRYINGTOTAKEFOE - 12] = sText_PkmnTryingToTakeFoe, [STRINGID_PKMNTRYINGTOTAKEFOE - BATTLESTRINGS_TABLE_START] = sText_PkmnTryingToTakeFoe,
[STRINGID_PKMNTOOKFOE - 12] = sText_PkmnTookFoe, [STRINGID_PKMNTOOKFOE - BATTLESTRINGS_TABLE_START] = sText_PkmnTookFoe,
[STRINGID_PKMNREDUCEDPP - 12] = sText_PkmnReducedPP, [STRINGID_PKMNREDUCEDPP - BATTLESTRINGS_TABLE_START] = sText_PkmnReducedPP,
[STRINGID_PKMNSTOLEITEM - 12] = sText_PkmnStoleItem, [STRINGID_PKMNSTOLEITEM - BATTLESTRINGS_TABLE_START] = sText_PkmnStoleItem,
[STRINGID_TARGETCANTESCAPENOW - 12] = sText_TargetCantEscapeNow, [STRINGID_TARGETCANTESCAPENOW - BATTLESTRINGS_TABLE_START] = sText_TargetCantEscapeNow,
[STRINGID_PKMNFELLINTONIGHTMARE - 12] = sText_PkmnFellIntoNightmare, [STRINGID_PKMNFELLINTONIGHTMARE - BATTLESTRINGS_TABLE_START] = sText_PkmnFellIntoNightmare,
[STRINGID_PKMNLOCKEDINNIGHTMARE - 12] = sText_PkmnLockedInNightmare, [STRINGID_PKMNLOCKEDINNIGHTMARE - BATTLESTRINGS_TABLE_START] = sText_PkmnLockedInNightmare,
[STRINGID_PKMNLAIDCURSE - 12] = sText_PkmnLaidCurse, [STRINGID_PKMNLAIDCURSE - BATTLESTRINGS_TABLE_START] = sText_PkmnLaidCurse,
[STRINGID_PKMNAFFLICTEDBYCURSE - 12] = sText_PkmnAfflictedByCurse, [STRINGID_PKMNAFFLICTEDBYCURSE - BATTLESTRINGS_TABLE_START] = sText_PkmnAfflictedByCurse,
[STRINGID_SPIKESSCATTERED - 12] = sText_SpikesScattered, [STRINGID_SPIKESSCATTERED - BATTLESTRINGS_TABLE_START] = sText_SpikesScattered,
[STRINGID_PKMNHURTBYSPIKES - 12] = sText_PkmnHurtBySpikes, [STRINGID_PKMNHURTBYSPIKES - BATTLESTRINGS_TABLE_START] = sText_PkmnHurtBySpikes,
[STRINGID_PKMNIDENTIFIED - 12] = sText_PkmnIdentified, [STRINGID_PKMNIDENTIFIED - BATTLESTRINGS_TABLE_START] = sText_PkmnIdentified,
[STRINGID_PKMNPERISHCOUNTFELL - 12] = sText_PkmnPerishCountFell, [STRINGID_PKMNPERISHCOUNTFELL - BATTLESTRINGS_TABLE_START] = sText_PkmnPerishCountFell,
[STRINGID_PKMNBRACEDITSELF - 12] = sText_PkmnBracedItself, [STRINGID_PKMNBRACEDITSELF - BATTLESTRINGS_TABLE_START] = sText_PkmnBracedItself,
[STRINGID_PKMNENDUREDHIT - 12] = sText_PkmnEnduredHit, [STRINGID_PKMNENDUREDHIT - BATTLESTRINGS_TABLE_START] = sText_PkmnEnduredHit,
[STRINGID_MAGNITUDESTRENGTH - 12] = sText_MagnitudeStrength, [STRINGID_MAGNITUDESTRENGTH - BATTLESTRINGS_TABLE_START] = sText_MagnitudeStrength,
[STRINGID_PKMNCUTHPMAXEDATTACK - 12] = sText_PkmnCutHPMaxedAttack, [STRINGID_PKMNCUTHPMAXEDATTACK - BATTLESTRINGS_TABLE_START] = sText_PkmnCutHPMaxedAttack,
[STRINGID_PKMNCOPIEDSTATCHANGES - 12] = sText_PkmnCopiedStatChanges, [STRINGID_PKMNCOPIEDSTATCHANGES - BATTLESTRINGS_TABLE_START] = sText_PkmnCopiedStatChanges,
[STRINGID_PKMNGOTFREE - 12] = sText_PkmnGotFree, [STRINGID_PKMNGOTFREE - BATTLESTRINGS_TABLE_START] = sText_PkmnGotFree,
[STRINGID_PKMNSHEDLEECHSEED - 12] = sText_PkmnShedLeechSeed, [STRINGID_PKMNSHEDLEECHSEED - BATTLESTRINGS_TABLE_START] = sText_PkmnShedLeechSeed,
[STRINGID_PKMNBLEWAWAYSPIKES - 12] = sText_PkmnBlewAwaySpikes, [STRINGID_PKMNBLEWAWAYSPIKES - BATTLESTRINGS_TABLE_START] = sText_PkmnBlewAwaySpikes,
[STRINGID_PKMNFLEDFROMBATTLE - 12] = sText_PkmnFledFromBattle, [STRINGID_PKMNFLEDFROMBATTLE - BATTLESTRINGS_TABLE_START] = sText_PkmnFledFromBattle,
[STRINGID_PKMNFORESAWATTACK - 12] = sText_PkmnForesawAttack, [STRINGID_PKMNFORESAWATTACK - BATTLESTRINGS_TABLE_START] = sText_PkmnForesawAttack,
[STRINGID_PKMNTOOKATTACK - 12] = sText_PkmnTookAttack, [STRINGID_PKMNTOOKATTACK - BATTLESTRINGS_TABLE_START] = sText_PkmnTookAttack,
[STRINGID_PKMNATTACK - 12] = sText_PkmnAttack, [STRINGID_PKMNATTACK - BATTLESTRINGS_TABLE_START] = sText_PkmnAttack,
[STRINGID_PKMNCENTERATTENTION - 12] = sText_PkmnCenterAttention, [STRINGID_PKMNCENTERATTENTION - BATTLESTRINGS_TABLE_START] = sText_PkmnCenterAttention,
[STRINGID_PKMNCHARGINGPOWER - 12] = sText_PkmnChargingPower, [STRINGID_PKMNCHARGINGPOWER - BATTLESTRINGS_TABLE_START] = sText_PkmnChargingPower,
[STRINGID_NATUREPOWERTURNEDINTO - 12] = sText_NaturePowerTurnedInto, [STRINGID_NATUREPOWERTURNEDINTO - BATTLESTRINGS_TABLE_START] = sText_NaturePowerTurnedInto,
[STRINGID_PKMNSTATUSNORMAL - 12] = sText_PkmnStatusNormal, [STRINGID_PKMNSTATUSNORMAL - BATTLESTRINGS_TABLE_START] = sText_PkmnStatusNormal,
[STRINGID_PKMNHASNOMOVESLEFT - 12] = sText_PkmnHasNoMovesLeft, [STRINGID_PKMNHASNOMOVESLEFT - BATTLESTRINGS_TABLE_START] = sText_PkmnHasNoMovesLeft,
[STRINGID_PKMNSUBJECTEDTOTORMENT - 12] = sText_PkmnSubjectedToTorment, [STRINGID_PKMNSUBJECTEDTOTORMENT - BATTLESTRINGS_TABLE_START] = sText_PkmnSubjectedToTorment,
[STRINGID_PKMNCANTUSEMOVETORMENT - 12] = sText_PkmnCantUseMoveTorment, [STRINGID_PKMNCANTUSEMOVETORMENT - BATTLESTRINGS_TABLE_START] = sText_PkmnCantUseMoveTorment,
[STRINGID_PKMNTIGHTENINGFOCUS - 12] = sText_PkmnTighteningFocus, [STRINGID_PKMNTIGHTENINGFOCUS - BATTLESTRINGS_TABLE_START] = sText_PkmnTighteningFocus,
[STRINGID_PKMNFELLFORTAUNT - 12] = sText_PkmnFellForTaunt, [STRINGID_PKMNFELLFORTAUNT - BATTLESTRINGS_TABLE_START] = sText_PkmnFellForTaunt,
[STRINGID_PKMNCANTUSEMOVETAUNT - 12] = sText_PkmnCantUseMoveTaunt, [STRINGID_PKMNCANTUSEMOVETAUNT - BATTLESTRINGS_TABLE_START] = sText_PkmnCantUseMoveTaunt,
[STRINGID_PKMNREADYTOHELP - 12] = sText_PkmnReadyToHelp, [STRINGID_PKMNREADYTOHELP - BATTLESTRINGS_TABLE_START] = sText_PkmnReadyToHelp,
[STRINGID_PKMNSWITCHEDITEMS - 12] = sText_PkmnSwitchedItems, [STRINGID_PKMNSWITCHEDITEMS - BATTLESTRINGS_TABLE_START] = sText_PkmnSwitchedItems,
[STRINGID_PKMNCOPIEDFOE - 12] = sText_PkmnCopiedFoe, [STRINGID_PKMNCOPIEDFOE - BATTLESTRINGS_TABLE_START] = sText_PkmnCopiedFoe,
[STRINGID_PKMNMADEWISH - 12] = sText_PkmnMadeWish, [STRINGID_PKMNMADEWISH - BATTLESTRINGS_TABLE_START] = sText_PkmnMadeWish,
[STRINGID_PKMNWISHCAMETRUE - 12] = sText_PkmnWishCameTrue, [STRINGID_PKMNWISHCAMETRUE - BATTLESTRINGS_TABLE_START] = sText_PkmnWishCameTrue,
[STRINGID_PKMNPLANTEDROOTS - 12] = sText_PkmnPlantedRoots, [STRINGID_PKMNPLANTEDROOTS - BATTLESTRINGS_TABLE_START] = sText_PkmnPlantedRoots,
[STRINGID_PKMNABSORBEDNUTRIENTS - 12] = sText_PkmnAbsorbedNutrients, [STRINGID_PKMNABSORBEDNUTRIENTS - BATTLESTRINGS_TABLE_START] = sText_PkmnAbsorbedNutrients,
[STRINGID_PKMNANCHOREDITSELF - 12] = sText_PkmnAnchoredItself, [STRINGID_PKMNANCHOREDITSELF - BATTLESTRINGS_TABLE_START] = sText_PkmnAnchoredItself,
[STRINGID_PKMNWASMADEDROWSY - 12] = sText_PkmnWasMadeDrowsy, [STRINGID_PKMNWASMADEDROWSY - BATTLESTRINGS_TABLE_START] = sText_PkmnWasMadeDrowsy,
[STRINGID_PKMNKNOCKEDOFF - 12] = sText_PkmnKnockedOff, [STRINGID_PKMNKNOCKEDOFF - BATTLESTRINGS_TABLE_START] = sText_PkmnKnockedOff,
[STRINGID_PKMNSWAPPEDABILITIES - 12] = sText_PkmnSwappedAbilities, [STRINGID_PKMNSWAPPEDABILITIES - BATTLESTRINGS_TABLE_START] = sText_PkmnSwappedAbilities,
[STRINGID_PKMNSEALEDOPPONENTMOVE - 12] = sText_PkmnSealedOpponentMove, [STRINGID_PKMNSEALEDOPPONENTMOVE - BATTLESTRINGS_TABLE_START] = sText_PkmnSealedOpponentMove,
[STRINGID_PKMNCANTUSEMOVESEALED - 12] = sText_PkmnCantUseMoveSealed, [STRINGID_PKMNCANTUSEMOVESEALED - BATTLESTRINGS_TABLE_START] = sText_PkmnCantUseMoveSealed,
[STRINGID_PKMNWANTSGRUDGE - 12] = sText_PkmnWantsGrudge, [STRINGID_PKMNWANTSGRUDGE - BATTLESTRINGS_TABLE_START] = sText_PkmnWantsGrudge,
[STRINGID_PKMNLOSTPPGRUDGE - 12] = sText_PkmnLostPPGrudge, [STRINGID_PKMNLOSTPPGRUDGE - BATTLESTRINGS_TABLE_START] = sText_PkmnLostPPGrudge,
[STRINGID_PKMNSHROUDEDITSELF - 12] = sText_PkmnShroudedItself, [STRINGID_PKMNSHROUDEDITSELF - BATTLESTRINGS_TABLE_START] = sText_PkmnShroudedItself,
[STRINGID_PKMNMOVEBOUNCED - 12] = sText_PkmnMoveBounced, [STRINGID_PKMNMOVEBOUNCED - BATTLESTRINGS_TABLE_START] = sText_PkmnMoveBounced,
[STRINGID_PKMNWAITSFORTARGET - 12] = sText_PkmnWaitsForTarget, [STRINGID_PKMNWAITSFORTARGET - BATTLESTRINGS_TABLE_START] = sText_PkmnWaitsForTarget,
[STRINGID_PKMNSNATCHEDMOVE - 12] = sText_PkmnSnatchedMove, [STRINGID_PKMNSNATCHEDMOVE - BATTLESTRINGS_TABLE_START] = sText_PkmnSnatchedMove,
[STRINGID_PKMNMADEITRAIN - 12] = sText_PkmnMadeItRain, [STRINGID_PKMNMADEITRAIN - BATTLESTRINGS_TABLE_START] = sText_PkmnMadeItRain,
[STRINGID_PKMNRAISEDSPEED - 12] = sText_PkmnRaisedSpeed, [STRINGID_PKMNRAISEDSPEED - BATTLESTRINGS_TABLE_START] = sText_PkmnRaisedSpeed,
[STRINGID_PKMNPROTECTEDBY - 12] = sText_PkmnProtectedBy, [STRINGID_PKMNPROTECTEDBY - BATTLESTRINGS_TABLE_START] = sText_PkmnProtectedBy,
[STRINGID_PKMNPREVENTSUSAGE - 12] = sText_PkmnPreventsUsage, [STRINGID_PKMNPREVENTSUSAGE - BATTLESTRINGS_TABLE_START] = sText_PkmnPreventsUsage,
[STRINGID_PKMNRESTOREDHPUSING - 12] = sText_PkmnRestoredHPUsing, [STRINGID_PKMNRESTOREDHPUSING - BATTLESTRINGS_TABLE_START] = sText_PkmnRestoredHPUsing,
[STRINGID_PKMNCHANGEDTYPEWITH - 12] = sText_PkmnChangedTypeWith, [STRINGID_PKMNCHANGEDTYPEWITH - BATTLESTRINGS_TABLE_START] = sText_PkmnChangedTypeWith,
[STRINGID_PKMNPREVENTSPARALYSISWITH - 12] = sText_PkmnPreventsParalysisWith, [STRINGID_PKMNPREVENTSPARALYSISWITH - BATTLESTRINGS_TABLE_START] = sText_PkmnPreventsParalysisWith,
[STRINGID_PKMNPREVENTSROMANCEWITH - 12] = sText_PkmnPreventsRomanceWith, [STRINGID_PKMNPREVENTSROMANCEWITH - BATTLESTRINGS_TABLE_START] = sText_PkmnPreventsRomanceWith,
[STRINGID_PKMNPREVENTSPOISONINGWITH - 12] = sText_PkmnPreventsPoisoningWith, [STRINGID_PKMNPREVENTSPOISONINGWITH - BATTLESTRINGS_TABLE_START] = sText_PkmnPreventsPoisoningWith,
[STRINGID_PKMNPREVENTSCONFUSIONWITH - 12] = sText_PkmnPreventsConfusionWith, [STRINGID_PKMNPREVENTSCONFUSIONWITH - BATTLESTRINGS_TABLE_START] = sText_PkmnPreventsConfusionWith,
[STRINGID_PKMNRAISEDFIREPOWERWITH - 12] = sText_PkmnRaisedFirePowerWith, [STRINGID_PKMNRAISEDFIREPOWERWITH - BATTLESTRINGS_TABLE_START] = sText_PkmnRaisedFirePowerWith,
[STRINGID_PKMNANCHORSITSELFWITH - 12] = sText_PkmnAnchorsItselfWith, [STRINGID_PKMNANCHORSITSELFWITH - BATTLESTRINGS_TABLE_START] = sText_PkmnAnchorsItselfWith,
[STRINGID_PKMNCUTSATTACKWITH - 12] = sText_PkmnCutsAttackWith, [STRINGID_PKMNCUTSATTACKWITH - BATTLESTRINGS_TABLE_START] = sText_PkmnCutsAttackWith,
[STRINGID_PKMNPREVENTSSTATLOSSWITH - 12] = sText_PkmnPreventsStatLossWith, [STRINGID_PKMNPREVENTSSTATLOSSWITH - BATTLESTRINGS_TABLE_START] = sText_PkmnPreventsStatLossWith,
[STRINGID_PKMNHURTSWITH - 12] = sText_PkmnHurtsWith, [STRINGID_PKMNHURTSWITH - BATTLESTRINGS_TABLE_START] = sText_PkmnHurtsWith,
[STRINGID_PKMNTRACED - 12] = sText_PkmnTraced, [STRINGID_PKMNTRACED - BATTLESTRINGS_TABLE_START] = sText_PkmnTraced,
[STRINGID_STATSHARPLY - 12] = sText_StatSharply, [STRINGID_STATSHARPLY - BATTLESTRINGS_TABLE_START] = sText_StatSharply,
[STRINGID_STATROSE - 12] = gText_StatRose, [STRINGID_STATROSE - BATTLESTRINGS_TABLE_START] = gText_StatRose,
[STRINGID_STATHARSHLY - 12] = sText_StatHarshly, [STRINGID_STATHARSHLY - BATTLESTRINGS_TABLE_START] = sText_StatHarshly,
[STRINGID_STATFELL - 12] = sText_StatFell, [STRINGID_STATFELL - BATTLESTRINGS_TABLE_START] = sText_StatFell,
[STRINGID_ATTACKERSSTATROSE - 12] = sText_AttackersStatRose, [STRINGID_ATTACKERSSTATROSE - BATTLESTRINGS_TABLE_START] = sText_AttackersStatRose,
[STRINGID_DEFENDERSSTATROSE - 12] = gText_DefendersStatRose, [STRINGID_DEFENDERSSTATROSE - BATTLESTRINGS_TABLE_START] = gText_DefendersStatRose,
[STRINGID_ATTACKERSSTATFELL - 12] = sText_AttackersStatFell, [STRINGID_ATTACKERSSTATFELL - BATTLESTRINGS_TABLE_START] = sText_AttackersStatFell,
[STRINGID_DEFENDERSSTATFELL - 12] = sText_DefendersStatFell, [STRINGID_DEFENDERSSTATFELL - BATTLESTRINGS_TABLE_START] = sText_DefendersStatFell,
[STRINGID_CRITICALHIT - 12] = sText_CriticalHit, [STRINGID_CRITICALHIT - BATTLESTRINGS_TABLE_START] = sText_CriticalHit,
[STRINGID_ONEHITKO - 12] = sText_OneHitKO, [STRINGID_ONEHITKO - BATTLESTRINGS_TABLE_START] = sText_OneHitKO,
[STRINGID_123POOF - 12] = sText_123Poof, [STRINGID_123POOF - BATTLESTRINGS_TABLE_START] = sText_123Poof,
[STRINGID_ANDELLIPSIS - 12] = sText_AndEllipsis, [STRINGID_ANDELLIPSIS - BATTLESTRINGS_TABLE_START] = sText_AndEllipsis,
[STRINGID_NOTVERYEFFECTIVE - 12] = sText_NotVeryEffective, [STRINGID_NOTVERYEFFECTIVE - BATTLESTRINGS_TABLE_START] = sText_NotVeryEffective,
[STRINGID_SUPEREFFECTIVE - 12] = sText_SuperEffective, [STRINGID_SUPEREFFECTIVE - BATTLESTRINGS_TABLE_START] = sText_SuperEffective,
[STRINGID_GOTAWAYSAFELY - 12] = sText_GotAwaySafely, [STRINGID_GOTAWAYSAFELY - BATTLESTRINGS_TABLE_START] = sText_GotAwaySafely,
[STRINGID_WILDPKMNFLED - 12] = sText_WildPkmnFled, [STRINGID_WILDPKMNFLED - BATTLESTRINGS_TABLE_START] = sText_WildPkmnFled,
[STRINGID_NORUNNINGFROMTRAINERS - 12] = sText_NoRunningFromTrainers, [STRINGID_NORUNNINGFROMTRAINERS - BATTLESTRINGS_TABLE_START] = sText_NoRunningFromTrainers,
[STRINGID_CANTESCAPE - 12] = sText_CantEscape, [STRINGID_CANTESCAPE - BATTLESTRINGS_TABLE_START] = sText_CantEscape,
[STRINGID_DONTLEAVEBIRCH - 12] = sText_DontLeaveBirch, [STRINGID_DONTLEAVEBIRCH - BATTLESTRINGS_TABLE_START] = sText_DontLeaveBirch,
[STRINGID_BUTNOTHINGHAPPENED - 12] = sText_ButNothingHappened, [STRINGID_BUTNOTHINGHAPPENED - BATTLESTRINGS_TABLE_START] = sText_ButNothingHappened,
[STRINGID_BUTITFAILED - 12] = sText_ButItFailed, [STRINGID_BUTITFAILED - BATTLESTRINGS_TABLE_START] = sText_ButItFailed,
[STRINGID_ITHURTCONFUSION - 12] = sText_ItHurtConfusion, [STRINGID_ITHURTCONFUSION - BATTLESTRINGS_TABLE_START] = sText_ItHurtConfusion,
[STRINGID_MIRRORMOVEFAILED - 12] = sText_MirrorMoveFailed, [STRINGID_MIRRORMOVEFAILED - BATTLESTRINGS_TABLE_START] = sText_MirrorMoveFailed,
[STRINGID_STARTEDTORAIN - 12] = sText_StartedToRain, [STRINGID_STARTEDTORAIN - BATTLESTRINGS_TABLE_START] = sText_StartedToRain,
[STRINGID_DOWNPOURSTARTED - 12] = sText_DownpourStarted, [STRINGID_DOWNPOURSTARTED - BATTLESTRINGS_TABLE_START] = sText_DownpourStarted,
[STRINGID_RAINCONTINUES - 12] = sText_RainContinues, [STRINGID_RAINCONTINUES - BATTLESTRINGS_TABLE_START] = sText_RainContinues,
[STRINGID_DOWNPOURCONTINUES - 12] = sText_DownpourContinues, [STRINGID_DOWNPOURCONTINUES - BATTLESTRINGS_TABLE_START] = sText_DownpourContinues,
[STRINGID_RAINSTOPPED - 12] = sText_RainStopped, [STRINGID_RAINSTOPPED - BATTLESTRINGS_TABLE_START] = sText_RainStopped,
[STRINGID_SANDSTORMBREWED - 12] = sText_SandstormBrewed, [STRINGID_SANDSTORMBREWED - BATTLESTRINGS_TABLE_START] = sText_SandstormBrewed,
[STRINGID_SANDSTORMRAGES - 12] = sText_SandstormRages, [STRINGID_SANDSTORMRAGES - BATTLESTRINGS_TABLE_START] = sText_SandstormRages,
[STRINGID_SANDSTORMSUBSIDED - 12] = sText_SandstormSubsided, [STRINGID_SANDSTORMSUBSIDED - BATTLESTRINGS_TABLE_START] = sText_SandstormSubsided,
[STRINGID_SUNLIGHTGOTBRIGHT - 12] = sText_SunlightGotBright, [STRINGID_SUNLIGHTGOTBRIGHT - BATTLESTRINGS_TABLE_START] = sText_SunlightGotBright,
[STRINGID_SUNLIGHTSTRONG - 12] = sText_SunlightStrong, [STRINGID_SUNLIGHTSTRONG - BATTLESTRINGS_TABLE_START] = sText_SunlightStrong,
[STRINGID_SUNLIGHTFADED - 12] = sText_SunlightFaded, [STRINGID_SUNLIGHTFADED - BATTLESTRINGS_TABLE_START] = sText_SunlightFaded,
[STRINGID_STARTEDHAIL - 12] = sText_StartedHail, [STRINGID_STARTEDHAIL - BATTLESTRINGS_TABLE_START] = sText_StartedHail,
[STRINGID_HAILCONTINUES - 12] = sText_HailContinues, [STRINGID_HAILCONTINUES - BATTLESTRINGS_TABLE_START] = sText_HailContinues,
[STRINGID_HAILSTOPPED - 12] = sText_HailStopped, [STRINGID_HAILSTOPPED - BATTLESTRINGS_TABLE_START] = sText_HailStopped,
[STRINGID_FAILEDTOSPITUP - 12] = sText_FailedToSpitUp, [STRINGID_FAILEDTOSPITUP - BATTLESTRINGS_TABLE_START] = sText_FailedToSpitUp,
[STRINGID_FAILEDTOSWALLOW - 12] = sText_FailedToSwallow, [STRINGID_FAILEDTOSWALLOW - BATTLESTRINGS_TABLE_START] = sText_FailedToSwallow,
[STRINGID_WINDBECAMEHEATWAVE - 12] = sText_WindBecameHeatWave, [STRINGID_WINDBECAMEHEATWAVE - BATTLESTRINGS_TABLE_START] = sText_WindBecameHeatWave,
[STRINGID_STATCHANGESGONE - 12] = sText_StatChangesGone, [STRINGID_STATCHANGESGONE - BATTLESTRINGS_TABLE_START] = sText_StatChangesGone,
[STRINGID_COINSSCATTERED - 12] = sText_CoinsScattered, [STRINGID_COINSSCATTERED - BATTLESTRINGS_TABLE_START] = sText_CoinsScattered,
[STRINGID_TOOWEAKFORSUBSTITUTE - 12] = sText_TooWeakForSubstitute, [STRINGID_TOOWEAKFORSUBSTITUTE - BATTLESTRINGS_TABLE_START] = sText_TooWeakForSubstitute,
[STRINGID_SHAREDPAIN - 12] = sText_SharedPain, [STRINGID_SHAREDPAIN - BATTLESTRINGS_TABLE_START] = sText_SharedPain,
[STRINGID_BELLCHIMED - 12] = sText_BellChimed, [STRINGID_BELLCHIMED - BATTLESTRINGS_TABLE_START] = sText_BellChimed,
[STRINGID_FAINTINTHREE - 12] = sText_FaintInThree, [STRINGID_FAINTINTHREE - BATTLESTRINGS_TABLE_START] = sText_FaintInThree,
[STRINGID_NOPPLEFT - 12] = sText_NoPPLeft, [STRINGID_NOPPLEFT - BATTLESTRINGS_TABLE_START] = sText_NoPPLeft,
[STRINGID_BUTNOPPLEFT - 12] = sText_ButNoPPLeft, [STRINGID_BUTNOPPLEFT - BATTLESTRINGS_TABLE_START] = sText_ButNoPPLeft,
[STRINGID_PLAYERUSEDITEM - 12] = sText_PlayerUsedItem, [STRINGID_PLAYERUSEDITEM - BATTLESTRINGS_TABLE_START] = sText_PlayerUsedItem,
[STRINGID_WALLYUSEDITEM - 12] = sText_WallyUsedItem, [STRINGID_WALLYUSEDITEM - BATTLESTRINGS_TABLE_START] = sText_WallyUsedItem,
[STRINGID_TRAINERBLOCKEDBALL - 12] = sText_TrainerBlockedBall, [STRINGID_TRAINERBLOCKEDBALL - BATTLESTRINGS_TABLE_START] = sText_TrainerBlockedBall,
[STRINGID_DONTBEATHIEF - 12] = sText_DontBeAThief, [STRINGID_DONTBEATHIEF - BATTLESTRINGS_TABLE_START] = sText_DontBeAThief,
[STRINGID_ITDODGEDBALL - 12] = sText_ItDodgedBall, [STRINGID_ITDODGEDBALL - BATTLESTRINGS_TABLE_START] = sText_ItDodgedBall,
[STRINGID_YOUMISSEDPKMN - 12] = sText_YouMissedPkmn, [STRINGID_YOUMISSEDPKMN - BATTLESTRINGS_TABLE_START] = sText_YouMissedPkmn,
[STRINGID_PKMNBROKEFREE - 12] = sText_PkmnBrokeFree, [STRINGID_PKMNBROKEFREE - BATTLESTRINGS_TABLE_START] = sText_PkmnBrokeFree,
[STRINGID_ITAPPEAREDCAUGHT - 12] = sText_ItAppearedCaught, [STRINGID_ITAPPEAREDCAUGHT - BATTLESTRINGS_TABLE_START] = sText_ItAppearedCaught,
[STRINGID_AARGHALMOSTHADIT - 12] = sText_AarghAlmostHadIt, [STRINGID_AARGHALMOSTHADIT - BATTLESTRINGS_TABLE_START] = sText_AarghAlmostHadIt,
[STRINGID_SHOOTSOCLOSE - 12] = sText_ShootSoClose, [STRINGID_SHOOTSOCLOSE - BATTLESTRINGS_TABLE_START] = sText_ShootSoClose,
[STRINGID_GOTCHAPKMNCAUGHT - 12] = sText_GotchaPkmnCaught, [STRINGID_GOTCHAPKMNCAUGHT - BATTLESTRINGS_TABLE_START] = sText_GotchaPkmnCaught,
[STRINGID_GOTCHAPKMNCAUGHT2 - 12] = sText_GotchaPkmnCaught2, [STRINGID_GOTCHAPKMNCAUGHT2 - BATTLESTRINGS_TABLE_START] = sText_GotchaPkmnCaught2,
[STRINGID_GIVENICKNAMECAPTURED - 12] = sText_GiveNicknameCaptured, [STRINGID_GIVENICKNAMECAPTURED - BATTLESTRINGS_TABLE_START] = sText_GiveNicknameCaptured,
[STRINGID_PKMNSENTTOPC - 12] = sText_PkmnSentToPC, [STRINGID_PKMNSENTTOPC - BATTLESTRINGS_TABLE_START] = sText_PkmnSentToPC,
[STRINGID_PKMNDATAADDEDTODEX - 12] = sText_PkmnDataAddedToDex, [STRINGID_PKMNDATAADDEDTODEX - BATTLESTRINGS_TABLE_START] = sText_PkmnDataAddedToDex,
[STRINGID_ITISRAINING - 12] = sText_ItIsRaining, [STRINGID_ITISRAINING - BATTLESTRINGS_TABLE_START] = sText_ItIsRaining,
[STRINGID_SANDSTORMISRAGING - 12] = sText_SandstormIsRaging, [STRINGID_SANDSTORMISRAGING - BATTLESTRINGS_TABLE_START] = sText_SandstormIsRaging,
[STRINGID_CANTESCAPE2 - 12] = sText_CantEscape2, [STRINGID_CANTESCAPE2 - BATTLESTRINGS_TABLE_START] = sText_CantEscape2,
[STRINGID_PKMNIGNORESASLEEP - 12] = sText_PkmnIgnoresAsleep, [STRINGID_PKMNIGNORESASLEEP - BATTLESTRINGS_TABLE_START] = sText_PkmnIgnoresAsleep,
[STRINGID_PKMNIGNOREDORDERS - 12] = sText_PkmnIgnoredOrders, [STRINGID_PKMNIGNOREDORDERS - BATTLESTRINGS_TABLE_START] = sText_PkmnIgnoredOrders,
[STRINGID_PKMNBEGANTONAP - 12] = sText_PkmnBeganToNap, [STRINGID_PKMNBEGANTONAP - BATTLESTRINGS_TABLE_START] = sText_PkmnBeganToNap,
[STRINGID_PKMNLOAFING - 12] = sText_PkmnLoafing, [STRINGID_PKMNLOAFING - BATTLESTRINGS_TABLE_START] = sText_PkmnLoafing,
[STRINGID_PKMNWONTOBEY - 12] = sText_PkmnWontObey, [STRINGID_PKMNWONTOBEY - BATTLESTRINGS_TABLE_START] = sText_PkmnWontObey,
[STRINGID_PKMNTURNEDAWAY - 12] = sText_PkmnTurnedAway, [STRINGID_PKMNTURNEDAWAY - BATTLESTRINGS_TABLE_START] = sText_PkmnTurnedAway,
[STRINGID_PKMNPRETENDNOTNOTICE - 12] = sText_PkmnPretendNotNotice, [STRINGID_PKMNPRETENDNOTNOTICE - BATTLESTRINGS_TABLE_START] = sText_PkmnPretendNotNotice,
[STRINGID_ENEMYABOUTTOSWITCHPKMN - 12] = sText_EnemyAboutToSwitchPkmn, [STRINGID_ENEMYABOUTTOSWITCHPKMN - BATTLESTRINGS_TABLE_START] = sText_EnemyAboutToSwitchPkmn,
[STRINGID_CREPTCLOSER - 12] = sText_CreptCloser, [STRINGID_CREPTCLOSER - BATTLESTRINGS_TABLE_START] = sText_CreptCloser,
[STRINGID_CANTGETCLOSER - 12] = sText_CantGetCloser, [STRINGID_CANTGETCLOSER - BATTLESTRINGS_TABLE_START] = sText_CantGetCloser,
[STRINGID_PKMNWATCHINGCAREFULLY - 12] = sText_PkmnWatchingCarefully, [STRINGID_PKMNWATCHINGCAREFULLY - BATTLESTRINGS_TABLE_START] = sText_PkmnWatchingCarefully,
[STRINGID_PKMNCURIOUSABOUTX - 12] = sText_PkmnCuriousAboutX, [STRINGID_PKMNCURIOUSABOUTX - BATTLESTRINGS_TABLE_START] = sText_PkmnCuriousAboutX,
[STRINGID_PKMNENTHRALLEDBYX - 12] = sText_PkmnEnthralledByX, [STRINGID_PKMNENTHRALLEDBYX - BATTLESTRINGS_TABLE_START] = sText_PkmnEnthralledByX,
[STRINGID_PKMNIGNOREDX - 12] = sText_PkmnIgnoredX, [STRINGID_PKMNIGNOREDX - BATTLESTRINGS_TABLE_START] = sText_PkmnIgnoredX,
[STRINGID_THREWPOKEBLOCKATPKMN - 12] = sText_ThrewPokeblockAtPkmn, [STRINGID_THREWPOKEBLOCKATPKMN - BATTLESTRINGS_TABLE_START] = sText_ThrewPokeblockAtPkmn,
[STRINGID_OUTOFSAFARIBALLS - 12] = sText_OutOfSafariBalls, [STRINGID_OUTOFSAFARIBALLS - BATTLESTRINGS_TABLE_START] = sText_OutOfSafariBalls,
[STRINGID_PKMNSITEMCUREDPARALYSIS - 12] = sText_PkmnsItemCuredParalysis, [STRINGID_PKMNSITEMCUREDPARALYSIS - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemCuredParalysis,
[STRINGID_PKMNSITEMCUREDPOISON - 12] = sText_PkmnsItemCuredPoison, [STRINGID_PKMNSITEMCUREDPOISON - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemCuredPoison,
[STRINGID_PKMNSITEMHEALEDBURN - 12] = sText_PkmnsItemHealedBurn, [STRINGID_PKMNSITEMHEALEDBURN - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemHealedBurn,
[STRINGID_PKMNSITEMDEFROSTEDIT - 12] = sText_PkmnsItemDefrostedIt, [STRINGID_PKMNSITEMDEFROSTEDIT - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemDefrostedIt,
[STRINGID_PKMNSITEMWOKEIT - 12] = sText_PkmnsItemWokeIt, [STRINGID_PKMNSITEMWOKEIT - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemWokeIt,
[STRINGID_PKMNSITEMSNAPPEDOUT - 12] = sText_PkmnsItemSnappedOut, [STRINGID_PKMNSITEMSNAPPEDOUT - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemSnappedOut,
[STRINGID_PKMNSITEMCUREDPROBLEM - 12] = sText_PkmnsItemCuredProblem, [STRINGID_PKMNSITEMCUREDPROBLEM - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemCuredProblem,
[STRINGID_PKMNSITEMRESTOREDHEALTH - 12] = sText_PkmnsItemRestoredHealth, [STRINGID_PKMNSITEMRESTOREDHEALTH - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemRestoredHealth,
[STRINGID_PKMNSITEMRESTOREDPP - 12] = sText_PkmnsItemRestoredPP, [STRINGID_PKMNSITEMRESTOREDPP - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemRestoredPP,
[STRINGID_PKMNSITEMRESTOREDSTATUS - 12] = sText_PkmnsItemRestoredStatus, [STRINGID_PKMNSITEMRESTOREDSTATUS - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemRestoredStatus,
[STRINGID_PKMNSITEMRESTOREDHPALITTLE - 12] = sText_PkmnsItemRestoredHPALittle, [STRINGID_PKMNSITEMRESTOREDHPALITTLE - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemRestoredHPALittle,
[STRINGID_ITEMALLOWSONLYYMOVE - 12] = sText_ItemAllowsOnlyYMove, [STRINGID_ITEMALLOWSONLYYMOVE - BATTLESTRINGS_TABLE_START] = sText_ItemAllowsOnlyYMove,
[STRINGID_PKMNHUNGONWITHX - 12] = sText_PkmnHungOnWithX, [STRINGID_PKMNHUNGONWITHX - BATTLESTRINGS_TABLE_START] = sText_PkmnHungOnWithX,
[STRINGID_EMPTYSTRING3 - 12] = gText_EmptyString3, [STRINGID_EMPTYSTRING3 - BATTLESTRINGS_TABLE_START] = gText_EmptyString3,
[STRINGID_PKMNSXPREVENTSBURNS - 12] = sText_PkmnsXPreventsBurns, [STRINGID_PKMNSXPREVENTSBURNS - BATTLESTRINGS_TABLE_START] = sText_PkmnsXPreventsBurns,
[STRINGID_PKMNSXBLOCKSY - 12] = sText_PkmnsXBlocksY, [STRINGID_PKMNSXBLOCKSY - BATTLESTRINGS_TABLE_START] = sText_PkmnsXBlocksY,
[STRINGID_PKMNSXRESTOREDHPALITTLE2 - 12] = sText_PkmnsXRestoredHPALittle2, [STRINGID_PKMNSXRESTOREDHPALITTLE2 - BATTLESTRINGS_TABLE_START] = sText_PkmnsXRestoredHPALittle2,
[STRINGID_PKMNSXWHIPPEDUPSANDSTORM - 12] = sText_PkmnsXWhippedUpSandstorm, [STRINGID_PKMNSXWHIPPEDUPSANDSTORM - BATTLESTRINGS_TABLE_START] = sText_PkmnsXWhippedUpSandstorm,
[STRINGID_PKMNSXPREVENTSYLOSS - 12] = sText_PkmnsXPreventsYLoss, [STRINGID_PKMNSXPREVENTSYLOSS - BATTLESTRINGS_TABLE_START] = sText_PkmnsXPreventsYLoss,
[STRINGID_PKMNSXINFATUATEDY - 12] = sText_PkmnsXInfatuatedY, [STRINGID_PKMNSXINFATUATEDY - BATTLESTRINGS_TABLE_START] = sText_PkmnsXInfatuatedY,
[STRINGID_PKMNSXMADEYINEFFECTIVE - 12] = sText_PkmnsXMadeYIneffective, [STRINGID_PKMNSXMADEYINEFFECTIVE - BATTLESTRINGS_TABLE_START] = sText_PkmnsXMadeYIneffective,
[STRINGID_PKMNSXCUREDYPROBLEM - 12] = sText_PkmnsXCuredYProblem, [STRINGID_PKMNSXCUREDYPROBLEM - BATTLESTRINGS_TABLE_START] = sText_PkmnsXCuredYProblem,
[STRINGID_ITSUCKEDLIQUIDOOZE - 12] = sText_ItSuckedLiquidOoze, [STRINGID_ITSUCKEDLIQUIDOOZE - BATTLESTRINGS_TABLE_START] = sText_ItSuckedLiquidOoze,
[STRINGID_PKMNTRANSFORMED - 12] = sText_PkmnTransformed, [STRINGID_PKMNTRANSFORMED - BATTLESTRINGS_TABLE_START] = sText_PkmnTransformed,
[STRINGID_ELECTRICITYWEAKENED - 12] = sText_ElectricityWeakened, [STRINGID_ELECTRICITYWEAKENED - BATTLESTRINGS_TABLE_START] = sText_ElectricityWeakened,
[STRINGID_FIREWEAKENED - 12] = sText_FireWeakened, [STRINGID_FIREWEAKENED - BATTLESTRINGS_TABLE_START] = sText_FireWeakened,
[STRINGID_PKMNHIDUNDERWATER - 12] = sText_PkmnHidUnderwater, [STRINGID_PKMNHIDUNDERWATER - BATTLESTRINGS_TABLE_START] = sText_PkmnHidUnderwater,
[STRINGID_PKMNSPRANGUP - 12] = sText_PkmnSprangUp, [STRINGID_PKMNSPRANGUP - BATTLESTRINGS_TABLE_START] = sText_PkmnSprangUp,
[STRINGID_HMMOVESCANTBEFORGOTTEN - 12] = sText_HMMovesCantBeForgotten, [STRINGID_HMMOVESCANTBEFORGOTTEN - BATTLESTRINGS_TABLE_START] = sText_HMMovesCantBeForgotten,
[STRINGID_XFOUNDONEY - 12] = sText_XFoundOneY, [STRINGID_XFOUNDONEY - BATTLESTRINGS_TABLE_START] = sText_XFoundOneY,
[STRINGID_PLAYERDEFEATEDTRAINER1 - 12] = sText_PlayerDefeatedLinkTrainerTrainer1, [STRINGID_PLAYERDEFEATEDTRAINER1 - BATTLESTRINGS_TABLE_START] = sText_PlayerDefeatedLinkTrainerTrainer1,
[STRINGID_SOOTHINGAROMA - 12] = sText_SoothingAroma, [STRINGID_SOOTHINGAROMA - BATTLESTRINGS_TABLE_START] = sText_SoothingAroma,
[STRINGID_ITEMSCANTBEUSEDNOW - 12] = sText_ItemsCantBeUsedNow, [STRINGID_ITEMSCANTBEUSEDNOW - BATTLESTRINGS_TABLE_START] = sText_ItemsCantBeUsedNow,
[STRINGID_FORXCOMMAYZ - 12] = sText_ForXCommaYZ, [STRINGID_FORXCOMMAYZ - BATTLESTRINGS_TABLE_START] = sText_ForXCommaYZ,
[STRINGID_USINGITEMSTATOFPKMNROSE - 12] = sText_UsingItemTheStatOfPkmnRose, [STRINGID_USINGITEMSTATOFPKMNROSE - BATTLESTRINGS_TABLE_START] = sText_UsingItemTheStatOfPkmnRose,
[STRINGID_PKMNUSEDXTOGETPUMPED - 12] = sText_PkmnUsedXToGetPumped, [STRINGID_PKMNUSEDXTOGETPUMPED - BATTLESTRINGS_TABLE_START] = sText_PkmnUsedXToGetPumped,
[STRINGID_PKMNSXMADEYUSELESS - 12] = sText_PkmnsXMadeYUseless, [STRINGID_PKMNSXMADEYUSELESS - BATTLESTRINGS_TABLE_START] = sText_PkmnsXMadeYUseless,
[STRINGID_PKMNTRAPPEDBYSANDTOMB - 12] = sText_PkmnTrappedBySandTomb, [STRINGID_PKMNTRAPPEDBYSANDTOMB - BATTLESTRINGS_TABLE_START] = sText_PkmnTrappedBySandTomb,
[STRINGID_EMPTYSTRING4 - 12] = sText_EmptyString4, [STRINGID_EMPTYSTRING4 - BATTLESTRINGS_TABLE_START] = sText_EmptyString4,
[STRINGID_ABOOSTED - 12] = sText_ABoosted, [STRINGID_ABOOSTED - BATTLESTRINGS_TABLE_START] = sText_ABoosted,
[STRINGID_PKMNSXINTENSIFIEDSUN - 12] = sText_PkmnsXIntensifiedSun, [STRINGID_PKMNSXINTENSIFIEDSUN - BATTLESTRINGS_TABLE_START] = sText_PkmnsXIntensifiedSun,
[STRINGID_PKMNMAKESGROUNDMISS - 12] = sText_PkmnMakesGroundMiss, [STRINGID_PKMNMAKESGROUNDMISS - BATTLESTRINGS_TABLE_START] = sText_PkmnMakesGroundMiss,
[STRINGID_YOUTHROWABALLNOWRIGHT - 12] = sText_YouThrowABallNowRight, [STRINGID_YOUTHROWABALLNOWRIGHT - BATTLESTRINGS_TABLE_START] = sText_YouThrowABallNowRight,
[STRINGID_PKMNSXTOOKATTACK - 12] = sText_PkmnsXTookAttack, [STRINGID_PKMNSXTOOKATTACK - BATTLESTRINGS_TABLE_START] = sText_PkmnsXTookAttack,
[STRINGID_PKMNCHOSEXASDESTINY - 12] = sText_PkmnChoseXAsDestiny, [STRINGID_PKMNCHOSEXASDESTINY - BATTLESTRINGS_TABLE_START] = sText_PkmnChoseXAsDestiny,
[STRINGID_PKMNLOSTFOCUS - 12] = sText_PkmnLostFocus, [STRINGID_PKMNLOSTFOCUS - BATTLESTRINGS_TABLE_START] = sText_PkmnLostFocus,
[STRINGID_USENEXTPKMN - 12] = sText_UseNextPkmn, [STRINGID_USENEXTPKMN - BATTLESTRINGS_TABLE_START] = sText_UseNextPkmn,
[STRINGID_PKMNFLEDUSINGITS - 12] = sText_PkmnFledUsingIts, [STRINGID_PKMNFLEDUSINGITS - BATTLESTRINGS_TABLE_START] = sText_PkmnFledUsingIts,
[STRINGID_PKMNFLEDUSING - 12] = sText_PkmnFledUsing, [STRINGID_PKMNFLEDUSING - BATTLESTRINGS_TABLE_START] = sText_PkmnFledUsing,
[STRINGID_PKMNWASDRAGGEDOUT - 12] = sText_PkmnWasDraggedOut, [STRINGID_PKMNWASDRAGGEDOUT - BATTLESTRINGS_TABLE_START] = sText_PkmnWasDraggedOut,
[STRINGID_PREVENTEDFROMWORKING - 12] = sText_PreventedFromWorking, [STRINGID_PREVENTEDFROMWORKING - BATTLESTRINGS_TABLE_START] = sText_PreventedFromWorking,
[STRINGID_PKMNSITEMNORMALIZEDSTATUS - 12] = sText_PkmnsItemNormalizedStatus, [STRINGID_PKMNSITEMNORMALIZEDSTATUS - BATTLESTRINGS_TABLE_START] = sText_PkmnsItemNormalizedStatus,
[STRINGID_TRAINER1USEDITEM - 12] = sText_Trainer1UsedItem, [STRINGID_TRAINER1USEDITEM - BATTLESTRINGS_TABLE_START] = sText_Trainer1UsedItem,
[STRINGID_BOXISFULL - 12] = sText_BoxIsFull, [STRINGID_BOXISFULL - BATTLESTRINGS_TABLE_START] = sText_BoxIsFull,
[STRINGID_PKMNAVOIDEDATTACK - 12] = sText_PkmnAvoidedAttack, [STRINGID_PKMNAVOIDEDATTACK - BATTLESTRINGS_TABLE_START] = sText_PkmnAvoidedAttack,
[STRINGID_PKMNSXMADEITINEFFECTIVE - 12] = sText_PkmnsXMadeItIneffective, [STRINGID_PKMNSXMADEITINEFFECTIVE - BATTLESTRINGS_TABLE_START] = sText_PkmnsXMadeItIneffective,
[STRINGID_PKMNSXPREVENTSFLINCHING - 12] = sText_PkmnsXPreventsFlinching, [STRINGID_PKMNSXPREVENTSFLINCHING - BATTLESTRINGS_TABLE_START] = sText_PkmnsXPreventsFlinching,
[STRINGID_PKMNALREADYHASBURN - 12] = sText_PkmnAlreadyHasBurn, [STRINGID_PKMNALREADYHASBURN - BATTLESTRINGS_TABLE_START] = sText_PkmnAlreadyHasBurn,
[STRINGID_STATSWONTDECREASE2 - 12] = sText_StatsWontDecrease2, [STRINGID_STATSWONTDECREASE2 - BATTLESTRINGS_TABLE_START] = sText_StatsWontDecrease2,
[STRINGID_PKMNSXBLOCKSY2 - 12] = sText_PkmnsXBlocksY2, [STRINGID_PKMNSXBLOCKSY2 - BATTLESTRINGS_TABLE_START] = sText_PkmnsXBlocksY2,
[STRINGID_PKMNSXWOREOFF - 12] = sText_PkmnsXWoreOff, [STRINGID_PKMNSXWOREOFF - BATTLESTRINGS_TABLE_START] = sText_PkmnsXWoreOff,
[STRINGID_PKMNRAISEDDEFALITTLE - 12] = sText_PkmnRaisedDefALittle, [STRINGID_PKMNRAISEDDEFALITTLE - BATTLESTRINGS_TABLE_START] = sText_PkmnRaisedDefALittle,
[STRINGID_PKMNRAISEDSPDEFALITTLE - 12] = sText_PkmnRaisedSpDefALittle, [STRINGID_PKMNRAISEDSPDEFALITTLE - BATTLESTRINGS_TABLE_START] = sText_PkmnRaisedSpDefALittle,
[STRINGID_THEWALLSHATTERED - 12] = sText_TheWallShattered, [STRINGID_THEWALLSHATTERED - BATTLESTRINGS_TABLE_START] = sText_TheWallShattered,
[STRINGID_PKMNSXPREVENTSYSZ - 12] = sText_PkmnsXPreventsYsZ, [STRINGID_PKMNSXPREVENTSYSZ - BATTLESTRINGS_TABLE_START] = sText_PkmnsXPreventsYsZ,
[STRINGID_PKMNSXCUREDITSYPROBLEM - 12] = sText_PkmnsXCuredItsYProblem, [STRINGID_PKMNSXCUREDITSYPROBLEM - BATTLESTRINGS_TABLE_START] = sText_PkmnsXCuredItsYProblem,
[STRINGID_ATTACKERCANTESCAPE - 12] = sText_AttackerCantEscape, [STRINGID_ATTACKERCANTESCAPE - BATTLESTRINGS_TABLE_START] = sText_AttackerCantEscape,
[STRINGID_PKMNOBTAINEDX - 12] = sText_PkmnObtainedX, [STRINGID_PKMNOBTAINEDX - BATTLESTRINGS_TABLE_START] = sText_PkmnObtainedX,
[STRINGID_PKMNOBTAINEDX2 - 12] = sText_PkmnObtainedX2, [STRINGID_PKMNOBTAINEDX2 - BATTLESTRINGS_TABLE_START] = sText_PkmnObtainedX2,
[STRINGID_PKMNOBTAINEDXYOBTAINEDZ - 12] = sText_PkmnObtainedXYObtainedZ, [STRINGID_PKMNOBTAINEDXYOBTAINEDZ - BATTLESTRINGS_TABLE_START] = sText_PkmnObtainedXYObtainedZ,
[STRINGID_BUTNOEFFECT - 12] = sText_ButNoEffect, [STRINGID_BUTNOEFFECT - BATTLESTRINGS_TABLE_START] = sText_ButNoEffect,
[STRINGID_PKMNSXHADNOEFFECTONY - 12] = sText_PkmnsXHadNoEffectOnY, [STRINGID_PKMNSXHADNOEFFECTONY - BATTLESTRINGS_TABLE_START] = sText_PkmnsXHadNoEffectOnY,
[STRINGID_TWOENEMIESDEFEATED - 12] = sText_TwoInGameTrainersDefeated, [STRINGID_TWOENEMIESDEFEATED - BATTLESTRINGS_TABLE_START] = sText_TwoInGameTrainersDefeated,
[STRINGID_TRAINER2LOSETEXT - 12] = sText_Trainer2LoseText, [STRINGID_TRAINER2LOSETEXT - BATTLESTRINGS_TABLE_START] = sText_Trainer2LoseText,
[STRINGID_PKMNINCAPABLEOFPOWER - 12] = sText_PkmnIncapableOfPower, [STRINGID_PKMNINCAPABLEOFPOWER - BATTLESTRINGS_TABLE_START] = sText_PkmnIncapableOfPower,
[STRINGID_GLINTAPPEARSINEYE - 12] = sText_GlintAppearsInEye, [STRINGID_GLINTAPPEARSINEYE - BATTLESTRINGS_TABLE_START] = sText_GlintAppearsInEye,
[STRINGID_PKMNGETTINGINTOPOSITION - 12] = sText_PkmnGettingIntoPosition, [STRINGID_PKMNGETTINGINTOPOSITION - BATTLESTRINGS_TABLE_START] = sText_PkmnGettingIntoPosition,
[STRINGID_PKMNBEGANGROWLINGDEEPLY - 12] = sText_PkmnBeganGrowlingDeeply, [STRINGID_PKMNBEGANGROWLINGDEEPLY - BATTLESTRINGS_TABLE_START] = sText_PkmnBeganGrowlingDeeply,
[STRINGID_PKMNEAGERFORMORE - 12] = sText_PkmnEagerForMore, [STRINGID_PKMNEAGERFORMORE - BATTLESTRINGS_TABLE_START] = sText_PkmnEagerForMore,
[STRINGID_DEFEATEDOPPONENTBYREFEREE - 12] = sText_DefeatedOpponentByReferee, [STRINGID_DEFEATEDOPPONENTBYREFEREE - BATTLESTRINGS_TABLE_START] = sText_DefeatedOpponentByReferee,
[STRINGID_LOSTTOOPPONENTBYREFEREE - 12] = sText_LostToOpponentByReferee, [STRINGID_LOSTTOOPPONENTBYREFEREE - BATTLESTRINGS_TABLE_START] = sText_LostToOpponentByReferee,
[STRINGID_TIEDOPPONENTBYREFEREE - 12] = sText_TiedOpponentByReferee, [STRINGID_TIEDOPPONENTBYREFEREE - BATTLESTRINGS_TABLE_START] = sText_TiedOpponentByReferee,
[STRINGID_QUESTIONFORFEITMATCH - 12] = sText_QuestionForfeitMatch, [STRINGID_QUESTIONFORFEITMATCH - BATTLESTRINGS_TABLE_START] = sText_QuestionForfeitMatch,
[STRINGID_FORFEITEDMATCH - 12] = sText_ForfeitedMatch, [STRINGID_FORFEITEDMATCH - BATTLESTRINGS_TABLE_START] = sText_ForfeitedMatch,
[STRINGID_PKMNTRANSFERREDSOMEONESPC - 12] = gText_PkmnTransferredSomeonesPC, [STRINGID_PKMNTRANSFERREDSOMEONESPC - BATTLESTRINGS_TABLE_START] = gText_PkmnTransferredSomeonesPC,
[STRINGID_PKMNTRANSFERREDLANETTESPC - 12] = gText_PkmnTransferredLanettesPC, [STRINGID_PKMNTRANSFERREDLANETTESPC - BATTLESTRINGS_TABLE_START] = gText_PkmnTransferredLanettesPC,
[STRINGID_PKMNBOXSOMEONESPCFULL - 12] = gText_PkmnTransferredSomeonesPCBoxFull, [STRINGID_PKMNBOXSOMEONESPCFULL - BATTLESTRINGS_TABLE_START] = gText_PkmnTransferredSomeonesPCBoxFull,
[STRINGID_PKMNBOXLANETTESPCFULL - 12] = gText_PkmnTransferredLanettesPCBoxFull, [STRINGID_PKMNBOXLANETTESPCFULL - BATTLESTRINGS_TABLE_START] = gText_PkmnTransferredLanettesPCBoxFull,
[STRINGID_TRAINER1WINTEXT - 12] = sText_Trainer1WinText, [STRINGID_TRAINER1WINTEXT - BATTLESTRINGS_TABLE_START] = sText_Trainer1WinText,
[STRINGID_TRAINER2WINTEXT - 12] = sText_Trainer2WinText, [STRINGID_TRAINER2WINTEXT - BATTLESTRINGS_TABLE_START] = sText_Trainer2WinText,
}; };
const u16 gMissStringIds[] = const u16 gMissStringIds[] =
@ -2331,14 +2331,14 @@ void BufferStringBattle(u16 stringID)
} }
break; break;
default: // load a string from the table default: // load a string from the table
if (stringID >= BATTLESTRINGS_COUNT + BATTLESTRINGS_ID_ADDER) if (stringID >= BATTLESTRINGS_COUNT)
{ {
gDisplayedStringBattle[0] = EOS; gDisplayedStringBattle[0] = EOS;
return; return;
} }
else else
{ {
stringPtr = gBattleStringsTable[stringID - BATTLESTRINGS_ID_ADDER]; stringPtr = gBattleStringsTable[stringID - BATTLESTRINGS_TABLE_START];
} }
break; break;
} }
@ -2862,7 +2862,7 @@ static void ExpandBattleTextBuffPlaceholders(const u8 *src, u8 *dst)
{ {
case B_BUFF_STRING: // battle string case B_BUFF_STRING: // battle string
hword = T1_READ_16(&src[srcID + 1]); hword = T1_READ_16(&src[srcID + 1]);
StringAppend(dst, gBattleStringsTable[hword - BATTLESTRINGS_ID_ADDER]); StringAppend(dst, gBattleStringsTable[hword - BATTLESTRINGS_TABLE_START]);
srcID += 3; srcID += 3;
break; break;
case B_BUFF_NUMBER: // int to string case B_BUFF_NUMBER: // int to string

View File

@ -1827,13 +1827,18 @@ static void FillFactoryFrontierTrainerParty(u16 trainerId, u8 firstMonId)
if (trainerId < FRONTIER_TRAINERS_COUNT) if (trainerId < FRONTIER_TRAINERS_COUNT)
{ {
u8 lvlMode = gSaveBlock2Ptr->frontier.lvlMode; // Unused variable. u8 lvlMode = gSaveBlock2Ptr->frontier.lvlMode;
u8 battleMode = VarGet(VAR_FRONTIER_BATTLE_MODE); u8 battleMode = VarGet(VAR_FRONTIER_BATTLE_MODE);
// By mistake Battle Tower's Level 50 challenge number is used to determine the IVs for Battle Factory.
#ifdef BUGFIX
u8 challengeNum = gSaveBlock2Ptr->frontier.factoryWinStreaks[battleMode][lvlMode] / 7;
#else
u8 challengeNum = gSaveBlock2Ptr->frontier.towerWinStreaks[battleMode][FRONTIER_LVL_50] / 7; u8 challengeNum = gSaveBlock2Ptr->frontier.towerWinStreaks[battleMode][FRONTIER_LVL_50] / 7;
#endif
if (gSaveBlock2Ptr->frontier.curChallengeBattleNum < 6) if (gSaveBlock2Ptr->frontier.curChallengeBattleNum < 6)
fixedIV = GetFactoryMonFixedIV(challengeNum, 0); fixedIV = GetFactoryMonFixedIV(challengeNum, FALSE);
else else
fixedIV = GetFactoryMonFixedIV(challengeNum, 1); fixedIV = GetFactoryMonFixedIV(challengeNum, TRUE); // Last trainer in challenge uses higher IVs
} }
else if (trainerId == TRAINER_EREADER) else if (trainerId == TRAINER_EREADER)
{ {

View File

@ -570,7 +570,7 @@ void BattleTv_SetDataBasedOnString(u16 stringId)
moveSlot = GetBattlerMoveSlotId(gBattlerAttacker, gBattleMsgDataPtr->currentMove); moveSlot = GetBattlerMoveSlotId(gBattlerAttacker, gBattleMsgDataPtr->currentMove);
if (moveSlot >= MAX_MON_MOVES && IsNotSpecialBattleString(stringId) && stringId > BATTLESTRINGS_ID_ADDER) if (moveSlot >= MAX_MON_MOVES && IsNotSpecialBattleString(stringId) && stringId > BATTLESTRINGS_TABLE_START)
{ {
tvPtr->side[atkSide].faintCause = FNT_OTHER; tvPtr->side[atkSide].faintCause = FNT_OTHER;
return; return;

View File

@ -413,56 +413,56 @@ static const union AnimCmd sAnim_GetOnOffSurfBlobEast[] =
ANIMCMD_JUMP(0), ANIMCMD_JUMP(0),
}; };
static const union AnimCmd sAnim_BunnyHoppyBackWheelSouth[] = static const union AnimCmd sAnim_BunnyHopBackWheelSouth[] =
{ {
ANIMCMD_FRAME(9, 4), ANIMCMD_FRAME(9, 4),
ANIMCMD_FRAME(10, 4), ANIMCMD_FRAME(10, 4),
ANIMCMD_END, ANIMCMD_END,
}; };
static const union AnimCmd sAnim_BunnyHoppyBackWheelNorth[] = static const union AnimCmd sAnim_BunnyHopBackWheelNorth[] =
{ {
ANIMCMD_FRAME(13, 4), ANIMCMD_FRAME(13, 4),
ANIMCMD_FRAME(14, 4), ANIMCMD_FRAME(14, 4),
ANIMCMD_END, ANIMCMD_END,
}; };
static const union AnimCmd sAnim_BunnyHoppyBackWheelWest[] = static const union AnimCmd sAnim_BunnyHopBackWheelWest[] =
{ {
ANIMCMD_FRAME(17, 4), ANIMCMD_FRAME(17, 4),
ANIMCMD_FRAME(18, 4), ANIMCMD_FRAME(18, 4),
ANIMCMD_END, ANIMCMD_END,
}; };
static const union AnimCmd sAnim_BunnyHoppyBackWheelEast[] = static const union AnimCmd sAnim_BunnyHopBackWheelEast[] =
{ {
ANIMCMD_FRAME(17, 4, .hFlip = TRUE), ANIMCMD_FRAME(17, 4, .hFlip = TRUE),
ANIMCMD_FRAME(18, 4, .hFlip = TRUE), ANIMCMD_FRAME(18, 4, .hFlip = TRUE),
ANIMCMD_END, ANIMCMD_END,
}; };
static const union AnimCmd sAnim_BunnyHoppyFrontWheelSouth[] = static const union AnimCmd sAnim_BunnyHopFrontWheelSouth[] =
{ {
ANIMCMD_FRAME(11, 4), ANIMCMD_FRAME(11, 4),
ANIMCMD_FRAME(12, 4), ANIMCMD_FRAME(12, 4),
ANIMCMD_END, ANIMCMD_END,
}; };
static const union AnimCmd sAnim_BunnyHoppyFrontWheelNorth[] = static const union AnimCmd sAnim_BunnyHopFrontWheelNorth[] =
{ {
ANIMCMD_FRAME(15, 4), ANIMCMD_FRAME(15, 4),
ANIMCMD_FRAME(16, 4), ANIMCMD_FRAME(16, 4),
ANIMCMD_END, ANIMCMD_END,
}; };
static const union AnimCmd sAnim_BunnyHoppyFrontWheelWest[] = static const union AnimCmd sAnim_BunnyHopFrontWheelWest[] =
{ {
ANIMCMD_FRAME(19, 4), ANIMCMD_FRAME(19, 4),
ANIMCMD_FRAME(20, 4), ANIMCMD_FRAME(20, 4),
ANIMCMD_END, ANIMCMD_END,
}; };
static const union AnimCmd sAnim_BunnyHoppyFrontWheelEast[] = static const union AnimCmd sAnim_BunnyHopFrontWheelEast[] =
{ {
ANIMCMD_FRAME(19, 4, .hFlip = TRUE), ANIMCMD_FRAME(19, 4, .hFlip = TRUE),
ANIMCMD_FRAME(20, 4, .hFlip = TRUE), ANIMCMD_FRAME(20, 4, .hFlip = TRUE),
@ -1024,14 +1024,14 @@ static const union AnimCmd *const sAnimTable_AcroBike[] = {
[ANIM_STD_GO_FASTEST_NORTH] = sAnim_GoFastestNorth, [ANIM_STD_GO_FASTEST_NORTH] = sAnim_GoFastestNorth,
[ANIM_STD_GO_FASTEST_WEST] = sAnim_GoFastestWest, [ANIM_STD_GO_FASTEST_WEST] = sAnim_GoFastestWest,
[ANIM_STD_GO_FASTEST_EAST] = sAnim_GoFastestEast, [ANIM_STD_GO_FASTEST_EAST] = sAnim_GoFastestEast,
[ANIM_BUNNY_HOPPY_BACK_WHEEL_SOUTH] = sAnim_BunnyHoppyBackWheelSouth, [ANIM_BUNNY_HOP_BACK_WHEEL_SOUTH] = sAnim_BunnyHopBackWheelSouth,
[ANIM_BUNNY_HOPPY_BACK_WHEEL_NORTH] = sAnim_BunnyHoppyBackWheelNorth, [ANIM_BUNNY_HOP_BACK_WHEEL_NORTH] = sAnim_BunnyHopBackWheelNorth,
[ANIM_BUNNY_HOPPY_BACK_WHEEL_WEST] = sAnim_BunnyHoppyBackWheelWest, [ANIM_BUNNY_HOP_BACK_WHEEL_WEST] = sAnim_BunnyHopBackWheelWest,
[ANIM_BUNNY_HOPPY_BACK_WHEEL_EAST] = sAnim_BunnyHoppyBackWheelEast, [ANIM_BUNNY_HOP_BACK_WHEEL_EAST] = sAnim_BunnyHopBackWheelEast,
[ANIM_BUNNY_HOPPY_FRONT_WHEEL_SOUTH] = sAnim_BunnyHoppyFrontWheelSouth, [ANIM_BUNNY_HOP_FRONT_WHEEL_SOUTH] = sAnim_BunnyHopFrontWheelSouth,
[ANIM_BUNNY_HOPPY_FRONT_WHEEL_NORTH] = sAnim_BunnyHoppyFrontWheelNorth, [ANIM_BUNNY_HOP_FRONT_WHEEL_NORTH] = sAnim_BunnyHopFrontWheelNorth,
[ANIM_BUNNY_HOPPY_FRONT_WHEEL_WEST] = sAnim_BunnyHoppyFrontWheelWest, [ANIM_BUNNY_HOP_FRONT_WHEEL_WEST] = sAnim_BunnyHopFrontWheelWest,
[ANIM_BUNNY_HOPPY_FRONT_WHEEL_EAST] = sAnim_BunnyHoppyFrontWheelEast, [ANIM_BUNNY_HOP_FRONT_WHEEL_EAST] = sAnim_BunnyHopFrontWheelEast,
[ANIM_STANDING_WHEELIE_BACK_WHEEL_SOUTH] = sAnim_StandingWheelieBackWheelSouth, [ANIM_STANDING_WHEELIE_BACK_WHEEL_SOUTH] = sAnim_StandingWheelieBackWheelSouth,
[ANIM_STANDING_WHEELIE_BACK_WHEEL_NORTH] = sAnim_StandingWheelieBackWheelNorth, [ANIM_STANDING_WHEELIE_BACK_WHEEL_NORTH] = sAnim_StandingWheelieBackWheelNorth,
[ANIM_STANDING_WHEELIE_BACK_WHEEL_WEST] = sAnim_StandingWheelieBackWheelWest, [ANIM_STANDING_WHEELIE_BACK_WHEEL_WEST] = sAnim_StandingWheelieBackWheelWest,

View File

@ -305,7 +305,7 @@ const u16 gFieldEffectObjectPalette1[] = INCBIN_U16("graphics/field_effects/pale
const u32 gFieldEffectObjectPic_GroundImpactDust[] = INCBIN_U32("graphics/field_effects/pics/ground_impact_dust.4bpp"); const u32 gFieldEffectObjectPic_GroundImpactDust[] = INCBIN_U32("graphics/field_effects/pics/ground_impact_dust.4bpp");
const u32 gFieldEffectObjectPic_JumpTallGrass[] = INCBIN_U32("graphics/field_effects/pics/jump_tall_grass.4bpp"); const u32 gFieldEffectObjectPic_JumpTallGrass[] = INCBIN_U32("graphics/field_effects/pics/jump_tall_grass.4bpp");
const u32 gUnusedGrass3[] = INCBIN_U32("graphics/field_effects/pics/unused_grass_3.4bpp"); const u32 gUnusedGrass3[] = INCBIN_U32("graphics/field_effects/pics/unused_grass_3.4bpp");
const u32 gFieldEffectObjectPic_JumpLongGrass[] = INCBIN_U32("graphics/field_effects/pics/unknown_16.4bpp"); const u32 gFieldEffectObjectPic_JumpLongGrass[] = INCBIN_U32("graphics/field_effects/pics/jump_long_grass.4bpp");
const u32 gFieldEffectObjectPic_Unknown17[] = INCBIN_U32("graphics/field_effects/pics/unknown_17.4bpp"); const u32 gFieldEffectObjectPic_Unknown17[] = INCBIN_U32("graphics/field_effects/pics/unknown_17.4bpp");
const u32 gFieldEffectObjectPic_UnusedGrass2[] = INCBIN_U32("graphics/field_effects/pics/unused_grass_2.4bpp"); const u32 gFieldEffectObjectPic_UnusedGrass2[] = INCBIN_U32("graphics/field_effects/pics/unused_grass_2.4bpp");
const u32 gFieldEffectObjectPic_LongGrass[] = INCBIN_U32("graphics/field_effects/pics/long_grass.4bpp"); const u32 gFieldEffectObjectPic_LongGrass[] = INCBIN_U32("graphics/field_effects/pics/long_grass.4bpp");

View File

@ -78,12 +78,12 @@ static const struct Subsprite sOamTable_16x16_4[] = {
}; };
static const struct SubspriteTable sOamTables_16x16[] = { static const struct SubspriteTable sOamTables_16x16[] = {
{0, NULL}, {},
{1, sOamTable_16x16_0}, {ARRAY_COUNT(sOamTable_16x16_0), sOamTable_16x16_0},
{1, sOamTable_16x16_1}, {ARRAY_COUNT(sOamTable_16x16_1), sOamTable_16x16_1},
{2, sOamTable_16x16_2}, {ARRAY_COUNT(sOamTable_16x16_2), sOamTable_16x16_2},
{2, sOamTable_16x16_3}, {ARRAY_COUNT(sOamTable_16x16_3), sOamTable_16x16_3},
{2, sOamTable_16x16_4} {ARRAY_COUNT(sOamTable_16x16_4), sOamTable_16x16_4}
}; };
static const struct Subsprite sOamTable_16x32_0[] = { static const struct Subsprite sOamTable_16x32_0[] = {
@ -174,12 +174,12 @@ static const struct Subsprite sOamTable_16x32_4[] = {
}; };
static const struct SubspriteTable sOamTables_16x32[] = { static const struct SubspriteTable sOamTables_16x32[] = {
{0, NULL}, {},
{1, sOamTable_16x32_0}, {ARRAY_COUNT(sOamTable_16x32_0), sOamTable_16x32_0},
{1, sOamTable_16x32_1}, {ARRAY_COUNT(sOamTable_16x32_1), sOamTable_16x32_1},
{3, sOamTable_16x32_2}, {ARRAY_COUNT(sOamTable_16x32_2), sOamTable_16x32_2},
{2, sOamTable_16x32_3}, {ARRAY_COUNT(sOamTable_16x32_3), sOamTable_16x32_3},
{2, sOamTable_16x32_4} {ARRAY_COUNT(sOamTable_16x32_4), sOamTable_16x32_4}
}; };
static const struct Subsprite sOamTable_32x32_0[] = { static const struct Subsprite sOamTable_32x32_0[] = {
@ -270,12 +270,12 @@ static const struct Subsprite sOamTable_32x32_4[] = {
}; };
static const struct SubspriteTable sOamTables_32x32[] = { static const struct SubspriteTable sOamTables_32x32[] = {
{0, NULL}, {},
{1, sOamTable_32x32_0}, {ARRAY_COUNT(sOamTable_32x32_0), sOamTable_32x32_0},
{1, sOamTable_32x32_1}, {ARRAY_COUNT(sOamTable_32x32_1), sOamTable_32x32_1},
{3, sOamTable_32x32_2}, {ARRAY_COUNT(sOamTable_32x32_2), sOamTable_32x32_2},
{2, sOamTable_32x32_3}, {ARRAY_COUNT(sOamTable_32x32_3), sOamTable_32x32_3},
{2, sOamTable_32x32_4} {ARRAY_COUNT(sOamTable_32x32_4), sOamTable_32x32_4}
}; };
static const struct Subsprite sOamTable_48x48[] = { static const struct Subsprite sOamTable_48x48[] = {
@ -378,12 +378,12 @@ static const struct Subsprite sOamTable_48x48[] = {
}; };
static const struct SubspriteTable sOamTables_48x48[] = { static const struct SubspriteTable sOamTables_48x48[] = {
{12, sOamTable_48x48}, {ARRAY_COUNT(sOamTable_48x48), sOamTable_48x48},
{12, sOamTable_48x48}, {ARRAY_COUNT(sOamTable_48x48), sOamTable_48x48},
{12, sOamTable_48x48}, {ARRAY_COUNT(sOamTable_48x48), sOamTable_48x48},
{12, sOamTable_48x48}, {ARRAY_COUNT(sOamTable_48x48), sOamTable_48x48},
{12, sOamTable_48x48}, {ARRAY_COUNT(sOamTable_48x48), sOamTable_48x48},
{12, sOamTable_48x48} {ARRAY_COUNT(sOamTable_48x48), sOamTable_48x48}
}; };
static const struct Subsprite sOamTable_64x32_0[] = { static const struct Subsprite sOamTable_64x32_0[] = {
@ -432,12 +432,12 @@ static const struct Subsprite sOamTable_64x32_3[] = {
// Unused // Unused
static const struct SubspriteTable sOamTables_64x32[] = { static const struct SubspriteTable sOamTables_64x32[] = {
{0, NULL}, {},
{1, sOamTable_64x32_0}, {ARRAY_COUNT(sOamTable_64x32_0), sOamTable_64x32_0},
{1, sOamTable_64x32_1}, {ARRAY_COUNT(sOamTable_64x32_1), sOamTable_64x32_1},
{1, sOamTable_64x32_2}, {ARRAY_COUNT(sOamTable_64x32_2), sOamTable_64x32_2},
{1, sOamTable_64x32_3}, {ARRAY_COUNT(sOamTable_64x32_3), sOamTable_64x32_3},
{1, sOamTable_64x32_3} {ARRAY_COUNT(sOamTable_64x32_3), sOamTable_64x32_3}
}; };
static const struct Subsprite sOamTable_64x64_0[] = { static const struct Subsprite sOamTable_64x64_0[] = {
@ -485,12 +485,12 @@ static const struct Subsprite sOamTable_64x64_3[] = {
}; };
static const struct SubspriteTable sOamTables_64x64[] = { static const struct SubspriteTable sOamTables_64x64[] = {
{0, NULL}, {},
{1, sOamTable_64x64_0}, {ARRAY_COUNT(sOamTable_64x64_0), sOamTable_64x64_0},
{1, sOamTable_64x64_1}, {ARRAY_COUNT(sOamTable_64x64_1), sOamTable_64x64_1},
{1, sOamTable_64x64_2}, {ARRAY_COUNT(sOamTable_64x64_2), sOamTable_64x64_2},
{1, sOamTable_64x64_3}, {ARRAY_COUNT(sOamTable_64x64_3), sOamTable_64x64_3},
{1, sOamTable_64x64_3} {ARRAY_COUNT(sOamTable_64x64_3), sOamTable_64x64_3}
}; };
static const struct Subsprite sOamTable_96x40_0[] = { static const struct Subsprite sOamTable_96x40_0[] = {
@ -987,12 +987,12 @@ static const struct Subsprite sOamTable_96x40_3[] = {
// Used by SS Tidal // Used by SS Tidal
static const struct SubspriteTable sOamTables_96x40[] = { static const struct SubspriteTable sOamTables_96x40[] = {
{15, sOamTable_96x40_0}, {ARRAY_COUNT(sOamTable_96x40_0), sOamTable_96x40_0},
{15, sOamTable_96x40_0}, {ARRAY_COUNT(sOamTable_96x40_0), sOamTable_96x40_0},
{15, sOamTable_96x40_1}, {ARRAY_COUNT(sOamTable_96x40_1), sOamTable_96x40_1},
{15, sOamTable_96x40_2}, {ARRAY_COUNT(sOamTable_96x40_2), sOamTable_96x40_2},
{15, sOamTable_96x40_3}, {ARRAY_COUNT(sOamTable_96x40_3), sOamTable_96x40_3},
{15, sOamTable_96x40_3} {ARRAY_COUNT(sOamTable_96x40_3), sOamTable_96x40_3}
}; };
static const struct Subsprite sOamTable_88x32_0[] = { static const struct Subsprite sOamTable_88x32_0[] = {
@ -1521,10 +1521,10 @@ static const struct Subsprite sOamTable_88x32_3[] = {
// Used by Submarine Shadow // Used by Submarine Shadow
static const struct SubspriteTable sOamTables_88x32[] = { static const struct SubspriteTable sOamTables_88x32[] = {
{16, sOamTable_88x32_0}, {ARRAY_COUNT(sOamTable_88x32_0), sOamTable_88x32_0},
{16, sOamTable_88x32_0}, {ARRAY_COUNT(sOamTable_88x32_0), sOamTable_88x32_0},
{16, sOamTable_88x32_1}, {ARRAY_COUNT(sOamTable_88x32_1), sOamTable_88x32_1},
{16, sOamTable_88x32_2}, {ARRAY_COUNT(sOamTable_88x32_2), sOamTable_88x32_2},
{16, sOamTable_88x32_3}, {ARRAY_COUNT(sOamTable_88x32_3), sOamTable_88x32_3},
{16, sOamTable_88x32_3} {ARRAY_COUNT(sOamTable_88x32_3), sOamTable_88x32_3}
}; };

View File

@ -37,16 +37,24 @@
#include "battle.h" // to get rid of later #include "battle.h" // to get rid of later
#include "constants/rgb.h" #include "constants/rgb.h"
#define GFXTAG_EGG 12345
#define GFXTAG_EGG_SHARD 23456
#define PALTAG_EGG 54321
#define EGG_X (DISPLAY_WIDTH / 2)
#define EGG_Y (DISPLAY_HEIGHT / 2 - 5)
struct EggHatchData struct EggHatchData
{ {
u8 eggSpriteID; u8 eggSpriteId;
u8 pokeSpriteID; u8 monSpriteId;
u8 CB2_state; u8 state;
u8 CB2_PalCounter; u8 delayTimer;
u8 eggPartyID; u8 eggPartyId;
u8 unused_5; u8 unused_5;
u8 unused_6; u8 unused_6;
u8 eggShardVelocityID; u8 eggShardVelocityId;
u8 windowId; u8 windowId;
u8 unused_9; u8 unused_9;
u8 unused_A; u8 unused_A;
@ -58,29 +66,27 @@ extern const u32 gTradePlatform_Tilemap[];
extern const u8 gText_HatchedFromEgg[]; extern const u8 gText_HatchedFromEgg[];
extern const u8 gText_NicknameHatchPrompt[]; extern const u8 gText_NicknameHatchPrompt[];
static void Task_EggHatch(u8 taskID); static void Task_EggHatch(u8);
static void CB2_EggHatch_0(void); static void CB2_LoadEggHatch(void);
static void CB2_EggHatch_1(void); static void CB2_EggHatch(void);
static void SpriteCB_Egg_0(struct Sprite* sprite); static void SpriteCB_Egg_Shake1(struct Sprite*);
static void SpriteCB_Egg_1(struct Sprite* sprite); static void SpriteCB_Egg_Shake2(struct Sprite*);
static void SpriteCB_Egg_2(struct Sprite* sprite); static void SpriteCB_Egg_Shake3(struct Sprite*);
static void SpriteCB_Egg_3(struct Sprite* sprite); static void SpriteCB_Egg_WaitHatch(struct Sprite*);
static void SpriteCB_Egg_4(struct Sprite* sprite); static void SpriteCB_Egg_Hatch(struct Sprite*);
static void SpriteCB_Egg_5(struct Sprite* sprite); static void SpriteCB_Egg_Reveal(struct Sprite*);
static void SpriteCB_EggShard(struct Sprite* sprite); static void SpriteCB_EggShard(struct Sprite*);
static void EggHatchPrintMessage(u8 windowId, u8* string, u8 x, u8 y, u8 speed); static void EggHatchPrintMessage(u8, u8*, u8, u8, u8);
static void CreateRandomEggShardSprite(void); static void CreateRandomEggShardSprite(void);
static void CreateEggShardSprite(u8 x, u8 y, s16 data1, s16 data2, s16 data3, u8 spriteAnimIndex); static void CreateEggShardSprite(u8, u8, s16, s16, s16, u8);
// IWRAM bss
static struct EggHatchData *sEggHatchData; static struct EggHatchData *sEggHatchData;
// rom data static const u16 sEggPalette[] = INCBIN_U16("graphics/pokemon/egg/normal.gbapal");
static const u16 sEggPalette[] = INCBIN_U16("graphics/pokemon/egg/normal.gbapal"); static const u8 sEggHatchTiles[] = INCBIN_U8("graphics/pokemon/egg/hatch.4bpp");
static const u8 sEggHatchTiles[] = INCBIN_U8("graphics/misc/egg_hatch.4bpp"); static const u8 sEggShardTiles[] = INCBIN_U8("graphics/pokemon/egg/shard.4bpp");
static const u8 sEggShardTiles[] = INCBIN_U8("graphics/misc/egg_shard.4bpp");
static const struct OamData sOamData_EggHatch = static const struct OamData sOamData_Egg =
{ {
.y = 0, .y = 0,
.affineMode = ST_OAM_AFFINE_OFF, .affineMode = ST_OAM_AFFINE_OFF,
@ -97,64 +103,71 @@ static const struct OamData sOamData_EggHatch =
.affineParam = 0, .affineParam = 0,
}; };
static const union AnimCmd sSpriteAnim_EggHatch0[] = static const union AnimCmd sSpriteAnim_Egg_Normal[] =
{ {
ANIMCMD_FRAME(0, 5), ANIMCMD_FRAME(0, 5),
ANIMCMD_END ANIMCMD_END
}; };
static const union AnimCmd sSpriteAnim_EggHatch1[] = static const union AnimCmd sSpriteAnim_Egg_Cracked1[] =
{ {
ANIMCMD_FRAME(16, 5), ANIMCMD_FRAME(16, 5),
ANIMCMD_END ANIMCMD_END
}; };
static const union AnimCmd sSpriteAnim_EggHatch2[] = static const union AnimCmd sSpriteAnim_Egg_Cracked2[] =
{ {
ANIMCMD_FRAME(32, 5), ANIMCMD_FRAME(32, 5),
ANIMCMD_END ANIMCMD_END
}; };
static const union AnimCmd sSpriteAnim_EggHatch3[] = static const union AnimCmd sSpriteAnim_Egg_Cracked3[] =
{ {
ANIMCMD_FRAME(48, 5), ANIMCMD_FRAME(48, 5),
ANIMCMD_END ANIMCMD_END
}; };
static const union AnimCmd *const sSpriteAnimTable_EggHatch[] = enum {
EGG_ANIM_NORMAL,
EGG_ANIM_CRACKED_1,
EGG_ANIM_CRACKED_2,
EGG_ANIM_CRACKED_3,
};
static const union AnimCmd *const sSpriteAnimTable_Egg[] =
{ {
sSpriteAnim_EggHatch0, [EGG_ANIM_NORMAL] = sSpriteAnim_Egg_Normal,
sSpriteAnim_EggHatch1, [EGG_ANIM_CRACKED_1] = sSpriteAnim_Egg_Cracked1,
sSpriteAnim_EggHatch2, [EGG_ANIM_CRACKED_2] = sSpriteAnim_Egg_Cracked2,
sSpriteAnim_EggHatch3, [EGG_ANIM_CRACKED_3] = sSpriteAnim_Egg_Cracked3,
}; };
static const struct SpriteSheet sEggHatch_Sheet = static const struct SpriteSheet sEggHatch_Sheet =
{ {
.data = sEggHatchTiles, .data = sEggHatchTiles,
.size = 2048, .size = 0x800,
.tag = 12345, .tag = GFXTAG_EGG,
}; };
static const struct SpriteSheet sEggShards_Sheet = static const struct SpriteSheet sEggShards_Sheet =
{ {
.data = sEggShardTiles, .data = sEggShardTiles,
.size = 128, .size = 0x80,
.tag = 23456, .tag = GFXTAG_EGG_SHARD,
}; };
static const struct SpritePalette sEgg_SpritePalette = static const struct SpritePalette sEgg_SpritePalette =
{ {
.data = sEggPalette, .data = sEggPalette,
.tag = 54321 .tag = PALTAG_EGG
}; };
static const struct SpriteTemplate sSpriteTemplate_EggHatch = static const struct SpriteTemplate sSpriteTemplate_Egg =
{ {
.tileTag = 12345, .tileTag = GFXTAG_EGG,
.paletteTag = 54321, .paletteTag = PALTAG_EGG,
.oam = &sOamData_EggHatch, .oam = &sOamData_Egg,
.anims = sSpriteAnimTable_EggHatch, .anims = sSpriteAnimTable_Egg,
.images = NULL, .images = NULL,
.affineAnims = gDummySpriteAffineAnimTable, .affineAnims = gDummySpriteAffineAnimTable,
.callback = SpriteCallbackDummy .callback = SpriteCallbackDummy
@ -211,8 +224,8 @@ static const union AnimCmd *const sSpriteAnimTable_EggShard[] =
static const struct SpriteTemplate sSpriteTemplate_EggShard = static const struct SpriteTemplate sSpriteTemplate_EggShard =
{ {
.tileTag = 23456, .tileTag = GFXTAG_EGG_SHARD,
.paletteTag = 54321, .paletteTag = PALTAG_EGG,
.oam = &sOamData_EggShard, .oam = &sOamData_EggShard,
.anims = sSpriteAnimTable_EggShard, .anims = sSpriteAnimTable_EggShard,
.images = NULL, .images = NULL,
@ -220,7 +233,7 @@ static const struct SpriteTemplate sSpriteTemplate_EggShard =
.callback = SpriteCB_EggShard .callback = SpriteCB_EggShard
}; };
static const struct BgTemplate sBgTemplates_EggHatch[2] = static const struct BgTemplate sBgTemplates_EggHatch[] =
{ {
{ {
.bg = 0, .bg = 0,
@ -243,7 +256,7 @@ static const struct BgTemplate sBgTemplates_EggHatch[2] =
}, },
}; };
static const struct WindowTemplate sWinTemplates_EggHatch[2] = static const struct WindowTemplate sWinTemplates_EggHatch[] =
{ {
{ {
.bg = 0, .bg = 0,
@ -270,9 +283,14 @@ static const struct WindowTemplate sYesNoWinTemplate =
static const s16 sEggShardVelocities[][2] = static const s16 sEggShardVelocities[][2] =
{ {
// First shake
{Q_8_8(-1.5), Q_8_8(-3.75)}, {Q_8_8(-1.5), Q_8_8(-3.75)},
// Third shake
{Q_8_8(-5), Q_8_8(-3)}, {Q_8_8(-5), Q_8_8(-3)},
{Q_8_8(3.5), Q_8_8(-3)}, {Q_8_8(3.5), Q_8_8(-3)},
// Hatching
{Q_8_8(-4), Q_8_8(-3.75)}, {Q_8_8(-4), Q_8_8(-3.75)},
{Q_8_8(2), Q_8_8(-1.5)}, {Q_8_8(2), Q_8_8(-1.5)},
{Q_8_8(-0.5), Q_8_8(-6.75)}, {Q_8_8(-0.5), Q_8_8(-6.75)},
@ -291,8 +309,6 @@ static const s16 sEggShardVelocities[][2] =
{Q_8_8(2.5), Q_8_8(-7.5)}, {Q_8_8(2.5), Q_8_8(-7.5)},
}; };
// code
static void CreateHatchedMon(struct Pokemon *egg, struct Pokemon *temp) static void CreateHatchedMon(struct Pokemon *egg, struct Pokemon *temp)
{ {
u16 species; u16 species;
@ -301,21 +317,17 @@ static void CreateHatchedMon(struct Pokemon *egg, struct Pokemon *temp)
u16 moves[MAX_MON_MOVES]; u16 moves[MAX_MON_MOVES];
u32 ivs[NUM_STATS]; u32 ivs[NUM_STATS];
species = GetMonData(egg, MON_DATA_SPECIES); species = GetMonData(egg, MON_DATA_SPECIES);
for (i = 0; i < MAX_MON_MOVES; i++) for (i = 0; i < MAX_MON_MOVES; i++)
{
moves[i] = GetMonData(egg, MON_DATA_MOVE1 + i); moves[i] = GetMonData(egg, MON_DATA_MOVE1 + i);
}
personality = GetMonData(egg, MON_DATA_PERSONALITY); personality = GetMonData(egg, MON_DATA_PERSONALITY);
for (i = 0; i < NUM_STATS; i++) for (i = 0; i < NUM_STATS; i++)
{
ivs[i] = GetMonData(egg, MON_DATA_HP_IV + i); ivs[i] = GetMonData(egg, MON_DATA_HP_IV + i);
}
// The language is initially read from the Egg but is later overwritten below
language = GetMonData(egg, MON_DATA_LANGUAGE); language = GetMonData(egg, MON_DATA_LANGUAGE);
gameMet = GetMonData(egg, MON_DATA_MET_GAME); gameMet = GetMonData(egg, MON_DATA_MET_GAME);
markings = GetMonData(egg, MON_DATA_MARKINGS); markings = GetMonData(egg, MON_DATA_MARKINGS);
@ -325,14 +337,10 @@ static void CreateHatchedMon(struct Pokemon *egg, struct Pokemon *temp)
CreateMon(temp, species, EGG_HATCH_LEVEL, USE_RANDOM_IVS, TRUE, personality, OT_ID_PLAYER_ID, 0); CreateMon(temp, species, EGG_HATCH_LEVEL, USE_RANDOM_IVS, TRUE, personality, OT_ID_PLAYER_ID, 0);
for (i = 0; i < MAX_MON_MOVES; i++) for (i = 0; i < MAX_MON_MOVES; i++)
{
SetMonData(temp, MON_DATA_MOVE1 + i, &moves[i]); SetMonData(temp, MON_DATA_MOVE1 + i, &moves[i]);
}
for (i = 0; i < NUM_STATS; i++) for (i = 0; i < NUM_STATS; i++)
{
SetMonData(temp, MON_DATA_HP_IV + i, &ivs[i]); SetMonData(temp, MON_DATA_HP_IV + i, &ivs[i]);
}
language = GAME_LANGUAGE; language = GAME_LANGUAGE;
SetMonData(temp, MON_DATA_LANGUAGE, &language); SetMonData(temp, MON_DATA_LANGUAGE, &language);
@ -350,34 +358,35 @@ static void CreateHatchedMon(struct Pokemon *egg, struct Pokemon *temp)
static void AddHatchedMonToParty(u8 id) static void AddHatchedMonToParty(u8 id)
{ {
u8 isEgg = 0x46; // ? u8 isEgg = 0x46; // ?
u16 pokeNum; u16 species;
u8 name[12]; u8 name[POKEMON_NAME_LENGTH + 1];
u16 ball; u16 ball;
u16 caughtLvl; u16 metLevel;
u8 mapNameID; u8 metLocation;
struct Pokemon* mon = &gPlayerParty[id]; struct Pokemon* mon = &gPlayerParty[id];
CreateHatchedMon(mon, &gEnemyParty[0]); CreateHatchedMon(mon, &gEnemyParty[0]);
SetMonData(mon, MON_DATA_IS_EGG, &isEgg); SetMonData(mon, MON_DATA_IS_EGG, &isEgg);
pokeNum = GetMonData(mon, MON_DATA_SPECIES); species = GetMonData(mon, MON_DATA_SPECIES);
GetSpeciesName(name, pokeNum); GetSpeciesName(name, species);
SetMonData(mon, MON_DATA_NICKNAME, name); SetMonData(mon, MON_DATA_NICKNAME, name);
pokeNum = SpeciesToNationalPokedexNum(pokeNum); species = SpeciesToNationalPokedexNum(species);
GetSetPokedexFlag(pokeNum, FLAG_SET_SEEN); GetSetPokedexFlag(species, FLAG_SET_SEEN);
GetSetPokedexFlag(pokeNum, FLAG_SET_CAUGHT); GetSetPokedexFlag(species, FLAG_SET_CAUGHT);
GetMonNickname2(mon, gStringVar1); GetMonNickname2(mon, gStringVar1);
ball = ITEM_POKE_BALL; ball = ITEM_POKE_BALL;
SetMonData(mon, MON_DATA_POKEBALL, &ball); SetMonData(mon, MON_DATA_POKEBALL, &ball);
caughtLvl = 0; // A met level of 0 is interpreted on the summary screen as "hatched at"
SetMonData(mon, MON_DATA_MET_LEVEL, &caughtLvl); metLevel = 0;
SetMonData(mon, MON_DATA_MET_LEVEL, &metLevel);
mapNameID = GetCurrentRegionMapSectionId(); metLocation = GetCurrentRegionMapSectionId();
SetMonData(mon, MON_DATA_MET_LOCATION, &mapNameID); SetMonData(mon, MON_DATA_MET_LOCATION, &metLocation);
MonRestorePP(mon); MonRestorePP(mon);
CalculateMonStats(mon); CalculateMonStats(mon);
@ -396,7 +405,7 @@ static bool8 _CheckDaycareMonReceivedMail(struct DayCare *daycare, u8 daycareId)
GetBoxMonNickname(&daycareMon->mon, nickname); GetBoxMonNickname(&daycareMon->mon, nickname);
if (daycareMon->mail.message.itemId != ITEM_NONE if (daycareMon->mail.message.itemId != ITEM_NONE
&& (StringCompareWithoutExtCtrlCodes(nickname, daycareMon->mail.monName) != 0 && (StringCompareWithoutExtCtrlCodes(nickname, daycareMon->mail.monName) != 0
|| StringCompareWithoutExtCtrlCodes(gSaveBlock2Ptr->playerName, daycareMon->mail.otName) != 0)) || StringCompareWithoutExtCtrlCodes(gSaveBlock2Ptr->playerName, daycareMon->mail.otName) != 0))
{ {
StringCopy(gStringVar1, nickname); StringCopy(gStringVar1, nickname);
TVShowConvertInternationalString(gStringVar2, daycareMon->mail.otName, daycareMon->mail.gameLanguage); TVShowConvertInternationalString(gStringVar2, daycareMon->mail.otName, daycareMon->mail.gameLanguage);
@ -411,26 +420,27 @@ bool8 CheckDaycareMonReceivedMail(void)
return _CheckDaycareMonReceivedMail(&gSaveBlock1Ptr->daycare, gSpecialVar_0x8004); return _CheckDaycareMonReceivedMail(&gSaveBlock1Ptr->daycare, gSpecialVar_0x8004);
} }
static u8 EggHatchCreateMonSprite(u8 useAlt, u8 switchID, u8 pokeID, u16* speciesLoc) static u8 EggHatchCreateMonSprite(u8 useAlt, u8 state, u8 partyId, u16* speciesLoc)
{ {
u8 position = 0; u8 position = 0;
u8 spriteID = 0; u8 spriteId = 0;
struct Pokemon* mon = NULL; struct Pokemon* mon = NULL;
if (useAlt == FALSE) if (useAlt == FALSE)
{ {
mon = &gPlayerParty[pokeID]; mon = &gPlayerParty[partyId];
position = B_POSITION_OPPONENT_LEFT; position = B_POSITION_OPPONENT_LEFT;
} }
if (useAlt == TRUE) if (useAlt == TRUE)
{ {
// Alternate sprite allocation position. Never reached. // Alternate sprite allocation position. Never reached.
mon = &gPlayerParty[pokeID]; mon = &gPlayerParty[partyId];
position = B_POSITION_OPPONENT_RIGHT; position = B_POSITION_OPPONENT_RIGHT;
} }
switch (switchID) switch (state)
{ {
case 0: case 0:
// Load mon sprite gfx
{ {
u16 species = GetMonData(mon, MON_DATA_SPECIES); u16 species = GetMonData(mon, MON_DATA_SPECIES);
u32 pid = GetMonData(mon, MON_DATA_PERSONALITY); u32 pid = GetMonData(mon, MON_DATA_PERSONALITY);
@ -442,13 +452,14 @@ static u8 EggHatchCreateMonSprite(u8 useAlt, u8 switchID, u8 pokeID, u16* specie
} }
break; break;
case 1: case 1:
// Create mon sprite
SetMultiuseSpriteTemplateToPokemon(GetMonSpritePalStruct(mon)->tag, position); SetMultiuseSpriteTemplateToPokemon(GetMonSpritePalStruct(mon)->tag, position);
spriteID = CreateSprite(&gMultiuseSpriteTemplate, 120, 75, 6); spriteId = CreateSprite(&gMultiuseSpriteTemplate, EGG_X, EGG_Y, 6);
gSprites[spriteID].invisible = TRUE; gSprites[spriteId].invisible = TRUE;
gSprites[spriteID].callback = SpriteCallbackDummy; gSprites[spriteId].callback = SpriteCallbackDummy;
break; break;
} }
return spriteID; return spriteId;
} }
static void VBlankCB_EggHatch(void) static void VBlankCB_EggHatch(void)
@ -465,28 +476,28 @@ void EggHatch(void)
FadeScreen(FADE_TO_BLACK, 0); FadeScreen(FADE_TO_BLACK, 0);
} }
static void Task_EggHatch(u8 taskID) static void Task_EggHatch(u8 taskId)
{ {
if (!gPaletteFade.active) if (!gPaletteFade.active)
{ {
CleanupOverworldWindowsAndTilemaps(); CleanupOverworldWindowsAndTilemaps();
SetMainCallback2(CB2_EggHatch_0); SetMainCallback2(CB2_LoadEggHatch);
gFieldCallback = FieldCB_ContinueScriptHandleMusic; gFieldCallback = FieldCB_ContinueScriptHandleMusic;
DestroyTask(taskID); DestroyTask(taskId);
} }
} }
static void CB2_EggHatch_0(void) static void CB2_LoadEggHatch(void)
{ {
switch (gMain.state) switch (gMain.state)
{ {
case 0: case 0:
SetGpuReg(REG_OFFSET_DISPCNT, 0); SetGpuReg(REG_OFFSET_DISPCNT, 0);
sEggHatchData = Alloc(sizeof(struct EggHatchData)); sEggHatchData = Alloc(sizeof(*sEggHatchData));
AllocateMonSpritesGfx(); AllocateMonSpritesGfx();
sEggHatchData->eggPartyID = gSpecialVar_0x8004; sEggHatchData->eggPartyId = gSpecialVar_0x8004;
sEggHatchData->eggShardVelocityID = 0; sEggHatchData->eggShardVelocityId = 0;
SetVBlankCallback(VBlankCB_EggHatch); SetVBlankCallback(VBlankCB_EggHatch);
gSpecialVar_0x8005 = GetCurrentMapMusic(); gSpecialVar_0x8005 = GetCurrentMapMusic();
@ -532,15 +543,15 @@ static void CB2_EggHatch_0(void)
break; break;
case 4: case 4:
CopyBgTilemapBufferToVram(0); CopyBgTilemapBufferToVram(0);
AddHatchedMonToParty(sEggHatchData->eggPartyID); AddHatchedMonToParty(sEggHatchData->eggPartyId);
gMain.state++; gMain.state++;
break; break;
case 5: case 5:
EggHatchCreateMonSprite(FALSE, 0, sEggHatchData->eggPartyID, &sEggHatchData->species); EggHatchCreateMonSprite(FALSE, 0, sEggHatchData->eggPartyId, &sEggHatchData->species);
gMain.state++; gMain.state++;
break; break;
case 6: case 6:
sEggHatchData->pokeSpriteID = EggHatchCreateMonSprite(FALSE, 1, sEggHatchData->eggPartyID, &sEggHatchData->species); sEggHatchData->monSpriteId = EggHatchCreateMonSprite(FALSE, 1, sEggHatchData->eggPartyId, &sEggHatchData->species);
gMain.state++; gMain.state++;
break; break;
case 7: case 7:
@ -552,8 +563,8 @@ static void CB2_EggHatch_0(void)
gMain.state++; gMain.state++;
break; break;
case 8: case 8:
SetMainCallback2(CB2_EggHatch_1); SetMainCallback2(CB2_EggHatch);
sEggHatchData->CB2_state = 0; sEggHatchData->state = 0;
break; break;
} }
RunTasks(); RunTasks();
@ -571,121 +582,127 @@ static void EggHatchSetMonNickname(void)
SetMainCallback2(CB2_ReturnToField); SetMainCallback2(CB2_ReturnToField);
} }
static void Task_EggHatchPlayBGM(u8 taskID) #define tTimer data[0]
static void Task_EggHatchPlayBGM(u8 taskId)
{ {
if (gTasks[taskID].data[0] == 0) if (gTasks[taskId].tTimer == 0)
{ {
StopMapMusic(); StopMapMusic();
PlayRainStoppingSoundEffect(); PlayRainStoppingSoundEffect();
} }
if (gTasks[taskID].data[0] == 1)
if (gTasks[taskId].tTimer == 1)
PlayBGM(MUS_EVOLUTION_INTRO); PlayBGM(MUS_EVOLUTION_INTRO);
if (gTasks[taskID].data[0] > 60)
if (gTasks[taskId].tTimer > 60)
{ {
PlayBGM(MUS_EVOLUTION); PlayBGM(MUS_EVOLUTION);
DestroyTask(taskID); DestroyTask(taskId);
// UB: task is destroyed, yet the value is incremented
#ifdef UBFIX
return;
#endif
} }
gTasks[taskID].data[0]++; gTasks[taskId].tTimer++;
} }
static void CB2_EggHatch_1(void) static void CB2_EggHatch(void)
{ {
u16 species; u16 species;
u8 gender; u8 gender;
u32 personality; u32 personality;
switch (sEggHatchData->CB2_state) switch (sEggHatchData->state)
{ {
case 0: case 0:
BeginNormalPaletteFade(PALETTES_ALL, 0, 0x10, 0, RGB_BLACK); BeginNormalPaletteFade(PALETTES_ALL, 0, 16, 0, RGB_BLACK);
sEggHatchData->eggSpriteID = CreateSprite(&sSpriteTemplate_EggHatch, 120, 75, 5); sEggHatchData->eggSpriteId = CreateSprite(&sSpriteTemplate_Egg, EGG_X, EGG_Y, 5);
ShowBg(0); ShowBg(0);
ShowBg(1); ShowBg(1);
sEggHatchData->CB2_state++; sEggHatchData->state++;
CreateTask(Task_EggHatchPlayBGM, 5); CreateTask(Task_EggHatchPlayBGM, 5);
break; break;
case 1: case 1:
if (!gPaletteFade.active) if (!gPaletteFade.active)
{ {
FillWindowPixelBuffer(sEggHatchData->windowId, PIXEL_FILL(0)); FillWindowPixelBuffer(sEggHatchData->windowId, PIXEL_FILL(0));
sEggHatchData->CB2_PalCounter = 0; sEggHatchData->delayTimer = 0;
sEggHatchData->CB2_state++; sEggHatchData->state++;
} }
break; break;
case 2: case 2:
if (++sEggHatchData->CB2_PalCounter > 30) if (++sEggHatchData->delayTimer > 30)
{ {
sEggHatchData->CB2_state++; // Start hatching animation
gSprites[sEggHatchData->eggSpriteID].callback = SpriteCB_Egg_0; sEggHatchData->state++;
gSprites[sEggHatchData->eggSpriteId].callback = SpriteCB_Egg_Shake1;
} }
break; break;
case 3: case 3:
if (gSprites[sEggHatchData->eggSpriteID].callback == SpriteCallbackDummy) // Wait for hatching animation to finish
if (gSprites[sEggHatchData->eggSpriteId].callback == SpriteCallbackDummy)
{ {
species = GetMonData(&gPlayerParty[sEggHatchData->eggPartyID], MON_DATA_SPECIES); species = GetMonData(&gPlayerParty[sEggHatchData->eggPartyId], MON_DATA_SPECIES);
DoMonFrontSpriteAnimation(&gSprites[sEggHatchData->pokeSpriteID], species, FALSE, 1); DoMonFrontSpriteAnimation(&gSprites[sEggHatchData->monSpriteId], species, FALSE, 1);
sEggHatchData->CB2_state++; sEggHatchData->state++;
} }
break; break;
case 4: case 4:
if (gSprites[sEggHatchData->pokeSpriteID].callback == SpriteCallbackDummy) // Wait for Pokémon's front sprite animation
{ if (gSprites[sEggHatchData->monSpriteId].callback == SpriteCallbackDummy)
sEggHatchData->CB2_state++; sEggHatchData->state++;
}
break; break;
case 5: case 5:
GetMonNickname2(&gPlayerParty[sEggHatchData->eggPartyID], gStringVar1); // "{mon} hatched from egg" message/fanfare
GetMonNickname2(&gPlayerParty[sEggHatchData->eggPartyId], gStringVar1);
StringExpandPlaceholders(gStringVar4, gText_HatchedFromEgg); StringExpandPlaceholders(gStringVar4, gText_HatchedFromEgg);
EggHatchPrintMessage(sEggHatchData->windowId, gStringVar4, 0, 3, TEXT_SKIP_DRAW); EggHatchPrintMessage(sEggHatchData->windowId, gStringVar4, 0, 3, TEXT_SKIP_DRAW);
PlayFanfare(MUS_EVOLVED); PlayFanfare(MUS_EVOLVED);
sEggHatchData->CB2_state++; sEggHatchData->state++;
PutWindowTilemap(sEggHatchData->windowId); PutWindowTilemap(sEggHatchData->windowId);
CopyWindowToVram(sEggHatchData->windowId, COPYWIN_FULL); CopyWindowToVram(sEggHatchData->windowId, COPYWIN_FULL);
break; break;
case 6: case 6:
if (IsFanfareTaskInactive()) if (IsFanfareTaskInactive())
sEggHatchData->CB2_state++; sEggHatchData->state++;
break; break;
case 7: case 7: // Twice?
if (IsFanfareTaskInactive()) if (IsFanfareTaskInactive())
sEggHatchData->CB2_state++; sEggHatchData->state++;
break; break;
case 8: case 8:
GetMonNickname2(&gPlayerParty[sEggHatchData->eggPartyID], gStringVar1); // Ready the nickname prompt
GetMonNickname2(&gPlayerParty[sEggHatchData->eggPartyId], gStringVar1);
StringExpandPlaceholders(gStringVar4, gText_NicknameHatchPrompt); StringExpandPlaceholders(gStringVar4, gText_NicknameHatchPrompt);
EggHatchPrintMessage(sEggHatchData->windowId, gStringVar4, 0, 2, 1); EggHatchPrintMessage(sEggHatchData->windowId, gStringVar4, 0, 2, 1);
sEggHatchData->CB2_state++; sEggHatchData->state++;
break; break;
case 9: case 9:
// Print the nickname prompt
if (!IsTextPrinterActive(sEggHatchData->windowId)) if (!IsTextPrinterActive(sEggHatchData->windowId))
{ {
LoadUserWindowBorderGfx(sEggHatchData->windowId, 0x140, 0xE0); LoadUserWindowBorderGfx(sEggHatchData->windowId, 0x140, 0xE0);
CreateYesNoMenu(&sYesNoWinTemplate, 0x140, 0xE, 0); CreateYesNoMenu(&sYesNoWinTemplate, 0x140, 0xE, 0);
sEggHatchData->CB2_state++; sEggHatchData->state++;
} }
break; break;
case 10: case 10:
// Handle the nickname prompt input
switch (Menu_ProcessInputNoWrapClearOnChoose()) switch (Menu_ProcessInputNoWrapClearOnChoose())
{ {
case 0: case 0: // Yes
GetMonNickname2(&gPlayerParty[sEggHatchData->eggPartyID], gStringVar3); GetMonNickname2(&gPlayerParty[sEggHatchData->eggPartyId], gStringVar3);
species = GetMonData(&gPlayerParty[sEggHatchData->eggPartyID], MON_DATA_SPECIES); species = GetMonData(&gPlayerParty[sEggHatchData->eggPartyId], MON_DATA_SPECIES);
gender = GetMonGender(&gPlayerParty[sEggHatchData->eggPartyID]); gender = GetMonGender(&gPlayerParty[sEggHatchData->eggPartyId]);
personality = GetMonData(&gPlayerParty[sEggHatchData->eggPartyID], MON_DATA_PERSONALITY, 0); personality = GetMonData(&gPlayerParty[sEggHatchData->eggPartyId], MON_DATA_PERSONALITY, 0);
DoNamingScreen(NAMING_SCREEN_NICKNAME, gStringVar3, species, gender, personality, EggHatchSetMonNickname); DoNamingScreen(NAMING_SCREEN_NICKNAME, gStringVar3, species, gender, personality, EggHatchSetMonNickname);
break; break;
case 1: case 1: // No
case -1: case MENU_B_PRESSED:
sEggHatchData->CB2_state++; sEggHatchData->state++;
break;
} }
break; break;
case 11: case 11:
BeginNormalPaletteFade(PALETTES_ALL, 0, 0, 0x10, RGB_BLACK); BeginNormalPaletteFade(PALETTES_ALL, 0, 0, 16, RGB_BLACK);
sEggHatchData->CB2_state++; sEggHatchData->state++;
break; break;
case 12: case 12:
if (!gPaletteFade.active) if (!gPaletteFade.active)
@ -707,136 +724,170 @@ static void CB2_EggHatch_1(void)
UpdatePaletteFade(); UpdatePaletteFade();
} }
static void SpriteCB_Egg_0(struct Sprite* sprite) #define sTimer data[0]
#define sSinIdx data[1]
#define sDelayTimer data[2]
static void SpriteCB_Egg_Shake1(struct Sprite* sprite)
{ {
if (++sprite->data[0] > 20) if (++sprite->sTimer > 20)
{ {
sprite->callback = SpriteCB_Egg_1; sprite->callback = SpriteCB_Egg_Shake2;
sprite->data[0] = 0; sprite->sTimer = 0;
} }
else else
{ {
sprite->data[1] = (sprite->data[1] + 20) & 0xFF; // Shake egg
sprite->x2 = Sin(sprite->data[1], 1); sprite->sSinIdx = (sprite->sSinIdx + 20) & 0xFF;
if (sprite->data[0] == 15) sprite->x2 = Sin(sprite->sSinIdx, 1);
if (sprite->sTimer == 15)
{ {
// First egg crack
PlaySE(SE_BALL); PlaySE(SE_BALL);
StartSpriteAnim(sprite, 1); StartSpriteAnim(sprite, EGG_ANIM_CRACKED_1);
CreateRandomEggShardSprite(); CreateRandomEggShardSprite();
} }
} }
} }
static void SpriteCB_Egg_1(struct Sprite* sprite) static void SpriteCB_Egg_Shake2(struct Sprite* sprite)
{ {
if (++sprite->data[2] > 30) if (++sprite->sDelayTimer > 30)
{ {
if (++sprite->data[0] > 20) if (++sprite->sTimer > 20)
{ {
sprite->callback = SpriteCB_Egg_2; sprite->callback = SpriteCB_Egg_Shake3;
sprite->data[0] = 0; sprite->sTimer = 0;
sprite->data[2] = 0; sprite->sDelayTimer = 0;
} }
else else
{ {
sprite->data[1] = (sprite->data[1] + 20) & 0xFF; // Shake egg
sprite->x2 = Sin(sprite->data[1], 2); sprite->sSinIdx = (sprite->sSinIdx + 20) & 0xFF;
if (sprite->data[0] == 15) sprite->x2 = Sin(sprite->sSinIdx, 2);
if (sprite->sTimer == 15)
{ {
// Second egg crack
PlaySE(SE_BALL); PlaySE(SE_BALL);
StartSpriteAnim(sprite, 2); StartSpriteAnim(sprite, EGG_ANIM_CRACKED_2);
} }
} }
} }
} }
static void SpriteCB_Egg_2(struct Sprite* sprite) static void SpriteCB_Egg_Shake3(struct Sprite* sprite)
{ {
if (++sprite->data[2] > 30) if (++sprite->sDelayTimer > 30)
{ {
if (++sprite->data[0] > 38) if (++sprite->sTimer > 38)
{ {
u16 species; u16 species;
sprite->callback = SpriteCB_Egg_WaitHatch;
sprite->callback = SpriteCB_Egg_3; sprite->sTimer = 0;
sprite->data[0] = 0; species = GetMonData(&gPlayerParty[sEggHatchData->eggPartyId], MON_DATA_SPECIES);
species = GetMonData(&gPlayerParty[sEggHatchData->eggPartyID], MON_DATA_SPECIES); gSprites[sEggHatchData->monSpriteId].x2 = 0;
gSprites[sEggHatchData->pokeSpriteID].x2 = 0; gSprites[sEggHatchData->monSpriteId].y2 = 0;
gSprites[sEggHatchData->pokeSpriteID].y2 = 0;
} }
else else
{ {
sprite->data[1] = (sprite->data[1] + 20) & 0xFF; // Shake egg
sprite->x2 = Sin(sprite->data[1], 2); sprite->sSinIdx = (sprite->sSinIdx + 20) & 0xFF;
if (sprite->data[0] == 15) sprite->x2 = Sin(sprite->sSinIdx, 2);
if (sprite->sTimer == 15)
{ {
// Third egg crack
// This ineffectually sets the animation to the frame it's already using.
// They likely meant to use the 3rd and final cracked frame of the egg, which goes unused as a result.
PlaySE(SE_BALL); PlaySE(SE_BALL);
StartSpriteAnim(sprite, 2); #ifdef BUGFIX
StartSpriteAnim(sprite, EGG_ANIM_CRACKED_3);
#else
StartSpriteAnim(sprite, EGG_ANIM_CRACKED_2);
#endif
CreateRandomEggShardSprite(); CreateRandomEggShardSprite();
CreateRandomEggShardSprite(); CreateRandomEggShardSprite();
} }
if (sprite->data[0] == 30) if (sprite->sTimer == 30)
PlaySE(SE_BALL); PlaySE(SE_BALL);
} }
} }
} }
static void SpriteCB_Egg_3(struct Sprite* sprite) static void SpriteCB_Egg_WaitHatch(struct Sprite* sprite)
{ {
if (++sprite->data[0] > 50) if (++sprite->sTimer > 50)
{ {
sprite->callback = SpriteCB_Egg_4; sprite->callback = SpriteCB_Egg_Hatch;
sprite->data[0] = 0; sprite->sTimer = 0;
} }
} }
static void SpriteCB_Egg_4(struct Sprite* sprite) static void SpriteCB_Egg_Hatch(struct Sprite* sprite)
{ {
s16 i; s16 i;
if (sprite->data[0] == 0)
BeginNormalPaletteFade(PALETTES_ALL, -1, 0, 0x10, RGB_WHITEALPHA); // Fade to white to hide transition from egg to Pokémon
if (sprite->data[0] < 4u) if (sprite->sTimer == 0)
BeginNormalPaletteFade(PALETTES_ALL, -1, 0, 16, RGB_WHITEALPHA);
// Create a shower of 16 egg shards in 4 groups of 4
if ((u32)sprite->sTimer < 4)
{ {
for (i = 0; i <= 3; i++) for (i = 0; i < 4; i++)
CreateRandomEggShardSprite(); CreateRandomEggShardSprite();
} }
sprite->data[0]++;
sprite->sTimer++;
if (!gPaletteFade.active) if (!gPaletteFade.active)
{ {
// Screen is hidden by the fade to white, hide egg
PlaySE(SE_EGG_HATCH); PlaySE(SE_EGG_HATCH);
sprite->invisible = TRUE; sprite->invisible = TRUE;
sprite->callback = SpriteCB_Egg_5; sprite->callback = SpriteCB_Egg_Reveal;
sprite->data[0] = 0; sprite->sTimer = 0;
} }
} }
static void SpriteCB_Egg_5(struct Sprite* sprite) static void SpriteCB_Egg_Reveal(struct Sprite* sprite)
{ {
if (sprite->data[0] == 0) if (sprite->sTimer == 0)
{ {
gSprites[sEggHatchData->pokeSpriteID].invisible = FALSE; // Reveal hatched Pokémon
StartSpriteAffineAnim(&gSprites[sEggHatchData->pokeSpriteID], BATTLER_AFFINE_EMERGE); gSprites[sEggHatchData->monSpriteId].invisible = FALSE;
StartSpriteAffineAnim(&gSprites[sEggHatchData->monSpriteId], BATTLER_AFFINE_EMERGE);
} }
if (sprite->data[0] == 8)
BeginNormalPaletteFade(PALETTES_ALL, -1, 0x10, 0, RGB_WHITEALPHA); // Fade back from white for reveal
if (sprite->data[0] <= 9) if (sprite->sTimer == 8)
gSprites[sEggHatchData->pokeSpriteID].y -= 1; BeginNormalPaletteFade(PALETTES_ALL, -1, 16, 0, RGB_WHITEALPHA);
if (sprite->data[0] > 40)
sprite->callback = SpriteCallbackDummy; if (sprite->sTimer <= 9)
sprite->data[0]++; gSprites[sEggHatchData->monSpriteId].y--;
if (sprite->sTimer > 40)
sprite->callback = SpriteCallbackDummy; // Finished
sprite->sTimer++;
} }
#define sVelocX data[1]
#define sVelocY data[2]
#define sAccelY data[3]
#define sDeltaX data[4]
#define sDeltaY data[5]
static void SpriteCB_EggShard(struct Sprite* sprite) static void SpriteCB_EggShard(struct Sprite* sprite)
{ {
sprite->data[4] += sprite->data[1]; sprite->sDeltaX += sprite->sVelocX;
sprite->data[5] += sprite->data[2]; sprite->sDeltaY += sprite->sVelocY;
sprite->x2 = sprite->data[4] / 256; sprite->x2 = sprite->sDeltaX / 256;
sprite->y2 = sprite->data[5] / 256; sprite->y2 = sprite->sDeltaY / 256;
sprite->data[2] += sprite->data[3]; sprite->sVelocY += sprite->sAccelY;
if (sprite->y + sprite->y2 > sprite->y + 20 && sprite->data[2] > 0) if (sprite->y + sprite->y2 > sprite->y + 20 && sprite->sVelocY > 0)
DestroySprite(sprite); DestroySprite(sprite);
} }
@ -844,20 +895,23 @@ static void CreateRandomEggShardSprite(void)
{ {
u16 spriteAnimIndex; u16 spriteAnimIndex;
s16 velocity1 = sEggShardVelocities[sEggHatchData->eggShardVelocityID][0]; s16 velocityX = sEggShardVelocities[sEggHatchData->eggShardVelocityId][0];
s16 velocity2 = sEggShardVelocities[sEggHatchData->eggShardVelocityID][1]; s16 velocityY = sEggShardVelocities[sEggHatchData->eggShardVelocityId][1];
sEggHatchData->eggShardVelocityID++; sEggHatchData->eggShardVelocityId++;
spriteAnimIndex = Random() % 4;
CreateEggShardSprite(120, 60, velocity1, velocity2, 100, spriteAnimIndex); // Randomly choose one of the 4 shard images
spriteAnimIndex = Random() % ARRAY_COUNT(sSpriteAnimTable_EggShard);
CreateEggShardSprite(EGG_X, EGG_Y - 15, velocityX, velocityY, 100, spriteAnimIndex);
} }
static void CreateEggShardSprite(u8 x, u8 y, s16 data1, s16 data2, s16 data3, u8 spriteAnimIndex) static void CreateEggShardSprite(u8 x, u8 y, s16 velocityX, s16 velocityY, s16 acceleration, u8 spriteAnimIndex)
{ {
u8 spriteID = CreateSprite(&sSpriteTemplate_EggShard, x, y, 4); u8 spriteId = CreateSprite(&sSpriteTemplate_EggShard, x, y, 4);
gSprites[spriteID].data[1] = data1; gSprites[spriteId].sVelocX = velocityX;
gSprites[spriteID].data[2] = data2; gSprites[spriteId].sVelocY = velocityY;
gSprites[spriteID].data[3] = data3; gSprites[spriteId].sAccelY = acceleration;
StartSpriteAnim(&gSprites[spriteID], spriteAnimIndex); StartSpriteAnim(&gSprites[spriteId], spriteAnimIndex);
} }
static void EggHatchPrintMessage(u8 windowId, u8* string, u8 x, u8 y, u8 speed) static void EggHatchPrintMessage(u8 windowId, u8* string, u8 x, u8 y, u8 speed)

View File

@ -744,26 +744,26 @@ static const u8 sJumpSpecialDirectionAnimNums[] = { // used for jumping onto sur
[DIR_NORTHEAST] = ANIM_GET_ON_OFF_POKEMON_NORTH, [DIR_NORTHEAST] = ANIM_GET_ON_OFF_POKEMON_NORTH,
}; };
static const u8 sAcroWheelieDirectionAnimNums[] = { static const u8 sAcroWheelieDirectionAnimNums[] = {
[DIR_NONE] = ANIM_BUNNY_HOPPY_BACK_WHEEL_SOUTH, [DIR_NONE] = ANIM_BUNNY_HOP_BACK_WHEEL_SOUTH,
[DIR_SOUTH] = ANIM_BUNNY_HOPPY_BACK_WHEEL_SOUTH, [DIR_SOUTH] = ANIM_BUNNY_HOP_BACK_WHEEL_SOUTH,
[DIR_NORTH] = ANIM_BUNNY_HOPPY_BACK_WHEEL_NORTH, [DIR_NORTH] = ANIM_BUNNY_HOP_BACK_WHEEL_NORTH,
[DIR_WEST] = ANIM_BUNNY_HOPPY_BACK_WHEEL_WEST, [DIR_WEST] = ANIM_BUNNY_HOP_BACK_WHEEL_WEST,
[DIR_EAST] = ANIM_BUNNY_HOPPY_BACK_WHEEL_EAST, [DIR_EAST] = ANIM_BUNNY_HOP_BACK_WHEEL_EAST,
[DIR_SOUTHWEST] = ANIM_BUNNY_HOPPY_BACK_WHEEL_SOUTH, [DIR_SOUTHWEST] = ANIM_BUNNY_HOP_BACK_WHEEL_SOUTH,
[DIR_SOUTHEAST] = ANIM_BUNNY_HOPPY_BACK_WHEEL_SOUTH, [DIR_SOUTHEAST] = ANIM_BUNNY_HOP_BACK_WHEEL_SOUTH,
[DIR_NORTHWEST] = ANIM_BUNNY_HOPPY_BACK_WHEEL_NORTH, [DIR_NORTHWEST] = ANIM_BUNNY_HOP_BACK_WHEEL_NORTH,
[DIR_NORTHEAST] = ANIM_BUNNY_HOPPY_BACK_WHEEL_NORTH, [DIR_NORTHEAST] = ANIM_BUNNY_HOP_BACK_WHEEL_NORTH,
}; };
static const u8 sAcroUnusedDirectionAnimNums[] = { static const u8 sAcroUnusedDirectionAnimNums[] = {
[DIR_NONE] = ANIM_BUNNY_HOPPY_FRONT_WHEEL_SOUTH, [DIR_NONE] = ANIM_BUNNY_HOP_FRONT_WHEEL_SOUTH,
[DIR_SOUTH] = ANIM_BUNNY_HOPPY_FRONT_WHEEL_SOUTH, [DIR_SOUTH] = ANIM_BUNNY_HOP_FRONT_WHEEL_SOUTH,
[DIR_NORTH] = ANIM_BUNNY_HOPPY_FRONT_WHEEL_NORTH, [DIR_NORTH] = ANIM_BUNNY_HOP_FRONT_WHEEL_NORTH,
[DIR_WEST] = ANIM_BUNNY_HOPPY_FRONT_WHEEL_WEST, [DIR_WEST] = ANIM_BUNNY_HOP_FRONT_WHEEL_WEST,
[DIR_EAST] = ANIM_BUNNY_HOPPY_FRONT_WHEEL_EAST, [DIR_EAST] = ANIM_BUNNY_HOP_FRONT_WHEEL_EAST,
[DIR_SOUTHWEST] = ANIM_BUNNY_HOPPY_FRONT_WHEEL_SOUTH, [DIR_SOUTHWEST] = ANIM_BUNNY_HOP_FRONT_WHEEL_SOUTH,
[DIR_SOUTHEAST] = ANIM_BUNNY_HOPPY_FRONT_WHEEL_SOUTH, [DIR_SOUTHEAST] = ANIM_BUNNY_HOP_FRONT_WHEEL_SOUTH,
[DIR_NORTHWEST] = ANIM_BUNNY_HOPPY_FRONT_WHEEL_NORTH, [DIR_NORTHWEST] = ANIM_BUNNY_HOP_FRONT_WHEEL_NORTH,
[DIR_NORTHEAST] = ANIM_BUNNY_HOPPY_FRONT_WHEEL_NORTH, [DIR_NORTHEAST] = ANIM_BUNNY_HOP_FRONT_WHEEL_NORTH,
}; };
static const u8 sAcroEndWheelieDirectionAnimNums[] = { static const u8 sAcroEndWheelieDirectionAnimNums[] = {
[DIR_NONE] = ANIM_STANDING_WHEELIE_BACK_WHEEL_SOUTH, [DIR_NONE] = ANIM_STANDING_WHEELIE_BACK_WHEEL_SOUTH,

View File

@ -863,7 +863,7 @@ static void Task_EvolutionScene(u8 taskId)
{ {
BufferMoveToLearnIntoBattleTextBuff2(); BufferMoveToLearnIntoBattleTextBuff2();
PlayFanfare(MUS_LEVEL_UP); PlayFanfare(MUS_LEVEL_UP);
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNLEARNEDMOVE - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNLEARNEDMOVE - BATTLESTRINGS_TABLE_START]);
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gTasks[taskId].tLearnsFirstMove = 0x40; // re-used as a counter gTasks[taskId].tLearnsFirstMove = 0x40; // re-used as a counter
gTasks[taskId].tState++; gTasks[taskId].tState++;
@ -881,7 +881,7 @@ static void Task_EvolutionScene(u8 taskId)
{ {
// "{mon} is trying to learn {move}" // "{mon} is trying to learn {move}"
BufferMoveToLearnIntoBattleTextBuff2(); BufferMoveToLearnIntoBattleTextBuff2();
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE1 - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE1 - BATTLESTRINGS_TABLE_START]);
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gTasks[taskId].tLearnMoveState++; gTasks[taskId].tLearnMoveState++;
} }
@ -890,7 +890,7 @@ static void Task_EvolutionScene(u8 taskId)
if (!IsTextPrinterActive(0) && !IsSEPlaying()) if (!IsTextPrinterActive(0) && !IsSEPlaying())
{ {
// "But, {mon} can't learn more than four moves" // "But, {mon} can't learn more than four moves"
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE2 - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE2 - BATTLESTRINGS_TABLE_START]);
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gTasks[taskId].tLearnMoveState++; gTasks[taskId].tLearnMoveState++;
} }
@ -899,7 +899,7 @@ static void Task_EvolutionScene(u8 taskId)
if (!IsTextPrinterActive(0) && !IsSEPlaying()) if (!IsTextPrinterActive(0) && !IsSEPlaying())
{ {
// "Delete a move to make room for {move}?" // "Delete a move to make room for {move}?"
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE3 - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE3 - BATTLESTRINGS_TABLE_START]);
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gTasks[taskId].tLearnMoveYesState = MVSTATE_SHOW_MOVE_SELECT; gTasks[taskId].tLearnMoveYesState = MVSTATE_SHOW_MOVE_SELECT;
gTasks[taskId].tLearnMoveNoState = MVSTATE_ASK_CANCEL; gTasks[taskId].tLearnMoveNoState = MVSTATE_ASK_CANCEL;
@ -987,7 +987,7 @@ static void Task_EvolutionScene(u8 taskId)
if (IsHMMove2(move)) if (IsHMMove2(move))
{ {
// Can't forget HMs // Can't forget HMs
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_HMMOVESCANTBEFORGOTTEN - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_HMMOVESCANTBEFORGOTTEN - BATTLESTRINGS_TABLE_START]);
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gTasks[taskId].tLearnMoveState = MVSTATE_RETRY_AFTER_HM; gTasks[taskId].tLearnMoveState = MVSTATE_RETRY_AFTER_HM;
} }
@ -1004,14 +1004,14 @@ static void Task_EvolutionScene(u8 taskId)
} }
break; break;
case MVSTATE_FORGET_MSG_1: case MVSTATE_FORGET_MSG_1:
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_123POOF - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_123POOF - BATTLESTRINGS_TABLE_START]);
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gTasks[taskId].tLearnMoveState++; gTasks[taskId].tLearnMoveState++;
break; break;
case MVSTATE_FORGET_MSG_2: case MVSTATE_FORGET_MSG_2:
if (!IsTextPrinterActive(0) && !IsSEPlaying()) if (!IsTextPrinterActive(0) && !IsSEPlaying())
{ {
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNFORGOTMOVE - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNFORGOTMOVE - BATTLESTRINGS_TABLE_START]);
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gTasks[taskId].tLearnMoveState++; gTasks[taskId].tLearnMoveState++;
} }
@ -1019,20 +1019,20 @@ static void Task_EvolutionScene(u8 taskId)
case MVSTATE_LEARNED_MOVE: case MVSTATE_LEARNED_MOVE:
if (!IsTextPrinterActive(0) && !IsSEPlaying()) if (!IsTextPrinterActive(0) && !IsSEPlaying())
{ {
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_ANDELLIPSIS - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_ANDELLIPSIS - BATTLESTRINGS_TABLE_START]);
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gTasks[taskId].tState = EVOSTATE_LEARNED_MOVE; gTasks[taskId].tState = EVOSTATE_LEARNED_MOVE;
} }
break; break;
case MVSTATE_ASK_CANCEL: case MVSTATE_ASK_CANCEL:
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_STOPLEARNINGMOVE - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_STOPLEARNINGMOVE - BATTLESTRINGS_TABLE_START]);
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gTasks[taskId].tLearnMoveYesState = MVSTATE_CANCEL; gTasks[taskId].tLearnMoveYesState = MVSTATE_CANCEL;
gTasks[taskId].tLearnMoveNoState = MVSTATE_INTRO_MSG_1; gTasks[taskId].tLearnMoveNoState = MVSTATE_INTRO_MSG_1;
gTasks[taskId].tLearnMoveState = MVSTATE_PRINT_YES_NO; gTasks[taskId].tLearnMoveState = MVSTATE_PRINT_YES_NO;
break; break;
case MVSTATE_CANCEL: case MVSTATE_CANCEL:
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_DIDNOTLEARNMOVE - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_DIDNOTLEARNMOVE - BATTLESTRINGS_TABLE_START]);
BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG); BattlePutTextOnWindow(gDisplayedStringBattle, B_WIN_MSG);
gTasks[taskId].tState = EVOSTATE_TRY_LEARN_MOVE; gTasks[taskId].tState = EVOSTATE_TRY_LEARN_MOVE;
break; break;
@ -1266,7 +1266,7 @@ static void Task_TradeEvolutionScene(u8 taskId)
{ {
BufferMoveToLearnIntoBattleTextBuff2(); BufferMoveToLearnIntoBattleTextBuff2();
PlayFanfare(MUS_LEVEL_UP); PlayFanfare(MUS_LEVEL_UP);
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNLEARNEDMOVE - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNLEARNEDMOVE - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tLearnsFirstMove = 0x40; // re-used as a counter gTasks[taskId].tLearnsFirstMove = 0x40; // re-used as a counter
gTasks[taskId].tState++; gTasks[taskId].tState++;
@ -1284,7 +1284,7 @@ static void Task_TradeEvolutionScene(u8 taskId)
{ {
// "{mon} is trying to learn {move}" // "{mon} is trying to learn {move}"
BufferMoveToLearnIntoBattleTextBuff2(); BufferMoveToLearnIntoBattleTextBuff2();
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE1 - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE1 - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tLearnMoveState++; gTasks[taskId].tLearnMoveState++;
} }
@ -1293,7 +1293,7 @@ static void Task_TradeEvolutionScene(u8 taskId)
if (!IsTextPrinterActive(0) && !IsSEPlaying()) if (!IsTextPrinterActive(0) && !IsSEPlaying())
{ {
// "But, {mon} can't learn more than four moves" // "But, {mon} can't learn more than four moves"
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE2 - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE2 - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tLearnMoveState++; gTasks[taskId].tLearnMoveState++;
} }
@ -1302,7 +1302,7 @@ static void Task_TradeEvolutionScene(u8 taskId)
if (!IsTextPrinterActive(0) && !IsSEPlaying()) if (!IsTextPrinterActive(0) && !IsSEPlaying())
{ {
// "Delete a move to make room for {move}?" // "Delete a move to make room for {move}?"
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE3 - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE3 - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tLearnMoveYesState = T_MVSTATE_SHOW_MOVE_SELECT; gTasks[taskId].tLearnMoveYesState = T_MVSTATE_SHOW_MOVE_SELECT;
gTasks[taskId].tLearnMoveNoState = T_MVSTATE_ASK_CANCEL; gTasks[taskId].tLearnMoveNoState = T_MVSTATE_ASK_CANCEL;
@ -1323,7 +1323,7 @@ static void Task_TradeEvolutionScene(u8 taskId)
{ {
case 0: // YES case 0: // YES
sEvoCursorPos = 0; sEvoCursorPos = 0;
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_EMPTYSTRING3 - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_EMPTYSTRING3 - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tLearnMoveState = gTasks[taskId].tLearnMoveYesState; gTasks[taskId].tLearnMoveState = gTasks[taskId].tLearnMoveYesState;
if (gTasks[taskId].tLearnMoveState == T_MVSTATE_SHOW_MOVE_SELECT) if (gTasks[taskId].tLearnMoveState == T_MVSTATE_SHOW_MOVE_SELECT)
@ -1332,7 +1332,7 @@ static void Task_TradeEvolutionScene(u8 taskId)
case 1: // NO case 1: // NO
case MENU_B_PRESSED: case MENU_B_PRESSED:
sEvoCursorPos = 1; sEvoCursorPos = 1;
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_EMPTYSTRING3 - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_EMPTYSTRING3 - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tLearnMoveState = gTasks[taskId].tLearnMoveNoState; gTasks[taskId].tLearnMoveState = gTasks[taskId].tLearnMoveNoState;
break; break;
@ -1371,7 +1371,7 @@ static void Task_TradeEvolutionScene(u8 taskId)
if (IsHMMove2(move)) if (IsHMMove2(move))
{ {
// Can't forget HMs // Can't forget HMs
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_HMMOVESCANTBEFORGOTTEN - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_HMMOVESCANTBEFORGOTTEN - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tLearnMoveState = T_MVSTATE_RETRY_AFTER_HM; gTasks[taskId].tLearnMoveState = T_MVSTATE_RETRY_AFTER_HM;
} }
@ -1382,7 +1382,7 @@ static void Task_TradeEvolutionScene(u8 taskId)
RemoveMonPPBonus(mon, var); RemoveMonPPBonus(mon, var);
SetMonMoveSlot(mon, gMoveToLearn, var); SetMonMoveSlot(mon, gMoveToLearn, var);
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_123POOF - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_123POOF - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tLearnMoveState++; gTasks[taskId].tLearnMoveState++;
} }
@ -1392,7 +1392,7 @@ static void Task_TradeEvolutionScene(u8 taskId)
case T_MVSTATE_FORGET_MSG: case T_MVSTATE_FORGET_MSG:
if (!IsTextPrinterActive(0) && !IsSEPlaying()) if (!IsTextPrinterActive(0) && !IsSEPlaying())
{ {
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNFORGOTMOVE - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNFORGOTMOVE - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tLearnMoveState++; gTasks[taskId].tLearnMoveState++;
} }
@ -1400,20 +1400,20 @@ static void Task_TradeEvolutionScene(u8 taskId)
case T_MVSTATE_LEARNED_MOVE: case T_MVSTATE_LEARNED_MOVE:
if (!IsTextPrinterActive(0) && !IsSEPlaying()) if (!IsTextPrinterActive(0) && !IsSEPlaying())
{ {
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_ANDELLIPSIS - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_ANDELLIPSIS - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tState = T_EVOSTATE_LEARNED_MOVE; gTasks[taskId].tState = T_EVOSTATE_LEARNED_MOVE;
} }
break; break;
case T_MVSTATE_ASK_CANCEL: case T_MVSTATE_ASK_CANCEL:
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_STOPLEARNINGMOVE - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_STOPLEARNINGMOVE - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tLearnMoveYesState = T_MVSTATE_CANCEL; gTasks[taskId].tLearnMoveYesState = T_MVSTATE_CANCEL;
gTasks[taskId].tLearnMoveNoState = T_MVSTATE_INTRO_MSG_1; gTasks[taskId].tLearnMoveNoState = T_MVSTATE_INTRO_MSG_1;
gTasks[taskId].tLearnMoveState = T_MVSTATE_PRINT_YES_NO; gTasks[taskId].tLearnMoveState = T_MVSTATE_PRINT_YES_NO;
break; break;
case T_MVSTATE_CANCEL: case T_MVSTATE_CANCEL:
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_DIDNOTLEARNMOVE - BATTLESTRINGS_ID_ADDER]); BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_DIDNOTLEARNMOVE - BATTLESTRINGS_TABLE_START]);
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1); DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
gTasks[taskId].tState = T_EVOSTATE_TRY_LEARN_MOVE; gTasks[taskId].tState = T_EVOSTATE_TRY_LEARN_MOVE;
break; break;

View File

@ -487,6 +487,8 @@ void UpdateLongGrassFieldEffect(struct Sprite *sprite)
#undef sCurrentMap #undef sCurrentMap
#undef sObjectMoved #undef sObjectMoved
// Effectively unused as it's not possible in vanilla to jump onto long grass (no adjacent ledges, and can't ride the Acro Bike in it).
// The graphics for this effect do not visually correspond to long grass either. Perhaps these graphics were its original design?
u32 FldEff_JumpLongGrass(void) u32 FldEff_JumpLongGrass(void)
{ {
u8 spriteId; u8 spriteId;