Decompile fn_12199 (UISkillDescribeWnd::Slot15)

Batch #10065 by codeplay: 0 byte-identical, 1 confirmed by peer review.

- fn_12199 UISkillDescribeWnd::Slot15: logic confirmed by peer review

Peer-reviewed-by: ragnarok-clanker, meitogi, gordaoprogramas
Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes).
This commit is contained in:
ragnarok-clanker 2026-11-02 15:06:35 +00:00
commit fdb595e4a3
6 changed files with 45 additions and 16 deletions

View file

@ -27,6 +27,7 @@
#include "Contents/SkinMgr.h"
#include "Client/Mode/ModeMgr.h"
#include "Client/Mode/CGameMode.h"
#include "Client/Input/Mouse.h"
#include "Client/Mode/EquipWindowLook.h"
#include "Contents/Actors/Pc.h"
#include "Contents/World/World.h"
@ -84,6 +85,7 @@
#include "UI/Dialogs/UIWaitWnd.h"
#include "UI/Items/UICardItemIllustWnd.h"
#include "UI/Items/UIEquipWnd.h"
#include "UI/Items/UISwapEquipmentWnd.h"
#include "UI/Items/UIExchangeWnd.h"
#include "UI/Items/UIItemCollectionWnd.h"
#include "UI/Items/UIItemIdentifyWnd.h"
@ -244,8 +246,8 @@ UIEquipWnd::UIEquipWnd(UIWindowContext& windows, UIFrameContext& frames) : UIFra
this->unknown_011C = 0;
this->unknown_012C = 0;
this->m_scrollBar = nullptr;
for (int& value : this->unknown_0138) {
value = 0;
for (UIWindow*& value : this->unknown_0138) {
value = nullptr;
}
this->m_firstSlot = 0;
this->unknown_015C = g_session.m_damageSkinMode;
@ -2931,6 +2933,24 @@ int UIDisconnectedServerMsgWnd::SendMsg(UIWindow* sender, int message, std::intp
return 0;
}
namespace {
#pragma pack(push, 1)
struct ChangeTitlePacket {
/* 0000 */ std::uint16_t packetType;
/* 0002 */ std::int32_t titleId;
};
struct TakeoffEquipAllPacket {
/* 0000 */ std::uint16_t packetType;
/* 0002 */ std::uint32_t location;
};
#pragma pack(pop)
}
bool IsEquipViewHidden();
// OFFSET: 0x008F9880
// OFFSET: 0x008F6750
// FUNCTION: fn_12322
void UISayDialogWnd::Resize(int width, int height) {
@ -3516,7 +3536,7 @@ void UIItemCompositionWnd::Slot15(int width, int height) {
// OFFSET: 0x008DE490
// FUNCTION: fn_12168
void UIComboBoxWnd::Slot15(int width, int height) {
this->m_list = new UIComboBox(*this->m_context, *reinterpret_cast<UIListBoxContext*>(nullptr));
this->m_list = new UIComboBox();
this->m_list->Configure(0, 0, width, height, 1);
this->AddChild(this->m_list);
}
@ -3526,7 +3546,7 @@ void UIComboBoxWnd::Slot15(int width, int height) {
void UISkillDescribeWnd::Slot15(int width, int height) {
this->unknown_00D4 = LookupMessage(526);
this->m_skillId = -1;
this->m_viewer = new UITextViewer(*this->m_context, *reinterpret_cast<UITextViewerContext*>(nullptr));
this->m_viewer = new UITextViewer();
this->m_viewer->Configure(3, 3, width - 6, height - 6, 0);
unsigned red, green, blue;
SkinPaletteChannels(ResourceMgr::Instance(), 2, 2, red, green, blue);
@ -3534,15 +3554,15 @@ void UISkillDescribeWnd::Slot15(int width, int height) {
this->m_viewer->backgroundColor = color;
this->m_viewer->Invalidate();
this->AddChild(this->m_viewer);
this->m_closeButton = this->AddCloseButton(*reinterpret_cast<UIButtonContext*>(nullptr), "ESC", 0);
this->m_closeButton = this->AddCloseButton("ESC", 0);
this->m_text = new UITextViewer(*this->m_context, *reinterpret_cast<UITextViewerContext*>(nullptr));
this->m_text = new UITextViewer();
this->m_text->backgroundColor = color;
this->m_text->Invalidate();
this->m_text->Configure(3, 3, width - 31, height - 6, 0);
this->AddChild(this->m_text);
this->m_delayButton = new UIBitmapButton(*this->m_context, *reinterpret_cast<UIButtonContext*>(nullptr));
this->m_delayButton = new UIBitmapButton();
this->m_delayButton->SetBitmap("유저인터페이스\\skilldelayinfo\\btn_sd_normal.bmp", 0, 0);
this->m_delayButton->SetBitmap("유저인터페이스\\skilldelayinfo\\btn_sd_over.bmp", 1, 0);
this->m_delayButton->SetBitmap("유저인터페이스\\skilldelayinfo\\btn_sd_pressed.bmp", 2, 0);
@ -3552,7 +3572,7 @@ void UISkillDescribeWnd::Slot15(int width, int height) {
this->m_delayButton->SetTooltip(LookupMessage(4254));
this->m_delayButton->Enable(0);
this->AddChild(this->m_delayButton);
this->AddCloseButton(*reinterpret_cast<UIButtonContext*>(nullptr), "", 0);
this->AddCloseButton("", 0);
}
// OFFSET: 0x008E8DC0
@ -7578,7 +7598,7 @@ void UIWhisperWnd::Slot15(int, int) {
this->m_resizer->SetColors(0xFFFF00FF, 0xFFFF00FF);
this->AddChild(this->m_resizer);
this->m_edit = new UIChatEditCtrl(*this->m_context, *reinterpret_cast<UIEditContext*>(nullptr));
this->m_edit = new UIChatEditCtrl();
this->m_edit->SetSize(this->geometry.width - 30, 16);
this->m_edit->Move(3, this->geometry.height - 18);
this->m_edit->maximum = 70;
@ -7588,7 +7608,7 @@ void UIWhisperWnd::Slot15(int, int) {
InputFocus{g_windowMgr.hoverWindow}.Set(this->m_edit);
this->m_edit->SetId(490);
UIChatHisBox2* history = new UIChatHisBox2(*this->m_context, *reinterpret_cast<UIListBoxContext*>(nullptr));
UIChatHisBox2* history = new UIChatHisBox2();
this->m_chatHistory = history;
history->Configure(0, 0, this->geometry.width - 2, this->geometry.height - 38, 1);
this->m_chatHistory->Move(1, 17);
@ -7598,7 +7618,7 @@ void UIWhisperWnd::Slot15(int, int) {
static_cast<UIChatHisBox2*>(this->m_chatHistory)->backgroundBlue = 255;
this->AddChild(this->m_chatHistory);
this->m_closeButton = this->AddCloseButton(*this->m_controls, "/q", 0);
this->m_closeButton = this->AddCloseButton("/q", 0);
}
// OFFSET: 0x008F6A30

View file

@ -221,6 +221,7 @@ public:
class UIChatEditCtrl : public UIEditCtrl {
public:
UIChatEditCtrl();
UIChatEditCtrl(UIWindowContext& windows, UIEditContext& edit);
void Paint() override;
void Slot25(int x, int y) override;

View file

@ -8,6 +8,7 @@ struct ITEM_INFO;
class UITabControl;
class UIListBoxTitle;
class UIBitmapButton;
class UICheckBox;
class UIEquipWnd : public UIFrameWnd {
public:
@ -25,7 +26,9 @@ public:
/* 00D0 */ UIBitmapButton* m_otherButton;
/* 00D4 */ std::uint32_t m_updateTick;
/* 00D8 */ int unknown_00D8;
/* 00DC */ unsigned char unknown_00DC[0x10];
/* 00DC */ UICheckBox* unknown_00DC;
/* 00E0 */ UICheckBox* unknown_00E0;
/* 00E4 */ unsigned char unknown_00E4[0x08];
/* 00EC */ UITabControl* m_tabs;
/* 00F0 */ int m_page;
/* 00F4 */ int m_contentTop;
@ -35,17 +38,17 @@ public:
/* 0120 */ UIListBoxTitle* m_titleList;
/* 0124 */ UIWindow* unknown_0124;
/* 0128 */ int unknown_0128;
/* 012C */ int unknown_012C;
/* 0130 */ int unknown_0130;
/* 012C */ UIBitmapButton* unknown_012C;
/* 0130 */ UIBitmapButton* unknown_0130;
/* 0134 */ UIWindow* m_scrollBar;
/* 0138 */ int unknown_0138[6];
/* 0138 */ UIWindow* unknown_0138[6];
/* 0150 */ int unknown_0150;
/* 0154 */ int m_firstSlot;
/* 0158 */ int m_hoverSlot;
/* 015C */ int unknown_015C;
/* 0160 */ std::vector<std::string> m_damageSkinNames;
/* 016C */ std::vector<std::string> m_damageSkinIcons;
/* 0178 */ int unknown_0178;
/* 0178 */ UIBitmapButton* unknown_0178;
void Slot19() override;
void Slot25(int x, int y) override;
@ -55,6 +58,7 @@ public:
void Slot31(int x, int y) override;
void Slot32(int x, int y) override;
void Slot35(int delta) override;
int SendMsg(UIWindow* sender, int message, std::intptr_t a, std::intptr_t b, std::intptr_t c, std::intptr_t d) override;
void DrawDamageSkinPage();
void DrawEquipSlots();

View file

@ -20,6 +20,8 @@ public:
};
class UISwapEquipmentWnd : public UIFrameWnd {
friend class UIEquipWnd;
public:
UISwapEquipmentWnd(UIWindowContext& windows, UIFrameContext& frames);
void Slot10(int x, int y, std::intptr_t value) override;

View file

@ -7,6 +7,7 @@
class UIComboBox : public UIListBox {
public:
UIComboBox();
UIComboBox(UIWindowContext& windows, UIListBoxContext& list);
void Resize(int width, int height) override;
void Slot15(int width, int height) override;

View file

@ -7,6 +7,7 @@ struct UIButtonContext;
class UIChatHisBox2 : public UIChatHisBox {
public:
UIChatHisBox2();
UIChatHisBox2(UIWindowContext& windows, UIListBoxContext& list);
bool Slot08() override;
void Paint() override;