summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGriffinR <griffin.g.richards@gmail.com>2021-01-19 04:19:14 -0500
committerGriffinR <griffin.g.richards@gmail.com>2021-01-19 04:19:14 -0500
commit9dd867689e85e2ce7f50ec9fc0344220e60a7777 (patch)
treecbdc885e05e4cfcf8c487795fb59a55b18c1e4f7 /src
parent3f9037d63a46bd36f412ab7b23dd60c36e9b4cd2 (diff)
Use ARRAY_COUNT in PrintMenuTable
Diffstat (limited to 'src')
-rw-r--r--src/main_menu.c2
-rw-r--r--src/player_pc.c4
-rw-r--r--src/secret_base.c2
3 files changed, 4 insertions, 4 deletions
diff --git a/src/main_menu.c b/src/main_menu.c
index 0100a3341..74af96da8 100644
--- a/src/main_menu.c
+++ b/src/main_menu.c
@@ -2097,7 +2097,7 @@ static void NewGameBirchSpeech_ShowGenderMenu(void)
{
DrawMainMenuWindowBorder(&gNewGameBirchSpeechTextWindows[1], 0xF3);
FillWindowPixelBuffer(1, PIXEL_FILL(1));
- PrintMenuTable(1, 2, sMenuActions_Gender);
+ PrintMenuTable(1, ARRAY_COUNT(sMenuActions_Gender), sMenuActions_Gender);
InitMenuInUpperLeftCornerPlaySoundWhenAPressed(1, 2, 0);
PutWindowTilemap(1);
CopyWindowToVram(1, 3);
diff --git a/src/player_pc.c b/src/player_pc.c
index 928aac706..ff3087db4 100644
--- a/src/player_pc.c
+++ b/src/player_pc.c
@@ -443,7 +443,7 @@ static void InitItemStorageMenu(u8 taskId, u8 var)
windowTemplate.width = GetMaxWidthInMenuTable(gPCText_ItemPCOptionsText, 4);
data[4] = AddWindow(&windowTemplate);
SetStandardWindowBorderStyle(data[4], 0);
- PrintMenuTable(data[4], 4, gPCText_ItemPCOptionsText);
+ PrintMenuTable(data[4], ARRAY_COUNT(gPCText_ItemPCOptionsText), gPCText_ItemPCOptionsText);
InitMenuInUpperLeftCornerPlaySoundWhenAPressed(data[4], 4, var);
ScheduleBgCopyTilemapToVram(0);
ItemStorageMenuPrint(gPCText_OptionDescList[var]);
@@ -686,7 +686,7 @@ static void Mailbox_ReturnToPlayerPC(u8 taskId)
static void Mailbox_PrintMailOptions(u8 taskId)
{
u8 r4 = sub_81D1C84(2);
- PrintMenuTable(r4, 4, gMailboxMailOptions);
+ PrintMenuTable(r4, ARRAY_COUNT(gMailboxMailOptions), gMailboxMailOptions);
InitMenuInUpperLeftCornerPlaySoundWhenAPressed(r4, 4, 0);
ScheduleBgCopyTilemapToVram(0);
gTasks[taskId].func = Mailbox_MailOptionsProcessInput;
diff --git a/src/secret_base.c b/src/secret_base.c
index 8e0929593..d49eef277 100644
--- a/src/secret_base.c
+++ b/src/secret_base.c
@@ -996,7 +996,7 @@ static void ShowRegistryMenuActions(u8 taskId)
template.width = GetMaxWidthInMenuTable(sRegistryMenuActions, 2);
data[7] = AddWindow(&template);
SetStandardWindowBorderStyle(data[7], 0);
- PrintMenuTable(data[7], 2, sRegistryMenuActions);
+ PrintMenuTable(data[7], ARRAY_COUNT(sRegistryMenuActions), sRegistryMenuActions);
InitMenuInUpperLeftCornerPlaySoundWhenAPressed(data[7], 2, 0);
ScheduleBgCopyTilemapToVram(0);
gTasks[taskId].func = HandleRegistryMenuActionsInput;