Decompile 8 functions in Source/UI/UILapineUpgradeBoxWnd.cpp, Source/UI/UILapineUpgradeBoxWnd.h

Batch #1398 by Yommy: 0 byte-identical, 8 confirmed by peer review.

- fn_04194 UILapineUpgradeBoxWnd::Slot10: logic confirmed by peer review
- fn_04195 UILapineUpgradeBox_IngredientInfoWnd::Slot10: logic confirmed by peer review
- fn_04197 UILapineUpgradeBox_IngredientInfoWnd::Move: logic confirmed by peer review
- fn_04203 UILapineUpgradeBoxWnd::Slot26: logic confirmed by peer review
- fn_04204 UILapineUpgradeBox_IngredientInfoWnd::Slot26: logic confirmed by peer review
- fn_04207 UILapineUpgradeBox_IngredientInfoWnd::Slot31: logic confirmed by peer review
- fn_04213 UILapineUpgradeBox_IngredientInfoWnd::Slot35: logic confirmed by peer review
- fn_04225 UILapineUpgradeBoxWnd::SetWaiting: logic confirmed by peer review

Reviewed-by: ragnarok-clanker
Adds to the build: Source/UI/UILapineUpgradeBoxWnd.cpp
This commit is contained in:
ragnarok-clanker 2026-10-28 12:35:53 +00:00
commit 5c5adbf389
3 changed files with 123 additions and 0 deletions

View file

@ -0,0 +1,77 @@
#include "UI/UILapineUpgradeBoxWnd.h"
#include "Client/Mode/ModeDragState.h"
#include "Client/Mode/ModeEvents.h"
#include "UI/Buttons/UIBitmapButton.h"
// OFFSET: 0x006035E0
// FUNCTION: fn_04194
void UILapineUpgradeBoxWnd::Slot10(int x, int y, std::intptr_t value) {
ModeEvents* mode = this->m_context->mode;
if (this->item.unknown_0000[1] > 0) {
mode->SendModeMessage(18, 0, 0, 0, 0);
return;
}
const ModeDragState* drag = reinterpret_cast<const ModeDragState*>(value);
if (drag->source == 27) {
this->SendMsg(this, 31, drag->id, 0, 0, 0);
}
mode->SendModeMessage(18, 0, 0, 0, 0);
}
// OFFSET: 0x00603650
// FUNCTION: fn_04195
void UILapineUpgradeBox_IngredientInfoWnd::Slot10(int x, int y, std::intptr_t value) {
if (this->parent) {
this->parent->Slot10(x + this->geometry.x, y + this->geometry.y, value);
}
}
// OFFSET: 0x006036D0
// FUNCTION: fn_04197
void UILapineUpgradeBox_IngredientInfoWnd::Move(int x, int y) {
UIWindow::Move(x, y);
}
// OFFSET: 0x00603DB0
// FUNCTION: fn_04203
void UILapineUpgradeBoxWnd::Slot26(int x, int y) {
if (static_cast<unsigned>(x - 101) <= 24 && static_cast<unsigned>(y - 165) <= 24 && this->item.unknown_0000[1] != 0) {
this->SendMsg(this, 104, this->item.unknown_0000[1], 0, 0, 0);
}
}
// OFFSET: 0x00603DF0
// FUNCTION: fn_04204
void UILapineUpgradeBox_IngredientInfoWnd::Slot26(int x, int y) {
if (this->item.unknown_0000[1] > 0) {
this->parent->SendMsg(this, 104, this->item.unknown_0000[1], 0, 0, 0);
}
}
// OFFSET: 0x00603EC0
// FUNCTION: fn_04207
void UILapineUpgradeBox_IngredientInfoWnd::Slot31(int x, int y) {
this->selected = 1;
this->Invalidate();
if (this->parent) {
this->parent->SendMsg(this, 6, 0, 0, 0, 0);
}
}
// OFFSET: 0x00604180
// FUNCTION: fn_04213
void UILapineUpgradeBox_IngredientInfoWnd::Slot35(int argument) {
if (this->parent) {
this->parent->Slot35(argument);
}
}
// OFFSET: 0x00605BB0
// FUNCTION: fn_04225
void UILapineUpgradeBoxWnd::SetWaiting(unsigned char value) {
this->waiting = value;
this->upgradeButton->SetDisabled(value);
this->upgradeButton->Invalidate();
this->Invalidate();
}

View file

@ -0,0 +1,45 @@
#ifndef RAGNAROK_SOURCE_UI_UILAPINEUPGRADEBOXWND_H
#define RAGNAROK_SOURCE_UI_UILAPINEUPGRADEBOXWND_H
#include "Contents/Items/ItemInfo.h"
#include "UI/Window/UIFrameWnd.h"
#include <string>
class UIBitmapButton;
class UILapineUpgradeBox_IngredientInfoWnd : public UIFrameWnd {
public:
void Move(int x, int y) override;
void Slot10(int x, int y, std::intptr_t value) override;
void Slot26(int x, int y) override;
void Slot31(int x, int y) override;
void Slot35(int argument) override;
/* 00B8 */ ItemInfo item;
/* 01B0 */ unsigned char selected;
/* 01B4 */ std::string tooltip;
/* 01CC */ int quantity;
};
class UILapineUpgradeBoxWnd : public UIFrameWnd {
public:
void Slot10(int x, int y, std::intptr_t value) override;
void Slot26(int x, int y) override;
void SetWaiting(unsigned char value);
/* 00B4 */ UIBitmapButton* closeButton;
/* 00B8 */ UIBitmapButton* upgradeButton;
/* 00BC */ UIBitmapButton* selectButton;
/* 00C0 */ UIWindow* ingredientList;
/* 00C4 */ int ingredientId;
/* 00C8 */ std::string title;
/* 00E0 */ ItemInfo item;
/* 01DC */ std::string description;
/* 01F4 */ std::string notice;
/* 020C */ std::uint32_t noticeTick;
/* 0210 */ std::uint32_t noticeDuration;
/* 0214 */ unsigned char waiting;
};
#endif

View file

@ -611,6 +611,7 @@
"Source/UI/Text/UITextViewerMessages.cpp": 2,
"Source/UI/Text/UITransBalloonText.cpp": 2,
"Source/UI/UILapineScrollBar.cpp": 2,
"Source/UI/UILapineUpgradeBoxWnd.cpp": 2,
"Source/UI/UIStaticBitmap.cpp": 2,
"Source/UI/Window/FrameFocus.cpp": 2,
"Source/UI/Window/FrameTextCache.cpp": 2,