Merge pull request #1536 from GriffinRichards/clean-braille

Add font id constants, better braille support
This commit is contained in:
GriffinR
2021-11-03 13:17:29 -04:00
committed by GitHub
134 changed files with 2116 additions and 1967 deletions

View File

@@ -439,7 +439,7 @@ static const struct ListMenuTemplate sPokeblockListMenuTemplate =
.lettersSpacing = 0,
.itemVerticalPadding = 0,
.scrollMultiple = LIST_MULTIPLE_SCROLL_DPAD,
.fontId = 1,
.fontId = FONT_NORMAL,
.cursorKind = 1
};
@@ -692,7 +692,7 @@ static void HandleInitWindows(void)
static void PrintOnPokeblockWindow(u8 windowId, const u8 *string, s32 x)
{
AddTextPrinterParameterized4(windowId, 1, x, 1, 0, 0, sTextColor, 0, string);
AddTextPrinterParameterized4(windowId, FONT_NORMAL, x, 1, 0, 0, sTextColor, 0, string);
}
static void DrawPokeblockMenuTitleText(void)
@@ -700,7 +700,7 @@ static void DrawPokeblockMenuTitleText(void)
u8 i;
const u8 *itemName = ItemId_GetName(ITEM_POKEBLOCK_CASE);
PrintOnPokeblockWindow(WIN_TITLE, itemName, GetStringCenterAlignXOffset(1, itemName, 0x48));
PrintOnPokeblockWindow(WIN_TITLE, itemName, GetStringCenterAlignXOffset(FONT_NORMAL, itemName, 0x48));
PrintOnPokeblockWindow(WIN_SPICY, gText_Spicy, 0);
PrintOnPokeblockWindow(WIN_DRY, gText_Dry, 0);
@@ -728,7 +728,7 @@ static void UpdatePokeblockList(void)
sPokeblockMenu->items[i].id = LIST_CANCEL;
gMultiuseListMenuTemplate = sPokeblockListMenuTemplate;
gMultiuseListMenuTemplate.fontId = 7;
gMultiuseListMenuTemplate.fontId = FONT_NARROW;
gMultiuseListMenuTemplate.totalItems = sPokeblockMenu->itemsNo;
gMultiuseListMenuTemplate.items = sPokeblockMenu->items;
gMultiuseListMenuTemplate.maxShowed = sPokeblockMenu->maxShowed;
@@ -1204,7 +1204,7 @@ static void PokeblockAction_Toss(u8 taskId)
ClearStdWindowAndFrameToTransparent(tWindowId, FALSE);
StringCopy(gStringVar1, gPokeblockNames[gSaveBlock1Ptr->pokeblocks[gSpecialVar_ItemId].color]);
StringExpandPlaceholders(gStringVar4, gText_ThrowAwayVar1);
DisplayMessageAndContinueTask(taskId, WIN_TOSS_MSG, 10, 13, 1, GetPlayerTextSpeedDelay(), gStringVar4, CreateTossPokeblockYesNoMenu);
DisplayMessageAndContinueTask(taskId, WIN_TOSS_MSG, 10, 13, FONT_NORMAL, GetPlayerTextSpeedDelay(), gStringVar4, CreateTossPokeblockYesNoMenu);
}
static void CreateTossPokeblockYesNoMenu(u8 taskId)
@@ -1215,7 +1215,7 @@ static void CreateTossPokeblockYesNoMenu(u8 taskId)
static void TossedPokeblockMessage(u8 taskId)
{
StringExpandPlaceholders(gStringVar4, gText_Var1ThrownAway);
DisplayMessageAndContinueTask(taskId, WIN_TOSS_MSG, 10, 13, 1, GetPlayerTextSpeedDelay(), gStringVar4, TossPokeblock);
DisplayMessageAndContinueTask(taskId, WIN_TOSS_MSG, 10, 13, FONT_NORMAL, GetPlayerTextSpeedDelay(), gStringVar4, TossPokeblock);
}
static void TossPokeblock(u8 taskId)