Decompile 9 functions in Source/UI/Acceptance/UIChooseSellBuyWnd.cpp, Source/UI/Party/UIPartySettingWnd.h, ...

Batch #1849 by Yommy: 0 byte-identical, 9 confirmed by peer review.

- fn_12223 UIGraffiStrboxWnd::Paint: logic confirmed by peer review
- fn_12231 UIMinimapZoomWnd::Paint: logic confirmed by peer review
- fn_12239 UIPartyInvitationToWnd::Paint: logic confirmed by peer review
- fn_12240 UIPartySettingWnd::Paint: logic confirmed by peer review
- fn_12249 UISelectCartWnd::Paint: logic confirmed by peer review
- fn_12250 UISkillDescribeWnd::Paint: logic confirmed by peer review
- fn_12259 UIWhisperWnd::Paint: logic confirmed by peer review
- fn_12266 UIWhisperWnd::Slot26: logic confirmed by peer review
- fn_12297 UINotifyItemObtainWnd::Slot19: logic confirmed by peer review

Reviewed-by: ragnarok-clanker
This commit is contained in:
ragnarok-clanker 2026-10-28 22:53:46 +00:00
commit e6c26dca89
8 changed files with 219 additions and 0 deletions

View file

@ -1,15 +1,19 @@
#include "Client/Application/ApplicationWindow.h"
#include "Client/Mode/ActiveGameMode.h" #include "Client/Mode/ActiveGameMode.h"
#include "Client/Mode/CGameMode.h"
#include "Client/Mode/ModeEvents.h" #include "Client/Mode/ModeEvents.h"
#include "Client/Replay.h" #include "Client/Replay.h"
#include "Client/ReplayPacketRecorder.h" #include "Client/ReplayPacketRecorder.h"
#include "Resource/Bitmap/BitmapResource.h" #include "Resource/Bitmap/BitmapResource.h"
#include "Resource/ResourceMgr.h" #include "Resource/ResourceMgr.h"
#include "Resource/SkinPalette.h"
#include "Resource/TextureNames.h" #include "Resource/TextureNames.h"
#include "UI/Acceptance/UIJoinPartyAcceptWnd.h" #include "UI/Acceptance/UIJoinPartyAcceptWnd.h"
#include "UI/Buttons/UIBitmapButton.h" #include "UI/Buttons/UIBitmapButton.h"
#include "UI/Chat/UIWhisperWnd.h" #include "UI/Chat/UIWhisperWnd.h"
#include "UI/Dialogs/UIBookWnd.h" #include "UI/Dialogs/UIBookWnd.h"
#include "UI/Dialogs/UIDisconnectedServerMsgWnd.h" #include "UI/Dialogs/UIDisconnectedServerMsgWnd.h"
#include "UI/Dialogs/UIGraffiStrboxWnd.h"
#include "UI/Dialogs/UILoadingWnd.h" #include "UI/Dialogs/UILoadingWnd.h"
#include "UI/Dialogs/UIMenuWnd.h" #include "UI/Dialogs/UIMenuWnd.h"
#include "UI/Dialogs/UIMinimapZoomWnd.h" #include "UI/Dialogs/UIMinimapZoomWnd.h"
@ -26,14 +30,20 @@
#include "UI/Items/UIExchangeWnd.h" #include "UI/Items/UIExchangeWnd.h"
#include "UI/Items/UIItemCollectionWnd.h" #include "UI/Items/UIItemCollectionWnd.h"
#include "UI/Items/UIItemIdentifyWnd.h" #include "UI/Items/UIItemIdentifyWnd.h"
#include "UI/Items/UINotifyItemObtainWnd.h"
#include "UI/Lists/UIComboBoxWnd.h" #include "UI/Lists/UIComboBoxWnd.h"
#include "UI/Lists/UIListBox.h" #include "UI/Lists/UIListBox.h"
#include "UI/Party/UIPartySettingWnd.h" #include "UI/Party/UIPartySettingWnd.h"
#include "UI/Shop/UInCash_CallWnd.h" #include "UI/Shop/UInCash_CallWnd.h"
#include "UI/Skill/UISkillDescribeWnd.h"
#include "UI/Status/UIStatusWnd.h" #include "UI/Status/UIStatusWnd.h"
#include "UI/Text/UITextViewer.h" #include "UI/Text/UITextViewer.h"
#include "UI/Window/UIWindowMgr.h"
#include "UI/Window/WindowBorder.h"
#include "UI/Window/WindowManagerWindows.h" #include "UI/Window/WindowManagerWindows.h"
#include "Utility/Text/FormatString.h"
#include <cstdio>
#include <cstring> #include <cstring>
#include <windows.h> #include <windows.h>
#include <timeapi.h> #include <timeapi.h>
@ -119,11 +129,35 @@ void UIDisconnectedServerMsgWnd::Paint() {
this->DrawBitmap(0, 0, bitmap ? &bitmap->image : nullptr, false); this->DrawBitmap(0, 0, bitmap ? &bitmap->image : nullptr, false);
} }
// OFFSET: 0x008EE230
// FUNCTION: fn_12223
void UIGraffiStrboxWnd::Paint() {
auto& controls = *this->m_controls;
const int titleHeight = this->DrawTitleBar(controls.fonts, controls.locale, false, "", 0);
this->DrawPanelBackground(titleHeight, 0, "");
this->DrawButtonBar(2, 0, 1);
this->DrawTextAt(controls.fonts, controls.locale, 17, 23, controls.services.MessageText(436), 0, 0, 12, 0xFFFFFF, 0, 0);
this->DrawTextAt(controls.fonts, controls.locale, 16, 22, controls.services.MessageText(436), 0, 0, 12, 0, 0, 0);
}
// OFFSET: 0x008EECD0 // OFFSET: 0x008EECD0
// FUNCTION: fn_12228 // FUNCTION: fn_12228
void UILoadingWnd::Paint() { void UILoadingWnd::Paint() {
} }
// OFFSET: 0x008EF0A0
// FUNCTION: fn_12231
void UIMinimapZoomWnd::Paint() {
auto& controls = *this->m_controls;
this->ClearSurface(0xFFFF00FF);
int column = 0;
int row = 0;
static_cast<CGameMode*>(g_world.ActiveGameMode())->PlayerCell(&column, &row);
const std::string text = FormatOwnedString(" %d %d", column, row);
this->DrawTextAt(controls.fonts, controls.locale, 19, 128, text.c_str(), 0, 0, 12, 0, 0, 0);
this->DrawTextAt(controls.fonts, controls.locale, 20, 128, text.c_str(), 0, 0, 12, 0xFFFFFF, 0, 0);
}
// OFFSET: 0x008EF590 // OFFSET: 0x008EF590
// FUNCTION: fn_12233 // FUNCTION: fn_12233
void UINoticeConfirmWnd::Paint() { void UINoticeConfirmWnd::Paint() {
@ -141,6 +175,34 @@ void UINotifyLevelUpWnd::Paint() {
void UINotifyQuestWnd::Paint() { void UINotifyQuestWnd::Paint() {
} }
// OFFSET: 0x008EF9A0
// FUNCTION: fn_12239
void UIPartyInvitationToWnd::Paint() {
auto& controls = *this->m_controls;
const int titleHeight = this->DrawTitleBar(controls.fonts, controls.locale, true, controls.services.MessageText(2056), 0);
this->DrawPanelBackground(titleHeight, 0, "");
this->DrawButtonBar(2, 0, 1);
this->DrawTextAt(controls.fonts, controls.locale, 10, 22, controls.services.MessageText(2058), 0, 0, 12, 0, 0, 0);
}
// OFFSET: 0x008EFA00
// FUNCTION: fn_12240
void UIPartySettingWnd::Paint() {
auto& controls = *this->m_controls;
const int titleHeight = this->DrawTitleBar(controls.fonts, controls.locale, true, controls.services.MessageText(this->m_mode == 50 ? 2054 : 291), 0);
this->DrawPanelBackground(titleHeight, 0, "");
this->DrawButtonBar(2, 0, 1);
if (this->m_mode == 70) {
this->DrawTextAt(controls.fonts, controls.locale, 10, 22, controls.services.MessageText(292), 0, 0, 12, 0, 0, 0);
} else if (this->m_mode == 50) {
this->DrawTextAt(controls.fonts, controls.locale, 10, 22, controls.services.MessageText(2057), 0, 0, 12, 0, 0, 0);
}
this->DrawTextAt(controls.fonts, controls.locale, 10, this->m_mode + 82, controls.services.MessageText(738), 0, 0, 12, 0, 0, 0);
this->DrawTextAt(controls.fonts, controls.locale, 10, this->m_mode + 17, controls.services.MessageText(293), 0, 0, 12, 0, 0, 0);
}
// OFFSET: 0x008EFF60 // OFFSET: 0x008EFF60
// FUNCTION: fn_12245 // FUNCTION: fn_12245
void UIQuitWnd::Paint() { void UIQuitWnd::Paint() {
@ -155,6 +217,33 @@ void UIRestartWnd::Paint() {
this->DrawBitmap(0, 0, bitmap ? &bitmap->image : nullptr, false); this->DrawBitmap(0, 0, bitmap ? &bitmap->image : nullptr, false);
} }
// OFFSET: 0x008F0350
// FUNCTION: fn_12249
void UISelectCartWnd::Paint() {
auto& controls = *this->m_controls;
const int titleHeight = this->DrawTitleBar(controls.fonts, controls.locale, true, controls.services.MessageText(659), 0);
this->DrawPanelBackground(titleHeight, 0, "");
const auto* left = static_cast<CBitmapRes*>(ResourceMgr::Instance().Load(Resolve("유저인터페이스\\sysboxs_ld.bmp")));
this->DrawBitmap(0, this->geometry.height - left->image.height, &left->image, false);
const auto* right = static_cast<CBitmapRes*>(ResourceMgr::Instance().Load(Resolve("유저인터페이스\\sysboxs_rd.bmp")));
this->DrawBitmap(this->geometry.width - right->image.width, this->geometry.height - right->image.height, &right->image, false);
}
// OFFSET: 0x008F0400
// FUNCTION: fn_12250
void UISkillDescribeWnd::Paint() {
this->ClearSurface(0xFFFF00FF);
unsigned red, green, blue;
SkinPaletteChannels(ResourceMgr::Instance(), 2, 2, red, green, blue);
const UIWindow* text = this->m_text;
this->FillRegion(
text->geometry.width + text->geometry.x, text->geometry.y, this->geometry.width - text->geometry.width - text->geometry.x - 3, text->geometry.height,
RGB(red, green, blue)
);
DrawRoundedBorder(*this, 0, 0, this->geometry.width, this->geometry.height, 0xC3C3C3);
DrawRoundedBorder(*this, 2, 2, this->geometry.width - 4, this->geometry.height - 4, 0xFFFFFF);
}
// OFFSET: 0x008F2A90 // OFFSET: 0x008F2A90
// FUNCTION: fn_12258 // FUNCTION: fn_12258
void UIWaitWnd::Paint() { void UIWaitWnd::Paint() {
@ -162,6 +251,23 @@ void UIWaitWnd::Paint() {
this->DrawBitmap(0, 0, bitmap ? &bitmap->image : nullptr, false); this->DrawBitmap(0, 0, bitmap ? &bitmap->image : nullptr, false);
} }
// OFFSET: 0x008F2AD0
// FUNCTION: fn_12259
void UIWhisperWnd::Paint() {
auto& controls = *this->m_controls;
char title[128];
if (!this->m_code.empty()) {
std::sprintf(title, "With %s [%s]", this->m_name.c_str(), this->m_code.c_str());
} else {
std::sprintf(title, "With %s", this->m_name.c_str());
}
DrawRoundedBorder(*this, 0, 0, this->geometry.width, this->geometry.height, 0xC0C0C0);
this->FillRegion(1, this->geometry.height - 20, this->geometry.width - 2, 1, 0xC0C0C0);
this->DrawTextAt(controls.fonts, controls.locale, 10, 3, title, 0, 0, 12, 0xFFFFFF, 0, 0);
}
// OFFSET: 0x008F2DE0 // OFFSET: 0x008F2DE0
// FUNCTION: fn_12261 // FUNCTION: fn_12261
void UInCash_CallWnd::Paint() { void UInCash_CallWnd::Paint() {
@ -182,6 +288,27 @@ void UIStatusWnd::Slot26(int, int y) {
} }
} }
// OFFSET: 0x008F3330
// FUNCTION: fn_12266
void UIWhisperWnd::Slot26(int, int y) {
if (y >= 17 || this->m_code.size() == 0) {
return;
}
HGLOBAL memory = GlobalAlloc(GHND, this->m_code.size() + 1);
void* data = GlobalLock(memory);
std::memcpy(data, this->m_code.c_str(), this->m_code.size());
GlobalUnWire(memory);
if (OpenClipboard(hWnd)) {
EmptyClipboard();
SetClipboardData(CF_TEXT, memory);
CloseClipboard();
g_windowMgr.SendNotice(3, 0, 0, 0, 0, 0);
g_windowMgr.SendNotice(1, reinterpret_cast<std::intptr_t>("C-Code copied to clipboard"), 0x64FFFF, 0, 0, 0);
}
}
// OFFSET: 0x008F3630 // OFFSET: 0x008F3630
// FUNCTION: fn_12268 // FUNCTION: fn_12268
void UIBookWnd::Slot25(int x, int y) { void UIBookWnd::Slot25(int x, int y) {
@ -337,6 +464,14 @@ void UIItemCollectionWnd::Slot19() {
} }
} }
// OFFSET: 0x008F4FC0
// FUNCTION: fn_12297
void UINotifyItemObtainWnd::Slot19() {
if (timeGetTime() > this->m_shownTick + 5000) {
this->m_frameContext->windows.CloseWindow(58);
}
}
// OFFSET: 0x008F50B0 // OFFSET: 0x008F50B0
// FUNCTION: fn_12300 // FUNCTION: fn_12300
void UISayDialogWnd::Slot19() { void UISayDialogWnd::Slot19() {

View file

@ -3,9 +3,23 @@
#include "UI/Window/UIFrameWnd.h" #include "UI/Window/UIFrameWnd.h"
#include <string>
struct UIButtonContext;
class UIWhisperWnd : public UIFrameWnd { class UIWhisperWnd : public UIFrameWnd {
public: public:
/* 00B4 */ unsigned char unknown_00B4[0x18];
/* 00CC */ std::string m_name;
/* 00E4 */ unsigned char unknown_00E4[0x20];
/* 0104 */ std::string m_code;
void Paint() override;
void Slot26(int x, int y) override;
void Slot33(int x, int y) override; void Slot33(int x, int y) override;
protected:
UIButtonContext* m_controls;
}; };
#endif #endif

View file

@ -0,0 +1,16 @@
#ifndef RAGNAROK_SOURCE_UI_DIALOGS_UIGRAFFISTRBOXWND_H
#define RAGNAROK_SOURCE_UI_DIALOGS_UIGRAFFISTRBOXWND_H
#include "UI/Window/UIFrameWnd.h"
struct UIButtonContext;
class UIGraffiStrboxWnd : public UIFrameWnd {
public:
void Paint() override;
protected:
UIButtonContext* m_controls;
};
#endif

View file

@ -3,9 +3,15 @@
#include "UI/Window/UIFrameWnd.h" #include "UI/Window/UIFrameWnd.h"
struct UIButtonContext;
class UIMinimapZoomWnd : public UIFrameWnd { class UIMinimapZoomWnd : public UIFrameWnd {
public: public:
void Paint() override;
void Slot25(int x, int y) override; void Slot25(int x, int y) override;
protected:
UIButtonContext* m_controls;
}; };
#endif #endif

View file

@ -3,9 +3,15 @@
#include "UI/Window/UIFrameWnd.h" #include "UI/Window/UIFrameWnd.h"
struct UIButtonContext;
class UISelectCartWnd : public UIFrameWnd { class UISelectCartWnd : public UIFrameWnd {
public: public:
void Paint() override;
void Slot25(int x, int y) override; void Slot25(int x, int y) override;
protected:
UIButtonContext* m_controls;
}; };
#endif #endif

View file

@ -0,0 +1,14 @@
#ifndef RAGNAROK_SOURCE_UI_ITEMS_UINOTIFYITEMOBTAINWND_H
#define RAGNAROK_SOURCE_UI_ITEMS_UINOTIFYITEMOBTAINWND_H
#include "UI/Window/UIFrameWnd.h"
class UINotifyItemObtainWnd : public UIFrameWnd {
public:
/* 00B4 */ unsigned char unknown_00B4[0x30];
/* 00E4 */ std::uint32_t m_shownTick;
void Slot19() override;
};
#endif

View file

@ -3,9 +3,23 @@
#include "UI/Window/UIFrameWnd.h" #include "UI/Window/UIFrameWnd.h"
struct UIButtonContext;
class UIPartySettingWnd : public UIFrameWnd { class UIPartySettingWnd : public UIFrameWnd {
public: public:
/* 00B4 */ unsigned char unknown_00B4[0x28];
/* 00DC */ int m_mode;
void Paint() override;
void Slot25(int x, int y) override; void Slot25(int x, int y) override;
protected:
UIButtonContext* m_controls;
};
class UIPartyInvitationToWnd : public UIPartySettingWnd {
public:
void Paint() override;
}; };
#endif #endif

View file

@ -0,0 +1,14 @@
#ifndef RAGNAROK_SOURCE_UI_SKILL_UISKILLDESCRIBEWND_H
#define RAGNAROK_SOURCE_UI_SKILL_UISKILLDESCRIBEWND_H
#include "UI/Window/UIFrameWnd.h"
class UISkillDescribeWnd : public UIFrameWnd {
public:
/* 00B4 */ unsigned char unknown_00B4[0x54];
/* 0108 */ UIWindow* m_text;
void Paint() override;
};
#endif