Document union_room_chat.c

This commit is contained in:
GriffinR 2020-06-01 14:05:29 -04:00
parent f53e2491bf
commit 7632404ba5
24 changed files with 1643 additions and 1269 deletions

View File

@ -1,95 +1,183 @@
#ifndef GUARD_TEXT_H #ifndef GUARD_TEXT_H
#define GUARD_TEXT_H #define GUARD_TEXT_H
#define CHAR_SPACE 0x00 #define CHAR_SPACE 0x00
#define CHAR_PLUS 0x2E #define CHAR_A_GRAVE 0x01
#define CHAR_0 0xA1 #define CHAR_A_ACUTE 0x02
#define CHAR_1 0xA2 #define CHAR_A_CIRCUMFLEX 0x03
#define CHAR_2 0xA3 #define CHAR_C_CEDILLA 0x04
#define CHAR_3 0xA4 #define CHAR_E_GRAVE 0x05
#define CHAR_4 0xA5 #define CHAR_E_ACUTE 0x06
#define CHAR_5 0xA6 #define CHAR_E_CIRCUMFLEX 0x07
#define CHAR_6 0xA7 #define CHAR_E_DIAERESIS 0x08
#define CHAR_7 0xA8 #define CHAR_I_GRAVE 0x09
#define CHAR_8 0xA9 //#define CHAR_I_ACUTE 0x0A // Is 0x5A instead
#define CHAR_9 0xAA #define CHAR_I_CIRCUMFLEX 0x0B
#define CHAR_EXCL_MARK 0xAB #define CHAR_I_DIAERESIS 0x0C
#define CHAR_QUESTION_MARK 0xAC #define CHAR_O_GRAVE 0x0D
#define CHAR_PERIOD 0xAD #define CHAR_O_ACUTE 0x0E
#define CHAR_HYPHEN 0xAE #define CHAR_O_CIRCUMFLEX 0x0F
#define CHAR_ELLIPSIS 0xB0 #define CHAR_OE 0x10
#define CHAR_DBL_QUOT_LEFT 0xB1 #define CHAR_U_GRAVE 0x11
#define CHAR_DBL_QUOT_RIGHT 0xB2 #define CHAR_U_ACUTE 0x12
#define CHAR_SGL_QUOT_LEFT 0xB3 #define CHAR_U_CIRCUMFLEX 0x13
#define CHAR_SGL_QUOT_RIGHT 0xB4 #define CHAR_N_TILDE 0x14
#define CHAR_MALE 0xB5 #define CHAR_ESZETT 0x15
#define CHAR_FEMALE 0xB6 #define CHAR_a_GRAVE 0x16
#define CHAR_CURRENCY 0xB7 #define CHAR_a_ACUTE 0x17
#define CHAR_COMMA 0xB8 //#define CHAR_a_CIRCUMFLEX 0x18 // Is 0x68 instead
#define CHAR_MULT_SIGN 0xB9 #define CHAR_c_CEDILLA 0x19
#define CHAR_SLASH 0xBA #define CHAR_e_GRAVE 0x1A
#define CHAR_A 0xBB #define CHAR_e_ACUTE 0x1B
#define CHAR_B 0xBC #define CHAR_e_CIRCUMFLEX 0x1C
#define CHAR_C 0xBD #define CHAR_e_DIAERESIS 0x1D
#define CHAR_D 0xBE #define CHAR_i_GRAVE 0x1E
#define CHAR_E 0xBF //#define CHAR_i_ACUTE 0x1F // Is 0x6F instead
#define CHAR_F 0xC0 #define CHAR_i_CIRCUMFLEX 0x20
#define CHAR_G 0xC1 #define CHAR_i_DIAERESIS 0x21
#define CHAR_H 0xC2 #define CHAR_o_GRAVE 0x22
#define CHAR_I 0xC3 #define CHAR_o_ACUTE 0x23
#define CHAR_J 0xC4 #define CHAR_o_CIRCUMFLEX 0x24
#define CHAR_K 0xC5 #define CHAR_oe 0x25
#define CHAR_L 0xC6 #define CHAR_u_GRAVE 0x26
#define CHAR_M 0xC7 #define CHAR_u_ACUTE 0x27
#define CHAR_N 0xC8 #define CHAR_u_CIRCUMFLEX 0x28
#define CHAR_O 0xC9 #define CHAR_n_TILDE 0x29
#define CHAR_P 0xCA #define CHAR_MASCULINE_ORDINAL 0x2A
#define CHAR_Q 0xCB #define CHAR_FEMININE_ORDINAL 0x2B
#define CHAR_R 0xCC #define CHAR_SUPER_ER 0x2C
#define CHAR_S 0xCD #define CHAR_AMPERSAND 0x2D
#define CHAR_T 0xCE #define CHAR_PLUS 0x2E
#define CHAR_U 0xCF //
#define CHAR_V 0xD0 #define CHAR_LV 0x34
#define CHAR_W 0xD1 #define CHAR_EQUALS 0x35
#define CHAR_X 0xD2 #define CHAR_SEMICOLON 0x36
#define CHAR_Y 0xD3 //
#define CHAR_Z 0xD4 #define CHAR_INV_QUESTION_MARK 0x51
#define CHAR_a 0xD5 #define CHAR_INV_EXCL_MARK 0x52
#define CHAR_b 0xD6 #define CHAR_PK 0x53
#define CHAR_c 0xD7 #define CHAR_MN 0x54
#define CHAR_d 0xD8 #define CHAR_PO 0x55
#define CHAR_e 0xD9 #define CHAR_KE 0x56
#define CHAR_f 0xDA #define CHAR_BLOCK_1 0x57 // Each of these 3
#define CHAR_g 0xDB #define CHAR_BLOCK_2 0x58 // chars contains 1/3
#define CHAR_h 0xDC #define CHAR_BLOCK_3 0x59 // of the word BLOCK
#define CHAR_i 0xDD #define CHAR_I_ACUTE 0x5A
#define CHAR_j 0xDE #define CHAR_PERCENT 0x5B
#define CHAR_k 0xDF #define CHAR_LEFT_PAREN 0x5C
#define CHAR_l 0xE0 #define CHAR_RIGHT_PAREN 0x5D
#define CHAR_m 0xE1 //
#define CHAR_n 0xE2 #define CHAR_a_CIRCUMFLEX 0x68
#define CHAR_o 0xE3 //
#define CHAR_p 0xE4 #define CHAR_i_ACUTE 0x6F
#define CHAR_q 0xE5 //
#define CHAR_r 0xE6 #define CHAR_UNK_SPACER 0x77
#define CHAR_s 0xE7 //
#define CHAR_t 0xE8 #define CHAR_UP_ARROW 0x79
#define CHAR_u 0xE9 #define CHAR_DOWN_ARROW 0x7A
#define CHAR_v 0xEA #define CHAR_LEFT_ARROW 0x7B
#define CHAR_w 0xEB #define CHAR_RIGHT_ARROW 0x7C
#define CHAR_x 0xEC //
#define CHAR_y 0xED #define CHAR_SUPER_E 0x84
#define CHAR_z 0xEE #define CHAR_LESS_THAN 0x85
#define CHAR_SPECIAL_F7 0xF7 #define CHAR_GREATER_THAN 0x86
#define CHAR_SPECIAL_F8 0xF8 //
#define CHAR_SPECIAL_F9 0xF9 #define CHAR_SUPER_RE 0xA0
#define CHAR_COLON 0xF0 #define CHAR_0 0xA1
#define CHAR_PROMPT_SCROLL 0xFA // waits for button press and scrolls dialog #define CHAR_1 0xA2
#define CHAR_PROMPT_CLEAR 0xFB // waits for button press and clears dialog #define CHAR_2 0xA3
#define EXT_CTRL_CODE_BEGIN 0xFC // extended control code #define CHAR_3 0xA4
#define PLACEHOLDER_BEGIN 0xFD // string placeholder #define CHAR_4 0xA5
#define CHAR_NEWLINE 0xFE #define CHAR_5 0xA6
#define EOS 0xFF // end of string #define CHAR_6 0xA7
#define CHAR_7 0xA8
#define CHAR_8 0xA9
#define CHAR_9 0xAA
#define CHAR_EXCL_MARK 0xAB
#define CHAR_QUESTION_MARK 0xAC
#define CHAR_PERIOD 0xAD
#define CHAR_HYPHEN 0xAE
#define CHAR_BULLET 0xAF
#define CHAR_ELLIPSIS 0xB0
#define CHAR_DBL_QUOT_LEFT 0xB1
#define CHAR_DBL_QUOT_RIGHT 0xB2
#define CHAR_SGL_QUOT_LEFT 0xB3
#define CHAR_SGL_QUOT_RIGHT 0xB4
#define CHAR_MALE 0xB5
#define CHAR_FEMALE 0xB6
#define CHAR_CURRENCY 0xB7
#define CHAR_COMMA 0xB8
#define CHAR_MULT_SIGN 0xB9
#define CHAR_SLASH 0xBA
#define CHAR_A 0xBB
#define CHAR_B 0xBC
#define CHAR_C 0xBD
#define CHAR_D 0xBE
#define CHAR_E 0xBF
#define CHAR_F 0xC0
#define CHAR_G 0xC1
#define CHAR_H 0xC2
#define CHAR_I 0xC3
#define CHAR_J 0xC4
#define CHAR_K 0xC5
#define CHAR_L 0xC6
#define CHAR_M 0xC7
#define CHAR_N 0xC8
#define CHAR_O 0xC9
#define CHAR_P 0xCA
#define CHAR_Q 0xCB
#define CHAR_R 0xCC
#define CHAR_S 0xCD
#define CHAR_T 0xCE
#define CHAR_U 0xCF
#define CHAR_V 0xD0
#define CHAR_W 0xD1
#define CHAR_X 0xD2
#define CHAR_Y 0xD3
#define CHAR_Z 0xD4
#define CHAR_a 0xD5
#define CHAR_b 0xD6
#define CHAR_c 0xD7
#define CHAR_d 0xD8
#define CHAR_e 0xD9
#define CHAR_f 0xDA
#define CHAR_g 0xDB
#define CHAR_h 0xDC
#define CHAR_i 0xDD
#define CHAR_j 0xDE
#define CHAR_k 0xDF
#define CHAR_l 0xE0
#define CHAR_m 0xE1
#define CHAR_n 0xE2
#define CHAR_o 0xE3
#define CHAR_p 0xE4
#define CHAR_q 0xE5
#define CHAR_r 0xE6
#define CHAR_s 0xE7
#define CHAR_t 0xE8
#define CHAR_u 0xE9
#define CHAR_v 0xEA
#define CHAR_w 0xEB
#define CHAR_x 0xEC
#define CHAR_y 0xED
#define CHAR_z 0xEE
#define CHAR_BLACK_TRIANGLE 0xEF
#define CHAR_COLON 0xF0
#define CHAR_A_DIAERESIS 0xF1
#define CHAR_O_DIAERESIS 0xF2
#define CHAR_U_DIAERESIS 0xF3
#define CHAR_a_DIAERESIS 0xF4
#define CHAR_o_DIAERESIS 0xF5
#define CHAR_u_DIAERESIS 0xF6
#define CHAR_SPECIAL_F7 0xF7
#define CHAR_SPECIAL_F8 0xF8
#define CHAR_SPECIAL_F9 0xF9
#define CHAR_PROMPT_SCROLL 0xFA // waits for button press and scrolls dialog
#define CHAR_PROMPT_CLEAR 0xFB // waits for button press and clears dialog
#define EXT_CTRL_CODE_BEGIN 0xFC // extended control code
#define PLACEHOLDER_BEGIN 0xFD // string placeholder
#define CHAR_NEWLINE 0xFE
#define EOS 0xFF // end of string
// Special F9 chars // Special F9 chars
#define CHAR_UP_ARROW_2 0x00 #define CHAR_UP_ARROW_2 0x00

