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