summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPikalaxALT <pikalaxalt@gmail.com>2020-01-25 16:17:51 -0500
committerPikalaxALT <pikalaxalt@gmail.com>2020-01-25 16:17:51 -0500
commit52c0e05abbd0b58c943d045a8457c45c72caac38 (patch)
tree83184630625158858cacc63a3cbbf4ae90e5603c /src
parent1f47b6ae4fefbe50a3680251fc9b88a7655e7179 (diff)
Static symbols resolution
Diffstat (limited to 'src')
-rw-r--r--src/union_room_chat.c145
-rw-r--r--src/union_room_chat_display.c230
-rw-r--r--src/union_room_chat_objects.c62
3 files changed, 218 insertions, 219 deletions
diff --git a/src/union_room_chat.c b/src/union_room_chat.c
index f8243f742..751e5c865 100644
--- a/src/union_room_chat.c
+++ b/src/union_room_chat.c
@@ -47,42 +47,41 @@ struct UnionRoomChat
u8 unk190[0x28];
};
-EWRAM_DATA struct UnionRoomChat * gUnknown_203B0E0 = NULL;
-
-void sub_812845C(struct UnionRoomChat * unionRoomChat);
-void c2_081284E0(void);
-void sub_81285B4(void);
-void sub_81285CC(void);
-void sub_81285E8(u8 taskId);
-void sub_8128640(void);
-void sub_81286C4(void);
-void sub_81287B4(void);
-void sub_81288D4(void);
-void sub_8128AA0(void);
-void sub_8128C04(void);
-void sub_8128CA8(void);
-void sub_8128DA4(void);
-void sub_8128E78(void);
-void sub_8128FB8(void);
-void sub_8129218(u16 a0);
-bool32 sub_8129228(void);
-void sub_81292D8(void);
-void sub_81293AC(void);
-void sub_81293D8(void);
-bool32 sub_8129408(void);
-void sub_8129424(void);
-void sub_8129454(void);
-void sub_8129470(void);
-u8 *sub_81294C8(void);
-u8 *sub_81294EC(void);
-void sub_8129560(u8 *ptr);
-void sub_8129568(u8 *ptr);
-void sub_8129590(u8 *ptr);
-void sub_81295C0(u8 *ptr);
-void sub_81295EC(u8 *ptr);
-void sub_8129614(u8 *ptr);
-u8 *sub_8129758(void);
-void sub_81298F8(u8 taskId);
+static EWRAM_DATA struct UnionRoomChat * gUnknown_203B0E0 = NULL;
+
+static void sub_812845C(struct UnionRoomChat * unionRoomChat);
+static void c2_081284E0(void);
+static void sub_81285B4(void);
+static void sub_81285CC(void);
+static void sub_81285E8(u8 taskId);
+static void sub_8128640(void);
+static void sub_81286C4(void);
+static void sub_81287B4(void);
+static void sub_81288D4(void);
+static void sub_8128AA0(void);
+static void sub_8128C04(void);
+static void sub_8128CA8(void);
+static void sub_8128DA4(void);
+static void sub_8128E78(void);
+static void sub_8128FB8(void);
+static void sub_8129218(u16 a0);
+static bool32 sub_8129228(void);
+static void sub_81292D8(void);
+static void sub_81293AC(void);
+static void sub_81293D8(void);
+static bool32 sub_8129408(void);
+static void sub_8129424(void);
+static void sub_8129454(void);
+static void sub_8129470(void);
+static u8 *sub_81294C8(void);
+static u8 *sub_81294EC(void);
+static void sub_8129560(u8 *ptr);
+static void sub_8129568(u8 *ptr);
+static void sub_8129590(u8 *ptr);
+static void sub_81295C0(u8 *ptr);
+static void sub_81295EC(u8 *ptr);
+static void sub_8129614(u8 *ptr);
+static void sub_81298F8(u8 taskId);
static void (*const gUnknown_845A880[])(void) = {
sub_8128640,
@@ -105,7 +104,7 @@ static const u8 sKeyboardPageMaxRow[] =
9
};
-const u8 gUnknown_845A8AC[] = {
+static const u8 gUnknown_845A8AC[] = {
CHAR_SPACE, 0x16, 0x17, 0x68, 0x19, 0x1A, 0x1B, 0x1C,
0x1D, 0x1E, CHAR_SPACE, 0x20, 0x21, 0x22, 0x23, 0x24,
0x25, 0x26, 0x27, 0x28, 0x29, 0x15, 0x01, 0x02,
@@ -189,7 +188,7 @@ void sub_8128420(void)
SetMainCallback2(c2_081284E0);
}
-void sub_812845C(struct UnionRoomChat * unionRoomChat)
+static void sub_812845C(struct UnionRoomChat * unionRoomChat)
{
int i;
@@ -211,14 +210,14 @@ void sub_812845C(struct UnionRoomChat * unionRoomChat)
StringCopy(unionRoomChat->unkB9[i], gSaveBlock1Ptr->unk3AD4[i]);
}
-void sub_81284BC(void)
+static void sub_81284BC(void)
{
DestroyTask(gUnknown_203B0E0->unkE);
DestroyTask(gUnknown_203B0E0->unkF);
Free(gUnknown_203B0E0);
}
-void c2_081284E0(void)
+static void c2_081284E0(void)
{
switch (gMain.state)
{
@@ -254,7 +253,7 @@ void c2_081284E0(void)
}
}
-void sub_81285B4(void)
+static void sub_81285B4(void)
{
TransferPlttBuffer();
LoadOam();
@@ -262,7 +261,7 @@ void sub_81285B4(void)
ScanlineEffect_InitHBlankDmaTransfer();
}
-void sub_81285CC(void)
+static void sub_81285CC(void)
{
RunTasks();
sub_8129BFC();
@@ -271,7 +270,7 @@ void sub_81285CC(void)
UpdatePaletteFade();
}
-void sub_81285E8(u8 taskId)
+static void sub_81285E8(u8 taskId)
{
switch (gUnknown_203B0E0->unk17)
{
@@ -292,7 +291,7 @@ void sub_81285E8(u8 taskId)
gUnknown_845A880[gUnknown_203B0E0->unk4]();
}
-void sub_8128640(void)
+static void sub_8128640(void)
{
switch (gUnknown_203B0E0->unk6)
{
@@ -314,7 +313,7 @@ void sub_8128640(void)
}
}
-void sub_81286C4(void)
+static void sub_81286C4(void)
{
bool8 var0, var1;
@@ -378,7 +377,7 @@ void sub_81286C4(void)
}
}
-void sub_81287B4(void)
+static void sub_81287B4(void)
{
s16 input;
int var0;
@@ -439,7 +438,7 @@ void sub_81287B4(void)
}
}
-void sub_81288D4(void)
+static void sub_81288D4(void)
{
s8 input;
@@ -526,7 +525,7 @@ void sub_81288D4(void)
}
}
-void sub_8128AA0(void)
+static void sub_8128AA0(void)
{
switch (gUnknown_203B0E0->unk6)
{
@@ -583,7 +582,7 @@ void sub_8128AA0(void)
}
}
-void sub_8128C04(void)
+static void sub_8128C04(void)
{
switch (gUnknown_203B0E0->unk6)
{
@@ -618,7 +617,7 @@ void sub_8128C04(void)
}
}
-void sub_8128CA8(void)
+static void sub_8128CA8(void)
{
switch (gUnknown_203B0E0->unk6)
{
@@ -664,7 +663,7 @@ void sub_8128CA8(void)
}
}
-void sub_8128DA4(void)
+static void sub_8128DA4(void)
{
switch (gUnknown_203B0E0->unk6)
{
@@ -698,7 +697,7 @@ void sub_8128DA4(void)
}
}
-void sub_8128E78(void)
+static void sub_8128E78(void)
{
switch (gUnknown_203B0E0->unk6)
{
@@ -761,7 +760,7 @@ void sub_8128E78(void)
}
}
-void sub_8128FB8(void)
+static void sub_8128FB8(void)
{
s8 input;
@@ -877,13 +876,13 @@ void sub_8128FB8(void)
}
}
-void sub_8129218(u16 arg0)
+static void sub_8129218(u16 arg0)
{
gUnknown_203B0E0->unk4 = arg0;
gUnknown_203B0E0->unk6 = 0;
}
-bool32 sub_8129228(void)
+static bool32 sub_8129228(void)
{
if (!(gMain.newAndRepeatedKeys & DPAD_UP))
{
@@ -934,7 +933,7 @@ bool32 sub_8129228(void)
}
}
-void sub_81292D8(void)
+static void sub_81292D8(void)
{
int i;
const u8 *charsStr;
@@ -987,7 +986,7 @@ void sub_81292D8(void)
*str = EOS;
}
-void sub_81293AC(void)
+static void sub_81293AC(void)
{
gUnknown_203B0E0->unk14 = gUnknown_203B0E0->unk15;
if (gUnknown_203B0E0->unk15)
@@ -998,7 +997,7 @@ void sub_81293AC(void)
}
}
-void sub_81293D8(void)
+static void sub_81293D8(void)
{
u8 *str;
u8 character;
@@ -1013,7 +1012,7 @@ void sub_81293D8(void)
}
}
-bool32 sub_8129408(void)
+static bool32 sub_8129408(void)
{
if (gUnknown_203B0E0->unk15)
return TRUE;
@@ -1021,21 +1020,21 @@ bool32 sub_8129408(void)
return FALSE;
}
-void sub_8129424(void)
+static void sub_8129424(void)
{
u8 *src = sub_8129758();
StringCopy(gUnknown_203B0E0->unkB9[gUnknown_203B0E0->currentRow], src);
gUnknown_203B0E0->unk18 = 1;
}
-void sub_8129454(void)
+static void sub_8129454(void)
{
gUnknown_203B0E0->unk1A[0] = EOS;
gUnknown_203B0E0->unk14 = 15;
gUnknown_203B0E0->unk15 = 0;
}
-void sub_8129470(void)
+static void sub_8129470(void)
{
int i;
for (i = 0; i < UNION_ROOM_KB_ROW_COUNT; i++)
@@ -1048,7 +1047,7 @@ u8 *sub_81294B0(int arg0)
}
// GetEndOfUnk1A
-u8 *sub_81294C8(void)
+static u8 *sub_81294C8(void)
{
u8 *str = gUnknown_203B0E0->unk1A;
while (*str != EOS)
@@ -1058,7 +1057,7 @@ u8 *sub_81294C8(void)
}
// GetPtrToLastCharOfUnk1A
-u8 *sub_81294EC(void)
+static u8 *sub_81294EC(void)
{
u8 *str = gUnknown_203B0E0->unk1A;
u8 *str2 = str;
@@ -1073,7 +1072,7 @@ u8 *sub_81294EC(void)
return str2;
}
-u16 sub_812951C(void)
+static u16 sub_812951C(void)
{
u8 *str;
u32 i, numChars, strLength;
@@ -1097,26 +1096,26 @@ u16 sub_812951C(void)
return numChars;
}
-void sub_8129560(u8 *arg0)
+static void sub_8129560(u8 *arg0)
{
arg0[0] = 0;
}
-void sub_8129568(u8 *arg0)
+static void sub_8129568(u8 *arg0)
{
arg0[0] = 2;
StringCopy(&arg0[1], gSaveBlock2Ptr->playerName);
arg0[1 + (PLAYER_NAME_LENGTH + 1)] = gUnknown_203B0E0->unk13;
}
-void sub_8129590(u8 *arg0)
+static void sub_8129590(u8 *arg0)
{
arg0[0] = 1;
StringCopy(&arg0[1], gSaveBlock2Ptr->playerName);
StringCopy(&arg0[1 + (PLAYER_NAME_LENGTH + 1)], gUnknown_203B0E0->unk1A);
}
-void sub_81295C0(u8 *arg0)
+static void sub_81295C0(u8 *arg0)
{
arg0[0] = 3;
StringCopy(&arg0[1], gSaveBlock2Ptr->playerName);
@@ -1124,21 +1123,21 @@ void sub_81295C0(u8 *arg0)
sub_80FB9D0();
}
-void sub_81295EC(u8 *arg0)
+static void sub_81295EC(u8 *arg0)
{
arg0[0] = 4;
StringCopy(&arg0[1], gSaveBlock2Ptr->playerName);
arg0[1 + (PLAYER_NAME_LENGTH + 1)] = gUnknown_203B0E0->unk13;
}
-void sub_8129614(u8 *arg0)
+static void sub_8129614(u8 *arg0)
{
arg0[0] = 5;
StringCopy(&arg0[1], gSaveBlock2Ptr->playerName);
arg0[1 + (PLAYER_NAME_LENGTH + 1)] = gUnknown_203B0E0->unk13;
}
-bool32 sub_812963C(u8 *arg0, u8 *arg1)
+static bool32 sub_812963C(u8 *arg0, u8 *arg1)
{
u8 *tempStr;
u8 var0 = *arg1;
@@ -1297,7 +1296,7 @@ void copy_strings_to_sav1(void)
StringCopy(gSaveBlock1Ptr->unk3AD4[9], gText_ByeBye);
}
-void sub_81298F8(u8 taskId)
+static void sub_81298F8(u8 taskId)
{
u8 *buffer;
s16 *data = gTasks[taskId].data;
diff --git a/src/union_room_chat_display.c b/src/union_room_chat_display.c
index c60c94eb0..4bd4be8fe 100644
--- a/src/union_room_chat_display.c
+++ b/src/union_room_chat_display.c
@@ -53,65 +53,65 @@ struct Unk845AB64
bool8 widerBox;
};
-EWRAM_DATA struct UnionRoomChat2 * gUnknown_203B0E4 = NULL;
-
-void sub_8129BB8(struct UnionRoomChat2 * ptr);
-void sub_8129BC4(void);
-bool32 sub_8129CA0(u8 *state);
-bool32 sub_8129D40(u8 *state);
-bool32 sub_8129D78(u8 *state);
-bool32 sub_8129DB0(u8 *state);
-bool32 sub_8129E1C(u8 *state);
-bool32 sub_8129E28(u8 *state);
-bool32 sub_8129E74(u8 *state);
-bool32 sub_8129EB8(u8 *state);
-bool32 sub_8129F24(u8 *state);
-bool32 sub_8129FCC(u8 *state);
-bool32 sub_812A074(u8 *state);
-bool32 sub_812A0B0(u8 *state);
-bool32 sub_812A18C(u8 *state);
-bool32 sub_812A1B8(u8 *state);
-bool32 sub_812A1FC(u8 *state);
-bool32 sub_812A240(u8 *state);
-bool32 sub_812A294(u8 *state);
-bool32 sub_812A2E4(u8 *state);
-bool32 sub_812A334(u8 *state);
-bool32 sub_812A378(u8 *state);
-bool32 sub_812A3D0(u8 *state);
-bool32 sub_812A420(u8 *state);
-void sub_812A424(u8 a0, u8 a1, u8 a2);
-void sub_812A51C(void);
-void sub_812A544(void);
-void sub_812A578(int a0, u16 a1);
-void sub_812A6F4(void);
-void sub_812A728(void);
-void sub_812A74C(u16 a0, u16 a1, u8 a2);
-void sub_812A778(u16 a0, u8 *a1, u8 a2, u8 a3, u8 a4);
-void sub_812A804(void);
-bool32 sub_812A980(void);
-bool32 sub_812A9C8(void);
-void sub_812AA10(void);
-void sub_812AA64(void);
-void sub_812AA78(u16 a0, u8 *a1, u8 a2);
-void sub_812AAD4(void);
-void sub_812AB8C(void);
-void sub_812ABD8(void);
-void sub_812AC08(void);
-void sub_812AC58(void);
-void sub_812AC9C(void);
-void sub_812ACC0(void);
-void sub_812ACEC(void);
-void sub_812AD04(void);
-void sub_812AD20(void);
-void sub_812AD50(void);
-void sub_812ADA0(s16 a0);
-void sub_812ADF8(s16 a0);
-
-const u16 gUnknown_845AA24[] = INCBIN_U16("graphics/union_room_chat/unk_845AA24.gbapal");
-const u16 gUnknown_845AA44[] = INCBIN_U16("graphics/union_room_chat/unk_845AA44.gbapal");
-const u16 gUnknown_845AA64[] = INCBIN_U16("graphics/union_room_chat/unk_845AA64.gbapal");
-
-const struct BgTemplate gUnknown_845AA84[] = {
+static EWRAM_DATA struct UnionRoomChat2 * gUnknown_203B0E4 = NULL;
+
+static void sub_8129BB8(struct UnionRoomChat2 * ptr);
+static void sub_8129BC4(void);
+static bool32 sub_8129CA0(u8 *state);
+static bool32 sub_8129D40(u8 *state);
+static bool32 sub_8129D78(u8 *state);
+static bool32 sub_8129DB0(u8 *state);
+static bool32 sub_8129E1C(u8 *state);
+static bool32 sub_8129E28(u8 *state);
+static bool32 sub_8129E74(u8 *state);
+static bool32 sub_8129EB8(u8 *state);
+static bool32 sub_8129F24(u8 *state);
+static bool32 sub_8129FCC(u8 *state);
+static bool32 sub_812A074(u8 *state);
+static bool32 sub_812A0B0(u8 *state);
+static bool32 sub_812A18C(u8 *state);
+static bool32 sub_812A1B8(u8 *state);
+static bool32 sub_812A1FC(u8 *state);
+static bool32 sub_812A240(u8 *state);
+static bool32 sub_812A294(u8 *state);
+static bool32 sub_812A2E4(u8 *state);
+static bool32 sub_812A334(u8 *state);
+static bool32 sub_812A378(u8 *state);
+static bool32 sub_812A3D0(u8 *state);
+static bool32 sub_812A420(u8 *state);
+static void sub_812A424(u8 a0, u8 a1, u8 a2);
+static void sub_812A51C(void);
+static void sub_812A544(void);
+static void sub_812A578(int a0, u16 a1);
+static void sub_812A6F4(void);
+static void sub_812A728(void);
+static void sub_812A74C(u16 a0, u16 a1, u8 a2);
+static void sub_812A778(u16 a0, u8 *a1, u8 a2, u8 a3, u8 a4);
+static void sub_812A804(void);
+static bool32 sub_812A980(void);
+static bool32 sub_812A9C8(void);
+static void sub_812AA10(void);
+static void sub_812AA64(void);
+static void sub_812AA78(u16 a0, u8 *a1, u8 a2);
+static void sub_812AAD4(void);
+static void sub_812AB8C(void);
+static void sub_812ABD8(void);
+static void sub_812AC08(void);
+static void sub_812AC58(void);
+static void sub_812AC9C(void);
+static void sub_812ACC0(void);
+static void sub_812ACEC(void);
+static void sub_812AD04(void);
+static void sub_812AD20(void);
+static void sub_812AD50(void);
+static void sub_812ADA0(s16 a0);
+static void sub_812ADF8(s16 a0);
+
+static const u16 gUnknown_845AA24[] = INCBIN_U16("graphics/union_room_chat/unk_845AA24.gbapal");
+static const u16 gUnknown_845AA44[] = INCBIN_U16("graphics/union_room_chat/unk_845AA44.gbapal");
+static const u16 gUnknown_845AA64[] = INCBIN_U16("graphics/union_room_chat/unk_845AA64.gbapal");
+
+static const struct BgTemplate gUnknown_845AA84[] = {
{
.bg = 0,
.charBaseIndex = 0,
@@ -147,7 +147,7 @@ const struct BgTemplate gUnknown_845AA84[] = {
}
};
-const struct WindowTemplate gUnknown_845AA94[] = {
+static const struct WindowTemplate gUnknown_845AA94[] = {
{
.bg = 3,
.tilemapLeft = 8,
@@ -183,7 +183,7 @@ const struct WindowTemplate gUnknown_845AA94[] = {
}, DUMMY_WIN_TEMPLATE
};
-const struct Unk845AABC gUnknown_845AABC[] = {
+static const struct Unk845AABC gUnknown_845AABC[] = {
{ 0, sub_8129CA0},
{ 3, sub_8129D40},
{ 4, sub_8129D78},
@@ -207,7 +207,7 @@ const struct Unk845AABC gUnknown_845AABC[] = {
{20, sub_812A3D0}
};
-const struct Unk845AB64 gUnknown_845AB64[] = {
+static const struct Unk845AB64 gUnknown_845AB64[] = {
{
.text = gText_QuitChatting,
.boxType = 1,
@@ -310,9 +310,9 @@ const struct Unk845AB64 gUnknown_845AB64[] = {
}
};
-const u8 gText_Ellipsis[] = _("…");
+static const u8 gText_Ellipsis[] = _("…");
-const struct MenuAction gUnknown_845ABEC[] = {
+static const struct MenuAction gUnknown_845ABEC[] = {
{gText_Upper},
{gText_Lower},
{gText_Symbols},
@@ -356,7 +356,7 @@ void sub_8129B88(void)
gScanlineEffect.state = 3;
}
-void sub_8129BB8(struct UnionRoomChat2 *arg0)
+static void sub_8129BB8(struct UnionRoomChat2 *arg0)
{
arg0->unk18 = 0xFF;
arg0->messageWindowId = 0xFF;
@@ -367,7 +367,7 @@ void sub_8129BC4(void)
{
int i;
- if (!gUnknown_203B0E4)
+ if (gUnknown_203B0E4 == NULL)
return;
for (i = 0; i < 3; i++)
@@ -414,7 +414,7 @@ bool8 sub_8129C8C(u8 arg0)
return gUnknown_203B0E4->subtasks[arg0].active;
}
-bool32 sub_8129CA0(u8 *state)
+static bool32 sub_8129CA0(u8 *state)
{
if (FreeTempTileDataBuffersIfPossible() == TRUE)
return TRUE;
@@ -459,7 +459,7 @@ bool32 sub_8129CA0(u8 *state)
return TRUE;
}
-bool32 sub_8129D40(u8 *state)
+static bool32 sub_8129D40(u8 *state)
{
switch (*state)
{
@@ -475,7 +475,7 @@ bool32 sub_8129D40(u8 *state)
return TRUE;
}
-bool32 sub_8129D78(u8 *state)
+static bool32 sub_8129D78(u8 *state)
{
switch (*state)
{
@@ -491,7 +491,7 @@ bool32 sub_8129D78(u8 *state)
return TRUE;
}
-bool32 sub_8129DB0(u8 *state)
+static bool32 sub_8129DB0(u8 *state)
{
switch (*state)
{
@@ -521,13 +521,13 @@ bool32 sub_8129DB0(u8 *state)
return TRUE;
}
-bool32 sub_8129E1C(u8 *state)
+static bool32 sub_8129E1C(u8 *state)
{
sub_812AF1C();
return FALSE;
}
-bool32 sub_8129E28(u8 *state)
+static bool32 sub_8129E28(u8 *state)
{
switch (*state)
{
@@ -544,7 +544,7 @@ bool32 sub_8129E28(u8 *state)
return TRUE;
}
-bool32 sub_8129E74(u8 *state)
+static bool32 sub_8129E74(u8 *state)
{
switch (*state)
{
@@ -566,7 +566,7 @@ bool32 sub_8129E74(u8 *state)
return TRUE;
}
-bool32 sub_8129EB8(u8 *state)
+static bool32 sub_8129EB8(u8 *state)
{
u32 var0, var1;
u8 *str;
@@ -593,7 +593,7 @@ bool32 sub_8129EB8(u8 *state)
return TRUE;
}
-bool32 sub_8129F24(u8 *state)
+static bool32 sub_8129F24(u8 *state)
{
u16 var0;
u8 *str;
@@ -634,7 +634,7 @@ bool32 sub_8129F24(u8 *state)
return TRUE;
}
-bool32 sub_8129FCC(u8 *state)
+static bool32 sub_8129FCC(u8 *state)
{
u16 var0;
u8 *str;
@@ -680,7 +680,7 @@ bool32 sub_8129FCC(u8 *state)
return TRUE;
}
-bool32 sub_812A074(u8 *state)
+static bool32 sub_812A074(u8 *state)
{
switch (*state)
{
@@ -699,7 +699,7 @@ bool32 sub_812A074(u8 *state)
return TRUE;
}
-bool32 sub_812A0B0(u8 *state)
+static bool32 sub_812A0B0(u8 *state)
{
u16 var0;
u8 *str;
@@ -756,7 +756,7 @@ bool32 sub_812A0B0(u8 *state)
return TRUE;
}
-bool32 sub_812A18C(u8 *state)
+static bool32 sub_812A18C(u8 *state)
{
switch (*state)
{
@@ -771,7 +771,7 @@ bool32 sub_812A18C(u8 *state)
return TRUE;
}
-bool32 sub_812A1B8(u8 *state)
+static bool32 sub_812A1B8(u8 *state)
{
switch (*state)
{
@@ -787,7 +787,7 @@ bool32 sub_812A1B8(u8 *state)
return TRUE;
}
-bool32 sub_812A1FC(u8 *state)
+static bool32 sub_812A1FC(u8 *state)
{
switch (*state)
{
@@ -803,7 +803,7 @@ bool32 sub_812A1FC(u8 *state)
return TRUE;
}
-bool32 sub_812A240(u8 *state)
+static bool32 sub_812A240(u8 *state)
{
u8 *str;
@@ -824,7 +824,7 @@ bool32 sub_812A240(u8 *state)
return TRUE;
}
-bool32 sub_812A294(u8 *state)
+static bool32 sub_812A294(u8 *state)
{
switch (*state)
{
@@ -841,7 +841,7 @@ bool32 sub_812A294(u8 *state)
return TRUE;
}
-bool32 sub_812A2E4(u8 *state)
+static bool32 sub_812A2E4(u8 *state)
{
switch (*state)
{
@@ -858,7 +858,7 @@ bool32 sub_812A2E4(u8 *state)
return TRUE;
}
-bool32 sub_812A334(u8 *state)
+static bool32 sub_812A334(u8 *state)
{
switch (*state)
{
@@ -874,7 +874,7 @@ bool32 sub_812A334(u8 *state)
return TRUE;
}
-bool32 sub_812A378(u8 *state)
+static bool32 sub_812A378(u8 *state)
{
switch (*state)
{
@@ -892,7 +892,7 @@ bool32 sub_812A378(u8 *state)
return TRUE;
}
-bool32 sub_812A3D0(u8 *state)
+static bool32 sub_812A3D0(u8 *state)
{
switch (*state)
{
@@ -909,12 +909,12 @@ bool32 sub_812A3D0(u8 *state)
return TRUE;
}
-bool32 sub_812A420(u8 *arg0)
+static bool32 sub_812A420(u8 *arg0)
{
return FALSE;
}
-void sub_812A424(u8 left, u8 top, u8 initialCursorPos)
+static void sub_812A424(u8 left, u8 top, u8 initialCursorPos)
{
struct WindowTemplate template;
template.bg = 0;
@@ -936,7 +936,7 @@ void sub_812A424(u8 left, u8 top, u8 initialCursorPos)
}
}
-void sub_812A51C(void)
+static void sub_812A51C(void)
{
if (gUnknown_203B0E4->unk18 != 0xFF)
{
@@ -945,7 +945,7 @@ void sub_812A51C(void)
}
}
-void sub_812A544(void)
+static void sub_812A544(void)
{
if (gUnknown_203B0E4->unk18 != 0xFF)
{
@@ -959,7 +959,7 @@ s8 sub_812A568(void)
return Menu_ProcessInput();
}
-void sub_812A578(int arg0, u16 arg1)
+static void sub_812A578(int arg0, u16 arg1)
{
const u8 *str;
int windowId;
@@ -1027,7 +1027,7 @@ void sub_812A578(int arg0, u16 arg1)
gUnknown_203B0E4->messageWindowId = windowId;
}
-void sub_812A6F4(void)
+static void sub_812A6F4(void)
{
if (gUnknown_203B0E4->messageWindowId != 0xFF)
{
@@ -1038,7 +1038,7 @@ void sub_812A6F4(void)
ChangeBgY(0, 0, 0);
}
-void sub_812A728(void)
+static void sub_812A728(void)
{
if (gUnknown_203B0E4->messageWindowId != 0xFF)
{
@@ -1047,12 +1047,12 @@ void sub_812A728(void)
}
}
-void sub_812A74C(u16 x, u16 width, u8 fillValue)
+static void sub_812A74C(u16 x, u16 width, u8 fillValue)
{
FillWindowPixelRect(1, fillValue, x * 8, 1, width * 8, 14);
}
-void sub_812A778(u16 x, u8 *str, u8 fillValue, u8 arg3, u8 arg4)
+static void sub_812A778(u16 x, u8 *str, u8 fillValue, u8 arg3, u8 arg4)
{
u8 *str2;
u8 sp[38];
@@ -1070,7 +1070,7 @@ void sub_812A778(u16 x, u8 *str, u8 fillValue, u8 arg3, u8 arg4)
AddTextPrinterParameterized3(1, 2, x * 8, 1, sp, TEXT_SPEED_FF, str2);
}
-void sub_812A804(void)
+static void sub_812A804(void)
{
u8 page;
int i;
@@ -1132,7 +1132,7 @@ void sub_812A804(void)
}
}
-bool32 sub_812A980(void)
+static bool32 sub_812A980(void)
{
if (gUnknown_203B0E4->bg1hofs < 56)
{
@@ -1151,7 +1151,7 @@ bool32 sub_812A980(void)
return FALSE;
}
-bool32 sub_812A9C8(void)
+static bool32 sub_812A9C8(void)
{
if (gUnknown_203B0E4->bg1hofs > 0)
{
@@ -1170,7 +1170,7 @@ bool32 sub_812A9C8(void)
return FALSE;
}
-void sub_812AA10(void)
+static void sub_812AA10(void)
{
FillWindowPixelBuffer(3, PIXEL_FILL(1));
DrawTextBorderOuter(3, 1, 13);
@@ -1179,13 +1179,13 @@ void sub_812AA10(void)
PutWindowTilemap(3);
}
-void sub_812AA64(void)
+static void sub_812AA64(void)
{
ClearStdWindowAndFrameToTransparent(3, FALSE);
ClearWindowTilemap(3);
}
-void sub_812AA78(u16 row, u8 *str, u8 arg2)
+static void sub_812AA78(u16 row, u8 *str, u8 arg2)
{
u8 color[3];
color[0] = 1;
@@ -1195,7 +1195,7 @@ void sub_812AA78(u16 row, u8 *str, u8 arg2)
AddTextPrinterParameterized3(0, 2, 0, row * 15, color, TEXT_SPEED_FF, str);
}
-void sub_812AAD4(void)
+static void sub_812AAD4(void)
{
ChangeBgX(0, 0, 0);
ChangeBgY(0, 0, 0);
@@ -1220,7 +1220,7 @@ void sub_812AAD4(void)
SetGpuReg(REG_OFFSET_WINOUT, WINOUT_WIN01_BG_ALL | WINOUT_WIN01_OBJ | WINOUT_WIN01_CLR);
}
-void sub_812AB8C(void)
+static void sub_812AB8C(void)
{
SetBgTilemapBuffer(0, gUnknown_203B0E4->bg0Buffer);
SetBgTilemapBuffer(1, gUnknown_203B0E4->bg1Buffer);
@@ -1228,14 +1228,14 @@ void sub_812AB8C(void)
SetBgTilemapBuffer(2, gUnknown_203B0E4->bg2Buffer);
}
-void sub_812ABD8(void)
+static void sub_812ABD8(void)
{
RequestDma3Fill(0, (void *)BG_CHAR_ADDR(0), 0x20, 1);
FillBgTilemapBufferRect_Palette0(0, 0, 0, 0, 32, 32);
CopyBgTilemapBufferToVram(0);
}
-void sub_812AC08(void)
+static void sub_812AC08(void)
{
LoadPalette(gUnknown_8EAA9F0, 0x70, 0x20);
LoadPalette(gUnknown_845AA24, 0xC0, 0x20);
@@ -1244,7 +1244,7 @@ void sub_812AC08(void)
CopyBgTilemapBufferToVram(1);
}
-void sub_812AC58(void)
+static void sub_812AC58(void)
{
u8 *ptr;
@@ -1254,13 +1254,13 @@ void sub_812AC58(void)
CopyBgTilemapBufferToVram(2);
}
-void sub_812AC9C(void)
+static void sub_812AC9C(void)
{
LoadPalette(gUnknown_845AA44, 0x80, 0x20);
RequestDma3Fill(0, (void *)BG_CHAR_ADDR(1) + 0x20, 0x20, 1);
}
-void sub_812ACC0(void)
+static void sub_812ACC0(void)
{
LoadPalette(gUnknown_845AA64, 0xF0, 0x20);
PutWindowTilemap(0);
@@ -1268,21 +1268,21 @@ void sub_812ACC0(void)
CopyWindowToVram(0, 3);
}
-void sub_812ACEC(void)
+static void sub_812ACEC(void)
{
PutWindowTilemap(2);
sub_812A804();
CopyWindowToVram(2, 3);
}
-void sub_812AD04(void)
+static void sub_812AD04(void)
{
FillWindowPixelBuffer(1, PIXEL_FILL(0));
PutWindowTilemap(1);
CopyWindowToVram(1, 3);
}
-void sub_812AD20(void)
+static void sub_812AD20(void)
{
FillWindowPixelBuffer(3, PIXEL_FILL(1));
TextWindow_SetUserSelectedFrame(3, 1, 0xD0);
@@ -1290,7 +1290,7 @@ void sub_812AD20(void)
LoadPalette(gTMCaseMainWindowPalette, 0xE0, 0x20);
}
-void sub_812AD50(void)
+static void sub_812AD50(void)
{
struct ScanlineEffectParams params;
params.dmaControl = SCANLINE_EFFECT_DMACNT_16BIT;
@@ -1302,13 +1302,13 @@ void sub_812AD50(void)
ScanlineEffect_SetParams(params);
}
-void sub_812ADA0(s16 arg0)
+static void sub_812ADA0(s16 arg0)
{
CpuFill16(arg0, gScanlineEffectRegBuffers[gScanlineEffect.srcBuffer], 0x120);
CpuFill16(0, gScanlineEffectRegBuffers[gScanlineEffect.srcBuffer] + 0x90, 0x20);
}
-void sub_812ADF8(s16 arg0)
+static void sub_812ADF8(s16 arg0)
{
CpuFill16(arg0, gScanlineEffectRegBuffers[0], 0x120);
CpuFill16(0, gScanlineEffectRegBuffers[0] + 0x90, 0x20);
diff --git a/src/union_room_chat_objects.c b/src/union_room_chat_objects.c
index 805e95d33..70f9f48ff 100644
--- a/src/union_room_chat_objects.c
+++ b/src/union_room_chat_objects.c
@@ -14,18 +14,18 @@ struct UnionRoomChat3
u16 unk14;
};
-EWRAM_DATA struct UnionRoomChat3 *gUnknown_203B0E8 = NULL;
+static EWRAM_DATA struct UnionRoomChat3 *gUnknown_203B0E8 = NULL;
-void sub_812B09C(struct Sprite * sprite);
-void sub_812B0D4(struct Sprite * sprite);
+static void sub_812B09C(struct Sprite * sprite);
+static void sub_812B0D4(struct Sprite * sprite);
-const u16 gUnknown_845AC14[] = INCBIN_U16("graphics/union_room_chat/unk_845AC14.gbapal");
-const u32 gUnknown_845AC34[] = INCBIN_U32("graphics/union_room_chat/unk_845AC34.4bpp.lz");
-const u32 gUnknown_845AEB8[] = INCBIN_U32("graphics/union_room_chat/unk_845AEB8.4bpp.lz");
-const u32 gUnknown_845AED8[] = INCBIN_U32("graphics/union_room_chat/unk_845AED8.4bpp.lz");
-const u32 gUnknown_845AF04[] = INCBIN_U32("graphics/union_room_chat/unk_845AF04.4bpp.lz");
+static const u16 gUnknown_845AC14[] = INCBIN_U16("graphics/union_room_chat/unk_845AC14.gbapal");
+static const u32 gUnknown_845AC34[] = INCBIN_U32("graphics/union_room_chat/unk_845AC34.4bpp.lz");
+static const u32 gUnknown_845AEB8[] = INCBIN_U32("graphics/union_room_chat/unk_845AEB8.4bpp.lz");
+static const u32 gUnknown_845AED8[] = INCBIN_U32("graphics/union_room_chat/unk_845AED8.4bpp.lz");
+static const u32 gUnknown_845AF04[] = INCBIN_U32("graphics/union_room_chat/unk_845AF04.4bpp.lz");
-const struct CompressedSpriteSheet gUnknown_845AF58[] = {
+static const struct CompressedSpriteSheet gUnknown_845AF58[] = {
{gUnknown_845AC34, 0x1000, 0},
{gUnknown_845AED8, 0x0040, 1},
{gUnknown_845AEB8, 0x0040, 2},
@@ -33,44 +33,44 @@ const struct CompressedSpriteSheet gUnknown_845AF58[] = {
{gUnknown_8EA1A50, 0x0400, 4}
};
-const struct SpritePalette gUnknown_845AF80 = {
+static const struct SpritePalette gUnknown_845AF80 = {
gUnknown_845AC14, 0
};
-const struct OamData gOamData_845AF88 = {
+static const struct OamData gOamData_845AF88 = {
.shape = SPRITE_SHAPE(64x32),
.size = SPRITE_SIZE(64x32),
.priority = 1
};
-const union AnimCmd gAnimCmd_845AF90[] = {
+static const union AnimCmd gAnimCmd_845AF90[] = {
ANIMCMD_FRAME(0x00, 30),
ANIMCMD_END
};
-const union AnimCmd gAnimCmd_845AF98[] = {
+static const union AnimCmd gAnimCmd_845AF98[] = {
ANIMCMD_FRAME(0x20, 30),
ANIMCMD_END
};
-const union AnimCmd gAnimCmd_845AFA0[] = {
+static const union AnimCmd gAnimCmd_845AFA0[] = {
ANIMCMD_FRAME(0x40, 30),
ANIMCMD_END
};
-const union AnimCmd gAnimCmd_845AFA8[] = {
+static const union AnimCmd gAnimCmd_845AFA8[] = {
ANIMCMD_FRAME(0x60, 30),
ANIMCMD_END
};
-const union AnimCmd *const gSpriteAnimTable_845AFB0[] = {
+static const union AnimCmd *const gSpriteAnimTable_845AFB0[] = {
gAnimCmd_845AF90,
gAnimCmd_845AF98,
gAnimCmd_845AFA0,
gAnimCmd_845AFA8
};
-const struct SpriteTemplate gUnknown_845AFC0 = {
+static const struct SpriteTemplate gUnknown_845AFC0 = {
.tileTag = 0,
.paletteTag = 0,
.oam = &gOamData_845AF88,
@@ -79,13 +79,13 @@ const struct SpriteTemplate gUnknown_845AFC0 = {
.callback = SpriteCallbackDummy
};
-const struct OamData gOamData_845AFD8 = {
+static const struct OamData gOamData_845AFD8 = {
.shape = SPRITE_SHAPE(8x16),
.size = SPRITE_SIZE(8x16),
.priority = 2
};
-const struct SpriteTemplate gUnknown_845AFE0 = {
+static const struct SpriteTemplate gUnknown_845AFE0 = {
.tileTag = 2,
.paletteTag = 0,
.oam = &gOamData_845AFD8,
@@ -94,7 +94,7 @@ const struct SpriteTemplate gUnknown_845AFE0 = {
.callback = sub_812B09C
};
-const struct SpriteTemplate gUnknown_845AFF8 = {
+static const struct SpriteTemplate gUnknown_845AFF8 = {
.tileTag = 1,
.paletteTag = 0,
.oam = &gOamData_845AFD8,
@@ -103,46 +103,46 @@ const struct SpriteTemplate gUnknown_845AFF8 = {
.callback = sub_812B0D4
};
-const struct OamData gOamData_845B010 = {
+static const struct OamData gOamData_845B010 = {
.shape = SPRITE_SHAPE(16x16),
.size = SPRITE_SIZE(16x16),
.priority = 2
};
-const struct OamData gOamData_845B018 = {
+static const struct OamData gOamData_845B018 = {
.shape = SPRITE_SHAPE(32x16),
.size = SPRITE_SIZE(32x16),
.priority = 2
};
-const union AnimCmd gAnimCmd_845B020[] = {
+static const union AnimCmd gAnimCmd_845B020[] = {
ANIMCMD_FRAME(0x00, 2),
ANIMCMD_END
};
-const union AnimCmd gAnimCmd_845B028[] = {
+static const union AnimCmd gAnimCmd_845B028[] = {
ANIMCMD_FRAME(0x08, 2),
ANIMCMD_END
};
-const union AnimCmd gAnimCmd_845B030[] = {
+static const union AnimCmd gAnimCmd_845B030[] = {
ANIMCMD_FRAME(0x10, 2),
ANIMCMD_END
};
-const union AnimCmd gAnimCmd_845B038[] = {
+static const union AnimCmd gAnimCmd_845B038[] = {
ANIMCMD_FRAME(0x18, 2),
ANIMCMD_END
};
-const union AnimCmd *const gSpriteAnimTable_845B040[] = {
+static const union AnimCmd *const gSpriteAnimTable_845B040[] = {
gAnimCmd_845B020,
gAnimCmd_845B028,
gAnimCmd_845B030,
gAnimCmd_845B038
};
-const struct SpriteTemplate gUnknown_845B050 = {
+static const struct SpriteTemplate gUnknown_845B050 = {
.tileTag = 3,
.paletteTag = 0,
.oam = &gOamData_845B010,
@@ -151,7 +151,7 @@ const struct SpriteTemplate gUnknown_845B050 = {
.callback = SpriteCallbackDummy
};
-const struct SpriteTemplate gUnknown_845B068 = {
+static const struct SpriteTemplate gUnknown_845B068 = {
.tileTag = 4,
.paletteTag = 0,
.oam = &gOamData_845B018,
@@ -253,7 +253,7 @@ void sub_812B048(void)
gUnknown_203B0E8->unk4 = &gSprites[spriteId];
}
-void sub_812B09C(struct Sprite *sprite)
+static void sub_812B09C(struct Sprite *sprite)
{
int var0 = sub_81297DC();
if (var0 == 15)
@@ -267,7 +267,7 @@ void sub_812B09C(struct Sprite *sprite)
}
}
-void sub_812B0D4(struct Sprite *sprite)
+static void sub_812B0D4(struct Sprite *sprite)
{
if (++sprite->data[0] > 4)
{