Decompile fn_11752 (UITalkboxTrapInputWnd::Slot15)

Batch #7179 by aDw: 0 byte-identical, 1 confirmed by peer review.

- fn_11752 UITalkboxTrapInputWnd::Slot15: logic confirmed by peer review

Peer-reviewed-by: ragnarok-clanker, alisonrag, superintelligence
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-10-31 04:40:13 +00:00
commit 4e38d1a589
2 changed files with 34 additions and 0 deletions

View file

@ -1053,6 +1053,37 @@ void UIChatRoomWnd::Move(int x, int y) {
this->Slot36();
}
// OFFSET: 0x008B7040
// FUNCTION: fn_11752
void UITalkboxTrapInputWnd::Slot15(int, int) {
this->edit = new UIEditCtrl(*this->m_context, *this->m_editContext);
this->edit->SetSize(240, 16);
this->edit->Move(22, 50);
this->edit->maximum = 78;
this->edit->Background(242, 242, 242);
this->AddChild(this->edit);
InputFocus focus{g_windowMgr.hoverWindow};
focus.Set(this->edit);
const std::string prefix("유저인터페이스\\");
const char* names[2][3] = {{"btn_ok", "btn_ok_a", "btn_ok_b"}, {"btn_cancel", "btn_cancel_a", "btn_cancel_b"}};
int ids[2] = {184, 185};
int positions[2][2] = {{189, 96}, {234, 96}};
for (int index = 0; index < 2; ++index) {
auto* button = new UIBitmapButton(*this->m_context, *this->m_controls);
button->SetBitmap((prefix + names[index][0] + ".bmp").c_str(), 0, 0);
button->SetBitmap((prefix + names[index][1] + ".bmp").c_str(), 1, 0);
button->SetBitmap((prefix + names[index][2] + ".bmp").c_str(), 2, 0);
button->SetSize(button->BitmapWidth(), button->BitmapHeight());
button->Move(positions[index][0], positions[index][1]);
button->SetId(ids[index]);
this->AddChild(button);
}
this->m_message0 = 184;
}
// OFFSET: 0x008B7A60
// FUNCTION: fn_11753
void UILoginOTPWnd::Slot18() {

View file

@ -4,6 +4,7 @@
#include "UI/Window/UIFrameWnd.h"
class UIEditCtrl;
struct UIEditContext;
struct TalkboxTrapTarget {
/* 0000 */ int unknown_0000;
@ -19,6 +20,7 @@ struct TalkboxTrapRequest {
class UITalkboxTrapInputWnd : public UIFrameWnd {
public:
void Slot15(int width, int height) override;
void Paint() override;
int SendMsg(UIWindow* sender, int message, std::intptr_t a, std::intptr_t b, std::intptr_t c, std::intptr_t d) override;
@ -27,6 +29,7 @@ public:
protected:
UIButtonContext* m_controls;
UIEditContext* m_editContext;
};
#endif