Merge pull request #1773 from Jaizu/patch-27

Fix 'y' actually being 'x' in CreatePCMultichoice
This commit is contained in:
GriffinR 2022-09-08 16:31:26 -04:00 committed by GitHub
commit 75ded96ecf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -328,7 +328,7 @@ bool16 ScriptMenu_CreatePCMultichoice(void)
static void CreatePCMultichoice(void)
{
u8 y = 8;
u8 x = 8;
u32 pixelWidth = 0;
u8 width;
u8 numChoices;
@ -353,25 +353,25 @@ static void CreatePCMultichoice(void)
numChoices = 4;
windowId = CreateWindowFromRect(0, 0, width, 8);
SetStandardWindowBorderStyle(windowId, FALSE);
AddTextPrinterParameterized(windowId, FONT_NORMAL, gText_HallOfFame, y, 33, TEXT_SKIP_DRAW, NULL);
AddTextPrinterParameterized(windowId, FONT_NORMAL, gText_LogOff, y, 49, TEXT_SKIP_DRAW, NULL);
AddTextPrinterParameterized(windowId, FONT_NORMAL, gText_HallOfFame, x, 33, TEXT_SKIP_DRAW, NULL);
AddTextPrinterParameterized(windowId, FONT_NORMAL, gText_LogOff, x, 49, TEXT_SKIP_DRAW, NULL);
}
else
{
numChoices = 3;
windowId = CreateWindowFromRect(0, 0, width, 6);
SetStandardWindowBorderStyle(windowId, FALSE);
AddTextPrinterParameterized(windowId, FONT_NORMAL, gText_LogOff, y, 33, TEXT_SKIP_DRAW, NULL);
AddTextPrinterParameterized(windowId, FONT_NORMAL, gText_LogOff, x, 33, TEXT_SKIP_DRAW, NULL);
}
// Change PC name if player has met Lanette
if (FlagGet(FLAG_SYS_PC_LANETTE))
AddTextPrinterParameterized(windowId, FONT_NORMAL, gText_LanettesPC, y, 1, TEXT_SKIP_DRAW, NULL);
AddTextPrinterParameterized(windowId, FONT_NORMAL, gText_LanettesPC, x, 1, TEXT_SKIP_DRAW, NULL);
else
AddTextPrinterParameterized(windowId, FONT_NORMAL, gText_SomeonesPC, y, 1, TEXT_SKIP_DRAW, NULL);
AddTextPrinterParameterized(windowId, FONT_NORMAL, gText_SomeonesPC, x, 1, TEXT_SKIP_DRAW, NULL);
StringExpandPlaceholders(gStringVar4, gText_PlayersPC);
PrintPlayerNameOnWindow(windowId, gStringVar4, y, 17);
PrintPlayerNameOnWindow(windowId, gStringVar4, x, 17);
InitMenuInUpperLeftCornerNormal(windowId, numChoices, 0);
CopyWindowToVram(windowId, COPYWIN_FULL);
InitMultichoiceCheckWrap(FALSE, numChoices, windowId, MULTI_PC);