Merge branch 'master' into player_field_avatar

This commit is contained in:
MCboy
2018-08-12 23:26:00 +04:30
committed by GitHub
238 changed files with 40368 additions and 49947 deletions
+10 -10
View File
@@ -279,7 +279,7 @@ static void sub_8035C4C(void)
{
if (gBattleOutcome == B_OUTCOME_WON)
{
switch (gLinkPlayers[gBattleScripting.multiplayerId].lp_field_18)
switch (gLinkPlayers[gBattleScripting.multiplayerId].id)
{
case 0:
BattlePutTextOnWindow(gText_Win, 0x16);
@@ -301,7 +301,7 @@ static void sub_8035C4C(void)
}
else
{
switch (gLinkPlayers[gBattleScripting.multiplayerId].lp_field_18)
switch (gLinkPlayers[gBattleScripting.multiplayerId].id)
{
case 0:
BattlePutTextOnWindow(gText_Win, 0x17);
@@ -324,7 +324,7 @@ static void sub_8035C4C(void)
}
else if (gBattleOutcome == B_OUTCOME_WON)
{
if (gLinkPlayers[gBattleScripting.multiplayerId].lp_field_18 != 0)
if (gLinkPlayers[gBattleScripting.multiplayerId].id != 0)
{
BattlePutTextOnWindow(gText_Win, 0x17);
BattlePutTextOnWindow(gText_Loss, 0x16);
@@ -337,7 +337,7 @@ static void sub_8035C4C(void)
}
else
{
if (gLinkPlayers[gBattleScripting.multiplayerId].lp_field_18 != 0)
if (gLinkPlayers[gBattleScripting.multiplayerId].id != 0)
{
BattlePutTextOnWindow(gText_Win, 0x16);
BattlePutTextOnWindow(gText_Loss, 0x17);
@@ -366,23 +366,23 @@ void sub_8035D74(u8 taskId)
name = gLinkPlayers[i].name;
linkPlayer = &gLinkPlayers[i];
switch (linkPlayer->lp_field_18)
switch (linkPlayer->id)
{
case 0:
BattlePutTextOnWindow(name, 0x11);
sub_8035AE4(taskId, linkPlayer->lp_field_18, 1, 2, 4);
sub_8035AE4(taskId, linkPlayer->id, 1, 2, 4);
break;
case 1:
BattlePutTextOnWindow(name, 0x12);
sub_8035AE4(taskId, linkPlayer->lp_field_18, 2, 2, 4);
sub_8035AE4(taskId, linkPlayer->id, 2, 2, 4);
break;
case 2:
BattlePutTextOnWindow(name, 0x13);
sub_8035AE4(taskId, linkPlayer->lp_field_18, 1, 2, 8);
sub_8035AE4(taskId, linkPlayer->id, 1, 2, 8);
break;
case 3:
BattlePutTextOnWindow(name, 0x14);
sub_8035AE4(taskId, linkPlayer->lp_field_18, 2, 2, 8);
sub_8035AE4(taskId, linkPlayer->id, 2, 2, 8);
break;
}
}
@@ -393,7 +393,7 @@ void sub_8035D74(u8 taskId)
u8 opponentId = playerId ^ BIT_SIDE;
u8 opponentId_copy = opponentId;
if (gLinkPlayers[playerId].lp_field_18 != 0)
if (gLinkPlayers[playerId].id != 0)
opponentId = playerId, playerId = opponentId_copy;
name = gLinkPlayers[playerId].name;
+46 -46
View File
@@ -264,67 +264,67 @@ static void InitSinglePlayerBtlControllers(void)
for (var = gUnknown_0203C7B4, i = 0; i < MAX_BATTLERS_COUNT; i++)
{
switch (gLinkPlayers[i].lp_field_18)
switch (gLinkPlayers[i].id)
{
case 0:
case 3:
sub_81B8D64(gLinkPlayers[i].lp_field_18, 0);
sub_81B8D64(gLinkPlayers[i].id, 0);
break;
case 1:
case 2:
sub_81B8D64(gLinkPlayers[i].lp_field_18, 1);
sub_81B8D64(gLinkPlayers[i].id, 1);
break;
}
if (i == var)
{
gBattlerControllerFuncs[gLinkPlayers[i].lp_field_18] = SetControllerToRecordedPlayer;
switch (gLinkPlayers[i].lp_field_18)
gBattlerControllerFuncs[gLinkPlayers[i].id] = SetControllerToRecordedPlayer;
switch (gLinkPlayers[i].id)
{
case 0:
case 3:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = B_POSITION_PLAYER_LEFT;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 0;
gBattlerPositions[gLinkPlayers[i].id] = B_POSITION_PLAYER_LEFT;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 0;
break;
case 1:
case 2:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = B_POSITION_PLAYER_RIGHT;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 3;
gBattlerPositions[gLinkPlayers[i].id] = B_POSITION_PLAYER_RIGHT;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 3;
break;
}
}
else if ((!(gLinkPlayers[i].lp_field_18 & 1) && !(gLinkPlayers[var].lp_field_18 & 1))
|| ((gLinkPlayers[i].lp_field_18 & 1) && (gLinkPlayers[var].lp_field_18 & 1)))
else if ((!(gLinkPlayers[i].id & 1) && !(gLinkPlayers[var].id & 1))
|| ((gLinkPlayers[i].id & 1) && (gLinkPlayers[var].id & 1)))
{
gBattlerControllerFuncs[gLinkPlayers[i].lp_field_18] = SetControllerToRecordedPlayer;
switch (gLinkPlayers[i].lp_field_18)
gBattlerControllerFuncs[gLinkPlayers[i].id] = SetControllerToRecordedPlayer;
switch (gLinkPlayers[i].id)
{
case 0:
case 3:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = B_POSITION_PLAYER_LEFT;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 0;
gBattlerPositions[gLinkPlayers[i].id] = B_POSITION_PLAYER_LEFT;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 0;
break;
case 1:
case 2:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = B_POSITION_PLAYER_RIGHT;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 3;
gBattlerPositions[gLinkPlayers[i].id] = B_POSITION_PLAYER_RIGHT;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 3;
break;
}
}
else
{
gBattlerControllerFuncs[gLinkPlayers[i].lp_field_18] = SetControllerToRecordedOpponent;
switch (gLinkPlayers[i].lp_field_18)
gBattlerControllerFuncs[gLinkPlayers[i].id] = SetControllerToRecordedOpponent;
switch (gLinkPlayers[i].id)
{
case 0:
case 3:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = B_POSITION_OPPONENT_LEFT;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 0;
gBattlerPositions[gLinkPlayers[i].id] = B_POSITION_OPPONENT_LEFT;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 0;
break;
case 1:
case 2:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = B_POSITION_OPPONENT_RIGHT;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 3;
gBattlerPositions[gLinkPlayers[i].id] = B_POSITION_OPPONENT_RIGHT;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 3;
break;
}
}
@@ -506,69 +506,69 @@ static void InitLinkBtlControllers(void)
for (i = 0; i < MAX_BATTLERS_COUNT; i++)
{
switch (gLinkPlayers[i].lp_field_18)
switch (gLinkPlayers[i].id)
{
case 0:
case 3:
sub_81B8D64(gLinkPlayers[i].lp_field_18, 0);
sub_81B8D64(gLinkPlayers[i].id, 0);
break;
case 1:
case 2:
sub_81B8D64(gLinkPlayers[i].lp_field_18, 1);
sub_81B8D64(gLinkPlayers[i].id, 1);
break;
}
if (i == multiplayerId)
{
gBattlerControllerFuncs[gLinkPlayers[i].lp_field_18] = SetControllerToPlayer;
switch (gLinkPlayers[i].lp_field_18)
gBattlerControllerFuncs[gLinkPlayers[i].id] = SetControllerToPlayer;
switch (gLinkPlayers[i].id)
{
case 0:
case 3:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = 0;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 0;
gBattlerPositions[gLinkPlayers[i].id] = 0;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 0;
break;
case 1:
case 2:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = 2;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 3;
gBattlerPositions[gLinkPlayers[i].id] = 2;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 3;
break;
}
}
else
{
if ((!(gLinkPlayers[i].lp_field_18 & 1) && !(gLinkPlayers[multiplayerId].lp_field_18 & 1))
|| ((gLinkPlayers[i].lp_field_18 & 1) && (gLinkPlayers[multiplayerId].lp_field_18 & 1)))
if ((!(gLinkPlayers[i].id & 1) && !(gLinkPlayers[multiplayerId].id & 1))
|| ((gLinkPlayers[i].id & 1) && (gLinkPlayers[multiplayerId].id & 1)))
{
gBattlerControllerFuncs[gLinkPlayers[i].lp_field_18] = SetControllerToLinkPartner;
switch (gLinkPlayers[i].lp_field_18)
gBattlerControllerFuncs[gLinkPlayers[i].id] = SetControllerToLinkPartner;
switch (gLinkPlayers[i].id)
{
case 0:
case 3:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = 0;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 0;
gBattlerPositions[gLinkPlayers[i].id] = 0;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 0;
break;
case 1:
case 2:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = 2;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 3;
gBattlerPositions[gLinkPlayers[i].id] = 2;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 3;
break;
}
}
else
{
gBattlerControllerFuncs[gLinkPlayers[i].lp_field_18] = SetControllerToLinkOpponent;
switch (gLinkPlayers[i].lp_field_18)
gBattlerControllerFuncs[gLinkPlayers[i].id] = SetControllerToLinkOpponent;
switch (gLinkPlayers[i].id)
{
case 0:
case 3:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = 1;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 0;
gBattlerPositions[gLinkPlayers[i].id] = 1;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 0;
break;
case 1:
case 2:
gBattlerPositions[gLinkPlayers[i].lp_field_18] = 3;
gBattlerPartyIndexes[gLinkPlayers[i].lp_field_18] = 3;
gBattlerPositions[gLinkPlayers[i].id] = 3;
gBattlerPartyIndexes[gLinkPlayers[i].id] = 3;
break;
}
}
+13
View File
@@ -0,0 +1,13 @@
#include "global.h"
#include "battle.h"
#include "data2.h"
#include "constants/items.h"
#include "constants/moves.h"
#include "constants/species.h"
#include "constants/trainers.h"
#include "data/trainer_parties.h"
#include "data/text/trainer_class_names.h"
#include "data/trainers.h"
#include "data/text/species_names.h"
#include "data/text/move_names.h"
+26 -26
View File
@@ -828,7 +828,7 @@ static void SetAllPlayersBerryData(void)
for (i = 0; i < numPlayers; i++)
{
src = (struct BattleEnigmaBerry *)(gBlockRecvBuffer[i] + 2);
battlerId = gLinkPlayers[i].lp_field_18;
battlerId = gLinkPlayers[i].id;
for (j = 0; j < BERRY_NAME_COUNT - 1; j++)
gEnigmaBerries[battlerId].name[j] = src->name[j];
@@ -965,8 +965,8 @@ static void CB2_HandleStartBattle(void)
if (gTrainerBattleOpponent_A == TRAINER_OPPONENT_C00)
{
gLinkPlayers[0].lp_field_18 = 0;
gLinkPlayers[1].lp_field_18 = 1;
gLinkPlayers[0].id = 0;
gLinkPlayers[1].id = 1;
}
SendBlock(bitmask_all_link_players_but_self(), &gBattleStruct->field_180, 32);
@@ -1153,10 +1153,10 @@ static void CB2_HandleStartMultiPartnerBattle(void)
{
u8 language;
gLinkPlayers[0].lp_field_18 = 0;
gLinkPlayers[1].lp_field_18 = 2;
gLinkPlayers[2].lp_field_18 = 1;
gLinkPlayers[3].lp_field_18 = 3;
gLinkPlayers[0].id = 0;
gLinkPlayers[1].id = 2;
gLinkPlayers[2].id = 1;
gLinkPlayers[3].id = 3;
GetFrontierTrainerName(gLinkPlayers[2].name, gTrainerBattleOpponent_A);
GetFrontierTrainerName(gLinkPlayers[3].name, gTrainerBattleOpponent_B);
sub_8165B88(&language, gTrainerBattleOpponent_A);
@@ -1214,7 +1214,7 @@ static void CB2_HandleStartMultiPartnerBattle(void)
if ((GetBlockReceivedStatus() & 3) == 3)
{
ResetBlockReceivedFlags();
if (gLinkPlayers[playerMultiplayerId].lp_field_18 != 0)
if (gLinkPlayers[playerMultiplayerId].id != 0)
{
memcpy(gPlayerParty, gBlockRecvBuffer[enemyMultiplayerId], sizeof(struct Pokemon) * 2);
memcpy(gPlayerParty + 3, gBlockRecvBuffer[playerMultiplayerId], sizeof(struct Pokemon) * 2);
@@ -1238,7 +1238,7 @@ static void CB2_HandleStartMultiPartnerBattle(void)
if ((GetBlockReceivedStatus() & 3) == 3)
{
ResetBlockReceivedFlags();
if (gLinkPlayers[playerMultiplayerId].lp_field_18 != 0)
if (gLinkPlayers[playerMultiplayerId].id != 0)
{
memcpy(gPlayerParty + 2, gBlockRecvBuffer[enemyMultiplayerId], sizeof(struct Pokemon));
memcpy(gPlayerParty + 5, gBlockRecvBuffer[playerMultiplayerId], sizeof(struct Pokemon));
@@ -1429,8 +1429,8 @@ static void CB2_PreInitMultiBattle(void)
if (numPlayers == 4)
{
if ((!(gLinkPlayers[i].lp_field_18 & 1) && !(gLinkPlayers[playerMultiplierId].lp_field_18 & 1))
|| (gLinkPlayers[i].lp_field_18 & 1 && gLinkPlayers[playerMultiplierId].lp_field_18 & 1))
if ((!(gLinkPlayers[i].id & 1) && !(gLinkPlayers[playerMultiplierId].id & 1))
|| (gLinkPlayers[i].id & 1 && gLinkPlayers[playerMultiplierId].id & 1))
{
memcpy(gUnknown_02022FF8, gBlockRecvBuffer[i], sizeof(struct UnknownPokemonStruct4) * 3);
}
@@ -1590,7 +1590,7 @@ static void CB2_HandleStartMultiBattle(void)
for (id = 0; id < MAX_LINK_PLAYERS; id++)
{
sub_8185F90(gBlockRecvBuffer[id][1]);
switch (gLinkPlayers[id].lp_field_18)
switch (gLinkPlayers[id].id)
{
case 0:
gTasks[var].data[3] |= gBlockRecvBuffer[id][1] & 0x3F;
@@ -1627,7 +1627,7 @@ static void CB2_HandleStartMultiBattle(void)
{
if (id == playerMultiplayerId)
{
switch (gLinkPlayers[id].lp_field_18)
switch (gLinkPlayers[id].id)
{
case 0:
case 3:
@@ -1641,10 +1641,10 @@ static void CB2_HandleStartMultiBattle(void)
}
else
{
if ((!(gLinkPlayers[id].lp_field_18 & 1) && !(gLinkPlayers[playerMultiplayerId].lp_field_18 & 1))
|| ((gLinkPlayers[id].lp_field_18 & 1) && (gLinkPlayers[playerMultiplayerId].lp_field_18 & 1)))
if ((!(gLinkPlayers[id].id & 1) && !(gLinkPlayers[playerMultiplayerId].id & 1))
|| ((gLinkPlayers[id].id & 1) && (gLinkPlayers[playerMultiplayerId].id & 1)))
{
switch (gLinkPlayers[id].lp_field_18)
switch (gLinkPlayers[id].id)
{
case 0:
case 3:
@@ -1658,7 +1658,7 @@ static void CB2_HandleStartMultiBattle(void)
}
else
{
switch (gLinkPlayers[id].lp_field_18)
switch (gLinkPlayers[id].id)
{
case 0:
case 3:
@@ -1690,7 +1690,7 @@ static void CB2_HandleStartMultiBattle(void)
{
if (id == playerMultiplayerId)
{
switch (gLinkPlayers[id].lp_field_18)
switch (gLinkPlayers[id].id)
{
case 0:
case 3:
@@ -1704,10 +1704,10 @@ static void CB2_HandleStartMultiBattle(void)
}
else
{
if ((!(gLinkPlayers[id].lp_field_18 & 1) && !(gLinkPlayers[playerMultiplayerId].lp_field_18 & 1))
|| ((gLinkPlayers[id].lp_field_18 & 1) && (gLinkPlayers[playerMultiplayerId].lp_field_18 & 1)))
if ((!(gLinkPlayers[id].id & 1) && !(gLinkPlayers[playerMultiplayerId].id & 1))
|| ((gLinkPlayers[id].id & 1) && (gLinkPlayers[playerMultiplayerId].id & 1)))
{
switch (gLinkPlayers[id].lp_field_18)
switch (gLinkPlayers[id].id)
{
case 0:
case 3:
@@ -1721,7 +1721,7 @@ static void CB2_HandleStartMultiBattle(void)
}
else
{
switch (gLinkPlayers[id].lp_field_18)
switch (gLinkPlayers[id].id)
{
case 0:
case 3:
@@ -2095,7 +2095,7 @@ static void sub_8038B94(u8 taskId)
if (gBattleTypeFlags & BATTLE_TYPE_MULTI)
{
switch (gLinkPlayers[r2].lp_field_18)
switch (gLinkPlayers[r2].id)
{
case 0:
case 2:
@@ -3964,9 +3964,9 @@ void BattleTurnPassed(void)
TurnValuesCleanUp(TRUE);
if (gBattleOutcome == 0)
{
if (UpdateTurnCounters())
if (DoFieldEndTurnEffects())
return;
if (TurnBasedEffects())
if (DoBattlerEndTurnEffects())
return;
}
if (HandleFaintedMonActions())
@@ -4008,7 +4008,7 @@ void BattleTurnPassed(void)
gChosenMoveByBattler[i] = MOVE_NONE;
}
for (i = 0; i < 4; i++)
for (i = 0; i < MAX_BATTLERS_COUNT; i++)
*(gBattleStruct->monToSwitchIntoId + i) = PARTY_SIZE;
*(&gBattleStruct->field_91) = gAbsentBattlerFlags;
+9 -9
View File
@@ -2383,25 +2383,25 @@ u32 BattleStringExpandPlaceholders(const u8 *src, u8 *dst)
toCpy = text;
break;
case B_TXT_LINK_PLAYER_MON1_NAME: // link first player poke name
GetMonData(&gPlayerParty[gBattlerPartyIndexes[gLinkPlayers[multiplayerID].lp_field_18]],
GetMonData(&gPlayerParty[gBattlerPartyIndexes[gLinkPlayers[multiplayerID].id]],
MON_DATA_NICKNAME, text);
StringGetEnd10(text);
toCpy = text;
break;
case B_TXT_LINK_OPPONENT_MON1_NAME: // link first opponent poke name
GetMonData(&gEnemyParty[gBattlerPartyIndexes[gLinkPlayers[multiplayerID].lp_field_18 ^ 1]],
GetMonData(&gEnemyParty[gBattlerPartyIndexes[gLinkPlayers[multiplayerID].id ^ 1]],
MON_DATA_NICKNAME, text);
StringGetEnd10(text);
toCpy = text;
break;
case B_TXT_LINK_PLAYER_MON2_NAME: // link second player poke name
GetMonData(&gPlayerParty[gBattlerPartyIndexes[gLinkPlayers[multiplayerID].lp_field_18 ^ 2]],
GetMonData(&gPlayerParty[gBattlerPartyIndexes[gLinkPlayers[multiplayerID].id ^ 2]],
MON_DATA_NICKNAME, text);
StringGetEnd10(text);
toCpy = text;
break;
case B_TXT_LINK_OPPONENT_MON2_NAME: // link second opponent poke name
GetMonData(&gEnemyParty[gBattlerPartyIndexes[gLinkPlayers[multiplayerID].lp_field_18 ^ 3]],
GetMonData(&gEnemyParty[gBattlerPartyIndexes[gLinkPlayers[multiplayerID].id ^ 3]],
MON_DATA_NICKNAME, text);
StringGetEnd10(text);
toCpy = text;
@@ -2467,7 +2467,7 @@ u32 BattleStringExpandPlaceholders(const u8 *src, u8 *dst)
}
else
{
if (gLinkPlayers[gBattleScripting.multiplayerId].lp_field_18 == gPotentialItemEffectBattler)
if (gLinkPlayers[gBattleScripting.multiplayerId].id == gPotentialItemEffectBattler)
{
StringCopy(text, gEnigmaBerries[gPotentialItemEffectBattler].name);
StringAppend(text, sText_BerrySuffix);
@@ -2562,13 +2562,13 @@ u32 BattleStringExpandPlaceholders(const u8 *src, u8 *dst)
toCpy = gLinkPlayers[multiplayerID].name;
break;
case B_TXT_1F: // link partner name?
toCpy = gLinkPlayers[GetBattlerMultiplayerId(2 ^ gLinkPlayers[multiplayerID].lp_field_18)].name;
toCpy = gLinkPlayers[GetBattlerMultiplayerId(2 ^ gLinkPlayers[multiplayerID].id)].name;
break;
case B_TXT_20: // link opponent 1 name?
toCpy = gLinkPlayers[GetBattlerMultiplayerId(1 ^ gLinkPlayers[multiplayerID].lp_field_18)].name;
toCpy = gLinkPlayers[GetBattlerMultiplayerId(1 ^ gLinkPlayers[multiplayerID].id)].name;
break;
case B_TXT_21: // link opponent 2 name?
toCpy = gLinkPlayers[GetBattlerMultiplayerId(3 ^ gLinkPlayers[multiplayerID].lp_field_18)].name;
toCpy = gLinkPlayers[GetBattlerMultiplayerId(3 ^ gLinkPlayers[multiplayerID].id)].name;
break;
case B_TXT_22: // link scripting active name
toCpy = gLinkPlayers[GetBattlerMultiplayerId(gBattleScripting.battler)].name;
@@ -2832,7 +2832,7 @@ static void ExpandBattleTextBuffPlaceholders(const u8 *src, u8 *dst)
{
if (hword == ITEM_ENIGMA_BERRY)
{
if (gLinkPlayers[gBattleScripting.multiplayerId].lp_field_18 == gPotentialItemEffectBattler)
if (gLinkPlayers[gBattleScripting.multiplayerId].id == gPotentialItemEffectBattler)
{
StringCopy(dst, gEnigmaBerries[gPotentialItemEffectBattler].name);
StringAppend(dst, sText_BerrySuffix);
+1 -1
View File
@@ -356,7 +356,7 @@ static void Task_ExitTrainerHillRecords(u8 taskId)
{
if (!gPaletteFade.active)
{
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
Free(sTilemapBuffer);
RemoveTrainerHillRecordsWindow(0);
FreeAllWindowBuffers();
+13 -13
View File
@@ -1120,9 +1120,9 @@ static void atk01_accuracycheck(void)
{
u16 move = T2_READ_16(gBattlescriptCurrInstr + 5);
if (move == 0xFFFE || move == 0xFFFF)
if (move == NO_ACC_CALC || move == NO_ACC_CALC_CHECK_LOCK_ON)
{
if (gStatuses3[gBattlerTarget] & STATUS3_ALWAYS_HITS && move == 0xFFFF && gDisableStructs[gBattlerTarget].battlerWithSureHit == gBattlerAttacker)
if (gStatuses3[gBattlerTarget] & STATUS3_ALWAYS_HITS && move == NO_ACC_CALC_CHECK_LOCK_ON && gDisableStructs[gBattlerTarget].battlerWithSureHit == gBattlerAttacker)
gBattlescriptCurrInstr += 7;
else if (gStatuses3[gBattlerTarget] & (STATUS3_ON_AIR | STATUS3_UNDERGROUND | STATUS3_UNDERWATER))
gBattlescriptCurrInstr = T1_READ_PTR(gBattlescriptCurrInstr + 1);
@@ -4378,22 +4378,22 @@ static void atk46_playanimation2(void) // animation Id is stored in the first po
static void atk47_setgraphicalstatchangevalues(void)
{
u8 value = 0;
switch (gBattleScripting.statChanger & 0xF0)
switch (GET_STAT_BUFF_VALUE2(gBattleScripting.statChanger))
{
case 0x10: // +1
case SET_STAT_BUFF_VALUE(1): // +1
value = 0xF;
break;
case 0x20: // +2
case SET_STAT_BUFF_VALUE(2): // +2
value = 0x27;
break;
case 0x90: // -1
case SET_STAT_BUFF_VALUE(1) | STAT_BUFF_NEGATIVE: // -1
value = 0x16;
break;
case 0xA0: // -2
case SET_STAT_BUFF_VALUE(2) | STAT_BUFF_NEGATIVE: // -2
value = 0x2E;
break;
}
gBattleScripting.animArg1 = (gBattleScripting.statChanger & 0xF) + value - 1;
gBattleScripting.animArg1 = GET_STAT_BUFF_ID(gBattleScripting.statChanger) + value - 1;
gBattleScripting.animArg2 = 0;
gBattlescriptCurrInstr++;
}
@@ -4479,16 +4479,16 @@ static void atk48_playstatchangeanimation(void)
}
}
if (gBattlescriptCurrInstr[3] & ATK48_BIT_x4 && changeableStatsCount < 2)
if (gBattlescriptCurrInstr[3] & ATK48_ONLY_MULTIPLE && changeableStatsCount < 2)
{
gBattlescriptCurrInstr += 4;
}
else if (changeableStatsCount != 0 && gBattleScripting.field_1B == 0)
else if (changeableStatsCount != 0 && !gBattleScripting.statAnimPlayed)
{
BtlController_EmitBattleAnimation(0, B_ANIM_STATS_CHANGE, statAnimId);
MarkBattlerForControllerExec(gActiveBattler);
if (gBattlescriptCurrInstr[3] & ATK48_BIT_x4 && changeableStatsCount > 1)
gBattleScripting.field_1B = 1;
if (gBattlescriptCurrInstr[3] & ATK48_ONLY_MULTIPLE && changeableStatsCount > 1)
gBattleScripting.statAnimPlayed = TRUE;
gBattlescriptCurrInstr += 4;
}
else
@@ -7230,7 +7230,7 @@ static u8 ChangeStatBuffs(s8 statValue, u8 statId, u8 flags, const u8 *BS_ptr)
PREPARE_STAT_BUFFER(gBattleTextBuff1, statId)
if ((statValue << 0x18) < 0) // stat decrease
if (statValue <= -1) // Stat decrease.
{
if (gSideTimers[GET_BATTLER_SIDE(gActiveBattler)].mistTimer
&& !certain && gCurrentMove != MOVE_CURSE)
+10 -10
View File
@@ -467,7 +467,7 @@ void StartWallyTutorialBattle(void)
{
CreateMaleMon(&gEnemyParty[0], SPECIES_RALTS, 5);
ScriptContext2_Enable();
gMain.savedCallback = CB2_ReturnToFieldContinueScript;
gMain.savedCallback = CB2_ReturnToFieldContinueScriptPlayMapMusic;
gBattleTypeFlags = BATTLE_TYPE_WALLY_TUTORIAL;
CreateBattleStartTask(B_TRANSITION_SLICE, 0);
}
@@ -609,13 +609,13 @@ static void CB2_EndScriptedWildBattle(void)
if (IsPlayerDefeated(gBattleOutcome) == TRUE)
{
if (InBattlePyramid())
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
else
SetMainCallback2(CB2_WhiteOut);
}
else
{
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
}
}
@@ -900,7 +900,7 @@ static void CB2_GiveStarter(void)
{
u16 starterMon;
*GetVarPointer(VAR_FIRST_POKE) = gSpecialVar_Result;
*GetVarPointer(VAR_STARTER_MON) = gSpecialVar_Result;
starterMon = GetStarterPokemon(gSpecialVar_Result);
ScriptGiveMon(starterMon, 5, 0, 0, 0, 0);
ResetTasks();
@@ -932,7 +932,7 @@ static void CB2_StartFirstBattle(void)
static void CB2_EndFirstBattle(void)
{
Overworld_ClearSavedMusic();
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
}
static void sub_80B1218(void)
@@ -1308,18 +1308,18 @@ static void CB2_EndTrainerBattle(void)
{
if (gTrainerBattleOpponent_A == TRAINER_SECRET_BASE)
{
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
}
else if (IsPlayerDefeated(gBattleOutcome) == TRUE)
{
if (InBattlePyramid() || sub_81D5C18())
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
else
SetMainCallback2(CB2_WhiteOut);
}
else
{
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
if (!InBattlePyramid() && !sub_81D5C18())
{
RegisterTrainerInMatchCall();
@@ -1332,7 +1332,7 @@ static void CB2_EndRematchBattle(void)
{
if (gTrainerBattleOpponent_A == TRAINER_SECRET_BASE)
{
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
}
else if (IsPlayerDefeated(gBattleOutcome) == TRUE)
{
@@ -1340,7 +1340,7 @@ static void CB2_EndRematchBattle(void)
}
else
{
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
RegisterTrainerInMatchCall();
SetBattledTrainersFlags();
HandleRematchVarsOnBattleEnd();
+108 -54
View File
@@ -426,7 +426,7 @@ u8 CheckMoveLimitations(u8 battlerId, u8 unusableMoves, u8 check)
gPotentialItemEffectBattler = battlerId;
for (i = 0; i < MAX_BATTLERS_COUNT; i++)
for (i = 0; i < 4; i++)
{
if (gBattleMons[battlerId].moves[i] == 0 && check & MOVE_LIMITATION_ZEROMOVE)
unusableMoves |= gBitTable[i];
@@ -490,7 +490,22 @@ u8 GetImprisonedMovesCount(u8 battlerId, u16 move)
return imprisionedMoves;
}
u8 UpdateTurnCounters(void)
enum
{
ENDTURN_ORDER,
ENDTURN_REFLECT,
ENDTURN_LIGHT_SCREEN,
ENDTURN_MIST,
ENDTURN_SAFEGUARD,
ENDTURN_WISH,
ENDTURN_RAIN,
ENDTURN_SANDSTORM,
ENDTURN_SUN,
ENDTURN_HAIL,
ENDTURN_FIELD_COUNT,
};
u8 DoFieldEndTurnEffects(void)
{
u8 effect = 0;
s32 i;
@@ -508,7 +523,7 @@ u8 UpdateTurnCounters(void)
switch (gBattleStruct->turnCountersTracker)
{
case 0:
case ENDTURN_ORDER:
for (i = 0; i < gBattlersCount; i++)
{
gBattlerByTurnOrder[i] = i;
@@ -530,7 +545,7 @@ u8 UpdateTurnCounters(void)
gBattleStruct->turnSideTracker = 0;
}
// fall through
case 1:
case ENDTURN_REFLECT:
while (gBattleStruct->turnSideTracker < 2)
{
side = gBattleStruct->turnSideTracker;
@@ -555,7 +570,7 @@ u8 UpdateTurnCounters(void)
gBattleStruct->turnSideTracker = 0;
}
break;
case 2:
case ENDTURN_LIGHT_SCREEN:
while (gBattleStruct->turnSideTracker < 2)
{
side = gBattleStruct->turnSideTracker;
@@ -581,7 +596,7 @@ u8 UpdateTurnCounters(void)
gBattleStruct->turnSideTracker = 0;
}
break;
case 3:
case ENDTURN_MIST:
while (gBattleStruct->turnSideTracker < 2)
{
side = gBattleStruct->turnSideTracker;
@@ -605,7 +620,7 @@ u8 UpdateTurnCounters(void)
gBattleStruct->turnSideTracker = 0;
}
break;
case 4:
case ENDTURN_SAFEGUARD:
while (gBattleStruct->turnSideTracker < 2)
{
side = gBattleStruct->turnSideTracker;
@@ -629,7 +644,7 @@ u8 UpdateTurnCounters(void)
gBattleStruct->turnSideTracker = 0;
}
break;
case 5:
case ENDTURN_WISH:
while (gBattleStruct->turnSideTracker < gBattlersCount)
{
gActiveBattler = gBattlerByTurnOrder[gBattleStruct->turnSideTracker];
@@ -650,7 +665,7 @@ u8 UpdateTurnCounters(void)
gBattleStruct->turnCountersTracker++;
}
break;
case 6:
case ENDTURN_RAIN:
if (gBattleWeather & WEATHER_RAIN_ANY)
{
if (!(gBattleWeather & WEATHER_RAIN_PERMANENT))
@@ -680,7 +695,7 @@ u8 UpdateTurnCounters(void)
}
gBattleStruct->turnCountersTracker++;
break;
case 7:
case ENDTURN_SANDSTORM:
if (gBattleWeather & WEATHER_SANDSTORM_ANY)
{
if (!(gBattleWeather & WEATHER_SANDSTORM_PERMANENT) && --gWishFutureKnock.weatherDuration == 0)
@@ -700,7 +715,7 @@ u8 UpdateTurnCounters(void)
}
gBattleStruct->turnCountersTracker++;
break;
case 8:
case ENDTURN_SUN:
if (gBattleWeather & WEATHER_SUN_ANY)
{
if (!(gBattleWeather & WEATHER_SUN_PERMANENT) && --gWishFutureKnock.weatherDuration == 0)
@@ -718,8 +733,8 @@ u8 UpdateTurnCounters(void)
}
gBattleStruct->turnCountersTracker++;
break;
case 9:
if (gBattleWeather & WEATHER_HAIL)
case ENDTURN_HAIL:
if (gBattleWeather & WEATHER_HAIL_ANY)
{
if (--gWishFutureKnock.weatherDuration == 0)
{
@@ -738,7 +753,7 @@ u8 UpdateTurnCounters(void)
}
gBattleStruct->turnCountersTracker++;
break;
case 10:
case ENDTURN_FIELD_COUNT:
effect++;
break;
}
@@ -746,14 +761,36 @@ u8 UpdateTurnCounters(void)
return (gBattleMainFunc != BattleTurnPassed);
}
#define TURNBASED_MAX_CASE 19
enum
{
ENDTURN_INGRAIN,
ENDTURN_ABILITIES,
ENDTURN_ITEMS1,
ENDTURN_LEECH_SEED,
ENDTURN_POISON,
ENDTURN_BAD_POISON,
ENDTURN_BURN,
ENDTURN_NIGHTMARES,
ENDTURN_CURSE,
ENDTURN_WRAP,
ENDTURN_UPROAR,
ENDTURN_THRASH,
ENDTURN_DISABLE,
ENDTURN_ENCORE,
ENDTURN_LOCK_ON,
ENDTURN_CHARGE,
ENDTURN_TAUNT,
ENDTURN_YAWN,
ENDTURN_ITEMS2,
ENDTURN_BATTLER_COUNT
};
u8 TurnBasedEffects(void)
u8 DoBattlerEndTurnEffects(void)
{
u8 effect = 0;
gHitMarker |= (HITMARKER_GRUDGE | HITMARKER_x20);
while (gBattleStruct->turnEffectsBattlerId < gBattlersCount && gBattleStruct->turnEffectsTracker <= TURNBASED_MAX_CASE)
while (gBattleStruct->turnEffectsBattlerId < gBattlersCount && gBattleStruct->turnEffectsTracker <= ENDTURN_BATTLER_COUNT)
{
gActiveBattler = gBattlerAttacker = gBattlerByTurnOrder[gBattleStruct->turnEffectsBattlerId];
if (gAbsentBattlerFlags & gBitTable[gActiveBattler])
@@ -764,7 +801,7 @@ u8 TurnBasedEffects(void)
{
switch (gBattleStruct->turnEffectsTracker)
{
case 0: // ingrain
case ENDTURN_INGRAIN: // ingrain
if ((gStatuses3[gActiveBattler] & STATUS3_ROOTED)
&& gBattleMons[gActiveBattler].hp != gBattleMons[gActiveBattler].maxHP
&& gBattleMons[gActiveBattler].hp != 0)
@@ -778,22 +815,22 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 1: // end turn abilities
case ENDTURN_ABILITIES: // end turn abilities
if (AbilityBattleEffects(ABILITYEFFECT_ENDTURN, gActiveBattler, 0, 0, 0))
effect++;
gBattleStruct->turnEffectsTracker++;
break;
case 2: // item effects
case ENDTURN_ITEMS1: // item effects
if (ItemBattleEffects(1, gActiveBattler, 0))
effect++;
gBattleStruct->turnEffectsTracker++;
break;
case 18: // item effects again
case ENDTURN_ITEMS2: // item effects again
if (ItemBattleEffects(1, gActiveBattler, 1))
effect++;
gBattleStruct->turnEffectsTracker++;
break;
case 3: // leech seed
case ENDTURN_LEECH_SEED: // leech seed
if ((gStatuses3[gActiveBattler] & STATUS3_LEECHSEED)
&& gBattleMons[gStatuses3[gActiveBattler] & STATUS3_LEECHSEED_BATTLER].hp != 0
&& gBattleMons[gActiveBattler].hp != 0)
@@ -809,7 +846,7 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 4: // poison
case ENDTURN_POISON: // poison
if ((gBattleMons[gActiveBattler].status1 & STATUS1_POISON) && gBattleMons[gActiveBattler].hp != 0)
{
gBattleMoveDamage = gBattleMons[gActiveBattler].maxHP / 8;
@@ -820,7 +857,7 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 5: // toxic poison
case ENDTURN_BAD_POISON: // toxic poison
if ((gBattleMons[gActiveBattler].status1 & STATUS1_TOXIC_POISON) && gBattleMons[gActiveBattler].hp != 0)
{
gBattleMoveDamage = gBattleMons[gActiveBattler].maxHP / 16;
@@ -834,7 +871,7 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 6: // burn
case ENDTURN_BURN: // burn
if ((gBattleMons[gActiveBattler].status1 & STATUS1_BURN) && gBattleMons[gActiveBattler].hp != 0)
{
gBattleMoveDamage = gBattleMons[gActiveBattler].maxHP / 8;
@@ -845,7 +882,7 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 7: // spooky nightmares
case ENDTURN_NIGHTMARES: // spooky nightmares
if ((gBattleMons[gActiveBattler].status2 & STATUS2_NIGHTMARE) && gBattleMons[gActiveBattler].hp != 0)
{
// R/S does not perform this sleep check, which causes the nightmare effect to
@@ -865,7 +902,7 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 8: // curse
case ENDTURN_CURSE: // curse
if ((gBattleMons[gActiveBattler].status2 & STATUS2_CURSED) && gBattleMons[gActiveBattler].hp != 0)
{
gBattleMoveDamage = gBattleMons[gActiveBattler].maxHP / 4;
@@ -876,7 +913,7 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 9: // wrap
case ENDTURN_WRAP: // wrap
if ((gBattleMons[gActiveBattler].status2 & STATUS2_WRAPPED) && gBattleMons[gActiveBattler].hp != 0)
{
gBattleMons[gActiveBattler].status2 -= 0x2000;
@@ -909,7 +946,7 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 10: // uproar
case ENDTURN_UPROAR: // uproar
if (gBattleMons[gActiveBattler].status2 & STATUS2_UPROAR)
{
for (gBattlerAttacker = 0; gBattlerAttacker < gBattlersCount; gBattlerAttacker++)
@@ -958,7 +995,7 @@ u8 TurnBasedEffects(void)
if (effect != 2)
gBattleStruct->turnEffectsTracker++;
break;
case 11: // thrash
case ENDTURN_THRASH: // thrash
if (gBattleMons[gActiveBattler].status2 & STATUS2_LOCK_CONFUSE)
{
gBattleMons[gActiveBattler].status2 -= 0x400;
@@ -980,7 +1017,7 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 12: // disable
case ENDTURN_DISABLE: // disable
if (gDisableStructs[gActiveBattler].disableTimer1 != 0)
{
s32 i;
@@ -1003,7 +1040,7 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 13: // encore
case ENDTURN_ENCORE: // encore
if (gDisableStructs[gActiveBattler].encoreTimer1 != 0)
{
if (gBattleMons[gActiveBattler].moves[gDisableStructs[gActiveBattler].encoredMovePos] != gDisableStructs[gActiveBattler].encoredMove) // pokemon does not have the encored move anymore
@@ -1022,22 +1059,22 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 14: // lock-on decrement
case ENDTURN_LOCK_ON: // lock-on decrement
if (gStatuses3[gActiveBattler] & STATUS3_ALWAYS_HITS)
gStatuses3[gActiveBattler] -= 0x8;
gBattleStruct->turnEffectsTracker++;
break;
case 15: // charge
case ENDTURN_CHARGE: // charge
if (gDisableStructs[gActiveBattler].chargeTimer1 && --gDisableStructs[gActiveBattler].chargeTimer1 == 0)
gStatuses3[gActiveBattler] &= ~STATUS3_CHARGED_UP;
gBattleStruct->turnEffectsTracker++;
break;
case 16: // taunt
case ENDTURN_TAUNT: // taunt
if (gDisableStructs[gActiveBattler].tauntTimer1)
gDisableStructs[gActiveBattler].tauntTimer1--;
gBattleStruct->turnEffectsTracker++;
break;
case 17: // yawn
case ENDTURN_YAWN: // yawn
if (gStatuses3[gActiveBattler] & STATUS3_YAWN)
{
gStatuses3[gActiveBattler] -= 0x800;
@@ -1056,7 +1093,7 @@ u8 TurnBasedEffects(void)
}
gBattleStruct->turnEffectsTracker++;
break;
case 19: // done
case ENDTURN_BATTLER_COUNT: // done
gBattleStruct->turnEffectsTracker = 0;
gBattleStruct->turnEffectsBattlerId++;
break;
@@ -1264,7 +1301,24 @@ void TryClearRageStatuses(void)
}
}
#define ATKCANCELLER_MAX_CASE 14
enum
{
CANCELLER_FLAGS,
CANCELLER_ASLEEP,
CANCELLER_FROZEN,
CANCELLER_TRUANT,
CANCELLER_RECHARGE,
CANCELLER_FLINCH,
CANCELLER_DISABLED,
CANCELLER_TAUNTED,
CANCELLER_IMPRISONED,
CANCELLER_CONFUSED,
CANCELLER_PARALYSED,
CANCELLER_IN_LOVE,
CANCELLER_BIDE,
CANCELLER_THAW,
CANCELLER_END,
};
u8 AtkCanceller_UnableToUseMove(void)
{
@@ -1274,12 +1328,12 @@ u8 AtkCanceller_UnableToUseMove(void)
{
switch (gBattleStruct->atkCancellerTracker)
{
case 0: // flags clear
case CANCELLER_FLAGS: // flags clear
gBattleMons[gBattlerAttacker].status2 &= ~(STATUS2_DESTINY_BOND);
gStatuses3[gBattlerAttacker] &= ~(STATUS3_GRUDGE);
gBattleStruct->atkCancellerTracker++;
break;
case 1: // check being asleep
case CANCELLER_ASLEEP: // check being asleep
if (gBattleMons[gBattlerAttacker].status1 & STATUS1_SLEEP)
{
if (UproarWakeUpCheck(gBattlerAttacker))
@@ -1323,7 +1377,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 2: // check being frozen
case CANCELLER_FROZEN: // check being frozen
if (gBattleMons[gBattlerAttacker].status1 & STATUS1_FREEZE)
{
if (Random() % 5)
@@ -1350,7 +1404,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 3: // truant
case CANCELLER_TRUANT: // truant
if (gBattleMons[gBattlerAttacker].ability == ABILITY_TRUANT && gDisableStructs[gBattlerAttacker].truantCounter)
{
CancelMultiTurnMoves(gBattlerAttacker);
@@ -1362,7 +1416,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 4: // recharge
case CANCELLER_RECHARGE: // recharge
if (gBattleMons[gBattlerAttacker].status2 & STATUS2_RECHARGE)
{
gBattleMons[gBattlerAttacker].status2 &= ~(STATUS2_RECHARGE);
@@ -1374,7 +1428,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 5: // flinch
case CANCELLER_FLINCH: // flinch
if (gBattleMons[gBattlerAttacker].status2 & STATUS2_FLINCHED)
{
gBattleMons[gBattlerAttacker].status2 &= ~(STATUS2_FLINCHED);
@@ -1386,7 +1440,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 6: // disabled move
case CANCELLER_DISABLED: // disabled move
if (gDisableStructs[gBattlerAttacker].disabledMove == gCurrentMove && gDisableStructs[gBattlerAttacker].disabledMove != 0)
{
gProtectStructs[gBattlerAttacker].usedDisabledMove = 1;
@@ -1398,7 +1452,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 7: // taunt
case CANCELLER_TAUNTED: // taunt
if (gDisableStructs[gBattlerAttacker].tauntTimer1 && gBattleMoves[gCurrentMove].power == 0)
{
gProtectStructs[gBattlerAttacker].usedTauntedMove = 1;
@@ -1409,7 +1463,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 8: // imprisoned
case CANCELLER_IMPRISONED: // imprisoned
if (GetImprisonedMovesCount(gBattlerAttacker, gCurrentMove))
{
gProtectStructs[gBattlerAttacker].usedImprisionedMove = 1;
@@ -1420,7 +1474,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 9: // confusion
case CANCELLER_CONFUSED: // confusion
if (gBattleMons[gBattlerAttacker].status2 & STATUS2_CONFUSION)
{
gBattleMons[gBattlerAttacker].status2--;
@@ -1450,7 +1504,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 10: // paralysis
case CANCELLER_PARALYSED: // paralysis
if ((gBattleMons[gBattlerAttacker].status1 & STATUS1_PARALYSIS) && (Random() % 4) == 0)
{
gProtectStructs[gBattlerAttacker].prlzImmobility = 1;
@@ -1462,7 +1516,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 11: // infatuation
case CANCELLER_IN_LOVE: // infatuation
if (gBattleMons[gBattlerAttacker].status2 & STATUS2_INFATUATION)
{
gBattleScripting.battler = CountTrailingZeroBits((gBattleMons[gBattlerAttacker].status2 & STATUS2_INFATUATION) >> 0x10);
@@ -1482,7 +1536,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 12: // bide
case CANCELLER_BIDE: // bide
if (gBattleMons[gBattlerAttacker].status2 & STATUS2_BIDE)
{
gBattleMons[gBattlerAttacker].status2 -= 0x100;
@@ -1512,7 +1566,7 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case 13: // move thawing
case CANCELLER_THAW: // move thawing
if (gBattleMons[gBattlerAttacker].status1 & STATUS1_FREEZE)
{
if (gBattleMoves[gCurrentMove].effect == EFFECT_THAW_HIT)
@@ -1526,11 +1580,11 @@ u8 AtkCanceller_UnableToUseMove(void)
}
gBattleStruct->atkCancellerTracker++;
break;
case ATKCANCELLER_MAX_CASE:
case CANCELLER_END:
break;
}
} while (gBattleStruct->atkCancellerTracker != ATKCANCELLER_MAX_CASE && effect == 0);
} while (gBattleStruct->atkCancellerTracker != CANCELLER_END && effect == 0);
if (effect == 2)
{
+2 -2
View File
@@ -2687,7 +2687,7 @@ static void CB2_HandlePlayerLinkPlayAgainChoice(void)
if (gReceivedRemoteLinkPlayers == 0)
{
FREE_AND_SET_NULL(sBerryBlenderData);
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
}
break;
}
@@ -2737,7 +2737,7 @@ static void CB2_HandlePlayerPlayAgainChoice(void)
if (sBerryBlenderData->playAgainState == PLAY_AGAIN_OK)
SetMainCallback2(DoBerryBlending);
else
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
FreeAllWindowBuffers();
UnsetBgTilemapBuffer(2);
+2 -2
View File
@@ -83,11 +83,11 @@ static void UpdatePerMinute(struct Time *localTime)
static void ReturnFromStartWallClock(void)
{
InitTimeBasedEvents();
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
}
void StartWallClock(void)
{
SetMainCallback2(Cb2_StartWallClock);
SetMainCallback2(CB2_StartWallClock);
gMain.savedCallback = ReturnFromStartWallClock;
}
+1 -1
View File
@@ -2285,7 +2285,7 @@ static void sub_81772B8(struct Sprite *sprite)
static void sub_8177388(void)
{
u16 starter = SpeciesToNationalPokedexNum(GetStarterPokemon(VarGet(VAR_FIRST_POKE)));
u16 starter = SpeciesToNationalPokedexNum(GetStarterPokemon(VarGet(VAR_STARTER_MON)));
u16 page;
u16 dexNum;
u16 j;
+25
View File
@@ -0,0 +1,25 @@
static const struct HealLocation sHealLocations[] =
{
{MAP_GROUP(LITTLEROOT_TOWN_BRENDANS_HOUSE_2F), MAP_NUM(LITTLEROOT_TOWN_BRENDANS_HOUSE_2F), 4, 2},
{MAP_GROUP(LITTLEROOT_TOWN_MAYS_HOUSE_2F), MAP_NUM(LITTLEROOT_TOWN_MAYS_HOUSE_2F), 4, 2},
{MAP_GROUP(PETALBURG_CITY), MAP_NUM(PETALBURG_CITY), 20, 17},
{MAP_GROUP(SLATEPORT_CITY), MAP_NUM(SLATEPORT_CITY), 19, 20},
{MAP_GROUP(MAUVILLE_CITY), MAP_NUM(MAUVILLE_CITY), 22, 6},
{MAP_GROUP(RUSTBORO_CITY), MAP_NUM(RUSTBORO_CITY), 16, 39},
{MAP_GROUP(FORTREE_CITY), MAP_NUM(FORTREE_CITY), 5, 7},
{MAP_GROUP(LILYCOVE_CITY), MAP_NUM(LILYCOVE_CITY), 24, 15},
{MAP_GROUP(MOSSDEEP_CITY), MAP_NUM(MOSSDEEP_CITY), 28, 17},
{MAP_GROUP(SOOTOPOLIS_CITY), MAP_NUM(SOOTOPOLIS_CITY), 43, 32},
{MAP_GROUP(EVER_GRANDE_CITY), MAP_NUM(EVER_GRANDE_CITY), 27, 49},
{MAP_GROUP(LITTLEROOT_TOWN), MAP_NUM(LITTLEROOT_TOWN), 5, 9},
{MAP_GROUP(LITTLEROOT_TOWN), MAP_NUM(LITTLEROOT_TOWN), 14, 9},
{MAP_GROUP(OLDALE_TOWN), MAP_NUM(OLDALE_TOWN), 6, 17},
{MAP_GROUP(DEWFORD_TOWN), MAP_NUM(DEWFORD_TOWN), 2, 11},
{MAP_GROUP(LAVARIDGE_TOWN), MAP_NUM(LAVARIDGE_TOWN), 9, 7},
{MAP_GROUP(FALLARBOR_TOWN), MAP_NUM(FALLARBOR_TOWN), 14, 8},
{MAP_GROUP(VERDANTURF_TOWN), MAP_NUM(VERDANTURF_TOWN), 16, 4},
{MAP_GROUP(PACIFIDLOG_TOWN), MAP_NUM(PACIFIDLOG_TOWN), 8, 16},
{MAP_GROUP(EVER_GRANDE_CITY), MAP_NUM(EVER_GRANDE_CITY), 18, 6},
{MAP_GROUP(SOUTHERN_ISLAND_EXTERIOR), MAP_NUM(SOUTHERN_ISLAND_EXTERIOR), 15, 20},
{MAP_GROUP(BATTLE_FRONTIER_OUTSIDE_EAST), MAP_NUM(BATTLE_FRONTIER_OUTSIDE_EAST), 3, 52},
};
+714
View File
@@ -0,0 +1,714 @@
static const u8 sNullMoveDescription[] = _("");
static const u8 sPoundMoveDescription[] = _("Pounds the foe with\nforelegs or tail.");
static const u8 sKarateChopMoveDescription[] = _("A chopping attack with a\nhigh critical-hit ratio.");
static const u8 sDoubleSlapMoveDescription[] = _("Repeatedly slaps the foe\n2 to 5 times.");
static const u8 sCometPunchMoveDescription[] = _("Repeatedly punches the foe\n2 to 5 times.");
static const u8 sMegaPunchMoveDescription[] = _("A strong punch thrown with\nincredible power.");
static const u8 sPayDayMoveDescription[] = _("Throws coins at the foe.\nMoney is recovered after.");
static const u8 sFirePunchMoveDescription[] = _("A fiery punch that may burn\nthe foe.");
static const u8 sIcePunchMoveDescription[] = _("An icy punch that may\nfreeze the foe.");
static const u8 sThunderPunchMoveDescription[] = _("An electrified punch that\nmay paralyze the foe.");
static const u8 sScratchMoveDescription[] = _("Scratches the foe with\nsharp claws.");
static const u8 sViceGripMoveDescription[] = _("Grips the foe with large and\npowerful pincers.");
static const u8 sGuillotineMoveDescription[] = _("A powerful pincer attack\nthat may cause fainting.");
static const u8 sRazorWindMoveDescription[] = _("A 2-turn move that strikes\nthe foe on the 2nd turn.");
static const u8 sSwordsDanceMoveDescription[] = _("A fighting dance that\nsharply raises ATTACK.");
static const u8 sCutMoveDescription[] = _("Cuts the foe with sharp\nscythes, claws, etc.");
static const u8 sGustMoveDescription[] = _("Strikes the foe with a gust\nof wind whipped up by wings.");
static const u8 sWingAttackMoveDescription[] = _("Strikes the foe with wings\nspread wide.");
static const u8 sWhirlwindMoveDescription[] = _("Blows away the foe with\nwind and ends the battle.");
static const u8 sFlyMoveDescription[] = _("Flies up on the first turn,\nthen strikes the next turn.");
static const u8 sBindMoveDescription[] = _("Binds and squeezes the foe\nfor 2 to 5 turns.");
static const u8 sSlamMoveDescription[] = _("Slams the foe with a long\ntail, vine, etc.");
static const u8 sVineWhipMoveDescription[] = _("Strikes the foe with\nslender, whiplike vines.");
static const u8 sStompMoveDescription[] = _("Stomps the enemy with a big\nfoot. May cause flinching.");
static const u8 sDoubleKickMoveDescription[] = _("A double-kicking attack\nthat strikes the foe twice.");
static const u8 sMegaKickMoveDescription[] = _("An extremely powerful kick\nwith intense force.");
static const u8 sJumpKickMoveDescription[] = _("A strong jumping kick. May\nmiss and hurt the kicker.");
static const u8 sRollingKickMoveDescription[] = _("A fast kick delivered from\na rapid spin.");
static const u8 sSandAttackMoveDescription[] = _("Reduces the foes accuracy\nby hurling sand in its face.");
static const u8 sHeadbuttMoveDescription[] = _("A ramming attack that may\ncause flinching.");
static const u8 sHornAttackMoveDescription[] = _("Jabs the foe with sharp\nhorns.");
static const u8 sFuryAttackMoveDescription[] = _("Jabs the foe 2 to 5 times\nwith sharp horns, etc.");
static const u8 sHornDrillMoveDescription[] = _("A one-hit KO attack that\nuses a horn like a drill.");
static const u8 sTackleMoveDescription[] = _("Charges the foe with a full-\nbody tackle.");
static const u8 sBodySlamMoveDescription[] = _("A full-body slam that may\ncause paralysis.");
static const u8 sWrapMoveDescription[] = _("Wraps and squeezes the foe\n2 to 5 times with vines, etc.");
static const u8 sTakeDownMoveDescription[] = _("A reckless charge attack\nthat also hurts the user.");
static const u8 sThrashMoveDescription[] = _("A rampage of 2 to 3 turns\nthat confuses the user.");
static const u8 sDoubleEdgeMoveDescription[] = _("A life-risking tackle that\nalso hurts the user.");
static const u8 sTailWhipMoveDescription[] = _("Wags the tail to lower the\nfoes DEFENSE.");
static const u8 sPoisonStingMoveDescription[] = _("A toxic attack with barbs,\netc., that may poison.");
static const u8 sTwineedleMoveDescription[] = _("Stingers on the forelegs\njab the foe twice.");
static const u8 sPinMissileMoveDescription[] = _("Sharp pins are fired to\nstrike 2 to 5 times.");
static const u8 sLeerMoveDescription[] = _("Frightens the foe with a\nleer to lower DEFENSE.");
static const u8 sBiteMoveDescription[] = _("Bites with vicious fangs.\nMay cause flinching.");
static const u8 sGrowlMoveDescription[] = _("Growls cutely to reduce the\nfoes ATTACK.");
static const u8 sRoarMoveDescription[] = _("Makes the foe flee to end\nthe battle.");
static const u8 sSingMoveDescription[] = _("A soothing song lulls the\nfoe into a deep slumber.");
static const u8 sSupersonicMoveDescription[] = _("Emits bizarre sound waves\nthat may confuse the foe.");
static const u8 sSonicBoomMoveDescription[] = _("Launches shock waves that\nalways inflict 20 HP damage.");
static const u8 sDisableMoveDescription[] = _("Psychically disables one of\nthe foes moves.");
static const u8 sAcidMoveDescription[] = _("Sprays a hide-melting acid.\nMay lower DEFENSE.");
static const u8 sEmberMoveDescription[] = _("A weak fire attack that may\ninflict a burn.");
static const u8 sFlamethrowerMoveDescription[] = _("A powerful fire attack that\nmay inflict a burn.");
static const u8 sMistMoveDescription[] = _("Creates a mist that stops\nreduction of abilities.");
static const u8 sWaterGunMoveDescription[] = _("Squirts water to attack\nthe foe.");
static const u8 sHydroPumpMoveDescription[] = _("Blasts water at high power\nto strike the foe.");
static const u8 sSurfMoveDescription[] = _("Creates a huge wave, then\ncrashes it down on the foe.");
static const u8 sIceBeamMoveDescription[] = _("Blasts the foe with an icy\nbeam that may freeze it.");
static const u8 sBlizzardMoveDescription[] = _("Hits the foe with an icy\nstorm that may freeze it.");
static const u8 sPsybeamMoveDescription[] = _("Fires a peculiar ray that\nmay confuse the foe.");
static const u8 sBubbleBeamMoveDescription[] = _("Forcefully sprays bubbles\nthat may lower SPEED.");
static const u8 sAuroraBeamMoveDescription[] = _("Fires a rainbow-colored\nbeam that may lower ATTACK.");
static const u8 sHyperBeamMoveDescription[] = _("Powerful, but leaves the\nuser immobile the next turn.");
static const u8 sPeckMoveDescription[] = _("Attacks the foe with a\njabbing beak, etc.");
static const u8 sDrillPeckMoveDescription[] = _("A corkscrewing attack with\nthe beak acting as a drill.");
static const u8 sSubmissionMoveDescription[] = _("A reckless body slam that\nalso hurts the user.");
static const u8 sLowKickMoveDescription[] = _("A kick that inflicts more\ndamage on heavier foes.");
static const u8 sCounterMoveDescription[] = _("Retaliates any physical hit\nwith double the power.");
static const u8 sSeismicTossMoveDescription[] = _("Inflicts damage identical\nto the users level.");
static const u8 sStrengthMoveDescription[] = _("Builds enormous power,\nthen slams the foe.");
static const u8 sAbsorbMoveDescription[] = _("An attack that absorbs\nhalf the damage inflicted.");
static const u8 sMegaDrainMoveDescription[] = _("An attack that absorbs\nhalf the damage inflicted.");
static const u8 sLeechSeedMoveDescription[] = _("Plants a seed on the foe to\nsteal HP on every turn.");
static const u8 sGrowthMoveDescription[] = _("Forces the body to grow\nand heightens SP. ATK.");
static const u8 sRazorLeafMoveDescription[] = _("Cuts the enemy with leaves.\nHigh critical-hit ratio.");
static const u8 sSolarBeamMoveDescription[] = _("Absorbs light in one turn,\nthen attacks next turn.");
static const u8 sPoisonPowderMoveDescription[] = _("Scatters a toxic powder\nthat may poison the foe.");
static const u8 sStunSporeMoveDescription[] = _("Scatters a powder that may\nparalyze the foe.");
static const u8 sSleepPowderMoveDescription[] = _("Scatters a powder that may\ncause the foe to sleep.");
static const u8 sPetalDanceMoveDescription[] = _("A rampage of 2 to 3 turns\nthat confuses the user.");
static const u8 sStringShotMoveDescription[] = _("Binds the foe with string\nto reduce its SPEED.");
static const u8 sDragonRageMoveDescription[] = _("Launches shock waves that\nalways inflict 40 HP damage.");
static const u8 sFireSpinMoveDescription[] = _("Traps the foe in a ring of\nfire for 2 to 5 turns.");
static const u8 sThunderShockMoveDescription[] = _("An electrical attack that\nmay paralyze the foe.");
static const u8 sThunderboltMoveDescription[] = _("A strong electrical attack\nthat may paralyze the foe.");
static const u8 sThunderWaveMoveDescription[] = _("A weak jolt of electricity\nthat paralyzes the foe.");
static const u8 sThunderMoveDescription[] = _("A lightning attack that may\ncause paralysis.");
static const u8 sRockThrowMoveDescription[] = _("Throws small rocks to\nstrike the foe.");
static const u8 sEarthquakeMoveDescription[] = _("A powerful quake, but has\nno effect on flying foes.");
static const u8 sFissureMoveDescription[] = _("A one-hit KO move that\ndrops the foe in a fissure.");
static const u8 sDigMoveDescription[] = _("Digs underground the first\nturn and strikes next turn.");
static const u8 sToxicMoveDescription[] = _("Poisons the foe with an\nintensifying toxin.");
static const u8 sConfusionMoveDescription[] = _("A psychic attack that may\ncause confusion.");
static const u8 sPsychicMoveDescription[] = _("A powerful psychic attack\nthat may lower SP. DEF.");
static const u8 sHypnosisMoveDescription[] = _("A hypnotizing move that\nmay induce sleep.");
static const u8 sMeditateMoveDescription[] = _("Meditates in a peaceful\nfashion to raise ATTACK.");
static const u8 sAgilityMoveDescription[] = _("Relaxes the body to sharply\nboost SPEED.");
static const u8 sQuickAttackMoveDescription[] = _("An extremely fast attack\nthat always strikes first.");
static const u8 sRageMoveDescription[] = _("Raises the users ATTACK\nevery time it is hit.");
static const u8 sTeleportMoveDescription[] = _("A psychic move for fleeing\nfrom battle instantly.");
static const u8 sNightShadeMoveDescription[] = _("Inflicts damage identical\nto the users level.");
static const u8 sMimicMoveDescription[] = _("Copies a move used by the\nfoe during one battle.");
static const u8 sScreechMoveDescription[] = _("Emits a screech to sharply\nreduce the foes DEFENSE.");
static const u8 sDoubleTeamMoveDescription[] = _("Creates illusory copies to\nraise evasiveness.");
static const u8 sRecoverMoveDescription[] = _("Recovers up to half the\nusers maximum HP.");
static const u8 sHardenMoveDescription[] = _("Stiffens the bodys \nmuscles to raise DEFENSE.");
static const u8 sMinimizeMoveDescription[] = _("Minimizes the users size\nto raise evasiveness.");
static const u8 sSmokescreenMoveDescription[] = _("Lowers the foes accuracy\nusing smoke, ink, etc.");
static const u8 sConfuseRayMoveDescription[] = _("A sinister ray that\nconfuses the foe.");
static const u8 sWithdrawMoveDescription[] = _("Withdraws the body into its\nhard shell to raise DEFENSE.");
static const u8 sDefenseCurlMoveDescription[] = _("Curls up to conceal weak\nspots and raise DEFENSE.");
static const u8 sBarrierMoveDescription[] = _("Creates a barrier that\nsharply raises DEFENSE.");
static const u8 sLightScreenMoveDescription[] = _("Creates a wall of light that\nlowers SP. ATK damage.");
static const u8 sHazeMoveDescription[] = _("Creates a black haze that\neliminates all stat changes.");
static const u8 sReflectMoveDescription[] = _("Creates a wall of light that\nweakens physical attacks.");
static const u8 sFocusEnergyMoveDescription[] = _("Focuses power to raise the\ncritical-hit ratio.");
static const u8 sBideMoveDescription[] = _("Endures attack for 2\nturns to retaliate double.");
static const u8 sMetronomeMoveDescription[] = _("Waggles a finger to use any\nPOKéMON move at random.");
static const u8 sMirrorMoveMoveDescription[] = _("Counters the foes attack\nwith the same move.");
static const u8 sSelfDestructMoveDescription[] = _("Inflicts severe damage but\nmakes the user faint.");
static const u8 sEggBombMoveDescription[] = _("An egg is forcibly hurled at\nthe foe.");
static const u8 sLickMoveDescription[] = _("Licks with a long tongue to\ninjure. May also paralyze.");
static const u8 sSmogMoveDescription[] = _("An exhaust-gas attack\nthat may also poison.");
static const u8 sSludgeMoveDescription[] = _("Sludge is hurled to inflict\ndamage. May also poison.");
static const u8 sBoneClubMoveDescription[] = _("Clubs the foe with a bone.\nMay cause flinching.");
static const u8 sFireBlastMoveDescription[] = _("Incinerates everything it\nstrikes. May cause a burn.");
static const u8 sWaterfallMoveDescription[] = _("Charges the foe with speed\nto climb waterfalls.");
static const u8 sClampMoveDescription[] = _("Traps and squeezes the\nfoe for 2 to 5 turns.");
static const u8 sSwiftMoveDescription[] = _("Sprays star-shaped rays\nthat never miss.");
static const u8 sSkullBashMoveDescription[] = _("Tucks in the head, then\nattacks on the next turn.");
static const u8 sSpikeCannonMoveDescription[] = _("Launches sharp spikes that\nstrike 2 to 5 times.");
static const u8 sConstrictMoveDescription[] = _("Constricts to inflict pain.\nMay lower SPEED.");
static const u8 sAmnesiaMoveDescription[] = _("Forgets about something\nand sharply raises SP. DEF.");
static const u8 sKinesisMoveDescription[] = _("Distracts the foe.\nMay lower accuracy.");
static const u8 sSoftBoiledMoveDescription[] = _("Recovers up to half the\nusers maximum HP.");
static const u8 sHiJumpKickMoveDescription[] = _("A jumping knee kick. If it\nmisses, the user is hurt.");
static const u8 sGlareMoveDescription[] = _("Intimidates and frightens\nthe foe into paralysis.");
static const u8 sDreamEaterMoveDescription[] = _("Takes one half the damage\ninflicted on a sleeping foe.");
static const u8 sPoisonGasMoveDescription[] = _("Envelops the foe in a toxic\ngas that may poison.");
static const u8 sBarrageMoveDescription[] = _("Hurls round objects at the\nfoe 2 to 5 times.");
static const u8 sLeechLifeMoveDescription[] = _("An attack that steals half\nthe damage inflicted.");
static const u8 sLovelyKissMoveDescription[] = _("Demands a kiss with a scary\nface that induces sleep.");
static const u8 sSkyAttackMoveDescription[] = _("Searches out weak spots,\nthen strikes the next turn.");
static const u8 sTransformMoveDescription[] = _("Alters the users cells to\nbecome a copy of the foe.");
static const u8 sBubbleMoveDescription[] = _("An attack using bubbles.\nMay lower the foes SPEED.");
static const u8 sDizzyPunchMoveDescription[] = _("A rhythmic punch that may\nconfuse the foe.");
static const u8 sSporeMoveDescription[] = _("Scatters a cloud of spores\nthat always induce sleep.");
static const u8 sFlashMoveDescription[] = _("Looses a powerful blast of\nlight that cuts accuracy.");
static const u8 sPsywaveMoveDescription[] = _("Attacks with a psychic\nwave of varying intensity.");
static const u8 sSplashMoveDescription[] = _("Its just a splash...\nHas no effect whatsoever.");
static const u8 sAcidArmorMoveDescription[] = _("Liquifies the users body\nto sharply raise DEFENSE.");
static const u8 sCrabhammerMoveDescription[] = _("Hammers with a pincer. Has a\nhigh critical-hit ratio.");
static const u8 sExplosionMoveDescription[] = _("Inflicts severe damage but\nmakes the user faint.");
static const u8 sFurySwipesMoveDescription[] = _("Rakes the foe with sharp\nclaws, etc., 2 to 5 times.");
static const u8 sBonemerangMoveDescription[] = _("Throws a bone boomerang\nthat strikes twice.");
static const u8 sRestMoveDescription[] = _("The user sleeps for 2 turns,\nrestoring HP and status.");
static const u8 sRockSlideMoveDescription[] = _("Large boulders are hurled.\nMay cause flinching.");
static const u8 sHyperFangMoveDescription[] = _("Attacks with sharp fangs.\nMay cause flinching.");
static const u8 sSharpenMoveDescription[] = _("Reduces the polygon count\nand raises ATTACK.");
static const u8 sConversionMoveDescription[] = _("Changes the users type\ninto a known moves type.");
static const u8 sTriAttackMoveDescription[] = _("Fires three types of beams\nat the same time.");
static const u8 sSuperFangMoveDescription[] = _("Attacks with sharp fangs\nand cuts half the foes HP.");
static const u8 sSlashMoveDescription[] = _("Slashes with claws, etc. Has\na high critical-hit ratio.");
static const u8 sSubstituteMoveDescription[] = _("Creates a decoy using 1/4\nof the users maximum HP.");
static const u8 sStruggleMoveDescription[] = _("Used only if all PP are gone.\nAlso hurts the user a little.");
static const u8 sSketchMoveDescription[] = _("Copies the foes last move\npermanently.");
static const u8 sTripleKickMoveDescription[] = _("Kicks the foe 3 times in a\nrow with rising intensity.");
static const u8 sThiefMoveDescription[] = _("While attacking, it may\nsteal the foes held item.");
static const u8 sSpiderWebMoveDescription[] = _("Ensnares the foe to stop it\nfrom fleeing or switching.");
static const u8 sMindReaderMoveDescription[] = _("Senses the foes action to\nensure the next moves hit.");
static const u8 sNightmareMoveDescription[] = _("Inflicts 1/4 damage on a\nsleeping foe every turn.");
static const u8 sFlameWheelMoveDescription[] = _("A fiery charge attack that\nmay inflict a burn.");
static const u8 sSnoreMoveDescription[] = _("A loud attack that can be\nused only while asleep.");
static const u8 sCurseMoveDescription[] = _("A move that functions\ndifferently for GHOSTS.");
static const u8 sFlailMoveDescription[] = _("Inflicts more damage when\nthe users HP is down.");
static const u8 sConversion2MoveDescription[] = _("Makes the user resistant\nto the last attacks type.");
static const u8 sAeroblastMoveDescription[] = _("Launches a vacuumed blast.\nHigh critical-hit ratio.");
static const u8 sCottonSporeMoveDescription[] = _("Spores cling to the foe,\nsharply reducing SPEED.");
static const u8 sReversalMoveDescription[] = _("Inflicts more damage when\nthe users HP is down.");
static const u8 sSpiteMoveDescription[] = _("Spitefully cuts the PP\nof the foes last move.");
static const u8 sPowderSnowMoveDescription[] = _("Blasts the foe with a snowy\ngust. May cause freezing.");
static const u8 sProtectMoveDescription[] = _("Evades attack, but may fail\nif used in succession.");
static const u8 sMachPunchMoveDescription[] = _("A punch is thrown at wicked\nspeed to strike first.");
static const u8 sScaryFaceMoveDescription[] = _("Frightens with a scary face\nto sharply reduce SPEED.");
static const u8 sFaintAttackMoveDescription[] = _("Draws the foe close, then\nstrikes without fail.");
static const u8 sSweetKissMoveDescription[] = _("Demands a kiss with a cute\nlook. May cause confusion.");
static const u8 sBellyDrumMoveDescription[] = _("Maximizes ATTACK while\nsacrificing HP.");
static const u8 sSludgeBombMoveDescription[] = _("Sludge is hurled to inflict\ndamage. May also poison.");
static const u8 sMudSlapMoveDescription[] = _("Hurls mud in the foes face\nto reduce its accuracy.");
static const u8 sOctazookaMoveDescription[] = _("Fires a lump of ink to\ndamage and cut accuracy.");
static const u8 sSpikesMoveDescription[] = _("Sets spikes that hurt a \nfoe switching in.");
static const u8 sZapCannonMoveDescription[] = _("Powerful and sure to cause\nparalysis, but inaccurate.");
static const u8 sForesightMoveDescription[] = _("Negates the foes efforts\nto heighten evasiveness.");
static const u8 sDestinyBondMoveDescription[] = _("If the user faints, the foe\nis also made to faint.");
static const u8 sPerishSongMoveDescription[] = _("Any POKéMON hearing this\nsong faints in 3 turns.");
static const u8 sIcyWindMoveDescription[] = _("A chilling attack that\nlowers the foes SPEED.");
static const u8 sDetectMoveDescription[] = _("Evades attack, but may fail\nif used in succession.");
static const u8 sBoneRushMoveDescription[] = _("Strikes the foe with a bone\nin hand 2 to 5 times.");
static const u8 sLockOnMoveDescription[] = _("Locks on to the foe to\nensure the next move hits.");
static const u8 sOutrageMoveDescription[] = _("A rampage of 2 to 3 turns\nthat confuses the user.");
static const u8 sSandstormMoveDescription[] = _("Causes a sandstorm that\nrages for several turns.");
static const u8 sGigaDrainMoveDescription[] = _("An attack that steals half\nthe damage inflicted.");
static const u8 sEndureMoveDescription[] = _("Endures any attack for\n1 turn, leaving at least 1HP.");
static const u8 sCharmMoveDescription[] = _("Charms the foe and sharply\nreduces its ATTACK.");
static const u8 sRolloutMoveDescription[] = _("An attack lasting 5 turns\nwith rising intensity.");
static const u8 sFalseSwipeMoveDescription[] = _("An attack that leaves the\nfoe with at least 1 HP.");
static const u8 sSwaggerMoveDescription[] = _("Confuses the foe, but also\nsharply raises ATTACK.");
static const u8 sMilkDrinkMoveDescription[] = _("Recovers up to half the\nusers maximum HP.");
static const u8 sSparkMoveDescription[] = _("An electrified tackle that\nmay paralyze the foe.");
static const u8 sFuryCutterMoveDescription[] = _("An attack that intensifies\non each successive hit.");
static const u8 sSteelWingMoveDescription[] = _("Strikes the foe with hard\nwings spread wide.");
static const u8 sMeanLookMoveDescription[] = _("Fixes the foe with a mean\nlook that prevents escape.");
static const u8 sAttractMoveDescription[] = _("Makes the opposite gender\nless likely to attack.");
static const u8 sSleepTalkMoveDescription[] = _("Uses an available move\nrandomly while asleep.");
static const u8 sHealBellMoveDescription[] = _("Chimes soothingly to heal\nall status abnormalities.");
static const u8 sReturnMoveDescription[] = _("An attack that increases\nin power with friendship.");
static const u8 sPresentMoveDescription[] = _("A gift in the form of a\nbomb. May restore HP.");
static const u8 sFrustrationMoveDescription[] = _("An attack that is stronger\nif the TRAINER is disliked.");
static const u8 sSafeguardMoveDescription[] = _("A mystical force prevents\nall status problems.");
static const u8 sPainSplitMoveDescription[] = _("Adds the user and foes HP,\nthen shares them equally.");
static const u8 sSacredFireMoveDescription[] = _("A mystical fire attack that\nmay inflict a burn.");
static const u8 sMagnitudeMoveDescription[] = _("A ground-shaking attack\nof random intensity.");
static const u8 sDynamicPunchMoveDescription[] = _("Powerful and sure to cause\nconfusion, but inaccurate.");
static const u8 sMegahornMoveDescription[] = _("A brutal ramming attack\nusing out-thrust horns.");
static const u8 sDragonBreathMoveDescription[] = _("Strikes the foe with an\nincredible blast of breath.");
static const u8 sBatonPassMoveDescription[] = _("Switches out the user while\nkeeping effects in play.");
static const u8 sEncoreMoveDescription[] = _("Makes the foe repeat its\nlast move over 2 to 6 turns.");
static const u8 sPursuitMoveDescription[] = _("Inflicts bad damage if used\non a foe switching out.");
static const u8 sRapidSpinMoveDescription[] = _("Spins the body at high\nspeed to strike the foe.");
static const u8 sSweetScentMoveDescription[] = _("Allures the foe to reduce\nevasiveness.");
static const u8 sIronTailMoveDescription[] = _("Attacks with a rock-hard\ntail. May lower DEFENSE.");
static const u8 sMetalClawMoveDescription[] = _("A claw attack that may\nraise the users ATTACK.");
static const u8 sVitalThrowMoveDescription[] = _("Makes the users move last,\nbut it never misses.");
static const u8 sMorningSunMoveDescription[] = _("Restores HP. The amount\nvaries with the weather.");
static const u8 sSynthesisMoveDescription[] = _("Restores HP. The amount\nvaries with the weather.");
static const u8 sMoonlightMoveDescription[] = _("Restores HP. The amount\nvaries with the weather.");
static const u8 sHiddenPowerMoveDescription[] = _("The effectiveness varies\nwith the user.");
static const u8 sCrossChopMoveDescription[] = _("A double-chopping attack.\nHigh critical-hit ratio.");
static const u8 sTwisterMoveDescription[] = _("Whips up a vicious twister\nto tear at the foe.");
static const u8 sRainDanceMoveDescription[] = _("Boosts the power of WATER-\ntype moves for 5 turns.");
static const u8 sSunnyDayMoveDescription[] = _("Boosts the power of FIRE-\ntype moves for 5 turns.");
static const u8 sCrunchMoveDescription[] = _("Crunches with sharp fangs.\nMay lower SP. DEF.");
static const u8 sMirrorCoatMoveDescription[] = _("Counters the foes special\nattack at double the power.");
static const u8 sPsychUpMoveDescription[] = _("Copies the foes effect(s)\nand gives to the user.");
static const u8 sExtremeSpeedMoveDescription[] = _("An extremely fast and\npowerful attack.");
static const u8 sAncientPowerMoveDescription[] = _("An attack that may raise\nall stats.");
static const u8 sShadowBallMoveDescription[] = _("Hurls a black blob that may\nlower the foes SP. DEF.");
static const u8 sFutureSightMoveDescription[] = _("Heightens inner power to\nstrike 2 turns later.");
static const u8 sRockSmashMoveDescription[] = _("A rock-crushing attack\nthat may lower DEFENSE.");
static const u8 sWhirlpoolMoveDescription[] = _("Traps and hurts the foe in\na whirlpool for 2 to 5 turns.");
static const u8 sBeatUpMoveDescription[] = _("Summons party POKéMON to\njoin in the attack.");
static const u8 sFakeOutMoveDescription[] = _("A 1st-turn, 1st-strike move\nthat causes flinching.");
static const u8 sUproarMoveDescription[] = _("Causes an uproar for 2 to 5\nturns and prevents sleep.");
static const u8 sStockpileMoveDescription[] = _("Charges up power for up to\n3 turns.");
static const u8 sSpitUpMoveDescription[] = _("Releases stockpiled power\n(the more the better).");
static const u8 sSwallowMoveDescription[] = _("Absorbs stockpiled power\nand restores HP.");
static const u8 sHeatWaveMoveDescription[] = _("Exhales a hot breath on the\nfoe. May inflict a burn.");
static const u8 sHailMoveDescription[] = _("Summons a hailstorm that\nstrikes every turn.");
static const u8 sTormentMoveDescription[] = _("Torments the foe and stops\nsuccessive use of a move.");
static const u8 sFlatterMoveDescription[] = _("Confuses the foe, but\nraises its SP. ATK.");
static const u8 sWillOWispMoveDescription[] = _("Inflicts a burn on the foe\nwith intense fire.");
static const u8 sMementoMoveDescription[] = _("The user faints and lowers\nthe foes abilities.");
static const u8 sFacadeMoveDescription[] = _("Boosts ATTACK when burned,\nparalyzed, or poisoned.");
static const u8 sFocusPunchMoveDescription[] = _("A powerful loyalty attack.\nThe user flinches if hit.");
static const u8 sSmellingSaltMoveDescription[] = _("Powerful against paralyzed\nfoes, but also heals them.");
static const u8 sFollowMeMoveDescription[] = _("Draws attention to make\nfoes attack only the user.");
static const u8 sNaturePowerMoveDescription[] = _("The type of attack varies\ndepending on the location.");
static const u8 sChargeMoveDescription[] = _("Charges power to boost the\nelectric move used next.");
static const u8 sTauntMoveDescription[] = _("Taunts the foe into only\nusing attack moves.");
static const u8 sHelpingHandMoveDescription[] = _("Boosts the power of the\nrecipients moves.");
static const u8 sTrickMoveDescription[] = _("Tricks the foe into trading\nheld items.");
static const u8 sRolePlayMoveDescription[] = _("Mimics the target and\ncopies its special ability.");
static const u8 sWishMoveDescription[] = _("A wish that restores HP.\nIt takes time to work.");
static const u8 sAssistMoveDescription[] = _("Attacks randomly with one\nof the partners moves.");
static const u8 sIngrainMoveDescription[] = _("Lays roots that restore HP.\nThe user cant switch out.");
static const u8 sSuperpowerMoveDescription[] = _("Boosts strength sharply,\nbut lowers abilities.");
static const u8 sMagicCoatMoveDescription[] = _("Reflects special effects\nback to the attacker.");
static const u8 sRecycleMoveDescription[] = _("Recycles a used item for\none more use.");
static const u8 sRevengeMoveDescription[] = _("An attack that gains power\nif injured by the foe.");
static const u8 sBrickBreakMoveDescription[] = _("Destroys barriers such as\nREFLECT and causes damage.");
static const u8 sYawnMoveDescription[] = _("Lulls the foe into yawning,\nthen sleeping next turn.");
static const u8 sKnockOffMoveDescription[] = _("Knocks down the foes held\nitem to prevent its use.");
static const u8 sEndeavorMoveDescription[] = _("Gains power if the users HP\nis lower than the foes HP.");
static const u8 sEruptionMoveDescription[] = _("The higher the users HP,\nthe more damage caused.");
static const u8 sSkillSwapMoveDescription[] = _("The user swaps special\nabilities with the target.");
static const u8 sImprisonMoveDescription[] = _("Prevents foes from using\nmoves known by the user.");
static const u8 sRefreshMoveDescription[] = _("Heals poisoning, paralysis,\nor a burn.");
static const u8 sGrudgeMoveDescription[] = _("If the user faints, deletes\nall PP of foes last move.");
static const u8 sSnatchMoveDescription[] = _("Steals the effects of the\nmove the target uses next.");
static const u8 sSecretPowerMoveDescription[] = _("An attack with effects\nthat vary by location.");
static const u8 sDiveMoveDescription[] = _("Dives underwater the first\nturn and strikes next turn.");
static const u8 sArmThrustMoveDescription[] = _("Straight-arm punches that\nstrike the foe 2 to 5 times.");
static const u8 sCamouflageMoveDescription[] = _("Alters the POKéMONs type\ndepending on the location.");
static const u8 sTailGlowMoveDescription[] = _("Flashes a light that sharply\nraises SP. ATK.");
static const u8 sLusterPurgeMoveDescription[] = _("Attacks with a burst of\nlight. May lower SP. DEF.");
static const u8 sMistBallMoveDescription[] = _("Attacks with a flurry of\ndown. May lower SP. ATK.");
static const u8 sFeatherDanceMoveDescription[] = _("Envelops the foe with down\nto sharply reduce ATTACK.");
static const u8 sTeeterDanceMoveDescription[] = _("Confuses all POKéMON on\nthe scene.");
static const u8 sBlazeKickMoveDescription[] = _("A kick with a high critical-\nhit ratio. May cause a burn.");
static const u8 sMudSportMoveDescription[] = _("Covers the user in mud to\nraise electrical resistance.");
static const u8 sIceBallMoveDescription[] = _("A 5-turn attack that gains\npower on successive hits.");
static const u8 sNeedleArmMoveDescription[] = _("Attacks with thorny arms.\nMay cause flinching.");
static const u8 sSlackOffMoveDescription[] = _("Slacks off and restores\nhalf the maximum HP.");
static const u8 sHyperVoiceMoveDescription[] = _("A loud attack that uses\nsound waves to injure.");
static const u8 sPoisonFangMoveDescription[] = _("A sharp-fanged attack.\nMay badly poison the foe.");
static const u8 sCrushClawMoveDescription[] = _("Tears at the foe with sharp\nclaws. May lower DEFENSE.");
static const u8 sBlastBurnMoveDescription[] = _("Powerful, but leaves the\nuser immobile the next turn.");
static const u8 sHydroCannonMoveDescription[] = _("Powerful, but leaves the\nuser immobile the next turn.");
static const u8 sMeteorMashMoveDescription[] = _("Fires a meteor-like punch.\nMay raise ATTACK.");
static const u8 sAstonishMoveDescription[] = _("An attack that may shock\nthe foe into flinching.");
static const u8 sWeatherBallMoveDescription[] = _("The moves type and power\nchange with the weather.");
static const u8 sAromatherapyMoveDescription[] = _("Heals all status problems\nwith a soothing scent.");
static const u8 sFakeTearsMoveDescription[] = _("Feigns crying to sharply\nlower the foes SP. DEF.");
static const u8 sAirCutterMoveDescription[] = _("Hacks with razorlike wind.\nHigh critical-hit ratio.");
static const u8 sOverheatMoveDescription[] = _("Allows a full-power attack,\nbut sharply lowers SP. ATK.");
static const u8 sOdorSleuthMoveDescription[] = _("Negates the foes efforts\nto heighten evasiveness.");
static const u8 sRockTombMoveDescription[] = _("Stops the foe from moving\nwith rocks and cuts SPEED.");
static const u8 sSilverWindMoveDescription[] = _("A powdery attack that may\nraise abilities.");
static const u8 sMetalSoundMoveDescription[] = _("Emits a horrible screech\nthat sharply lowers SP. DEF.");
static const u8 sGrassWhistleMoveDescription[] = _("Lulls the foe into sleep\nwith a pleasant melody.");
static const u8 sTickleMoveDescription[] = _("Makes the foe laugh to\nlower ATTACK and DEFENSE.");
static const u8 sCosmicPowerMoveDescription[] = _("Raises DEFENSE and SP. DEF\nwith a mystic power.");
static const u8 sWaterSpoutMoveDescription[] = _("Inflicts more damage if the\nusers HP is high.");
static const u8 sSignalBeamMoveDescription[] = _("A strange beam attack that\nmay confuse the foe.");
static const u8 sShadowPunchMoveDescription[] = _("An unavoidable punch that\nis thrown from shadows.");
static const u8 sExtrasensoryMoveDescription[] = _("Attacks with a peculiar\npower. May cause flinching.");
static const u8 sSkyUppercutMoveDescription[] = _("An uppercut thrown as if\nleaping into the sky.");
static const u8 sSandTombMoveDescription[] = _("Traps and hurts the foe in\nquicksand for 2 to 5 turns.");
static const u8 sSheerColdMoveDescription[] = _("A chilling attack that\ncauses fainting if it hits.");
static const u8 sMuddyWaterMoveDescription[] = _("Attacks with muddy water.\nMay lower accuracy.");
static const u8 sBulletSeedMoveDescription[] = _("Shoots 2 to 5 seeds in a row\nto strike the foe.");
static const u8 sAerialAceMoveDescription[] = _("An extremely speedy and\nunavoidable attack.");
static const u8 sIcicleSpearMoveDescription[] = _("Attacks the foe by firing\n2 to 5 icicles in a row.");
static const u8 sIronDefenseMoveDescription[] = _("Hardens the bodys surface\nto sharply raise DEFENSE.");
static const u8 sBlockMoveDescription[] = _("Blocks the foes way to\nprevent escape.");
static const u8 sHowlMoveDescription[] = _("Howls to raise the spirit\nand boosts ATTACK.");
static const u8 sDragonClawMoveDescription[] = _("Slashes the foe with sharp\nclaws.");
static const u8 sFrenzyPlantMoveDescription[] = _("Powerful, but leaves the\nuser immobile the next turn.");
static const u8 sBulkUpMoveDescription[] = _("Bulks up the body to boost\nboth ATTACK and DEFENSE.");
static const u8 sBounceMoveDescription[] = _("Bounces up, then down the\nnext turn. May paralyze.");
static const u8 sMudShotMoveDescription[] = _("Hurls mud at the foe and\nreduces SPEED.");
static const u8 sPoisonTailMoveDescription[] = _("Has a high critical-hit\nratio. May also poison.");
static const u8 sCovetMoveDescription[] = _("Cutely begs to obtain an\nitem held by the foe.");
static const u8 sVoltTackleMoveDescription[] = _("A life-risking tackle that\nslightly hurts the user.");
static const u8 sMagicalLeafMoveDescription[] = _("Attacks with a strange leaf\nthat cannot be evaded.");
static const u8 sWaterSportMoveDescription[] = _("The user becomes soaked to\nraise resistance to fire.");
static const u8 sCalmMindMoveDescription[] = _("Raises SP. ATK and SP. DEF\nby focusing the mind.");
static const u8 sLeafBladeMoveDescription[] = _("Slashes with a sharp leaf.\nHigh critical-hit ratio.");
static const u8 sDragonDanceMoveDescription[] = _("A mystical dance that ups\nATTACK and SPEED.");
static const u8 sRockBlastMoveDescription[] = _("Hurls boulders at the foe\n2 to 5 times in a row.");
static const u8 sShockWaveMoveDescription[] = _("A fast and unavoidable\nelectric attack.");
static const u8 sWaterPulseMoveDescription[] = _("Attacks with ultrasonic\nwaves. May confuse the foe.");
static const u8 sDoomDesireMoveDescription[] = _("Summons strong sunlight to\nattack 2 turns later.");
static const u8 sPsychoBoostMoveDescription[] = _("Allows a full-power attack,\nbut sharply lowers SP. ATK.");
// MOVE_NONE is ignored in this table. Make sure to always subtract 1 before getting the right pointer.
const u8 *const gMoveDescriptionPointers[MOVES_COUNT - 1] =
{
[MOVE_POUND - 1] = sPoundMoveDescription,
[MOVE_KARATE_CHOP - 1] = sKarateChopMoveDescription,
[MOVE_DOUBLE_SLAP - 1] = sDoubleSlapMoveDescription,
[MOVE_COMET_PUNCH - 1] = sCometPunchMoveDescription,
[MOVE_MEGA_PUNCH - 1] = sMegaPunchMoveDescription,
[MOVE_PAY_DAY - 1] = sPayDayMoveDescription,
[MOVE_FIRE_PUNCH - 1] = sFirePunchMoveDescription,
[MOVE_ICE_PUNCH - 1] = sIcePunchMoveDescription,
[MOVE_THUNDER_PUNCH - 1] = sThunderPunchMoveDescription,
[MOVE_SCRATCH - 1] = sScratchMoveDescription,
[MOVE_VICE_GRIP - 1] = sViceGripMoveDescription,
[MOVE_GUILLOTINE - 1] = sGuillotineMoveDescription,
[MOVE_RAZOR_WIND - 1] = sRazorWindMoveDescription,
[MOVE_SWORDS_DANCE - 1] = sSwordsDanceMoveDescription,
[MOVE_CUT - 1] = sCutMoveDescription,
[MOVE_GUST - 1] = sGustMoveDescription,
[MOVE_WING_ATTACK - 1] = sWingAttackMoveDescription,
[MOVE_WHIRLWIND - 1] = sWhirlwindMoveDescription,
[MOVE_FLY - 1] = sFlyMoveDescription,
[MOVE_BIND - 1] = sBindMoveDescription,
[MOVE_SLAM - 1] = sSlamMoveDescription,
[MOVE_VINE_WHIP - 1] = sVineWhipMoveDescription,
[MOVE_STOMP - 1] = sStompMoveDescription,
[MOVE_DOUBLE_KICK - 1] = sDoubleKickMoveDescription,
[MOVE_MEGA_KICK - 1] = sMegaKickMoveDescription,
[MOVE_JUMP_KICK - 1] = sJumpKickMoveDescription,
[MOVE_ROLLING_KICK - 1] = sRollingKickMoveDescription,
[MOVE_SAND_ATTACK - 1] = sSandAttackMoveDescription,
[MOVE_HEADBUTT - 1] = sHeadbuttMoveDescription,
[MOVE_HORN_ATTACK - 1] = sHornAttackMoveDescription,
[MOVE_FURY_ATTACK - 1] = sFuryAttackMoveDescription,
[MOVE_HORN_DRILL - 1] = sHornDrillMoveDescription,
[MOVE_TACKLE - 1] = sTackleMoveDescription,
[MOVE_BODY_SLAM - 1] = sBodySlamMoveDescription,
[MOVE_WRAP - 1] = sWrapMoveDescription,
[MOVE_TAKE_DOWN - 1] = sTakeDownMoveDescription,
[MOVE_THRASH - 1] = sThrashMoveDescription,
[MOVE_DOUBLE_EDGE - 1] = sDoubleEdgeMoveDescription,
[MOVE_TAIL_WHIP - 1] = sTailWhipMoveDescription,
[MOVE_POISON_STING - 1] = sPoisonStingMoveDescription,
[MOVE_TWINEEDLE - 1] = sTwineedleMoveDescription,
[MOVE_PIN_MISSILE - 1] = sPinMissileMoveDescription,
[MOVE_LEER - 1] = sLeerMoveDescription,
[MOVE_BITE - 1] = sBiteMoveDescription,
[MOVE_GROWL - 1] = sGrowlMoveDescription,
[MOVE_ROAR - 1] = sRoarMoveDescription,
[MOVE_SING - 1] = sSingMoveDescription,
[MOVE_SUPERSONIC - 1] = sSupersonicMoveDescription,
[MOVE_SONIC_BOOM - 1] = sSonicBoomMoveDescription,
[MOVE_DISABLE - 1] = sDisableMoveDescription,
[MOVE_ACID - 1] = sAcidMoveDescription,
[MOVE_EMBER - 1] = sEmberMoveDescription,
[MOVE_FLAMETHROWER - 1] = sFlamethrowerMoveDescription,
[MOVE_MIST - 1] = sMistMoveDescription,
[MOVE_WATER_GUN - 1] = sWaterGunMoveDescription,
[MOVE_HYDRO_PUMP - 1] = sHydroPumpMoveDescription,
[MOVE_SURF - 1] = sSurfMoveDescription,
[MOVE_ICE_BEAM - 1] = sIceBeamMoveDescription,
[MOVE_BLIZZARD - 1] = sBlizzardMoveDescription,
[MOVE_PSYBEAM - 1] = sPsybeamMoveDescription,
[MOVE_BUBBLE_BEAM - 1] = sBubbleBeamMoveDescription,
[MOVE_AURORA_BEAM - 1] = sAuroraBeamMoveDescription,
[MOVE_HYPER_BEAM - 1] = sHyperBeamMoveDescription,
[MOVE_PECK - 1] = sPeckMoveDescription,
[MOVE_DRILL_PECK - 1] = sDrillPeckMoveDescription,
[MOVE_SUBMISSION - 1] = sSubmissionMoveDescription,
[MOVE_LOW_KICK - 1] = sLowKickMoveDescription,
[MOVE_COUNTER - 1] = sCounterMoveDescription,
[MOVE_SEISMIC_TOSS - 1] = sSeismicTossMoveDescription,
[MOVE_STRENGTH - 1] = sStrengthMoveDescription,
[MOVE_ABSORB - 1] = sAbsorbMoveDescription,
[MOVE_MEGA_DRAIN - 1] = sMegaDrainMoveDescription,
[MOVE_LEECH_SEED - 1] = sLeechSeedMoveDescription,
[MOVE_GROWTH - 1] = sGrowthMoveDescription,
[MOVE_RAZOR_LEAF - 1] = sRazorLeafMoveDescription,
[MOVE_SOLAR_BEAM - 1] = sSolarBeamMoveDescription,
[MOVE_POISON_POWDER - 1] = sPoisonPowderMoveDescription,
[MOVE_STUN_SPORE - 1] = sStunSporeMoveDescription,
[MOVE_SLEEP_POWDER - 1] = sSleepPowderMoveDescription,
[MOVE_PETAL_DANCE - 1] = sPetalDanceMoveDescription,
[MOVE_STRING_SHOT - 1] = sStringShotMoveDescription,
[MOVE_DRAGON_RAGE - 1] = sDragonRageMoveDescription,
[MOVE_FIRE_SPIN - 1] = sFireSpinMoveDescription,
[MOVE_THUNDER_SHOCK - 1] = sThunderShockMoveDescription,
[MOVE_THUNDERBOLT - 1] = sThunderboltMoveDescription,
[MOVE_THUNDER_WAVE - 1] = sThunderWaveMoveDescription,
[MOVE_THUNDER - 1] = sThunderMoveDescription,
[MOVE_ROCK_THROW - 1] = sRockThrowMoveDescription,
[MOVE_EARTHQUAKE - 1] = sEarthquakeMoveDescription,
[MOVE_FISSURE - 1] = sFissureMoveDescription,
[MOVE_DIG - 1] = sDigMoveDescription,
[MOVE_TOXIC - 1] = sToxicMoveDescription,
[MOVE_CONFUSION - 1] = sConfusionMoveDescription,
[MOVE_PSYCHIC - 1] = sPsychicMoveDescription,
[MOVE_HYPNOSIS - 1] = sHypnosisMoveDescription,
[MOVE_MEDITATE - 1] = sMeditateMoveDescription,
[MOVE_AGILITY - 1] = sAgilityMoveDescription,
[MOVE_QUICK_ATTACK - 1] = sQuickAttackMoveDescription,
[MOVE_RAGE - 1] = sRageMoveDescription,
[MOVE_TELEPORT - 1] = sTeleportMoveDescription,
[MOVE_NIGHT_SHADE - 1] = sNightShadeMoveDescription,
[MOVE_MIMIC - 1] = sMimicMoveDescription,
[MOVE_SCREECH - 1] = sScreechMoveDescription,
[MOVE_DOUBLE_TEAM - 1] = sDoubleTeamMoveDescription,
[MOVE_RECOVER - 1] = sRecoverMoveDescription,
[MOVE_HARDEN - 1] = sHardenMoveDescription,
[MOVE_MINIMIZE - 1] = sMinimizeMoveDescription,
[MOVE_SMOKESCREEN - 1] = sSmokescreenMoveDescription,
[MOVE_CONFUSE_RAY - 1] = sConfuseRayMoveDescription,
[MOVE_WITHDRAW - 1] = sWithdrawMoveDescription,
[MOVE_DEFENSE_CURL - 1] = sDefenseCurlMoveDescription,
[MOVE_BARRIER - 1] = sBarrierMoveDescription,
[MOVE_LIGHT_SCREEN - 1] = sLightScreenMoveDescription,
[MOVE_HAZE - 1] = sHazeMoveDescription,
[MOVE_REFLECT - 1] = sReflectMoveDescription,
[MOVE_FOCUS_ENERGY - 1] = sFocusEnergyMoveDescription,
[MOVE_BIDE - 1] = sBideMoveDescription,
[MOVE_METRONOME - 1] = sMetronomeMoveDescription,
[MOVE_MIRROR_MOVE - 1] = sMirrorMoveMoveDescription,
[MOVE_SELF_DESTRUCT - 1] = sSelfDestructMoveDescription,
[MOVE_EGG_BOMB - 1] = sEggBombMoveDescription,
[MOVE_LICK - 1] = sLickMoveDescription,
[MOVE_SMOG - 1] = sSmogMoveDescription,
[MOVE_SLUDGE - 1] = sSludgeMoveDescription,
[MOVE_BONE_CLUB - 1] = sBoneClubMoveDescription,
[MOVE_FIRE_BLAST - 1] = sFireBlastMoveDescription,
[MOVE_WATERFALL - 1] = sWaterfallMoveDescription,
[MOVE_CLAMP - 1] = sClampMoveDescription,
[MOVE_SWIFT - 1] = sSwiftMoveDescription,
[MOVE_SKULL_BASH - 1] = sSkullBashMoveDescription,
[MOVE_SPIKE_CANNON - 1] = sSpikeCannonMoveDescription,
[MOVE_CONSTRICT - 1] = sConstrictMoveDescription,
[MOVE_AMNESIA - 1] = sAmnesiaMoveDescription,
[MOVE_KINESIS - 1] = sKinesisMoveDescription,
[MOVE_SOFT_BOILED - 1] = sSoftBoiledMoveDescription,
[MOVE_HI_JUMP_KICK - 1] = sHiJumpKickMoveDescription,
[MOVE_GLARE - 1] = sGlareMoveDescription,
[MOVE_DREAM_EATER - 1] = sDreamEaterMoveDescription,
[MOVE_POISON_GAS - 1] = sPoisonGasMoveDescription,
[MOVE_BARRAGE - 1] = sBarrageMoveDescription,
[MOVE_LEECH_LIFE - 1] = sLeechLifeMoveDescription,
[MOVE_LOVELY_KISS - 1] = sLovelyKissMoveDescription,
[MOVE_SKY_ATTACK - 1] = sSkyAttackMoveDescription,
[MOVE_TRANSFORM - 1] = sTransformMoveDescription,
[MOVE_BUBBLE - 1] = sBubbleMoveDescription,
[MOVE_DIZZY_PUNCH - 1] = sDizzyPunchMoveDescription,
[MOVE_SPORE - 1] = sSporeMoveDescription,
[MOVE_FLASH - 1] = sFlashMoveDescription,
[MOVE_PSYWAVE - 1] = sPsywaveMoveDescription,
[MOVE_SPLASH - 1] = sSplashMoveDescription,
[MOVE_ACID_ARMOR - 1] = sAcidArmorMoveDescription,
[MOVE_CRABHAMMER - 1] = sCrabhammerMoveDescription,
[MOVE_EXPLOSION - 1] = sExplosionMoveDescription,
[MOVE_FURY_SWIPES - 1] = sFurySwipesMoveDescription,
[MOVE_BONEMERANG - 1] = sBonemerangMoveDescription,
[MOVE_REST - 1] = sRestMoveDescription,
[MOVE_ROCK_SLIDE - 1] = sRockSlideMoveDescription,
[MOVE_HYPER_FANG - 1] = sHyperFangMoveDescription,
[MOVE_SHARPEN - 1] = sSharpenMoveDescription,
[MOVE_CONVERSION - 1] = sConversionMoveDescription,
[MOVE_TRI_ATTACK - 1] = sTriAttackMoveDescription,
[MOVE_SUPER_FANG - 1] = sSuperFangMoveDescription,
[MOVE_SLASH - 1] = sSlashMoveDescription,
[MOVE_SUBSTITUTE - 1] = sSubstituteMoveDescription,
[MOVE_STRUGGLE - 1] = sStruggleMoveDescription,
[MOVE_SKETCH - 1] = sSketchMoveDescription,
[MOVE_TRIPLE_KICK - 1] = sTripleKickMoveDescription,
[MOVE_THIEF - 1] = sThiefMoveDescription,
[MOVE_SPIDER_WEB - 1] = sSpiderWebMoveDescription,
[MOVE_MIND_READER - 1] = sMindReaderMoveDescription,
[MOVE_NIGHTMARE - 1] = sNightmareMoveDescription,
[MOVE_FLAME_WHEEL - 1] = sFlameWheelMoveDescription,
[MOVE_SNORE - 1] = sSnoreMoveDescription,
[MOVE_CURSE - 1] = sCurseMoveDescription,
[MOVE_FLAIL - 1] = sFlailMoveDescription,
[MOVE_CONVERSION_2 - 1] = sConversion2MoveDescription,
[MOVE_AEROBLAST - 1] = sAeroblastMoveDescription,
[MOVE_COTTON_SPORE - 1] = sCottonSporeMoveDescription,
[MOVE_REVERSAL - 1] = sReversalMoveDescription,
[MOVE_SPITE - 1] = sSpiteMoveDescription,
[MOVE_POWDER_SNOW - 1] = sPowderSnowMoveDescription,
[MOVE_PROTECT - 1] = sProtectMoveDescription,
[MOVE_MACH_PUNCH - 1] = sMachPunchMoveDescription,
[MOVE_SCARY_FACE - 1] = sScaryFaceMoveDescription,
[MOVE_FAINT_ATTACK - 1] = sFaintAttackMoveDescription,
[MOVE_SWEET_KISS - 1] = sSweetKissMoveDescription,
[MOVE_BELLY_DRUM - 1] = sBellyDrumMoveDescription,
[MOVE_SLUDGE_BOMB - 1] = sSludgeBombMoveDescription,
[MOVE_MUD_SLAP - 1] = sMudSlapMoveDescription,
[MOVE_OCTAZOOKA - 1] = sOctazookaMoveDescription,
[MOVE_SPIKES - 1] = sSpikesMoveDescription,
[MOVE_ZAP_CANNON - 1] = sZapCannonMoveDescription,
[MOVE_FORESIGHT - 1] = sForesightMoveDescription,
[MOVE_DESTINY_BOND - 1] = sDestinyBondMoveDescription,
[MOVE_PERISH_SONG - 1] = sPerishSongMoveDescription,
[MOVE_ICY_WIND - 1] = sIcyWindMoveDescription,
[MOVE_DETECT - 1] = sDetectMoveDescription,
[MOVE_BONE_RUSH - 1] = sBoneRushMoveDescription,
[MOVE_LOCK_ON - 1] = sLockOnMoveDescription,
[MOVE_OUTRAGE - 1] = sOutrageMoveDescription,
[MOVE_SANDSTORM - 1] = sSandstormMoveDescription,
[MOVE_GIGA_DRAIN - 1] = sGigaDrainMoveDescription,
[MOVE_ENDURE - 1] = sEndureMoveDescription,
[MOVE_CHARM - 1] = sCharmMoveDescription,
[MOVE_ROLLOUT - 1] = sRolloutMoveDescription,
[MOVE_FALSE_SWIPE - 1] = sFalseSwipeMoveDescription,
[MOVE_SWAGGER - 1] = sSwaggerMoveDescription,
[MOVE_MILK_DRINK - 1] = sMilkDrinkMoveDescription,
[MOVE_SPARK - 1] = sSparkMoveDescription,
[MOVE_FURY_CUTTER - 1] = sFuryCutterMoveDescription,
[MOVE_STEEL_WING - 1] = sSteelWingMoveDescription,
[MOVE_MEAN_LOOK - 1] = sMeanLookMoveDescription,
[MOVE_ATTRACT - 1] = sAttractMoveDescription,
[MOVE_SLEEP_TALK - 1] = sSleepTalkMoveDescription,
[MOVE_HEAL_BELL - 1] = sHealBellMoveDescription,
[MOVE_RETURN - 1] = sReturnMoveDescription,
[MOVE_PRESENT - 1] = sPresentMoveDescription,
[MOVE_FRUSTRATION - 1] = sFrustrationMoveDescription,
[MOVE_SAFEGUARD - 1] = sSafeguardMoveDescription,
[MOVE_PAIN_SPLIT - 1] = sPainSplitMoveDescription,
[MOVE_SACRED_FIRE - 1] = sSacredFireMoveDescription,
[MOVE_MAGNITUDE - 1] = sMagnitudeMoveDescription,
[MOVE_DYNAMIC_PUNCH - 1] = sDynamicPunchMoveDescription,
[MOVE_MEGAHORN - 1] = sMegahornMoveDescription,
[MOVE_DRAGON_BREATH - 1] = sDragonBreathMoveDescription,
[MOVE_BATON_PASS - 1] = sBatonPassMoveDescription,
[MOVE_ENCORE - 1] = sEncoreMoveDescription,
[MOVE_PURSUIT - 1] = sPursuitMoveDescription,
[MOVE_RAPID_SPIN - 1] = sRapidSpinMoveDescription,
[MOVE_SWEET_SCENT - 1] = sSweetScentMoveDescription,
[MOVE_IRON_TAIL - 1] = sIronTailMoveDescription,
[MOVE_METAL_CLAW - 1] = sMetalClawMoveDescription,
[MOVE_VITAL_THROW - 1] = sVitalThrowMoveDescription,
[MOVE_MORNING_SUN - 1] = sMorningSunMoveDescription,
[MOVE_SYNTHESIS - 1] = sSynthesisMoveDescription,
[MOVE_MOONLIGHT - 1] = sMoonlightMoveDescription,
[MOVE_HIDDEN_POWER - 1] = sHiddenPowerMoveDescription,
[MOVE_CROSS_CHOP - 1] = sCrossChopMoveDescription,
[MOVE_TWISTER - 1] = sTwisterMoveDescription,
[MOVE_RAIN_DANCE - 1] = sRainDanceMoveDescription,
[MOVE_SUNNY_DAY - 1] = sSunnyDayMoveDescription,
[MOVE_CRUNCH - 1] = sCrunchMoveDescription,
[MOVE_MIRROR_COAT - 1] = sMirrorCoatMoveDescription,
[MOVE_PSYCH_UP - 1] = sPsychUpMoveDescription,
[MOVE_EXTREME_SPEED - 1] = sExtremeSpeedMoveDescription,
[MOVE_ANCIENT_POWER - 1] = sAncientPowerMoveDescription,
[MOVE_SHADOW_BALL - 1] = sShadowBallMoveDescription,
[MOVE_FUTURE_SIGHT - 1] = sFutureSightMoveDescription,
[MOVE_ROCK_SMASH - 1] = sRockSmashMoveDescription,
[MOVE_WHIRLPOOL - 1] = sWhirlpoolMoveDescription,
[MOVE_BEAT_UP - 1] = sBeatUpMoveDescription,
[MOVE_FAKE_OUT - 1] = sFakeOutMoveDescription,
[MOVE_UPROAR - 1] = sUproarMoveDescription,
[MOVE_STOCKPILE - 1] = sStockpileMoveDescription,
[MOVE_SPIT_UP - 1] = sSpitUpMoveDescription,
[MOVE_SWALLOW - 1] = sSwallowMoveDescription,
[MOVE_HEAT_WAVE - 1] = sHeatWaveMoveDescription,
[MOVE_HAIL - 1] = sHailMoveDescription,
[MOVE_TORMENT - 1] = sTormentMoveDescription,
[MOVE_FLATTER - 1] = sFlatterMoveDescription,
[MOVE_WILL_O_WISP - 1] = sWillOWispMoveDescription,
[MOVE_MEMENTO - 1] = sMementoMoveDescription,
[MOVE_FACADE - 1] = sFacadeMoveDescription,
[MOVE_FOCUS_PUNCH - 1] = sFocusPunchMoveDescription,
[MOVE_SMELLING_SALT - 1] = sSmellingSaltMoveDescription,
[MOVE_FOLLOW_ME - 1] = sFollowMeMoveDescription,
[MOVE_NATURE_POWER - 1] = sNaturePowerMoveDescription,
[MOVE_CHARGE - 1] = sChargeMoveDescription,
[MOVE_TAUNT - 1] = sTauntMoveDescription,
[MOVE_HELPING_HAND - 1] = sHelpingHandMoveDescription,
[MOVE_TRICK - 1] = sTrickMoveDescription,
[MOVE_ROLE_PLAY - 1] = sRolePlayMoveDescription,
[MOVE_WISH - 1] = sWishMoveDescription,
[MOVE_ASSIST - 1] = sAssistMoveDescription,
[MOVE_INGRAIN - 1] = sIngrainMoveDescription,
[MOVE_SUPERPOWER - 1] = sSuperpowerMoveDescription,
[MOVE_MAGIC_COAT - 1] = sMagicCoatMoveDescription,
[MOVE_RECYCLE - 1] = sRecycleMoveDescription,
[MOVE_REVENGE - 1] = sRevengeMoveDescription,
[MOVE_BRICK_BREAK - 1] = sBrickBreakMoveDescription,
[MOVE_YAWN - 1] = sYawnMoveDescription,
[MOVE_KNOCK_OFF - 1] = sKnockOffMoveDescription,
[MOVE_ENDEAVOR - 1] = sEndeavorMoveDescription,
[MOVE_ERUPTION - 1] = sEruptionMoveDescription,
[MOVE_SKILL_SWAP - 1] = sSkillSwapMoveDescription,
[MOVE_IMPRISON - 1] = sImprisonMoveDescription,
[MOVE_REFRESH - 1] = sRefreshMoveDescription,
[MOVE_GRUDGE - 1] = sGrudgeMoveDescription,
[MOVE_SNATCH - 1] = sSnatchMoveDescription,
[MOVE_SECRET_POWER - 1] = sSecretPowerMoveDescription,
[MOVE_DIVE - 1] = sDiveMoveDescription,
[MOVE_ARM_THRUST - 1] = sArmThrustMoveDescription,
[MOVE_CAMOUFLAGE - 1] = sCamouflageMoveDescription,
[MOVE_TAIL_GLOW - 1] = sTailGlowMoveDescription,
[MOVE_LUSTER_PURGE - 1] = sLusterPurgeMoveDescription,
[MOVE_MIST_BALL - 1] = sMistBallMoveDescription,
[MOVE_FEATHER_DANCE - 1] = sFeatherDanceMoveDescription,
[MOVE_TEETER_DANCE - 1] = sTeeterDanceMoveDescription,
[MOVE_BLAZE_KICK - 1] = sBlazeKickMoveDescription,
[MOVE_MUD_SPORT - 1] = sMudSportMoveDescription,
[MOVE_ICE_BALL - 1] = sIceBallMoveDescription,
[MOVE_NEEDLE_ARM - 1] = sNeedleArmMoveDescription,
[MOVE_SLACK_OFF - 1] = sSlackOffMoveDescription,
[MOVE_HYPER_VOICE - 1] = sHyperVoiceMoveDescription,
[MOVE_POISON_FANG - 1] = sPoisonFangMoveDescription,
[MOVE_CRUSH_CLAW - 1] = sCrushClawMoveDescription,
[MOVE_BLAST_BURN - 1] = sBlastBurnMoveDescription,
[MOVE_HYDRO_CANNON - 1] = sHydroCannonMoveDescription,
[MOVE_METEOR_MASH - 1] = sMeteorMashMoveDescription,
[MOVE_ASTONISH - 1] = sAstonishMoveDescription,
[MOVE_WEATHER_BALL - 1] = sWeatherBallMoveDescription,
[MOVE_AROMATHERAPY - 1] = sAromatherapyMoveDescription,
[MOVE_FAKE_TEARS - 1] = sFakeTearsMoveDescription,
[MOVE_AIR_CUTTER - 1] = sAirCutterMoveDescription,
[MOVE_OVERHEAT - 1] = sOverheatMoveDescription,
[MOVE_ODOR_SLEUTH - 1] = sOdorSleuthMoveDescription,
[MOVE_ROCK_TOMB - 1] = sRockTombMoveDescription,
[MOVE_SILVER_WIND - 1] = sSilverWindMoveDescription,
[MOVE_METAL_SOUND - 1] = sMetalSoundMoveDescription,
[MOVE_GRASS_WHISTLE - 1] = sGrassWhistleMoveDescription,
[MOVE_TICKLE - 1] = sTickleMoveDescription,
[MOVE_COSMIC_POWER - 1] = sCosmicPowerMoveDescription,
[MOVE_WATER_SPOUT - 1] = sWaterSpoutMoveDescription,
[MOVE_SIGNAL_BEAM - 1] = sSignalBeamMoveDescription,
[MOVE_SHADOW_PUNCH - 1] = sShadowPunchMoveDescription,
[MOVE_EXTRASENSORY - 1] = sExtrasensoryMoveDescription,
[MOVE_SKY_UPPERCUT - 1] = sSkyUppercutMoveDescription,
[MOVE_SAND_TOMB - 1] = sSandTombMoveDescription,
[MOVE_SHEER_COLD - 1] = sSheerColdMoveDescription,
[MOVE_MUDDY_WATER - 1] = sMuddyWaterMoveDescription,
[MOVE_BULLET_SEED - 1] = sBulletSeedMoveDescription,
[MOVE_AERIAL_ACE - 1] = sAerialAceMoveDescription,
[MOVE_ICICLE_SPEAR - 1] = sIcicleSpearMoveDescription,
[MOVE_IRON_DEFENSE - 1] = sIronDefenseMoveDescription,
[MOVE_BLOCK - 1] = sBlockMoveDescription,
[MOVE_HOWL - 1] = sHowlMoveDescription,
[MOVE_DRAGON_CLAW - 1] = sDragonClawMoveDescription,
[MOVE_FRENZY_PLANT - 1] = sFrenzyPlantMoveDescription,
[MOVE_BULK_UP - 1] = sBulkUpMoveDescription,
[MOVE_BOUNCE - 1] = sBounceMoveDescription,
[MOVE_MUD_SHOT - 1] = sMudShotMoveDescription,
[MOVE_POISON_TAIL - 1] = sPoisonTailMoveDescription,
[MOVE_COVET - 1] = sCovetMoveDescription,
[MOVE_VOLT_TACKLE - 1] = sVoltTackleMoveDescription,
[MOVE_MAGICAL_LEAF - 1] = sMagicalLeafMoveDescription,
[MOVE_WATER_SPORT - 1] = sWaterSportMoveDescription,
[MOVE_CALM_MIND - 1] = sCalmMindMoveDescription,
[MOVE_LEAF_BLADE - 1] = sLeafBladeMoveDescription,
[MOVE_DRAGON_DANCE - 1] = sDragonDanceMoveDescription,
[MOVE_ROCK_BLAST - 1] = sRockBlastMoveDescription,
[MOVE_SHOCK_WAVE - 1] = sShockWaveMoveDescription,
[MOVE_WATER_PULSE - 1] = sWaterPulseMoveDescription,
[MOVE_DOOM_DESIRE - 1] = sDoomDesireMoveDescription,
[MOVE_PSYCHO_BOOST - 1] = sPsychoBoostMoveDescription,
};
+358
View File
@@ -0,0 +1,358 @@
const u8 gMoveNames[MOVES_COUNT][MOVE_NAME_LENGTH + 1] =
{
[MOVE_NONE] = _("-"),
[MOVE_POUND] = _("POUND"),
[MOVE_KARATE_CHOP] = _("KARATE CHOP"),
[MOVE_DOUBLE_SLAP] = _("DOUBLESLAP"),
[MOVE_COMET_PUNCH] = _("COMET PUNCH"),
[MOVE_MEGA_PUNCH] = _("MEGA PUNCH"),
[MOVE_PAY_DAY] = _("PAY DAY"),
[MOVE_FIRE_PUNCH] = _("FIRE PUNCH"),
[MOVE_ICE_PUNCH] = _("ICE PUNCH"),
[MOVE_THUNDER_PUNCH] = _("THUNDERPUNCH"),
[MOVE_SCRATCH] = _("SCRATCH"),
[MOVE_VICE_GRIP] = _("VICEGRIP"),
[MOVE_GUILLOTINE] = _("GUILLOTINE"),
[MOVE_RAZOR_WIND] = _("RAZOR WIND"),
[MOVE_SWORDS_DANCE] = _("SWORDS DANCE"),
[MOVE_CUT] = _("CUT"),
[MOVE_GUST] = _("GUST"),
[MOVE_WING_ATTACK] = _("WING ATTACK"),
[MOVE_WHIRLWIND] = _("WHIRLWIND"),
[MOVE_FLY] = _("FLY"),
[MOVE_BIND] = _("BIND"),
[MOVE_SLAM] = _("SLAM"),
[MOVE_VINE_WHIP] = _("VINE WHIP"),
[MOVE_STOMP] = _("STOMP"),
[MOVE_DOUBLE_KICK] = _("DOUBLE KICK"),
[MOVE_MEGA_KICK] = _("MEGA KICK"),
[MOVE_JUMP_KICK] = _("JUMP KICK"),
[MOVE_ROLLING_KICK] = _("ROLLING KICK"),
[MOVE_SAND_ATTACK] = _("SAND-ATTACK"),
[MOVE_HEADBUTT] = _("HEADBUTT"),
[MOVE_HORN_ATTACK] = _("HORN ATTACK"),
[MOVE_FURY_ATTACK] = _("FURY ATTACK"),
[MOVE_HORN_DRILL] = _("HORN DRILL"),
[MOVE_TACKLE] = _("TACKLE"),
[MOVE_BODY_SLAM] = _("BODY SLAM"),
[MOVE_WRAP] = _("WRAP"),
[MOVE_TAKE_DOWN] = _("TAKE DOWN"),
[MOVE_THRASH] = _("THRASH"),
[MOVE_DOUBLE_EDGE] = _("DOUBLE-EDGE"),
[MOVE_TAIL_WHIP] = _("TAIL WHIP"),
[MOVE_POISON_STING] = _("POISON STING"),
[MOVE_TWINEEDLE] = _("TWINEEDLE"),
[MOVE_PIN_MISSILE] = _("PIN MISSILE"),
[MOVE_LEER] = _("LEER"),
[MOVE_BITE] = _("BITE"),
[MOVE_GROWL] = _("GROWL"),
[MOVE_ROAR] = _("ROAR"),
[MOVE_SING] = _("SING"),
[MOVE_SUPERSONIC] = _("SUPERSONIC"),
[MOVE_SONIC_BOOM] = _("SONICBOOM"),
[MOVE_DISABLE] = _("DISABLE"),
[MOVE_ACID] = _("ACID"),
[MOVE_EMBER] = _("EMBER"),
[MOVE_FLAMETHROWER] = _("FLAMETHROWER"),
[MOVE_MIST] = _("MIST"),
[MOVE_WATER_GUN] = _("WATER GUN"),
[MOVE_HYDRO_PUMP] = _("HYDRO PUMP"),
[MOVE_SURF] = _("SURF"),
[MOVE_ICE_BEAM] = _("ICE BEAM"),
[MOVE_BLIZZARD] = _("BLIZZARD"),
[MOVE_PSYBEAM] = _("PSYBEAM"),
[MOVE_BUBBLE_BEAM] = _("BUBBLEBEAM"),
[MOVE_AURORA_BEAM] = _("AURORA BEAM"),
[MOVE_HYPER_BEAM] = _("HYPER BEAM"),
[MOVE_PECK] = _("PECK"),
[MOVE_DRILL_PECK] = _("DRILL PECK"),
[MOVE_SUBMISSION] = _("SUBMISSION"),
[MOVE_LOW_KICK] = _("LOW KICK"),
[MOVE_COUNTER] = _("COUNTER"),
[MOVE_SEISMIC_TOSS] = _("SEISMIC TOSS"),
[MOVE_STRENGTH] = _("STRENGTH"),
[MOVE_ABSORB] = _("ABSORB"),
[MOVE_MEGA_DRAIN] = _("MEGA DRAIN"),
[MOVE_LEECH_SEED] = _("LEECH SEED"),
[MOVE_GROWTH] = _("GROWTH"),
[MOVE_RAZOR_LEAF] = _("RAZOR LEAF"),
[MOVE_SOLAR_BEAM] = _("SOLARBEAM"),
[MOVE_POISON_POWDER] = _("POISONPOWDER"),
[MOVE_STUN_SPORE] = _("STUN SPORE"),
[MOVE_SLEEP_POWDER] = _("SLEEP POWDER"),
[MOVE_PETAL_DANCE] = _("PETAL DANCE"),
[MOVE_STRING_SHOT] = _("STRING SHOT"),
[MOVE_DRAGON_RAGE] = _("DRAGON RAGE"),
[MOVE_FIRE_SPIN] = _("FIRE SPIN"),
[MOVE_THUNDER_SHOCK] = _("THUNDERSHOCK"),
[MOVE_THUNDERBOLT] = _("THUNDERBOLT"),
[MOVE_THUNDER_WAVE] = _("THUNDER WAVE"),
[MOVE_THUNDER] = _("THUNDER"),
[MOVE_ROCK_THROW] = _("ROCK THROW"),
[MOVE_EARTHQUAKE] = _("EARTHQUAKE"),
[MOVE_FISSURE] = _("FISSURE"),
[MOVE_DIG] = _("DIG"),
[MOVE_TOXIC] = _("TOXIC"),
[MOVE_CONFUSION] = _("CONFUSION"),
[MOVE_PSYCHIC] = _("PSYCHIC"),
[MOVE_HYPNOSIS] = _("HYPNOSIS"),
[MOVE_MEDITATE] = _("MEDITATE"),
[MOVE_AGILITY] = _("AGILITY"),
[MOVE_QUICK_ATTACK] = _("QUICK ATTACK"),
[MOVE_RAGE] = _("RAGE"),
[MOVE_TELEPORT] = _("TELEPORT"),
[MOVE_NIGHT_SHADE] = _("NIGHT SHADE"),
[MOVE_MIMIC] = _("MIMIC"),
[MOVE_SCREECH] = _("SCREECH"),
[MOVE_DOUBLE_TEAM] = _("DOUBLE TEAM"),
[MOVE_RECOVER] = _("RECOVER"),
[MOVE_HARDEN] = _("HARDEN"),
[MOVE_MINIMIZE] = _("MINIMIZE"),
[MOVE_SMOKESCREEN] = _("SMOKESCREEN"),
[MOVE_CONFUSE_RAY] = _("CONFUSE RAY"),
[MOVE_WITHDRAW] = _("WITHDRAW"),
[MOVE_DEFENSE_CURL] = _("DEFENSE CURL"),
[MOVE_BARRIER] = _("BARRIER"),
[MOVE_LIGHT_SCREEN] = _("LIGHT SCREEN"),
[MOVE_HAZE] = _("HAZE"),
[MOVE_REFLECT] = _("REFLECT"),
[MOVE_FOCUS_ENERGY] = _("FOCUS ENERGY"),
[MOVE_BIDE] = _("BIDE"),
[MOVE_METRONOME] = _("METRONOME"),
[MOVE_MIRROR_MOVE] = _("MIRROR MOVE"),
[MOVE_SELF_DESTRUCT] = _("SELFDESTRUCT"),
[MOVE_EGG_BOMB] = _("EGG BOMB"),
[MOVE_LICK] = _("LICK"),
[MOVE_SMOG] = _("SMOG"),
[MOVE_SLUDGE] = _("SLUDGE"),
[MOVE_BONE_CLUB] = _("BONE CLUB"),
[MOVE_FIRE_BLAST] = _("FIRE BLAST"),
[MOVE_WATERFALL] = _("WATERFALL"),
[MOVE_CLAMP] = _("CLAMP"),
[MOVE_SWIFT] = _("SWIFT"),
[MOVE_SKULL_BASH] = _("SKULL BASH"),
[MOVE_SPIKE_CANNON] = _("SPIKE CANNON"),
[MOVE_CONSTRICT] = _("CONSTRICT"),
[MOVE_AMNESIA] = _("AMNESIA"),
[MOVE_KINESIS] = _("KINESIS"),
[MOVE_SOFT_BOILED] = _("SOFTBOILED"),
[MOVE_HI_JUMP_KICK] = _("HI JUMP KICK"),
[MOVE_GLARE] = _("GLARE"),
[MOVE_DREAM_EATER] = _("DREAM EATER"),
[MOVE_POISON_GAS] = _("POISON GAS"),
[MOVE_BARRAGE] = _("BARRAGE"),
[MOVE_LEECH_LIFE] = _("LEECH LIFE"),
[MOVE_LOVELY_KISS] = _("LOVELY KISS"),
[MOVE_SKY_ATTACK] = _("SKY ATTACK"),
[MOVE_TRANSFORM] = _("TRANSFORM"),
[MOVE_BUBBLE] = _("BUBBLE"),
[MOVE_DIZZY_PUNCH] = _("DIZZY PUNCH"),
[MOVE_SPORE] = _("SPORE"),
[MOVE_FLASH] = _("FLASH"),
[MOVE_PSYWAVE] = _("PSYWAVE"),
[MOVE_SPLASH] = _("SPLASH"),
[MOVE_ACID_ARMOR] = _("ACID ARMOR"),
[MOVE_CRABHAMMER] = _("CRABHAMMER"),
[MOVE_EXPLOSION] = _("EXPLOSION"),
[MOVE_FURY_SWIPES] = _("FURY SWIPES"),
[MOVE_BONEMERANG] = _("BONEMERANG"),
[MOVE_REST] = _("REST"),
[MOVE_ROCK_SLIDE] = _("ROCK SLIDE"),
[MOVE_HYPER_FANG] = _("HYPER FANG"),
[MOVE_SHARPEN] = _("SHARPEN"),
[MOVE_CONVERSION] = _("CONVERSION"),
[MOVE_TRI_ATTACK] = _("TRI ATTACK"),
[MOVE_SUPER_FANG] = _("SUPER FANG"),
[MOVE_SLASH] = _("SLASH"),
[MOVE_SUBSTITUTE] = _("SUBSTITUTE"),
[MOVE_STRUGGLE] = _("STRUGGLE"),
[MOVE_SKETCH] = _("SKETCH"),
[MOVE_TRIPLE_KICK] = _("TRIPLE KICK"),
[MOVE_THIEF] = _("THIEF"),
[MOVE_SPIDER_WEB] = _("SPIDER WEB"),
[MOVE_MIND_READER] = _("MIND READER"),
[MOVE_NIGHTMARE] = _("NIGHTMARE"),
[MOVE_FLAME_WHEEL] = _("FLAME WHEEL"),
[MOVE_SNORE] = _("SNORE"),
[MOVE_CURSE] = _("CURSE"),
[MOVE_FLAIL] = _("FLAIL"),
[MOVE_CONVERSION_2] = _("CONVERSION 2"),
[MOVE_AEROBLAST] = _("AEROBLAST"),
[MOVE_COTTON_SPORE] = _("COTTON SPORE"),
[MOVE_REVERSAL] = _("REVERSAL"),
[MOVE_SPITE] = _("SPITE"),
[MOVE_POWDER_SNOW] = _("POWDER SNOW"),
[MOVE_PROTECT] = _("PROTECT"),
[MOVE_MACH_PUNCH] = _("MACH PUNCH"),
[MOVE_SCARY_FACE] = _("SCARY FACE"),
[MOVE_FAINT_ATTACK] = _("FAINT ATTACK"),
[MOVE_SWEET_KISS] = _("SWEET KISS"),
[MOVE_BELLY_DRUM] = _("BELLY DRUM"),
[MOVE_SLUDGE_BOMB] = _("SLUDGE BOMB"),
[MOVE_MUD_SLAP] = _("MUD-SLAP"),
[MOVE_OCTAZOOKA] = _("OCTAZOOKA"),
[MOVE_SPIKES] = _("SPIKES"),
[MOVE_ZAP_CANNON] = _("ZAP CANNON"),
[MOVE_FORESIGHT] = _("FORESIGHT"),
[MOVE_DESTINY_BOND] = _("DESTINY BOND"),
[MOVE_PERISH_SONG] = _("PERISH SONG"),
[MOVE_ICY_WIND] = _("ICY WIND"),
[MOVE_DETECT] = _("DETECT"),
[MOVE_BONE_RUSH] = _("BONE RUSH"),
[MOVE_LOCK_ON] = _("LOCK-ON"),
[MOVE_OUTRAGE] = _("OUTRAGE"),
[MOVE_SANDSTORM] = _("SANDSTORM"),
[MOVE_GIGA_DRAIN] = _("GIGA DRAIN"),
[MOVE_ENDURE] = _("ENDURE"),
[MOVE_CHARM] = _("CHARM"),
[MOVE_ROLLOUT] = _("ROLLOUT"),
[MOVE_FALSE_SWIPE] = _("FALSE SWIPE"),
[MOVE_SWAGGER] = _("SWAGGER"),
[MOVE_MILK_DRINK] = _("MILK DRINK"),
[MOVE_SPARK] = _("SPARK"),
[MOVE_FURY_CUTTER] = _("FURY CUTTER"),
[MOVE_STEEL_WING] = _("STEEL WING"),
[MOVE_MEAN_LOOK] = _("MEAN LOOK"),
[MOVE_ATTRACT] = _("ATTRACT"),
[MOVE_SLEEP_TALK] = _("SLEEP TALK"),
[MOVE_HEAL_BELL] = _("HEAL BELL"),
[MOVE_RETURN] = _("RETURN"),
[MOVE_PRESENT] = _("PRESENT"),
[MOVE_FRUSTRATION] = _("FRUSTRATION"),
[MOVE_SAFEGUARD] = _("SAFEGUARD"),
[MOVE_PAIN_SPLIT] = _("PAIN SPLIT"),
[MOVE_SACRED_FIRE] = _("SACRED FIRE"),
[MOVE_MAGNITUDE] = _("MAGNITUDE"),
[MOVE_DYNAMIC_PUNCH] = _("DYNAMICPUNCH"),
[MOVE_MEGAHORN] = _("MEGAHORN"),
[MOVE_DRAGON_BREATH] = _("DRAGONBREATH"),
[MOVE_BATON_PASS] = _("BATON PASS"),
[MOVE_ENCORE] = _("ENCORE"),
[MOVE_PURSUIT] = _("PURSUIT"),
[MOVE_RAPID_SPIN] = _("RAPID SPIN"),
[MOVE_SWEET_SCENT] = _("SWEET SCENT"),
[MOVE_IRON_TAIL] = _("IRON TAIL"),
[MOVE_METAL_CLAW] = _("METAL CLAW"),
[MOVE_VITAL_THROW] = _("VITAL THROW"),
[MOVE_MORNING_SUN] = _("MORNING SUN"),
[MOVE_SYNTHESIS] = _("SYNTHESIS"),
[MOVE_MOONLIGHT] = _("MOONLIGHT"),
[MOVE_HIDDEN_POWER] = _("HIDDEN POWER"),
[MOVE_CROSS_CHOP] = _("CROSS CHOP"),
[MOVE_TWISTER] = _("TWISTER"),
[MOVE_RAIN_DANCE] = _("RAIN DANCE"),
[MOVE_SUNNY_DAY] = _("SUNNY DAY"),
[MOVE_CRUNCH] = _("CRUNCH"),
[MOVE_MIRROR_COAT] = _("MIRROR COAT"),
[MOVE_PSYCH_UP] = _("PSYCH UP"),
[MOVE_EXTREME_SPEED] = _("EXTREMESPEED"),
[MOVE_ANCIENT_POWER] = _("ANCIENTPOWER"),
[MOVE_SHADOW_BALL] = _("SHADOW BALL"),
[MOVE_FUTURE_SIGHT] = _("FUTURE SIGHT"),
[MOVE_ROCK_SMASH] = _("ROCK SMASH"),
[MOVE_WHIRLPOOL] = _("WHIRLPOOL"),
[MOVE_BEAT_UP] = _("BEAT UP"),
[MOVE_FAKE_OUT] = _("FAKE OUT"),
[MOVE_UPROAR] = _("UPROAR"),
[MOVE_STOCKPILE] = _("STOCKPILE"),
[MOVE_SPIT_UP] = _("SPIT UP"),
[MOVE_SWALLOW] = _("SWALLOW"),
[MOVE_HEAT_WAVE] = _("HEAT WAVE"),
[MOVE_HAIL] = _("HAIL"),
[MOVE_TORMENT] = _("TORMENT"),
[MOVE_FLATTER] = _("FLATTER"),
[MOVE_WILL_O_WISP] = _("WILL-O-WISP"),
[MOVE_MEMENTO] = _("MEMENTO"),
[MOVE_FACADE] = _("FACADE"),
[MOVE_FOCUS_PUNCH] = _("FOCUS PUNCH"),
[MOVE_SMELLING_SALT] = _("SMELLINGSALT"),
[MOVE_FOLLOW_ME] = _("FOLLOW ME"),
[MOVE_NATURE_POWER] = _("NATURE POWER"),
[MOVE_CHARGE] = _("CHARGE"),
[MOVE_TAUNT] = _("TAUNT"),
[MOVE_HELPING_HAND] = _("HELPING HAND"),
[MOVE_TRICK] = _("TRICK"),
[MOVE_ROLE_PLAY] = _("ROLE PLAY"),
[MOVE_WISH] = _("WISH"),
[MOVE_ASSIST] = _("ASSIST"),
[MOVE_INGRAIN] = _("INGRAIN"),
[MOVE_SUPERPOWER] = _("SUPERPOWER"),
[MOVE_MAGIC_COAT] = _("MAGIC COAT"),
[MOVE_RECYCLE] = _("RECYCLE"),
[MOVE_REVENGE] = _("REVENGE"),
[MOVE_BRICK_BREAK] = _("BRICK BREAK"),
[MOVE_YAWN] = _("YAWN"),
[MOVE_KNOCK_OFF] = _("KNOCK OFF"),
[MOVE_ENDEAVOR] = _("ENDEAVOR"),
[MOVE_ERUPTION] = _("ERUPTION"),
[MOVE_SKILL_SWAP] = _("SKILL SWAP"),
[MOVE_IMPRISON] = _("IMPRISON"),
[MOVE_REFRESH] = _("REFRESH"),
[MOVE_GRUDGE] = _("GRUDGE"),
[MOVE_SNATCH] = _("SNATCH"),
[MOVE_SECRET_POWER] = _("SECRET POWER"),
[MOVE_DIVE] = _("DIVE"),
[MOVE_ARM_THRUST] = _("ARM THRUST"),
[MOVE_CAMOUFLAGE] = _("CAMOUFLAGE"),
[MOVE_TAIL_GLOW] = _("TAIL GLOW"),
[MOVE_LUSTER_PURGE] = _("LUSTER PURGE"),
[MOVE_MIST_BALL] = _("MIST BALL"),
[MOVE_FEATHER_DANCE] = _("FEATHERDANCE"),
[MOVE_TEETER_DANCE] = _("TEETER DANCE"),
[MOVE_BLAZE_KICK] = _("BLAZE KICK"),
[MOVE_MUD_SPORT] = _("MUD SPORT"),
[MOVE_ICE_BALL] = _("ICE BALL"),
[MOVE_NEEDLE_ARM] = _("NEEDLE ARM"),
[MOVE_SLACK_OFF] = _("SLACK OFF"),
[MOVE_HYPER_VOICE] = _("HYPER VOICE"),
[MOVE_POISON_FANG] = _("POISON FANG"),
[MOVE_CRUSH_CLAW] = _("CRUSH CLAW"),
[MOVE_BLAST_BURN] = _("BLAST BURN"),
[MOVE_HYDRO_CANNON] = _("HYDRO CANNON"),
[MOVE_METEOR_MASH] = _("METEOR MASH"),
[MOVE_ASTONISH] = _("ASTONISH"),
[MOVE_WEATHER_BALL] = _("WEATHER BALL"),
[MOVE_AROMATHERAPY] = _("AROMATHERAPY"),
[MOVE_FAKE_TEARS] = _("FAKE TEARS"),
[MOVE_AIR_CUTTER] = _("AIR CUTTER"),
[MOVE_OVERHEAT] = _("OVERHEAT"),
[MOVE_ODOR_SLEUTH] = _("ODOR SLEUTH"),
[MOVE_ROCK_TOMB] = _("ROCK TOMB"),
[MOVE_SILVER_WIND] = _("SILVER WIND"),
[MOVE_METAL_SOUND] = _("METAL SOUND"),
[MOVE_GRASS_WHISTLE] = _("GRASSWHISTLE"),
[MOVE_TICKLE] = _("TICKLE"),
[MOVE_COSMIC_POWER] = _("COSMIC POWER"),
[MOVE_WATER_SPOUT] = _("WATER SPOUT"),
[MOVE_SIGNAL_BEAM] = _("SIGNAL BEAM"),
[MOVE_SHADOW_PUNCH] = _("SHADOW PUNCH"),
[MOVE_EXTRASENSORY] = _("EXTRASENSORY"),
[MOVE_SKY_UPPERCUT] = _("SKY UPPERCUT"),
[MOVE_SAND_TOMB] = _("SAND TOMB"),
[MOVE_SHEER_COLD] = _("SHEER COLD"),
[MOVE_MUDDY_WATER] = _("MUDDY WATER"),
[MOVE_BULLET_SEED] = _("BULLET SEED"),
[MOVE_AERIAL_ACE] = _("AERIAL ACE"),
[MOVE_ICICLE_SPEAR] = _("ICICLE SPEAR"),
[MOVE_IRON_DEFENSE] = _("IRON DEFENSE"),
[MOVE_BLOCK] = _("BLOCK"),
[MOVE_HOWL] = _("HOWL"),
[MOVE_DRAGON_CLAW] = _("DRAGON CLAW"),
[MOVE_FRENZY_PLANT] = _("FRENZY PLANT"),
[MOVE_BULK_UP] = _("BULK UP"),
[MOVE_BOUNCE] = _("BOUNCE"),
[MOVE_MUD_SHOT] = _("MUD SHOT"),
[MOVE_POISON_TAIL] = _("POISON TAIL"),
[MOVE_COVET] = _("COVET"),
[MOVE_VOLT_TACKLE] = _("VOLT TACKLE"),
[MOVE_MAGICAL_LEAF] = _("MAGICAL LEAF"),
[MOVE_WATER_SPORT] = _("WATER SPORT"),
[MOVE_CALM_MIND] = _("CALM MIND"),
[MOVE_LEAF_BLADE] = _("LEAF BLADE"),
[MOVE_DRAGON_DANCE] = _("DRAGON DANCE"),
[MOVE_ROCK_BLAST] = _("ROCK BLAST"),
[MOVE_SHOCK_WAVE] = _("SHOCK WAVE"),
[MOVE_WATER_PULSE] = _("WATER PULSE"),
[MOVE_DOOM_DESIRE] = _("DOOM DESIRE"),
[MOVE_PSYCHO_BOOST] = _("PSYCHO BOOST"),
};
+414
View File
@@ -0,0 +1,414 @@
const u8 gSpeciesNames[][POKEMON_NAME_LENGTH + 1] = {
[SPECIES_NONE] = _("??????????"),
[SPECIES_BULBASAUR] = _("BULBASAUR"),
[SPECIES_IVYSAUR] = _("IVYSAUR"),
[SPECIES_VENUSAUR] = _("VENUSAUR"),
[SPECIES_CHARMANDER] = _("CHARMANDER"),
[SPECIES_CHARMELEON] = _("CHARMELEON"),
[SPECIES_CHARIZARD] = _("CHARIZARD"),
[SPECIES_SQUIRTLE] = _("SQUIRTLE"),
[SPECIES_WARTORTLE] = _("WARTORTLE"),
[SPECIES_BLASTOISE] = _("BLASTOISE"),
[SPECIES_CATERPIE] = _("CATERPIE"),
[SPECIES_METAPOD] = _("METAPOD"),
[SPECIES_BUTTERFREE] = _("BUTTERFREE"),
[SPECIES_WEEDLE] = _("WEEDLE"),
[SPECIES_KAKUNA] = _("KAKUNA"),
[SPECIES_BEEDRILL] = _("BEEDRILL"),
[SPECIES_PIDGEY] = _("PIDGEY"),
[SPECIES_PIDGEOTTO] = _("PIDGEOTTO"),
[SPECIES_PIDGEOT] = _("PIDGEOT"),
[SPECIES_RATTATA] = _("RATTATA"),
[SPECIES_RATICATE] = _("RATICATE"),
[SPECIES_SPEAROW] = _("SPEAROW"),
[SPECIES_FEAROW] = _("FEAROW"),
[SPECIES_EKANS] = _("EKANS"),
[SPECIES_ARBOK] = _("ARBOK"),
[SPECIES_PIKACHU] = _("PIKACHU"),
[SPECIES_RAICHU] = _("RAICHU"),
[SPECIES_SANDSHREW] = _("SANDSHREW"),
[SPECIES_SANDSLASH] = _("SANDSLASH"),
[SPECIES_NIDORAN_F] = _("NIDORAN♀"),
[SPECIES_NIDORINA] = _("NIDORINA"),
[SPECIES_NIDOQUEEN] = _("NIDOQUEEN"),
[SPECIES_NIDORAN_M] = _("NIDORAN♂"),
[SPECIES_NIDORINO] = _("NIDORINO"),
[SPECIES_NIDOKING] = _("NIDOKING"),
[SPECIES_CLEFAIRY] = _("CLEFAIRY"),
[SPECIES_CLEFABLE] = _("CLEFABLE"),
[SPECIES_VULPIX] = _("VULPIX"),
[SPECIES_NINETALES] = _("NINETALES"),
[SPECIES_JIGGLYPUFF] = _("JIGGLYPUFF"),
[SPECIES_WIGGLYTUFF] = _("WIGGLYTUFF"),
[SPECIES_ZUBAT] = _("ZUBAT"),
[SPECIES_GOLBAT] = _("GOLBAT"),
[SPECIES_ODDISH] = _("ODDISH"),
[SPECIES_GLOOM] = _("GLOOM"),
[SPECIES_VILEPLUME] = _("VILEPLUME"),
[SPECIES_PARAS] = _("PARAS"),
[SPECIES_PARASECT] = _("PARASECT"),
[SPECIES_VENONAT] = _("VENONAT"),
[SPECIES_VENOMOTH] = _("VENOMOTH"),
[SPECIES_DIGLETT] = _("DIGLETT"),
[SPECIES_DUGTRIO] = _("DUGTRIO"),
[SPECIES_MEOWTH] = _("MEOWTH"),
[SPECIES_PERSIAN] = _("PERSIAN"),
[SPECIES_PSYDUCK] = _("PSYDUCK"),
[SPECIES_GOLDUCK] = _("GOLDUCK"),
[SPECIES_MANKEY] = _("MANKEY"),
[SPECIES_PRIMEAPE] = _("PRIMEAPE"),
[SPECIES_GROWLITHE] = _("GROWLITHE"),
[SPECIES_ARCANINE] = _("ARCANINE"),
[SPECIES_POLIWAG] = _("POLIWAG"),
[SPECIES_POLIWHIRL] = _("POLIWHIRL"),
[SPECIES_POLIWRATH] = _("POLIWRATH"),
[SPECIES_ABRA] = _("ABRA"),
[SPECIES_KADABRA] = _("KADABRA"),
[SPECIES_ALAKAZAM] = _("ALAKAZAM"),
[SPECIES_MACHOP] = _("MACHOP"),
[SPECIES_MACHOKE] = _("MACHOKE"),
[SPECIES_MACHAMP] = _("MACHAMP"),
[SPECIES_BELLSPROUT] = _("BELLSPROUT"),
[SPECIES_WEEPINBELL] = _("WEEPINBELL"),
[SPECIES_VICTREEBEL] = _("VICTREEBEL"),
[SPECIES_TENTACOOL] = _("TENTACOOL"),
[SPECIES_TENTACRUEL] = _("TENTACRUEL"),
[SPECIES_GEODUDE] = _("GEODUDE"),
[SPECIES_GRAVELER] = _("GRAVELER"),
[SPECIES_GOLEM] = _("GOLEM"),
[SPECIES_PONYTA] = _("PONYTA"),
[SPECIES_RAPIDASH] = _("RAPIDASH"),
[SPECIES_SLOWPOKE] = _("SLOWPOKE"),
[SPECIES_SLOWBRO] = _("SLOWBRO"),
[SPECIES_MAGNEMITE] = _("MAGNEMITE"),
[SPECIES_MAGNETON] = _("MAGNETON"),
[SPECIES_FARFETCHD] = _("FARFETCHD"),
[SPECIES_DODUO] = _("DODUO"),
[SPECIES_DODRIO] = _("DODRIO"),
[SPECIES_SEEL] = _("SEEL"),
[SPECIES_DEWGONG] = _("DEWGONG"),
[SPECIES_GRIMER] = _("GRIMER"),
[SPECIES_MUK] = _("MUK"),
[SPECIES_SHELLDER] = _("SHELLDER"),
[SPECIES_CLOYSTER] = _("CLOYSTER"),
[SPECIES_GASTLY] = _("GASTLY"),
[SPECIES_HAUNTER] = _("HAUNTER"),
[SPECIES_GENGAR] = _("GENGAR"),
[SPECIES_ONIX] = _("ONIX"),
[SPECIES_DROWZEE] = _("DROWZEE"),
[SPECIES_HYPNO] = _("HYPNO"),
[SPECIES_KRABBY] = _("KRABBY"),
[SPECIES_KINGLER] = _("KINGLER"),
[SPECIES_VOLTORB] = _("VOLTORB"),
[SPECIES_ELECTRODE] = _("ELECTRODE"),
[SPECIES_EXEGGCUTE] = _("EXEGGCUTE"),
[SPECIES_EXEGGUTOR] = _("EXEGGUTOR"),
[SPECIES_CUBONE] = _("CUBONE"),
[SPECIES_MAROWAK] = _("MAROWAK"),
[SPECIES_HITMONLEE] = _("HITMONLEE"),
[SPECIES_HITMONCHAN] = _("HITMONCHAN"),
[SPECIES_LICKITUNG] = _("LICKITUNG"),
[SPECIES_KOFFING] = _("KOFFING"),
[SPECIES_WEEZING] = _("WEEZING"),
[SPECIES_RHYHORN] = _("RHYHORN"),
[SPECIES_RHYDON] = _("RHYDON"),
[SPECIES_CHANSEY] = _("CHANSEY"),
[SPECIES_TANGELA] = _("TANGELA"),
[SPECIES_KANGASKHAN] = _("KANGASKHAN"),
[SPECIES_HORSEA] = _("HORSEA"),
[SPECIES_SEADRA] = _("SEADRA"),
[SPECIES_GOLDEEN] = _("GOLDEEN"),
[SPECIES_SEAKING] = _("SEAKING"),
[SPECIES_STARYU] = _("STARYU"),
[SPECIES_STARMIE] = _("STARMIE"),
[SPECIES_MR_MIME] = _("MR. MIME"),
[SPECIES_SCYTHER] = _("SCYTHER"),
[SPECIES_JYNX] = _("JYNX"),
[SPECIES_ELECTABUZZ] = _("ELECTABUZZ"),
[SPECIES_MAGMAR] = _("MAGMAR"),
[SPECIES_PINSIR] = _("PINSIR"),
[SPECIES_TAUROS] = _("TAUROS"),
[SPECIES_MAGIKARP] = _("MAGIKARP"),
[SPECIES_GYARADOS] = _("GYARADOS"),
[SPECIES_LAPRAS] = _("LAPRAS"),
[SPECIES_DITTO] = _("DITTO"),
[SPECIES_EEVEE] = _("EEVEE"),
[SPECIES_VAPOREON] = _("VAPOREON"),
[SPECIES_JOLTEON] = _("JOLTEON"),
[SPECIES_FLAREON] = _("FLAREON"),
[SPECIES_PORYGON] = _("PORYGON"),
[SPECIES_OMANYTE] = _("OMANYTE"),
[SPECIES_OMASTAR] = _("OMASTAR"),
[SPECIES_KABUTO] = _("KABUTO"),
[SPECIES_KABUTOPS] = _("KABUTOPS"),
[SPECIES_AERODACTYL] = _("AERODACTYL"),
[SPECIES_SNORLAX] = _("SNORLAX"),
[SPECIES_ARTICUNO] = _("ARTICUNO"),
[SPECIES_ZAPDOS] = _("ZAPDOS"),
[SPECIES_MOLTRES] = _("MOLTRES"),
[SPECIES_DRATINI] = _("DRATINI"),
[SPECIES_DRAGONAIR] = _("DRAGONAIR"),
[SPECIES_DRAGONITE] = _("DRAGONITE"),
[SPECIES_MEWTWO] = _("MEWTWO"),
[SPECIES_MEW] = _("MEW"),
[SPECIES_CHIKORITA] = _("CHIKORITA"),
[SPECIES_BAYLEEF] = _("BAYLEEF"),
[SPECIES_MEGANIUM] = _("MEGANIUM"),
[SPECIES_CYNDAQUIL] = _("CYNDAQUIL"),
[SPECIES_QUILAVA] = _("QUILAVA"),
[SPECIES_TYPHLOSION] = _("TYPHLOSION"),
[SPECIES_TOTODILE] = _("TOTODILE"),
[SPECIES_CROCONAW] = _("CROCONAW"),
[SPECIES_FERALIGATR] = _("FERALIGATR"),
[SPECIES_SENTRET] = _("SENTRET"),
[SPECIES_FURRET] = _("FURRET"),
[SPECIES_HOOTHOOT] = _("HOOTHOOT"),
[SPECIES_NOCTOWL] = _("NOCTOWL"),
[SPECIES_LEDYBA] = _("LEDYBA"),
[SPECIES_LEDIAN] = _("LEDIAN"),
[SPECIES_SPINARAK] = _("SPINARAK"),
[SPECIES_ARIADOS] = _("ARIADOS"),
[SPECIES_CROBAT] = _("CROBAT"),
[SPECIES_CHINCHOU] = _("CHINCHOU"),
[SPECIES_LANTURN] = _("LANTURN"),
[SPECIES_PICHU] = _("PICHU"),
[SPECIES_CLEFFA] = _("CLEFFA"),
[SPECIES_IGGLYBUFF] = _("IGGLYBUFF"),
[SPECIES_TOGEPI] = _("TOGEPI"),
[SPECIES_TOGETIC] = _("TOGETIC"),
[SPECIES_NATU] = _("NATU"),
[SPECIES_XATU] = _("XATU"),
[SPECIES_MAREEP] = _("MAREEP"),
[SPECIES_FLAAFFY] = _("FLAAFFY"),
[SPECIES_AMPHAROS] = _("AMPHAROS"),
[SPECIES_BELLOSSOM] = _("BELLOSSOM"),
[SPECIES_MARILL] = _("MARILL"),
[SPECIES_AZUMARILL] = _("AZUMARILL"),
[SPECIES_SUDOWOODO] = _("SUDOWOODO"),
[SPECIES_POLITOED] = _("POLITOED"),
[SPECIES_HOPPIP] = _("HOPPIP"),
[SPECIES_SKIPLOOM] = _("SKIPLOOM"),
[SPECIES_JUMPLUFF] = _("JUMPLUFF"),
[SPECIES_AIPOM] = _("AIPOM"),
[SPECIES_SUNKERN] = _("SUNKERN"),
[SPECIES_SUNFLORA] = _("SUNFLORA"),
[SPECIES_YANMA] = _("YANMA"),
[SPECIES_WOOPER] = _("WOOPER"),
[SPECIES_QUAGSIRE] = _("QUAGSIRE"),
[SPECIES_ESPEON] = _("ESPEON"),
[SPECIES_UMBREON] = _("UMBREON"),
[SPECIES_MURKROW] = _("MURKROW"),
[SPECIES_SLOWKING] = _("SLOWKING"),
[SPECIES_MISDREAVUS] = _("MISDREAVUS"),
[SPECIES_UNOWN] = _("UNOWN"),
[SPECIES_WOBBUFFET] = _("WOBBUFFET"),
[SPECIES_GIRAFARIG] = _("GIRAFARIG"),
[SPECIES_PINECO] = _("PINECO"),
[SPECIES_FORRETRESS] = _("FORRETRESS"),
[SPECIES_DUNSPARCE] = _("DUNSPARCE"),
[SPECIES_GLIGAR] = _("GLIGAR"),
[SPECIES_STEELIX] = _("STEELIX"),
[SPECIES_SNUBBULL] = _("SNUBBULL"),
[SPECIES_GRANBULL] = _("GRANBULL"),
[SPECIES_QWILFISH] = _("QWILFISH"),
[SPECIES_SCIZOR] = _("SCIZOR"),
[SPECIES_SHUCKLE] = _("SHUCKLE"),
[SPECIES_HERACROSS] = _("HERACROSS"),
[SPECIES_SNEASEL] = _("SNEASEL"),
[SPECIES_TEDDIURSA] = _("TEDDIURSA"),
[SPECIES_URSARING] = _("URSARING"),
[SPECIES_SLUGMA] = _("SLUGMA"),
[SPECIES_MAGCARGO] = _("MAGCARGO"),
[SPECIES_SWINUB] = _("SWINUB"),
[SPECIES_PILOSWINE] = _("PILOSWINE"),
[SPECIES_CORSOLA] = _("CORSOLA"),
[SPECIES_REMORAID] = _("REMORAID"),
[SPECIES_OCTILLERY] = _("OCTILLERY"),
[SPECIES_DELIBIRD] = _("DELIBIRD"),
[SPECIES_MANTINE] = _("MANTINE"),
[SPECIES_SKARMORY] = _("SKARMORY"),
[SPECIES_HOUNDOUR] = _("HOUNDOUR"),
[SPECIES_HOUNDOOM] = _("HOUNDOOM"),
[SPECIES_KINGDRA] = _("KINGDRA"),
[SPECIES_PHANPY] = _("PHANPY"),
[SPECIES_DONPHAN] = _("DONPHAN"),
[SPECIES_PORYGON2] = _("PORYGON2"),
[SPECIES_STANTLER] = _("STANTLER"),
[SPECIES_SMEARGLE] = _("SMEARGLE"),
[SPECIES_TYROGUE] = _("TYROGUE"),
[SPECIES_HITMONTOP] = _("HITMONTOP"),
[SPECIES_SMOOCHUM] = _("SMOOCHUM"),
[SPECIES_ELEKID] = _("ELEKID"),
[SPECIES_MAGBY] = _("MAGBY"),
[SPECIES_MILTANK] = _("MILTANK"),
[SPECIES_BLISSEY] = _("BLISSEY"),
[SPECIES_RAIKOU] = _("RAIKOU"),
[SPECIES_ENTEI] = _("ENTEI"),
[SPECIES_SUICUNE] = _("SUICUNE"),
[SPECIES_LARVITAR] = _("LARVITAR"),
[SPECIES_PUPITAR] = _("PUPITAR"),
[SPECIES_TYRANITAR] = _("TYRANITAR"),
[SPECIES_LUGIA] = _("LUGIA"),
[SPECIES_HO_OH] = _("HO-OH"),
[SPECIES_CELEBI] = _("CELEBI"),
[SPECIES_OLD_UNOWN_B] = _("?"),
[SPECIES_OLD_UNOWN_C] = _("?"),
[SPECIES_OLD_UNOWN_D] = _("?"),
[SPECIES_OLD_UNOWN_E] = _("?"),
[SPECIES_OLD_UNOWN_F] = _("?"),
[SPECIES_OLD_UNOWN_G] = _("?"),
[SPECIES_OLD_UNOWN_H] = _("?"),
[SPECIES_OLD_UNOWN_I] = _("?"),
[SPECIES_OLD_UNOWN_J] = _("?"),
[SPECIES_OLD_UNOWN_K] = _("?"),
[SPECIES_OLD_UNOWN_L] = _("?"),
[SPECIES_OLD_UNOWN_M] = _("?"),
[SPECIES_OLD_UNOWN_N] = _("?"),
[SPECIES_OLD_UNOWN_O] = _("?"),
[SPECIES_OLD_UNOWN_P] = _("?"),
[SPECIES_OLD_UNOWN_Q] = _("?"),
[SPECIES_OLD_UNOWN_R] = _("?"),
[SPECIES_OLD_UNOWN_S] = _("?"),
[SPECIES_OLD_UNOWN_T] = _("?"),
[SPECIES_OLD_UNOWN_U] = _("?"),
[SPECIES_OLD_UNOWN_V] = _("?"),
[SPECIES_OLD_UNOWN_W] = _("?"),
[SPECIES_OLD_UNOWN_X] = _("?"),
[SPECIES_OLD_UNOWN_Y] = _("?"),
[SPECIES_OLD_UNOWN_Z] = _("?"),
[SPECIES_TREECKO] = _("TREECKO"),
[SPECIES_GROVYLE] = _("GROVYLE"),
[SPECIES_SCEPTILE] = _("SCEPTILE"),
[SPECIES_TORCHIC] = _("TORCHIC"),
[SPECIES_COMBUSKEN] = _("COMBUSKEN"),
[SPECIES_BLAZIKEN] = _("BLAZIKEN"),
[SPECIES_MUDKIP] = _("MUDKIP"),
[SPECIES_MARSHTOMP] = _("MARSHTOMP"),
[SPECIES_SWAMPERT] = _("SWAMPERT"),
[SPECIES_POOCHYENA] = _("POOCHYENA"),
[SPECIES_MIGHTYENA] = _("MIGHTYENA"),
[SPECIES_ZIGZAGOON] = _("ZIGZAGOON"),
[SPECIES_LINOONE] = _("LINOONE"),
[SPECIES_WURMPLE] = _("WURMPLE"),
[SPECIES_SILCOON] = _("SILCOON"),
[SPECIES_BEAUTIFLY] = _("BEAUTIFLY"),
[SPECIES_CASCOON] = _("CASCOON"),
[SPECIES_DUSTOX] = _("DUSTOX"),
[SPECIES_LOTAD] = _("LOTAD"),
[SPECIES_LOMBRE] = _("LOMBRE"),
[SPECIES_LUDICOLO] = _("LUDICOLO"),
[SPECIES_SEEDOT] = _("SEEDOT"),
[SPECIES_NUZLEAF] = _("NUZLEAF"),
[SPECIES_SHIFTRY] = _("SHIFTRY"),
[SPECIES_NINCADA] = _("NINCADA"),
[SPECIES_NINJASK] = _("NINJASK"),
[SPECIES_SHEDINJA] = _("SHEDINJA"),
[SPECIES_TAILLOW] = _("TAILLOW"),
[SPECIES_SWELLOW] = _("SWELLOW"),
[SPECIES_SHROOMISH] = _("SHROOMISH"),
[SPECIES_BRELOOM] = _("BRELOOM"),
[SPECIES_SPINDA] = _("SPINDA"),
[SPECIES_WINGULL] = _("WINGULL"),
[SPECIES_PELIPPER] = _("PELIPPER"),
[SPECIES_SURSKIT] = _("SURSKIT"),
[SPECIES_MASQUERAIN] = _("MASQUERAIN"),
[SPECIES_WAILMER] = _("WAILMER"),
[SPECIES_WAILORD] = _("WAILORD"),
[SPECIES_SKITTY] = _("SKITTY"),
[SPECIES_DELCATTY] = _("DELCATTY"),
[SPECIES_KECLEON] = _("KECLEON"),
[SPECIES_BALTOY] = _("BALTOY"),
[SPECIES_CLAYDOL] = _("CLAYDOL"),
[SPECIES_NOSEPASS] = _("NOSEPASS"),
[SPECIES_TORKOAL] = _("TORKOAL"),
[SPECIES_SABLEYE] = _("SABLEYE"),
[SPECIES_BARBOACH] = _("BARBOACH"),
[SPECIES_WHISCASH] = _("WHISCASH"),
[SPECIES_LUVDISC] = _("LUVDISC"),
[SPECIES_CORPHISH] = _("CORPHISH"),
[SPECIES_CRAWDAUNT] = _("CRAWDAUNT"),
[SPECIES_FEEBAS] = _("FEEBAS"),
[SPECIES_MILOTIC] = _("MILOTIC"),
[SPECIES_CARVANHA] = _("CARVANHA"),
[SPECIES_SHARPEDO] = _("SHARPEDO"),
[SPECIES_TRAPINCH] = _("TRAPINCH"),
[SPECIES_VIBRAVA] = _("VIBRAVA"),
[SPECIES_FLYGON] = _("FLYGON"),
[SPECIES_MAKUHITA] = _("MAKUHITA"),
[SPECIES_HARIYAMA] = _("HARIYAMA"),
[SPECIES_ELECTRIKE] = _("ELECTRIKE"),
[SPECIES_MANECTRIC] = _("MANECTRIC"),
[SPECIES_NUMEL] = _("NUMEL"),
[SPECIES_CAMERUPT] = _("CAMERUPT"),
[SPECIES_SPHEAL] = _("SPHEAL"),
[SPECIES_SEALEO] = _("SEALEO"),
[SPECIES_WALREIN] = _("WALREIN"),
[SPECIES_CACNEA] = _("CACNEA"),
[SPECIES_CACTURNE] = _("CACTURNE"),
[SPECIES_SNORUNT] = _("SNORUNT"),
[SPECIES_GLALIE] = _("GLALIE"),
[SPECIES_LUNATONE] = _("LUNATONE"),
[SPECIES_SOLROCK] = _("SOLROCK"),
[SPECIES_AZURILL] = _("AZURILL"),
[SPECIES_SPOINK] = _("SPOINK"),
[SPECIES_GRUMPIG] = _("GRUMPIG"),
[SPECIES_PLUSLE] = _("PLUSLE"),
[SPECIES_MINUN] = _("MINUN"),
[SPECIES_MAWILE] = _("MAWILE"),
[SPECIES_MEDITITE] = _("MEDITITE"),
[SPECIES_MEDICHAM] = _("MEDICHAM"),
[SPECIES_SWABLU] = _("SWABLU"),
[SPECIES_ALTARIA] = _("ALTARIA"),
[SPECIES_WYNAUT] = _("WYNAUT"),
[SPECIES_DUSKULL] = _("DUSKULL"),
[SPECIES_DUSCLOPS] = _("DUSCLOPS"),
[SPECIES_ROSELIA] = _("ROSELIA"),
[SPECIES_SLAKOTH] = _("SLAKOTH"),
[SPECIES_VIGOROTH] = _("VIGOROTH"),
[SPECIES_SLAKING] = _("SLAKING"),
[SPECIES_GULPIN] = _("GULPIN"),
[SPECIES_SWALOT] = _("SWALOT"),
[SPECIES_TROPIUS] = _("TROPIUS"),
[SPECIES_WHISMUR] = _("WHISMUR"),
[SPECIES_LOUDRED] = _("LOUDRED"),
[SPECIES_EXPLOUD] = _("EXPLOUD"),
[SPECIES_CLAMPERL] = _("CLAMPERL"),
[SPECIES_HUNTAIL] = _("HUNTAIL"),
[SPECIES_GOREBYSS] = _("GOREBYSS"),
[SPECIES_ABSOL] = _("ABSOL"),
[SPECIES_SHUPPET] = _("SHUPPET"),
[SPECIES_BANETTE] = _("BANETTE"),
[SPECIES_SEVIPER] = _("SEVIPER"),
[SPECIES_ZANGOOSE] = _("ZANGOOSE"),
[SPECIES_RELICANTH] = _("RELICANTH"),
[SPECIES_ARON] = _("ARON"),
[SPECIES_LAIRON] = _("LAIRON"),
[SPECIES_AGGRON] = _("AGGRON"),
[SPECIES_CASTFORM] = _("CASTFORM"),
[SPECIES_VOLBEAT] = _("VOLBEAT"),
[SPECIES_ILLUMISE] = _("ILLUMISE"),
[SPECIES_LILEEP] = _("LILEEP"),
[SPECIES_CRADILY] = _("CRADILY"),
[SPECIES_ANORITH] = _("ANORITH"),
[SPECIES_ARMALDO] = _("ARMALDO"),
[SPECIES_RALTS] = _("RALTS"),
[SPECIES_KIRLIA] = _("KIRLIA"),
[SPECIES_GARDEVOIR] = _("GARDEVOIR"),
[SPECIES_BAGON] = _("BAGON"),
[SPECIES_SHELGON] = _("SHELGON"),
[SPECIES_SALAMENCE] = _("SALAMENCE"),
[SPECIES_BELDUM] = _("BELDUM"),
[SPECIES_METANG] = _("METANG"),
[SPECIES_METAGROSS] = _("METAGROSS"),
[SPECIES_REGIROCK] = _("REGIROCK"),
[SPECIES_REGICE] = _("REGICE"),
[SPECIES_REGISTEEL] = _("REGISTEEL"),
[SPECIES_KYOGRE] = _("KYOGRE"),
[SPECIES_GROUDON] = _("GROUDON"),
[SPECIES_RAYQUAZA] = _("RAYQUAZA"),
[SPECIES_LATIAS] = _("LATIAS"),
[SPECIES_LATIOS] = _("LATIOS"),
[SPECIES_JIRACHI] = _("JIRACHI"),
[SPECIES_DEOXYS] = _("DEOXYS"),
[SPECIES_CHIMECHO] = _("CHIMECHO"),
};
+73
View File
@@ -0,0 +1,73 @@
#ifndef GUARD_TRAINER_CLASS_NAMES_H
#define GUARD_TRAINER_CLASS_NAMES_H
const u8 gTrainerClassNames[][13] = {
_("{PKMN} TRAINER"),
_("{PKMN} TRAINER"),
_("HIKER"),
_("TEAM AQUA"),
_("{PKMN} BREEDER"),
_("COOLTRAINER"),
_("BIRD KEEPER"),
_("COLLECTOR"),
_("SWIMMER♂"),
_("TEAM MAGMA"),
_("EXPERT"),
_("AQUA ADMIN"),
_("BLACK BELT"),
_("AQUA LEADER"),
_("HEX MANIAC"),
_("AROMA LADY"),
_("RUIN MANIAC"),
_("INTERVIEWER"),
_("TUBER"),
_("TUBER"),
_("LADY"),
_("BEAUTY"),
_("RICH BOY"),
_("POKéMANIAC"),
_("GUITARIST"),
_("KINDLER"),
_("CAMPER"),
_("PICNICKER"),
_("BUG MANIAC"),
_("PSYCHIC"),
_("GENTLEMAN"),
_("ELITE FOUR"),
_("LEADER"),
_("SCHOOL KID"),
_("SR. AND JR."),
_("WINSTRATE"),
_("POKéFAN"),
_("YOUNGSTER"),
_("CHAMPION"),
_("FISHERMAN"),
_("TRIATHLETE"),
_("DRAGON TAMER"),
_("NINJA BOY"),
_("BATTLE GIRL"),
_("PARASOL LADY"),
_("SWIMMER♀"),
_("TWINS"),
_("SAILOR"),
_("COOLTRAINER"),
_("MAGMA ADMIN"),
_("{PKMN} TRAINER"),
_("BUG CATCHER"),
_("{PKMN} RANGER"),
_("MAGMA LEADER"),
_("LASS"),
_("YOUNG COUPLE"),
_("OLD COUPLE"),
_("SIS AND BRO"),
_("SALON MAIDEN"),
_("DOME ACE"),
_("PALACE MAVEN"),
_("ARENA TYCOON"),
_("FACTORY HEAD"),
_("PIKE QUEEN"),
_("PYRAMID KING"),
_("{PKMN} TRAINER"),
};
#endif
File diff suppressed because it is too large Load Diff
+11971
View File
File diff suppressed because it is too large Load Diff
@@ -1,11 +1,11 @@
#include "global.h"
#include "text.h"
#include "unk_text_util.h"
#include "dynamic_placeholder_text_util.h"
#include "string_util.h"
static EWRAM_DATA const u8 *sStringPointers[8] = {};
void UnkTextUtil_Reset(void)
void DynamicPlaceholderTextUtil_Reset(void)
{
const u8 **ptr;
u8 *fillval;
@@ -20,7 +20,7 @@ void UnkTextUtil_Reset(void)
} while ((int)ptr2 >= (int)ptr);
}
void UnkTextUtil_SetPtrI(u8 idx, const u8 *ptr)
void DynamicPlaceholderTextUtil_SetPlaceholderPtr(u8 idx, const u8 *ptr)
{
if (idx < ARRAY_COUNT(sStringPointers))
{
@@ -28,7 +28,7 @@ void UnkTextUtil_SetPtrI(u8 idx, const u8 *ptr)
}
}
u8 *UnkTextUtil_StringExpandPlaceholders(u8 *dest, const u8 *src)
u8 *DynamicPlaceholderTextUtil_ExpandPlaceholders(u8 *dest, const u8 *src)
{
while (*src != EOS)
{
@@ -50,7 +50,7 @@ u8 *UnkTextUtil_StringExpandPlaceholders(u8 *dest, const u8 *src)
return dest;
}
const u8 *UnkTextUtil_GetPtrI(u8 idx)
const u8 *DynamicPlaceholderTextUtil_GetPlaceholderPtr(u8 idx)
{
return sStringPointers[idx];
}
+1 -1
View File
@@ -631,7 +631,7 @@ static void CB2_EggHatch_1(void)
GetMonNick(&gPlayerParty[sEggHatchData->eggPartyID], gStringVar1);
StringExpandPlaceholders(gStringVar4, gText_HatchedFromEgg);
EggHatchPrintMessage(sEggHatchData->windowId, gStringVar4, 0, 3, 0xFF);
PlayFanfare(371);
PlayFanfare(MUS_FANFA5);
sEggHatchData->CB2_state++;
PutWindowTilemap(sEggHatchData->windowId);
CopyWindowToVram(sEggHatchData->windowId, 3);
+1 -1
View File
@@ -63,7 +63,7 @@ static const struct WindowTemplate gUnknown_085E5070[] = {
// .text
void sub_817018C(MainCallback callback)
void FieldInitRegionMap(MainCallback callback)
{
SetVBlankCallback(NULL);
sFieldRegionMapHandler = malloc(sizeof(*sFieldRegionMapHandler));
+1 -1
View File
@@ -272,7 +272,7 @@ bool8 sub_80FB59C(void)
void Task_HandlePorthole(u8 taskId)
{
s16 *data = gTasks[taskId].data;
u16 *var = GetVarPointer(VAR_PORTHOLE);
u16 *var = GetVarPointer(VAR_PORTHOLE_STATE);
struct WarpData *location = &gSaveBlock1Ptr->location;
switch (data[0])
+4329
View File
File diff suppressed because it is too large Load Diff
+14 -60
View File
@@ -1,83 +1,37 @@
// Includes
#include "global.h"
#include "constants/maps.h"
#include "heal_location.h"
#include "constants/maps.h"
#define HEAL_LOCATION(map, x, y) {MAP_GROUP(map), MAP_NUM(map), x, y}
#include "data/heal_locations.h"
// Static type declarations
// Static RAM declarations
// Static ROM declarations
// .rodata
static const struct HealLocation sHealLocations[] = {
HEAL_LOCATION(LITTLEROOT_TOWN_BRENDANS_HOUSE_2F, 4, 2),
HEAL_LOCATION(LITTLEROOT_TOWN_MAYS_HOUSE_2F, 4, 2),
HEAL_LOCATION(PETALBURG_CITY, 20, 17),
HEAL_LOCATION(SLATEPORT_CITY, 19, 20),
HEAL_LOCATION(MAUVILLE_CITY, 22, 6),
HEAL_LOCATION(RUSTBORO_CITY, 16, 39),
HEAL_LOCATION(FORTREE_CITY, 5, 7),
HEAL_LOCATION(LILYCOVE_CITY, 24, 15),
HEAL_LOCATION(MOSSDEEP_CITY, 28, 17),
HEAL_LOCATION(SOOTOPOLIS_CITY, 43, 32),
HEAL_LOCATION(EVER_GRANDE_CITY, 27, 49),
HEAL_LOCATION(LITTLEROOT_TOWN, 5, 9),
HEAL_LOCATION(LITTLEROOT_TOWN, 14, 9),
HEAL_LOCATION(OLDALE_TOWN, 6, 17),
HEAL_LOCATION(DEWFORD_TOWN, 2, 11),
HEAL_LOCATION(LAVARIDGE_TOWN, 9, 7),
HEAL_LOCATION(FALLARBOR_TOWN, 14, 8),
HEAL_LOCATION(VERDANTURF_TOWN, 16, 4),
HEAL_LOCATION(PACIFIDLOG_TOWN, 8, 16),
HEAL_LOCATION(EVER_GRANDE_CITY, 18, 6),
HEAL_LOCATION(SOUTHERN_ISLAND_EXTERIOR, 15, 20),
HEAL_LOCATION(BATTLE_FRONTIER_OUTSIDE_EAST, 3, 52)
};
#define NUM_HEAL_LOCATIONS (ARRAY_COUNT(sHealLocations))
// .text
static u32 GetHealLocationIndexFromMapGroupAndNum(u16 mapGroup, u16 mapNum)
u32 GetHealLocationIndexByMap(u16 mapGroup, u16 mapNum)
{
u32 i;
for (i = 0; i < NUM_HEAL_LOCATIONS; i++)
for (i = 0; i < ARRAY_COUNT(sHealLocations); i++)
{
if (sHealLocations[i].group == mapGroup && sHealLocations[i].map == mapNum)
{
return i + 1;
}
}
return 0;
}
const struct HealLocation *GetHealLocationPointerFromMapGroupAndNum(u16 mapGroup, u16 mapNum)
const struct HealLocation *GetHealLocationByMap(u16 mapGroup, u16 mapNum)
{
u32 loc;
u32 index = GetHealLocationIndexByMap(mapGroup, mapNum);
loc = GetHealLocationIndexFromMapGroupAndNum(mapGroup, mapNum);
if (loc == 0)
{
if (index == 0)
return NULL;
}
return &sHealLocations[loc - 1];
else
return &sHealLocations[index - 1];
}
const struct HealLocation *GetHealLocationPointer(u32 loc)
const struct HealLocation *GetHealLocation(u32 index)
{
if (loc == 0)
{
if (index == 0)
return NULL;
}
if (loc > NUM_HEAL_LOCATIONS)
{
else if (index > ARRAY_COUNT(sHealLocations))
return NULL;
}
return &sHealLocations[loc - 1];
else
return &sHealLocations[index - 1];
}
+1 -1
View File
@@ -301,7 +301,7 @@ void sub_81AABB0(void)
void CB2_ChooseBerry(void)
{
GoToBagMenu(4, 3, sub_80861B0);
GoToBagMenu(4, 3, CB2_ReturnToFieldContinueScript);
}
void sub_81AABF0(void(*callback)(void))
+1 -1
View File
@@ -304,7 +304,7 @@ void LinkTestScreen(void)
void sub_8009628(u8 a0)
{
gLocalLinkPlayer.lp_field_18 = a0;
gLocalLinkPlayer.id = a0;
}
static void InitLocalLinkPlayer(void)
+23 -23
View File
@@ -2126,7 +2126,7 @@ void sub_800DD94(struct UnkLinkRfuStruct_02022B14 *data, u8 r9, bool32 r2, int r
for (i = 0; i < 2; i++)
{
data->playerTrainerId[i] = gSaveBlock2Ptr->playerTrainerId[i];
data->unk_00.playerTrainerId[i] = gSaveBlock2Ptr->playerTrainerId[i];
}
for (i = 0; i < 4; i++)
{
@@ -2136,14 +2136,14 @@ void sub_800DD94(struct UnkLinkRfuStruct_02022B14 *data, u8 r9, bool32 r2, int r
data->playerGender = gSaveBlock2Ptr->playerGender;
data->unk_0a_0 = r9;
data->unk_0a_7 = r2;
data->unk_00_0 = 2;
data->unk_01_2 = 3;
data->unk_00_4 = 0;
data->unk_00_5 = 0;
data->unk_00_6 = 0;
data->unk_00_7 = FlagGet(FLAG_0x87F);
data->unk_01_0 = IsNationalPokedexEnabled();
data->unk_01_1 = FlagGet(FLAG_SYS_GAME_CLEAR);
data->unk_00.unk_00_0 = 2;
data->unk_00.unk_01_2 = 3;
data->unk_00.unk_00_4 = 0;
data->unk_00.unk_00_5 = 0;
data->unk_00.unk_00_6 = 0;
data->unk_00.unk_00_7 = FlagGet(FLAG_0x87F);
data->unk_00.unk_01_0 = IsNationalPokedexEnabled();
data->unk_00.unk_01_1 = FlagGet(FLAG_SYS_GAME_CLEAR);
}
bool8 sub_800DE7C(struct UnkLinkRfuStruct_02022B14 *buff1, u8 *buff2, u8 idx)
@@ -2155,12 +2155,12 @@ bool8 sub_800DE7C(struct UnkLinkRfuStruct_02022B14 *buff1, u8 *buff2, u8 idx)
retVal = TRUE;
if (sub_8010454(gUnknown_03007890->unk_14[idx].unk_04) && ((gUnknown_03007890->unk_07 >> idx) & 1))
{
memcpy(buff1, &gUnknown_03007890->unk_14[idx].unk_06, sizeof(gUnknown_03007890->unk_14[idx].unk_06));
memcpy(buff1, &gUnknown_03007890->unk_14[idx].unk_06, 0xD);
memcpy(buff2, gUnknown_03007890->unk_14[idx].unk_15, sizeof(gUnknown_03007890->unk_14[idx].unk_15));
}
else
{
memset(buff1, 0, sizeof(gUnknown_03007890->unk_14[idx].unk_06));
memset(buff1, 0, 0xD);
memset(buff2, 0, sizeof(gUnknown_03007890->unk_14[idx].unk_15));
}
}
@@ -2169,12 +2169,12 @@ bool8 sub_800DE7C(struct UnkLinkRfuStruct_02022B14 *buff1, u8 *buff2, u8 idx)
retVal = FALSE;
if (sub_8010454(gUnknown_03007890->unk_14[idx].unk_04))
{
memcpy(buff1, &gUnknown_03007890->unk_14[idx].unk_06, sizeof(gUnknown_03007890->unk_14[idx].unk_06));
memcpy(buff1, &gUnknown_03007890->unk_14[idx].unk_06, 0xD);
memcpy(buff2, gUnknown_03007890->unk_14[idx].unk_15, sizeof(gUnknown_03007890->unk_14[idx].unk_15));
}
else
{
memset(buff1, 0, sizeof(gUnknown_03007890->unk_14[idx].unk_06));
memset(buff1, 0, 0xD);
memset(buff2, 0, sizeof(gUnknown_03007890->unk_14[idx].unk_15));
}
}
@@ -2850,7 +2850,7 @@ void sub_800EF38(void)
gUnknown_03005000.unk_ce7 = gUnknown_03004140.unk_00;
}
bool8 sub_800EF58(bool32 a0)
bool32 sub_800EF58(bool32 a0)
{
if (gUnknown_03005000.unk_04 == 17 || a0)
{
@@ -4104,7 +4104,7 @@ bool8 sub_8010540(void)
return retval;
}
bool8 sub_80105EC(void)
bool32 sub_80105EC(void)
{
u8 flags = 0;
int i;
@@ -4129,7 +4129,7 @@ bool8 sub_80105EC(void)
return FALSE;
}
bool8 sub_801064C(u16 a0, const u8 *a1)
bool32 sub_801064C(u16 a0, const u8 *a1)
{
u8 r1 = sub_8011CE4(a1, a0);
if (r1 == 0xFF)
@@ -4154,14 +4154,14 @@ void sub_80106D4(void)
rfu_NI_setSendData(1 << gUnknown_03005000.unk_c3e, 8, &gUnknown_03005000.unk_c85, 1);
}
u8 sub_8010714(u16 a0, const u8 *a1)
u32 sub_8010714(u16 a0, const u8 *a1)
{
u8 r0 = sub_8011CE4(a1, a0);
if (r0 == 0xff)
return 2;
if (gUnknown_03007880[r0]->unk_0 == 0)
return TRUE;
return FALSE;
return 1;
return 0;
}
void sub_8010750(void)
@@ -4512,14 +4512,14 @@ void sub_8010F84(u8 a0, u32 a1, u32 a2)
void sub_8010FA0(bool32 a0, bool32 a1)
{
gUnknown_02022B14.unk_00_4 = a0;
gUnknown_02022B14.unk_00_5 = a1;
gUnknown_02022B14.unk_00.unk_00_4 = a0;
gUnknown_02022B14.unk_00.unk_00_5 = a1;
}
void sub_8010FCC(u32 a0, u32 a1, u32 a2)
{
gUnknown_02022B14.unk_09_2 = a0;
gUnknown_02022B14.unk_08_0 = a1;
gUnknown_02022B14.type = a0;
gUnknown_02022B14.species = a1;
gUnknown_02022B14.unk_0b_1 = a2;
}
+6 -6
View File
@@ -39,7 +39,7 @@ struct UnkIndicatorsStruct
struct ScrollIndicatorPair
{
u8 field_0;
u16 *currItemPtr;
u16 *scrollOffset;
u16 fullyUpThreshold;
u16 fullyDownThreshold;
u8 topSpriteId;
@@ -1064,7 +1064,7 @@ static u8 AddScrollIndicatorArrowObject(u8 arrowDir, u8 x, u8 y, u16 tileTag, u1
#undef tFrequency
#undef tSinePos
u8 AddScrollIndicatorArrowPair(const struct ScrollArrowsTemplate *arrowInfo, u16 *currItemPtr)
u8 AddScrollIndicatorArrowPair(const struct ScrollArrowsTemplate *arrowInfo, u16 *scrollOffset)
{
struct CompressedSpriteSheet spriteSheet;
struct SpritePalette spritePal;
@@ -1091,7 +1091,7 @@ u8 AddScrollIndicatorArrowPair(const struct ScrollArrowsTemplate *arrowInfo, u16
data = (void*) gTasks[taskId].data;
data->field_0 = 0;
data->currItemPtr = currItemPtr;
data->scrollOffset = scrollOffset;
data->fullyUpThreshold = arrowInfo->fullyUpThreshold;
data->fullyDownThreshold = arrowInfo->fullyDownThreshold;
data->tileTag = arrowInfo->tileTag;
@@ -1108,7 +1108,7 @@ u8 AddScrollIndicatorArrowPair(const struct ScrollArrowsTemplate *arrowInfo, u16
return taskId;
}
u8 AddScrollIndicatorArrowPairParameterized(u32 arrowType, s32 commonPos, s32 firstPos, s32 secondPos, s32 fullyDownThreshold, s32 tileTag, s32 palTag, u16 *currItemPtr)
u8 AddScrollIndicatorArrowPairParameterized(u32 arrowType, s32 commonPos, s32 firstPos, s32 secondPos, s32 fullyDownThreshold, s32 tileTag, s32 palTag, u16 *scrollOffset)
{
if (arrowType == SCROLL_ARROW_UP || arrowType == SCROLL_ARROW_DOWN)
{
@@ -1135,13 +1135,13 @@ u8 AddScrollIndicatorArrowPairParameterized(u32 arrowType, s32 commonPos, s32 fi
gTempScrollArrowTemplate.palTag = palTag;
gTempScrollArrowTemplate.palNum = 0;
return AddScrollIndicatorArrowPair(&gTempScrollArrowTemplate, currItemPtr);
return AddScrollIndicatorArrowPair(&gTempScrollArrowTemplate, scrollOffset);
}
static void Task_ScrollIndicatorArrowPair(u8 taskId)
{
struct ScrollIndicatorPair *data = (void*) gTasks[taskId].data;
u16 currItem = (*data->currItemPtr);
u16 currItem = (*data->scrollOffset);
if (currItem == data->fullyUpThreshold && currItem != 0xFFFF)
gSprites[data->topSpriteId].invisible = TRUE;
+1 -1
View File
@@ -38,7 +38,7 @@ EWRAM_DATA struct PokemonStorage gPokemonStorage = {0};
EWRAM_DATA u8 gSaveblock3_DMA[SAVEBLOCK_MOVE_RANGE] = {0};
EWRAM_DATA struct LoadedSaveData gLoadedSaveData = {0};
EWRAM_DATA u32 gLastEncryptionKey = {0};
EWRAM_DATA u32 gLastEncryptionKey = 0;
// IWRAM common
IWRAM_DATA bool32 gFlashMemoryPresent;
+1 -1
View File
@@ -1965,7 +1965,7 @@ void sub_80323CC(u8 a, u8 b, u16 c, u16 d, u8 e, u8 f)
{
struct WindowTemplate sp;
sp = sub_8198A50(0, a + 1, b + 1, 5, 4, f, d);
sp = CreateWindowTemplate(0, a + 1, b + 1, 5, 4, f, d);
CreateYesNoMenu(&sp, c, e, 0);
}
+2 -2
View File
@@ -360,7 +360,7 @@ MATCHCALLDEF(sMomMatchCallHeader, 0, 0, FLAG_0x0D8, gMomMatchCallDesc, gMomMatch
static const match_call_text_data_t sStevenTextScripts[] = {
{ gText_Steven_Pokenav_2B5B95, 0xffff, 0xffff },
{ gText_Steven_Pokenav_2B5C53, FLAG_0x0C7, 0xffff },
{ gText_Steven_Pokenav_2B5C53, FLAG_RUSTURF_TUNNEL_OPENED, 0xffff },
{ gText_Steven_Pokenav_2B5CC9, FLAG_0x0D4, 0xffff },
{ gText_Steven_Pokenav_2B5DB4, FLAG_0x070, 0xffff },
{ gText_Steven_Pokenav_2B5E26, FLAG_0x4F6, 0xffff },
@@ -415,7 +415,7 @@ MATCHCALLDEF(sBrendanMatchCallHeader, 4, FEMALE, FLAG_0x0FD, gMayBrendanMatchCal
static const match_call_text_data_t sWallyTextScripts[] = {
{ gText_Wally_Pokenav_2B4DE2, 0xFFFF, 0xFFFF },
{ gText_Wally_Pokenav_2B4E57, FLAG_0x0C7, 0xFFFF },
{ gText_Wally_Pokenav_2B4E57, FLAG_RUSTURF_TUNNEL_OPENED, 0xFFFF },
{ gText_Wally_Pokenav_2B4EA5, FLAG_0x4F3, 0xFFFF },
{ gText_Wally_Pokenav_2B4F41, FLAG_0x097, 0xFFFF },
{ gText_Wally_Pokenav_2B4FF3, FLAG_0x06F, 0xFFFF },
+1 -2
View File
@@ -120,7 +120,6 @@ extern void DrawWindowBorder(u8, u8, u8, u8, u8, u8);
extern void sub_81980A8(u8, u8, u8, u8, u8, u8);
extern u8 MoveMenuCursor(s8);
extern u8 sub_8199134(s8, s8);
extern void sub_8199F74(u8 windowId, u8 fontId, const u8 *str, u8 left, u8 top, u8 speed, void (*callback)(struct TextSubPrinter *, u16), u8 letterSpacing, u8 lineSpacing);
extern void sub_8198C78(void);
extern void task_free_buf_after_copying_tile_data_to_vram(u8 taskId);
@@ -1143,7 +1142,7 @@ void SetWindowTemplateFields(struct WindowTemplate *template, u8 bg, u8 left, u8
template->baseBlock = baseBlock;
}
struct WindowTemplate sub_8198A50(u8 bg, u8 left, u8 top, u8 width, u8 height, u8 paletteNum, u16 baseBlock)
struct WindowTemplate CreateWindowTemplate(u8 bg, u8 left, u8 top, u8 width, u8 height, u8 paletteNum, u16 baseBlock)
{
struct WindowTemplate template;
SetWindowTemplateFields(&template, bg, left, top, width, height, paletteNum, baseBlock);
+5 -5
View File
@@ -689,7 +689,7 @@ void copy_saved_warp2_bank_and_enter_x_to_warp1(u8 unused)
void sub_8084CCC(u8 a1)
{
const struct HealLocation *warp = GetHealLocationPointer(a1);
const struct HealLocation *warp = GetHealLocation(a1);
if (warp)
Overworld_SetWarpDestination(warp->group, warp->map, -1, warp->x, warp->y);
@@ -702,7 +702,7 @@ void Overworld_SetWarpDestToLastHealLoc(void)
void Overworld_SetHealLocationWarp(u8 healLocationId)
{
const struct HealLocation *healLocation = GetHealLocationPointer(healLocationId);
const struct HealLocation *healLocation = GetHealLocation(healLocationId);
if (healLocation != NULL)
SetWarpData(&gSaveBlock1Ptr->lastHealLocation, healLocation->group, healLocation->map, -1, healLocation->x, healLocation->y);
@@ -761,7 +761,7 @@ void sub_8084F2C(s8 mapGroup, s8 mapNum, s8 warpId, s8 x, s8 y)
void sub_8084F6C(u8 a1)
{
const struct HealLocation *warp = GetHealLocationPointer(a1);
const struct HealLocation *warp = GetHealLocation(a1);
if (warp)
SetWarpData(&gSaveBlock1Ptr->warp1, warp->group, warp->map, -1, warp->x, warp->y);
}
@@ -1689,14 +1689,14 @@ void CB2_ReturnToFieldWithOpenMenu(void)
CB2_ReturnToField();
}
void sub_80861B0(void)
void CB2_ReturnToFieldContinueScript(void)
{
FieldClearVBlankHBlankCallbacks();
gFieldCallback = sub_80AF188;
CB2_ReturnToField();
}
void CB2_ReturnToFieldContinueScript(void)
void CB2_ReturnToFieldContinueScriptPlayMapMusic(void)
{
FieldClearVBlankHBlankCallbacks();
gFieldCallback = sub_80AF168;
+1 -1
View File
@@ -812,7 +812,7 @@ const struct WindowTemplate sWindowTemplates_0855D2A8[] =
DUMMY_WIN_TEMPLATE
};
const u8 gUnknown_0855D2B8[] = _("{UNK_CTRL_F9 8}000");
const u8 gUnknown_0855D2B8[] = _("{NO}000");
const u8 gUnknown_0855D2BE[] = INCBIN_U8("graphics/pokedex/caught_ball.4bpp");
const u8 sText_TenDashes[] = _("----------");
+13 -13
View File
@@ -1752,7 +1752,7 @@ bool8 sub_80688F8(u8 caseId, u8 battlerId)
return FALSE;
if (!gMain.inBattle)
return FALSE;
if (gLinkPlayers[GetMultiplayerId()].lp_field_18 == battlerId)
if (gLinkPlayers[GetMultiplayerId()].id == battlerId)
return FALSE;
break;
case 2:
@@ -1774,7 +1774,7 @@ bool8 sub_80688F8(u8 caseId, u8 battlerId)
return FALSE;
if (gBattleTypeFlags & BATTLE_TYPE_MULTI)
{
if (gLinkPlayers[GetMultiplayerId()].lp_field_18 == battlerId)
if (gLinkPlayers[GetMultiplayerId()].id == battlerId)
return FALSE;
}
else
@@ -2089,7 +2089,7 @@ void GiveBoxMonInitialMoveset(struct BoxPokemon *boxMon)
s32 level = GetLevelFromBoxMonExp(boxMon);
s32 i;
for (i = 0; gLevelUpLearnsets[species][i] != (u16)-1; i++)
for (i = 0; gLevelUpLearnsets[species][i] != LEVEL_UP_END; i++)
{
u16 moveLevel;
u16 move;
@@ -2101,7 +2101,7 @@ void GiveBoxMonInitialMoveset(struct BoxPokemon *boxMon)
move = (gLevelUpLearnsets[species][i] & 0x1FF);
if (GiveMoveToBoxMon(boxMon, move) == (u16)-1)
if (GiveMoveToBoxMon(boxMon, move) == 0xFFFF)
DeleteFirstMoveAndGiveMoveToBoxMon(boxMon, move);
}
}
@@ -2123,7 +2123,7 @@ u16 MonTryLearningNewMove(struct Pokemon *mon, bool8 firstMove)
while ((gLevelUpLearnsets[species][sLearningMoveTableID] & 0xFE00) != (level << 9))
{
sLearningMoveTableID++;
if (gLevelUpLearnsets[species][sLearningMoveTableID] == 0xFFFF)
if (gLevelUpLearnsets[species][sLearningMoveTableID] == LEVEL_UP_END)
return 0;
}
}
@@ -4806,7 +4806,7 @@ void EvolutionRenameMon(struct Pokemon *mon, u16 oldSpecies, u16 newSpecies)
bool8 sub_806D7EC(void)
{
bool8 retVal = FALSE;
switch (gLinkPlayers[GetMultiplayerId()].lp_field_18)
switch (gLinkPlayers[GetMultiplayerId()].id)
{
case 0:
case 3:
@@ -4823,7 +4823,7 @@ bool8 sub_806D7EC(void)
u16 GetLinkTrainerFlankId(u8 linkPlayerId)
{
u16 flankId = 0;
switch (gLinkPlayers[linkPlayerId].lp_field_18)
switch (gLinkPlayers[linkPlayerId].id)
{
case 0:
case 3:
@@ -4841,7 +4841,7 @@ s32 GetBattlerMultiplayerId(u16 a1)
{
s32 id;
for (id = 0; id < MAX_LINK_PLAYERS; id++)
if (gLinkPlayers[id].lp_field_18 == a1)
if (gLinkPlayers[id].id == a1)
break;
return id;
}
@@ -5694,7 +5694,7 @@ const u8 *GetTrainerPartnerName(void)
else
{
u8 id = GetMultiplayerId();
return gLinkPlayers[GetBattlerMultiplayerId(gLinkPlayers[id].lp_field_18 ^ 2)].name;
return gLinkPlayers[GetBattlerMultiplayerId(gLinkPlayers[id].id ^ 2)].name;
}
}
@@ -5824,7 +5824,7 @@ u8 sub_806EF08(u8 arg0)
s32 i;
s32 var = 0;
u8 multiplayerId = GetMultiplayerId();
switch (gLinkPlayers[multiplayerId].lp_field_18)
switch (gLinkPlayers[multiplayerId].id)
{
case 0:
case 2:
@@ -5837,7 +5837,7 @@ u8 sub_806EF08(u8 arg0)
}
for (i = 0; i < 4; i++)
{
if (gLinkPlayers[i].lp_field_18 == (s16)(var))
if (gLinkPlayers[i].id == (s16)(var))
break;
}
return i;
@@ -5847,7 +5847,7 @@ u8 sub_806EF84(u8 arg0, u8 arg1)
{
s32 i;
s32 var = 0;
switch (gLinkPlayers[arg1].lp_field_18)
switch (gLinkPlayers[arg1].id)
{
case 0:
case 2:
@@ -5860,7 +5860,7 @@ u8 sub_806EF84(u8 arg0, u8 arg1)
}
for (i = 0; i < 4; i++)
{
if (gLinkPlayers[i].lp_field_18 == (s16)(var))
if (gLinkPlayers[i].id == (s16)(var))
break;
}
return i;
+505 -20
View File
@@ -7,17 +7,49 @@
#include "text.h"
#include "strings.h"
#include "window.h"
#include "menu.h"
#include "bg.h"
#include "main.h"
#include "palette.h"
#include "overworld.h"
#include "field_screen.h"
#include "field_weather.h"
#include "script.h"
#include "international_string_util.h"
#include "walda_phrase.h"
#include "sound.h"
#include "gpu_regs.h"
#include "constants/songs.h"
IWRAM_DATA u8 gUnknown_03000F78[0x188];
struct OptionAndDescription
{
const u8 *optionTxt;
const u8 *descriptionTxt;
};
extern const u8 gText_PartyFull[];
extern const u8 gText_Box[];
extern const u8 gText_JustOnePkmn[];
extern u8 gUnknown_02039D00;
// This file's functions.
void StorageSystemCreatePrimaryMenu(u8 whichMenu, s16 *windowIdPtr);
void sub_80C7D74(u8);
u8 sub_80CAEA0(void);
void SetBoxWallpaper(u8 boxId, u8 wallpaperId);
void SetCurrentBox(u8 boxId);
void ClearMonInBox(u8 boxId, u8 boxPos);
void ResetWaldaWallpaper(void);
void sub_80C7958(u8 curBox);
void sub_80C7B14(void);
void sub_80C7BB4(void);
void sub_80CA028(void);
void sub_80C7B80(void);
void sub_80D2AA4(void);
void sub_80C7BE4(void);
void sub_80CAA14(void);
void sub_80C7CF4(struct Sprite *sprite);
struct Sprite *sub_80CD2E8(u16 x, u16 y, u8 animId, u8 priority, u8 subpriority);
// const rom data
const struct OptionAndDescription gUnknown_085716C0[] =
const struct PSS_MenuStringPtrs gUnknown_085716C0[] =
{
{gText_WithdrawPokemon, gText_WithdrawMonDescription},
{gText_DepositPokemon, gText_DepositMonDescription},
@@ -74,6 +106,10 @@ static const union AffineAnimCmd *const sSpriteAffineAnimTable_8571730[] =
const u8 gUnknown_08571734[] = {4, 0xF, 0xE};
const u8 gUnknown_08571737[] = _("/30");
const u16 gBoxSelectionPopupPalette[] = INCBIN_U16("graphics/unknown/unknown_57173C.gbapal");
const u8 gBoxSelectionPopupCenterTiles[] = INCBIN_U8("graphics/pokemon_storage/box_selection_popup_center.4bpp");
const u8 gBoxSelectionPopupSidesTiles[] = INCBIN_U8("graphics/pokemon_storage/box_selection_popup_sides.4bpp");
// code
u8 CountMonsInBox(u8 boxId)
{
@@ -166,24 +202,473 @@ static u8 *StringCopyAndFillWithSpaces(u8 *dst, const u8 *src, u16 n)
return str;
}
/* can't match
static void sub_80C7128(u16 *dst, u16 dstToAdd, u16 dstToMul, const u16 *src, u16 srcToAdd, u16 srcToMul, u32 size, u16 count, u16 srcBy)
static void sub_80C7128(u16 *dest, u16 dest_left, u16 dest_top, const u16 *src, u16 src_left, u16 src_top, u16 dest_width, u16 dest_height, u16 src_width)
{
u16 i;
size <<= 0x11;
dst += (dstToMul * 32) + dstToAdd;
src += (srcToMul * srcBy) + srcToAdd;
i = 0;
if (i < count)
dest_width *= 2;
dest += dest_top * 0x20 + dest_left;
src += src_top * src_width + src_left;
for (i = 0; i < dest_height; i++)
{
size >>= 1;
for (i = 0; i < count; i++)
CpuCopy16(src, dest, dest_width);
dest += 0x20;
src += src_width;
}
}
#define MAX_DMA_BLOCK_SIZE 0x1000
#define Dma3FillLarge_(value, dest, size, bit) \
{ \
void *_dest = dest; \
u32 _size = size; \
while (1) \
{ \
if (_size <= MAX_DMA_BLOCK_SIZE) \
{ \
DmaFill##bit(3, value, _dest, _size); \
break; \
} \
DmaFill##bit(3, value, _dest, MAX_DMA_BLOCK_SIZE); \
_dest += MAX_DMA_BLOCK_SIZE; \
_size -= MAX_DMA_BLOCK_SIZE; \
} \
}
#define Dma3FillLarge16_(value, dest, size) Dma3FillLarge_(value, dest, size, 16)
#define Dma3FillLarge32_(value, dest, size) Dma3FillLarge_(value, dest, size, 32)
void sub_80C71A4(u16 *dest, u16 dest_left, u16 dest_top, u16 width, u16 height)
{
u16 i;
dest += dest_top * 0x20 + dest_left;
width *= 2;
for (i = 0; i < height; dest += 0x20, i++)
Dma3FillLarge16_(0, dest, width);
}
void Task_PokemonStorageSystem(u8 taskId)
{
struct Task *task = gTasks + taskId;
switch (task->data[0])
{
case 0:
StorageSystemCreatePrimaryMenu(task->data[1], &task->data[15]);
sub_81973A4();
NewMenuHelpers_DrawDialogueFrame(0, 0);
FillWindowPixelBuffer(0, 0x11);
AddTextPrinterParameterized(0, 1, gUnknown_085716C0[task->data[1]].desc, TEXT_SPEED_FF, NULL, 2, 1, 3);
CopyWindowToVram(0, 3);
CopyWindowToVram(task->data[15], 3);
task->data[0]++;
break;
case 1:
if (IsWeatherNotFadingIn())
{
CpuSet(src, dst, size >> 0x10);
dst += 0x20;
src += srcBy;
task->data[0]++;
}
break;
case 2:
task->data[2] = ProcessMenuInput();
switch(task->data[2])
{
case -2:
task->data[3] = task->data[1];
if (gMain.newKeys & DPAD_UP && --task->data[3] < 0)
task->data[3] = 4;
if (gMain.newKeys & DPAD_DOWN && ++task->data[3] > 4)
task->data[3] = 0;
if (task->data[1] != task->data[3])
{
task->data[1] = task->data[3];
FillWindowPixelBuffer(0, 0x11);
AddTextPrinterParameterized(0, 1, gUnknown_085716C0[task->data[1]].desc, 0, NULL, 2, 1, 3);
}
break;
case -1:
case 4:
sub_819746C(task->data[15], TRUE);
ScriptContext2_Disable();
EnableBothScriptContexts();
RemoveWindow(task->data[15]);
DestroyTask(taskId);
break;
default:
if (task->data[2] == 0 && CountPartyMons() == PARTY_SIZE)
{
FillWindowPixelBuffer(0, 0x11);
AddTextPrinterParameterized(0, 1, gText_PartyFull, 0, NULL, 2, 1, 3);
task->data[0] = 3;
}
else if (task->data[2] == 1 && CountPartyMons() == 1)
{
FillWindowPixelBuffer(0, 0x11);
AddTextPrinterParameterized(0, 1, gText_JustOnePkmn, 0, NULL, 2, 1, 3);
task->data[0] = 3;
}
else
{
FadeScreen(1, 0);
task->data[0] = 4;
}
break;
}
break;
case 3:
if (gMain.newKeys & (A_BUTTON | B_BUTTON))
{
FillWindowPixelBuffer(0, 0x11);
AddTextPrinterParameterized(0, 1, gUnknown_085716C0[task->data[1]].desc, 0, NULL, 2, 1, 3);
task->data[0] = 2;
}
else if (gMain.newKeys & DPAD_UP)
{
if (--task->data[1] < 0)
task->data[1] = 4;
MoveMenuCursor(-1);
task->data[1] = GetMenuCursorPos();
FillWindowPixelBuffer(0, 0x11);
AddTextPrinterParameterized(0, 1, gUnknown_085716C0[task->data[1]].desc, 0, NULL, 2, 1, 3);
task->data[0] = 2;
}
else if (gMain.newKeys & DPAD_DOWN)
{
if (++task->data[1] > 3)
task->data[1] = 0;
MoveMenuCursor(1);
task->data[1] = GetMenuCursorPos();
FillWindowPixelBuffer(0, 0x11);
AddTextPrinterParameterized(0, 1, gUnknown_085716C0[task->data[1]].desc, 0, NULL, 2, 1, 3);
task->data[0] = 2;
}
break;
case 4:
if (!gPaletteFade.active)
{
overworld_free_bg_tilemaps();
sub_80C7D74(task->data[2]);
RemoveWindow(task->data[15]);
DestroyTask(taskId);
}
break;
}
}
void ShowPokemonStorageSystem(void)
{
u8 taskId = CreateTask(Task_PokemonStorageSystem, 80);
gTasks[taskId].data[0] = 0;
gTasks[taskId].data[1] = 0;
ScriptContext2_Enable();
}
void mapldr_0808C6D8(void)
{
u8 taskId;
MainCallback vblankCb = gMain.vblankCallback;
SetVBlankCallback(NULL);
taskId = CreateTask(Task_PokemonStorageSystem, 80);
gTasks[taskId].data[0] = 0;
gTasks[taskId].data[1] = gUnknown_02039D00;
Task_PokemonStorageSystem(taskId);
SetVBlankCallback(vblankCb);
pal_fill_black();
}
void StorageSystemCreatePrimaryMenu(u8 whichMenu, s16 *windowIdPtr)
{
s16 windowId;
struct WindowTemplate winTemplate = gUnknown_085716E8;
winTemplate.width = GetMaxWidthInMenuTable((void *)gUnknown_085716C0, ARRAY_COUNT(gUnknown_085716C0));
windowId = AddWindow(&winTemplate);
NewMenuHelpers_DrawStdWindowFrame(windowId, FALSE);
PrintMenuTable(windowId, ARRAY_COUNT(gUnknown_085716C0), (void *)gUnknown_085716C0);
InitMenuInUpperLeftCornerPlaySoundWhenAPressed(windowId, ARRAY_COUNT(gUnknown_085716C0), whichMenu);
*windowIdPtr = windowId;
}
void sub_80C7678(void)
{
gUnknown_02039D00 = sub_80CAEA0();
gFieldCallback = mapldr_0808C6D8;
SetMainCallback2(CB2_ReturnToField);
}
s16 StorageSystemGetNextMonIndex(struct BoxPokemon *box, s8 startIdx, u8 stopIdx, u8 mode)
{
s16 i;
s16 direction;
if (mode == 0 || mode == 1)
{
direction = 1;
}
else
{
direction = -1;
}
if (mode == 1 || mode == 3)
{
for (i = startIdx + direction; i >= 0 && i <= stopIdx; i += direction)
{
if (GetBoxMonData(box + i, MON_DATA_SPECIES) != 0)
return i;
}
}
}*/
else
{
for (i = startIdx + direction; i >= 0 && i <= stopIdx; i += direction)
{
if (GetBoxMonData(box + i, MON_DATA_SPECIES) != 0 && !GetBoxMonData(box + i, MON_DATA_IS_EGG))
return i;
}
}
return -1;
}
void ResetPokemonStorageSystem(void)
{
u16 boxId;
u16 boxMon;
SetCurrentBox(0);
for (boxId = 0; boxId < TOTAL_BOXES_COUNT; boxId++)
{
for (boxMon = 0; boxMon < IN_BOX_COUNT; boxMon++)
ClearMonInBox(boxId, boxMon);
}
for (boxId = 0; boxId < TOTAL_BOXES_COUNT; boxId++)
{
u8 *dest = StringCopy(GetBoxNamePtr(boxId), gText_Box);
ConvertIntToDecimalStringN(dest, boxId + 1, STR_CONV_MODE_LEFT_ALIGN, 2);
}
for (boxId = 0; boxId < TOTAL_BOXES_COUNT; boxId++)
{
SetBoxWallpaper(boxId, boxId % 4);
}
ResetWaldaWallpaper();
}
void sub_80C77E8(struct UnkPSSStruct_2002370 *a0, u16 tileTag, u16 palTag, u8 a3, bool32 loadPal)
{
struct SpritePalette palette =
{
gBoxSelectionPopupPalette, palTag
};
struct SpriteSheet sheets[] =
{
{gBoxSelectionPopupCenterTiles, 0x800, tileTag},
{gBoxSelectionPopupSidesTiles, 0x180, tileTag + 1},
{}
};
if (loadPal)
LoadSpritePalette(&palette);
LoadSpriteSheets(sheets);
gUnknown_02039D04 = a0;
a0->unk_0240 = tileTag;
a0->unk_0242 = palTag;
a0->unk_0246 = a3;
a0->unk_023c = loadPal;
}
void sub_80C7890(void)
{
if (gUnknown_02039D04->unk_023c)
FreeSpritePaletteByTag(gUnknown_02039D04->unk_0242);
FreeSpriteTilesByTag(gUnknown_02039D04->unk_0240);
FreeSpriteTilesByTag(gUnknown_02039D04->unk_0240 + 1);
}
void sub_80C78D4(u8 curBox)
{
sub_80C7958(curBox);
}
void sub_80C78E4(void)
{
sub_80C7B14();
}
u8 sub_80C78F0(void)
{
if (gMain.newKeys & B_BUTTON)
{
PlaySE(SE_SELECT);
return 201;
}
if (gMain.newKeys & A_BUTTON)
{
PlaySE(SE_SELECT);
return gUnknown_02039D04->curBox;
}
if (gMain.newKeys & DPAD_LEFT)
{
PlaySE(SE_SELECT);
sub_80C7BB4();
}
else if (gMain.newKeys & DPAD_RIGHT)
{
PlaySE(SE_SELECT);
sub_80C7B80();
}
return 200;
}
void sub_80C7958(u8 curBox)
{
u16 i;
u8 spriteId;
struct SpriteTemplate template;
struct OamData oamData = {};
oamData.size = 3;
oamData.paletteNum = 1;
template = (struct SpriteTemplate){
0, 0, &oamData, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, SpriteCallbackDummy
};
gUnknown_02039D04->curBox = curBox;
template.tileTag = gUnknown_02039D04->unk_0240;
template.paletteTag = gUnknown_02039D04->unk_0242;
spriteId = CreateSprite(&template, 0xA0, 0x60, 0);
gUnknown_02039D04->unk_0000 = gSprites + spriteId;
oamData.shape = ST_OAM_V_RECTANGLE;
oamData.size = 1;
template.tileTag = gUnknown_02039D04->unk_0240 + 1;
template.anims = sSpriteAnimTable_8571710;
for (i = 0; i < 4; i++)
{
u16 r5;
spriteId = CreateSprite(&template, 0x7c, 0x50, gUnknown_02039D04->unk_0246);
gUnknown_02039D04->unk_0004[i] = gSprites + spriteId;
r5 = 0;
if (i & 2)
{
gUnknown_02039D04->unk_0004[i]->pos1.x = 0xc4;
r5 = 2;
}
if (i & 1)
{
gUnknown_02039D04->unk_0004[i]->pos1.y = 0x70;
gUnknown_02039D04->unk_0004[i]->oam.size = 0;
r5++;
}
StartSpriteAnim(gUnknown_02039D04->unk_0004[i], r5);
}
for (i = 0; i < 2; i++)
{
gUnknown_02039D04->unk_0020[i] = sub_80CD2E8(72 * i + 0x7c, 0x58, i, 0, gUnknown_02039D04->unk_0246);
if (gUnknown_02039D04->unk_0020[i])
{
gUnknown_02039D04->unk_0020[i]->data[0] = (i == 0 ? -1 : 1);
gUnknown_02039D04->unk_0020[i]->callback = sub_80C7CF4;
}
}
sub_80C7BE4();
}
void sub_80C7B14(void)
{
u16 i;
if (gUnknown_02039D04->unk_0000)
{
DestroySprite(gUnknown_02039D04->unk_0000);
gUnknown_02039D04->unk_0000 = NULL;
}
for (i = 0; i < 4; i++)
{
if (gUnknown_02039D04->unk_0004[i])
{
DestroySprite(gUnknown_02039D04->unk_0004[i]);
gUnknown_02039D04->unk_0004[i] = NULL;
}
}
for (i = 0; i < 2; i++)
{
if (gUnknown_02039D04->unk_0020[i])
DestroySprite(gUnknown_02039D04->unk_0020[i]);
}
}
void sub_80C7B80(void)
{
if (++gUnknown_02039D04->curBox >= TOTAL_BOXES_COUNT)
gUnknown_02039D04->curBox = 0;
sub_80C7BE4();
}
void sub_80C7BB4(void)
{
gUnknown_02039D04->curBox = (gUnknown_02039D04->curBox == 0 ? TOTAL_BOXES_COUNT - 1 : gUnknown_02039D04->curBox - 1);
sub_80C7BE4();
}
void sub_80C7BE4(void)
{
u8 text[16];
struct WindowTemplate winTemplate;
u8 windowId;
u8 *boxName = GetBoxNamePtr(gUnknown_02039D04->curBox);
u8 nPokemonInBox = CountMonsInBox(gUnknown_02039D04->curBox);
u32 winTileData;
s32 center;
memset(&winTemplate, 0, sizeof(winTemplate));
winTemplate.width = 8;
winTemplate.height = 4;
windowId = AddWindow(&winTemplate);
FillWindowPixelBuffer(windowId, 0x44);
center = GetStringCenterAlignXOffset(1, boxName, 0x40);
box_print(windowId, 1, center, 1, gUnknown_08571734, TEXT_SPEED_FF, boxName);
ConvertIntToDecimalStringN(text, nPokemonInBox, 1, 2);
StringAppend(text, gUnknown_08571737);
center = GetStringCenterAlignXOffset(1, text, 0x40);
box_print(windowId, 1, center, 0x11, gUnknown_08571734, TEXT_SPEED_FF, text);
winTileData = GetWindowAttribute(windowId, WINDOW_TILE_DATA);
CpuCopy32((void *)winTileData, (void *)OBJ_VRAM0 + 0x100 + (GetSpriteTileStartByTag(gUnknown_02039D04->unk_0240) * 32), 0x400);
RemoveWindow(windowId);
}
void sub_80C7CF4(struct Sprite *sprite)
{
if (++sprite->data[1] > 3)
{
sprite->data[1] = 0;
sprite->pos2.x += sprite->data[0];
if (++sprite->data[2] > 5)
{
sprite->data[2] = 0;
sprite->pos2.x = 0;
}
}
}
void sub_80C7D28(void)
{
LoadOam();
ProcessSpriteCopyRequests();
sub_80D2AA4();
TransferPlttBuffer();
SetGpuReg(REG_OFFSET_BG2HOFS, gUnknown_02039D08->bg2_X);
}
void c2_Box(void)
{
RunTasks();
do_scheduled_bg_tilemap_copies_to_vram();
sub_80CA028();
sub_80CAA14();
AnimateSprites();
BuildOamBuffer();
}
+294 -64
View File
@@ -15,7 +15,7 @@
#include "sound.h"
#include "constants/species.h"
#include "sprite.h"
#include "unk_text_util.h"
#include "dynamic_placeholder_text_util.h"
#include "string_util.h"
#include "task.h"
#include "text.h"
@@ -27,21 +27,8 @@
#include "scanline_effect.h"
#include "menu_helpers.h"
#include "daycare.h"
struct ContestMove
{
u8 effect;
u8 type;
u8 comboID;
u8 combo[4];
};
struct ContestEffect
{
u8 type;
u8 appeal;
u8 jam;
};
#include "data2.h"
#include "contest.h"
extern struct UnkSummaryStruct* gUnknown_0203CF1C;
extern struct BgTemplate gUnknown_0861CBB4;
@@ -69,6 +56,7 @@ extern u8 gUnknown_0861CE74[];
extern u8 gUnknown_0861CE7B[];
extern struct WindowTemplate gUnknown_0861CCEC;
extern struct WindowTemplate gUnknown_0861CD14;
extern const u8 *const gContestEffectDescriptionPointers[];
void sub_81C488C(u8 a);
extern u8 sub_81221EC();
@@ -96,6 +84,7 @@ extern u8 gText_PkmnInfo[];
extern u8 gText_PkmnSkills[];
extern u8 gText_BattleMoves[];
extern u8 gText_ContestMoves[];
extern u8 gText_HMMovesCantBeForgotten2[];
extern u8 gText_Cancel2[];
extern u8 gText_Info[];
extern u8 gText_Switch[];
@@ -144,12 +133,14 @@ extern u8 gUnknown_0861CE8E[];
extern u8 gText_OneDash[];
extern u8 gText_TwoDashes[];
extern u8 gText_ThreeDashes[];
extern u8 gText_Cancel[];
extern u8 gUnknown_0861CE97[];
extern const struct SpriteTemplate gUnknown_0861CFC4;
extern void sub_8199C30(u8 a, u8 b, u8 c, u8 d, u8 e, u8 f);
extern bool8 sub_81A6BF4();
extern bool8 sub_81B9E94();
extern void UnkTextUtil_Reset();
extern void DynamicPlaceholderTextUtil_Reset();
extern void sub_8124610(u8 *a, u8 b);
extern int GetPlayerIDAsU32();
extern u8 GetCurrentPpToMaxPpState(u8 a, u8 b);
@@ -173,6 +164,9 @@ void sub_81C4984();
void sub_81C4A08();
void sub_81C4A88();
void sub_81C4280();
void sub_81C43A0();
void sub_81C4484();
void sub_81C4420();
void sub_81C0510(u8 taskId);
void sub_81C171C(u8 taskId);
void ResetAllBgsCoordinates();
@@ -341,15 +335,16 @@ struct UnkSummaryStruct
u8 unk40C9;
u8 unk40CA;
u8 unk40CB[8];
u8 unk40D3;
u8 unk40D4;
u8 unk40D5;
u8 unk_filler5[0x19];
u8 unk40D3[0x1C];
u8 unk40EF;
s16 unk40F0;
u8 unk_filler4[6];
};
// const rom data
#include "data/text/move_descriptions.h"
// code
void sub_81BF8EC(u8 a, void *b, u8 c, u8 d, void *e)
{
u8 byte;
@@ -506,8 +501,8 @@ bool8 sub_81BFB10(void)
gMain.state++;
break;
case 17:
gUnknown_0203CF1C->unk40D3 = sub_81C45F4(&gUnknown_0203CF1C->currentMon, &gUnknown_0203CF1C->unk40F0);
if (gUnknown_0203CF1C->unk40D3 != 0xFF)
gUnknown_0203CF1C->unk40D3[0] = sub_81C45F4(&gUnknown_0203CF1C->currentMon, &gUnknown_0203CF1C->unk40F0);
if (gUnknown_0203CF1C->unk40D3[0] != 0xFF)
{
gUnknown_0203CF1C->unk40F0 = 0;
gMain.state++;
@@ -890,10 +885,10 @@ void sub_81C0704(u8 taskId)
break;
case 1:
sub_81C4898();
DestroySpriteAndFreeResources(&gSprites[gUnknown_0203CF1C->unk40D3]);
DestroySpriteAndFreeResources(&gSprites[gUnknown_0203CF1C->unk40D3[0]]);
break;
case 2:
DestroySpriteAndFreeResources(&gSprites[gUnknown_0203CF1C->unk40D4]);
DestroySpriteAndFreeResources(&gSprites[gUnknown_0203CF1C->unk40D3[1]]);
break;
case 3:
sub_81C0098(&gUnknown_0203CF1C->currentMon);
@@ -916,10 +911,10 @@ void sub_81C0704(u8 taskId)
data[1] = 0;
break;
case 8:
gUnknown_0203CF1C->unk40D3 = sub_81C45F4(&gUnknown_0203CF1C->currentMon, &data[1]);
if (gUnknown_0203CF1C->unk40D3 == 0xFF)
gUnknown_0203CF1C->unk40D3[0] = sub_81C45F4(&gUnknown_0203CF1C->currentMon, &data[1]);
if (gUnknown_0203CF1C->unk40D3[0] == 0xFF)
return;
gSprites[gUnknown_0203CF1C->unk40D3].data[2] = 1;
gSprites[gUnknown_0203CF1C->unk40D3[0]].data[2] = 1;
sub_81C0E24();
data[1] = 0;
break;
@@ -934,7 +929,7 @@ void sub_81C0704(u8 taskId)
sub_81C2524();
break;
case 12:
gSprites[gUnknown_0203CF1C->unk40D3].data[2] = 0;
gSprites[gUnknown_0203CF1C->unk40D3[0]].data[2] = 0;
break;
default:
if (sub_81221EC() == 0 && FuncIsActiveTask(sub_81C20F0) == 0)
@@ -1139,7 +1134,7 @@ void sub_81C0E48(u8 taskId)
gUnknown_0203CF1C->unk40C6 = 0;
move = gUnknown_0203CF1C->summary.moves[gUnknown_0203CF1C->unk40C6];
ClearWindowTilemap(0x13);
if (gSprites[gUnknown_0203CF1C->unk40D5].invisible == 0)
if (gSprites[gUnknown_0203CF1C->unk40D3[2]].invisible == 0)
ClearWindowTilemap(0xD);
sub_81C1DA4(9, -3);
sub_81C1EFC(9, -3, move);
@@ -1245,7 +1240,7 @@ void sub_81C1070(s16 *a, s8 b, u8 *c)
if ((*c == 4 && gUnknown_0203CF1C->unk40C4 == 0) || a[1] == 1)
{
ClearWindowTilemap(19);
if (!gSprites[gUnknown_0203CF1C->unk40D5].invisible)
if (!gSprites[gUnknown_0203CF1C->unk40D3[2]].invisible)
ClearWindowTilemap(13);
schedule_bg_copy_tilemap_to_vram(0);
sub_81C1DA4(9, -3);
@@ -1889,7 +1884,7 @@ void sub_81C1940(u8 taskId)
{
ClearWindowTilemap(19);
if (!gSprites[gUnknown_0203CF1C->unk40D5].invisible)
if (!gSprites[gUnknown_0203CF1C->unk40D3[2]].invisible)
ClearWindowTilemap(13);
move = gUnknown_0203CF1C->summary.moves[gUnknown_0203CF1C->unk40C6];
gTasks[taskId].func = sub_81C174C;
@@ -1903,7 +1898,7 @@ void sub_81C1940(u8 taskId)
if (gUnknown_0203CF1C->unk40C0 != 3)
{
ClearWindowTilemap(19);
if (!gSprites[gUnknown_0203CF1C->unk40D5].invisible)
if (!gSprites[gUnknown_0203CF1C->unk40D3[2]].invisible)
ClearWindowTilemap(13);
move = gUnknown_0203CF1C->summary.moves[gUnknown_0203CF1C->unk40C6];
gTasks[taskId].func = sub_81C174C;
@@ -1915,7 +1910,7 @@ void sub_81C1940(u8 taskId)
else if (gMain.newKeys & (A_BUTTON | B_BUTTON))
{
ClearWindowTilemap(19);
if (!gSprites[gUnknown_0203CF1C->unk40D5].invisible)
if (!gSprites[gUnknown_0203CF1C->unk40D3[2]].invisible)
ClearWindowTilemap(13);
move = gUnknown_0203CF1C->summary.moves[gUnknown_0203CF1C->unk40C6];
sub_81C3E9C(move);
@@ -2208,7 +2203,7 @@ void sub_81C1E20(u8 taskId)
}
else
{
if (!gSprites[gUnknown_0203CF1C->unk40D5].invisible)
if (!gSprites[gUnknown_0203CF1C->unk40D3[2]].invisible)
PutWindowTilemap(13);
PutWindowTilemap(19);
}
@@ -2259,7 +2254,7 @@ void sub_81C1F80(u8 taskId)
}
else
{
if (!gSprites[gUnknown_0203CF1C->unk40D5].invisible)
if (!gSprites[gUnknown_0203CF1C->unk40D3[2]].invisible)
{
PutWindowTilemap(13);
}
@@ -2908,12 +2903,12 @@ void sub_81C307C()
{
struct PokeSummary *sum = &gUnknown_0203CF1C->summary;
u8 *text;
UnkTextUtil_Reset();
UnkTextUtil_SetPtrI(0, gUnknown_0861CE74);
UnkTextUtil_SetPtrI(1, gUnknown_0861CE7B);
DynamicPlaceholderTextUtil_Reset();
DynamicPlaceholderTextUtil_SetPlaceholderPtr(0, gUnknown_0861CE74);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(1, gUnknown_0861CE7B);
sub_81C31C0();
if (sub_81A6BF4() == TRUE || sub_81B9E94() == TRUE || sub_81C3304() == TRUE)
UnkTextUtil_StringExpandPlaceholders(gStringVar4, gText_XNature);
DynamicPlaceholderTextUtil_ExpandPlaceholders(gStringVar4, gText_XNature);
else
{
u8 *alloced1 = Alloc(32);
@@ -2922,7 +2917,7 @@ void sub_81C307C()
if (sum->metLocation <= 0xD4)
{
sub_8124610(alloced2, sum->metLocation);
UnkTextUtil_SetPtrI(4, alloced2);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(4, alloced2);
}
if (sub_81C3220() == 1)
{
@@ -2937,7 +2932,7 @@ void sub_81C307C()
text = (sum->metLocation > 0xD4) ? gText_XNatureObtainedInTrade : gText_XNatureProbablyMetAt;
else
text = gText_XNatureObtainedInTrade;
UnkTextUtil_StringExpandPlaceholders(gStringVar4, text);
DynamicPlaceholderTextUtil_ExpandPlaceholders(gStringVar4, text);
Free(alloced1);
Free(alloced2);
}
@@ -2951,8 +2946,8 @@ void sub_81C3194()
void sub_81C31C0()
{
struct UnkSummaryStruct *sumStruct = gUnknown_0203CF1C;
UnkTextUtil_SetPtrI(2, gNatureNamePointers[sumStruct->summary.nature]);
UnkTextUtil_SetPtrI(5, gText_EmptyString5);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(2, gNatureNamePointers[sumStruct->summary.nature]);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(5, gText_EmptyString5);
}
void sub_81C31F0(u8 *a)
@@ -2961,7 +2956,7 @@ void sub_81C31F0(u8 *a)
if (level == 0)
level = EGG_HATCH_LEVEL;
ConvertIntToDecimalStringN(a, level, 0, 3);
UnkTextUtil_SetPtrI(3, a);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(3, a);
}
u8 sub_81C3220()
@@ -3216,12 +3211,12 @@ void sub_81C3710()
ConvertIntToDecimalStringN(alloced2, gUnknown_0203CF1C->summary.maxHP, 1, 3);
ConvertIntToDecimalStringN(alloced3, gUnknown_0203CF1C->summary.atk, 1, 7);
ConvertIntToDecimalStringN(alloced4, gUnknown_0203CF1C->summary.def, 1, 7);
UnkTextUtil_Reset();
UnkTextUtil_SetPtrI(0, alloced1);
UnkTextUtil_SetPtrI(1, alloced2);
UnkTextUtil_SetPtrI(2, alloced3);
UnkTextUtil_SetPtrI(3, alloced4);
UnkTextUtil_StringExpandPlaceholders(gStringVar4, gUnknown_0861CE82);
DynamicPlaceholderTextUtil_Reset();
DynamicPlaceholderTextUtil_SetPlaceholderPtr(0, alloced1);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(1, alloced2);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(2, alloced3);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(3, alloced4);
DynamicPlaceholderTextUtil_ExpandPlaceholders(gStringVar4, gUnknown_0861CE82);
Free(alloced1);
Free(alloced2);
Free(alloced3);
@@ -3238,11 +3233,11 @@ void sub_81C3808()
ConvertIntToDecimalStringN(gStringVar1, gUnknown_0203CF1C->summary.spatk, 1, 3);
ConvertIntToDecimalStringN(gStringVar2, gUnknown_0203CF1C->summary.spdef, 1, 3);
ConvertIntToDecimalStringN(gStringVar3, gUnknown_0203CF1C->summary.speed, 1, 3);
UnkTextUtil_Reset();
UnkTextUtil_SetPtrI(0, gStringVar1);
UnkTextUtil_SetPtrI(1, gStringVar2);
UnkTextUtil_SetPtrI(2, gStringVar3);
UnkTextUtil_StringExpandPlaceholders(gStringVar4, gUnknown_0861CE8E);
DynamicPlaceholderTextUtil_Reset();
DynamicPlaceholderTextUtil_SetPlaceholderPtr(0, gStringVar1);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(1, gStringVar2);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(2, gStringVar3);
DynamicPlaceholderTextUtil_ExpandPlaceholders(gStringVar4, gUnknown_0861CE8E);
}
void sub_81C3890()
@@ -3351,10 +3346,10 @@ void sub_81C3B08(u8 a)
sub_81C25A4(r8, gMoveNames[move], 0, (a<<4) + 1, 0, 1);
ConvertIntToDecimalStringN(gStringVar1, r10->summary.pp[a], 1, 2);
ConvertIntToDecimalStringN(gStringVar2, r6, 1, 2);
UnkTextUtil_Reset();
UnkTextUtil_SetPtrI(0, gStringVar1);
UnkTextUtil_SetPtrI(1, gStringVar2);
UnkTextUtil_StringExpandPlaceholders(gStringVar4, gUnknown_0861CE97);
DynamicPlaceholderTextUtil_Reset();
DynamicPlaceholderTextUtil_SetPlaceholderPtr(0, gStringVar1);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(1, gStringVar2);
DynamicPlaceholderTextUtil_ExpandPlaceholders(gStringVar4, gUnknown_0861CE97);
text = gStringVar4;
r5 = GetCurrentPpToMaxPpState(r10->summary.pp[a], r6) + 9;
offset = GetStringRightAlignXOffset(1, text, 0x2C);
@@ -3446,17 +3441,17 @@ void sub_81C3B08(u8 a)
movs r2, 0x1\n\
movs r3, 0x2\n\
bl ConvertIntToDecimalStringN\n\
bl UnkTextUtil_Reset\n\
bl DynamicPlaceholderTextUtil_Reset\n\
movs r0, 0\n\
mov r1, r8\n\
bl UnkTextUtil_SetPtrI\n\
bl DynamicPlaceholderTextUtil_SetPlaceholderPtr\n\
movs r0, 0x1\n\
adds r1, r4, 0\n\
bl UnkTextUtil_SetPtrI\n\
bl DynamicPlaceholderTextUtil_SetPlaceholderPtr\n\
ldr r4, =gStringVar4\n\
ldr r1, =gUnknown_0861CE97\n\
adds r0, r4, 0\n\
bl UnkTextUtil_StringExpandPlaceholders\n\
bl DynamicPlaceholderTextUtil_ExpandPlaceholders\n\
adds r7, r4, 0\n\
ldrb r0, [r5]\n\
adds r1, r6, 0\n\
@@ -3591,3 +3586,238 @@ void sub_81C3D54(u8 taskId)
}
data[0]++;
}
void sub_81C3E2C(u8 moveSlot)
{
u16 move;
if (moveSlot == 4)
move = gUnknown_0203CF1C->unk40C4;
else
move = gUnknown_0203CF1C->summary.moves[moveSlot];
if (move != MOVE_NONE)
{
u8 windowId = sub_81C2D2C(&gUnknown_0861CD14, 2);
sub_81C25A4(windowId, gContestEffectDescriptionPointers[gContestMoves[move].effect], 6, 1, 0, 0);
}
}
void sub_81C3E9C(u16 move)
{
u8 windowId = sub_81C2D2C(&gUnknown_0861CD14, 2);
FillWindowPixelBuffer(windowId, 0);
if (move != MOVE_NONE)
{
if (gUnknown_0203CF1C->unk40C0 == 2)
{
sub_81C3C5C(move);
sub_81C25A4(windowId, gMoveDescriptionPointers[move - 1], 6, 1, 0, 0);
}
else
{
sub_81C25A4(windowId, gContestEffectDescriptionPointers[gContestMoves[move].effect], 6, 1, 0, 0);
}
PutWindowTilemap(windowId);
}
else
{
ClearWindowTilemap(windowId);
}
schedule_bg_copy_tilemap_to_vram(0);
}
void sub_81C3F44(void)
{
u8 windowId1 = sub_81C2D2C(&gUnknown_0861CD14, 0);
u8 windowId2 = sub_81C2D2C(&gUnknown_0861CD14, 1);
if (gUnknown_0203CF1C->unk40C4 == MOVE_NONE)
{
sub_81C25A4(windowId1, gText_Cancel, 0, 0x41, 0, 1);
}
else
{
u16 move = gUnknown_0203CF1C->unk40C4;
if (gUnknown_0203CF1C->unk40C0 == 2)
sub_81C25A4(windowId1, gMoveNames[move], 0, 0x41, 0, 6);
else
sub_81C25A4(windowId1, gMoveNames[move], 0, 0x41, 0, 5);
ConvertIntToDecimalStringN(gStringVar1, gBattleMoves[move].pp, 1, 2);
DynamicPlaceholderTextUtil_Reset();
DynamicPlaceholderTextUtil_SetPlaceholderPtr(0, gStringVar1);
DynamicPlaceholderTextUtil_SetPlaceholderPtr(1, gStringVar1);
DynamicPlaceholderTextUtil_ExpandPlaceholders(gStringVar4, gUnknown_0861CE97);
sub_81C25A4(windowId2, gStringVar4, GetStringRightAlignXOffset(1, gStringVar4, 0x2C), 0x41, 0, 12);
}
}
void sub_81C4064(void)
{
u8 windowId = sub_81C2D2C(&gUnknown_0861CD14, 0);
FillWindowPixelRect(windowId, 0, 0, 0x42, 0x48, 0x10);
CopyWindowToVram(windowId, 2);
}
void sub_81C40A0(u8 a, u8 b)
{
u8 windowId1 = sub_81C2D2C(&gUnknown_0861CD14, 0);
u8 windowId2 = sub_81C2D2C(&gUnknown_0861CD14, 1);
FillWindowPixelRect(windowId1, 0, 0, a * 16, 0x48, 0x10);
FillWindowPixelRect(windowId1, 0, 0, b * 16, 0x48, 0x10);
FillWindowPixelRect(windowId2, 0, 0, a * 16, 0x30, 0x10);
FillWindowPixelRect(windowId2, 0, 0, b * 16, 0x30, 0x10);
sub_81C3B08(a);
sub_81C3B08(b);
}
void sub_81C4154(void)
{
u8 windowId = sub_81C2D2C(&gUnknown_0861CD14, 2);
FillWindowPixelBuffer(windowId, 0);
sub_81C25A4(windowId, gText_HMMovesCantBeForgotten2, 6, 1, 0, 0);
}
void sub_81C4190(void)
{
u8 i;
for (i = 0; i < 28; i++)
gUnknown_0203CF1C->unk40D3[i] |= 0xFF;
}
void sub_81C41C0(u8 spriteArrayId)
{
if (gUnknown_0203CF1C->unk40D3[spriteArrayId] != 0xFF)
{
DestroySprite(&gSprites[gUnknown_0203CF1C->unk40D3[spriteArrayId]]);
gUnknown_0203CF1C->unk40D3[spriteArrayId] = 0xFF;
}
}
void sub_81C4204(u8 spriteArrayId, bool8 invisible)
{
gSprites[gUnknown_0203CF1C->unk40D3[spriteArrayId]].invisible = invisible;
}
void sub_81C424C(void)
{
u8 i;
for (i = 3; i < 28; i++)
{
if (gUnknown_0203CF1C->unk40D3[i] != 0xFF)
sub_81C4204(i, TRUE);
}
}
void sub_81C4280(void)
{
switch (gUnknown_0203CF1C->unk40C0)
{
case 0:
sub_81C43A0();
break;
case 2:
sub_81C4420();
sub_81C44F0();
break;
case 3:
sub_81C4484();
sub_81C44F0();
break;
}
}
void sub_81C42C8(void)
{
u8 i;
for (i = 3; i < 8; i++)
{
if (gUnknown_0203CF1C->unk40D3[i] == 0xFF)
gUnknown_0203CF1C->unk40D3[i] = CreateSprite(&gUnknown_0861CFC4, 0, 0, 2);
sub_81C4204(i, TRUE);
}
}
extern const u8 gUnknown_0861CFDC[];
void sub_81C4318(u8 typeId, u8 x, u8 y, u8 spriteArrayId)
{
struct Sprite *sprite = &gSprites[gUnknown_0203CF1C->unk40D3[spriteArrayId]];
StartSpriteAnim(sprite, typeId);
sprite->oam.paletteNum = gUnknown_0861CFDC[typeId];
sprite->pos1.x = x + 16;
sprite->pos1.y = y + 8;
sub_81C4204(spriteArrayId, FALSE);
}
void sub_81C43A0(void)
{
struct PokeSummary *summary = &gUnknown_0203CF1C->summary;
if (summary->isEgg)
{
sub_81C4318(TYPE_MYSTERY, 0x78, 0x30, 3);
sub_81C4204(4, TRUE);
}
else
{
sub_81C4318(gBaseStats[summary->species].type1, 0x78, 0x30, 3);
if (gBaseStats[summary->species].type1 != gBaseStats[summary->species].type2)
{
sub_81C4318(gBaseStats[summary->species].type2, 0xA0, 0x30, 4);
sub_81C4204(4, FALSE);
}
else
{
sub_81C4204(4, TRUE);
}
}
}
void sub_81C4420(void)
{
u8 i;
struct PokeSummary *summary = &gUnknown_0203CF1C->summary;
for (i = 0; i < 4; i++)
{
if (summary->moves[i] != MOVE_NONE)
sub_81C4318(gBattleMoves[summary->moves[i]].type, 0x55, 0x20 + (i * 0x10), i + 3);
else
sub_81C4204(i + 3, TRUE);
}
}
void sub_81C4484(void)
{
u8 i;
struct PokeSummary *summary = &gUnknown_0203CF1C->summary;
for (i = 0; i < 4; i++)
{
if (summary->moves[i] != MOVE_NONE)
sub_81C4318(NUMBER_OF_MON_TYPES + gContestMoves[summary->moves[i]].contestCategory, 0x55, 0x20 + (i * 0x10), i + 3);
else
sub_81C4204(i + 3, TRUE);
}
}
void sub_81C44F0(void)
{
if (gUnknown_0203CF1C->unk40C4 == MOVE_NONE)
{
sub_81C4204(7, TRUE);
}
else
{
if (gUnknown_0203CF1C->unk40C0 == 2)
sub_81C4318(gBattleMoves[gUnknown_0203CF1C->unk40C4].type, 0x55, 0x60, 7);
else
sub_81C4318(NUMBER_OF_MON_TYPES + gContestMoves[gUnknown_0203CF1C->unk40C4].contestCategory, 0x55, 0x60, 7);
}
}
+3 -3
View File
@@ -159,7 +159,7 @@ void sub_8184E58(void)
{
sPlayers[i].trainerId = gLinkPlayers[i].trainerId;
sPlayers[i].gender = gLinkPlayers[i].gender;
sPlayers[i].battlerId = gLinkPlayers[i].lp_field_18;
sPlayers[i].battlerId = gLinkPlayers[i].id;
sPlayers[i].language = gLinkPlayers[i].language;
if (i < linkPlayersCount)
@@ -1340,7 +1340,7 @@ static void SetRecordedBattleVarsFromSave(struct RecordedBattleSave *src)
}
gLinkPlayers[i].gender = src->playersGender[i];
gLinkPlayers[i].language = src->playersLanguage[i];
gLinkPlayers[i].lp_field_18 = src->playersBattlers[i];
gLinkPlayers[i].id = src->playersBattlers[i];
gLinkPlayers[i].trainerId = src->playersTrainerId[i];
if (var)
@@ -1453,7 +1453,7 @@ u8 GetActiveBattlerLinkPlayerGender(void)
for (i = 0; i < MAX_LINK_PLAYERS; i++)
{
if (gLinkPlayers[i].lp_field_18 == gActiveBattler)
if (gLinkPlayers[i].id == gActiveBattler)
break;
}
+57 -55
View File
@@ -22,6 +22,8 @@
#include "field_effect.h"
#include "region_map.h"
#include "constants/region_map_sections.h"
#include "heal_location.h"
#include "constants/heal_locations.h"
#define MAP_WIDTH 28
#define MAP_HEIGHT 15
@@ -52,7 +54,7 @@ static EWRAM_DATA struct {
/*0x88c*/ u8 unk_88c[0x1c0];
/*0xa4c*/ u8 unk_a4c[0x26];
/*0xa72*/ bool8 unk_a72;
} *gUnknown_0203A148 = NULL; // a74
} *sFlyMap = NULL; // a74
static bool32 gUnknown_03001180;
static bool32 gUnknown_03001184;
@@ -242,23 +244,23 @@ static const u16 Unknown_085A1D48[] = INCBIN_U16("graphics/pokenav/fly_target_ic
static const u8 sUnknown_085A1D68[] = INCBIN_U8("graphics/pokenav/fly_target_icons.4bpp.lz");
static const u8 sUnknown_085A1E3C[][3] = {
{MAP_GROUP(LITTLEROOT_TOWN), MAP_NUM(LITTLEROOT_TOWN), 1},
{MAP_GROUP(OLDALE_TOWN), MAP_NUM(OLDALE_TOWN), 14},
{MAP_GROUP(DEWFORD_TOWN), MAP_NUM(DEWFORD_TOWN), 15},
{MAP_GROUP(LAVARIDGE_TOWN), MAP_NUM(LAVARIDGE_TOWN), 16},
{MAP_GROUP(FALLARBOR_TOWN), MAP_NUM(FALLARBOR_TOWN), 17},
{MAP_GROUP(VERDANTURF_TOWN), MAP_NUM(VERDANTURF_TOWN), 18},
{MAP_GROUP(PACIFIDLOG_TOWN), MAP_NUM(PACIFIDLOG_TOWN), 19},
{MAP_GROUP(PETALBURG_CITY), MAP_NUM(PETALBURG_CITY), 3},
{MAP_GROUP(SLATEPORT_CITY), MAP_NUM(SLATEPORT_CITY), 4},
{MAP_GROUP(MAUVILLE_CITY), MAP_NUM(MAUVILLE_CITY), 5},
{MAP_GROUP(RUSTBORO_CITY), MAP_NUM(RUSTBORO_CITY), 6},
{MAP_GROUP(FORTREE_CITY), MAP_NUM(FORTREE_CITY), 7},
{MAP_GROUP(LILYCOVE_CITY), MAP_NUM(LILYCOVE_CITY), 8},
{MAP_GROUP(MOSSDEEP_CITY), MAP_NUM(MOSSDEEP_CITY), 9},
{MAP_GROUP(SOOTOPOLIS_CITY), MAP_NUM(SOOTOPOLIS_CITY), 10},
{MAP_GROUP(EVER_GRANDE_CITY), MAP_NUM(EVER_GRANDE_CITY), 11},
static const u8 sMapHealLocations[][3] = {
{MAP_GROUP(LITTLEROOT_TOWN), MAP_NUM(LITTLEROOT_TOWN), HEAL_LOCATION_LITTLEROOT_TOWN_BRENDANS_HOUSE_2F},
{MAP_GROUP(OLDALE_TOWN), MAP_NUM(OLDALE_TOWN), HEAL_LOCATION_OLDALE_TOWN},
{MAP_GROUP(DEWFORD_TOWN), MAP_NUM(DEWFORD_TOWN), HEAL_LOCATION_DEWFORD_TOWN},
{MAP_GROUP(LAVARIDGE_TOWN), MAP_NUM(LAVARIDGE_TOWN), HEAL_LOCATION_LAVARIDGE_TOWN},
{MAP_GROUP(FALLARBOR_TOWN), MAP_NUM(FALLARBOR_TOWN), HEAL_LOCATION_FALLARBOR_TOWN},
{MAP_GROUP(VERDANTURF_TOWN), MAP_NUM(VERDANTURF_TOWN), HEAL_LOCATION_VERDANTURF_TOWN},
{MAP_GROUP(PACIFIDLOG_TOWN), MAP_NUM(PACIFIDLOG_TOWN), HEAL_LOCATION_PACIFIDLOG_TOWN},
{MAP_GROUP(PETALBURG_CITY), MAP_NUM(PETALBURG_CITY), HEAL_LOCATION_PETALBURG_CITY},
{MAP_GROUP(SLATEPORT_CITY), MAP_NUM(SLATEPORT_CITY), HEAL_LOCATION_SLATEPORT_CITY},
{MAP_GROUP(MAUVILLE_CITY), MAP_NUM(MAUVILLE_CITY), HEAL_LOCATION_MAUVILLE_CITY},
{MAP_GROUP(RUSTBORO_CITY), MAP_NUM(RUSTBORO_CITY), HEAL_LOCATION_RUSTBORO_CITY},
{MAP_GROUP(FORTREE_CITY), MAP_NUM(FORTREE_CITY), HEAL_LOCATION_FORTREE_CITY},
{MAP_GROUP(LILYCOVE_CITY), MAP_NUM(LILYCOVE_CITY), HEAL_LOCATION_LILYCOVE_CITY},
{MAP_GROUP(MOSSDEEP_CITY), MAP_NUM(MOSSDEEP_CITY), HEAL_LOCATION_MOSSDEEP_CITY},
{MAP_GROUP(SOOTOPOLIS_CITY), MAP_NUM(SOOTOPOLIS_CITY), HEAL_LOCATION_SOOTOPOLIS_CITY},
{MAP_GROUP(EVER_GRANDE_CITY), MAP_NUM(EVER_GRANDE_CITY), HEAL_LOCATION_EVER_GRANDE_CITY_1},
{MAP_GROUP(ROUTE101), MAP_NUM(ROUTE101), 0},
{MAP_GROUP(ROUTE102), MAP_NUM(ROUTE102), 0},
{MAP_GROUP(ROUTE103), MAP_NUM(ROUTE103), 0},
@@ -1578,8 +1580,8 @@ void MCB2_FlyMap(void)
SetGpuReg(REG_OFFSET_BG2HOFS, 0);
SetGpuReg(REG_OFFSET_BG3HOFS, 0);
SetGpuReg(REG_OFFSET_BG3VOFS, 0);
gUnknown_0203A148 = malloc(sizeof(*gUnknown_0203A148));
if (gUnknown_0203A148 == NULL)
sFlyMap = malloc(sizeof(*sFlyMap));
if (sFlyMap == NULL)
{
SetMainCallback2(CB2_ReturnToFieldWithOpenMenu);
}
@@ -1608,11 +1610,11 @@ void MCB2_FlyMap(void)
gMain.state++;
break;
case 4:
InitRegionMap(&gUnknown_0203A148->regionMap, FALSE);
InitRegionMap(&sFlyMap->regionMap, FALSE);
CreateRegionMapCursor(0, 0);
CreateRegionMapPlayerIcon(1, 1);
gUnknown_0203A148->mapSecId = gUnknown_0203A148->regionMap.mapSecId;
StringFill(gUnknown_0203A148->unk_a4c, CHAR_SPACE, 16);
sFlyMap->mapSecId = sFlyMap->regionMap.mapSecId;
StringFill(sFlyMap->unk_a4c, CHAR_SPACE, 16);
gUnknown_03001180 = TRUE;
sub_8124904();
gMain.state++;
@@ -1664,7 +1666,7 @@ static void sub_81248C0(void)
static void sub_81248D4(void)
{
gUnknown_0203A148->unk_000();
sFlyMap->unk_000();
AnimateSprites();
BuildOamBuffer();
do_scheduled_bg_tilemap_copies_to_vram();
@@ -1672,8 +1674,8 @@ static void sub_81248D4(void)
static void sub_81248F4(void callback(void))
{
gUnknown_0203A148->unk_000 = callback;
gUnknown_0203A148->unk_004 = 0;
sFlyMap->unk_000 = callback;
sFlyMap->unk_004 = 0;
}
static void sub_8124904(void)
@@ -1682,21 +1684,21 @@ static void sub_8124904(void)
bool32 flag;
const u8 *name;
if (gUnknown_0203A148->regionMap.iconDrawType > MAPSECTYPE_NONE && gUnknown_0203A148->regionMap.iconDrawType <= MAPSECTYPE_BATTLE_FRONTIER)
if (sFlyMap->regionMap.iconDrawType > MAPSECTYPE_NONE && sFlyMap->regionMap.iconDrawType <= MAPSECTYPE_BATTLE_FRONTIER)
{
flag = FALSE;
for (i = 0; i < 1; i++)
{
if (gUnknown_0203A148->regionMap.mapSecId == gUnknown_085A1EDC[i].mapSecId)
if (sFlyMap->regionMap.mapSecId == gUnknown_085A1EDC[i].mapSecId)
{
if (FlagGet(gUnknown_085A1EDC[i].flag))
{
StringLength(gUnknown_085A1EDC[i].name[gUnknown_0203A148->regionMap.posWithinMapSec]);
StringLength(gUnknown_085A1EDC[i].name[sFlyMap->regionMap.posWithinMapSec]);
flag = TRUE;
sub_8198070(0, FALSE);
SetWindowBorderStyle(1, FALSE, 0x65, 0x0d);
PrintTextOnWindow(1, 1, gUnknown_0203A148->regionMap.mapSecName, 0, 1, 0, NULL);
name = gUnknown_085A1EDC[i].name[gUnknown_0203A148->regionMap.posWithinMapSec];
PrintTextOnWindow(1, 1, sFlyMap->regionMap.mapSecName, 0, 1, 0, NULL);
name = gUnknown_085A1EDC[i].name[sFlyMap->regionMap.posWithinMapSec];
PrintTextOnWindow(1, 1, name, GetStringRightAlignXOffset(1, name, 0x60), 0x11, 0, NULL);
schedule_bg_copy_tilemap_to_vram(0);
gUnknown_03001180 = TRUE;
@@ -1715,7 +1717,7 @@ static void sub_8124904(void)
{
FillWindowPixelBuffer(0, 0x11);
}
PrintTextOnWindow(0, 1, gUnknown_0203A148->regionMap.mapSecName, 0, 1, 0, NULL);
PrintTextOnWindow(0, 1, sFlyMap->regionMap.mapSecName, 0, 1, 0, NULL);
schedule_bg_copy_tilemap_to_vram(0);
gUnknown_03001180 = FALSE;
}
@@ -1739,8 +1741,8 @@ static void sub_8124A70(void)
{
struct SpriteSheet sheet;
LZ77UnCompWram(sUnknown_085A1D68, gUnknown_0203A148->unk_88c);
sheet.data = gUnknown_0203A148->unk_88c;
LZ77UnCompWram(sUnknown_085A1D68, sFlyMap->unk_88c);
sheet.data = sFlyMap->unk_88c;
sheet.size = 0x1c0;
sheet.tag = 2;
LoadSpriteSheet(&sheet);
@@ -1829,7 +1831,7 @@ static void sub_8124BE4(void)
static void sub_8124CBC(struct Sprite *sprite)
{
if (gUnknown_0203A148->regionMap.mapSecId == sprite->data[0])
if (sFlyMap->regionMap.mapSecId == sprite->data[0])
{
if (++sprite->data[1] > 16)
{
@@ -1846,11 +1848,11 @@ static void sub_8124CBC(struct Sprite *sprite)
static void sub_8124D14(void)
{
switch (gUnknown_0203A148->unk_004)
switch (sFlyMap->unk_004)
{
case 0:
BeginNormalPaletteFade(0xFFFFFFFF, 0, 16, 0, 0);
gUnknown_0203A148->unk_004++;
sFlyMap->unk_004++;
break;
case 1:
if (!UpdatePaletteFade())
@@ -1863,7 +1865,7 @@ static void sub_8124D14(void)
static void sub_8124D64(void)
{
if (gUnknown_0203A148->unk_004 == 0)
if (sFlyMap->unk_004 == 0)
{
switch (sub_81230AC())
{
@@ -1875,16 +1877,16 @@ static void sub_8124D64(void)
sub_8124904();
break;
case INPUT_EVENT_A_BUTTON:
if (gUnknown_0203A148->regionMap.iconDrawType == MAPSECTYPE_CITY_CANFLY || gUnknown_0203A148->regionMap.iconDrawType == MAPSECTYPE_BATTLE_FRONTIER)
if (sFlyMap->regionMap.iconDrawType == MAPSECTYPE_CITY_CANFLY || sFlyMap->regionMap.iconDrawType == MAPSECTYPE_BATTLE_FRONTIER)
{
m4aSongNumStart(SE_SELECT);
gUnknown_0203A148->unk_a72 = TRUE;
sFlyMap->unk_a72 = TRUE;
sub_81248F4(sub_8124E0C);
}
break;
case INPUT_EVENT_B_BUTTON:
m4aSongNumStart(SE_SELECT);
gUnknown_0203A148->unk_a72 = FALSE;
sFlyMap->unk_a72 = FALSE;
sub_81248F4(sub_8124E0C);
break;
}
@@ -1893,40 +1895,40 @@ static void sub_8124D64(void)
static void sub_8124E0C(void)
{
switch (gUnknown_0203A148->unk_004)
switch (sFlyMap->unk_004)
{
case 0:
BeginNormalPaletteFade(0xFFFFFFFF, 0, 0, 16, 0);
gUnknown_0203A148->unk_004++;
sFlyMap->unk_004++;
break;
case 1:
if (!UpdatePaletteFade())
{
FreeRegionMapIconResources();
if (gUnknown_0203A148->unk_a72)
if (sFlyMap->unk_a72)
{
switch (gUnknown_0203A148->regionMap.mapSecId)
switch (sFlyMap->regionMap.mapSecId)
{
case MAPSEC_SOUTHERN_ISLAND:
sub_8084CCC(0x15);
sub_8084CCC(HEAL_LOCATION_SOUTHERN_ISLAND_EXTERIOR);
break;
case MAPSEC_BATTLE_FRONTIER:
sub_8084CCC(0x16);
sub_8084CCC(HEAL_LOCATION_BATTLE_FRONTIER_OUTSIDE_EAST);
break;
case MAPSEC_LITTLEROOT_TOWN:
sub_8084CCC(gSaveBlock2Ptr->playerGender == MALE ? 0x0C : 0x0D);
sub_8084CCC(gSaveBlock2Ptr->playerGender == MALE ? HEAL_LOCATION_LITTLEROOT_TOWN_1 : HEAL_LOCATION_LITTLEROOT_TOWN_2);
break;
case MAPSEC_EVER_GRANDE_CITY:
sub_8084CCC(FlagGet(FLAG_LANDMARK_POKEMON_LEAGUE) && gUnknown_0203A148->regionMap.posWithinMapSec == 0 ? 0x14 : 0x0B);
sub_8084CCC(FlagGet(FLAG_LANDMARK_POKEMON_LEAGUE) && sFlyMap->regionMap.posWithinMapSec == 0 ? HEAL_LOCATION_EVER_GRANDE_CITY_2 : HEAL_LOCATION_EVER_GRANDE_CITY_1);
break;
default:
if (sUnknown_085A1E3C[gUnknown_0203A148->regionMap.mapSecId][2] != 0)
if (sMapHealLocations[sFlyMap->regionMap.mapSecId][2] != 0)
{
sub_8084CCC(sUnknown_085A1E3C[gUnknown_0203A148->regionMap.mapSecId][2]);
sub_8084CCC(sMapHealLocations[sFlyMap->regionMap.mapSecId][2]);
}
else
{
warp1_set_2(sUnknown_085A1E3C[gUnknown_0203A148->regionMap.mapSecId][0], sUnknown_085A1E3C[gUnknown_0203A148->regionMap.mapSecId][1], -1);
warp1_set_2(sMapHealLocations[sFlyMap->regionMap.mapSecId][0], sMapHealLocations[sFlyMap->regionMap.mapSecId][1], -1);
}
break;
}
@@ -1936,10 +1938,10 @@ static void sub_8124E0C(void)
{
SetMainCallback2(sub_81B58A8);
}
if (gUnknown_0203A148 != NULL)
if (sFlyMap != NULL)
{
free(gUnknown_0203A148);
gUnknown_0203A148 = NULL;
free(sFlyMap);
sFlyMap = NULL;
}
FreeAllWindowBuffers();
}
+3256 -10
View File
File diff suppressed because it is too large Load Diff
-6
View File
@@ -189,12 +189,6 @@ struct RotatingGatePuzzle
u8 orientation;
};
struct Coords8
{
s8 deltaX;
s8 deltaY;
};
// .rodata
// Fortree
static const struct RotatingGatePuzzle sRotatingGate_FortreePuzzleConfig[] =
+2 -2
View File
@@ -31,7 +31,7 @@ extern void IncrementGameStat(u8 index);
extern void ScriptContext1_SetupScript(u8*);
extern void ScriptContext2_RunNewScript(u8*);
extern void CB2_ReturnToField(void);
extern void CB2_ReturnToFieldContinueScript(void);
extern void CB2_ReturnToFieldContinueScriptPlayMapMusic(void);
extern void CB2_LoadMap(void);
extern void sub_80AF6F0(void);
extern void ScriptContext1_Stop(void);
@@ -125,7 +125,7 @@ void CB2_EndSafariBattle(void)
{
ScriptContext1_SetupScript(EventScript_2A4B9B);
ScriptContext1_Stop();
SetMainCallback2(CB2_ReturnToFieldContinueScript);
SetMainCallback2(CB2_ReturnToFieldContinueScriptPlayMapMusic);
}
}
+2 -2
View File
@@ -1515,7 +1515,7 @@ bool8 ScrCmd_braillemessage(struct ScriptContext *ctx)
xText = (xWindow - xText - 1) * 8 + 3;
yText = (yText - yWindow - 1) * 8;
winTemplate = sub_8198A50(0, xWindow, yWindow + 1, width, height, 0xF, 0x1);
winTemplate = CreateWindowTemplate(0, xWindow, yWindow + 1, width, height, 0xF, 0x1);
gUnknown_03000F30 = AddWindow(&winTemplate);
LoadUserWindowBorderGfx(gUnknown_03000F30, 0x214, 0xE0);
NewMenuHelpers_DrawStdWindowFrame(gUnknown_03000F30, 0);
@@ -1909,7 +1909,7 @@ bool8 ScrCmd_playslotmachine(struct ScriptContext *ctx)
{
u8 slotMachineIndex = VarGet(ScriptReadHalfword(ctx));
PlaySlotMachine(slotMachineIndex, CB2_ReturnToFieldContinueScript);
PlaySlotMachine(slotMachineIndex, CB2_ReturnToFieldContinueScriptPlayMapMusic);
ScriptContext1_Stop();
return TRUE;
}
+2051
View File
File diff suppressed because it is too large Load Diff
+2 -2
View File
@@ -13,7 +13,7 @@
extern u8 GetKeypadIconWidth(u8 keypadIconId);
extern u16 Font6Func(struct TextPrinter *textPrinter);
extern u32 GetGlyphWidthFont6(u16 glyphId, bool32 isJapanese);
extern u8* UnkTextUtil_GetPtrI(u8 a1);
extern u8* DynamicPlaceholderTextUtil_GetPlaceholderPtr(u8 a1);
extern int sub_8197964();
EWRAM_DATA struct TextPrinter gTempTextPrinter = {0};
@@ -3227,7 +3227,7 @@ u32 GetStringWidth(u8 fontId, const u8 *str, s16 letterSpacing)
}
case 0xF7:
if (bufferPointer == NULL)
bufferPointer = UnkTextUtil_GetPtrI(*++str);
bufferPointer = DynamicPlaceholderTextUtil_GetPlaceholderPtr(*++str);
while (*bufferPointer != 0xFF)
{
glyphWidth = func(*bufferPointer++, isJapanese);
+2 -2
View File
@@ -3454,7 +3454,7 @@ void ChangePokemonNickname(void)
void ChangePokemonNickname_CB(void)
{
SetMonData(&gPlayerParty[gSpecialVar_0x8004], MON_DATA_NICKNAME, gStringVar2);
CB2_ReturnToFieldContinueScript();
CB2_ReturnToFieldContinueScriptPlayMapMusic();
}
void ChangeBoxPokemonNickname(void)
@@ -3470,7 +3470,7 @@ void ChangeBoxPokemonNickname(void)
void ChangeBoxPokemonNickname_CB(void)
{
SetBoxMonNickFromAnyBox(gSpecialVar_MonBoxId, gSpecialVar_MonBoxPos, gStringVar2);
CB2_ReturnToFieldContinueScript();
CB2_ReturnToFieldContinueScriptPlayMapMusic();
}
void TV_CopyNicknameToStringVar1AndEnsureTerminated(void)
-1
View File
@@ -13,7 +13,6 @@ extern const u8 gText_Peekaboo[];
extern u8 *GetWaldaPhrasePtr(void);
extern bool32 IsWaldaPhraseEmpty(void);
extern void sub_80AF168(void);
extern void CB2_ReturnToField(void);
extern void SetWaldaPhrase(const u8 *src);
extern void SetWaldaWallpaperPatternId(u8 patternId);
extern void SetWaldaWallpaperIconId(u8 iconId);
+2 -2
View File
@@ -602,7 +602,7 @@ static void WallClockInit(void)
ShowBg(3);
}
void Cb2_StartWallClock(void)
void CB2_StartWallClock(void)
{
u8 taskId;
u8 spriteId;
@@ -644,7 +644,7 @@ void Cb2_StartWallClock(void)
schedule_bg_copy_tilemap_to_vram(2);
}
void Cb2_ViewWallClock(void)
void CB2_ViewWallClock(void)
{
u8 taskId;
u8 spriteId;