From ae9a60eb2ad7400d2f1c4367d31f3ebbbbbb1f91 Mon Sep 17 00:00:00 2001 From: PokeCodec <67983839+PokeCodec@users.noreply.github.com> Date: Thu, 3 Sep 2020 10:30:20 -0400 Subject: Documenting and whitespace fixing --- src/unk_text_util_2.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/unk_text_util_2.c') diff --git a/src/unk_text_util_2.c b/src/unk_text_util_2.c index 2ff8c6507..22db293e9 100644 --- a/src/unk_text_util_2.c +++ b/src/unk_text_util_2.c @@ -135,7 +135,7 @@ u16 Font6Func(struct TextPrinter *textPrinter) } DecompressGlyphFont6(char_); CopyGlyphToWindow(textPrinter); - textPrinter->printerTemplate.currentX += gUnknown_03002F90.unk80 + textPrinter->printerTemplate.letterSpacing; + textPrinter->printerTemplate.currentX += gUnknown_03002F90.width + textPrinter->printerTemplate.letterSpacing; return 0; case 1: if (TextPrinterWait(textPrinter)) @@ -210,8 +210,8 @@ static void DecompressGlyphFont6(u16 glyph) DecompressGlyphTile(glyphs + 0x8, (u16 *)(gUnknown_03002F90.unk20)); DecompressGlyphTile(glyphs + 0x80, (u16 *)(gUnknown_03002F90.unk40)); DecompressGlyphTile(glyphs + 0x88, (u16 *)(gUnknown_03002F90.unk60)); - gUnknown_03002F90.unk80 = 0x10; - gUnknown_03002F90.unk81 = 0x10; + gUnknown_03002F90.width = 0x10; + gUnknown_03002F90.height = 0x10; } u32 GetGlyphWidthFont6(u16 glyphId, bool32 isJapanese) -- cgit v1.2.3 From 28ef2fb774bf596a3e7f81055453304e0d2ce066 Mon Sep 17 00:00:00 2001 From: PokeCodec <67983839+PokeCodec@users.noreply.github.com> Date: Fri, 4 Sep 2020 21:11:55 -0400 Subject: Switch to button macros --- src/unk_text_util_2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/unk_text_util_2.c') diff --git a/src/unk_text_util_2.c b/src/unk_text_util_2.c index 22db293e9..b92b34fbd 100644 --- a/src/unk_text_util_2.c +++ b/src/unk_text_util_2.c @@ -19,14 +19,14 @@ u16 Font6Func(struct TextPrinter *textPrinter) switch (textPrinter->state) { case 0: - if (gMain.heldKeys & (A_BUTTON | B_BUTTON) && subStruct->hasPrintBeenSpedUp) + if (JOY_HELD(A_BUTTON | B_BUTTON) && subStruct->hasPrintBeenSpedUp) { textPrinter->delayCounter = 0; } if (textPrinter->delayCounter && textPrinter->textSpeed) { textPrinter->delayCounter --; - if (gTextFlags.canABSpeedUpPrint && gMain.newKeys & (A_BUTTON | B_BUTTON)) + if (gTextFlags.canABSpeedUpPrint && JOY_NEW(A_BUTTON | B_BUTTON)) { subStruct->hasPrintBeenSpedUp = TRUE; textPrinter->delayCounter = 0; -- cgit v1.2.3