This commit is contained in:
GriffinR
2019-08-06 13:52:10 -04:00
committed by huderlem
parent d931ba9602
commit 5fb7ab05dd
7 changed files with 48 additions and 49 deletions

View File

@@ -50,6 +50,8 @@
#define PYRAMID_BAG_ITEMS_COUNT 10
#define HALL_FACILITIES_COUNT 9 // 7 facilities for single mode + tower double mode + tower multi mode.
#define TRAINER_ID_LENGTH 4
// string lengths
#define ITEM_NAME_LENGTH 14
#define POKEMON_NAME_LENGTH 10

View File

@@ -10,6 +10,8 @@
#define LILYCOVE_LADY_STATE_COMPLETED 1
#define LILYCOVE_LADY_STATE_PRIZE 2
#define LILYCOVE_LADY_GIFT_THRESHOLD 5
#define QUIZ_AUTHOR_PLAYER 0
#define QUIZ_AUTHOR_OTHER_PLAYER 1
#define QUIZ_AUTHOR_LADY 2
@@ -18,13 +20,7 @@
#define QUIZ_AUTHOR_NAME_LADY 0
#define QUIZ_AUTHOR_NAME_PLAYER 1
#define QUIZ_AUTHOR_NAME_OTHER_PLAYER 2
// TODO use array count macro?
#define QUIZ_QUESTION_LEN 9 //ARRAY_COUNT(sQuizLadyQuestion#)
#define NUM_QUIZ_QUESTIONS 16 //ARRAY_COUNT(sQuizLadyQuizQuestions)
#define FAVOR_DESCRIPTION_NUM 6 //ARRAY_COUNT(sFavorLadyDescriptions)
#define LILYCOVE_LADY_GIFT_THRESHOLD 5
#define QUIZ_QUESTION_LEN 9
#endif

View File

@@ -224,7 +224,7 @@ struct Apprentice
u8 number;
struct ApprenticeMon party[3];
u16 easyChatWords[6];
u8 playerId[4];
u8 playerId[TRAINER_ID_LENGTH];
u8 playerName[PLAYER_NAME_LENGTH];
u8 language;
u32 checksum;
@@ -263,7 +263,7 @@ struct EmeraldBattleTowerRecord
/*0x01*/ u8 facilityClass;
/*0x02*/ u16 winStreak;
/*0x04*/ u8 name[PLAYER_NAME_LENGTH + 1];
/*0x0C*/ u8 trainerId[4];
/*0x0C*/ u8 trainerId[TRAINER_ID_LENGTH];
/*0x10*/ u16 greeting[6];
/*0x1C*/ u16 speechWon[6];
/*0x28*/ u16 speechLost[6];
@@ -278,7 +278,7 @@ struct BattleTowerEReaderTrainer
/*0x01*/ u8 facilityClass;
/*0x02*/ u16 winStreak;
/*0x04*/ u8 name[PLAYER_NAME_LENGTH + 1];
/*0x0C*/ u8 trainerId[4];
/*0x0C*/ u8 trainerId[TRAINER_ID_LENGTH];
/*0x10*/ u16 greeting[6];
/*0x1C*/ u16 farewellPlayerLost[6];
/*0x28*/ u16 farewellPlayerWon[6];
@@ -425,7 +425,7 @@ struct PlayersApprentice
struct RankingHall1P
{
u8 id[4];
u8 id[TRAINER_ID_LENGTH];
u16 winStreak;
u8 name[PLAYER_NAME_LENGTH + 1];
u8 language;
@@ -433,8 +433,8 @@ struct RankingHall1P
struct RankingHall2P
{
u8 id1[4];
u8 id2[4];
u8 id1[TRAINER_ID_LENGTH];
u8 id2[TRAINER_ID_LENGTH];
u16 winStreak;
u8 name1[PLAYER_NAME_LENGTH + 1];
u8 name2[PLAYER_NAME_LENGTH + 1];
@@ -446,7 +446,7 @@ struct SaveBlock2
/*0x00*/ u8 playerName[PLAYER_NAME_LENGTH + 1];
/*0x08*/ u8 playerGender; // MALE, FEMALE
/*0x09*/ u8 specialSaveWarpFlags;
/*0x0A*/ u8 playerTrainerId[4];
/*0x0A*/ u8 playerTrainerId[TRAINER_ID_LENGTH];
/*0x0E*/ u16 playTimeHours;
/*0x10*/ u8 playTimeMinutes;
/*0x11*/ u8 playTimeSeconds;
@@ -495,7 +495,7 @@ struct SecretBase
/*0x1A9D*/ u8 battledOwnerToday:1;
/*0x1A9D*/ u8 registryStatus:2;
/*0x1A9E*/ u8 trainerName[PLAYER_NAME_LENGTH];
/*0x1AA5*/ u8 trainerId[4]; // byte 0 is used for determining trainer class
/*0x1AA5*/ u8 trainerId[TRAINER_ID_LENGTH]; // byte 0 is used for determining trainer class
/*0x1AA9*/ u8 language;
/*0x1AAA*/ u16 numSecretBasesReceived;
/*0x1AAC*/ u8 numTimesEntered;
@@ -581,7 +581,7 @@ struct MailStruct
{
/*0x00*/ u16 words[MAIL_WORDS_COUNT];
/*0x12*/ u8 playerName[PLAYER_NAME_LENGTH + 1];
/*0x1A*/ u8 trainerId[4];
/*0x1A*/ u8 trainerId[TRAINER_ID_LENGTH];
/*0x1E*/ u16 species;
/*0x20*/ u16 itemId;
};
@@ -598,7 +598,7 @@ struct MauvilleManBard
/*0x0E*/ u16 temporaryLyrics[6];
/*0x1A*/ u8 playerName[8];
/*0x22*/ u8 filler_2DB6[0x3];
/*0x25*/ u8 playerTrainerId[4];
/*0x25*/ u8 playerTrainerId[TRAINER_ID_LENGTH];
/*0x29*/ bool8 hasChangedSong;
/*0x2A*/ u8 language;
}; /*size = 0x2C*/
@@ -745,7 +745,7 @@ struct LilycoveLadyQuiz
/*0x014*/ u16 correctAnswer;
/*0x016*/ u16 playerAnswer;
/*0x018*/ u8 playerName[PLAYER_NAME_LENGTH + 1];
/*0x020*/ u16 playerTrainerId[4];
/*0x020*/ u16 playerTrainerId[TRAINER_ID_LENGTH];
/*0x028*/ u16 prize;
/*0x02a*/ bool8 waitingForChallenger;
/*0x02b*/ u8 questionId;