From a496a763ca54871e19e2482b550127e2aa709b05 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Sat, 13 Oct 2018 20:38:46 +0200 Subject: Merge record mixing, pokemon and global with apprentice --- include/apprentice.h | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 include/apprentice.h (limited to 'include/apprentice.h') diff --git a/include/apprentice.h b/include/apprentice.h new file mode 100644 index 000000000..98185e3c2 --- /dev/null +++ b/include/apprentice.h @@ -0,0 +1,17 @@ +#ifndef GUARD_APPRENTICE_H +#define GUARD_APPRENTICE_H + +#define APPRENTICE_SPECIES_COUNT 10 + +struct ApprenticeTrainer +{ + u8 name[6][PLAYER_NAME_LENGTH + 1]; // For all six languages. + u16 otId; + u16 facilityClass; + u16 species[APPRENTICE_SPECIES_COUNT]; + u8 rest[14]; +}; + +extern const struct ApprenticeTrainer gApprentices[]; + +#endif // GUARD_APPRENTICE_H -- cgit v1.2.3 From b4a42a6832e851f457636da61fceb530b77962f9 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Sun, 14 Oct 2018 11:37:44 +0200 Subject: Decompile apprentice --- include/apprentice.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'include/apprentice.h') diff --git a/include/apprentice.h b/include/apprentice.h index 98185e3c2..86c6250a0 100644 --- a/include/apprentice.h +++ b/include/apprentice.h @@ -7,11 +7,13 @@ struct ApprenticeTrainer { u8 name[6][PLAYER_NAME_LENGTH + 1]; // For all six languages. u16 otId; - u16 facilityClass; + u8 facilityClass; u16 species[APPRENTICE_SPECIES_COUNT]; u8 rest[14]; }; extern const struct ApprenticeTrainer gApprentices[]; +const u8 *GetApprenticeNameInLanguage(u32 apprenticeId, s32 language); + #endif // GUARD_APPRENTICE_H -- cgit v1.2.3 From 145df4906326488874b3f75ef96f99e85b18f2a0 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Sun, 14 Oct 2018 14:35:51 +0200 Subject: Document more of apprentice --- include/apprentice.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/apprentice.h') diff --git a/include/apprentice.h b/include/apprentice.h index 86c6250a0..90383b737 100644 --- a/include/apprentice.h +++ b/include/apprentice.h @@ -14,6 +14,7 @@ struct ApprenticeTrainer extern const struct ApprenticeTrainer gApprentices[]; +void CopyFriendsApprenticeChallengeText(u8 saveblockApprenticeId); const u8 *GetApprenticeNameInLanguage(u32 apprenticeId, s32 language); #endif // GUARD_APPRENTICE_H -- cgit v1.2.3 From f47ed3268c76b43db4bce0a60f355b18d0edc875 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Sun, 14 Oct 2018 17:00:41 +0200 Subject: Finish documenting apprentice for now --- include/apprentice.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'include/apprentice.h') diff --git a/include/apprentice.h b/include/apprentice.h index 90383b737..ca0b04800 100644 --- a/include/apprentice.h +++ b/include/apprentice.h @@ -15,6 +15,10 @@ struct ApprenticeTrainer extern const struct ApprenticeTrainer gApprentices[]; void CopyFriendsApprenticeChallengeText(u8 saveblockApprenticeId); +void Apprentice_EnableBothScriptContexts(void); +void ResetApprenticeStruct(struct Apprentice *apprentice); +void ResetAllApprenticeData(void); +void CallApprenticeFunction(void); const u8 *GetApprenticeNameInLanguage(u32 apprenticeId, s32 language); #endif // GUARD_APPRENTICE_H -- cgit v1.2.3