View File

Before

Width:  |  Height:  |  Size: 513 B

After

Width:  |  Height:  |  Size: 513 B

View File

Before

Width:  |  Height:  |  Size: 189 B

After

Width:  |  Height:  |  Size: 189 B

View File

Before

Width:  |  Height:  |  Size: 307 B

After

Width:  |  Height:  |  Size: 307 B

View File

Before

Width:  |  Height:  |  Size: 188 B

After

Width:  |  Height:  |  Size: 188 B

View File

Before

Width:  |  Height:  |  Size: 247 B

After

Width:  |  Height:  |  Size: 247 B

View File

Before

Width:  |  Height:  |  Size: 157 B

After

Width:  |  Height:  |  Size: 157 B

View File

Before

Width:  |  Height:  |  Size: 146 B

After

Width:  |  Height:  |  Size: 146 B

View File

@ -52,6 +52,7 @@
#define APPRENTICE_COUNT 4 #define APPRENTICE_COUNT 4
#define APPRENTICE_MAX_QUESTIONS 9 #define APPRENTICE_MAX_QUESTIONS 9
#define MAX_REMATCH_ENTRIES 100 // only REMATCH_TABLE_ENTRIES (78) are used #define MAX_REMATCH_ENTRIES 100 // only REMATCH_TABLE_ENTRIES (78) are used
#define UNION_ROOM_KB_ROW_COUNT 10
#define PYRAMID_BAG_ITEMS_COUNT 10 #define PYRAMID_BAG_ITEMS_COUNT 10
#define HALL_FACILITIES_COUNT 9 // 7 facilities for single mode + tower double mode + tower multi mode. #define HALL_FACILITIES_COUNT 9 // 7 facilities for single mode + tower double mode + tower multi mode.

