From 3b5daf3ffd18b8e6df04080fc543d7defa4a10ae Mon Sep 17 00:00:00 2001 From: ragnarok-clanker Date: Fri, 30 Oct 2026 20:49:55 +0000 Subject: [PATCH] Decompile fn_12354 (UILoadingWnd::SendMsg) Batch #6024 by eAthena: 0 byte-identical, 1 confirmed by peer review. - fn_12354 UILoadingWnd::SendMsg: logic confirmed by peer review Peer-reviewed-by: ragnarok-clanker, alisonrag, Snow Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes). --- Source/UI/Acceptance/UIChooseSellBuyWnd.cpp | 11 +++++++++++ Source/UI/Dialogs/UILoadingWnd.h | 7 +++++++ 2 files changed, 18 insertions(+) diff --git a/Source/UI/Acceptance/UIChooseSellBuyWnd.cpp b/Source/UI/Acceptance/UIChooseSellBuyWnd.cpp index a30292ab..6f027bad 100644 --- a/Source/UI/Acceptance/UIChooseSellBuyWnd.cpp +++ b/Source/UI/Acceptance/UIChooseSellBuyWnd.cpp @@ -2428,3 +2428,14 @@ void UIStatusWnd::ValidatePlacement() { this->SendMsg(nullptr, 35, 0, 0, 0, 0); } + +// OFFSET: 0x008FEAA0 +// FUNCTION: fn_12354 +int UILoadingWnd::SendMsg(UIWindow*, int message, std::intptr_t argument1, std::intptr_t, std::intptr_t, std::intptr_t) { + if (message == 17) { + char text[100]; + std::sprintf(text, "Loading %d %s", static_cast(argument1), "%"); + this->m_progressBar->SetValue(static_cast(argument1)); + } + return 0; +} diff --git a/Source/UI/Dialogs/UILoadingWnd.h b/Source/UI/Dialogs/UILoadingWnd.h index 5bd97988..52c36525 100644 --- a/Source/UI/Dialogs/UILoadingWnd.h +++ b/Source/UI/Dialogs/UILoadingWnd.h @@ -1,11 +1,18 @@ #ifndef RAGNAROK_SOURCE_UI_DIALOGS_UILOADINGWND_H #define RAGNAROK_SOURCE_UI_DIALOGS_UILOADINGWND_H +#include "UI/UIBarGraph.h" #include "UI/Window/UIFrameWnd.h" +#include + class UILoadingWnd : public UIFrameWnd { public: void Paint() override; + int SendMsg(UIWindow* sender, int message, std::intptr_t argument1, std::intptr_t argument2, std::intptr_t argument3, std::intptr_t argument4) override; + + /* 00B4 */ unsigned char unknown_00B4[0x4]; + /* 00B8 */ UIBarGraph* m_progressBar; }; #endif