summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDeokishisu <6993375+Deokishisu@users.noreply.github.com>2020-12-31 11:36:27 -0500
committerGitHub <noreply@github.com>2020-12-31 11:36:27 -0500
commit6e77eef0cd221d2c89a491467cdd56d7bb454e53 (patch)
tree62f154df33bfb8f6ec53d334e9413ebe72b7646e /src
parentf8a1bf14fbb4dae6ffb93b921e6b590e8cef5a4d (diff)
Fix Missed Magic Numbers in main_menu.c
There were two lines where magic numbers were used instead of the constant for MAIN_MENU_WINDOW_ERROR, so I filled them in.
Diffstat (limited to 'src')
-rw-r--r--src/main_menu.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main_menu.c b/src/main_menu.c
index 8d5343852..8f6cf7b45 100644
--- a/src/main_menu.c
+++ b/src/main_menu.c
@@ -508,7 +508,7 @@ static void Task_MysteryGiftError(u8 taskId)
break;
case 2:
RunTextPrinters();
- if (!IsTextPrinterActive(4))
+ if (!IsTextPrinterActive(MAIN_MENU_WINDOW_ERROR))
gTasks[taskId].tMGErrorMsgState++;
break;
case 3:
@@ -599,7 +599,7 @@ static bool8 HandleMenuInput(u8 taskId)
static void PrintMessageOnWindow4(const u8 *str)
{
FillWindowPixelBuffer(MAIN_MENU_WINDOW_ERROR, PIXEL_FILL(10));
- MainMenu_DrawWindow(&sWindowTemplate[4]);
+ MainMenu_DrawWindow(&sWindowTemplate[MAIN_MENU_WINDOW_ERROR]);
AddTextPrinterParameterized3(MAIN_MENU_WINDOW_ERROR, 2, 0, 2, sTextColor1, 2, str);
PutWindowTilemap(MAIN_MENU_WINDOW_ERROR);
CopyWindowToVram(MAIN_MENU_WINDOW_ERROR, COPYWIN_GFX);