diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/battle_tower.h | 2 | ||||
-rw-r--r-- | include/constants/battle.h | 2 | ||||
-rw-r--r-- | include/event_scripts.h | 3 | ||||
-rw-r--r-- | include/field_message_box.h | 1 | ||||
-rw-r--r-- | include/global.h | 24 | ||||
-rw-r--r-- | include/main.h | 2 | ||||
-rw-r--r-- | include/pokemon.h | 4 | ||||
-rw-r--r-- | include/pokenav.h | 8 | ||||
-rw-r--r-- | include/strings.h | 15 | ||||
-rw-r--r-- | include/trainer_hill.h | 36 |
10 files changed, 78 insertions, 19 deletions
diff --git a/include/battle_tower.h b/include/battle_tower.h index bd8e80fc1..12d6d2e9e 100644 --- a/include/battle_tower.h +++ b/include/battle_tower.h @@ -79,7 +79,7 @@ void GetBattleTowerTrainerLanguage(u8 *dst, u16 trainerId); u8 SetFacilityPtrsGetLevel(void); u8 GetFrontierEnemyMonLevel(u8 lvlMode); s32 GetHighestLevelInPlayerParty(void); -u8 sub_81660B8(u8 facilityClass); +u8 FacilityClassToGraphicsId(u8 facilityClass); bool32 ValidateBattleTowerRecord(u8 recordId); // unused void sub_8166188(void); diff --git a/include/constants/battle.h b/include/constants/battle.h index acb0f6689..346d5d9ea 100644 --- a/include/constants/battle.h +++ b/include/constants/battle.h @@ -174,7 +174,7 @@ #define HITMARKER_GRUDGE 0x01000000 #define HITMARKER_OBEYS 0x02000000 #define HITMARKER_x4000000 0x04000000 -#define HITMARKER_x8000000 0x08000000 +#define HITMARKER_CHARGING 0x08000000 #define HITMARKER_FAINTED(battler) (gBitTable[battler] << 0x1C) #define HITMARKER_UNK(battler) (0x10000000 << battler) diff --git a/include/event_scripts.h b/include/event_scripts.h index e611dc6e0..afeac6628 100644 --- a/include/event_scripts.h +++ b/include/event_scripts.h @@ -584,4 +584,7 @@ extern const u8 EventScript_275A86[]; extern const u8 EventScript_275ADF[]; extern const u8 EventScript_275B38[]; +// trainer hill +extern const u8 EventScript_2C83F0[]; + #endif // GUARD_EVENT_SCRIPTS_H diff --git a/include/field_message_box.h b/include/field_message_box.h index e3deee4d6..9515a54fd 100644 --- a/include/field_message_box.h +++ b/include/field_message_box.h @@ -11,6 +11,7 @@ enum bool8 ShowFieldMessage(const u8 *message); bool8 sub_8098238(const u8 *message); +bool8 sub_80982B8(void); bool8 ShowFieldAutoScrollMessage(const u8 *message); void HideFieldMessageBox(void); bool8 IsFieldMessageBoxHidden(void); diff --git a/include/global.h b/include/global.h index c11bddc2d..f45d36f68 100644 --- a/include/global.h +++ b/include/global.h @@ -378,7 +378,8 @@ struct BattleFrontier /*0xEE0*/ u8 field_EE0; /*0xEE1*/ u8 field_EE1[2][PLAYER_NAME_LENGTH + 1]; /*0xEF1*/ u8 field_EF1[2][4]; - /*0xEF9*/ u8 field_EF9; + /*0xEF9*/ u8 field_EF9_0:7; + /*0xEF9*/ u8 field_EF9_1:1; /*0xEFA*/ u8 field_EFA; /*0xEFB*/ u8 field_EFB; /*0xEFC*/ struct FrontierMonData field_EFC[3]; @@ -792,6 +793,21 @@ struct UnkSaveSubstruct_3b98 u8 trainerName[PLAYER_NAME_LENGTH + 1]; }; +struct SaveTrainerHill +{ + /*0x3D64*/ u32 field_3D64; + /*0x3D68*/ u32 field_3D68; + /*0x3D6C*/ u8 field_3D6C; + /*0x3D6D*/ u8 unused; + /*0x3D6E*/ u16 field_3D6E_0a:1; // 1 + /*0x3D6E*/ u16 field_3D6E_0b:1; // 2 + /*0x3D6E*/ u16 field_3D6E_0c:1; // 4 + /*0x3D6E*/ u16 field_3D6E_0d:1; // 8 + /*0x3D6E*/ u16 field_3D6E_0e:1; // x10 + /*0x3D6E*/ u16 field_3D6E_0f:1; // x20 + /*0x3D6E*/ u16 tag:2; // x40, x80 = xC0 +}; + struct SaveBlock1 { /*0x00*/ struct Coords16 pos; @@ -869,13 +885,15 @@ struct SaveBlock1 /*0x31A8*/ u8 giftRibbons[52]; /*0x31DC*/ struct Roamer roamer; /*0x31F8*/ struct EnigmaBerry enigmaBerry; - /*0x322C*/ u8 field_322C[1276]; + /*0x322C*/ u8 field_322C[1260]; + /*0x3718*/ u32 trainerHillTimes[4]; /*0x3728*/ struct RamScript ramScript; /*0x3B14*/ struct RecordMixingGift recordMixingGift; /*0x3B24*/ u8 seen2[DEX_FLAGS_NO]; /*0x3B58*/ LilycoveLady lilycoveLady; /*0x3B98*/ struct UnkSaveSubstruct_3b98 unk_3B98[20]; - /*0x3C88*/ u8 filler_3C88[0xE8]; + /*0x3C88*/ u8 filler_3C88[0xDC]; + /*0x3D64*/ struct SaveTrainerHill trainerHill; /*0x3D70*/ struct WaldaPhrase waldaPhrase; // sizeof: 0x3D88 }; diff --git a/include/main.h b/include/main.h index 0d441035d..2ed30307b 100644 --- a/include/main.h +++ b/include/main.h @@ -61,6 +61,8 @@ void SetHBlankCallback(IntrCallback callback); void SetVCountCallback(IntrCallback callback); void SetSerialCallback(IntrCallback callback); void InitFlashTimer(void); +void sub_80008DC(u32 *var); +void sub_80008E8(void); void DoSoftReset(void); void ClearPokemonCrySongs(void); void RestoreSerialTimer3IntrHandlers(void); diff --git a/include/pokemon.h b/include/pokemon.h index cfa5cc350..507497683 100644 --- a/include/pokemon.h +++ b/include/pokemon.h @@ -451,8 +451,8 @@ void CreateMaleMon(struct Pokemon *mon, u16 species, u8 level); void CreateMonWithIVsPersonality(struct Pokemon *mon, u16 species, u8 level, u32 ivs, u32 personality); void CreateMonWithIVsOTID(struct Pokemon *mon, u16 species, u8 level, u8 *ivs, u32 otId); void CreateMonWithEVSpread(struct Pokemon *mon, u16 species, u8 level, u8 fixedIV, u8 evSpread); -void sub_806819C(struct Pokemon *mon, struct BattleTowerPokemon *src); -void sub_8068338(struct Pokemon *mon, struct BattleTowerPokemon *src, bool8 lvl50); +void CreateBattleTowerMon(struct Pokemon *mon, struct BattleTowerPokemon *src); +void CreateBattleTowerMon2(struct Pokemon *mon, struct BattleTowerPokemon *src, bool8 lvl50); void CreateApprenticeMon(struct Pokemon *mon, const struct Apprentice *src, u8 monId); void CreateMonWithEVSpreadNatureOTID(struct Pokemon *mon, u16 species, u8 level, u8 nature, u8 fixedIV, u8 evSpread, u32 otId); void sub_80686FC(struct Pokemon *mon, struct BattleTowerPokemon *dest); diff --git a/include/pokenav.h b/include/pokenav.h index d8f0c9f97..e5dba8ae0 100644 --- a/include/pokenav.h +++ b/include/pokenav.h @@ -3,7 +3,6 @@ #include "player_pc.h" #include "list_menu.h" -bool8 sub_81D5C18(void); bool8 sub_81D20BC(void *arg0); bool8 sub_81D312C(void *arg0); void sub_81D1ED4(void *arg0); @@ -14,28 +13,21 @@ void sub_81D3464(void *arg0); void sub_81D3480(void *arg0, u8 arg1); void sub_81D2754(void *arg0, void *arg1); void sub_81D1F84(void *arg0, void *arg1, void *arg2); -const u8 *sub_81D62AC(void); u8 sub_81D1C84(u8); u8 sub_81D1DC0(struct PlayerPCItemPageStruct *); void sub_81D1E90(struct PlayerPCItemPageStruct *); void sub_81D1EC0(void); void sub_81D1D04(u8); bool8 sub_81D1C44(u8); -void sub_81D5FB4(u16*); bool8 sub_81D4A58(struct EventObject*); void sub_81D2BF4(u8 *); u16 sub_81D2C3C(void); void sub_81D2C50(void); u8 sub_81D28C8(const struct ListMenuItem *items, u16 numChoices); void sub_81D2824(u16); -bool32 InTrainerHill(void); bool8 EventObjectIsFarawayIslandMew(struct EventObject *); u32 sub_81D427C(void); void sub_81D4998(void); -u8 GetCurrentTrainerHillMapId(void); -u8 sub_81D6490(void); -const struct WarpEvent *sub_81D6120(void); -const struct WarpEvent *sub_81D6134(u8); void sub_81D3640(u16 arg0, void* statStoreLocation1, void* statStoreLocation2, u8 arg3, u8 arg4, u8 arg5); void sub_81D3784(u16 arg0, void* statStoreLocation1, u8 arg2, u8 arg3, u8 arg4); diff --git a/include/strings.h b/include/strings.h index d16dd21f8..ff0d08195 100644 --- a/include/strings.h +++ b/include/strings.h @@ -1231,10 +1231,17 @@ extern const u8 gText_MtPyre[]; extern const u8 gText_SkyPillar[]; extern const u8 gText_DontRemember[]; extern const u8 gUnknown_085EB597[]; -extern const u8 gUnknown_085EB32D[]; -extern const u8 gUnknown_085EB33E[]; -extern const u8 gUnknown_085EB350[]; -extern const u8 gUnknown_085EB361[]; +extern const u8 gText_NormalTagMatch[]; +extern const u8 gText_VarietyTagMatch[]; +extern const u8 gText_UniqueTagMatch[]; +extern const u8 gText_ExpertTagMatch[]; +extern const u8 gText_TimeBoard[]; +extern const u8 gText_TimeCleared[]; +extern const u8 gText_XMinYDotZSec[]; +extern const u8 gText_TrainerHill1F[]; +extern const u8 gText_TrainerHill2F[]; +extern const u8 gText_TrainerHill3F[]; +extern const u8 gText_TrainerHill4F[]; extern const u8 OldaleTown_PokemonCenter_2F_Text_277F1B[]; extern const u8 OldaleTown_PokemonCenter_2F_Text_277F5A[]; diff --git a/include/trainer_hill.h b/include/trainer_hill.h new file mode 100644 index 000000000..bbc4f45c5 --- /dev/null +++ b/include/trainer_hill.h @@ -0,0 +1,36 @@ +#ifndef GUARD_TRAINER_HILL_H +#define GUARD_TRAINER_HILL_H + +extern u32 *gUnknown_0203CF5C; + +void CallTrainerHillFunction(void); +void ResetTrainerHillResults(void); +u8 GetTrainerHillOpponentClass(u16 trainerId); +void GetTrainerHillTrainerName(u8 *dst, u16 trainerId); +u8 GetTrainerHillTrainerFrontSpriteId(u16 trainerId); +void InitTrainerHillBattleStruct(void); +void FreeTrainerHillBattleStruct(void); +void CopyTrainerHillTrainerText(u8 which, u16 trainerId); +bool8 sub_81D5C18(void); +void nullsub_129(void); +void PrintOnTrainerHillRecordsWindow(void); +void sub_81D5DF8(void); +bool32 sub_81D5F48(void); +void sub_81D5FB4(u16 *mapArg); +bool32 InTrainerHill(void); +u8 GetCurrentTrainerHillMapId(void); +const struct WarpEvent* sub_81D6120(void); +const struct WarpEvent* sub_81D6134(u8 warpEventId); +u16 LocalIdToHillTrainerId(u8 localId); +bool8 GetHillTrainerFlag(u8 eventObjectId); +void SetHillTrainerFlag(void); +const u8 *sub_81D62AC(void); +void FillHillTrainerParty(void); +void FillHillTrainersParties(void); +u32 sub_81D63C4(void); +u8 GetTrainerEncounterMusicIdInTrainerHill(u16 trainerId); +u8 sub_81D6490(void); +void sub_81D64C0(void); +bool32 sub_81D6534(void); + +#endif // GUARD_TRAINER_HILL_H |