View File

@ -974,7 +974,7 @@ struct SaveBlock1
/*0x3B24*/ u8 seen2[DEX_FLAGS_NO]; /*0x3B24*/ u8 seen2[DEX_FLAGS_NO];
/*0x3B58*/ LilycoveLady lilycoveLady; /*0x3B58*/ LilycoveLady lilycoveLady;
/*0x3B98*/ struct TrainerNameRecord trainerNameRecords[20]; /*0x3B98*/ struct TrainerNameRecord trainerNameRecords[20];
/*0x3C88*/ u8 unk3C88[10][21]; /*0x3C88*/ u8 registeredTexts[UNION_ROOM_KB_ROW_COUNT][21];
/*0x3D5A*/ u8 filler3D5A[0xA]; /*0x3D5A*/ u8 filler3D5A[0xA];
/*0x3D64*/ struct SaveTrainerHill trainerHill; /*0x3D64*/ struct SaveTrainerHill trainerHill;
/*0x3D70*/ struct WaldaPhrase waldaPhrase; /*0x3D70*/ struct WaldaPhrase waldaPhrase;

View File

@ -4986,14 +4986,14 @@ extern const u16 gEasyChatRightWindow_Pal[];
extern const u32 gUsePokeblockCondition_Gfx[]; extern const u32 gUsePokeblockCondition_Gfx[];
// Union Room Chat // Union Room Chat
extern const u16 gUnknown_08DD4BB0[]; extern const u16 gUnionRoomChat_Background_Pal[];
extern const u16 gUnknown_08DD4BD0[]; extern const u32 gUnionRoomChat_Background_Gfx[];
extern const u32 gUnknown_08DD4BF0[]; extern const u32 gUnionRoomChat_Background_Tilemap[];
extern const u32 gUnknown_08DD4C4C[]; extern const u16 gUnionRoomChat_Window_Pal1[];
extern const u32 gUnknown_08DD4CF8[]; extern const u16 gUnionRoomChat_Window_Pal2[];
extern const u16 gLinkMiscMenu_Pal[]; extern const u32 gUnionRoomChat_Border_Gfx[];
extern const u32 gLinkMiscMenu_Gfx[]; extern const u32 gUnionRoomChat_Border_Tilemap[];
extern const u32 gLinkMiscMenu_Tilemap[]; extern const u32 gUnionRoomChat_RButtonLabels[];
// Use Pokeblock // Use Pokeblock
extern const u8 gPokenavConditionCancel_Gfx[]; extern const u8 gPokenavConditionCancel_Gfx[];

