From 9da11d64dfca72c923d8b337fb8c8cc124ef57fc Mon Sep 17 00:00:00 2001 From: Viperio19 Date: Mon, 18 Nov 2024 20:15:27 +0100 Subject: [PATCH 01/11] Rename variable and function names related to overworld poison damage --- include/field_overworld_state.h | 6 ++-- include/overlay005/ov5_021EF4BC.h | 2 +- include/struct_decls/struct_0203A790_decl.h | 2 +- include/unk_02054884.h | 2 +- src/encounter.c | 2 +- src/field_battle_data_transfer.c | 2 +- src/field_menu.c | 2 +- src/field_overworld_state.c | 20 +++++------ src/overlay005/field_control.c | 12 +++---- src/overlay005/ov5_021EF4BC.c | 2 +- src/overlay006/ov6_02240C9C.c | 2 +- src/scrcmd.c | 4 +-- src/unk_02054884.c | 40 ++++++++++----------- 13 files changed, 49 insertions(+), 49 deletions(-) diff --git a/include/field_overworld_state.h b/include/field_overworld_state.h index 1697751b56..4ca05cf6d6 100644 --- a/include/field_overworld_state.h +++ b/include/field_overworld_state.h @@ -30,9 +30,9 @@ UnkStruct_020556C4 *sub_0203A76C(FieldOverworldState *param0); int FieldOverworldState_GetCameraType(const FieldOverworldState *param0); void FieldOverworldState_SetCameraType(FieldOverworldState *param0, int param1); PlayerData *FieldOverworldState_GetPlayerData(FieldOverworldState *param0); -u16 *sub_0203A784(FieldOverworldState *param0); -u16 *sub_0203A788(FieldOverworldState *param0); -u16 *sub_0203A78C(FieldOverworldState *param0); +u16 *FieldOverworldState_GetSafariBallCount(FieldOverworldState *param0); +u16 *FieldOverworldState_GetSafariStepCount(FieldOverworldState *param0); +u16 *FieldOverworldState_GetPoisonStepCount(FieldOverworldState *param0); FieldOverworldState *SaveData_GetFieldOverworldState(SaveData *param0); FieldOverworldSave *SaveData_GetFieldOverworldSave(SaveData *param0); void FieldSystem_SaveObjects(FieldSystem *fieldSystem); diff --git a/include/overlay005/ov5_021EF4BC.h b/include/overlay005/ov5_021EF4BC.h index 374b2c6c1d..13f32c4302 100644 --- a/include/overlay005/ov5_021EF4BC.h +++ b/include/overlay005/ov5_021EF4BC.h @@ -7,6 +7,6 @@ UnkStruct_ov5_021EF4F8 *ov5_021EF4BC(u32 param0, HBlankSystem *param1); void ov5_021EF4F8(UnkStruct_ov5_021EF4F8 *param0); -void ov5_021EF518(UnkStruct_ov5_021EF4F8 *param0); +void Field_DoPoisonEffect(UnkStruct_ov5_021EF4F8 *param0); #endif // POKEPLATINUM_OV5_021EF4BC_H diff --git a/include/struct_decls/struct_0203A790_decl.h b/include/struct_decls/struct_0203A790_decl.h index 49d0f0f980..78621e74fd 100644 --- a/include/struct_decls/struct_0203A790_decl.h +++ b/include/struct_decls/struct_0203A790_decl.h @@ -1,6 +1,6 @@ #ifndef POKEPLATINUM_STRUCT_0203A790_DECL_H #define POKEPLATINUM_STRUCT_0203A790_DECL_H -typedef struct UnkStruct_0203A790_t FieldOverworldState; +typedef struct FieldOverworldState FieldOverworldState; #endif // POKEPLATINUM_STRUCT_0203A790_DECL_H diff --git a/include/unk_02054884.h b/include/unk_02054884.h index 256f17699e..aa5768c246 100644 --- a/include/unk_02054884.h +++ b/include/unk_02054884.h @@ -18,7 +18,7 @@ Pokemon *Party_FindFirstEligibleBattler(const Party *party); Pokemon *Party_FindFirstHatchedMon(const Party *party); BOOL Party_HasTwoAliveMons(const Party *party); void Party_GiveChampionRibbons(Party *party); -int sub_02054B04(Party *param0, u16 param1); +int Pokemon_DoPoisonDamage(Party *param0, u16 param1); BOOL Pokemon_TrySurvivePoison(Pokemon *mon); #endif // POKEPLATINUM_UNK_02054884_H diff --git a/src/encounter.c b/src/encounter.c index 0abdf505b2..bdb0be7235 100644 --- a/src/encounter.c +++ b/src/encounter.c @@ -457,7 +457,7 @@ static BOOL FieldTask_SafariEncounter(FieldTask *task) FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); Encounter *encounter = FieldTask_GetEnv(task); int *state = FieldTask_GetState(task); - u16 *ballCount = sub_0203A784(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *ballCount = FieldOverworldState_GetSafariBallCount(SaveData_GetFieldOverworldState(fieldSystem->saveData)); switch (*state) { case 0: diff --git a/src/field_battle_data_transfer.c b/src/field_battle_data_transfer.c index d4fe908bb0..9e6175bc7c 100644 --- a/src/field_battle_data_transfer.c +++ b/src/field_battle_data_transfer.c @@ -429,7 +429,7 @@ void FieldBattleDTO_UpdateFieldSystem(const FieldBattleDTO *dto, FieldSystem *fi Party *party = Party_GetFromSavedata(fieldSystem->saveData); Bag *bag = SaveData_GetBag(fieldSystem->saveData); PokedexData *pokedex = SaveData_Pokedex(fieldSystem->saveData); - u16 *fieldSysSafariBalls = sub_0203A784(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *fieldSysSafariBalls = FieldOverworldState_GetSafariBallCount(SaveData_GetFieldOverworldState(fieldSystem->saveData)); TrainerInfo_Copy(dto->trainerInfo[BATTLER_PLAYER_SLOT_1], trainerInfo); Party_cpy(dto->parties[BATTLER_PLAYER_SLOT_1], party); diff --git a/src/field_menu.c b/src/field_menu.c index c310f52451..e394741610 100644 --- a/src/field_menu.c +++ b/src/field_menu.c @@ -686,7 +686,7 @@ static void sub_0203B094(FieldTask *taskMan) v5 = MessageLoader_GetNewStrbuf(v2, 11); if (v6 == 0) { - u16 *v7 = sub_0203A784(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *v7 = FieldOverworldState_GetSafariBallCount(SaveData_GetFieldOverworldState(fieldSystem->saveData)); StringTemplate_SetNumber(v3, 0, *v7, 2, 0, 1); } else { diff --git a/src/field_overworld_state.c b/src/field_overworld_state.c index b45449dd5c..09f14f9859 100644 --- a/src/field_overworld_state.c +++ b/src/field_overworld_state.c @@ -16,7 +16,7 @@ #include "unk_0203A7D8.h" #include "unk_020556C4.h" -typedef struct UnkStruct_0203A790_t { +typedef struct FieldOverworldState { Location player; Location entrance; Location previous; @@ -28,9 +28,9 @@ typedef struct UnkStruct_0203A790_t { u8 cameraType; UnkStruct_020556C4 unk_6C; PlayerData playerData; - u16 unk_94; - u16 unk_96; - u16 unk_98; + u16 poisonSteps; + u16 safariSteps; + u16 safariBalls; u16 unk_9A; u16 unk_9C; } FieldOverworldState; @@ -140,19 +140,19 @@ PlayerData *FieldOverworldState_GetPlayerData(FieldOverworldState *fieldState) return &fieldState->playerData; } -u16 *sub_0203A784(FieldOverworldState *fieldState) +u16 *FieldOverworldState_GetSafariBallCount(FieldOverworldState *fieldState) { - return &fieldState->unk_98; + return &fieldState->safariBalls; } -u16 *sub_0203A788(FieldOverworldState *fieldState) +u16 *FieldOverworldState_GetSafariStepCount(FieldOverworldState *fieldState) { - return &fieldState->unk_96; + return &fieldState->safariSteps; } -u16 *sub_0203A78C(FieldOverworldState *fieldState) +u16 *FieldOverworldState_GetPoisonStepCount(FieldOverworldState *fieldState) { - return &fieldState->unk_94; + return &fieldState->poisonSteps; } FieldOverworldState *SaveData_GetFieldOverworldState(SaveData *saveData) diff --git a/src/overlay005/field_control.c b/src/overlay005/field_control.c index 409c05b058..4e17a8a9aa 100644 --- a/src/overlay005/field_control.c +++ b/src/overlay005/field_control.c @@ -896,7 +896,7 @@ static void Field_CalculateFriendship(FieldSystem *fieldSystem) static BOOL Field_UpdatePoison(FieldSystem *fieldSystem) { Party *party = Party_GetFromSavedata(fieldSystem->saveData); - u16 *poisonSteps = sub_0203A78C(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *poisonSteps = FieldOverworldState_GetPoisonStepCount(SaveData_GetFieldOverworldState(fieldSystem->saveData)); (*poisonSteps)++; (*poisonSteps) %= 4; @@ -905,14 +905,14 @@ static BOOL Field_UpdatePoison(FieldSystem *fieldSystem) return FALSE; } - switch (sub_02054B04(party, MapHeader_GetMapLabelTextID(fieldSystem->location->mapId))) { + switch (Pokemon_DoPoisonDamage(party, MapHeader_GetMapLabelTextID(fieldSystem->location->mapId))) { case 0: return FALSE; case 1: - ov5_021EF518(fieldSystem->unk_04->unk_20); + Field_DoPoisonEffect(fieldSystem->unk_04->unk_20); return FALSE; case 2: - ov5_021EF518(fieldSystem->unk_04->unk_20); + Field_DoPoisonEffect(fieldSystem->unk_04->unk_20); ScriptManager_Set(fieldSystem, 2003, NULL); return TRUE; } @@ -926,14 +926,14 @@ static BOOL Field_UpdateSafari(FieldSystem *fieldSystem) return FALSE; } - u16 *balls = sub_0203A784(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *balls = FieldOverworldState_GetSafariBallCount(SaveData_GetFieldOverworldState(fieldSystem->saveData)); if (*balls == 0) { ScriptManager_Set(fieldSystem, 8802, NULL); return TRUE; } - u16 *steps = sub_0203A788(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *steps = FieldOverworldState_GetSafariStepCount(SaveData_GetFieldOverworldState(fieldSystem->saveData)); (*steps)++; if (*steps >= 500) { diff --git a/src/overlay005/ov5_021EF4BC.c b/src/overlay005/ov5_021EF4BC.c index feacd7321a..cfea846be6 100644 --- a/src/overlay005/ov5_021EF4BC.c +++ b/src/overlay005/ov5_021EF4BC.c @@ -60,7 +60,7 @@ void ov5_021EF4F8(UnkStruct_ov5_021EF4F8 *param0) Heap_FreeToHeap(param0); } -void ov5_021EF518(UnkStruct_ov5_021EF4F8 *param0) +void Field_DoPoisonEffect(UnkStruct_ov5_021EF4F8 *param0) { GF_ASSERT(param0->unk_00 == 0); diff --git a/src/overlay006/ov6_02240C9C.c b/src/overlay006/ov6_02240C9C.c index 0a22916da7..8a1280ed4d 100644 --- a/src/overlay006/ov6_02240C9C.c +++ b/src/overlay006/ov6_02240C9C.c @@ -1389,7 +1389,7 @@ static void ov6_02242328(FieldSystem *fieldSystem, const BOOL param1, FieldBattl if (!param1) { *param2 = FieldBattleDTO_New(11, (0x0 | 0x0)); } else { - u16 *v0 = sub_0203A784(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *v0 = FieldOverworldState_GetSafariBallCount(SaveData_GetFieldOverworldState(fieldSystem->saveData)); *param2 = FieldBattleDTO_NewSafari(11, *v0); } } diff --git a/src/scrcmd.c b/src/scrcmd.c index 629dcb0780..a476266fbe 100644 --- a/src/scrcmd.c +++ b/src/scrcmd.c @@ -6381,8 +6381,8 @@ static BOOL ScrCmd_202(ScriptContext *ctx) TVBroadcast *v4 = SaveData_TVBroadcast(ctx->fieldSystem->saveData); int v5 = ScriptContext_ReadByte(ctx); - v0 = sub_0203A784(v2); - v1 = sub_0203A788(v2); + v0 = FieldOverworldState_GetSafariBallCount(v2); + v1 = FieldOverworldState_GetSafariStepCount(v2); switch (v5) { case 0: diff --git a/src/unk_02054884.c b/src/unk_02054884.c index 6f3147480f..cf492754ec 100644 --- a/src/unk_02054884.c +++ b/src/unk_02054884.c @@ -175,41 +175,41 @@ void Party_GiveChampionRibbons(Party *party) } } -int sub_02054B04(Party *param0, u16 param1) +int Pokemon_DoPoisonDamage(Party *param0, u16 param1) { - int v0 = 0; - int v1 = 0; - int v2, v3; - Pokemon *v4; + int numPoisoned = 0; + int numFainted = 0; + int i, partyCount; + Pokemon *mon; - v3 = Party_GetCurrentCount(param0); + partyCount = Party_GetCurrentCount(param0); - for (v2 = 0; v2 < v3; v2++) { - v4 = Party_GetPokemonBySlotIndex(param0, v2); + for (i = 0; i < partyCount; i++) { + mon = Party_GetPokemonBySlotIndex(param0, i); - if (Pokemon_CanBattle(v4)) { - if (Pokemon_GetValue(v4, MON_DATA_STATUS_CONDITION, NULL) & (MON_CONDITION_TOXIC | MON_CONDITION_POISON)) { - u32 v5 = Pokemon_GetValue(v4, MON_DATA_CURRENT_HP, NULL); + if (Pokemon_CanBattle(mon)) { + if (Pokemon_GetValue(mon, MON_DATA_STATUS_CONDITION, NULL) & (MON_CONDITION_TOXIC | MON_CONDITION_POISON)) { + u32 hp = Pokemon_GetValue(mon, MON_DATA_CURRENT_HP, NULL); - if (v5 > 1) { - v5--; + if (hp > 1) { + hp--; } - Pokemon_SetValue(v4, MON_DATA_CURRENT_HP, &v5); + Pokemon_SetValue(mon, MON_DATA_CURRENT_HP, &hp); - if (v5 == 1) { - v1++; - Pokemon_UpdateFriendship(v4, 7, param1); + if (hp == 1) { + numFainted++; + Pokemon_UpdateFriendship(mon, 7, param1); } - v0++; + numPoisoned++; } } } - if (v1) { + if (numFainted) { return 2; - } else if (v0) { + } else if (numPoisoned) { return 1; } else { return 0; From 00890c62623f431de6a88de60d93bc04fb44afc8 Mon Sep 17 00:00:00 2001 From: Viperio19 Date: Mon, 18 Nov 2024 20:50:16 +0100 Subject: [PATCH 02/11] Rename variable and function names from field_overworld_state.c --- include/field_overworld_state.h | 4 ++-- include/inlines.h | 2 +- include/unk_020553DC.h | 4 ++-- src/field_overworld_state.c | 16 ++++++++-------- src/overlay005/field_control.c | 2 +- src/overlay005/ov5_021DFB54.c | 2 +- src/overlay006/ov6_02247100.c | 2 +- src/scrcmd.c | 8 ++++---- src/unk_020482D4.c | 2 +- src/unk_020528D0.c | 2 +- src/unk_02052C6C.c | 2 +- src/unk_020553DC.c | 14 +++++++------- src/unk_020683F4.c | 4 ++-- src/unk_0206B70C.c | 2 +- 14 files changed, 33 insertions(+), 33 deletions(-) diff --git a/include/field_overworld_state.h b/include/field_overworld_state.h index 4ca05cf6d6..19533ee191 100644 --- a/include/field_overworld_state.h +++ b/include/field_overworld_state.h @@ -18,10 +18,10 @@ void FieldOverworldState_Init(FieldOverworldState *param0); Location *FieldOverworldState_GetPlayerLocation(FieldOverworldState *param0); Location *FieldOverworldState_GetEntranceLocation(FieldOverworldState *param0); Location *FieldOverworldState_GetPrevLocation(FieldOverworldState *param0); -Location *sub_0203A72C(FieldOverworldState *param0); +Location *FieldOverworldState_GetExitLocation(FieldOverworldState *param0); Location *FieldOverworldState_GetSpecialLocation(FieldOverworldState *param0); void FieldOverworldState_SetSpecialLocation(FieldOverworldState *param0, Location *param1); -u16 *sub_0203A748(FieldOverworldState *param0); +u16 *FieldOverworldState_GetSpecialBGM(FieldOverworldState *param0); u16 FieldOverworldState_GetWeather(const FieldOverworldState *param0); void FieldOverworldState_SetWeather(FieldOverworldState *param0, u16 param1); u16 FieldOverworldState_GetWarpId(const FieldOverworldState *param0); diff --git a/include/inlines.h b/include/inlines.h index f401ccc80d..a0d91f2640 100644 --- a/include/inlines.h +++ b/include/inlines.h @@ -132,7 +132,7 @@ static inline void inline_ov61_0222C3B0_sub(SysTask *param0, void *param1) static inline void inline_ov47_0225621C_sub(FieldSystem *fieldSystem, int *param1, int *param2) { FieldOverworldState *v0 = SaveData_GetFieldOverworldState(fieldSystem->saveData); - Location *location = sub_0203A72C(v0); + Location *location = FieldOverworldState_GetExitLocation(v0); if (MapHeader_IsOnMainMatrix(fieldSystem->location->mapId)) { *param1 = fieldSystem->location->x; diff --git a/include/unk_020553DC.h b/include/unk_020553DC.h index a30d9e5e46..2f43d9aa17 100644 --- a/include/unk_020553DC.h +++ b/include/unk_020553DC.h @@ -4,8 +4,8 @@ #include "field/field_system_decl.h" void sub_020553DC(void); -void sub_020553F0(FieldSystem *fieldSystem, u16 param1); -u16 sub_02055404(FieldSystem *fieldSystem); +void Sound_SetSpecialBGM(FieldSystem *fieldSystem, u16 param1); +u16 Sound_GetSpecialBGM(FieldSystem *fieldSystem); void Sound_ClearSpecialBGM(FieldSystem *fieldSystem); u16 sub_02055428(FieldSystem *fieldSystem, int param1); u16 sub_020554A4(FieldSystem *fieldSystem, int param1); diff --git a/src/field_overworld_state.c b/src/field_overworld_state.c index 09f14f9859..47c48e981d 100644 --- a/src/field_overworld_state.c +++ b/src/field_overworld_state.c @@ -21,8 +21,8 @@ typedef struct FieldOverworldState { Location entrance; Location previous; Location special; - Location unk_50; - u16 unk_64; + Location exit; + u16 bgm; u16 weather; u16 warpId; u8 cameraType; @@ -31,8 +31,8 @@ typedef struct FieldOverworldState { u16 poisonSteps; u16 safariSteps; u16 safariBalls; - u16 unk_9A; - u16 unk_9C; + u16 padding_9A; // unused + u16 padding_9C; // unused } FieldOverworldState; typedef struct UnkStruct_0203A79C_t { @@ -79,9 +79,9 @@ Location *FieldOverworldState_GetPrevLocation(FieldOverworldState *fieldState) return &fieldState->previous; } -Location *sub_0203A72C(FieldOverworldState *fieldState) +Location *FieldOverworldState_GetExitLocation(FieldOverworldState *fieldState) { - return &fieldState->unk_50; + return &fieldState->exit; } Location *FieldOverworldState_GetSpecialLocation(FieldOverworldState *fieldState) @@ -95,9 +95,9 @@ void FieldOverworldState_SetSpecialLocation(FieldOverworldState *fieldState, Loc return; } -u16 *sub_0203A748(FieldOverworldState *fieldState) +u16 *FieldOverworldState_GetSpecialBGM(FieldOverworldState *fieldState) { - return &fieldState->unk_64; + return &fieldState->bgm; } u16 FieldOverworldState_GetWeather(const FieldOverworldState *fieldState) diff --git a/src/overlay005/field_control.c b/src/overlay005/field_control.c index 4e17a8a9aa..96bd09e054 100644 --- a/src/overlay005/field_control.c +++ b/src/overlay005/field_control.c @@ -1025,7 +1025,7 @@ static BOOL Field_MapConnection(const FieldSystem *fieldSystem, int playerX, int static void Field_SetMapConnection(FieldSystem *fieldSystem, const int playerX, const int playerZ, const int playerDir) { FieldOverworldState *v0 = SaveData_GetFieldOverworldState(fieldSystem->saveData); - Location *nextMap = sub_0203A72C(v0); + Location *nextMap = FieldOverworldState_GetExitLocation(v0); (*nextMap) = *(fieldSystem->location); nextMap->faceDirection = playerDir; diff --git a/src/overlay005/ov5_021DFB54.c b/src/overlay005/ov5_021DFB54.c index aeba553703..dad1ceafb0 100644 --- a/src/overlay005/ov5_021DFB54.c +++ b/src/overlay005/ov5_021DFB54.c @@ -624,7 +624,7 @@ static BOOL ov5_021E0160(FieldTask *taskMan) switch (v0->unk_00) { case 0: if (PlayerAvatar_MapDistortionState(v0->playerAvatar) == AVATAR_DISTORTION_STATE_NONE) { - sub_020553F0(v0->fieldSystem, 0); + Sound_SetSpecialBGM(v0->fieldSystem, 0); sub_02055554(v0->fieldSystem, 1151, 1); } diff --git a/src/overlay006/ov6_02247100.c b/src/overlay006/ov6_02247100.c index 267f7d9316..bedf5a8814 100644 --- a/src/overlay006/ov6_02247100.c +++ b/src/overlay006/ov6_02247100.c @@ -154,7 +154,7 @@ static int ov6_02247288(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ sub_0203A7F0(v1, &v2); FieldTask_ChangeMapChangeByDig(taskMan, &v2, param2->unk_08); } else { - Location *v3 = sub_0203A72C(v0); + Location *v3 = FieldOverworldState_GetExitLocation(v0); FieldTask_ChangeMapChangeByDig(taskMan, v3, param2->unk_08); } diff --git a/src/scrcmd.c b/src/scrcmd.c index a476266fbe..148590a685 100644 --- a/src/scrcmd.c +++ b/src/scrcmd.c @@ -4753,14 +4753,14 @@ static BOOL ScrCmd_SetPlayerBike(ScriptContext *ctx) u8 rideBike = ScriptContext_ReadByte(ctx); if (rideBike == TRUE) { - sub_020553F0(ctx->fieldSystem, 1152); + Sound_SetSpecialBGM(ctx->fieldSystem, 1152); sub_02055554(ctx->fieldSystem, 1152, 1); PlayerAvatar_SetRequestStateBit(ctx->fieldSystem->playerAvatar, (1 << 1)); PlayerAvatar_RequestChangeState(ctx->fieldSystem->playerAvatar); } else { PlayerAvatar_SetRequestStateBit(ctx->fieldSystem->playerAvatar, (1 << 0)); PlayerAvatar_RequestChangeState(ctx->fieldSystem->playerAvatar); - sub_020553F0(ctx->fieldSystem, 0); + Sound_SetSpecialBGM(ctx->fieldSystem, 0); sub_02055554(ctx->fieldSystem, sub_02055428(ctx->fieldSystem, ctx->fieldSystem->location->mapId), 1); } @@ -4769,7 +4769,7 @@ static BOOL ScrCmd_SetPlayerBike(ScriptContext *ctx) static BOOL ScrCmd_2BF(ScriptContext *ctx) { - sub_020553F0(ctx->fieldSystem, 1189); + Sound_SetSpecialBGM(ctx->fieldSystem, 1189); return 0; } @@ -7694,7 +7694,7 @@ static BOOL ScrCmd_2B5(ScriptContext *ctx) u16 v1 = ScriptContext_GetVar(ctx); u16 v2 = ScriptContext_GetVar(ctx); FieldOverworldState *v3 = SaveData_GetFieldOverworldState(ctx->fieldSystem->saveData); - Location *location = sub_0203A72C(v3); + Location *location = FieldOverworldState_GetExitLocation(v3); location->mapId = mapId; location->x = v1; diff --git a/src/unk_020482D4.c b/src/unk_020482D4.c index 2b3b7e5cb0..8c7ac51eee 100644 --- a/src/unk_020482D4.c +++ b/src/unk_020482D4.c @@ -68,7 +68,7 @@ BOOL ScrCmd_PlayDefaultMusic(ScriptContext *ctx) BOOL ScrCmd_053(ScriptContext *param0) { - sub_020553F0(param0->fieldSystem, ScriptContext_ReadHalfWord(param0)); + Sound_SetSpecialBGM(param0->fieldSystem, ScriptContext_ReadHalfWord(param0)); return 0; } diff --git a/src/unk_020528D0.c b/src/unk_020528D0.c index a8b9d2c47d..9a006784d9 100644 --- a/src/unk_020528D0.c +++ b/src/unk_020528D0.c @@ -220,7 +220,7 @@ BOOL sub_02052B2C(FieldTask *param0) u16 v4 = FieldOverworldState_GetWarpId(v3); sub_0203A824(v4, &v2); - sub_0203A7F0(v4, sub_0203A72C(v3)); + sub_0203A7F0(v4, FieldOverworldState_GetExitLocation(v3)); FieldTask_ChangeMapByLocation(param0, &v2); sub_020705B4(fieldSystem); } diff --git a/src/unk_02052C6C.c b/src/unk_02052C6C.c index bfc2ba29ac..cc3824b04c 100644 --- a/src/unk_02052C6C.c +++ b/src/unk_02052C6C.c @@ -184,7 +184,7 @@ void sub_02052E58(FieldTask *param0) v3 = SaveData_GetVarsFlags(fieldSystem->saveData); v4 = SaveData_GetTrainerInfo(fieldSystem->saveData); v1 = FieldOverworldState_GetSpecialLocation(SaveData_GetFieldOverworldState(fieldSystem->saveData)); - v2 = sub_0203A72C(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + v2 = FieldOverworldState_GetExitLocation(SaveData_GetFieldOverworldState(fieldSystem->saveData)); v5->unk_00 = SystemFlag_CheckGameCompleted(v3); v5->unk_04.unk_00 = SaveData_GetTrainerInfo(fieldSystem->saveData); diff --git a/src/unk_020553DC.c b/src/unk_020553DC.c index ceb2e37537..a1ef634a83 100644 --- a/src/unk_020553DC.c +++ b/src/unk_020553DC.c @@ -119,23 +119,23 @@ void sub_020553DC() return; } -void sub_020553F0(FieldSystem *fieldSystem, u16 param1) +void Sound_SetSpecialBGM(FieldSystem *fieldSystem, u16 param1) { - u16 *v0 = sub_0203A748(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *v0 = FieldOverworldState_GetSpecialBGM(SaveData_GetFieldOverworldState(fieldSystem->saveData)); *v0 = param1; return; } -u16 sub_02055404(FieldSystem *fieldSystem) +u16 Sound_GetSpecialBGM(FieldSystem *fieldSystem) { - u16 *v0 = sub_0203A748(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *v0 = FieldOverworldState_GetSpecialBGM(SaveData_GetFieldOverworldState(fieldSystem->saveData)); return *v0; } void Sound_ClearSpecialBGM(FieldSystem *fieldSystem) { - u16 *v0 = sub_0203A748(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *v0 = FieldOverworldState_GetSpecialBGM(SaveData_GetFieldOverworldState(fieldSystem->saveData)); *v0 = 0; return; @@ -174,8 +174,8 @@ u16 sub_02055428(FieldSystem *fieldSystem, int param1) v2 = sub_020554A4(fieldSystem, param1); - if (sub_02055404(fieldSystem) != 0) { - v2 = sub_02055404(fieldSystem); + if (Sound_GetSpecialBGM(fieldSystem) != 0) { + v2 = Sound_GetSpecialBGM(fieldSystem); } return v2; diff --git a/src/unk_020683F4.c b/src/unk_020683F4.c index 3d90c31b09..f006a16453 100644 --- a/src/unk_020683F4.c +++ b/src/unk_020683F4.c @@ -491,11 +491,11 @@ static BOOL sub_02068884(FieldTask *param0) PlayerAvatar_SetRequestStateBit(fieldSystem->playerAvatar, (1 << 0)); PlayerAvatar_RequestChangeState(fieldSystem->playerAvatar); - sub_020553F0(fieldSystem, 0); + Sound_SetSpecialBGM(fieldSystem, 0); sub_02055554( fieldSystem, sub_02055428(fieldSystem, fieldSystem->location->mapId), 1); } else { - sub_020553F0(fieldSystem, 1152); + Sound_SetSpecialBGM(fieldSystem, 1152); sub_02055554(fieldSystem, 1152, 1); sub_02062DDC(Player_MapObject(fieldSystem->playerAvatar)); diff --git a/src/unk_0206B70C.c b/src/unk_0206B70C.c index 7cf3569566..89acae091c 100644 --- a/src/unk_0206B70C.c +++ b/src/unk_0206B70C.c @@ -80,7 +80,7 @@ void sub_0206B70C(FieldSystem *fieldSystem, UnkStruct_0203D8AC *param1, int para UnkStruct_020556C4 *v7; VarsFlags *v8 = SaveData_GetVarsFlags(fieldSystem->saveData); FieldOverworldState *v9 = SaveData_GetFieldOverworldState(fieldSystem->saveData); - Location *v10 = sub_0203A72C(v9); + Location *v10 = FieldOverworldState_GetExitLocation(v9); memset(param1, 0, sizeof(UnkStruct_0203D8AC)); From 0dea833d8efa473559ee3863c13101e3bd171d39 Mon Sep 17 00:00:00 2001 From: Viperio19 Date: Mon, 18 Nov 2024 21:48:58 +0100 Subject: [PATCH 03/11] Rename variables related to FieldOverworldState --- include/field_map_change.h | 24 ++++++------ include/inlines.h | 4 +- src/overlay005/field_control.c | 4 +- src/overlay005/fieldmap.c | 70 +++++++++++++++++----------------- src/overlay006/ov6_02247100.c | 16 ++++---- src/overlay023/ov23_022521F0.c | 18 ++++----- src/scrcmd.c | 26 ++++++------- src/unk_020528D0.c | 30 +++++++-------- src/unk_020553DC.c | 16 ++++---- src/unk_0206AFE0.c | 6 +-- src/unk_0206B70C.c | 6 +-- 11 files changed, 110 insertions(+), 110 deletions(-) diff --git a/include/field_map_change.h b/include/field_map_change.h index ea199b9685..99dc5ff9c5 100644 --- a/include/field_map_change.h +++ b/include/field_map_change.h @@ -13,23 +13,23 @@ void sub_02053494(FieldSystem *fieldSystem); void FieldSystem_SetLoadNewGameSpawnTask(FieldSystem *fieldSystem); void FieldSystem_SetLoadSavedGameMapTask(FieldSystem *fieldSystem); void FieldSystem_StartLoadMapFromErrorTask(FieldSystem *fieldSystem); -void FieldSystem_StartChangeMapTask(FieldTask *param0, const Location *param1); -void FieldTask_ChangeMapByLocation(FieldTask *param0, const Location *param1); -void FieldTask_ChangeMapToLocation(FieldTask *param0, int param1, int param2, int param3, int param4, int param5); -void FieldTask_StartMapChangeFull(FieldTask *param0, int param1, int param2, int param3, int param4, int param5); +void FieldSystem_StartChangeMapTask(FieldTask *taskMan, const Location *param1); +void FieldTask_ChangeMapByLocation(FieldTask *taskMan, const Location *param1); +void FieldTask_ChangeMapToLocation(FieldTask *taskMan, int param1, int param2, int param3, int param4, int param5); +void FieldTask_StartMapChangeFull(FieldTask *taskMan, int param1, int param2, int param3, int param4, int param5); void FieldTask_StartMapChangeFly(FieldSystem *fieldSystem, int param1, int param2, int param3, int param4, int param5); -void FieldTask_ChangeMapChangeFly(FieldTask *param0, int param1, int param2, int param3, int param4, int param5); -void FieldTask_ChangeMapChangeByDig(FieldTask *param0, const Location *param1, u32 param2); +void FieldTask_ChangeMapChangeFly(FieldTask *taskMan, int param1, int param2, int param3, int param4, int param5); +void FieldTask_ChangeMapChangeByDig(FieldTask *taskMan, const Location *location, u32 param2); void FieldSystem_StartMapChangeWarpTask(FieldSystem *fieldSystem, int param1, int param2); void *sub_02053FAC(FieldSystem *fieldSystem); void FieldTask_SetUndergroundMapChange(FieldSystem *fieldSystem); -BOOL FieldTask_MapChangeToUnderground(FieldTask *param0); -BOOL sub_0205430C(FieldTask *param0); +BOOL FieldTask_MapChangeToUnderground(FieldTask *taskMan); +BOOL sub_0205430C(FieldTask *taskMan); FieldTaskFunc FieldMapChange_GetMapChangeUndergroundTask(const FieldSystem *fieldSystem); -void sub_020544F0(FieldTask *param0, const Location *param1); +void sub_020544F0(FieldTask *taskMan, const Location *param1); void sub_020545EC(FieldSystem *fieldSystem); -void sub_02054708(FieldTask *param0); -void sub_02054800(FieldTask *param0, int param1, int param2, int param3, int param4, int param5); -void sub_02054864(FieldTask *param0); +void sub_02054708(FieldTask *taskMan); +void sub_02054800(FieldTask *taskMan, int param1, int param2, int param3, int param4, int param5); +void sub_02054864(FieldTask *taskMan); #endif // POKEPLATINUM_FIELD_MAP_CHANGE_H diff --git a/include/inlines.h b/include/inlines.h index a0d91f2640..994ebcdef8 100644 --- a/include/inlines.h +++ b/include/inlines.h @@ -131,8 +131,8 @@ static inline void inline_ov61_0222C3B0_sub(SysTask *param0, void *param1) static inline void inline_ov47_0225621C_sub(FieldSystem *fieldSystem, int *param1, int *param2) { - FieldOverworldState *v0 = SaveData_GetFieldOverworldState(fieldSystem->saveData); - Location *location = FieldOverworldState_GetExitLocation(v0); + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(fieldSystem->saveData); + Location *location = FieldOverworldState_GetExitLocation(fieldState); if (MapHeader_IsOnMainMatrix(fieldSystem->location->mapId)) { *param1 = fieldSystem->location->x; diff --git a/src/overlay005/field_control.c b/src/overlay005/field_control.c index 96bd09e054..d5e1728c96 100644 --- a/src/overlay005/field_control.c +++ b/src/overlay005/field_control.c @@ -1024,8 +1024,8 @@ static BOOL Field_MapConnection(const FieldSystem *fieldSystem, int playerX, int static void Field_SetMapConnection(FieldSystem *fieldSystem, const int playerX, const int playerZ, const int playerDir) { - FieldOverworldState *v0 = SaveData_GetFieldOverworldState(fieldSystem->saveData); - Location *nextMap = FieldOverworldState_GetExitLocation(v0); + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(fieldSystem->saveData); + Location *nextMap = FieldOverworldState_GetExitLocation(fieldState); (*nextMap) = *(fieldSystem->location); nextMap->faceDirection = playerDir; diff --git a/src/overlay005/fieldmap.c b/src/overlay005/fieldmap.c index 53dc805e74..4a1d5c4c4a 100644 --- a/src/overlay005/fieldmap.c +++ b/src/overlay005/fieldmap.c @@ -400,24 +400,24 @@ static BOOL ov5_021D119C(FieldSystem *fieldSystem) static BOOL FieldMap_ChangeZone(FieldSystem *fieldSystem) { u32 v0; - u32 v1; - int v2, v3; - FieldOverworldState *v4; + u32 mapId; + int x, y; + FieldOverworldState *fieldState; - if (FieldMap_InDistortionWorld(fieldSystem) == 1) { - return 0; + if (FieldMap_InDistortionWorld(fieldSystem) == TRUE) { + return FALSE; } - v2 = (Player_GetXPos(fieldSystem->playerAvatar) - ov5_021EA6AC(fieldSystem->unk_28)) / 32; - v3 = (Player_GetZPos(fieldSystem->playerAvatar) - ov5_021EA6B4(fieldSystem->unk_28)) / 32; - v0 = sub_02039E30(fieldSystem->unk_2C, v2, v3); - v1 = fieldSystem->location->mapId; + x = (Player_GetXPos(fieldSystem->playerAvatar) - ov5_021EA6AC(fieldSystem->unk_28)) / 32; + y = (Player_GetZPos(fieldSystem->playerAvatar) - ov5_021EA6B4(fieldSystem->unk_28)) / 32; + v0 = sub_02039E30(fieldSystem->unk_2C, x, y); + mapId = fieldSystem->location->mapId; - if (v0 == v1) { - return 0; + if (v0 == mapId) { + return FALSE; } - v4 = SaveData_GetFieldOverworldState(fieldSystem->saveData); + fieldState = SaveData_GetFieldOverworldState(fieldSystem->saveData); { fieldSystem->location->mapId = v0; @@ -426,10 +426,10 @@ static BOOL FieldMap_ChangeZone(FieldSystem *fieldSystem) } { - int v5 = MapHeaderData_GetNumObjectEvents(fieldSystem); - const ObjectEvent *v6 = MapHeaderData_GetObjectEvents(fieldSystem); + int npcCount = MapHeaderData_GetNumObjectEvents(fieldSystem); + const ObjectEvent *npcList = MapHeaderData_GetObjectEvents(fieldSystem); - sub_0206184C(fieldSystem->mapObjMan, v1, v0, v5, v6); + sub_0206184C(fieldSystem->mapObjMan, mapId, v0, npcCount, npcList); } { @@ -439,7 +439,7 @@ static BOOL FieldMap_ChangeZone(FieldSystem *fieldSystem) if (fieldSystem->unk_04->unk_0C != NULL) { ov5_021D5F7C( - fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(v4)); + fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(fieldState)); } } @@ -447,7 +447,7 @@ static BOOL FieldMap_ChangeZone(FieldSystem *fieldSystem) int v7, v8; int v9; - v7 = MapHeader_GetMapLabelTextID(v1); + v7 = MapHeader_GetMapLabelTextID(mapId); v8 = MapHeader_GetMapLabelTextID(v0); v9 = MapHeader_GetMapLabelWindowID(v0); @@ -465,11 +465,11 @@ static BOOL FieldMap_ChangeZone(FieldSystem *fieldSystem) void ov5_021D12D0(FieldSystem *fieldSystem, u32 param1) { - u32 v0; - FieldOverworldState *v1; + u32 mapId; + FieldOverworldState *fieldState; - v0 = fieldSystem->location->mapId; - v1 = SaveData_GetFieldOverworldState(fieldSystem->saveData); + mapId = fieldSystem->location->mapId; + fieldState = SaveData_GetFieldOverworldState(fieldSystem->saveData); { fieldSystem->location->mapId = param1; @@ -479,10 +479,10 @@ void ov5_021D12D0(FieldSystem *fieldSystem, u32 param1) } { - int v2 = MapHeaderData_GetNumObjectEvents(fieldSystem); - const ObjectEvent *v3 = MapHeaderData_GetObjectEvents(fieldSystem); + int npcCount = MapHeaderData_GetNumObjectEvents(fieldSystem); + const ObjectEvent *npcList = MapHeaderData_GetObjectEvents(fieldSystem); - sub_0206184C(fieldSystem->mapObjMan, v0, param1, v2, v3); + sub_0206184C(fieldSystem->mapObjMan, mapId, param1, npcCount, npcList); } { @@ -490,7 +490,7 @@ void ov5_021D12D0(FieldSystem *fieldSystem, u32 param1) sub_0203A418(fieldSystem); if (fieldSystem->unk_04->unk_0C != NULL) { - ov5_021D5F7C(fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(v1)); + ov5_021D5F7C(fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(fieldState)); } } } @@ -515,7 +515,7 @@ static void ov5_021D134C(FieldSystem *fieldSystem, u8 param1) if ((param1 & 2) != 0) { ov5_021E8188(fieldSystem, fieldSystem->unk_28); - if (FieldMap_InDistortionWorld(fieldSystem) == 1) { + if (FieldMap_InDistortionWorld(fieldSystem) == TRUE) { ov9_0224CA5C(fieldSystem); } } @@ -712,7 +712,7 @@ static void ov5_021D15F4(FieldSystem *fieldSystem) sub_020241B4(); if (fieldSystem->unk_20 == 1) { - if (FieldMap_InDistortionWorld(fieldSystem) == 1) { + if (FieldMap_InDistortionWorld(fieldSystem) == TRUE) { ov9_02249F9C(fieldSystem); } @@ -724,7 +724,7 @@ static void ov5_021D15F4(FieldSystem *fieldSystem) sub_0206979C(fieldSystem); ov5_021E91FC(fieldSystem->unk_28, fieldSystem->unk_44); - if (FieldMap_InDistortionWorld(fieldSystem) == 1) { + if (FieldMap_InDistortionWorld(fieldSystem) == TRUE) { ov9_0224CA50(fieldSystem); } @@ -745,7 +745,7 @@ static void ov5_021D15F4(FieldSystem *fieldSystem) ov5_021DF4F8(fieldSystem->unk_40); sub_02020C08(); - if (FieldMap_InDistortionWorld(fieldSystem) == 1) { + if (FieldMap_InDistortionWorld(fieldSystem) == TRUE) { ov9_02250780(fieldSystem); } @@ -819,7 +819,7 @@ static void ov5_021D17EC(FieldSystem *fieldSystem) { fieldSystem->unk_28 = ov5_021E9084(fieldSystem->unk_2C, fieldSystem->unk_30, fieldSystem->unk_50, fieldSystem->unk_60); - if (FieldMap_InDistortionWorld(fieldSystem) == 1) { + if (FieldMap_InDistortionWorld(fieldSystem) == TRUE) { int v0 = 0, v1 = 0, v2 = 0; ov9_02251094(fieldSystem->location->mapId, &v0, &v1, &v2); @@ -845,7 +845,7 @@ static void ov5_021D1878(FieldSystem *fieldSystem) { int v0 = 80; - if (FieldMap_InDistortionWorld(fieldSystem) == 1) { + if (FieldMap_InDistortionWorld(fieldSystem) == TRUE) { v0 = 112; } @@ -864,7 +864,7 @@ static void ov5_021D1878(FieldSystem *fieldSystem) if (fieldSystem->mapLoadType == MAP_LOAD_TYPE_UNDERGROUND) { v1 = Unk_ov5_021FF7D0; } else { - if (FieldMap_InDistortionWorld(fieldSystem) == 1) { + if (FieldMap_InDistortionWorld(fieldSystem) == TRUE) { v1 = Unk_ov5_021FF6B8; } else { v1 = Unk_ov5_021FF744; @@ -916,7 +916,7 @@ static void ov5_021D1968(FieldSystem *fieldSystem) fieldSystem->unk_4C = ov5_021D521C(fieldSystem->unk_44, ov5_021EFAD8(fieldSystem->unk_30)); - if (FieldMap_InDistortionWorld(fieldSystem) == 1) { + if (FieldMap_InDistortionWorld(fieldSystem) == TRUE) { fieldSystem->unk_04->unk_0C = NULL; } else { fieldSystem->unk_04->unk_0C = ov5_021D5EB8(fieldSystem); @@ -979,8 +979,8 @@ static BOOL FieldMap_InDistortionWorld(FieldSystem *fieldSystem) int v1 = sub_02027F80(v0); if (v1 == 9) { - return 1; + return TRUE; } - return 0; + return FALSE; } diff --git a/src/overlay006/ov6_02247100.c b/src/overlay006/ov6_02247100.c index bedf5a8814..9987835fdf 100644 --- a/src/overlay006/ov6_02247100.c +++ b/src/overlay006/ov6_02247100.c @@ -144,18 +144,18 @@ static int ov6_02247244(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ static int ov6_02247288(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) { - FieldOverworldState *v0 = SaveData_GetFieldOverworldState(fieldSystem->saveData); + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(fieldSystem->saveData); if (param2->unk_08 == 2) { - u16 v1; - Location v2; + u16 warpId; + Location location; - v1 = FieldOverworldState_GetWarpId(v0); - sub_0203A7F0(v1, &v2); - FieldTask_ChangeMapChangeByDig(taskMan, &v2, param2->unk_08); + warpId = FieldOverworldState_GetWarpId(fieldState); + sub_0203A7F0(warpId, &location); + FieldTask_ChangeMapChangeByDig(taskMan, &location, param2->unk_08); } else { - Location *v3 = FieldOverworldState_GetExitLocation(v0); - FieldTask_ChangeMapChangeByDig(taskMan, v3, param2->unk_08); + Location *location = FieldOverworldState_GetExitLocation(fieldState); + FieldTask_ChangeMapChangeByDig(taskMan, location, param2->unk_08); } return 2; diff --git a/src/overlay023/ov23_022521F0.c b/src/overlay023/ov23_022521F0.c index 6d3fce9a29..8361f8acc3 100644 --- a/src/overlay023/ov23_022521F0.c +++ b/src/overlay023/ov23_022521F0.c @@ -937,17 +937,17 @@ void ov23_022534A0(FieldSystem *fieldSystem) ov23_022431EC(v4, v4->unk_04, ov23_02251270); { - int v8, v9; - const ObjectEvent *v10; - MapObject *v11; + int npcCount, i; + const ObjectEvent *npcList; + MapObject *mapObj; - v8 = MapHeaderData_GetNumObjectEvents(v4->fieldSystem); - v10 = MapHeaderData_GetObjectEvents(v4->fieldSystem); + npcCount = MapHeaderData_GetNumObjectEvents(v4->fieldSystem); + npcList = MapHeaderData_GetObjectEvents(v4->fieldSystem); - for (v9 = 0; v9 < v8; v9++) { - if ((v10[v9].x == v1) && (v10[v9].z == v2)) { - v11 = MapObjMan_LocalMapObjByIndex(v4->fieldSystem->mapObjMan, v9); - MapObject_SetDir(v11, v3); + for (i = 0; i < npcCount; i++) { + if ((npcList[i].x == v1) && (npcList[i].z == v2)) { + mapObj = MapObjMan_LocalMapObjByIndex(v4->fieldSystem->mapObjMan, i); + MapObject_SetDir(mapObj, v3); } } } diff --git a/src/scrcmd.c b/src/scrcmd.c index 148590a685..7646857920 100644 --- a/src/scrcmd.c +++ b/src/scrcmd.c @@ -4631,8 +4631,8 @@ static BOOL ScrCmd_204(ScriptContext *ctx) static BOOL ScrCmd_200(ScriptContext *ctx) { - FieldOverworldState *v0 = SaveData_GetFieldOverworldState(ctx->fieldSystem->saveData); - Location *location = FieldOverworldState_GetPrevLocation(v0); + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(ctx->fieldSystem->saveData); + Location *location = FieldOverworldState_GetPrevLocation(fieldState); u16 *mapId = ScriptContext_GetVarPointer(ctx); *mapId = location->mapId; @@ -4692,20 +4692,20 @@ static BOOL ScrCmd_0C2(ScriptContext *ctx) static BOOL ScrCmd_0C3(ScriptContext *ctx) { - FieldOverworldState *v0 = SaveData_GetFieldOverworldState(ctx->fieldSystem->saveData); + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(ctx->fieldSystem->saveData); - FieldOverworldState_SetWeather(v0, OVERWORLD_WEATHER_CLEAR); - ov5_021D5F7C(ctx->fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(v0)); + FieldOverworldState_SetWeather(fieldState, OVERWORLD_WEATHER_CLEAR); + ov5_021D5F7C(ctx->fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(fieldState)); return 1; } static BOOL ScrCmd_0C4(ScriptContext *ctx) { - FieldOverworldState *v0 = SaveData_GetFieldOverworldState(ctx->fieldSystem->saveData); + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(ctx->fieldSystem->saveData); - FieldOverworldState_SetWeather(v0, OVERWORLD_WEATHER_CLEAR); - ov5_021D5F7C(ctx->fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(v0)); + FieldOverworldState_SetWeather(fieldState, OVERWORLD_WEATHER_CLEAR); + ov5_021D5F7C(ctx->fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(fieldState)); return 1; } @@ -6376,13 +6376,13 @@ static BOOL ScrCmd_202(ScriptContext *ctx) { u16 *v0; u16 *v1; - FieldOverworldState *v2 = SaveData_GetFieldOverworldState(ctx->fieldSystem->saveData); + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(ctx->fieldSystem->saveData); VarsFlags *v3 = SaveData_GetVarsFlags(ctx->fieldSystem->saveData); TVBroadcast *v4 = SaveData_TVBroadcast(ctx->fieldSystem->saveData); int v5 = ScriptContext_ReadByte(ctx); - v0 = FieldOverworldState_GetSafariBallCount(v2); - v1 = FieldOverworldState_GetSafariStepCount(v2); + v0 = FieldOverworldState_GetSafariBallCount(fieldState); + v1 = FieldOverworldState_GetSafariStepCount(fieldState); switch (v5) { case 0: @@ -7693,8 +7693,8 @@ static BOOL ScrCmd_2B5(ScriptContext *ctx) u16 mapId = ScriptContext_GetVar(ctx); u16 v1 = ScriptContext_GetVar(ctx); u16 v2 = ScriptContext_GetVar(ctx); - FieldOverworldState *v3 = SaveData_GetFieldOverworldState(ctx->fieldSystem->saveData); - Location *location = FieldOverworldState_GetExitLocation(v3); + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(ctx->fieldSystem->saveData); + Location *location = FieldOverworldState_GetExitLocation(fieldState); location->mapId = mapId; location->x = v1; diff --git a/src/unk_020528D0.c b/src/unk_020528D0.c index 9a006784d9..8e537e0073 100644 --- a/src/unk_020528D0.c +++ b/src/unk_020528D0.c @@ -202,12 +202,12 @@ static void sub_02052AA4(UnkStruct_02052AA4 *param0, u16 param1, u8 param2, u8 p BOOL sub_02052B2C(FieldTask *param0) { FieldSystem *fieldSystem; - int *v1; + int *state; fieldSystem = FieldTask_GetFieldSystem(param0); - v1 = FieldTask_GetState(param0); + state = FieldTask_GetState(param0); - switch (*v1) { + switch (*state) { case 0: { if ((fieldSystem != NULL) && (fieldSystem->saveData != NULL)) { Party_SetGiratinaForm(Party_GetFromSavedata(fieldSystem->saveData), 0); @@ -215,36 +215,36 @@ BOOL sub_02052B2C(FieldTask *param0) } { - Location v2; - FieldOverworldState *v3 = SaveData_GetFieldOverworldState(fieldSystem->saveData); - u16 v4 = FieldOverworldState_GetWarpId(v3); + Location location; + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(fieldSystem->saveData); + u16 warpId = FieldOverworldState_GetWarpId(fieldState); - sub_0203A824(v4, &v2); - sub_0203A7F0(v4, FieldOverworldState_GetExitLocation(v3)); - FieldTask_ChangeMapByLocation(param0, &v2); + sub_0203A824(warpId, &location); + sub_0203A7F0(warpId, FieldOverworldState_GetExitLocation(fieldState)); + FieldTask_ChangeMapByLocation(param0, &location); sub_020705B4(fieldSystem); } - (*v1)++; + (*state)++; break; case 1: sub_0200564C(0, 20); - (*v1)++; + (*state)++; break; case 2: if (Sound_CheckFade() == 0) { sub_020553DC(); - (*v1)++; + (*state)++; } break; case 3: sub_0200AB4C(-16, ((GX_BLEND_PLANEMASK_BG0 | GX_BLEND_PLANEMASK_BG1 | GX_BLEND_PLANEMASK_BG2 | GX_BLEND_PLANEMASK_BG3 | GX_BLEND_PLANEMASK_OBJ | GX_BLEND_PLANEMASK_BD) ^ GX_BLEND_PLANEMASK_BG3), 1); sub_0200AB4C(-16, (GX_BLEND_PLANEMASK_BG0 | GX_BLEND_PLANEMASK_BG1 | GX_BLEND_PLANEMASK_BG2 | GX_BLEND_PLANEMASK_BG3 | GX_BLEND_PLANEMASK_OBJ | GX_BLEND_PLANEMASK_BD), 2); sub_02052914(fieldSystem, param0); - (*v1)++; + (*state)++; break; case 4: FieldTransition_StartMap(param0); - (*v1)++; + (*state)++; break; case 5: sub_0200AB4C(0, (GX_BLEND_PLANEMASK_BG0 | GX_BLEND_PLANEMASK_BG1 | GX_BLEND_PLANEMASK_BG2 | GX_BLEND_PLANEMASK_BG3 | GX_BLEND_PLANEMASK_OBJ | GX_BLEND_PLANEMASK_BD), 3); @@ -256,7 +256,7 @@ BOOL sub_02052B2C(FieldTask *param0) ScriptManager_Start(param0, 2021, NULL, NULL); } - (*v1)++; + (*state)++; break; case 6: return 1; diff --git a/src/unk_020553DC.c b/src/unk_020553DC.c index a1ef634a83..760aa8d7d6 100644 --- a/src/unk_020553DC.c +++ b/src/unk_020553DC.c @@ -208,27 +208,27 @@ u16 sub_020554A4(FieldSystem *fieldSystem, int headerID) static u16 sub_020554E8(FieldSystem *fieldSystem, int param1) { - int v0, v1; - FieldOverworldState *v2 = SaveData_GetFieldOverworldState(fieldSystem->saveData); - Location *location = FieldOverworldState_GetPrevLocation(v2); + int x, y; + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(fieldSystem->saveData); + Location *location = FieldOverworldState_GetPrevLocation(fieldState); - v0 = Player_GetXPos(fieldSystem->playerAvatar); - v1 = Player_GetZPos(fieldSystem->playerAvatar); + x = Player_GetXPos(fieldSystem->playerAvatar); + y = Player_GetZPos(fieldSystem->playerAvatar); if (param1 != 350) { return 0; } if ((location->mapId == 80) || (location->mapId == 351)) { - if (v0 < 299) { + if (x < 299) { return 0; } - if (v0 > 306) { + if (x > 306) { return 0; } - if ((v1 == 576) || (v1 == 681)) { + if ((y == 576) || (y == 681)) { return 1189; } } diff --git a/src/unk_0206AFE0.c b/src/unk_0206AFE0.c index f44a6041b5..245bc5caaa 100644 --- a/src/unk_0206AFE0.c +++ b/src/unk_0206AFE0.c @@ -455,10 +455,10 @@ static u8 sub_0206B4A4(VarsFlags *param0) void sub_0206B514(SaveData *param0) { - u32 v0; + u32 unused; VarsFlags *v1 = SaveData_GetVarsFlags(param0); - FieldOverworldState *v2 = SaveData_GetFieldOverworldState(param0); - Location *location = FieldOverworldState_GetPlayerLocation(v2); + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(param0); + Location *location = FieldOverworldState_GetPlayerLocation(fieldState); if ((location->mapId != MAP_HEADER_RESORT_AREA) && (location->mapId != MAP_HEADER_VILLA)) { SystemFlag_ClearVillaVisitorInside(v1); diff --git a/src/unk_0206B70C.c b/src/unk_0206B70C.c index 89acae091c..ce0a3eaaaf 100644 --- a/src/unk_0206B70C.c +++ b/src/unk_0206B70C.c @@ -79,8 +79,8 @@ void sub_0206B70C(FieldSystem *fieldSystem, UnkStruct_0203D8AC *param1, int para int x, z, v6; UnkStruct_020556C4 *v7; VarsFlags *v8 = SaveData_GetVarsFlags(fieldSystem->saveData); - FieldOverworldState *v9 = SaveData_GetFieldOverworldState(fieldSystem->saveData); - Location *v10 = FieldOverworldState_GetExitLocation(v9); + FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(fieldSystem->saveData); + Location *v10 = FieldOverworldState_GetExitLocation(fieldState); memset(param1, 0, sizeof(UnkStruct_0203D8AC)); @@ -88,7 +88,7 @@ void sub_0206B70C(FieldSystem *fieldSystem, UnkStruct_0203D8AC *param1, int para z = Player_GetZPos(fieldSystem->playerAvatar); int v11 = 10 - 1; - Location *location = FieldOverworldState_GetPlayerLocation(v9); + Location *location = FieldOverworldState_GetPlayerLocation(fieldState); v6 = location->mapId; From 37ba7393bf3e7d07fd5cc685dafa60d489fb7e59 Mon Sep 17 00:00:00 2001 From: Viperio19 Date: Mon, 18 Nov 2024 22:17:35 +0100 Subject: [PATCH 04/11] Rename variables in unk_02054884.c --- src/unk_02054884.c | 60 +++++++++++++++++++++++----------------------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/src/unk_02054884.c b/src/unk_02054884.c index cf492754ec..13635f70c2 100644 --- a/src/unk_02054884.c +++ b/src/unk_02054884.c @@ -31,55 +31,55 @@ BOOL Pokemon_CanBattle(Pokemon *mon) BOOL sub_020548B0(int param0, SaveData *param1, u16 param2, u8 param3, u16 param4, int param5, int param6) { - BOOL v0; - Pokemon *v1; + BOOL result; + Pokemon *mon; u32 v2; - Party *v3; - TrainerInfo *v4; + Party *party; + TrainerInfo *trainerInfo; - v4 = SaveData_GetTrainerInfo(param1); - v3 = Party_GetFromSavedata(param1); - v1 = Pokemon_New(param0); + trainerInfo = SaveData_GetTrainerInfo(param1); + party = Party_GetFromSavedata(param1); + mon = Pokemon_New(param0); - Pokemon_Init(v1); - Pokemon_InitWith(v1, param2, param3, 32, FALSE, 0, OTID_NOT_SET, 0); - Pokemon_SetCatchData(v1, v4, ITEM_POKE_BALL, param5, param6, param0); + Pokemon_Init(mon); + Pokemon_InitWith(mon, param2, param3, 32, FALSE, 0, OTID_NOT_SET, 0); + Pokemon_SetCatchData(mon, trainerInfo, ITEM_POKE_BALL, param5, param6, param0); v2 = param4; - Pokemon_SetValue(v1, MON_DATA_HELD_ITEM, &v2); - v0 = Party_AddPokemon(v3, v1); + Pokemon_SetValue(mon, MON_DATA_HELD_ITEM, &v2); + result = Party_AddPokemon(party, mon); - if (v0) { - sub_0202F180(param1, v1); + if (result) { + sub_0202F180(param1, mon); } - Heap_FreeToHeap(v1); + Heap_FreeToHeap(mon); - return v0; + return result; } BOOL sub_02054930(int param0, SaveData *param1, u16 param2, u8 param3, int param4, int param5) { int v0; - BOOL v1; - TrainerInfo *v2 = SaveData_GetTrainerInfo(param1); - Party *v3 = Party_GetFromSavedata(param1); - Pokemon *v4 = Pokemon_New(32); + BOOL result; + TrainerInfo *trainerInfo = SaveData_GetTrainerInfo(param1); + Party *party = Party_GetFromSavedata(param1); + Pokemon *mon = Pokemon_New(32); - Pokemon_Init(v4); + Pokemon_Init(mon); v0 = sub_02017070(param4, param5); - ov5_021E6CF0(v4, param2, param3, v2, 4, v0); + ov5_021E6CF0(mon, param2, param3, trainerInfo, 4, v0); - v1 = Party_AddPokemon(v3, v4); - Heap_FreeToHeap(v4); + result = Party_AddPokemon(party, mon); + Heap_FreeToHeap(mon); - return v1; + return result; } -void sub_02054988(Party *param0, int param1, int param2, u16 param3) +void sub_02054988(Party *party, int param1, int param2, u16 param3) { - Pokemon_ResetMoveSlot(Party_GetPokemonBySlotIndex(param0, param1), param3, param2); + Pokemon_ResetMoveSlot(Party_GetPokemonBySlotIndex(party, param1), param3, param2); } // In many of the functions below, C99-style iterator declaration doesn't match @@ -175,17 +175,17 @@ void Party_GiveChampionRibbons(Party *party) } } -int Pokemon_DoPoisonDamage(Party *param0, u16 param1) +int Pokemon_DoPoisonDamage(Party *party, u16 param1) { int numPoisoned = 0; int numFainted = 0; int i, partyCount; Pokemon *mon; - partyCount = Party_GetCurrentCount(param0); + partyCount = Party_GetCurrentCount(party); for (i = 0; i < partyCount; i++) { - mon = Party_GetPokemonBySlotIndex(param0, i); + mon = Party_GetPokemonBySlotIndex(party, i); if (Pokemon_CanBattle(mon)) { if (Pokemon_GetValue(mon, MON_DATA_STATUS_CONDITION, NULL) & (MON_CONDITION_TOXIC | MON_CONDITION_POISON)) { From f003c44d02b9dde6637118ebdf5f007047adcdae Mon Sep 17 00:00:00 2001 From: Rachel Date: Mon, 18 Nov 2024 17:37:59 -0800 Subject: [PATCH 05/11] Refactor generation of trainer data files --- res/trainers/meson.build | 40 ++++---- tools/json2bin/convert.py | 37 ++++++++ tools/json2bin/meson.build | 3 +- tools/json2bin/trainer_data.py | 163 ++++++++++---------------------- tools/json2bin/trainer_party.py | 55 +++++++++++ 5 files changed, 164 insertions(+), 134 deletions(-) create mode 100644 tools/json2bin/trainer_party.py diff --git a/res/trainers/meson.build b/res/trainers/meson.build index 1b25bf36ad..3445bf0250 100644 --- a/res/trainers/meson.build +++ b/res/trainers/meson.build @@ -5,35 +5,39 @@ foreach i : range(928) trainer_data_files += i_fname endforeach +trainer_data_gen = generator( + trainer_data_py, + arguments: [ '@INPUT@', '@OUTPUT@', ], + output: '@BASENAME@.bin', +) + +trainer_party_gen = generator( + trainer_party_py, + arguments: [ '@INPUT@', '@OUTPUT@', ], + output: '@BASENAME@.bin', +) + trdata_narc = custom_target('trdata.narc', output: 'trdata.narc', - input: trainer_data_files, - env: json2bin_env, + input: trainer_data_gen.process(trainer_data_files, env: json2bin_env), depends: [ py_consts_generators ], command: [ - trainer_data_py, - '--mode', 'data', - '--knarc', knarc_exe, - '--source-dir', '@CURRENT_SOURCE_DIR@', - '--private-dir', '@PRIVATE_DIR@', - '--output-dir', '@OUTDIR@', - ] + knarc_exe, + '-d', '@PRIVATE_DIR@', + '-p', '@OUTPUT@', + ], ) trpoke_narc = custom_target('trpoke.narc', output: 'trpoke.narc', - input: trainer_data_files, - env: json2bin_env, + input: trainer_party_gen.process(trainer_data_files, env: json2bin_env), depends: [ py_consts_generators ], command: [ - trainer_data_py, - '--mode', 'poke', - '--knarc', knarc_exe, - '--source-dir', '@CURRENT_SOURCE_DIR@', - '--private-dir', '@PRIVATE_DIR@', - '--output-dir', '@OUTDIR@', + knarc_exe, + '-d', '@PRIVATE_DIR@', + '-p', '@OUTPUT@', ] ) nitrofs_files += trdata_narc -nitrofs_files += trpoke_narc \ No newline at end of file +nitrofs_files += trpoke_narc diff --git a/tools/json2bin/convert.py b/tools/json2bin/convert.py index 980a32c2e7..55c252a8e3 100644 --- a/tools/json2bin/convert.py +++ b/tools/json2bin/convert.py @@ -1,4 +1,8 @@ #!/usr/bin/env python3 +import collections +import functools + +from consts import items, moves, species, trainer, trainer_ai def pad(len: int) -> bytes: return (0).to_bytes(len, 'little') @@ -11,3 +15,36 @@ def u16(i: int) -> bytes: def u32(i: int) -> bytes: return i.to_bytes(4, 'little') + +def from_item(s: str) -> int: + return items.Item[s].value + +def from_move(s: str) -> int: + return moves.Move[s].value + +def from_species(s: str) -> int: + return species.PokemonSpecies[s].value + +def from_trainer_class(s: str) -> int: + return trainer.TrainerClass[s].value + +def from_trainer_ai_flag(s: str) -> int: + return trainer_ai.AIFlag[s].value + +TrainerDataFlags = collections.namedtuple('TrainerDataFlags', ['has_moves', 'has_items']) + +def derive_data_flags(party: list[dict]) -> TrainerDataFlags: + has_moves = False + has_items = False + for mon in party: + has_moves |= functools.reduce( + lambda x, y: x or y, + map( + lambda move: move != moves.Move.MOVE_NONE.name, + mon.get('moves', []) or [], + ), + False, + ) + has_items |= bool(mon.get('item', None)) + + return TrainerDataFlags(has_moves, has_items) diff --git a/tools/json2bin/meson.build b/tools/json2bin/meson.build index 49e09b7673..21fef6697f 100644 --- a/tools/json2bin/meson.build +++ b/tools/json2bin/meson.build @@ -5,10 +5,11 @@ json2bin_env.set('PYTHONPATH', meson.project_build_root()) # access to constants movedata_py = find_program('movedata.py', native: true) pokemon_personal_data_py = find_program('pokemon_personal_data.py', native: true) pokemon_wotbl_data_py = find_program('pokemon_wotbl_data.py', native: true) -trainer_data_py = find_program('trainer_data.py', native: true) evo_py = find_program('evo.py', native: true) pl_poke_data_py = find_program('pl_poke_data.py', native: true) # New single-file-parser scripts encounter_py = find_program('encounter.py', native: true) event_py = find_program('event.py', native: true) +trainer_data_py = find_program('trainer_data.py', native: true) +trainer_party_py = find_program('trainer_party.py', native: true) diff --git a/tools/json2bin/trainer_data.py b/tools/json2bin/trainer_data.py index be8220bc3d..719e317b68 100644 --- a/tools/json2bin/trainer_data.py +++ b/tools/json2bin/trainer_data.py @@ -1,128 +1,61 @@ #!/usr/bin/env python3 -from collections.abc import Mapping, Sequence -import pathlib, functools - -from consts import ( - items, - moves, - species, - trainer, - trainer_ai +import functools +import json +import pathlib +import sys + +from consts import items +from convert import ( + TrainerDataFlags, + derive_data_flags, + from_trainer_class, + pad, + u8, + u16, + u32, + from_item, + from_trainer_ai_flag, ) -import json2bin as j2b - - -def derive_data_flags(party: Sequence[Mapping], *args) -> bytes: - defined_moves = False - defined_items = False - for mon in party: - defined_moves |= functools.reduce(lambda x, y: x or y, - map(lambda move: move != moves.Move.MOVE_NONE.name, - mon.get('moves', []) if mon.get('moves', []) else []), - False) - defined_items |= bool(mon.get('item', None)) - - return (int(defined_moves) | (int(defined_items) << 1)).to_bytes(1, 'little') - - -def parse_trainer_items(item_list: Sequence[str], *args) -> bytes: - item_bin = bytearray([]) - for item_str in item_list: - item_bin.extend(items.Item[item_str].value.to_bytes(2, 'little')) - - for _ in range(4 - len(item_list)): - item_bin.extend(items.Item.ITEM_NONE.value.to_bytes(2, 'little')) - return item_bin - - -def parse_poke_moves(move_list: Sequence[str], *args) -> bytes: - move_bin = bytearray([]) - for move_str in move_list: - move_bin.extend(moves.Move[move_str].value.to_bytes(2, 'little')) - - for _ in range(4 - len(move_list)): - move_bin.extend(moves.Move.MOVE_NONE.value.to_bytes(2, 'little')) - return move_bin - -def parse_party_mon(mon: dict, has_moves: bool, has_items: bool) -> bytes: - binary_mon = bytearray([]) - binary_mon.extend(j2b.parse_int(mon['power'], 2)) - binary_mon.extend(j2b.parse_int(mon['level'], 2)) +def parse_trainer_items(item_list: list[str]) -> bytes: + item_list += [items.Item.ITEM_NONE.name] * (4 - len(item_list)) + return b"".join([u16(from_item(item_str)) for item_str in item_list]) - species_and_form = (species.PokemonSpecies[mon['species']].value & 0x3FF) | (mon['form'] << 10) - binary_mon.extend(j2b.parse_int(species_and_form, 2)) - if has_items: - binary_mon.extend(j2b.parse_const(mon['item'], 2, items.Item)) - if has_moves: - binary_mon.extend(parse_poke_moves(mon['moves'])) - - binary_mon.extend(j2b.parse_int(mon['ball_seal'], 2)) - return binary_mon +def pack_data_flags(flags: TrainerDataFlags) -> bytes: + return u8(int(flags.has_moves) | (int(flags.has_items) << 1)) -# Parties are a complicated and variable structure, so just process them wholly -# independently -def parse_party_mons(party_list: Sequence[Mapping], *args) -> bytes: - if len(party_list) == 0: # special case, pads to 2 words instead of 1 word - return (0).to_bytes(8, 'little') +def parse_ai_flags(flags: list[str]) -> bytes: + return u32( + functools.reduce( + lambda x, y: x | y, + [from_trainer_ai_flag(s) for s in flags], + 0, + ) + ) - data_flags = int.from_bytes(derive_data_flags(party_list, args), 'little') - has_moves = data_flags & 1 - has_items = data_flags & 2 - binary_party = bytearray(b''.join([parse_party_mon(mon, has_moves, has_items) for mon in party_list])) +input_path = pathlib.Path(sys.argv[1]) +output_path = pathlib.Path(sys.argv[2]) - # word-align - if len(binary_party) % 4 != 0: - target_len = len(binary_party) + (4 - (len(binary_party) % 4)) - binary_party.extend([0] * (target_len - len(binary_party))) +data = {} +with open(input_path, "r", encoding="utf-8") as input_file: + data = json.load(input_file) - return binary_party - - -DATA_SCHEMA = j2b.Parser() \ - .register('party', 1, derive_data_flags) \ - .register('class', 1, j2b.parse_const, trainer.TrainerClass) \ - .pad(1) \ - .register('party', 1, - lambda party, size, _: j2b.parse_int(len(party), size, _)) \ - .register('items', 8, parse_trainer_items) \ - .register('ai_flags', 4, j2b.pack_flags, trainer_ai.AIFlag) \ - .register('double_battle', 1, - lambda val, size, _: j2b.parse_int(2 if val else 0, size, _)) \ - .pad(3) - - -POKE_SCHEMA = j2b.Parser().register('party', 18, parse_party_mons) - - -def indexer(file_path: pathlib.Path) -> int: - return int(file_path.stem) - - -j2b.ARGPARSER.add_argument('--mode', required=True, - choices=['data', 'poke'], - help='Determines which data archive to compile') +packed = b"".join( + [ + pack_data_flags(derive_data_flags(data["party"])), + u8(from_trainer_class(data["class"])), + pad(1), + u8(len(data["party"])), + parse_trainer_items(data["items"]), + parse_ai_flags(data["ai_flags"]), + u8(2 if data["double_battle"] else 0), + pad(3), + ] +) -args = j2b.ARGPARSER.parse_args() -if args.mode == 'data': - j2b.json2bin(args.source_dir, - DATA_SCHEMA, - args.private_dir, - args.output_dir, - indexer, - glob_pattern='*.json', - narc_name='trdata', - narc_packer=args.knarc) -elif args.mode == 'poke': - j2b.json2bin(args.source_dir, - POKE_SCHEMA, - args.private_dir, - args.output_dir, - indexer, - glob_pattern='*.json', - narc_name='trpoke', - narc_packer=args.knarc) \ No newline at end of file +with open(output_path, "wb") as output_file: + output_file.write(packed) diff --git a/tools/json2bin/trainer_party.py b/tools/json2bin/trainer_party.py new file mode 100644 index 0000000000..53f7f72d81 --- /dev/null +++ b/tools/json2bin/trainer_party.py @@ -0,0 +1,55 @@ +#!/usr/bin/env python3 +import json +import pathlib +import sys + +from consts import moves +from convert import derive_data_flags, pad, u16, u32, from_item, from_move, from_species + + +def parse_poke_moves(move_list: list[str]) -> bytes: + move_list += [moves.Move.MOVE_NONE.name] * (4 - len(move_list)) + return b"".join([u16(from_move(move_str)) for move_str in move_list]) + + +def parse_party_mon(mon: dict, has_moves: bool, has_items: bool) -> bytes: + return b"".join( + [ + u16(mon["power"]), + u16(mon["level"]), + u16((from_species(mon["species"]) & 0x3FF) | (mon["form"] << 10)), + u16(from_item(mon["item"])) if has_items else b"", + *[parse_poke_moves(mon["moves"]) if has_moves else b""], + u16(mon["ball_seal"]), + ] + ) + + +input_path = pathlib.Path(sys.argv[1]) +output_path = pathlib.Path(sys.argv[2]) + +data = {} +with open(input_path, "r", encoding="utf-8") as input_file: + data = json.load(input_file) + +party = data["party"] +if len(party) == 0: + packed = pad(8) +else: + data_flags = derive_data_flags(party) + packed = bytearray( + b"".join( + [ + parse_party_mon(mon, data_flags.has_moves, data_flags.has_items) + for mon in party + ] + ) + ) + + # word-align + if len(packed) % 4 > 0: + packed.extend(pad(4 - (len(packed) % 4))) + packed = bytes(packed) + +with open(output_path, "wb") as output_file: + output_file.write(packed) From 1764e5475678def2835772da4c9499725a907559 Mon Sep 17 00:00:00 2001 From: Rachel Date: Mon, 18 Nov 2024 17:48:34 -0800 Subject: [PATCH 06/11] Map semantic names onto trainer data files --- res/trainers/meson.build | 966 +++++++++++++++++- ...572.json => trainer_ace_trainer_abel.json} | 0 ...1.json => trainer_ace_trainer_alicia.json} | 0 ...80.json => trainer_ace_trainer_allen.json} | 0 ...7.json => trainer_ace_trainer_alyssa.json} | 0 ...27.json => trainer_ace_trainer_anton.json} | 0 ...0.json => trainer_ace_trainer_arthur.json} | 0 ...32.json => trainer_ace_trainer_blake.json} | 0 ...3.json => trainer_ace_trainer_brandi.json} | 0 ....json => trainer_ace_trainer_breanna.json} | 0 ...2.json => trainer_ace_trainer_brenda.json} | 0 ...8.json => trainer_ace_trainer_brenna.json} | 0 ...son => trainer_ace_trainer_catherine.json} | 0 ...79.json => trainer_ace_trainer_cesar.json} | 0 ....json => trainer_ace_trainer_clarice.json} | 0 ...0.json => trainer_ace_trainer_dalton.json} | 0 ...> trainer_ace_trainer_dalton_rematch.json} | 0 ...575.json => trainer_ace_trainer_dana.json} | 0 ...3.json => trainer_ace_trainer_deanna.json} | 0 ...> trainer_ace_trainer_deanna_rematch.json} | 0 ...8.json => trainer_ace_trainer_dennis.json} | 0 ...trainer_ace_trainer_dennis_rematch_1.json} | 0 ...trainer_ace_trainer_dennis_rematch_2.json} | 0 ....json => trainer_ace_trainer_destiny.json} | 0 ...6.json => trainer_ace_trainer_ernest.json} | 0 ...66.json => trainer_ace_trainer_felix.json} | 0 ....json => trainer_ace_trainer_garrett.json} | 0 ...8.json => trainer_ace_trainer_graham.json} | 0 ...25.json => trainer_ace_trainer_henry.json} | 0 ...9.json => trainer_ace_trainer_isaiah.json} | 0 ...170.json => trainer_ace_trainer_jake.json} | 0 ... => trainer_ace_trainer_jake_rematch.json} | 0 ...86.json => trainer_ace_trainer_jamie.json} | 0 ...0.json => trainer_ace_trainer_jasmin.json} | 0 ...88.json => trainer_ace_trainer_jonah.json} | 0 ...565.json => trainer_ace_trainer_jose.json} | 0 ...son => trainer_ace_trainer_kassandra.json} | 0 ...9.json => trainer_ace_trainer_keenan.json} | 0 ...34.json => trainer_ace_trainer_laura.json} | 0 ...35.json => trainer_ace_trainer_maria.json} | 0 ...6.json => trainer_ace_trainer_mariah.json} | 0 ...287.json => trainer_ace_trainer_maya.json} | 0 ...> trainer_ace_trainer_maya_rematch_1.json} | 0 ...> trainer_ace_trainer_maya_rematch_2.json} | 0 ...7.json => trainer_ace_trainer_meagan.json} | 0 ...89.json => trainer_ace_trainer_micah.json} | 0 ....json => trainer_ace_trainer_mikayla.json} | 0 ...74.json => trainer_ace_trainer_moira.json} | 0 ...=> trainer_ace_trainer_moira_rematch.json} | 0 ....json => trainer_ace_trainer_monique.json} | 0 ....json => trainer_ace_trainer_natasha.json} | 0 ...1.json => trainer_ace_trainer_olivia.json} | 0 ...> trainer_ace_trainer_olivia_rematch.json} | 0 ...224.json => trainer_ace_trainer_omar.json} | 0 ...67.json => trainer_ace_trainer_quinn.json} | 0 ....json => trainer_ace_trainer_rodolfo.json} | 0 ... trainer_ace_trainer_rodolfo_rematch.json} | 0 ...82.json => trainer_ace_trainer_ruben.json} | 0 ...8.json => trainer_ace_trainer_sandra.json} | 0 ...564.json => trainer_ace_trainer_saul.json} | 0 ... => trainer_ace_trainer_saul_rematch.json} | 0 ...json => trainer_ace_trainer_savannah.json} | 0 ...8.json => trainer_ace_trainer_sergio.json} | 0 ....json => trainer_ace_trainer_shannon.json} | 0 ... trainer_ace_trainer_shannon_rematch.json} | 0 ...1.json => trainer_ace_trainer_skylar.json} | 0 ...0.json => trainer_ace_trainer_stefan.json} | 0 ...7.json => trainer_ace_trainer_sydney.json} | 0 ....json => trainer_ace_trainer_zachery.json} | 0 ...35.json => trainer_aroma_lady_alison.json} | 0 ...60.json => trainer_aroma_lady_angela.json} | 0 ...json => trainer_aroma_lady_elizabeth.json} | 0 ...ainer_aroma_lady_elizabeth_rematch_1.json} | 0 ...ainer_aroma_lady_elizabeth_rematch_2.json} | 0 ...ainer_aroma_lady_elizabeth_rematch_3.json} | 0 ...44.json => trainer_aroma_lady_hannah.json} | 0 ...259.json => trainer_aroma_lady_jenna.json} | 0 ...14.json => trainer_aroma_lady_taylor.json} | 0 .../{0536.json => trainer_artist_ismael.json} | 0 ...{0045.json => trainer_artist_william.json} | 0 ... => trainer_artist_william_rematch_1.json} | 0 ... => trainer_artist_william_rematch_2.json} | 0 ... => trainer_artist_william_rematch_3.json} | 0 ...38.json => trainer_battle_girl_helen.json} | 0 ... trainer_battle_girl_helen_rematch_1.json} | 0 ... trainer_battle_girl_helen_rematch_2.json} | 0 ... trainer_battle_girl_helen_rematch_3.json} | 0 ...0.json => trainer_battle_girl_kelsey.json} | 0 ...72.json => trainer_battle_girl_tyler.json} | 0 .../{0346.json => trainer_beauty_cyndy.json} | 0 ...on => trainer_beauty_cyndy_rematch_1.json} | 0 ...on => trainer_beauty_cyndy_rematch_2.json} | 0 .../{0491.json => trainer_beauty_devon.json} | 0 ...550.json => trainer_beauty_gabriella.json} | 0 .../{0551.json => trainer_beauty_harley.json} | 0 ...{0348.json => trainer_beauty_lindsay.json} | 0 .../{0492.json => trainer_beauty_nicola.json} | 0 ...=> trainer_belle_and_pa_ava_and_matt.json} | 0 ...=> trainer_belle_and_pa_beth_and_bob.json} | 0 ...son => trainer_bird_keeper_alexandra.json} | 0 ...4.json => trainer_bird_keeper_audrey.json} | 0 ...> trainer_bird_keeper_audrey_rematch.json} | 0 ...3.json => trainer_bird_keeper_autumn.json} | 0 ....json => trainer_bird_keeper_brianna.json} | 0 ...rainer_bird_keeper_brianna_rematch_1.json} | 0 ...rainer_bird_keeper_brianna_rematch_2.json} | 0 ...5.json => trainer_bird_keeper_geneva.json} | 0 ...233.json => trainer_bird_keeper_hana.json} | 0 ...son => trainer_bird_keeper_katherine.json} | 0 ....json => trainer_bird_keeper_krystal.json} | 0 ...0069.json => trainer_black_belt_adam.json} | 0 ...0313.json => trainer_black_belt_carl.json} | 0 ...309.json => trainer_black_belt_colby.json} | 0 ...10.json => trainer_black_belt_darren.json} | 0 ...232.json => trainer_black_belt_david.json} | 0 ...587.json => trainer_black_belt_davon.json} | 0 ... => trainer_black_belt_davon_rematch.json} | 0 ...128.json => trainer_black_belt_derek.json} | 0 ...446.json => trainer_black_belt_eddie.json} | 0 ...7.json => trainer_black_belt_gregory.json} | 0 ...8.json => trainer_black_belt_griffin.json} | 0 ...0.json => trainer_black_belt_jarrett.json} | 0 ...2.json => trainer_black_belt_jeffery.json} | 0 ...45.json => trainer_black_belt_kendal.json} | 0 ...0042.json => trainer_black_belt_kyle.json} | 0 ...0148.json => trainer_black_belt_luke.json} | 0 ...444.json => trainer_black_belt_miles.json} | 0 ...json => trainer_black_belt_nathaniel.json} | 0 ...58.json => trainer_black_belt_philip.json} | 0 ...=> trainer_black_belt_philip_rematch.json} | 0 ...11.json => trainer_black_belt_rafael.json} | 0 ...{0589.json => trainer_black_belt_ray.json} | 0 ...314.json => trainer_black_belt_ricky.json} | 0 ...0079.json => trainer_black_belt_sean.json} | 0 ...47.json => trainer_black_belt_willie.json} | 0 ...{0046.json => trainer_breeder_albert.json} | 0 ... => trainer_breeder_albert_rematch_1.json} | 0 ... => trainer_breeder_albert_rematch_2.json} | 0 ... => trainer_breeder_albert_rematch_3.json} | 0 .../{0057.json => trainer_breeder_amber.json} | 0 ...047.json => trainer_breeder_jennifer.json} | 0 ...> trainer_breeder_jennifer_rematch_1.json} | 0 ...> trainer_breeder_jennifer_rematch_2.json} | 0 ...> trainer_breeder_jennifer_rematch_3.json} | 0 ...{0056.json => trainer_breeder_kahlil.json} | 0 ...{0537.json => trainer_breeder_kaylee.json} | 0 ....json => trainer_bug_catcher_brandon.json} | 0 ...rainer_bug_catcher_brandon_rematch_1.json} | 0 ...rainer_bug_catcher_brandon_rematch_2.json} | 0 ...rainer_bug_catcher_brandon_rematch_3.json} | 0 ...3.json => trainer_bug_catcher_donald.json} | 0 ...201.json => trainer_bug_catcher_jack.json} | 0 ....json => trainer_bug_catcher_phillip.json} | 0 ...538.json => trainer_cameraman_darryl.json} | 0 ...0874.json => trainer_cameraman_tevin.json} | 0 ...=> trainer_cameraman_tevin_rematch_1.json} | 0 ...=> trainer_cameraman_tevin_rematch_2.json} | 0 ...=> trainer_cameraman_tevin_rematch_3.json} | 0 ...=> trainer_cameraman_tevin_rematch_4.json} | 0 ...{0034.json => trainer_camper_anthony.json} | 0 .../{0265.json => trainer_camper_curtis.json} | 0 .../{0379.json => trainer_camper_diego.json} | 0 .../{0266.json => trainer_camper_drew.json} | 0 .../{0016.json => trainer_camper_jacob.json} | 0 ...0378.json => trainer_camper_lawrence.json} | 0 .../{0380.json => trainer_camper_parker.json} | 0 ...{0377.json => trainer_camper_zackary.json} | 0 ... => trainer_camper_zackary_rematch_1.json} | 0 ... => trainer_camper_zackary_rematch_2.json} | 0 ... => trainer_camper_zackary_rematch_3.json} | 0 ...267.json => trainer_champion_cynthia.json} | 0 ... => trainer_champion_cynthia_rematch.json} | 0 .../{0886.json => trainer_clown_lee.json} | 0 ....json => trainer_clown_lee_rematch_1.json} | 0 ....json => trainer_clown_lee_rematch_2.json} | 0 ....json => trainer_clown_lee_rematch_3.json} | 0 ....json => trainer_clown_lee_rematch_4.json} | 0 ...0273.json => trainer_collector_brady.json} | 0 ...{0381.json => trainer_collector_dean.json} | 0 ...72.json => trainer_collector_douglas.json} | 0 ...0276.json => trainer_collector_edwin.json} | 0 ...539.json => trainer_collector_eugene.json} | 0 ...5.json => trainer_collector_fernando.json} | 0 ...{0274.json => trainer_collector_ivan.json} | 0 ...on => trainer_collector_ivan_rematch.json} | 0 ...0382.json => trainer_collector_jamal.json} | 0 ...0383.json => trainer_collector_terry.json} | 0 ...ainer_commander_jupiter_spear_pillar.json} | 0 ...ner_commander_jupiter_stark_mountain.json} | 0 ...upiter_team_galactic_eterna_building.json} | 0 ...> trainer_commander_mars_lake_verity.json} | 0 ... trainer_commander_mars_spear_pillar.json} | 0 ...rainer_commander_mars_stark_mountain.json} | 0 ...iner_commander_mars_valley_windworks.json} | 0 ...trainer_commander_saturn_galactic_hq.json} | 0 ...rainer_commander_saturn_valor_cavern.json} | 0 ...0048.json => trainer_cowgirl_shelley.json} | 0 .../{0025.json => trainer_cyclist_axel.json} | 0 .../{0026.json => trainer_cyclist_james.json} | 0 .../{0027.json => trainer_cyclist_john.json} | 0 ...on => trainer_cyclist_john_rematch_1.json} | 0 ...on => trainer_cyclist_john_rematch_2.json} | 0 ...on => trainer_cyclist_john_rematch_3.json} | 0 .../{0031.json => trainer_cyclist_kayla.json} | 0 ...n => trainer_cyclist_kayla_rematch_1.json} | 0 ...n => trainer_cyclist_kayla_rematch_2.json} | 0 ...n => trainer_cyclist_kayla_rematch_3.json} | 0 .../{0029.json => trainer_cyclist_megan.json} | 0 ...{0030.json => trainer_cyclist_nicole.json} | 0 ...{0032.json => trainer_cyclist_rachel.json} | 0 .../{0028.json => trainer_cyclist_ryan.json} | 0 ... trainer_dawn_jubilife_city_chimchar.json} | 0 ...=> trainer_dawn_jubilife_city_piplup.json} | 0 ...> trainer_dawn_jubilife_city_turtwig.json} | 0 ...trainer_dawn_veilstone_city_chimchar.json} | 0 ...> trainer_dawn_veilstone_city_piplup.json} | 0 ... trainer_dawn_veilstone_city_turtwig.json} | 0 ...on => trainer_double_team_al_and_kay.json} | 0 ...on => trainer_double_team_jo_and_pat.json} | 0 ...n => trainer_double_team_zac_and_jen.json} | 0 ...json => trainer_dragon_tamer_clinton.json} | 0 ....json => trainer_dragon_tamer_darien.json} | 0 ...1.json => trainer_dragon_tamer_drake.json} | 0 ...son => trainer_dragon_tamer_geoffrey.json} | 0 ...rainer_dragon_tamer_geoffrey_rematch.json} | 0 ....json => trainer_dragon_tamer_hayden.json} | 0 ... trainer_dragon_tamer_hayden_rematch.json} | 0 ...386.json => trainer_dragon_tamer_joe.json} | 0 ....json => trainer_dragon_tamer_keegan.json} | 0 ...2.json => trainer_dragon_tamer_kenny.json} | 0 ....json => trainer_dragon_tamer_ondrej.json} | 0 ...json => trainer_dragon_tamer_patrick.json} | 0 ...ainer_dragon_tamer_patrick_rematch_1.json} | 0 ...ainer_dragon_tamer_patrick_rematch_2.json} | 0 ...json => trainer_dragon_tamer_stanley.json} | 0 ...261.json => trainer_elite_four_aaron.json} | 0 ... => trainer_elite_four_aaron_rematch.json} | 0 ...62.json => trainer_elite_four_bertha.json} | 0 ...=> trainer_elite_four_bertha_rematch.json} | 0 ...263.json => trainer_elite_four_flint.json} | 0 ... trainer_elite_four_flint_fight_area.json} | 0 ... => trainer_elite_four_flint_rematch.json} | 0 ...64.json => trainer_elite_four_lucian.json} | 0 ...=> trainer_elite_four_lucian_rematch.json} | 0 ...{0173.json => trainer_fisherman_alec.json} | 0 ...on => trainer_fisherman_alec_rematch.json} | 0 ...022.json => trainer_fisherman_andrew.json} | 0 ...0172.json => trainer_fisherman_brett.json} | 0 ...{0043.json => trainer_fisherman_cody.json} | 0 ...{0175.json => trainer_fisherman_cole.json} | 0 ...{0168.json => trainer_fisherman_cory.json} | 0 ...0293.json => trainer_fisherman_erick.json} | 0 ...174.json => trainer_fisherman_george.json} | 0 ...023.json => trainer_fisherman_joseph.json} | 0 ...> trainer_fisherman_joseph_rematch_1.json} | 0 ...> trainer_fisherman_joseph_rematch_2.json} | 0 ...{0092.json => trainer_fisherman_josh.json} | 0 ...{0091.json => trainer_fisherman_juan.json} | 0 ...11.json => trainer_fisherman_kenneth.json} | 0 .../{0154.json => trainer_fisherman_luc.json} | 0 ...153.json => trainer_fisherman_miguel.json} | 0 ... => trainer_fisherman_miguel_rematch.json} | 0 ...093.json => trainer_fisherman_travis.json} | 0 ...401.json => trainer_fisherman_walter.json} | 0 ...24.json => trainer_fisherman_zachary.json} | 0 ...actic_boss_cyrus_celestic_town_ruins.json} | 0 ...galactic_boss_cyrus_distortion_world.json} | 0 ...iner_galactic_boss_cyrus_galactic_hq.json} | 0 ...trainer_galactic_grunt_celestic_town.json} | 0 ...ner_galactic_grunt_floaroma_meadow_1.json} | 0 ...ner_galactic_grunt_floaroma_meadow_2.json} | 0 ...rainer_galactic_grunt_galactic_hq_1f.json} | 0 ...iner_galactic_grunt_galactic_hq_2f_1.json} | 0 ...iner_galactic_grunt_galactic_hq_2f_2.json} | 0 ...iner_galactic_grunt_galactic_hq_2f_3.json} | 0 ...iner_galactic_grunt_galactic_hq_3f_1.json} | 0 ...iner_galactic_grunt_galactic_hq_3f_2.json} | 0 ...iner_galactic_grunt_galactic_hq_3f_3.json} | 0 ...iner_galactic_grunt_galactic_hq_3f_4.json} | 0 ...ner_galactic_grunt_galactic_hq_b2f_1.json} | 0 ...ner_galactic_grunt_galactic_hq_b2f_2.json} | 0 ...trainer_galactic_grunt_iron_island_1.json} | 0 ...trainer_galactic_grunt_iron_island_2.json} | 0 ...ainer_galactic_grunt_jubilife_city_1.json} | 0 ...ainer_galactic_grunt_jubilife_city_2.json} | 0 ... trainer_galactic_grunt_lake_valor_1.json} | 0 ... trainer_galactic_grunt_lake_valor_2.json} | 0 ... trainer_galactic_grunt_lake_valor_3.json} | 0 ...trainer_galactic_grunt_lake_verity_1.json} | 0 ...trainer_galactic_grunt_lake_verity_2.json} | 0 ...trainer_galactic_grunt_lake_verity_3.json} | 0 ...trainer_galactic_grunt_lake_verity_4.json} | 0 ...ainer_galactic_grunt_mt_coronet_3f_1.json} | 0 ...ainer_galactic_grunt_mt_coronet_4f_1.json} | 0 ...ainer_galactic_grunt_mt_coronet_4f_2.json} | 0 ...ainer_galactic_grunt_mt_coronet_5f_1.json} | 0 ...ainer_galactic_grunt_mt_coronet_5f_2.json} | 0 ...trainer_galactic_grunt_mt_coronet_6f.json} | 0 ...iner_galactic_grunt_mt_coronet__3f_1.json} | 0 ...actic_grunt_mt_coronet_tunnel_room_1.json} | 0 ...actic_grunt_mt_coronet_tunnel_room_2.json} | 0 ...actic_grunt_mt_coronet_tunnel_room_3.json} | 0 ...rainer_galactic_grunt_spear_pillar_1.json} | 0 ...rainer_galactic_grunt_spear_pillar_2.json} | 0 ...t_team_galactic_eterna_building_1f_1.json} | 0 ...t_team_galactic_eterna_building_1f_2.json} | 0 ...t_team_galactic_eterna_building_2f_1.json} | 0 ...t_team_galactic_eterna_building_2f_2.json} | 0 ...unt_team_galactic_eterna_building_3f.json} | 0 ...er_galactic_grunt_valley_windworks_1.json} | 0 ...er_galactic_grunt_valley_windworks_2.json} | 0 ...er_galactic_grunt_valley_windworks_3.json} | 0 ...ainer_galactic_grunt_valor_lakefront.json} | 0 ...iner_galactic_grunt_veilstone_city_1.json} | 0 ...iner_galactic_grunt_veilstone_city_2.json} | 0 ...084.json => trainer_gentleman_jeremy.json} | 0 ...> trainer_gentleman_jeremy_rematch_1.json} | 0 ...> trainer_gentleman_jeremy_rematch_2.json} | 0 ...> trainer_gentleman_jeremy_rematch_3.json} | 0 ...2.json => trainer_gentleman_leonardo.json} | 0 ...877.json => trainer_guitarist_arturo.json} | 0 ...> trainer_guitarist_arturo_rematch_1.json} | 0 ...> trainer_guitarist_arturo_rematch_2.json} | 0 ...> trainer_guitarist_arturo_rematch_3.json} | 0 ...> trainer_guitarist_arturo_rematch_4.json} | 0 ...0301.json => trainer_guitarist_jerry.json} | 0 ...303.json => trainer_guitarist_lonnie.json} | 0 ...02.json => trainer_guitarist_preston.json} | 0 ...{0300.json => trainer_guitarist_tony.json} | 0 ...on => trainer_guitarist_tony_rematch.json} | 0 ...0040.json => trainer_hiker_alexander.json} | 0 .../{0452.json => trainer_hiker_damon.json} | 0 .../{0018.json => trainer_hiker_daniel.json} | 0 ...{0041.json => trainer_hiker_jonathan.json} | 0 .../{0037.json => trainer_hiker_justin.json} | 0 .../{0036.json => trainer_hiker_kevin.json} | 0 .../{0455.json => trainer_hiker_lorenzo.json} | 0 .../{0326.json => trainer_hiker_louis.json} | 0 .../{0453.json => trainer_hiker_maurice.json} | 0 ...{0019.json => trainer_hiker_nicholas.json} | 0 ...{0454.json => trainer_hiker_reginald.json} | 0 .../{0039.json => trainer_hiker_robert.json} | 0 ...{0451.json => trainer_hiker_theodore.json} | 0 ... => trainer_hiker_theodore_rematch_1.json} | 0 ... => trainer_hiker_theodore_rematch_2.json} | 0 ... => trainer_hiker_theodore_rematch_3.json} | 0 .../{0880.json => trainer_idol_grace.json} | 0 ...json => trainer_idol_grace_rematch_1.json} | 0 ...json => trainer_idol_grace_rematch_2.json} | 0 ...json => trainer_idol_grace_rematch_3.json} | 0 ...json => trainer_idol_grace_rematch_4.json} | 0 ...=> trainer_interviewers_roxy_and_oli.json} | 0 ..._interviewers_roxy_and_oli_rematch_1.json} | 0 ..._interviewers_roxy_and_oli_rematch_2.json} | 0 ..._interviewers_roxy_and_oli_rematch_3.json} | 0 ..._interviewers_roxy_and_oli_rematch_4.json} | 0 .../{0307.json => trainer_jogger_craig.json} | 0 ...on => trainer_jogger_craig_rematch_1.json} | 0 ...on => trainer_jogger_craig_rematch_2.json} | 0 .../{0308.json => trainer_jogger_raul.json} | 0 ...{0049.json => trainer_jogger_richard.json} | 0 .../{0130.json => trainer_jogger_scott.json} | 0 .../{0306.json => trainer_jogger_wyatt.json} | 0 .../{0893.json => trainer_lady_celeste.json} | 0 .../{0546.json => trainer_lady_kylie.json} | 0 .../{0083.json => trainer_lady_melissa.json} | 0 ...on => trainer_lady_melissa_rematch_1.json} | 0 ...on => trainer_lady_melissa_rematch_2.json} | 0 ...on => trainer_lady_melissa_rematch_3.json} | 0 .../{0544.json => trainer_lass_blythe.json} | 0 .../{0204.json => trainer_lass_briana.json} | 0 .../{0324.json => trainer_lass_caroline.json} | 0 .../{0450.json => trainer_lass_cassidy.json} | 0 .../{0323.json => trainer_lass_kaitlin.json} | 0 .../{0322.json => trainer_lass_madeline.json} | 0 ...n => trainer_lass_madeline_rematch_1.json} | 0 ...n => trainer_lass_madeline_rematch_2.json} | 0 ...n => trainer_lass_madeline_rematch_3.json} | 0 .../{0325.json => trainer_lass_molly.json} | 0 .../{0003.json => trainer_lass_natalie.json} | 0 .../{0011.json => trainer_lass_samantha.json} | 0 ...n => trainer_lass_samantha_rematch_1.json} | 0 ...n => trainer_lass_samantha_rematch_2.json} | 0 ...n => trainer_lass_samantha_rematch_3.json} | 0 .../{0012.json => trainer_lass_sarah.json} | 0 .../{0250.json => trainer_leader_byron.json} | 0 ...json => trainer_leader_byron_rematch.json} | 0 ...{0319.json => trainer_leader_candice.json} | 0 ...on => trainer_leader_candice_rematch.json} | 0 ...{0318.json => trainer_leader_fantina.json} | 0 ...on => trainer_leader_fantina_rematch.json} | 0 ...0315.json => trainer_leader_gardenia.json} | 0 ...n => trainer_leader_gardenia_rematch.json} | 0 ...{0317.json => trainer_leader_maylene.json} | 0 ...on => trainer_leader_maylene_rematch.json} | 0 .../{0246.json => trainer_leader_roark.json} | 0 ...json => trainer_leader_roark_rematch.json} | 0 ...{0320.json => trainer_leader_volkner.json} | 0 ...=> trainer_leader_volkner_fight_area.json} | 0 ...on => trainer_leader_volkner_rematch.json} | 0 .../{0316.json => trainer_leader_wake.json} | 0 ....json => trainer_leader_wake_rematch.json} | 0 ...trainer_lucas_jubilife_city_chimchar.json} | 0 ...> trainer_lucas_jubilife_city_piplup.json} | 0 ... trainer_lucas_jubilife_city_turtwig.json} | 0 ...rainer_lucas_veilstone_city_chimchar.json} | 0 ... trainer_lucas_veilstone_city_piplup.json} | 0 ...trainer_lucas_veilstone_city_turtwig.json} | 0 .../{0897.json => trainer_maid_belinda.json} | 0 .../{0901.json => trainer_maid_clare.json} | 0 .../{0900.json => trainer_maid_elena.json} | 0 .../{0899.json => trainer_maid_emily.json} | 0 .../{0898.json => trainer_maid_sophie.json} | 0 ...89.json => trainer_ninja_boy_brennan.json} | 0 ...0490.json => trainer_ninja_boy_bruce.json} | 0 ...072.json => trainer_ninja_boy_davido.json} | 0 ...0147.json => trainer_ninja_boy_ethan.json} | 0 ...488.json => trainer_ninja_boy_fabian.json} | 0 ...{0070.json => trainer_ninja_boy_joel.json} | 0 ...46.json => trainer_ninja_boy_matthew.json} | 0 ...071.json => trainer_ninja_boy_nathan.json} | 0 ...{0080.json => trainer_ninja_boy_nick.json} | 0 ...{0078.json => trainer_ninja_boy_zach.json} | 0 ... => trainer_ninja_boy_zach_rematch_1.json} | 0 ... => trainer_ninja_boy_zach_rematch_2.json} | 0 ... => trainer_ninja_boy_zach_rematch_3.json} | 0 res/trainers/{0000.json => trainer_none.json} | 0 ...7.json => trainer_parasol_lady_alexa.json} | 0 ...trainer_parasol_lady_alexa_rematch_1.json} | 0 ...trainer_parasol_lady_alexa_rematch_2.json} | 0 ...trainer_parasol_lady_alexa_rematch_3.json} | 0 ...json => trainer_parasol_lady_sabrina.json} | 0 .../{0121.json => trainer_pi_carlos.json} | 0 ....json => trainer_pi_carlos_rematch_1.json} | 0 ....json => trainer_pi_carlos_rematch_2.json} | 0 .../{0541.json => trainer_pi_kendrick.json} | 0 .../{0459.json => trainer_picnicker_ana.json} | 0 ...0.json => trainer_picnicker_cheyenne.json} | 0 ...0329.json => trainer_picnicker_diana.json} | 0 ...456.json => trainer_picnicker_karina.json} | 0 ...> trainer_picnicker_karina_rematch_1.json} | 0 ...> trainer_picnicker_karina_rematch_2.json} | 0 ...> trainer_picnicker_karina_rematch_3.json} | 0 ...035.json => trainer_picnicker_lauren.json} | 0 ...0017.json => trainer_picnicker_siena.json} | 0 ...457.json => trainer_picnicker_summer.json} | 0 ...{0458.json => trainer_picnicker_tori.json} | 0 ...{0889.json => trainer_poke_kid_ariel.json} | 0 ... => trainer_poke_kid_ariel_rematch_1.json} | 0 ... => trainer_poke_kid_ariel_rematch_2.json} | 0 ... => trainer_poke_kid_ariel_rematch_3.json} | 0 ... => trainer_poke_kid_ariel_rematch_4.json} | 0 ...53.json => trainer_poke_kid_danielle.json} | 0 ... trainer_poke_kid_danielle_rematch_1.json} | 0 ... trainer_poke_kid_danielle_rematch_2.json} | 0 ... trainer_poke_kid_danielle_rematch_3.json} | 0 ...{0832.json => trainer_poke_kid_janet.json} | 0 ...0331.json => trainer_poke_kid_meghan.json} | 0 ...0530.json => trainer_pokefan_leonard.json} | 0 ...540.json => trainer_pokefan_meredith.json} | 0 ...0531.json => trainer_pokefan_rebekah.json} | 0 ...{0089.json => trainer_policeman_alex.json} | 0 ...0088.json => trainer_policeman_bobby.json} | 0 ...0102.json => trainer_policeman_caleb.json} | 0 ...0332.json => trainer_policeman_danny.json} | 0 ...=> trainer_policeman_danny_rematch_1.json} | 0 ...=> trainer_policeman_danny_rematch_2.json} | 0 ...=> trainer_policeman_danny_rematch_3.json} | 0 ...0090.json => trainer_policeman_dylan.json} | 0 ...333.json => trainer_policeman_thomas.json} | 0 ...0120.json => trainer_psychic_abigail.json} | 0 ...=> trainer_psychic_abigail_rematch_1.json} | 0 ...=> trainer_psychic_abigail_rematch_2.json} | 0 ...289.json => trainer_psychic_brittney.json} | 0 ... => trainer_psychic_brittney_rematch.json} | 0 .../{0234.json => trainer_psychic_bryce.json} | 0 ...0586.json => trainer_psychic_chelsey.json} | 0 ...{0583.json => trainer_psychic_corbin.json} | 0 ...on => trainer_psychic_corbin_rematch.json} | 0 .../{0585.json => trainer_psychic_daisy.json} | 0 ...son => trainer_psychic_daisy_rematch.json} | 0 ...0397.json => trainer_psychic_deandre.json} | 0 ...0399.json => trainer_psychic_desiree.json} | 0 ...{0205.json => trainer_psychic_elijah.json} | 0 ...{0400.json => trainer_psychic_kendra.json} | 0 .../{0395.json => trainer_psychic_kody.json} | 0 ...{0396.json => trainer_psychic_landon.json} | 0 ...0206.json => trainer_psychic_lindsey.json} | 0 ...0288.json => trainer_psychic_maxwell.json} | 0 ...n => trainer_psychic_maxwell_rematch.json} | 0 ...119.json => trainer_psychic_mitchell.json} | 0 ...> trainer_psychic_mitchell_rematch_1.json} | 0 ...> trainer_psychic_mitchell_rematch_2.json} | 0 ...0398.json => trainer_psychic_rachael.json} | 0 ...584.json => trainer_psychic_sterling.json} | 0 ...235.json => trainer_psychic_valencia.json} | 0 .../{0292.json => trainer_rancher_marco.json} | 0 ...n => trainer_rancher_marco_rematch_1.json} | 0 ...n => trainer_rancher_marco_rematch_2.json} | 0 ...{0096.json => trainer_ranger_allison.json} | 0 ... => trainer_ranger_allison_rematch_1.json} | 0 ... => trainer_ranger_allison_rematch_2.json} | 0 ... => trainer_ranger_allison_rematch_3.json} | 0 .../{0594.json => trainer_ranger_ashlee.json} | 0 ...son => trainer_ranger_ashlee_rematch.json} | 0 ...{0592.json => trainer_ranger_deshawn.json} | 0 .../{0593.json => trainer_ranger_dwayne.json} | 0 ...{0595.json => trainer_ranger_felicia.json} | 0 ...{0095.json => trainer_ranger_jeffrey.json} | 0 .../{0596.json => trainer_ranger_krista.json} | 0 .../{0591.json => trainer_ranger_kyler.json} | 0 ...json => trainer_ranger_kyler_rematch.json} | 0 .../{0094.json => trainer_ranger_taylor.json} | 0 ...n => trainer_ranger_taylor_rematch_1.json} | 0 ...n => trainer_ranger_taylor_rematch_2.json} | 0 ...n => trainer_ranger_taylor_rematch_3.json} | 0 ...894.json => trainer_reporters_kinsey.json} | 0 ...> trainer_reporters_kinsey_rematch_1.json} | 0 ...> trainer_reporters_kinsey_rematch_2.json} | 0 ...> trainer_reporters_kinsey_rematch_3.json} | 0 ...> trainer_reporters_kinsey_rematch_4.json} | 0 ...47.json => trainer_reporters_valerie.json} | 0 ...{0082.json => trainer_rich_boy_jason.json} | 0 .../{0892.json => trainer_rich_boy_liam.json} | 0 ...{0545.json => trainer_rich_boy_roman.json} | 0 .../{0335.json => trainer_rich_boy_trey.json} | 0 ...n => trainer_rich_boy_trey_rematch_1.json} | 0 ...n => trainer_rich_boy_trey_rematch_2.json} | 0 ...trainer_rival_canalave_city_chimchar.json} | 0 ...> trainer_rival_canalave_city_piplup.json} | 0 ... trainer_rival_canalave_city_turtwig.json} | 0 ...=> trainer_rival_fight_area_chimchar.json} | 0 ...n => trainer_rival_fight_area_piplup.json} | 0 ... => trainer_rival_fight_area_turtwig.json} | 0 ...trainer_rival_pastoria_city_chimchar.json} | 0 ...> trainer_rival_pastoria_city_piplup.json} | 0 ... trainer_rival_pastoria_city_turtwig.json} | 0 ...rainer_rival_pokemon_league_chimchar.json} | 0 ... trainer_rival_pokemon_league_piplup.json} | 0 ...trainer_rival_pokemon_league_turtwig.json} | 0 ... => trainer_rival_route_201_chimchar.json} | 0 ...on => trainer_rival_route_201_piplup.json} | 0 ...n => trainer_rival_route_201_turtwig.json} | 0 ... => trainer_rival_route_203_chimchar.json} | 0 ...on => trainer_rival_route_203_piplup.json} | 0 ...n => trainer_rival_route_203_turtwig.json} | 0 ... => trainer_rival_route_209_chimchar.json} | 0 ...on => trainer_rival_route_209_piplup.json} | 0 ...n => trainer_rival_route_209_turtwig.json} | 0 ... trainer_rival_spear_pillar_chimchar.json} | 0 ...=> trainer_rival_spear_pillar_piplup.json} | 0 ...> trainer_rival_spear_pillar_turtwig.json} | 0 ...ainer_rival_survival_area_1_chimchar.json} | 0 ...trainer_rival_survival_area_1_piplup.json} | 0 ...rainer_rival_survival_area_1_turtwig.json} | 0 ...ainer_rival_survival_area_2_chimchar.json} | 0 ...trainer_rival_survival_area_2_piplup.json} | 0 ...rainer_rival_survival_area_2_turtwig.json} | 0 ...0529.json => trainer_roughneck_kirby.json} | 0 ...13.json => trainer_ruin_maniac_bryan.json} | 0 ...4.json => trainer_ruin_maniac_calvin.json} | 0 ...3.json => trainer_ruin_maniac_gerald.json} | 0 ...42.json => trainer_ruin_maniac_harry.json} | 0 ... trainer_ruin_maniac_harry_rematch_1.json} | 0 ... trainer_ruin_maniac_harry_rematch_2.json} | 0 ...553.json => trainer_ruin_maniac_karl.json} | 0 ...05.json => trainer_ruin_maniac_larry.json} | 0 ...4.json => trainer_ruin_maniac_ronald.json} | 0 .../{0339.json => trainer_sailor_damian.json} | 0 .../{0180.json => trainer_sailor_luther.json} | 0 .../{0337.json => trainer_sailor_marc.json} | 0 ...son => trainer_sailor_marc_rematch_1.json} | 0 ...son => trainer_sailor_marc_rematch_2.json} | 0 .../{0110.json => trainer_sailor_paul.json} | 0 .../{0483.json => trainer_sailor_samson.json} | 0 .../{0338.json => trainer_sailor_skyler.json} | 0 ...482.json => trainer_sailor_zachariah.json} | 0 ... => trainer_sailor_zachariah_rematch.json} | 0 ...40.json => trainer_school_kid_chance.json} | 0 ...json => trainer_school_kid_christine.json} | 0 ...8.json => trainer_school_kid_esteban.json} | 0 ...1.json => trainer_school_kid_forrest.json} | 0 ....json => trainer_school_kid_harrison.json} | 0 ...json => trainer_school_kid_mackenzie.json} | 0 ...344.json => trainer_school_kid_tiera.json} | 0 ...29.json => trainer_scientist_darrius.json} | 0 ...549.json => trainer_scientist_emilio.json} | 0 ...0.json => trainer_scientist_fredrick.json} | 0 ...0486.json => trainer_scientist_shaun.json} | 0 ...=> trainer_scientist_shaun_rematch_1.json} | 0 ...=> trainer_scientist_shaun_rematch_2.json} | 0 ...=> trainer_scientist_shaun_rematch_3.json} | 0 ...99.json => trainer_scientist_stefano.json} | 0 ...831.json => trainer_scientist_travon.json} | 0 .../{0139.json => trainer_skier_andrea.json} | 0 ...on => trainer_skier_andrea_rematch_1.json} | 0 ...on => trainer_skier_andrea_rematch_2.json} | 0 .../{0143.json => trainer_skier_bjorn.json} | 0 ...son => trainer_skier_bjorn_rematch_1.json} | 0 ...son => trainer_skier_bjorn_rematch_2.json} | 0 .../{0136.json => trainer_skier_bradley.json} | 0 .../{0137.json => trainer_skier_edward.json} | 0 ...on => trainer_skier_edward_rematch_1.json} | 0 ...on => trainer_skier_edward_rematch_2.json} | 0 .../{0138.json => trainer_skier_kaitlyn.json} | 0 .../{0144.json => trainer_skier_lexie.json} | 0 .../{0145.json => trainer_skier_madison.json} | 0 ...n => trainer_skier_madison_rematch_1.json} | 0 ...n => trainer_skier_madison_rematch_2.json} | 0 .../{0142.json => trainer_skier_shawn.json} | 0 ...43.json => trainer_socialite_rebecca.json} | 0 ...0085.json => trainer_socialite_reina.json} | 0 ...=> trainer_socialite_reina_rematch_1.json} | 0 ...=> trainer_socialite_reina_rematch_2.json} | 0 ...{0159.json => trainer_swimmer_adrian.json} | 0 ...{0190.json => trainer_swimmer_aubree.json} | 0 ...93.json => trainer_swimmer_cassandra.json} | 0 ...{0494.json => trainer_swimmer_claire.json} | 0 ...{0186.json => trainer_swimmer_colton.json} | 0 ...0192.json => trainer_swimmer_crystal.json} | 0 ...n => trainer_swimmer_crystal_rematch.json} | 0 ...{0166.json => trainer_swimmer_dillon.json} | 0 .../{0163.json => trainer_swimmer_erica.json} | 0 .../{0160.json => trainer_swimmer_erik.json} | 0 .../{0104.json => trainer_swimmer_evan.json} | 0 ...85.json => trainer_swimmer_francisco.json} | 0 ...=> trainer_swimmer_francisco_rematch.json} | 0 ...94.json => trainer_swimmer_gabrielle.json} | 0 .../{0597.json => trainer_swimmer_glenn.json} | 0 ...son => trainer_swimmer_glenn_rematch.json} | 0 .../{0105.json => trainer_swimmer_haley.json} | 0 ...0162.json => trainer_swimmer_jessica.json} | 0 ...{0601.json => trainer_swimmer_joanna.json} | 0 ...on => trainer_swimmer_joanna_rematch.json} | 0 ...0164.json => trainer_swimmer_katelyn.json} | 0 .../{0598.json => trainer_swimmer_kurt.json} | 0 .../{0604.json => trainer_swimmer_lydia.json} | 0 ...0603.json => trainer_swimmer_mallory.json} | 0 .../{0106.json => trainer_swimmer_mary.json} | 0 ...0189.json => trainer_swimmer_miranda.json} | 0 ...n => trainer_swimmer_miranda_rematch.json} | 0 .../{0188.json => trainer_swimmer_oscar.json} | 0 .../{0191.json => trainer_swimmer_paige.json} | 0 ...0184.json => trainer_swimmer_ricardo.json} | 0 .../{0599.json => trainer_swimmer_sam.json} | 0 ...0103.json => trainer_swimmer_sheltin.json} | 0 ...{0602.json => trainer_swimmer_sophia.json} | 0 .../{0187.json => trainer_swimmer_troy.json} | 0 ...0167.json => trainer_swimmer_vanessa.json} | 0 ...0161.json => trainer_swimmer_vincent.json} | 0 .../{0600.json => trainer_swimmer_wade.json} | 0 ...{0183.json => trainer_swimmer_wesley.json} | 0 ...on => trainer_swimmer_wesley_rematch.json} | 0 ...=> trainer_trainer_buck_battleground.json} | 0 ...11.json => trainer_trainer_buck_buck.json} | 0 ... trainer_trainer_cheryl_battleground.json} | 0 ...son => trainer_trainer_cheryl_cheryl.json} | 0 ... trainer_trainer_marley_battleground.json} | 0 ...son => trainer_trainer_marley_marley.json} | 0 ...=> trainer_trainer_mira_battleground.json} | 0 ...12.json => trainer_trainer_mira_mira.json} | 0 ...> trainer_trainer_riley_battleground.json} | 0 ....json => trainer_trainer_riley_riley.json} | 0 .../{0498.json => trainer_tuber_caitlyn.json} | 0 .../{0108.json => trainer_tuber_chelsea.json} | 0 ...n => trainer_tuber_chelsea_rematch_1.json} | 0 ...n => trainer_tuber_chelsea_rematch_2.json} | 0 .../{0359.json => trainer_tuber_conner.json} | 0 .../{0361.json => trainer_tuber_holly.json} | 0 .../{0497.json => trainer_tuber_jacky.json} | 0 .../{0107.json => trainer_tuber_jared.json} | 0 ...son => trainer_tuber_jared_rematch_1.json} | 0 ...son => trainer_tuber_jared_rematch_2.json} | 0 .../{0360.json => trainer_tuber_mariel.json} | 0 .../{0358.json => trainer_tuber_trenton.json} | 0 ...4.json => trainer_twins_emma_and_lil.json} | 0 ...15.json => trainer_twins_liv_and_liz.json} | 0 ...5.json => trainer_twins_teri_and_tia.json} | 0 ...trainer_twins_teri_and_tia_rematch_1.json} | 0 ...trainer_twins_teri_and_tia_rematch_2.json} | 0 .../{0005.json => trainer_unknown_005.json} | 0 .../{0006.json => trainer_unknown_006.json} | 0 .../{0007.json => trainer_unknown_007.json} | 0 .../{0008.json => trainer_unknown_008.json} | 0 .../{0009.json => trainer_unknown_009.json} | 0 .../{0050.json => trainer_unknown_050.json} | 0 .../{0051.json => trainer_unknown_051.json} | 0 .../{0052.json => trainer_unknown_052.json} | 0 .../{0054.json => trainer_unknown_054.json} | 0 .../{0058.json => trainer_unknown_058.json} | 0 .../{0059.json => trainer_unknown_059.json} | 0 .../{0060.json => trainer_unknown_060.json} | 0 .../{0061.json => trainer_unknown_061.json} | 0 .../{0062.json => trainer_unknown_062.json} | 0 .../{0063.json => trainer_unknown_063.json} | 0 .../{0064.json => trainer_unknown_064.json} | 0 .../{0077.json => trainer_unknown_077.json} | 0 .../{0086.json => trainer_unknown_086.json} | 0 .../{0087.json => trainer_unknown_087.json} | 0 .../{0097.json => trainer_unknown_097.json} | 0 .../{0098.json => trainer_unknown_098.json} | 0 .../{0100.json => trainer_unknown_100.json} | 0 .../{0101.json => trainer_unknown_101.json} | 0 .../{0109.json => trainer_unknown_109.json} | 0 .../{0112.json => trainer_unknown_112.json} | 0 .../{0115.json => trainer_unknown_115.json} | 0 .../{0116.json => trainer_unknown_116.json} | 0 .../{0117.json => trainer_unknown_117.json} | 0 .../{0118.json => trainer_unknown_118.json} | 0 .../{0122.json => trainer_unknown_122.json} | 0 .../{0123.json => trainer_unknown_123.json} | 0 .../{0124.json => trainer_unknown_124.json} | 0 .../{0125.json => trainer_unknown_125.json} | 0 .../{0126.json => trainer_unknown_126.json} | 0 .../{0131.json => trainer_unknown_131.json} | 0 .../{0149.json => trainer_unknown_149.json} | 0 .../{0150.json => trainer_unknown_150.json} | 0 .../{0151.json => trainer_unknown_151.json} | 0 .../{0152.json => trainer_unknown_152.json} | 0 .../{0155.json => trainer_unknown_155.json} | 0 .../{0156.json => trainer_unknown_156.json} | 0 .../{0157.json => trainer_unknown_157.json} | 0 .../{0158.json => trainer_unknown_158.json} | 0 .../{0165.json => trainer_unknown_165.json} | 0 .../{0169.json => trainer_unknown_169.json} | 0 .../{0176.json => trainer_unknown_176.json} | 0 .../{0177.json => trainer_unknown_177.json} | 0 .../{0178.json => trainer_unknown_178.json} | 0 .../{0179.json => trainer_unknown_179.json} | 0 .../{0181.json => trainer_unknown_181.json} | 0 .../{0182.json => trainer_unknown_182.json} | 0 .../{0197.json => trainer_unknown_197.json} | 0 .../{0198.json => trainer_unknown_198.json} | 0 .../{0199.json => trainer_unknown_199.json} | 0 .../{0200.json => trainer_unknown_200.json} | 0 .../{0207.json => trainer_unknown_207.json} | 0 .../{0208.json => trainer_unknown_208.json} | 0 .../{0209.json => trainer_unknown_209.json} | 0 .../{0210.json => trainer_unknown_210.json} | 0 .../{0211.json => trainer_unknown_211.json} | 0 .../{0212.json => trainer_unknown_212.json} | 0 .../{0213.json => trainer_unknown_213.json} | 0 .../{0214.json => trainer_unknown_214.json} | 0 .../{0215.json => trainer_unknown_215.json} | 0 .../{0216.json => trainer_unknown_216.json} | 0 .../{0217.json => trainer_unknown_217.json} | 0 .../{0218.json => trainer_unknown_218.json} | 0 .../{0219.json => trainer_unknown_219.json} | 0 .../{0220.json => trainer_unknown_220.json} | 0 .../{0221.json => trainer_unknown_221.json} | 0 .../{0222.json => trainer_unknown_222.json} | 0 .../{0223.json => trainer_unknown_223.json} | 0 .../{0238.json => trainer_unknown_238.json} | 0 .../{0239.json => trainer_unknown_239.json} | 0 .../{0241.json => trainer_unknown_241.json} | 0 .../{0242.json => trainer_unknown_242.json} | 0 .../{0243.json => trainer_unknown_243.json} | 0 .../{0251.json => trainer_unknown_251.json} | 0 .../{0252.json => trainer_unknown_252.json} | 0 .../{0253.json => trainer_unknown_253.json} | 0 .../{0254.json => trainer_unknown_254.json} | 0 .../{0255.json => trainer_unknown_255.json} | 0 .../{0291.json => trainer_unknown_291.json} | 0 .../{0321.json => trainer_unknown_321.json} | 0 .../{0334.json => trainer_unknown_334.json} | 0 .../{0336.json => trainer_unknown_336.json} | 0 .../{0347.json => trainer_unknown_347.json} | 0 .../{0349.json => trainer_unknown_349.json} | 0 .../{0350.json => trainer_unknown_350.json} | 0 .../{0351.json => trainer_unknown_351.json} | 0 .../{0352.json => trainer_unknown_352.json} | 0 .../{0353.json => trainer_unknown_353.json} | 0 .../{0354.json => trainer_unknown_354.json} | 0 .../{0363.json => trainer_unknown_363.json} | 0 .../{0364.json => trainer_unknown_364.json} | 0 .../{0365.json => trainer_unknown_365.json} | 0 .../{0368.json => trainer_unknown_368.json} | 0 .../{0369.json => trainer_unknown_369.json} | 0 .../{0370.json => trainer_unknown_370.json} | 0 .../{0371.json => trainer_unknown_371.json} | 0 .../{0374.json => trainer_unknown_374.json} | 0 .../{0375.json => trainer_unknown_375.json} | 0 .../{0376.json => trainer_unknown_376.json} | 0 .../{0384.json => trainer_unknown_384.json} | 0 .../{0385.json => trainer_unknown_385.json} | 0 .../{0387.json => trainer_unknown_387.json} | 0 .../{0391.json => trainer_unknown_391.json} | 0 .../{0402.json => trainer_unknown_402.json} | 0 .../{0411.json => trainer_unknown_411.json} | 0 .../{0413.json => trainer_unknown_413.json} | 0 .../{0424.json => trainer_unknown_424.json} | 0 .../{0429.json => trainer_unknown_429.json} | 0 .../{0431.json => trainer_unknown_431.json} | 0 .../{0432.json => trainer_unknown_432.json} | 0 .../{0433.json => trainer_unknown_433.json} | 0 .../{0434.json => trainer_unknown_434.json} | 0 .../{0435.json => trainer_unknown_435.json} | 0 .../{0436.json => trainer_unknown_436.json} | 0 .../{0437.json => trainer_unknown_437.json} | 0 .../{0438.json => trainer_unknown_438.json} | 0 .../{0439.json => trainer_unknown_439.json} | 0 .../{0440.json => trainer_unknown_440.json} | 0 .../{0441.json => trainer_unknown_441.json} | 0 .../{0448.json => trainer_unknown_448.json} | 0 .../{0449.json => trainer_unknown_449.json} | 0 .../{0460.json => trainer_unknown_460.json} | 0 .../{0461.json => trainer_unknown_461.json} | 0 .../{0462.json => trainer_unknown_462.json} | 0 .../{0463.json => trainer_unknown_463.json} | 0 .../{0464.json => trainer_unknown_464.json} | 0 .../{0465.json => trainer_unknown_465.json} | 0 .../{0466.json => trainer_unknown_466.json} | 0 .../{0467.json => trainer_unknown_467.json} | 0 .../{0468.json => trainer_unknown_468.json} | 0 .../{0469.json => trainer_unknown_469.json} | 0 .../{0484.json => trainer_unknown_484.json} | 0 .../{0485.json => trainer_unknown_485.json} | 0 .../{0487.json => trainer_unknown_487.json} | 0 .../{0493.json => trainer_unknown_493.json} | 0 .../{0495.json => trainer_unknown_495.json} | 0 .../{0501.json => trainer_unknown_501.json} | 0 .../{0502.json => trainer_unknown_502.json} | 0 .../{0511.json => trainer_unknown_511.json} | 0 .../{0605.json => trainer_unknown_605.json} | 0 .../{0651.json => trainer_unknown_651.json} | 0 .../{0652.json => trainer_unknown_652.json} | 0 .../{0778.json => trainer_unknown_778.json} | 0 .../{0779.json => trainer_unknown_779.json} | 0 .../{0780.json => trainer_unknown_780.json} | 0 .../{0781.json => trainer_unknown_781.json} | 0 .../{0782.json => trainer_unknown_782.json} | 0 .../{0783.json => trainer_unknown_783.json} | 0 .../{0784.json => trainer_unknown_784.json} | 0 .../{0785.json => trainer_unknown_785.json} | 0 .../{0786.json => trainer_unknown_786.json} | 0 .../{0787.json => trainer_unknown_787.json} | 0 .../{0788.json => trainer_unknown_788.json} | 0 .../{0789.json => trainer_unknown_789.json} | 0 .../{0790.json => trainer_unknown_790.json} | 0 .../{0791.json => trainer_unknown_791.json} | 0 .../{0792.json => trainer_unknown_792.json} | 0 .../{0793.json => trainer_unknown_793.json} | 0 .../{0794.json => trainer_unknown_794.json} | 0 .../{0795.json => trainer_unknown_795.json} | 0 .../{0796.json => trainer_unknown_796.json} | 0 .../{0797.json => trainer_unknown_797.json} | 0 .../{0798.json => trainer_unknown_798.json} | 0 .../{0799.json => trainer_unknown_799.json} | 0 .../{0800.json => trainer_unknown_800.json} | 0 .../{0801.json => trainer_unknown_801.json} | 0 .../{0802.json => trainer_unknown_802.json} | 0 .../{0803.json => trainer_unknown_803.json} | 0 .../{0804.json => trainer_unknown_804.json} | 0 .../{0805.json => trainer_unknown_805.json} | 0 .../{0806.json => trainer_unknown_806.json} | 0 .../{0807.json => trainer_unknown_807.json} | 0 .../{0808.json => trainer_unknown_808.json} | 0 .../{0809.json => trainer_unknown_809.json} | 0 .../{0810.json => trainer_unknown_810.json} | 0 .../{0811.json => trainer_unknown_811.json} | 0 .../{0812.json => trainer_unknown_812.json} | 0 .../{0813.json => trainer_unknown_813.json} | 0 .../{0814.json => trainer_unknown_814.json} | 0 .../{0815.json => trainer_unknown_815.json} | 0 .../{0816.json => trainer_unknown_816.json} | 0 .../{0817.json => trainer_unknown_817.json} | 0 .../{0818.json => trainer_unknown_818.json} | 0 .../{0819.json => trainer_unknown_819.json} | 0 .../{0820.json => trainer_unknown_820.json} | 0 .../{0821.json => trainer_unknown_821.json} | 0 .../{0822.json => trainer_unknown_822.json} | 0 .../{0823.json => trainer_unknown_823.json} | 0 .../{0824.json => trainer_unknown_824.json} | 0 .../{0825.json => trainer_unknown_825.json} | 0 .../{0826.json => trainer_unknown_828.json} | 0 .../{0833.json => trainer_unknown_833.json} | 0 .../{0834.json => trainer_unknown_834.json} | 0 .../{0840.json => trainer_unknown_840.json} | 0 .../{0841.json => trainer_unknown_841.json} | 0 .../{0842.json => trainer_unknown_842.json} | 0 .../{0902.json => trainer_unknown_902.json} | 0 .../{0903.json => trainer_unknown_903.json} | 0 .../{0904.json => trainer_unknown_904.json} | 0 .../{0905.json => trainer_unknown_905.json} | 0 ...0362.json => trainer_veteran_armando.json} | 0 ...n => trainer_veteran_armando_rematch.json} | 0 ...0500.json => trainer_veteran_brenden.json} | 0 .../{0068.json => trainer_veteran_brian.json} | 0 ...n => trainer_veteran_brian_rematch_1.json} | 0 ...n => trainer_veteran_brian_rematch_2.json} | 0 ...0229.json => trainer_veteran_clayton.json} | 0 .../{0228.json => trainer_veteran_edgar.json} | 0 ...0552.json => trainer_veteran_emanuel.json} | 0 .../{0240.json => trainer_veteran_grant.json} | 0 ...{0606.json => trainer_veteran_harlan.json} | 0 ...0499.json => trainer_veteran_terrell.json} | 0 .../{0366.json => trainer_waitress_kati.json} | 0 .../{0504.json => trainer_worker_braden.json} | 0 ...{0505.json => trainer_worker_brendon.json} | 0 .../{0195.json => trainer_worker_colin.json} | 0 .../{0846.json => trainer_worker_conrad.json} | 0 .../{0844.json => trainer_worker_dillan.json} | 0 .../{0257.json => trainer_worker_gary.json} | 0 ...{0367.json => trainer_worker_gerardo.json} | 0 .../{0845.json => trainer_worker_holden.json} | 0 ...{0256.json => trainer_worker_jackson.json} | 0 .../{0196.json => trainer_worker_mason.json} | 0 .../{0503.json => trainer_worker_noel.json} | 0 ...{0506.json => trainer_worker_quentin.json} | 0 ...=> trainer_young_couple_mike_and_nat.json} | 0 ...n => trainer_young_couple_ty_and_sue.json} | 0 ...033.json => trainer_youngster_austin.json} | 0 ...355.json => trainer_youngster_dallas.json} | 0 ...> trainer_youngster_dallas_rematch_1.json} | 0 ...> trainer_youngster_dallas_rematch_2.json} | 0 ...> trainer_youngster_dallas_rematch_3.json} | 0 ...245.json => trainer_youngster_darius.json} | 0 ...0357.json => trainer_youngster_donny.json} | 0 ...4.json => trainer_youngster_jonathon.json} | 0 ...0002.json => trainer_youngster_logan.json} | 0 ...04.json => trainer_youngster_michael.json} | 0 ...532.json => trainer_youngster_oliver.json} | 0 ....json => trainer_youngster_sebastian.json} | 0 ...01.json => trainer_youngster_tristan.json} | 0 ... trainer_youngster_tristan_rematch_1.json} | 0 ... trainer_youngster_tristan_rematch_2.json} | 0 ... trainer_youngster_tristan_rematch_3.json} | 0 ...0010.json => trainer_youngster_tyler.json} | 0 ...0496.json => trainer_youngster_wayne.json} | 0 res/trainers/trainers.order | 928 +++++++++++++++++ 930 files changed, 1880 insertions(+), 14 deletions(-) rename res/trainers/{0572.json => trainer_ace_trainer_abel.json} (100%) rename res/trainers/{0271.json => trainer_ace_trainer_alicia.json} (100%) rename res/trainers/{0280.json => trainer_ace_trainer_allen.json} (100%) rename res/trainers/{0067.json => trainer_ace_trainer_alyssa.json} (100%) rename res/trainers/{0827.json => trainer_ace_trainer_anton.json} (100%) rename res/trainers/{0390.json => trainer_ace_trainer_arthur.json} (100%) rename res/trainers/{0132.json => trainer_ace_trainer_blake.json} (100%) rename res/trainers/{0393.json => trainer_ace_trainer_brandi.json} (100%) rename res/trainers/{0283.json => trainer_ace_trainer_breanna.json} (100%) rename res/trainers/{0392.json => trainer_ace_trainer_brenda.json} (100%) rename res/trainers/{0828.json => trainer_ace_trainer_brenna.json} (100%) rename res/trainers/{0284.json => trainer_ace_trainer_catherine.json} (100%) rename res/trainers/{0279.json => trainer_ace_trainer_cesar.json} (100%) rename res/trainers/{0394.json => trainer_ace_trainer_clarice.json} (100%) rename res/trainers/{0140.json => trainer_ace_trainer_dalton.json} (100%) rename res/trainers/{0648.json => trainer_ace_trainer_dalton_rematch.json} (100%) rename res/trainers/{0575.json => trainer_ace_trainer_dana.json} (100%) rename res/trainers/{0573.json => trainer_ace_trainer_deanna.json} (100%) rename res/trainers/{0671.json => trainer_ace_trainer_deanna_rematch.json} (100%) rename res/trainers/{0278.json => trainer_ace_trainer_dennis.json} (100%) rename res/trainers/{0664.json => trainer_ace_trainer_dennis_rematch_1.json} (100%) rename res/trainers/{0665.json => trainer_ace_trainer_dennis_rematch_2.json} (100%) rename res/trainers/{0285.json => trainer_ace_trainer_destiny.json} (100%) rename res/trainers/{0066.json => trainer_ace_trainer_ernest.json} (100%) rename res/trainers/{0566.json => trainer_ace_trainer_felix.json} (100%) rename res/trainers/{0133.json => trainer_ace_trainer_garrett.json} (100%) rename res/trainers/{0568.json => trainer_ace_trainer_graham.json} (100%) rename res/trainers/{0225.json => trainer_ace_trainer_henry.json} (100%) rename res/trainers/{0269.json => trainer_ace_trainer_isaiah.json} (100%) rename res/trainers/{0170.json => trainer_ace_trainer_jake.json} (100%) rename res/trainers/{0663.json => trainer_ace_trainer_jake_rematch.json} (100%) rename res/trainers/{0286.json => trainer_ace_trainer_jamie.json} (100%) rename res/trainers/{0580.json => trainer_ace_trainer_jasmin.json} (100%) rename res/trainers/{0388.json => trainer_ace_trainer_jonah.json} (100%) rename res/trainers/{0565.json => trainer_ace_trainer_jose.json} (100%) rename res/trainers/{0579.json => trainer_ace_trainer_kassandra.json} (100%) rename res/trainers/{0569.json => trainer_ace_trainer_keenan.json} (100%) rename res/trainers/{0134.json => trainer_ace_trainer_laura.json} (100%) rename res/trainers/{0135.json => trainer_ace_trainer_maria.json} (100%) rename res/trainers/{0226.json => trainer_ace_trainer_mariah.json} (100%) rename res/trainers/{0287.json => trainer_ace_trainer_maya.json} (100%) rename res/trainers/{0669.json => trainer_ace_trainer_maya_rematch_1.json} (100%) rename res/trainers/{0670.json => trainer_ace_trainer_maya_rematch_2.json} (100%) rename res/trainers/{0577.json => trainer_ace_trainer_meagan.json} (100%) rename res/trainers/{0389.json => trainer_ace_trainer_micah.json} (100%) rename res/trainers/{0576.json => trainer_ace_trainer_mikayla.json} (100%) rename res/trainers/{0574.json => trainer_ace_trainer_moira.json} (100%) rename res/trainers/{0672.json => trainer_ace_trainer_moira_rematch.json} (100%) rename res/trainers/{0582.json => trainer_ace_trainer_monique.json} (100%) rename res/trainers/{0581.json => trainer_ace_trainer_natasha.json} (100%) rename res/trainers/{0141.json => trainer_ace_trainer_olivia.json} (100%) rename res/trainers/{0649.json => trainer_ace_trainer_olivia_rematch.json} (100%) rename res/trainers/{0224.json => trainer_ace_trainer_omar.json} (100%) rename res/trainers/{0567.json => trainer_ace_trainer_quinn.json} (100%) rename res/trainers/{0563.json => trainer_ace_trainer_rodolfo.json} (100%) rename res/trainers/{0666.json => trainer_ace_trainer_rodolfo_rematch.json} (100%) rename res/trainers/{0282.json => trainer_ace_trainer_ruben.json} (100%) rename res/trainers/{0578.json => trainer_ace_trainer_sandra.json} (100%) rename res/trainers/{0564.json => trainer_ace_trainer_saul.json} (100%) rename res/trainers/{0667.json => trainer_ace_trainer_saul_rematch.json} (100%) rename res/trainers/{0270.json => trainer_ace_trainer_savannah.json} (100%) rename res/trainers/{0268.json => trainer_ace_trainer_sergio.json} (100%) rename res/trainers/{0171.json => trainer_ace_trainer_shannon.json} (100%) rename res/trainers/{0668.json => trainer_ace_trainer_shannon_rematch.json} (100%) rename res/trainers/{0571.json => trainer_ace_trainer_skylar.json} (100%) rename res/trainers/{0570.json => trainer_ace_trainer_stefan.json} (100%) rename res/trainers/{0227.json => trainer_ace_trainer_sydney.json} (100%) rename res/trainers/{0281.json => trainer_ace_trainer_zachery.json} (100%) rename res/trainers/{0535.json => trainer_aroma_lady_alison.json} (100%) rename res/trainers/{0260.json => trainer_aroma_lady_angela.json} (100%) rename res/trainers/{0021.json => trainer_aroma_lady_elizabeth.json} (100%) rename res/trainers/{0627.json => trainer_aroma_lady_elizabeth_rematch_1.json} (100%) rename res/trainers/{0628.json => trainer_aroma_lady_elizabeth_rematch_2.json} (100%) rename res/trainers/{0629.json => trainer_aroma_lady_elizabeth_rematch_3.json} (100%) rename res/trainers/{0044.json => trainer_aroma_lady_hannah.json} (100%) rename res/trainers/{0259.json => trainer_aroma_lady_jenna.json} (100%) rename res/trainers/{0014.json => trainer_aroma_lady_taylor.json} (100%) rename res/trainers/{0536.json => trainer_artist_ismael.json} (100%) rename res/trainers/{0045.json => trainer_artist_william.json} (100%) rename res/trainers/{0630.json => trainer_artist_william_rematch_1.json} (100%) rename res/trainers/{0631.json => trainer_artist_william_rematch_2.json} (100%) rename res/trainers/{0632.json => trainer_artist_william_rematch_3.json} (100%) rename res/trainers/{0038.json => trainer_battle_girl_helen.json} (100%) rename res/trainers/{0633.json => trainer_battle_girl_helen_rematch_1.json} (100%) rename res/trainers/{0634.json => trainer_battle_girl_helen_rematch_2.json} (100%) rename res/trainers/{0635.json => trainer_battle_girl_helen_rematch_3.json} (100%) rename res/trainers/{0020.json => trainer_battle_girl_kelsey.json} (100%) rename res/trainers/{0372.json => trainer_battle_girl_tyler.json} (100%) rename res/trainers/{0346.json => trainer_beauty_cyndy.json} (100%) rename res/trainers/{0749.json => trainer_beauty_cyndy_rematch_1.json} (100%) rename res/trainers/{0750.json => trainer_beauty_cyndy_rematch_2.json} (100%) rename res/trainers/{0491.json => trainer_beauty_devon.json} (100%) rename res/trainers/{0550.json => trainer_beauty_gabriella.json} (100%) rename res/trainers/{0551.json => trainer_beauty_harley.json} (100%) rename res/trainers/{0348.json => trainer_beauty_lindsay.json} (100%) rename res/trainers/{0492.json => trainer_beauty_nicola.json} (100%) rename res/trainers/{0290.json => trainer_belle_and_pa_ava_and_matt.json} (100%) rename res/trainers/{0533.json => trainer_belle_and_pa_beth_and_bob.json} (100%) rename res/trainers/{0076.json => trainer_bird_keeper_alexandra.json} (100%) rename res/trainers/{0554.json => trainer_bird_keeper_audrey.json} (100%) rename res/trainers/{0638.json => trainer_bird_keeper_audrey_rematch.json} (100%) rename res/trainers/{0373.json => trainer_bird_keeper_autumn.json} (100%) rename res/trainers/{0074.json => trainer_bird_keeper_brianna.json} (100%) rename res/trainers/{0636.json => trainer_bird_keeper_brianna_rematch_1.json} (100%) rename res/trainers/{0637.json => trainer_bird_keeper_brianna_rematch_2.json} (100%) rename res/trainers/{0555.json => trainer_bird_keeper_geneva.json} (100%) rename res/trainers/{0233.json => trainer_bird_keeper_hana.json} (100%) rename res/trainers/{0081.json => trainer_bird_keeper_katherine.json} (100%) rename res/trainers/{0556.json => trainer_bird_keeper_krystal.json} (100%) rename res/trainers/{0069.json => trainer_black_belt_adam.json} (100%) rename res/trainers/{0313.json => trainer_black_belt_carl.json} (100%) rename res/trainers/{0309.json => trainer_black_belt_colby.json} (100%) rename res/trainers/{0310.json => trainer_black_belt_darren.json} (100%) rename res/trainers/{0232.json => trainer_black_belt_david.json} (100%) rename res/trainers/{0587.json => trainer_black_belt_davon.json} (100%) rename res/trainers/{0700.json => trainer_black_belt_davon_rematch.json} (100%) rename res/trainers/{0128.json => trainer_black_belt_derek.json} (100%) rename res/trainers/{0446.json => trainer_black_belt_eddie.json} (100%) rename res/trainers/{0127.json => trainer_black_belt_gregory.json} (100%) rename res/trainers/{0588.json => trainer_black_belt_griffin.json} (100%) rename res/trainers/{0590.json => trainer_black_belt_jarrett.json} (100%) rename res/trainers/{0312.json => trainer_black_belt_jeffery.json} (100%) rename res/trainers/{0445.json => trainer_black_belt_kendal.json} (100%) rename res/trainers/{0042.json => trainer_black_belt_kyle.json} (100%) rename res/trainers/{0148.json => trainer_black_belt_luke.json} (100%) rename res/trainers/{0444.json => trainer_black_belt_miles.json} (100%) rename res/trainers/{0129.json => trainer_black_belt_nathaniel.json} (100%) rename res/trainers/{0258.json => trainer_black_belt_philip.json} (100%) rename res/trainers/{0699.json => trainer_black_belt_philip_rematch.json} (100%) rename res/trainers/{0311.json => trainer_black_belt_rafael.json} (100%) rename res/trainers/{0589.json => trainer_black_belt_ray.json} (100%) rename res/trainers/{0314.json => trainer_black_belt_ricky.json} (100%) rename res/trainers/{0079.json => trainer_black_belt_sean.json} (100%) rename res/trainers/{0447.json => trainer_black_belt_willie.json} (100%) rename res/trainers/{0046.json => trainer_breeder_albert.json} (100%) rename res/trainers/{0639.json => trainer_breeder_albert_rematch_1.json} (100%) rename res/trainers/{0640.json => trainer_breeder_albert_rematch_2.json} (100%) rename res/trainers/{0641.json => trainer_breeder_albert_rematch_3.json} (100%) rename res/trainers/{0057.json => trainer_breeder_amber.json} (100%) rename res/trainers/{0047.json => trainer_breeder_jennifer.json} (100%) rename res/trainers/{0642.json => trainer_breeder_jennifer_rematch_1.json} (100%) rename res/trainers/{0643.json => trainer_breeder_jennifer_rematch_2.json} (100%) rename res/trainers/{0644.json => trainer_breeder_jennifer_rematch_3.json} (100%) rename res/trainers/{0056.json => trainer_breeder_kahlil.json} (100%) rename res/trainers/{0537.json => trainer_breeder_kaylee.json} (100%) rename res/trainers/{0013.json => trainer_bug_catcher_brandon.json} (100%) rename res/trainers/{0712.json => trainer_bug_catcher_brandon_rematch_1.json} (100%) rename res/trainers/{0713.json => trainer_bug_catcher_brandon_rematch_2.json} (100%) rename res/trainers/{0714.json => trainer_bug_catcher_brandon_rematch_3.json} (100%) rename res/trainers/{0203.json => trainer_bug_catcher_donald.json} (100%) rename res/trainers/{0201.json => trainer_bug_catcher_jack.json} (100%) rename res/trainers/{0202.json => trainer_bug_catcher_phillip.json} (100%) rename res/trainers/{0538.json => trainer_cameraman_darryl.json} (100%) rename res/trainers/{0874.json => trainer_cameraman_tevin.json} (100%) rename res/trainers/{0875.json => trainer_cameraman_tevin_rematch_1.json} (100%) rename res/trainers/{0876.json => trainer_cameraman_tevin_rematch_2.json} (100%) rename res/trainers/{0906.json => trainer_cameraman_tevin_rematch_3.json} (100%) rename res/trainers/{0914.json => trainer_cameraman_tevin_rematch_4.json} (100%) rename res/trainers/{0034.json => trainer_camper_anthony.json} (100%) rename res/trainers/{0265.json => trainer_camper_curtis.json} (100%) rename res/trainers/{0379.json => trainer_camper_diego.json} (100%) rename res/trainers/{0266.json => trainer_camper_drew.json} (100%) rename res/trainers/{0016.json => trainer_camper_jacob.json} (100%) rename res/trainers/{0378.json => trainer_camper_lawrence.json} (100%) rename res/trainers/{0380.json => trainer_camper_parker.json} (100%) rename res/trainers/{0377.json => trainer_camper_zackary.json} (100%) rename res/trainers/{0645.json => trainer_camper_zackary_rematch_1.json} (100%) rename res/trainers/{0646.json => trainer_camper_zackary_rematch_2.json} (100%) rename res/trainers/{0647.json => trainer_camper_zackary_rematch_3.json} (100%) rename res/trainers/{0267.json => trainer_champion_cynthia.json} (100%) rename res/trainers/{0870.json => trainer_champion_cynthia_rematch.json} (100%) rename res/trainers/{0886.json => trainer_clown_lee.json} (100%) rename res/trainers/{0887.json => trainer_clown_lee_rematch_1.json} (100%) rename res/trainers/{0888.json => trainer_clown_lee_rematch_2.json} (100%) rename res/trainers/{0910.json => trainer_clown_lee_rematch_3.json} (100%) rename res/trainers/{0918.json => trainer_clown_lee_rematch_4.json} (100%) rename res/trainers/{0273.json => trainer_collector_brady.json} (100%) rename res/trainers/{0381.json => trainer_collector_dean.json} (100%) rename res/trainers/{0272.json => trainer_collector_douglas.json} (100%) rename res/trainers/{0276.json => trainer_collector_edwin.json} (100%) rename res/trainers/{0539.json => trainer_collector_eugene.json} (100%) rename res/trainers/{0275.json => trainer_collector_fernando.json} (100%) rename res/trainers/{0274.json => trainer_collector_ivan.json} (100%) rename res/trainers/{0650.json => trainer_collector_ivan_rematch.json} (100%) rename res/trainers/{0382.json => trainer_collector_jamal.json} (100%) rename res/trainers/{0383.json => trainer_collector_terry.json} (100%) rename res/trainers/{0407.json => trainer_commander_jupiter_spear_pillar.json} (100%) rename res/trainers/{0927.json => trainer_commander_jupiter_stark_mountain.json} (100%) rename res/trainers/{0406.json => trainer_commander_jupiter_team_galactic_eterna_building.json} (100%) rename res/trainers/{0405.json => trainer_commander_mars_lake_verity.json} (100%) rename res/trainers/{0528.json => trainer_commander_mars_spear_pillar.json} (100%) rename res/trainers/{0926.json => trainer_commander_mars_stark_mountain.json} (100%) rename res/trainers/{0295.json => trainer_commander_mars_valley_windworks.json} (100%) rename res/trainers/{0409.json => trainer_commander_saturn_galactic_hq.json} (100%) rename res/trainers/{0408.json => trainer_commander_saturn_valor_cavern.json} (100%) rename res/trainers/{0048.json => trainer_cowgirl_shelley.json} (100%) rename res/trainers/{0025.json => trainer_cyclist_axel.json} (100%) rename res/trainers/{0026.json => trainer_cyclist_james.json} (100%) rename res/trainers/{0027.json => trainer_cyclist_john.json} (100%) rename res/trainers/{0653.json => trainer_cyclist_john_rematch_1.json} (100%) rename res/trainers/{0654.json => trainer_cyclist_john_rematch_2.json} (100%) rename res/trainers/{0655.json => trainer_cyclist_john_rematch_3.json} (100%) rename res/trainers/{0031.json => trainer_cyclist_kayla.json} (100%) rename res/trainers/{0656.json => trainer_cyclist_kayla_rematch_1.json} (100%) rename res/trainers/{0657.json => trainer_cyclist_kayla_rematch_2.json} (100%) rename res/trainers/{0658.json => trainer_cyclist_kayla_rematch_3.json} (100%) rename res/trainers/{0029.json => trainer_cyclist_megan.json} (100%) rename res/trainers/{0030.json => trainer_cyclist_nicole.json} (100%) rename res/trainers/{0032.json => trainer_cyclist_rachel.json} (100%) rename res/trainers/{0028.json => trainer_cyclist_ryan.json} (100%) rename res/trainers/{0616.json => trainer_dawn_jubilife_city_chimchar.json} (100%) rename res/trainers/{0617.json => trainer_dawn_jubilife_city_piplup.json} (100%) rename res/trainers/{0618.json => trainer_dawn_jubilife_city_turtwig.json} (100%) rename res/trainers/{0624.json => trainer_dawn_veilstone_city_chimchar.json} (100%) rename res/trainers/{0625.json => trainer_dawn_veilstone_city_piplup.json} (100%) rename res/trainers/{0626.json => trainer_dawn_veilstone_city_turtwig.json} (100%) rename res/trainers/{0237.json => trainer_double_team_al_and_kay.json} (100%) rename res/trainers/{0236.json => trainer_double_team_jo_and_pat.json} (100%) rename res/trainers/{0075.json => trainer_double_team_zac_and_jen.json} (100%) rename res/trainers/{0231.json => trainer_dragon_tamer_clinton.json} (100%) rename res/trainers/{0558.json => trainer_dragon_tamer_darien.json} (100%) rename res/trainers/{0561.json => trainer_dragon_tamer_drake.json} (100%) rename res/trainers/{0557.json => trainer_dragon_tamer_geoffrey.json} (100%) rename res/trainers/{0662.json => trainer_dragon_tamer_geoffrey_rematch.json} (100%) rename res/trainers/{0277.json => trainer_dragon_tamer_hayden.json} (100%) rename res/trainers/{0661.json => trainer_dragon_tamer_hayden_rematch.json} (100%) rename res/trainers/{0386.json => trainer_dragon_tamer_joe.json} (100%) rename res/trainers/{0559.json => trainer_dragon_tamer_keegan.json} (100%) rename res/trainers/{0562.json => trainer_dragon_tamer_kenny.json} (100%) rename res/trainers/{0230.json => trainer_dragon_tamer_ondrej.json} (100%) rename res/trainers/{0073.json => trainer_dragon_tamer_patrick.json} (100%) rename res/trainers/{0659.json => trainer_dragon_tamer_patrick_rematch_1.json} (100%) rename res/trainers/{0660.json => trainer_dragon_tamer_patrick_rematch_2.json} (100%) rename res/trainers/{0560.json => trainer_dragon_tamer_stanley.json} (100%) rename res/trainers/{0261.json => trainer_elite_four_aaron.json} (100%) rename res/trainers/{0866.json => trainer_elite_four_aaron_rematch.json} (100%) rename res/trainers/{0262.json => trainer_elite_four_bertha.json} (100%) rename res/trainers/{0867.json => trainer_elite_four_bertha_rematch.json} (100%) rename res/trainers/{0263.json => trainer_elite_four_flint.json} (100%) rename res/trainers/{0922.json => trainer_elite_four_flint_fight_area.json} (100%) rename res/trainers/{0868.json => trainer_elite_four_flint_rematch.json} (100%) rename res/trainers/{0264.json => trainer_elite_four_lucian.json} (100%) rename res/trainers/{0869.json => trainer_elite_four_lucian_rematch.json} (100%) rename res/trainers/{0173.json => trainer_fisherman_alec.json} (100%) rename res/trainers/{0686.json => trainer_fisherman_alec_rematch.json} (100%) rename res/trainers/{0022.json => trainer_fisherman_andrew.json} (100%) rename res/trainers/{0172.json => trainer_fisherman_brett.json} (100%) rename res/trainers/{0043.json => trainer_fisherman_cody.json} (100%) rename res/trainers/{0175.json => trainer_fisherman_cole.json} (100%) rename res/trainers/{0168.json => trainer_fisherman_cory.json} (100%) rename res/trainers/{0293.json => trainer_fisherman_erick.json} (100%) rename res/trainers/{0174.json => trainer_fisherman_george.json} (100%) rename res/trainers/{0023.json => trainer_fisherman_joseph.json} (100%) rename res/trainers/{0683.json => trainer_fisherman_joseph_rematch_1.json} (100%) rename res/trainers/{0684.json => trainer_fisherman_joseph_rematch_2.json} (100%) rename res/trainers/{0092.json => trainer_fisherman_josh.json} (100%) rename res/trainers/{0091.json => trainer_fisherman_juan.json} (100%) rename res/trainers/{0111.json => trainer_fisherman_kenneth.json} (100%) rename res/trainers/{0154.json => trainer_fisherman_luc.json} (100%) rename res/trainers/{0153.json => trainer_fisherman_miguel.json} (100%) rename res/trainers/{0685.json => trainer_fisherman_miguel_rematch.json} (100%) rename res/trainers/{0093.json => trainer_fisherman_travis.json} (100%) rename res/trainers/{0401.json => trainer_fisherman_walter.json} (100%) rename res/trainers/{0024.json => trainer_fisherman_zachary.json} (100%) rename res/trainers/{0913.json => trainer_galactic_boss_cyrus_celestic_town_ruins.json} (100%) rename res/trainers/{0404.json => trainer_galactic_boss_cyrus_distortion_world.json} (100%) rename res/trainers/{0403.json => trainer_galactic_boss_cyrus_galactic_hq.json} (100%) rename res/trainers/{0416.json => trainer_galactic_grunt_celestic_town.json} (100%) rename res/trainers/{0296.json => trainer_galactic_grunt_floaroma_meadow_1.json} (100%) rename res/trainers/{0297.json => trainer_galactic_grunt_floaroma_meadow_2.json} (100%) rename res/trainers/{0428.json => trainer_galactic_grunt_galactic_hq_1f.json} (100%) rename res/trainers/{0510.json => trainer_galactic_grunt_galactic_hq_2f_1.json} (100%) rename res/trainers/{0513.json => trainer_galactic_grunt_galactic_hq_2f_2.json} (100%) rename res/trainers/{0430.json => trainer_galactic_grunt_galactic_hq_2f_3.json} (100%) rename res/trainers/{0509.json => trainer_galactic_grunt_galactic_hq_3f_1.json} (100%) rename res/trainers/{0512.json => trainer_galactic_grunt_galactic_hq_3f_2.json} (100%) rename res/trainers/{0514.json => trainer_galactic_grunt_galactic_hq_3f_3.json} (100%) rename res/trainers/{0522.json => trainer_galactic_grunt_galactic_hq_3f_4.json} (100%) rename res/trainers/{0507.json => trainer_galactic_grunt_galactic_hq_b2f_1.json} (100%) rename res/trainers/{0508.json => trainer_galactic_grunt_galactic_hq_b2f_2.json} (100%) rename res/trainers/{0835.json => trainer_galactic_grunt_iron_island_1.json} (100%) rename res/trainers/{0836.json => trainer_galactic_grunt_iron_island_2.json} (100%) rename res/trainers/{0414.json => trainer_galactic_grunt_jubilife_city_1.json} (100%) rename res/trainers/{0415.json => trainer_galactic_grunt_jubilife_city_2.json} (100%) rename res/trainers/{0417.json => trainer_galactic_grunt_lake_valor_1.json} (100%) rename res/trainers/{0418.json => trainer_galactic_grunt_lake_valor_2.json} (100%) rename res/trainers/{0425.json => trainer_galactic_grunt_lake_valor_3.json} (100%) rename res/trainers/{0419.json => trainer_galactic_grunt_lake_verity_1.json} (100%) rename res/trainers/{0426.json => trainer_galactic_grunt_lake_verity_2.json} (100%) rename res/trainers/{0420.json => trainer_galactic_grunt_lake_verity_3.json} (100%) rename res/trainers/{0427.json => trainer_galactic_grunt_lake_verity_4.json} (100%) rename res/trainers/{0515.json => trainer_galactic_grunt_mt_coronet_3f_1.json} (100%) rename res/trainers/{0516.json => trainer_galactic_grunt_mt_coronet_4f_1.json} (100%) rename res/trainers/{0517.json => trainer_galactic_grunt_mt_coronet_4f_2.json} (100%) rename res/trainers/{0520.json => trainer_galactic_grunt_mt_coronet_5f_1.json} (100%) rename res/trainers/{0525.json => trainer_galactic_grunt_mt_coronet_5f_2.json} (100%) rename res/trainers/{0526.json => trainer_galactic_grunt_mt_coronet_6f.json} (100%) rename res/trainers/{0523.json => trainer_galactic_grunt_mt_coronet__3f_1.json} (100%) rename res/trainers/{0518.json => trainer_galactic_grunt_mt_coronet_tunnel_room_1.json} (100%) rename res/trainers/{0519.json => trainer_galactic_grunt_mt_coronet_tunnel_room_2.json} (100%) rename res/trainers/{0524.json => trainer_galactic_grunt_mt_coronet_tunnel_room_3.json} (100%) rename res/trainers/{0521.json => trainer_galactic_grunt_spear_pillar_1.json} (100%) rename res/trainers/{0527.json => trainer_galactic_grunt_spear_pillar_2.json} (100%) rename res/trainers/{0410.json => trainer_galactic_grunt_team_galactic_eterna_building_1f_1.json} (100%) rename res/trainers/{0421.json => trainer_galactic_grunt_team_galactic_eterna_building_1f_2.json} (100%) rename res/trainers/{0412.json => trainer_galactic_grunt_team_galactic_eterna_building_2f_1.json} (100%) rename res/trainers/{0422.json => trainer_galactic_grunt_team_galactic_eterna_building_2f_2.json} (100%) rename res/trainers/{0423.json => trainer_galactic_grunt_team_galactic_eterna_building_3f.json} (100%) rename res/trainers/{0843.json => trainer_galactic_grunt_valley_windworks_1.json} (100%) rename res/trainers/{0298.json => trainer_galactic_grunt_valley_windworks_2.json} (100%) rename res/trainers/{0299.json => trainer_galactic_grunt_valley_windworks_3.json} (100%) rename res/trainers/{0847.json => trainer_galactic_grunt_valor_lakefront.json} (100%) rename res/trainers/{0848.json => trainer_galactic_grunt_veilstone_city_1.json} (100%) rename res/trainers/{0849.json => trainer_galactic_grunt_veilstone_city_2.json} (100%) rename res/trainers/{0084.json => trainer_gentleman_jeremy.json} (100%) rename res/trainers/{0691.json => trainer_gentleman_jeremy_rematch_1.json} (100%) rename res/trainers/{0692.json => trainer_gentleman_jeremy_rematch_2.json} (100%) rename res/trainers/{0693.json => trainer_gentleman_jeremy_rematch_3.json} (100%) rename res/trainers/{0542.json => trainer_gentleman_leonardo.json} (100%) rename res/trainers/{0877.json => trainer_guitarist_arturo.json} (100%) rename res/trainers/{0878.json => trainer_guitarist_arturo_rematch_1.json} (100%) rename res/trainers/{0879.json => trainer_guitarist_arturo_rematch_2.json} (100%) rename res/trainers/{0907.json => trainer_guitarist_arturo_rematch_3.json} (100%) rename res/trainers/{0915.json => trainer_guitarist_arturo_rematch_4.json} (100%) rename res/trainers/{0301.json => trainer_guitarist_jerry.json} (100%) rename res/trainers/{0303.json => trainer_guitarist_lonnie.json} (100%) rename res/trainers/{0302.json => trainer_guitarist_preston.json} (100%) rename res/trainers/{0300.json => trainer_guitarist_tony.json} (100%) rename res/trainers/{0694.json => trainer_guitarist_tony_rematch.json} (100%) rename res/trainers/{0040.json => trainer_hiker_alexander.json} (100%) rename res/trainers/{0452.json => trainer_hiker_damon.json} (100%) rename res/trainers/{0018.json => trainer_hiker_daniel.json} (100%) rename res/trainers/{0041.json => trainer_hiker_jonathan.json} (100%) rename res/trainers/{0037.json => trainer_hiker_justin.json} (100%) rename res/trainers/{0036.json => trainer_hiker_kevin.json} (100%) rename res/trainers/{0455.json => trainer_hiker_lorenzo.json} (100%) rename res/trainers/{0326.json => trainer_hiker_louis.json} (100%) rename res/trainers/{0453.json => trainer_hiker_maurice.json} (100%) rename res/trainers/{0019.json => trainer_hiker_nicholas.json} (100%) rename res/trainers/{0454.json => trainer_hiker_reginald.json} (100%) rename res/trainers/{0039.json => trainer_hiker_robert.json} (100%) rename res/trainers/{0451.json => trainer_hiker_theodore.json} (100%) rename res/trainers/{0709.json => trainer_hiker_theodore_rematch_1.json} (100%) rename res/trainers/{0710.json => trainer_hiker_theodore_rematch_2.json} (100%) rename res/trainers/{0711.json => trainer_hiker_theodore_rematch_3.json} (100%) rename res/trainers/{0880.json => trainer_idol_grace.json} (100%) rename res/trainers/{0881.json => trainer_idol_grace_rematch_1.json} (100%) rename res/trainers/{0882.json => trainer_idol_grace_rematch_2.json} (100%) rename res/trainers/{0908.json => trainer_idol_grace_rematch_3.json} (100%) rename res/trainers/{0916.json => trainer_idol_grace_rematch_4.json} (100%) rename res/trainers/{0883.json => trainer_interviewers_roxy_and_oli.json} (100%) rename res/trainers/{0884.json => trainer_interviewers_roxy_and_oli_rematch_1.json} (100%) rename res/trainers/{0885.json => trainer_interviewers_roxy_and_oli_rematch_2.json} (100%) rename res/trainers/{0909.json => trainer_interviewers_roxy_and_oli_rematch_3.json} (100%) rename res/trainers/{0917.json => trainer_interviewers_roxy_and_oli_rematch_4.json} (100%) rename res/trainers/{0307.json => trainer_jogger_craig.json} (100%) rename res/trainers/{0697.json => trainer_jogger_craig_rematch_1.json} (100%) rename res/trainers/{0698.json => trainer_jogger_craig_rematch_2.json} (100%) rename res/trainers/{0308.json => trainer_jogger_raul.json} (100%) rename res/trainers/{0049.json => trainer_jogger_richard.json} (100%) rename res/trainers/{0130.json => trainer_jogger_scott.json} (100%) rename res/trainers/{0306.json => trainer_jogger_wyatt.json} (100%) rename res/trainers/{0893.json => trainer_lady_celeste.json} (100%) rename res/trainers/{0546.json => trainer_lady_kylie.json} (100%) rename res/trainers/{0083.json => trainer_lady_melissa.json} (100%) rename res/trainers/{0729.json => trainer_lady_melissa_rematch_1.json} (100%) rename res/trainers/{0730.json => trainer_lady_melissa_rematch_2.json} (100%) rename res/trainers/{0731.json => trainer_lady_melissa_rematch_3.json} (100%) rename res/trainers/{0544.json => trainer_lass_blythe.json} (100%) rename res/trainers/{0204.json => trainer_lass_briana.json} (100%) rename res/trainers/{0324.json => trainer_lass_caroline.json} (100%) rename res/trainers/{0450.json => trainer_lass_cassidy.json} (100%) rename res/trainers/{0323.json => trainer_lass_kaitlin.json} (100%) rename res/trainers/{0322.json => trainer_lass_madeline.json} (100%) rename res/trainers/{0706.json => trainer_lass_madeline_rematch_1.json} (100%) rename res/trainers/{0707.json => trainer_lass_madeline_rematch_2.json} (100%) rename res/trainers/{0708.json => trainer_lass_madeline_rematch_3.json} (100%) rename res/trainers/{0325.json => trainer_lass_molly.json} (100%) rename res/trainers/{0003.json => trainer_lass_natalie.json} (100%) rename res/trainers/{0011.json => trainer_lass_samantha.json} (100%) rename res/trainers/{0703.json => trainer_lass_samantha_rematch_1.json} (100%) rename res/trainers/{0704.json => trainer_lass_samantha_rematch_2.json} (100%) rename res/trainers/{0705.json => trainer_lass_samantha_rematch_3.json} (100%) rename res/trainers/{0012.json => trainer_lass_sarah.json} (100%) rename res/trainers/{0250.json => trainer_leader_byron.json} (100%) rename res/trainers/{0856.json => trainer_leader_byron_rematch.json} (100%) rename res/trainers/{0319.json => trainer_leader_candice.json} (100%) rename res/trainers/{0853.json => trainer_leader_candice_rematch.json} (100%) rename res/trainers/{0318.json => trainer_leader_fantina.json} (100%) rename res/trainers/{0860.json => trainer_leader_fantina_rematch.json} (100%) rename res/trainers/{0315.json => trainer_leader_gardenia.json} (100%) rename res/trainers/{0857.json => trainer_leader_gardenia_rematch.json} (100%) rename res/trainers/{0317.json => trainer_leader_maylene.json} (100%) rename res/trainers/{0854.json => trainer_leader_maylene_rematch.json} (100%) rename res/trainers/{0246.json => trainer_leader_roark.json} (100%) rename res/trainers/{0858.json => trainer_leader_roark_rematch.json} (100%) rename res/trainers/{0320.json => trainer_leader_volkner.json} (100%) rename res/trainers/{0921.json => trainer_leader_volkner_fight_area.json} (100%) rename res/trainers/{0855.json => trainer_leader_volkner_rematch.json} (100%) rename res/trainers/{0316.json => trainer_leader_wake.json} (100%) rename res/trainers/{0859.json => trainer_leader_wake_rematch.json} (100%) rename res/trainers/{0613.json => trainer_lucas_jubilife_city_chimchar.json} (100%) rename res/trainers/{0614.json => trainer_lucas_jubilife_city_piplup.json} (100%) rename res/trainers/{0615.json => trainer_lucas_jubilife_city_turtwig.json} (100%) rename res/trainers/{0621.json => trainer_lucas_veilstone_city_chimchar.json} (100%) rename res/trainers/{0622.json => trainer_lucas_veilstone_city_piplup.json} (100%) rename res/trainers/{0623.json => trainer_lucas_veilstone_city_turtwig.json} (100%) rename res/trainers/{0897.json => trainer_maid_belinda.json} (100%) rename res/trainers/{0901.json => trainer_maid_clare.json} (100%) rename res/trainers/{0900.json => trainer_maid_elena.json} (100%) rename res/trainers/{0899.json => trainer_maid_emily.json} (100%) rename res/trainers/{0898.json => trainer_maid_sophie.json} (100%) rename res/trainers/{0489.json => trainer_ninja_boy_brennan.json} (100%) rename res/trainers/{0490.json => trainer_ninja_boy_bruce.json} (100%) rename res/trainers/{0072.json => trainer_ninja_boy_davido.json} (100%) rename res/trainers/{0147.json => trainer_ninja_boy_ethan.json} (100%) rename res/trainers/{0488.json => trainer_ninja_boy_fabian.json} (100%) rename res/trainers/{0070.json => trainer_ninja_boy_joel.json} (100%) rename res/trainers/{0146.json => trainer_ninja_boy_matthew.json} (100%) rename res/trainers/{0071.json => trainer_ninja_boy_nathan.json} (100%) rename res/trainers/{0080.json => trainer_ninja_boy_nick.json} (100%) rename res/trainers/{0078.json => trainer_ninja_boy_zach.json} (100%) rename res/trainers/{0746.json => trainer_ninja_boy_zach_rematch_1.json} (100%) rename res/trainers/{0747.json => trainer_ninja_boy_zach_rematch_2.json} (100%) rename res/trainers/{0748.json => trainer_ninja_boy_zach_rematch_3.json} (100%) rename res/trainers/{0000.json => trainer_none.json} (100%) rename res/trainers/{0327.json => trainer_parasol_lady_alexa.json} (100%) rename res/trainers/{0715.json => trainer_parasol_lady_alexa_rematch_1.json} (100%) rename res/trainers/{0716.json => trainer_parasol_lady_alexa_rematch_2.json} (100%) rename res/trainers/{0717.json => trainer_parasol_lady_alexa_rematch_3.json} (100%) rename res/trainers/{0328.json => trainer_parasol_lady_sabrina.json} (100%) rename res/trainers/{0121.json => trainer_pi_carlos.json} (100%) rename res/trainers/{0689.json => trainer_pi_carlos_rematch_1.json} (100%) rename res/trainers/{0690.json => trainer_pi_carlos_rematch_2.json} (100%) rename res/trainers/{0541.json => trainer_pi_kendrick.json} (100%) rename res/trainers/{0459.json => trainer_picnicker_ana.json} (100%) rename res/trainers/{0330.json => trainer_picnicker_cheyenne.json} (100%) rename res/trainers/{0329.json => trainer_picnicker_diana.json} (100%) rename res/trainers/{0456.json => trainer_picnicker_karina.json} (100%) rename res/trainers/{0718.json => trainer_picnicker_karina_rematch_1.json} (100%) rename res/trainers/{0719.json => trainer_picnicker_karina_rematch_2.json} (100%) rename res/trainers/{0720.json => trainer_picnicker_karina_rematch_3.json} (100%) rename res/trainers/{0035.json => trainer_picnicker_lauren.json} (100%) rename res/trainers/{0017.json => trainer_picnicker_siena.json} (100%) rename res/trainers/{0457.json => trainer_picnicker_summer.json} (100%) rename res/trainers/{0458.json => trainer_picnicker_tori.json} (100%) rename res/trainers/{0889.json => trainer_poke_kid_ariel.json} (100%) rename res/trainers/{0890.json => trainer_poke_kid_ariel_rematch_1.json} (100%) rename res/trainers/{0891.json => trainer_poke_kid_ariel_rematch_2.json} (100%) rename res/trainers/{0911.json => trainer_poke_kid_ariel_rematch_3.json} (100%) rename res/trainers/{0919.json => trainer_poke_kid_ariel_rematch_4.json} (100%) rename res/trainers/{0053.json => trainer_poke_kid_danielle.json} (100%) rename res/trainers/{0721.json => trainer_poke_kid_danielle_rematch_1.json} (100%) rename res/trainers/{0722.json => trainer_poke_kid_danielle_rematch_2.json} (100%) rename res/trainers/{0723.json => trainer_poke_kid_danielle_rematch_3.json} (100%) rename res/trainers/{0832.json => trainer_poke_kid_janet.json} (100%) rename res/trainers/{0331.json => trainer_poke_kid_meghan.json} (100%) rename res/trainers/{0530.json => trainer_pokefan_leonard.json} (100%) rename res/trainers/{0540.json => trainer_pokefan_meredith.json} (100%) rename res/trainers/{0531.json => trainer_pokefan_rebekah.json} (100%) rename res/trainers/{0089.json => trainer_policeman_alex.json} (100%) rename res/trainers/{0088.json => trainer_policeman_bobby.json} (100%) rename res/trainers/{0102.json => trainer_policeman_caleb.json} (100%) rename res/trainers/{0332.json => trainer_policeman_danny.json} (100%) rename res/trainers/{0724.json => trainer_policeman_danny_rematch_1.json} (100%) rename res/trainers/{0725.json => trainer_policeman_danny_rematch_2.json} (100%) rename res/trainers/{0726.json => trainer_policeman_danny_rematch_3.json} (100%) rename res/trainers/{0090.json => trainer_policeman_dylan.json} (100%) rename res/trainers/{0333.json => trainer_policeman_thomas.json} (100%) rename res/trainers/{0120.json => trainer_psychic_abigail.json} (100%) rename res/trainers/{0677.json => trainer_psychic_abigail_rematch_1.json} (100%) rename res/trainers/{0678.json => trainer_psychic_abigail_rematch_2.json} (100%) rename res/trainers/{0289.json => trainer_psychic_brittney.json} (100%) rename res/trainers/{0679.json => trainer_psychic_brittney_rematch.json} (100%) rename res/trainers/{0234.json => trainer_psychic_bryce.json} (100%) rename res/trainers/{0586.json => trainer_psychic_chelsey.json} (100%) rename res/trainers/{0583.json => trainer_psychic_corbin.json} (100%) rename res/trainers/{0676.json => trainer_psychic_corbin_rematch.json} (100%) rename res/trainers/{0585.json => trainer_psychic_daisy.json} (100%) rename res/trainers/{0680.json => trainer_psychic_daisy_rematch.json} (100%) rename res/trainers/{0397.json => trainer_psychic_deandre.json} (100%) rename res/trainers/{0399.json => trainer_psychic_desiree.json} (100%) rename res/trainers/{0205.json => trainer_psychic_elijah.json} (100%) rename res/trainers/{0400.json => trainer_psychic_kendra.json} (100%) rename res/trainers/{0395.json => trainer_psychic_kody.json} (100%) rename res/trainers/{0396.json => trainer_psychic_landon.json} (100%) rename res/trainers/{0206.json => trainer_psychic_lindsey.json} (100%) rename res/trainers/{0288.json => trainer_psychic_maxwell.json} (100%) rename res/trainers/{0675.json => trainer_psychic_maxwell_rematch.json} (100%) rename res/trainers/{0119.json => trainer_psychic_mitchell.json} (100%) rename res/trainers/{0673.json => trainer_psychic_mitchell_rematch_1.json} (100%) rename res/trainers/{0674.json => trainer_psychic_mitchell_rematch_2.json} (100%) rename res/trainers/{0398.json => trainer_psychic_rachael.json} (100%) rename res/trainers/{0584.json => trainer_psychic_sterling.json} (100%) rename res/trainers/{0235.json => trainer_psychic_valencia.json} (100%) rename res/trainers/{0292.json => trainer_rancher_marco.json} (100%) rename res/trainers/{0681.json => trainer_rancher_marco_rematch_1.json} (100%) rename res/trainers/{0682.json => trainer_rancher_marco_rematch_2.json} (100%) rename res/trainers/{0096.json => trainer_ranger_allison.json} (100%) rename res/trainers/{0736.json => trainer_ranger_allison_rematch_1.json} (100%) rename res/trainers/{0737.json => trainer_ranger_allison_rematch_2.json} (100%) rename res/trainers/{0738.json => trainer_ranger_allison_rematch_3.json} (100%) rename res/trainers/{0594.json => trainer_ranger_ashlee.json} (100%) rename res/trainers/{0739.json => trainer_ranger_ashlee_rematch.json} (100%) rename res/trainers/{0592.json => trainer_ranger_deshawn.json} (100%) rename res/trainers/{0593.json => trainer_ranger_dwayne.json} (100%) rename res/trainers/{0595.json => trainer_ranger_felicia.json} (100%) rename res/trainers/{0095.json => trainer_ranger_jeffrey.json} (100%) rename res/trainers/{0596.json => trainer_ranger_krista.json} (100%) rename res/trainers/{0591.json => trainer_ranger_kyler.json} (100%) rename res/trainers/{0735.json => trainer_ranger_kyler_rematch.json} (100%) rename res/trainers/{0094.json => trainer_ranger_taylor.json} (100%) rename res/trainers/{0732.json => trainer_ranger_taylor_rematch_1.json} (100%) rename res/trainers/{0733.json => trainer_ranger_taylor_rematch_2.json} (100%) rename res/trainers/{0734.json => trainer_ranger_taylor_rematch_3.json} (100%) rename res/trainers/{0894.json => trainer_reporters_kinsey.json} (100%) rename res/trainers/{0895.json => trainer_reporters_kinsey_rematch_1.json} (100%) rename res/trainers/{0896.json => trainer_reporters_kinsey_rematch_2.json} (100%) rename res/trainers/{0912.json => trainer_reporters_kinsey_rematch_3.json} (100%) rename res/trainers/{0920.json => trainer_reporters_kinsey_rematch_4.json} (100%) rename res/trainers/{0547.json => trainer_reporters_valerie.json} (100%) rename res/trainers/{0082.json => trainer_rich_boy_jason.json} (100%) rename res/trainers/{0892.json => trainer_rich_boy_liam.json} (100%) rename res/trainers/{0545.json => trainer_rich_boy_roman.json} (100%) rename res/trainers/{0335.json => trainer_rich_boy_trey.json} (100%) rename res/trainers/{0727.json => trainer_rich_boy_trey_rematch_1.json} (100%) rename res/trainers/{0728.json => trainer_rich_boy_trey_rematch_2.json} (100%) rename res/trainers/{0478.json => trainer_rival_canalave_city_chimchar.json} (100%) rename res/trainers/{0476.json => trainer_rival_canalave_city_piplup.json} (100%) rename res/trainers/{0477.json => trainer_rival_canalave_city_turtwig.json} (100%) rename res/trainers/{0925.json => trainer_rival_fight_area_chimchar.json} (100%) rename res/trainers/{0923.json => trainer_rival_fight_area_piplup.json} (100%) rename res/trainers/{0924.json => trainer_rival_fight_area_turtwig.json} (100%) rename res/trainers/{0475.json => trainer_rival_pastoria_city_chimchar.json} (100%) rename res/trainers/{0473.json => trainer_rival_pastoria_city_piplup.json} (100%) rename res/trainers/{0474.json => trainer_rival_pastoria_city_turtwig.json} (100%) rename res/trainers/{0481.json => trainer_rival_pokemon_league_chimchar.json} (100%) rename res/trainers/{0479.json => trainer_rival_pokemon_league_piplup.json} (100%) rename res/trainers/{0480.json => trainer_rival_pokemon_league_turtwig.json} (100%) rename res/trainers/{0852.json => trainer_rival_route_201_chimchar.json} (100%) rename res/trainers/{0850.json => trainer_rival_route_201_piplup.json} (100%) rename res/trainers/{0851.json => trainer_rival_route_201_turtwig.json} (100%) rename res/trainers/{0249.json => trainer_rival_route_203_chimchar.json} (100%) rename res/trainers/{0247.json => trainer_rival_route_203_piplup.json} (100%) rename res/trainers/{0248.json => trainer_rival_route_203_turtwig.json} (100%) rename res/trainers/{0472.json => trainer_rival_route_209_chimchar.json} (100%) rename res/trainers/{0470.json => trainer_rival_route_209_piplup.json} (100%) rename res/trainers/{0471.json => trainer_rival_route_209_turtwig.json} (100%) rename res/trainers/{0620.json => trainer_rival_spear_pillar_chimchar.json} (100%) rename res/trainers/{0607.json => trainer_rival_spear_pillar_piplup.json} (100%) rename res/trainers/{0619.json => trainer_rival_spear_pillar_turtwig.json} (100%) rename res/trainers/{0839.json => trainer_rival_survival_area_1_chimchar.json} (100%) rename res/trainers/{0837.json => trainer_rival_survival_area_1_piplup.json} (100%) rename res/trainers/{0838.json => trainer_rival_survival_area_1_turtwig.json} (100%) rename res/trainers/{0873.json => trainer_rival_survival_area_2_chimchar.json} (100%) rename res/trainers/{0871.json => trainer_rival_survival_area_2_piplup.json} (100%) rename res/trainers/{0872.json => trainer_rival_survival_area_2_turtwig.json} (100%) rename res/trainers/{0529.json => trainer_roughneck_kirby.json} (100%) rename res/trainers/{0113.json => trainer_ruin_maniac_bryan.json} (100%) rename res/trainers/{0304.json => trainer_ruin_maniac_calvin.json} (100%) rename res/trainers/{0443.json => trainer_ruin_maniac_gerald.json} (100%) rename res/trainers/{0442.json => trainer_ruin_maniac_harry.json} (100%) rename res/trainers/{0695.json => trainer_ruin_maniac_harry_rematch_1.json} (100%) rename res/trainers/{0696.json => trainer_ruin_maniac_harry_rematch_2.json} (100%) rename res/trainers/{0553.json => trainer_ruin_maniac_karl.json} (100%) rename res/trainers/{0305.json => trainer_ruin_maniac_larry.json} (100%) rename res/trainers/{0114.json => trainer_ruin_maniac_ronald.json} (100%) rename res/trainers/{0339.json => trainer_sailor_damian.json} (100%) rename res/trainers/{0180.json => trainer_sailor_luther.json} (100%) rename res/trainers/{0337.json => trainer_sailor_marc.json} (100%) rename res/trainers/{0740.json => trainer_sailor_marc_rematch_1.json} (100%) rename res/trainers/{0741.json => trainer_sailor_marc_rematch_2.json} (100%) rename res/trainers/{0110.json => trainer_sailor_paul.json} (100%) rename res/trainers/{0483.json => trainer_sailor_samson.json} (100%) rename res/trainers/{0338.json => trainer_sailor_skyler.json} (100%) rename res/trainers/{0482.json => trainer_sailor_zachariah.json} (100%) rename res/trainers/{0742.json => trainer_sailor_zachariah_rematch.json} (100%) rename res/trainers/{0340.json => trainer_school_kid_chance.json} (100%) rename res/trainers/{0345.json => trainer_school_kid_christine.json} (100%) rename res/trainers/{0548.json => trainer_school_kid_esteban.json} (100%) rename res/trainers/{0341.json => trainer_school_kid_forrest.json} (100%) rename res/trainers/{0342.json => trainer_school_kid_harrison.json} (100%) rename res/trainers/{0343.json => trainer_school_kid_mackenzie.json} (100%) rename res/trainers/{0344.json => trainer_school_kid_tiera.json} (100%) rename res/trainers/{0829.json => trainer_scientist_darrius.json} (100%) rename res/trainers/{0549.json => trainer_scientist_emilio.json} (100%) rename res/trainers/{0830.json => trainer_scientist_fredrick.json} (100%) rename res/trainers/{0486.json => trainer_scientist_shaun.json} (100%) rename res/trainers/{0743.json => trainer_scientist_shaun_rematch_1.json} (100%) rename res/trainers/{0744.json => trainer_scientist_shaun_rematch_2.json} (100%) rename res/trainers/{0745.json => trainer_scientist_shaun_rematch_3.json} (100%) rename res/trainers/{0099.json => trainer_scientist_stefano.json} (100%) rename res/trainers/{0831.json => trainer_scientist_travon.json} (100%) rename res/trainers/{0139.json => trainer_skier_andrea.json} (100%) rename res/trainers/{0755.json => trainer_skier_andrea_rematch_1.json} (100%) rename res/trainers/{0756.json => trainer_skier_andrea_rematch_2.json} (100%) rename res/trainers/{0143.json => trainer_skier_bjorn.json} (100%) rename res/trainers/{0753.json => trainer_skier_bjorn_rematch_1.json} (100%) rename res/trainers/{0754.json => trainer_skier_bjorn_rematch_2.json} (100%) rename res/trainers/{0136.json => trainer_skier_bradley.json} (100%) rename res/trainers/{0137.json => trainer_skier_edward.json} (100%) rename res/trainers/{0751.json => trainer_skier_edward_rematch_1.json} (100%) rename res/trainers/{0752.json => trainer_skier_edward_rematch_2.json} (100%) rename res/trainers/{0138.json => trainer_skier_kaitlyn.json} (100%) rename res/trainers/{0144.json => trainer_skier_lexie.json} (100%) rename res/trainers/{0145.json => trainer_skier_madison.json} (100%) rename res/trainers/{0757.json => trainer_skier_madison_rematch_1.json} (100%) rename res/trainers/{0758.json => trainer_skier_madison_rematch_2.json} (100%) rename res/trainers/{0142.json => trainer_skier_shawn.json} (100%) rename res/trainers/{0543.json => trainer_socialite_rebecca.json} (100%) rename res/trainers/{0085.json => trainer_socialite_reina.json} (100%) rename res/trainers/{0701.json => trainer_socialite_reina_rematch_1.json} (100%) rename res/trainers/{0702.json => trainer_socialite_reina_rematch_2.json} (100%) rename res/trainers/{0159.json => trainer_swimmer_adrian.json} (100%) rename res/trainers/{0190.json => trainer_swimmer_aubree.json} (100%) rename res/trainers/{0193.json => trainer_swimmer_cassandra.json} (100%) rename res/trainers/{0494.json => trainer_swimmer_claire.json} (100%) rename res/trainers/{0186.json => trainer_swimmer_colton.json} (100%) rename res/trainers/{0192.json => trainer_swimmer_crystal.json} (100%) rename res/trainers/{0763.json => trainer_swimmer_crystal_rematch.json} (100%) rename res/trainers/{0166.json => trainer_swimmer_dillon.json} (100%) rename res/trainers/{0163.json => trainer_swimmer_erica.json} (100%) rename res/trainers/{0160.json => trainer_swimmer_erik.json} (100%) rename res/trainers/{0104.json => trainer_swimmer_evan.json} (100%) rename res/trainers/{0185.json => trainer_swimmer_francisco.json} (100%) rename res/trainers/{0760.json => trainer_swimmer_francisco_rematch.json} (100%) rename res/trainers/{0194.json => trainer_swimmer_gabrielle.json} (100%) rename res/trainers/{0597.json => trainer_swimmer_glenn.json} (100%) rename res/trainers/{0761.json => trainer_swimmer_glenn_rematch.json} (100%) rename res/trainers/{0105.json => trainer_swimmer_haley.json} (100%) rename res/trainers/{0162.json => trainer_swimmer_jessica.json} (100%) rename res/trainers/{0601.json => trainer_swimmer_joanna.json} (100%) rename res/trainers/{0764.json => trainer_swimmer_joanna_rematch.json} (100%) rename res/trainers/{0164.json => trainer_swimmer_katelyn.json} (100%) rename res/trainers/{0598.json => trainer_swimmer_kurt.json} (100%) rename res/trainers/{0604.json => trainer_swimmer_lydia.json} (100%) rename res/trainers/{0603.json => trainer_swimmer_mallory.json} (100%) rename res/trainers/{0106.json => trainer_swimmer_mary.json} (100%) rename res/trainers/{0189.json => trainer_swimmer_miranda.json} (100%) rename res/trainers/{0762.json => trainer_swimmer_miranda_rematch.json} (100%) rename res/trainers/{0188.json => trainer_swimmer_oscar.json} (100%) rename res/trainers/{0191.json => trainer_swimmer_paige.json} (100%) rename res/trainers/{0184.json => trainer_swimmer_ricardo.json} (100%) rename res/trainers/{0599.json => trainer_swimmer_sam.json} (100%) rename res/trainers/{0103.json => trainer_swimmer_sheltin.json} (100%) rename res/trainers/{0602.json => trainer_swimmer_sophia.json} (100%) rename res/trainers/{0187.json => trainer_swimmer_troy.json} (100%) rename res/trainers/{0167.json => trainer_swimmer_vanessa.json} (100%) rename res/trainers/{0161.json => trainer_swimmer_vincent.json} (100%) rename res/trainers/{0600.json => trainer_swimmer_wade.json} (100%) rename res/trainers/{0183.json => trainer_swimmer_wesley.json} (100%) rename res/trainers/{0759.json => trainer_swimmer_wesley_rematch.json} (100%) rename res/trainers/{0862.json => trainer_trainer_buck_battleground.json} (100%) rename res/trainers/{0611.json => trainer_trainer_buck_buck.json} (100%) rename res/trainers/{0865.json => trainer_trainer_cheryl_battleground.json} (100%) rename res/trainers/{0608.json => trainer_trainer_cheryl_cheryl.json} (100%) rename res/trainers/{0863.json => trainer_trainer_marley_battleground.json} (100%) rename res/trainers/{0610.json => trainer_trainer_marley_marley.json} (100%) rename res/trainers/{0864.json => trainer_trainer_mira_battleground.json} (100%) rename res/trainers/{0612.json => trainer_trainer_mira_mira.json} (100%) rename res/trainers/{0861.json => trainer_trainer_riley_battleground.json} (100%) rename res/trainers/{0609.json => trainer_trainer_riley_riley.json} (100%) rename res/trainers/{0498.json => trainer_tuber_caitlyn.json} (100%) rename res/trainers/{0108.json => trainer_tuber_chelsea.json} (100%) rename res/trainers/{0773.json => trainer_tuber_chelsea_rematch_1.json} (100%) rename res/trainers/{0775.json => trainer_tuber_chelsea_rematch_2.json} (100%) rename res/trainers/{0359.json => trainer_tuber_conner.json} (100%) rename res/trainers/{0361.json => trainer_tuber_holly.json} (100%) rename res/trainers/{0497.json => trainer_tuber_jacky.json} (100%) rename res/trainers/{0107.json => trainer_tuber_jared.json} (100%) rename res/trainers/{0771.json => trainer_tuber_jared_rematch_1.json} (100%) rename res/trainers/{0772.json => trainer_tuber_jared_rematch_2.json} (100%) rename res/trainers/{0360.json => trainer_tuber_mariel.json} (100%) rename res/trainers/{0358.json => trainer_tuber_trenton.json} (100%) rename res/trainers/{0294.json => trainer_twins_emma_and_lil.json} (100%) rename res/trainers/{0015.json => trainer_twins_liv_and_liz.json} (100%) rename res/trainers/{0065.json => trainer_twins_teri_and_tia.json} (100%) rename res/trainers/{0687.json => trainer_twins_teri_and_tia_rematch_1.json} (100%) rename res/trainers/{0688.json => trainer_twins_teri_and_tia_rematch_2.json} (100%) rename res/trainers/{0005.json => trainer_unknown_005.json} (100%) rename res/trainers/{0006.json => trainer_unknown_006.json} (100%) rename res/trainers/{0007.json => trainer_unknown_007.json} (100%) rename res/trainers/{0008.json => trainer_unknown_008.json} (100%) rename res/trainers/{0009.json => trainer_unknown_009.json} (100%) rename res/trainers/{0050.json => trainer_unknown_050.json} (100%) rename res/trainers/{0051.json => trainer_unknown_051.json} (100%) rename res/trainers/{0052.json => trainer_unknown_052.json} (100%) rename res/trainers/{0054.json => trainer_unknown_054.json} (100%) rename res/trainers/{0058.json => trainer_unknown_058.json} (100%) rename res/trainers/{0059.json => trainer_unknown_059.json} (100%) rename res/trainers/{0060.json => trainer_unknown_060.json} (100%) rename res/trainers/{0061.json => trainer_unknown_061.json} (100%) rename res/trainers/{0062.json => trainer_unknown_062.json} (100%) rename res/trainers/{0063.json => trainer_unknown_063.json} (100%) rename res/trainers/{0064.json => trainer_unknown_064.json} (100%) rename res/trainers/{0077.json => trainer_unknown_077.json} (100%) rename res/trainers/{0086.json => trainer_unknown_086.json} (100%) rename res/trainers/{0087.json => trainer_unknown_087.json} (100%) rename res/trainers/{0097.json => trainer_unknown_097.json} (100%) rename res/trainers/{0098.json => trainer_unknown_098.json} (100%) rename res/trainers/{0100.json => trainer_unknown_100.json} (100%) rename res/trainers/{0101.json => trainer_unknown_101.json} (100%) rename res/trainers/{0109.json => trainer_unknown_109.json} (100%) rename res/trainers/{0112.json => trainer_unknown_112.json} (100%) rename res/trainers/{0115.json => trainer_unknown_115.json} (100%) rename res/trainers/{0116.json => trainer_unknown_116.json} (100%) rename res/trainers/{0117.json => trainer_unknown_117.json} (100%) rename res/trainers/{0118.json => trainer_unknown_118.json} (100%) rename res/trainers/{0122.json => trainer_unknown_122.json} (100%) rename res/trainers/{0123.json => trainer_unknown_123.json} (100%) rename res/trainers/{0124.json => trainer_unknown_124.json} (100%) rename res/trainers/{0125.json => trainer_unknown_125.json} (100%) rename res/trainers/{0126.json => trainer_unknown_126.json} (100%) rename res/trainers/{0131.json => trainer_unknown_131.json} (100%) rename res/trainers/{0149.json => trainer_unknown_149.json} (100%) rename res/trainers/{0150.json => trainer_unknown_150.json} (100%) rename res/trainers/{0151.json => trainer_unknown_151.json} (100%) rename res/trainers/{0152.json => trainer_unknown_152.json} (100%) rename res/trainers/{0155.json => trainer_unknown_155.json} (100%) rename res/trainers/{0156.json => trainer_unknown_156.json} (100%) rename res/trainers/{0157.json => trainer_unknown_157.json} (100%) rename res/trainers/{0158.json => trainer_unknown_158.json} (100%) rename res/trainers/{0165.json => trainer_unknown_165.json} (100%) rename res/trainers/{0169.json => trainer_unknown_169.json} (100%) rename res/trainers/{0176.json => trainer_unknown_176.json} (100%) rename res/trainers/{0177.json => trainer_unknown_177.json} (100%) rename res/trainers/{0178.json => trainer_unknown_178.json} (100%) rename res/trainers/{0179.json => trainer_unknown_179.json} (100%) rename res/trainers/{0181.json => trainer_unknown_181.json} (100%) rename res/trainers/{0182.json => trainer_unknown_182.json} (100%) rename res/trainers/{0197.json => trainer_unknown_197.json} (100%) rename res/trainers/{0198.json => trainer_unknown_198.json} (100%) rename res/trainers/{0199.json => trainer_unknown_199.json} (100%) rename res/trainers/{0200.json => trainer_unknown_200.json} (100%) rename res/trainers/{0207.json => trainer_unknown_207.json} (100%) rename res/trainers/{0208.json => trainer_unknown_208.json} (100%) rename res/trainers/{0209.json => trainer_unknown_209.json} (100%) rename res/trainers/{0210.json => trainer_unknown_210.json} (100%) rename res/trainers/{0211.json => trainer_unknown_211.json} (100%) rename res/trainers/{0212.json => trainer_unknown_212.json} (100%) rename res/trainers/{0213.json => trainer_unknown_213.json} (100%) rename res/trainers/{0214.json => trainer_unknown_214.json} (100%) rename res/trainers/{0215.json => trainer_unknown_215.json} (100%) rename res/trainers/{0216.json => trainer_unknown_216.json} (100%) rename res/trainers/{0217.json => trainer_unknown_217.json} (100%) rename res/trainers/{0218.json => trainer_unknown_218.json} (100%) rename res/trainers/{0219.json => trainer_unknown_219.json} (100%) rename res/trainers/{0220.json => trainer_unknown_220.json} (100%) rename res/trainers/{0221.json => trainer_unknown_221.json} (100%) rename res/trainers/{0222.json => trainer_unknown_222.json} (100%) rename res/trainers/{0223.json => trainer_unknown_223.json} (100%) rename res/trainers/{0238.json => trainer_unknown_238.json} (100%) rename res/trainers/{0239.json => trainer_unknown_239.json} (100%) rename res/trainers/{0241.json => trainer_unknown_241.json} (100%) rename res/trainers/{0242.json => trainer_unknown_242.json} (100%) rename res/trainers/{0243.json => trainer_unknown_243.json} (100%) rename res/trainers/{0251.json => trainer_unknown_251.json} (100%) rename res/trainers/{0252.json => trainer_unknown_252.json} (100%) rename res/trainers/{0253.json => trainer_unknown_253.json} (100%) rename res/trainers/{0254.json => trainer_unknown_254.json} (100%) rename res/trainers/{0255.json => trainer_unknown_255.json} (100%) rename res/trainers/{0291.json => trainer_unknown_291.json} (100%) rename res/trainers/{0321.json => trainer_unknown_321.json} (100%) rename res/trainers/{0334.json => trainer_unknown_334.json} (100%) rename res/trainers/{0336.json => trainer_unknown_336.json} (100%) rename res/trainers/{0347.json => trainer_unknown_347.json} (100%) rename res/trainers/{0349.json => trainer_unknown_349.json} (100%) rename res/trainers/{0350.json => trainer_unknown_350.json} (100%) rename res/trainers/{0351.json => trainer_unknown_351.json} (100%) rename res/trainers/{0352.json => trainer_unknown_352.json} (100%) rename res/trainers/{0353.json => trainer_unknown_353.json} (100%) rename res/trainers/{0354.json => trainer_unknown_354.json} (100%) rename res/trainers/{0363.json => trainer_unknown_363.json} (100%) rename res/trainers/{0364.json => trainer_unknown_364.json} (100%) rename res/trainers/{0365.json => trainer_unknown_365.json} (100%) rename res/trainers/{0368.json => trainer_unknown_368.json} (100%) rename res/trainers/{0369.json => trainer_unknown_369.json} (100%) rename res/trainers/{0370.json => trainer_unknown_370.json} (100%) rename res/trainers/{0371.json => trainer_unknown_371.json} (100%) rename res/trainers/{0374.json => trainer_unknown_374.json} (100%) rename res/trainers/{0375.json => trainer_unknown_375.json} (100%) rename res/trainers/{0376.json => trainer_unknown_376.json} (100%) rename res/trainers/{0384.json => trainer_unknown_384.json} (100%) rename res/trainers/{0385.json => trainer_unknown_385.json} (100%) rename res/trainers/{0387.json => trainer_unknown_387.json} (100%) rename res/trainers/{0391.json => trainer_unknown_391.json} (100%) rename res/trainers/{0402.json => trainer_unknown_402.json} (100%) rename res/trainers/{0411.json => trainer_unknown_411.json} (100%) rename res/trainers/{0413.json => trainer_unknown_413.json} (100%) rename res/trainers/{0424.json => trainer_unknown_424.json} (100%) rename res/trainers/{0429.json => trainer_unknown_429.json} (100%) rename res/trainers/{0431.json => trainer_unknown_431.json} (100%) rename res/trainers/{0432.json => trainer_unknown_432.json} (100%) rename res/trainers/{0433.json => trainer_unknown_433.json} (100%) rename res/trainers/{0434.json => trainer_unknown_434.json} (100%) rename res/trainers/{0435.json => trainer_unknown_435.json} (100%) rename res/trainers/{0436.json => trainer_unknown_436.json} (100%) rename res/trainers/{0437.json => trainer_unknown_437.json} (100%) rename res/trainers/{0438.json => trainer_unknown_438.json} (100%) rename res/trainers/{0439.json => trainer_unknown_439.json} (100%) rename res/trainers/{0440.json => trainer_unknown_440.json} (100%) rename res/trainers/{0441.json => trainer_unknown_441.json} (100%) rename res/trainers/{0448.json => trainer_unknown_448.json} (100%) rename res/trainers/{0449.json => trainer_unknown_449.json} (100%) rename res/trainers/{0460.json => trainer_unknown_460.json} (100%) rename res/trainers/{0461.json => trainer_unknown_461.json} (100%) rename res/trainers/{0462.json => trainer_unknown_462.json} (100%) rename res/trainers/{0463.json => trainer_unknown_463.json} (100%) rename res/trainers/{0464.json => trainer_unknown_464.json} (100%) rename res/trainers/{0465.json => trainer_unknown_465.json} (100%) rename res/trainers/{0466.json => trainer_unknown_466.json} (100%) rename res/trainers/{0467.json => trainer_unknown_467.json} (100%) rename res/trainers/{0468.json => trainer_unknown_468.json} (100%) rename res/trainers/{0469.json => trainer_unknown_469.json} (100%) rename res/trainers/{0484.json => trainer_unknown_484.json} (100%) rename res/trainers/{0485.json => trainer_unknown_485.json} (100%) rename res/trainers/{0487.json => trainer_unknown_487.json} (100%) rename res/trainers/{0493.json => trainer_unknown_493.json} (100%) rename res/trainers/{0495.json => trainer_unknown_495.json} (100%) rename res/trainers/{0501.json => trainer_unknown_501.json} (100%) rename res/trainers/{0502.json => trainer_unknown_502.json} (100%) rename res/trainers/{0511.json => trainer_unknown_511.json} (100%) rename res/trainers/{0605.json => trainer_unknown_605.json} (100%) rename res/trainers/{0651.json => trainer_unknown_651.json} (100%) rename res/trainers/{0652.json => trainer_unknown_652.json} (100%) rename res/trainers/{0778.json => trainer_unknown_778.json} (100%) rename res/trainers/{0779.json => trainer_unknown_779.json} (100%) rename res/trainers/{0780.json => trainer_unknown_780.json} (100%) rename res/trainers/{0781.json => trainer_unknown_781.json} (100%) rename res/trainers/{0782.json => trainer_unknown_782.json} (100%) rename res/trainers/{0783.json => trainer_unknown_783.json} (100%) rename res/trainers/{0784.json => trainer_unknown_784.json} (100%) rename res/trainers/{0785.json => trainer_unknown_785.json} (100%) rename res/trainers/{0786.json => trainer_unknown_786.json} (100%) rename res/trainers/{0787.json => trainer_unknown_787.json} (100%) rename res/trainers/{0788.json => trainer_unknown_788.json} (100%) rename res/trainers/{0789.json => trainer_unknown_789.json} (100%) rename res/trainers/{0790.json => trainer_unknown_790.json} (100%) rename res/trainers/{0791.json => trainer_unknown_791.json} (100%) rename res/trainers/{0792.json => trainer_unknown_792.json} (100%) rename res/trainers/{0793.json => trainer_unknown_793.json} (100%) rename res/trainers/{0794.json => trainer_unknown_794.json} (100%) rename res/trainers/{0795.json => trainer_unknown_795.json} (100%) rename res/trainers/{0796.json => trainer_unknown_796.json} (100%) rename res/trainers/{0797.json => trainer_unknown_797.json} (100%) rename res/trainers/{0798.json => trainer_unknown_798.json} (100%) rename res/trainers/{0799.json => trainer_unknown_799.json} (100%) rename res/trainers/{0800.json => trainer_unknown_800.json} (100%) rename res/trainers/{0801.json => trainer_unknown_801.json} (100%) rename res/trainers/{0802.json => trainer_unknown_802.json} (100%) rename res/trainers/{0803.json => trainer_unknown_803.json} (100%) rename res/trainers/{0804.json => trainer_unknown_804.json} (100%) rename res/trainers/{0805.json => trainer_unknown_805.json} (100%) rename res/trainers/{0806.json => trainer_unknown_806.json} (100%) rename res/trainers/{0807.json => trainer_unknown_807.json} (100%) rename res/trainers/{0808.json => trainer_unknown_808.json} (100%) rename res/trainers/{0809.json => trainer_unknown_809.json} (100%) rename res/trainers/{0810.json => trainer_unknown_810.json} (100%) rename res/trainers/{0811.json => trainer_unknown_811.json} (100%) rename res/trainers/{0812.json => trainer_unknown_812.json} (100%) rename res/trainers/{0813.json => trainer_unknown_813.json} (100%) rename res/trainers/{0814.json => trainer_unknown_814.json} (100%) rename res/trainers/{0815.json => trainer_unknown_815.json} (100%) rename res/trainers/{0816.json => trainer_unknown_816.json} (100%) rename res/trainers/{0817.json => trainer_unknown_817.json} (100%) rename res/trainers/{0818.json => trainer_unknown_818.json} (100%) rename res/trainers/{0819.json => trainer_unknown_819.json} (100%) rename res/trainers/{0820.json => trainer_unknown_820.json} (100%) rename res/trainers/{0821.json => trainer_unknown_821.json} (100%) rename res/trainers/{0822.json => trainer_unknown_822.json} (100%) rename res/trainers/{0823.json => trainer_unknown_823.json} (100%) rename res/trainers/{0824.json => trainer_unknown_824.json} (100%) rename res/trainers/{0825.json => trainer_unknown_825.json} (100%) rename res/trainers/{0826.json => trainer_unknown_828.json} (100%) rename res/trainers/{0833.json => trainer_unknown_833.json} (100%) rename res/trainers/{0834.json => trainer_unknown_834.json} (100%) rename res/trainers/{0840.json => trainer_unknown_840.json} (100%) rename res/trainers/{0841.json => trainer_unknown_841.json} (100%) rename res/trainers/{0842.json => trainer_unknown_842.json} (100%) rename res/trainers/{0902.json => trainer_unknown_902.json} (100%) rename res/trainers/{0903.json => trainer_unknown_903.json} (100%) rename res/trainers/{0904.json => trainer_unknown_904.json} (100%) rename res/trainers/{0905.json => trainer_unknown_905.json} (100%) rename res/trainers/{0362.json => trainer_veteran_armando.json} (100%) rename res/trainers/{0777.json => trainer_veteran_armando_rematch.json} (100%) rename res/trainers/{0500.json => trainer_veteran_brenden.json} (100%) rename res/trainers/{0068.json => trainer_veteran_brian.json} (100%) rename res/trainers/{0774.json => trainer_veteran_brian_rematch_1.json} (100%) rename res/trainers/{0776.json => trainer_veteran_brian_rematch_2.json} (100%) rename res/trainers/{0229.json => trainer_veteran_clayton.json} (100%) rename res/trainers/{0228.json => trainer_veteran_edgar.json} (100%) rename res/trainers/{0552.json => trainer_veteran_emanuel.json} (100%) rename res/trainers/{0240.json => trainer_veteran_grant.json} (100%) rename res/trainers/{0606.json => trainer_veteran_harlan.json} (100%) rename res/trainers/{0499.json => trainer_veteran_terrell.json} (100%) rename res/trainers/{0366.json => trainer_waitress_kati.json} (100%) rename res/trainers/{0504.json => trainer_worker_braden.json} (100%) rename res/trainers/{0505.json => trainer_worker_brendon.json} (100%) rename res/trainers/{0195.json => trainer_worker_colin.json} (100%) rename res/trainers/{0846.json => trainer_worker_conrad.json} (100%) rename res/trainers/{0844.json => trainer_worker_dillan.json} (100%) rename res/trainers/{0257.json => trainer_worker_gary.json} (100%) rename res/trainers/{0367.json => trainer_worker_gerardo.json} (100%) rename res/trainers/{0845.json => trainer_worker_holden.json} (100%) rename res/trainers/{0256.json => trainer_worker_jackson.json} (100%) rename res/trainers/{0196.json => trainer_worker_mason.json} (100%) rename res/trainers/{0503.json => trainer_worker_noel.json} (100%) rename res/trainers/{0506.json => trainer_worker_quentin.json} (100%) rename res/trainers/{0534.json => trainer_young_couple_mike_and_nat.json} (100%) rename res/trainers/{0055.json => trainer_young_couple_ty_and_sue.json} (100%) rename res/trainers/{0033.json => trainer_youngster_austin.json} (100%) rename res/trainers/{0355.json => trainer_youngster_dallas.json} (100%) rename res/trainers/{0768.json => trainer_youngster_dallas_rematch_1.json} (100%) rename res/trainers/{0769.json => trainer_youngster_dallas_rematch_2.json} (100%) rename res/trainers/{0770.json => trainer_youngster_dallas_rematch_3.json} (100%) rename res/trainers/{0245.json => trainer_youngster_darius.json} (100%) rename res/trainers/{0357.json => trainer_youngster_donny.json} (100%) rename res/trainers/{0244.json => trainer_youngster_jonathon.json} (100%) rename res/trainers/{0002.json => trainer_youngster_logan.json} (100%) rename res/trainers/{0004.json => trainer_youngster_michael.json} (100%) rename res/trainers/{0532.json => trainer_youngster_oliver.json} (100%) rename res/trainers/{0356.json => trainer_youngster_sebastian.json} (100%) rename res/trainers/{0001.json => trainer_youngster_tristan.json} (100%) rename res/trainers/{0765.json => trainer_youngster_tristan_rematch_1.json} (100%) rename res/trainers/{0766.json => trainer_youngster_tristan_rematch_2.json} (100%) rename res/trainers/{0767.json => trainer_youngster_tristan_rematch_3.json} (100%) rename res/trainers/{0010.json => trainer_youngster_tyler.json} (100%) rename res/trainers/{0496.json => trainer_youngster_wayne.json} (100%) create mode 100644 res/trainers/trainers.order diff --git a/res/trainers/meson.build b/res/trainers/meson.build index 3445bf0250..391af2b461 100644 --- a/res/trainers/meson.build +++ b/res/trainers/meson.build @@ -1,43 +1,981 @@ -trainer_data_files = [] - -foreach i : range(928) - i_fname = run_command('printf', '%04d.json', i.to_string(), check: true).stdout() - trainer_data_files += i_fname -endforeach +trainer_data_files = [ + 'trainer_none.json', + 'trainer_youngster_tristan.json', + 'trainer_youngster_logan.json', + 'trainer_lass_natalie.json', + 'trainer_youngster_michael.json', + 'trainer_unknown_005.json', + 'trainer_unknown_006.json', + 'trainer_unknown_007.json', + 'trainer_unknown_008.json', + 'trainer_unknown_009.json', + 'trainer_youngster_tyler.json', + 'trainer_lass_samantha.json', + 'trainer_lass_sarah.json', + 'trainer_bug_catcher_brandon.json', + 'trainer_aroma_lady_taylor.json', + 'trainer_twins_liv_and_liz.json', + 'trainer_camper_jacob.json', + 'trainer_picnicker_siena.json', + 'trainer_hiker_daniel.json', + 'trainer_hiker_nicholas.json', + 'trainer_battle_girl_kelsey.json', + 'trainer_aroma_lady_elizabeth.json', + 'trainer_fisherman_andrew.json', + 'trainer_fisherman_joseph.json', + 'trainer_fisherman_zachary.json', + 'trainer_cyclist_axel.json', + 'trainer_cyclist_james.json', + 'trainer_cyclist_john.json', + 'trainer_cyclist_ryan.json', + 'trainer_cyclist_megan.json', + 'trainer_cyclist_nicole.json', + 'trainer_cyclist_kayla.json', + 'trainer_cyclist_rachel.json', + 'trainer_youngster_austin.json', + 'trainer_camper_anthony.json', + 'trainer_picnicker_lauren.json', + 'trainer_hiker_kevin.json', + 'trainer_hiker_justin.json', + 'trainer_battle_girl_helen.json', + 'trainer_hiker_robert.json', + 'trainer_hiker_alexander.json', + 'trainer_hiker_jonathan.json', + 'trainer_black_belt_kyle.json', + 'trainer_fisherman_cody.json', + 'trainer_aroma_lady_hannah.json', + 'trainer_artist_william.json', + 'trainer_breeder_albert.json', + 'trainer_breeder_jennifer.json', + 'trainer_cowgirl_shelley.json', + 'trainer_jogger_richard.json', + 'trainer_unknown_050.json', + 'trainer_unknown_051.json', + 'trainer_unknown_052.json', + 'trainer_poke_kid_danielle.json', + 'trainer_unknown_054.json', + 'trainer_young_couple_ty_and_sue.json', + 'trainer_breeder_kahlil.json', + 'trainer_breeder_amber.json', + 'trainer_unknown_058.json', + 'trainer_unknown_059.json', + 'trainer_unknown_060.json', + 'trainer_unknown_061.json', + 'trainer_unknown_062.json', + 'trainer_unknown_063.json', + 'trainer_unknown_064.json', + 'trainer_twins_teri_and_tia.json', + 'trainer_ace_trainer_ernest.json', + 'trainer_ace_trainer_alyssa.json', + 'trainer_veteran_brian.json', + 'trainer_black_belt_adam.json', + 'trainer_ninja_boy_joel.json', + 'trainer_ninja_boy_nathan.json', + 'trainer_ninja_boy_davido.json', + 'trainer_dragon_tamer_patrick.json', + 'trainer_bird_keeper_brianna.json', + 'trainer_double_team_zac_and_jen.json', + 'trainer_bird_keeper_alexandra.json', + 'trainer_unknown_077.json', + 'trainer_ninja_boy_zach.json', + 'trainer_black_belt_sean.json', + 'trainer_ninja_boy_nick.json', + 'trainer_bird_keeper_katherine.json', + 'trainer_rich_boy_jason.json', + 'trainer_lady_melissa.json', + 'trainer_gentleman_jeremy.json', + 'trainer_socialite_reina.json', + 'trainer_unknown_086.json', + 'trainer_unknown_087.json', + 'trainer_policeman_bobby.json', + 'trainer_policeman_alex.json', + 'trainer_policeman_dylan.json', + 'trainer_fisherman_juan.json', + 'trainer_fisherman_josh.json', + 'trainer_fisherman_travis.json', + 'trainer_ranger_taylor.json', + 'trainer_ranger_jeffrey.json', + 'trainer_ranger_allison.json', + 'trainer_unknown_097.json', + 'trainer_unknown_098.json', + 'trainer_scientist_stefano.json', + 'trainer_unknown_100.json', + 'trainer_unknown_101.json', + 'trainer_policeman_caleb.json', + 'trainer_swimmer_sheltin.json', + 'trainer_swimmer_evan.json', + 'trainer_swimmer_haley.json', + 'trainer_swimmer_mary.json', + 'trainer_tuber_jared.json', + 'trainer_tuber_chelsea.json', + 'trainer_unknown_109.json', + 'trainer_sailor_paul.json', + 'trainer_fisherman_kenneth.json', + 'trainer_unknown_112.json', + 'trainer_ruin_maniac_bryan.json', + 'trainer_ruin_maniac_ronald.json', + 'trainer_unknown_115.json', + 'trainer_unknown_116.json', + 'trainer_unknown_117.json', + 'trainer_unknown_118.json', + 'trainer_psychic_mitchell.json', + 'trainer_psychic_abigail.json', + 'trainer_pi_carlos.json', + 'trainer_unknown_122.json', + 'trainer_unknown_123.json', + 'trainer_unknown_124.json', + 'trainer_unknown_125.json', + 'trainer_unknown_126.json', + 'trainer_black_belt_gregory.json', + 'trainer_black_belt_derek.json', + 'trainer_black_belt_nathaniel.json', + 'trainer_jogger_scott.json', + 'trainer_unknown_131.json', + 'trainer_ace_trainer_blake.json', + 'trainer_ace_trainer_garrett.json', + 'trainer_ace_trainer_laura.json', + 'trainer_ace_trainer_maria.json', + 'trainer_skier_bradley.json', + 'trainer_skier_edward.json', + 'trainer_skier_kaitlyn.json', + 'trainer_skier_andrea.json', + 'trainer_ace_trainer_dalton.json', + 'trainer_ace_trainer_olivia.json', + 'trainer_skier_shawn.json', + 'trainer_skier_bjorn.json', + 'trainer_skier_lexie.json', + 'trainer_skier_madison.json', + 'trainer_ninja_boy_matthew.json', + 'trainer_ninja_boy_ethan.json', + 'trainer_black_belt_luke.json', + 'trainer_unknown_149.json', + 'trainer_unknown_150.json', + 'trainer_unknown_151.json', + 'trainer_unknown_152.json', + 'trainer_fisherman_miguel.json', + 'trainer_fisherman_luc.json', + 'trainer_unknown_155.json', + 'trainer_unknown_156.json', + 'trainer_unknown_157.json', + 'trainer_unknown_158.json', + 'trainer_swimmer_adrian.json', + 'trainer_swimmer_erik.json', + 'trainer_swimmer_vincent.json', + 'trainer_swimmer_jessica.json', + 'trainer_swimmer_erica.json', + 'trainer_swimmer_katelyn.json', + 'trainer_unknown_165.json', + 'trainer_swimmer_dillon.json', + 'trainer_swimmer_vanessa.json', + 'trainer_fisherman_cory.json', + 'trainer_unknown_169.json', + 'trainer_ace_trainer_jake.json', + 'trainer_ace_trainer_shannon.json', + 'trainer_fisherman_brett.json', + 'trainer_fisherman_alec.json', + 'trainer_fisherman_george.json', + 'trainer_fisherman_cole.json', + 'trainer_unknown_176.json', + 'trainer_unknown_177.json', + 'trainer_unknown_178.json', + 'trainer_unknown_179.json', + 'trainer_sailor_luther.json', + 'trainer_unknown_181.json', + 'trainer_unknown_182.json', + 'trainer_swimmer_wesley.json', + 'trainer_swimmer_ricardo.json', + 'trainer_swimmer_francisco.json', + 'trainer_swimmer_colton.json', + 'trainer_swimmer_troy.json', + 'trainer_swimmer_oscar.json', + 'trainer_swimmer_miranda.json', + 'trainer_swimmer_aubree.json', + 'trainer_swimmer_paige.json', + 'trainer_swimmer_crystal.json', + 'trainer_swimmer_cassandra.json', + 'trainer_swimmer_gabrielle.json', + 'trainer_worker_colin.json', + 'trainer_worker_mason.json', + 'trainer_unknown_197.json', + 'trainer_unknown_198.json', + 'trainer_unknown_199.json', + 'trainer_unknown_200.json', + 'trainer_bug_catcher_jack.json', + 'trainer_bug_catcher_phillip.json', + 'trainer_bug_catcher_donald.json', + 'trainer_lass_briana.json', + 'trainer_psychic_elijah.json', + 'trainer_psychic_lindsey.json', + 'trainer_unknown_207.json', + 'trainer_unknown_208.json', + 'trainer_unknown_209.json', + 'trainer_unknown_210.json', + 'trainer_unknown_211.json', + 'trainer_unknown_212.json', + 'trainer_unknown_213.json', + 'trainer_unknown_214.json', + 'trainer_unknown_215.json', + 'trainer_unknown_216.json', + 'trainer_unknown_217.json', + 'trainer_unknown_218.json', + 'trainer_unknown_219.json', + 'trainer_unknown_220.json', + 'trainer_unknown_221.json', + 'trainer_unknown_222.json', + 'trainer_unknown_223.json', + 'trainer_ace_trainer_omar.json', + 'trainer_ace_trainer_henry.json', + 'trainer_ace_trainer_mariah.json', + 'trainer_ace_trainer_sydney.json', + 'trainer_veteran_edgar.json', + 'trainer_veteran_clayton.json', + 'trainer_dragon_tamer_ondrej.json', + 'trainer_dragon_tamer_clinton.json', + 'trainer_black_belt_david.json', + 'trainer_bird_keeper_hana.json', + 'trainer_psychic_bryce.json', + 'trainer_psychic_valencia.json', + 'trainer_double_team_jo_and_pat.json', + 'trainer_double_team_al_and_kay.json', + 'trainer_unknown_238.json', + 'trainer_unknown_239.json', + 'trainer_veteran_grant.json', + 'trainer_unknown_241.json', + 'trainer_unknown_242.json', + 'trainer_unknown_243.json', + 'trainer_youngster_jonathon.json', + 'trainer_youngster_darius.json', + 'trainer_leader_roark.json', + 'trainer_rival_route_203_piplup.json', + 'trainer_rival_route_203_turtwig.json', + 'trainer_rival_route_203_chimchar.json', + 'trainer_leader_byron.json', + 'trainer_unknown_251.json', + 'trainer_unknown_252.json', + 'trainer_unknown_253.json', + 'trainer_unknown_254.json', + 'trainer_unknown_255.json', + 'trainer_worker_jackson.json', + 'trainer_worker_gary.json', + 'trainer_black_belt_philip.json', + 'trainer_aroma_lady_jenna.json', + 'trainer_aroma_lady_angela.json', + 'trainer_elite_four_aaron.json', + 'trainer_elite_four_bertha.json', + 'trainer_elite_four_flint.json', + 'trainer_elite_four_lucian.json', + 'trainer_camper_curtis.json', + 'trainer_camper_drew.json', + 'trainer_champion_cynthia.json', + 'trainer_ace_trainer_sergio.json', + 'trainer_ace_trainer_isaiah.json', + 'trainer_ace_trainer_savannah.json', + 'trainer_ace_trainer_alicia.json', + 'trainer_collector_douglas.json', + 'trainer_collector_brady.json', + 'trainer_collector_ivan.json', + 'trainer_collector_fernando.json', + 'trainer_collector_edwin.json', + 'trainer_dragon_tamer_hayden.json', + 'trainer_ace_trainer_dennis.json', + 'trainer_ace_trainer_cesar.json', + 'trainer_ace_trainer_allen.json', + 'trainer_ace_trainer_zachery.json', + 'trainer_ace_trainer_ruben.json', + 'trainer_ace_trainer_breanna.json', + 'trainer_ace_trainer_catherine.json', + 'trainer_ace_trainer_destiny.json', + 'trainer_ace_trainer_jamie.json', + 'trainer_ace_trainer_maya.json', + 'trainer_psychic_maxwell.json', + 'trainer_psychic_brittney.json', + 'trainer_belle_and_pa_ava_and_matt.json', + 'trainer_unknown_291.json', + 'trainer_rancher_marco.json', + 'trainer_fisherman_erick.json', + 'trainer_twins_emma_and_lil.json', + 'trainer_commander_mars_valley_windworks.json', + 'trainer_galactic_grunt_floaroma_meadow_1.json', + 'trainer_galactic_grunt_floaroma_meadow_2.json', + 'trainer_galactic_grunt_valley_windworks_2.json', + 'trainer_galactic_grunt_valley_windworks_3.json', + 'trainer_guitarist_tony.json', + 'trainer_guitarist_jerry.json', + 'trainer_guitarist_preston.json', + 'trainer_guitarist_lonnie.json', + 'trainer_ruin_maniac_calvin.json', + 'trainer_ruin_maniac_larry.json', + 'trainer_jogger_wyatt.json', + 'trainer_jogger_craig.json', + 'trainer_jogger_raul.json', + 'trainer_black_belt_colby.json', + 'trainer_black_belt_darren.json', + 'trainer_black_belt_rafael.json', + 'trainer_black_belt_jeffery.json', + 'trainer_black_belt_carl.json', + 'trainer_black_belt_ricky.json', + 'trainer_leader_gardenia.json', + 'trainer_leader_wake.json', + 'trainer_leader_maylene.json', + 'trainer_leader_fantina.json', + 'trainer_leader_candice.json', + 'trainer_leader_volkner.json', + 'trainer_unknown_321.json', + 'trainer_lass_madeline.json', + 'trainer_lass_kaitlin.json', + 'trainer_lass_caroline.json', + 'trainer_lass_molly.json', + 'trainer_hiker_louis.json', + 'trainer_parasol_lady_alexa.json', + 'trainer_parasol_lady_sabrina.json', + 'trainer_picnicker_diana.json', + 'trainer_picnicker_cheyenne.json', + 'trainer_poke_kid_meghan.json', + 'trainer_policeman_danny.json', + 'trainer_policeman_thomas.json', + 'trainer_unknown_334.json', + 'trainer_rich_boy_trey.json', + 'trainer_unknown_336.json', + 'trainer_sailor_marc.json', + 'trainer_sailor_skyler.json', + 'trainer_sailor_damian.json', + 'trainer_school_kid_chance.json', + 'trainer_school_kid_forrest.json', + 'trainer_school_kid_harrison.json', + 'trainer_school_kid_mackenzie.json', + 'trainer_school_kid_tiera.json', + 'trainer_school_kid_christine.json', + 'trainer_beauty_cyndy.json', + 'trainer_unknown_347.json', + 'trainer_beauty_lindsay.json', + 'trainer_unknown_349.json', + 'trainer_unknown_350.json', + 'trainer_unknown_351.json', + 'trainer_unknown_352.json', + 'trainer_unknown_353.json', + 'trainer_unknown_354.json', + 'trainer_youngster_dallas.json', + 'trainer_youngster_sebastian.json', + 'trainer_youngster_donny.json', + 'trainer_tuber_trenton.json', + 'trainer_tuber_conner.json', + 'trainer_tuber_mariel.json', + 'trainer_tuber_holly.json', + 'trainer_veteran_armando.json', + 'trainer_unknown_363.json', + 'trainer_unknown_364.json', + 'trainer_unknown_365.json', + 'trainer_waitress_kati.json', + 'trainer_worker_gerardo.json', + 'trainer_unknown_368.json', + 'trainer_unknown_369.json', + 'trainer_unknown_370.json', + 'trainer_unknown_371.json', + 'trainer_battle_girl_tyler.json', + 'trainer_bird_keeper_autumn.json', + 'trainer_unknown_374.json', + 'trainer_unknown_375.json', + 'trainer_unknown_376.json', + 'trainer_camper_zackary.json', + 'trainer_camper_lawrence.json', + 'trainer_camper_diego.json', + 'trainer_camper_parker.json', + 'trainer_collector_dean.json', + 'trainer_collector_jamal.json', + 'trainer_collector_terry.json', + 'trainer_unknown_384.json', + 'trainer_unknown_385.json', + 'trainer_dragon_tamer_joe.json', + 'trainer_unknown_387.json', + 'trainer_ace_trainer_jonah.json', + 'trainer_ace_trainer_micah.json', + 'trainer_ace_trainer_arthur.json', + 'trainer_unknown_391.json', + 'trainer_ace_trainer_brenda.json', + 'trainer_ace_trainer_brandi.json', + 'trainer_ace_trainer_clarice.json', + 'trainer_psychic_kody.json', + 'trainer_psychic_landon.json', + 'trainer_psychic_deandre.json', + 'trainer_psychic_rachael.json', + 'trainer_psychic_desiree.json', + 'trainer_psychic_kendra.json', + 'trainer_fisherman_walter.json', + 'trainer_unknown_402.json', + 'trainer_galactic_boss_cyrus_galactic_hq.json', + 'trainer_galactic_boss_cyrus_distortion_world.json', + 'trainer_commander_mars_lake_verity.json', + 'trainer_commander_jupiter_team_galactic_eterna_building.json', + 'trainer_commander_jupiter_spear_pillar.json', + 'trainer_commander_saturn_valor_cavern.json', + 'trainer_commander_saturn_galactic_hq.json', + 'trainer_galactic_grunt_team_galactic_eterna_building_1f_1.json', + 'trainer_unknown_411.json', + 'trainer_galactic_grunt_team_galactic_eterna_building_2f_1.json', + 'trainer_unknown_413.json', + 'trainer_galactic_grunt_jubilife_city_1.json', + 'trainer_galactic_grunt_jubilife_city_2.json', + 'trainer_galactic_grunt_celestic_town.json', + 'trainer_galactic_grunt_lake_valor_1.json', + 'trainer_galactic_grunt_lake_valor_2.json', + 'trainer_galactic_grunt_lake_verity_1.json', + 'trainer_galactic_grunt_lake_verity_3.json', + 'trainer_galactic_grunt_team_galactic_eterna_building_1f_2.json', + 'trainer_galactic_grunt_team_galactic_eterna_building_2f_2.json', + 'trainer_galactic_grunt_team_galactic_eterna_building_3f.json', + 'trainer_unknown_424.json', + 'trainer_galactic_grunt_lake_valor_3.json', + 'trainer_galactic_grunt_lake_verity_2.json', + 'trainer_galactic_grunt_lake_verity_4.json', + 'trainer_galactic_grunt_galactic_hq_1f.json', + 'trainer_unknown_429.json', + 'trainer_galactic_grunt_galactic_hq_2f_3.json', + 'trainer_unknown_431.json', + 'trainer_unknown_432.json', + 'trainer_unknown_433.json', + 'trainer_unknown_434.json', + 'trainer_unknown_435.json', + 'trainer_unknown_436.json', + 'trainer_unknown_437.json', + 'trainer_unknown_438.json', + 'trainer_unknown_439.json', + 'trainer_unknown_440.json', + 'trainer_unknown_441.json', + 'trainer_ruin_maniac_harry.json', + 'trainer_ruin_maniac_gerald.json', + 'trainer_black_belt_miles.json', + 'trainer_black_belt_kendal.json', + 'trainer_black_belt_eddie.json', + 'trainer_black_belt_willie.json', + 'trainer_unknown_448.json', + 'trainer_unknown_449.json', + 'trainer_lass_cassidy.json', + 'trainer_hiker_theodore.json', + 'trainer_hiker_damon.json', + 'trainer_hiker_maurice.json', + 'trainer_hiker_reginald.json', + 'trainer_hiker_lorenzo.json', + 'trainer_picnicker_karina.json', + 'trainer_picnicker_summer.json', + 'trainer_picnicker_tori.json', + 'trainer_picnicker_ana.json', + 'trainer_unknown_460.json', + 'trainer_unknown_461.json', + 'trainer_unknown_462.json', + 'trainer_unknown_463.json', + 'trainer_unknown_464.json', + 'trainer_unknown_465.json', + 'trainer_unknown_466.json', + 'trainer_unknown_467.json', + 'trainer_unknown_468.json', + 'trainer_unknown_469.json', + 'trainer_rival_route_209_piplup.json', + 'trainer_rival_route_209_turtwig.json', + 'trainer_rival_route_209_chimchar.json', + 'trainer_rival_pastoria_city_piplup.json', + 'trainer_rival_pastoria_city_turtwig.json', + 'trainer_rival_pastoria_city_chimchar.json', + 'trainer_rival_canalave_city_piplup.json', + 'trainer_rival_canalave_city_turtwig.json', + 'trainer_rival_canalave_city_chimchar.json', + 'trainer_rival_pokemon_league_piplup.json', + 'trainer_rival_pokemon_league_turtwig.json', + 'trainer_rival_pokemon_league_chimchar.json', + 'trainer_sailor_zachariah.json', + 'trainer_sailor_samson.json', + 'trainer_unknown_484.json', + 'trainer_unknown_485.json', + 'trainer_scientist_shaun.json', + 'trainer_unknown_487.json', + 'trainer_ninja_boy_fabian.json', + 'trainer_ninja_boy_brennan.json', + 'trainer_ninja_boy_bruce.json', + 'trainer_beauty_devon.json', + 'trainer_beauty_nicola.json', + 'trainer_unknown_493.json', + 'trainer_swimmer_claire.json', + 'trainer_unknown_495.json', + 'trainer_youngster_wayne.json', + 'trainer_tuber_jacky.json', + 'trainer_tuber_caitlyn.json', + 'trainer_veteran_terrell.json', + 'trainer_veteran_brenden.json', + 'trainer_unknown_501.json', + 'trainer_unknown_502.json', + 'trainer_worker_noel.json', + 'trainer_worker_braden.json', + 'trainer_worker_brendon.json', + 'trainer_worker_quentin.json', + 'trainer_galactic_grunt_galactic_hq_b2f_1.json', + 'trainer_galactic_grunt_galactic_hq_b2f_2.json', + 'trainer_galactic_grunt_galactic_hq_3f_1.json', + 'trainer_galactic_grunt_galactic_hq_2f_1.json', + 'trainer_unknown_511.json', + 'trainer_galactic_grunt_galactic_hq_3f_2.json', + 'trainer_galactic_grunt_galactic_hq_2f_2.json', + 'trainer_galactic_grunt_galactic_hq_3f_3.json', + 'trainer_galactic_grunt_mt_coronet_3f_1.json', + 'trainer_galactic_grunt_mt_coronet_4f_1.json', + 'trainer_galactic_grunt_mt_coronet_4f_2.json', + 'trainer_galactic_grunt_mt_coronet_tunnel_room_1.json', + 'trainer_galactic_grunt_mt_coronet_tunnel_room_2.json', + 'trainer_galactic_grunt_mt_coronet_5f_1.json', + 'trainer_galactic_grunt_spear_pillar_1.json', + 'trainer_galactic_grunt_galactic_hq_3f_4.json', + 'trainer_galactic_grunt_mt_coronet__3f_1.json', + 'trainer_galactic_grunt_mt_coronet_tunnel_room_3.json', + 'trainer_galactic_grunt_mt_coronet_5f_2.json', + 'trainer_galactic_grunt_mt_coronet_6f.json', + 'trainer_galactic_grunt_spear_pillar_2.json', + 'trainer_commander_mars_spear_pillar.json', + 'trainer_roughneck_kirby.json', + 'trainer_pokefan_leonard.json', + 'trainer_pokefan_rebekah.json', + 'trainer_youngster_oliver.json', + 'trainer_belle_and_pa_beth_and_bob.json', + 'trainer_young_couple_mike_and_nat.json', + 'trainer_aroma_lady_alison.json', + 'trainer_artist_ismael.json', + 'trainer_breeder_kaylee.json', + 'trainer_cameraman_darryl.json', + 'trainer_collector_eugene.json', + 'trainer_pokefan_meredith.json', + 'trainer_pi_kendrick.json', + 'trainer_gentleman_leonardo.json', + 'trainer_socialite_rebecca.json', + 'trainer_lass_blythe.json', + 'trainer_rich_boy_roman.json', + 'trainer_lady_kylie.json', + 'trainer_reporters_valerie.json', + 'trainer_school_kid_esteban.json', + 'trainer_scientist_emilio.json', + 'trainer_beauty_gabriella.json', + 'trainer_beauty_harley.json', + 'trainer_veteran_emanuel.json', + 'trainer_ruin_maniac_karl.json', + 'trainer_bird_keeper_audrey.json', + 'trainer_bird_keeper_geneva.json', + 'trainer_bird_keeper_krystal.json', + 'trainer_dragon_tamer_geoffrey.json', + 'trainer_dragon_tamer_darien.json', + 'trainer_dragon_tamer_keegan.json', + 'trainer_dragon_tamer_stanley.json', + 'trainer_dragon_tamer_drake.json', + 'trainer_dragon_tamer_kenny.json', + 'trainer_ace_trainer_rodolfo.json', + 'trainer_ace_trainer_saul.json', + 'trainer_ace_trainer_jose.json', + 'trainer_ace_trainer_felix.json', + 'trainer_ace_trainer_quinn.json', + 'trainer_ace_trainer_graham.json', + 'trainer_ace_trainer_keenan.json', + 'trainer_ace_trainer_stefan.json', + 'trainer_ace_trainer_skylar.json', + 'trainer_ace_trainer_abel.json', + 'trainer_ace_trainer_deanna.json', + 'trainer_ace_trainer_moira.json', + 'trainer_ace_trainer_dana.json', + 'trainer_ace_trainer_mikayla.json', + 'trainer_ace_trainer_meagan.json', + 'trainer_ace_trainer_sandra.json', + 'trainer_ace_trainer_kassandra.json', + 'trainer_ace_trainer_jasmin.json', + 'trainer_ace_trainer_natasha.json', + 'trainer_ace_trainer_monique.json', + 'trainer_psychic_corbin.json', + 'trainer_psychic_sterling.json', + 'trainer_psychic_daisy.json', + 'trainer_psychic_chelsey.json', + 'trainer_black_belt_davon.json', + 'trainer_black_belt_griffin.json', + 'trainer_black_belt_ray.json', + 'trainer_black_belt_jarrett.json', + 'trainer_ranger_kyler.json', + 'trainer_ranger_deshawn.json', + 'trainer_ranger_dwayne.json', + 'trainer_ranger_ashlee.json', + 'trainer_ranger_felicia.json', + 'trainer_ranger_krista.json', + 'trainer_swimmer_glenn.json', + 'trainer_swimmer_kurt.json', + 'trainer_swimmer_sam.json', + 'trainer_swimmer_wade.json', + 'trainer_swimmer_joanna.json', + 'trainer_swimmer_sophia.json', + 'trainer_swimmer_mallory.json', + 'trainer_swimmer_lydia.json', + 'trainer_unknown_605.json', + 'trainer_veteran_harlan.json', + 'trainer_rival_spear_pillar_piplup.json', + 'trainer_trainer_cheryl_cheryl.json', + 'trainer_trainer_riley_riley.json', + 'trainer_trainer_marley_marley.json', + 'trainer_trainer_buck_buck.json', + 'trainer_trainer_mira_mira.json', + 'trainer_lucas_jubilife_city_chimchar.json', + 'trainer_lucas_jubilife_city_piplup.json', + 'trainer_lucas_jubilife_city_turtwig.json', + 'trainer_dawn_jubilife_city_chimchar.json', + 'trainer_dawn_jubilife_city_piplup.json', + 'trainer_dawn_jubilife_city_turtwig.json', + 'trainer_rival_spear_pillar_turtwig.json', + 'trainer_rival_spear_pillar_chimchar.json', + 'trainer_lucas_veilstone_city_chimchar.json', + 'trainer_lucas_veilstone_city_piplup.json', + 'trainer_lucas_veilstone_city_turtwig.json', + 'trainer_dawn_veilstone_city_chimchar.json', + 'trainer_dawn_veilstone_city_piplup.json', + 'trainer_dawn_veilstone_city_turtwig.json', + 'trainer_aroma_lady_elizabeth_rematch_1.json', + 'trainer_aroma_lady_elizabeth_rematch_2.json', + 'trainer_aroma_lady_elizabeth_rematch_3.json', + 'trainer_artist_william_rematch_1.json', + 'trainer_artist_william_rematch_2.json', + 'trainer_artist_william_rematch_3.json', + 'trainer_battle_girl_helen_rematch_1.json', + 'trainer_battle_girl_helen_rematch_2.json', + 'trainer_battle_girl_helen_rematch_3.json', + 'trainer_bird_keeper_brianna_rematch_1.json', + 'trainer_bird_keeper_brianna_rematch_2.json', + 'trainer_bird_keeper_audrey_rematch.json', + 'trainer_breeder_albert_rematch_1.json', + 'trainer_breeder_albert_rematch_2.json', + 'trainer_breeder_albert_rematch_3.json', + 'trainer_breeder_jennifer_rematch_1.json', + 'trainer_breeder_jennifer_rematch_2.json', + 'trainer_breeder_jennifer_rematch_3.json', + 'trainer_camper_zackary_rematch_1.json', + 'trainer_camper_zackary_rematch_2.json', + 'trainer_camper_zackary_rematch_3.json', + 'trainer_ace_trainer_dalton_rematch.json', + 'trainer_ace_trainer_olivia_rematch.json', + 'trainer_collector_ivan_rematch.json', + 'trainer_unknown_651.json', + 'trainer_unknown_652.json', + 'trainer_cyclist_john_rematch_1.json', + 'trainer_cyclist_john_rematch_2.json', + 'trainer_cyclist_john_rematch_3.json', + 'trainer_cyclist_kayla_rematch_1.json', + 'trainer_cyclist_kayla_rematch_2.json', + 'trainer_cyclist_kayla_rematch_3.json', + 'trainer_dragon_tamer_patrick_rematch_1.json', + 'trainer_dragon_tamer_patrick_rematch_2.json', + 'trainer_dragon_tamer_hayden_rematch.json', + 'trainer_dragon_tamer_geoffrey_rematch.json', + 'trainer_ace_trainer_jake_rematch.json', + 'trainer_ace_trainer_dennis_rematch_1.json', + 'trainer_ace_trainer_dennis_rematch_2.json', + 'trainer_ace_trainer_rodolfo_rematch.json', + 'trainer_ace_trainer_saul_rematch.json', + 'trainer_ace_trainer_shannon_rematch.json', + 'trainer_ace_trainer_maya_rematch_1.json', + 'trainer_ace_trainer_maya_rematch_2.json', + 'trainer_ace_trainer_deanna_rematch.json', + 'trainer_ace_trainer_moira_rematch.json', + 'trainer_psychic_mitchell_rematch_1.json', + 'trainer_psychic_mitchell_rematch_2.json', + 'trainer_psychic_maxwell_rematch.json', + 'trainer_psychic_corbin_rematch.json', + 'trainer_psychic_abigail_rematch_1.json', + 'trainer_psychic_abigail_rematch_2.json', + 'trainer_psychic_brittney_rematch.json', + 'trainer_psychic_daisy_rematch.json', + 'trainer_rancher_marco_rematch_1.json', + 'trainer_rancher_marco_rematch_2.json', + 'trainer_fisherman_joseph_rematch_1.json', + 'trainer_fisherman_joseph_rematch_2.json', + 'trainer_fisherman_miguel_rematch.json', + 'trainer_fisherman_alec_rematch.json', + 'trainer_twins_teri_and_tia_rematch_1.json', + 'trainer_twins_teri_and_tia_rematch_2.json', + 'trainer_pi_carlos_rematch_1.json', + 'trainer_pi_carlos_rematch_2.json', + 'trainer_gentleman_jeremy_rematch_1.json', + 'trainer_gentleman_jeremy_rematch_2.json', + 'trainer_gentleman_jeremy_rematch_3.json', + 'trainer_guitarist_tony_rematch.json', + 'trainer_ruin_maniac_harry_rematch_1.json', + 'trainer_ruin_maniac_harry_rematch_2.json', + 'trainer_jogger_craig_rematch_1.json', + 'trainer_jogger_craig_rematch_2.json', + 'trainer_black_belt_philip_rematch.json', + 'trainer_black_belt_davon_rematch.json', + 'trainer_socialite_reina_rematch_1.json', + 'trainer_socialite_reina_rematch_2.json', + 'trainer_lass_samantha_rematch_1.json', + 'trainer_lass_samantha_rematch_2.json', + 'trainer_lass_samantha_rematch_3.json', + 'trainer_lass_madeline_rematch_1.json', + 'trainer_lass_madeline_rematch_2.json', + 'trainer_lass_madeline_rematch_3.json', + 'trainer_hiker_theodore_rematch_1.json', + 'trainer_hiker_theodore_rematch_2.json', + 'trainer_hiker_theodore_rematch_3.json', + 'trainer_bug_catcher_brandon_rematch_1.json', + 'trainer_bug_catcher_brandon_rematch_2.json', + 'trainer_bug_catcher_brandon_rematch_3.json', + 'trainer_parasol_lady_alexa_rematch_1.json', + 'trainer_parasol_lady_alexa_rematch_2.json', + 'trainer_parasol_lady_alexa_rematch_3.json', + 'trainer_picnicker_karina_rematch_1.json', + 'trainer_picnicker_karina_rematch_2.json', + 'trainer_picnicker_karina_rematch_3.json', + 'trainer_poke_kid_danielle_rematch_1.json', + 'trainer_poke_kid_danielle_rematch_2.json', + 'trainer_poke_kid_danielle_rematch_3.json', + 'trainer_policeman_danny_rematch_1.json', + 'trainer_policeman_danny_rematch_2.json', + 'trainer_policeman_danny_rematch_3.json', + 'trainer_rich_boy_trey_rematch_1.json', + 'trainer_rich_boy_trey_rematch_2.json', + 'trainer_lady_melissa_rematch_1.json', + 'trainer_lady_melissa_rematch_2.json', + 'trainer_lady_melissa_rematch_3.json', + 'trainer_ranger_taylor_rematch_1.json', + 'trainer_ranger_taylor_rematch_2.json', + 'trainer_ranger_taylor_rematch_3.json', + 'trainer_ranger_kyler_rematch.json', + 'trainer_ranger_allison_rematch_1.json', + 'trainer_ranger_allison_rematch_2.json', + 'trainer_ranger_allison_rematch_3.json', + 'trainer_ranger_ashlee_rematch.json', + 'trainer_sailor_marc_rematch_1.json', + 'trainer_sailor_marc_rematch_2.json', + 'trainer_sailor_zachariah_rematch.json', + 'trainer_scientist_shaun_rematch_1.json', + 'trainer_scientist_shaun_rematch_2.json', + 'trainer_scientist_shaun_rematch_3.json', + 'trainer_ninja_boy_zach_rematch_1.json', + 'trainer_ninja_boy_zach_rematch_2.json', + 'trainer_ninja_boy_zach_rematch_3.json', + 'trainer_beauty_cyndy_rematch_1.json', + 'trainer_beauty_cyndy_rematch_2.json', + 'trainer_skier_edward_rematch_1.json', + 'trainer_skier_edward_rematch_2.json', + 'trainer_skier_bjorn_rematch_1.json', + 'trainer_skier_bjorn_rematch_2.json', + 'trainer_skier_andrea_rematch_1.json', + 'trainer_skier_andrea_rematch_2.json', + 'trainer_skier_madison_rematch_1.json', + 'trainer_skier_madison_rematch_2.json', + 'trainer_swimmer_wesley_rematch.json', + 'trainer_swimmer_francisco_rematch.json', + 'trainer_swimmer_glenn_rematch.json', + 'trainer_swimmer_miranda_rematch.json', + 'trainer_swimmer_crystal_rematch.json', + 'trainer_swimmer_joanna_rematch.json', + 'trainer_youngster_tristan_rematch_1.json', + 'trainer_youngster_tristan_rematch_2.json', + 'trainer_youngster_tristan_rematch_3.json', + 'trainer_youngster_dallas_rematch_1.json', + 'trainer_youngster_dallas_rematch_2.json', + 'trainer_youngster_dallas_rematch_3.json', + 'trainer_tuber_jared_rematch_1.json', + 'trainer_tuber_jared_rematch_2.json', + 'trainer_tuber_chelsea_rematch_1.json', + 'trainer_veteran_brian_rematch_1.json', + 'trainer_tuber_chelsea_rematch_2.json', + 'trainer_veteran_brian_rematch_2.json', + 'trainer_veteran_armando_rematch.json', + 'trainer_unknown_778.json', + 'trainer_unknown_779.json', + 'trainer_unknown_780.json', + 'trainer_unknown_781.json', + 'trainer_unknown_782.json', + 'trainer_unknown_783.json', + 'trainer_unknown_784.json', + 'trainer_unknown_785.json', + 'trainer_unknown_786.json', + 'trainer_unknown_787.json', + 'trainer_unknown_788.json', + 'trainer_unknown_789.json', + 'trainer_unknown_790.json', + 'trainer_unknown_791.json', + 'trainer_unknown_792.json', + 'trainer_unknown_793.json', + 'trainer_unknown_794.json', + 'trainer_unknown_795.json', + 'trainer_unknown_796.json', + 'trainer_unknown_797.json', + 'trainer_unknown_798.json', + 'trainer_unknown_799.json', + 'trainer_unknown_800.json', + 'trainer_unknown_801.json', + 'trainer_unknown_802.json', + 'trainer_unknown_803.json', + 'trainer_unknown_804.json', + 'trainer_unknown_805.json', + 'trainer_unknown_806.json', + 'trainer_unknown_807.json', + 'trainer_unknown_808.json', + 'trainer_unknown_809.json', + 'trainer_unknown_810.json', + 'trainer_unknown_811.json', + 'trainer_unknown_812.json', + 'trainer_unknown_813.json', + 'trainer_unknown_814.json', + 'trainer_unknown_815.json', + 'trainer_unknown_816.json', + 'trainer_unknown_817.json', + 'trainer_unknown_818.json', + 'trainer_unknown_819.json', + 'trainer_unknown_820.json', + 'trainer_unknown_821.json', + 'trainer_unknown_822.json', + 'trainer_unknown_823.json', + 'trainer_unknown_824.json', + 'trainer_unknown_825.json', + 'trainer_unknown_828.json', + 'trainer_ace_trainer_anton.json', + 'trainer_ace_trainer_brenna.json', + 'trainer_scientist_darrius.json', + 'trainer_scientist_fredrick.json', + 'trainer_scientist_travon.json', + 'trainer_poke_kid_janet.json', + 'trainer_unknown_833.json', + 'trainer_unknown_834.json', + 'trainer_galactic_grunt_iron_island_1.json', + 'trainer_galactic_grunt_iron_island_2.json', + 'trainer_rival_survival_area_1_piplup.json', + 'trainer_rival_survival_area_1_turtwig.json', + 'trainer_rival_survival_area_1_chimchar.json', + 'trainer_unknown_840.json', + 'trainer_unknown_841.json', + 'trainer_unknown_842.json', + 'trainer_galactic_grunt_valley_windworks_1.json', + 'trainer_worker_dillan.json', + 'trainer_worker_holden.json', + 'trainer_worker_conrad.json', + 'trainer_galactic_grunt_valor_lakefront.json', + 'trainer_galactic_grunt_veilstone_city_1.json', + 'trainer_galactic_grunt_veilstone_city_2.json', + 'trainer_rival_route_201_piplup.json', + 'trainer_rival_route_201_turtwig.json', + 'trainer_rival_route_201_chimchar.json', + 'trainer_leader_candice_rematch.json', + 'trainer_leader_maylene_rematch.json', + 'trainer_leader_volkner_rematch.json', + 'trainer_leader_byron_rematch.json', + 'trainer_leader_gardenia_rematch.json', + 'trainer_leader_roark_rematch.json', + 'trainer_leader_wake_rematch.json', + 'trainer_leader_fantina_rematch.json', + 'trainer_trainer_riley_battleground.json', + 'trainer_trainer_buck_battleground.json', + 'trainer_trainer_marley_battleground.json', + 'trainer_trainer_mira_battleground.json', + 'trainer_trainer_cheryl_battleground.json', + 'trainer_elite_four_aaron_rematch.json', + 'trainer_elite_four_bertha_rematch.json', + 'trainer_elite_four_flint_rematch.json', + 'trainer_elite_four_lucian_rematch.json', + 'trainer_champion_cynthia_rematch.json', + 'trainer_rival_survival_area_2_piplup.json', + 'trainer_rival_survival_area_2_turtwig.json', + 'trainer_rival_survival_area_2_chimchar.json', + 'trainer_cameraman_tevin.json', + 'trainer_cameraman_tevin_rematch_1.json', + 'trainer_cameraman_tevin_rematch_2.json', + 'trainer_guitarist_arturo.json', + 'trainer_guitarist_arturo_rematch_1.json', + 'trainer_guitarist_arturo_rematch_2.json', + 'trainer_idol_grace.json', + 'trainer_idol_grace_rematch_1.json', + 'trainer_idol_grace_rematch_2.json', + 'trainer_interviewers_roxy_and_oli.json', + 'trainer_interviewers_roxy_and_oli_rematch_1.json', + 'trainer_interviewers_roxy_and_oli_rematch_2.json', + 'trainer_clown_lee.json', + 'trainer_clown_lee_rematch_1.json', + 'trainer_clown_lee_rematch_2.json', + 'trainer_poke_kid_ariel.json', + 'trainer_poke_kid_ariel_rematch_1.json', + 'trainer_poke_kid_ariel_rematch_2.json', + 'trainer_rich_boy_liam.json', + 'trainer_lady_celeste.json', + 'trainer_reporters_kinsey.json', + 'trainer_reporters_kinsey_rematch_1.json', + 'trainer_reporters_kinsey_rematch_2.json', + 'trainer_maid_belinda.json', + 'trainer_maid_sophie.json', + 'trainer_maid_emily.json', + 'trainer_maid_elena.json', + 'trainer_maid_clare.json', + 'trainer_unknown_902.json', + 'trainer_unknown_903.json', + 'trainer_unknown_904.json', + 'trainer_unknown_905.json', + 'trainer_cameraman_tevin_rematch_3.json', + 'trainer_guitarist_arturo_rematch_3.json', + 'trainer_idol_grace_rematch_3.json', + 'trainer_interviewers_roxy_and_oli_rematch_3.json', + 'trainer_clown_lee_rematch_3.json', + 'trainer_poke_kid_ariel_rematch_3.json', + 'trainer_reporters_kinsey_rematch_3.json', + 'trainer_galactic_boss_cyrus_celestic_town_ruins.json', + 'trainer_cameraman_tevin_rematch_4.json', + 'trainer_guitarist_arturo_rematch_4.json', + 'trainer_idol_grace_rematch_4.json', + 'trainer_interviewers_roxy_and_oli_rematch_4.json', + 'trainer_clown_lee_rematch_4.json', + 'trainer_poke_kid_ariel_rematch_4.json', + 'trainer_reporters_kinsey_rematch_4.json', + 'trainer_leader_volkner_fight_area.json', + 'trainer_elite_four_flint_fight_area.json', + 'trainer_rival_fight_area_piplup.json', + 'trainer_rival_fight_area_turtwig.json', + 'trainer_rival_fight_area_chimchar.json', + 'trainer_commander_mars_stark_mountain.json', + 'trainer_commander_jupiter_stark_mountain.json', +] trainer_data_gen = generator( trainer_data_py, arguments: [ '@INPUT@', '@OUTPUT@', ], - output: '@BASENAME@.bin', + output: '@BASENAME@', ) trainer_party_gen = generator( trainer_party_py, arguments: [ '@INPUT@', '@OUTPUT@', ], - output: '@BASENAME@.bin', + output: '@BASENAME@', ) +trainers_order = files('trainers.order') + trdata_narc = custom_target('trdata.narc', - output: 'trdata.narc', + output: [ + 'trdata.narc', + 'trdata.naix', + ], input: trainer_data_gen.process(trainer_data_files, env: json2bin_env), depends: [ py_consts_generators ], command: [ knarc_exe, '-d', '@PRIVATE_DIR@', - '-p', '@OUTPUT@', + '-p', '@OUTPUT0@', + '--order', trainers_order, + '--naix', ], ) trpoke_narc = custom_target('trpoke.narc', - output: 'trpoke.narc', + output: [ + 'trpoke.narc', + 'trpoke.naix', + ], input: trainer_party_gen.process(trainer_data_files, env: json2bin_env), depends: [ py_consts_generators ], command: [ knarc_exe, '-d', '@PRIVATE_DIR@', - '-p', '@OUTPUT@', + '-p', '@OUTPUT0@', + '--order', trainers_order, + '--naix', ] ) -nitrofs_files += trdata_narc -nitrofs_files += trpoke_narc +nitrofs_files += trdata_narc[0] +nitrofs_files += trpoke_narc[0] +naix_headers += trdata_narc[1] +naix_headers += trpoke_narc[1] diff --git a/res/trainers/0572.json b/res/trainers/trainer_ace_trainer_abel.json similarity index 100% rename from res/trainers/0572.json rename to res/trainers/trainer_ace_trainer_abel.json diff --git a/res/trainers/0271.json b/res/trainers/trainer_ace_trainer_alicia.json similarity index 100% rename from res/trainers/0271.json rename to res/trainers/trainer_ace_trainer_alicia.json diff --git a/res/trainers/0280.json b/res/trainers/trainer_ace_trainer_allen.json similarity index 100% rename from res/trainers/0280.json rename to res/trainers/trainer_ace_trainer_allen.json diff --git a/res/trainers/0067.json b/res/trainers/trainer_ace_trainer_alyssa.json similarity index 100% rename from res/trainers/0067.json rename to res/trainers/trainer_ace_trainer_alyssa.json diff --git a/res/trainers/0827.json b/res/trainers/trainer_ace_trainer_anton.json similarity index 100% rename from res/trainers/0827.json rename to res/trainers/trainer_ace_trainer_anton.json diff --git a/res/trainers/0390.json b/res/trainers/trainer_ace_trainer_arthur.json similarity index 100% rename from res/trainers/0390.json rename to res/trainers/trainer_ace_trainer_arthur.json diff --git a/res/trainers/0132.json b/res/trainers/trainer_ace_trainer_blake.json similarity index 100% rename from res/trainers/0132.json rename to res/trainers/trainer_ace_trainer_blake.json diff --git a/res/trainers/0393.json b/res/trainers/trainer_ace_trainer_brandi.json similarity index 100% rename from res/trainers/0393.json rename to res/trainers/trainer_ace_trainer_brandi.json diff --git a/res/trainers/0283.json b/res/trainers/trainer_ace_trainer_breanna.json similarity index 100% rename from res/trainers/0283.json rename to res/trainers/trainer_ace_trainer_breanna.json diff --git a/res/trainers/0392.json b/res/trainers/trainer_ace_trainer_brenda.json similarity index 100% rename from res/trainers/0392.json rename to res/trainers/trainer_ace_trainer_brenda.json diff --git a/res/trainers/0828.json b/res/trainers/trainer_ace_trainer_brenna.json similarity index 100% rename from res/trainers/0828.json rename to res/trainers/trainer_ace_trainer_brenna.json diff --git a/res/trainers/0284.json b/res/trainers/trainer_ace_trainer_catherine.json similarity index 100% rename from res/trainers/0284.json rename to res/trainers/trainer_ace_trainer_catherine.json diff --git a/res/trainers/0279.json b/res/trainers/trainer_ace_trainer_cesar.json similarity index 100% rename from res/trainers/0279.json rename to res/trainers/trainer_ace_trainer_cesar.json diff --git a/res/trainers/0394.json b/res/trainers/trainer_ace_trainer_clarice.json similarity index 100% rename from res/trainers/0394.json rename to res/trainers/trainer_ace_trainer_clarice.json diff --git a/res/trainers/0140.json b/res/trainers/trainer_ace_trainer_dalton.json similarity index 100% rename from res/trainers/0140.json rename to res/trainers/trainer_ace_trainer_dalton.json diff --git a/res/trainers/0648.json b/res/trainers/trainer_ace_trainer_dalton_rematch.json similarity index 100% rename from res/trainers/0648.json rename to res/trainers/trainer_ace_trainer_dalton_rematch.json diff --git a/res/trainers/0575.json b/res/trainers/trainer_ace_trainer_dana.json similarity index 100% rename from res/trainers/0575.json rename to res/trainers/trainer_ace_trainer_dana.json diff --git a/res/trainers/0573.json b/res/trainers/trainer_ace_trainer_deanna.json similarity index 100% rename from res/trainers/0573.json rename to res/trainers/trainer_ace_trainer_deanna.json diff --git a/res/trainers/0671.json b/res/trainers/trainer_ace_trainer_deanna_rematch.json similarity index 100% rename from res/trainers/0671.json rename to res/trainers/trainer_ace_trainer_deanna_rematch.json diff --git a/res/trainers/0278.json b/res/trainers/trainer_ace_trainer_dennis.json similarity index 100% rename from res/trainers/0278.json rename to res/trainers/trainer_ace_trainer_dennis.json diff --git a/res/trainers/0664.json b/res/trainers/trainer_ace_trainer_dennis_rematch_1.json similarity index 100% rename from res/trainers/0664.json rename to res/trainers/trainer_ace_trainer_dennis_rematch_1.json diff --git a/res/trainers/0665.json b/res/trainers/trainer_ace_trainer_dennis_rematch_2.json similarity index 100% rename from res/trainers/0665.json rename to res/trainers/trainer_ace_trainer_dennis_rematch_2.json diff --git a/res/trainers/0285.json b/res/trainers/trainer_ace_trainer_destiny.json similarity index 100% rename from res/trainers/0285.json rename to res/trainers/trainer_ace_trainer_destiny.json diff --git a/res/trainers/0066.json b/res/trainers/trainer_ace_trainer_ernest.json similarity index 100% rename from res/trainers/0066.json rename to res/trainers/trainer_ace_trainer_ernest.json diff --git a/res/trainers/0566.json b/res/trainers/trainer_ace_trainer_felix.json similarity index 100% rename from res/trainers/0566.json rename to res/trainers/trainer_ace_trainer_felix.json diff --git a/res/trainers/0133.json b/res/trainers/trainer_ace_trainer_garrett.json similarity index 100% rename from res/trainers/0133.json rename to res/trainers/trainer_ace_trainer_garrett.json diff --git a/res/trainers/0568.json b/res/trainers/trainer_ace_trainer_graham.json similarity index 100% rename from res/trainers/0568.json rename to res/trainers/trainer_ace_trainer_graham.json diff --git a/res/trainers/0225.json b/res/trainers/trainer_ace_trainer_henry.json similarity index 100% rename from res/trainers/0225.json rename to res/trainers/trainer_ace_trainer_henry.json diff --git a/res/trainers/0269.json b/res/trainers/trainer_ace_trainer_isaiah.json similarity index 100% rename from res/trainers/0269.json rename to res/trainers/trainer_ace_trainer_isaiah.json diff --git a/res/trainers/0170.json b/res/trainers/trainer_ace_trainer_jake.json similarity index 100% rename from res/trainers/0170.json rename to res/trainers/trainer_ace_trainer_jake.json diff --git a/res/trainers/0663.json b/res/trainers/trainer_ace_trainer_jake_rematch.json similarity index 100% rename from res/trainers/0663.json rename to res/trainers/trainer_ace_trainer_jake_rematch.json diff --git a/res/trainers/0286.json b/res/trainers/trainer_ace_trainer_jamie.json similarity index 100% rename from res/trainers/0286.json rename to res/trainers/trainer_ace_trainer_jamie.json diff --git a/res/trainers/0580.json b/res/trainers/trainer_ace_trainer_jasmin.json similarity index 100% rename from res/trainers/0580.json rename to res/trainers/trainer_ace_trainer_jasmin.json diff --git a/res/trainers/0388.json b/res/trainers/trainer_ace_trainer_jonah.json similarity index 100% rename from res/trainers/0388.json rename to res/trainers/trainer_ace_trainer_jonah.json diff --git a/res/trainers/0565.json b/res/trainers/trainer_ace_trainer_jose.json similarity index 100% rename from res/trainers/0565.json rename to res/trainers/trainer_ace_trainer_jose.json diff --git a/res/trainers/0579.json b/res/trainers/trainer_ace_trainer_kassandra.json similarity index 100% rename from res/trainers/0579.json rename to res/trainers/trainer_ace_trainer_kassandra.json diff --git a/res/trainers/0569.json b/res/trainers/trainer_ace_trainer_keenan.json similarity index 100% rename from res/trainers/0569.json rename to res/trainers/trainer_ace_trainer_keenan.json diff --git a/res/trainers/0134.json b/res/trainers/trainer_ace_trainer_laura.json similarity index 100% rename from res/trainers/0134.json rename to res/trainers/trainer_ace_trainer_laura.json diff --git a/res/trainers/0135.json b/res/trainers/trainer_ace_trainer_maria.json similarity index 100% rename from res/trainers/0135.json rename to res/trainers/trainer_ace_trainer_maria.json diff --git a/res/trainers/0226.json b/res/trainers/trainer_ace_trainer_mariah.json similarity index 100% rename from res/trainers/0226.json rename to res/trainers/trainer_ace_trainer_mariah.json diff --git a/res/trainers/0287.json b/res/trainers/trainer_ace_trainer_maya.json similarity index 100% rename from res/trainers/0287.json rename to res/trainers/trainer_ace_trainer_maya.json diff --git a/res/trainers/0669.json b/res/trainers/trainer_ace_trainer_maya_rematch_1.json similarity index 100% rename from res/trainers/0669.json rename to res/trainers/trainer_ace_trainer_maya_rematch_1.json diff --git a/res/trainers/0670.json b/res/trainers/trainer_ace_trainer_maya_rematch_2.json similarity index 100% rename from res/trainers/0670.json rename to res/trainers/trainer_ace_trainer_maya_rematch_2.json diff --git a/res/trainers/0577.json b/res/trainers/trainer_ace_trainer_meagan.json similarity index 100% rename from res/trainers/0577.json rename to res/trainers/trainer_ace_trainer_meagan.json diff --git a/res/trainers/0389.json b/res/trainers/trainer_ace_trainer_micah.json similarity index 100% rename from res/trainers/0389.json rename to res/trainers/trainer_ace_trainer_micah.json diff --git a/res/trainers/0576.json b/res/trainers/trainer_ace_trainer_mikayla.json similarity index 100% rename from res/trainers/0576.json rename to res/trainers/trainer_ace_trainer_mikayla.json diff --git a/res/trainers/0574.json b/res/trainers/trainer_ace_trainer_moira.json similarity index 100% rename from res/trainers/0574.json rename to res/trainers/trainer_ace_trainer_moira.json diff --git a/res/trainers/0672.json b/res/trainers/trainer_ace_trainer_moira_rematch.json similarity index 100% rename from res/trainers/0672.json rename to res/trainers/trainer_ace_trainer_moira_rematch.json diff --git a/res/trainers/0582.json b/res/trainers/trainer_ace_trainer_monique.json similarity index 100% rename from res/trainers/0582.json rename to res/trainers/trainer_ace_trainer_monique.json diff --git a/res/trainers/0581.json b/res/trainers/trainer_ace_trainer_natasha.json similarity index 100% rename from res/trainers/0581.json rename to res/trainers/trainer_ace_trainer_natasha.json diff --git a/res/trainers/0141.json b/res/trainers/trainer_ace_trainer_olivia.json similarity index 100% rename from res/trainers/0141.json rename to res/trainers/trainer_ace_trainer_olivia.json diff --git a/res/trainers/0649.json b/res/trainers/trainer_ace_trainer_olivia_rematch.json similarity index 100% rename from res/trainers/0649.json rename to res/trainers/trainer_ace_trainer_olivia_rematch.json diff --git a/res/trainers/0224.json b/res/trainers/trainer_ace_trainer_omar.json similarity index 100% rename from res/trainers/0224.json rename to res/trainers/trainer_ace_trainer_omar.json diff --git a/res/trainers/0567.json b/res/trainers/trainer_ace_trainer_quinn.json similarity index 100% rename from res/trainers/0567.json rename to res/trainers/trainer_ace_trainer_quinn.json diff --git a/res/trainers/0563.json b/res/trainers/trainer_ace_trainer_rodolfo.json similarity index 100% rename from res/trainers/0563.json rename to res/trainers/trainer_ace_trainer_rodolfo.json diff --git a/res/trainers/0666.json b/res/trainers/trainer_ace_trainer_rodolfo_rematch.json similarity index 100% rename from res/trainers/0666.json rename to res/trainers/trainer_ace_trainer_rodolfo_rematch.json diff --git a/res/trainers/0282.json b/res/trainers/trainer_ace_trainer_ruben.json similarity index 100% rename from res/trainers/0282.json rename to res/trainers/trainer_ace_trainer_ruben.json diff --git a/res/trainers/0578.json b/res/trainers/trainer_ace_trainer_sandra.json similarity index 100% rename from res/trainers/0578.json rename to res/trainers/trainer_ace_trainer_sandra.json diff --git a/res/trainers/0564.json b/res/trainers/trainer_ace_trainer_saul.json similarity index 100% rename from res/trainers/0564.json rename to res/trainers/trainer_ace_trainer_saul.json diff --git a/res/trainers/0667.json b/res/trainers/trainer_ace_trainer_saul_rematch.json similarity index 100% rename from res/trainers/0667.json rename to res/trainers/trainer_ace_trainer_saul_rematch.json diff --git a/res/trainers/0270.json b/res/trainers/trainer_ace_trainer_savannah.json similarity index 100% rename from res/trainers/0270.json rename to res/trainers/trainer_ace_trainer_savannah.json diff --git a/res/trainers/0268.json b/res/trainers/trainer_ace_trainer_sergio.json similarity index 100% rename from res/trainers/0268.json rename to res/trainers/trainer_ace_trainer_sergio.json diff --git a/res/trainers/0171.json b/res/trainers/trainer_ace_trainer_shannon.json similarity index 100% rename from res/trainers/0171.json rename to res/trainers/trainer_ace_trainer_shannon.json diff --git a/res/trainers/0668.json b/res/trainers/trainer_ace_trainer_shannon_rematch.json similarity index 100% rename from res/trainers/0668.json rename to res/trainers/trainer_ace_trainer_shannon_rematch.json diff --git a/res/trainers/0571.json b/res/trainers/trainer_ace_trainer_skylar.json similarity index 100% rename from res/trainers/0571.json rename to res/trainers/trainer_ace_trainer_skylar.json diff --git a/res/trainers/0570.json b/res/trainers/trainer_ace_trainer_stefan.json similarity index 100% rename from res/trainers/0570.json rename to res/trainers/trainer_ace_trainer_stefan.json diff --git a/res/trainers/0227.json b/res/trainers/trainer_ace_trainer_sydney.json similarity index 100% rename from res/trainers/0227.json rename to res/trainers/trainer_ace_trainer_sydney.json diff --git a/res/trainers/0281.json b/res/trainers/trainer_ace_trainer_zachery.json similarity index 100% rename from res/trainers/0281.json rename to res/trainers/trainer_ace_trainer_zachery.json diff --git a/res/trainers/0535.json b/res/trainers/trainer_aroma_lady_alison.json similarity index 100% rename from res/trainers/0535.json rename to res/trainers/trainer_aroma_lady_alison.json diff --git a/res/trainers/0260.json b/res/trainers/trainer_aroma_lady_angela.json similarity index 100% rename from res/trainers/0260.json rename to res/trainers/trainer_aroma_lady_angela.json diff --git a/res/trainers/0021.json b/res/trainers/trainer_aroma_lady_elizabeth.json similarity index 100% rename from res/trainers/0021.json rename to res/trainers/trainer_aroma_lady_elizabeth.json diff --git a/res/trainers/0627.json b/res/trainers/trainer_aroma_lady_elizabeth_rematch_1.json similarity index 100% rename from res/trainers/0627.json rename to res/trainers/trainer_aroma_lady_elizabeth_rematch_1.json diff --git a/res/trainers/0628.json b/res/trainers/trainer_aroma_lady_elizabeth_rematch_2.json similarity index 100% rename from res/trainers/0628.json rename to res/trainers/trainer_aroma_lady_elizabeth_rematch_2.json diff --git a/res/trainers/0629.json b/res/trainers/trainer_aroma_lady_elizabeth_rematch_3.json similarity index 100% rename from res/trainers/0629.json rename to res/trainers/trainer_aroma_lady_elizabeth_rematch_3.json diff --git a/res/trainers/0044.json b/res/trainers/trainer_aroma_lady_hannah.json similarity index 100% rename from res/trainers/0044.json rename to res/trainers/trainer_aroma_lady_hannah.json diff --git a/res/trainers/0259.json b/res/trainers/trainer_aroma_lady_jenna.json similarity index 100% rename from res/trainers/0259.json rename to res/trainers/trainer_aroma_lady_jenna.json diff --git a/res/trainers/0014.json b/res/trainers/trainer_aroma_lady_taylor.json similarity index 100% rename from res/trainers/0014.json rename to res/trainers/trainer_aroma_lady_taylor.json diff --git a/res/trainers/0536.json b/res/trainers/trainer_artist_ismael.json similarity index 100% rename from res/trainers/0536.json rename to res/trainers/trainer_artist_ismael.json diff --git a/res/trainers/0045.json b/res/trainers/trainer_artist_william.json similarity index 100% rename from res/trainers/0045.json rename to res/trainers/trainer_artist_william.json diff --git a/res/trainers/0630.json b/res/trainers/trainer_artist_william_rematch_1.json similarity index 100% rename from res/trainers/0630.json rename to res/trainers/trainer_artist_william_rematch_1.json diff --git a/res/trainers/0631.json b/res/trainers/trainer_artist_william_rematch_2.json similarity index 100% rename from res/trainers/0631.json rename to res/trainers/trainer_artist_william_rematch_2.json diff --git a/res/trainers/0632.json b/res/trainers/trainer_artist_william_rematch_3.json similarity index 100% rename from res/trainers/0632.json rename to res/trainers/trainer_artist_william_rematch_3.json diff --git a/res/trainers/0038.json b/res/trainers/trainer_battle_girl_helen.json similarity index 100% rename from res/trainers/0038.json rename to res/trainers/trainer_battle_girl_helen.json diff --git a/res/trainers/0633.json b/res/trainers/trainer_battle_girl_helen_rematch_1.json similarity index 100% rename from res/trainers/0633.json rename to res/trainers/trainer_battle_girl_helen_rematch_1.json diff --git a/res/trainers/0634.json b/res/trainers/trainer_battle_girl_helen_rematch_2.json similarity index 100% rename from res/trainers/0634.json rename to res/trainers/trainer_battle_girl_helen_rematch_2.json diff --git a/res/trainers/0635.json b/res/trainers/trainer_battle_girl_helen_rematch_3.json similarity index 100% rename from res/trainers/0635.json rename to res/trainers/trainer_battle_girl_helen_rematch_3.json diff --git a/res/trainers/0020.json b/res/trainers/trainer_battle_girl_kelsey.json similarity index 100% rename from res/trainers/0020.json rename to res/trainers/trainer_battle_girl_kelsey.json diff --git a/res/trainers/0372.json b/res/trainers/trainer_battle_girl_tyler.json similarity index 100% rename from res/trainers/0372.json rename to res/trainers/trainer_battle_girl_tyler.json diff --git a/res/trainers/0346.json b/res/trainers/trainer_beauty_cyndy.json similarity index 100% rename from res/trainers/0346.json rename to res/trainers/trainer_beauty_cyndy.json diff --git a/res/trainers/0749.json b/res/trainers/trainer_beauty_cyndy_rematch_1.json similarity index 100% rename from res/trainers/0749.json rename to res/trainers/trainer_beauty_cyndy_rematch_1.json diff --git a/res/trainers/0750.json b/res/trainers/trainer_beauty_cyndy_rematch_2.json similarity index 100% rename from res/trainers/0750.json rename to res/trainers/trainer_beauty_cyndy_rematch_2.json diff --git a/res/trainers/0491.json b/res/trainers/trainer_beauty_devon.json similarity index 100% rename from res/trainers/0491.json rename to res/trainers/trainer_beauty_devon.json diff --git a/res/trainers/0550.json b/res/trainers/trainer_beauty_gabriella.json similarity index 100% rename from res/trainers/0550.json rename to res/trainers/trainer_beauty_gabriella.json diff --git a/res/trainers/0551.json b/res/trainers/trainer_beauty_harley.json similarity index 100% rename from res/trainers/0551.json rename to res/trainers/trainer_beauty_harley.json diff --git a/res/trainers/0348.json b/res/trainers/trainer_beauty_lindsay.json similarity index 100% rename from res/trainers/0348.json rename to res/trainers/trainer_beauty_lindsay.json diff --git a/res/trainers/0492.json b/res/trainers/trainer_beauty_nicola.json similarity index 100% rename from res/trainers/0492.json rename to res/trainers/trainer_beauty_nicola.json diff --git a/res/trainers/0290.json b/res/trainers/trainer_belle_and_pa_ava_and_matt.json similarity index 100% rename from res/trainers/0290.json rename to res/trainers/trainer_belle_and_pa_ava_and_matt.json diff --git a/res/trainers/0533.json b/res/trainers/trainer_belle_and_pa_beth_and_bob.json similarity index 100% rename from res/trainers/0533.json rename to res/trainers/trainer_belle_and_pa_beth_and_bob.json diff --git a/res/trainers/0076.json b/res/trainers/trainer_bird_keeper_alexandra.json similarity index 100% rename from res/trainers/0076.json rename to res/trainers/trainer_bird_keeper_alexandra.json diff --git a/res/trainers/0554.json b/res/trainers/trainer_bird_keeper_audrey.json similarity index 100% rename from res/trainers/0554.json rename to res/trainers/trainer_bird_keeper_audrey.json diff --git a/res/trainers/0638.json b/res/trainers/trainer_bird_keeper_audrey_rematch.json similarity index 100% rename from res/trainers/0638.json rename to res/trainers/trainer_bird_keeper_audrey_rematch.json diff --git a/res/trainers/0373.json b/res/trainers/trainer_bird_keeper_autumn.json similarity index 100% rename from res/trainers/0373.json rename to res/trainers/trainer_bird_keeper_autumn.json diff --git a/res/trainers/0074.json b/res/trainers/trainer_bird_keeper_brianna.json similarity index 100% rename from res/trainers/0074.json rename to res/trainers/trainer_bird_keeper_brianna.json diff --git a/res/trainers/0636.json b/res/trainers/trainer_bird_keeper_brianna_rematch_1.json similarity index 100% rename from res/trainers/0636.json rename to res/trainers/trainer_bird_keeper_brianna_rematch_1.json diff --git a/res/trainers/0637.json b/res/trainers/trainer_bird_keeper_brianna_rematch_2.json similarity index 100% rename from res/trainers/0637.json rename to res/trainers/trainer_bird_keeper_brianna_rematch_2.json diff --git a/res/trainers/0555.json b/res/trainers/trainer_bird_keeper_geneva.json similarity index 100% rename from res/trainers/0555.json rename to res/trainers/trainer_bird_keeper_geneva.json diff --git a/res/trainers/0233.json b/res/trainers/trainer_bird_keeper_hana.json similarity index 100% rename from res/trainers/0233.json rename to res/trainers/trainer_bird_keeper_hana.json diff --git a/res/trainers/0081.json b/res/trainers/trainer_bird_keeper_katherine.json similarity index 100% rename from res/trainers/0081.json rename to res/trainers/trainer_bird_keeper_katherine.json diff --git a/res/trainers/0556.json b/res/trainers/trainer_bird_keeper_krystal.json similarity index 100% rename from res/trainers/0556.json rename to res/trainers/trainer_bird_keeper_krystal.json diff --git a/res/trainers/0069.json b/res/trainers/trainer_black_belt_adam.json similarity index 100% rename from res/trainers/0069.json rename to res/trainers/trainer_black_belt_adam.json diff --git a/res/trainers/0313.json b/res/trainers/trainer_black_belt_carl.json similarity index 100% rename from res/trainers/0313.json rename to res/trainers/trainer_black_belt_carl.json diff --git a/res/trainers/0309.json b/res/trainers/trainer_black_belt_colby.json similarity index 100% rename from res/trainers/0309.json rename to res/trainers/trainer_black_belt_colby.json diff --git a/res/trainers/0310.json b/res/trainers/trainer_black_belt_darren.json similarity index 100% rename from res/trainers/0310.json rename to res/trainers/trainer_black_belt_darren.json diff --git a/res/trainers/0232.json b/res/trainers/trainer_black_belt_david.json similarity index 100% rename from res/trainers/0232.json rename to res/trainers/trainer_black_belt_david.json diff --git a/res/trainers/0587.json b/res/trainers/trainer_black_belt_davon.json similarity index 100% rename from res/trainers/0587.json rename to res/trainers/trainer_black_belt_davon.json diff --git a/res/trainers/0700.json b/res/trainers/trainer_black_belt_davon_rematch.json similarity index 100% rename from res/trainers/0700.json rename to res/trainers/trainer_black_belt_davon_rematch.json diff --git a/res/trainers/0128.json b/res/trainers/trainer_black_belt_derek.json similarity index 100% rename from res/trainers/0128.json rename to res/trainers/trainer_black_belt_derek.json diff --git a/res/trainers/0446.json b/res/trainers/trainer_black_belt_eddie.json similarity index 100% rename from res/trainers/0446.json rename to res/trainers/trainer_black_belt_eddie.json diff --git a/res/trainers/0127.json b/res/trainers/trainer_black_belt_gregory.json similarity index 100% rename from res/trainers/0127.json rename to res/trainers/trainer_black_belt_gregory.json diff --git a/res/trainers/0588.json b/res/trainers/trainer_black_belt_griffin.json similarity index 100% rename from res/trainers/0588.json rename to res/trainers/trainer_black_belt_griffin.json diff --git a/res/trainers/0590.json b/res/trainers/trainer_black_belt_jarrett.json similarity index 100% rename from res/trainers/0590.json rename to res/trainers/trainer_black_belt_jarrett.json diff --git a/res/trainers/0312.json b/res/trainers/trainer_black_belt_jeffery.json similarity index 100% rename from res/trainers/0312.json rename to res/trainers/trainer_black_belt_jeffery.json diff --git a/res/trainers/0445.json b/res/trainers/trainer_black_belt_kendal.json similarity index 100% rename from res/trainers/0445.json rename to res/trainers/trainer_black_belt_kendal.json diff --git a/res/trainers/0042.json b/res/trainers/trainer_black_belt_kyle.json similarity index 100% rename from res/trainers/0042.json rename to res/trainers/trainer_black_belt_kyle.json diff --git a/res/trainers/0148.json b/res/trainers/trainer_black_belt_luke.json similarity index 100% rename from res/trainers/0148.json rename to res/trainers/trainer_black_belt_luke.json diff --git a/res/trainers/0444.json b/res/trainers/trainer_black_belt_miles.json similarity index 100% rename from res/trainers/0444.json rename to res/trainers/trainer_black_belt_miles.json diff --git a/res/trainers/0129.json b/res/trainers/trainer_black_belt_nathaniel.json similarity index 100% rename from res/trainers/0129.json rename to res/trainers/trainer_black_belt_nathaniel.json diff --git a/res/trainers/0258.json b/res/trainers/trainer_black_belt_philip.json similarity index 100% rename from res/trainers/0258.json rename to res/trainers/trainer_black_belt_philip.json diff --git a/res/trainers/0699.json b/res/trainers/trainer_black_belt_philip_rematch.json similarity index 100% rename from res/trainers/0699.json rename to res/trainers/trainer_black_belt_philip_rematch.json diff --git a/res/trainers/0311.json b/res/trainers/trainer_black_belt_rafael.json similarity index 100% rename from res/trainers/0311.json rename to res/trainers/trainer_black_belt_rafael.json diff --git a/res/trainers/0589.json b/res/trainers/trainer_black_belt_ray.json similarity index 100% rename from res/trainers/0589.json rename to res/trainers/trainer_black_belt_ray.json diff --git a/res/trainers/0314.json b/res/trainers/trainer_black_belt_ricky.json similarity index 100% rename from res/trainers/0314.json rename to res/trainers/trainer_black_belt_ricky.json diff --git a/res/trainers/0079.json b/res/trainers/trainer_black_belt_sean.json similarity index 100% rename from res/trainers/0079.json rename to res/trainers/trainer_black_belt_sean.json diff --git a/res/trainers/0447.json b/res/trainers/trainer_black_belt_willie.json similarity index 100% rename from res/trainers/0447.json rename to res/trainers/trainer_black_belt_willie.json diff --git a/res/trainers/0046.json b/res/trainers/trainer_breeder_albert.json similarity index 100% rename from res/trainers/0046.json rename to res/trainers/trainer_breeder_albert.json diff --git a/res/trainers/0639.json b/res/trainers/trainer_breeder_albert_rematch_1.json similarity index 100% rename from res/trainers/0639.json rename to res/trainers/trainer_breeder_albert_rematch_1.json diff --git a/res/trainers/0640.json b/res/trainers/trainer_breeder_albert_rematch_2.json similarity index 100% rename from res/trainers/0640.json rename to res/trainers/trainer_breeder_albert_rematch_2.json diff --git a/res/trainers/0641.json b/res/trainers/trainer_breeder_albert_rematch_3.json similarity index 100% rename from res/trainers/0641.json rename to res/trainers/trainer_breeder_albert_rematch_3.json diff --git a/res/trainers/0057.json b/res/trainers/trainer_breeder_amber.json similarity index 100% rename from res/trainers/0057.json rename to res/trainers/trainer_breeder_amber.json diff --git a/res/trainers/0047.json b/res/trainers/trainer_breeder_jennifer.json similarity index 100% rename from res/trainers/0047.json rename to res/trainers/trainer_breeder_jennifer.json diff --git a/res/trainers/0642.json b/res/trainers/trainer_breeder_jennifer_rematch_1.json similarity index 100% rename from res/trainers/0642.json rename to res/trainers/trainer_breeder_jennifer_rematch_1.json diff --git a/res/trainers/0643.json b/res/trainers/trainer_breeder_jennifer_rematch_2.json similarity index 100% rename from res/trainers/0643.json rename to res/trainers/trainer_breeder_jennifer_rematch_2.json diff --git a/res/trainers/0644.json b/res/trainers/trainer_breeder_jennifer_rematch_3.json similarity index 100% rename from res/trainers/0644.json rename to res/trainers/trainer_breeder_jennifer_rematch_3.json diff --git a/res/trainers/0056.json b/res/trainers/trainer_breeder_kahlil.json similarity index 100% rename from res/trainers/0056.json rename to res/trainers/trainer_breeder_kahlil.json diff --git a/res/trainers/0537.json b/res/trainers/trainer_breeder_kaylee.json similarity index 100% rename from res/trainers/0537.json rename to res/trainers/trainer_breeder_kaylee.json diff --git a/res/trainers/0013.json b/res/trainers/trainer_bug_catcher_brandon.json similarity index 100% rename from res/trainers/0013.json rename to res/trainers/trainer_bug_catcher_brandon.json diff --git a/res/trainers/0712.json b/res/trainers/trainer_bug_catcher_brandon_rematch_1.json similarity index 100% rename from res/trainers/0712.json rename to res/trainers/trainer_bug_catcher_brandon_rematch_1.json diff --git a/res/trainers/0713.json b/res/trainers/trainer_bug_catcher_brandon_rematch_2.json similarity index 100% rename from res/trainers/0713.json rename to res/trainers/trainer_bug_catcher_brandon_rematch_2.json diff --git a/res/trainers/0714.json b/res/trainers/trainer_bug_catcher_brandon_rematch_3.json similarity index 100% rename from res/trainers/0714.json rename to res/trainers/trainer_bug_catcher_brandon_rematch_3.json diff --git a/res/trainers/0203.json b/res/trainers/trainer_bug_catcher_donald.json similarity index 100% rename from res/trainers/0203.json rename to res/trainers/trainer_bug_catcher_donald.json diff --git a/res/trainers/0201.json b/res/trainers/trainer_bug_catcher_jack.json similarity index 100% rename from res/trainers/0201.json rename to res/trainers/trainer_bug_catcher_jack.json diff --git a/res/trainers/0202.json b/res/trainers/trainer_bug_catcher_phillip.json similarity index 100% rename from res/trainers/0202.json rename to res/trainers/trainer_bug_catcher_phillip.json diff --git a/res/trainers/0538.json b/res/trainers/trainer_cameraman_darryl.json similarity index 100% rename from res/trainers/0538.json rename to res/trainers/trainer_cameraman_darryl.json diff --git a/res/trainers/0874.json b/res/trainers/trainer_cameraman_tevin.json similarity index 100% rename from res/trainers/0874.json rename to res/trainers/trainer_cameraman_tevin.json diff --git a/res/trainers/0875.json b/res/trainers/trainer_cameraman_tevin_rematch_1.json similarity index 100% rename from res/trainers/0875.json rename to res/trainers/trainer_cameraman_tevin_rematch_1.json diff --git a/res/trainers/0876.json b/res/trainers/trainer_cameraman_tevin_rematch_2.json similarity index 100% rename from res/trainers/0876.json rename to res/trainers/trainer_cameraman_tevin_rematch_2.json diff --git a/res/trainers/0906.json b/res/trainers/trainer_cameraman_tevin_rematch_3.json similarity index 100% rename from res/trainers/0906.json rename to res/trainers/trainer_cameraman_tevin_rematch_3.json diff --git a/res/trainers/0914.json b/res/trainers/trainer_cameraman_tevin_rematch_4.json similarity index 100% rename from res/trainers/0914.json rename to res/trainers/trainer_cameraman_tevin_rematch_4.json diff --git a/res/trainers/0034.json b/res/trainers/trainer_camper_anthony.json similarity index 100% rename from res/trainers/0034.json rename to res/trainers/trainer_camper_anthony.json diff --git a/res/trainers/0265.json b/res/trainers/trainer_camper_curtis.json similarity index 100% rename from res/trainers/0265.json rename to res/trainers/trainer_camper_curtis.json diff --git a/res/trainers/0379.json b/res/trainers/trainer_camper_diego.json similarity index 100% rename from res/trainers/0379.json rename to res/trainers/trainer_camper_diego.json diff --git a/res/trainers/0266.json b/res/trainers/trainer_camper_drew.json similarity index 100% rename from res/trainers/0266.json rename to res/trainers/trainer_camper_drew.json diff --git a/res/trainers/0016.json b/res/trainers/trainer_camper_jacob.json similarity index 100% rename from res/trainers/0016.json rename to res/trainers/trainer_camper_jacob.json diff --git a/res/trainers/0378.json b/res/trainers/trainer_camper_lawrence.json similarity index 100% rename from res/trainers/0378.json rename to res/trainers/trainer_camper_lawrence.json diff --git a/res/trainers/0380.json b/res/trainers/trainer_camper_parker.json similarity index 100% rename from res/trainers/0380.json rename to res/trainers/trainer_camper_parker.json diff --git a/res/trainers/0377.json b/res/trainers/trainer_camper_zackary.json similarity index 100% rename from res/trainers/0377.json rename to res/trainers/trainer_camper_zackary.json diff --git a/res/trainers/0645.json b/res/trainers/trainer_camper_zackary_rematch_1.json similarity index 100% rename from res/trainers/0645.json rename to res/trainers/trainer_camper_zackary_rematch_1.json diff --git a/res/trainers/0646.json b/res/trainers/trainer_camper_zackary_rematch_2.json similarity index 100% rename from res/trainers/0646.json rename to res/trainers/trainer_camper_zackary_rematch_2.json diff --git a/res/trainers/0647.json b/res/trainers/trainer_camper_zackary_rematch_3.json similarity index 100% rename from res/trainers/0647.json rename to res/trainers/trainer_camper_zackary_rematch_3.json diff --git a/res/trainers/0267.json b/res/trainers/trainer_champion_cynthia.json similarity index 100% rename from res/trainers/0267.json rename to res/trainers/trainer_champion_cynthia.json diff --git a/res/trainers/0870.json b/res/trainers/trainer_champion_cynthia_rematch.json similarity index 100% rename from res/trainers/0870.json rename to res/trainers/trainer_champion_cynthia_rematch.json diff --git a/res/trainers/0886.json b/res/trainers/trainer_clown_lee.json similarity index 100% rename from res/trainers/0886.json rename to res/trainers/trainer_clown_lee.json diff --git a/res/trainers/0887.json b/res/trainers/trainer_clown_lee_rematch_1.json similarity index 100% rename from res/trainers/0887.json rename to res/trainers/trainer_clown_lee_rematch_1.json diff --git a/res/trainers/0888.json b/res/trainers/trainer_clown_lee_rematch_2.json similarity index 100% rename from res/trainers/0888.json rename to res/trainers/trainer_clown_lee_rematch_2.json diff --git a/res/trainers/0910.json b/res/trainers/trainer_clown_lee_rematch_3.json similarity index 100% rename from res/trainers/0910.json rename to res/trainers/trainer_clown_lee_rematch_3.json diff --git a/res/trainers/0918.json b/res/trainers/trainer_clown_lee_rematch_4.json similarity index 100% rename from res/trainers/0918.json rename to res/trainers/trainer_clown_lee_rematch_4.json diff --git a/res/trainers/0273.json b/res/trainers/trainer_collector_brady.json similarity index 100% rename from res/trainers/0273.json rename to res/trainers/trainer_collector_brady.json diff --git a/res/trainers/0381.json b/res/trainers/trainer_collector_dean.json similarity index 100% rename from res/trainers/0381.json rename to res/trainers/trainer_collector_dean.json diff --git a/res/trainers/0272.json b/res/trainers/trainer_collector_douglas.json similarity index 100% rename from res/trainers/0272.json rename to res/trainers/trainer_collector_douglas.json diff --git a/res/trainers/0276.json b/res/trainers/trainer_collector_edwin.json similarity index 100% rename from res/trainers/0276.json rename to res/trainers/trainer_collector_edwin.json diff --git a/res/trainers/0539.json b/res/trainers/trainer_collector_eugene.json similarity index 100% rename from res/trainers/0539.json rename to res/trainers/trainer_collector_eugene.json diff --git a/res/trainers/0275.json b/res/trainers/trainer_collector_fernando.json similarity index 100% rename from res/trainers/0275.json rename to res/trainers/trainer_collector_fernando.json diff --git a/res/trainers/0274.json b/res/trainers/trainer_collector_ivan.json similarity index 100% rename from res/trainers/0274.json rename to res/trainers/trainer_collector_ivan.json diff --git a/res/trainers/0650.json b/res/trainers/trainer_collector_ivan_rematch.json similarity index 100% rename from res/trainers/0650.json rename to res/trainers/trainer_collector_ivan_rematch.json diff --git a/res/trainers/0382.json b/res/trainers/trainer_collector_jamal.json similarity index 100% rename from res/trainers/0382.json rename to res/trainers/trainer_collector_jamal.json diff --git a/res/trainers/0383.json b/res/trainers/trainer_collector_terry.json similarity index 100% rename from res/trainers/0383.json rename to res/trainers/trainer_collector_terry.json diff --git a/res/trainers/0407.json b/res/trainers/trainer_commander_jupiter_spear_pillar.json similarity index 100% rename from res/trainers/0407.json rename to res/trainers/trainer_commander_jupiter_spear_pillar.json diff --git a/res/trainers/0927.json b/res/trainers/trainer_commander_jupiter_stark_mountain.json similarity index 100% rename from res/trainers/0927.json rename to res/trainers/trainer_commander_jupiter_stark_mountain.json diff --git a/res/trainers/0406.json b/res/trainers/trainer_commander_jupiter_team_galactic_eterna_building.json similarity index 100% rename from res/trainers/0406.json rename to res/trainers/trainer_commander_jupiter_team_galactic_eterna_building.json diff --git a/res/trainers/0405.json b/res/trainers/trainer_commander_mars_lake_verity.json similarity index 100% rename from res/trainers/0405.json rename to res/trainers/trainer_commander_mars_lake_verity.json diff --git a/res/trainers/0528.json b/res/trainers/trainer_commander_mars_spear_pillar.json similarity index 100% rename from res/trainers/0528.json rename to res/trainers/trainer_commander_mars_spear_pillar.json diff --git a/res/trainers/0926.json b/res/trainers/trainer_commander_mars_stark_mountain.json similarity index 100% rename from res/trainers/0926.json rename to res/trainers/trainer_commander_mars_stark_mountain.json diff --git a/res/trainers/0295.json b/res/trainers/trainer_commander_mars_valley_windworks.json similarity index 100% rename from res/trainers/0295.json rename to res/trainers/trainer_commander_mars_valley_windworks.json diff --git a/res/trainers/0409.json b/res/trainers/trainer_commander_saturn_galactic_hq.json similarity index 100% rename from res/trainers/0409.json rename to res/trainers/trainer_commander_saturn_galactic_hq.json diff --git a/res/trainers/0408.json b/res/trainers/trainer_commander_saturn_valor_cavern.json similarity index 100% rename from res/trainers/0408.json rename to res/trainers/trainer_commander_saturn_valor_cavern.json diff --git a/res/trainers/0048.json b/res/trainers/trainer_cowgirl_shelley.json similarity index 100% rename from res/trainers/0048.json rename to res/trainers/trainer_cowgirl_shelley.json diff --git a/res/trainers/0025.json b/res/trainers/trainer_cyclist_axel.json similarity index 100% rename from res/trainers/0025.json rename to res/trainers/trainer_cyclist_axel.json diff --git a/res/trainers/0026.json b/res/trainers/trainer_cyclist_james.json similarity index 100% rename from res/trainers/0026.json rename to res/trainers/trainer_cyclist_james.json diff --git a/res/trainers/0027.json b/res/trainers/trainer_cyclist_john.json similarity index 100% rename from res/trainers/0027.json rename to res/trainers/trainer_cyclist_john.json diff --git a/res/trainers/0653.json b/res/trainers/trainer_cyclist_john_rematch_1.json similarity index 100% rename from res/trainers/0653.json rename to res/trainers/trainer_cyclist_john_rematch_1.json diff --git a/res/trainers/0654.json b/res/trainers/trainer_cyclist_john_rematch_2.json similarity index 100% rename from res/trainers/0654.json rename to res/trainers/trainer_cyclist_john_rematch_2.json diff --git a/res/trainers/0655.json b/res/trainers/trainer_cyclist_john_rematch_3.json similarity index 100% rename from res/trainers/0655.json rename to res/trainers/trainer_cyclist_john_rematch_3.json diff --git a/res/trainers/0031.json b/res/trainers/trainer_cyclist_kayla.json similarity index 100% rename from res/trainers/0031.json rename to res/trainers/trainer_cyclist_kayla.json diff --git a/res/trainers/0656.json b/res/trainers/trainer_cyclist_kayla_rematch_1.json similarity index 100% rename from res/trainers/0656.json rename to res/trainers/trainer_cyclist_kayla_rematch_1.json diff --git a/res/trainers/0657.json b/res/trainers/trainer_cyclist_kayla_rematch_2.json similarity index 100% rename from res/trainers/0657.json rename to res/trainers/trainer_cyclist_kayla_rematch_2.json diff --git a/res/trainers/0658.json b/res/trainers/trainer_cyclist_kayla_rematch_3.json similarity index 100% rename from res/trainers/0658.json rename to res/trainers/trainer_cyclist_kayla_rematch_3.json diff --git a/res/trainers/0029.json b/res/trainers/trainer_cyclist_megan.json similarity index 100% rename from res/trainers/0029.json rename to res/trainers/trainer_cyclist_megan.json diff --git a/res/trainers/0030.json b/res/trainers/trainer_cyclist_nicole.json similarity index 100% rename from res/trainers/0030.json rename to res/trainers/trainer_cyclist_nicole.json diff --git a/res/trainers/0032.json b/res/trainers/trainer_cyclist_rachel.json similarity index 100% rename from res/trainers/0032.json rename to res/trainers/trainer_cyclist_rachel.json diff --git a/res/trainers/0028.json b/res/trainers/trainer_cyclist_ryan.json similarity index 100% rename from res/trainers/0028.json rename to res/trainers/trainer_cyclist_ryan.json diff --git a/res/trainers/0616.json b/res/trainers/trainer_dawn_jubilife_city_chimchar.json similarity index 100% rename from res/trainers/0616.json rename to res/trainers/trainer_dawn_jubilife_city_chimchar.json diff --git a/res/trainers/0617.json b/res/trainers/trainer_dawn_jubilife_city_piplup.json similarity index 100% rename from res/trainers/0617.json rename to res/trainers/trainer_dawn_jubilife_city_piplup.json diff --git a/res/trainers/0618.json b/res/trainers/trainer_dawn_jubilife_city_turtwig.json similarity index 100% rename from res/trainers/0618.json rename to res/trainers/trainer_dawn_jubilife_city_turtwig.json diff --git a/res/trainers/0624.json b/res/trainers/trainer_dawn_veilstone_city_chimchar.json similarity index 100% rename from res/trainers/0624.json rename to res/trainers/trainer_dawn_veilstone_city_chimchar.json diff --git a/res/trainers/0625.json b/res/trainers/trainer_dawn_veilstone_city_piplup.json similarity index 100% rename from res/trainers/0625.json rename to res/trainers/trainer_dawn_veilstone_city_piplup.json diff --git a/res/trainers/0626.json b/res/trainers/trainer_dawn_veilstone_city_turtwig.json similarity index 100% rename from res/trainers/0626.json rename to res/trainers/trainer_dawn_veilstone_city_turtwig.json diff --git a/res/trainers/0237.json b/res/trainers/trainer_double_team_al_and_kay.json similarity index 100% rename from res/trainers/0237.json rename to res/trainers/trainer_double_team_al_and_kay.json diff --git a/res/trainers/0236.json b/res/trainers/trainer_double_team_jo_and_pat.json similarity index 100% rename from res/trainers/0236.json rename to res/trainers/trainer_double_team_jo_and_pat.json diff --git a/res/trainers/0075.json b/res/trainers/trainer_double_team_zac_and_jen.json similarity index 100% rename from res/trainers/0075.json rename to res/trainers/trainer_double_team_zac_and_jen.json diff --git a/res/trainers/0231.json b/res/trainers/trainer_dragon_tamer_clinton.json similarity index 100% rename from res/trainers/0231.json rename to res/trainers/trainer_dragon_tamer_clinton.json diff --git a/res/trainers/0558.json b/res/trainers/trainer_dragon_tamer_darien.json similarity index 100% rename from res/trainers/0558.json rename to res/trainers/trainer_dragon_tamer_darien.json diff --git a/res/trainers/0561.json b/res/trainers/trainer_dragon_tamer_drake.json similarity index 100% rename from res/trainers/0561.json rename to res/trainers/trainer_dragon_tamer_drake.json diff --git a/res/trainers/0557.json b/res/trainers/trainer_dragon_tamer_geoffrey.json similarity index 100% rename from res/trainers/0557.json rename to res/trainers/trainer_dragon_tamer_geoffrey.json diff --git a/res/trainers/0662.json b/res/trainers/trainer_dragon_tamer_geoffrey_rematch.json similarity index 100% rename from res/trainers/0662.json rename to res/trainers/trainer_dragon_tamer_geoffrey_rematch.json diff --git a/res/trainers/0277.json b/res/trainers/trainer_dragon_tamer_hayden.json similarity index 100% rename from res/trainers/0277.json rename to res/trainers/trainer_dragon_tamer_hayden.json diff --git a/res/trainers/0661.json b/res/trainers/trainer_dragon_tamer_hayden_rematch.json similarity index 100% rename from res/trainers/0661.json rename to res/trainers/trainer_dragon_tamer_hayden_rematch.json diff --git a/res/trainers/0386.json b/res/trainers/trainer_dragon_tamer_joe.json similarity index 100% rename from res/trainers/0386.json rename to res/trainers/trainer_dragon_tamer_joe.json diff --git a/res/trainers/0559.json b/res/trainers/trainer_dragon_tamer_keegan.json similarity index 100% rename from res/trainers/0559.json rename to res/trainers/trainer_dragon_tamer_keegan.json diff --git a/res/trainers/0562.json b/res/trainers/trainer_dragon_tamer_kenny.json similarity index 100% rename from res/trainers/0562.json rename to res/trainers/trainer_dragon_tamer_kenny.json diff --git a/res/trainers/0230.json b/res/trainers/trainer_dragon_tamer_ondrej.json similarity index 100% rename from res/trainers/0230.json rename to res/trainers/trainer_dragon_tamer_ondrej.json diff --git a/res/trainers/0073.json b/res/trainers/trainer_dragon_tamer_patrick.json similarity index 100% rename from res/trainers/0073.json rename to res/trainers/trainer_dragon_tamer_patrick.json diff --git a/res/trainers/0659.json b/res/trainers/trainer_dragon_tamer_patrick_rematch_1.json similarity index 100% rename from res/trainers/0659.json rename to res/trainers/trainer_dragon_tamer_patrick_rematch_1.json diff --git a/res/trainers/0660.json b/res/trainers/trainer_dragon_tamer_patrick_rematch_2.json similarity index 100% rename from res/trainers/0660.json rename to res/trainers/trainer_dragon_tamer_patrick_rematch_2.json diff --git a/res/trainers/0560.json b/res/trainers/trainer_dragon_tamer_stanley.json similarity index 100% rename from res/trainers/0560.json rename to res/trainers/trainer_dragon_tamer_stanley.json diff --git a/res/trainers/0261.json b/res/trainers/trainer_elite_four_aaron.json similarity index 100% rename from res/trainers/0261.json rename to res/trainers/trainer_elite_four_aaron.json diff --git a/res/trainers/0866.json b/res/trainers/trainer_elite_four_aaron_rematch.json similarity index 100% rename from res/trainers/0866.json rename to res/trainers/trainer_elite_four_aaron_rematch.json diff --git a/res/trainers/0262.json b/res/trainers/trainer_elite_four_bertha.json similarity index 100% rename from res/trainers/0262.json rename to res/trainers/trainer_elite_four_bertha.json diff --git a/res/trainers/0867.json b/res/trainers/trainer_elite_four_bertha_rematch.json similarity index 100% rename from res/trainers/0867.json rename to res/trainers/trainer_elite_four_bertha_rematch.json diff --git a/res/trainers/0263.json b/res/trainers/trainer_elite_four_flint.json similarity index 100% rename from res/trainers/0263.json rename to res/trainers/trainer_elite_four_flint.json diff --git a/res/trainers/0922.json b/res/trainers/trainer_elite_four_flint_fight_area.json similarity index 100% rename from res/trainers/0922.json rename to res/trainers/trainer_elite_four_flint_fight_area.json diff --git a/res/trainers/0868.json b/res/trainers/trainer_elite_four_flint_rematch.json similarity index 100% rename from res/trainers/0868.json rename to res/trainers/trainer_elite_four_flint_rematch.json diff --git a/res/trainers/0264.json b/res/trainers/trainer_elite_four_lucian.json similarity index 100% rename from res/trainers/0264.json rename to res/trainers/trainer_elite_four_lucian.json diff --git a/res/trainers/0869.json b/res/trainers/trainer_elite_four_lucian_rematch.json similarity index 100% rename from res/trainers/0869.json rename to res/trainers/trainer_elite_four_lucian_rematch.json diff --git a/res/trainers/0173.json b/res/trainers/trainer_fisherman_alec.json similarity index 100% rename from res/trainers/0173.json rename to res/trainers/trainer_fisherman_alec.json diff --git a/res/trainers/0686.json b/res/trainers/trainer_fisherman_alec_rematch.json similarity index 100% rename from res/trainers/0686.json rename to res/trainers/trainer_fisherman_alec_rematch.json diff --git a/res/trainers/0022.json b/res/trainers/trainer_fisherman_andrew.json similarity index 100% rename from res/trainers/0022.json rename to res/trainers/trainer_fisherman_andrew.json diff --git a/res/trainers/0172.json b/res/trainers/trainer_fisherman_brett.json similarity index 100% rename from res/trainers/0172.json rename to res/trainers/trainer_fisherman_brett.json diff --git a/res/trainers/0043.json b/res/trainers/trainer_fisherman_cody.json similarity index 100% rename from res/trainers/0043.json rename to res/trainers/trainer_fisherman_cody.json diff --git a/res/trainers/0175.json b/res/trainers/trainer_fisherman_cole.json similarity index 100% rename from res/trainers/0175.json rename to res/trainers/trainer_fisherman_cole.json diff --git a/res/trainers/0168.json b/res/trainers/trainer_fisherman_cory.json similarity index 100% rename from res/trainers/0168.json rename to res/trainers/trainer_fisherman_cory.json diff --git a/res/trainers/0293.json b/res/trainers/trainer_fisherman_erick.json similarity index 100% rename from res/trainers/0293.json rename to res/trainers/trainer_fisherman_erick.json diff --git a/res/trainers/0174.json b/res/trainers/trainer_fisherman_george.json similarity index 100% rename from res/trainers/0174.json rename to res/trainers/trainer_fisherman_george.json diff --git a/res/trainers/0023.json b/res/trainers/trainer_fisherman_joseph.json similarity index 100% rename from res/trainers/0023.json rename to res/trainers/trainer_fisherman_joseph.json diff --git a/res/trainers/0683.json b/res/trainers/trainer_fisherman_joseph_rematch_1.json similarity index 100% rename from res/trainers/0683.json rename to res/trainers/trainer_fisherman_joseph_rematch_1.json diff --git a/res/trainers/0684.json b/res/trainers/trainer_fisherman_joseph_rematch_2.json similarity index 100% rename from res/trainers/0684.json rename to res/trainers/trainer_fisherman_joseph_rematch_2.json diff --git a/res/trainers/0092.json b/res/trainers/trainer_fisherman_josh.json similarity index 100% rename from res/trainers/0092.json rename to res/trainers/trainer_fisherman_josh.json diff --git a/res/trainers/0091.json b/res/trainers/trainer_fisherman_juan.json similarity index 100% rename from res/trainers/0091.json rename to res/trainers/trainer_fisherman_juan.json diff --git a/res/trainers/0111.json b/res/trainers/trainer_fisherman_kenneth.json similarity index 100% rename from res/trainers/0111.json rename to res/trainers/trainer_fisherman_kenneth.json diff --git a/res/trainers/0154.json b/res/trainers/trainer_fisherman_luc.json similarity index 100% rename from res/trainers/0154.json rename to res/trainers/trainer_fisherman_luc.json diff --git a/res/trainers/0153.json b/res/trainers/trainer_fisherman_miguel.json similarity index 100% rename from res/trainers/0153.json rename to res/trainers/trainer_fisherman_miguel.json diff --git a/res/trainers/0685.json b/res/trainers/trainer_fisherman_miguel_rematch.json similarity index 100% rename from res/trainers/0685.json rename to res/trainers/trainer_fisherman_miguel_rematch.json diff --git a/res/trainers/0093.json b/res/trainers/trainer_fisherman_travis.json similarity index 100% rename from res/trainers/0093.json rename to res/trainers/trainer_fisherman_travis.json diff --git a/res/trainers/0401.json b/res/trainers/trainer_fisherman_walter.json similarity index 100% rename from res/trainers/0401.json rename to res/trainers/trainer_fisherman_walter.json diff --git a/res/trainers/0024.json b/res/trainers/trainer_fisherman_zachary.json similarity index 100% rename from res/trainers/0024.json rename to res/trainers/trainer_fisherman_zachary.json diff --git a/res/trainers/0913.json b/res/trainers/trainer_galactic_boss_cyrus_celestic_town_ruins.json similarity index 100% rename from res/trainers/0913.json rename to res/trainers/trainer_galactic_boss_cyrus_celestic_town_ruins.json diff --git a/res/trainers/0404.json b/res/trainers/trainer_galactic_boss_cyrus_distortion_world.json similarity index 100% rename from res/trainers/0404.json rename to res/trainers/trainer_galactic_boss_cyrus_distortion_world.json diff --git a/res/trainers/0403.json b/res/trainers/trainer_galactic_boss_cyrus_galactic_hq.json similarity index 100% rename from res/trainers/0403.json rename to res/trainers/trainer_galactic_boss_cyrus_galactic_hq.json diff --git a/res/trainers/0416.json b/res/trainers/trainer_galactic_grunt_celestic_town.json similarity index 100% rename from res/trainers/0416.json rename to res/trainers/trainer_galactic_grunt_celestic_town.json diff --git a/res/trainers/0296.json b/res/trainers/trainer_galactic_grunt_floaroma_meadow_1.json similarity index 100% rename from res/trainers/0296.json rename to res/trainers/trainer_galactic_grunt_floaroma_meadow_1.json diff --git a/res/trainers/0297.json b/res/trainers/trainer_galactic_grunt_floaroma_meadow_2.json similarity index 100% rename from res/trainers/0297.json rename to res/trainers/trainer_galactic_grunt_floaroma_meadow_2.json diff --git a/res/trainers/0428.json b/res/trainers/trainer_galactic_grunt_galactic_hq_1f.json similarity index 100% rename from res/trainers/0428.json rename to res/trainers/trainer_galactic_grunt_galactic_hq_1f.json diff --git a/res/trainers/0510.json b/res/trainers/trainer_galactic_grunt_galactic_hq_2f_1.json similarity index 100% rename from res/trainers/0510.json rename to res/trainers/trainer_galactic_grunt_galactic_hq_2f_1.json diff --git a/res/trainers/0513.json b/res/trainers/trainer_galactic_grunt_galactic_hq_2f_2.json similarity index 100% rename from res/trainers/0513.json rename to res/trainers/trainer_galactic_grunt_galactic_hq_2f_2.json diff --git a/res/trainers/0430.json b/res/trainers/trainer_galactic_grunt_galactic_hq_2f_3.json similarity index 100% rename from res/trainers/0430.json rename to res/trainers/trainer_galactic_grunt_galactic_hq_2f_3.json diff --git a/res/trainers/0509.json b/res/trainers/trainer_galactic_grunt_galactic_hq_3f_1.json similarity index 100% rename from res/trainers/0509.json rename to res/trainers/trainer_galactic_grunt_galactic_hq_3f_1.json diff --git a/res/trainers/0512.json b/res/trainers/trainer_galactic_grunt_galactic_hq_3f_2.json similarity index 100% rename from res/trainers/0512.json rename to res/trainers/trainer_galactic_grunt_galactic_hq_3f_2.json diff --git a/res/trainers/0514.json b/res/trainers/trainer_galactic_grunt_galactic_hq_3f_3.json similarity index 100% rename from res/trainers/0514.json rename to res/trainers/trainer_galactic_grunt_galactic_hq_3f_3.json diff --git a/res/trainers/0522.json b/res/trainers/trainer_galactic_grunt_galactic_hq_3f_4.json similarity index 100% rename from res/trainers/0522.json rename to res/trainers/trainer_galactic_grunt_galactic_hq_3f_4.json diff --git a/res/trainers/0507.json b/res/trainers/trainer_galactic_grunt_galactic_hq_b2f_1.json similarity index 100% rename from res/trainers/0507.json rename to res/trainers/trainer_galactic_grunt_galactic_hq_b2f_1.json diff --git a/res/trainers/0508.json b/res/trainers/trainer_galactic_grunt_galactic_hq_b2f_2.json similarity index 100% rename from res/trainers/0508.json rename to res/trainers/trainer_galactic_grunt_galactic_hq_b2f_2.json diff --git a/res/trainers/0835.json b/res/trainers/trainer_galactic_grunt_iron_island_1.json similarity index 100% rename from res/trainers/0835.json rename to res/trainers/trainer_galactic_grunt_iron_island_1.json diff --git a/res/trainers/0836.json b/res/trainers/trainer_galactic_grunt_iron_island_2.json similarity index 100% rename from res/trainers/0836.json rename to res/trainers/trainer_galactic_grunt_iron_island_2.json diff --git a/res/trainers/0414.json b/res/trainers/trainer_galactic_grunt_jubilife_city_1.json similarity index 100% rename from res/trainers/0414.json rename to res/trainers/trainer_galactic_grunt_jubilife_city_1.json diff --git a/res/trainers/0415.json b/res/trainers/trainer_galactic_grunt_jubilife_city_2.json similarity index 100% rename from res/trainers/0415.json rename to res/trainers/trainer_galactic_grunt_jubilife_city_2.json diff --git a/res/trainers/0417.json b/res/trainers/trainer_galactic_grunt_lake_valor_1.json similarity index 100% rename from res/trainers/0417.json rename to res/trainers/trainer_galactic_grunt_lake_valor_1.json diff --git a/res/trainers/0418.json b/res/trainers/trainer_galactic_grunt_lake_valor_2.json similarity index 100% rename from res/trainers/0418.json rename to res/trainers/trainer_galactic_grunt_lake_valor_2.json diff --git a/res/trainers/0425.json b/res/trainers/trainer_galactic_grunt_lake_valor_3.json similarity index 100% rename from res/trainers/0425.json rename to res/trainers/trainer_galactic_grunt_lake_valor_3.json diff --git a/res/trainers/0419.json b/res/trainers/trainer_galactic_grunt_lake_verity_1.json similarity index 100% rename from res/trainers/0419.json rename to res/trainers/trainer_galactic_grunt_lake_verity_1.json diff --git a/res/trainers/0426.json b/res/trainers/trainer_galactic_grunt_lake_verity_2.json similarity index 100% rename from res/trainers/0426.json rename to res/trainers/trainer_galactic_grunt_lake_verity_2.json diff --git a/res/trainers/0420.json b/res/trainers/trainer_galactic_grunt_lake_verity_3.json similarity index 100% rename from res/trainers/0420.json rename to res/trainers/trainer_galactic_grunt_lake_verity_3.json diff --git a/res/trainers/0427.json b/res/trainers/trainer_galactic_grunt_lake_verity_4.json similarity index 100% rename from res/trainers/0427.json rename to res/trainers/trainer_galactic_grunt_lake_verity_4.json diff --git a/res/trainers/0515.json b/res/trainers/trainer_galactic_grunt_mt_coronet_3f_1.json similarity index 100% rename from res/trainers/0515.json rename to res/trainers/trainer_galactic_grunt_mt_coronet_3f_1.json diff --git a/res/trainers/0516.json b/res/trainers/trainer_galactic_grunt_mt_coronet_4f_1.json similarity index 100% rename from res/trainers/0516.json rename to res/trainers/trainer_galactic_grunt_mt_coronet_4f_1.json diff --git a/res/trainers/0517.json b/res/trainers/trainer_galactic_grunt_mt_coronet_4f_2.json similarity index 100% rename from res/trainers/0517.json rename to res/trainers/trainer_galactic_grunt_mt_coronet_4f_2.json diff --git a/res/trainers/0520.json b/res/trainers/trainer_galactic_grunt_mt_coronet_5f_1.json similarity index 100% rename from res/trainers/0520.json rename to res/trainers/trainer_galactic_grunt_mt_coronet_5f_1.json diff --git a/res/trainers/0525.json b/res/trainers/trainer_galactic_grunt_mt_coronet_5f_2.json similarity index 100% rename from res/trainers/0525.json rename to res/trainers/trainer_galactic_grunt_mt_coronet_5f_2.json diff --git a/res/trainers/0526.json b/res/trainers/trainer_galactic_grunt_mt_coronet_6f.json similarity index 100% rename from res/trainers/0526.json rename to res/trainers/trainer_galactic_grunt_mt_coronet_6f.json diff --git a/res/trainers/0523.json b/res/trainers/trainer_galactic_grunt_mt_coronet__3f_1.json similarity index 100% rename from res/trainers/0523.json rename to res/trainers/trainer_galactic_grunt_mt_coronet__3f_1.json diff --git a/res/trainers/0518.json b/res/trainers/trainer_galactic_grunt_mt_coronet_tunnel_room_1.json similarity index 100% rename from res/trainers/0518.json rename to res/trainers/trainer_galactic_grunt_mt_coronet_tunnel_room_1.json diff --git a/res/trainers/0519.json b/res/trainers/trainer_galactic_grunt_mt_coronet_tunnel_room_2.json similarity index 100% rename from res/trainers/0519.json rename to res/trainers/trainer_galactic_grunt_mt_coronet_tunnel_room_2.json diff --git a/res/trainers/0524.json b/res/trainers/trainer_galactic_grunt_mt_coronet_tunnel_room_3.json similarity index 100% rename from res/trainers/0524.json rename to res/trainers/trainer_galactic_grunt_mt_coronet_tunnel_room_3.json diff --git a/res/trainers/0521.json b/res/trainers/trainer_galactic_grunt_spear_pillar_1.json similarity index 100% rename from res/trainers/0521.json rename to res/trainers/trainer_galactic_grunt_spear_pillar_1.json diff --git a/res/trainers/0527.json b/res/trainers/trainer_galactic_grunt_spear_pillar_2.json similarity index 100% rename from res/trainers/0527.json rename to res/trainers/trainer_galactic_grunt_spear_pillar_2.json diff --git a/res/trainers/0410.json b/res/trainers/trainer_galactic_grunt_team_galactic_eterna_building_1f_1.json similarity index 100% rename from res/trainers/0410.json rename to res/trainers/trainer_galactic_grunt_team_galactic_eterna_building_1f_1.json diff --git a/res/trainers/0421.json b/res/trainers/trainer_galactic_grunt_team_galactic_eterna_building_1f_2.json similarity index 100% rename from res/trainers/0421.json rename to res/trainers/trainer_galactic_grunt_team_galactic_eterna_building_1f_2.json diff --git a/res/trainers/0412.json b/res/trainers/trainer_galactic_grunt_team_galactic_eterna_building_2f_1.json similarity index 100% rename from res/trainers/0412.json rename to res/trainers/trainer_galactic_grunt_team_galactic_eterna_building_2f_1.json diff --git a/res/trainers/0422.json b/res/trainers/trainer_galactic_grunt_team_galactic_eterna_building_2f_2.json similarity index 100% rename from res/trainers/0422.json rename to res/trainers/trainer_galactic_grunt_team_galactic_eterna_building_2f_2.json diff --git a/res/trainers/0423.json b/res/trainers/trainer_galactic_grunt_team_galactic_eterna_building_3f.json similarity index 100% rename from res/trainers/0423.json rename to res/trainers/trainer_galactic_grunt_team_galactic_eterna_building_3f.json diff --git a/res/trainers/0843.json b/res/trainers/trainer_galactic_grunt_valley_windworks_1.json similarity index 100% rename from res/trainers/0843.json rename to res/trainers/trainer_galactic_grunt_valley_windworks_1.json diff --git a/res/trainers/0298.json b/res/trainers/trainer_galactic_grunt_valley_windworks_2.json similarity index 100% rename from res/trainers/0298.json rename to res/trainers/trainer_galactic_grunt_valley_windworks_2.json diff --git a/res/trainers/0299.json b/res/trainers/trainer_galactic_grunt_valley_windworks_3.json similarity index 100% rename from res/trainers/0299.json rename to res/trainers/trainer_galactic_grunt_valley_windworks_3.json diff --git a/res/trainers/0847.json b/res/trainers/trainer_galactic_grunt_valor_lakefront.json similarity index 100% rename from res/trainers/0847.json rename to res/trainers/trainer_galactic_grunt_valor_lakefront.json diff --git a/res/trainers/0848.json b/res/trainers/trainer_galactic_grunt_veilstone_city_1.json similarity index 100% rename from res/trainers/0848.json rename to res/trainers/trainer_galactic_grunt_veilstone_city_1.json diff --git a/res/trainers/0849.json b/res/trainers/trainer_galactic_grunt_veilstone_city_2.json similarity index 100% rename from res/trainers/0849.json rename to res/trainers/trainer_galactic_grunt_veilstone_city_2.json diff --git a/res/trainers/0084.json b/res/trainers/trainer_gentleman_jeremy.json similarity index 100% rename from res/trainers/0084.json rename to res/trainers/trainer_gentleman_jeremy.json diff --git a/res/trainers/0691.json b/res/trainers/trainer_gentleman_jeremy_rematch_1.json similarity index 100% rename from res/trainers/0691.json rename to res/trainers/trainer_gentleman_jeremy_rematch_1.json diff --git a/res/trainers/0692.json b/res/trainers/trainer_gentleman_jeremy_rematch_2.json similarity index 100% rename from res/trainers/0692.json rename to res/trainers/trainer_gentleman_jeremy_rematch_2.json diff --git a/res/trainers/0693.json b/res/trainers/trainer_gentleman_jeremy_rematch_3.json similarity index 100% rename from res/trainers/0693.json rename to res/trainers/trainer_gentleman_jeremy_rematch_3.json diff --git a/res/trainers/0542.json b/res/trainers/trainer_gentleman_leonardo.json similarity index 100% rename from res/trainers/0542.json rename to res/trainers/trainer_gentleman_leonardo.json diff --git a/res/trainers/0877.json b/res/trainers/trainer_guitarist_arturo.json similarity index 100% rename from res/trainers/0877.json rename to res/trainers/trainer_guitarist_arturo.json diff --git a/res/trainers/0878.json b/res/trainers/trainer_guitarist_arturo_rematch_1.json similarity index 100% rename from res/trainers/0878.json rename to res/trainers/trainer_guitarist_arturo_rematch_1.json diff --git a/res/trainers/0879.json b/res/trainers/trainer_guitarist_arturo_rematch_2.json similarity index 100% rename from res/trainers/0879.json rename to res/trainers/trainer_guitarist_arturo_rematch_2.json diff --git a/res/trainers/0907.json b/res/trainers/trainer_guitarist_arturo_rematch_3.json similarity index 100% rename from res/trainers/0907.json rename to res/trainers/trainer_guitarist_arturo_rematch_3.json diff --git a/res/trainers/0915.json b/res/trainers/trainer_guitarist_arturo_rematch_4.json similarity index 100% rename from res/trainers/0915.json rename to res/trainers/trainer_guitarist_arturo_rematch_4.json diff --git a/res/trainers/0301.json b/res/trainers/trainer_guitarist_jerry.json similarity index 100% rename from res/trainers/0301.json rename to res/trainers/trainer_guitarist_jerry.json diff --git a/res/trainers/0303.json b/res/trainers/trainer_guitarist_lonnie.json similarity index 100% rename from res/trainers/0303.json rename to res/trainers/trainer_guitarist_lonnie.json diff --git a/res/trainers/0302.json b/res/trainers/trainer_guitarist_preston.json similarity index 100% rename from res/trainers/0302.json rename to res/trainers/trainer_guitarist_preston.json diff --git a/res/trainers/0300.json b/res/trainers/trainer_guitarist_tony.json similarity index 100% rename from res/trainers/0300.json rename to res/trainers/trainer_guitarist_tony.json diff --git a/res/trainers/0694.json b/res/trainers/trainer_guitarist_tony_rematch.json similarity index 100% rename from res/trainers/0694.json rename to res/trainers/trainer_guitarist_tony_rematch.json diff --git a/res/trainers/0040.json b/res/trainers/trainer_hiker_alexander.json similarity index 100% rename from res/trainers/0040.json rename to res/trainers/trainer_hiker_alexander.json diff --git a/res/trainers/0452.json b/res/trainers/trainer_hiker_damon.json similarity index 100% rename from res/trainers/0452.json rename to res/trainers/trainer_hiker_damon.json diff --git a/res/trainers/0018.json b/res/trainers/trainer_hiker_daniel.json similarity index 100% rename from res/trainers/0018.json rename to res/trainers/trainer_hiker_daniel.json diff --git a/res/trainers/0041.json b/res/trainers/trainer_hiker_jonathan.json similarity index 100% rename from res/trainers/0041.json rename to res/trainers/trainer_hiker_jonathan.json diff --git a/res/trainers/0037.json b/res/trainers/trainer_hiker_justin.json similarity index 100% rename from res/trainers/0037.json rename to res/trainers/trainer_hiker_justin.json diff --git a/res/trainers/0036.json b/res/trainers/trainer_hiker_kevin.json similarity index 100% rename from res/trainers/0036.json rename to res/trainers/trainer_hiker_kevin.json diff --git a/res/trainers/0455.json b/res/trainers/trainer_hiker_lorenzo.json similarity index 100% rename from res/trainers/0455.json rename to res/trainers/trainer_hiker_lorenzo.json diff --git a/res/trainers/0326.json b/res/trainers/trainer_hiker_louis.json similarity index 100% rename from res/trainers/0326.json rename to res/trainers/trainer_hiker_louis.json diff --git a/res/trainers/0453.json b/res/trainers/trainer_hiker_maurice.json similarity index 100% rename from res/trainers/0453.json rename to res/trainers/trainer_hiker_maurice.json diff --git a/res/trainers/0019.json b/res/trainers/trainer_hiker_nicholas.json similarity index 100% rename from res/trainers/0019.json rename to res/trainers/trainer_hiker_nicholas.json diff --git a/res/trainers/0454.json b/res/trainers/trainer_hiker_reginald.json similarity index 100% rename from res/trainers/0454.json rename to res/trainers/trainer_hiker_reginald.json diff --git a/res/trainers/0039.json b/res/trainers/trainer_hiker_robert.json similarity index 100% rename from res/trainers/0039.json rename to res/trainers/trainer_hiker_robert.json diff --git a/res/trainers/0451.json b/res/trainers/trainer_hiker_theodore.json similarity index 100% rename from res/trainers/0451.json rename to res/trainers/trainer_hiker_theodore.json diff --git a/res/trainers/0709.json b/res/trainers/trainer_hiker_theodore_rematch_1.json similarity index 100% rename from res/trainers/0709.json rename to res/trainers/trainer_hiker_theodore_rematch_1.json diff --git a/res/trainers/0710.json b/res/trainers/trainer_hiker_theodore_rematch_2.json similarity index 100% rename from res/trainers/0710.json rename to res/trainers/trainer_hiker_theodore_rematch_2.json diff --git a/res/trainers/0711.json b/res/trainers/trainer_hiker_theodore_rematch_3.json similarity index 100% rename from res/trainers/0711.json rename to res/trainers/trainer_hiker_theodore_rematch_3.json diff --git a/res/trainers/0880.json b/res/trainers/trainer_idol_grace.json similarity index 100% rename from res/trainers/0880.json rename to res/trainers/trainer_idol_grace.json diff --git a/res/trainers/0881.json b/res/trainers/trainer_idol_grace_rematch_1.json similarity index 100% rename from res/trainers/0881.json rename to res/trainers/trainer_idol_grace_rematch_1.json diff --git a/res/trainers/0882.json b/res/trainers/trainer_idol_grace_rematch_2.json similarity index 100% rename from res/trainers/0882.json rename to res/trainers/trainer_idol_grace_rematch_2.json diff --git a/res/trainers/0908.json b/res/trainers/trainer_idol_grace_rematch_3.json similarity index 100% rename from res/trainers/0908.json rename to res/trainers/trainer_idol_grace_rematch_3.json diff --git a/res/trainers/0916.json b/res/trainers/trainer_idol_grace_rematch_4.json similarity index 100% rename from res/trainers/0916.json rename to res/trainers/trainer_idol_grace_rematch_4.json diff --git a/res/trainers/0883.json b/res/trainers/trainer_interviewers_roxy_and_oli.json similarity index 100% rename from res/trainers/0883.json rename to res/trainers/trainer_interviewers_roxy_and_oli.json diff --git a/res/trainers/0884.json b/res/trainers/trainer_interviewers_roxy_and_oli_rematch_1.json similarity index 100% rename from res/trainers/0884.json rename to res/trainers/trainer_interviewers_roxy_and_oli_rematch_1.json diff --git a/res/trainers/0885.json b/res/trainers/trainer_interviewers_roxy_and_oli_rematch_2.json similarity index 100% rename from res/trainers/0885.json rename to res/trainers/trainer_interviewers_roxy_and_oli_rematch_2.json diff --git a/res/trainers/0909.json b/res/trainers/trainer_interviewers_roxy_and_oli_rematch_3.json similarity index 100% rename from res/trainers/0909.json rename to res/trainers/trainer_interviewers_roxy_and_oli_rematch_3.json diff --git a/res/trainers/0917.json b/res/trainers/trainer_interviewers_roxy_and_oli_rematch_4.json similarity index 100% rename from res/trainers/0917.json rename to res/trainers/trainer_interviewers_roxy_and_oli_rematch_4.json diff --git a/res/trainers/0307.json b/res/trainers/trainer_jogger_craig.json similarity index 100% rename from res/trainers/0307.json rename to res/trainers/trainer_jogger_craig.json diff --git a/res/trainers/0697.json b/res/trainers/trainer_jogger_craig_rematch_1.json similarity index 100% rename from res/trainers/0697.json rename to res/trainers/trainer_jogger_craig_rematch_1.json diff --git a/res/trainers/0698.json b/res/trainers/trainer_jogger_craig_rematch_2.json similarity index 100% rename from res/trainers/0698.json rename to res/trainers/trainer_jogger_craig_rematch_2.json diff --git a/res/trainers/0308.json b/res/trainers/trainer_jogger_raul.json similarity index 100% rename from res/trainers/0308.json rename to res/trainers/trainer_jogger_raul.json diff --git a/res/trainers/0049.json b/res/trainers/trainer_jogger_richard.json similarity index 100% rename from res/trainers/0049.json rename to res/trainers/trainer_jogger_richard.json diff --git a/res/trainers/0130.json b/res/trainers/trainer_jogger_scott.json similarity index 100% rename from res/trainers/0130.json rename to res/trainers/trainer_jogger_scott.json diff --git a/res/trainers/0306.json b/res/trainers/trainer_jogger_wyatt.json similarity index 100% rename from res/trainers/0306.json rename to res/trainers/trainer_jogger_wyatt.json diff --git a/res/trainers/0893.json b/res/trainers/trainer_lady_celeste.json similarity index 100% rename from res/trainers/0893.json rename to res/trainers/trainer_lady_celeste.json diff --git a/res/trainers/0546.json b/res/trainers/trainer_lady_kylie.json similarity index 100% rename from res/trainers/0546.json rename to res/trainers/trainer_lady_kylie.json diff --git a/res/trainers/0083.json b/res/trainers/trainer_lady_melissa.json similarity index 100% rename from res/trainers/0083.json rename to res/trainers/trainer_lady_melissa.json diff --git a/res/trainers/0729.json b/res/trainers/trainer_lady_melissa_rematch_1.json similarity index 100% rename from res/trainers/0729.json rename to res/trainers/trainer_lady_melissa_rematch_1.json diff --git a/res/trainers/0730.json b/res/trainers/trainer_lady_melissa_rematch_2.json similarity index 100% rename from res/trainers/0730.json rename to res/trainers/trainer_lady_melissa_rematch_2.json diff --git a/res/trainers/0731.json b/res/trainers/trainer_lady_melissa_rematch_3.json similarity index 100% rename from res/trainers/0731.json rename to res/trainers/trainer_lady_melissa_rematch_3.json diff --git a/res/trainers/0544.json b/res/trainers/trainer_lass_blythe.json similarity index 100% rename from res/trainers/0544.json rename to res/trainers/trainer_lass_blythe.json diff --git a/res/trainers/0204.json b/res/trainers/trainer_lass_briana.json similarity index 100% rename from res/trainers/0204.json rename to res/trainers/trainer_lass_briana.json diff --git a/res/trainers/0324.json b/res/trainers/trainer_lass_caroline.json similarity index 100% rename from res/trainers/0324.json rename to res/trainers/trainer_lass_caroline.json diff --git a/res/trainers/0450.json b/res/trainers/trainer_lass_cassidy.json similarity index 100% rename from res/trainers/0450.json rename to res/trainers/trainer_lass_cassidy.json diff --git a/res/trainers/0323.json b/res/trainers/trainer_lass_kaitlin.json similarity index 100% rename from res/trainers/0323.json rename to res/trainers/trainer_lass_kaitlin.json diff --git a/res/trainers/0322.json b/res/trainers/trainer_lass_madeline.json similarity index 100% rename from res/trainers/0322.json rename to res/trainers/trainer_lass_madeline.json diff --git a/res/trainers/0706.json b/res/trainers/trainer_lass_madeline_rematch_1.json similarity index 100% rename from res/trainers/0706.json rename to res/trainers/trainer_lass_madeline_rematch_1.json diff --git a/res/trainers/0707.json b/res/trainers/trainer_lass_madeline_rematch_2.json similarity index 100% rename from res/trainers/0707.json rename to res/trainers/trainer_lass_madeline_rematch_2.json diff --git a/res/trainers/0708.json b/res/trainers/trainer_lass_madeline_rematch_3.json similarity index 100% rename from res/trainers/0708.json rename to res/trainers/trainer_lass_madeline_rematch_3.json diff --git a/res/trainers/0325.json b/res/trainers/trainer_lass_molly.json similarity index 100% rename from res/trainers/0325.json rename to res/trainers/trainer_lass_molly.json diff --git a/res/trainers/0003.json b/res/trainers/trainer_lass_natalie.json similarity index 100% rename from res/trainers/0003.json rename to res/trainers/trainer_lass_natalie.json diff --git a/res/trainers/0011.json b/res/trainers/trainer_lass_samantha.json similarity index 100% rename from res/trainers/0011.json rename to res/trainers/trainer_lass_samantha.json diff --git a/res/trainers/0703.json b/res/trainers/trainer_lass_samantha_rematch_1.json similarity index 100% rename from res/trainers/0703.json rename to res/trainers/trainer_lass_samantha_rematch_1.json diff --git a/res/trainers/0704.json b/res/trainers/trainer_lass_samantha_rematch_2.json similarity index 100% rename from res/trainers/0704.json rename to res/trainers/trainer_lass_samantha_rematch_2.json diff --git a/res/trainers/0705.json b/res/trainers/trainer_lass_samantha_rematch_3.json similarity index 100% rename from res/trainers/0705.json rename to res/trainers/trainer_lass_samantha_rematch_3.json diff --git a/res/trainers/0012.json b/res/trainers/trainer_lass_sarah.json similarity index 100% rename from res/trainers/0012.json rename to res/trainers/trainer_lass_sarah.json diff --git a/res/trainers/0250.json b/res/trainers/trainer_leader_byron.json similarity index 100% rename from res/trainers/0250.json rename to res/trainers/trainer_leader_byron.json diff --git a/res/trainers/0856.json b/res/trainers/trainer_leader_byron_rematch.json similarity index 100% rename from res/trainers/0856.json rename to res/trainers/trainer_leader_byron_rematch.json diff --git a/res/trainers/0319.json b/res/trainers/trainer_leader_candice.json similarity index 100% rename from res/trainers/0319.json rename to res/trainers/trainer_leader_candice.json diff --git a/res/trainers/0853.json b/res/trainers/trainer_leader_candice_rematch.json similarity index 100% rename from res/trainers/0853.json rename to res/trainers/trainer_leader_candice_rematch.json diff --git a/res/trainers/0318.json b/res/trainers/trainer_leader_fantina.json similarity index 100% rename from res/trainers/0318.json rename to res/trainers/trainer_leader_fantina.json diff --git a/res/trainers/0860.json b/res/trainers/trainer_leader_fantina_rematch.json similarity index 100% rename from res/trainers/0860.json rename to res/trainers/trainer_leader_fantina_rematch.json diff --git a/res/trainers/0315.json b/res/trainers/trainer_leader_gardenia.json similarity index 100% rename from res/trainers/0315.json rename to res/trainers/trainer_leader_gardenia.json diff --git a/res/trainers/0857.json b/res/trainers/trainer_leader_gardenia_rematch.json similarity index 100% rename from res/trainers/0857.json rename to res/trainers/trainer_leader_gardenia_rematch.json diff --git a/res/trainers/0317.json b/res/trainers/trainer_leader_maylene.json similarity index 100% rename from res/trainers/0317.json rename to res/trainers/trainer_leader_maylene.json diff --git a/res/trainers/0854.json b/res/trainers/trainer_leader_maylene_rematch.json similarity index 100% rename from res/trainers/0854.json rename to res/trainers/trainer_leader_maylene_rematch.json diff --git a/res/trainers/0246.json b/res/trainers/trainer_leader_roark.json similarity index 100% rename from res/trainers/0246.json rename to res/trainers/trainer_leader_roark.json diff --git a/res/trainers/0858.json b/res/trainers/trainer_leader_roark_rematch.json similarity index 100% rename from res/trainers/0858.json rename to res/trainers/trainer_leader_roark_rematch.json diff --git a/res/trainers/0320.json b/res/trainers/trainer_leader_volkner.json similarity index 100% rename from res/trainers/0320.json rename to res/trainers/trainer_leader_volkner.json diff --git a/res/trainers/0921.json b/res/trainers/trainer_leader_volkner_fight_area.json similarity index 100% rename from res/trainers/0921.json rename to res/trainers/trainer_leader_volkner_fight_area.json diff --git a/res/trainers/0855.json b/res/trainers/trainer_leader_volkner_rematch.json similarity index 100% rename from res/trainers/0855.json rename to res/trainers/trainer_leader_volkner_rematch.json diff --git a/res/trainers/0316.json b/res/trainers/trainer_leader_wake.json similarity index 100% rename from res/trainers/0316.json rename to res/trainers/trainer_leader_wake.json diff --git a/res/trainers/0859.json b/res/trainers/trainer_leader_wake_rematch.json similarity index 100% rename from res/trainers/0859.json rename to res/trainers/trainer_leader_wake_rematch.json diff --git a/res/trainers/0613.json b/res/trainers/trainer_lucas_jubilife_city_chimchar.json similarity index 100% rename from res/trainers/0613.json rename to res/trainers/trainer_lucas_jubilife_city_chimchar.json diff --git a/res/trainers/0614.json b/res/trainers/trainer_lucas_jubilife_city_piplup.json similarity index 100% rename from res/trainers/0614.json rename to res/trainers/trainer_lucas_jubilife_city_piplup.json diff --git a/res/trainers/0615.json b/res/trainers/trainer_lucas_jubilife_city_turtwig.json similarity index 100% rename from res/trainers/0615.json rename to res/trainers/trainer_lucas_jubilife_city_turtwig.json diff --git a/res/trainers/0621.json b/res/trainers/trainer_lucas_veilstone_city_chimchar.json similarity index 100% rename from res/trainers/0621.json rename to res/trainers/trainer_lucas_veilstone_city_chimchar.json diff --git a/res/trainers/0622.json b/res/trainers/trainer_lucas_veilstone_city_piplup.json similarity index 100% rename from res/trainers/0622.json rename to res/trainers/trainer_lucas_veilstone_city_piplup.json diff --git a/res/trainers/0623.json b/res/trainers/trainer_lucas_veilstone_city_turtwig.json similarity index 100% rename from res/trainers/0623.json rename to res/trainers/trainer_lucas_veilstone_city_turtwig.json diff --git a/res/trainers/0897.json b/res/trainers/trainer_maid_belinda.json similarity index 100% rename from res/trainers/0897.json rename to res/trainers/trainer_maid_belinda.json diff --git a/res/trainers/0901.json b/res/trainers/trainer_maid_clare.json similarity index 100% rename from res/trainers/0901.json rename to res/trainers/trainer_maid_clare.json diff --git a/res/trainers/0900.json b/res/trainers/trainer_maid_elena.json similarity index 100% rename from res/trainers/0900.json rename to res/trainers/trainer_maid_elena.json diff --git a/res/trainers/0899.json b/res/trainers/trainer_maid_emily.json similarity index 100% rename from res/trainers/0899.json rename to res/trainers/trainer_maid_emily.json diff --git a/res/trainers/0898.json b/res/trainers/trainer_maid_sophie.json similarity index 100% rename from res/trainers/0898.json rename to res/trainers/trainer_maid_sophie.json diff --git a/res/trainers/0489.json b/res/trainers/trainer_ninja_boy_brennan.json similarity index 100% rename from res/trainers/0489.json rename to res/trainers/trainer_ninja_boy_brennan.json diff --git a/res/trainers/0490.json b/res/trainers/trainer_ninja_boy_bruce.json similarity index 100% rename from res/trainers/0490.json rename to res/trainers/trainer_ninja_boy_bruce.json diff --git a/res/trainers/0072.json b/res/trainers/trainer_ninja_boy_davido.json similarity index 100% rename from res/trainers/0072.json rename to res/trainers/trainer_ninja_boy_davido.json diff --git a/res/trainers/0147.json b/res/trainers/trainer_ninja_boy_ethan.json similarity index 100% rename from res/trainers/0147.json rename to res/trainers/trainer_ninja_boy_ethan.json diff --git a/res/trainers/0488.json b/res/trainers/trainer_ninja_boy_fabian.json similarity index 100% rename from res/trainers/0488.json rename to res/trainers/trainer_ninja_boy_fabian.json diff --git a/res/trainers/0070.json b/res/trainers/trainer_ninja_boy_joel.json similarity index 100% rename from res/trainers/0070.json rename to res/trainers/trainer_ninja_boy_joel.json diff --git a/res/trainers/0146.json b/res/trainers/trainer_ninja_boy_matthew.json similarity index 100% rename from res/trainers/0146.json rename to res/trainers/trainer_ninja_boy_matthew.json diff --git a/res/trainers/0071.json b/res/trainers/trainer_ninja_boy_nathan.json similarity index 100% rename from res/trainers/0071.json rename to res/trainers/trainer_ninja_boy_nathan.json diff --git a/res/trainers/0080.json b/res/trainers/trainer_ninja_boy_nick.json similarity index 100% rename from res/trainers/0080.json rename to res/trainers/trainer_ninja_boy_nick.json diff --git a/res/trainers/0078.json b/res/trainers/trainer_ninja_boy_zach.json similarity index 100% rename from res/trainers/0078.json rename to res/trainers/trainer_ninja_boy_zach.json diff --git a/res/trainers/0746.json b/res/trainers/trainer_ninja_boy_zach_rematch_1.json similarity index 100% rename from res/trainers/0746.json rename to res/trainers/trainer_ninja_boy_zach_rematch_1.json diff --git a/res/trainers/0747.json b/res/trainers/trainer_ninja_boy_zach_rematch_2.json similarity index 100% rename from res/trainers/0747.json rename to res/trainers/trainer_ninja_boy_zach_rematch_2.json diff --git a/res/trainers/0748.json b/res/trainers/trainer_ninja_boy_zach_rematch_3.json similarity index 100% rename from res/trainers/0748.json rename to res/trainers/trainer_ninja_boy_zach_rematch_3.json diff --git a/res/trainers/0000.json b/res/trainers/trainer_none.json similarity index 100% rename from res/trainers/0000.json rename to res/trainers/trainer_none.json diff --git a/res/trainers/0327.json b/res/trainers/trainer_parasol_lady_alexa.json similarity index 100% rename from res/trainers/0327.json rename to res/trainers/trainer_parasol_lady_alexa.json diff --git a/res/trainers/0715.json b/res/trainers/trainer_parasol_lady_alexa_rematch_1.json similarity index 100% rename from res/trainers/0715.json rename to res/trainers/trainer_parasol_lady_alexa_rematch_1.json diff --git a/res/trainers/0716.json b/res/trainers/trainer_parasol_lady_alexa_rematch_2.json similarity index 100% rename from res/trainers/0716.json rename to res/trainers/trainer_parasol_lady_alexa_rematch_2.json diff --git a/res/trainers/0717.json b/res/trainers/trainer_parasol_lady_alexa_rematch_3.json similarity index 100% rename from res/trainers/0717.json rename to res/trainers/trainer_parasol_lady_alexa_rematch_3.json diff --git a/res/trainers/0328.json b/res/trainers/trainer_parasol_lady_sabrina.json similarity index 100% rename from res/trainers/0328.json rename to res/trainers/trainer_parasol_lady_sabrina.json diff --git a/res/trainers/0121.json b/res/trainers/trainer_pi_carlos.json similarity index 100% rename from res/trainers/0121.json rename to res/trainers/trainer_pi_carlos.json diff --git a/res/trainers/0689.json b/res/trainers/trainer_pi_carlos_rematch_1.json similarity index 100% rename from res/trainers/0689.json rename to res/trainers/trainer_pi_carlos_rematch_1.json diff --git a/res/trainers/0690.json b/res/trainers/trainer_pi_carlos_rematch_2.json similarity index 100% rename from res/trainers/0690.json rename to res/trainers/trainer_pi_carlos_rematch_2.json diff --git a/res/trainers/0541.json b/res/trainers/trainer_pi_kendrick.json similarity index 100% rename from res/trainers/0541.json rename to res/trainers/trainer_pi_kendrick.json diff --git a/res/trainers/0459.json b/res/trainers/trainer_picnicker_ana.json similarity index 100% rename from res/trainers/0459.json rename to res/trainers/trainer_picnicker_ana.json diff --git a/res/trainers/0330.json b/res/trainers/trainer_picnicker_cheyenne.json similarity index 100% rename from res/trainers/0330.json rename to res/trainers/trainer_picnicker_cheyenne.json diff --git a/res/trainers/0329.json b/res/trainers/trainer_picnicker_diana.json similarity index 100% rename from res/trainers/0329.json rename to res/trainers/trainer_picnicker_diana.json diff --git a/res/trainers/0456.json b/res/trainers/trainer_picnicker_karina.json similarity index 100% rename from res/trainers/0456.json rename to res/trainers/trainer_picnicker_karina.json diff --git a/res/trainers/0718.json b/res/trainers/trainer_picnicker_karina_rematch_1.json similarity index 100% rename from res/trainers/0718.json rename to res/trainers/trainer_picnicker_karina_rematch_1.json diff --git a/res/trainers/0719.json b/res/trainers/trainer_picnicker_karina_rematch_2.json similarity index 100% rename from res/trainers/0719.json rename to res/trainers/trainer_picnicker_karina_rematch_2.json diff --git a/res/trainers/0720.json b/res/trainers/trainer_picnicker_karina_rematch_3.json similarity index 100% rename from res/trainers/0720.json rename to res/trainers/trainer_picnicker_karina_rematch_3.json diff --git a/res/trainers/0035.json b/res/trainers/trainer_picnicker_lauren.json similarity index 100% rename from res/trainers/0035.json rename to res/trainers/trainer_picnicker_lauren.json diff --git a/res/trainers/0017.json b/res/trainers/trainer_picnicker_siena.json similarity index 100% rename from res/trainers/0017.json rename to res/trainers/trainer_picnicker_siena.json diff --git a/res/trainers/0457.json b/res/trainers/trainer_picnicker_summer.json similarity index 100% rename from res/trainers/0457.json rename to res/trainers/trainer_picnicker_summer.json diff --git a/res/trainers/0458.json b/res/trainers/trainer_picnicker_tori.json similarity index 100% rename from res/trainers/0458.json rename to res/trainers/trainer_picnicker_tori.json diff --git a/res/trainers/0889.json b/res/trainers/trainer_poke_kid_ariel.json similarity index 100% rename from res/trainers/0889.json rename to res/trainers/trainer_poke_kid_ariel.json diff --git a/res/trainers/0890.json b/res/trainers/trainer_poke_kid_ariel_rematch_1.json similarity index 100% rename from res/trainers/0890.json rename to res/trainers/trainer_poke_kid_ariel_rematch_1.json diff --git a/res/trainers/0891.json b/res/trainers/trainer_poke_kid_ariel_rematch_2.json similarity index 100% rename from res/trainers/0891.json rename to res/trainers/trainer_poke_kid_ariel_rematch_2.json diff --git a/res/trainers/0911.json b/res/trainers/trainer_poke_kid_ariel_rematch_3.json similarity index 100% rename from res/trainers/0911.json rename to res/trainers/trainer_poke_kid_ariel_rematch_3.json diff --git a/res/trainers/0919.json b/res/trainers/trainer_poke_kid_ariel_rematch_4.json similarity index 100% rename from res/trainers/0919.json rename to res/trainers/trainer_poke_kid_ariel_rematch_4.json diff --git a/res/trainers/0053.json b/res/trainers/trainer_poke_kid_danielle.json similarity index 100% rename from res/trainers/0053.json rename to res/trainers/trainer_poke_kid_danielle.json diff --git a/res/trainers/0721.json b/res/trainers/trainer_poke_kid_danielle_rematch_1.json similarity index 100% rename from res/trainers/0721.json rename to res/trainers/trainer_poke_kid_danielle_rematch_1.json diff --git a/res/trainers/0722.json b/res/trainers/trainer_poke_kid_danielle_rematch_2.json similarity index 100% rename from res/trainers/0722.json rename to res/trainers/trainer_poke_kid_danielle_rematch_2.json diff --git a/res/trainers/0723.json b/res/trainers/trainer_poke_kid_danielle_rematch_3.json similarity index 100% rename from res/trainers/0723.json rename to res/trainers/trainer_poke_kid_danielle_rematch_3.json diff --git a/res/trainers/0832.json b/res/trainers/trainer_poke_kid_janet.json similarity index 100% rename from res/trainers/0832.json rename to res/trainers/trainer_poke_kid_janet.json diff --git a/res/trainers/0331.json b/res/trainers/trainer_poke_kid_meghan.json similarity index 100% rename from res/trainers/0331.json rename to res/trainers/trainer_poke_kid_meghan.json diff --git a/res/trainers/0530.json b/res/trainers/trainer_pokefan_leonard.json similarity index 100% rename from res/trainers/0530.json rename to res/trainers/trainer_pokefan_leonard.json diff --git a/res/trainers/0540.json b/res/trainers/trainer_pokefan_meredith.json similarity index 100% rename from res/trainers/0540.json rename to res/trainers/trainer_pokefan_meredith.json diff --git a/res/trainers/0531.json b/res/trainers/trainer_pokefan_rebekah.json similarity index 100% rename from res/trainers/0531.json rename to res/trainers/trainer_pokefan_rebekah.json diff --git a/res/trainers/0089.json b/res/trainers/trainer_policeman_alex.json similarity index 100% rename from res/trainers/0089.json rename to res/trainers/trainer_policeman_alex.json diff --git a/res/trainers/0088.json b/res/trainers/trainer_policeman_bobby.json similarity index 100% rename from res/trainers/0088.json rename to res/trainers/trainer_policeman_bobby.json diff --git a/res/trainers/0102.json b/res/trainers/trainer_policeman_caleb.json similarity index 100% rename from res/trainers/0102.json rename to res/trainers/trainer_policeman_caleb.json diff --git a/res/trainers/0332.json b/res/trainers/trainer_policeman_danny.json similarity index 100% rename from res/trainers/0332.json rename to res/trainers/trainer_policeman_danny.json diff --git a/res/trainers/0724.json b/res/trainers/trainer_policeman_danny_rematch_1.json similarity index 100% rename from res/trainers/0724.json rename to res/trainers/trainer_policeman_danny_rematch_1.json diff --git a/res/trainers/0725.json b/res/trainers/trainer_policeman_danny_rematch_2.json similarity index 100% rename from res/trainers/0725.json rename to res/trainers/trainer_policeman_danny_rematch_2.json diff --git a/res/trainers/0726.json b/res/trainers/trainer_policeman_danny_rematch_3.json similarity index 100% rename from res/trainers/0726.json rename to res/trainers/trainer_policeman_danny_rematch_3.json diff --git a/res/trainers/0090.json b/res/trainers/trainer_policeman_dylan.json similarity index 100% rename from res/trainers/0090.json rename to res/trainers/trainer_policeman_dylan.json diff --git a/res/trainers/0333.json b/res/trainers/trainer_policeman_thomas.json similarity index 100% rename from res/trainers/0333.json rename to res/trainers/trainer_policeman_thomas.json diff --git a/res/trainers/0120.json b/res/trainers/trainer_psychic_abigail.json similarity index 100% rename from res/trainers/0120.json rename to res/trainers/trainer_psychic_abigail.json diff --git a/res/trainers/0677.json b/res/trainers/trainer_psychic_abigail_rematch_1.json similarity index 100% rename from res/trainers/0677.json rename to res/trainers/trainer_psychic_abigail_rematch_1.json diff --git a/res/trainers/0678.json b/res/trainers/trainer_psychic_abigail_rematch_2.json similarity index 100% rename from res/trainers/0678.json rename to res/trainers/trainer_psychic_abigail_rematch_2.json diff --git a/res/trainers/0289.json b/res/trainers/trainer_psychic_brittney.json similarity index 100% rename from res/trainers/0289.json rename to res/trainers/trainer_psychic_brittney.json diff --git a/res/trainers/0679.json b/res/trainers/trainer_psychic_brittney_rematch.json similarity index 100% rename from res/trainers/0679.json rename to res/trainers/trainer_psychic_brittney_rematch.json diff --git a/res/trainers/0234.json b/res/trainers/trainer_psychic_bryce.json similarity index 100% rename from res/trainers/0234.json rename to res/trainers/trainer_psychic_bryce.json diff --git a/res/trainers/0586.json b/res/trainers/trainer_psychic_chelsey.json similarity index 100% rename from res/trainers/0586.json rename to res/trainers/trainer_psychic_chelsey.json diff --git a/res/trainers/0583.json b/res/trainers/trainer_psychic_corbin.json similarity index 100% rename from res/trainers/0583.json rename to res/trainers/trainer_psychic_corbin.json diff --git a/res/trainers/0676.json b/res/trainers/trainer_psychic_corbin_rematch.json similarity index 100% rename from res/trainers/0676.json rename to res/trainers/trainer_psychic_corbin_rematch.json diff --git a/res/trainers/0585.json b/res/trainers/trainer_psychic_daisy.json similarity index 100% rename from res/trainers/0585.json rename to res/trainers/trainer_psychic_daisy.json diff --git a/res/trainers/0680.json b/res/trainers/trainer_psychic_daisy_rematch.json similarity index 100% rename from res/trainers/0680.json rename to res/trainers/trainer_psychic_daisy_rematch.json diff --git a/res/trainers/0397.json b/res/trainers/trainer_psychic_deandre.json similarity index 100% rename from res/trainers/0397.json rename to res/trainers/trainer_psychic_deandre.json diff --git a/res/trainers/0399.json b/res/trainers/trainer_psychic_desiree.json similarity index 100% rename from res/trainers/0399.json rename to res/trainers/trainer_psychic_desiree.json diff --git a/res/trainers/0205.json b/res/trainers/trainer_psychic_elijah.json similarity index 100% rename from res/trainers/0205.json rename to res/trainers/trainer_psychic_elijah.json diff --git a/res/trainers/0400.json b/res/trainers/trainer_psychic_kendra.json similarity index 100% rename from res/trainers/0400.json rename to res/trainers/trainer_psychic_kendra.json diff --git a/res/trainers/0395.json b/res/trainers/trainer_psychic_kody.json similarity index 100% rename from res/trainers/0395.json rename to res/trainers/trainer_psychic_kody.json diff --git a/res/trainers/0396.json b/res/trainers/trainer_psychic_landon.json similarity index 100% rename from res/trainers/0396.json rename to res/trainers/trainer_psychic_landon.json diff --git a/res/trainers/0206.json b/res/trainers/trainer_psychic_lindsey.json similarity index 100% rename from res/trainers/0206.json rename to res/trainers/trainer_psychic_lindsey.json diff --git a/res/trainers/0288.json b/res/trainers/trainer_psychic_maxwell.json similarity index 100% rename from res/trainers/0288.json rename to res/trainers/trainer_psychic_maxwell.json diff --git a/res/trainers/0675.json b/res/trainers/trainer_psychic_maxwell_rematch.json similarity index 100% rename from res/trainers/0675.json rename to res/trainers/trainer_psychic_maxwell_rematch.json diff --git a/res/trainers/0119.json b/res/trainers/trainer_psychic_mitchell.json similarity index 100% rename from res/trainers/0119.json rename to res/trainers/trainer_psychic_mitchell.json diff --git a/res/trainers/0673.json b/res/trainers/trainer_psychic_mitchell_rematch_1.json similarity index 100% rename from res/trainers/0673.json rename to res/trainers/trainer_psychic_mitchell_rematch_1.json diff --git a/res/trainers/0674.json b/res/trainers/trainer_psychic_mitchell_rematch_2.json similarity index 100% rename from res/trainers/0674.json rename to res/trainers/trainer_psychic_mitchell_rematch_2.json diff --git a/res/trainers/0398.json b/res/trainers/trainer_psychic_rachael.json similarity index 100% rename from res/trainers/0398.json rename to res/trainers/trainer_psychic_rachael.json diff --git a/res/trainers/0584.json b/res/trainers/trainer_psychic_sterling.json similarity index 100% rename from res/trainers/0584.json rename to res/trainers/trainer_psychic_sterling.json diff --git a/res/trainers/0235.json b/res/trainers/trainer_psychic_valencia.json similarity index 100% rename from res/trainers/0235.json rename to res/trainers/trainer_psychic_valencia.json diff --git a/res/trainers/0292.json b/res/trainers/trainer_rancher_marco.json similarity index 100% rename from res/trainers/0292.json rename to res/trainers/trainer_rancher_marco.json diff --git a/res/trainers/0681.json b/res/trainers/trainer_rancher_marco_rematch_1.json similarity index 100% rename from res/trainers/0681.json rename to res/trainers/trainer_rancher_marco_rematch_1.json diff --git a/res/trainers/0682.json b/res/trainers/trainer_rancher_marco_rematch_2.json similarity index 100% rename from res/trainers/0682.json rename to res/trainers/trainer_rancher_marco_rematch_2.json diff --git a/res/trainers/0096.json b/res/trainers/trainer_ranger_allison.json similarity index 100% rename from res/trainers/0096.json rename to res/trainers/trainer_ranger_allison.json diff --git a/res/trainers/0736.json b/res/trainers/trainer_ranger_allison_rematch_1.json similarity index 100% rename from res/trainers/0736.json rename to res/trainers/trainer_ranger_allison_rematch_1.json diff --git a/res/trainers/0737.json b/res/trainers/trainer_ranger_allison_rematch_2.json similarity index 100% rename from res/trainers/0737.json rename to res/trainers/trainer_ranger_allison_rematch_2.json diff --git a/res/trainers/0738.json b/res/trainers/trainer_ranger_allison_rematch_3.json similarity index 100% rename from res/trainers/0738.json rename to res/trainers/trainer_ranger_allison_rematch_3.json diff --git a/res/trainers/0594.json b/res/trainers/trainer_ranger_ashlee.json similarity index 100% rename from res/trainers/0594.json rename to res/trainers/trainer_ranger_ashlee.json diff --git a/res/trainers/0739.json b/res/trainers/trainer_ranger_ashlee_rematch.json similarity index 100% rename from res/trainers/0739.json rename to res/trainers/trainer_ranger_ashlee_rematch.json diff --git a/res/trainers/0592.json b/res/trainers/trainer_ranger_deshawn.json similarity index 100% rename from res/trainers/0592.json rename to res/trainers/trainer_ranger_deshawn.json diff --git a/res/trainers/0593.json b/res/trainers/trainer_ranger_dwayne.json similarity index 100% rename from res/trainers/0593.json rename to res/trainers/trainer_ranger_dwayne.json diff --git a/res/trainers/0595.json b/res/trainers/trainer_ranger_felicia.json similarity index 100% rename from res/trainers/0595.json rename to res/trainers/trainer_ranger_felicia.json diff --git a/res/trainers/0095.json b/res/trainers/trainer_ranger_jeffrey.json similarity index 100% rename from res/trainers/0095.json rename to res/trainers/trainer_ranger_jeffrey.json diff --git a/res/trainers/0596.json b/res/trainers/trainer_ranger_krista.json similarity index 100% rename from res/trainers/0596.json rename to res/trainers/trainer_ranger_krista.json diff --git a/res/trainers/0591.json b/res/trainers/trainer_ranger_kyler.json similarity index 100% rename from res/trainers/0591.json rename to res/trainers/trainer_ranger_kyler.json diff --git a/res/trainers/0735.json b/res/trainers/trainer_ranger_kyler_rematch.json similarity index 100% rename from res/trainers/0735.json rename to res/trainers/trainer_ranger_kyler_rematch.json diff --git a/res/trainers/0094.json b/res/trainers/trainer_ranger_taylor.json similarity index 100% rename from res/trainers/0094.json rename to res/trainers/trainer_ranger_taylor.json diff --git a/res/trainers/0732.json b/res/trainers/trainer_ranger_taylor_rematch_1.json similarity index 100% rename from res/trainers/0732.json rename to res/trainers/trainer_ranger_taylor_rematch_1.json diff --git a/res/trainers/0733.json b/res/trainers/trainer_ranger_taylor_rematch_2.json similarity index 100% rename from res/trainers/0733.json rename to res/trainers/trainer_ranger_taylor_rematch_2.json diff --git a/res/trainers/0734.json b/res/trainers/trainer_ranger_taylor_rematch_3.json similarity index 100% rename from res/trainers/0734.json rename to res/trainers/trainer_ranger_taylor_rematch_3.json diff --git a/res/trainers/0894.json b/res/trainers/trainer_reporters_kinsey.json similarity index 100% rename from res/trainers/0894.json rename to res/trainers/trainer_reporters_kinsey.json diff --git a/res/trainers/0895.json b/res/trainers/trainer_reporters_kinsey_rematch_1.json similarity index 100% rename from res/trainers/0895.json rename to res/trainers/trainer_reporters_kinsey_rematch_1.json diff --git a/res/trainers/0896.json b/res/trainers/trainer_reporters_kinsey_rematch_2.json similarity index 100% rename from res/trainers/0896.json rename to res/trainers/trainer_reporters_kinsey_rematch_2.json diff --git a/res/trainers/0912.json b/res/trainers/trainer_reporters_kinsey_rematch_3.json similarity index 100% rename from res/trainers/0912.json rename to res/trainers/trainer_reporters_kinsey_rematch_3.json diff --git a/res/trainers/0920.json b/res/trainers/trainer_reporters_kinsey_rematch_4.json similarity index 100% rename from res/trainers/0920.json rename to res/trainers/trainer_reporters_kinsey_rematch_4.json diff --git a/res/trainers/0547.json b/res/trainers/trainer_reporters_valerie.json similarity index 100% rename from res/trainers/0547.json rename to res/trainers/trainer_reporters_valerie.json diff --git a/res/trainers/0082.json b/res/trainers/trainer_rich_boy_jason.json similarity index 100% rename from res/trainers/0082.json rename to res/trainers/trainer_rich_boy_jason.json diff --git a/res/trainers/0892.json b/res/trainers/trainer_rich_boy_liam.json similarity index 100% rename from res/trainers/0892.json rename to res/trainers/trainer_rich_boy_liam.json diff --git a/res/trainers/0545.json b/res/trainers/trainer_rich_boy_roman.json similarity index 100% rename from res/trainers/0545.json rename to res/trainers/trainer_rich_boy_roman.json diff --git a/res/trainers/0335.json b/res/trainers/trainer_rich_boy_trey.json similarity index 100% rename from res/trainers/0335.json rename to res/trainers/trainer_rich_boy_trey.json diff --git a/res/trainers/0727.json b/res/trainers/trainer_rich_boy_trey_rematch_1.json similarity index 100% rename from res/trainers/0727.json rename to res/trainers/trainer_rich_boy_trey_rematch_1.json diff --git a/res/trainers/0728.json b/res/trainers/trainer_rich_boy_trey_rematch_2.json similarity index 100% rename from res/trainers/0728.json rename to res/trainers/trainer_rich_boy_trey_rematch_2.json diff --git a/res/trainers/0478.json b/res/trainers/trainer_rival_canalave_city_chimchar.json similarity index 100% rename from res/trainers/0478.json rename to res/trainers/trainer_rival_canalave_city_chimchar.json diff --git a/res/trainers/0476.json b/res/trainers/trainer_rival_canalave_city_piplup.json similarity index 100% rename from res/trainers/0476.json rename to res/trainers/trainer_rival_canalave_city_piplup.json diff --git a/res/trainers/0477.json b/res/trainers/trainer_rival_canalave_city_turtwig.json similarity index 100% rename from res/trainers/0477.json rename to res/trainers/trainer_rival_canalave_city_turtwig.json diff --git a/res/trainers/0925.json b/res/trainers/trainer_rival_fight_area_chimchar.json similarity index 100% rename from res/trainers/0925.json rename to res/trainers/trainer_rival_fight_area_chimchar.json diff --git a/res/trainers/0923.json b/res/trainers/trainer_rival_fight_area_piplup.json similarity index 100% rename from res/trainers/0923.json rename to res/trainers/trainer_rival_fight_area_piplup.json diff --git a/res/trainers/0924.json b/res/trainers/trainer_rival_fight_area_turtwig.json similarity index 100% rename from res/trainers/0924.json rename to res/trainers/trainer_rival_fight_area_turtwig.json diff --git a/res/trainers/0475.json b/res/trainers/trainer_rival_pastoria_city_chimchar.json similarity index 100% rename from res/trainers/0475.json rename to res/trainers/trainer_rival_pastoria_city_chimchar.json diff --git a/res/trainers/0473.json b/res/trainers/trainer_rival_pastoria_city_piplup.json similarity index 100% rename from res/trainers/0473.json rename to res/trainers/trainer_rival_pastoria_city_piplup.json diff --git a/res/trainers/0474.json b/res/trainers/trainer_rival_pastoria_city_turtwig.json similarity index 100% rename from res/trainers/0474.json rename to res/trainers/trainer_rival_pastoria_city_turtwig.json diff --git a/res/trainers/0481.json b/res/trainers/trainer_rival_pokemon_league_chimchar.json similarity index 100% rename from res/trainers/0481.json rename to res/trainers/trainer_rival_pokemon_league_chimchar.json diff --git a/res/trainers/0479.json b/res/trainers/trainer_rival_pokemon_league_piplup.json similarity index 100% rename from res/trainers/0479.json rename to res/trainers/trainer_rival_pokemon_league_piplup.json diff --git a/res/trainers/0480.json b/res/trainers/trainer_rival_pokemon_league_turtwig.json similarity index 100% rename from res/trainers/0480.json rename to res/trainers/trainer_rival_pokemon_league_turtwig.json diff --git a/res/trainers/0852.json b/res/trainers/trainer_rival_route_201_chimchar.json similarity index 100% rename from res/trainers/0852.json rename to res/trainers/trainer_rival_route_201_chimchar.json diff --git a/res/trainers/0850.json b/res/trainers/trainer_rival_route_201_piplup.json similarity index 100% rename from res/trainers/0850.json rename to res/trainers/trainer_rival_route_201_piplup.json diff --git a/res/trainers/0851.json b/res/trainers/trainer_rival_route_201_turtwig.json similarity index 100% rename from res/trainers/0851.json rename to res/trainers/trainer_rival_route_201_turtwig.json diff --git a/res/trainers/0249.json b/res/trainers/trainer_rival_route_203_chimchar.json similarity index 100% rename from res/trainers/0249.json rename to res/trainers/trainer_rival_route_203_chimchar.json diff --git a/res/trainers/0247.json b/res/trainers/trainer_rival_route_203_piplup.json similarity index 100% rename from res/trainers/0247.json rename to res/trainers/trainer_rival_route_203_piplup.json diff --git a/res/trainers/0248.json b/res/trainers/trainer_rival_route_203_turtwig.json similarity index 100% rename from res/trainers/0248.json rename to res/trainers/trainer_rival_route_203_turtwig.json diff --git a/res/trainers/0472.json b/res/trainers/trainer_rival_route_209_chimchar.json similarity index 100% rename from res/trainers/0472.json rename to res/trainers/trainer_rival_route_209_chimchar.json diff --git a/res/trainers/0470.json b/res/trainers/trainer_rival_route_209_piplup.json similarity index 100% rename from res/trainers/0470.json rename to res/trainers/trainer_rival_route_209_piplup.json diff --git a/res/trainers/0471.json b/res/trainers/trainer_rival_route_209_turtwig.json similarity index 100% rename from res/trainers/0471.json rename to res/trainers/trainer_rival_route_209_turtwig.json diff --git a/res/trainers/0620.json b/res/trainers/trainer_rival_spear_pillar_chimchar.json similarity index 100% rename from res/trainers/0620.json rename to res/trainers/trainer_rival_spear_pillar_chimchar.json diff --git a/res/trainers/0607.json b/res/trainers/trainer_rival_spear_pillar_piplup.json similarity index 100% rename from res/trainers/0607.json rename to res/trainers/trainer_rival_spear_pillar_piplup.json diff --git a/res/trainers/0619.json b/res/trainers/trainer_rival_spear_pillar_turtwig.json similarity index 100% rename from res/trainers/0619.json rename to res/trainers/trainer_rival_spear_pillar_turtwig.json diff --git a/res/trainers/0839.json b/res/trainers/trainer_rival_survival_area_1_chimchar.json similarity index 100% rename from res/trainers/0839.json rename to res/trainers/trainer_rival_survival_area_1_chimchar.json diff --git a/res/trainers/0837.json b/res/trainers/trainer_rival_survival_area_1_piplup.json similarity index 100% rename from res/trainers/0837.json rename to res/trainers/trainer_rival_survival_area_1_piplup.json diff --git a/res/trainers/0838.json b/res/trainers/trainer_rival_survival_area_1_turtwig.json similarity index 100% rename from res/trainers/0838.json rename to res/trainers/trainer_rival_survival_area_1_turtwig.json diff --git a/res/trainers/0873.json b/res/trainers/trainer_rival_survival_area_2_chimchar.json similarity index 100% rename from res/trainers/0873.json rename to res/trainers/trainer_rival_survival_area_2_chimchar.json diff --git a/res/trainers/0871.json b/res/trainers/trainer_rival_survival_area_2_piplup.json similarity index 100% rename from res/trainers/0871.json rename to res/trainers/trainer_rival_survival_area_2_piplup.json diff --git a/res/trainers/0872.json b/res/trainers/trainer_rival_survival_area_2_turtwig.json similarity index 100% rename from res/trainers/0872.json rename to res/trainers/trainer_rival_survival_area_2_turtwig.json diff --git a/res/trainers/0529.json b/res/trainers/trainer_roughneck_kirby.json similarity index 100% rename from res/trainers/0529.json rename to res/trainers/trainer_roughneck_kirby.json diff --git a/res/trainers/0113.json b/res/trainers/trainer_ruin_maniac_bryan.json similarity index 100% rename from res/trainers/0113.json rename to res/trainers/trainer_ruin_maniac_bryan.json diff --git a/res/trainers/0304.json b/res/trainers/trainer_ruin_maniac_calvin.json similarity index 100% rename from res/trainers/0304.json rename to res/trainers/trainer_ruin_maniac_calvin.json diff --git a/res/trainers/0443.json b/res/trainers/trainer_ruin_maniac_gerald.json similarity index 100% rename from res/trainers/0443.json rename to res/trainers/trainer_ruin_maniac_gerald.json diff --git a/res/trainers/0442.json b/res/trainers/trainer_ruin_maniac_harry.json similarity index 100% rename from res/trainers/0442.json rename to res/trainers/trainer_ruin_maniac_harry.json diff --git a/res/trainers/0695.json b/res/trainers/trainer_ruin_maniac_harry_rematch_1.json similarity index 100% rename from res/trainers/0695.json rename to res/trainers/trainer_ruin_maniac_harry_rematch_1.json diff --git a/res/trainers/0696.json b/res/trainers/trainer_ruin_maniac_harry_rematch_2.json similarity index 100% rename from res/trainers/0696.json rename to res/trainers/trainer_ruin_maniac_harry_rematch_2.json diff --git a/res/trainers/0553.json b/res/trainers/trainer_ruin_maniac_karl.json similarity index 100% rename from res/trainers/0553.json rename to res/trainers/trainer_ruin_maniac_karl.json diff --git a/res/trainers/0305.json b/res/trainers/trainer_ruin_maniac_larry.json similarity index 100% rename from res/trainers/0305.json rename to res/trainers/trainer_ruin_maniac_larry.json diff --git a/res/trainers/0114.json b/res/trainers/trainer_ruin_maniac_ronald.json similarity index 100% rename from res/trainers/0114.json rename to res/trainers/trainer_ruin_maniac_ronald.json diff --git a/res/trainers/0339.json b/res/trainers/trainer_sailor_damian.json similarity index 100% rename from res/trainers/0339.json rename to res/trainers/trainer_sailor_damian.json diff --git a/res/trainers/0180.json b/res/trainers/trainer_sailor_luther.json similarity index 100% rename from res/trainers/0180.json rename to res/trainers/trainer_sailor_luther.json diff --git a/res/trainers/0337.json b/res/trainers/trainer_sailor_marc.json similarity index 100% rename from res/trainers/0337.json rename to res/trainers/trainer_sailor_marc.json diff --git a/res/trainers/0740.json b/res/trainers/trainer_sailor_marc_rematch_1.json similarity index 100% rename from res/trainers/0740.json rename to res/trainers/trainer_sailor_marc_rematch_1.json diff --git a/res/trainers/0741.json b/res/trainers/trainer_sailor_marc_rematch_2.json similarity index 100% rename from res/trainers/0741.json rename to res/trainers/trainer_sailor_marc_rematch_2.json diff --git a/res/trainers/0110.json b/res/trainers/trainer_sailor_paul.json similarity index 100% rename from res/trainers/0110.json rename to res/trainers/trainer_sailor_paul.json diff --git a/res/trainers/0483.json b/res/trainers/trainer_sailor_samson.json similarity index 100% rename from res/trainers/0483.json rename to res/trainers/trainer_sailor_samson.json diff --git a/res/trainers/0338.json b/res/trainers/trainer_sailor_skyler.json similarity index 100% rename from res/trainers/0338.json rename to res/trainers/trainer_sailor_skyler.json diff --git a/res/trainers/0482.json b/res/trainers/trainer_sailor_zachariah.json similarity index 100% rename from res/trainers/0482.json rename to res/trainers/trainer_sailor_zachariah.json diff --git a/res/trainers/0742.json b/res/trainers/trainer_sailor_zachariah_rematch.json similarity index 100% rename from res/trainers/0742.json rename to res/trainers/trainer_sailor_zachariah_rematch.json diff --git a/res/trainers/0340.json b/res/trainers/trainer_school_kid_chance.json similarity index 100% rename from res/trainers/0340.json rename to res/trainers/trainer_school_kid_chance.json diff --git a/res/trainers/0345.json b/res/trainers/trainer_school_kid_christine.json similarity index 100% rename from res/trainers/0345.json rename to res/trainers/trainer_school_kid_christine.json diff --git a/res/trainers/0548.json b/res/trainers/trainer_school_kid_esteban.json similarity index 100% rename from res/trainers/0548.json rename to res/trainers/trainer_school_kid_esteban.json diff --git a/res/trainers/0341.json b/res/trainers/trainer_school_kid_forrest.json similarity index 100% rename from res/trainers/0341.json rename to res/trainers/trainer_school_kid_forrest.json diff --git a/res/trainers/0342.json b/res/trainers/trainer_school_kid_harrison.json similarity index 100% rename from res/trainers/0342.json rename to res/trainers/trainer_school_kid_harrison.json diff --git a/res/trainers/0343.json b/res/trainers/trainer_school_kid_mackenzie.json similarity index 100% rename from res/trainers/0343.json rename to res/trainers/trainer_school_kid_mackenzie.json diff --git a/res/trainers/0344.json b/res/trainers/trainer_school_kid_tiera.json similarity index 100% rename from res/trainers/0344.json rename to res/trainers/trainer_school_kid_tiera.json diff --git a/res/trainers/0829.json b/res/trainers/trainer_scientist_darrius.json similarity index 100% rename from res/trainers/0829.json rename to res/trainers/trainer_scientist_darrius.json diff --git a/res/trainers/0549.json b/res/trainers/trainer_scientist_emilio.json similarity index 100% rename from res/trainers/0549.json rename to res/trainers/trainer_scientist_emilio.json diff --git a/res/trainers/0830.json b/res/trainers/trainer_scientist_fredrick.json similarity index 100% rename from res/trainers/0830.json rename to res/trainers/trainer_scientist_fredrick.json diff --git a/res/trainers/0486.json b/res/trainers/trainer_scientist_shaun.json similarity index 100% rename from res/trainers/0486.json rename to res/trainers/trainer_scientist_shaun.json diff --git a/res/trainers/0743.json b/res/trainers/trainer_scientist_shaun_rematch_1.json similarity index 100% rename from res/trainers/0743.json rename to res/trainers/trainer_scientist_shaun_rematch_1.json diff --git a/res/trainers/0744.json b/res/trainers/trainer_scientist_shaun_rematch_2.json similarity index 100% rename from res/trainers/0744.json rename to res/trainers/trainer_scientist_shaun_rematch_2.json diff --git a/res/trainers/0745.json b/res/trainers/trainer_scientist_shaun_rematch_3.json similarity index 100% rename from res/trainers/0745.json rename to res/trainers/trainer_scientist_shaun_rematch_3.json diff --git a/res/trainers/0099.json b/res/trainers/trainer_scientist_stefano.json similarity index 100% rename from res/trainers/0099.json rename to res/trainers/trainer_scientist_stefano.json diff --git a/res/trainers/0831.json b/res/trainers/trainer_scientist_travon.json similarity index 100% rename from res/trainers/0831.json rename to res/trainers/trainer_scientist_travon.json diff --git a/res/trainers/0139.json b/res/trainers/trainer_skier_andrea.json similarity index 100% rename from res/trainers/0139.json rename to res/trainers/trainer_skier_andrea.json diff --git a/res/trainers/0755.json b/res/trainers/trainer_skier_andrea_rematch_1.json similarity index 100% rename from res/trainers/0755.json rename to res/trainers/trainer_skier_andrea_rematch_1.json diff --git a/res/trainers/0756.json b/res/trainers/trainer_skier_andrea_rematch_2.json similarity index 100% rename from res/trainers/0756.json rename to res/trainers/trainer_skier_andrea_rematch_2.json diff --git a/res/trainers/0143.json b/res/trainers/trainer_skier_bjorn.json similarity index 100% rename from res/trainers/0143.json rename to res/trainers/trainer_skier_bjorn.json diff --git a/res/trainers/0753.json b/res/trainers/trainer_skier_bjorn_rematch_1.json similarity index 100% rename from res/trainers/0753.json rename to res/trainers/trainer_skier_bjorn_rematch_1.json diff --git a/res/trainers/0754.json b/res/trainers/trainer_skier_bjorn_rematch_2.json similarity index 100% rename from res/trainers/0754.json rename to res/trainers/trainer_skier_bjorn_rematch_2.json diff --git a/res/trainers/0136.json b/res/trainers/trainer_skier_bradley.json similarity index 100% rename from res/trainers/0136.json rename to res/trainers/trainer_skier_bradley.json diff --git a/res/trainers/0137.json b/res/trainers/trainer_skier_edward.json similarity index 100% rename from res/trainers/0137.json rename to res/trainers/trainer_skier_edward.json diff --git a/res/trainers/0751.json b/res/trainers/trainer_skier_edward_rematch_1.json similarity index 100% rename from res/trainers/0751.json rename to res/trainers/trainer_skier_edward_rematch_1.json diff --git a/res/trainers/0752.json b/res/trainers/trainer_skier_edward_rematch_2.json similarity index 100% rename from res/trainers/0752.json rename to res/trainers/trainer_skier_edward_rematch_2.json diff --git a/res/trainers/0138.json b/res/trainers/trainer_skier_kaitlyn.json similarity index 100% rename from res/trainers/0138.json rename to res/trainers/trainer_skier_kaitlyn.json diff --git a/res/trainers/0144.json b/res/trainers/trainer_skier_lexie.json similarity index 100% rename from res/trainers/0144.json rename to res/trainers/trainer_skier_lexie.json diff --git a/res/trainers/0145.json b/res/trainers/trainer_skier_madison.json similarity index 100% rename from res/trainers/0145.json rename to res/trainers/trainer_skier_madison.json diff --git a/res/trainers/0757.json b/res/trainers/trainer_skier_madison_rematch_1.json similarity index 100% rename from res/trainers/0757.json rename to res/trainers/trainer_skier_madison_rematch_1.json diff --git a/res/trainers/0758.json b/res/trainers/trainer_skier_madison_rematch_2.json similarity index 100% rename from res/trainers/0758.json rename to res/trainers/trainer_skier_madison_rematch_2.json diff --git a/res/trainers/0142.json b/res/trainers/trainer_skier_shawn.json similarity index 100% rename from res/trainers/0142.json rename to res/trainers/trainer_skier_shawn.json diff --git a/res/trainers/0543.json b/res/trainers/trainer_socialite_rebecca.json similarity index 100% rename from res/trainers/0543.json rename to res/trainers/trainer_socialite_rebecca.json diff --git a/res/trainers/0085.json b/res/trainers/trainer_socialite_reina.json similarity index 100% rename from res/trainers/0085.json rename to res/trainers/trainer_socialite_reina.json diff --git a/res/trainers/0701.json b/res/trainers/trainer_socialite_reina_rematch_1.json similarity index 100% rename from res/trainers/0701.json rename to res/trainers/trainer_socialite_reina_rematch_1.json diff --git a/res/trainers/0702.json b/res/trainers/trainer_socialite_reina_rematch_2.json similarity index 100% rename from res/trainers/0702.json rename to res/trainers/trainer_socialite_reina_rematch_2.json diff --git a/res/trainers/0159.json b/res/trainers/trainer_swimmer_adrian.json similarity index 100% rename from res/trainers/0159.json rename to res/trainers/trainer_swimmer_adrian.json diff --git a/res/trainers/0190.json b/res/trainers/trainer_swimmer_aubree.json similarity index 100% rename from res/trainers/0190.json rename to res/trainers/trainer_swimmer_aubree.json diff --git a/res/trainers/0193.json b/res/trainers/trainer_swimmer_cassandra.json similarity index 100% rename from res/trainers/0193.json rename to res/trainers/trainer_swimmer_cassandra.json diff --git a/res/trainers/0494.json b/res/trainers/trainer_swimmer_claire.json similarity index 100% rename from res/trainers/0494.json rename to res/trainers/trainer_swimmer_claire.json diff --git a/res/trainers/0186.json b/res/trainers/trainer_swimmer_colton.json similarity index 100% rename from res/trainers/0186.json rename to res/trainers/trainer_swimmer_colton.json diff --git a/res/trainers/0192.json b/res/trainers/trainer_swimmer_crystal.json similarity index 100% rename from res/trainers/0192.json rename to res/trainers/trainer_swimmer_crystal.json diff --git a/res/trainers/0763.json b/res/trainers/trainer_swimmer_crystal_rematch.json similarity index 100% rename from res/trainers/0763.json rename to res/trainers/trainer_swimmer_crystal_rematch.json diff --git a/res/trainers/0166.json b/res/trainers/trainer_swimmer_dillon.json similarity index 100% rename from res/trainers/0166.json rename to res/trainers/trainer_swimmer_dillon.json diff --git a/res/trainers/0163.json b/res/trainers/trainer_swimmer_erica.json similarity index 100% rename from res/trainers/0163.json rename to res/trainers/trainer_swimmer_erica.json diff --git a/res/trainers/0160.json b/res/trainers/trainer_swimmer_erik.json similarity index 100% rename from res/trainers/0160.json rename to res/trainers/trainer_swimmer_erik.json diff --git a/res/trainers/0104.json b/res/trainers/trainer_swimmer_evan.json similarity index 100% rename from res/trainers/0104.json rename to res/trainers/trainer_swimmer_evan.json diff --git a/res/trainers/0185.json b/res/trainers/trainer_swimmer_francisco.json similarity index 100% rename from res/trainers/0185.json rename to res/trainers/trainer_swimmer_francisco.json diff --git a/res/trainers/0760.json b/res/trainers/trainer_swimmer_francisco_rematch.json similarity index 100% rename from res/trainers/0760.json rename to res/trainers/trainer_swimmer_francisco_rematch.json diff --git a/res/trainers/0194.json b/res/trainers/trainer_swimmer_gabrielle.json similarity index 100% rename from res/trainers/0194.json rename to res/trainers/trainer_swimmer_gabrielle.json diff --git a/res/trainers/0597.json b/res/trainers/trainer_swimmer_glenn.json similarity index 100% rename from res/trainers/0597.json rename to res/trainers/trainer_swimmer_glenn.json diff --git a/res/trainers/0761.json b/res/trainers/trainer_swimmer_glenn_rematch.json similarity index 100% rename from res/trainers/0761.json rename to res/trainers/trainer_swimmer_glenn_rematch.json diff --git a/res/trainers/0105.json b/res/trainers/trainer_swimmer_haley.json similarity index 100% rename from res/trainers/0105.json rename to res/trainers/trainer_swimmer_haley.json diff --git a/res/trainers/0162.json b/res/trainers/trainer_swimmer_jessica.json similarity index 100% rename from res/trainers/0162.json rename to res/trainers/trainer_swimmer_jessica.json diff --git a/res/trainers/0601.json b/res/trainers/trainer_swimmer_joanna.json similarity index 100% rename from res/trainers/0601.json rename to res/trainers/trainer_swimmer_joanna.json diff --git a/res/trainers/0764.json b/res/trainers/trainer_swimmer_joanna_rematch.json similarity index 100% rename from res/trainers/0764.json rename to res/trainers/trainer_swimmer_joanna_rematch.json diff --git a/res/trainers/0164.json b/res/trainers/trainer_swimmer_katelyn.json similarity index 100% rename from res/trainers/0164.json rename to res/trainers/trainer_swimmer_katelyn.json diff --git a/res/trainers/0598.json b/res/trainers/trainer_swimmer_kurt.json similarity index 100% rename from res/trainers/0598.json rename to res/trainers/trainer_swimmer_kurt.json diff --git a/res/trainers/0604.json b/res/trainers/trainer_swimmer_lydia.json similarity index 100% rename from res/trainers/0604.json rename to res/trainers/trainer_swimmer_lydia.json diff --git a/res/trainers/0603.json b/res/trainers/trainer_swimmer_mallory.json similarity index 100% rename from res/trainers/0603.json rename to res/trainers/trainer_swimmer_mallory.json diff --git a/res/trainers/0106.json b/res/trainers/trainer_swimmer_mary.json similarity index 100% rename from res/trainers/0106.json rename to res/trainers/trainer_swimmer_mary.json diff --git a/res/trainers/0189.json b/res/trainers/trainer_swimmer_miranda.json similarity index 100% rename from res/trainers/0189.json rename to res/trainers/trainer_swimmer_miranda.json diff --git a/res/trainers/0762.json b/res/trainers/trainer_swimmer_miranda_rematch.json similarity index 100% rename from res/trainers/0762.json rename to res/trainers/trainer_swimmer_miranda_rematch.json diff --git a/res/trainers/0188.json b/res/trainers/trainer_swimmer_oscar.json similarity index 100% rename from res/trainers/0188.json rename to res/trainers/trainer_swimmer_oscar.json diff --git a/res/trainers/0191.json b/res/trainers/trainer_swimmer_paige.json similarity index 100% rename from res/trainers/0191.json rename to res/trainers/trainer_swimmer_paige.json diff --git a/res/trainers/0184.json b/res/trainers/trainer_swimmer_ricardo.json similarity index 100% rename from res/trainers/0184.json rename to res/trainers/trainer_swimmer_ricardo.json diff --git a/res/trainers/0599.json b/res/trainers/trainer_swimmer_sam.json similarity index 100% rename from res/trainers/0599.json rename to res/trainers/trainer_swimmer_sam.json diff --git a/res/trainers/0103.json b/res/trainers/trainer_swimmer_sheltin.json similarity index 100% rename from res/trainers/0103.json rename to res/trainers/trainer_swimmer_sheltin.json diff --git a/res/trainers/0602.json b/res/trainers/trainer_swimmer_sophia.json similarity index 100% rename from res/trainers/0602.json rename to res/trainers/trainer_swimmer_sophia.json diff --git a/res/trainers/0187.json b/res/trainers/trainer_swimmer_troy.json similarity index 100% rename from res/trainers/0187.json rename to res/trainers/trainer_swimmer_troy.json diff --git a/res/trainers/0167.json b/res/trainers/trainer_swimmer_vanessa.json similarity index 100% rename from res/trainers/0167.json rename to res/trainers/trainer_swimmer_vanessa.json diff --git a/res/trainers/0161.json b/res/trainers/trainer_swimmer_vincent.json similarity index 100% rename from res/trainers/0161.json rename to res/trainers/trainer_swimmer_vincent.json diff --git a/res/trainers/0600.json b/res/trainers/trainer_swimmer_wade.json similarity index 100% rename from res/trainers/0600.json rename to res/trainers/trainer_swimmer_wade.json diff --git a/res/trainers/0183.json b/res/trainers/trainer_swimmer_wesley.json similarity index 100% rename from res/trainers/0183.json rename to res/trainers/trainer_swimmer_wesley.json diff --git a/res/trainers/0759.json b/res/trainers/trainer_swimmer_wesley_rematch.json similarity index 100% rename from res/trainers/0759.json rename to res/trainers/trainer_swimmer_wesley_rematch.json diff --git a/res/trainers/0862.json b/res/trainers/trainer_trainer_buck_battleground.json similarity index 100% rename from res/trainers/0862.json rename to res/trainers/trainer_trainer_buck_battleground.json diff --git a/res/trainers/0611.json b/res/trainers/trainer_trainer_buck_buck.json similarity index 100% rename from res/trainers/0611.json rename to res/trainers/trainer_trainer_buck_buck.json diff --git a/res/trainers/0865.json b/res/trainers/trainer_trainer_cheryl_battleground.json similarity index 100% rename from res/trainers/0865.json rename to res/trainers/trainer_trainer_cheryl_battleground.json diff --git a/res/trainers/0608.json b/res/trainers/trainer_trainer_cheryl_cheryl.json similarity index 100% rename from res/trainers/0608.json rename to res/trainers/trainer_trainer_cheryl_cheryl.json diff --git a/res/trainers/0863.json b/res/trainers/trainer_trainer_marley_battleground.json similarity index 100% rename from res/trainers/0863.json rename to res/trainers/trainer_trainer_marley_battleground.json diff --git a/res/trainers/0610.json b/res/trainers/trainer_trainer_marley_marley.json similarity index 100% rename from res/trainers/0610.json rename to res/trainers/trainer_trainer_marley_marley.json diff --git a/res/trainers/0864.json b/res/trainers/trainer_trainer_mira_battleground.json similarity index 100% rename from res/trainers/0864.json rename to res/trainers/trainer_trainer_mira_battleground.json diff --git a/res/trainers/0612.json b/res/trainers/trainer_trainer_mira_mira.json similarity index 100% rename from res/trainers/0612.json rename to res/trainers/trainer_trainer_mira_mira.json diff --git a/res/trainers/0861.json b/res/trainers/trainer_trainer_riley_battleground.json similarity index 100% rename from res/trainers/0861.json rename to res/trainers/trainer_trainer_riley_battleground.json diff --git a/res/trainers/0609.json b/res/trainers/trainer_trainer_riley_riley.json similarity index 100% rename from res/trainers/0609.json rename to res/trainers/trainer_trainer_riley_riley.json diff --git a/res/trainers/0498.json b/res/trainers/trainer_tuber_caitlyn.json similarity index 100% rename from res/trainers/0498.json rename to res/trainers/trainer_tuber_caitlyn.json diff --git a/res/trainers/0108.json b/res/trainers/trainer_tuber_chelsea.json similarity index 100% rename from res/trainers/0108.json rename to res/trainers/trainer_tuber_chelsea.json diff --git a/res/trainers/0773.json b/res/trainers/trainer_tuber_chelsea_rematch_1.json similarity index 100% rename from res/trainers/0773.json rename to res/trainers/trainer_tuber_chelsea_rematch_1.json diff --git a/res/trainers/0775.json b/res/trainers/trainer_tuber_chelsea_rematch_2.json similarity index 100% rename from res/trainers/0775.json rename to res/trainers/trainer_tuber_chelsea_rematch_2.json diff --git a/res/trainers/0359.json b/res/trainers/trainer_tuber_conner.json similarity index 100% rename from res/trainers/0359.json rename to res/trainers/trainer_tuber_conner.json diff --git a/res/trainers/0361.json b/res/trainers/trainer_tuber_holly.json similarity index 100% rename from res/trainers/0361.json rename to res/trainers/trainer_tuber_holly.json diff --git a/res/trainers/0497.json b/res/trainers/trainer_tuber_jacky.json similarity index 100% rename from res/trainers/0497.json rename to res/trainers/trainer_tuber_jacky.json diff --git a/res/trainers/0107.json b/res/trainers/trainer_tuber_jared.json similarity index 100% rename from res/trainers/0107.json rename to res/trainers/trainer_tuber_jared.json diff --git a/res/trainers/0771.json b/res/trainers/trainer_tuber_jared_rematch_1.json similarity index 100% rename from res/trainers/0771.json rename to res/trainers/trainer_tuber_jared_rematch_1.json diff --git a/res/trainers/0772.json b/res/trainers/trainer_tuber_jared_rematch_2.json similarity index 100% rename from res/trainers/0772.json rename to res/trainers/trainer_tuber_jared_rematch_2.json diff --git a/res/trainers/0360.json b/res/trainers/trainer_tuber_mariel.json similarity index 100% rename from res/trainers/0360.json rename to res/trainers/trainer_tuber_mariel.json diff --git a/res/trainers/0358.json b/res/trainers/trainer_tuber_trenton.json similarity index 100% rename from res/trainers/0358.json rename to res/trainers/trainer_tuber_trenton.json diff --git a/res/trainers/0294.json b/res/trainers/trainer_twins_emma_and_lil.json similarity index 100% rename from res/trainers/0294.json rename to res/trainers/trainer_twins_emma_and_lil.json diff --git a/res/trainers/0015.json b/res/trainers/trainer_twins_liv_and_liz.json similarity index 100% rename from res/trainers/0015.json rename to res/trainers/trainer_twins_liv_and_liz.json diff --git a/res/trainers/0065.json b/res/trainers/trainer_twins_teri_and_tia.json similarity index 100% rename from res/trainers/0065.json rename to res/trainers/trainer_twins_teri_and_tia.json diff --git a/res/trainers/0687.json b/res/trainers/trainer_twins_teri_and_tia_rematch_1.json similarity index 100% rename from res/trainers/0687.json rename to res/trainers/trainer_twins_teri_and_tia_rematch_1.json diff --git a/res/trainers/0688.json b/res/trainers/trainer_twins_teri_and_tia_rematch_2.json similarity index 100% rename from res/trainers/0688.json rename to res/trainers/trainer_twins_teri_and_tia_rematch_2.json diff --git a/res/trainers/0005.json b/res/trainers/trainer_unknown_005.json similarity index 100% rename from res/trainers/0005.json rename to res/trainers/trainer_unknown_005.json diff --git a/res/trainers/0006.json b/res/trainers/trainer_unknown_006.json similarity index 100% rename from res/trainers/0006.json rename to res/trainers/trainer_unknown_006.json diff --git a/res/trainers/0007.json b/res/trainers/trainer_unknown_007.json similarity index 100% rename from res/trainers/0007.json rename to res/trainers/trainer_unknown_007.json diff --git a/res/trainers/0008.json b/res/trainers/trainer_unknown_008.json similarity index 100% rename from res/trainers/0008.json rename to res/trainers/trainer_unknown_008.json diff --git a/res/trainers/0009.json b/res/trainers/trainer_unknown_009.json similarity index 100% rename from res/trainers/0009.json rename to res/trainers/trainer_unknown_009.json diff --git a/res/trainers/0050.json b/res/trainers/trainer_unknown_050.json similarity index 100% rename from res/trainers/0050.json rename to res/trainers/trainer_unknown_050.json diff --git a/res/trainers/0051.json b/res/trainers/trainer_unknown_051.json similarity index 100% rename from res/trainers/0051.json rename to res/trainers/trainer_unknown_051.json diff --git a/res/trainers/0052.json b/res/trainers/trainer_unknown_052.json similarity index 100% rename from res/trainers/0052.json rename to res/trainers/trainer_unknown_052.json diff --git a/res/trainers/0054.json b/res/trainers/trainer_unknown_054.json similarity index 100% rename from res/trainers/0054.json rename to res/trainers/trainer_unknown_054.json diff --git a/res/trainers/0058.json b/res/trainers/trainer_unknown_058.json similarity index 100% rename from res/trainers/0058.json rename to res/trainers/trainer_unknown_058.json diff --git a/res/trainers/0059.json b/res/trainers/trainer_unknown_059.json similarity index 100% rename from res/trainers/0059.json rename to res/trainers/trainer_unknown_059.json diff --git a/res/trainers/0060.json b/res/trainers/trainer_unknown_060.json similarity index 100% rename from res/trainers/0060.json rename to res/trainers/trainer_unknown_060.json diff --git a/res/trainers/0061.json b/res/trainers/trainer_unknown_061.json similarity index 100% rename from res/trainers/0061.json rename to res/trainers/trainer_unknown_061.json diff --git a/res/trainers/0062.json b/res/trainers/trainer_unknown_062.json similarity index 100% rename from res/trainers/0062.json rename to res/trainers/trainer_unknown_062.json diff --git a/res/trainers/0063.json b/res/trainers/trainer_unknown_063.json similarity index 100% rename from res/trainers/0063.json rename to res/trainers/trainer_unknown_063.json diff --git a/res/trainers/0064.json b/res/trainers/trainer_unknown_064.json similarity index 100% rename from res/trainers/0064.json rename to res/trainers/trainer_unknown_064.json diff --git a/res/trainers/0077.json b/res/trainers/trainer_unknown_077.json similarity index 100% rename from res/trainers/0077.json rename to res/trainers/trainer_unknown_077.json diff --git a/res/trainers/0086.json b/res/trainers/trainer_unknown_086.json similarity index 100% rename from res/trainers/0086.json rename to res/trainers/trainer_unknown_086.json diff --git a/res/trainers/0087.json b/res/trainers/trainer_unknown_087.json similarity index 100% rename from res/trainers/0087.json rename to res/trainers/trainer_unknown_087.json diff --git a/res/trainers/0097.json b/res/trainers/trainer_unknown_097.json similarity index 100% rename from res/trainers/0097.json rename to res/trainers/trainer_unknown_097.json diff --git a/res/trainers/0098.json b/res/trainers/trainer_unknown_098.json similarity index 100% rename from res/trainers/0098.json rename to res/trainers/trainer_unknown_098.json diff --git a/res/trainers/0100.json b/res/trainers/trainer_unknown_100.json similarity index 100% rename from res/trainers/0100.json rename to res/trainers/trainer_unknown_100.json diff --git a/res/trainers/0101.json b/res/trainers/trainer_unknown_101.json similarity index 100% rename from res/trainers/0101.json rename to res/trainers/trainer_unknown_101.json diff --git a/res/trainers/0109.json b/res/trainers/trainer_unknown_109.json similarity index 100% rename from res/trainers/0109.json rename to res/trainers/trainer_unknown_109.json diff --git a/res/trainers/0112.json b/res/trainers/trainer_unknown_112.json similarity index 100% rename from res/trainers/0112.json rename to res/trainers/trainer_unknown_112.json diff --git a/res/trainers/0115.json b/res/trainers/trainer_unknown_115.json similarity index 100% rename from res/trainers/0115.json rename to res/trainers/trainer_unknown_115.json diff --git a/res/trainers/0116.json b/res/trainers/trainer_unknown_116.json similarity index 100% rename from res/trainers/0116.json rename to res/trainers/trainer_unknown_116.json diff --git a/res/trainers/0117.json b/res/trainers/trainer_unknown_117.json similarity index 100% rename from res/trainers/0117.json rename to res/trainers/trainer_unknown_117.json diff --git a/res/trainers/0118.json b/res/trainers/trainer_unknown_118.json similarity index 100% rename from res/trainers/0118.json rename to res/trainers/trainer_unknown_118.json diff --git a/res/trainers/0122.json b/res/trainers/trainer_unknown_122.json similarity index 100% rename from res/trainers/0122.json rename to res/trainers/trainer_unknown_122.json diff --git a/res/trainers/0123.json b/res/trainers/trainer_unknown_123.json similarity index 100% rename from res/trainers/0123.json rename to res/trainers/trainer_unknown_123.json diff --git a/res/trainers/0124.json b/res/trainers/trainer_unknown_124.json similarity index 100% rename from res/trainers/0124.json rename to res/trainers/trainer_unknown_124.json diff --git a/res/trainers/0125.json b/res/trainers/trainer_unknown_125.json similarity index 100% rename from res/trainers/0125.json rename to res/trainers/trainer_unknown_125.json diff --git a/res/trainers/0126.json b/res/trainers/trainer_unknown_126.json similarity index 100% rename from res/trainers/0126.json rename to res/trainers/trainer_unknown_126.json diff --git a/res/trainers/0131.json b/res/trainers/trainer_unknown_131.json similarity index 100% rename from res/trainers/0131.json rename to res/trainers/trainer_unknown_131.json diff --git a/res/trainers/0149.json b/res/trainers/trainer_unknown_149.json similarity index 100% rename from res/trainers/0149.json rename to res/trainers/trainer_unknown_149.json diff --git a/res/trainers/0150.json b/res/trainers/trainer_unknown_150.json similarity index 100% rename from res/trainers/0150.json rename to res/trainers/trainer_unknown_150.json diff --git a/res/trainers/0151.json b/res/trainers/trainer_unknown_151.json similarity index 100% rename from res/trainers/0151.json rename to res/trainers/trainer_unknown_151.json diff --git a/res/trainers/0152.json b/res/trainers/trainer_unknown_152.json similarity index 100% rename from res/trainers/0152.json rename to res/trainers/trainer_unknown_152.json diff --git a/res/trainers/0155.json b/res/trainers/trainer_unknown_155.json similarity index 100% rename from res/trainers/0155.json rename to res/trainers/trainer_unknown_155.json diff --git a/res/trainers/0156.json b/res/trainers/trainer_unknown_156.json similarity index 100% rename from res/trainers/0156.json rename to res/trainers/trainer_unknown_156.json diff --git a/res/trainers/0157.json b/res/trainers/trainer_unknown_157.json similarity index 100% rename from res/trainers/0157.json rename to res/trainers/trainer_unknown_157.json diff --git a/res/trainers/0158.json b/res/trainers/trainer_unknown_158.json similarity index 100% rename from res/trainers/0158.json rename to res/trainers/trainer_unknown_158.json diff --git a/res/trainers/0165.json b/res/trainers/trainer_unknown_165.json similarity index 100% rename from res/trainers/0165.json rename to res/trainers/trainer_unknown_165.json diff --git a/res/trainers/0169.json b/res/trainers/trainer_unknown_169.json similarity index 100% rename from res/trainers/0169.json rename to res/trainers/trainer_unknown_169.json diff --git a/res/trainers/0176.json b/res/trainers/trainer_unknown_176.json similarity index 100% rename from res/trainers/0176.json rename to res/trainers/trainer_unknown_176.json diff --git a/res/trainers/0177.json b/res/trainers/trainer_unknown_177.json similarity index 100% rename from res/trainers/0177.json rename to res/trainers/trainer_unknown_177.json diff --git a/res/trainers/0178.json b/res/trainers/trainer_unknown_178.json similarity index 100% rename from res/trainers/0178.json rename to res/trainers/trainer_unknown_178.json diff --git a/res/trainers/0179.json b/res/trainers/trainer_unknown_179.json similarity index 100% rename from res/trainers/0179.json rename to res/trainers/trainer_unknown_179.json diff --git a/res/trainers/0181.json b/res/trainers/trainer_unknown_181.json similarity index 100% rename from res/trainers/0181.json rename to res/trainers/trainer_unknown_181.json diff --git a/res/trainers/0182.json b/res/trainers/trainer_unknown_182.json similarity index 100% rename from res/trainers/0182.json rename to res/trainers/trainer_unknown_182.json diff --git a/res/trainers/0197.json b/res/trainers/trainer_unknown_197.json similarity index 100% rename from res/trainers/0197.json rename to res/trainers/trainer_unknown_197.json diff --git a/res/trainers/0198.json b/res/trainers/trainer_unknown_198.json similarity index 100% rename from res/trainers/0198.json rename to res/trainers/trainer_unknown_198.json diff --git a/res/trainers/0199.json b/res/trainers/trainer_unknown_199.json similarity index 100% rename from res/trainers/0199.json rename to res/trainers/trainer_unknown_199.json diff --git a/res/trainers/0200.json b/res/trainers/trainer_unknown_200.json similarity index 100% rename from res/trainers/0200.json rename to res/trainers/trainer_unknown_200.json diff --git a/res/trainers/0207.json b/res/trainers/trainer_unknown_207.json similarity index 100% rename from res/trainers/0207.json rename to res/trainers/trainer_unknown_207.json diff --git a/res/trainers/0208.json b/res/trainers/trainer_unknown_208.json similarity index 100% rename from res/trainers/0208.json rename to res/trainers/trainer_unknown_208.json diff --git a/res/trainers/0209.json b/res/trainers/trainer_unknown_209.json similarity index 100% rename from res/trainers/0209.json rename to res/trainers/trainer_unknown_209.json diff --git a/res/trainers/0210.json b/res/trainers/trainer_unknown_210.json similarity index 100% rename from res/trainers/0210.json rename to res/trainers/trainer_unknown_210.json diff --git a/res/trainers/0211.json b/res/trainers/trainer_unknown_211.json similarity index 100% rename from res/trainers/0211.json rename to res/trainers/trainer_unknown_211.json diff --git a/res/trainers/0212.json b/res/trainers/trainer_unknown_212.json similarity index 100% rename from res/trainers/0212.json rename to res/trainers/trainer_unknown_212.json diff --git a/res/trainers/0213.json b/res/trainers/trainer_unknown_213.json similarity index 100% rename from res/trainers/0213.json rename to res/trainers/trainer_unknown_213.json diff --git a/res/trainers/0214.json b/res/trainers/trainer_unknown_214.json similarity index 100% rename from res/trainers/0214.json rename to res/trainers/trainer_unknown_214.json diff --git a/res/trainers/0215.json b/res/trainers/trainer_unknown_215.json similarity index 100% rename from res/trainers/0215.json rename to res/trainers/trainer_unknown_215.json diff --git a/res/trainers/0216.json b/res/trainers/trainer_unknown_216.json similarity index 100% rename from res/trainers/0216.json rename to res/trainers/trainer_unknown_216.json diff --git a/res/trainers/0217.json b/res/trainers/trainer_unknown_217.json similarity index 100% rename from res/trainers/0217.json rename to res/trainers/trainer_unknown_217.json diff --git a/res/trainers/0218.json b/res/trainers/trainer_unknown_218.json similarity index 100% rename from res/trainers/0218.json rename to res/trainers/trainer_unknown_218.json diff --git a/res/trainers/0219.json b/res/trainers/trainer_unknown_219.json similarity index 100% rename from res/trainers/0219.json rename to res/trainers/trainer_unknown_219.json diff --git a/res/trainers/0220.json b/res/trainers/trainer_unknown_220.json similarity index 100% rename from res/trainers/0220.json rename to res/trainers/trainer_unknown_220.json diff --git a/res/trainers/0221.json b/res/trainers/trainer_unknown_221.json similarity index 100% rename from res/trainers/0221.json rename to res/trainers/trainer_unknown_221.json diff --git a/res/trainers/0222.json b/res/trainers/trainer_unknown_222.json similarity index 100% rename from res/trainers/0222.json rename to res/trainers/trainer_unknown_222.json diff --git a/res/trainers/0223.json b/res/trainers/trainer_unknown_223.json similarity index 100% rename from res/trainers/0223.json rename to res/trainers/trainer_unknown_223.json diff --git a/res/trainers/0238.json b/res/trainers/trainer_unknown_238.json similarity index 100% rename from res/trainers/0238.json rename to res/trainers/trainer_unknown_238.json diff --git a/res/trainers/0239.json b/res/trainers/trainer_unknown_239.json similarity index 100% rename from res/trainers/0239.json rename to res/trainers/trainer_unknown_239.json diff --git a/res/trainers/0241.json b/res/trainers/trainer_unknown_241.json similarity index 100% rename from res/trainers/0241.json rename to res/trainers/trainer_unknown_241.json diff --git a/res/trainers/0242.json b/res/trainers/trainer_unknown_242.json similarity index 100% rename from res/trainers/0242.json rename to res/trainers/trainer_unknown_242.json diff --git a/res/trainers/0243.json b/res/trainers/trainer_unknown_243.json similarity index 100% rename from res/trainers/0243.json rename to res/trainers/trainer_unknown_243.json diff --git a/res/trainers/0251.json b/res/trainers/trainer_unknown_251.json similarity index 100% rename from res/trainers/0251.json rename to res/trainers/trainer_unknown_251.json diff --git a/res/trainers/0252.json b/res/trainers/trainer_unknown_252.json similarity index 100% rename from res/trainers/0252.json rename to res/trainers/trainer_unknown_252.json diff --git a/res/trainers/0253.json b/res/trainers/trainer_unknown_253.json similarity index 100% rename from res/trainers/0253.json rename to res/trainers/trainer_unknown_253.json diff --git a/res/trainers/0254.json b/res/trainers/trainer_unknown_254.json similarity index 100% rename from res/trainers/0254.json rename to res/trainers/trainer_unknown_254.json diff --git a/res/trainers/0255.json b/res/trainers/trainer_unknown_255.json similarity index 100% rename from res/trainers/0255.json rename to res/trainers/trainer_unknown_255.json diff --git a/res/trainers/0291.json b/res/trainers/trainer_unknown_291.json similarity index 100% rename from res/trainers/0291.json rename to res/trainers/trainer_unknown_291.json diff --git a/res/trainers/0321.json b/res/trainers/trainer_unknown_321.json similarity index 100% rename from res/trainers/0321.json rename to res/trainers/trainer_unknown_321.json diff --git a/res/trainers/0334.json b/res/trainers/trainer_unknown_334.json similarity index 100% rename from res/trainers/0334.json rename to res/trainers/trainer_unknown_334.json diff --git a/res/trainers/0336.json b/res/trainers/trainer_unknown_336.json similarity index 100% rename from res/trainers/0336.json rename to res/trainers/trainer_unknown_336.json diff --git a/res/trainers/0347.json b/res/trainers/trainer_unknown_347.json similarity index 100% rename from res/trainers/0347.json rename to res/trainers/trainer_unknown_347.json diff --git a/res/trainers/0349.json b/res/trainers/trainer_unknown_349.json similarity index 100% rename from res/trainers/0349.json rename to res/trainers/trainer_unknown_349.json diff --git a/res/trainers/0350.json b/res/trainers/trainer_unknown_350.json similarity index 100% rename from res/trainers/0350.json rename to res/trainers/trainer_unknown_350.json diff --git a/res/trainers/0351.json b/res/trainers/trainer_unknown_351.json similarity index 100% rename from res/trainers/0351.json rename to res/trainers/trainer_unknown_351.json diff --git a/res/trainers/0352.json b/res/trainers/trainer_unknown_352.json similarity index 100% rename from res/trainers/0352.json rename to res/trainers/trainer_unknown_352.json diff --git a/res/trainers/0353.json b/res/trainers/trainer_unknown_353.json similarity index 100% rename from res/trainers/0353.json rename to res/trainers/trainer_unknown_353.json diff --git a/res/trainers/0354.json b/res/trainers/trainer_unknown_354.json similarity index 100% rename from res/trainers/0354.json rename to res/trainers/trainer_unknown_354.json diff --git a/res/trainers/0363.json b/res/trainers/trainer_unknown_363.json similarity index 100% rename from res/trainers/0363.json rename to res/trainers/trainer_unknown_363.json diff --git a/res/trainers/0364.json b/res/trainers/trainer_unknown_364.json similarity index 100% rename from res/trainers/0364.json rename to res/trainers/trainer_unknown_364.json diff --git a/res/trainers/0365.json b/res/trainers/trainer_unknown_365.json similarity index 100% rename from res/trainers/0365.json rename to res/trainers/trainer_unknown_365.json diff --git a/res/trainers/0368.json b/res/trainers/trainer_unknown_368.json similarity index 100% rename from res/trainers/0368.json rename to res/trainers/trainer_unknown_368.json diff --git a/res/trainers/0369.json b/res/trainers/trainer_unknown_369.json similarity index 100% rename from res/trainers/0369.json rename to res/trainers/trainer_unknown_369.json diff --git a/res/trainers/0370.json b/res/trainers/trainer_unknown_370.json similarity index 100% rename from res/trainers/0370.json rename to res/trainers/trainer_unknown_370.json diff --git a/res/trainers/0371.json b/res/trainers/trainer_unknown_371.json similarity index 100% rename from res/trainers/0371.json rename to res/trainers/trainer_unknown_371.json diff --git a/res/trainers/0374.json b/res/trainers/trainer_unknown_374.json similarity index 100% rename from res/trainers/0374.json rename to res/trainers/trainer_unknown_374.json diff --git a/res/trainers/0375.json b/res/trainers/trainer_unknown_375.json similarity index 100% rename from res/trainers/0375.json rename to res/trainers/trainer_unknown_375.json diff --git a/res/trainers/0376.json b/res/trainers/trainer_unknown_376.json similarity index 100% rename from res/trainers/0376.json rename to res/trainers/trainer_unknown_376.json diff --git a/res/trainers/0384.json b/res/trainers/trainer_unknown_384.json similarity index 100% rename from res/trainers/0384.json rename to res/trainers/trainer_unknown_384.json diff --git a/res/trainers/0385.json b/res/trainers/trainer_unknown_385.json similarity index 100% rename from res/trainers/0385.json rename to res/trainers/trainer_unknown_385.json diff --git a/res/trainers/0387.json b/res/trainers/trainer_unknown_387.json similarity index 100% rename from res/trainers/0387.json rename to res/trainers/trainer_unknown_387.json diff --git a/res/trainers/0391.json b/res/trainers/trainer_unknown_391.json similarity index 100% rename from res/trainers/0391.json rename to res/trainers/trainer_unknown_391.json diff --git a/res/trainers/0402.json b/res/trainers/trainer_unknown_402.json similarity index 100% rename from res/trainers/0402.json rename to res/trainers/trainer_unknown_402.json diff --git a/res/trainers/0411.json b/res/trainers/trainer_unknown_411.json similarity index 100% rename from res/trainers/0411.json rename to res/trainers/trainer_unknown_411.json diff --git a/res/trainers/0413.json b/res/trainers/trainer_unknown_413.json similarity index 100% rename from res/trainers/0413.json rename to res/trainers/trainer_unknown_413.json diff --git a/res/trainers/0424.json b/res/trainers/trainer_unknown_424.json similarity index 100% rename from res/trainers/0424.json rename to res/trainers/trainer_unknown_424.json diff --git a/res/trainers/0429.json b/res/trainers/trainer_unknown_429.json similarity index 100% rename from res/trainers/0429.json rename to res/trainers/trainer_unknown_429.json diff --git a/res/trainers/0431.json b/res/trainers/trainer_unknown_431.json similarity index 100% rename from res/trainers/0431.json rename to res/trainers/trainer_unknown_431.json diff --git a/res/trainers/0432.json b/res/trainers/trainer_unknown_432.json similarity index 100% rename from res/trainers/0432.json rename to res/trainers/trainer_unknown_432.json diff --git a/res/trainers/0433.json b/res/trainers/trainer_unknown_433.json similarity index 100% rename from res/trainers/0433.json rename to res/trainers/trainer_unknown_433.json diff --git a/res/trainers/0434.json b/res/trainers/trainer_unknown_434.json similarity index 100% rename from res/trainers/0434.json rename to res/trainers/trainer_unknown_434.json diff --git a/res/trainers/0435.json b/res/trainers/trainer_unknown_435.json similarity index 100% rename from res/trainers/0435.json rename to res/trainers/trainer_unknown_435.json diff --git a/res/trainers/0436.json b/res/trainers/trainer_unknown_436.json similarity index 100% rename from res/trainers/0436.json rename to res/trainers/trainer_unknown_436.json diff --git a/res/trainers/0437.json b/res/trainers/trainer_unknown_437.json similarity index 100% rename from res/trainers/0437.json rename to res/trainers/trainer_unknown_437.json diff --git a/res/trainers/0438.json b/res/trainers/trainer_unknown_438.json similarity index 100% rename from res/trainers/0438.json rename to res/trainers/trainer_unknown_438.json diff --git a/res/trainers/0439.json b/res/trainers/trainer_unknown_439.json similarity index 100% rename from res/trainers/0439.json rename to res/trainers/trainer_unknown_439.json diff --git a/res/trainers/0440.json b/res/trainers/trainer_unknown_440.json similarity index 100% rename from res/trainers/0440.json rename to res/trainers/trainer_unknown_440.json diff --git a/res/trainers/0441.json b/res/trainers/trainer_unknown_441.json similarity index 100% rename from res/trainers/0441.json rename to res/trainers/trainer_unknown_441.json diff --git a/res/trainers/0448.json b/res/trainers/trainer_unknown_448.json similarity index 100% rename from res/trainers/0448.json rename to res/trainers/trainer_unknown_448.json diff --git a/res/trainers/0449.json b/res/trainers/trainer_unknown_449.json similarity index 100% rename from res/trainers/0449.json rename to res/trainers/trainer_unknown_449.json diff --git a/res/trainers/0460.json b/res/trainers/trainer_unknown_460.json similarity index 100% rename from res/trainers/0460.json rename to res/trainers/trainer_unknown_460.json diff --git a/res/trainers/0461.json b/res/trainers/trainer_unknown_461.json similarity index 100% rename from res/trainers/0461.json rename to res/trainers/trainer_unknown_461.json diff --git a/res/trainers/0462.json b/res/trainers/trainer_unknown_462.json similarity index 100% rename from res/trainers/0462.json rename to res/trainers/trainer_unknown_462.json diff --git a/res/trainers/0463.json b/res/trainers/trainer_unknown_463.json similarity index 100% rename from res/trainers/0463.json rename to res/trainers/trainer_unknown_463.json diff --git a/res/trainers/0464.json b/res/trainers/trainer_unknown_464.json similarity index 100% rename from res/trainers/0464.json rename to res/trainers/trainer_unknown_464.json diff --git a/res/trainers/0465.json b/res/trainers/trainer_unknown_465.json similarity index 100% rename from res/trainers/0465.json rename to res/trainers/trainer_unknown_465.json diff --git a/res/trainers/0466.json b/res/trainers/trainer_unknown_466.json similarity index 100% rename from res/trainers/0466.json rename to res/trainers/trainer_unknown_466.json diff --git a/res/trainers/0467.json b/res/trainers/trainer_unknown_467.json similarity index 100% rename from res/trainers/0467.json rename to res/trainers/trainer_unknown_467.json diff --git a/res/trainers/0468.json b/res/trainers/trainer_unknown_468.json similarity index 100% rename from res/trainers/0468.json rename to res/trainers/trainer_unknown_468.json diff --git a/res/trainers/0469.json b/res/trainers/trainer_unknown_469.json similarity index 100% rename from res/trainers/0469.json rename to res/trainers/trainer_unknown_469.json diff --git a/res/trainers/0484.json b/res/trainers/trainer_unknown_484.json similarity index 100% rename from res/trainers/0484.json rename to res/trainers/trainer_unknown_484.json diff --git a/res/trainers/0485.json b/res/trainers/trainer_unknown_485.json similarity index 100% rename from res/trainers/0485.json rename to res/trainers/trainer_unknown_485.json diff --git a/res/trainers/0487.json b/res/trainers/trainer_unknown_487.json similarity index 100% rename from res/trainers/0487.json rename to res/trainers/trainer_unknown_487.json diff --git a/res/trainers/0493.json b/res/trainers/trainer_unknown_493.json similarity index 100% rename from res/trainers/0493.json rename to res/trainers/trainer_unknown_493.json diff --git a/res/trainers/0495.json b/res/trainers/trainer_unknown_495.json similarity index 100% rename from res/trainers/0495.json rename to res/trainers/trainer_unknown_495.json diff --git a/res/trainers/0501.json b/res/trainers/trainer_unknown_501.json similarity index 100% rename from res/trainers/0501.json rename to res/trainers/trainer_unknown_501.json diff --git a/res/trainers/0502.json b/res/trainers/trainer_unknown_502.json similarity index 100% rename from res/trainers/0502.json rename to res/trainers/trainer_unknown_502.json diff --git a/res/trainers/0511.json b/res/trainers/trainer_unknown_511.json similarity index 100% rename from res/trainers/0511.json rename to res/trainers/trainer_unknown_511.json diff --git a/res/trainers/0605.json b/res/trainers/trainer_unknown_605.json similarity index 100% rename from res/trainers/0605.json rename to res/trainers/trainer_unknown_605.json diff --git a/res/trainers/0651.json b/res/trainers/trainer_unknown_651.json similarity index 100% rename from res/trainers/0651.json rename to res/trainers/trainer_unknown_651.json diff --git a/res/trainers/0652.json b/res/trainers/trainer_unknown_652.json similarity index 100% rename from res/trainers/0652.json rename to res/trainers/trainer_unknown_652.json diff --git a/res/trainers/0778.json b/res/trainers/trainer_unknown_778.json similarity index 100% rename from res/trainers/0778.json rename to res/trainers/trainer_unknown_778.json diff --git a/res/trainers/0779.json b/res/trainers/trainer_unknown_779.json similarity index 100% rename from res/trainers/0779.json rename to res/trainers/trainer_unknown_779.json diff --git a/res/trainers/0780.json b/res/trainers/trainer_unknown_780.json similarity index 100% rename from res/trainers/0780.json rename to res/trainers/trainer_unknown_780.json diff --git a/res/trainers/0781.json b/res/trainers/trainer_unknown_781.json similarity index 100% rename from res/trainers/0781.json rename to res/trainers/trainer_unknown_781.json diff --git a/res/trainers/0782.json b/res/trainers/trainer_unknown_782.json similarity index 100% rename from res/trainers/0782.json rename to res/trainers/trainer_unknown_782.json diff --git a/res/trainers/0783.json b/res/trainers/trainer_unknown_783.json similarity index 100% rename from res/trainers/0783.json rename to res/trainers/trainer_unknown_783.json diff --git a/res/trainers/0784.json b/res/trainers/trainer_unknown_784.json similarity index 100% rename from res/trainers/0784.json rename to res/trainers/trainer_unknown_784.json diff --git a/res/trainers/0785.json b/res/trainers/trainer_unknown_785.json similarity index 100% rename from res/trainers/0785.json rename to res/trainers/trainer_unknown_785.json diff --git a/res/trainers/0786.json b/res/trainers/trainer_unknown_786.json similarity index 100% rename from res/trainers/0786.json rename to res/trainers/trainer_unknown_786.json diff --git a/res/trainers/0787.json b/res/trainers/trainer_unknown_787.json similarity index 100% rename from res/trainers/0787.json rename to res/trainers/trainer_unknown_787.json diff --git a/res/trainers/0788.json b/res/trainers/trainer_unknown_788.json similarity index 100% rename from res/trainers/0788.json rename to res/trainers/trainer_unknown_788.json diff --git a/res/trainers/0789.json b/res/trainers/trainer_unknown_789.json similarity index 100% rename from res/trainers/0789.json rename to res/trainers/trainer_unknown_789.json diff --git a/res/trainers/0790.json b/res/trainers/trainer_unknown_790.json similarity index 100% rename from res/trainers/0790.json rename to res/trainers/trainer_unknown_790.json diff --git a/res/trainers/0791.json b/res/trainers/trainer_unknown_791.json similarity index 100% rename from res/trainers/0791.json rename to res/trainers/trainer_unknown_791.json diff --git a/res/trainers/0792.json b/res/trainers/trainer_unknown_792.json similarity index 100% rename from res/trainers/0792.json rename to res/trainers/trainer_unknown_792.json diff --git a/res/trainers/0793.json b/res/trainers/trainer_unknown_793.json similarity index 100% rename from res/trainers/0793.json rename to res/trainers/trainer_unknown_793.json diff --git a/res/trainers/0794.json b/res/trainers/trainer_unknown_794.json similarity index 100% rename from res/trainers/0794.json rename to res/trainers/trainer_unknown_794.json diff --git a/res/trainers/0795.json b/res/trainers/trainer_unknown_795.json similarity index 100% rename from res/trainers/0795.json rename to res/trainers/trainer_unknown_795.json diff --git a/res/trainers/0796.json b/res/trainers/trainer_unknown_796.json similarity index 100% rename from res/trainers/0796.json rename to res/trainers/trainer_unknown_796.json diff --git a/res/trainers/0797.json b/res/trainers/trainer_unknown_797.json similarity index 100% rename from res/trainers/0797.json rename to res/trainers/trainer_unknown_797.json diff --git a/res/trainers/0798.json b/res/trainers/trainer_unknown_798.json similarity index 100% rename from res/trainers/0798.json rename to res/trainers/trainer_unknown_798.json diff --git a/res/trainers/0799.json b/res/trainers/trainer_unknown_799.json similarity index 100% rename from res/trainers/0799.json rename to res/trainers/trainer_unknown_799.json diff --git a/res/trainers/0800.json b/res/trainers/trainer_unknown_800.json similarity index 100% rename from res/trainers/0800.json rename to res/trainers/trainer_unknown_800.json diff --git a/res/trainers/0801.json b/res/trainers/trainer_unknown_801.json similarity index 100% rename from res/trainers/0801.json rename to res/trainers/trainer_unknown_801.json diff --git a/res/trainers/0802.json b/res/trainers/trainer_unknown_802.json similarity index 100% rename from res/trainers/0802.json rename to res/trainers/trainer_unknown_802.json diff --git a/res/trainers/0803.json b/res/trainers/trainer_unknown_803.json similarity index 100% rename from res/trainers/0803.json rename to res/trainers/trainer_unknown_803.json diff --git a/res/trainers/0804.json b/res/trainers/trainer_unknown_804.json similarity index 100% rename from res/trainers/0804.json rename to res/trainers/trainer_unknown_804.json diff --git a/res/trainers/0805.json b/res/trainers/trainer_unknown_805.json similarity index 100% rename from res/trainers/0805.json rename to res/trainers/trainer_unknown_805.json diff --git a/res/trainers/0806.json b/res/trainers/trainer_unknown_806.json similarity index 100% rename from res/trainers/0806.json rename to res/trainers/trainer_unknown_806.json diff --git a/res/trainers/0807.json b/res/trainers/trainer_unknown_807.json similarity index 100% rename from res/trainers/0807.json rename to res/trainers/trainer_unknown_807.json diff --git a/res/trainers/0808.json b/res/trainers/trainer_unknown_808.json similarity index 100% rename from res/trainers/0808.json rename to res/trainers/trainer_unknown_808.json diff --git a/res/trainers/0809.json b/res/trainers/trainer_unknown_809.json similarity index 100% rename from res/trainers/0809.json rename to res/trainers/trainer_unknown_809.json diff --git a/res/trainers/0810.json b/res/trainers/trainer_unknown_810.json similarity index 100% rename from res/trainers/0810.json rename to res/trainers/trainer_unknown_810.json diff --git a/res/trainers/0811.json b/res/trainers/trainer_unknown_811.json similarity index 100% rename from res/trainers/0811.json rename to res/trainers/trainer_unknown_811.json diff --git a/res/trainers/0812.json b/res/trainers/trainer_unknown_812.json similarity index 100% rename from res/trainers/0812.json rename to res/trainers/trainer_unknown_812.json diff --git a/res/trainers/0813.json b/res/trainers/trainer_unknown_813.json similarity index 100% rename from res/trainers/0813.json rename to res/trainers/trainer_unknown_813.json diff --git a/res/trainers/0814.json b/res/trainers/trainer_unknown_814.json similarity index 100% rename from res/trainers/0814.json rename to res/trainers/trainer_unknown_814.json diff --git a/res/trainers/0815.json b/res/trainers/trainer_unknown_815.json similarity index 100% rename from res/trainers/0815.json rename to res/trainers/trainer_unknown_815.json diff --git a/res/trainers/0816.json b/res/trainers/trainer_unknown_816.json similarity index 100% rename from res/trainers/0816.json rename to res/trainers/trainer_unknown_816.json diff --git a/res/trainers/0817.json b/res/trainers/trainer_unknown_817.json similarity index 100% rename from res/trainers/0817.json rename to res/trainers/trainer_unknown_817.json diff --git a/res/trainers/0818.json b/res/trainers/trainer_unknown_818.json similarity index 100% rename from res/trainers/0818.json rename to res/trainers/trainer_unknown_818.json diff --git a/res/trainers/0819.json b/res/trainers/trainer_unknown_819.json similarity index 100% rename from res/trainers/0819.json rename to res/trainers/trainer_unknown_819.json diff --git a/res/trainers/0820.json b/res/trainers/trainer_unknown_820.json similarity index 100% rename from res/trainers/0820.json rename to res/trainers/trainer_unknown_820.json diff --git a/res/trainers/0821.json b/res/trainers/trainer_unknown_821.json similarity index 100% rename from res/trainers/0821.json rename to res/trainers/trainer_unknown_821.json diff --git a/res/trainers/0822.json b/res/trainers/trainer_unknown_822.json similarity index 100% rename from res/trainers/0822.json rename to res/trainers/trainer_unknown_822.json diff --git a/res/trainers/0823.json b/res/trainers/trainer_unknown_823.json similarity index 100% rename from res/trainers/0823.json rename to res/trainers/trainer_unknown_823.json diff --git a/res/trainers/0824.json b/res/trainers/trainer_unknown_824.json similarity index 100% rename from res/trainers/0824.json rename to res/trainers/trainer_unknown_824.json diff --git a/res/trainers/0825.json b/res/trainers/trainer_unknown_825.json similarity index 100% rename from res/trainers/0825.json rename to res/trainers/trainer_unknown_825.json diff --git a/res/trainers/0826.json b/res/trainers/trainer_unknown_828.json similarity index 100% rename from res/trainers/0826.json rename to res/trainers/trainer_unknown_828.json diff --git a/res/trainers/0833.json b/res/trainers/trainer_unknown_833.json similarity index 100% rename from res/trainers/0833.json rename to res/trainers/trainer_unknown_833.json diff --git a/res/trainers/0834.json b/res/trainers/trainer_unknown_834.json similarity index 100% rename from res/trainers/0834.json rename to res/trainers/trainer_unknown_834.json diff --git a/res/trainers/0840.json b/res/trainers/trainer_unknown_840.json similarity index 100% rename from res/trainers/0840.json rename to res/trainers/trainer_unknown_840.json diff --git a/res/trainers/0841.json b/res/trainers/trainer_unknown_841.json similarity index 100% rename from res/trainers/0841.json rename to res/trainers/trainer_unknown_841.json diff --git a/res/trainers/0842.json b/res/trainers/trainer_unknown_842.json similarity index 100% rename from res/trainers/0842.json rename to res/trainers/trainer_unknown_842.json diff --git a/res/trainers/0902.json b/res/trainers/trainer_unknown_902.json similarity index 100% rename from res/trainers/0902.json rename to res/trainers/trainer_unknown_902.json diff --git a/res/trainers/0903.json b/res/trainers/trainer_unknown_903.json similarity index 100% rename from res/trainers/0903.json rename to res/trainers/trainer_unknown_903.json diff --git a/res/trainers/0904.json b/res/trainers/trainer_unknown_904.json similarity index 100% rename from res/trainers/0904.json rename to res/trainers/trainer_unknown_904.json diff --git a/res/trainers/0905.json b/res/trainers/trainer_unknown_905.json similarity index 100% rename from res/trainers/0905.json rename to res/trainers/trainer_unknown_905.json diff --git a/res/trainers/0362.json b/res/trainers/trainer_veteran_armando.json similarity index 100% rename from res/trainers/0362.json rename to res/trainers/trainer_veteran_armando.json diff --git a/res/trainers/0777.json b/res/trainers/trainer_veteran_armando_rematch.json similarity index 100% rename from res/trainers/0777.json rename to res/trainers/trainer_veteran_armando_rematch.json diff --git a/res/trainers/0500.json b/res/trainers/trainer_veteran_brenden.json similarity index 100% rename from res/trainers/0500.json rename to res/trainers/trainer_veteran_brenden.json diff --git a/res/trainers/0068.json b/res/trainers/trainer_veteran_brian.json similarity index 100% rename from res/trainers/0068.json rename to res/trainers/trainer_veteran_brian.json diff --git a/res/trainers/0774.json b/res/trainers/trainer_veteran_brian_rematch_1.json similarity index 100% rename from res/trainers/0774.json rename to res/trainers/trainer_veteran_brian_rematch_1.json diff --git a/res/trainers/0776.json b/res/trainers/trainer_veteran_brian_rematch_2.json similarity index 100% rename from res/trainers/0776.json rename to res/trainers/trainer_veteran_brian_rematch_2.json diff --git a/res/trainers/0229.json b/res/trainers/trainer_veteran_clayton.json similarity index 100% rename from res/trainers/0229.json rename to res/trainers/trainer_veteran_clayton.json diff --git a/res/trainers/0228.json b/res/trainers/trainer_veteran_edgar.json similarity index 100% rename from res/trainers/0228.json rename to res/trainers/trainer_veteran_edgar.json diff --git a/res/trainers/0552.json b/res/trainers/trainer_veteran_emanuel.json similarity index 100% rename from res/trainers/0552.json rename to res/trainers/trainer_veteran_emanuel.json diff --git a/res/trainers/0240.json b/res/trainers/trainer_veteran_grant.json similarity index 100% rename from res/trainers/0240.json rename to res/trainers/trainer_veteran_grant.json diff --git a/res/trainers/0606.json b/res/trainers/trainer_veteran_harlan.json similarity index 100% rename from res/trainers/0606.json rename to res/trainers/trainer_veteran_harlan.json diff --git a/res/trainers/0499.json b/res/trainers/trainer_veteran_terrell.json similarity index 100% rename from res/trainers/0499.json rename to res/trainers/trainer_veteran_terrell.json diff --git a/res/trainers/0366.json b/res/trainers/trainer_waitress_kati.json similarity index 100% rename from res/trainers/0366.json rename to res/trainers/trainer_waitress_kati.json diff --git a/res/trainers/0504.json b/res/trainers/trainer_worker_braden.json similarity index 100% rename from res/trainers/0504.json rename to res/trainers/trainer_worker_braden.json diff --git a/res/trainers/0505.json b/res/trainers/trainer_worker_brendon.json similarity index 100% rename from res/trainers/0505.json rename to res/trainers/trainer_worker_brendon.json diff --git a/res/trainers/0195.json b/res/trainers/trainer_worker_colin.json similarity index 100% rename from res/trainers/0195.json rename to res/trainers/trainer_worker_colin.json diff --git a/res/trainers/0846.json b/res/trainers/trainer_worker_conrad.json similarity index 100% rename from res/trainers/0846.json rename to res/trainers/trainer_worker_conrad.json diff --git a/res/trainers/0844.json b/res/trainers/trainer_worker_dillan.json similarity index 100% rename from res/trainers/0844.json rename to res/trainers/trainer_worker_dillan.json diff --git a/res/trainers/0257.json b/res/trainers/trainer_worker_gary.json similarity index 100% rename from res/trainers/0257.json rename to res/trainers/trainer_worker_gary.json diff --git a/res/trainers/0367.json b/res/trainers/trainer_worker_gerardo.json similarity index 100% rename from res/trainers/0367.json rename to res/trainers/trainer_worker_gerardo.json diff --git a/res/trainers/0845.json b/res/trainers/trainer_worker_holden.json similarity index 100% rename from res/trainers/0845.json rename to res/trainers/trainer_worker_holden.json diff --git a/res/trainers/0256.json b/res/trainers/trainer_worker_jackson.json similarity index 100% rename from res/trainers/0256.json rename to res/trainers/trainer_worker_jackson.json diff --git a/res/trainers/0196.json b/res/trainers/trainer_worker_mason.json similarity index 100% rename from res/trainers/0196.json rename to res/trainers/trainer_worker_mason.json diff --git a/res/trainers/0503.json b/res/trainers/trainer_worker_noel.json similarity index 100% rename from res/trainers/0503.json rename to res/trainers/trainer_worker_noel.json diff --git a/res/trainers/0506.json b/res/trainers/trainer_worker_quentin.json similarity index 100% rename from res/trainers/0506.json rename to res/trainers/trainer_worker_quentin.json diff --git a/res/trainers/0534.json b/res/trainers/trainer_young_couple_mike_and_nat.json similarity index 100% rename from res/trainers/0534.json rename to res/trainers/trainer_young_couple_mike_and_nat.json diff --git a/res/trainers/0055.json b/res/trainers/trainer_young_couple_ty_and_sue.json similarity index 100% rename from res/trainers/0055.json rename to res/trainers/trainer_young_couple_ty_and_sue.json diff --git a/res/trainers/0033.json b/res/trainers/trainer_youngster_austin.json similarity index 100% rename from res/trainers/0033.json rename to res/trainers/trainer_youngster_austin.json diff --git a/res/trainers/0355.json b/res/trainers/trainer_youngster_dallas.json similarity index 100% rename from res/trainers/0355.json rename to res/trainers/trainer_youngster_dallas.json diff --git a/res/trainers/0768.json b/res/trainers/trainer_youngster_dallas_rematch_1.json similarity index 100% rename from res/trainers/0768.json rename to res/trainers/trainer_youngster_dallas_rematch_1.json diff --git a/res/trainers/0769.json b/res/trainers/trainer_youngster_dallas_rematch_2.json similarity index 100% rename from res/trainers/0769.json rename to res/trainers/trainer_youngster_dallas_rematch_2.json diff --git a/res/trainers/0770.json b/res/trainers/trainer_youngster_dallas_rematch_3.json similarity index 100% rename from res/trainers/0770.json rename to res/trainers/trainer_youngster_dallas_rematch_3.json diff --git a/res/trainers/0245.json b/res/trainers/trainer_youngster_darius.json similarity index 100% rename from res/trainers/0245.json rename to res/trainers/trainer_youngster_darius.json diff --git a/res/trainers/0357.json b/res/trainers/trainer_youngster_donny.json similarity index 100% rename from res/trainers/0357.json rename to res/trainers/trainer_youngster_donny.json diff --git a/res/trainers/0244.json b/res/trainers/trainer_youngster_jonathon.json similarity index 100% rename from res/trainers/0244.json rename to res/trainers/trainer_youngster_jonathon.json diff --git a/res/trainers/0002.json b/res/trainers/trainer_youngster_logan.json similarity index 100% rename from res/trainers/0002.json rename to res/trainers/trainer_youngster_logan.json diff --git a/res/trainers/0004.json b/res/trainers/trainer_youngster_michael.json similarity index 100% rename from res/trainers/0004.json rename to res/trainers/trainer_youngster_michael.json diff --git a/res/trainers/0532.json b/res/trainers/trainer_youngster_oliver.json similarity index 100% rename from res/trainers/0532.json rename to res/trainers/trainer_youngster_oliver.json diff --git a/res/trainers/0356.json b/res/trainers/trainer_youngster_sebastian.json similarity index 100% rename from res/trainers/0356.json rename to res/trainers/trainer_youngster_sebastian.json diff --git a/res/trainers/0001.json b/res/trainers/trainer_youngster_tristan.json similarity index 100% rename from res/trainers/0001.json rename to res/trainers/trainer_youngster_tristan.json diff --git a/res/trainers/0765.json b/res/trainers/trainer_youngster_tristan_rematch_1.json similarity index 100% rename from res/trainers/0765.json rename to res/trainers/trainer_youngster_tristan_rematch_1.json diff --git a/res/trainers/0766.json b/res/trainers/trainer_youngster_tristan_rematch_2.json similarity index 100% rename from res/trainers/0766.json rename to res/trainers/trainer_youngster_tristan_rematch_2.json diff --git a/res/trainers/0767.json b/res/trainers/trainer_youngster_tristan_rematch_3.json similarity index 100% rename from res/trainers/0767.json rename to res/trainers/trainer_youngster_tristan_rematch_3.json diff --git a/res/trainers/0010.json b/res/trainers/trainer_youngster_tyler.json similarity index 100% rename from res/trainers/0010.json rename to res/trainers/trainer_youngster_tyler.json diff --git a/res/trainers/0496.json b/res/trainers/trainer_youngster_wayne.json similarity index 100% rename from res/trainers/0496.json rename to res/trainers/trainer_youngster_wayne.json diff --git a/res/trainers/trainers.order b/res/trainers/trainers.order new file mode 100644 index 0000000000..67328395db --- /dev/null +++ b/res/trainers/trainers.order @@ -0,0 +1,928 @@ +trainer_none +trainer_youngster_tristan +trainer_youngster_logan +trainer_lass_natalie +trainer_youngster_michael +trainer_unknown_005 +trainer_unknown_006 +trainer_unknown_007 +trainer_unknown_008 +trainer_unknown_009 +trainer_youngster_tyler +trainer_lass_samantha +trainer_lass_sarah +trainer_bug_catcher_brandon +trainer_aroma_lady_taylor +trainer_twins_liv_and_liz +trainer_camper_jacob +trainer_picnicker_siena +trainer_hiker_daniel +trainer_hiker_nicholas +trainer_battle_girl_kelsey +trainer_aroma_lady_elizabeth +trainer_fisherman_andrew +trainer_fisherman_joseph +trainer_fisherman_zachary +trainer_cyclist_axel +trainer_cyclist_james +trainer_cyclist_john +trainer_cyclist_ryan +trainer_cyclist_megan +trainer_cyclist_nicole +trainer_cyclist_kayla +trainer_cyclist_rachel +trainer_youngster_austin +trainer_camper_anthony +trainer_picnicker_lauren +trainer_hiker_kevin +trainer_hiker_justin +trainer_battle_girl_helen +trainer_hiker_robert +trainer_hiker_alexander +trainer_hiker_jonathan +trainer_black_belt_kyle +trainer_fisherman_cody +trainer_aroma_lady_hannah +trainer_artist_william +trainer_breeder_albert +trainer_breeder_jennifer +trainer_cowgirl_shelley +trainer_jogger_richard +trainer_unknown_050 +trainer_unknown_051 +trainer_unknown_052 +trainer_poke_kid_danielle +trainer_unknown_054 +trainer_young_couple_ty_and_sue +trainer_breeder_kahlil +trainer_breeder_amber +trainer_unknown_058 +trainer_unknown_059 +trainer_unknown_060 +trainer_unknown_061 +trainer_unknown_062 +trainer_unknown_063 +trainer_unknown_064 +trainer_twins_teri_and_tia +trainer_ace_trainer_ernest +trainer_ace_trainer_alyssa +trainer_veteran_brian +trainer_black_belt_adam +trainer_ninja_boy_joel +trainer_ninja_boy_nathan +trainer_ninja_boy_davido +trainer_dragon_tamer_patrick +trainer_bird_keeper_brianna +trainer_double_team_zac_and_jen +trainer_bird_keeper_alexandra +trainer_unknown_077 +trainer_ninja_boy_zach +trainer_black_belt_sean +trainer_ninja_boy_nick +trainer_bird_keeper_katherine +trainer_rich_boy_jason +trainer_lady_melissa +trainer_gentleman_jeremy +trainer_socialite_reina +trainer_unknown_086 +trainer_unknown_087 +trainer_policeman_bobby +trainer_policeman_alex +trainer_policeman_dylan +trainer_fisherman_juan +trainer_fisherman_josh +trainer_fisherman_travis +trainer_ranger_taylor +trainer_ranger_jeffrey +trainer_ranger_allison +trainer_unknown_097 +trainer_unknown_098 +trainer_scientist_stefano +trainer_unknown_100 +trainer_unknown_101 +trainer_policeman_caleb +trainer_swimmer_sheltin +trainer_swimmer_evan +trainer_swimmer_haley +trainer_swimmer_mary +trainer_tuber_jared +trainer_tuber_chelsea +trainer_unknown_109 +trainer_sailor_paul +trainer_fisherman_kenneth +trainer_unknown_112 +trainer_ruin_maniac_bryan +trainer_ruin_maniac_ronald +trainer_unknown_115 +trainer_unknown_116 +trainer_unknown_117 +trainer_unknown_118 +trainer_psychic_mitchell +trainer_psychic_abigail +trainer_pi_carlos +trainer_unknown_122 +trainer_unknown_123 +trainer_unknown_124 +trainer_unknown_125 +trainer_unknown_126 +trainer_black_belt_gregory +trainer_black_belt_derek +trainer_black_belt_nathaniel +trainer_jogger_scott +trainer_unknown_131 +trainer_ace_trainer_blake +trainer_ace_trainer_garrett +trainer_ace_trainer_laura +trainer_ace_trainer_maria +trainer_skier_bradley +trainer_skier_edward +trainer_skier_kaitlyn +trainer_skier_andrea +trainer_ace_trainer_dalton +trainer_ace_trainer_olivia +trainer_skier_shawn +trainer_skier_bjorn +trainer_skier_lexie +trainer_skier_madison +trainer_ninja_boy_matthew +trainer_ninja_boy_ethan +trainer_black_belt_luke +trainer_unknown_149 +trainer_unknown_150 +trainer_unknown_151 +trainer_unknown_152 +trainer_fisherman_miguel +trainer_fisherman_luc +trainer_unknown_155 +trainer_unknown_156 +trainer_unknown_157 +trainer_unknown_158 +trainer_swimmer_adrian +trainer_swimmer_erik +trainer_swimmer_vincent +trainer_swimmer_jessica +trainer_swimmer_erica +trainer_swimmer_katelyn +trainer_unknown_165 +trainer_swimmer_dillon +trainer_swimmer_vanessa +trainer_fisherman_cory +trainer_unknown_169 +trainer_ace_trainer_jake +trainer_ace_trainer_shannon +trainer_fisherman_brett +trainer_fisherman_alec +trainer_fisherman_george +trainer_fisherman_cole +trainer_unknown_176 +trainer_unknown_177 +trainer_unknown_178 +trainer_unknown_179 +trainer_sailor_luther +trainer_unknown_181 +trainer_unknown_182 +trainer_swimmer_wesley +trainer_swimmer_ricardo +trainer_swimmer_francisco +trainer_swimmer_colton +trainer_swimmer_troy +trainer_swimmer_oscar +trainer_swimmer_miranda +trainer_swimmer_aubree +trainer_swimmer_paige +trainer_swimmer_crystal +trainer_swimmer_cassandra +trainer_swimmer_gabrielle +trainer_worker_colin +trainer_worker_mason +trainer_unknown_197 +trainer_unknown_198 +trainer_unknown_199 +trainer_unknown_200 +trainer_bug_catcher_jack +trainer_bug_catcher_phillip +trainer_bug_catcher_donald +trainer_lass_briana +trainer_psychic_elijah +trainer_psychic_lindsey +trainer_unknown_207 +trainer_unknown_208 +trainer_unknown_209 +trainer_unknown_210 +trainer_unknown_211 +trainer_unknown_212 +trainer_unknown_213 +trainer_unknown_214 +trainer_unknown_215 +trainer_unknown_216 +trainer_unknown_217 +trainer_unknown_218 +trainer_unknown_219 +trainer_unknown_220 +trainer_unknown_221 +trainer_unknown_222 +trainer_unknown_223 +trainer_ace_trainer_omar +trainer_ace_trainer_henry +trainer_ace_trainer_mariah +trainer_ace_trainer_sydney +trainer_veteran_edgar +trainer_veteran_clayton +trainer_dragon_tamer_ondrej +trainer_dragon_tamer_clinton +trainer_black_belt_david +trainer_bird_keeper_hana +trainer_psychic_bryce +trainer_psychic_valencia +trainer_double_team_jo_and_pat +trainer_double_team_al_and_kay +trainer_unknown_238 +trainer_unknown_239 +trainer_veteran_grant +trainer_unknown_241 +trainer_unknown_242 +trainer_unknown_243 +trainer_youngster_jonathon +trainer_youngster_darius +trainer_leader_roark +trainer_rival_route_203_piplup +trainer_rival_route_203_turtwig +trainer_rival_route_203_chimchar +trainer_leader_byron +trainer_unknown_251 +trainer_unknown_252 +trainer_unknown_253 +trainer_unknown_254 +trainer_unknown_255 +trainer_worker_jackson +trainer_worker_gary +trainer_black_belt_philip +trainer_aroma_lady_jenna +trainer_aroma_lady_angela +trainer_elite_four_aaron +trainer_elite_four_bertha +trainer_elite_four_flint +trainer_elite_four_lucian +trainer_camper_curtis +trainer_camper_drew +trainer_champion_cynthia +trainer_ace_trainer_sergio +trainer_ace_trainer_isaiah +trainer_ace_trainer_savannah +trainer_ace_trainer_alicia +trainer_collector_douglas +trainer_collector_brady +trainer_collector_ivan +trainer_collector_fernando +trainer_collector_edwin +trainer_dragon_tamer_hayden +trainer_ace_trainer_dennis +trainer_ace_trainer_cesar +trainer_ace_trainer_allen +trainer_ace_trainer_zachery +trainer_ace_trainer_ruben +trainer_ace_trainer_breanna +trainer_ace_trainer_catherine +trainer_ace_trainer_destiny +trainer_ace_trainer_jamie +trainer_ace_trainer_maya +trainer_psychic_maxwell +trainer_psychic_brittney +trainer_belle_and_pa_ava_and_matt +trainer_unknown_291 +trainer_rancher_marco +trainer_fisherman_erick +trainer_twins_emma_and_lil +trainer_commander_mars_valley_windworks +trainer_galactic_grunt_floaroma_meadow_1 +trainer_galactic_grunt_floaroma_meadow_2 +trainer_galactic_grunt_valley_windworks_2 +trainer_galactic_grunt_valley_windworks_3 +trainer_guitarist_tony +trainer_guitarist_jerry +trainer_guitarist_preston +trainer_guitarist_lonnie +trainer_ruin_maniac_calvin +trainer_ruin_maniac_larry +trainer_jogger_wyatt +trainer_jogger_craig +trainer_jogger_raul +trainer_black_belt_colby +trainer_black_belt_darren +trainer_black_belt_rafael +trainer_black_belt_jeffery +trainer_black_belt_carl +trainer_black_belt_ricky +trainer_leader_gardenia +trainer_leader_wake +trainer_leader_maylene +trainer_leader_fantina +trainer_leader_candice +trainer_leader_volkner +trainer_unknown_321 +trainer_lass_madeline +trainer_lass_kaitlin +trainer_lass_caroline +trainer_lass_molly +trainer_hiker_louis +trainer_parasol_lady_alexa +trainer_parasol_lady_sabrina +trainer_picnicker_diana +trainer_picnicker_cheyenne +trainer_poke_kid_meghan +trainer_policeman_danny +trainer_policeman_thomas +trainer_unknown_334 +trainer_rich_boy_trey +trainer_unknown_336 +trainer_sailor_marc +trainer_sailor_skyler +trainer_sailor_damian +trainer_school_kid_chance +trainer_school_kid_forrest +trainer_school_kid_harrison +trainer_school_kid_mackenzie +trainer_school_kid_tiera +trainer_school_kid_christine +trainer_beauty_cyndy +trainer_unknown_347 +trainer_beauty_lindsay +trainer_unknown_349 +trainer_unknown_350 +trainer_unknown_351 +trainer_unknown_352 +trainer_unknown_353 +trainer_unknown_354 +trainer_youngster_dallas +trainer_youngster_sebastian +trainer_youngster_donny +trainer_tuber_trenton +trainer_tuber_conner +trainer_tuber_mariel +trainer_tuber_holly +trainer_veteran_armando +trainer_unknown_363 +trainer_unknown_364 +trainer_unknown_365 +trainer_waitress_kati +trainer_worker_gerardo +trainer_unknown_368 +trainer_unknown_369 +trainer_unknown_370 +trainer_unknown_371 +trainer_battle_girl_tyler +trainer_bird_keeper_autumn +trainer_unknown_374 +trainer_unknown_375 +trainer_unknown_376 +trainer_camper_zackary +trainer_camper_lawrence +trainer_camper_diego +trainer_camper_parker +trainer_collector_dean +trainer_collector_jamal +trainer_collector_terry +trainer_unknown_384 +trainer_unknown_385 +trainer_dragon_tamer_joe +trainer_unknown_387 +trainer_ace_trainer_jonah +trainer_ace_trainer_micah +trainer_ace_trainer_arthur +trainer_unknown_391 +trainer_ace_trainer_brenda +trainer_ace_trainer_brandi +trainer_ace_trainer_clarice +trainer_psychic_kody +trainer_psychic_landon +trainer_psychic_deandre +trainer_psychic_rachael +trainer_psychic_desiree +trainer_psychic_kendra +trainer_fisherman_walter +trainer_unknown_402 +trainer_galactic_boss_cyrus_galactic_hq +trainer_galactic_boss_cyrus_distortion_world +trainer_commander_mars_lake_verity +trainer_commander_jupiter_team_galactic_eterna_building +trainer_commander_jupiter_spear_pillar +trainer_commander_saturn_valor_cavern +trainer_commander_saturn_galactic_hq +trainer_galactic_grunt_team_galactic_eterna_building_1f_1 +trainer_unknown_411 +trainer_galactic_grunt_team_galactic_eterna_building_2f_1 +trainer_unknown_413 +trainer_galactic_grunt_jubilife_city_1 +trainer_galactic_grunt_jubilife_city_2 +trainer_galactic_grunt_celestic_town +trainer_galactic_grunt_lake_valor_1 +trainer_galactic_grunt_lake_valor_2 +trainer_galactic_grunt_lake_verity_1 +trainer_galactic_grunt_lake_verity_3 +trainer_galactic_grunt_team_galactic_eterna_building_1f_2 +trainer_galactic_grunt_team_galactic_eterna_building_2f_2 +trainer_galactic_grunt_team_galactic_eterna_building_3f +trainer_unknown_424 +trainer_galactic_grunt_lake_valor_3 +trainer_galactic_grunt_lake_verity_2 +trainer_galactic_grunt_lake_verity_4 +trainer_galactic_grunt_galactic_hq_1f +trainer_unknown_429 +trainer_galactic_grunt_galactic_hq_2f_3 +trainer_unknown_431 +trainer_unknown_432 +trainer_unknown_433 +trainer_unknown_434 +trainer_unknown_435 +trainer_unknown_436 +trainer_unknown_437 +trainer_unknown_438 +trainer_unknown_439 +trainer_unknown_440 +trainer_unknown_441 +trainer_ruin_maniac_harry +trainer_ruin_maniac_gerald +trainer_black_belt_miles +trainer_black_belt_kendal +trainer_black_belt_eddie +trainer_black_belt_willie +trainer_unknown_448 +trainer_unknown_449 +trainer_lass_cassidy +trainer_hiker_theodore +trainer_hiker_damon +trainer_hiker_maurice +trainer_hiker_reginald +trainer_hiker_lorenzo +trainer_picnicker_karina +trainer_picnicker_summer +trainer_picnicker_tori +trainer_picnicker_ana +trainer_unknown_460 +trainer_unknown_461 +trainer_unknown_462 +trainer_unknown_463 +trainer_unknown_464 +trainer_unknown_465 +trainer_unknown_466 +trainer_unknown_467 +trainer_unknown_468 +trainer_unknown_469 +trainer_rival_route_209_piplup +trainer_rival_route_209_turtwig +trainer_rival_route_209_chimchar +trainer_rival_pastoria_city_piplup +trainer_rival_pastoria_city_turtwig +trainer_rival_pastoria_city_chimchar +trainer_rival_canalave_city_piplup +trainer_rival_canalave_city_turtwig +trainer_rival_canalave_city_chimchar +trainer_rival_pokemon_league_piplup +trainer_rival_pokemon_league_turtwig +trainer_rival_pokemon_league_chimchar +trainer_sailor_zachariah +trainer_sailor_samson +trainer_unknown_484 +trainer_unknown_485 +trainer_scientist_shaun +trainer_unknown_487 +trainer_ninja_boy_fabian +trainer_ninja_boy_brennan +trainer_ninja_boy_bruce +trainer_beauty_devon +trainer_beauty_nicola +trainer_unknown_493 +trainer_swimmer_claire +trainer_unknown_495 +trainer_youngster_wayne +trainer_tuber_jacky +trainer_tuber_caitlyn +trainer_veteran_terrell +trainer_veteran_brenden +trainer_unknown_501 +trainer_unknown_502 +trainer_worker_noel +trainer_worker_braden +trainer_worker_brendon +trainer_worker_quentin +trainer_galactic_grunt_galactic_hq_b2f_1 +trainer_galactic_grunt_galactic_hq_b2f_2 +trainer_galactic_grunt_galactic_hq_3f_1 +trainer_galactic_grunt_galactic_hq_2f_1 +trainer_unknown_511 +trainer_galactic_grunt_galactic_hq_3f_2 +trainer_galactic_grunt_galactic_hq_2f_2 +trainer_galactic_grunt_galactic_hq_3f_3 +trainer_galactic_grunt_mt_coronet_3f_1 +trainer_galactic_grunt_mt_coronet_4f_1 +trainer_galactic_grunt_mt_coronet_4f_2 +trainer_galactic_grunt_mt_coronet_tunnel_room_1 +trainer_galactic_grunt_mt_coronet_tunnel_room_2 +trainer_galactic_grunt_mt_coronet_5f_1 +trainer_galactic_grunt_spear_pillar_1 +trainer_galactic_grunt_galactic_hq_3f_4 +trainer_galactic_grunt_mt_coronet__3f_1 +trainer_galactic_grunt_mt_coronet_tunnel_room_3 +trainer_galactic_grunt_mt_coronet_5f_2 +trainer_galactic_grunt_mt_coronet_6f +trainer_galactic_grunt_spear_pillar_2 +trainer_commander_mars_spear_pillar +trainer_roughneck_kirby +trainer_pokefan_leonard +trainer_pokefan_rebekah +trainer_youngster_oliver +trainer_belle_and_pa_beth_and_bob +trainer_young_couple_mike_and_nat +trainer_aroma_lady_alison +trainer_artist_ismael +trainer_breeder_kaylee +trainer_cameraman_darryl +trainer_collector_eugene +trainer_pokefan_meredith +trainer_pi_kendrick +trainer_gentleman_leonardo +trainer_socialite_rebecca +trainer_lass_blythe +trainer_rich_boy_roman +trainer_lady_kylie +trainer_reporters_valerie +trainer_school_kid_esteban +trainer_scientist_emilio +trainer_beauty_gabriella +trainer_beauty_harley +trainer_veteran_emanuel +trainer_ruin_maniac_karl +trainer_bird_keeper_audrey +trainer_bird_keeper_geneva +trainer_bird_keeper_krystal +trainer_dragon_tamer_geoffrey +trainer_dragon_tamer_darien +trainer_dragon_tamer_keegan +trainer_dragon_tamer_stanley +trainer_dragon_tamer_drake +trainer_dragon_tamer_kenny +trainer_ace_trainer_rodolfo +trainer_ace_trainer_saul +trainer_ace_trainer_jose +trainer_ace_trainer_felix +trainer_ace_trainer_quinn +trainer_ace_trainer_graham +trainer_ace_trainer_keenan +trainer_ace_trainer_stefan +trainer_ace_trainer_skylar +trainer_ace_trainer_abel +trainer_ace_trainer_deanna +trainer_ace_trainer_moira +trainer_ace_trainer_dana +trainer_ace_trainer_mikayla +trainer_ace_trainer_meagan +trainer_ace_trainer_sandra +trainer_ace_trainer_kassandra +trainer_ace_trainer_jasmin +trainer_ace_trainer_natasha +trainer_ace_trainer_monique +trainer_psychic_corbin +trainer_psychic_sterling +trainer_psychic_daisy +trainer_psychic_chelsey +trainer_black_belt_davon +trainer_black_belt_griffin +trainer_black_belt_ray +trainer_black_belt_jarrett +trainer_ranger_kyler +trainer_ranger_deshawn +trainer_ranger_dwayne +trainer_ranger_ashlee +trainer_ranger_felicia +trainer_ranger_krista +trainer_swimmer_glenn +trainer_swimmer_kurt +trainer_swimmer_sam +trainer_swimmer_wade +trainer_swimmer_joanna +trainer_swimmer_sophia +trainer_swimmer_mallory +trainer_swimmer_lydia +trainer_unknown_605 +trainer_veteran_harlan +trainer_rival_spear_pillar_piplup +trainer_trainer_cheryl_cheryl +trainer_trainer_riley_riley +trainer_trainer_marley_marley +trainer_trainer_buck_buck +trainer_trainer_mira_mira +trainer_lucas_jubilife_city_chimchar +trainer_lucas_jubilife_city_piplup +trainer_lucas_jubilife_city_turtwig +trainer_dawn_jubilife_city_chimchar +trainer_dawn_jubilife_city_piplup +trainer_dawn_jubilife_city_turtwig +trainer_rival_spear_pillar_turtwig +trainer_rival_spear_pillar_chimchar +trainer_lucas_veilstone_city_chimchar +trainer_lucas_veilstone_city_piplup +trainer_lucas_veilstone_city_turtwig +trainer_dawn_veilstone_city_chimchar +trainer_dawn_veilstone_city_piplup +trainer_dawn_veilstone_city_turtwig +trainer_aroma_lady_elizabeth_rematch_1 +trainer_aroma_lady_elizabeth_rematch_2 +trainer_aroma_lady_elizabeth_rematch_3 +trainer_artist_william_rematch_1 +trainer_artist_william_rematch_2 +trainer_artist_william_rematch_3 +trainer_battle_girl_helen_rematch_1 +trainer_battle_girl_helen_rematch_2 +trainer_battle_girl_helen_rematch_3 +trainer_bird_keeper_brianna_rematch_1 +trainer_bird_keeper_brianna_rematch_2 +trainer_bird_keeper_audrey_rematch +trainer_breeder_albert_rematch_1 +trainer_breeder_albert_rematch_2 +trainer_breeder_albert_rematch_3 +trainer_breeder_jennifer_rematch_1 +trainer_breeder_jennifer_rematch_2 +trainer_breeder_jennifer_rematch_3 +trainer_camper_zackary_rematch_1 +trainer_camper_zackary_rematch_2 +trainer_camper_zackary_rematch_3 +trainer_ace_trainer_dalton_rematch +trainer_ace_trainer_olivia_rematch +trainer_collector_ivan_rematch +trainer_unknown_651 +trainer_unknown_652 +trainer_cyclist_john_rematch_1 +trainer_cyclist_john_rematch_2 +trainer_cyclist_john_rematch_3 +trainer_cyclist_kayla_rematch_1 +trainer_cyclist_kayla_rematch_2 +trainer_cyclist_kayla_rematch_3 +trainer_dragon_tamer_patrick_rematch_1 +trainer_dragon_tamer_patrick_rematch_2 +trainer_dragon_tamer_hayden_rematch +trainer_dragon_tamer_geoffrey_rematch +trainer_ace_trainer_jake_rematch +trainer_ace_trainer_dennis_rematch_1 +trainer_ace_trainer_dennis_rematch_2 +trainer_ace_trainer_rodolfo_rematch +trainer_ace_trainer_saul_rematch +trainer_ace_trainer_shannon_rematch +trainer_ace_trainer_maya_rematch_1 +trainer_ace_trainer_maya_rematch_2 +trainer_ace_trainer_deanna_rematch +trainer_ace_trainer_moira_rematch +trainer_psychic_mitchell_rematch_1 +trainer_psychic_mitchell_rematch_2 +trainer_psychic_maxwell_rematch +trainer_psychic_corbin_rematch +trainer_psychic_abigail_rematch_1 +trainer_psychic_abigail_rematch_2 +trainer_psychic_brittney_rematch +trainer_psychic_daisy_rematch +trainer_rancher_marco_rematch_1 +trainer_rancher_marco_rematch_2 +trainer_fisherman_joseph_rematch_1 +trainer_fisherman_joseph_rematch_2 +trainer_fisherman_miguel_rematch +trainer_fisherman_alec_rematch +trainer_twins_teri_and_tia_rematch_1 +trainer_twins_teri_and_tia_rematch_2 +trainer_pi_carlos_rematch_1 +trainer_pi_carlos_rematch_2 +trainer_gentleman_jeremy_rematch_1 +trainer_gentleman_jeremy_rematch_2 +trainer_gentleman_jeremy_rematch_3 +trainer_guitarist_tony_rematch +trainer_ruin_maniac_harry_rematch_1 +trainer_ruin_maniac_harry_rematch_2 +trainer_jogger_craig_rematch_1 +trainer_jogger_craig_rematch_2 +trainer_black_belt_philip_rematch +trainer_black_belt_davon_rematch +trainer_socialite_reina_rematch_1 +trainer_socialite_reina_rematch_2 +trainer_lass_samantha_rematch_1 +trainer_lass_samantha_rematch_2 +trainer_lass_samantha_rematch_3 +trainer_lass_madeline_rematch_1 +trainer_lass_madeline_rematch_2 +trainer_lass_madeline_rematch_3 +trainer_hiker_theodore_rematch_1 +trainer_hiker_theodore_rematch_2 +trainer_hiker_theodore_rematch_3 +trainer_bug_catcher_brandon_rematch_1 +trainer_bug_catcher_brandon_rematch_2 +trainer_bug_catcher_brandon_rematch_3 +trainer_parasol_lady_alexa_rematch_1 +trainer_parasol_lady_alexa_rematch_2 +trainer_parasol_lady_alexa_rematch_3 +trainer_picnicker_karina_rematch_1 +trainer_picnicker_karina_rematch_2 +trainer_picnicker_karina_rematch_3 +trainer_poke_kid_danielle_rematch_1 +trainer_poke_kid_danielle_rematch_2 +trainer_poke_kid_danielle_rematch_3 +trainer_policeman_danny_rematch_1 +trainer_policeman_danny_rematch_2 +trainer_policeman_danny_rematch_3 +trainer_rich_boy_trey_rematch_1 +trainer_rich_boy_trey_rematch_2 +trainer_lady_melissa_rematch_1 +trainer_lady_melissa_rematch_2 +trainer_lady_melissa_rematch_3 +trainer_ranger_taylor_rematch_1 +trainer_ranger_taylor_rematch_2 +trainer_ranger_taylor_rematch_3 +trainer_ranger_kyler_rematch +trainer_ranger_allison_rematch_1 +trainer_ranger_allison_rematch_2 +trainer_ranger_allison_rematch_3 +trainer_ranger_ashlee_rematch +trainer_sailor_marc_rematch_1 +trainer_sailor_marc_rematch_2 +trainer_sailor_zachariah_rematch +trainer_scientist_shaun_rematch_1 +trainer_scientist_shaun_rematch_2 +trainer_scientist_shaun_rematch_3 +trainer_ninja_boy_zach_rematch_1 +trainer_ninja_boy_zach_rematch_2 +trainer_ninja_boy_zach_rematch_3 +trainer_beauty_cyndy_rematch_1 +trainer_beauty_cyndy_rematch_2 +trainer_skier_edward_rematch_1 +trainer_skier_edward_rematch_2 +trainer_skier_bjorn_rematch_1 +trainer_skier_bjorn_rematch_2 +trainer_skier_andrea_rematch_1 +trainer_skier_andrea_rematch_2 +trainer_skier_madison_rematch_1 +trainer_skier_madison_rematch_2 +trainer_swimmer_wesley_rematch +trainer_swimmer_francisco_rematch +trainer_swimmer_glenn_rematch +trainer_swimmer_miranda_rematch +trainer_swimmer_crystal_rematch +trainer_swimmer_joanna_rematch +trainer_youngster_tristan_rematch_1 +trainer_youngster_tristan_rematch_2 +trainer_youngster_tristan_rematch_3 +trainer_youngster_dallas_rematch_1 +trainer_youngster_dallas_rematch_2 +trainer_youngster_dallas_rematch_3 +trainer_tuber_jared_rematch_1 +trainer_tuber_jared_rematch_2 +trainer_tuber_chelsea_rematch_1 +trainer_veteran_brian_rematch_1 +trainer_tuber_chelsea_rematch_2 +trainer_veteran_brian_rematch_2 +trainer_veteran_armando_rematch +trainer_unknown_778 +trainer_unknown_779 +trainer_unknown_780 +trainer_unknown_781 +trainer_unknown_782 +trainer_unknown_783 +trainer_unknown_784 +trainer_unknown_785 +trainer_unknown_786 +trainer_unknown_787 +trainer_unknown_788 +trainer_unknown_789 +trainer_unknown_790 +trainer_unknown_791 +trainer_unknown_792 +trainer_unknown_793 +trainer_unknown_794 +trainer_unknown_795 +trainer_unknown_796 +trainer_unknown_797 +trainer_unknown_798 +trainer_unknown_799 +trainer_unknown_800 +trainer_unknown_801 +trainer_unknown_802 +trainer_unknown_803 +trainer_unknown_804 +trainer_unknown_805 +trainer_unknown_806 +trainer_unknown_807 +trainer_unknown_808 +trainer_unknown_809 +trainer_unknown_810 +trainer_unknown_811 +trainer_unknown_812 +trainer_unknown_813 +trainer_unknown_814 +trainer_unknown_815 +trainer_unknown_816 +trainer_unknown_817 +trainer_unknown_818 +trainer_unknown_819 +trainer_unknown_820 +trainer_unknown_821 +trainer_unknown_822 +trainer_unknown_823 +trainer_unknown_824 +trainer_unknown_825 +trainer_unknown_828 +trainer_ace_trainer_anton +trainer_ace_trainer_brenna +trainer_scientist_darrius +trainer_scientist_fredrick +trainer_scientist_travon +trainer_poke_kid_janet +trainer_unknown_833 +trainer_unknown_834 +trainer_galactic_grunt_iron_island_1 +trainer_galactic_grunt_iron_island_2 +trainer_rival_survival_area_1_piplup +trainer_rival_survival_area_1_turtwig +trainer_rival_survival_area_1_chimchar +trainer_unknown_840 +trainer_unknown_841 +trainer_unknown_842 +trainer_galactic_grunt_valley_windworks_1 +trainer_worker_dillan +trainer_worker_holden +trainer_worker_conrad +trainer_galactic_grunt_valor_lakefront +trainer_galactic_grunt_veilstone_city_1 +trainer_galactic_grunt_veilstone_city_2 +trainer_rival_route_201_piplup +trainer_rival_route_201_turtwig +trainer_rival_route_201_chimchar +trainer_leader_candice_rematch +trainer_leader_maylene_rematch +trainer_leader_volkner_rematch +trainer_leader_byron_rematch +trainer_leader_gardenia_rematch +trainer_leader_roark_rematch +trainer_leader_wake_rematch +trainer_leader_fantina_rematch +trainer_trainer_riley_battleground +trainer_trainer_buck_battleground +trainer_trainer_marley_battleground +trainer_trainer_mira_battleground +trainer_trainer_cheryl_battleground +trainer_elite_four_aaron_rematch +trainer_elite_four_bertha_rematch +trainer_elite_four_flint_rematch +trainer_elite_four_lucian_rematch +trainer_champion_cynthia_rematch +trainer_rival_survival_area_2_piplup +trainer_rival_survival_area_2_turtwig +trainer_rival_survival_area_2_chimchar +trainer_cameraman_tevin +trainer_cameraman_tevin_rematch_1 +trainer_cameraman_tevin_rematch_2 +trainer_guitarist_arturo +trainer_guitarist_arturo_rematch_1 +trainer_guitarist_arturo_rematch_2 +trainer_idol_grace +trainer_idol_grace_rematch_1 +trainer_idol_grace_rematch_2 +trainer_interviewers_roxy_and_oli +trainer_interviewers_roxy_and_oli_rematch_1 +trainer_interviewers_roxy_and_oli_rematch_2 +trainer_clown_lee +trainer_clown_lee_rematch_1 +trainer_clown_lee_rematch_2 +trainer_poke_kid_ariel +trainer_poke_kid_ariel_rematch_1 +trainer_poke_kid_ariel_rematch_2 +trainer_rich_boy_liam +trainer_lady_celeste +trainer_reporters_kinsey +trainer_reporters_kinsey_rematch_1 +trainer_reporters_kinsey_rematch_2 +trainer_maid_belinda +trainer_maid_sophie +trainer_maid_emily +trainer_maid_elena +trainer_maid_clare +trainer_unknown_902 +trainer_unknown_903 +trainer_unknown_904 +trainer_unknown_905 +trainer_cameraman_tevin_rematch_3 +trainer_guitarist_arturo_rematch_3 +trainer_idol_grace_rematch_3 +trainer_interviewers_roxy_and_oli_rematch_3 +trainer_clown_lee_rematch_3 +trainer_poke_kid_ariel_rematch_3 +trainer_reporters_kinsey_rematch_3 +trainer_galactic_boss_cyrus_celestic_town_ruins +trainer_cameraman_tevin_rematch_4 +trainer_guitarist_arturo_rematch_4 +trainer_idol_grace_rematch_4 +trainer_interviewers_roxy_and_oli_rematch_4 +trainer_clown_lee_rematch_4 +trainer_poke_kid_ariel_rematch_4 +trainer_reporters_kinsey_rematch_4 +trainer_leader_volkner_fight_area +trainer_elite_four_flint_fight_area +trainer_rival_fight_area_piplup +trainer_rival_fight_area_turtwig +trainer_rival_fight_area_chimchar +trainer_commander_mars_stark_mountain +trainer_commander_jupiter_stark_mountain From 0c0edafa26b7de3e29e8a7e55f4fb1d288f33369 Mon Sep 17 00:00:00 2001 From: Rachel Date: Sat, 16 Nov 2024 14:02:13 -0800 Subject: [PATCH 07/11] Identify unk_0201D15C -> math --- include/inlines.h | 4 +--- include/{unk_0201D15C.h => math.h} | 6 +++--- platinum.us/main.lsf | 2 +- src/battle/healthbar.c | 2 +- src/battle/ov16_0223B140.c | 2 +- src/battle/ov16_02264798.c | 2 +- src/battle/ov16_0226871C.c | 2 +- src/battle/ov16_0226DE44.c | 2 +- src/bg_window.c | 2 +- src/game_records.c | 2 +- src/game_start.c | 2 +- src/main.c | 2 +- src/{unk_0201D15C.c => math.c} | 6 +----- src/meson.build | 2 +- src/overlay005/ov5_021D5EB8.c | 2 +- src/overlay005/ov5_021E622C.c | 2 +- src/overlay005/ov5_021EB1A0.c | 2 +- src/overlay005/ov5_021F08CC.c | 2 +- src/overlay005/ov5_021F6454.c | 2 +- src/overlay005/ov5_021F8560.c | 2 +- src/overlay005/vs_seeker.c | 2 +- src/overlay006/ov6_0223E140.c | 2 +- src/overlay006/ov6_02240C9C.c | 2 +- src/overlay006/ov6_022426AC.c | 2 +- src/overlay006/ov6_02243258.c | 2 +- src/overlay006/ov6_022465FC.c | 2 +- src/overlay006/ov6_02246A30.c | 2 +- src/overlay008/ov8_02249960.c | 2 +- src/overlay009/ov9_02249960.c | 2 +- src/overlay010/ov10_0221F800.c | 2 +- src/overlay012/ov12_02226B84.c | 2 +- src/overlay012/ov12_0222D6B0.c | 2 +- src/overlay012/ov12_02235E94.c | 2 +- src/overlay017/ov17_022413D8.c | 2 +- src/overlay017/ov17_022476F8.c | 2 +- src/overlay017/ov17_0224A0FC.c | 2 +- src/overlay017/ov17_02250744.c | 2 +- src/overlay019/ov19_021D8B54.c | 2 +- src/overlay019/ov19_021DCF88.c | 2 +- src/overlay021/ov21_021D76B0.c | 2 +- src/overlay021/ov21_021E4CA4.c | 2 +- src/overlay022/ov22_02257F50.c | 2 +- src/overlay022/ov22_022589E0.c | 2 +- src/overlay023/ov23_0223E140.c | 2 +- src/overlay023/ov23_0224340C.c | 2 +- src/overlay023/ov23_02248F1C.c | 2 +- src/overlay023/ov23_0224DC40.c | 2 +- src/overlay033/ov33_02256474.c | 2 +- src/overlay041/ov41_022567B0.c | 2 +- src/overlay042/ov42_022561C0.c | 2 +- src/overlay053/ov53_02256420.c | 2 +- src/overlay058/ov58_021D0D80.c | 2 +- src/overlay059/ov59_021D0D80.c | 2 +- src/overlay062/ov62_022300D8.c | 2 +- src/overlay062/ov62_02234A10.c | 2 +- src/overlay062/ov62_02236CBC.c | 2 +- src/overlay065/ov65_02235060.c | 2 +- src/overlay066/ov66_0222DDF0.c | 2 +- src/overlay069/ov69_0225C700.c | 2 +- src/overlay070/ov70_0225C9B4.c | 2 +- src/overlay070/ov70_02260B44.c | 2 +- src/overlay070/ov70_022630A4.c | 2 +- src/overlay070/ov70_02266E9C.c | 2 +- src/overlay070/ov70_0226CE54.c | 2 +- src/overlay072/ov72_0223D7A0.c | 2 +- src/overlay077/ov77_021D0D80.c | 2 +- src/overlay077/ov77_021D25B0.c | 2 +- src/overlay077/ov77_021D6670.c | 2 +- src/overlay079/ov79_021D2268.c | 2 +- src/overlay083/ov83_0223D6A8.c | 2 +- src/overlay083/ov83_0223F7F4.c | 2 +- src/overlay084/ov84_0223B5A0.c | 2 +- src/overlay086/ov86_0223B140.c | 2 +- src/overlay088/ov88_0223B140.c | 2 +- src/overlay092/ov92_021D0D80.c | 2 +- src/overlay095/ov95_02248590.c | 2 +- src/overlay095/ov95_02249740.c | 2 +- src/overlay095/ov95_0224A390.c | 2 +- src/overlay097/ov97_0222D30C.c | 2 +- src/overlay099/ov99_021D2C08.c | 2 +- src/overlay099/ov99_021D2E28.c | 2 +- src/overlay099/ov99_021D340C.c | 2 +- src/overlay099/ov99_021D4134.c | 2 +- src/overlay100/ov100_021D13E4.c | 2 +- src/overlay100/ov100_021D1C44.c | 2 +- src/overlay100/ov100_021D400C.c | 2 +- src/overlay101/ov101_021D1A28.c | 2 +- src/overlay101/ov101_021D59AC.c | 2 +- src/overlay104/ov104_0222DCE0.c | 2 +- src/overlay104/ov104_0222FBE4.c | 2 +- src/overlay104/ov104_022339B4.c | 2 +- src/overlay104/ov104_02237DD8.c | 2 +- src/overlay104/ov104_0223A7F4.c | 2 +- src/overlay104/ov104_0223AF58.c | 2 +- src/overlay104/ov104_0223B6F4.c | 2 +- src/overlay104/ov104_0223BCBC.c | 2 +- src/overlay108/ov108_02241AE0.c | 2 +- src/overlay109/ov109_021D0D80.c | 2 +- src/overlay109/ov109_021D3D50.c | 2 +- src/overlay111/ov111_021D0D80.c | 2 +- src/overlay113/ov113_0225E368.c | 2 +- src/overlay114/ov114_0225C700.c | 2 +- src/overlay115/ov115_02260CEC.c | 2 +- src/overlay116/ov116_02260440.c | 2 +- src/overlay116/ov116_022604C4.c | 2 +- src/overlay116/ov116_02262A8C.c | 2 +- src/overlay116/ov116_0226432C.c | 2 +- src/overlay117/ov117_02263AF0.c | 2 +- src/poffin.c | 2 +- src/pokemon.c | 2 +- src/record_mixed_rng.c | 2 +- src/savedata.c | 2 +- src/scrcmd.c | 2 +- src/script_manager.c | 2 +- src/trainer_data.c | 2 +- src/unk_02006224.c | 2 +- src/unk_02014D38.c | 2 +- src/unk_02017728.c | 2 +- src/unk_0201E190.c | 2 +- src/unk_0202854C.c | 2 +- src/unk_0202D7A8.c | 2 +- src/unk_0202F1D4.c | 2 +- src/unk_02030CE8.c | 2 +- src/unk_0203D1B8.c | 2 +- src/unk_02048BD0.c | 2 +- src/unk_02049D08.c | 2 +- src/unk_0204B830.c | 2 +- src/unk_0204CDDC.c | 2 +- src/unk_0205B33C.c | 2 +- src/unk_0205DFC4.c | 2 +- src/unk_0206450C.c | 2 +- src/unk_0206AFE0.c | 2 +- src/unk_0206CCB0.c | 2 +- src/unk_0208694C.c | 2 +- src/unk_0208B284.c | 2 +- src/unk_020933F8.c | 2 +- src/unk_02094EDC.c | 2 +- src/unk_020961E8.c | 2 +- 138 files changed, 140 insertions(+), 146 deletions(-) rename include/{unk_0201D15C.h => math.h} (88%) rename src/{unk_0201D15C.c => math.c} (98%) diff --git a/include/inlines.h b/include/inlines.h index f401ccc80d..3188ba65fd 100644 --- a/include/inlines.h +++ b/include/inlines.h @@ -15,14 +15,12 @@ #include "heap.h" #include "location.h" #include "map_header.h" +#include "math.h" #include "narc.h" #include "palette.h" #include "script_manager.h" #include "sys_task.h" #include "sys_task_manager.h" -#include "system_flags.h" -#include "unk_0201D15C.h" -#include "vars_flags.h" static inline void inline_ov61_0222C3B0_sub_1(UnkStruct_ov61_0222C3B0 *); static inline void inline_ov61_0222C3B0_sub(SysTask *, void *); diff --git a/include/unk_0201D15C.h b/include/math.h similarity index 88% rename from include/unk_0201D15C.h rename to include/math.h index 7597d27534..26e150d5e7 100644 --- a/include/unk_0201D15C.h +++ b/include/math.h @@ -1,5 +1,5 @@ -#ifndef POKEPLATINUM_UNK_0201D15C_H -#define POKEPLATINUM_UNK_0201D15C_H +#ifndef POKEPLATINUM_MATH_H +#define POKEPLATINUM_MATH_H #include @@ -26,4 +26,4 @@ void DecodeData(void *data, u32 size, u32 seed); u16 sub_0201D628(const void *param0, u32 param1); void sub_0201D640(int param0); -#endif // POKEPLATINUM_UNK_0201D15C_H +#endif // POKEPLATINUM_MATH_H diff --git a/platinum.us/main.lsf b/platinum.us/main.lsf index 9254926a5e..a20ae68300 100644 --- a/platinum.us/main.lsf +++ b/platinum.us/main.lsf @@ -73,7 +73,7 @@ Static main Object main.nef.p/src_sys_task_manager.c.o Object main.nef.p/src_unk_0201CED8.c.o Object main.nef.p/src_charcode.c.o - Object main.nef.p/src_unk_0201D15C.c.o + Object main.nef.p/src_math.c.o Object main.nef.p/src_text.c.o Object main.nef.p/src_unk_0201DBEC.c.o Object main.nef.p/src_unk_0201DD00.c.o diff --git a/src/battle/healthbar.c b/src/battle/healthbar.c index b0cb63b39d..500accc3e7 100644 --- a/src/battle/healthbar.c +++ b/src/battle/healthbar.c @@ -19,6 +19,7 @@ #include "bg_window.h" #include "cell_actor.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "palette.h" @@ -30,7 +31,6 @@ #include "text.h" #include "unk_0200C440.h" #include "unk_0200C6E4.h" -#include "unk_0201D15C.h" #include "unk_0208C098.h" #define HEALTHBAR_SCROLL_SPEED 24 diff --git a/src/battle/ov16_0223B140.c b/src/battle/ov16_0223B140.c index 801ea6a4c5..9b72a0b86c 100644 --- a/src/battle/ov16_0223B140.c +++ b/src/battle/ov16_0223B140.c @@ -50,6 +50,7 @@ #include "gx_layers.h" #include "hardware_palette.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "overlay_manager.h" @@ -75,7 +76,6 @@ #include "unk_0201567C.h" #include "unk_02015F84.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E3D8.h" #include "unk_0202419C.h" diff --git a/src/battle/ov16_02264798.c b/src/battle/ov16_02264798.c index 0c24dd3bbf..93508bd654 100644 --- a/src/battle/ov16_02264798.c +++ b/src/battle/ov16_02264798.c @@ -9,10 +9,10 @@ #include "battle/struct_ov16_0225BFFC_decl.h" #include "battle/struct_ov16_0225BFFC_t.h" +#include "math.h" #include "sys_task.h" #include "sys_task_manager.h" #include "unk_0200762C.h" -#include "unk_0201D15C.h" static void ov16_02264800(SysTask *param0, void *param1); diff --git a/src/battle/ov16_0226871C.c b/src/battle/ov16_0226871C.c index 315c855a46..df764b4952 100644 --- a/src/battle/ov16_0226871C.c +++ b/src/battle/ov16_0226871C.c @@ -37,6 +37,7 @@ #include "graphics.h" #include "heap.h" #include "inlines.h" +#include "math.h" #include "message.h" #include "message_util.h" #include "move_table.h" @@ -56,7 +57,6 @@ #include "unk_0200C6E4.h" #include "unk_02012744.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201E86C.h" #include "unk_0207C908.h" #include "unk_0208C098.h" diff --git a/src/battle/ov16_0226DE44.c b/src/battle/ov16_0226DE44.c index 58d33b8a8d..2c083d131d 100644 --- a/src/battle/ov16_0226DE44.c +++ b/src/battle/ov16_0226DE44.c @@ -9,12 +9,12 @@ #include "struct_defs/struct_0200D0F4.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "palette.h" #include "sys_task.h" #include "sys_task_manager.h" #include "unk_0200C6E4.h" -#include "unk_0201D15C.h" typedef struct UnkStruct_ov16_0226DEEC_t { CellActorData *unk_00; diff --git a/src/bg_window.c b/src/bg_window.c index a89c90e195..6c538ea57a 100644 --- a/src/bg_window.c +++ b/src/bg_window.c @@ -5,7 +5,7 @@ #include "gx_layers.h" #include "heap.h" -#include "unk_0201D15C.h" +#include "math.h" static u8 ConvertToGxBgScreenSize(u8 bgScreenSize, u8 bgType); static void GetBgScreenTileDimensions(u8 bgScreenSize, u8 *outXTiles, u8 *outYTiles); diff --git a/src/game_records.c b/src/game_records.c index d336fe297f..2b86b58cb9 100644 --- a/src/game_records.c +++ b/src/game_records.c @@ -3,7 +3,7 @@ #include #include "game_records.h" -#include "unk_0201D15C.h" +#include "math.h" #include "unk_0202631C.h" #define START_ENCODED_RECORDS RECORD_TRAINER_SCORE diff --git a/src/game_start.c b/src/game_start.c index 9b69db865f..e2f06ceeee 100644 --- a/src/game_start.c +++ b/src/game_start.c @@ -8,6 +8,7 @@ #include "heap.h" #include "location.h" #include "main.h" +#include "math.h" #include "overlay_manager.h" #include "party.h" #include "pokemon.h" @@ -19,7 +20,6 @@ #include "system_flags.h" #include "trainer_info.h" #include "unk_02017428.h" -#include "unk_0201D15C.h" #include "unk_0205C980.h" #include "unk_0206B9D8.h" #include "vars_flags.h" diff --git a/src/main.c b/src/main.c index 0bc473a821..5e55ec2f1b 100644 --- a/src/main.c +++ b/src/main.c @@ -16,6 +16,7 @@ #include "game_overlay.h" #include "game_start.h" #include "main.h" +#include "math.h" #include "overlay_manager.h" #include "rtc.h" #include "save_player.h" @@ -26,7 +27,6 @@ #include "unk_0200F174.h" #include "unk_02017428.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201E3D8.h" #include "unk_02022844.h" #include "unk_0202419C.h" diff --git a/src/unk_0201D15C.c b/src/math.c similarity index 98% rename from src/unk_0201D15C.c rename to src/math.c index e9ccfffa83..c61eea0d35 100644 --- a/src/unk_0201D15C.c +++ b/src/math.c @@ -1,10 +1,6 @@ -#include "unk_0201D15C.h" - -#include -#include +#include "math.h" #include "heap.h" -#include "inlines.h" typedef struct { MATHCRC16Table unk_00; diff --git a/src/meson.build b/src/meson.build index a997a4e0c8..7fa697aa78 100644 --- a/src/meson.build +++ b/src/meson.build @@ -68,7 +68,7 @@ pokeplatinum_c = files( 'sys_task_manager.c', 'unk_0201CED8.c', 'charcode.c', - 'unk_0201D15C.c', + 'math.c', 'text.c', 'unk_0201DBEC.c', 'unk_0201DD00.c', diff --git a/src/overlay005/ov5_021D5EB8.c b/src/overlay005/ov5_021D5EB8.c index 3ead07b203..978b217bc2 100644 --- a/src/overlay005/ov5_021D5EB8.c +++ b/src/overlay005/ov5_021D5EB8.c @@ -17,6 +17,7 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "sprite_resource.h" #include "sys_task.h" @@ -25,7 +26,6 @@ #include "unk_020093B4.h" #include "unk_0200A328.h" #include "unk_0200A784.h" -#include "unk_0201D15C.h" #include "unk_0201E190.h" #include "unk_0202309C.h" diff --git a/src/overlay005/ov5_021E622C.c b/src/overlay005/ov5_021E622C.c index 6de5650d51..a56166b5ee 100644 --- a/src/overlay005/ov5_021E622C.c +++ b/src/overlay005/ov5_021E622C.c @@ -18,6 +18,7 @@ #include "game_records.h" #include "heap.h" #include "item.h" +#include "math.h" #include "message.h" #include "message_util.h" #include "party.h" @@ -28,7 +29,6 @@ #include "string_template.h" #include "trainer_info.h" #include "unk_02017038.h" -#include "unk_0201D15C.h" #include "unk_020261E4.h" #include "unk_0202CC64.h" #include "unk_020559DC.h" diff --git a/src/overlay005/ov5_021EB1A0.c b/src/overlay005/ov5_021EB1A0.c index 6f06a89a14..36dfa14bfc 100644 --- a/src/overlay005/ov5_021EB1A0.c +++ b/src/overlay005/ov5_021EB1A0.c @@ -19,7 +19,7 @@ #include "overlay101/struct_ov101_021D5D90_decl.h" #include "map_object.h" -#include "unk_0201D15C.h" +#include "math.h" #include "unk_02020AEC.h" typedef struct { diff --git a/src/overlay005/ov5_021F08CC.c b/src/overlay005/ov5_021F08CC.c index 20072f6edd..74d1a53ed0 100644 --- a/src/overlay005/ov5_021F08CC.c +++ b/src/overlay005/ov5_021F08CC.c @@ -22,6 +22,7 @@ #include "game_records.h" #include "heap.h" #include "map_object.h" +#include "math.h" #include "message.h" #include "party.h" #include "player_avatar.h" @@ -33,7 +34,6 @@ #include "sys_task.h" #include "sys_task_manager.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" #include "unk_0205D8CC.h" #include "unk_020655F4.h" #include "unk_0206CCB0.h" diff --git a/src/overlay005/ov5_021F6454.c b/src/overlay005/ov5_021F6454.c index 24c951a9d0..e13f8b97e7 100644 --- a/src/overlay005/ov5_021F6454.c +++ b/src/overlay005/ov5_021F6454.c @@ -29,6 +29,7 @@ #include "inlines.h" #include "list_menu.h" #include "map_object.h" +#include "math.h" #include "message.h" #include "narc.h" #include "party.h" @@ -45,7 +46,6 @@ #include "unk_020041CC.h" #include "unk_02005474.h" #include "unk_0200F174.h" -#include "unk_0201D15C.h" #include "unk_02020AEC.h" #include "unk_0202631C.h" #include "unk_0202C858.h" diff --git a/src/overlay005/ov5_021F8560.c b/src/overlay005/ov5_021F8560.c index 398adbc4d4..33c951b2f4 100644 --- a/src/overlay005/ov5_021F8560.c +++ b/src/overlay005/ov5_021F8560.c @@ -16,8 +16,8 @@ #include "overlay101/struct_ov101_021D86B0.h" #include "map_object.h" +#include "math.h" #include "player_avatar.h" -#include "unk_0201D15C.h" #include "unk_020711EC.h" #include "unk_02073838.h" diff --git a/src/overlay005/vs_seeker.c b/src/overlay005/vs_seeker.c index e9ddd239b8..55f6668227 100644 --- a/src/overlay005/vs_seeker.c +++ b/src/overlay005/vs_seeker.c @@ -16,6 +16,7 @@ #include "heap.h" #include "map_header_data.h" #include "map_object.h" +#include "math.h" #include "player_avatar.h" #include "script_manager.h" #include "string_template.h" @@ -23,7 +24,6 @@ #include "sys_task_manager.h" #include "system_flags.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" #include "unk_020655F4.h" #include "unk_0206AFE0.h" #include "vars_flags.h" diff --git a/src/overlay006/ov6_0223E140.c b/src/overlay006/ov6_0223E140.c index 5e5ced3bb8..590aac9006 100644 --- a/src/overlay006/ov6_0223E140.c +++ b/src/overlay006/ov6_0223E140.c @@ -30,12 +30,12 @@ #include "gx_layers.h" #include "heap.h" #include "map_object.h" +#include "math.h" #include "narc.h" #include "player_avatar.h" #include "sys_task.h" #include "sys_task_manager.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" #include "unk_020655F4.h" void include_unk_ov6_02248F30(); diff --git a/src/overlay006/ov6_02240C9C.c b/src/overlay006/ov6_02240C9C.c index 0a22916da7..16c7d992cb 100644 --- a/src/overlay006/ov6_02240C9C.c +++ b/src/overlay006/ov6_02240C9C.c @@ -36,6 +36,7 @@ #include "map_header.h" #include "map_header_data.h" #include "map_tile_behavior.h" +#include "math.h" #include "narc.h" #include "party.h" #include "player_avatar.h" @@ -47,7 +48,6 @@ #include "system_flags.h" #include "trainer_data.h" #include "trainer_info.h" -#include "unk_0201D15C.h" #include "unk_0202631C.h" #include "unk_0202D7A8.h" #include "unk_02054884.h" diff --git a/src/overlay006/ov6_022426AC.c b/src/overlay006/ov6_022426AC.c index 7029ec6c24..aa8220bfb5 100644 --- a/src/overlay006/ov6_022426AC.c +++ b/src/overlay006/ov6_022426AC.c @@ -8,6 +8,7 @@ #include "cell_actor.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "pokemon.h" #include "sprite_resource.h" @@ -16,7 +17,6 @@ #include "unk_020093B4.h" #include "unk_0200A328.h" #include "unk_020131EC.h" -#include "unk_0201D15C.h" typedef struct UnkStruct_ov6_022426B8_t { SpriteResourceCollection *unk_00[4]; diff --git a/src/overlay006/ov6_02243258.c b/src/overlay006/ov6_02243258.c index a0d9df0535..733d5f4686 100644 --- a/src/overlay006/ov6_02243258.c +++ b/src/overlay006/ov6_02243258.c @@ -18,6 +18,7 @@ #include "gx_layers.h" #include "heap.h" #include "map_object.h" +#include "math.h" #include "narc.h" #include "player_avatar.h" #include "pokemon.h" @@ -29,7 +30,6 @@ #include "unk_0200A328.h" #include "unk_0200F174.h" #include "unk_020131EC.h" -#include "unk_0201D15C.h" #include "unk_0205D8CC.h" #include "unk_020711EC.h" diff --git a/src/overlay006/ov6_022465FC.c b/src/overlay006/ov6_022465FC.c index 405657c7a8..022c03d230 100644 --- a/src/overlay006/ov6_022465FC.c +++ b/src/overlay006/ov6_022465FC.c @@ -10,9 +10,9 @@ #include "overlay006/struct_ov6_022465F4_decl.h" #include "savedata/save_table.h" +#include "math.h" #include "narc.h" #include "rtc.h" -#include "unk_0201D15C.h" #include "unk_0202E2CC.h" #include "unk_020559DC.h" #include "unk_0206CCB0.h" diff --git a/src/overlay006/ov6_02246A30.c b/src/overlay006/ov6_02246A30.c index a0721f620e..f22f66e322 100644 --- a/src/overlay006/ov6_02246A30.c +++ b/src/overlay006/ov6_02246A30.c @@ -10,10 +10,10 @@ #include "field/field_system.h" #include "inlines.h" +#include "math.h" #include "save_player.h" #include "system_flags.h" #include "trainer_info.h" -#include "unk_0201D15C.h" #include "unk_0202631C.h" #include "vars_flags.h" diff --git a/src/overlay008/ov8_02249960.c b/src/overlay008/ov8_02249960.c index 0ae8e4b94c..f42560b060 100644 --- a/src/overlay008/ov8_02249960.c +++ b/src/overlay008/ov8_02249960.c @@ -44,6 +44,7 @@ #include "map_object.h" #include "map_object_move.h" #include "map_tile_behavior.h" +#include "math.h" #include "message.h" #include "player_avatar.h" #include "render_window.h" @@ -55,7 +56,6 @@ #include "sys_task_manager.h" #include "trainer_info.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" #include "unk_02027F50.h" #include "unk_02054D00.h" #include "unk_0205D8CC.h" diff --git a/src/overlay009/ov9_02249960.c b/src/overlay009/ov9_02249960.c index ec2bf209b1..cb79397c89 100644 --- a/src/overlay009/ov9_02249960.c +++ b/src/overlay009/ov9_02249960.c @@ -49,6 +49,7 @@ #include "map_object.h" #include "map_object_move.h" #include "map_tile_behavior.h" +#include "math.h" #include "narc.h" #include "player_avatar.h" #include "resource_collection.h" @@ -62,7 +63,6 @@ #include "unk_020093B4.h" #include "unk_0200A328.h" #include "unk_0201CED8.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_02020AEC.h" #include "unk_02027F50.h" diff --git a/src/overlay010/ov10_0221F800.c b/src/overlay010/ov10_0221F800.c index d6c09eb5e0..a9178422eb 100644 --- a/src/overlay010/ov10_0221F800.c +++ b/src/overlay010/ov10_0221F800.c @@ -37,6 +37,7 @@ #include "item.h" #include "journal.h" #include "map_header.h" +#include "math.h" #include "menu.h" #include "message.h" #include "narc.h" @@ -59,7 +60,6 @@ #include "unk_02012744.h" #include "unk_02014000.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0202419C.h" #include "unk_02024220.h" diff --git a/src/overlay012/ov12_02226B84.c b/src/overlay012/ov12_02226B84.c index d621f2a9dc..5ed3bb3f2e 100644 --- a/src/overlay012/ov12_02226B84.c +++ b/src/overlay012/ov12_02226B84.c @@ -28,13 +28,13 @@ #include "graphics.h" #include "heap.h" #include "inlines.h" +#include "math.h" #include "palette.h" #include "spl.h" #include "sys_task_manager.h" #include "unk_0200762C.h" #include "unk_0200C6E4.h" #include "unk_02014000.h" -#include "unk_0201D15C.h" #include "unk_0201F834.h" typedef struct { diff --git a/src/overlay012/ov12_0222D6B0.c b/src/overlay012/ov12_0222D6B0.c index 5fd2c489a8..b700b3aaed 100644 --- a/src/overlay012/ov12_0222D6B0.c +++ b/src/overlay012/ov12_0222D6B0.c @@ -22,10 +22,10 @@ #include "bg_window.h" #include "heap.h" +#include "math.h" #include "sys_task_manager.h" #include "unk_0200762C.h" #include "unk_0200C6E4.h" -#include "unk_0201D15C.h" typedef struct { u8 unk_00; diff --git a/src/overlay012/ov12_02235E94.c b/src/overlay012/ov12_02235E94.c index a965da98fe..d0bf02ca20 100644 --- a/src/overlay012/ov12_02235E94.c +++ b/src/overlay012/ov12_02235E94.c @@ -26,6 +26,7 @@ #include "overlay104/struct_ov104_02241308.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "palette.h" #include "pokemon.h" @@ -36,7 +37,6 @@ #include "unk_020093B4.h" #include "unk_0200C6E4.h" #include "unk_02014000.h" -#include "unk_0201D15C.h" #include "unk_0202C9F4.h" #include "unk_02097B18.h" diff --git a/src/overlay017/ov17_022413D8.c b/src/overlay017/ov17_022413D8.c index 438ed2fa90..9177083832 100644 --- a/src/overlay017/ov17_022413D8.c +++ b/src/overlay017/ov17_022413D8.c @@ -30,6 +30,7 @@ #include "graphics.h" #include "heap.h" #include "inlines.h" +#include "math.h" #include "message.h" #include "narc.h" #include "palette.h" @@ -44,7 +45,6 @@ #include "unk_0200762C.h" #include "unk_0200C6E4.h" #include "unk_02012744.h" -#include "unk_0201D15C.h" #include "unk_0208C098.h" #include "unk_02094EDC.h" diff --git a/src/overlay017/ov17_022476F8.c b/src/overlay017/ov17_022476F8.c index 4781aa921a..390843fbcd 100644 --- a/src/overlay017/ov17_022476F8.c +++ b/src/overlay017/ov17_022476F8.c @@ -17,6 +17,7 @@ #include "bg_window.h" #include "game_options.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "pokemon.h" @@ -28,7 +29,6 @@ #include "unk_02005474.h" #include "unk_0200762C.h" #include "unk_0200C6E4.h" -#include "unk_0201D15C.h" typedef struct { u8 *unk_00; diff --git a/src/overlay017/ov17_0224A0FC.c b/src/overlay017/ov17_0224A0FC.c index 0e1df667ba..2f5253b887 100644 --- a/src/overlay017/ov17_0224A0FC.c +++ b/src/overlay017/ov17_0224A0FC.c @@ -40,6 +40,7 @@ #include "game_options.h" #include "heap.h" #include "inlines.h" +#include "math.h" #include "message.h" #include "narc.h" #include "palette.h" @@ -55,7 +56,6 @@ #include "unk_0200C6E4.h" #include "unk_02012744.h" #include "unk_02014000.h" -#include "unk_0201D15C.h" #include "unk_020933F8.h" #include "unk_02094EDC.h" diff --git a/src/overlay017/ov17_02250744.c b/src/overlay017/ov17_02250744.c index 49f869c956..2d10c8a31f 100644 --- a/src/overlay017/ov17_02250744.c +++ b/src/overlay017/ov17_02250744.c @@ -20,6 +20,7 @@ #include "game_options.h" #include "graphics.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "palette.h" @@ -34,7 +35,6 @@ #include "unk_02005474.h" #include "unk_0200762C.h" #include "unk_0200C6E4.h" -#include "unk_0201D15C.h" #include "unk_020933F8.h" #include "unk_02094EDC.h" diff --git a/src/overlay019/ov19_021D8B54.c b/src/overlay019/ov19_021D8B54.c index c8bfe5c836..63c16dea41 100644 --- a/src/overlay019/ov19_021D8B54.c +++ b/src/overlay019/ov19_021D8B54.c @@ -18,10 +18,10 @@ #include "cell_actor.h" #include "graphics.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "sys_task.h" #include "sys_task_manager.h" -#include "unk_0201D15C.h" typedef struct { CellActor *unk_00; diff --git a/src/overlay019/ov19_021DCF88.c b/src/overlay019/ov19_021DCF88.c index 5d6eef668a..d9c856ef09 100644 --- a/src/overlay019/ov19_021DCF88.c +++ b/src/overlay019/ov19_021DCF88.c @@ -16,12 +16,12 @@ #include "enums.h" #include "graphics.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "strbuf.h" #include "sys_task.h" #include "sys_task_manager.h" #include "text.h" -#include "unk_0201D15C.h" #include "unk_020797C8.h" typedef struct { diff --git a/src/overlay021/ov21_021D76B0.c b/src/overlay021/ov21_021D76B0.c index b2536ae793..37c9841fca 100644 --- a/src/overlay021/ov21_021D76B0.c +++ b/src/overlay021/ov21_021D76B0.c @@ -26,6 +26,7 @@ #include "cell_actor.h" #include "core_sys.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "sprite_resource.h" #include "touch_screen.h" @@ -34,7 +35,6 @@ #include "unk_0200A328.h" #include "unk_0200A9DC.h" #include "unk_02012744.h" -#include "unk_0201D15C.h" #include "unk_0201F834.h" #include "unk_02023FCC.h" diff --git a/src/overlay021/ov21_021E4CA4.c b/src/overlay021/ov21_021E4CA4.c index 14d72ea314..5979fa7819 100644 --- a/src/overlay021/ov21_021E4CA4.c +++ b/src/overlay021/ov21_021E4CA4.c @@ -24,6 +24,7 @@ #include "cell_actor.h" #include "core_sys.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "sprite_resource.h" #include "touch_screen.h" @@ -33,7 +34,6 @@ #include "unk_0200A328.h" #include "unk_0200A9DC.h" #include "unk_02012744.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201F834.h" #include "unk_02023FCC.h" diff --git a/src/overlay022/ov22_02257F50.c b/src/overlay022/ov22_02257F50.c index 06fc07eddf..96c2c8dfbc 100644 --- a/src/overlay022/ov22_02257F50.c +++ b/src/overlay022/ov22_02257F50.c @@ -18,10 +18,10 @@ #include "overlay022/struct_ov22_022599A0.h" #include "heap.h" +#include "math.h" #include "sys_task_manager.h" #include "touch_screen.h" #include "unk_0200679C.h" -#include "unk_0201D15C.h" typedef struct { UnkStruct_ov22_02259560 *unk_00; diff --git a/src/overlay022/ov22_022589E0.c b/src/overlay022/ov22_022589E0.c index d10ef0d417..17422ffd63 100644 --- a/src/overlay022/ov22_022589E0.c +++ b/src/overlay022/ov22_022589E0.c @@ -20,10 +20,10 @@ #include "core_sys.h" #include "heap.h" +#include "math.h" #include "sys_task_manager.h" #include "unk_02005474.h" #include "unk_0200679C.h" -#include "unk_0201D15C.h" typedef struct { UnkStruct_ov22_0225A0E4 *unk_00; diff --git a/src/overlay023/ov23_0223E140.c b/src/overlay023/ov23_0223E140.c index cb1647fad3..68d020bab2 100644 --- a/src/overlay023/ov23_0223E140.c +++ b/src/overlay023/ov23_0223E140.c @@ -38,6 +38,7 @@ #include "gx_layers.h" #include "heap.h" #include "journal.h" +#include "math.h" #include "menu.h" #include "narc.h" #include "render_window.h" @@ -58,7 +59,6 @@ #include "unk_0200A9DC.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E86C.h" #include "unk_0201F834.h" diff --git a/src/overlay023/ov23_0224340C.c b/src/overlay023/ov23_0224340C.c index 0f80699426..59ee8b8cf5 100644 --- a/src/overlay023/ov23_0224340C.c +++ b/src/overlay023/ov23_0224340C.c @@ -36,6 +36,7 @@ #include "gx_layers.h" #include "heap.h" #include "map_object_move.h" +#include "math.h" #include "narc.h" #include "player_avatar.h" #include "sprite_resource.h" @@ -48,7 +49,6 @@ #include "unk_020093B4.h" #include "unk_0200A328.h" #include "unk_0200A9DC.h" -#include "unk_0201D15C.h" #include "unk_0201E86C.h" #include "unk_0201F834.h" #include "unk_0202854C.h" diff --git a/src/overlay023/ov23_02248F1C.c b/src/overlay023/ov23_02248F1C.c index 9a1890d749..8de14a9cec 100644 --- a/src/overlay023/ov23_02248F1C.c +++ b/src/overlay023/ov23_02248F1C.c @@ -16,6 +16,7 @@ #include "communication_system.h" #include "graphics.h" #include "gx_layers.h" +#include "math.h" #include "narc.h" #include "player_avatar.h" #include "render_window.h" @@ -27,7 +28,6 @@ #include "unk_020093B4.h" #include "unk_0200A328.h" #include "unk_0200F174.h" -#include "unk_0201D15C.h" #include "unk_0205D8CC.h" typedef struct { diff --git a/src/overlay023/ov23_0224DC40.c b/src/overlay023/ov23_0224DC40.c index 636e2b7633..b18caf6aa2 100644 --- a/src/overlay023/ov23_0224DC40.c +++ b/src/overlay023/ov23_0224DC40.c @@ -22,6 +22,7 @@ #include "game_records.h" #include "heap.h" #include "list_menu.h" +#include "math.h" #include "menu.h" #include "message.h" #include "render_window.h" @@ -30,7 +31,6 @@ #include "sys_task_manager.h" #include "trainer_info.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" #include "unk_0202854C.h" #include "unk_020573FC.h" #include "unk_0206AFE0.h" diff --git a/src/overlay033/ov33_02256474.c b/src/overlay033/ov33_02256474.c index d4b8b6122e..2d7b2e068e 100644 --- a/src/overlay033/ov33_02256474.c +++ b/src/overlay033/ov33_02256474.c @@ -21,12 +21,12 @@ #include "graphics.h" #include "heap.h" #include "inlines.h" +#include "math.h" #include "narc.h" #include "pokemon.h" #include "pokemon_icon.h" #include "sys_task.h" #include "sys_task_manager.h" -#include "unk_0201D15C.h" typedef struct { UnkStruct_ov25_022558C4 *unk_00; diff --git a/src/overlay041/ov41_022567B0.c b/src/overlay041/ov41_022567B0.c index b2a102a211..f02ef58adc 100644 --- a/src/overlay041/ov41_022567B0.c +++ b/src/overlay041/ov41_022567B0.c @@ -19,8 +19,8 @@ #include "bg_window.h" #include "graphics.h" #include "heap.h" +#include "math.h" #include "sys_task_manager.h" -#include "unk_0201D15C.h" #include "unk_02099D44.h" struct UnkStruct_ov41_022567B0_t { diff --git a/src/overlay042/ov42_022561C0.c b/src/overlay042/ov42_022561C0.c index 7ea2eb7cfd..96cc300062 100644 --- a/src/overlay042/ov42_022561C0.c +++ b/src/overlay042/ov42_022561C0.c @@ -9,9 +9,9 @@ #include "bg_window.h" #include "heap.h" +#include "math.h" #include "sys_task.h" #include "sys_task_manager.h" -#include "unk_0201D15C.h" #include "unk_02099D44.h" typedef struct { diff --git a/src/overlay053/ov53_02256420.c b/src/overlay053/ov53_02256420.c index 18aa3a2235..95c52cb317 100644 --- a/src/overlay053/ov53_02256420.c +++ b/src/overlay053/ov53_02256420.c @@ -19,9 +19,9 @@ #include "bg_window.h" #include "graphics.h" #include "heap.h" +#include "math.h" #include "pokemon_icon.h" #include "sys_task_manager.h" -#include "unk_0201D15C.h" struct UnkStruct_ov53_02256420_t { const UnkStruct_ov53_02256420_1 *unk_00; diff --git a/src/overlay058/ov58_021D0D80.c b/src/overlay058/ov58_021D0D80.c index fa3fa3a317..d813000a4d 100644 --- a/src/overlay058/ov58_021D0D80.c +++ b/src/overlay058/ov58_021D0D80.c @@ -26,6 +26,7 @@ #include "gx_layers.h" #include "heap.h" #include "journal.h" +#include "math.h" #include "message.h" #include "narc.h" #include "overlay_manager.h" @@ -44,7 +45,6 @@ #include "unk_0200F174.h" #include "unk_02015920.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E3D8.h" #include "unk_0201E86C.h" diff --git a/src/overlay059/ov59_021D0D80.c b/src/overlay059/ov59_021D0D80.c index 8d0588e7f5..f65a5db4fd 100644 --- a/src/overlay059/ov59_021D0D80.c +++ b/src/overlay059/ov59_021D0D80.c @@ -27,6 +27,7 @@ #include "gx_layers.h" #include "heap.h" #include "journal.h" +#include "math.h" #include "menu.h" #include "message.h" #include "message_util.h" @@ -47,7 +48,6 @@ #include "unk_0200A784.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E86C.h" #include "unk_0201F834.h" diff --git a/src/overlay062/ov62_022300D8.c b/src/overlay062/ov62_022300D8.c index 36564e00f7..3035bf8f20 100644 --- a/src/overlay062/ov62_022300D8.c +++ b/src/overlay062/ov62_022300D8.c @@ -21,6 +21,7 @@ #include "bg_window.h" #include "graphics.h" +#include "math.h" #include "message.h" #include "narc.h" #include "palette.h" @@ -31,7 +32,6 @@ #include "text.h" #include "unk_0200C6E4.h" #include "unk_02012744.h" -#include "unk_0201D15C.h" #include "unk_0201E86C.h" #include "unk_02030A80.h" #include "unk_0208C010.h" diff --git a/src/overlay062/ov62_02234A10.c b/src/overlay062/ov62_02234A10.c index efaa04e172..07ea3ad32e 100644 --- a/src/overlay062/ov62_02234A10.c +++ b/src/overlay062/ov62_02234A10.c @@ -15,6 +15,7 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "message.h" #include "palette.h" #include "strbuf.h" @@ -24,7 +25,6 @@ #include "unk_0200C6E4.h" #include "unk_0200F174.h" #include "unk_02012744.h" -#include "unk_0201D15C.h" #include "unk_0208B284.h" static void ov62_02234A10(UnkStruct_0208C06C *param0); diff --git a/src/overlay062/ov62_02236CBC.c b/src/overlay062/ov62_02236CBC.c index 85b5a909a8..9db513c8ed 100644 --- a/src/overlay062/ov62_02236CBC.c +++ b/src/overlay062/ov62_02236CBC.c @@ -18,13 +18,13 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "palette.h" #include "touch_screen.h" #include "unk_02005474.h" #include "unk_0200C6E4.h" #include "unk_02012744.h" -#include "unk_0201D15C.h" #include "unk_0202D05C.h" #include "unk_02030A80.h" #include "unk_0206AFE0.h" diff --git a/src/overlay065/ov65_02235060.c b/src/overlay065/ov65_02235060.c index dddf74ec7c..072a9c83d5 100644 --- a/src/overlay065/ov65_02235060.c +++ b/src/overlay065/ov65_02235060.c @@ -27,11 +27,11 @@ #include "core_sys.h" #include "graphics.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "sprite_resource.h" #include "unk_020093B4.h" #include "unk_0200A328.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #define MCR_PCANM_DESTPL(x) ((7 * 32) + (((x) + 1) * 2)) diff --git a/src/overlay066/ov66_0222DDF0.c b/src/overlay066/ov66_0222DDF0.c index b6babeab91..72e8904c3b 100644 --- a/src/overlay066/ov66_0222DDF0.c +++ b/src/overlay066/ov66_0222DDF0.c @@ -47,6 +47,7 @@ #include "heap.h" #include "inlines.h" #include "journal.h" +#include "math.h" #include "message.h" #include "party.h" #include "pokemon.h" @@ -58,7 +59,6 @@ #include "unk_020041CC.h" #include "unk_02005474.h" #include "unk_02014D38.h" -#include "unk_0201D15C.h" #include "unk_0202631C.h" #include "unk_0202C858.h" #include "unk_02030EA4.h" diff --git a/src/overlay069/ov69_0225C700.c b/src/overlay069/ov69_0225C700.c index 0634ba4480..894396a327 100644 --- a/src/overlay069/ov69_0225C700.c +++ b/src/overlay069/ov69_0225C700.c @@ -30,6 +30,7 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "overlay_manager.h" @@ -49,7 +50,6 @@ #include "unk_0200F174.h" #include "unk_02015920.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E86C.h" #include "unk_0201F834.h" diff --git a/src/overlay070/ov70_0225C9B4.c b/src/overlay070/ov70_0225C9B4.c index a656eae9b4..909b596b7f 100644 --- a/src/overlay070/ov70_0225C9B4.c +++ b/src/overlay070/ov70_0225C9B4.c @@ -22,8 +22,8 @@ #include "core_sys.h" #include "heap.h" +#include "math.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" typedef struct { fx32 unk_00; diff --git a/src/overlay070/ov70_02260B44.c b/src/overlay070/ov70_02260B44.c index f741e5f248..0cd4ebc345 100644 --- a/src/overlay070/ov70_02260B44.c +++ b/src/overlay070/ov70_02260B44.c @@ -13,8 +13,8 @@ #include "easy3d_object.h" #include "graphics.h" #include "heap.h" +#include "math.h" #include "narc.h" -#include "unk_0201D15C.h" typedef struct { BOOL unk_00; diff --git a/src/overlay070/ov70_022630A4.c b/src/overlay070/ov70_022630A4.c index fdfc87a039..efdcdd59a9 100644 --- a/src/overlay070/ov70_022630A4.c +++ b/src/overlay070/ov70_022630A4.c @@ -36,9 +36,9 @@ #include "core_sys.h" #include "enums.h" #include "list_menu.h" +#include "math.h" #include "strbuf.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" typedef struct { fx32 unk_00; diff --git a/src/overlay070/ov70_02266E9C.c b/src/overlay070/ov70_02266E9C.c index b9a9f32cc1..889f70d2c0 100644 --- a/src/overlay070/ov70_02266E9C.c +++ b/src/overlay070/ov70_02266E9C.c @@ -20,9 +20,9 @@ #include "enums.h" #include "list_menu.h" +#include "math.h" #include "strbuf.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" typedef struct { ListMenuTemplate unk_00; diff --git a/src/overlay070/ov70_0226CE54.c b/src/overlay070/ov70_0226CE54.c index 2b69ae6d96..6fba2436e9 100644 --- a/src/overlay070/ov70_0226CE54.c +++ b/src/overlay070/ov70_0226CE54.c @@ -14,8 +14,8 @@ #include "overlay070/struct_ov70_02261E10_decl.h" #include "heap.h" +#include "math.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" typedef struct { u16 unk_00; diff --git a/src/overlay072/ov72_0223D7A0.c b/src/overlay072/ov72_0223D7A0.c index 371836104b..0fae0a9de6 100644 --- a/src/overlay072/ov72_0223D7A0.c +++ b/src/overlay072/ov72_0223D7A0.c @@ -28,6 +28,7 @@ #include "gx_layers.h" #include "heap.h" #include "inlines.h" +#include "math.h" #include "message.h" #include "narc.h" #include "overlay_manager.h" @@ -48,7 +49,6 @@ #include "unk_02012744.h" #include "unk_02015920.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E3D8.h" #include "unk_0201E86C.h" diff --git a/src/overlay077/ov77_021D0D80.c b/src/overlay077/ov77_021D0D80.c index 6910fe48e7..110298bfeb 100644 --- a/src/overlay077/ov77_021D0D80.c +++ b/src/overlay077/ov77_021D0D80.c @@ -17,6 +17,7 @@ #include "gx_layers.h" #include "heap.h" #include "main.h" +#include "math.h" #include "message.h" #include "narc.h" #include "overlay_manager.h" @@ -27,7 +28,6 @@ #include "unk_0200A9DC.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201E190.h" #include "unk_0202419C.h" #include "unk_02024220.h" diff --git a/src/overlay077/ov77_021D25B0.c b/src/overlay077/ov77_021D25B0.c index 0367060a46..8a92e05d0c 100644 --- a/src/overlay077/ov77_021D25B0.c +++ b/src/overlay077/ov77_021D25B0.c @@ -22,6 +22,7 @@ #include "gx_layers.h" #include "heap.h" #include "main.h" +#include "math.h" #include "narc.h" #include "overlay_manager.h" #include "sys_task.h" @@ -32,7 +33,6 @@ #include "unk_0200F174.h" #include "unk_02014000.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0202419C.h" #include "unk_02024220.h" diff --git a/src/overlay077/ov77_021D6670.c b/src/overlay077/ov77_021D6670.c index e3aa900f60..09de9132ad 100644 --- a/src/overlay077/ov77_021D6670.c +++ b/src/overlay077/ov77_021D6670.c @@ -10,13 +10,13 @@ #include "cell_actor.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "sprite_resource.h" #include "sys_task.h" #include "sys_task_manager.h" #include "unk_020093B4.h" #include "unk_0200A328.h" #include "unk_0200A784.h" -#include "unk_0201D15C.h" #include "unk_0201E86C.h" #include "unk_0201F834.h" diff --git a/src/overlay079/ov79_021D2268.c b/src/overlay079/ov79_021D2268.c index a7f6bcb6f1..59c2e8d76f 100644 --- a/src/overlay079/ov79_021D2268.c +++ b/src/overlay079/ov79_021D2268.c @@ -25,6 +25,7 @@ #include "font.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "overlay_manager.h" @@ -41,7 +42,6 @@ #include "unk_0200C6E4.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_020393C8.h" #include "unk_0208C098.h" diff --git a/src/overlay083/ov83_0223D6A8.c b/src/overlay083/ov83_0223D6A8.c index 8867d138b5..c8ffc9b677 100644 --- a/src/overlay083/ov83_0223D6A8.c +++ b/src/overlay083/ov83_0223D6A8.c @@ -43,6 +43,7 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "render_window.h" #include "sprite_resource.h" @@ -56,7 +57,6 @@ #include "unk_0200A328.h" #include "unk_02015064.h" #include "unk_02015920.h" -#include "unk_0201D15C.h" #include "unk_0201E3BC.h" #include "unk_02098FFC.h" diff --git a/src/overlay083/ov83_0223F7F4.c b/src/overlay083/ov83_0223F7F4.c index 26a6509536..e09157d208 100644 --- a/src/overlay083/ov83_0223F7F4.c +++ b/src/overlay083/ov83_0223F7F4.c @@ -21,8 +21,8 @@ #include "berry_data.h" #include "core_sys.h" #include "heap.h" +#include "math.h" #include "poffin.h" -#include "unk_0201D15C.h" #include "unk_0201E3BC.h" s32 ov83_0223F7F4(int param0, int param1, int param2, int param3, int param4, int param5) diff --git a/src/overlay084/ov84_0223B5A0.c b/src/overlay084/ov84_0223B5A0.c index 4123eb8380..b920bb1570 100644 --- a/src/overlay084/ov84_0223B5A0.c +++ b/src/overlay084/ov84_0223B5A0.c @@ -28,6 +28,7 @@ #include "heap.h" #include "item.h" #include "list_menu.h" +#include "math.h" #include "menu.h" #include "message.h" #include "narc.h" @@ -47,7 +48,6 @@ #include "unk_0200C6E4.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E3D8.h" #include "unk_0202D7A8.h" diff --git a/src/overlay086/ov86_0223B140.c b/src/overlay086/ov86_0223B140.c index 5d74d396e9..5b3fcc2e6e 100644 --- a/src/overlay086/ov86_0223B140.c +++ b/src/overlay086/ov86_0223B140.c @@ -24,6 +24,7 @@ #include "gx_layers.h" #include "heap.h" #include "inlines.h" +#include "math.h" #include "message.h" #include "narc.h" #include "overlay_manager.h" @@ -44,7 +45,6 @@ #include "unk_0200F174.h" #include "unk_020131EC.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" typedef struct { fx32 unk_00; diff --git a/src/overlay088/ov88_0223B140.c b/src/overlay088/ov88_0223B140.c index 96ff77fbeb..38e26ad78e 100644 --- a/src/overlay088/ov88_0223B140.c +++ b/src/overlay088/ov88_0223B140.c @@ -38,6 +38,7 @@ #include "item.h" #include "journal.h" #include "list_menu.h" +#include "math.h" #include "menu.h" #include "message.h" #include "message_util.h" @@ -66,7 +67,6 @@ #include "unk_0200F174.h" #include "unk_020131EC.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E86C.h" #include "unk_0201F834.h" diff --git a/src/overlay092/ov92_021D0D80.c b/src/overlay092/ov92_021D0D80.c index 9ad2b83b53..41afb2a481 100644 --- a/src/overlay092/ov92_021D0D80.c +++ b/src/overlay092/ov92_021D0D80.c @@ -19,6 +19,7 @@ #include "gx_layers.h" #include "heap.h" #include "list_menu.h" +#include "math.h" #include "menu.h" #include "message.h" #include "narc.h" @@ -34,7 +35,6 @@ #include "unk_02005474.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0202419C.h" #include "unk_0202C858.h" #include "unk_020996D0.h" diff --git a/src/overlay095/ov95_02248590.c b/src/overlay095/ov95_02248590.c index 91d8ea97d2..cb42c21fd9 100644 --- a/src/overlay095/ov95_02248590.c +++ b/src/overlay095/ov95_02248590.c @@ -21,11 +21,11 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "sys_task.h" #include "sys_task_manager.h" #include "unk_02005474.h" #include "unk_0200F174.h" -#include "unk_0201D15C.h" #include "unk_0202419C.h" enum { diff --git a/src/overlay095/ov95_02249740.c b/src/overlay095/ov95_02249740.c index a5fc60eb77..dd4483e8bf 100644 --- a/src/overlay095/ov95_02249740.c +++ b/src/overlay095/ov95_02249740.c @@ -19,12 +19,12 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "sys_task.h" #include "sys_task_manager.h" #include "unk_02005474.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0202419C.h" enum { diff --git a/src/overlay095/ov95_0224A390.c b/src/overlay095/ov95_0224A390.c index 760a749870..75139c5069 100644 --- a/src/overlay095/ov95_0224A390.c +++ b/src/overlay095/ov95_0224A390.c @@ -19,12 +19,12 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "sys_task.h" #include "sys_task_manager.h" #include "unk_02005474.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0202419C.h" #include "unk_020393C8.h" diff --git a/src/overlay097/ov97_0222D30C.c b/src/overlay097/ov97_0222D30C.c index 8490d6da2e..8c15825285 100644 --- a/src/overlay097/ov97_0222D30C.c +++ b/src/overlay097/ov97_0222D30C.c @@ -31,6 +31,7 @@ #include "heap.h" #include "list_menu.h" #include "main.h" +#include "math.h" #include "message.h" #include "message_util.h" #include "overlay_manager.h" @@ -53,7 +54,6 @@ #include "unk_0200A328.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0202DAB4.h" #include "unk_02033200.h" #include "unk_020363E8.h" diff --git a/src/overlay099/ov99_021D2C08.c b/src/overlay099/ov99_021D2C08.c index ab667c0024..d843b0b532 100644 --- a/src/overlay099/ov99_021D2C08.c +++ b/src/overlay099/ov99_021D2C08.c @@ -12,9 +12,9 @@ #include "overlay099/struct_ov99_021D3A40.h" #include "bg_window.h" +#include "math.h" #include "unk_0200A9DC.h" #include "unk_0200C6E4.h" -#include "unk_0201D15C.h" typedef struct { s32 unk_00; diff --git a/src/overlay099/ov99_021D2E28.c b/src/overlay099/ov99_021D2E28.c index 99b0046e83..cd02bb3c9b 100644 --- a/src/overlay099/ov99_021D2E28.c +++ b/src/overlay099/ov99_021D2E28.c @@ -12,10 +12,10 @@ #include "overlay099/struct_ov99_021D3A40.h" #include "bg_window.h" +#include "math.h" #include "palette.h" #include "unk_0200A9DC.h" #include "unk_0200C6E4.h" -#include "unk_0201D15C.h" typedef struct { s32 unk_00; diff --git a/src/overlay099/ov99_021D340C.c b/src/overlay099/ov99_021D340C.c index 9dfd39f02c..2ed6651bf5 100644 --- a/src/overlay099/ov99_021D340C.c +++ b/src/overlay099/ov99_021D340C.c @@ -12,10 +12,10 @@ #include "overlay099/struct_ov99_021D35E8.h" #include "overlay099/struct_ov99_021D3A40.h" +#include "math.h" #include "palette.h" #include "unk_0200A9DC.h" #include "unk_0200C6E4.h" -#include "unk_0201D15C.h" typedef struct { s16 unk_00; diff --git a/src/overlay099/ov99_021D4134.c b/src/overlay099/ov99_021D4134.c index 3389f7aca1..a833b08aad 100644 --- a/src/overlay099/ov99_021D4134.c +++ b/src/overlay099/ov99_021D4134.c @@ -13,9 +13,9 @@ #include "easy3d_object.h" #include "graphics.h" #include "heap.h" +#include "math.h" #include "palette.h" #include "unk_0200C6E4.h" -#include "unk_0201D15C.h" typedef struct { u16 unk_00; diff --git a/src/overlay100/ov100_021D13E4.c b/src/overlay100/ov100_021D13E4.c index 84a14c5e01..944d7fa304 100644 --- a/src/overlay100/ov100_021D13E4.c +++ b/src/overlay100/ov100_021D13E4.c @@ -21,6 +21,7 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "palette.h" #include "sys_task.h" @@ -28,7 +29,6 @@ #include "unk_02005474.h" #include "unk_0200C6E4.h" #include "unk_0200F174.h" -#include "unk_0201D15C.h" #include "unk_0202419C.h" static void ov100_021D1808(UnkStruct_ov100_021D1808 *param0); diff --git a/src/overlay100/ov100_021D1C44.c b/src/overlay100/ov100_021D1C44.c index 2d36cfb061..925a46b26d 100644 --- a/src/overlay100/ov100_021D1C44.c +++ b/src/overlay100/ov100_021D1C44.c @@ -21,6 +21,7 @@ #include "easy3d_object.h" #include "graphics.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "palette.h" #include "sys_task.h" @@ -30,7 +31,6 @@ #include "unk_02005474.h" #include "unk_0200C6E4.h" #include "unk_0200F174.h" -#include "unk_0201D15C.h" #include "unk_0202419C.h" static void ov100_021D1C98(UnkStruct_ov100_021D1C98 *param0); diff --git a/src/overlay100/ov100_021D400C.c b/src/overlay100/ov100_021D400C.c index d5c5a14232..f3c352fdf6 100644 --- a/src/overlay100/ov100_021D400C.c +++ b/src/overlay100/ov100_021D400C.c @@ -5,9 +5,9 @@ #include "overlay100/struct_ov100_021D4104.h" +#include "math.h" #include "sys_task_manager.h" #include "unk_0200C6E4.h" -#include "unk_0201D15C.h" typedef struct { f32 unk_00; diff --git a/src/overlay101/ov101_021D1A28.c b/src/overlay101/ov101_021D1A28.c index 12b336fdab..4d77e7ffe3 100644 --- a/src/overlay101/ov101_021D1A28.c +++ b/src/overlay101/ov101_021D1A28.c @@ -36,10 +36,10 @@ #include "core_sys.h" #include "enums.h" #include "heap.h" +#include "math.h" #include "sys_task.h" #include "sys_task_manager.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" #include "unk_020711EC.h" typedef struct { diff --git a/src/overlay101/ov101_021D59AC.c b/src/overlay101/ov101_021D59AC.c index 33d2934c7b..87422cbfde 100644 --- a/src/overlay101/ov101_021D59AC.c +++ b/src/overlay101/ov101_021D59AC.c @@ -14,10 +14,10 @@ #include "cell_actor.h" #include "enums.h" +#include "math.h" #include "sys_task.h" #include "sys_task_manager.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" #include "unk_020711EC.h" typedef struct { diff --git a/src/overlay104/ov104_0222DCE0.c b/src/overlay104/ov104_0222DCE0.c index aba25e23c1..6859013e27 100644 --- a/src/overlay104/ov104_0222DCE0.c +++ b/src/overlay104/ov104_0222DCE0.c @@ -21,6 +21,7 @@ #include "flags.h" #include "heap.h" #include "map_header.h" +#include "math.h" #include "message.h" #include "narc.h" #include "party.h" @@ -30,7 +31,6 @@ #include "strbuf.h" #include "string_template.h" #include "trainer_info.h" -#include "unk_0201D15C.h" #include "unk_0202C858.h" #include "unk_02038F8C.h" #include "unk_0208C098.h" diff --git a/src/overlay104/ov104_0222FBE4.c b/src/overlay104/ov104_0222FBE4.c index 7da6aa19cc..083841b66e 100644 --- a/src/overlay104/ov104_0222FBE4.c +++ b/src/overlay104/ov104_0222FBE4.c @@ -67,6 +67,7 @@ #include "field_comm_manager.h" #include "game_records.h" #include "heap.h" +#include "math.h" #include "menu.h" #include "message.h" #include "narc.h" @@ -88,7 +89,6 @@ #include "unk_0200F174.h" #include "unk_02014000.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0202ACE0.h" #include "unk_0202D05C.h" #include "unk_0202F1D4.h" diff --git a/src/overlay104/ov104_022339B4.c b/src/overlay104/ov104_022339B4.c index 01f1932da0..0fe6bf18df 100644 --- a/src/overlay104/ov104_022339B4.c +++ b/src/overlay104/ov104_022339B4.c @@ -21,10 +21,10 @@ #include "game_records.h" #include "heap.h" +#include "math.h" #include "party.h" #include "pokemon.h" #include "savedata.h" -#include "unk_0201D15C.h" #include "unk_0202FF4C.h" #include "unk_0203061C.h" #include "unk_0205DFC4.h" diff --git a/src/overlay104/ov104_02237DD8.c b/src/overlay104/ov104_02237DD8.c index ba7735fbf1..0550e42b80 100644 --- a/src/overlay104/ov104_02237DD8.c +++ b/src/overlay104/ov104_02237DD8.c @@ -27,12 +27,12 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "palette.h" #include "party.h" #include "pokemon.h" #include "savedata.h" -#include "unk_0201D15C.h" #include "unk_02030494.h" #include "unk_0203061C.h" #include "unk_0205DFC4.h" diff --git a/src/overlay104/ov104_0223A7F4.c b/src/overlay104/ov104_0223A7F4.c index 0e58c86115..ac64826735 100644 --- a/src/overlay104/ov104_0223A7F4.c +++ b/src/overlay104/ov104_0223A7F4.c @@ -19,12 +19,12 @@ #include "communication_system.h" #include "field_battle_data_transfer.h" #include "heap.h" +#include "math.h" #include "message.h" #include "party.h" #include "pokemon.h" #include "strbuf.h" #include "trainer_info.h" -#include "unk_0201D15C.h" #include "unk_02096420.h" static const struct { diff --git a/src/overlay104/ov104_0223AF58.c b/src/overlay104/ov104_0223AF58.c index fe9242509b..345762b293 100644 --- a/src/overlay104/ov104_0223AF58.c +++ b/src/overlay104/ov104_0223AF58.c @@ -18,10 +18,10 @@ #include "communication_system.h" #include "field_battle_data_transfer.h" #include "heap.h" +#include "math.h" #include "party.h" #include "pokemon.h" #include "trainer_info.h" -#include "unk_0201D15C.h" #include "unk_02030108.h" #include "unk_02096420.h" diff --git a/src/overlay104/ov104_0223B6F4.c b/src/overlay104/ov104_0223B6F4.c index d2c55e469b..a4f05770f7 100644 --- a/src/overlay104/ov104_0223B6F4.c +++ b/src/overlay104/ov104_0223B6F4.c @@ -19,13 +19,13 @@ #include "communication_system.h" #include "field_battle_data_transfer.h" #include "heap.h" +#include "math.h" #include "message.h" #include "party.h" #include "pokemon.h" #include "save_player.h" #include "strbuf.h" #include "trainer_info.h" -#include "unk_0201D15C.h" #include "unk_0203061C.h" #include "unk_0205DFC4.h" #include "unk_02096420.h" diff --git a/src/overlay104/ov104_0223BCBC.c b/src/overlay104/ov104_0223BCBC.c index b2c70c3635..eceec063cc 100644 --- a/src/overlay104/ov104_0223BCBC.c +++ b/src/overlay104/ov104_0223BCBC.c @@ -15,13 +15,13 @@ #include "communication_system.h" #include "field_battle_data_transfer.h" #include "heap.h" +#include "math.h" #include "message.h" #include "party.h" #include "pokemon.h" #include "save_player.h" #include "strbuf.h" #include "trainer_info.h" -#include "unk_0201D15C.h" #include "unk_02096420.h" u8 ov104_0223BD70(u8 param0, BOOL param1); diff --git a/src/overlay108/ov108_02241AE0.c b/src/overlay108/ov108_02241AE0.c index 60e610bdda..6e39828ee0 100644 --- a/src/overlay108/ov108_02241AE0.c +++ b/src/overlay108/ov108_02241AE0.c @@ -28,6 +28,7 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "menu.h" #include "message.h" #include "narc.h" @@ -47,7 +48,6 @@ #include "unk_0200A784.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_02030494.h" #include "unk_0203061C.h" diff --git a/src/overlay109/ov109_021D0D80.c b/src/overlay109/ov109_021D0D80.c index 9acc6ef622..1adffe501a 100644 --- a/src/overlay109/ov109_021D0D80.c +++ b/src/overlay109/ov109_021D0D80.c @@ -38,6 +38,7 @@ #include "gx_layers.h" #include "heap.h" #include "journal.h" +#include "math.h" #include "message.h" #include "narc.h" #include "overlay_manager.h" @@ -57,7 +58,6 @@ #include "unk_0200C6E4.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E3D8.h" #include "unk_0202419C.h" diff --git a/src/overlay109/ov109_021D3D50.c b/src/overlay109/ov109_021D3D50.c index 2e55eefff8..bf1d01684d 100644 --- a/src/overlay109/ov109_021D3D50.c +++ b/src/overlay109/ov109_021D3D50.c @@ -26,6 +26,7 @@ #include "gx_layers.h" #include "heap.h" #include "journal.h" +#include "math.h" #include "menu.h" #include "message.h" #include "message_util.h" @@ -47,7 +48,6 @@ #include "unk_0200A784.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E86C.h" #include "unk_0201F834.h" diff --git a/src/overlay111/ov111_021D0D80.c b/src/overlay111/ov111_021D0D80.c index 647028bf44..af19b0d033 100644 --- a/src/overlay111/ov111_021D0D80.c +++ b/src/overlay111/ov111_021D0D80.c @@ -25,6 +25,7 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "overlay_manager.h" @@ -44,7 +45,6 @@ #include "unk_0201567C.h" #include "unk_02015920.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E3D8.h" diff --git a/src/overlay113/ov113_0225E368.c b/src/overlay113/ov113_0225E368.c index 52fdd1c861..371a122887 100644 --- a/src/overlay113/ov113_0225E368.c +++ b/src/overlay113/ov113_0225E368.c @@ -29,11 +29,11 @@ #include "easy3d_object.h" #include "graphics.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "pokemon.h" #include "unk_02005474.h" #include "unk_0200F174.h" -#include "unk_0201D15C.h" __attribute__((aligned(4))) static const s16 Unk_ov113_02260BCC[] = { 0xFF, diff --git a/src/overlay114/ov114_0225C700.c b/src/overlay114/ov114_0225C700.c index da2de276fa..58ca92480a 100644 --- a/src/overlay114/ov114_0225C700.c +++ b/src/overlay114/ov114_0225C700.c @@ -29,6 +29,7 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "render_window.h" @@ -49,7 +50,6 @@ #include "unk_0200F174.h" #include "unk_02015920.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E86C.h" #include "unk_0201F834.h" diff --git a/src/overlay115/ov115_02260CEC.c b/src/overlay115/ov115_02260CEC.c index 23aadbe4aa..f5e4bdbdbc 100644 --- a/src/overlay115/ov115_02260CEC.c +++ b/src/overlay115/ov115_02260CEC.c @@ -34,6 +34,7 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "render_window.h" @@ -49,7 +50,6 @@ #include "unk_0200A784.h" #include "unk_0200A9DC.h" #include "unk_02012744.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E3D8.h" #include "unk_0201E86C.h" diff --git a/src/overlay116/ov116_02260440.c b/src/overlay116/ov116_02260440.c index 6699594c28..55f70d2db7 100644 --- a/src/overlay116/ov116_02260440.c +++ b/src/overlay116/ov116_02260440.c @@ -12,7 +12,7 @@ #include "overlay116/struct_ov116_02260498.h" #include "overlay116/struct_ov116_0226139C.h" -#include "unk_0201D15C.h" +#include "math.h" #include "unk_02032798.h" static void ov116_02260440(int param0, int param1, void *param2, void *param3); diff --git a/src/overlay116/ov116_022604C4.c b/src/overlay116/ov116_022604C4.c index c40b113eb6..abe1746f6b 100644 --- a/src/overlay116/ov116_022604C4.c +++ b/src/overlay116/ov116_022604C4.c @@ -31,6 +31,7 @@ #include "easy3d_object.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "overlay_manager.h" #include "palette.h" @@ -39,7 +40,6 @@ #include "unk_0200C6E4.h" #include "unk_0200F174.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E3D8.h" #include "unk_02024220.h" diff --git a/src/overlay116/ov116_02262A8C.c b/src/overlay116/ov116_02262A8C.c index 04d2fc7c51..4568207f28 100644 --- a/src/overlay116/ov116_02262A8C.c +++ b/src/overlay116/ov116_02262A8C.c @@ -18,13 +18,13 @@ #include "easy3d_object.h" #include "heap.h" #include "inlines.h" +#include "math.h" #include "sys_task.h" #include "sys_task_manager.h" #include "touch_screen.h" #include "unk_02005474.h" #include "unk_0200C6E4.h" #include "unk_0200F174.h" -#include "unk_0201D15C.h" static const s16 Unk_ov116_02267BFC[] = { -2, diff --git a/src/overlay116/ov116_0226432C.c b/src/overlay116/ov116_0226432C.c index 9906752733..ba267523c4 100644 --- a/src/overlay116/ov116_0226432C.c +++ b/src/overlay116/ov116_0226432C.c @@ -24,13 +24,13 @@ #include "easy3d_object.h" #include "heap.h" #include "inlines.h" +#include "math.h" #include "palette.h" #include "sys_task.h" #include "sys_task_manager.h" #include "unk_02005474.h" #include "unk_0200C6E4.h" #include "unk_0200F174.h" -#include "unk_0201D15C.h" typedef struct { CellActorData *unk_00; diff --git a/src/overlay117/ov117_02263AF0.c b/src/overlay117/ov117_02263AF0.c index d3736683ec..62f2960f2f 100644 --- a/src/overlay117/ov117_02263AF0.c +++ b/src/overlay117/ov117_02263AF0.c @@ -36,6 +36,7 @@ #include "error_handling.h" #include "font.h" #include "graphics.h" +#include "math.h" #include "message.h" #include "narc.h" #include "palette.h" @@ -44,7 +45,6 @@ #include "unk_02005474.h" #include "unk_0200C6E4.h" #include "unk_02012744.h" -#include "unk_0201D15C.h" #include "unk_0201E86C.h" typedef struct { diff --git a/src/poffin.c b/src/poffin.c index 3b73f51d4b..d24f3cd53e 100644 --- a/src/poffin.c +++ b/src/poffin.c @@ -7,8 +7,8 @@ #include "struct_defs/struct_0202AB28.h" #include "heap.h" +#include "math.h" #include "savedata.h" -#include "unk_0201D15C.h" int Poffin_sizeof(void) { diff --git a/src/pokemon.c b/src/pokemon.c index e4cd9b3637..7744370271 100644 --- a/src/pokemon.c +++ b/src/pokemon.c @@ -38,6 +38,7 @@ #include "heap.h" #include "inlines.h" #include "item.h" +#include "math.h" #include "message.h" #include "message_util.h" #include "move_table.h" @@ -54,7 +55,6 @@ #include "unk_0200C6E4.h" #include "unk_02015F84.h" #include "unk_02017038.h" -#include "unk_0201D15C.h" #include "unk_02028124.h" #include "unk_0202C9F4.h" #include "unk_02092494.h" diff --git a/src/record_mixed_rng.c b/src/record_mixed_rng.c index 254c4183e0..b5b2f67e50 100644 --- a/src/record_mixed_rng.c +++ b/src/record_mixed_rng.c @@ -6,9 +6,9 @@ #include "charcode.h" #include "charcode_util.h" +#include "math.h" #include "savedata.h" #include "strbuf.h" -#include "unk_0201D15C.h" RecordMixedRNG *sRNGCollection; diff --git a/src/savedata.c b/src/savedata.c index ef2ef62e82..97bc6c9b8c 100644 --- a/src/savedata.c +++ b/src/savedata.c @@ -9,9 +9,9 @@ #include "heap.h" #include "inlines.h" +#include "math.h" #include "savedata_misc.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0209A74C.h" #include "unk_0209AA74.h" diff --git a/src/scrcmd.c b/src/scrcmd.c index 629dcb0780..83ed723696 100644 --- a/src/scrcmd.c +++ b/src/scrcmd.c @@ -113,6 +113,7 @@ #include "map_header_data.h" #include "map_object.h" #include "map_object_move.h" +#include "math.h" #include "menu.h" #include "message.h" #include "message_util.h" @@ -141,7 +142,6 @@ #include "unk_020041CC.h" #include "unk_0200F174.h" #include "unk_02014D38.h" -#include "unk_0201D15C.h" #include "unk_020261E4.h" #include "unk_0202631C.h" #include "unk_02028124.h" diff --git a/src/script_manager.c b/src/script_manager.c index 12fb060c30..e114a546f9 100644 --- a/src/script_manager.c +++ b/src/script_manager.c @@ -16,12 +16,12 @@ #include "map_header.h" #include "map_header_data.h" #include "map_object.h" +#include "math.h" #include "message.h" #include "narc.h" #include "player_avatar.h" #include "strbuf.h" #include "trainer_data.h" -#include "unk_0201D15C.h" #include "vars_flags.h" #include "constdata/const_020EAB80.h" diff --git a/src/trainer_data.c b/src/trainer_data.c index 56bb09ad40..e9f784703d 100644 --- a/src/trainer_data.c +++ b/src/trainer_data.c @@ -12,6 +12,7 @@ #include "charcode_util.h" #include "field_battle_data_transfer.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "party.h" @@ -20,7 +21,6 @@ #include "savedata_misc.h" #include "strbuf.h" #include "trainer_data.h" -#include "unk_0201D15C.h" static void TrainerData_BuildParty(FieldBattleDTO *dto, int battler, int heapID); diff --git a/src/unk_02006224.c b/src/unk_02006224.c index b5276797fc..e717dd74a3 100644 --- a/src/unk_02006224.c +++ b/src/unk_02006224.c @@ -4,10 +4,10 @@ #include "struct_defs/chatot_cry.h" #include "struct_defs/struct_02004CB4.h" +#include "math.h" #include "unk_02003B60.h" #include "unk_020041CC.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" #include "unk_0202CC64.h" BOOL CheckMicRecordingStatus(void); diff --git a/src/unk_02014D38.c b/src/unk_02014D38.c index 9da9e402ab..4e71de00d3 100644 --- a/src/unk_02014D38.c +++ b/src/unk_02014D38.c @@ -5,11 +5,11 @@ #include "graphics.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "savedata.h" #include "strbuf.h" -#include "unk_0201D15C.h" static const u16 Unk_020E5522[] = { 0x1F0, diff --git a/src/unk_02017728.c b/src/unk_02017728.c index 210c96ce30..4fcfb1ad95 100644 --- a/src/unk_02017728.c +++ b/src/unk_02017728.c @@ -7,8 +7,8 @@ #include "core_sys.h" #include "heap.h" +#include "math.h" #include "sys_task_manager.h" -#include "unk_0201D15C.h" #include "unk_02024358.h" typedef struct { diff --git a/src/unk_0201E190.c b/src/unk_0201E190.c index 249b23208e..4c806f2579 100644 --- a/src/unk_0201E190.c +++ b/src/unk_0201E190.c @@ -5,7 +5,7 @@ #include #include -#include "unk_0201D15C.h" +#include "math.h" #define F32_PI ((f32)3.14159265358979323846) #define FX_F32_RAD_TO_IDX(f) ((u16)(FX_RAD_TO_IDX(FX32_CONST(f)))) diff --git a/src/unk_0202854C.c b/src/unk_0202854C.c index f3cc2ece4a..b8c915720c 100644 --- a/src/unk_0202854C.c +++ b/src/unk_0202854C.c @@ -11,10 +11,10 @@ #include "core_sys.h" #include "heap.h" +#include "math.h" #include "rtc.h" #include "savedata.h" #include "trainer_info.h" -#include "unk_0201D15C.h" static void sub_02028B48(UndergroundData *param0, int param1, int param2); diff --git a/src/unk_0202D7A8.c b/src/unk_0202D7A8.c index 2475428986..e3277cb38b 100644 --- a/src/unk_0202D7A8.c +++ b/src/unk_0202D7A8.c @@ -9,8 +9,8 @@ #include "struct_defs/struct_020698E4.h" #include "struct_defs/struct_0206C638.h" +#include "math.h" #include "savedata.h" -#include "unk_0201D15C.h" int SpecialEncounter_SaveSize(void) { diff --git a/src/unk_0202F1D4.c b/src/unk_0202F1D4.c index 8fb42f69b4..2083d72766 100644 --- a/src/unk_0202F1D4.c +++ b/src/unk_0202F1D4.c @@ -22,6 +22,7 @@ #include "field_battle_data_transfer.h" #include "game_options.h" #include "heap.h" +#include "math.h" #include "party.h" #include "pokemon.h" #include "save_player.h" @@ -29,7 +30,6 @@ #include "trainer_info.h" #include "unk_02006224.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_02026150.h" #include "unk_0202631C.h" diff --git a/src/unk_02030CE8.c b/src/unk_02030CE8.c index 81bf2743b8..23f8e7e770 100644 --- a/src/unk_02030CE8.c +++ b/src/unk_02030CE8.c @@ -9,10 +9,10 @@ #include "overlay096/struct_ov96_0223B574.h" #include "charcode_util.h" +#include "math.h" #include "save_player.h" #include "savedata.h" #include "trainer_info.h" -#include "unk_0201D15C.h" #include "unk_0202C858.h" static void sub_02030DD0(SaveData *param0, UnkStruct_ov96_0223B574 *param1); diff --git a/src/unk_0203D1B8.c b/src/unk_0203D1B8.c index 9afb53327b..40e0643a66 100644 --- a/src/unk_0203D1B8.c +++ b/src/unk_0203D1B8.c @@ -95,6 +95,7 @@ #include "game_options.h" #include "game_records.h" #include "heap.h" +#include "math.h" #include "overlay_manager.h" #include "party.h" #include "player_avatar.h" @@ -110,7 +111,6 @@ #include "system_flags.h" #include "trainer_info.h" #include "unk_02017498.h" -#include "unk_0201D15C.h" #include "unk_0202631C.h" #include "unk_02028124.h" #include "unk_020298BC.h" diff --git a/src/unk_02048BD0.c b/src/unk_02048BD0.c index 28781caef1..1e116e0bde 100644 --- a/src/unk_02048BD0.c +++ b/src/unk_02048BD0.c @@ -5,6 +5,7 @@ #include "field_script_context.h" #include "inlines.h" +#include "math.h" #include "record_mixed_rng.h" #include "save_player.h" #include "savedata.h" @@ -12,7 +13,6 @@ #include "strbuf.h" #include "string_template.h" #include "trainer_info.h" -#include "unk_0201D15C.h" #include "unk_0203D1B8.h" #include "unk_0206CCB0.h" diff --git a/src/unk_02049D08.c b/src/unk_02049D08.c index b3af969a05..d5510164ae 100644 --- a/src/unk_02049D08.c +++ b/src/unk_02049D08.c @@ -25,6 +25,7 @@ #include "inlines.h" #include "journal.h" #include "location.h" +#include "math.h" #include "party.h" #include "player_avatar.h" #include "pokemon.h" @@ -32,7 +33,6 @@ #include "savedata.h" #include "system_flags.h" #include "trainer_info.h" -#include "unk_0201D15C.h" #include "unk_0202D05C.h" #include "unk_0203061C.h" #include "unk_0204AEE8.h" diff --git a/src/unk_0204B830.c b/src/unk_0204B830.c index cd5a5b5d9c..5c66d666a8 100644 --- a/src/unk_0204B830.c +++ b/src/unk_0204B830.c @@ -15,6 +15,7 @@ #include "field_script_context.h" #include "heap.h" #include "inlines.h" +#include "math.h" #include "party.h" #include "pokemon.h" #include "poketch_data.h" @@ -25,7 +26,6 @@ #include "string_template.h" #include "trainer_info.h" #include "unk_02017038.h" -#include "unk_0201D15C.h" #include "unk_0202602C.h" #include "unk_0202854C.h" #include "unk_020298BC.h" diff --git a/src/unk_0204CDDC.c b/src/unk_0204CDDC.c index 640f4bb14e..5c2dea5e8d 100644 --- a/src/unk_0204CDDC.c +++ b/src/unk_0204CDDC.c @@ -7,7 +7,7 @@ #include "field_script_context.h" #include "inlines.h" -#include "unk_0201D15C.h" +#include "math.h" #include "unk_0206AFE0.h" #include "vars_flags.h" diff --git a/src/unk_0205B33C.c b/src/unk_0205B33C.c index e9f1e620d2..83d23ccaa6 100644 --- a/src/unk_0205B33C.c +++ b/src/unk_0205B33C.c @@ -18,6 +18,7 @@ #include "field_task.h" #include "heap.h" #include "journal.h" +#include "math.h" #include "message.h" #include "save_player.h" #include "savedata.h" @@ -28,7 +29,6 @@ #include "trainer_info.h" #include "unk_02014A84.h" #include "unk_02014D38.h" -#include "unk_0201D15C.h" #include "unk_02033200.h" #include "unk_020366A0.h" #include "unk_0205C980.h" diff --git a/src/unk_0205DFC4.c b/src/unk_0205DFC4.c index 0a9df27cb3..8fe87c4711 100644 --- a/src/unk_0205DFC4.c +++ b/src/unk_0205DFC4.c @@ -14,12 +14,12 @@ #include "field_task.h" #include "heap.h" #include "map_object.h" +#include "math.h" #include "party.h" #include "pokemon.h" #include "save_player.h" #include "savedata.h" #include "trainer_info.h" -#include "unk_0201D15C.h" typedef struct { MapObject *unk_00; diff --git a/src/unk_0206450C.c b/src/unk_0206450C.c index c605a5c85e..7aeadd5cd2 100644 --- a/src/unk_0206450C.c +++ b/src/unk_0206450C.c @@ -10,8 +10,8 @@ #include "map_object.h" #include "map_object_move.h" +#include "math.h" #include "player_avatar.h" -#include "unk_0201D15C.h" #include "unk_0205F180.h" #include "unk_020655F4.h" #include "unk_02067A84.h" diff --git a/src/unk_0206AFE0.c b/src/unk_0206AFE0.c index f44a6041b5..ceaeb27182 100644 --- a/src/unk_0206AFE0.c +++ b/src/unk_0206AFE0.c @@ -10,10 +10,10 @@ #include "field_overworld_state.h" #include "location.h" +#include "math.h" #include "record_mixed_rng.h" #include "savedata.h" #include "system_flags.h" -#include "unk_0201D15C.h" #include "vars_flags.h" static BOOL sub_0206AFE0(VarsFlags *param0, u16 param1, u16 param2); diff --git a/src/unk_0206CCB0.c b/src/unk_0206CCB0.c index 81669c9029..05b75c4d37 100644 --- a/src/unk_0206CCB0.c +++ b/src/unk_0206CCB0.c @@ -39,6 +39,7 @@ #include "heap.h" #include "inlines.h" #include "map_header.h" +#include "math.h" #include "message.h" #include "party.h" #include "pokemon.h" @@ -52,7 +53,6 @@ #include "string_template.h" #include "system_flags.h" #include "trainer_info.h" -#include "unk_0201D15C.h" #include "unk_0202631C.h" #include "unk_020298BC.h" #include "unk_0202D7A8.h" diff --git a/src/unk_0208694C.c b/src/unk_0208694C.c index d61bc92c0a..f008955c08 100644 --- a/src/unk_0208694C.c +++ b/src/unk_0208694C.c @@ -19,6 +19,7 @@ #include "graphics.h" #include "gx_layers.h" #include "heap.h" +#include "math.h" #include "message.h" #include "message_util.h" #include "narc.h" @@ -41,7 +42,6 @@ #include "unk_02012744.h" #include "unk_0201567C.h" #include "unk_02017728.h" -#include "unk_0201D15C.h" #include "unk_0201DBEC.h" #include "unk_0201E86C.h" #include "unk_0201F834.h" diff --git a/src/unk_0208B284.c b/src/unk_0208B284.c index ce8a84d600..d309cc3674 100644 --- a/src/unk_0208B284.c +++ b/src/unk_0208B284.c @@ -10,12 +10,12 @@ #include "struct_defs/struct_0208B878.h" #include "heap.h" +#include "math.h" #include "narc.h" #include "palette.h" #include "sys_task.h" #include "sys_task_manager.h" #include "unk_0200C6E4.h" -#include "unk_0201D15C.h" typedef struct { f32 unk_00; diff --git a/src/unk_020933F8.c b/src/unk_020933F8.c index 428dbf0c0a..bdc402d9ee 100644 --- a/src/unk_020933F8.c +++ b/src/unk_020933F8.c @@ -35,6 +35,7 @@ #include "game_records.h" #include "heap.h" #include "journal.h" +#include "math.h" #include "party.h" #include "pokemon.h" #include "ribbon.h" @@ -48,7 +49,6 @@ #include "trainer_info.h" #include "unk_02005474.h" #include "unk_0200A9DC.h" -#include "unk_0201D15C.h" #include "unk_0202631C.h" #include "unk_020298BC.h" #include "unk_0202CC64.h" diff --git a/src/unk_02094EDC.c b/src/unk_02094EDC.c index 292512a5d5..5dc37339f2 100644 --- a/src/unk_02094EDC.c +++ b/src/unk_02094EDC.c @@ -16,6 +16,7 @@ #include "graphics.h" #include "heap.h" +#include "math.h" #include "message.h" #include "narc.h" #include "pokemon.h" @@ -23,7 +24,6 @@ #include "strbuf.h" #include "unk_0200762C.h" #include "unk_020131EC.h" -#include "unk_0201D15C.h" #include "unk_020298BC.h" #include "unk_020933F8.h" diff --git a/src/unk_020961E8.c b/src/unk_020961E8.c index 9607328dd5..b3fd7af0d3 100644 --- a/src/unk_020961E8.c +++ b/src/unk_020961E8.c @@ -11,8 +11,8 @@ #include "overlay059/struct_ov59_021D30E0.h" #include "communication_system.h" +#include "math.h" #include "unk_02005474.h" -#include "unk_0201D15C.h" #include "unk_02030EE0.h" #include "unk_02032798.h" #include "unk_020366A0.h" From 5cb7907656cfcb9e66d8dc6111985f9e00e9f8cc Mon Sep 17 00:00:00 2001 From: Rachel Date: Sat, 16 Nov 2024 15:53:50 -0800 Subject: [PATCH 08/11] Document math.c --- include/math.h | 38 +++-- src/battle/healthbar.c | 2 +- src/battle/ov16_02264798.c | 2 +- src/battle/ov16_0226DE44.c | 2 +- src/bg_window.c | 10 +- src/math.c | 256 ++++++++++++++++---------------- src/overlay005/ov5_021F8560.c | 4 +- src/overlay006/ov6_0223E140.c | 16 +- src/overlay006/ov6_02243258.c | 56 +++---- src/overlay009/ov9_02249960.c | 6 +- src/overlay012/ov12_02226B84.c | 2 +- src/overlay017/ov17_022413D8.c | 8 +- src/overlay017/ov17_022476F8.c | 2 +- src/overlay017/ov17_0224A0FC.c | 6 +- src/overlay017/ov17_02250744.c | 2 +- src/overlay019/ov19_021D8B54.c | 2 +- src/overlay019/ov19_021DCF88.c | 2 +- src/overlay021/ov21_021D76B0.c | 4 +- src/overlay021/ov21_021E4CA4.c | 4 +- src/overlay033/ov33_02256474.c | 2 +- src/overlay053/ov53_02256420.c | 2 +- src/overlay058/ov58_021D0D80.c | 2 +- src/overlay059/ov59_021D0D80.c | 2 +- src/overlay062/ov62_022300D8.c | 4 +- src/overlay062/ov62_02234A10.c | 2 +- src/overlay062/ov62_02236CBC.c | 8 +- src/overlay065/ov65_02235060.c | 4 +- src/overlay069/ov69_0225C700.c | 4 +- src/overlay070/ov70_0225C9B4.c | 4 +- src/overlay070/ov70_0226CE54.c | 4 +- src/overlay072/ov72_0223D7A0.c | 2 +- src/overlay077/ov77_021D0D80.c | 2 +- src/overlay079/ov79_021D2268.c | 6 +- src/overlay083/ov83_0223F7F4.c | 4 +- src/overlay084/ov84_0223B5A0.c | 4 +- src/overlay086/ov86_0223B140.c | 4 +- src/overlay088/ov88_0223B140.c | 2 +- src/overlay092/ov92_021D0D80.c | 4 +- src/overlay095/ov95_02248590.c | 4 +- src/overlay095/ov95_02249740.c | 4 +- src/overlay095/ov95_0224A390.c | 4 +- src/overlay097/ov97_0222D30C.c | 36 ++--- src/overlay099/ov99_021D2C08.c | 2 +- src/overlay099/ov99_021D2E28.c | 20 +-- src/overlay099/ov99_021D340C.c | 2 +- src/overlay100/ov100_021D400C.c | 16 +- src/overlay101/ov101_021D59AC.c | 10 +- src/overlay104/ov104_0222FBE4.c | 4 +- src/overlay109/ov109_021D0D80.c | 6 +- src/overlay109/ov109_021D3D50.c | 2 +- src/overlay113/ov113_0225E368.c | 14 +- src/overlay115/ov115_02260CEC.c | 8 +- src/overlay116/ov116_0226432C.c | 52 +++---- src/overlay117/ov117_02263AF0.c | 30 ++-- src/savedata.c | 14 +- src/unk_02017728.c | 4 +- src/unk_0201E190.c | 6 +- src/unk_0205DFC4.c | 4 +- src/unk_0208694C.c | 2 +- src/unk_0208B284.c | 4 +- 60 files changed, 373 insertions(+), 365 deletions(-) diff --git a/include/math.h b/include/math.h index 26e150d5e7..d729093292 100644 --- a/include/math.h +++ b/include/math.h @@ -3,27 +3,39 @@ #include -fx32 sub_0201D15C(u16 param0); -fx32 sub_0201D1D4(u16 param0); -fx32 sub_0201D250(u16 param0); -fx32 sub_0201D264(u16 param0); -u16 sub_0201D278(u16 param0); -u16 sub_0201D2A4(u16 param0); -fx32 sub_0201D2B8(fx32 param0); -fx32 sub_0201D2C4(fx32 param0); +#include "constants/heap.h" + +enum AffineTransformationMatrixMode { + AFFINE_MODE_NORMAL = 0, + AFFINE_MODE_MAX_256, + AFFINE_MODE_MAX_360, +}; + +fx32 CalcSineDegrees(u16 degrees); +fx32 CalcCosineDegrees(u16 degrees); +fx32 CalcSineDegrees_Wraparound(u16 degrees); +fx32 CalcCosineDegrees_Wraparound(u16 degrees); +u16 CalcAngleRotationIdx(u16 degrees); +u16 CalcAngleRotationIdx_Wraparound(u16 degrees); +fx32 CalcSineDegrees_FX32(fx32 degrees); +fx32 CalcCosineDegrees_FX32(fx32 degrees); + u32 LCRNG_GetSeed(void); void LCRNG_SetSeed(u32 seed); u16 LCRNG_Next(void); u32 ARNG_Next(u32 seed); void MTRNG_SetSeed(u32 seed); u32 MTRNG_Next(void); -void sub_0201D470(MtxFx22 *param0, u16 param1, fx32 param2, fx32 param3, u8 param4); -s32 sub_0201D4CC(s32 param0, s32 param1, s32 param2, s32 param3, u32 param4); -s32 sub_0201D580(u16 param0, s32 param1); + +void CreateAffineTransformationMatrix(MtxFx22 *matrix, u16 degrees, fx32 xScale, fx32 yScale, u8 mode); + +s32 CalcDotProduct2D(s32 x0, s32 y0, s32 x1, s32 y1, u32 unused); +s32 CalcRadialAngle(u16 radius, s32 distance); + u32 SumBytes(const void *data, u32 size); void EncodeData(void *data, u32 size, u32 seed); void DecodeData(void *data, u32 size, u32 seed); -u16 sub_0201D628(const void *param0, u32 param1); -void sub_0201D640(int param0); +u16 CalcCRC16Checksum(const void *data, u32 dataLen); +void InitCRC16Table(enum HeapId heapID); #endif // POKEPLATINUM_MATH_H diff --git a/src/battle/healthbar.c b/src/battle/healthbar.c index 500accc3e7..8bb73ba828 100644 --- a/src/battle/healthbar.c +++ b/src/battle/healthbar.c @@ -1855,6 +1855,6 @@ static void ov16_022684BC(SysTask *param0, void *param1) v0->unk_54 -= 360; } - v1 = FX_Mul(sub_0201D15C(v0->unk_54), 0x1800) / FX32_ONE; + v1 = FX_Mul(CalcSineDegrees(v0->unk_54), 0x1800) / FX32_ONE; Healthbar_OffsetPositionXY(v0, 0, v1); } diff --git a/src/battle/ov16_02264798.c b/src/battle/ov16_02264798.c index 93508bd654..c230a1ea6e 100644 --- a/src/battle/ov16_02264798.c +++ b/src/battle/ov16_02264798.c @@ -55,6 +55,6 @@ static void ov16_02264800(SysTask *param0, void *param1) v0->unk_198 -= 360; } - v1 = FX_Mul(sub_0201D15C(v0->unk_198), 0x1800) / FX32_ONE; + v1 = FX_Mul(CalcSineDegrees(v0->unk_198), 0x1800) / FX32_ONE; sub_02007DEC(v0->unk_20, 4, v1); } diff --git a/src/battle/ov16_0226DE44.c b/src/battle/ov16_0226DE44.c index 2c083d131d..00927ca27f 100644 --- a/src/battle/ov16_0226DE44.c +++ b/src/battle/ov16_0226DE44.c @@ -173,7 +173,7 @@ static void ov16_0226DFD8(SysTask *param0, void *param1) } if (v0->unk_1C == 0) { - v1 = FX_Mul(sub_0201D15C(v0->unk_10 / 100), 14 << FX32_SHIFT) / FX32_ONE; + v1 = FX_Mul(CalcSineDegrees(v0->unk_10 / 100), 14 << FX32_SHIFT) / FX32_ONE; sub_0200D500(v0->unk_00, v0->unk_08, v0->unk_0C - v1, v0->unk_14); } } diff --git a/src/bg_window.c b/src/bg_window.c index 6c538ea57a..f4cf031608 100644 --- a/src/bg_window.c +++ b/src/bg_window.c @@ -747,7 +747,7 @@ void Bg_SetAffineParams(BgConfig *bgConfig, u8 bgLayer, const MtxFx22 *mtx, int static void ResetBgAffineTransforms(BgConfig *bgConfig, u8 bgLayer) { MtxFx22 mtx; - sub_0201D470(&mtx, 0, FX32_ONE, FX32_ONE, 0); + CreateAffineTransformationMatrix(&mtx, 0, FX32_ONE, FX32_ONE, AFFINE_MODE_NORMAL); Bg_SetAffineParams(bgConfig, bgLayer, &mtx, 0, 0); } @@ -2460,7 +2460,7 @@ static void RunScheduledScrolls(BgConfig *bgConfig) G2_SetBG2Offset(bgConfig->bgs[BG_LAYER_MAIN_2].xOffset, bgConfig->bgs[BG_LAYER_MAIN_2].yOffset); } else { MtxFx22 mtx; - sub_0201D470(&mtx, bgConfig->bgs[BG_LAYER_MAIN_2].rotation, bgConfig->bgs[BG_LAYER_MAIN_2].xScale, bgConfig->bgs[BG_LAYER_MAIN_2].yScale, 2); + CreateAffineTransformationMatrix(&mtx, bgConfig->bgs[BG_LAYER_MAIN_2].rotation, bgConfig->bgs[BG_LAYER_MAIN_2].xScale, bgConfig->bgs[BG_LAYER_MAIN_2].yScale, AFFINE_MODE_MAX_360); G2_SetBG2Affine(&mtx, bgConfig->bgs[BG_LAYER_MAIN_2].xCenter, bgConfig->bgs[BG_LAYER_MAIN_2].yCenter, bgConfig->bgs[BG_LAYER_MAIN_2].xOffset, bgConfig->bgs[BG_LAYER_MAIN_2].yOffset); } } @@ -2470,7 +2470,7 @@ static void RunScheduledScrolls(BgConfig *bgConfig) G2_SetBG3Offset(bgConfig->bgs[BG_LAYER_MAIN_3].xOffset, bgConfig->bgs[BG_LAYER_MAIN_3].yOffset); } else { MtxFx22 mtx; - sub_0201D470(&mtx, bgConfig->bgs[BG_LAYER_MAIN_3].rotation, bgConfig->bgs[BG_LAYER_MAIN_3].xScale, bgConfig->bgs[BG_LAYER_MAIN_3].yScale, 2); + CreateAffineTransformationMatrix(&mtx, bgConfig->bgs[BG_LAYER_MAIN_3].rotation, bgConfig->bgs[BG_LAYER_MAIN_3].xScale, bgConfig->bgs[BG_LAYER_MAIN_3].yScale, AFFINE_MODE_MAX_360); G2_SetBG3Affine(&mtx, bgConfig->bgs[BG_LAYER_MAIN_3].xCenter, bgConfig->bgs[BG_LAYER_MAIN_3].yCenter, bgConfig->bgs[BG_LAYER_MAIN_3].xOffset, bgConfig->bgs[BG_LAYER_MAIN_3].yOffset); } } @@ -2488,7 +2488,7 @@ static void RunScheduledScrolls(BgConfig *bgConfig) G2S_SetBG2Offset(bgConfig->bgs[BG_LAYER_SUB_2].xOffset, bgConfig->bgs[BG_LAYER_SUB_2].yOffset); } else { MtxFx22 mtx; - sub_0201D470(&mtx, bgConfig->bgs[BG_LAYER_SUB_2].rotation, bgConfig->bgs[BG_LAYER_SUB_2].xScale, bgConfig->bgs[BG_LAYER_SUB_2].yScale, 2); + CreateAffineTransformationMatrix(&mtx, bgConfig->bgs[BG_LAYER_SUB_2].rotation, bgConfig->bgs[BG_LAYER_SUB_2].xScale, bgConfig->bgs[BG_LAYER_SUB_2].yScale, AFFINE_MODE_MAX_360); G2S_SetBG2Affine(&mtx, bgConfig->bgs[BG_LAYER_SUB_2].xCenter, bgConfig->bgs[BG_LAYER_SUB_2].yCenter, bgConfig->bgs[BG_LAYER_SUB_2].xOffset, bgConfig->bgs[BG_LAYER_SUB_2].yOffset); } } @@ -2498,7 +2498,7 @@ static void RunScheduledScrolls(BgConfig *bgConfig) G2S_SetBG3Offset(bgConfig->bgs[BG_LAYER_SUB_3].xOffset, bgConfig->bgs[BG_LAYER_SUB_3].yOffset); } else { MtxFx22 mtx; - sub_0201D470(&mtx, bgConfig->bgs[BG_LAYER_SUB_3].rotation, bgConfig->bgs[BG_LAYER_SUB_3].xScale, bgConfig->bgs[BG_LAYER_SUB_3].yScale, 2); + CreateAffineTransformationMatrix(&mtx, bgConfig->bgs[BG_LAYER_SUB_3].rotation, bgConfig->bgs[BG_LAYER_SUB_3].xScale, bgConfig->bgs[BG_LAYER_SUB_3].yScale, AFFINE_MODE_MAX_360); G2S_SetBG3Affine(&mtx, bgConfig->bgs[BG_LAYER_SUB_3].xCenter, bgConfig->bgs[BG_LAYER_SUB_3].yCenter, bgConfig->bgs[BG_LAYER_SUB_3].xOffset, bgConfig->bgs[BG_LAYER_SUB_3].yOffset); } } diff --git a/src/math.c b/src/math.c index c61eea0d35..a09644fb96 100644 --- a/src/math.c +++ b/src/math.c @@ -1,215 +1,210 @@ #include "math.h" -#include "heap.h" +#include -typedef struct { - MATHCRC16Table unk_00; -} UnkStruct_021BFB10; +#include "heap.h" static u16 LCRNG_NextFrom(u32 *seed); -fx32 sub_0201D15C(u16 param0) +fx32 CalcSineDegrees(u16 degrees) { - if (param0 >= 360) { + if (degrees >= 360) { return 0; } - { - fx16 v0; - fx32 v1; - - v0 = FX_SinIdx(sub_0201D278(param0)); - v1 = FX32_CONST(FX_FX16_TO_F32(v0)); - - return v1; - } + fx16 sin = FX_SinIdx(CalcAngleRotationIdx(degrees)); + return FX32_CONST(FX_FX16_TO_F32(sin)); } -fx32 sub_0201D1D4(u16 param0) +fx32 CalcCosineDegrees(u16 degrees) { - if (param0 >= 360) { + if (degrees >= 360) { return 0; } - { - fx16 v0; - fx32 v1; - - v0 = FX_CosIdx(sub_0201D278(param0)); - v1 = FX32_CONST(FX_FX16_TO_F32(v0)); - - return v1; - } + fx16 cos = FX_CosIdx(CalcAngleRotationIdx(degrees)); + return FX32_CONST(FX_FX16_TO_F32(cos)); } -fx32 sub_0201D250(u16 param0) +fx32 CalcSineDegrees_Wraparound(u16 degrees) { - param0 %= 360; - return sub_0201D15C(param0); + degrees %= 360; + return CalcSineDegrees(degrees); } -fx32 sub_0201D264(u16 param0) +fx32 CalcCosineDegrees_Wraparound(u16 degrees) { - param0 %= 360; - return sub_0201D1D4(param0); + degrees %= 360; + return CalcCosineDegrees(degrees); } -u16 sub_0201D278(u16 param0) +u16 CalcAngleRotationIdx(u16 degrees) { - if (param0 >= 360) { + if (degrees >= 360) { return 0; } - return FX_DEG_TO_IDX(param0 * FX32_ONE); + return FX_DEG_TO_IDX(degrees * FX32_ONE); } -u16 sub_0201D2A4(u16 param0) +u16 CalcAngleRotationIdx_Wraparound(u16 degrees) { - param0 %= 360; - return sub_0201D278(param0); + degrees %= 360; + return CalcAngleRotationIdx(degrees); } -fx32 sub_0201D2B8(fx32 param0) +fx32 CalcSineDegrees_FX32(fx32 degrees) { - u16 v0 = param0 >> FX32_SHIFT; - return sub_0201D250(v0); + u16 degreesUnshifted = degrees >> FX32_SHIFT; + return CalcSineDegrees_Wraparound(degreesUnshifted); } -fx32 sub_0201D2C4(fx32 param0) +fx32 CalcCosineDegrees_FX32(fx32 degrees) { - u16 v0 = param0 >> FX32_SHIFT; - return sub_0201D264(v0); + u16 degreesUnshifted = degrees >> FX32_SHIFT; + return CalcCosineDegrees_Wraparound(degreesUnshifted); } -u32 gLCRNG_State; +#define LCRNG_MULTIPLIER 1103515245L +#define LCRNG_INCREMENT 24691 + +static u32 sLCRNGState; -u32 LCRNG_GetSeed(void) +u32 LCRNG_GetSeed() { - return gLCRNG_State; + return sLCRNGState; } void LCRNG_SetSeed(u32 seed) { - gLCRNG_State = seed; + sLCRNGState = seed; } -u16 LCRNG_Next(void) +u16 LCRNG_Next() { - gLCRNG_State = gLCRNG_State * 1103515245L + 24691; - return (u16)(gLCRNG_State / 65536L); + sLCRNGState = sLCRNGState * LCRNG_MULTIPLIER + LCRNG_INCREMENT; + return sLCRNGState >> 16; } +// Matsumoto, M. & Nishimura, T. 1998. "Mersenne Twister: A 623-Dimensionally Equidistributed Uniform Pseudo-Random Number Generator." +#define MT19937_N 624 // degree of recurrence (number of total words) +#define MT19937_M 397 // middle word offset +#define MT19937_W 32 // word size (number of bits) +#define MT19937_R 31 // separation point of a single word; number of bits of the lower bitmask +#define MT19937_F 1812433253 // additional initialization constant +#define MT19937_A 0x9908B0DF // coefficient of the rational normal form twist matrix +#define MT19937_B 0x9D2C5680 // tempering bitmask +#define MT19937_C 0xEFC60000 // tempering bitmask +#define MT19937_S 7 // tempering bitshift (masked against B) +#define MT19937_T 15 // tempering bitshift (masked against C) +#define MT19937_U 11 // tempering bitshift (not masked) +#define MT19937_L 18 // tempering bitshift (not masked) + +#define MT19937_UMASK (0xFFFFFFFF << MT19937_R) +#define MT19937_LMASK (0xFFFFFFFF >> (MT19937_W - MT19937_R)) +#define MT19937_DEFAULT_SEED 5489 + u32 ARNG_Next(u32 seed) { - return seed * 1812433253L + 1; + return seed * MT19937_F + 1; } -static u32 sMTRNG_State[624]; -static int sMTRNG_Size = 624 + 1; -static u32 sMTRNG_Xor[2] = { 0x0UL, 0x9908b0dfUL }; +static u32 sMTRNGState[MT19937_N]; +static int sMTRNGIndex = MT19937_N + 1; +static u32 sMTRNGXor[2] = { 0, MT19937_A }; void MTRNG_SetSeed(u32 seed) { - sMTRNG_State[0] = seed & 0xffffffff; - - for (sMTRNG_Size = 1; sMTRNG_Size < 624; sMTRNG_Size++) { - sMTRNG_State[sMTRNG_Size] = (1812433253UL * (sMTRNG_State[sMTRNG_Size - 1] ^ (sMTRNG_State[sMTRNG_Size - 1] >> 30)) + sMTRNG_Size); - sMTRNG_State[sMTRNG_Size] &= 0xffffffff; + sMTRNGState[0] = seed; + for (sMTRNGIndex = 1; sMTRNGIndex < MT19937_N; sMTRNGIndex++) { + sMTRNGState[sMTRNGIndex] = MT19937_F * (sMTRNGState[sMTRNGIndex - 1] ^ (sMTRNGState[sMTRNGIndex - 1] >> (MT19937_W - 2))) + sMTRNGIndex; } } -u32 MTRNG_Next(void) +u32 MTRNG_Next() { u32 result; - - if (sMTRNG_Size >= 624) { - int i; - - if (sMTRNG_Size == 624 + 1) { - MTRNG_SetSeed(5489UL); + if (sMTRNGIndex >= MT19937_N) { + if (sMTRNGIndex == MT19937_N + 1) { + MTRNG_SetSeed(MT19937_DEFAULT_SEED); } - for (i = 0; i < 624 - 397; i++) { - result = (sMTRNG_State[i] & 0x80000000UL) | (sMTRNG_State[i + 1] & 0x7fffffffUL); - sMTRNG_State[i] = sMTRNG_State[i + 397] ^ (result >> 1) ^ sMTRNG_Xor[result & 0x1UL]; + int i; + for (i = 0; i < MT19937_N - MT19937_M; i++) { + result = (sMTRNGState[i] & MT19937_UMASK) | (sMTRNGState[i + 1] & MT19937_LMASK); + sMTRNGState[i] = sMTRNGState[i + MT19937_M] ^ (result >> 1) ^ sMTRNGXor[result & 1]; } - - for (; i < 624 - 1; i++) { - result = (sMTRNG_State[i] & 0x80000000UL) | (sMTRNG_State[i + 1] & 0x7fffffffUL); - sMTRNG_State[i] = sMTRNG_State[i + (397 - 624)] ^ (result >> 1) ^ sMTRNG_Xor[result & 0x1UL]; + for (; i < MT19937_N - 1; i++) { + result = (sMTRNGState[i] & MT19937_UMASK) | (sMTRNGState[i + 1] & MT19937_LMASK); + sMTRNGState[i] = sMTRNGState[i + (MT19937_M - MT19937_N)] ^ (result >> 1) ^ sMTRNGXor[result & 1]; } - result = (sMTRNG_State[624 - 1] & 0x80000000UL) | (sMTRNG_State[0] & 0x7fffffffUL); - - sMTRNG_State[624 - 1] = sMTRNG_State[397 - 1] ^ (result >> 1) ^ sMTRNG_Xor[result & 0x1UL]; - sMTRNG_Size = 0; + result = (sMTRNGState[MT19937_N - 1] & MT19937_UMASK) | (sMTRNGState[0] & MT19937_LMASK); + sMTRNGState[MT19937_N - 1] = sMTRNGState[MT19937_M - 1] ^ (result >> 1) ^ sMTRNGXor[result & 1]; + sMTRNGIndex = 0; } - result = sMTRNG_State[sMTRNG_Size++]; - - result ^= (result >> 11); - result ^= (result << 7) & 0x9d2c5680UL; - result ^= (result << 15) & 0xefc60000UL; - result ^= (result >> 18); + result = sMTRNGState[sMTRNGIndex++]; + result ^= (result >> MT19937_U); + result ^= (result << MT19937_S) & MT19937_B; + result ^= (result << MT19937_T) & MT19937_C; + result ^= (result >> MT19937_L); return result; } -void sub_0201D470(MtxFx22 *param0, u16 param1, fx32 param2, fx32 param3, u8 param4) +void CreateAffineTransformationMatrix(MtxFx22 *matrix, u16 degrees, fx32 xScale, fx32 yScale, u8 mode) { - if (param4 == 1) { - param1 = (u16)((u32)(0xffff * param1) >> 8); - } else if (param4 == 2) { - param1 = (u16)((u32)(0xffff * param1) / 360); + if (mode == AFFINE_MODE_MAX_256) { + degrees = (u32)(0xFFFF * degrees) >> 8; + } else if (mode == AFFINE_MODE_MAX_360) { + degrees = (u32)(0xFFFF * degrees) / 360; } - MTX_Rot22(param0, FX_SinIdx(param1), FX_CosIdx(param1)); - MTX_ScaleApply22(param0, param0, param2, param3); + MTX_Rot22(matrix, FX_SinIdx(degrees), FX_CosIdx(degrees)); + MTX_ScaleApply22(matrix, matrix, xScale, yScale); } -static inline void inline_0201D4CC(const VecFx32 *param0, const VecFx32 *param1, VecFx32 *param2) +static inline void CalcCrossProduct(const VecFx32 *a, const VecFx32 *b, VecFx32 *outResult) { - param2->x = 0; - param2->y = 0; - param2->z = FX_Mul(param0->x, param1->y) - FX_Mul(param1->x, param0->y); + outResult->x = 0; + outResult->y = 0; + outResult->z = FX_Mul(a->x, b->y) - FX_Mul(b->x, a->y); } -s32 sub_0201D4CC(s32 param0, s32 param1, s32 param2, s32 param3, u32 param4) +s32 CalcDotProduct2D(s32 x0, s32 y0, s32 x1, s32 y1, u32 unused) { - VecFx32 v0, v1, v2, v3; - fx32 v4; - fx32 v5; - s32 v6; - - VEC_Set(&v0, param0 << FX32_SHIFT, param1 << FX32_SHIFT, 0); - VEC_Set(&v1, param2 << FX32_SHIFT, param3 << FX32_SHIFT, 0); - inline_0201D4CC(&v0, &v1, &v3); + VecFx32 vec0, vec1, vecResult, cross; + fx32 crossMagnitude; + fx32 dotProduct; + s32 result; - v4 = v3.x + v3.y + v3.z; + VEC_Set(&vec0, x0 << FX32_SHIFT, y0 << FX32_SHIFT, 0); + VEC_Set(&vec1, x1 << FX32_SHIFT, y1 << FX32_SHIFT, 0); + CalcCrossProduct(&vec0, &vec1, &cross); + crossMagnitude = cross.x + cross.y + cross.z; - VEC_Set(&v0, param1 << FX32_SHIFT, param0 << FX32_SHIFT, 0); - VEC_Normalize(&v0, &v2); - VEC_Set(&v0, param0 << FX32_SHIFT, param1 << FX32_SHIFT, 0); - VEC_Set(&v1, param2 << FX32_SHIFT, param3 << FX32_SHIFT, 0); - VEC_Subtract(&v1, &v0, &v3); + VEC_Set(&vec0, y0 << FX32_SHIFT, x0 << FX32_SHIFT, 0); + VEC_Normalize(&vec0, &vecResult); + VEC_Set(&vec0, x0 << FX32_SHIFT, y0 << FX32_SHIFT, 0); + VEC_Set(&vec1, x1 << FX32_SHIFT, y1 << FX32_SHIFT, 0); + VEC_Subtract(&vec1, &vec0, &cross); - v5 = VEC_DotProduct(&v2, &v3); - v6 = v5 >> FX32_SHIFT; - v6 = MATH_IAbs(v6); + dotProduct = VEC_DotProduct(&vecResult, &cross); + result = dotProduct >> FX32_SHIFT; + result = MATH_IAbs(result); - if (v4 <= 0) { - v6 *= -1; + if (crossMagnitude <= 0) { + result *= -1; } - return v6; + return result; } -s32 sub_0201D580(u16 param0, s32 param1) +s32 CalcRadialAngle(u16 radius, s32 distance) { - s32 v0; - - v0 = FX_Mul((2 * param0) << FX32_SHIFT, FX32_CONST(3.140f)) >> FX32_SHIFT; - return (s32)((param1 * 0xffff) / v0); + s32 circumference = FX_Mul((2 * radius) << FX32_SHIFT, FX32_CONST(3.140f)) >> FX32_SHIFT; + return (distance * 0xFFFF) / circumference; } u32 SumBytes(const void *data, u32 size) @@ -237,21 +232,20 @@ void DecodeData(void *data, u32 size, u32 seed) static u16 LCRNG_NextFrom(u32 *seed) { - seed[0] = seed[0] * 1103515245L + 24691; - return (u16)(seed[0] / 65536L); + *seed = *seed * LCRNG_MULTIPLIER + LCRNG_INCREMENT; + return *seed >> 16; } -static UnkStruct_021BFB10 *Unk_021BFB10 = NULL; +static MATHCRC16Table *sCRC16Table = NULL; -u16 sub_0201D628(const void *param0, u32 param1) +u16 CalcCRC16Checksum(const void *data, u32 dataLen) { - return MATH_CalcCRC16CCITT(&Unk_021BFB10->unk_00, param0, param1); + return MATH_CalcCRC16CCITT(sCRC16Table, data, dataLen); } -void sub_0201D640(int param0) +void InitCRC16Table(enum HeapId heapID) { - GF_ASSERT(Unk_021BFB10 == NULL); - - Unk_021BFB10 = Heap_AllocFromHeap(param0, sizeof(UnkStruct_021BFB10)); - MATH_CRC16CCITTInitTable(&Unk_021BFB10->unk_00); + GF_ASSERT(sCRC16Table == NULL); + sCRC16Table = Heap_AllocFromHeap(heapID, sizeof(MATHCRC16Table)); + MATH_CRC16CCITTInitTable(sCRC16Table); } diff --git a/src/overlay005/ov5_021F8560.c b/src/overlay005/ov5_021F8560.c index 33c951b2f4..83e97f58f8 100644 --- a/src/overlay005/ov5_021F8560.c +++ b/src/overlay005/ov5_021F8560.c @@ -220,8 +220,8 @@ static void ov5_021F86E4(UnkStruct_ov101_021D5D90 *param0, void *param1) v4 = &v0->unk_20; } - v3.x += ((FX32_ONE * 0) + v4->x) + sub_0201D1D4(v0->unk_08) * v0->unk_0A; - v3.y += ((FX32_ONE * (+8)) + v4->y) + sub_0201D15C(v0->unk_08) * v0->unk_0A; + v3.x += ((FX32_ONE * 0) + v4->x) + CalcCosineDegrees(v0->unk_08) * v0->unk_0A; + v3.y += ((FX32_ONE * (+8)) + v4->y) + CalcSineDegrees(v0->unk_08) * v0->unk_0A; v3.z += ((FX32_ONE * 0) + v4->z); } diff --git a/src/overlay006/ov6_0223E140.c b/src/overlay006/ov6_0223E140.c index 590aac9006..7fd55c26fb 100644 --- a/src/overlay006/ov6_0223E140.c +++ b/src/overlay006/ov6_0223E140.c @@ -1138,7 +1138,7 @@ static BOOL ov6_0223EBDC(UnkStruct_ov6_0223EA98 *param0) case 3: Easy3DObject_GetPosition(¶m0->unk_24, &v1, &v2, &v3); v0[0] = ov6_0223FD18(¶m0->unk_E4, param0->unk_D0); - param0->unk_D8 += (sub_0201D264(param0->unk_D0 * (180 / 20)) * 3); + param0->unk_D8 += (CalcCosineDegrees_Wraparound(param0->unk_D0 * (180 / 20)) * 3); param0->unk_D0++; Easy3DObject_SetPosition(¶m0->unk_24, param0->unk_E4.unk_00, v2, param0->unk_D8); @@ -1157,7 +1157,7 @@ static BOOL ov6_0223EBDC(UnkStruct_ov6_0223EA98 *param0) case 5: Easy3DObject_GetPosition(¶m0->unk_24, &v1, &v2, &v3); v0[0] = ov6_0223FD18(¶m0->unk_E4, param0->unk_D0); - param0->unk_D8 -= (sub_0201D264(param0->unk_D0 * (90 / 20)) * 3); + param0->unk_D8 -= (CalcCosineDegrees_Wraparound(param0->unk_D0 * (90 / 20)) * 3); param0->unk_D0++; Easy3DObject_SetPosition(¶m0->unk_24, param0->unk_E4.unk_00, v2, param0->unk_D8); @@ -1214,7 +1214,7 @@ static BOOL ov6_0223EE5C(UnkStruct_ov6_0223EA98 *param0) case 3: Easy3DObject_GetPosition(¶m0->unk_24, &v1, &v2, &v3); v0[0] = ov6_0223FD18(¶m0->unk_E4, param0->unk_D0); - param0->unk_D8 += (sub_0201D264(param0->unk_D0 * (180 / 32)) * 3); + param0->unk_D8 += (CalcCosineDegrees_Wraparound(param0->unk_D0 * (180 / 32)) * 3); param0->unk_D0++; Easy3DObject_SetPosition(¶m0->unk_24, param0->unk_E4.unk_00, v2, param0->unk_D8); @@ -1228,7 +1228,7 @@ static BOOL ov6_0223EE5C(UnkStruct_ov6_0223EA98 *param0) param0->unk_18++; case 5: Easy3DObject_GetPosition(¶m0->unk_24, &v1, &v2, &v3); - param0->unk_D8 -= (sub_0201D264(param0->unk_D0 * (360 / 32)) * 2); + param0->unk_D8 -= (CalcCosineDegrees_Wraparound(param0->unk_D0 * (360 / 32)) * 2); param0->unk_D0++; Easy3DObject_SetPosition(¶m0->unk_24, v1, v2, param0->unk_D8); @@ -1252,7 +1252,7 @@ static BOOL ov6_0223EE5C(UnkStruct_ov6_0223EA98 *param0) v0[0] = ov6_0223FD18(¶m0->unk_E4, param0->unk_D0); v0[1] = ov6_0223FD18(¶m0->unk_F4, param0->unk_D0); param0->unk_D0++; - param0->unk_DC -= (sub_0201D264((param0->unk_D0 + 1) * (180 / 32)) * 4); + param0->unk_DC -= (CalcCosineDegrees_Wraparound((param0->unk_D0 + 1) * (180 / 32)) * 4); Easy3DObject_SetPosition(¶m0->unk_24, param0->unk_E4.unk_00 + param0->unk_DC, v2, param0->unk_F4.unk_00); if (v0[0] && v0[1]) { @@ -1267,7 +1267,7 @@ static BOOL ov6_0223EE5C(UnkStruct_ov6_0223EA98 *param0) param0->unk_18++; case 9: Easy3DObject_GetPosition(¶m0->unk_24, &v1, &v2, &v3); - param0->unk_D8 += (sub_0201D264(param0->unk_D0 * (360 / 32)) * 1); + param0->unk_D8 += (CalcCosineDegrees_Wraparound(param0->unk_D0 * (360 / 32)) * 1); param0->unk_D0++; Easy3DObject_SetPosition(¶m0->unk_24, v1, v2, param0->unk_D8); @@ -1291,7 +1291,7 @@ static BOOL ov6_0223EE5C(UnkStruct_ov6_0223EA98 *param0) Easy3DObject_GetPosition(¶m0->unk_24, &v1, &v2, &v3); v0[0] = ov6_0223FD18(¶m0->unk_E4, param0->unk_D0); v0[1] = ov6_0223FD18(¶m0->unk_F4, param0->unk_D0); - param0->unk_E0 += (sub_0201D264(param0->unk_D0 * (180 / 32)) * 2); + param0->unk_E0 += (CalcCosineDegrees_Wraparound(param0->unk_D0 * (180 / 32)) * 2); param0->unk_D0++; Easy3DObject_SetPosition(¶m0->unk_24, param0->unk_E4.unk_00, v2, param0->unk_F4.unk_00 + param0->unk_E0); @@ -1389,7 +1389,7 @@ static BOOL ov6_0223EE5C(UnkStruct_ov6_0223EA98 *param0) GX_SetMasterBrightness(param0->unk_0C); } - param0->unk_DC += (sub_0201D264((param0->unk_D0 + 1) * (180 / 32)) * 8); + param0->unk_DC += (CalcCosineDegrees_Wraparound((param0->unk_D0 + 1) * (180 / 32)) * 8); Easy3DObject_SetPosition(¶m0->unk_24, param0->unk_D4 + param0->unk_DC, v2, param0->unk_F4.unk_00); if (v0[0]) { diff --git a/src/overlay006/ov6_02243258.c b/src/overlay006/ov6_02243258.c index 733d5f4686..44a7057746 100644 --- a/src/overlay006/ov6_02243258.c +++ b/src/overlay006/ov6_02243258.c @@ -573,7 +573,7 @@ static CellActor *ov6_022437DC(UnkStruct_ov6_02243258 *param0) CellActor_SetAffineOverwriteMode(v0, 2); CellActor_SetAffineTranslation(v0, &v2); CellActor_SetAffineScale(v0, &v3); - CellActor_SetAffineZRotation(v0, sub_0201D2A4(0)); + CellActor_SetAffineZRotation(v0, CalcAngleRotationIdx_Wraparound(0)); return v0; } @@ -704,15 +704,15 @@ static void ov6_02243950(UnkStruct_ov101_021D5D90 *param0) v2->unk_40 = (FX32_ONE * 45); v2->unk_48 = (FX32_ONE * (128 + 64)); v2->unk_4C = (FX32_ONE * 32); - v2->unk_14.x = sub_0201D264(45) * ((v2->unk_48) / FX32_ONE); - v2->unk_14.y = sub_0201D250((v2->unk_40) / FX32_ONE) * ((v2->unk_48) / FX32_ONE); + v2->unk_14.x = CalcCosineDegrees_Wraparound(45) * ((v2->unk_48) / FX32_ONE); + v2->unk_14.y = CalcSineDegrees_Wraparound((v2->unk_40) / FX32_ONE) * ((v2->unk_48) / FX32_ONE); v0.x = v2->unk_08.x + v2->unk_14.x; v0.y = v2->unk_08.y + v2->unk_14.y; CellActor_SetPosition(v2->unk_68, &v0); CellActor_SetAffineScale(v2->unk_68, &v1); - CellActor_SetAffineZRotation(v2->unk_68, sub_0201D2A4((v2->unk_38) / FX32_ONE)); + CellActor_SetAffineZRotation(v2->unk_68, CalcAngleRotationIdx_Wraparound((v2->unk_38) / FX32_ONE)); CellActor_SetPriority(v2->unk_68, 132); CellActor_SetDrawFlag(v2->unk_68, 1); @@ -731,7 +731,7 @@ static void ov6_02243950(UnkStruct_ov101_021D5D90 *param0) CellActor_SetAffineOverwriteMode(v3, 2); CellActor_SetAffineTranslation(v3, &v4); CellActor_SetAffineScale(v3, &v5); - CellActor_SetAffineZRotation(v3, sub_0201D2A4(0)); + CellActor_SetAffineZRotation(v3, CalcAngleRotationIdx_Wraparound(0)); CellActor_SetAnim(v3, 2); } @@ -758,8 +758,8 @@ static int ov6_02243AB8(UnkStruct_ov6_02249110 *param0) param0->unk_4C = 0x1000; } - param0->unk_14.x = sub_0201D264(45) * ((param0->unk_48) / FX32_ONE); - param0->unk_14.y = sub_0201D250((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.x = CalcCosineDegrees_Wraparound(45) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.y = CalcSineDegrees_Wraparound((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); if (((param0->unk_40) / FX32_ONE) < 90) { param0->unk_40 += 0x4000; @@ -823,15 +823,15 @@ static int ov6_02243BEC(UnkStruct_ov6_02249110 *param0) param0->unk_4C = (FX32_ONE * 16); } - param0->unk_14.x = sub_0201D264((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); - param0->unk_14.y = sub_0201D250(128) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.x = CalcCosineDegrees_Wraparound((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.y = CalcSineDegrees_Wraparound(128) * ((param0->unk_48) / FX32_ONE); if (param0->unk_40 < (FX32_ONE * 160)) { param0->unk_40 += 0x1000; } param0->unk_38 += 0x2000; - CellActor_SetAffineZRotation(v1, sub_0201D2A4((param0->unk_38) / FX32_ONE)); + CellActor_SetAffineZRotation(v1, CalcAngleRotationIdx_Wraparound((param0->unk_38) / FX32_ONE)); param0->unk_2C.x += param0->unk_50; if (param0->unk_2C.x > 0x1000) { @@ -895,7 +895,7 @@ static int ov6_02243CFC(UnkStruct_ov6_02249110 *param0) CellActor_SetPosition(param0->unk_68, &v0); CellActor_SetAffineScale(param0->unk_68, &v1); - CellActor_SetAffineZRotation(param0->unk_68, sub_0201D2A4((param0->unk_38) / FX32_ONE)); + CellActor_SetAffineZRotation(param0->unk_68, CalcAngleRotationIdx_Wraparound((param0->unk_38) / FX32_ONE)); CellActor_SetDrawFlag(param0->unk_68, 1); CellActor_SetAnim(param0->unk_58.unk_08, 6); CellActor_SetAnimateFlag(param0->unk_58.unk_08, 1); @@ -920,8 +920,8 @@ static int ov6_02243DC0(UnkStruct_ov6_02249110 *param0) param0->unk_48 = 0; } - param0->unk_14.x = sub_0201D264(315) * ((param0->unk_48) / FX32_ONE); - param0->unk_14.y = sub_0201D250((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.x = CalcCosineDegrees_Wraparound(315) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.y = CalcSineDegrees_Wraparound((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); if (((param0->unk_40) / FX32_ONE) < 180) { param0->unk_40 -= 0x4000; @@ -946,7 +946,7 @@ static int ov6_02243DC0(UnkStruct_ov6_02249110 *param0) param0->unk_38 = (FX32_ONE * 60); } - CellActor_SetAffineZRotation(v1, sub_0201D2A4((param0->unk_38) / FX32_ONE)); + CellActor_SetAffineZRotation(v1, CalcAngleRotationIdx_Wraparound((param0->unk_38) / FX32_ONE)); v0.x = param0->unk_08.x + param0->unk_14.x; v0.y = param0->unk_08.y + param0->unk_14.y; @@ -1906,7 +1906,7 @@ static CellActor *ov6_02244D4C(UnkStruct_ov6_02243FFC *param0, const VecFx32 *pa CellActor_SetAffineOverwriteMode(v0, 2); CellActor_SetAffineTranslation(v0, &v1); CellActor_SetAffineScale(v0, &v2); - CellActor_SetAffineZRotation(v0, sub_0201D2A4(0)); + CellActor_SetAffineZRotation(v0, CalcAngleRotationIdx_Wraparound(0)); return v0; } @@ -2411,7 +2411,7 @@ static void ov6_0224551C(UnkStruct_ov6_02243FFC *param0) CellActor_SetPosition(v2->unk_58, &v0); CellActor_SetAffineScale(v2->unk_58, &v1); - CellActor_SetAffineZRotation(v2->unk_58, sub_0201D2A4((v2->unk_38) / FX32_ONE)); + CellActor_SetAffineZRotation(v2->unk_58, CalcAngleRotationIdx_Wraparound((v2->unk_38) / FX32_ONE)); CellActor_SetDrawFlag(v2->unk_58, 1); } @@ -2426,8 +2426,8 @@ static int ov6_022455C4(UnkStruct_ov6_02249198 *param0) param0->unk_4C += 0x4000; } - param0->unk_14.x = sub_0201D264(315) * ((param0->unk_48) / FX32_ONE); - param0->unk_14.y = sub_0201D250((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.x = CalcCosineDegrees_Wraparound(315) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.y = CalcSineDegrees_Wraparound((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); if (((param0->unk_40) / FX32_ONE) < 270) { param0->unk_40 += 0x4000; @@ -2452,7 +2452,7 @@ static int ov6_022455C4(UnkStruct_ov6_02249198 *param0) param0->unk_38 = 0; } - CellActor_SetAffineZRotation(v1, sub_0201D2A4((param0->unk_38) / FX32_ONE)); + CellActor_SetAffineZRotation(v1, CalcAngleRotationIdx_Wraparound((param0->unk_38) / FX32_ONE)); v0.x = param0->unk_08.x + param0->unk_14.x; v0.y = param0->unk_08.y + param0->unk_14.y; @@ -2498,15 +2498,15 @@ static void ov6_022456D4(UnkStruct_ov6_02243FFC *param0) v2->unk_40 = (FX32_ONE * 225); v2->unk_48 = (FX32_ONE * (128 + 64)); v2->unk_4C = (FX32_ONE * 32); - v2->unk_14.x = sub_0201D264(315) * ((v2->unk_48) / FX32_ONE); - v2->unk_14.y = sub_0201D250((v2->unk_40) / FX32_ONE) * ((v2->unk_48) / FX32_ONE); + v2->unk_14.x = CalcCosineDegrees_Wraparound(315) * ((v2->unk_48) / FX32_ONE); + v2->unk_14.y = CalcSineDegrees_Wraparound((v2->unk_40) / FX32_ONE) * ((v2->unk_48) / FX32_ONE); v0.x = v2->unk_08.x + v2->unk_14.x; v0.y = v2->unk_08.y + v2->unk_14.y; CellActor_SetPosition(v2->unk_58, &v0); CellActor_SetAffineScale(v2->unk_58, &v1); - CellActor_SetAffineZRotation(v2->unk_58, sub_0201D2A4((v2->unk_38) / FX32_ONE)); + CellActor_SetAffineZRotation(v2->unk_58, CalcAngleRotationIdx_Wraparound((v2->unk_38) / FX32_ONE)); CellActor_SetDrawFlag(v2->unk_58, 1); v2->unk_60 = ov6_02245B4C(param0->unk_244, param0->unk_248); @@ -2525,7 +2525,7 @@ static void ov6_022456D4(UnkStruct_ov6_02243FFC *param0) CellActor_SetAffineOverwriteMode(v3, 2); CellActor_SetAffineTranslation(v3, &v4); CellActor_SetAffineScale(v3, &v5); - CellActor_SetAffineZRotation(v3, sub_0201D2A4(0)); + CellActor_SetAffineZRotation(v3, CalcAngleRotationIdx_Wraparound(0)); } } @@ -2548,8 +2548,8 @@ static int ov6_02245840(UnkStruct_ov6_02249198 *param0) param0->unk_4C = 0x1000; } - param0->unk_14.x = sub_0201D264(315) * ((param0->unk_48) / FX32_ONE); - param0->unk_14.y = sub_0201D250((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.x = CalcCosineDegrees_Wraparound(315) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.y = CalcSineDegrees_Wraparound((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); if (((param0->unk_40) / FX32_ONE) < 270) { param0->unk_40 += 0x4000; @@ -2574,7 +2574,7 @@ static int ov6_02245840(UnkStruct_ov6_02249198 *param0) param0->unk_38 = (FX32_ONE * 360); } - CellActor_SetAffineZRotation(v1, sub_0201D2A4((param0->unk_38) / FX32_ONE)); + CellActor_SetAffineZRotation(v1, CalcAngleRotationIdx_Wraparound((param0->unk_38) / FX32_ONE)); v0.x = param0->unk_08.x + param0->unk_14.x; v0.y = param0->unk_08.y + param0->unk_14.y; @@ -2657,8 +2657,8 @@ static int ov6_02245A0C(UnkStruct_ov6_02249198 *param0) param0->unk_4C = (FX32_ONE * 16); } - param0->unk_14.x = sub_0201D264((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); - param0->unk_14.y = sub_0201D250(128) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.x = CalcCosineDegrees_Wraparound((param0->unk_40) / FX32_ONE) * ((param0->unk_48) / FX32_ONE); + param0->unk_14.y = CalcSineDegrees_Wraparound(128) * ((param0->unk_48) / FX32_ONE); if (param0->unk_40 < (FX32_ONE * 135)) { param0->unk_40 += 0x1000; diff --git a/src/overlay009/ov9_02249960.c b/src/overlay009/ov9_02249960.c index cb79397c89..0d27e45f3b 100644 --- a/src/overlay009/ov9_02249960.c +++ b/src/overlay009/ov9_02249960.c @@ -2844,12 +2844,12 @@ static void ov9_0224B2CC(UnkStruct_ov101_021D5D90 *param0, void *param1) v3 = v4->unk_08.unk_04.unk_18; - v3.x += (FX32_ONE * 0) + (sub_0201D1D4((v4->unk_00) / FX32_ONE) * v4->unk_08.unk_04.unk_10); - v3.y += (FX32_ONE * -512) + (sub_0201D15C((v4->unk_00) / FX32_ONE) * v4->unk_08.unk_04.unk_10); + v3.x += (FX32_ONE * 0) + (CalcCosineDegrees((v4->unk_00) / FX32_ONE) * v4->unk_08.unk_04.unk_10); + v3.y += (FX32_ONE * -512) + (CalcSineDegrees((v4->unk_00) / FX32_ONE) * v4->unk_08.unk_04.unk_10); sub_020715D4(param0, &v3); CellActor_SetPosition(v4->unk_40, &v3); - CellActor_SetAffineZRotation(v4->unk_40, sub_0201D2A4((v0) / FX32_ONE)); + CellActor_SetAffineZRotation(v4->unk_40, CalcAngleRotationIdx_Wraparound((v0) / FX32_ONE)); } static void ov9_0224B3A4(UnkStruct_ov101_021D5D90 *param0, void *param1) diff --git a/src/overlay012/ov12_02226B84.c b/src/overlay012/ov12_02226B84.c index 5ed3bb3f2e..a6b1ab1a15 100644 --- a/src/overlay012/ov12_02226B84.c +++ b/src/overlay012/ov12_02226B84.c @@ -2912,7 +2912,7 @@ static void ov12_02229A6C(SysTask *param0, void *param1) if (v0->unk_30) { v0->unk_2C += (360 / (v0->unk_06)); - SPLEmitter_SetPosY(v0->unk_38, (v0->unk_A8[0].unk_02 * 172) + sub_0201D250(v0->unk_2C)); + SPLEmitter_SetPosY(v0->unk_38, (v0->unk_A8[0].unk_02 * 172) + CalcSineDegrees_Wraparound(v0->unk_2C)); } } } diff --git a/src/overlay017/ov17_022413D8.c b/src/overlay017/ov17_022413D8.c index 9177083832..32c46103c7 100644 --- a/src/overlay017/ov17_022413D8.c +++ b/src/overlay017/ov17_022413D8.c @@ -1913,8 +1913,8 @@ static void ov17_022434E0(SysTask *param0, void *param1) } v3 = v0->unk_10 / 0x100; - v1 = FX_Mul(sub_0201D1D4(v0->unk_1E / 100), v3 << FX32_SHIFT) / FX32_ONE; - v2 = FX_Mul(sub_0201D15C(v0->unk_1E / 100), v3 << FX32_SHIFT) / FX32_ONE; + v1 = FX_Mul(CalcCosineDegrees(v0->unk_1E / 100), v3 << FX32_SHIFT) / FX32_ONE; + v2 = FX_Mul(CalcSineDegrees(v0->unk_1E / 100), v3 << FX32_SHIFT) / FX32_ONE; SpriteActor_SetSpritePositionXY(v0->unk_08, v0->unk_21 + v1, v0->unk_22 + v2); break; default: @@ -2023,8 +2023,8 @@ static void ov17_02243750(SysTask *param0, void *param1) v0->unk_0C -= 360 * 100; } - v3 = FX_Mul(sub_0201D15C(v0->unk_0C / 100), (12 << FX32_SHIFT)) / FX32_ONE; - v4 = FX_Mul(sub_0201D1D4(v0->unk_0C / 100), (6 << FX32_SHIFT)) / FX32_ONE; + v3 = FX_Mul(CalcSineDegrees(v0->unk_0C / 100), (12 << FX32_SHIFT)) / FX32_ONE; + v4 = FX_Mul(CalcCosineDegrees(v0->unk_0C / 100), (6 << FX32_SHIFT)) / FX32_ONE; v0->unk_20 += 0x80; SpriteActor_SetSpritePositionXY(v0->unk_04, (v0->unk_1C >> 8) + v3, (v0->unk_20 >> 8) + v4); diff --git a/src/overlay017/ov17_022476F8.c b/src/overlay017/ov17_022476F8.c index 390843fbcd..115b8eb792 100644 --- a/src/overlay017/ov17_022476F8.c +++ b/src/overlay017/ov17_022476F8.c @@ -143,7 +143,7 @@ static void ov17_02247840(SysTask *param0, void *param1) switch (v0->unk_14) { case 0: - v1 = sub_0201D2B8(v0->unk_10) * 8 / FX32_ONE; + v1 = CalcSineDegrees_FX32(v0->unk_10) * 8 / FX32_ONE; v0->unk_10 += (6 << FX32_SHIFT); v0->unk_0C -= 0x100; diff --git a/src/overlay017/ov17_0224A0FC.c b/src/overlay017/ov17_0224A0FC.c index 2f5253b887..f045a99689 100644 --- a/src/overlay017/ov17_0224A0FC.c +++ b/src/overlay017/ov17_0224A0FC.c @@ -1878,7 +1878,7 @@ static void ov17_0224BF58(UnkStruct_ov17_0224BE50 *param0) } v2 = (param0->unk_19 == 0) ? 3 : 3; - v1 = sub_0201D1D4(param0->unk_14 >> 8) * v2 / FX32_ONE; + v1 = CalcCosineDegrees(param0->unk_14 >> 8) * v2 / FX32_ONE; param0->unk_0C->unk_04 = v1 + Unk_ov17_022546F4[param0->unk_19][0] - v2; ov22_0225B100(param0->unk_0C->unk_00, param0->unk_0C->unk_04, param0->unk_0C->unk_08); @@ -2063,7 +2063,7 @@ void ov17_0224C49C(UnkStruct_ov17_0224C384 *param0, u32 param1, u32 param2, int v7 = (256 - v6) / 2; v3 = v0 + v7; v4 = (0x12 * 8); - v4 -= sub_0201D15C(v5) * 10 / FX32_ONE; + v4 -= CalcSineDegrees(v5) * 10 / FX32_ONE; sub_0200D500(param0->unk_04, v3, v4, (256 * FX32_ONE)); SpriteActor_EnableObject(param0->unk_04, 1); @@ -2217,7 +2217,7 @@ static void ov17_0224C7B8(SysTask *param0, void *param1) v0->unk_24 = v0->unk_28; v0->unk_10++; case 1: - v1 = sub_0201D2B8(v0->unk_20) * 4 / FX32_ONE; + v1 = CalcSineDegrees_FX32(v0->unk_20) * 4 / FX32_ONE; v2 = v0->unk_20; v0->unk_20 += (50 << FX32_SHIFT); diff --git a/src/overlay017/ov17_02250744.c b/src/overlay017/ov17_02250744.c index 2d10c8a31f..05b0eba615 100644 --- a/src/overlay017/ov17_02250744.c +++ b/src/overlay017/ov17_02250744.c @@ -562,7 +562,7 @@ static void ov17_02251140(SysTask *param0, void *param1) v0->unk_1C -= 360 << 8; } - v0->unk_10 = FX_Mul(sub_0201D15C(v0->unk_1C / 0x100), v0->unk_12 << FX32_SHIFT) / FX32_ONE; + v0->unk_10 = FX_Mul(CalcSineDegrees(v0->unk_1C / 0x100), v0->unk_12 << FX32_SHIFT) / FX32_ONE; v0->unk_08 -= v0->unk_14; v0->unk_0C += 0x280; diff --git a/src/overlay019/ov19_021D8B54.c b/src/overlay019/ov19_021D8B54.c index 63c16dea41..212325bdbf 100644 --- a/src/overlay019/ov19_021D8B54.c +++ b/src/overlay019/ov19_021D8B54.c @@ -592,7 +592,7 @@ static void ov19_021D9600(SysTask *param0, void *param1) v0->unk_0C += v0->unk_1C; v1.y = v0->unk_0C; v0->unk_18 += v0->unk_20; - v2 = v0->unk_24 * sub_0201D15C(v0->unk_18 >> FX32_SHIFT); + v2 = v0->unk_24 * CalcSineDegrees(v0->unk_18 >> FX32_SHIFT); v1.x = v0->unk_14 + v2; CellActor_SetPosition(v0->unk_00, &v1); diff --git a/src/overlay019/ov19_021DCF88.c b/src/overlay019/ov19_021DCF88.c index d9c856ef09..526bda6832 100644 --- a/src/overlay019/ov19_021DCF88.c +++ b/src/overlay019/ov19_021DCF88.c @@ -356,7 +356,7 @@ static void ov19_021DD024(UnkStruct_ov19_021DCF88 *param0) for (v3 = 1; v3 < (16 - 1); v3++) { v0 += v2; - param0->unk_D4[v3] = (sub_0201D15C(v0 >> FX32_SHIFT) * 16) >> FX32_SHIFT; + param0->unk_D4[v3] = (CalcSineDegrees(v0 >> FX32_SHIFT) * 16) >> FX32_SHIFT; param0->unk_E4[v3] = 16 - param0->unk_D4[v3]; } diff --git a/src/overlay021/ov21_021D76B0.c b/src/overlay021/ov21_021D76B0.c index 37c9841fca..8afcf7bd07 100644 --- a/src/overlay021/ov21_021D76B0.c +++ b/src/overlay021/ov21_021D76B0.c @@ -337,7 +337,7 @@ static int ov21_021D7950(void *param0, UnkStruct_ov21_021E6B20 *param1, const vo ov21_021D84A8(v3->unk_00[2], v3->unk_0C[2], -14, 2, 5); if (v0->unk_1C->unk_20 == 0) { - ov21_021D8354(v3, v2, sub_0201D580(524, v1->unk_0C), v1->unk_1C); + ov21_021D8354(v3, v2, CalcRadialAngle(524, v1->unk_0C), v1->unk_1C); } else if (v0->unk_1C->unk_20 == 1) { ov21_021D83C0(v3, v2, v0); } else { @@ -831,7 +831,7 @@ static void ov21_021D8324(UnkStruct_ov21_021D7A64 *param0) v3 = gCoreSys.touchX - (128 + 120); v2 = gCoreSys.touchY - (104 + -0); - param0->unk_0C = sub_0201D4CC(v1, v0, v3, v2, 524); + param0->unk_0C = CalcDotProduct2D(v1, v0, v3, v2, 524); param0->unk_0C *= 10; } diff --git a/src/overlay021/ov21_021E4CA4.c b/src/overlay021/ov21_021E4CA4.c index 5979fa7819..840c7ac0d6 100644 --- a/src/overlay021/ov21_021E4CA4.c +++ b/src/overlay021/ov21_021E4CA4.c @@ -1017,7 +1017,7 @@ static void ov21_021E5A44(UnkStruct_ov21_021E51DC *param0) v0 = param0->unk_58 - 157; v3 = gCoreSys.touchX - 51; v2 = gCoreSys.touchY - 157; - v4 = sub_0201D4CC(v1, v0, v3, v2, 0); + v4 = CalcDotProduct2D(v1, v0, v3, v2, 0); if (MATH_IAbs(v4) < 1) { return; @@ -1101,7 +1101,7 @@ static void ov21_021E5AD8(UnkStruct_ov21_021E51DC *param0) static void ov21_021E5B50(UnkStruct_ov21_021E5004 *param0, const UnkStruct_ov21_021E51DC *param1) { - CellActor_SetAffineZRotation(param0->unk_00, sub_0201D580(14, param1->unk_5C)); + CellActor_SetAffineZRotation(param0->unk_00, CalcRadialAngle(14, param1->unk_5C)); } static void ov21_021E5B6C(UnkStruct_ov21_021E5004 *param0, UnkStruct_ov21_021E4DA4 *param1, const UnkStruct_ov21_021E51DC *param2) diff --git a/src/overlay033/ov33_02256474.c b/src/overlay033/ov33_02256474.c index 2d7b2e068e..78da74687a 100644 --- a/src/overlay033/ov33_02256474.c +++ b/src/overlay033/ov33_02256474.c @@ -789,7 +789,7 @@ static void ov33_0225718C(UnkStruct_ov33_02256474 *param0, const UnkStruct_ov33_ v0->unk_34_val3[2] = 2; } - VEC_Set(&v0->unk_20, 0, -20 * sub_0201D15C(v0->unk_34_val3[1]), 0); + VEC_Set(&v0->unk_20, 0, -20 * CalcSineDegrees(v0->unk_34_val3[1]), 0); VEC_Add(&v0->unk_14, &v0->unk_20, ¶m0->unk_A4); ov25_02255900(v0->unk_00, param0->unk_A4.x, param0->unk_A4.y); diff --git a/src/overlay053/ov53_02256420.c b/src/overlay053/ov53_02256420.c index 95c52cb317..9b5cca2e6a 100644 --- a/src/overlay053/ov53_02256420.c +++ b/src/overlay053/ov53_02256420.c @@ -195,7 +195,7 @@ static void ov53_022565E0(SysTask *param0, void *param1) fx32 v4; v3 = ((((180 << FX32_SHIFT) / 16) * v2) + FX32_HALF) >> FX32_SHIFT; - v4 = sub_0201D15C(v3) * 24; + v4 = CalcSineDegrees(v3) * 24; ov25_02255900(v0->unk_9C, v0->unk_A4, v0->unk_A0 - v4); } ov25_0225524C(param1); diff --git a/src/overlay058/ov58_021D0D80.c b/src/overlay058/ov58_021D0D80.c index d813000a4d..de3378397a 100644 --- a/src/overlay058/ov58_021D0D80.c +++ b/src/overlay058/ov58_021D0D80.c @@ -1596,7 +1596,7 @@ static void ov58_021D2888(u16 *param0) *param0 = 0; } - v0 = sub_0201D250(*param0); + v0 = CalcSineDegrees_Wraparound(*param0); v3 = 15 + (v0 * 10) / FX32_ONE; v1 = GX_RGB(29, v3, 0); diff --git a/src/overlay059/ov59_021D0D80.c b/src/overlay059/ov59_021D0D80.c index f65a5db4fd..c71e4f76c4 100644 --- a/src/overlay059/ov59_021D0D80.c +++ b/src/overlay059/ov59_021D0D80.c @@ -1434,7 +1434,7 @@ static void ov59_021D23B0(u16 *param0) *param0 = 0; } - v0 = sub_0201D250(*param0); + v0 = CalcSineDegrees_Wraparound(*param0); v3 = 15 + (v0 * 10) / FX32_ONE; v1 = GX_RGB(29, v3, 0); diff --git a/src/overlay062/ov62_022300D8.c b/src/overlay062/ov62_022300D8.c index 3035bf8f20..4ff6a4bcf8 100644 --- a/src/overlay062/ov62_022300D8.c +++ b/src/overlay062/ov62_022300D8.c @@ -551,7 +551,7 @@ void ov62_02230C28(SysTask *param0, void *param1) sub_0200D638(v0->unk_00[0], &v1, &v2); sub_0200D638(v0->unk_00[1], &v3, &v4); - v1 = v1 + ((sub_0201D250((v0->unk_20 * 0xffff) / 360) * 1) * (v0->unk_18 * -1)); + v1 = v1 + ((CalcSineDegrees_Wraparound((v0->unk_20 * 0xffff) / 360) * 1) * (v0->unk_18 * -1)); v3 = v1; v0->unk_20 += 32; @@ -607,7 +607,7 @@ void ov62_02230C28(SysTask *param0, void *param1) sub_0200D638(v0->unk_00[0], &v9, &v10); sub_0200D638(v0->unk_00[1], &v11, &v12); - v9 = v0->unk_0C + ((sub_0201D250((v0->unk_20 * 0xffff) / 360) * 3) * (v0->unk_18 * -1)); + v9 = v0->unk_0C + ((CalcSineDegrees_Wraparound((v0->unk_20 * 0xffff) / 360) * 3) * (v0->unk_18 * -1)); v11 = v9; if (v0->unk_19 % 2) { diff --git a/src/overlay062/ov62_02234A10.c b/src/overlay062/ov62_02234A10.c index 07ea3ad32e..3ba5aa6684 100644 --- a/src/overlay062/ov62_02234A10.c +++ b/src/overlay062/ov62_02234A10.c @@ -336,7 +336,7 @@ BOOL ov62_02235008(UnkStruct_0208C06C *param0) } v8 = v6 * FX32_ONE; - v7 = v0->unk_00[v3].unk_0C + (sub_0201D250((v0->unk_00[v3].unk_04 * 0xffff) / 360) * 16); + v7 = v0->unk_00[v3].unk_0C + (CalcSineDegrees_Wraparound((v0->unk_00[v3].unk_04 * 0xffff) / 360) * 16); v0->unk_00[v3].unk_04 += (-4 * 1); sub_0200D614(param0->unk_534.unk_C8[v3].unk_00, v7, v8); diff --git a/src/overlay062/ov62_02236CBC.c b/src/overlay062/ov62_02236CBC.c index 9db513c8ed..42edeaa755 100644 --- a/src/overlay062/ov62_02236CBC.c +++ b/src/overlay062/ov62_02236CBC.c @@ -473,8 +473,8 @@ static BOOL ov62_022375A4(UnkStruct_0208C06C *param0) v0->unk_04[v1] = 1.0f; } - v4 = (128 << FX32_SHIFT) + sub_0201D250(v0->unk_2C[v1]) * v0->unk_18[v1]; - v5 = (106 << FX32_SHIFT) - sub_0201D264(v0->unk_2C[v1]) * v0->unk_18[v1]; + v4 = (128 << FX32_SHIFT) + CalcSineDegrees_Wraparound(v0->unk_2C[v1]) * v0->unk_18[v1]; + v5 = (106 << FX32_SHIFT) - CalcCosineDegrees_Wraparound(v0->unk_2C[v1]) * v0->unk_18[v1]; sub_0200D614(v0->unk_68[v1], v4, v5); SpriteActor_GetSpritePositionXY(v0->unk_68[v1], &v2, &v3); @@ -523,8 +523,8 @@ static BOOL ov62_022376C4(UnkStruct_0208C06C *param0) SpriteActor_EnableObject(v0->unk_54[v1], 0); } - v4 = (128 << FX32_SHIFT) - sub_0201D250(v0->unk_2C[v1]) * v0->unk_18[v1]; - v5 = (106 << FX32_SHIFT) - sub_0201D264(v0->unk_2C[v1]) * v0->unk_18[v1]; + v4 = (128 << FX32_SHIFT) - CalcSineDegrees_Wraparound(v0->unk_2C[v1]) * v0->unk_18[v1]; + v5 = (106 << FX32_SHIFT) - CalcCosineDegrees_Wraparound(v0->unk_2C[v1]) * v0->unk_18[v1]; sub_0200D614(v0->unk_68[v1], v4, v5); SpriteActor_GetSpritePositionXY(v0->unk_68[v1], &v2, &v3); diff --git a/src/overlay065/ov65_02235060.c b/src/overlay065/ov65_02235060.c index 072a9c83d5..e8ad24de66 100644 --- a/src/overlay065/ov65_02235060.c +++ b/src/overlay065/ov65_02235060.c @@ -939,7 +939,7 @@ static void ov65_02235EF8(UnkStruct_ov65_02235130 *param0, UnkStruct_ov65_022354 v0.unk_02 = ov63_0222BF90(param1->unk_00, 1); v1 = v0; - v0.unk_02 += FX_Mul(sub_0201D15C(param1->unk_08), -192 * FX32_ONE) >> FX32_SHIFT; + v0.unk_02 += FX_Mul(CalcSineDegrees(param1->unk_08), -192 * FX32_ONE) >> FX32_SHIFT; ov63_0222CFE0(param1->unk_04, v0); ov63_0222D060(param1->unk_04, v1); @@ -960,7 +960,7 @@ static void ov65_02235F94(UnkStruct_ov65_02235130 *param0, UnkStruct_ov65_022354 if (v3 > 0) { v3 = v3 % 6; v0 = (180 * v3) / 6; - v1.unk_02 -= FX_Mul(sub_0201D15C(v0), 4 * FX32_ONE) >> FX32_SHIFT; + v1.unk_02 -= FX_Mul(CalcSineDegrees(v0), 4 * FX32_ONE) >> FX32_SHIFT; } ov63_0222CFE0(param1->unk_04, v1); diff --git a/src/overlay069/ov69_0225C700.c b/src/overlay069/ov69_0225C700.c index 894396a327..8ea6f4c458 100644 --- a/src/overlay069/ov69_0225C700.c +++ b/src/overlay069/ov69_0225C700.c @@ -1283,11 +1283,11 @@ static u32 ov69_0225D194(const VecFx32 *param0, const VecFx32 *param1) v0 = MATH_ABS(param0->x - param1->x); v1 = MATH_ABS(param0->y - param1->y); - if (v0 > sub_0201D278(180)) { + if (v0 > CalcAngleRotationIdx(180)) { v0 = 0xffff - v0; } - if (v1 > sub_0201D278(180)) { + if (v1 > CalcAngleRotationIdx(180)) { v1 = 0xffff - v1; } diff --git a/src/overlay070/ov70_0225C9B4.c b/src/overlay070/ov70_0225C9B4.c index 909b596b7f..ccb5c509cd 100644 --- a/src/overlay070/ov70_0225C9B4.c +++ b/src/overlay070/ov70_0225C9B4.c @@ -1133,8 +1133,8 @@ static void ov70_0225D81C(UnkStruct_ov70_0225CC54 *param0, UnkStruct_ov70_0225CA v2 = v2 % 6; v0 = (180 * v2) / 6; - v1.z += FX_Mul(sub_0201D15C(v0), -2 * FX32_ONE); - v1.y += FX_Mul(sub_0201D15C(v0), 10 * FX32_ONE); + v1.z += FX_Mul(CalcSineDegrees(v0), -2 * FX32_ONE); + v1.y += FX_Mul(CalcSineDegrees(v0), 10 * FX32_ONE); } ov66_022347F8(param0->unk_04, &v1); diff --git a/src/overlay070/ov70_0226CE54.c b/src/overlay070/ov70_0226CE54.c index 6fba2436e9..db52fec0f5 100644 --- a/src/overlay070/ov70_0226CE54.c +++ b/src/overlay070/ov70_0226CE54.c @@ -346,7 +346,7 @@ static void ov70_0226D31C(UnkStruct_ov70_0226D2A0 *param0, UnkStruct_ov70_02261E { param0->unk_04.val1.unk_00 = 0; param0->unk_04.val1.unk_02 = 8; - param0->unk_04.val1.unk_04 = (sub_0201D2A4(5)); + param0->unk_04.val1.unk_04 = (CalcAngleRotationIdx_Wraparound(5)); param0->unk_04.val1.unk_06 = 2; param0->unk_04.val1.unk_08 = 4; } @@ -355,7 +355,7 @@ static void ov70_0226D33C(UnkStruct_ov70_0226D2A0 *param0, UnkStruct_ov70_02261E { param0->unk_04.val1.unk_00 = 0; param0->unk_04.val1.unk_02 = 16; - param0->unk_04.val1.unk_04 = (sub_0201D2A4(10)); + param0->unk_04.val1.unk_04 = (CalcAngleRotationIdx_Wraparound(10)); param0->unk_04.val1.unk_06 = 4; param0->unk_04.val1.unk_08 = 2; } diff --git a/src/overlay072/ov72_0223D7A0.c b/src/overlay072/ov72_0223D7A0.c index 0fae0a9de6..e27185c3b7 100644 --- a/src/overlay072/ov72_0223D7A0.c +++ b/src/overlay072/ov72_0223D7A0.c @@ -1069,7 +1069,7 @@ static void ov72_0223E8D0(u16 *param0) *param0 = 0; } - v0 = sub_0201D250(*param0); + v0 = CalcSineDegrees_Wraparound(*param0); v3 = 15 + (v0 * 10) / FX32_ONE; v1 = GX_RGB(29, v3, 0); diff --git a/src/overlay077/ov77_021D0D80.c b/src/overlay077/ov77_021D0D80.c index 110298bfeb..2c9e096140 100644 --- a/src/overlay077/ov77_021D0D80.c +++ b/src/overlay077/ov77_021D0D80.c @@ -530,7 +530,7 @@ static void ov77_021D1568(UnkStruct_ov77_021D1568 *param0, UnkStruct_ov77_021D12 param0->unk_2A8 += 2; param0->unk_2A8 %= 360; - v1 = sub_0201D250((param0->unk_2A8 * 0xffff) / 360); + v1 = CalcSineDegrees_Wraparound((param0->unk_2A8 * 0xffff) / 360); v1 *= 0.30; param1->unk_80.y -= v1; diff --git a/src/overlay079/ov79_021D2268.c b/src/overlay079/ov79_021D2268.c index 59c2e8d76f..d20624440f 100644 --- a/src/overlay079/ov79_021D2268.c +++ b/src/overlay079/ov79_021D2268.c @@ -840,7 +840,7 @@ static void ov79_021D2E74(SysTask *param0, void *param1) v3.y = v2->unk_00.y + FX_Mul(v2->unk_18.y, v0->unk_0C); v4 = FX_Mul(v2->unk_48, v0->unk_0C); - v4 = FX_Mul(sub_0201D250(v4 >> 12), FX32_CONST(-64)); + v4 = FX_Mul(CalcSineDegrees_Wraparound(v4 >> 12), FX32_CONST(-64)); v5 = FX32_ONE; v3.y += FX_Mul(v4, v5); @@ -1063,7 +1063,7 @@ static void ov79_021D34A8(SysTask *param0, void *param1) sub_02007DEC(v1->unk_C8, 1, v3.y >> 12); v4 = FX_Mul(v2->unk_48, v0->unk_0C); - v4 = FX_Mul(sub_0201D250(v4 >> 12), FX32_CONST(-6)); + v4 = FX_Mul(CalcSineDegrees_Wraparound(v4 >> 12), FX32_CONST(-6)); sub_02007DEC(v1->unk_C8, 4, v4 >> 12); @@ -1161,7 +1161,7 @@ static void ov79_021D36F0(SysTask *param0, void *param1) VecFx32 v3; fx32 v4, v5; - v4 = sub_0201D250(v2->unk_50); + v4 = CalcSineDegrees_Wraparound(v2->unk_50); v5 = FX_Mul(v4, FX32_CONST(2)); if (v2->unk_50 > 359) { diff --git a/src/overlay083/ov83_0223F7F4.c b/src/overlay083/ov83_0223F7F4.c index e09157d208..650f574f0b 100644 --- a/src/overlay083/ov83_0223F7F4.c +++ b/src/overlay083/ov83_0223F7F4.c @@ -37,7 +37,7 @@ s32 ov83_0223F7F4(int param0, int param1, int param2, int param3, int param4, in param2 -= param4; param3 -= param5; - v3 = sub_0201D4CC(param2, param3, param0, param1, 0); + v3 = CalcDotProduct2D(param2, param3, param0, param1, 0); v3 = ((v3) * 160); return v3; @@ -195,7 +195,7 @@ u16 ov83_0223F900(UnkStruct_ov83_0223F8AC *param0, const UnkStruct_ov83_0223FE50 } v5 = param0->unk_08; - param0->unk_08 += sub_0201D580(68, ((param0->unk_0C) / 160)); + param0->unk_08 += CalcRadialAngle(68, ((param0->unk_0C) / 160)); if (((param3 == 0) && (param0->unk_0C >= 0)) || ((param3 == 1) && (param0->unk_0C < 0))) { if (param3 == 0) { diff --git a/src/overlay084/ov84_0223B5A0.c b/src/overlay084/ov84_0223B5A0.c index b920bb1570..fd608f05e8 100644 --- a/src/overlay084/ov84_0223B5A0.c +++ b/src/overlay084/ov84_0223B5A0.c @@ -2968,8 +2968,8 @@ static BOOL ov84_0223EB84(UnkStruct_ov84_0223B5A0 *param0, u16 param1) if (ov84_0223EB6C() == 1) { s32 v0, v1; - v0 = sub_0201D4CC(128 - param0->unk_49E, 80 - param0->unk_4A0, 128 - gCoreSys.touchX, 80 - gCoreSys.touchY, 80); - v1 = sub_0201D580(80, v0 * 2); + v0 = CalcDotProduct2D(128 - param0->unk_49E, 80 - param0->unk_4A0, 128 - gCoreSys.touchX, 80 - gCoreSys.touchY, 80); + v1 = CalcRadialAngle(80, v0 * 2); v1 = ((v1 << 8) / 182) >> 8; param0->unk_49A += v1; diff --git a/src/overlay086/ov86_0223B140.c b/src/overlay086/ov86_0223B140.c index 5b3fcc2e6e..31de794a13 100644 --- a/src/overlay086/ov86_0223B140.c +++ b/src/overlay086/ov86_0223B140.c @@ -1607,8 +1607,8 @@ static void inline inline_ov86_0223CB74(UnkStruct_ov86_0223CAE4 *param0) int v0 = param0->unk_808 >> FX32_SHIFT; fx32 v1, v2; - v1 = param0->unk_818 + FX_Mul(sub_0201D1D4(v0), 10240); - v2 = FX_Mul(sub_0201D15C(v0), 10240) - FX16_ONE; + v1 = param0->unk_818 + FX_Mul(CalcCosineDegrees(v0), 10240); + v2 = FX_Mul(CalcSineDegrees(v0), 10240) - FX16_ONE; VEC_Fx16Set(&(param0->unk_826), v1 - 576, v2, 0); VEC_Fx16Set(&(param0->unk_82C), v1 + 576, v2, 0); diff --git a/src/overlay088/ov88_0223B140.c b/src/overlay088/ov88_0223B140.c index 38e26ad78e..e41431612d 100644 --- a/src/overlay088/ov88_0223B140.c +++ b/src/overlay088/ov88_0223B140.c @@ -1545,7 +1545,7 @@ static void ov88_0223CEF0(u16 *param0) *param0 = 0; } - v0 = sub_0201D250(*param0); + v0 = CalcSineDegrees_Wraparound(*param0); v3 = 15 + (v0 * 10) / FX32_ONE; v1 = GX_RGB(29, v3, 0); diff --git a/src/overlay092/ov92_021D0D80.c b/src/overlay092/ov92_021D0D80.c index 41afb2a481..eaf1f968c6 100644 --- a/src/overlay092/ov92_021D0D80.c +++ b/src/overlay092/ov92_021D0D80.c @@ -1539,11 +1539,11 @@ static u32 ov92_021D28C0(const UnkStruct_ov92_021D28C0 *param0, const UnkStruct_ v0 = MATH_ABS(param0->unk_00 - param1->unk_00); v1 = MATH_ABS(param0->unk_04 - param1->unk_04); - if (v0 > sub_0201D278(180)) { + if (v0 > CalcAngleRotationIdx(180)) { v0 = 0xffff - v0; } - if (v1 > sub_0201D278(180)) { + if (v1 > CalcAngleRotationIdx(180)) { v1 = 0xffff - v1; } diff --git a/src/overlay095/ov95_02248590.c b/src/overlay095/ov95_02248590.c index cb42c21fd9..d5d1a9740e 100644 --- a/src/overlay095/ov95_02248590.c +++ b/src/overlay095/ov95_02248590.c @@ -923,8 +923,8 @@ static void ov95_022492DC(UnkStruct_ov95_0224922C *param0) } } - param0->unk_14.x = param0->unk_08.x + FX_Mul(sub_0201D1D4(v0), param0->unk_38); - param0->unk_14.z = param0->unk_08.z + FX_Mul(sub_0201D15C(v0), param0->unk_3C); + param0->unk_14.x = param0->unk_08.x + FX_Mul(CalcCosineDegrees(v0), param0->unk_38); + param0->unk_14.z = param0->unk_08.z + FX_Mul(CalcSineDegrees(v0), param0->unk_3C); param0->unk_20.y += param0->unk_56; for (v1 = 0; v1 < 3; v1++) { diff --git a/src/overlay095/ov95_02249740.c b/src/overlay095/ov95_02249740.c index dd4483e8bf..1f4c106e6b 100644 --- a/src/overlay095/ov95_02249740.c +++ b/src/overlay095/ov95_02249740.c @@ -511,8 +511,8 @@ static void ov95_02249D38(UnkStruct_ov95_02249C28 *param0) param0->unk_5C--; } - param0->unk_1C.x = FX_Mul(sub_0201D1D4(v0), param0->unk_44); - param0->unk_1C.y = FX_Mul(sub_0201D15C(v0), param0->unk_48); + param0->unk_1C.x = FX_Mul(CalcCosineDegrees(v0), param0->unk_44); + param0->unk_1C.y = FX_Mul(CalcSineDegrees(v0), param0->unk_48); param0->unk_1C.z = 0; param0->unk_34.x += 0x300; diff --git a/src/overlay095/ov95_0224A390.c b/src/overlay095/ov95_0224A390.c index 75139c5069..e0d9d66b0f 100644 --- a/src/overlay095/ov95_0224A390.c +++ b/src/overlay095/ov95_0224A390.c @@ -507,8 +507,8 @@ static void ov95_0224A978(UnkStruct_ov95_0224A848 *param0) ov95_022479D4(param0->unk_0C, param0->unk_5C); } - param0->unk_1C.x = FX_Mul(sub_0201D1D4(v0), param0->unk_44); - param0->unk_1C.y = FX_Mul(sub_0201D15C(v0), param0->unk_48); + param0->unk_1C.x = FX_Mul(CalcCosineDegrees(v0), param0->unk_44); + param0->unk_1C.y = FX_Mul(CalcSineDegrees(v0), param0->unk_48); param0->unk_1C.z = 0; param0->unk_34.x -= 0x300; diff --git a/src/overlay097/ov97_0222D30C.c b/src/overlay097/ov97_0222D30C.c index 8c15825285..124b4da21e 100644 --- a/src/overlay097/ov97_0222D30C.c +++ b/src/overlay097/ov97_0222D30C.c @@ -1447,8 +1447,8 @@ static void ov97_0222EA68(UnkStruct_ov97_0222E398 *param0) int v2 = LCRNG_Next() % 360; int v3 = 64 + (LCRNG_Next() % 32); - v1.x = param0->unk_88[v0].unk_10.x + (sub_0201D250(v2) * v3); - v1.y = param0->unk_88[v0].unk_10.y + (sub_0201D264(v2) * v3); + v1.x = param0->unk_88[v0].unk_10.x + (CalcSineDegrees_Wraparound(v2) * v3); + v1.y = param0->unk_88[v0].unk_10.y + (CalcCosineDegrees_Wraparound(v2) * v3); CellActor_SetPosition(param0->unk_88[v0].unk_0C, &v1); } @@ -1592,31 +1592,31 @@ static void ov97_0222EEB8(SysTask *param0, void *param1) if (v0->unk_2C == 0) { v0->unk_34 += 8; v0->unk_34 %= 360; - v0->unk_40 = (sub_0201D264(v0->unk_34) * v0->unk_38) >> FX32_SHIFT; + v0->unk_40 = (CalcCosineDegrees_Wraparound(v0->unk_34) * v0->unk_38) >> FX32_SHIFT; - v1.x = v0->unk_10.x + (sub_0201D250(v0->unk_28) * v0->unk_40 * +1); - v1.y = v0->unk_10.y + (sub_0201D264(v0->unk_28) * v0->unk_44 * +1); + v1.x = v0->unk_10.x + (CalcSineDegrees_Wraparound(v0->unk_28) * v0->unk_40 * +1); + v1.y = v0->unk_10.y + (CalcCosineDegrees_Wraparound(v0->unk_28) * v0->unk_44 * +1); } else if (v0->unk_2C == 1) { v0->unk_34 += 8; v0->unk_34 %= 360; - v0->unk_44 = (sub_0201D250(v0->unk_34) * v0->unk_38) >> FX32_SHIFT; + v0->unk_44 = (CalcSineDegrees_Wraparound(v0->unk_34) * v0->unk_38) >> FX32_SHIFT; - v1.x = v0->unk_10.x + (sub_0201D250(v0->unk_28) * v0->unk_40 * +1); - v1.y = v0->unk_10.y + (sub_0201D264(v0->unk_28) * v0->unk_44 * +1); + v1.x = v0->unk_10.x + (CalcSineDegrees_Wraparound(v0->unk_28) * v0->unk_40 * +1); + v1.y = v0->unk_10.y + (CalcCosineDegrees_Wraparound(v0->unk_28) * v0->unk_44 * +1); } else if (v0->unk_2C == 2) { v0->unk_34 += 8; v0->unk_34 %= 360; - v0->unk_44 = (sub_0201D250(v0->unk_34) * v0->unk_38) >> FX32_SHIFT; + v0->unk_44 = (CalcSineDegrees_Wraparound(v0->unk_34) * v0->unk_38) >> FX32_SHIFT; - v1.x = v0->unk_10.x + (sub_0201D250(v0->unk_28) * v0->unk_40 * -1); - v1.y = v0->unk_10.y + (sub_0201D264(v0->unk_28) * v0->unk_44 * -1); + v1.x = v0->unk_10.x + (CalcSineDegrees_Wraparound(v0->unk_28) * v0->unk_40 * -1); + v1.y = v0->unk_10.y + (CalcCosineDegrees_Wraparound(v0->unk_28) * v0->unk_44 * -1); } else if (v0->unk_2C == 3) { v0->unk_34 += 8; v0->unk_34 %= 360; - v0->unk_40 = (sub_0201D264(v0->unk_34) * v0->unk_38) >> FX32_SHIFT; + v0->unk_40 = (CalcCosineDegrees_Wraparound(v0->unk_34) * v0->unk_38) >> FX32_SHIFT; - v1.x = v0->unk_10.x + (sub_0201D250(v0->unk_28) * v0->unk_40 * -1); - v1.y = v0->unk_10.y + (sub_0201D264(v0->unk_28) * v0->unk_44 * -1); + v1.x = v0->unk_10.x + (CalcSineDegrees_Wraparound(v0->unk_28) * v0->unk_40 * -1); + v1.y = v0->unk_10.y + (CalcCosineDegrees_Wraparound(v0->unk_28) * v0->unk_44 * -1); } else if (v0->unk_2C == 4) { if (v0->unk_38 < (64 + 32)) { v0->unk_38 += v0->unk_3C; @@ -1625,8 +1625,8 @@ static void ov97_0222EEB8(SysTask *param0, void *param1) v0->unk_40 = v0->unk_38; v0->unk_44 = v0->unk_38; - v1.x = v0->unk_10.x + (sub_0201D250(v0->unk_28) * v0->unk_40 * +1); - v1.y = v0->unk_10.y + (sub_0201D264(v0->unk_28) * v0->unk_44 * +1); + v1.x = v0->unk_10.x + (CalcSineDegrees_Wraparound(v0->unk_28) * v0->unk_40 * +1); + v1.y = v0->unk_10.y + (CalcCosineDegrees_Wraparound(v0->unk_28) * v0->unk_44 * +1); } else if (v0->unk_2C == 5) { if (v0->unk_38 < (64 + 32)) { v0->unk_38 += v0->unk_3C; @@ -1635,8 +1635,8 @@ static void ov97_0222EEB8(SysTask *param0, void *param1) v0->unk_40 = v0->unk_38; v0->unk_44 = v0->unk_38; - v1.x = v0->unk_10.x + (sub_0201D250(v0->unk_28) * v0->unk_40 * -1); - v1.y = v0->unk_10.y + (sub_0201D264(v0->unk_28) * v0->unk_44 * -1); + v1.x = v0->unk_10.x + (CalcSineDegrees_Wraparound(v0->unk_28) * v0->unk_40 * -1); + v1.y = v0->unk_10.y + (CalcCosineDegrees_Wraparound(v0->unk_28) * v0->unk_44 * -1); } else { v0->unk_04 = 10; v0->unk_1C += FX32_CONST(0.5); diff --git a/src/overlay099/ov99_021D2C08.c b/src/overlay099/ov99_021D2C08.c index d843b0b532..973b08e5d4 100644 --- a/src/overlay099/ov99_021D2C08.c +++ b/src/overlay099/ov99_021D2C08.c @@ -140,7 +140,7 @@ static void ov99_021D2D18(UnkStruct_ov99_021D2CB0 *param0, UnkStruct_ov99_021D2C v0->unk_08 -= 360 << FX32_SHIFT; } - v2 = FX_Mul(sub_0201D2B8(v0->unk_08), v1->unk_18); + v2 = FX_Mul(CalcSineDegrees_FX32(v0->unk_08), v1->unk_18); v0->unk_00 += v1->unk_0C; v0->unk_04 += v1->unk_10; diff --git a/src/overlay099/ov99_021D2E28.c b/src/overlay099/ov99_021D2E28.c index cd02bb3c9b..daa609c67c 100644 --- a/src/overlay099/ov99_021D2E28.c +++ b/src/overlay099/ov99_021D2E28.c @@ -140,8 +140,8 @@ static void ov99_021D2ED8(UnkStruct_ov99_021D2CB0 *param0, UnkStruct_ov99_021D2E param1->unk_94[v1].unk_04 = Unk_ov99_021D4BDC[v1].unk_44; param1->unk_94[v1].unk_10 = Unk_ov99_021D4BDC[v1].unk_10; param1->unk_94[v1].unk_1C = Unk_ov99_021D4BDC[v1].unk_0C; - param1->unk_94[v1].unk_28 = FX_Mul(sub_0201D2B8(Unk_ov99_021D4BDC[v1].unk_10), Unk_ov99_021D4BDC[v1].unk_04); - param1->unk_94[v1].unk_2C = FX_Mul(sub_0201D2C4(Unk_ov99_021D4BDC[v1].unk_10), Unk_ov99_021D4BDC[v1].unk_08); + param1->unk_94[v1].unk_28 = FX_Mul(CalcSineDegrees_FX32(Unk_ov99_021D4BDC[v1].unk_10), Unk_ov99_021D4BDC[v1].unk_04); + param1->unk_94[v1].unk_2C = FX_Mul(CalcCosineDegrees_FX32(Unk_ov99_021D4BDC[v1].unk_10), Unk_ov99_021D4BDC[v1].unk_08); param1->unk_94[v1].unk_34 = Unk_ov99_021D4BDC[v1].unk_00; sub_0200D650(param0->unk_10E0[v0], param1->unk_94[v1].unk_00 + param1->unk_94[v1].unk_28, param1->unk_94[v1].unk_04 + param1->unk_94[v1].unk_2C, ((192 + 80) << FX32_SHIFT)); @@ -188,8 +188,8 @@ static void ov99_021D2FD4(UnkStruct_ov99_021D2CB0 *param0, UnkStruct_ov99_021D2E v0->unk_39++; } - v0->unk_28 = FX_Mul(sub_0201D2B8(v0->unk_10), v1->unk_04); - v0->unk_2C = FX_Mul(sub_0201D2C4(v0->unk_10), v1->unk_08); + v0->unk_28 = FX_Mul(CalcSineDegrees_FX32(v0->unk_10), v1->unk_04); + v0->unk_2C = FX_Mul(CalcCosineDegrees_FX32(v0->unk_10), v1->unk_08); break; case 2: v0->unk_00 += v0->unk_28; @@ -211,8 +211,8 @@ static void ov99_021D2FD4(UnkStruct_ov99_021D2CB0 *param0, UnkStruct_ov99_021D2E v0->unk_18 -= 360 << FX32_SHIFT; } - v0->unk_28 = FX_Mul(sub_0201D2B8(v0->unk_14), v1->unk_24); - v0->unk_2C = FX_Mul(sub_0201D2B8(v0->unk_18), v1->unk_28); + v0->unk_28 = FX_Mul(CalcSineDegrees_FX32(v0->unk_14), v1->unk_24); + v0->unk_2C = FX_Mul(CalcSineDegrees_FX32(v0->unk_18), v1->unk_28); if (param0->unk_10FC >= 5970) { v0->unk_20 -= v1->unk_2C / 20; @@ -228,13 +228,13 @@ static void ov99_021D2FD4(UnkStruct_ov99_021D2CB0 *param0, UnkStruct_ov99_021D2E v0->unk_04 = v0->unk_04 + v0->unk_2C; v0->unk_10 = 0; v0->unk_1C = v1->unk_3C; - v0->unk_28 = FX_Mul(sub_0201D2B8(0), v1->unk_34); - v0->unk_2C = FX_Mul(sub_0201D2C4(0), v1->unk_38); + v0->unk_28 = FX_Mul(CalcSineDegrees_FX32(0), v1->unk_34); + v0->unk_2C = FX_Mul(CalcCosineDegrees_FX32(0), v1->unk_38); v0->unk_39++; case 5: v0->unk_10 += v0->unk_1C; - v0->unk_28 = FX_Mul(sub_0201D2C4(v0->unk_10), v1->unk_34); - v0->unk_2C = FX_Mul(sub_0201D2B8(v0->unk_10), v1->unk_38); + v0->unk_28 = FX_Mul(CalcCosineDegrees_FX32(v0->unk_10), v1->unk_34); + v0->unk_2C = FX_Mul(CalcSineDegrees_FX32(v0->unk_10), v1->unk_38); if (v0->unk_10 >= (180 << FX32_SHIFT)) { v0->unk_39++; diff --git a/src/overlay099/ov99_021D340C.c b/src/overlay099/ov99_021D340C.c index 2ed6651bf5..3401242e5d 100644 --- a/src/overlay099/ov99_021D340C.c +++ b/src/overlay099/ov99_021D340C.c @@ -195,7 +195,7 @@ static void ov99_021D35E8(UnkStruct_ov99_021D2CB0 *param0, UnkStruct_ov99_021D34 v0->unk_08 -= 360 << FX32_SHIFT; } - v2 = FX_Mul(sub_0201D2B8(v0->unk_08), v1->unk_10); + v2 = FX_Mul(CalcSineDegrees_FX32(v0->unk_08), v1->unk_10); v0->unk_00 += v1->unk_04; v0->unk_04 += v1->unk_08; diff --git a/src/overlay100/ov100_021D400C.c b/src/overlay100/ov100_021D400C.c index f3c352fdf6..cbe97bb4af 100644 --- a/src/overlay100/ov100_021D400C.c +++ b/src/overlay100/ov100_021D400C.c @@ -89,8 +89,8 @@ static BOOL ov100_021D4104(UnkStruct_ov100_021D4104 *param0, s16 param1, s16 par param0->unk_20 += 8; param0->unk_20 %= 360; - v7 += (sub_0201D250(param0->unk_20) * 1); - v8 += (sub_0201D264(param0->unk_20) * 1); + v7 += (CalcSineDegrees_Wraparound(param0->unk_20) * 1); + v8 += (CalcCosineDegrees_Wraparound(param0->unk_20) * 1); sub_0200D5E8(param0->unk_00, v7, v8); } @@ -110,8 +110,8 @@ static void ov100_021D4214(UnkStruct_ov100_021D4104 *param0) param0->unk_1C += 8; param0->unk_1C %= 360; - v0 = (128 << FX32_SHIFT) + (sub_0201D250(param0->unk_1C) * 64); - v1 = (48 << FX32_SHIFT) + (sub_0201D264(param0->unk_1C) * 24); + v0 = (128 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(param0->unk_1C) * 64); + v1 = (48 << FX32_SHIFT) + (CalcCosineDegrees_Wraparound(param0->unk_1C) * 24); sub_0200D650(param0->unk_00, v0, v1, FX32_CONST(192)); @@ -125,8 +125,8 @@ static void ov100_021D4264(UnkStruct_ov100_021D4104 *param0, int param1, int par param0->unk_1C += 8; param0->unk_1C %= 360; - v0 = (param1 << FX32_SHIFT) + (sub_0201D250(param0->unk_1C) * param3); - v1 = (param2 << FX32_SHIFT) + (sub_0201D264(param0->unk_1C) * param4); + v0 = (param1 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(param0->unk_1C) * param3); + v1 = (param2 << FX32_SHIFT) + (CalcCosineDegrees_Wraparound(param0->unk_1C) * param4); sub_0200D650(param0->unk_00, v0, v1, FX32_CONST(192)); } @@ -179,8 +179,8 @@ static void ov100_021D4318(UnkStruct_ov100_021D4104 *param0) sub_0200D67C(param0->unk_00, &v0, &v1, FX32_CONST(192)); - v0 += (sub_0201D250(param0->unk_20) * (3 * param0->unk_28[0])); - v1 += (sub_0201D264(param0->unk_20) * (3 * param0->unk_28[1])); + v0 += (CalcSineDegrees_Wraparound(param0->unk_20) * (3 * param0->unk_28[0])); + v1 += (CalcCosineDegrees_Wraparound(param0->unk_20) * (3 * param0->unk_28[1])); sub_0200D650(param0->unk_00, v0, v1, FX32_CONST(192)); diff --git a/src/overlay101/ov101_021D59AC.c b/src/overlay101/ov101_021D59AC.c index 87422cbfde..bce60b503e 100644 --- a/src/overlay101/ov101_021D59AC.c +++ b/src/overlay101/ov101_021D59AC.c @@ -845,7 +845,7 @@ static void ov101_021D6410(UnkStruct_ov101_021D13C8 *param0, UnkStruct_ov101_021 CellActor_SetAffineOverwriteMode(param1->unk_04, 2); CellActor_SetAffineTranslation(param1->unk_04, &v0); CellActor_SetAffineScale(param1->unk_04, &v1); - CellActor_SetAffineZRotation(param1->unk_04, sub_0201D2A4(0)); + CellActor_SetAffineZRotation(param1->unk_04, CalcAngleRotationIdx_Wraparound(0)); CellActor_SetAnimateFlag(param1->unk_04, 1); } @@ -1105,7 +1105,7 @@ static int ov101_021D682C(UnkStruct_ov101_021D66D0 *param0) ov101_021D84A4(param0->unk_20->unk_450, ¶m0->unk_24, &v0, (NNS_G2D_VRAM_TYPE_2DSUB), 1, 4, 4, 4, 4, 2, 6); CellActor_SetAffineOverwriteMode(param0->unk_24.unk_04, 2); CellActor_SetAffineTranslation(param0->unk_24.unk_04, &v1); - CellActor_SetAffineZRotation(param0->unk_24.unk_04, sub_0201D2A4(0)); + CellActor_SetAffineZRotation(param0->unk_24.unk_04, CalcAngleRotationIdx_Wraparound(0)); param0->unk_0C = 1; param0->unk_08++; @@ -1749,7 +1749,7 @@ static int ov101_021D7304(UnkStruct_ov101_021D5D90 *param0, void *param1) CellActor_SetAffineOverwriteMode(v3->unk_08.unk_04, 2); CellActor_SetAffineTranslation(v3->unk_08.unk_04, &v1); CellActor_SetAffineScale(v3->unk_08.unk_04, &v2); - CellActor_SetAffineZRotation(v3->unk_08.unk_04, sub_0201D2A4(0)); + CellActor_SetAffineZRotation(v3->unk_08.unk_04, CalcAngleRotationIdx_Wraparound(0)); CellActor_SetAnimateFlag(v3->unk_08.unk_04, 1); return 1; @@ -1862,7 +1862,7 @@ static int ov101_021D74A0(UnkStruct_ov101_021D5D90 *param0, void *param1) CellActor_SetAffineOverwriteMode(v3->unk_08.unk_04, 2); CellActor_SetAffineTranslation(v3->unk_08.unk_04, &v1); CellActor_SetAffineScale(v3->unk_08.unk_04, &v2); - CellActor_SetAffineZRotation(v3->unk_08.unk_04, sub_0201D2A4(0)); + CellActor_SetAffineZRotation(v3->unk_08.unk_04, CalcAngleRotationIdx_Wraparound(0)); CellActor_SetAnimateFlag(v3->unk_08.unk_04, 1); return 1; @@ -2136,7 +2136,7 @@ static int ov101_021D7810(UnkStruct_ov101_021D5D90 *param0, void *param1) CellActor_SetAffineOverwriteMode(v6->unk_18[v0].unk_04, 2); CellActor_SetAffineTranslation(v6->unk_18[v0].unk_04, &v4); CellActor_SetAffineScale(v6->unk_18[v0].unk_04, &v5); - CellActor_SetAffineZRotation(v6->unk_18[v0].unk_04, sub_0201D2A4(0)); + CellActor_SetAffineZRotation(v6->unk_18[v0].unk_04, CalcAngleRotationIdx_Wraparound(0)); v2 = (v6->unk_04 % (v1 * 10)) / v1; diff --git a/src/overlay104/ov104_0222FBE4.c b/src/overlay104/ov104_0222FBE4.c index 083841b66e..3742708977 100644 --- a/src/overlay104/ov104_0222FBE4.c +++ b/src/overlay104/ov104_0222FBE4.c @@ -2252,7 +2252,7 @@ static void ov104_022313FC(SysTask *param0, void *param1) v10 = v4->unk_00[v0].unk_0C & 0xffff; v11 = v4->unk_00[v0].unk_0C >> 16; - sub_0201D470(&v5, 0, FX32_ONE, FX32_ONE, 0); + CreateAffineTransformationMatrix(&v5, 0, FX32_ONE, FX32_ONE, AFFINE_MODE_NORMAL); v12 = v6 + v4->unk_00[v0].unk_08; v13 = v7 + v4->unk_00[v0].unk_0A; @@ -2317,7 +2317,7 @@ static void ov104_022313FC(SysTask *param0, void *param1) v14 = v4->unk_00[v0].unk_0C & 0xffff; v15 = v4->unk_00[v0].unk_0C >> 16; - sub_0201D470(&v5, 0, FX32_ONE, FX32_ONE, 0); + CreateAffineTransformationMatrix(&v5, 0, FX32_ONE, FX32_ONE, AFFINE_MODE_NORMAL); v16 = v6 + v4->unk_00[v0].unk_08; v17 = v7 + v4->unk_00[v0].unk_0A; diff --git a/src/overlay109/ov109_021D0D80.c b/src/overlay109/ov109_021D0D80.c index 1adffe501a..905cd227aa 100644 --- a/src/overlay109/ov109_021D0D80.c +++ b/src/overlay109/ov109_021D0D80.c @@ -2482,9 +2482,9 @@ static void ov109_021D2D78(UnkStruct_ov109_021D2D78 *param0, const VecFx32 *para ov109_021D39D4(&v1, param0->unk_20); v0 = (u16)((v1) / FX32_ONE); - param0->unk_44.x = (FX32_ONE * 0) + param0->unk_50.x + param1->x + (sub_0201D1D4(v0) * 22); + param0->unk_44.x = (FX32_ONE * 0) + param0->unk_50.x + param1->x + (CalcCosineDegrees(v0) * 22); param0->unk_44.y = (FX32_ONE * -6) + param0->unk_50.y + param1->y; - param0->unk_44.z = (FX32_ONE * 0) + param0->unk_50.z + param1->z + (sub_0201D15C(v0) * 22); + param0->unk_44.z = (FX32_ONE * 0) + param0->unk_50.z + param1->z + (CalcSineDegrees(v0) * 22); param0->unk_24.unk_00 = ((param0->unk_2C.x) / FX32_ONE); param0->unk_24.unk_02 = ((param0->unk_2C.y) / FX32_ONE); @@ -2902,7 +2902,7 @@ static void ov109_021D3370(UnkStruct_ov109_021D3370 *param0) param0->unk_0C = (FX32_ONE * 20); param0->unk_04++; case 1: - v0 = sub_0201D15C((param0->unk_10) / FX32_ONE) * ((param0->unk_08) / FX32_ONE); + v0 = CalcSineDegrees((param0->unk_10) / FX32_ONE) * ((param0->unk_08) / FX32_ONE); v1->unk_2C.z = 0; ov109_021D39D4(&v1->unk_2C.z, v0); diff --git a/src/overlay109/ov109_021D3D50.c b/src/overlay109/ov109_021D3D50.c index bf1d01684d..8ee83bebda 100644 --- a/src/overlay109/ov109_021D3D50.c +++ b/src/overlay109/ov109_021D3D50.c @@ -1427,7 +1427,7 @@ static void ov109_021D5314(u16 *param0) *param0 = 0; } - v0 = sub_0201D250(*param0); + v0 = CalcSineDegrees_Wraparound(*param0); v3 = 15 + (v0 * 10) / FX32_ONE; v1 = GX_RGB(29, v3, 0); diff --git a/src/overlay113/ov113_0225E368.c b/src/overlay113/ov113_0225E368.c index 371a122887..0383810ec2 100644 --- a/src/overlay113/ov113_0225E368.c +++ b/src/overlay113/ov113_0225E368.c @@ -1324,7 +1324,7 @@ static int ov113_0225F368(UnkStruct_ov113_0225EB20 *param0, UnkStruct_ov113_0225 v0->unk_04 -= 360 << FX32_SHIFT; } - v5 = FX_Mul(sub_0201D2B8(v0->unk_04), 0x8000); + v5 = FX_Mul(CalcSineDegrees_FX32(v0->unk_04), 0x8000); Easy3DObject_SetPosition(¶m1->unk_1C, v2 - 0x1000, v0->unk_0C + v5, v4); break; } @@ -1463,7 +1463,7 @@ static int ov113_0225F728(UnkStruct_ov113_0225EB20 *param0, UnkStruct_ov113_0225 v0->unk_04 -= 360 << FX32_SHIFT; } - v5 = FX_Mul(sub_0201D2B8(v0->unk_04), 0x8000); + v5 = FX_Mul(CalcSineDegrees_FX32(v0->unk_04), 0x8000); Easy3DObject_SetPosition(¶m1->unk_1C, v0->unk_08 + v5, v3 - 0x1000, v4); break; } @@ -1558,7 +1558,7 @@ static int ov113_0225F890(UnkStruct_ov113_0225EB20 *param0, UnkStruct_ov113_0225 v0->unk_F0 -= 360 << FX32_SHIFT; } - v4 = FX_Mul(sub_0201D2B8(v0->unk_F0), 0x10000); + v4 = FX_Mul(CalcSineDegrees_FX32(v0->unk_F0), 0x10000); Easy3DObject_GetPosition(¶m1->unk_1C, &v1, &v2, &v3); @@ -1656,7 +1656,7 @@ static int ov113_0225FAB0(UnkStruct_ov113_0225EB20 *param0, UnkStruct_ov113_0225 v0->unk_F0 -= 360 << FX32_SHIFT; } - v4 = FX_Mul(sub_0201D2B8(v0->unk_F0), 0x10000); + v4 = FX_Mul(CalcSineDegrees_FX32(v0->unk_F0), 0x10000); Easy3DObject_GetPosition(¶m1->unk_1C, &v1, &v2, &v3); @@ -2055,7 +2055,7 @@ static BOOL ov113_02260218(UnkStruct_ov113_0225EB20 *param0, UnkStruct_ov113_022 } } - v1 = FX_Mul(sub_0201D2B8(v0->unk_08), 0x1000); + v1 = FX_Mul(CalcSineDegrees_FX32(v0->unk_08), 0x1000); v2 = v0->cameraAngle; v2.y = v1; Camera_SetAngleAroundSelf(&v2, camera); @@ -2133,7 +2133,7 @@ static BOOL ov113_02260394(UnkStruct_ov113_0225EB20 *param0, UnkStruct_ov113_022 } } - v2 = FX_Mul(sub_0201D2B8(v0->unk_18), 0x10000); + v2 = FX_Mul(CalcSineDegrees_FX32(v0->unk_18), 0x10000); v1.x = v2; Camera_SetTarget(&v0->unk_00, camera); @@ -2172,7 +2172,7 @@ static BOOL ov113_0226046C(UnkStruct_ov113_0225EB20 *param0, UnkStruct_ov113_022 } } - v2 = FX_Mul(sub_0201D2B8(v0->unk_18), 0x8000); + v2 = FX_Mul(CalcSineDegrees_FX32(v0->unk_18), 0x8000); v1.y = v2; Camera_SetTarget(&v0->unk_00, camera); diff --git a/src/overlay115/ov115_02260CEC.c b/src/overlay115/ov115_02260CEC.c index f5e4bdbdbc..33a453f20b 100644 --- a/src/overlay115/ov115_02260CEC.c +++ b/src/overlay115/ov115_02260CEC.c @@ -3482,7 +3482,7 @@ static void ov115_0226414C(UnkStruct_ov115_02263DF8 *param0, u32 param1) fx32 v0; param1 -= ((20 * 0xffff) / 360); - v0 = (param1 * 90) / sub_0201D2A4(90 - ((20 * 0xffff) / 360)); + v0 = (param1 * 90) / CalcAngleRotationIdx_Wraparound(90 - ((20 * 0xffff) / 360)); v0 = (v0 * (FX32_CONST(180))) / 90; v0 = (FX32_CONST(180)) - v0; @@ -4102,8 +4102,8 @@ static void ov115_02264DD8(int param0, int param1, int param2, int param3, int p v1 = param4 - param3; v0 = param3 + ((param0 * v1) / param1); - *param5 = FX_Mul(sub_0201D1D4(v0), param2 << FX32_SHIFT) >> FX32_SHIFT; - *param6 = FX_Mul(sub_0201D15C(v0), param2 << FX32_SHIFT) >> FX32_SHIFT; + *param5 = FX_Mul(CalcCosineDegrees(v0), param2 << FX32_SHIFT) >> FX32_SHIFT; + *param6 = FX_Mul(CalcSineDegrees(v0), param2 << FX32_SHIFT) >> FX32_SHIFT; } static void ov115_02264E48(UnkStruct_ov115_02264FA0 *param0, UnkStruct_ov115_02261ADC *param1, NARC *param2, int param3, u32 param4, u32 param5, NNSFndAllocator *param6) @@ -4148,7 +4148,7 @@ static void ov115_02264E48(UnkStruct_ov115_02264FA0 *param0, UnkStruct_ov115_022 if ((v4 == 0) || (v4 == 1)) { Easy3DObject_SetRotation(¶m0->unk_00[v4], Unk_ov115_02265C5C[param3 - 1][param4], 1); } else { - Easy3DObject_SetRotation(¶m0->unk_00[v4], (sub_0201D278(180)), 1); + Easy3DObject_SetRotation(¶m0->unk_00[v4], (CalcAngleRotationIdx(180)), 1); } } diff --git a/src/overlay116/ov116_0226432C.c b/src/overlay116/ov116_0226432C.c index ba267523c4..2b3c3aef35 100644 --- a/src/overlay116/ov116_0226432C.c +++ b/src/overlay116/ov116_0226432C.c @@ -407,8 +407,8 @@ void ov116_0226493C(UnkStruct_ov116_02262A8C *param0, s16 param1, s16 param2) static inline void inline_ov116_022649E4(UnkStruct_ov116_02264FEC_sub1 *param0) { - param0->unk_1C = FX_Mul(sub_0201D250(param0->unk_28), FX32_CONST(param0->unk_2E)); - param0->unk_20 = FX_Mul(sub_0201D264(param0->unk_28), FX32_CONST(param0->unk_30)); + param0->unk_1C = FX_Mul(CalcSineDegrees_Wraparound(param0->unk_28), FX32_CONST(param0->unk_2E)); + param0->unk_20 = FX_Mul(CalcCosineDegrees_Wraparound(param0->unk_28), FX32_CONST(param0->unk_30)); } static inline void inline_ov116_022649E4_1(UnkStruct_ov116_02264FEC_sub1 *wk, fx32 x, fx32 y) @@ -1252,16 +1252,16 @@ static void ov116_02265AA4(SysTask *param0, void *param1) { sub_0200D67C(v1->unk_00[0].unk_00, &v5, &v6, ((192 + 64) << FX32_SHIFT)); - v3 = (v1->unk_00[0].unk_14 << FX32_SHIFT) + (sub_0201D250(v1->unk_00[0].unk_08) * v1->unk_00[0].unk_18); - v4 = (v1->unk_00[0].unk_16 << FX32_SHIFT) + (sub_0201D264(v1->unk_00[0].unk_08) * v1->unk_00[0].unk_1C); + v3 = (v1->unk_00[0].unk_14 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(v1->unk_00[0].unk_08) * v1->unk_00[0].unk_18); + v4 = (v1->unk_00[0].unk_16 << FX32_SHIFT) + (CalcCosineDegrees_Wraparound(v1->unk_00[0].unk_08) * v1->unk_00[0].unk_1C); sub_0200D650(v1->unk_00[0].unk_00, v3, v4, ((192 + 64) << FX32_SHIFT)); ov116_02264764(&v1->unk_00[0].unk_20, v3, v3 + FX32_CONST(180), ov116_022658C8(v1->unk_148)); ov116_02264764(&v1->unk_00[0].unk_38, v4, v4 - FX32_CONST(24), ov116_022658C8(v1->unk_148)); sub_0200D67C(v1->unk_A0[0].unk_00, &v5, &v6, ((192 + 64) << FX32_SHIFT)); - v3 = (v1->unk_A0[0].unk_14 << FX32_SHIFT) + (sub_0201D250(v1->unk_A0[0].unk_08) * v1->unk_A0[0].unk_18); - v4 = (v1->unk_A0[0].unk_16 << FX32_SHIFT) - (sub_0201D264(v1->unk_A0[0].unk_08) * v1->unk_A0[0].unk_1C); + v3 = (v1->unk_A0[0].unk_14 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(v1->unk_A0[0].unk_08) * v1->unk_A0[0].unk_18); + v4 = (v1->unk_A0[0].unk_16 << FX32_SHIFT) - (CalcCosineDegrees_Wraparound(v1->unk_A0[0].unk_08) * v1->unk_A0[0].unk_1C); sub_0200D650(v1->unk_A0[0].unk_00, v3, v4, ((192 + 64) << FX32_SHIFT)); ov116_02264764(&v1->unk_A0[0].unk_20, v3, v3 - FX32_CONST(180), ov116_022658C8(v1->unk_144)); @@ -1455,11 +1455,11 @@ static BOOL ov116_02265FD4(UnkStruct_ov116_02265D84 *param0, int param1, int par sub_0200D67C(param0->unk_00, &v3, &v4, ((192 + 64) << FX32_SHIFT)); if (param2 == 0) { - v1 = (param0->unk_14 << FX32_SHIFT) - (sub_0201D250(param0->unk_08) * param0->unk_18); - v2 = (param0->unk_16 << FX32_SHIFT) - (sub_0201D264(param0->unk_08) * param0->unk_1C); + v1 = (param0->unk_14 << FX32_SHIFT) - (CalcSineDegrees_Wraparound(param0->unk_08) * param0->unk_18); + v2 = (param0->unk_16 << FX32_SHIFT) - (CalcCosineDegrees_Wraparound(param0->unk_08) * param0->unk_1C); } else { - v1 = (param0->unk_14 << FX32_SHIFT) + (sub_0201D250(param0->unk_08) * param0->unk_18); - v2 = (param0->unk_16 << FX32_SHIFT) - (sub_0201D264(param0->unk_08) * param0->unk_1C); + v1 = (param0->unk_14 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(param0->unk_08) * param0->unk_18); + v2 = (param0->unk_16 << FX32_SHIFT) - (CalcCosineDegrees_Wraparound(param0->unk_08) * param0->unk_1C); } sub_0200D650(param0->unk_00, v1, v2, ((192 + 64) << FX32_SHIFT)); @@ -1516,13 +1516,13 @@ static void ov116_022660A8(SysTask *param0, void *param1) SpriteActor_EnableObject(v2->unk_A0[v0].unk_00, 1); sub_0200D67C(v2->unk_00[v0].unk_00, &v6, &v7, ((192 + 64) << FX32_SHIFT)); - v4 = (v2->unk_00[v0].unk_14 << FX32_SHIFT) + (sub_0201D250(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_18); - v5 = (v2->unk_00[v0].unk_16 << FX32_SHIFT) + (sub_0201D264(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_1C); + v4 = (v2->unk_00[v0].unk_14 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_18); + v5 = (v2->unk_00[v0].unk_16 << FX32_SHIFT) + (CalcCosineDegrees_Wraparound(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_1C); sub_0200D650(v2->unk_00[v0].unk_00, v4, v5, ((192 + 64) << FX32_SHIFT)); sub_0200D67C(v2->unk_A0[v0].unk_00, &v6, &v7, ((192 + 64) << FX32_SHIFT)); - v4 = (v2->unk_A0[v0].unk_14 << FX32_SHIFT) + (sub_0201D250(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_18); - v5 = (v2->unk_A0[v0].unk_16 << FX32_SHIFT) - (sub_0201D264(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_1C); + v4 = (v2->unk_A0[v0].unk_14 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_18); + v5 = (v2->unk_A0[v0].unk_16 << FX32_SHIFT) - (CalcCosineDegrees_Wraparound(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_1C); sub_0200D650(v2->unk_A0[v0].unk_00, v4, v5, ((192 + 64) << FX32_SHIFT)); } @@ -1643,13 +1643,13 @@ static void ov116_0226644C(SysTask *param0, void *param1) SpriteActor_EnableObject(v2->unk_A0[v0].unk_00, 1); sub_0200D67C(v2->unk_00[v0].unk_00, &v6, &v7, ((192 + 64) << FX32_SHIFT)); - v4 = (v2->unk_00[v0].unk_14 << FX32_SHIFT) + (sub_0201D250(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_18); - v5 = (v2->unk_00[v0].unk_16 << FX32_SHIFT) + (sub_0201D264(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_1C); + v4 = (v2->unk_00[v0].unk_14 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_18); + v5 = (v2->unk_00[v0].unk_16 << FX32_SHIFT) + (CalcCosineDegrees_Wraparound(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_1C); sub_0200D650(v2->unk_00[v0].unk_00, v4, v5, ((192 + 64) << FX32_SHIFT)); sub_0200D67C(v2->unk_A0[v0].unk_00, &v6, &v7, ((192 + 64) << FX32_SHIFT)); - v4 = (v2->unk_A0[v0].unk_14 << FX32_SHIFT) + (sub_0201D250(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_18); - v5 = (v2->unk_A0[v0].unk_16 << FX32_SHIFT) - (sub_0201D264(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_1C); + v4 = (v2->unk_A0[v0].unk_14 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_18); + v5 = (v2->unk_A0[v0].unk_16 << FX32_SHIFT) - (CalcCosineDegrees_Wraparound(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_1C); sub_0200D650(v2->unk_A0[v0].unk_00, v4, v5, ((192 + 64) << FX32_SHIFT)); } @@ -1761,13 +1761,13 @@ static void ov116_022667F4(SysTask *param0, void *param1) SpriteActor_EnableObject(v2->unk_A0[v0].unk_00, 1); sub_0200D67C(v2->unk_00[v0].unk_00, &v6, &v7, ((192 + 64) << FX32_SHIFT)); - v4 = (v2->unk_00[v0].unk_14 << FX32_SHIFT) + (sub_0201D250(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_18); - v5 = (v2->unk_00[v0].unk_16 << FX32_SHIFT) + (sub_0201D264(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_1C); + v4 = (v2->unk_00[v0].unk_14 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_18); + v5 = (v2->unk_00[v0].unk_16 << FX32_SHIFT) + (CalcCosineDegrees_Wraparound(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_1C); sub_0200D650(v2->unk_00[v0].unk_00, v4, v5, ((192 + 64) << FX32_SHIFT)); sub_0200D67C(v2->unk_A0[v0].unk_00, &v6, &v7, ((192 + 64) << FX32_SHIFT)); - v4 = (v2->unk_A0[v0].unk_14 << FX32_SHIFT) + (sub_0201D250(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_18); - v5 = (v2->unk_A0[v0].unk_16 << FX32_SHIFT) - (sub_0201D264(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_1C); + v4 = (v2->unk_A0[v0].unk_14 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_18); + v5 = (v2->unk_A0[v0].unk_16 << FX32_SHIFT) - (CalcCosineDegrees_Wraparound(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_1C); sub_0200D650(v2->unk_A0[v0].unk_00, v4, v5, ((192 + 64) << FX32_SHIFT)); } @@ -1907,13 +1907,13 @@ static void ov116_02266BF0(SysTask *param0, void *param1) SpriteActor_EnableObject(v2->unk_A0[v0].unk_00, 1); sub_0200D67C(v2->unk_00[v0].unk_00, &v6, &v7, ((192 + 64) << FX32_SHIFT)); - v4 = (v2->unk_00[v0].unk_14 << FX32_SHIFT) + (sub_0201D250(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_18); - v5 = (v2->unk_00[v0].unk_16 << FX32_SHIFT) + (sub_0201D264(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_1C); + v4 = (v2->unk_00[v0].unk_14 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_18); + v5 = (v2->unk_00[v0].unk_16 << FX32_SHIFT) + (CalcCosineDegrees_Wraparound(v2->unk_00[v0].unk_08) * v2->unk_00[v0].unk_1C); sub_0200D650(v2->unk_00[v0].unk_00, v4, v5, ((192 + 64) << FX32_SHIFT)); sub_0200D67C(v2->unk_A0[v0].unk_00, &v6, &v7, ((192 + 64) << FX32_SHIFT)); - v4 = (v2->unk_A0[v0].unk_14 << FX32_SHIFT) + (sub_0201D250(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_18); - v5 = (v2->unk_A0[v0].unk_16 << FX32_SHIFT) - (sub_0201D264(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_1C); + v4 = (v2->unk_A0[v0].unk_14 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_18); + v5 = (v2->unk_A0[v0].unk_16 << FX32_SHIFT) - (CalcCosineDegrees_Wraparound(v2->unk_A0[v0].unk_08) * v2->unk_A0[v0].unk_1C); sub_0200D650(v2->unk_A0[v0].unk_00, v4, v5, ((192 + 64) << FX32_SHIFT)); } diff --git a/src/overlay117/ov117_02263AF0.c b/src/overlay117/ov117_02263AF0.c index 62f2960f2f..26a2393f19 100644 --- a/src/overlay117/ov117_02263AF0.c +++ b/src/overlay117/ov117_02263AF0.c @@ -960,8 +960,8 @@ BOOL ov117_02264560(UnkStruct_ov117_02261280 *param0) v1->unk_04 = (128 + 32) << FX32_SHIFT; } - v4 = 128 + (FX_Mul(sub_0201D2B8(v1->unk_0C), v1->unk_04)) / FX32_ONE; - v5 = 96 + (-FX_Mul(sub_0201D2C4(v1->unk_0C), v1->unk_04)) / FX32_ONE; + v4 = 128 + (FX_Mul(CalcSineDegrees_FX32(v1->unk_0C), v1->unk_04)) / FX32_ONE; + v5 = 96 + (-FX_Mul(CalcCosineDegrees_FX32(v1->unk_0C), v1->unk_04)) / FX32_ONE; sub_0200D500(v1->unk_00, v4, v5, ((192 + 160) << FX32_SHIFT)); @@ -987,8 +987,8 @@ BOOL ov117_02264560(UnkStruct_ov117_02261280 *param0) v2->unk_04 = (128 + 32) << FX32_SHIFT; } - v4 = 128 + (FX_Mul(sub_0201D2B8(v2->unk_0C), v2->unk_04)) / FX32_ONE; - v5 = 96 + (-FX_Mul(sub_0201D2C4(v2->unk_0C), v2->unk_04)) / FX32_ONE; + v4 = 128 + (FX_Mul(CalcSineDegrees_FX32(v2->unk_0C), v2->unk_04)) / FX32_ONE; + v5 = 96 + (-FX_Mul(CalcCosineDegrees_FX32(v2->unk_0C), v2->unk_04)) / FX32_ONE; sub_0200D500(v2->unk_00, v4, v5, ((192 + 160) << FX32_SHIFT)); @@ -1014,8 +1014,8 @@ BOOL ov117_02264560(UnkStruct_ov117_02261280 *param0) v3->unk_04 = (128 + 32) << FX32_SHIFT; } - v4 = 128 + (FX_Mul(sub_0201D2B8(v3->unk_0C), v3->unk_04)) / FX32_ONE; - v5 = 96 + (-FX_Mul(sub_0201D2C4(v3->unk_0C), v3->unk_04)) / FX32_ONE; + v4 = 128 + (FX_Mul(CalcSineDegrees_FX32(v3->unk_0C), v3->unk_04)) / FX32_ONE; + v5 = 96 + (-FX_Mul(CalcCosineDegrees_FX32(v3->unk_0C), v3->unk_04)) / FX32_ONE; sub_0200D500(v3->unk_00, v4, v5, ((192 + 160) << FX32_SHIFT)); @@ -1490,8 +1490,8 @@ void ov117_02265064(UnkStruct_ov117_02261280 *param0, UnkStruct_ov117_022653F4 * v0 = Unk_ov117_02266D9C; for (v1 = 0; v1 < 3; v1++) { - v3 = 256 / 2 + FX_Mul(sub_0201D2B8(param1->unk_E4 + param1->unk_00[v1].unk_0C), 76); - v4 = 196 / 2 + (-FX_Mul(sub_0201D2C4(param1->unk_E4 + param1->unk_00[v1].unk_0C), (64 + 4))); + v3 = 256 / 2 + FX_Mul(CalcSineDegrees_FX32(param1->unk_E4 + param1->unk_00[v1].unk_0C), 76); + v4 = 196 / 2 + (-FX_Mul(CalcCosineDegrees_FX32(param1->unk_E4 + param1->unk_00[v1].unk_0C), (64 + 4))); param1->unk_00[v1].unk_00 = SpriteActor_LoadResources(param0->unk_24, param0->unk_28, &v0); sub_0200D500(param1->unk_00[v1].unk_00, v3, v4 + -24, ((192 + 160) << FX32_SHIFT)); @@ -1703,7 +1703,7 @@ static int ov117_02265454(UnkStruct_ov117_02261280 *param0, UnkStruct_ov117_0226 } v6 = ((180 * param2->unk_12) << FX32_SHIFT) / 15; - v7 = -(FX_Mul(sub_0201D2B8(v6), (24 << FX32_SHIFT))) / FX32_ONE; + v7 = -(FX_Mul(CalcSineDegrees_FX32(v6), (24 << FX32_SHIFT))) / FX32_ONE; sub_0200D500(param2->unk_00, v0, v1 + v7, ((192 + 160) << FX32_SHIFT)); sub_0200D500(param2->unk_08, v0, v1 + 24, ((192 + 160) << FX32_SHIFT)); @@ -1734,9 +1734,9 @@ static int ov117_02265644(UnkStruct_ov117_02261280 *param0, UnkStruct_ov117_0226 } v2 = ((180 * param1->unk_F3) << FX32_SHIFT) / Unk_ov117_02266BC4[param1->unk_F4].unk_00; - v3 = -(FX_Mul(sub_0201D2B8(v2), (12 << FX32_SHIFT))) / FX32_ONE; - v0 = 256 / 2 + FX_Mul(sub_0201D2B8(param1->unk_E4 + param2->unk_0C), 76); - v1 = 196 / 2 + (-FX_Mul(sub_0201D2C4(param1->unk_E4 + param2->unk_0C), (64 + 4))); + v3 = -(FX_Mul(CalcSineDegrees_FX32(v2), (12 << FX32_SHIFT))) / FX32_ONE; + v0 = 256 / 2 + FX_Mul(CalcSineDegrees_FX32(param1->unk_E4 + param2->unk_0C), 76); + v1 = 196 / 2 + (-FX_Mul(CalcCosineDegrees_FX32(param1->unk_E4 + param2->unk_0C), (64 + 4))); sub_0200D500(param2->unk_00, v0, v1 + -24 + v3, ((192 + 160) << FX32_SHIFT)); sub_0200D500(param2->unk_08, v0, v1 + -24 + 24, ((192 + 160) << FX32_SHIFT)); @@ -1821,8 +1821,8 @@ static int ov117_022657C4(UnkStruct_ov117_02261280 *param0, UnkStruct_ov117_0226 v3 += param2->unk_0C / ((360 / 12) << FX32_SHIFT); v3 %= 12; - v4 = 256 / 2 + FX_Mul(sub_0201D2B8((360 << FX32_SHIFT) / 12 * v3), 76); - v5 = 196 / 2 + (-FX_Mul(sub_0201D2C4((360 << FX32_SHIFT) / 12 * v3), (64 + 4))); + v4 = 256 / 2 + FX_Mul(CalcSineDegrees_FX32((360 << FX32_SHIFT) / 12 * v3), 76); + v5 = 196 / 2 + (-FX_Mul(CalcCosineDegrees_FX32((360 << FX32_SHIFT) / 12 * v3), (64 + 4))); sub_0200D5A0(param2->unk_00, &v6, &v7, ((192 + 160) << FX32_SHIFT)); @@ -1841,7 +1841,7 @@ static int ov117_022657C4(UnkStruct_ov117_02261280 *param0, UnkStruct_ov117_0226 param2->unk_2C += param2->unk_24; v8 = ((180 * param2->unk_12) << FX32_SHIFT) / param2->unk_18; - v9 = -(FX_Mul(sub_0201D2B8(v8), (12 << FX32_SHIFT))) / FX32_ONE; + v9 = -(FX_Mul(CalcSineDegrees_FX32(v8), (12 << FX32_SHIFT))) / FX32_ONE; sub_0200D500(param2->unk_00, param2->unk_28 / FX32_ONE, param2->unk_2C / FX32_ONE + -24 + v9, ((192 + 160) << FX32_SHIFT)); sub_0200D34C(param2->unk_00, ((8 + 8 + 12 + 8 + 8) << FX32_SHIFT) / param2->unk_18); diff --git a/src/savedata.c b/src/savedata.c index 97bc6c9b8c..b9cb7378ec 100644 --- a/src/savedata.c +++ b/src/savedata.c @@ -288,12 +288,12 @@ static void SaveData_CheckInfoInit(SaveCheckInfo *checkInfo) u16 SaveData_CalculateChecksum(const SaveData *saveData, const void *startAddress, u32 size) { - return sub_0201D628(startAddress, size); + return CalcCRC16Checksum(startAddress, size); } static u16 SaveData_CalculateFooterChecksum(const SaveData *saveData, void *startAddress, u32 size) { - return sub_0201D628(startAddress, size - sizeof(SaveBlockFooter)); + return CalcCRC16Checksum(startAddress, size - sizeof(SaveBlockFooter)); } static u32 SaveData_SaveOffset(int sectorID, const SaveBlockInfo *blockInfo) @@ -593,7 +593,7 @@ static BOOL SaveDataState_Load(SaveData *saveData) } for (i = 0; i < SAVE_TABLE_ENTRY_MAX; i++) { - saveData->pageInfo[i].checksum = sub_0201D628(SaveData_SaveTable(saveData, i), saveData->pageInfo[i].size); + saveData->pageInfo[i].checksum = CalcCRC16Checksum(SaveData_SaveTable(saveData, i), saveData->pageInfo[i].size); } return TRUE; @@ -931,7 +931,7 @@ static void SaveCheckFooter_Set(const SaveData *saveData, void *saveBody, int ex footer->saveCounter = saveData->sectorCounter + 1; footer->size = size; footer->id = extraSaveID; - footer->checksum = sub_0201D628(saveBody, size + sizeof(SaveCheckFooter) - 2); + footer->checksum = CalcCRC16Checksum(saveBody, size + sizeof(SaveCheckFooter) - 2); } static BOOL SaveCheckFooter_Validate(const SaveData *saveData, void *saveBody, int extraSaveID, u32 size) @@ -950,7 +950,7 @@ static BOOL SaveCheckFooter_Validate(const SaveData *saveData, void *saveBody, i return FALSE; } - if (footer->checksum != sub_0201D628(saveBody, size + sizeof(SaveCheckFooter) - 2)) { + if (footer->checksum != CalcCRC16Checksum(saveBody, size + sizeof(SaveCheckFooter) - 2)) { return FALSE; } @@ -1331,7 +1331,7 @@ BOOL SaveData_Checksum(int saveTableID) void *table = SaveData_SaveTable(saveData, saveTableID); int size = SaveTableEntry_BodySize(saveTableID) - 4; - u16 checkResult = sub_0201D628(table, size); + u16 checkResult = CalcCRC16Checksum(table, size); int halfSize = size / 2; u16 *halfTable = table; @@ -1355,7 +1355,7 @@ void SaveData_SetChecksum(int saveTableID) int halfSize = size / 2; u16 *halfTable = table; - u16 checksum = sub_0201D628(table, size); + u16 checksum = CalcCRC16Checksum(table, size); halfTable[halfSize] = checksum; diff --git a/src/unk_02017728.c b/src/unk_02017728.c index 4fcfb1ad95..8927d17fd1 100644 --- a/src/unk_02017728.c +++ b/src/unk_02017728.c @@ -3,6 +3,8 @@ #include #include +#include "constants/heap.h" + #include "struct_defs/struct_02017E74.h" #include "core_sys.h" @@ -183,7 +185,7 @@ void sub_0201789C(void) CARD_SetCacheFlushThreshold(0x500, 0x2400); - sub_0201D640(0); + InitCRC16Table(HEAP_ID_SYSTEM); } void InitGraphics(void) diff --git a/src/unk_0201E190.c b/src/unk_0201E190.c index 4c806f2579..c7d6a80fe6 100644 --- a/src/unk_0201E190.c +++ b/src/unk_0201E190.c @@ -64,10 +64,10 @@ void sub_0201E2E0(MtxFx33 *param0, u16 param1, u16 param2, u16 param3) { MtxFx33 v0; - MTX_RotX33(param0, sub_0201D15C(param1), sub_0201D1D4(param1)); - MTX_RotY33(&v0, sub_0201D15C(param2), sub_0201D1D4(param2)); + MTX_RotX33(param0, CalcSineDegrees(param1), CalcCosineDegrees(param1)); + MTX_RotY33(&v0, CalcSineDegrees(param2), CalcCosineDegrees(param2)); MTX_Concat33(param0, &v0, param0); - MTX_RotZ33(&v0, sub_0201D15C(param3), sub_0201D1D4(param3)); + MTX_RotZ33(&v0, CalcSineDegrees(param3), CalcCosineDegrees(param3)); MTX_Concat33(param0, &v0, param0); } diff --git a/src/unk_0205DFC4.c b/src/unk_0205DFC4.c index 8fe87c4711..7c4bf8b375 100644 --- a/src/unk_0205DFC4.c +++ b/src/unk_0205DFC4.c @@ -295,8 +295,8 @@ static BOOL sub_0205E268(FieldTask *param0) v0.x = FX32_CONST(8); v0.z = FX32_CONST(8); - v0.x = FX_Mul(sub_0201D15C(v2->unk_0E), v2->unk_04); - v0.z = FX_Mul(sub_0201D15C(v2->unk_0E), v2->unk_08); + v0.x = FX_Mul(CalcSineDegrees(v2->unk_0E), v2->unk_04); + v0.z = FX_Mul(CalcSineDegrees(v2->unk_0E), v2->unk_08); v0.y = 0; sub_020630AC(v2->unk_00, &v0); diff --git a/src/unk_0208694C.c b/src/unk_0208694C.c index f008955c08..5a44c808a7 100644 --- a/src/unk_0208694C.c +++ b/src/unk_0208694C.c @@ -2056,7 +2056,7 @@ static void sub_02088514(u16 *param0) *param0 = 0; } - v0 = sub_0201D250(*param0); + v0 = CalcSineDegrees_Wraparound(*param0); v3 = 15 + (v0 * 10) / FX32_ONE; v1 = GX_RGB(29, v3, 0); diff --git a/src/unk_0208B284.c b/src/unk_0208B284.c index d309cc3674..a29aee5d1f 100644 --- a/src/unk_0208B284.c +++ b/src/unk_0208B284.c @@ -162,8 +162,8 @@ static void sub_0208B3D4(SysTask *param0, void *param1) case 1: v0->unk_24[v1].unk_0C += (8 / 2); v0->unk_24[v1].unk_0C %= 720; - v14 = (v0->unk_24[0].unk_04 << FX32_SHIFT) + (sub_0201D250(v0->unk_24[v1].unk_0C) * v0->unk_FC); - v15 = (v0->unk_24[0].unk_06 << FX32_SHIFT) + (sub_0201D264(v0->unk_24[v1].unk_0C) * v0->unk_100); + v14 = (v0->unk_24[0].unk_04 << FX32_SHIFT) + (CalcSineDegrees_Wraparound(v0->unk_24[v1].unk_0C) * v0->unk_FC); + v15 = (v0->unk_24[0].unk_06 << FX32_SHIFT) + (CalcCosineDegrees_Wraparound(v0->unk_24[v1].unk_0C) * v0->unk_100); sub_0200D650(v0->unk_24[v1].unk_00, v14, v15, v0->unk_10.unk_10); break; default: From 59fba4bd28b59449022e92ac3de2b1d2bc1e3c53 Mon Sep 17 00:00:00 2001 From: Rachel Date: Mon, 18 Nov 2024 19:56:30 -0800 Subject: [PATCH 09/11] Decorate TrainerBattle and {Set,Clear}TrainerFlag with trdata.naix values --- asm/macros/scrcmd.inc | 4 +- res/field/scripts/meson.build | 8 +- res/field/scripts/scripts_battleground.s | 28 +-- res/field/scripts/scripts_canalave_city.s | 6 +- res/field/scripts/scripts_canalave_city_gym.s | 18 +- res/field/scripts/scripts_celestic_town.s | 2 +- .../scripts/scripts_celestic_town_cave.s | 4 +- .../scripts/scripts_distortion_world_b7f.s | 2 +- res/field/scripts/scripts_eterna_city_gym.s | 24 +- res/field/scripts/scripts_floaroma_meadow.s | 4 +- res/field/scripts/scripts_galactic_hq_4f.s | 2 +- .../scripts_galactic_hq_control_room.s | 2 +- ...cripts_hearthome_city_dp_gym_leader_room.s | 20 +- .../scripts_hearthome_city_gym_leader_room.s | 20 +- .../scripts_iron_island_b2f_left_room.s | 2 +- res/field/scripts/scripts_lake_verity.s | 2 +- res/field/scripts/scripts_oreburgh_city_gym.s | 12 +- res/field/scripts/scripts_pastoria_city.s | 6 +- res/field/scripts/scripts_pastoria_city_gym.s | 16 +- .../scripts_pokemon_league_aaron_room.s | 10 +- .../scripts_pokemon_league_bertha_room.s | 10 +- .../scripts_pokemon_league_champion_room.s | 10 +- .../scripts_pokemon_league_flint_room.s | 10 +- .../scripts_pokemon_league_lucian_room.s | 8 +- ...ripts_pokemon_league_north_pokecenter_1f.s | 6 +- res/field/scripts/scripts_pokemon_mansion.s | 28 +-- res/field/scripts/scripts_restaurant.s | 216 +++++++++--------- res/field/scripts/scripts_route_203.s | 6 +- ...scripts_route_209_gate_to_hearthome_city.s | 6 +- .../scripts/scripts_snowpoint_city_gym.s | 16 +- res/field/scripts/scripts_spear_pillar.s | 2 +- .../scripts/scripts_stark_mountain_room_1.s | 4 +- .../scripts_sunyshore_city_gym_room_3.s | 21 +- res/field/scripts/scripts_survival_area.s | 12 +- ...scripts_team_galactic_eterna_building_4f.s | 2 +- res/field/scripts/scripts_trainers_school.s | 12 +- res/field/scripts/scripts_unk_0400.s | 2 +- res/field/scripts/scripts_unk_1114.s | 4 +- .../scripts_valley_windworks_building.s | 2 +- .../scripts_valley_windworks_outside.s | 2 +- res/field/scripts/scripts_valor_cavern.s | 2 +- res/field/scripts/scripts_valor_lakefront.s | 2 +- .../scripts/scripts_veilstone_city_gym.s | 12 +- res/meson.build | 3 +- 44 files changed, 298 insertions(+), 292 deletions(-) diff --git a/asm/macros/scrcmd.inc b/asm/macros/scrcmd.inc index 01e1a7bd54..0343b60020 100644 --- a/asm/macros/scrcmd.inc +++ b/asm/macros/scrcmd.inc @@ -9,6 +9,8 @@ .include "consts/sdat.inc" .include "consts/species.inc" +#include "res/trainers/trdata.naix" + .macro Noop .short 0 .endm @@ -1263,7 +1265,7 @@ .short \arg0 .endm - .macro StartTrainerBattle enemyTrainer1, enemyTrainer2 + .macro StartTrainerBattle enemyTrainer1, enemyTrainer2=0 .short 229 .short \enemyTrainer1 .short \enemyTrainer2 diff --git a/res/field/scripts/meson.build b/res/field/scripts/meson.build index ffd9f1a5b0..e38bf70be2 100644 --- a/res/field/scripts/meson.build +++ b/res/field/scripts/meson.build @@ -1148,9 +1148,11 @@ scr_seq_narc = custom_target('scr_seq.narc', '-p', '@OUTPUT0@', '-o', scr_seq_narc_order, '-n' - ] + ], + depends: [ + trdata_narc, + ], ) -nitrofs_files += scr_seq_narc - +nitrofs_files += scr_seq_narc[0] naix_headers += scr_seq_narc[1] diff --git a/res/field/scripts/scripts_battleground.s b/res/field/scripts/scripts_battleground.s index dc887f969c..c9be048bf2 100644 --- a/res/field/scripts/scripts_battleground.s +++ b/res/field/scripts/scripts_battleground.s @@ -230,7 +230,7 @@ _032F: CloseMessage IncrementGameRecord RECORD_UNK_057 Call _0605 - StartTrainerBattle 0x4005, 0 + StartTrainerBattle 0x4005 CheckWonBattle 0x8000 Return @@ -396,55 +396,55 @@ _0605: Return _06B0: - SetVar 0x4005, 0x35A + SetVar 0x4005, trainer_leader_roark_rematch Return _06B8: - SetVar 0x4005, 0x359 + SetVar 0x4005, trainer_leader_gardenia_rematch Return _06C0: - SetVar 0x4005, 0x35B + SetVar 0x4005, trainer_leader_wake_rematch Return _06C8: - SetVar 0x4005, 0x356 + SetVar 0x4005, trainer_leader_maylene_rematch Return _06D0: - SetVar 0x4005, 0x35C + SetVar 0x4005, trainer_leader_fantina_rematch Return _06D8: - SetVar 0x4005, 0x355 + SetVar 0x4005, trainer_leader_candice_rematch Return _06E0: - SetVar 0x4005, 0x358 + SetVar 0x4005, trainer_leader_byron_rematch Return _06E8: - SetVar 0x4005, 0x357 + SetVar 0x4005, trainer_leader_volkner_rematch Return _06F0: - SetVar 0x4005, 0x361 + SetVar 0x4005, trainer_trainer_cheryl_battleground Return _06F8: - SetVar 0x4005, 0x35D + SetVar 0x4005, trainer_trainer_riley_battleground Return _0700: - SetVar 0x4005, 0x35F + SetVar 0x4005, trainer_trainer_marley_battleground Return _0708: - SetVar 0x4005, 0x35E + SetVar 0x4005, trainer_trainer_buck_battleground Return _0710: - SetVar 0x4005, 0x360 + SetVar 0x4005, trainer_trainer_mira_battleground Return _0718: diff --git a/res/field/scripts/scripts_canalave_city.s b/res/field/scripts/scripts_canalave_city.s index ac0516de96..6b1628a511 100644 --- a/res/field/scripts/scripts_canalave_city.s +++ b/res/field/scripts/scripts_canalave_city.s @@ -161,15 +161,15 @@ _028A: GoTo _02DF _02DF: - StartTrainerBattle 0x1DC, 0 + StartTrainerBattle trainer_rival_canalave_city_piplup GoTo _0303 _02EB: - StartTrainerBattle 0x1DD, 0 + StartTrainerBattle trainer_rival_canalave_city_turtwig GoTo _0303 _02F7: - StartTrainerBattle 0x1DE, 0 + StartTrainerBattle trainer_rival_canalave_city_chimchar GoTo _0303 _0303: diff --git a/res/field/scripts/scripts_canalave_city_gym.s b/res/field/scripts/scripts_canalave_city_gym.s index 53d1334fb2..b0ad4d4b91 100644 --- a/res/field/scripts/scripts_canalave_city_gym.s +++ b/res/field/scripts/scripts_canalave_city_gym.s @@ -21,7 +21,7 @@ _0016: ScrCmd_1CD 9, 35, 0, 0, 0 Message 0 CloseMessage - StartTrainerBattle 250, 0 + StartTrainerBattle trainer_leader_byron CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0120 Message 1 @@ -31,14 +31,14 @@ _0016: WaitSound GiveBadge BADGE_ID_MINE ScrCmd_260 23 - SetTrainerFlag 232 - SetTrainerFlag 0x100 - SetTrainerFlag 0x101 - SetTrainerFlag 0x117 - SetTrainerFlag 0x11B - SetTrainerFlag 0x13A - SetTrainerFlag 0x16F - ScrCmd_1CD 10, 35, 250, 0, 0 + SetTrainerFlag trainer_black_belt_david + SetTrainerFlag trainer_worker_jackson + SetTrainerFlag trainer_worker_gary + SetTrainerFlag trainer_ace_trainer_cesar + SetTrainerFlag trainer_ace_trainer_breanna + SetTrainerFlag trainer_black_belt_ricky + SetTrainerFlag trainer_worker_gerardo + ScrCmd_1CD 10, 35, trainer_leader_byron, 0, 0 ClearFlag 0x1B2 ClearFlag 0x2CC ClearFlag 0x1B8 diff --git a/res/field/scripts/scripts_celestic_town.s b/res/field/scripts/scripts_celestic_town.s index 83b7c554c4..66859a2d1a 100644 --- a/res/field/scripts/scripts_celestic_town.s +++ b/res/field/scripts/scripts_celestic_town.s @@ -40,7 +40,7 @@ _0063: _006E: Message 2 CloseMessage - StartTrainerBattle 0x1A0, 0 + StartTrainerBattle trainer_galactic_grunt_celestic_town CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0191 Message 4 diff --git a/res/field/scripts/scripts_celestic_town_cave.s b/res/field/scripts/scripts_celestic_town_cave.s index 7aa5f4ca64..98795bc014 100644 --- a/res/field/scripts/scripts_celestic_town_cave.s +++ b/res/field/scripts/scripts_celestic_town_cave.s @@ -101,7 +101,7 @@ _0181: _019D: Message 8 CloseMessage - StartTrainerBattle 0x391, 0 + StartTrainerBattle trainer_galactic_boss_cyrus_celestic_town_ruins CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0393 Call _01C3 @@ -466,7 +466,7 @@ _0538: GoToIfEq 0x800C, 1, _057A Message 8 CloseMessage - StartTrainerBattle 0x391, 0 + StartTrainerBattle trainer_galactic_boss_cyrus_celestic_town_ruins CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0393 Call _01C3 diff --git a/res/field/scripts/scripts_distortion_world_b7f.s b/res/field/scripts/scripts_distortion_world_b7f.s index f186c25346..fdf5a5e2d1 100644 --- a/res/field/scripts/scripts_distortion_world_b7f.s +++ b/res/field/scripts/scripts_distortion_world_b7f.s @@ -54,7 +54,7 @@ _0096: FacePlayer Message 5 CloseMessage - StartTrainerBattle 0x194, 0 + StartTrainerBattle trainer_galactic_boss_cyrus_distortion_world CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _01CE SetVar 0x4055, 10 diff --git a/res/field/scripts/scripts_eterna_city_gym.s b/res/field/scripts/scripts_eterna_city_gym.s index bd4a24ce10..2ead07510f 100644 --- a/res/field/scripts/scripts_eterna_city_gym.s +++ b/res/field/scripts/scripts_eterna_city_gym.s @@ -67,7 +67,7 @@ _0094: ScrCmd_1CD 9, 67, 0, 0, 0 Message 0 CloseMessage - StartTrainerBattle 0x13B, 0 + StartTrainerBattle trainer_leader_gardenia CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _01C3 Message 1 @@ -77,12 +77,12 @@ _0094: WaitSound GiveBadge BADGE_ID_FOREST ScrCmd_260 23 - SetTrainerFlag 0x103 - SetTrainerFlag 0x104 - SetTrainerFlag 0x144 - SetTrainerFlag 0x15C + SetTrainerFlag trainer_aroma_lady_jenna + SetTrainerFlag trainer_aroma_lady_angela + SetTrainerFlag trainer_lass_caroline + SetTrainerFlag trainer_beauty_lindsay ClearFlag 0x1FC - ScrCmd_1CD 10, 67, 0x13B, 0, 0 + ScrCmd_1CD 10, 67, trainer_leader_gardenia, 0, 0 Message 3 GoTo _0177 End @@ -149,10 +149,10 @@ _01C9: LockAll FacePlayer GoToIfGe 0x40AE, 1, _0211 - ScrCmd_0EA 0x144 + ScrCmd_0EA trainer_lass_caroline Message 6 CloseMessage - StartTrainerBattle 0x144, 0 + StartTrainerBattle trainer_lass_caroline CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _01C3 Message 7 @@ -175,12 +175,12 @@ _021C: LockAll FacePlayer GoToIfGe 0x40AE, 2, _0270 - ScrCmd_0EA 0x103 + ScrCmd_0EA trainer_aroma_lady_jenna SetVar 0x8007, 3 Call _02DA Message 8 CloseMessage - StartTrainerBattle 0x103, 0 + StartTrainerBattle trainer_aroma_lady_jenna CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _01C3 Message 9 @@ -203,12 +203,12 @@ _027B: LockAll FacePlayer GoToIfGe 0x40AE, 3, _02CF - ScrCmd_0EA 0x104 + ScrCmd_0EA trainer_aroma_lady_angela SetVar 0x8007, 4 Call _02DA Message 10 CloseMessage - StartTrainerBattle 0x104, 0 + StartTrainerBattle trainer_aroma_lady_angela CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _01C3 Message 11 diff --git a/res/field/scripts/scripts_floaroma_meadow.s b/res/field/scripts/scripts_floaroma_meadow.s index 59abf4f9e2..cf396e154e 100644 --- a/res/field/scripts/scripts_floaroma_meadow.s +++ b/res/field/scripts/scripts_floaroma_meadow.s @@ -18,11 +18,11 @@ _001E: _0024: LockAll Call _00CC - StartTrainerBattle 0x128, 0 + StartTrainerBattle trainer_galactic_grunt_floaroma_meadow_1 CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _006E Call _00EE - StartTrainerBattle 0x129, 0 + StartTrainerBattle trainer_galactic_grunt_floaroma_meadow_2 CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _006E Call _010E diff --git a/res/field/scripts/scripts_galactic_hq_4f.s b/res/field/scripts/scripts_galactic_hq_4f.s index 0b90989b33..cdaa5889ce 100644 --- a/res/field/scripts/scripts_galactic_hq_4f.s +++ b/res/field/scripts/scripts_galactic_hq_4f.s @@ -34,7 +34,7 @@ _0064: GoTo _0074 _0074: - StartTrainerBattle 0x193, 0 + StartTrainerBattle trainer_galactic_boss_cyrus_galactic_hq CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _00E1 Message 2 diff --git a/res/field/scripts/scripts_galactic_hq_control_room.s b/res/field/scripts/scripts_galactic_hq_control_room.s index 1c5f32ca0d..324ba9ae6f 100644 --- a/res/field/scripts/scripts_galactic_hq_control_room.s +++ b/res/field/scripts/scripts_galactic_hq_control_room.s @@ -39,7 +39,7 @@ _0059: GoToIfSet 173, _0114 Message 0 CloseMessage - StartTrainerBattle 0x199, 0 + StartTrainerBattle trainer_commander_saturn_galactic_hq CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _011F SetFlag 173 diff --git a/res/field/scripts/scripts_hearthome_city_dp_gym_leader_room.s b/res/field/scripts/scripts_hearthome_city_dp_gym_leader_room.s index e91fa3dcbd..c9a0a4591b 100644 --- a/res/field/scripts/scripts_hearthome_city_dp_gym_leader_room.s +++ b/res/field/scripts/scripts_hearthome_city_dp_gym_leader_room.s @@ -45,7 +45,7 @@ _0096: ScrCmd_1CD 9, 100, 0, 0, 0 Message 0 CloseMessage - StartTrainerBattle 0x13E, 0 + StartTrainerBattle trainer_leader_fantina CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _01DC Message 1 @@ -55,15 +55,15 @@ _0096: WaitSound GiveBadge BADGE_ID_RELIC ScrCmd_260 23 - SetTrainerFlag 0x10A - SetTrainerFlag 0x118 - SetTrainerFlag 0x11C - SetTrainerFlag 0x145 - SetTrainerFlag 0x14A - SetTrainerFlag 0x154 - SetTrainerFlag 0x157 - SetTrainerFlag 0x165 - ScrCmd_1CD 10, 100, 0x13E, 0, 0 + SetTrainerFlag trainer_camper_drew + SetTrainerFlag trainer_ace_trainer_allen + SetTrainerFlag trainer_ace_trainer_catherine + SetTrainerFlag trainer_lass_molly + SetTrainerFlag trainer_picnicker_cheyenne + SetTrainerFlag trainer_school_kid_chance + SetTrainerFlag trainer_school_kid_mackenzie + SetTrainerFlag trainer_youngster_donny + ScrCmd_1CD 10, 100, trainer_leader_fantina, 0, 0 SetVar 0x407B, 1 SetFlag 0x206 ClearFlag 0x207 diff --git a/res/field/scripts/scripts_hearthome_city_gym_leader_room.s b/res/field/scripts/scripts_hearthome_city_gym_leader_room.s index 7ca4ad1395..be11e17e72 100644 --- a/res/field/scripts/scripts_hearthome_city_gym_leader_room.s +++ b/res/field/scripts/scripts_hearthome_city_gym_leader_room.s @@ -59,7 +59,7 @@ _00BB: Message 0 CloseMessage SetFlag 142 - StartTrainerBattle 0x13E, 0 + StartTrainerBattle trainer_leader_fantina ClearFlag 142 CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0248 @@ -70,15 +70,15 @@ _00BB: WaitSound GiveBadge BADGE_ID_RELIC ScrCmd_260 23 - SetTrainerFlag 0x10A - SetTrainerFlag 0x118 - SetTrainerFlag 0x11C - SetTrainerFlag 0x145 - SetTrainerFlag 0x14A - SetTrainerFlag 0x154 - SetTrainerFlag 0x157 - SetTrainerFlag 0x165 - ScrCmd_1CD 10, 91, 0x13E, 0, 0 + SetTrainerFlag trainer_camper_drew + SetTrainerFlag trainer_ace_trainer_allen + SetTrainerFlag trainer_ace_trainer_catherine + SetTrainerFlag trainer_lass_molly + SetTrainerFlag trainer_picnicker_cheyenne + SetTrainerFlag trainer_school_kid_chance + SetTrainerFlag trainer_school_kid_mackenzie + SetTrainerFlag trainer_youngster_donny + ScrCmd_1CD 10, 91, trainer_leader_fantina, 0, 0 SetVar 0x407B, 1 SetFlag 0x206 ClearFlag 0x207 diff --git a/res/field/scripts/scripts_iron_island_b2f_left_room.s b/res/field/scripts/scripts_iron_island_b2f_left_room.s index 72028ea62e..71103935a2 100644 --- a/res/field/scripts/scripts_iron_island_b2f_left_room.s +++ b/res/field/scripts/scripts_iron_island_b2f_left_room.s @@ -172,7 +172,7 @@ _01AA: Message 8 CloseMessage SetHasPartner - StartTrainerBattle 0x343, 0x344 + StartTrainerBattle trainer_galactic_grunt_iron_island_1, trainer_galactic_grunt_iron_island_2 ClearHasPartner CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _037D diff --git a/res/field/scripts/scripts_lake_verity.s b/res/field/scripts/scripts_lake_verity.s index df0457aae5..538508fc5b 100644 --- a/res/field/scripts/scripts_lake_verity.s +++ b/res/field/scripts/scripts_lake_verity.s @@ -194,7 +194,7 @@ _0230: WaitMovement Message 9 CloseMessage - StartTrainerBattle 0x195, 0 + StartTrainerBattle trainer_commander_mars_lake_verity CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _02DB Message 10 diff --git a/res/field/scripts/scripts_oreburgh_city_gym.s b/res/field/scripts/scripts_oreburgh_city_gym.s index 13738cea86..c98790cd5e 100644 --- a/res/field/scripts/scripts_oreburgh_city_gym.s +++ b/res/field/scripts/scripts_oreburgh_city_gym.s @@ -16,7 +16,7 @@ _000E: ScrCmd_1CD 9, 47, 0, 0, 0 Message 0 CloseMessage - StartTrainerBattle 246, 0 + StartTrainerBattle trainer_leader_roark CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0119 Message 1 @@ -24,17 +24,17 @@ _000E: Message 2 PlaySound SEQ_BADGE WaitSound - SetTrainerFlag 244 - SetTrainerFlag 245 + SetTrainerFlag trainer_youngster_jonathon + SetTrainerFlag trainer_youngster_darius GiveBadge BADGE_ID_COAL ScrCmd_260 23 - SetTrainerFlag 244 - SetTrainerFlag 245 + SetTrainerFlag trainer_youngster_jonathon + SetTrainerFlag trainer_youngster_darius SetFlag 0x23F SetVar 0x40F0, 1 SetVar 0x4076, 1 SetVar 0x4079, 2 - ScrCmd_1CD 10, 47, 246, 0, 0 + ScrCmd_1CD 10, 47, trainer_leader_roark, 0, 0 SetVar 0x4077, 3 ClearFlag 0x17A ClearFlag 0x19D diff --git a/res/field/scripts/scripts_pastoria_city.s b/res/field/scripts/scripts_pastoria_city.s index 7d07ebbf6f..a93577fca1 100644 --- a/res/field/scripts/scripts_pastoria_city.s +++ b/res/field/scripts/scripts_pastoria_city.s @@ -581,15 +581,15 @@ _04C8: GoTo _053F _053F: - StartTrainerBattle 0x1D9, 0 + StartTrainerBattle trainer_rival_pastoria_city_piplup GoTo _0563 _054B: - StartTrainerBattle 0x1DA, 0 + StartTrainerBattle trainer_rival_pastoria_city_turtwig GoTo _0563 _0557: - StartTrainerBattle 0x1DB, 0 + StartTrainerBattle trainer_rival_pastoria_city_chimchar GoTo _0563 _0563: diff --git a/res/field/scripts/scripts_pastoria_city_gym.s b/res/field/scripts/scripts_pastoria_city_gym.s index 016f80c4ce..d49dbd3c33 100644 --- a/res/field/scripts/scripts_pastoria_city_gym.s +++ b/res/field/scripts/scripts_pastoria_city_gym.s @@ -48,7 +48,7 @@ _0076: ScrCmd_1CD 9, 122, 0, 0, 0 Message 0 CloseMessage - StartTrainerBattle 0x13C, 0 + StartTrainerBattle trainer_leader_wake CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _016B Message 1 @@ -58,16 +58,16 @@ _0076: WaitSound GiveBadge BADGE_ID_FEN ScrCmd_260 23 - SetTrainerFlag 0x125 - SetTrainerFlag 0x153 - SetTrainerFlag 0x191 - SetTrainerFlag 0x1E3 - SetTrainerFlag 0x1F1 - SetTrainerFlag 0x1F2 + SetTrainerFlag trainer_fisherman_erick + SetTrainerFlag trainer_sailor_damian + SetTrainerFlag trainer_fisherman_walter + SetTrainerFlag trainer_sailor_samson + SetTrainerFlag trainer_tuber_jacky + SetTrainerFlag trainer_tuber_caitlyn SetVar 0x407C, 3 SetFlag 0x20C SetFlag 0x156 - ScrCmd_1CD 10, 122, 0x13C, 0, 0 + ScrCmd_1CD 10, 122, trainer_leader_wake, 0, 0 Message 3 GoTo _010D End diff --git a/res/field/scripts/scripts_pokemon_league_aaron_room.s b/res/field/scripts/scripts_pokemon_league_aaron_room.s index 59d700889b..6d3d955373 100644 --- a/res/field/scripts/scripts_pokemon_league_aaron_room.s +++ b/res/field/scripts/scripts_pokemon_league_aaron_room.s @@ -11,7 +11,7 @@ _000A: LockAll FacePlayer GoToIfSet 176, _00AC - ScrCmd_0EA 0x105 + ScrCmd_0EA trainer_elite_four_aaron Message 0 CloseMessage CallIfUnset 214, _007A @@ -30,19 +30,19 @@ _000A: End _007A: - StartTrainerBattle 0x105, 0 + StartTrainerBattle trainer_elite_four_aaron Return _0082: - StartTrainerBattle 0x362, 0 + StartTrainerBattle trainer_elite_four_aaron_rematch Return _008A: - ScrCmd_1CD 11, 0x105, 0, 0, 0 + ScrCmd_1CD 11, trainer_elite_four_aaron, 0, 0, 0 Return _0098: - ScrCmd_1CD 11, 0x362, 0, 0, 0 + ScrCmd_1CD 11, trainer_elite_four_aaron_rematch, 0, 0, 0 Return _00A6: diff --git a/res/field/scripts/scripts_pokemon_league_bertha_room.s b/res/field/scripts/scripts_pokemon_league_bertha_room.s index 9d3ffd19d0..4b6c9226ff 100644 --- a/res/field/scripts/scripts_pokemon_league_bertha_room.s +++ b/res/field/scripts/scripts_pokemon_league_bertha_room.s @@ -11,7 +11,7 @@ _000A: LockAll FacePlayer GoToIfSet 177, _00AC - ScrCmd_0EA 0x106 + ScrCmd_0EA trainer_elite_four_bertha Message 0 CloseMessage CallIfUnset 214, _007A @@ -30,19 +30,19 @@ _000A: End _007A: - StartTrainerBattle 0x106, 0 + StartTrainerBattle trainer_elite_four_bertha Return _0082: - StartTrainerBattle 0x363, 0 + StartTrainerBattle trainer_elite_four_bertha_rematch Return _008A: - ScrCmd_1CD 11, 0x106, 0, 0, 0 + ScrCmd_1CD 11, trainer_elite_four_bertha, 0, 0, 0 Return _0098: - ScrCmd_1CD 11, 0x363, 0, 0, 0 + ScrCmd_1CD 11, trainer_elite_four_bertha_rematch, 0, 0, 0 Return _00A6: diff --git a/res/field/scripts/scripts_pokemon_league_champion_room.s b/res/field/scripts/scripts_pokemon_league_champion_room.s index 1209b11024..44cb7d3fc2 100644 --- a/res/field/scripts/scripts_pokemon_league_champion_room.s +++ b/res/field/scripts/scripts_pokemon_league_champion_room.s @@ -13,7 +13,7 @@ _000A: _000E: ApplyMovement 0xFF, _012C WaitMovement - ScrCmd_0EA 0x10B + ScrCmd_0EA trainer_champion_cynthia CallIfUnset 0x964, _00EB CallIfSet 0x964, _00F0 CloseMessage @@ -59,19 +59,19 @@ _00F0: Return _00F5: - StartTrainerBattle 0x10B, 0 + StartTrainerBattle trainer_champion_cynthia Return _00FD: - StartTrainerBattle 0x366, 0 + StartTrainerBattle trainer_champion_cynthia_rematch Return _0105: - ScrCmd_1CD 12, 0x10B, 0, 0, 0 + ScrCmd_1CD 12, trainer_champion_cynthia, 0, 0, 0 Return _0113: - ScrCmd_1CD 12, 0x366, 0, 0, 0 + ScrCmd_1CD 12, trainer_champion_cynthia_rematch, 0, 0, 0 Return _0121: diff --git a/res/field/scripts/scripts_pokemon_league_flint_room.s b/res/field/scripts/scripts_pokemon_league_flint_room.s index d2556b0b80..b84be25c97 100644 --- a/res/field/scripts/scripts_pokemon_league_flint_room.s +++ b/res/field/scripts/scripts_pokemon_league_flint_room.s @@ -11,7 +11,7 @@ _000A: LockAll FacePlayer GoToIfSet 178, _00D2 - ScrCmd_0EA 0x107 + ScrCmd_0EA trainer_elite_four_flint CallIfUnset 0x964, _00F0 CallIfSet 0x964, _0104 CloseMessage @@ -32,19 +32,19 @@ _000A: End _00A0: - StartTrainerBattle 0x107, 0 + StartTrainerBattle trainer_elite_four_flint Return _00A8: - StartTrainerBattle 0x364, 0 + StartTrainerBattle trainer_elite_four_flint_rematch Return _00B0: - ScrCmd_1CD 11, 0x107, 0, 0, 0 + ScrCmd_1CD 11, trainer_elite_four_flint, 0, 0, 0 Return _00BE: - ScrCmd_1CD 11, 0x364, 0, 0, 0 + ScrCmd_1CD 11, trainer_elite_four_flint_rematch, 0, 0, 0 Return _00CC: diff --git a/res/field/scripts/scripts_pokemon_league_lucian_room.s b/res/field/scripts/scripts_pokemon_league_lucian_room.s index f86e8eb54d..d11923c1ee 100644 --- a/res/field/scripts/scripts_pokemon_league_lucian_room.s +++ b/res/field/scripts/scripts_pokemon_league_lucian_room.s @@ -30,19 +30,19 @@ _000A: End _007A: - StartTrainerBattle 0x108, 0 + StartTrainerBattle trainer_elite_four_lucian Return _0082: - StartTrainerBattle 0x365, 0 + StartTrainerBattle trainer_elite_four_lucian_rematch Return _008A: - ScrCmd_1CD 11, 0x108, 0, 0, 0 + ScrCmd_1CD 11, trainer_elite_four_lucian, 0, 0, 0 Return _0098: - ScrCmd_1CD 11, 0x365, 0, 0, 0 + ScrCmd_1CD 11, trainer_elite_four_lucian_rematch, 0, 0, 0 Return _00A6: diff --git a/res/field/scripts/scripts_pokemon_league_north_pokecenter_1f.s b/res/field/scripts/scripts_pokemon_league_north_pokecenter_1f.s index cf646d5996..ef3697ea6a 100644 --- a/res/field/scripts/scripts_pokemon_league_north_pokecenter_1f.s +++ b/res/field/scripts/scripts_pokemon_league_north_pokecenter_1f.s @@ -154,15 +154,15 @@ _01C1: GoTo _01F7 _01F7: - StartTrainerBattle 0x1DF, 0 + StartTrainerBattle trainer_rival_pokemon_league_piplup GoTo _021B _0203: - StartTrainerBattle 0x1E0, 0 + StartTrainerBattle trainer_rival_pokemon_league_turtwig GoTo _021B _020F: - StartTrainerBattle 0x1E1, 0 + StartTrainerBattle trainer_rival_pokemon_league_chimchar GoTo _021B _021B: diff --git a/res/field/scripts/scripts_pokemon_mansion.s b/res/field/scripts/scripts_pokemon_mansion.s index 57525b2abd..8a451d7541 100644 --- a/res/field/scripts/scripts_pokemon_mansion.s +++ b/res/field/scripts/scripts_pokemon_mansion.s @@ -21,8 +21,8 @@ _0033: ScrCmd_1B7 0x404C, 5 AddVar 0x404C, 5 SetFlag 0xAB6 - ClearTrainerFlag 0x37C - ClearTrainerFlag 0x37D + ClearTrainerFlag trainer_rich_boy_liam + ClearTrainerFlag trainer_lady_celeste End _004D: @@ -81,8 +81,8 @@ _00FF: SetFlag 0x166 ScrCmd_03E 0x800C GoToIfEq 0x800C, 1, _0471 - SetTrainerFlag 0x37C - SetTrainerFlag 0x37D + SetTrainerFlag trainer_rich_boy_liam + SetTrainerFlag trainer_lady_celeste Message 5 CloseMessage ApplyMovement 2, _03FC @@ -95,7 +95,7 @@ _00FF: WaitMovement Message 15 CloseMessage - StartTrainerBattle 0x381, 0 + StartTrainerBattle trainer_maid_belinda CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0484 AddVar 0x8005, 0x404D @@ -107,7 +107,7 @@ _00FF: WaitMovement Message 17 CloseMessage - StartTrainerBattle 0x382, 0 + StartTrainerBattle trainer_maid_sophie CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0484 AddVar 0x8005, 0x404D @@ -119,7 +119,7 @@ _00FF: WaitMovement Message 19 CloseMessage - StartTrainerBattle 0x383, 0 + StartTrainerBattle trainer_maid_emily CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0484 AddVar 0x8005, 0x404D @@ -131,7 +131,7 @@ _00FF: WaitMovement Message 21 CloseMessage - StartTrainerBattle 0x384, 0 + StartTrainerBattle trainer_maid_elena CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0484 AddVar 0x8005, 0x404D @@ -151,7 +151,7 @@ _00FF: WaitMovement Message 23 CloseMessage - StartTrainerBattle 0x385, 0 + StartTrainerBattle trainer_maid_clare CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0484 AddVar 0x8005, 0x404D @@ -179,11 +179,11 @@ _00FF: CallIfEq 0x8006, 0, _03CD CallIfEq 0x8006, 1, _03D2 CloseMessage - StartTrainerBattle 0x8007, 0 + StartTrainerBattle 0x8007 CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0484 - SetTrainerFlag 0x37C - SetTrainerFlag 0x37D + SetTrainerFlag trainer_rich_boy_liam + SetTrainerFlag trainer_lady_celeste CallIfEq 0x8006, 0, _03D7 CallIfEq 0x8006, 1, _03DC CloseMessage @@ -203,14 +203,14 @@ _0396: End _03A1: - SetVar 0x8007, 0x37C + SetVar 0x8007, trainer_rich_boy_liam SetVar 0x4020, 62 ScrCmd_2F3 2, 0x8007 Message 8 Return _03B7: - SetVar 0x8007, 0x37D + SetVar 0x8007, trainer_lady_celeste SetVar 0x4020, 63 ScrCmd_2F3 2, 0x8007 Message 9 diff --git a/res/field/scripts/scripts_restaurant.s b/res/field/scripts/scripts_restaurant.s index c0ef81564a..06038dc066 100644 --- a/res/field/scripts/scripts_restaurant.s +++ b/res/field/scripts/scripts_restaurant.s @@ -57,24 +57,24 @@ _00B3: SetFlag 0x24A SetFlag 0x24B SetFlag 0x24C - ClearTrainerFlag 0x218 - ClearTrainerFlag 0x227 - ClearTrainerFlag 0x221 - ClearTrainerFlag 0x222 - ClearTrainerFlag 0x21E - ClearTrainerFlag 0x21F - ClearTrainerFlag 0x21B - ClearTrainerFlag 0x217 - ClearTrainerFlag 0x224 - ClearTrainerFlag 0x21C - ClearTrainerFlag 0x228 - ClearTrainerFlag 0x220 - ClearTrainerFlag 0x21A - ClearTrainerFlag 0x223 - ClearTrainerFlag 0x21D - ClearTrainerFlag 0x226 - ClearTrainerFlag 0x225 - ClearTrainerFlag 0x219 + ClearTrainerFlag trainer_artist_ismael + ClearTrainerFlag trainer_beauty_harley + ClearTrainerFlag trainer_rich_boy_roman + ClearTrainerFlag trainer_lady_kylie + ClearTrainerFlag trainer_gentleman_leonardo + ClearTrainerFlag trainer_socialite_rebecca + ClearTrainerFlag trainer_collector_eugene + ClearTrainerFlag trainer_aroma_lady_alison + ClearTrainerFlag trainer_school_kid_esteban + ClearTrainerFlag trainer_pokefan_meredith + ClearTrainerFlag trainer_veteran_emanuel + ClearTrainerFlag trainer_lass_blythe + ClearTrainerFlag trainer_cameraman_darryl + ClearTrainerFlag trainer_reporters_valerie + ClearTrainerFlag trainer_pi_kendrick + ClearTrainerFlag trainer_beauty_gabriella + ClearTrainerFlag trainer_scientist_emilio + ClearTrainerFlag trainer_breeder_kaylee SetVar 0x4104, 0 ScrCmd_1B7 0x4001, 1 SetVar 0x4000, 5 @@ -191,8 +191,8 @@ _031E: _0331: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x218 - GoToIfDefeated 0x218, _046C + CheckTrainerFlag trainer_artist_ismael + GoToIfDefeated trainer_artist_ismael, _046C CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _04BC SetVar 0x8008, 0x40FB @@ -228,11 +228,11 @@ _03C8: _03E7: CloseMessage - StartTrainerBattle 0x218, 0x227 + StartTrainerBattle trainer_artist_ismael, trainer_beauty_harley CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x218 - SetTrainerFlag 0x227 + SetTrainerFlag trainer_artist_ismael + SetTrainerFlag trainer_beauty_harley Call _04CF SetVar 0x8008, 0x40FB GoToIfEq 0x8008, 0, _043F @@ -313,8 +313,8 @@ _04CF: _04DB: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x227 - GoToIfDefeated 0x227, _0616 + CheckTrainerFlag trainer_beauty_harley + GoToIfDefeated trainer_beauty_harley, _0616 CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _0666 SetVar 0x8008, 0x40FB @@ -350,11 +350,11 @@ _0572: _0591: CloseMessage - StartTrainerBattle 0x218, 0x227 + StartTrainerBattle trainer_artist_ismael, trainer_beauty_harley CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x218 - SetTrainerFlag 0x227 + SetTrainerFlag trainer_artist_ismael + SetTrainerFlag trainer_beauty_harley Call _0679 SetVar 0x8008, 0x40FB GoToIfEq 0x8008, 0, _05E9 @@ -435,8 +435,8 @@ _0679: _0685: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x221 - GoToIfDefeated 0x221, _07C0 + CheckTrainerFlag trainer_rich_boy_roman + GoToIfDefeated trainer_rich_boy_roman, _07C0 CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _0810 SetVar 0x8008, 0x40FC @@ -472,11 +472,11 @@ _071C: _073B: CloseMessage - StartTrainerBattle 0x221, 0x222 + StartTrainerBattle trainer_rich_boy_roman, trainer_lady_kylie CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x221 - SetTrainerFlag 0x222 + SetTrainerFlag trainer_rich_boy_roman + SetTrainerFlag trainer_lady_kylie Call _0823 SetVar 0x8008, 0x40FC GoToIfEq 0x8008, 0, _0793 @@ -557,8 +557,8 @@ _0823: _082F: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x222 - GoToIfDefeated 0x222, _096A + CheckTrainerFlag trainer_lady_kylie + GoToIfDefeated trainer_lady_kylie, _096A CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _09BA SetVar 0x8008, 0x40FC @@ -594,11 +594,11 @@ _08C6: _08E5: CloseMessage - StartTrainerBattle 0x221, 0x222 + StartTrainerBattle trainer_rich_boy_roman, trainer_lady_kylie CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x221 - SetTrainerFlag 0x222 + SetTrainerFlag trainer_rich_boy_roman + SetTrainerFlag trainer_lady_kylie Call _09CD SetVar 0x8008, 0x40FC GoToIfEq 0x8008, 0, _093D @@ -679,8 +679,8 @@ _09CD: _09D9: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x21E - GoToIfDefeated 0x21E, _0B14 + CheckTrainerFlag trainer_gentleman_leonardo + GoToIfDefeated trainer_gentleman_leonardo, _0B14 CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _0B64 SetVar 0x8008, 0x40FD @@ -716,11 +716,11 @@ _0A70: _0A8F: CloseMessage - StartTrainerBattle 0x21E, 0x21F + StartTrainerBattle trainer_gentleman_leonardo, trainer_socialite_rebecca CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x21E - SetTrainerFlag 0x21F + SetTrainerFlag trainer_gentleman_leonardo + SetTrainerFlag trainer_socialite_rebecca Call _0B77 SetVar 0x8008, 0x40FD GoToIfEq 0x8008, 0, _0AE7 @@ -801,8 +801,8 @@ _0B77: _0B83: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x21F - GoToIfDefeated 0x21F, _0CBE + CheckTrainerFlag trainer_socialite_rebecca + GoToIfDefeated trainer_socialite_rebecca, _0CBE CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _0D0E SetVar 0x8008, 0x40FD @@ -838,11 +838,11 @@ _0C1A: _0C39: CloseMessage - StartTrainerBattle 0x21E, 0x21F + StartTrainerBattle trainer_gentleman_leonardo, trainer_socialite_rebecca CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x21E - SetTrainerFlag 0x21F + SetTrainerFlag trainer_gentleman_leonardo + SetTrainerFlag trainer_socialite_rebecca Call _0D21 SetVar 0x8008, 0x40FD GoToIfEq 0x8008, 0, _0C91 @@ -923,8 +923,8 @@ _0D21: _0D2D: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x21B - GoToIfDefeated 0x21B, _0E68 + CheckTrainerFlag trainer_collector_eugene + GoToIfDefeated trainer_collector_eugene, _0E68 CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _0EB8 SetVar 0x8008, 0x40FE @@ -960,11 +960,11 @@ _0DC4: _0DE3: CloseMessage - StartTrainerBattle 0x21B, 0x217 + StartTrainerBattle trainer_collector_eugene, trainer_aroma_lady_alison CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x21B - SetTrainerFlag 0x217 + SetTrainerFlag trainer_collector_eugene + SetTrainerFlag trainer_aroma_lady_alison Call _0ECB SetVar 0x8008, 0x40FE GoToIfEq 0x8008, 0, _0E3B @@ -1045,8 +1045,8 @@ _0ECB: _0ED7: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x217 - GoToIfDefeated 0x217, _1012 + CheckTrainerFlag trainer_aroma_lady_alison + GoToIfDefeated trainer_aroma_lady_alison, _1012 CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _1062 SetVar 0x8008, 0x40FE @@ -1082,11 +1082,11 @@ _0F6E: _0F8D: CloseMessage - StartTrainerBattle 0x21B, 0x217 + StartTrainerBattle trainer_collector_eugene, trainer_aroma_lady_alison CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x21B - SetTrainerFlag 0x217 + SetTrainerFlag trainer_collector_eugene + SetTrainerFlag trainer_aroma_lady_alison Call _1075 SetVar 0x8008, 0x40FE GoToIfEq 0x8008, 0, _0FE5 @@ -1167,8 +1167,8 @@ _1075: _1081: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x224 - GoToIfDefeated 0x224, _11BC + CheckTrainerFlag trainer_school_kid_esteban + GoToIfDefeated trainer_school_kid_esteban, _11BC CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _120C SetVar 0x8008, 0x40FF @@ -1204,11 +1204,11 @@ _1118: _1137: CloseMessage - StartTrainerBattle 0x224, 0x21C + StartTrainerBattle trainer_school_kid_esteban, trainer_pokefan_meredith CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x224 - SetTrainerFlag 0x21C + SetTrainerFlag trainer_school_kid_esteban + SetTrainerFlag trainer_pokefan_meredith Call _121F SetVar 0x8008, 0x40FF GoToIfEq 0x8008, 0, _118F @@ -1289,8 +1289,8 @@ _121F: _122B: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x21C - GoToIfDefeated 0x21C, _1366 + CheckTrainerFlag trainer_pokefan_meredith + GoToIfDefeated trainer_pokefan_meredith, _1366 CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _13B6 SetVar 0x8008, 0x40FF @@ -1326,11 +1326,11 @@ _12C2: _12E1: CloseMessage - StartTrainerBattle 0x224, 0x21C + StartTrainerBattle trainer_school_kid_esteban, trainer_pokefan_meredith CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x224 - SetTrainerFlag 0x21C + SetTrainerFlag trainer_school_kid_esteban + SetTrainerFlag trainer_pokefan_meredith Call _13C9 SetVar 0x8008, 0x40FF GoToIfEq 0x8008, 0, _1339 @@ -1411,8 +1411,8 @@ _13C9: _13D5: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x228 - GoToIfDefeated 0x228, _1510 + CheckTrainerFlag trainer_veteran_emanuel + GoToIfDefeated trainer_veteran_emanuel, _1510 CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _1560 SetVar 0x8008, 0x4100 @@ -1448,11 +1448,11 @@ _146C: _148B: CloseMessage - StartTrainerBattle 0x228, 0x220 + StartTrainerBattle trainer_veteran_emanuel, trainer_lass_blythe CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x228 - SetTrainerFlag 0x220 + SetTrainerFlag trainer_veteran_emanuel + SetTrainerFlag trainer_lass_blythe Call _1573 SetVar 0x8008, 0x4100 GoToIfEq 0x8008, 0, _14E3 @@ -1533,8 +1533,8 @@ _1573: _157F: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x220 - GoToIfDefeated 0x220, _16BA + CheckTrainerFlag trainer_lass_blythe + GoToIfDefeated trainer_lass_blythe, _16BA CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _170A SetVar 0x8008, 0x4100 @@ -1570,11 +1570,11 @@ _1616: _1635: CloseMessage - StartTrainerBattle 0x228, 0x220 + StartTrainerBattle trainer_veteran_emanuel, trainer_lass_blythe CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x228 - SetTrainerFlag 0x220 + SetTrainerFlag trainer_veteran_emanuel + SetTrainerFlag trainer_lass_blythe Call _171D SetVar 0x8008, 0x4100 GoToIfEq 0x8008, 0, _168D @@ -1655,8 +1655,8 @@ _171D: _1729: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x21A - GoToIfDefeated 0x21A, _1864 + CheckTrainerFlag trainer_cameraman_darryl + GoToIfDefeated trainer_cameraman_darryl, _1864 CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _18B4 SetVar 0x8008, 0x4101 @@ -1692,11 +1692,11 @@ _17C0: _17DF: CloseMessage - StartTrainerBattle 0x21A, 0x223 + StartTrainerBattle trainer_cameraman_darryl, trainer_reporters_valerie CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x21A - SetTrainerFlag 0x223 + SetTrainerFlag trainer_cameraman_darryl + SetTrainerFlag trainer_reporters_valerie Call _18C7 SetVar 0x8008, 0x4101 GoToIfEq 0x8008, 0, _1837 @@ -1777,8 +1777,8 @@ _18C7: _18D3: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x223 - GoToIfDefeated 0x223, _1A0E + CheckTrainerFlag trainer_reporters_valerie + GoToIfDefeated trainer_reporters_valerie, _1A0E CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _1A5E SetVar 0x8008, 0x4101 @@ -1814,11 +1814,11 @@ _196A: _1989: CloseMessage - StartTrainerBattle 0x21A, 0x223 + StartTrainerBattle trainer_cameraman_darryl, trainer_reporters_valerie CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x21A - SetTrainerFlag 0x223 + SetTrainerFlag trainer_cameraman_darryl + SetTrainerFlag trainer_reporters_valerie Call _1A71 SetVar 0x8008, 0x4101 GoToIfEq 0x8008, 0, _19E1 @@ -1899,8 +1899,8 @@ _1A71: _1A7D: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x21D - GoToIfDefeated 0x21D, _1BB8 + CheckTrainerFlag trainer_pi_kendrick + GoToIfDefeated trainer_pi_kendrick, _1BB8 CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _1C08 SetVar 0x8008, 0x4102 @@ -1936,11 +1936,11 @@ _1B14: _1B33: CloseMessage - StartTrainerBattle 0x21D, 0x226 + StartTrainerBattle trainer_pi_kendrick, trainer_beauty_gabriella CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x21D - SetTrainerFlag 0x226 + SetTrainerFlag trainer_pi_kendrick + SetTrainerFlag trainer_beauty_gabriella Call _1C1B SetVar 0x8008, 0x4102 GoToIfEq 0x8008, 0, _1B8B @@ -2021,8 +2021,8 @@ _1C1B: _1C27: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x226 - GoToIfDefeated 0x226, _1D62 + CheckTrainerFlag trainer_beauty_gabriella + GoToIfDefeated trainer_beauty_gabriella, _1D62 CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _1DB2 SetVar 0x8008, 0x4102 @@ -2058,11 +2058,11 @@ _1CBE: _1CDD: CloseMessage - StartTrainerBattle 0x21D, 0x226 + StartTrainerBattle trainer_pi_kendrick, trainer_beauty_gabriella CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x21D - SetTrainerFlag 0x226 + SetTrainerFlag trainer_pi_kendrick + SetTrainerFlag trainer_beauty_gabriella Call _1DC5 SetVar 0x8008, 0x4102 GoToIfEq 0x8008, 0, _1D35 @@ -2143,8 +2143,8 @@ _1DC5: _1DD1: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x225 - GoToIfDefeated 0x225, _1F0C + CheckTrainerFlag trainer_scientist_emilio + GoToIfDefeated trainer_scientist_emilio, _1F0C CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _1F5C SetVar 0x8008, 0x4103 @@ -2180,11 +2180,11 @@ _1E68: _1E87: CloseMessage - StartTrainerBattle 0x225, 0x219 + StartTrainerBattle trainer_scientist_emilio, trainer_breeder_kaylee CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x225 - SetTrainerFlag 0x219 + SetTrainerFlag trainer_scientist_emilio + SetTrainerFlag trainer_breeder_kaylee Call _1F6F SetVar 0x8008, 0x4103 GoToIfEq 0x8008, 0, _1EDF @@ -2265,8 +2265,8 @@ _1F6F: _1F7B: PlayFanfare SEQ_SE_CONFIRM LockAll - CheckTrainerFlag 0x219 - GoToIfDefeated 0x219, _20B6 + CheckTrainerFlag trainer_breeder_kaylee + GoToIfDefeated trainer_breeder_kaylee, _20B6 CountAliveMonsExcept 0x800C, 6 GoToIfEq 0x800C, 1, _2106 SetVar 0x8008, 0x4103 @@ -2302,11 +2302,11 @@ _2012: _2031: CloseMessage - StartTrainerBattle 0x225, 0x219 + StartTrainerBattle trainer_scientist_emilio, trainer_breeder_kaylee CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _2125 - SetTrainerFlag 0x225 - SetTrainerFlag 0x219 + SetTrainerFlag trainer_scientist_emilio + SetTrainerFlag trainer_breeder_kaylee Call _2119 SetVar 0x8008, 0x4103 GoToIfEq 0x8008, 0, _2089 diff --git a/res/field/scripts/scripts_route_203.s b/res/field/scripts/scripts_route_203.s index d02922829c..8929a8fad1 100644 --- a/res/field/scripts/scripts_route_203.s +++ b/res/field/scripts/scripts_route_203.s @@ -95,15 +95,15 @@ _0111: GoTo _0140 _0140: - StartTrainerBattle 247, 0 + StartTrainerBattle trainer_rival_route_203_piplup GoTo _0164 _014C: - StartTrainerBattle 248, 0 + StartTrainerBattle trainer_rival_route_203_turtwig GoTo _0164 _0158: - StartTrainerBattle 249, 0 + StartTrainerBattle trainer_rival_route_203_chimchar GoTo _0164 _0164: diff --git a/res/field/scripts/scripts_route_209_gate_to_hearthome_city.s b/res/field/scripts/scripts_route_209_gate_to_hearthome_city.s index e012ba52e3..cc60145f8d 100644 --- a/res/field/scripts/scripts_route_209_gate_to_hearthome_city.s +++ b/res/field/scripts/scripts_route_209_gate_to_hearthome_city.s @@ -38,17 +38,17 @@ _001D: End _00A5: - StartTrainerBattle 0x1D6, 0 + StartTrainerBattle trainer_rival_route_209_piplup GoTo _00CF End _00B3: - StartTrainerBattle 0x1D7, 0 + StartTrainerBattle trainer_rival_route_209_turtwig GoTo _00CF End _00C1: - StartTrainerBattle 0x1D8, 0 + StartTrainerBattle trainer_rival_route_209_chimchar GoTo _00CF End diff --git a/res/field/scripts/scripts_snowpoint_city_gym.s b/res/field/scripts/scripts_snowpoint_city_gym.s index ff687d4767..fd7f36fece 100644 --- a/res/field/scripts/scripts_snowpoint_city_gym.s +++ b/res/field/scripts/scripts_snowpoint_city_gym.s @@ -25,7 +25,7 @@ _0025: ScrCmd_1CD 9, 167, 0, 0, 0 Message 0 CloseMessage - StartTrainerBattle 0x13F, 0 + StartTrainerBattle trainer_leader_candice CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _010E Message 1 @@ -35,13 +35,13 @@ _0025: WaitSound GiveBadge BADGE_ID_ICICLE ScrCmd_260 23 - SetTrainerFlag 0x10C - SetTrainerFlag 0x10D - SetTrainerFlag 0x33B - SetTrainerFlag 0x10E - SetTrainerFlag 0x10F - SetTrainerFlag 0x33C - ScrCmd_1CD 10, 167, 0x13F, 0, 0 + SetTrainerFlag trainer_ace_trainer_sergio + SetTrainerFlag trainer_ace_trainer_isaiah + SetTrainerFlag trainer_ace_trainer_anton + SetTrainerFlag trainer_ace_trainer_savannah + SetTrainerFlag trainer_ace_trainer_alicia + SetTrainerFlag trainer_ace_trainer_brenna + ScrCmd_1CD 10, 167, trainer_leader_candice, 0, 0 SetFlag 0x1BF Message 3 GoTo _00B0 diff --git a/res/field/scripts/scripts_spear_pillar.s b/res/field/scripts/scripts_spear_pillar.s index b1c29e833c..229f693990 100644 --- a/res/field/scripts/scripts_spear_pillar.s +++ b/res/field/scripts/scripts_spear_pillar.s @@ -136,7 +136,7 @@ _01A6: _01CA: Message 0 CloseMessage - StartTrainerBattle 0x209, 0x20F + StartTrainerBattle trainer_galactic_grunt_spear_pillar_1, trainer_galactic_grunt_spear_pillar_2 CheckWonBattle 0x800C Return diff --git a/res/field/scripts/scripts_stark_mountain_room_1.s b/res/field/scripts/scripts_stark_mountain_room_1.s index 2401a72694..2bb4d8c8ac 100644 --- a/res/field/scripts/scripts_stark_mountain_room_1.s +++ b/res/field/scripts/scripts_stark_mountain_room_1.s @@ -19,7 +19,7 @@ _0014: CloseMessage ApplyMovement 0, _0160 WaitMovement - StartTrainerBattle 0x39E, 0 + StartTrainerBattle trainer_commander_mars_stark_mountain CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0150 Message 1 @@ -32,7 +32,7 @@ _0014: CloseMessage ApplyMovement 4, _01CC WaitMovement - StartTrainerBattle 0x39F, 0 + StartTrainerBattle trainer_commander_jupiter_stark_mountain CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0150 Message 3 diff --git a/res/field/scripts/scripts_sunyshore_city_gym_room_3.s b/res/field/scripts/scripts_sunyshore_city_gym_room_3.s index f733ed8d22..9e43d56d2d 100644 --- a/res/field/scripts/scripts_sunyshore_city_gym_room_3.s +++ b/res/field/scripts/scripts_sunyshore_city_gym_room_3.s @@ -30,7 +30,7 @@ _0027: ScrCmd_1CD 9, 156, 0, 0, 0 Message 0 CloseMessage - StartTrainerBattle 0x140, 0 + StartTrainerBattle trainer_leader_volkner CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _011A Message 1 @@ -40,16 +40,17 @@ _0027: WaitSound GiveBadge BADGE_ID_BEACON ScrCmd_260 23 - SetTrainerFlag 0x119 - SetTrainerFlag 0x11D - SetTrainerFlag 0x12D - SetTrainerFlag 0x12E - SetTrainerFlag 0x12F - SetTrainerFlag 0x14B - SetTrainerFlag 0x155 - SetTrainerFlag 0x158 + SetTrainerFlag trainer_ace_trainer_zachery + SetTrainerFlag trainer_ace_trainer_destiny + SetTrainerFlag trainer_guitarist_jerry + SetTrainerFlag trainer_guitarist_preston + SetTrainerFlag trainer_guitarist_lonnie + SetTrainerFlag trainer_poke_kid_meghan + SetTrainerFlag trainer_school_kid_forrest + SetTrainerFlag trainer_school_kid_tiera SetVar 0x407E, 2 - ScrCmd_1CD 10, 156, 246, 0, 0 + // BUG: trainer_leader_roark should be trainer_leader_volkner + ScrCmd_1CD 10, 156, trainer_leader_roark, 0, 0 Message 3 GoTo _00BC diff --git a/res/field/scripts/scripts_survival_area.s b/res/field/scripts/scripts_survival_area.s index 3822eaa7ba..13f1814850 100644 --- a/res/field/scripts/scripts_survival_area.s +++ b/res/field/scripts/scripts_survival_area.s @@ -183,12 +183,12 @@ _01FA: End _021A: - StartTrainerBattle 0x345, 0 + StartTrainerBattle trainer_rival_survival_area_1_piplup GoTo _02AE End _0228: - StartTrainerBattle 0x367, 0 + StartTrainerBattle trainer_rival_survival_area_2_piplup GoTo _02AE End @@ -199,12 +199,12 @@ _0236: End _0256: - StartTrainerBattle 0x346, 0 + StartTrainerBattle trainer_rival_survival_area_1_turtwig GoTo _02AE End _0264: - StartTrainerBattle 0x368, 0 + StartTrainerBattle trainer_rival_survival_area_2_turtwig GoTo _02AE End @@ -215,12 +215,12 @@ _0272: End _0292: - StartTrainerBattle 0x347, 0 + StartTrainerBattle trainer_rival_survival_area_1_chimchar GoTo _02AE End _02A0: - StartTrainerBattle 0x369, 0 + StartTrainerBattle trainer_rival_survival_area_2_chimchar GoTo _02AE End diff --git a/res/field/scripts/scripts_team_galactic_eterna_building_4f.s b/res/field/scripts/scripts_team_galactic_eterna_building_4f.s index b7138e9bfa..576a9c845f 100644 --- a/res/field/scripts/scripts_team_galactic_eterna_building_4f.s +++ b/res/field/scripts/scripts_team_galactic_eterna_building_4f.s @@ -27,7 +27,7 @@ _0022: WaitMovement Message 0 CloseMessage - StartTrainerBattle 0x196, 0 + StartTrainerBattle trainer_commander_jupiter_team_galactic_eterna_building CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0135 Message 1 diff --git a/res/field/scripts/scripts_trainers_school.s b/res/field/scripts/scripts_trainers_school.s index 411b238756..a3babcfea0 100644 --- a/res/field/scripts/scripts_trainers_school.s +++ b/res/field/scripts/scripts_trainers_school.s @@ -175,17 +175,17 @@ _01E7: End _0212: - StartTrainerBattle 0x156, 0 + StartTrainerBattle trainer_school_kid_harrison GoTo _023C End _0220: - StartTrainerBattle 0x156, 0 + StartTrainerBattle trainer_school_kid_harrison GoTo _023C End _022E: - StartTrainerBattle 0x156, 0 + StartTrainerBattle trainer_school_kid_harrison GoTo _023C End @@ -269,17 +269,17 @@ _031A: End _0345: - StartTrainerBattle 0x159, 0 + StartTrainerBattle trainer_school_kid_christine GoTo _036F End _0353: - StartTrainerBattle 0x159, 0 + StartTrainerBattle trainer_school_kid_christine GoTo _036F End _0361: - StartTrainerBattle 0x159, 0 + StartTrainerBattle trainer_school_kid_christine GoTo _036F End diff --git a/res/field/scripts/scripts_unk_0400.s b/res/field/scripts/scripts_unk_0400.s index 17c4357656..495c82081e 100644 --- a/res/field/scripts/scripts_unk_0400.s +++ b/res/field/scripts/scripts_unk_0400.s @@ -251,7 +251,7 @@ _0631: _0687: CloseMessage - StartTrainerBattle 0x8005, 0 + StartTrainerBattle 0x8005 CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0822 GoTo _06A8 diff --git a/res/field/scripts/scripts_unk_1114.s b/res/field/scripts/scripts_unk_1114.s index 258b13e1a4..12b632d6db 100644 --- a/res/field/scripts/scripts_unk_1114.s +++ b/res/field/scripts/scripts_unk_1114.s @@ -962,7 +962,7 @@ _0F01: _0F1D: CloseMessage ScrCmd_20B - StartTrainerBattle 0x8004, 0 + StartTrainerBattle 0x8004 CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0FC5 SetTrainerFlag 0x8004 @@ -1067,7 +1067,7 @@ _1083: OpenMessage ScrCmd_0E6 0x8004, 0 CloseMessage - StartTrainerBattle 0x8004, 0 + StartTrainerBattle 0x8004 CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0FC5 ScrCmd_0B9 0, 0x800C diff --git a/res/field/scripts/scripts_valley_windworks_building.s b/res/field/scripts/scripts_valley_windworks_building.s index afa501af29..d403b658d3 100644 --- a/res/field/scripts/scripts_valley_windworks_building.s +++ b/res/field/scripts/scripts_valley_windworks_building.s @@ -88,7 +88,7 @@ _00F5: _0107: Message 2 CloseMessage - StartTrainerBattle 0x127, 0 + StartTrainerBattle trainer_commander_mars_valley_windworks CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _02B9 Message 3 diff --git a/res/field/scripts/scripts_valley_windworks_outside.s b/res/field/scripts/scripts_valley_windworks_outside.s index a69de5c7fd..9193c42de7 100644 --- a/res/field/scripts/scripts_valley_windworks_outside.s +++ b/res/field/scripts/scripts_valley_windworks_outside.s @@ -63,7 +63,7 @@ _00CF: FacePlayer Message 0 CloseMessage - StartTrainerBattle 0x34B, 0 + StartTrainerBattle trainer_galactic_grunt_valley_windworks_1 CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0133 Message 1 diff --git a/res/field/scripts/scripts_valor_cavern.s b/res/field/scripts/scripts_valor_cavern.s index 54cee7d097..ce38ea5b4c 100644 --- a/res/field/scripts/scripts_valor_cavern.s +++ b/res/field/scripts/scripts_valor_cavern.s @@ -76,7 +76,7 @@ _00D3: WaitTime 30, 0x800C Message 1 CloseMessage - StartTrainerBattle 0x198, 0 + StartTrainerBattle trainer_commander_saturn_valor_cavern CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0144 Message 2 diff --git a/res/field/scripts/scripts_valor_lakefront.s b/res/field/scripts/scripts_valor_lakefront.s index 508ff510da..3309d355b5 100644 --- a/res/field/scripts/scripts_valor_lakefront.s +++ b/res/field/scripts/scripts_valor_lakefront.s @@ -84,7 +84,7 @@ _013A: FacePlayer Message 2 CloseMessage - StartTrainerBattle 0x34F, 0 + StartTrainerBattle trainer_galactic_grunt_valor_lakefront CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _01D9 Message 3 diff --git a/res/field/scripts/scripts_veilstone_city_gym.s b/res/field/scripts/scripts_veilstone_city_gym.s index f647163aa8..7db029f179 100644 --- a/res/field/scripts/scripts_veilstone_city_gym.s +++ b/res/field/scripts/scripts_veilstone_city_gym.s @@ -24,7 +24,7 @@ _0022: ScrCmd_1CD 9, 133, 0, 0, 0 Message 0 CloseMessage - StartTrainerBattle 0x13D, 0 + StartTrainerBattle trainer_leader_maylene CheckWonBattle 0x800C GoToIfEq 0x800C, 0, _0118 Message 1 @@ -34,11 +34,11 @@ _0022: WaitSound GiveBadge BADGE_ID_COBBLE ScrCmd_260 23 - SetTrainerFlag 0x135 - SetTrainerFlag 0x136 - SetTrainerFlag 0x137 - SetTrainerFlag 0x138 - ScrCmd_1CD 10, 133, 0x13D, 0, 0 + SetTrainerFlag trainer_black_belt_colby + SetTrainerFlag trainer_black_belt_darren + SetTrainerFlag trainer_black_belt_rafael + SetTrainerFlag trainer_black_belt_jeffery + ScrCmd_1CD 10, 133, trainer_leader_maylene, 0, 0 SetFlag 0x1A3 ClearFlag 0x1A8 SetVar 0x407D, 1 diff --git a/res/meson.build b/res/meson.build index 15948ab8ae..52ceb85a89 100644 --- a/res/meson.build +++ b/res/meson.build @@ -60,6 +60,8 @@ lz_gen = generator(nitrogfx_exe, output: '@PLAINNAME@.lz', ) +subdir('trainers') + subdir('battle') subdir('field') subdir('fonts') @@ -67,4 +69,3 @@ subdir('graphics') subdir('items') subdir('pokemon') subdir('sound') -subdir('trainers') From e7e7f4449775466a9a10790673abf0ecdcb8b7f5 Mon Sep 17 00:00:00 2001 From: Viperio19 Date: Tue, 19 Nov 2024 11:15:16 +0100 Subject: [PATCH 10/11] Improving on previous commits (concise declarations, removing unnecessary return; and scoping, more renaming) --- include/constants/field_poison.h | 8 ++++ include/field_overworld_state.h | 44 +++++++++---------- include/unk_020528D0.h | 4 +- include/unk_02054884.h | 8 ++-- include/unk_020553DC.h | 4 +- src/comm_player_manager.c | 6 +-- src/field_overworld_state.c | 4 +- src/overlay005/field_control.c | 7 +-- src/overlay005/fieldmap.c | 35 +++++++-------- src/overlay005/vs_seeker.c | 18 ++++---- src/overlay023/ov23_022521F0.c | 12 +++--- src/unk_0204B830.c | 3 +- src/unk_0204CFFC.c | 4 +- src/unk_020528D0.c | 39 ++++++++--------- src/unk_02054884.c | 60 +++++++++++++------------- src/unk_020553DC.c | 46 ++++++-------------- src/unk_020683F4.c | 49 +++++++++------------ src/unk_0206AFE0.c | 73 +++++++++----------------------- src/unk_0206B70C.c | 10 ++--- 19 files changed, 186 insertions(+), 248 deletions(-) create mode 100644 include/constants/field_poison.h diff --git a/include/constants/field_poison.h b/include/constants/field_poison.h new file mode 100644 index 0000000000..e2886ded58 --- /dev/null +++ b/include/constants/field_poison.h @@ -0,0 +1,8 @@ +#ifndef POKEPLATINUM_CONSTANTS_FIELD_POISON_H +#define POKEPLATINUM_CONSTANTS_FIELD_POISON_H + +#define FLDPSN_NONE 0 +#define FLDPSN_POISONED 1 +#define FLDPSN_FAINTED 2 + +#endif // POKEPLATINUM_CONSTANTS_FIELD_POISON_H diff --git a/include/field_overworld_state.h b/include/field_overworld_state.h index 19533ee191..c9844d0d23 100644 --- a/include/field_overworld_state.h +++ b/include/field_overworld_state.h @@ -13,28 +13,28 @@ int FieldOverworldState_Size(void); int FieldOverworldSave_Size(void); -void FieldOverworldSave_Init(FieldOverworldSave *param0); -void FieldOverworldState_Init(FieldOverworldState *param0); -Location *FieldOverworldState_GetPlayerLocation(FieldOverworldState *param0); -Location *FieldOverworldState_GetEntranceLocation(FieldOverworldState *param0); -Location *FieldOverworldState_GetPrevLocation(FieldOverworldState *param0); -Location *FieldOverworldState_GetExitLocation(FieldOverworldState *param0); -Location *FieldOverworldState_GetSpecialLocation(FieldOverworldState *param0); -void FieldOverworldState_SetSpecialLocation(FieldOverworldState *param0, Location *param1); -u16 *FieldOverworldState_GetSpecialBGM(FieldOverworldState *param0); -u16 FieldOverworldState_GetWeather(const FieldOverworldState *param0); -void FieldOverworldState_SetWeather(FieldOverworldState *param0, u16 param1); -u16 FieldOverworldState_GetWarpId(const FieldOverworldState *param0); -void FieldOverworldState_SetWarpId(FieldOverworldState *param0, u16 param1); -UnkStruct_020556C4 *sub_0203A76C(FieldOverworldState *param0); -int FieldOverworldState_GetCameraType(const FieldOverworldState *param0); -void FieldOverworldState_SetCameraType(FieldOverworldState *param0, int param1); -PlayerData *FieldOverworldState_GetPlayerData(FieldOverworldState *param0); -u16 *FieldOverworldState_GetSafariBallCount(FieldOverworldState *param0); -u16 *FieldOverworldState_GetSafariStepCount(FieldOverworldState *param0); -u16 *FieldOverworldState_GetPoisonStepCount(FieldOverworldState *param0); -FieldOverworldState *SaveData_GetFieldOverworldState(SaveData *param0); -FieldOverworldSave *SaveData_GetFieldOverworldSave(SaveData *param0); +void FieldOverworldSave_Init(FieldOverworldSave *fieldSave); +void FieldOverworldState_Init(FieldOverworldState *fieldState); +Location *FieldOverworldState_GetPlayerLocation(FieldOverworldState *fieldState); +Location *FieldOverworldState_GetEntranceLocation(FieldOverworldState *fieldState); +Location *FieldOverworldState_GetPrevLocation(FieldOverworldState *fieldState); +Location *FieldOverworldState_GetExitLocation(FieldOverworldState *fieldState); +Location *FieldOverworldState_GetSpecialLocation(FieldOverworldState *fieldState); +void FieldOverworldState_SetSpecialLocation(FieldOverworldState *fieldState, Location *location); +u16 *FieldOverworldState_GetSpecialBGM(FieldOverworldState *fieldState); +u16 FieldOverworldState_GetWeather(const FieldOverworldState *fieldState); +void FieldOverworldState_SetWeather(FieldOverworldState *fieldState, u16 weather); +u16 FieldOverworldState_GetWarpId(const FieldOverworldState *fieldState); +void FieldOverworldState_SetWarpId(FieldOverworldState *fieldState, u16 warpId); +UnkStruct_020556C4 *sub_0203A76C(FieldOverworldState *fieldState); +int FieldOverworldState_GetCameraType(const FieldOverworldState *fieldState); +void FieldOverworldState_SetCameraType(FieldOverworldState *fieldState, int type); +PlayerData *FieldOverworldState_GetPlayerData(FieldOverworldState *fieldState); +u16 *FieldOverworldState_GetSafariBallCount(FieldOverworldState *fieldState); +u16 *FieldOverworldState_GetSafariStepCount(FieldOverworldState *fieldState); +u16 *FieldOverworldState_GetPoisonStepCount(FieldOverworldState *fieldState); +FieldOverworldState *SaveData_GetFieldOverworldState(SaveData *saveData); +FieldOverworldSave *SaveData_GetFieldOverworldSave(SaveData *saveData); void FieldSystem_SaveObjects(FieldSystem *fieldSystem); void FieldSystem_LoadObjects(FieldSystem *fieldSystem); diff --git a/include/unk_020528D0.h b/include/unk_020528D0.h index 4f6b25dd15..df61e031f0 100644 --- a/include/unk_020528D0.h +++ b/include/unk_020528D0.h @@ -3,7 +3,7 @@ #include "field_task.h" -BOOL sub_02052B2C(FieldTask *param0); -void sub_02052C5C(FieldTask *param0); +BOOL sub_02052B2C(FieldTask *taskMan); +void sub_02052C5C(FieldTask *taskMan); #endif // POKEPLATINUM_UNK_020528D0_H diff --git a/include/unk_02054884.h b/include/unk_02054884.h index aa5768c246..af262b5aaf 100644 --- a/include/unk_02054884.h +++ b/include/unk_02054884.h @@ -9,16 +9,16 @@ #define PARTY_SLOT_NONE 0xFF BOOL Pokemon_CanBattle(Pokemon *mon); -BOOL sub_020548B0(int param0, SaveData *param1, u16 param2, u8 param3, u16 param4, int param5, int param6); -BOOL sub_02054930(int param0, SaveData *param1, u16 param2, u8 param3, int param4, int param5); -void sub_02054988(Party *param0, int param1, int param2, u16 param3); +BOOL sub_020548B0(int heapID, SaveData *saveData, u16 param2, u8 param3, u16 param4, int param5, int param6); +BOOL sub_02054930(int unused, SaveData *saveData, u16 param2, u8 param3, int param4, int param5); +void sub_02054988(Party *party, int param1, int param2, u16 param3); int Party_HasMonWithMove(Party *party, u16 moveID); int Party_AliveMonsCount(const Party *party); Pokemon *Party_FindFirstEligibleBattler(const Party *party); Pokemon *Party_FindFirstHatchedMon(const Party *party); BOOL Party_HasTwoAliveMons(const Party *party); void Party_GiveChampionRibbons(Party *party); -int Pokemon_DoPoisonDamage(Party *param0, u16 param1); +int Pokemon_DoPoisonDamage(Party *party, u16 mapLabelTextID); BOOL Pokemon_TrySurvivePoison(Pokemon *mon); #endif // POKEPLATINUM_UNK_02054884_H diff --git a/include/unk_020553DC.h b/include/unk_020553DC.h index 2f43d9aa17..5d1f0d7a23 100644 --- a/include/unk_020553DC.h +++ b/include/unk_020553DC.h @@ -4,11 +4,11 @@ #include "field/field_system_decl.h" void sub_020553DC(void); -void Sound_SetSpecialBGM(FieldSystem *fieldSystem, u16 param1); +void Sound_SetSpecialBGM(FieldSystem *fieldSystem, u16 sdatID); u16 Sound_GetSpecialBGM(FieldSystem *fieldSystem); void Sound_ClearSpecialBGM(FieldSystem *fieldSystem); u16 sub_02055428(FieldSystem *fieldSystem, int param1); -u16 sub_020554A4(FieldSystem *fieldSystem, int param1); +u16 sub_020554A4(FieldSystem *fieldSystem, int headerID); BOOL sub_02055554(FieldSystem *fieldSystem, u16 param1, int param2); u16 sub_0205560C(int param0); void Sound_TryFadeInBGM(FieldSystem *fieldSystem, int param1); diff --git a/src/comm_player_manager.c b/src/comm_player_manager.c index e149394c87..9e4f6379f0 100644 --- a/src/comm_player_manager.c +++ b/src/comm_player_manager.c @@ -631,13 +631,13 @@ static int CommPlayer_Direction(u16 unused, u16 keys) BOOL CommPlayer_CheckNPCCollision(int x, int z) { int npcCnt, i; - const ObjectEvent *npcList; + const ObjectEvent *objEventList; npcCnt = MapHeaderData_GetNumObjectEvents(sCommPlayerManager->fieldSystem); - npcList = MapHeaderData_GetObjectEvents(sCommPlayerManager->fieldSystem); + objEventList = MapHeaderData_GetObjectEvents(sCommPlayerManager->fieldSystem); for (i = 0; i < npcCnt; i++) { - if ((npcList[i].x == x) && (npcList[i].z == z)) { + if ((objEventList[i].x == x) && (objEventList[i].z == z)) { return 1; } } diff --git a/src/field_overworld_state.c b/src/field_overworld_state.c index 47c48e981d..2c808f524b 100644 --- a/src/field_overworld_state.c +++ b/src/field_overworld_state.c @@ -49,9 +49,9 @@ int FieldOverworldSave_Size(void) return sizeof(FieldOverworldSave); } -void FieldOverworldSave_Init(FieldOverworldSave *fieldState) +void FieldOverworldSave_Init(FieldOverworldSave *fieldSave) { - MI_CpuClear32(fieldState, sizeof(FieldOverworldSave)); + MI_CpuClear32(fieldSave, sizeof(FieldOverworldSave)); } void FieldOverworldState_Init(FieldOverworldState *fieldState) diff --git a/src/overlay005/field_control.c b/src/overlay005/field_control.c index d5e1728c96..5a6d7400c2 100644 --- a/src/overlay005/field_control.c +++ b/src/overlay005/field_control.c @@ -3,6 +3,7 @@ #include #include +#include "constants/field_poison.h" #include "constants/player_avatar.h" #include "consts/game_records.h" #include "consts/sdat.h" @@ -906,12 +907,12 @@ static BOOL Field_UpdatePoison(FieldSystem *fieldSystem) } switch (Pokemon_DoPoisonDamage(party, MapHeader_GetMapLabelTextID(fieldSystem->location->mapId))) { - case 0: + case FLDPSN_NONE: return FALSE; - case 1: + case FLDPSN_POISONED: Field_DoPoisonEffect(fieldSystem->unk_04->unk_20); return FALSE; - case 2: + case FLDPSN_FAINTED: Field_DoPoisonEffect(fieldSystem->unk_04->unk_20); ScriptManager_Set(fieldSystem, 2003, NULL); return TRUE; diff --git a/src/overlay005/fieldmap.c b/src/overlay005/fieldmap.c index 4a1d5c4c4a..6096bb6b07 100644 --- a/src/overlay005/fieldmap.c +++ b/src/overlay005/fieldmap.c @@ -418,29 +418,26 @@ static BOOL FieldMap_ChangeZone(FieldSystem *fieldSystem) } fieldState = SaveData_GetFieldOverworldState(fieldSystem->saveData); - { - fieldSystem->location->mapId = v0; - MapHeaderData_Load(fieldSystem, v0); - FieldMapChange_UpdateGameData(fieldSystem, 1); - } + fieldSystem->location->mapId = v0; + + MapHeaderData_Load(fieldSystem, v0); + FieldMapChange_UpdateGameData(fieldSystem, 1); { - int npcCount = MapHeaderData_GetNumObjectEvents(fieldSystem); - const ObjectEvent *npcList = MapHeaderData_GetObjectEvents(fieldSystem); + int objEventCount = MapHeaderData_GetNumObjectEvents(fieldSystem); + const ObjectEvent *objEventList = MapHeaderData_GetObjectEvents(fieldSystem); - sub_0206184C(fieldSystem->mapObjMan, mapId, v0, npcCount, npcList); + sub_0206184C(fieldSystem->mapObjMan, mapId, v0, objEventCount, objEventList); } - { - RadarChain_Clear(fieldSystem->chain); - sub_02055554(fieldSystem, sub_02055428(fieldSystem, fieldSystem->location->mapId), 1); - sub_0203A418(fieldSystem); + RadarChain_Clear(fieldSystem->chain); + sub_02055554(fieldSystem, sub_02055428(fieldSystem, fieldSystem->location->mapId), 1); + sub_0203A418(fieldSystem); - if (fieldSystem->unk_04->unk_0C != NULL) { - ov5_021D5F7C( - fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(fieldState)); - } + if (fieldSystem->unk_04->unk_0C != NULL) { + ov5_021D5F7C( + fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(fieldState)); } { @@ -479,10 +476,10 @@ void ov5_021D12D0(FieldSystem *fieldSystem, u32 param1) } { - int npcCount = MapHeaderData_GetNumObjectEvents(fieldSystem); - const ObjectEvent *npcList = MapHeaderData_GetObjectEvents(fieldSystem); + int objEventCount = MapHeaderData_GetNumObjectEvents(fieldSystem); + const ObjectEvent *objEventList = MapHeaderData_GetObjectEvents(fieldSystem); - sub_0206184C(fieldSystem->mapObjMan, mapId, param1, npcCount, npcList); + sub_0206184C(fieldSystem->mapObjMan, mapId, param1, objEventCount, objEventList); } { diff --git a/src/overlay005/vs_seeker.c b/src/overlay005/vs_seeker.c index e9ddd239b8..8e886fd227 100644 --- a/src/overlay005/vs_seeker.c +++ b/src/overlay005/vs_seeker.c @@ -500,11 +500,11 @@ static void VsSeekerSystem_CollectViableNpcs(VsSeekerSystem *vsSeeker) int trainerX, trainerZ; int numVisibleTrainers; int xMin, xMax, zMin, zMax; - u32 npcCount = MapHeaderData_GetNumObjectEvents(vsSeeker->fieldSystem); + u32 objEventCount = MapHeaderData_GetNumObjectEvents(vsSeeker->fieldSystem); numVisibleTrainers = 0; - for (int i = 0; i < npcCount; i++) { + for (int i = 0; i < objEventCount; i++) { vsSeeker->trainers[i] = NULL; } @@ -523,7 +523,7 @@ static void VsSeekerSystem_CollectViableNpcs(VsSeekerSystem *vsSeeker) zMin = 0; } - for (int i = 0; i < npcCount; i++) { + for (int i = 0; i < objEventCount; i++) { MapObject *mapObj = MapObjMan_LocalMapObjByIndex(vsSeeker->fieldSystem->mapObjMan, i); if (mapObj == NULL) { @@ -598,9 +598,9 @@ BOOL VsSeeker_UpdateStepCount(FieldSystem *fieldSystem) static void VsSeeker_ClearRematchMoveCode(FieldSystem *fieldSystem) { - u32 npcCount = MapHeaderData_GetNumObjectEvents(fieldSystem); + u32 objEventCount = MapHeaderData_GetNumObjectEvents(fieldSystem); - for (int i = 0; i < npcCount; i++) { + for (int i = 0; i < objEventCount; i++) { MapObject *mapObj = MapObjMan_LocalMapObjByIndex(fieldSystem->mapObjMan, i); if (mapObj == NULL) { @@ -812,10 +812,10 @@ void VsSeeker_SetMoveCodeForFacingDirection(FieldSystem *fieldSystem, MapObject static BOOL VsSeeker_WaitForNpcsToPause(FieldSystem *fieldSystem) { - u32 npcCount = MapHeaderData_GetNumObjectEvents(fieldSystem); + u32 objEventCount = MapHeaderData_GetNumObjectEvents(fieldSystem); BOOL anyMoving = FALSE; - for (int i = 0; i < npcCount; i++) { + for (int i = 0; i < objEventCount; i++) { MapObject *mapObj = MapObjMan_LocalMapObjByIndex(fieldSystem->mapObjMan, i); if (mapObj == NULL) { @@ -836,7 +836,7 @@ static BOOL VsSeeker_WaitForNpcsToPause(FieldSystem *fieldSystem) static MapObject *VsSeeker_GetSecondDoubleBattleTrainer(FieldSystem *fieldSystem, MapObject *trainerObj, enum VsSeeker2v2TrainerSearchMode mode) { u32 secondTrainerEventID, secondTrainerID; - u32 npcCount = MapHeaderData_GetNumObjectEvents(fieldSystem); + u32 objEventCount = MapHeaderData_GetNumObjectEvents(fieldSystem); u16 eventID = MapObject_GetEventID(trainerObj); u16 trainerID = Script_GetTrainerID(eventID); @@ -844,7 +844,7 @@ static MapObject *VsSeeker_GetSecondDoubleBattleTrainer(FieldSystem *fieldSystem return NULL; } - for (u32 i = 0; i < npcCount; i++) { + for (u32 i = 0; i < objEventCount; i++) { MapObject *mapObj = MapObjMan_LocalMapObjByIndex(fieldSystem->mapObjMan, i); if (mapObj == NULL) { diff --git a/src/overlay023/ov23_022521F0.c b/src/overlay023/ov23_022521F0.c index 8361f8acc3..525f694aef 100644 --- a/src/overlay023/ov23_022521F0.c +++ b/src/overlay023/ov23_022521F0.c @@ -937,15 +937,15 @@ void ov23_022534A0(FieldSystem *fieldSystem) ov23_022431EC(v4, v4->unk_04, ov23_02251270); { - int npcCount, i; - const ObjectEvent *npcList; + int objEventCount, i; + const ObjectEvent *objEventList; MapObject *mapObj; - npcCount = MapHeaderData_GetNumObjectEvents(v4->fieldSystem); - npcList = MapHeaderData_GetObjectEvents(v4->fieldSystem); + objEventCount = MapHeaderData_GetNumObjectEvents(v4->fieldSystem); + objEventList = MapHeaderData_GetObjectEvents(v4->fieldSystem); - for (i = 0; i < npcCount; i++) { - if ((npcList[i].x == v1) && (npcList[i].z == v2)) { + for (i = 0; i < objEventCount; i++) { + if (objEventList[i].x == v1 && objEventList[i].z == v2) { mapObj = MapObjMan_LocalMapObjByIndex(v4->fieldSystem->mapObjMan, i); MapObject_SetDir(mapObj, v3); } diff --git a/src/unk_0204B830.c b/src/unk_0204B830.c index cd5a5b5d9c..d082fef87b 100644 --- a/src/unk_0204B830.c +++ b/src/unk_0204B830.c @@ -3,6 +3,7 @@ #include #include +#include "constants/heap.h" #include "constants/species.h" #include "struct_decls/struct_party_decl.h" @@ -155,7 +156,7 @@ static BOOL sub_0204BA50(FieldSystem *fieldSystem, void *param1) static void sub_0204BA68(FieldSystem *fieldSystem, void *param1) { - sub_02054930(32, fieldSystem->saveData, 490, 1, 2, 1); + sub_02054930(HEAP_ID_FIELD_TASK, fieldSystem->saveData, 490, 1, 2, 1); } static void sub_0204BA88(UnkStruct_0204B830 *param0, u16 *param1, u16 *param2) diff --git a/src/unk_0204CFFC.c b/src/unk_0204CFFC.c index 145b3e6126..f5e859a434 100644 --- a/src/unk_0204CFFC.c +++ b/src/unk_0204CFFC.c @@ -3,6 +3,8 @@ #include #include +#include "constants/heap.h" + #include "struct_decls/struct_020797DC_decl.h" #include "struct_decls/struct_party_decl.h" @@ -39,7 +41,7 @@ BOOL ScrCmd_096(ScriptContext *param0) u16 *v7 = ScriptContext_GetVarPointer(param0); v2 = Party_GetFromSavedata(fieldSystem->saveData); - *v7 = sub_020548B0(11, fieldSystem->saveData, v4, v5, v6, v0, v1); + *v7 = sub_020548B0(HEAP_ID_FIELDMAP, fieldSystem->saveData, v4, v5, v6, v0, v1); return 0; } diff --git a/src/unk_020528D0.c b/src/unk_020528D0.c index 8e537e0073..7f9096f696 100644 --- a/src/unk_020528D0.c +++ b/src/unk_020528D0.c @@ -45,8 +45,8 @@ typedef struct { StringTemplate *unk_20; } UnkStruct_02052AA4; -static void sub_02052914(FieldSystem *fieldSystem, FieldTask *param1); -static BOOL sub_020529C4(FieldTask *param0); +static void sub_02052914(FieldSystem *fieldSystem, FieldTask *taskMan); +static BOOL sub_020529C4(FieldTask *taskMan); static void sub_02052AA4(UnkStruct_02052AA4 *param0, u16 param1, u8 param2, u8 param3); static const WindowTemplate Unk_020EC2F0 = { @@ -101,11 +101,9 @@ static void sub_020528D0(BgConfig *param0) Graphics_LoadPalette(14, 6, 0, 13 * 0x20, 0x20, 11); } -static void sub_02052914(FieldSystem *fieldSystem, FieldTask *param1) +static void sub_02052914(FieldSystem *fieldSystem, FieldTask *taskMan) { - UnkStruct_02052AA4 *v0; - - v0 = Heap_AllocFromHeap(11, sizeof(UnkStruct_02052AA4)); + UnkStruct_02052AA4 *v0 = Heap_AllocFromHeap(11, sizeof(UnkStruct_02052AA4)); if (v0 == NULL) { GF_ASSERT(FALSE); @@ -132,14 +130,14 @@ static void sub_02052914(FieldSystem *fieldSystem, FieldTask *param1) } Window_CopyToVRAM(&v0->unk_0C); - FieldTask_InitCall(param1, sub_020529C4, v0); + FieldTask_InitCall(taskMan, sub_020529C4, v0); return; } -static BOOL sub_020529C4(FieldTask *param0) +static BOOL sub_020529C4(FieldTask *taskMan) { - UnkStruct_02052AA4 *v0 = FieldTask_GetEnv(param0); + UnkStruct_02052AA4 *v0 = FieldTask_GetEnv(taskMan); switch (v0->unk_00) { case 0: @@ -199,13 +197,10 @@ static void sub_02052AA4(UnkStruct_02052AA4 *param0, u16 param1, u8 param2, u8 p return; } -BOOL sub_02052B2C(FieldTask *param0) +BOOL sub_02052B2C(FieldTask *taskMan) { - FieldSystem *fieldSystem; - int *state; - - fieldSystem = FieldTask_GetFieldSystem(param0); - state = FieldTask_GetState(param0); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + int *state = FieldTask_GetState(taskMan); switch (*state) { case 0: { @@ -221,7 +216,7 @@ BOOL sub_02052B2C(FieldTask *param0) sub_0203A824(warpId, &location); sub_0203A7F0(warpId, FieldOverworldState_GetExitLocation(fieldState)); - FieldTask_ChangeMapByLocation(param0, &location); + FieldTask_ChangeMapByLocation(taskMan, &location); sub_020705B4(fieldSystem); } (*state)++; @@ -239,11 +234,11 @@ BOOL sub_02052B2C(FieldTask *param0) case 3: sub_0200AB4C(-16, ((GX_BLEND_PLANEMASK_BG0 | GX_BLEND_PLANEMASK_BG1 | GX_BLEND_PLANEMASK_BG2 | GX_BLEND_PLANEMASK_BG3 | GX_BLEND_PLANEMASK_OBJ | GX_BLEND_PLANEMASK_BD) ^ GX_BLEND_PLANEMASK_BG3), 1); sub_0200AB4C(-16, (GX_BLEND_PLANEMASK_BG0 | GX_BLEND_PLANEMASK_BG1 | GX_BLEND_PLANEMASK_BG2 | GX_BLEND_PLANEMASK_BG3 | GX_BLEND_PLANEMASK_OBJ | GX_BLEND_PLANEMASK_BD), 2); - sub_02052914(fieldSystem, param0); + sub_02052914(fieldSystem, taskMan); (*state)++; break; case 4: - FieldTransition_StartMap(param0); + FieldTransition_StartMap(taskMan); (*state)++; break; case 5: @@ -251,9 +246,9 @@ BOOL sub_02052B2C(FieldTask *param0) if (sub_0203A7EC() == FieldOverworldState_GetWarpId(SaveData_GetFieldOverworldState(fieldSystem->saveData))) { - ScriptManager_Start(param0, 2020, NULL, NULL); + ScriptManager_Start(taskMan, 2020, NULL, NULL); } else { - ScriptManager_Start(param0, 2021, NULL, NULL); + ScriptManager_Start(taskMan, 2021, NULL, NULL); } (*state)++; @@ -265,7 +260,7 @@ BOOL sub_02052B2C(FieldTask *param0) return 0; } -void sub_02052C5C(FieldTask *param0) +void sub_02052C5C(FieldTask *taskMan) { - FieldTask_InitCall(param0, sub_02052B2C, NULL); + FieldTask_InitCall(taskMan, sub_02052B2C, NULL); } diff --git a/src/unk_02054884.c b/src/unk_02054884.c index 13635f70c2..355caf4d9e 100644 --- a/src/unk_02054884.c +++ b/src/unk_02054884.c @@ -4,6 +4,8 @@ #include #include "constants/battle/condition.h" +#include "constants/field_poison.h" +#include "constants/heap.h" #include "constants/items.h" #include "struct_decls/struct_party_decl.h" @@ -29,28 +31,27 @@ BOOL Pokemon_CanBattle(Pokemon *mon) return !Pokemon_GetValue(mon, MON_DATA_IS_EGG, NULL); } -BOOL sub_020548B0(int param0, SaveData *param1, u16 param2, u8 param3, u16 param4, int param5, int param6) +BOOL sub_020548B0(int heapID, SaveData *saveData, u16 param2, u8 param3, u16 param4, int param5, int param6) { BOOL result; Pokemon *mon; u32 v2; Party *party; - TrainerInfo *trainerInfo; + TrainerInfo *trainerInfo = SaveData_GetTrainerInfo(saveData); - trainerInfo = SaveData_GetTrainerInfo(param1); - party = Party_GetFromSavedata(param1); - mon = Pokemon_New(param0); + party = Party_GetFromSavedata(saveData); + mon = Pokemon_New(heapID); Pokemon_Init(mon); Pokemon_InitWith(mon, param2, param3, 32, FALSE, 0, OTID_NOT_SET, 0); - Pokemon_SetCatchData(mon, trainerInfo, ITEM_POKE_BALL, param5, param6, param0); + Pokemon_SetCatchData(mon, trainerInfo, ITEM_POKE_BALL, param5, param6, heapID); v2 = param4; Pokemon_SetValue(mon, MON_DATA_HELD_ITEM, &v2); result = Party_AddPokemon(party, mon); if (result) { - sub_0202F180(param1, mon); + sub_0202F180(saveData, mon); } Heap_FreeToHeap(mon); @@ -58,13 +59,13 @@ BOOL sub_020548B0(int param0, SaveData *param1, u16 param2, u8 param3, u16 param return result; } -BOOL sub_02054930(int param0, SaveData *param1, u16 param2, u8 param3, int param4, int param5) +BOOL sub_02054930(int unused, SaveData *saveData, u16 param2, u8 param3, int param4, int param5) { int v0; BOOL result; - TrainerInfo *trainerInfo = SaveData_GetTrainerInfo(param1); - Party *party = Party_GetFromSavedata(param1); - Pokemon *mon = Pokemon_New(32); + TrainerInfo *trainerInfo = SaveData_GetTrainerInfo(saveData); + Party *party = Party_GetFromSavedata(saveData); + Pokemon *mon = Pokemon_New(HEAP_ID_FIELD_TASK); Pokemon_Init(mon); @@ -175,44 +176,41 @@ void Party_GiveChampionRibbons(Party *party) } } -int Pokemon_DoPoisonDamage(Party *party, u16 param1) +int Pokemon_DoPoisonDamage(Party *party, u16 mapLabelTextID) { int numPoisoned = 0; int numFainted = 0; - int i, partyCount; + int i, partyCount = Party_GetCurrentCount(party); Pokemon *mon; - partyCount = Party_GetCurrentCount(party); - for (i = 0; i < partyCount; i++) { mon = Party_GetPokemonBySlotIndex(party, i); - if (Pokemon_CanBattle(mon)) { - if (Pokemon_GetValue(mon, MON_DATA_STATUS_CONDITION, NULL) & (MON_CONDITION_TOXIC | MON_CONDITION_POISON)) { - u32 hp = Pokemon_GetValue(mon, MON_DATA_CURRENT_HP, NULL); - - if (hp > 1) { - hp--; - } + if (Pokemon_CanBattle(mon) + && (Pokemon_GetValue(mon, MON_DATA_STATUS_CONDITION, NULL) & (MON_CONDITION_TOXIC | MON_CONDITION_POISON))) { + u32 hp = Pokemon_GetValue(mon, MON_DATA_CURRENT_HP, NULL); - Pokemon_SetValue(mon, MON_DATA_CURRENT_HP, &hp); + if (hp > 1) { + hp--; + } - if (hp == 1) { - numFainted++; - Pokemon_UpdateFriendship(mon, 7, param1); - } + Pokemon_SetValue(mon, MON_DATA_CURRENT_HP, &hp); - numPoisoned++; + if (hp == 1) { + numFainted++; + Pokemon_UpdateFriendship(mon, 7, mapLabelTextID); } + + numPoisoned++; } } if (numFainted) { - return 2; + return FLDPSN_FAINTED; } else if (numPoisoned) { - return 1; + return FLDPSN_POISONED; } else { - return 0; + return FLDPSN_NONE; } } diff --git a/src/unk_020553DC.c b/src/unk_020553DC.c index 760aa8d7d6..4f76e5c83d 100644 --- a/src/unk_020553DC.c +++ b/src/unk_020553DC.c @@ -115,39 +115,34 @@ void sub_020553DC() sub_0200569C(); sub_02004A3C(); sub_02004234(0); - - return; } -void Sound_SetSpecialBGM(FieldSystem *fieldSystem, u16 param1) +void Sound_SetSpecialBGM(FieldSystem *fieldSystem, u16 sdatID) { - u16 *v0 = FieldOverworldState_GetSpecialBGM(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *bgm = FieldOverworldState_GetSpecialBGM(SaveData_GetFieldOverworldState(fieldSystem->saveData)); - *v0 = param1; - return; + *bgm = sdatID; } u16 Sound_GetSpecialBGM(FieldSystem *fieldSystem) { - u16 *v0 = FieldOverworldState_GetSpecialBGM(SaveData_GetFieldOverworldState(fieldSystem->saveData)); - return *v0; + u16 *bgm = FieldOverworldState_GetSpecialBGM(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + return *bgm; } void Sound_ClearSpecialBGM(FieldSystem *fieldSystem) { - u16 *v0 = FieldOverworldState_GetSpecialBGM(SaveData_GetFieldOverworldState(fieldSystem->saveData)); + u16 *bgm = FieldOverworldState_GetSpecialBGM(SaveData_GetFieldOverworldState(fieldSystem->saveData)); - *v0 = 0; - return; + *bgm = 0; } u16 sub_02055428(FieldSystem *fieldSystem, int param1) { - PlayerAvatar *playerAvatar; + PlayerAvatar *playerAvatar = fieldSystem->playerAvatar; int v1; u16 v2, v3; - playerAvatar = fieldSystem->playerAvatar; v1 = PlayerAvatar_GetPlayerState(playerAvatar); if (v1 == 0x2) { @@ -284,21 +279,16 @@ static void sub_020555CC(FieldSystem *fieldSystem, int param1, int *param2, int *param3 = 0; break; } - - return; } u16 sub_0205560C(int param0) { - u8 v0; - u16 v1, v2; - - v0 = (u8)TrainerData_LoadParam(param0, 1); - v1 = 1101; + u8 v0 = (u8)TrainerData_LoadParam(param0, 1); + u16 i, v1 = 1101; - for (v2 = 0; v2 < 79; v2++) { - if (Unk_020EC3E0[v2][0] == v0) { - v1 = Unk_020EC3E0[v2][1]; + for (i = 0; i < 79; i++) { + if (Unk_020EC3E0[i][0] == v0) { + v1 = Unk_020EC3E0[i][1]; break; } } @@ -315,8 +305,6 @@ void Sound_TryFadeInBGM(FieldSystem *fieldSystem, int param1) if (sub_020041FC() != sub_020554A4(fieldSystem, param1)) { sub_0200564C(0, 40); } - - return; } void Sound_PlayMapBGM(FieldSystem *fieldSystem, int param1) @@ -333,18 +321,12 @@ void Sound_PlayMapBGM(FieldSystem *fieldSystem, int param1) sub_02004224(v0); sub_02004550(4, v0, 1); - - return; } void sub_020556A0(FieldSystem *fieldSystem, int param1) { - u16 v0; - - v0 = sub_02055428(fieldSystem, param1); + u16 v0 = sub_02055428(fieldSystem, param1); sub_02004224(sub_020554A4(fieldSystem, param1)); sub_02004550(4, v0, 1); - - return; } diff --git a/src/unk_020683F4.c b/src/unk_020683F4.c index f006a16453..5598ccf05e 100644 --- a/src/unk_020683F4.c +++ b/src/unk_020683F4.c @@ -157,12 +157,12 @@ static u32 sub_02068D68(const UnkStruct_020684D0 *param0); static u32 sub_02068E94(const UnkStruct_020684D0 *param0); static u32 sub_020690C4(const UnkStruct_020684D0 *param0); static u32 sub_02069130(const UnkStruct_020684D0 *param0); -static BOOL sub_02068884(FieldTask *param0); -static BOOL sub_02068F48(FieldTask *param0); +static BOOL sub_02068884(FieldTask *taskMan); +static BOOL sub_02068F48(FieldTask *taskMan); static void sub_020693F8(UnkStruct_02068870 *param0, UnkFuncPtr_02068870 param1); -static BOOL sub_0206932C(FieldTask *param0); -static BOOL sub_020690F0(FieldTask *param0); -static BOOL sub_020685AC(FieldTask *param0); +static BOOL sub_0206932C(FieldTask *taskMan); +static BOOL sub_020690F0(FieldTask *taskMan); +static BOOL sub_020685AC(FieldTask *taskMan); static void sub_020692E4(UnkStruct_02068870 *param0, u32 param1); static const UnkStruct_020EF79C Unk_020EF79C[] = { @@ -473,17 +473,14 @@ static BOOL sub_02068870(UnkStruct_02068870 *param0) return 0; } -static BOOL sub_02068884(FieldTask *param0) +static BOOL sub_02068884(FieldTask *taskMan) { - FieldSystem *fieldSystem; - int *v1; - - fieldSystem = FieldTask_GetFieldSystem(param0); - v1 = FieldTask_GetState(param0); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + int *state = FieldTask_GetState(taskMan); - switch (*v1) { + switch (*state) { case 0: - (*v1)++; + (*state)++; break; case 1: if (PlayerAvatar_GetPlayerState(fieldSystem->playerAvatar) == 0x1) { @@ -505,10 +502,10 @@ static BOOL sub_02068884(FieldTask *param0) RadarChain_Clear(fieldSystem->chain); } - (*v1)++; + (*state)++; break; case 2: - (*v1)++; + (*state)++; break; case 3: MapObjectMan_UnpauseAllMovement(fieldSystem->mapObjMan); @@ -940,13 +937,10 @@ static BOOL sub_02068EFC(UnkStruct_02068870 *param0) return 0; } -static BOOL sub_02068F48(FieldTask *param0) +static BOOL sub_02068F48(FieldTask *taskMan) { - FieldSystem *fieldSystem; - UnkStruct_02068EFC *v1; - - fieldSystem = FieldTask_GetFieldSystem(param0); - v1 = FieldTask_GetEnv(param0); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + UnkStruct_02068EFC *v1 = FieldTask_GetEnv(taskMan); switch (v1->unk_16) { case 0: @@ -1039,12 +1033,12 @@ static u32 sub_020690C4(const UnkStruct_020684D0 *param0) return -1; } -static BOOL sub_020690F0(FieldTask *param0) +static BOOL sub_020690F0(FieldTask *taskMan) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(param0); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); void *v1 = ov6_02247100(fieldSystem, 11); - FieldTask_InitJump(param0, ov6_02247120, v1); + FieldTask_InitJump(taskMan, ov6_02247120, v1); return 0; } @@ -1202,11 +1196,8 @@ static void sub_020692E4(UnkStruct_02068870 *param0, u32 param1) static BOOL sub_0206932C(FieldTask *taskMan) { - FieldSystem *fieldSystem; - UnkStruct_02068870 *v1; - - fieldSystem = FieldTask_GetFieldSystem(taskMan); - v1 = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + UnkStruct_02068870 *v1 = FieldTask_GetEnv(taskMan); switch (v1->unk_2A) { case 0: diff --git a/src/unk_0206AFE0.c b/src/unk_0206AFE0.c index 245bc5caaa..1be46b2a32 100644 --- a/src/unk_0206AFE0.c +++ b/src/unk_0206AFE0.c @@ -32,15 +32,15 @@ static BOOL sub_0206AFE0(VarsFlags *param0, u16 param1, u16 param2) if ((param1 < VARS_START) || (param1 > SPECIAL_VARS_START)) { GF_ASSERT(FALSE); - return 0; + return FALSE; } if (v0 == NULL) { - return 0; + return FALSE; } *v0 = param2; - return 1; + return TRUE; } static u16 sub_0206B010(VarsFlags *param0, u16 param1) @@ -162,11 +162,7 @@ void sub_0206B144(VarsFlags *param0, int param1) BOOL sub_0206B16C(VarsFlags *param0, int param1) { - if (sub_0206B010(param0, (19 + (((0 + VARS_START) + 32) + 16)) + param1) == sub_0206B128(param1)) { - return 1; - } else { - return 0; - } + return sub_0206B010(param0, (19 + (((0 + VARS_START) + 32) + 16)) + param1) == sub_0206B128(param1); } static int sub_0206B194(int param0) @@ -194,11 +190,7 @@ void sub_0206B1D8(VarsFlags *param0, int param1) BOOL VarFlags_HiddenLocationsUnlocked(VarsFlags *varFlags, int hiddenLocation) { - if (sub_0206B010(varFlags, (6 + (((0 + VARS_START) + 32) + 16)) + hiddenLocation) == sub_0206B194(hiddenLocation)) { - return 1; - } else { - return 0; - } + return sub_0206B010(varFlags, (6 + (((0 + VARS_START) + 32) + 16)) + hiddenLocation) == sub_0206B194(hiddenLocation); } BOOL sub_0206B218(VarsFlags *param0) @@ -213,9 +205,7 @@ u16 sub_0206B228(VarsFlags *param0) BOOL sub_0206B238(VarsFlags *param0) { - u16 v0; - - v0 = sub_0206B010(param0, (10 + (((0 + VARS_START) + 32) + 16))); + u16 v0 = sub_0206B010(param0, (10 + (((0 + VARS_START) + 32) + 16))); if (v0 < 10000) { v0++; @@ -238,30 +228,24 @@ BOOL sub_0206B270(VarsFlags *param0, u16 param1) void sub_0206B280(VarsFlags *param0, u32 param1) { - u16 v0, v1; - - v1 = (param1 >> 16) & 0xffff; - v0 = param1 & 0xffff; + u16 v1 = (param1 >> 16) & 0xffff; + u16 v0 = param1 & 0xffff; sub_0206AFE0(param0, (12 + (((0 + VARS_START) + 32) + 16)), v0); sub_0206AFE0(param0, (12 + (((0 + VARS_START) + 32) + 16)), v1); } u32 sub_0206B2A4(VarsFlags *param0) { - u16 v0, v1; - - v0 = sub_0206B010(param0, (12 + (((0 + VARS_START) + 32) + 16))); - v1 = sub_0206B010(param0, (13 + (((0 + VARS_START) + 32) + 16))); + u16 v0 = sub_0206B010(param0, (12 + (((0 + VARS_START) + 32) + 16))); + u16 v1 = sub_0206B010(param0, (13 + (((0 + VARS_START) + 32) + 16))); return (v1 << 16) | v0; } void sub_0206B2C8(VarsFlags *param0) { - u16 v0, v1; - - v0 = LCRNG_Next(); - v1 = LCRNG_Next(); + u16 v0 = LCRNG_Next(); + u16 v1 = LCRNG_Next(); sub_0206B280(param0, (v1 << 16) | v0); } @@ -269,10 +253,7 @@ void sub_0206B2C8(VarsFlags *param0) void sub_0206B2E4(SaveData *param0, u16 param1) { VarsFlags *v0 = SaveData_GetVarsFlags(param0); - u32 v1; - - v1 = RecordMixedRNG_GetRand(SaveData_GetRecordMixedRNG(param0)); - v1 = v1 * 1103515245L + 12345; + u32 v1 = RecordMixedRNG_GetRand(SaveData_GetRecordMixedRNG(param0)) * 1103515245L + 12345; sub_0206B280(v0, v1); } @@ -290,18 +271,13 @@ BOOL sub_0206B324(VarsFlags *param0, u16 param1) void sub_0206B334(SaveData *param0) { VarsFlags *v0 = SaveData_GetVarsFlags(param0); - u32 v1; - - v1 = (LCRNG_Next() % 98) + 2; + u32 v1 = (LCRNG_Next() % 98) + 2; sub_0206B324(v0, v1); } u16 sub_0206B354(VarsFlags *param0) { - u16 v0; - - v0 = sub_0206B010(param0, (14 + (((0 + VARS_START) + 32) + 16))); - return v0; + return sub_0206B010(param0, (14 + (((0 + VARS_START) + 32) + 16))); } BOOL sub_0206B364(VarsFlags *param0, u16 param1) @@ -311,10 +287,7 @@ BOOL sub_0206B364(VarsFlags *param0, u16 param1) u16 sub_0206B374(VarsFlags *param0) { - u16 v0; - - v0 = sub_0206B010(param0, (25 + (((0 + VARS_START) + 32) + 16))); - return v0; + return sub_0206B010(param0, (25 + (((0 + VARS_START) + 32) + 16))); } BOOL sub_0206B384(VarsFlags *param0, u16 param1) @@ -324,10 +297,7 @@ BOOL sub_0206B384(VarsFlags *param0, u16 param1) u16 sub_0206B394(VarsFlags *param0) { - u16 v0; - - v0 = sub_0206B010(param0, (16 + (((0 + VARS_START) + 32) + 16))); - return v0; + return sub_0206B010(param0, (16 + (((0 + VARS_START) + 32) + 16))); } BOOL sub_0206B3A4(VarsFlags *param0, u16 param1) @@ -337,9 +307,7 @@ BOOL sub_0206B3A4(VarsFlags *param0, u16 param1) BOOL sub_0206B3B4(VarsFlags *param0) { - u16 v0; - - v0 = sub_0206B010(param0, (18 + (((0 + VARS_START) + 32) + 16))); + u16 v0 = sub_0206B010(param0, (18 + (((0 + VARS_START) + 32) + 16))); if (v0 < 10000) { v0++; @@ -425,9 +393,7 @@ static const u8 Unk_020EFA6C[] = { static u8 sub_0206B4A4(VarsFlags *param0) { int v0; - u16 v1, v2, v3; - - v1 = 0; + u16 v1 = 0, v2, v3; for (v0 = 0; v0 < VILLA_FURNITURE_MAX; v0++) { if (SystemFlag_HandleOwnsVillaFurniture(param0, HANDLE_FLAG_CHECK, v0) == TRUE) { @@ -455,7 +421,6 @@ static u8 sub_0206B4A4(VarsFlags *param0) void sub_0206B514(SaveData *param0) { - u32 unused; VarsFlags *v1 = SaveData_GetVarsFlags(param0); FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(param0); Location *location = FieldOverworldState_GetPlayerLocation(fieldState); diff --git a/src/unk_0206B70C.c b/src/unk_0206B70C.c index ce0a3eaaaf..3c7787f520 100644 --- a/src/unk_0206B70C.c +++ b/src/unk_0206B70C.c @@ -87,7 +87,7 @@ void sub_0206B70C(FieldSystem *fieldSystem, UnkStruct_0203D8AC *param1, int para x = Player_GetXPos(fieldSystem->playerAvatar); z = Player_GetZPos(fieldSystem->playerAvatar); - int v11 = 10 - 1; + int v11 = 9; Location *location = FieldOverworldState_GetPlayerLocation(fieldState); v6 = location->mapId; @@ -153,7 +153,7 @@ void sub_0206B70C(FieldSystem *fieldSystem, UnkStruct_0203D8AC *param1, int para static void sub_0206B878(FieldSystem *fieldSystem, UnkStruct_0203D8AC *param1, const char *param2) { FSFile v0; - int v1, v2; + int v1, i; int v3; UnkStruct_0206B878 *v4; UnkUnion_0206B878 *v5; @@ -174,8 +174,8 @@ static void sub_0206B878(FieldSystem *fieldSystem, UnkStruct_0203D8AC *param1, c param1->unk_13A = v3; - for (v2 = 0; v2 < v3; v2++) { - v5 = &(param1->unk_5C[v2]); + for (i = 0; i < v3; i++) { + v5 = &(param1->unk_5C[i]); v1 = FS_ReadFile(&v0, v4, sizeof(UnkStruct_0206B878)); switch (v4->unk_00) { @@ -203,6 +203,4 @@ static void sub_0206B878(FieldSystem *fieldSystem, UnkStruct_0203D8AC *param1, c (void)FS_CloseFile(&v0); Heap_FreeToHeap(v4); - - return; } From da15089bc31f0cdb616bbe02c8e91e1c3997f5ae Mon Sep 17 00:00:00 2001 From: Viperio19 Date: Thu, 21 Nov 2024 08:07:02 +0100 Subject: [PATCH 11/11] Remove more unnecessary scope blocks and replace `taskMan` in files from this PR with `task` --- include/field_map_change.h | 24 +-- include/overlay006/ov6_02247100.h | 8 +- include/unk_020528D0.h | 4 +- src/field_map_change.c | 338 +++++++++++++++--------------- src/overlay005/fieldmap.c | 56 ++--- src/overlay006/ov6_02247100.c | 56 ++--- src/unk_020528D0.c | 32 +-- src/unk_020683F4.c | 44 ++-- 8 files changed, 276 insertions(+), 286 deletions(-) diff --git a/include/field_map_change.h b/include/field_map_change.h index 99dc5ff9c5..314bab79b0 100644 --- a/include/field_map_change.h +++ b/include/field_map_change.h @@ -13,23 +13,23 @@ void sub_02053494(FieldSystem *fieldSystem); void FieldSystem_SetLoadNewGameSpawnTask(FieldSystem *fieldSystem); void FieldSystem_SetLoadSavedGameMapTask(FieldSystem *fieldSystem); void FieldSystem_StartLoadMapFromErrorTask(FieldSystem *fieldSystem); -void FieldSystem_StartChangeMapTask(FieldTask *taskMan, const Location *param1); -void FieldTask_ChangeMapByLocation(FieldTask *taskMan, const Location *param1); -void FieldTask_ChangeMapToLocation(FieldTask *taskMan, int param1, int param2, int param3, int param4, int param5); -void FieldTask_StartMapChangeFull(FieldTask *taskMan, int param1, int param2, int param3, int param4, int param5); +void FieldSystem_StartChangeMapTask(FieldTask *task, const Location *param1); +void FieldTask_ChangeMapByLocation(FieldTask *task, const Location *param1); +void FieldTask_ChangeMapToLocation(FieldTask *task, int param1, int param2, int param3, int param4, int param5); +void FieldTask_StartMapChangeFull(FieldTask *task, int param1, int param2, int param3, int param4, int param5); void FieldTask_StartMapChangeFly(FieldSystem *fieldSystem, int param1, int param2, int param3, int param4, int param5); -void FieldTask_ChangeMapChangeFly(FieldTask *taskMan, int param1, int param2, int param3, int param4, int param5); -void FieldTask_ChangeMapChangeByDig(FieldTask *taskMan, const Location *location, u32 param2); +void FieldTask_ChangeMapChangeFly(FieldTask *task, int param1, int param2, int param3, int param4, int param5); +void FieldTask_ChangeMapChangeByDig(FieldTask *task, const Location *location, u32 param2); void FieldSystem_StartMapChangeWarpTask(FieldSystem *fieldSystem, int param1, int param2); void *sub_02053FAC(FieldSystem *fieldSystem); void FieldTask_SetUndergroundMapChange(FieldSystem *fieldSystem); -BOOL FieldTask_MapChangeToUnderground(FieldTask *taskMan); -BOOL sub_0205430C(FieldTask *taskMan); +BOOL FieldTask_MapChangeToUnderground(FieldTask *task); +BOOL sub_0205430C(FieldTask *task); FieldTaskFunc FieldMapChange_GetMapChangeUndergroundTask(const FieldSystem *fieldSystem); -void sub_020544F0(FieldTask *taskMan, const Location *param1); +void sub_020544F0(FieldTask *task, const Location *param1); void sub_020545EC(FieldSystem *fieldSystem); -void sub_02054708(FieldTask *taskMan); -void sub_02054800(FieldTask *taskMan, int param1, int param2, int param3, int param4, int param5); -void sub_02054864(FieldTask *taskMan); +void sub_02054708(FieldTask *task); +void sub_02054800(FieldTask *task, int param1, int param2, int param3, int param4, int param5); +void sub_02054864(FieldTask *task); #endif // POKEPLATINUM_FIELD_MAP_CHANGE_H diff --git a/include/overlay006/ov6_02247100.h b/include/overlay006/ov6_02247100.h index 2735c4e8cd..0f88a0e4d4 100644 --- a/include/overlay006/ov6_02247100.h +++ b/include/overlay006/ov6_02247100.h @@ -7,12 +7,12 @@ #include "pokemon.h" void *ov6_02247100(FieldSystem *fieldSystem, u32 param1); -BOOL ov6_02247120(FieldTask *param0); +BOOL ov6_02247120(FieldTask *task); void *ov6_022472C8(FieldSystem *fieldSystem, u32 param1, int param2); -BOOL ov6_022472E8(FieldTask *param0); +BOOL ov6_022472E8(FieldTask *task); void *ov6_02247488(FieldSystem *, Pokemon *, u32 param0); -BOOL ov6_022474AC(FieldTask *param0); +BOOL ov6_022474AC(FieldTask *task); void *ov6_02247530(FieldSystem *fieldSystem, Pokemon *param1, u32 param2); -BOOL ov6_02247554(FieldTask *param0); +BOOL ov6_02247554(FieldTask *task); #endif // POKEPLATINUM_OV6_02247100_H diff --git a/include/unk_020528D0.h b/include/unk_020528D0.h index df61e031f0..5d9afb1a8a 100644 --- a/include/unk_020528D0.h +++ b/include/unk_020528D0.h @@ -3,7 +3,7 @@ #include "field_task.h" -BOOL sub_02052B2C(FieldTask *taskMan); -void sub_02052C5C(FieldTask *taskMan); +BOOL sub_02052B2C(FieldTask *task); +void sub_02052C5C(FieldTask *task); #endif // POKEPLATINUM_UNK_020528D0_H diff --git a/src/field_map_change.c b/src/field_map_change.c index 63137851a4..8c4784e393 100644 --- a/src/field_map_change.c +++ b/src/field_map_change.c @@ -132,28 +132,28 @@ typedef struct MapChangeUnionData { Location location; } MapChangeUnionData; -static BOOL FieldTask_ChangeMap(FieldTask *taskMan); -static BOOL FieldTask_LoadNewGameSpawn(FieldTask *taskMan); +static BOOL FieldTask_ChangeMap(FieldTask *task); +static BOOL FieldTask_LoadNewGameSpawn(FieldTask *task); static void FieldMapChange_SetNewLocation(FieldSystem *fieldSystem, const Location *param1); static void FieldMapChange_InitTerrainCollisionManager(FieldSystem *fieldSystem); static void FieldMapChange_RemoveTerrainCollisionManager(FieldSystem *fieldSystem); static void FieldMapChange_CreatePlayerObject(FieldSystem *fieldSystem); static void sub_02053374(FieldSystem *fieldSystem); static void sub_020534BC(FieldSystem *fieldSystem); -static BOOL FieldTask_MapChangeFly(FieldTask *taskMan); -static void FieldTask_FinishFly(FieldTask *taskMan); -static BOOL FieldTransition_FinishMapFly(FieldTask *taskMan); -static void FieldTransition_StartMapAndFadeInFly(FieldTask *taskMan); -static BOOL FieldTransition_StartMapAndFadeInFlySub(FieldTask *taskMan); -static void FieldTask_FadeInFly(FieldTask *taskMan); -static BOOL FieldTask_WaitFadeInFly(FieldTask *taskMan); -static BOOL FieldTask_MapChangeByDig(FieldTask *taskMan); -static void FieldTask_StartFinishFieldMapDig(FieldTask *taskMan); -static BOOL FieldTransition_FinishMapDig(FieldTask *taskMan); -static void FieldTransition_StartMapAndFadeInDig(FieldTask *taskMan); -static BOOL FieldTask_FadeInDig(FieldTask *taskMan); -static void sub_02053E5C(FieldTask *taskMan); -static BOOL sub_0205444C(FieldTask *taskMan, int param1); +static BOOL FieldTask_MapChangeFly(FieldTask *task); +static void FieldTask_FinishFly(FieldTask *task); +static BOOL FieldTransition_FinishMapFly(FieldTask *task); +static void FieldTransition_StartMapAndFadeInFly(FieldTask *task); +static BOOL FieldTransition_StartMapAndFadeInFlySub(FieldTask *task); +static void FieldTask_FadeInFly(FieldTask *task); +static BOOL FieldTask_WaitFadeInFly(FieldTask *task); +static BOOL FieldTask_MapChangeByDig(FieldTask *task); +static void FieldTask_StartFinishFieldMapDig(FieldTask *task); +static BOOL FieldTransition_FinishMapDig(FieldTask *task); +static void FieldTransition_StartMapAndFadeInDig(FieldTask *task); +static BOOL FieldTask_FadeInDig(FieldTask *task); +static void sub_02053E5C(FieldTask *task); +static BOOL sub_0205444C(FieldTask *task, int param1); static const MapLoadMode sMapLoadMode[] = { { 0x1, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0xC4000 }, @@ -445,10 +445,10 @@ static void FieldSystem_SetLocationToUnionRoomExit(FieldSystem *fieldSystem) Location_Set(exit, fieldSystem->location->mapId, -1, 8, 2, 1); } -static BOOL FieldTask_LoadNewGameSpawn(FieldTask *taskMan) +static BOOL FieldTask_LoadNewGameSpawn(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - int *state = FieldTask_GetState(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + int *state = FieldTask_GetState(task); switch (*state) { case 0: @@ -459,7 +459,7 @@ static BOOL FieldTask_LoadNewGameSpawn(FieldTask *taskMan) (*state)++; break; case 1: - FieldTransition_StartMapAndFadeIn(taskMan); + FieldTransition_StartMapAndFadeIn(task); (*state)++; break; case 2: @@ -481,11 +481,11 @@ static inline BOOL CheckJournalAcquired(VarsFlags *varsFlags) return SystemFlag_HandleJournalAcquired(varsFlags, HANDLE_FLAG_CHECK); } -static BOOL FieldTask_LoadSavedGameMap(FieldTask *taskMan) +static BOOL FieldTask_LoadSavedGameMap(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); VarsFlags *varsFlags = SaveData_GetVarsFlags(fieldSystem->saveData); - int *state = FieldTask_GetState(taskMan); + int *state = FieldTask_GetState(task); switch (*state) { case 0: @@ -523,7 +523,7 @@ static BOOL FieldTask_LoadSavedGameMap(FieldTask *taskMan) (*state) = 2; break; case 2: - FieldTransition_StartMapAndFadeIn(taskMan); + FieldTransition_StartMapAndFadeIn(task); (*state) = 3; break; case 3: @@ -544,12 +544,12 @@ void FieldSystem_SetLoadSavedGameMapTask(FieldSystem *fieldSystem) FieldSystem_CreateTask(fieldSystem, FieldTask_LoadSavedGameMap, NULL); } -static BOOL FieldTask_LoadMapFromError(FieldTask *taskMan) +static BOOL FieldTask_LoadMapFromError(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeFromErrorData *errorData = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeFromErrorData *errorData = FieldTask_GetEnv(task); VarsFlags *varsFlags = SaveData_GetVarsFlags(fieldSystem->saveData); - int *state = FieldTask_GetState(taskMan); + int *state = FieldTask_GetState(task); switch (*state) { case 0: @@ -570,7 +570,7 @@ static BOOL FieldTask_LoadMapFromError(FieldTask *taskMan) case 2: fieldSystem->unk_7C = FieldSystem_InitCommUnionRoom(fieldSystem); fieldSystem->unk_80 = sub_0205C22C(fieldSystem->unk_7C); - FieldTransition_StartMap(taskMan); + FieldTransition_StartMap(task); (*state)++; break; case 3: @@ -615,21 +615,21 @@ void FieldSystem_StartLoadMapFromErrorTask(FieldSystem *fieldSystem) FieldSystem_CreateTask(fieldSystem, FieldTask_LoadMapFromError, errorData); } -static BOOL FieldTask_ChangeMap(FieldTask *taskMan) +static BOOL FieldTask_ChangeMap(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeData *mapChangeData = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeData *mapChangeData = FieldTask_GetEnv(task); Location *location = &mapChangeData->nextLocation; switch (mapChangeData->state) { case 0: Sound_PlayEffect(1539); Sound_TryFadeInBGM(fieldSystem, location->mapId); - FieldTransition_FadeOutAndFinishMap(taskMan); + FieldTransition_FadeOutAndFinishMap(task); mapChangeData->state++; break; case 1: - FieldTask_ChangeMapByLocation(taskMan, &mapChangeData->nextLocation); + FieldTask_ChangeMapByLocation(task, &mapChangeData->nextLocation); mapChangeData->state++; break; case 2: @@ -638,7 +638,7 @@ static BOOL FieldTask_ChangeMap(FieldTask *taskMan) } Sound_PlayMapBGM(fieldSystem, location->mapId); - FieldTransition_StartMapAndFadeIn(taskMan); + FieldTransition_StartMapAndFadeIn(task); mapChangeData->state++; break; case 3: @@ -649,20 +649,20 @@ static BOOL FieldTask_ChangeMap(FieldTask *taskMan) return FALSE; } -void FieldSystem_StartChangeMapTask(FieldTask *taskMan, const Location *nextLocation) +void FieldSystem_StartChangeMapTask(FieldTask *task, const Location *nextLocation) { MapChangeData *mapChangeData = Heap_AllocFromHeapAtEnd(11, sizeof(MapChangeData)); mapChangeData->state = 0; mapChangeData->nextLocation = *nextLocation; - FieldTask_InitCall(taskMan, FieldTask_ChangeMap, mapChangeData); + FieldTask_InitCall(task, FieldTask_ChangeMap, mapChangeData); } -static BOOL FieldTask_ChangeMapSub(FieldTask *taskMan) +static BOOL FieldTask_ChangeMapSub(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeSubData *mapChangeSub = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeSubData *mapChangeSub = FieldTask_GetEnv(task); switch (mapChangeSub->state) { case 0: @@ -686,9 +686,9 @@ static BOOL FieldTask_ChangeMapSub(FieldTask *taskMan) return 0; } -void FieldTask_ChangeMapByLocation(FieldTask *taskMan, const Location *nextLocation) +void FieldTask_ChangeMapByLocation(FieldTask *task, const Location *nextLocation) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); MapChangeSubData *mapChangeSub = Heap_AllocFromHeapAtEnd(11, sizeof(MapChangeSubData)); if (FieldSystem_HasParentProcess(fieldSystem)) { @@ -699,31 +699,31 @@ void FieldTask_ChangeMapByLocation(FieldTask *taskMan, const Location *nextLocat mapChangeSub->state = 0; mapChangeSub->nextLocation = *nextLocation; - FieldTask_InitCall(taskMan, FieldTask_ChangeMapSub, mapChangeSub); + FieldTask_InitCall(task, FieldTask_ChangeMapSub, mapChangeSub); } -void FieldTask_ChangeMapToLocation(FieldTask *taskMan, int param1, int param2, int param3, int param4, int param5) +void FieldTask_ChangeMapToLocation(FieldTask *task, int param1, int param2, int param3, int param4, int param5) { Location location; Location_Set(&location, param1, param2, param3, param4, param5); - FieldTask_ChangeMapByLocation(taskMan, &location); + FieldTask_ChangeMapByLocation(task, &location); } -static BOOL FieldTask_ChangeMapFull(FieldTask *taskMan) +static BOOL FieldTask_ChangeMapFull(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeSubData *mapChangeSub = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeSubData *mapChangeSub = FieldTask_GetEnv(task); Location *nextLocation = &mapChangeSub->nextLocation; switch (mapChangeSub->state) { case 0: Sound_TryFadeInBGM(fieldSystem, nextLocation->mapId); - FieldTransition_FinishMap(taskMan); + FieldTransition_FinishMap(task); mapChangeSub->state++; break; case 1: - FieldTask_ChangeMapByLocation(taskMan, &mapChangeSub->nextLocation); + FieldTask_ChangeMapByLocation(task, &mapChangeSub->nextLocation); mapChangeSub->state++; break; case 2: @@ -732,7 +732,7 @@ static BOOL FieldTask_ChangeMapFull(FieldTask *taskMan) } Sound_PlayMapBGM(fieldSystem, nextLocation->mapId); - FieldTransition_StartMap(taskMan); + FieldTransition_StartMap(task); mapChangeSub->state++; break; case 3: @@ -743,14 +743,14 @@ static BOOL FieldTask_ChangeMapFull(FieldTask *taskMan) return FALSE; } -void FieldTask_StartMapChangeFull(FieldTask *taskMan, int mapId, int param2, int x, int z, int dir) +void FieldTask_StartMapChangeFull(FieldTask *task, int mapId, int param2, int x, int z, int dir) { MapChangeSubData *mapChangeSub = Heap_AllocFromHeapAtEnd(11, sizeof(MapChangeSubData)); mapChangeSub->state = 0; Location_Set(&mapChangeSub->nextLocation, mapId, param2, x, z, dir); - FieldTask_InitCall(taskMan, FieldTask_ChangeMapFull, mapChangeSub); + FieldTask_InitCall(task, FieldTask_ChangeMapFull, mapChangeSub); } void FieldTask_StartMapChangeFly(FieldSystem *fieldSystem, int param1, int param2, int param3, int param4, int param5) @@ -768,7 +768,7 @@ void FieldTask_StartMapChangeFly(FieldSystem *fieldSystem, int param1, int param FieldSystem_CreateTask(fieldSystem, FieldTask_MapChangeFly, mapChangeData); } -void FieldTask_ChangeMapChangeFly(FieldTask *taskMan, int param1, int param2, int param3, int param4, int param5) +void FieldTask_ChangeMapChangeFly(FieldTask *task, int param1, int param2, int param3, int param4, int param5) { Location location; @@ -780,24 +780,24 @@ void FieldTask_ChangeMapChangeFly(FieldTask *taskMan, int param1, int param2, in mapChangeData->task = NULL; mapChangeData->location = location; - FieldTask_InitJump(taskMan, FieldTask_MapChangeFly, mapChangeData); + FieldTask_InitJump(task, FieldTask_MapChangeFly, mapChangeData); } -static BOOL FieldTask_MapChangeFly(FieldTask *taskMan) +static BOOL FieldTask_MapChangeFly(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeFlyData *mapChangeData = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeFlyData *mapChangeData = FieldTask_GetEnv(task); Location *location = &mapChangeData->location; switch (mapChangeData->state) { case 0: Sound_TryFadeInBGM(fieldSystem, location->mapId); - FieldTask_FinishFly(taskMan); + FieldTask_FinishFly(task); mapChangeData->state++; break; case 1: PlayerAvatar_SetPlayerState(fieldSystem->playerAvatar, 0x0); - FieldTask_ChangeMapByLocation(taskMan, &mapChangeData->location); + FieldTask_ChangeMapByLocation(task, &mapChangeData->location); mapChangeData->state++; break; case 2: @@ -807,7 +807,7 @@ static BOOL FieldTask_MapChangeFly(FieldTask *taskMan) Sound_PlayMapBGM(fieldSystem, location->mapId); sub_0207056C(fieldSystem); - FieldTransition_StartMapAndFadeInFly(taskMan); + FieldTransition_StartMapAndFadeInFly(task); mapChangeData->state++; break; case 3: @@ -818,18 +818,18 @@ static BOOL FieldTask_MapChangeFly(FieldTask *taskMan) return 0; } -static void FieldTask_FinishFly(FieldTask *taskMan) +static void FieldTask_FinishFly(FieldTask *task) { - FieldTask_InitCall(taskMan, FieldTransition_FinishMapFly, NULL); + FieldTask_InitCall(task, FieldTransition_FinishMapFly, NULL); } -static BOOL FieldTransition_FinishMapFly(FieldTask *taskMan) +static BOOL FieldTransition_FinishMapFly(FieldTask *task) { - int *state = FieldTask_GetState(taskMan); + int *state = FieldTask_GetState(task); switch (*state) { case 0: - FieldTransition_FinishMap(taskMan); + FieldTransition_FinishMap(task); (*state)++; break; case 1: @@ -839,25 +839,25 @@ static BOOL FieldTransition_FinishMapFly(FieldTask *taskMan) return FALSE; } -static void FieldTransition_StartMapAndFadeInFly(FieldTask *taskMan) +static void FieldTransition_StartMapAndFadeInFly(FieldTask *task) { - MapChangeFlyData *mapChangeData = FieldTask_GetEnv(taskMan); - FieldTask_InitCall(taskMan, FieldTransition_StartMapAndFadeInFlySub, mapChangeData); + MapChangeFlyData *mapChangeData = FieldTask_GetEnv(task); + FieldTask_InitCall(task, FieldTransition_StartMapAndFadeInFlySub, mapChangeData); } -static BOOL FieldTransition_StartMapAndFadeInFlySub(FieldTask *taskMan) +static BOOL FieldTransition_StartMapAndFadeInFlySub(FieldTask *task) { - int *state = FieldTask_GetState(taskMan); - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + int *state = FieldTask_GetState(task); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); switch (*state) { case 0: - FieldTransition_StartMap(taskMan); + FieldTransition_StartMap(task); (*state)++; break; case 1: FieldSystem_RequestLocationName(fieldSystem); - FieldTask_FadeInFly(taskMan); + FieldTask_FadeInFly(task); (*state)++; break; case 2: @@ -867,10 +867,10 @@ static BOOL FieldTransition_StartMapAndFadeInFlySub(FieldTask *taskMan) return FALSE; } -static void FieldTask_FadeInFly(FieldTask *taskMan) +static void FieldTask_FadeInFly(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeFlyData *mapChangeData = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeFlyData *mapChangeData = FieldTask_GetEnv(task); if (!FieldSystem_HasParentProcess(fieldSystem)) { GF_ASSERT(FALSE); @@ -878,12 +878,12 @@ static void FieldTask_FadeInFly(FieldTask *taskMan) } mapChangeData->task = FieldTask_InitFlyLandingTask(fieldSystem, PlayerAvatar_Gender(fieldSystem->playerAvatar)); - FieldTask_InitCall(taskMan, FieldTask_WaitFadeInFly, mapChangeData); + FieldTask_InitCall(task, FieldTask_WaitFadeInFly, mapChangeData); } -static BOOL FieldTask_WaitFadeInFly(FieldTask *taskMan) +static BOOL FieldTask_WaitFadeInFly(FieldTask *task) { - MapChangeFlyData *mapChangeData = FieldTask_GetEnv(taskMan); + MapChangeFlyData *mapChangeData = FieldTask_GetEnv(task); if (ov6_02245CF0(mapChangeData->task) == 1) { ov6_02245CFC(mapChangeData->task); @@ -893,7 +893,7 @@ static BOOL FieldTask_WaitFadeInFly(FieldTask *taskMan) return FALSE; } -void FieldTask_ChangeMapChangeByDig(FieldTask *taskMan, const Location *location, u32 param2) +void FieldTask_ChangeMapChangeByDig(FieldTask *task, const Location *location, u32 param2) { MapChangeDigData *mapChangeData = Heap_AllocFromHeapAtEnd(11, sizeof(MapChangeDigData)); @@ -902,24 +902,24 @@ void FieldTask_ChangeMapChangeByDig(FieldTask *taskMan, const Location *location mapChangeData->task = NULL; mapChangeData->location = *location; - FieldTask_InitJump(taskMan, FieldTask_MapChangeByDig, mapChangeData); + FieldTask_InitJump(task, FieldTask_MapChangeByDig, mapChangeData); } -static BOOL FieldTask_MapChangeByDig(FieldTask *taskMan) +static BOOL FieldTask_MapChangeByDig(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeDigData *mapChangeData = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeDigData *mapChangeData = FieldTask_GetEnv(task); Location *location = &mapChangeData->location; switch (mapChangeData->state) { case 0: Sound_TryFadeInBGM(fieldSystem, location->mapId); - FieldTask_StartFinishFieldMapDig(taskMan); + FieldTask_StartFinishFieldMapDig(task); mapChangeData->state++; break; case 1: PlayerAvatar_SetPlayerState(fieldSystem->playerAvatar, 0x0); - FieldTask_ChangeMapByLocation(taskMan, &mapChangeData->location); + FieldTask_ChangeMapByLocation(task, &mapChangeData->location); mapChangeData->state++; break; case 2: @@ -937,7 +937,7 @@ static BOOL FieldTask_MapChangeByDig(FieldTask *taskMan) GF_ASSERT(FALSE); } - FieldTransition_StartMapAndFadeInDig(taskMan); + FieldTransition_StartMapAndFadeInDig(task); mapChangeData->state++; break; case 3: @@ -948,18 +948,18 @@ static BOOL FieldTask_MapChangeByDig(FieldTask *taskMan) return FALSE; } -static void FieldTask_StartFinishFieldMapDig(FieldTask *taskMan) +static void FieldTask_StartFinishFieldMapDig(FieldTask *task) { - FieldTask_InitCall(taskMan, FieldTransition_FinishMapDig, NULL); + FieldTask_InitCall(task, FieldTransition_FinishMapDig, NULL); } -static BOOL FieldTransition_FinishMapDig(FieldTask *taskMan) +static BOOL FieldTransition_FinishMapDig(FieldTask *task) { - int *state = FieldTask_GetState(taskMan); + int *state = FieldTask_GetState(task); switch (*state) { case 0: - FieldTransition_FinishMap(taskMan); + FieldTransition_FinishMap(task); (*state)++; break; case 1: @@ -969,26 +969,26 @@ static BOOL FieldTransition_FinishMapDig(FieldTask *taskMan) return FALSE; } -static void FieldTransition_StartMapAndFadeInDig(FieldTask *taskMan) +static void FieldTransition_StartMapAndFadeInDig(FieldTask *task) { - MapChangeDigData *mapChangeData = FieldTask_GetEnv(taskMan); - FieldTask_InitCall(taskMan, FieldTask_FadeInDig, mapChangeData); + MapChangeDigData *mapChangeData = FieldTask_GetEnv(task); + FieldTask_InitCall(task, FieldTask_FadeInDig, mapChangeData); } -static BOOL FieldTask_FadeInDig(FieldTask *taskMan) +static BOOL FieldTask_FadeInDig(FieldTask *task) { - int *state = FieldTask_GetState(taskMan); - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeDigData *mapChangeData = FieldTask_GetEnv(taskMan); + int *state = FieldTask_GetState(task); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeDigData *mapChangeData = FieldTask_GetEnv(task); switch (*state) { case 0: - FieldTransition_StartMap(taskMan); + FieldTransition_StartMap(task); (*state)++; break; case 1: FieldSystem_RequestLocationName(fieldSystem); - sub_02053E5C(taskMan); + sub_02053E5C(task); (*state)++; break; case 2: @@ -998,10 +998,10 @@ static BOOL FieldTask_FadeInDig(FieldTask *taskMan) return FALSE; } -static void sub_02053E5C(FieldTask *taskMan) +static void sub_02053E5C(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeDigData *mapChangeData = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeDigData *mapChangeData = FieldTask_GetEnv(task); if (!FieldSystem_HasParentProcess(fieldSystem)) { GF_ASSERT(FALSE); @@ -1009,13 +1009,13 @@ static void sub_02053E5C(FieldTask *taskMan) } void *v2 = ov6_022472C8(fieldSystem, 4, mapChangeData->unk_04); - FieldTask_InitCall(taskMan, ov6_022472E8, v2); + FieldTask_InitCall(task, ov6_022472E8, v2); } -static BOOL FieldTask_MapChangeWarp(FieldTask *taskMan) +static BOOL FieldTask_MapChangeWarp(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeWarpData *mapChangeWarpData = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeWarpData *mapChangeWarpData = FieldTask_GetEnv(task); Location *nextLocation = &mapChangeWarpData->nextLocation; switch (mapChangeWarpData->state) { @@ -1026,12 +1026,12 @@ static BOOL FieldTask_MapChangeWarp(FieldTask *taskMan) case 1: if (mapChangeWarpData->warpFinished) { Sound_TryFadeInBGM(fieldSystem, nextLocation->mapId); - FieldTransition_FinishMap(taskMan); + FieldTransition_FinishMap(task); mapChangeWarpData->state++; } break; case 2: - FieldTask_ChangeMapByLocation(taskMan, &mapChangeWarpData->nextLocation); + FieldTask_ChangeMapByLocation(task, &mapChangeWarpData->nextLocation); mapChangeWarpData->state++; break; case 3: @@ -1040,7 +1040,7 @@ static BOOL FieldTask_MapChangeWarp(FieldTask *taskMan) } Sound_PlayMapBGM(fieldSystem, nextLocation->mapId); - FieldTransition_StartMap(taskMan); + FieldTransition_StartMap(task); mapChangeWarpData->state++; break; case 4: @@ -1135,10 +1135,10 @@ void FieldTask_SetUndergroundMapChange(FieldSystem *fieldSystem) FieldSystem_CreateTask(fieldSystem, FieldMapChange_GetMapChangeUndergroundTask(fieldSystem), mapChangeUndergroundData); } -BOOL FieldTask_MapChangeToUnderground(FieldTask *taskMan) +BOOL FieldTask_MapChangeToUnderground(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeUndergroundData *mapChangeUndergroundData = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeUndergroundData *mapChangeUndergroundData = FieldTask_GetEnv(task); switch (mapChangeUndergroundData->state) { case 0: @@ -1175,13 +1175,13 @@ BOOL FieldTask_MapChangeToUnderground(FieldTask *taskMan) break; case 3: if (SaveData_OverwriteCheck(fieldSystem->saveData)) { - ScriptManager_Start(taskMan, 2034, NULL, NULL); + ScriptManager_Start(task, 2034, NULL, NULL); } else { sub_020287E0(fieldSystem->saveData); mapChangeUndergroundData->saveInfoWin = SaveInfoWindow_New(fieldSystem, 11, BG_LAYER_MAIN_3); SaveInfoWindow_Draw(mapChangeUndergroundData->saveInfoWin); mapChangeUndergroundData->unk_1C = 0; - ScriptManager_Start(taskMan, 2005, NULL, &mapChangeUndergroundData->unk_1C); + ScriptManager_Start(task, 2005, NULL, &mapChangeUndergroundData->unk_1C); } mapChangeUndergroundData->state = 4; @@ -1209,19 +1209,19 @@ BOOL FieldTask_MapChangeToUnderground(FieldTask *taskMan) mapChangeUndergroundData->state++; break; case 7: - if (sub_0205444C(taskMan, 0)) { + if (sub_0205444C(task, 0)) { mapChangeUndergroundData->state++; } break; case 8: - FieldTransition_FinishMap(taskMan); + FieldTransition_FinishMap(task); mapChangeUndergroundData->state++; break; case 9: fieldSystem->mapLoadType = MAP_LOAD_TYPE_UNDERGROUND; Overlay_LoadByID(FS_OVERLAY_ID(overlay23), 2); ov23_022499E8(fieldSystem); - FieldTask_ChangeMapToLocation(taskMan, mapChangeUndergroundData->mapId, -1, mapChangeUndergroundData->unk_10, mapChangeUndergroundData->unk_14, 1); + FieldTask_ChangeMapToLocation(task, mapChangeUndergroundData->mapId, -1, mapChangeUndergroundData->unk_10, mapChangeUndergroundData->unk_14, 1); mapChangeUndergroundData->state++; break; case 10: @@ -1231,11 +1231,11 @@ BOOL FieldTask_MapChangeToUnderground(FieldTask *taskMan) sub_02004234(0); Sound_ClearSpecialBGM(fieldSystem); - FieldTransition_StartMap(taskMan); + FieldTransition_StartMap(task); mapChangeUndergroundData->state++; break; case 11: - if (sub_0205444C(taskMan, 1)) { + if (sub_0205444C(task, 1)) { ov23_02249A2C(); fieldSystem->unk_6C = ov23_02249404(fieldSystem); sub_0200AAE0(30, 0, -16, GX_BLEND_PLANEMASK_BG0 | GX_BLEND_PLANEMASK_BG3 | GX_BLEND_PLANEMASK_OBJ, 2); @@ -1254,10 +1254,10 @@ BOOL FieldTask_MapChangeToUnderground(FieldTask *taskMan) return 0; } -BOOL FieldTask_MapChangeFromUnderground(FieldTask *taskMan) +BOOL FieldTask_MapChangeFromUnderground(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeUndergroundData *mapChangeUndergroundData = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeUndergroundData *mapChangeUndergroundData = FieldTask_GetEnv(task); int v2 = 0; switch (mapChangeUndergroundData->state) { @@ -1277,18 +1277,18 @@ BOOL FieldTask_MapChangeFromUnderground(FieldTask *taskMan) } break; case 2: - if (sub_0205444C(taskMan, 2)) { + if (sub_0205444C(task, 2)) { mapChangeUndergroundData->state++; } break; case 3: - FieldTransition_FinishMap(taskMan); + FieldTransition_FinishMap(task); mapChangeUndergroundData->state++; break; case 4: fieldSystem->mapLoadType = MAP_LOAD_TYPE_OVERWORLD; Overlay_UnloadByID(FS_OVERLAY_ID(overlay23)); - FieldTask_ChangeMapToLocation(taskMan, mapChangeUndergroundData->mapId, -1, mapChangeUndergroundData->unk_10, mapChangeUndergroundData->unk_14, 1); + FieldTask_ChangeMapToLocation(task, mapChangeUndergroundData->mapId, -1, mapChangeUndergroundData->unk_10, mapChangeUndergroundData->unk_14, 1); mapChangeUndergroundData->state++; break; case 5: @@ -1298,11 +1298,11 @@ BOOL FieldTask_MapChangeFromUnderground(FieldTask *taskMan) sub_02004234(0); Sound_ClearSpecialBGM(fieldSystem); - FieldTransition_StartMap(taskMan); + FieldTransition_StartMap(task); mapChangeUndergroundData->state++; break; case 6: - if (sub_0205444C(taskMan, 3)) { + if (sub_0205444C(task, 3)) { mapChangeUndergroundData->state++; } break; @@ -1327,10 +1327,10 @@ FieldTaskFunc FieldMapChange_GetMapChangeUndergroundTask(const FieldSystem *fiel } } -static BOOL sub_0205444C(FieldTask *taskMan, int param1) +static BOOL sub_0205444C(FieldTask *task, int param1) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeUndergroundData *mapChangeUndergroundData = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeUndergroundData *mapChangeUndergroundData = FieldTask_GetEnv(task); BOOL ret = 0; switch (mapChangeUndergroundData->unk_04) { @@ -1350,10 +1350,10 @@ static BOOL sub_0205444C(FieldTask *taskMan, int param1) return ret; } -static BOOL sub_02054494(FieldTask *taskMan) +static BOOL sub_02054494(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeSubData *mapChangeSub = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeSubData *mapChangeSub = FieldTask_GetEnv(task); switch (mapChangeSub->state) { case 0: @@ -1374,9 +1374,9 @@ static BOOL sub_02054494(FieldTask *taskMan) return 0; } -void sub_020544F0(FieldTask *taskMan, const Location *nextLocation) +void sub_020544F0(FieldTask *task, const Location *nextLocation) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); MapChangeSubData *mapChangeData = Heap_AllocFromHeapAtEnd(11, sizeof(MapChangeSubData)); if (FieldSystem_HasParentProcess(fieldSystem)) { @@ -1387,14 +1387,14 @@ void sub_020544F0(FieldTask *taskMan, const Location *nextLocation) mapChangeData->state = 0; mapChangeData->nextLocation = *nextLocation; - FieldTask_InitCall(taskMan, sub_02054494, mapChangeData); + FieldTask_InitCall(task, sub_02054494, mapChangeData); } -static BOOL sub_02054538(FieldTask *taskMan) +static BOOL sub_02054538(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeUnionData *mapChangeData = FieldTask_GetEnv(taskMan); - int *state = FieldTask_GetState(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeUnionData *mapChangeData = FieldTask_GetEnv(task); + int *state = FieldTask_GetState(task); Location *v3 = &mapChangeData->location; switch (*state) { @@ -1405,12 +1405,12 @@ static BOOL sub_02054538(FieldTask *taskMan) break; case 1: if (mapChangeData->unk_04) { - FieldTransition_FinishMap(taskMan); + FieldTransition_FinishMap(task); (*state)++; } break; case 2: - FieldTask_ChangeMapByLocation(taskMan, &mapChangeData->location); + FieldTask_ChangeMapByLocation(task, &mapChangeData->location); (*state)++; break; case 3: @@ -1419,11 +1419,11 @@ static BOOL sub_02054538(FieldTask *taskMan) } Sound_PlayMapBGM(fieldSystem, v3->mapId); - FieldTransition_StartMap(taskMan); + FieldTransition_StartMap(task); (*state)++; break; case 4: - FieldTransition_FadeIn(taskMan); + FieldTransition_FadeIn(task); (*state)++; break; case 5: @@ -1450,25 +1450,25 @@ void sub_020545EC(FieldSystem *fieldSystem) fieldSystem->unk_7C = NULL; } -static BOOL sub_02054648(FieldTask *taskMan) +static BOOL sub_02054648(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeUnionData *mapChangeData = FieldTask_GetEnv(taskMan); - int *state = FieldTask_GetState(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeUnionData *mapChangeData = FieldTask_GetEnv(task); + int *state = FieldTask_GetState(task); Location *v3 = &mapChangeData->location; switch (*state) { case 0: Sound_TryFadeInBGM(fieldSystem, v3->mapId); - FieldTransition_FadeOut(taskMan); + FieldTransition_FadeOut(task); (*state)++; break; case 1: - FieldTransition_FinishMap(taskMan); + FieldTransition_FinishMap(task); (*state)++; break; case 2: - FieldTask_ChangeMapByLocation(taskMan, &mapChangeData->location); + FieldTask_ChangeMapByLocation(task, &mapChangeData->location); (*state)++; break; case 3: @@ -1477,7 +1477,7 @@ static BOOL sub_02054648(FieldTask *taskMan) } Sound_PlayMapBGM(fieldSystem, v3->mapId); - FieldTransition_StartMap(taskMan); + FieldTransition_StartMap(task); (*state)++; break; case 4: @@ -1498,9 +1498,9 @@ static BOOL sub_02054648(FieldTask *taskMan) return FALSE; } -void sub_02054708(FieldTask *taskMan) +void sub_02054708(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); Location *location = FieldOverworldState_GetSpecialLocation(SaveData_GetFieldOverworldState(fieldSystem->saveData)); MapChangeUnionData *mapChangeData = Heap_AllocFromHeapAtEnd(11, sizeof(MapChangeUnionData)); @@ -1513,24 +1513,24 @@ void sub_02054708(FieldTask *taskMan) fieldSystem->unk_80 = sub_0205C22C(fieldSystem->unk_7C); fieldSystem->mapLoadType = MAP_LOAD_TYPE_UNION; - FieldTask_InitCall(taskMan, sub_02054648, mapChangeData); + FieldTask_InitCall(task, sub_02054648, mapChangeData); } -static BOOL FieldTask_ChangeMapColosseum(FieldTask *taskMan) +static BOOL FieldTask_ChangeMapColosseum(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - MapChangeData *mapChangeData = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + MapChangeData *mapChangeData = FieldTask_GetEnv(task); Location *location = &mapChangeData->nextLocation; switch (mapChangeData->state) { case 0: Sound_PlayEffect(1539); Sound_TryFadeInBGM(fieldSystem, location->mapId); - FieldTransition_FadeOutAndFinishMap(taskMan); + FieldTransition_FadeOutAndFinishMap(task); mapChangeData->state++; break; case 1: - FieldTask_ChangeMapByLocation(taskMan, &mapChangeData->nextLocation); + FieldTask_ChangeMapByLocation(task, &mapChangeData->nextLocation); mapChangeData->state++; break; case 2: @@ -1539,7 +1539,7 @@ static BOOL FieldTask_ChangeMapColosseum(FieldTask *taskMan) } Sound_PlayMapBGM(fieldSystem, location->mapId); - FieldTransition_StartMap(taskMan); + FieldTransition_StartMap(task); mapChangeData->state++; break; case 3: @@ -1550,10 +1550,10 @@ static BOOL FieldTask_ChangeMapColosseum(FieldTask *taskMan) return FALSE; } -void sub_02054800(FieldTask *taskMan, int mapId, int param2, int x, int z, int param5) +void sub_02054800(FieldTask *task, int mapId, int param2, int x, int z, int param5) { Location nextLocation; - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); Location *location = FieldOverworldState_GetSpecialLocation(SaveData_GetFieldOverworldState(fieldSystem->saveData)); Location_SetToPlayerLocation(location, fieldSystem); @@ -1567,12 +1567,12 @@ void sub_02054800(FieldTask *taskMan, int mapId, int param2, int x, int z, int p mapChangeData->state = 0; mapChangeData->nextLocation = nextLocation; - FieldTask_InitCall(taskMan, FieldTask_ChangeMapColosseum, mapChangeData); + FieldTask_InitCall(task, FieldTask_ChangeMapColosseum, mapChangeData); } -void sub_02054864(FieldTask *taskMan) +void sub_02054864(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); Location *location = FieldOverworldState_GetSpecialLocation(SaveData_GetFieldOverworldState(fieldSystem->saveData)); fieldSystem->mapLoadType = MAP_LOAD_TYPE_OVERWORLD; diff --git a/src/overlay005/fieldmap.c b/src/overlay005/fieldmap.c index 6096bb6b07..d9f99f78f7 100644 --- a/src/overlay005/fieldmap.c +++ b/src/overlay005/fieldmap.c @@ -424,12 +424,10 @@ static BOOL FieldMap_ChangeZone(FieldSystem *fieldSystem) MapHeaderData_Load(fieldSystem, v0); FieldMapChange_UpdateGameData(fieldSystem, 1); - { - int objEventCount = MapHeaderData_GetNumObjectEvents(fieldSystem); - const ObjectEvent *objEventList = MapHeaderData_GetObjectEvents(fieldSystem); + int objEventCount = MapHeaderData_GetNumObjectEvents(fieldSystem); + const ObjectEvent *objEventList = MapHeaderData_GetObjectEvents(fieldSystem); - sub_0206184C(fieldSystem->mapObjMan, mapId, v0, objEventCount, objEventList); - } + sub_0206184C(fieldSystem->mapObjMan, mapId, v0, objEventCount, objEventList); RadarChain_Clear(fieldSystem->chain); sub_02055554(fieldSystem, sub_02055428(fieldSystem, fieldSystem->location->mapId), 1); @@ -440,21 +438,19 @@ static BOOL FieldMap_ChangeZone(FieldSystem *fieldSystem) fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(fieldState)); } - { - int v7, v8; - int v9; - - v7 = MapHeader_GetMapLabelTextID(mapId); - v8 = MapHeader_GetMapLabelTextID(v0); - v9 = MapHeader_GetMapLabelWindowID(v0); + int v7, v8; + int v9; - if (v7 != v8) { - if (v9 != 0) { - v9--; - } + v7 = MapHeader_GetMapLabelTextID(mapId); + v8 = MapHeader_GetMapLabelTextID(v0); + v9 = MapHeader_GetMapLabelWindowID(v0); - ov5_021DD9E8(fieldSystem->unk_04->unk_08, v8, v9); + if (v7 != v8) { + if (v9 != 0) { + v9--; } + + ov5_021DD9E8(fieldSystem->unk_04->unk_08, v8, v9); } return TRUE; @@ -468,27 +464,21 @@ void ov5_021D12D0(FieldSystem *fieldSystem, u32 param1) mapId = fieldSystem->location->mapId; fieldState = SaveData_GetFieldOverworldState(fieldSystem->saveData); - { - fieldSystem->location->mapId = param1; + fieldSystem->location->mapId = param1; - MapHeaderData_Load(fieldSystem, param1); - FieldMapChange_UpdateGameDataDistortionWorld(fieldSystem, 1); - } + MapHeaderData_Load(fieldSystem, param1); + FieldMapChange_UpdateGameDataDistortionWorld(fieldSystem, 1); - { - int objEventCount = MapHeaderData_GetNumObjectEvents(fieldSystem); - const ObjectEvent *objEventList = MapHeaderData_GetObjectEvents(fieldSystem); + int objEventCount = MapHeaderData_GetNumObjectEvents(fieldSystem); + const ObjectEvent *objEventList = MapHeaderData_GetObjectEvents(fieldSystem); - sub_0206184C(fieldSystem->mapObjMan, mapId, param1, objEventCount, objEventList); - } + sub_0206184C(fieldSystem->mapObjMan, mapId, param1, objEventCount, objEventList); - { - sub_02055554(fieldSystem, sub_02055428(fieldSystem, fieldSystem->location->mapId), 1); - sub_0203A418(fieldSystem); + sub_02055554(fieldSystem, sub_02055428(fieldSystem, fieldSystem->location->mapId), 1); + sub_0203A418(fieldSystem); - if (fieldSystem->unk_04->unk_0C != NULL) { - ov5_021D5F7C(fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(fieldState)); - } + if (fieldSystem->unk_04->unk_0C != NULL) { + ov5_021D5F7C(fieldSystem->unk_04->unk_0C, FieldOverworldState_GetWeather(fieldState)); } } diff --git a/src/overlay006/ov6_02247100.c b/src/overlay006/ov6_02247100.c index 9987835fdf..01e6a81201 100644 --- a/src/overlay006/ov6_02247100.c +++ b/src/overlay006/ov6_02247100.c @@ -59,14 +59,14 @@ void *ov6_02247100(FieldSystem *fieldSystem, u32 param1) return v0; } -BOOL ov6_02247120(FieldTask *taskMan) +BOOL ov6_02247120(FieldTask *task) { int v0; - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - UnkStruct_ov6_02247100 *v2 = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + UnkStruct_ov6_02247100 *v2 = FieldTask_GetEnv(task); do { - v0 = Unk_ov6_022495CC[v2->unk_00](taskMan, fieldSystem, v2); + v0 = Unk_ov6_022495CC[v2->unk_00](task, fieldSystem, v2); if (v0 == 2) { Heap_FreeToHeap(v2); @@ -76,7 +76,7 @@ BOOL ov6_02247120(FieldTask *taskMan) return 0; } -static int ov6_0224715C(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) +static int ov6_0224715C(FieldTask *task, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) { param2->unk_14 = ov5_021F0EB0(fieldSystem, 4); ov5_021F0F10(param2->unk_14, 1, (FX32_ONE * -150), 15); @@ -98,7 +98,7 @@ static int ov6_0224715C(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ return 0; } -static int ov6_022471C0(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) +static int ov6_022471C0(FieldTask *task, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) { if (MapObject_HasAnimationEnded(param2->unk_0C) == 0) { return 0; @@ -123,7 +123,7 @@ static int ov6_022471C0(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ return 0; } -static int ov6_02247244(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) +static int ov6_02247244(FieldTask *task, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) { if (MapObject_HasAnimationEnded(param2->unk_0C) == 1) { MapObject_FinishAnimation(param2->unk_0C); @@ -142,7 +142,7 @@ static int ov6_02247244(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ return 1; } -static int ov6_02247288(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) +static int ov6_02247288(FieldTask *task, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) { FieldOverworldState *fieldState = SaveData_GetFieldOverworldState(fieldSystem->saveData); @@ -152,10 +152,10 @@ static int ov6_02247288(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ warpId = FieldOverworldState_GetWarpId(fieldState); sub_0203A7F0(warpId, &location); - FieldTask_ChangeMapChangeByDig(taskMan, &location, param2->unk_08); + FieldTask_ChangeMapChangeByDig(task, &location, param2->unk_08); } else { Location *location = FieldOverworldState_GetExitLocation(fieldState); - FieldTask_ChangeMapChangeByDig(taskMan, location, param2->unk_08); + FieldTask_ChangeMapChangeByDig(task, location, param2->unk_08); } return 2; @@ -179,14 +179,14 @@ void *ov6_022472C8(FieldSystem *fieldSystem, u32 param1, int param2) return v0; } -BOOL ov6_022472E8(FieldTask *taskMan) +BOOL ov6_022472E8(FieldTask *task) { int v0; - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - UnkStruct_ov6_02247100 *v2 = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + UnkStruct_ov6_02247100 *v2 = FieldTask_GetEnv(task); do { - v0 = Unk_ov6_022495BC[v2->unk_00](taskMan, fieldSystem, v2); + v0 = Unk_ov6_022495BC[v2->unk_00](task, fieldSystem, v2); if (v0 == 2) { ov6_0224732C(fieldSystem, v2); @@ -211,7 +211,7 @@ static void ov6_0224732C(FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param Journal_SaveData(fieldSystem->journal, v0, 1); } -static int ov6_02247354(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) +static int ov6_02247354(FieldTask *task, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) { if (param2->unk_08 == 2) { StartScreenTransition(0, 1, 1, 0x0, 6, 1, 4); @@ -227,7 +227,7 @@ static int ov6_02247354(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ return 0; } -static int ov6_022473C8(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) +static int ov6_022473C8(FieldTask *task, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) { if (MapObject_HasAnimationEnded(param2->unk_0C) == 1) { MapObject_FinishAnimation(param2->unk_0C); @@ -244,7 +244,7 @@ static int ov6_022473C8(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ return 1; } -static int ov6_0224740C(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) +static int ov6_0224740C(FieldTask *task, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) { if (MapObject_HasAnimationEnded(param2->unk_0C) == 0) { return 0; @@ -264,7 +264,7 @@ static int ov6_0224740C(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ return 0; } -static int ov6_02247458(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) +static int ov6_02247458(FieldTask *task, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) { if (MapObject_HasAnimationEnded(param2->unk_0C) == 0) { return 0; @@ -299,14 +299,14 @@ void *ov6_02247488(FieldSystem *fieldSystem, Pokemon *param1, u32 param2) return v0; } -BOOL ov6_022474AC(FieldTask *taskMan) +BOOL ov6_022474AC(FieldTask *task) { int v0; - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - UnkStruct_ov6_02247100 *v2 = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + UnkStruct_ov6_02247100 *v2 = FieldTask_GetEnv(task); do { - v0 = Unk_ov6_022495F0[v2->unk_00](taskMan, fieldSystem, v2); + v0 = Unk_ov6_022495F0[v2->unk_00](task, fieldSystem, v2); if (v0 == 2) { Heap_FreeToHeap(v2); @@ -316,7 +316,7 @@ BOOL ov6_022474AC(FieldTask *taskMan) return 0; } -static int ov6_022474E8(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) +static int ov6_022474E8(FieldTask *task, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) { int v0 = PlayerAvatar_Gender(fieldSystem->playerAvatar); @@ -326,7 +326,7 @@ static int ov6_022474E8(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ return 0; } -static int ov6_0224750C(FieldTask *taskMan, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) +static int ov6_0224750C(FieldTask *task, FieldSystem *fieldSystem, UnkStruct_ov6_02247100 *param2) { if (ov6_02243FBC(param2->unk_10) == 0) { return 0; @@ -358,14 +358,14 @@ void *ov6_02247530(FieldSystem *fieldSystem, Pokemon *param1, u32 param2) return v0; } -BOOL ov6_02247554(FieldTask *taskMan) +BOOL ov6_02247554(FieldTask *task) { int v0; - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - UnkStruct_ov6_02247100 *v2 = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + UnkStruct_ov6_02247100 *v2 = FieldTask_GetEnv(task); do { - v0 = Unk_ov6_022495F0[v2->unk_00](taskMan, fieldSystem, v2); + v0 = Unk_ov6_022495F0[v2->unk_00](task, fieldSystem, v2); if (v0 == 2) { Heap_FreeToHeap(v2); diff --git a/src/unk_020528D0.c b/src/unk_020528D0.c index 7f9096f696..ef8b236703 100644 --- a/src/unk_020528D0.c +++ b/src/unk_020528D0.c @@ -45,8 +45,8 @@ typedef struct { StringTemplate *unk_20; } UnkStruct_02052AA4; -static void sub_02052914(FieldSystem *fieldSystem, FieldTask *taskMan); -static BOOL sub_020529C4(FieldTask *taskMan); +static void sub_02052914(FieldSystem *fieldSystem, FieldTask *task); +static BOOL sub_020529C4(FieldTask *task); static void sub_02052AA4(UnkStruct_02052AA4 *param0, u16 param1, u8 param2, u8 param3); static const WindowTemplate Unk_020EC2F0 = { @@ -101,7 +101,7 @@ static void sub_020528D0(BgConfig *param0) Graphics_LoadPalette(14, 6, 0, 13 * 0x20, 0x20, 11); } -static void sub_02052914(FieldSystem *fieldSystem, FieldTask *taskMan) +static void sub_02052914(FieldSystem *fieldSystem, FieldTask *task) { UnkStruct_02052AA4 *v0 = Heap_AllocFromHeap(11, sizeof(UnkStruct_02052AA4)); @@ -130,14 +130,14 @@ static void sub_02052914(FieldSystem *fieldSystem, FieldTask *taskMan) } Window_CopyToVRAM(&v0->unk_0C); - FieldTask_InitCall(taskMan, sub_020529C4, v0); + FieldTask_InitCall(task, sub_020529C4, v0); return; } -static BOOL sub_020529C4(FieldTask *taskMan) +static BOOL sub_020529C4(FieldTask *task) { - UnkStruct_02052AA4 *v0 = FieldTask_GetEnv(taskMan); + UnkStruct_02052AA4 *v0 = FieldTask_GetEnv(task); switch (v0->unk_00) { case 0: @@ -197,10 +197,10 @@ static void sub_02052AA4(UnkStruct_02052AA4 *param0, u16 param1, u8 param2, u8 p return; } -BOOL sub_02052B2C(FieldTask *taskMan) +BOOL sub_02052B2C(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - int *state = FieldTask_GetState(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + int *state = FieldTask_GetState(task); switch (*state) { case 0: { @@ -216,7 +216,7 @@ BOOL sub_02052B2C(FieldTask *taskMan) sub_0203A824(warpId, &location); sub_0203A7F0(warpId, FieldOverworldState_GetExitLocation(fieldState)); - FieldTask_ChangeMapByLocation(taskMan, &location); + FieldTask_ChangeMapByLocation(task, &location); sub_020705B4(fieldSystem); } (*state)++; @@ -234,11 +234,11 @@ BOOL sub_02052B2C(FieldTask *taskMan) case 3: sub_0200AB4C(-16, ((GX_BLEND_PLANEMASK_BG0 | GX_BLEND_PLANEMASK_BG1 | GX_BLEND_PLANEMASK_BG2 | GX_BLEND_PLANEMASK_BG3 | GX_BLEND_PLANEMASK_OBJ | GX_BLEND_PLANEMASK_BD) ^ GX_BLEND_PLANEMASK_BG3), 1); sub_0200AB4C(-16, (GX_BLEND_PLANEMASK_BG0 | GX_BLEND_PLANEMASK_BG1 | GX_BLEND_PLANEMASK_BG2 | GX_BLEND_PLANEMASK_BG3 | GX_BLEND_PLANEMASK_OBJ | GX_BLEND_PLANEMASK_BD), 2); - sub_02052914(fieldSystem, taskMan); + sub_02052914(fieldSystem, task); (*state)++; break; case 4: - FieldTransition_StartMap(taskMan); + FieldTransition_StartMap(task); (*state)++; break; case 5: @@ -246,9 +246,9 @@ BOOL sub_02052B2C(FieldTask *taskMan) if (sub_0203A7EC() == FieldOverworldState_GetWarpId(SaveData_GetFieldOverworldState(fieldSystem->saveData))) { - ScriptManager_Start(taskMan, 2020, NULL, NULL); + ScriptManager_Start(task, 2020, NULL, NULL); } else { - ScriptManager_Start(taskMan, 2021, NULL, NULL); + ScriptManager_Start(task, 2021, NULL, NULL); } (*state)++; @@ -260,7 +260,7 @@ BOOL sub_02052B2C(FieldTask *taskMan) return 0; } -void sub_02052C5C(FieldTask *taskMan) +void sub_02052C5C(FieldTask *task) { - FieldTask_InitCall(taskMan, sub_02052B2C, NULL); + FieldTask_InitCall(task, sub_02052B2C, NULL); } diff --git a/src/unk_020683F4.c b/src/unk_020683F4.c index 5598ccf05e..29b68334d0 100644 --- a/src/unk_020683F4.c +++ b/src/unk_020683F4.c @@ -157,12 +157,12 @@ static u32 sub_02068D68(const UnkStruct_020684D0 *param0); static u32 sub_02068E94(const UnkStruct_020684D0 *param0); static u32 sub_020690C4(const UnkStruct_020684D0 *param0); static u32 sub_02069130(const UnkStruct_020684D0 *param0); -static BOOL sub_02068884(FieldTask *taskMan); -static BOOL sub_02068F48(FieldTask *taskMan); +static BOOL sub_02068884(FieldTask *task); +static BOOL sub_02068F48(FieldTask *task); static void sub_020693F8(UnkStruct_02068870 *param0, UnkFuncPtr_02068870 param1); -static BOOL sub_0206932C(FieldTask *taskMan); -static BOOL sub_020690F0(FieldTask *taskMan); -static BOOL sub_020685AC(FieldTask *taskMan); +static BOOL sub_0206932C(FieldTask *task); +static BOOL sub_020690F0(FieldTask *task); +static BOOL sub_020685AC(FieldTask *task); static void sub_020692E4(UnkStruct_02068870 *param0, u32 param1); static const UnkStruct_020EF79C Unk_020EF79C[] = { @@ -301,17 +301,17 @@ static void sub_02068584(UnkStruct_02068870 *param0, u32 param1) FieldSystem_CreateTask(param0->fieldSystem, sub_020685AC, v0); } -static BOOL sub_020685AC(FieldTask *taskMan) +static BOOL sub_020685AC(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - UnkStruct_0206851C *v1 = FieldTask_GetEnv(taskMan); - int *v2 = FieldTask_GetState(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + UnkStruct_0206851C *v1 = FieldTask_GetEnv(task); + int *v2 = FieldTask_GetState(task); MapObject *v3; switch (*v2) { case 0: sub_0203C9D4(fieldSystem, &v3); - ScriptManager_Start(taskMan, v1->unk_00, v3, NULL); + ScriptManager_Start(task, v1->unk_00, v3, NULL); *(u16 *)FieldSystem_GetScriptMemberPtr(fieldSystem, SCRIPT_DATA_PARAMETER_0) = v1->unk_04; *(u16 *)FieldSystem_GetScriptMemberPtr(fieldSystem, SCRIPT_DATA_PARAMETER_1) = v1->unk_06; @@ -473,10 +473,10 @@ static BOOL sub_02068870(UnkStruct_02068870 *param0) return 0; } -static BOOL sub_02068884(FieldTask *taskMan) +static BOOL sub_02068884(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - int *state = FieldTask_GetState(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + int *state = FieldTask_GetState(task); switch (*state) { case 0: @@ -937,10 +937,10 @@ static BOOL sub_02068EFC(UnkStruct_02068870 *param0) return 0; } -static BOOL sub_02068F48(FieldTask *taskMan) +static BOOL sub_02068F48(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - UnkStruct_02068EFC *v1 = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + UnkStruct_02068EFC *v1 = FieldTask_GetEnv(task); switch (v1->unk_16) { case 0: @@ -1033,12 +1033,12 @@ static u32 sub_020690C4(const UnkStruct_020684D0 *param0) return -1; } -static BOOL sub_020690F0(FieldTask *taskMan) +static BOOL sub_020690F0(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); void *v1 = ov6_02247100(fieldSystem, 11); - FieldTask_InitJump(taskMan, ov6_02247120, v1); + FieldTask_InitJump(task, ov6_02247120, v1); return 0; } @@ -1194,10 +1194,10 @@ static void sub_020692E4(UnkStruct_02068870 *param0, u32 param1) FieldSystem_CreateTask(param0->fieldSystem, sub_02068F48, v0); } -static BOOL sub_0206932C(FieldTask *taskMan) +static BOOL sub_0206932C(FieldTask *task) { - FieldSystem *fieldSystem = FieldTask_GetFieldSystem(taskMan); - UnkStruct_02068870 *v1 = FieldTask_GetEnv(taskMan); + FieldSystem *fieldSystem = FieldTask_GetFieldSystem(task); + UnkStruct_02068870 *v1 = FieldTask_GetEnv(task); switch (v1->unk_2A) { case 0: