From f40a488f0929b77cacf72bfe5cea2c5e939c41bb Mon Sep 17 00:00:00 2001 From: ragnarok-clanker Date: Sun, 8 Nov 2026 23:51:57 +0000 Subject: [PATCH] Decompile fn_10820 (UIStaticText::Paint) Batch #14953 by SapitoSucio: 1 byte-identical, 0 confirmed by peer review. - fn_10820 UIStaticText::Paint: byte-identical Merged automatically: every function is byte-identical to the original. --- Source/UI/Text/UIStaticText.cpp | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/Source/UI/Text/UIStaticText.cpp b/Source/UI/Text/UIStaticText.cpp index 39adb6c94..f9868a641 100644 --- a/Source/UI/Text/UIStaticText.cpp +++ b/Source/UI/Text/UIStaticText.cpp @@ -130,24 +130,20 @@ void UIStaticText::SetTextFittedCodePage(const char* value) { // FUNCTION: fn_10820 void UIStaticText::Paint() { this->ClearSurface(this->background); - const auto draw = [&](int x, int y, std::uint32_t color, unsigned char boldValue, unsigned char italicValue) { - this->DrawTextAt(x, y, this->text.c_str(), 0, this->fontFamily, this->fontHeight, color, boldValue, italicValue - ); - }; if (this->shadow != 0) { - draw(1, 1, 0xFFFFFF, 0, 0); + this->DrawTextAt(1, 1, this->text.c_str(), 0, this->fontFamily, this->fontHeight, 0xFFFFFF, 0, 0); } if (this->outline != 0) { - draw(-1, 0, this->outlineColor, 0, 0); - draw(1, 0, this->outlineColor, 0, 0); - draw(0, 1, this->outlineColor, 0, 0); + this->DrawTextAt(-1, 0, this->text.c_str(), 0, this->fontFamily, this->fontHeight, this->outlineColor, 0, 0); + this->DrawTextAt(1, 0, this->text.c_str(), 0, this->fontFamily, this->fontHeight, this->outlineColor, 0, 0); + this->DrawTextAt(0, 1, this->text.c_str(), 0, this->fontFamily, this->fontHeight, this->outlineColor, 0, 0); } const unsigned color = static_cast(this->red) | (static_cast(this->green) << 8) | (static_cast(this->blue) << 16); - draw(0, 0, color, this->bold, this->italic); + this->DrawTextAt(0, 0, this->text.c_str(), 0, this->fontFamily, this->fontHeight, color, this->bold, this->italic); } // OFFSET: 0x0085EE40