View File

@ -2815,10 +2815,10 @@ extern const u8 gText_RegisterTextHere[];
extern const u8 gText_InputText[]; extern const u8 gText_InputText[];
extern const u8 gText_ExitingChat[]; extern const u8 gText_ExitingChat[];
extern const u8 gText_LeaderLeftEndingChat[]; extern const u8 gText_LeaderLeftEndingChat[];
extern const u8 gText_RegisteredTextChanged[]; extern const u8 gText_RegisteredTextChangedOKToSave[];
extern const u8 gText_AlreadySavedFile_Unused[]; extern const u8 gText_AlreadySavedFile_Chat[];
extern const u8 gText_SavingDontTurnOff_Unused[]; extern const u8 gText_SavingDontTurnOff_Chat[];
extern const u8 gText_PlayerSavedGame_Unused[]; extern const u8 gText_PlayerSavedGame_Chat[];
extern const u8 gText_IfLeaderLeavesChatEnds[]; extern const u8 gText_IfLeaderLeavesChatEnds[];
extern const u8 gText_Upper[]; extern const u8 gText_Upper[];
extern const u8 gText_Lower[]; extern const u8 gText_Lower[];

View File

@ -1,18 +1,7 @@
#ifndef GUARD_UNION_ROOM_CHAT_H #ifndef GUARD_UNION_ROOM_CHAT_H
#define GUARD_UNION_ROOM_CHAT_H #define GUARD_UNION_ROOM_CHAT_H
enum
{
UNION_ROOM_KB_PAGE_UPPER,
UNION_ROOM_KB_PAGE_LOWER,
UNION_ROOM_KB_PAGE_EMOJI,
UNION_ROOM_KB_PAGE_COUNT
};
#define UNION_ROOM_KB_ROW_COUNT 10
void EnterUnionRoomChat(void); void EnterUnionRoomChat(void);
void copy_strings_to_sav1(void); void InitUnionRoomChatRegisteredTexts(void);
#endif // GUARD_UNION_ROOM_CHAT_H #endif // GUARD_UNION_ROOM_CHAT_H

