diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/pokedex.h | 2 | ||||
-rw-r--r-- | include/pokemon.h | 35 | ||||
-rw-r--r-- | include/proto.h | 2 | ||||
-rw-r--r-- | include/seal.h | 24 | ||||
-rw-r--r-- | include/trainer_data.h | 13 | ||||
-rw-r--r-- | include/unk_0206B688.h | 21 | ||||
-rw-r--r-- | include/unk_0206BB28.h | 12 |
7 files changed, 90 insertions, 19 deletions
diff --git a/include/pokedex.h b/include/pokedex.h index 11058569..891fddb5 100644 --- a/include/pokedex.h +++ b/include/pokedex.h @@ -2,6 +2,8 @@ #define POKEDIAMOND_POKEDEX_H #include "global.h" +#include "pokemon.h" +#include "save_block_2.h" struct Pokedex { diff --git a/include/pokemon.h b/include/pokemon.h index 097df9e0..d107bf85 100644 --- a/include/pokemon.h +++ b/include/pokemon.h @@ -142,8 +142,8 @@ struct PartyPokemon /* 0x096 */ u16 speed; /* 0x098 */ u16 spatk; /* 0x09A */ u16 spdef; - /* 0x09C */ struct Mail seal_something; // a struct? - /* 0x0D4 */ u8 sealCoords[0x18]; // u8 pairs? + /* 0x09C */ struct Mail mail; + /* 0x0D4 */ u8 sealCoords[8][3]; // seal coords }; struct Pokemon { @@ -263,6 +263,7 @@ void FUN_02069038(u32 a0, u32 a1, u32 a2, s32 a3, u32 a4, u32 a5, u32 a6); void FUN_020690AC(struct SomeDrawPokemonStruct * a0, u32 a1); u32 FUN_020690C4(void); u32 FUN_020690C8(void); +u8 GetBoxMonUnownLetter(struct BoxPokemon * boxmon); u8 GetMonUnownLetter(struct Pokemon * pokemon); struct BoxPokemon * FUN_020690E4(struct Pokemon * pokemon); @@ -278,21 +279,21 @@ u32 FUN_02069818(struct Pokemon * pokemon, u32 * r5, u16 * sp0); void FUN_020698E0(struct Pokemon * pokemon, int slot1, int slot2); void FUN_020698E8(struct BoxPokemon * boxmon, int slot1, int slot2); void FUN_020699A4(struct Pokemon * pokemon, u32 slot); -void FUN_02069A64(struct BoxPokemon * src, struct Pokemon * dest); -u8 FUN_02069AEC(struct PlayerParty * party); +void CopyBoxPokemonToPokemon(struct BoxPokemon * src, struct Pokemon * dest); +u8 Party_GetMaxLevel(struct PlayerParty * party); u16 SpeciesToSinnohDexNo(u16 species); -u16 FUN_02069B60(u16 sinnoh_dex); -void FUN_02069B88(struct Pokemon * src, struct Pokemon * dest); -void FUN_02069BA0(struct Pokemon * src, struct BoxPokemon * dest); -void FUN_02069BB4(struct BoxPokemon * src, struct BoxPokemon * dest); -s8 FUN_02069BC8(struct Pokemon * pokemon, int flavor); -int FUN_02069BFC(u16 species, u32 forme, u16 * dest); -void FUN_02069C4C(struct PlayerParty * party); -void FUN_02069D50(struct PlayerParty * party, int r5); -void FUN_02069DC8(struct PlayerParty * party); -BOOL FUN_02069E74(struct Pokemon * pokemon); -BOOL FUN_02069E94(struct Pokemon * pokemon); -void FUN_02069EC4(struct Pokemon * pokemon); +u16 SinnohDexNoToSpecies(u16 sinnoh_dex); +void CopyPokemonToPokemon(struct Pokemon * src, struct Pokemon * dest); +void CopyPokemonToBoxPokemon(struct Pokemon * src, struct BoxPokemon * dest); +void CopyBoxPokemonToBoxPokemon(struct BoxPokemon * src, struct BoxPokemon * dest); +s8 MonGetFlavorPreference(struct Pokemon * pokemon, int flavor); +int Species_LoadLearnsetTable(u16 species, u32 forme, u16 * dest); +void Party_GivePokerusAtRandom(struct PlayerParty * party); +void Party_UpdatePokerus(struct PlayerParty * party, int r5); +void Party_SpreadPokerus(struct PlayerParty * party); +BOOL Pokemon_HasPokerus(struct Pokemon * pokemon); +BOOL Pokemon_IsImmuneToPokerus(struct Pokemon * pokemon); +void Pokemon_UpdateArceusForme(struct Pokemon * pokemon); void FUN_02069FB0(u32 r7, u32 r5, u32 r4, u32 r6, u32 sp18, u32 sp1C, u32 sp20); void FUN_0206A014(struct Pokemon * pokemon, struct PlayerData * a1, u32 pokeball, u32 a3, u32 encounterType, u32 heap_id); void FUN_0206A094(struct Pokemon * pokemon, u32 a1, u32 a2); @@ -304,7 +305,7 @@ BOOL IsPokemonLegendaryOrMythical(u16 species); u16 GetLegendaryMon(u32 idx); BOOL FUN_0206A998(struct Pokemon * pokemon); BOOL FUN_0206A9AC(struct BoxPokemon * boxmon, struct PlayerData * sb2, u32 heap_id); -void FUN_0206AA84(struct Pokemon * pokemon); +void Pokemon_RemoveCapsule(struct Pokemon * pokemon); void RestoreBoxMonPP(struct BoxPokemon * boxmon); #endif //POKEDIAMOND_POKEMON_H diff --git a/include/proto.h b/include/proto.h index 365c0ecd..7af3f19d 100644 --- a/include/proto.h +++ b/include/proto.h @@ -7,7 +7,7 @@ #include "string16.h" // for struct definitions #include "player_data.h" // for struct definitions -int FUN_0206AE00(int x); +int TrainerClass_GetGenderOrTrainerCount(int x); int FUN_02014C3C(u8); void FUN_02014C54(int, int, struct UnkStruct_02069038 *, u8); u32 IsNighttime(void); // is day or night diff --git a/include/seal.h b/include/seal.h new file mode 100644 index 00000000..9e31e2e4 --- /dev/null +++ b/include/seal.h @@ -0,0 +1,24 @@ +#ifndef POKEDIAMOND_SEAL_H +#define POKEDIAMOND_SEAL_H + +typedef u8 Coords8[3]; +typedef Coords8 CapsuleArray[8]; + +struct SealCase +{ + CapsuleArray coords[12]; + u8 padding_120[0x50]; +}; + +u32 FUN_02029C58(void); +void FUN_02029C60(struct SealCase * sealCase); +void FUN_02029C74(const CapsuleArray * a0, CapsuleArray * a1); +struct SealCase * FUN_02029C80(struct SaveBlock2 * sav2); +CapsuleArray * FUN_02029C8C(struct SealCase * sealCase, s32 idx); +void FUN_02029CA4(struct SealCase * sealCase, const CapsuleArray * src, s32 idx); +Coords8 * FUN_02029CC8(CapsuleArray * a0, s32 a1); +u8 FUN_02029CE0(Coords8 * a0); +u8 FUN_02029CE4(Coords8 * a0); +u8 FUN_02029CE8(Coords8 * a0); + +#endif //POKEDIAMOND_SEAL_H diff --git a/include/trainer_data.h b/include/trainer_data.h index 6a5b69a4..0951a5dd 100644 --- a/include/trainer_data.h +++ b/include/trainer_data.h @@ -2,6 +2,8 @@ #define POKEDIAMOND_TRAINER_DATA_H #include "global.h" +#include "save_block_2.h" +#include "string16.h" #include "constants/pokemon.h" struct TrainerMonSpecies @@ -57,7 +59,7 @@ struct TrainerData u8 npoke; u16 items[4]; u32 unk_C; - u32 unk_10; + u32 doubleBattle; }; struct TrainerDataLoaded @@ -76,4 +78,13 @@ struct EnemyTrainerSet struct TrainerDataLoaded datas[4]; }; +void EnemyTrainerSet_Init(struct EnemyTrainerSet * sp0, struct SaveBlock2 * r4, u32 sp4); +s32 TrainerData_GetAttr(u32 tr_idx, u32 attr_no); +BOOL TrainerMessageWithIdPairExists(u32 pos, u32 idx, u32 heap_id); +void GetTrainerMessageByIdPair(u32 pos, u32 idx, struct String * str, u32 heap_id); +void TrainerData_ReadTrData(u32 idx, struct TrainerData * dest); +void TrainerData_ReadTrPoke(u32 idx, union TrainerMon * dest); +int TrainerClass_GetGenderOrTrainerCount(int a0); +void CreateNPCTrainerParty(struct EnemyTrainerSet * enemies, s32 party_id, u32 heap_id); + #endif //POKEDIAMOND_TRAINER_DATA_H diff --git a/include/unk_0206B688.h b/include/unk_0206B688.h new file mode 100644 index 00000000..cf8136b1 --- /dev/null +++ b/include/unk_0206B688.h @@ -0,0 +1,21 @@ +#ifndef POKEDIAMOND_UNK_0206B688_H +#define POKEDIAMOND_UNK_0206B688_H + +#include "pokemon.h" + +u32 FUN_0206B688(struct BoxPokemon * boxmon); +u32 FUN_0206B6C8(struct Pokemon * pokemon); +u32 FUN_0206B6D4(u32 species, u32 is_egg, u32 forme); +u16 BoxMon_GetAlternateForme(struct BoxPokemon * boxmon); +u32 FUN_0206B7BC(u32 species, u32 forme, u32 is_egg); +u32 FUN_0206B83C(struct BoxPokemon * boxmon); +u32 FUN_0206B87C(struct Pokemon * pokemon); +u32 FUN_0206B888(void); +u32 FUN_0206B88C(void); +u32 FUN_0206B890(void); +u32 FUN_0206B894(void); +u32 FUN_0206B898(void); +u32 FUN_0206B89C(void); +u32 FUN_0206B8A0(void); + +#endif //POKEDIAMOND_UNK_0206B688_H diff --git a/include/unk_0206BB28.h b/include/unk_0206BB28.h new file mode 100644 index 00000000..ff60e220 --- /dev/null +++ b/include/unk_0206BB28.h @@ -0,0 +1,12 @@ +#ifndef POKEDIAMOND_UNK_0206BB28_H +#define POKEDIAMOND_UNK_0206BB28_H + +#include "save_block_2.h" +#include "pokedex.h" +#include "pokemon.h" + +BOOL FUN_0206BB28(struct SaveBlock2 * sav2); +BOOL FUN_0206BB34(struct Pokedex * pokedex); +u32 FUN_0206BB48(BOOL isNationalDex, u32 species); + +#endif //POKEDIAMOND_UNK_0206BB28_H |