diff options
author | Marcus Huderle <huderlem@gmail.com> | 2018-10-13 10:22:58 -0500 |
---|---|---|
committer | Marcus Huderle <huderlem@gmail.com> | 2018-10-13 10:22:58 -0500 |
commit | b24559d69b6fa0abf042a1b7cdbcab3d1ec91fd6 (patch) | |
tree | 7b51d7b9cb9a370fe1dd9db8eeadc23089ba1328 /src/option_menu.c | |
parent | fa9d1759bd7fa17ced37225bd31d46466da857c6 (diff) | |
parent | a2a6700966cc802185577e44ba88a9154429c93b (diff) |
Merge remote-tracking branch 'upstream/master' into shop
# Conflicts:
# asm/shop.s
Diffstat (limited to 'src/option_menu.c')
-rw-r--r-- | src/option_menu.c | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/src/option_menu.c b/src/option_menu.c index fc0c0c24e..6cb208c63 100644 --- a/src/option_menu.c +++ b/src/option_menu.c @@ -91,8 +91,24 @@ static const u8 *const sOptionMenuItemsNames[MENUITEM_COUNT] = static const struct WindowTemplate sOptionMenuWinTemplates[] = { - {1, 2, 1, 0x1A, 2, 1, 2}, - {0, 2, 5, 0x1A, 0xE, 1, 0x36}, + { + .priority = 1, + .tilemapLeft = 2, + .tilemapTop = 1, + .width = 26, + .height = 2, + .paletteNum = 1, + .baseBlock = 2 + }, + { + .priority = 0, + .tilemapLeft = 2, + .tilemapTop = 5, + .width = 26, + .height = 14, + .paletteNum = 1, + .baseBlock = 0x36 + }, DUMMY_WIN_TEMPLATE }; @@ -379,7 +395,7 @@ static void DrawOptionMenuChoice(const u8 *text, u8 x, u8 y, u8 style) } dst[i] = EOS; - PrintTextOnWindow(WIN_OPTIONS, 1, dst, x, y + 1, TEXT_SPEED_FF, NULL); + AddTextPrinterParameterized(WIN_OPTIONS, 1, dst, x, y + 1, TEXT_SPEED_FF, NULL); } static u8 TextSpeed_ProcessInput(u8 selection) @@ -605,7 +621,7 @@ static void ButtonMode_DrawChoices(u8 selection) static void DrawTextOption(void) { FillWindowPixelBuffer(WIN_TEXT_OPTION, 0x11); - PrintTextOnWindow(WIN_TEXT_OPTION, 1, gText_Option, 8, 1, TEXT_SPEED_FF, NULL); + AddTextPrinterParameterized(WIN_TEXT_OPTION, 1, gText_Option, 8, 1, TEXT_SPEED_FF, NULL); CopyWindowToVram(WIN_TEXT_OPTION, 3); } @@ -616,7 +632,7 @@ static void DrawOptionMenuTexts(void) FillWindowPixelBuffer(WIN_OPTIONS, 0x11); for (i = 0; i < MENUITEM_COUNT; i++) { - PrintTextOnWindow(WIN_OPTIONS, 1, sOptionMenuItemsNames[i], 8, (i * 16) + 1, TEXT_SPEED_FF, NULL); + AddTextPrinterParameterized(WIN_OPTIONS, 1, sOptionMenuItemsNames[i], 8, (i * 16) + 1, TEXT_SPEED_FF, NULL); } CopyWindowToVram(WIN_OPTIONS, 3); } |