View File

@ -1447,19 +1447,15 @@ const u32 gUnknown_08DD4620[] = INCBIN_U32("graphics/unknown/unknown_DD4620.bin.
const u32 gUnknown_08DD46E0[] = INCBIN_U32("graphics/unknown/unknown_DD46E0.bin.lz"); const u32 gUnknown_08DD46E0[] = INCBIN_U32("graphics/unknown/unknown_DD46E0.bin.lz");
const u32 gUnknown_08DD47A0[] = INCBIN_U32("graphics/unknown/unknown_DD47A0.bin.lz"); const u32 gUnknown_08DD47A0[] = INCBIN_U32("graphics/unknown/unknown_DD47A0.bin.lz");
// link // union room chat
const u16 gUnionRoomChat_Background_Pal[] = INCBIN_U16("graphics/union_room_chat/background.gbapal");
const u16 gLinkMiscMenu_Pal[] = INCBIN_U16("graphics/link/misc.gbapal"); const u32 gUnionRoomChat_Background_Gfx[] = INCBIN_U32("graphics/union_room_chat/background.4bpp.lz");
const u32 gLinkMiscMenu_Gfx[] = INCBIN_U32("graphics/link/misc.4bpp.lz"); const u32 gUnionRoomChat_Background_Tilemap[] = INCBIN_U32("graphics/union_room_chat/background.bin.lz");
const u32 gLinkMiscMenu_Tilemap[] = INCBIN_U32("graphics/link/misc.bin.lz"); const u16 gUnionRoomChat_Window_Pal1[] = INCBIN_U16("graphics/union_room_chat/window_1.gbapal");
const u16 gUnionRoomChat_Window_Pal2[] = INCBIN_U16("graphics/union_room_chat/window_2.gbapal");
const u16 gUnknown_08DD4BB0[] = INCBIN_U16("graphics/link/link1.gbapal"); const u32 gUnionRoomChat_Border_Gfx[] = INCBIN_U32("graphics/union_room_chat/border.4bpp.lz");
const u16 gUnknown_08DD4BD0[] = INCBIN_U16("graphics/link/link2.gbapal"); const u32 gUnionRoomChat_Border_Tilemap[] = INCBIN_U32("graphics/union_room_chat/border.bin.lz");
const u32 gUnionRoomChat_RButtonLabels[] = INCBIN_U32("graphics/union_room_chat/r_button_labels.4bpp.lz");
const u32 gUnknown_08DD4BF0[] = INCBIN_U32("graphics/link/link_winedge.4bpp.lz");
const u32 gUnknown_08DD4C4C[] = INCBIN_U32("graphics/link/link_winedge.bin.lz");
const u32 gUnknown_08DD4CF8[] = INCBIN_U32("graphics/interface/unk_change_case.4bpp.lz");
const u16 gTilesetPalettes_General[][16] = const u16 gTilesetPalettes_General[][16] =
{ {

View File

@ -197,7 +197,7 @@ void NewGameInitData(void)
WarpToTruck(); WarpToTruck();
ScriptContext2_RunNewScript(EventScript_ResetAllMapFlags); ScriptContext2_RunNewScript(EventScript_ResetAllMapFlags);
ResetMiniGamesResults(); ResetMiniGamesResults();
copy_strings_to_sav1(); InitUnionRoomChatRegisteredTexts();
InitLilycoveLady(); InitLilycoveLady();
ResetAllApprenticeData(); ResetAllApprenticeData();
ClearRankingHallRecords(); ClearRankingHallRecords();

View File

@ -1261,10 +1261,10 @@ const u8 gJPText_PlayersXPokemon[] = _("{SPECIAL_F7 0x00}の{SPECIAL_F7 0x01}ひ
const u8 gJPText_PlayersXPokmonDoesNotExist[] = _("{SPECIAL_F7 0x00}の{SPECIAL_F7 0x01}ひきめは いません"); // Unused const u8 gJPText_PlayersXPokmonDoesNotExist[] = _("{SPECIAL_F7 0x00}の{SPECIAL_F7 0x01}ひきめは いません"); // Unused
const u8 gText_ExitingChat[] = _("Exiting the chat…"); const u8 gText_ExitingChat[] = _("Exiting the chat…");
const u8 gText_LeaderLeftEndingChat[] = _("The LEADER, {SPECIAL_F7 0x00}, has\nleft, ending the chat."); const u8 gText_LeaderLeftEndingChat[] = _("The LEADER, {SPECIAL_F7 0x00}, has\nleft, ending the chat.");
const u8 gText_RegisteredTextChanged[] = _("The registered text has been changed.\nIs it okay to save the game?"); const u8 gText_RegisteredTextChangedOKToSave[] = _("The registered text has been changed.\nIs it okay to save the game?");
const u8 gText_AlreadySavedFile_Unused[] = _("There is already a saved file.\nIs it okay to overwrite it?"); const u8 gText_AlreadySavedFile_Chat[] = _("There is already a saved file.\nIs it okay to overwrite it?");
const u8 gText_SavingDontTurnOff_Unused[] = _("SAVING…\nDON'T TURN OFF THE POWER."); const u8 gText_SavingDontTurnOff_Chat[] = _("SAVING…\nDON'T TURN OFF THE POWER.");
const u8 gText_PlayerSavedGame_Unused[] = _("{SPECIAL_F7 0x00} saved the game."); const u8 gText_PlayerSavedGame_Chat[] = _("{SPECIAL_F7 0x00} saved the game.");
const u8 gText_IfLeaderLeavesChatEnds[] = _("If the LEADER leaves, the chat\nwill end. Is that okay?"); const u8 gText_IfLeaderLeavesChatEnds[] = _("If the LEADER leaves, the chat\nwill end. Is that okay?");
const u8 gText_Hello[] = _("HELLO"); const u8 gText_Hello[] = _("HELLO");
const u8 gText_Pokemon2[] = _("POKéMON"); const u8 gText_Pokemon2[] = _("POKéMON");

File diff suppressed because it is too large Load Diff