From 5aa8b42abb4e326758fec9589f85dbd22b764fb0 Mon Sep 17 00:00:00 2001 From: ragnarok-clanker Date: Fri, 30 Oct 2026 00:44:53 +0000 Subject: [PATCH] Decompile 5 functions in Source/UI/Quest/UIRenewQuestUI.cpp, Source/UI/Quest/UIRenewQuestUI.h, ... Batch #4047 by youko: 4 byte-identical, 1 confirmed by peer review. - fn_16634 CUIRenewQuestUI::OnTabButton: byte-identical - fn_16635 CUIRenewQuestUI::OnPanelButton: byte-identical - fn_16659 CUIListBoxEx::ClearItems: byte-identical - fn_16660 CUIListBoxEx::ClearItems: byte-identical - fn_16661 CUISelectPackageItemBox::Slot53: logic confirmed by peer review Peer-reviewed-by: ragnarok-clanker, Yommy, superintelligence Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes). Adds to the build: Source/UI/SelectPackageItemBox/UISelectPackageItemBox.cpp --- Source/UI/Quest/UIRenewQuestUI.cpp | 10 +++++ Source/UI/Quest/UIRenewQuestUI.h | 3 ++ .../SelectPackageItemBox.h | 31 ++++++++++++++++ .../UISelectPackageItemBox.cpp | 37 +++++++++++++++++++ data/compile.json | 1 + 5 files changed, 82 insertions(+) create mode 100644 Source/UI/SelectPackageItemBox/SelectPackageItemBox.h create mode 100644 Source/UI/SelectPackageItemBox/UISelectPackageItemBox.cpp diff --git a/Source/UI/Quest/UIRenewQuestUI.cpp b/Source/UI/Quest/UIRenewQuestUI.cpp index b8ce1e15..1857b52b 100644 --- a/Source/UI/Quest/UIRenewQuestUI.cpp +++ b/Source/UI/Quest/UIRenewQuestUI.cpp @@ -606,3 +606,13 @@ void CUIRenewQuestUI::Slot53(int value) { this->Slot15(this->geometry.width, this->geometry.height); this->Slot16(); } + +// OFFSET: 0x00A67FA0 +// FUNCTION: fn_16634 +void CUIRenewQuestUI::OnTabButton(CUITabButton* button) { +} + +// OFFSET: 0x00A67FB0 +// FUNCTION: fn_16635 +void CUIRenewQuestUI::OnPanelButton() { +} diff --git a/Source/UI/Quest/UIRenewQuestUI.h b/Source/UI/Quest/UIRenewQuestUI.h index 24faa296..ab25023c 100644 --- a/Source/UI/Quest/UIRenewQuestUI.h +++ b/Source/UI/Quest/UIRenewQuestUI.h @@ -32,6 +32,9 @@ class CUIRenewQuestUI : public CUIFrameWnd { public: void Paint() override; virtual void Slot53(int value); + + void OnTabButton(CUITabButton* button); + void OnPanelButton(); }; #if defined(_WIN32) && !defined(_WIN64) diff --git a/Source/UI/SelectPackageItemBox/SelectPackageItemBox.h b/Source/UI/SelectPackageItemBox/SelectPackageItemBox.h new file mode 100644 index 00000000..0c40786a --- /dev/null +++ b/Source/UI/SelectPackageItemBox/SelectPackageItemBox.h @@ -0,0 +1,31 @@ +#ifndef RAGNAROK_SOURCE_UI_SELECTPACKAGEITEMBOX_SELECTPACKAGEITEMBOX_H +#define RAGNAROK_SOURCE_UI_SELECTPACKAGEITEMBOX_SELECTPACKAGEITEMBOX_H + +#include "Contents/Items/ItemInfo.h" +#include "UI/FrameSkin.h" +#include "UI/Lists/UIListBoxTemplate.h" + +#include + +namespace SelectPackageItemBox { +class CTabInfoData { +public: + /* 0000 */ unsigned char unknown_0000[0x08]; + /* 0008 */ std::string unknown_0008; +}; + +class CUIItemInfo : public CUIListItem {}; + +class CUITabInfo : public CUIListItem {}; +} + +class CUISelectPackageItemBox : public CUIFrameWnd { +public: + virtual void Slot53(); +}; + +#if defined(_WIN32) && !defined(_WIN64) +static_assert(sizeof(SelectPackageItemBox::CTabInfoData) == 0x20); +#endif + +#endif diff --git a/Source/UI/SelectPackageItemBox/UISelectPackageItemBox.cpp b/Source/UI/SelectPackageItemBox/UISelectPackageItemBox.cpp new file mode 100644 index 00000000..11a5662f --- /dev/null +++ b/Source/UI/SelectPackageItemBox/UISelectPackageItemBox.cpp @@ -0,0 +1,37 @@ +#include "UI/SelectPackageItemBox/SelectPackageItemBox.h" + +// OFFSET: 0x00A693D0 +// FUNCTION: fn_16659 +template <> +void CUIListBoxEx::ClearItems() { + for (SelectPackageItemBox::CUIItemInfo* item : this->items) { + this->RemoveChild(item, 1); + } + + this->items.clear(); + this->selected = static_cast(-1); +} + +// OFFSET: 0x00A69430 +// FUNCTION: fn_16660 +template <> +void CUIListBoxEx::ClearItems() { + for (SelectPackageItemBox::CUITabInfo* item : this->items) { + this->RemoveChild(item, 1); + } + + this->items.clear(); + this->selected = static_cast(-1); +} + +// OFFSET: 0x00A694F0 +// FUNCTION: fn_16661 +void CUISelectPackageItemBox::Slot53() { + this->unknown_00B4 = 0; + this->Resize(387, 283); + this->Move(0, 0); + this->Slot15(this->geometry.width, this->geometry.height); + this->Slot16(); + this->SetSkinColors(0, 0, 0, 0); + this->m_buttonBarStyle = 3; +} diff --git a/data/compile.json b/data/compile.json index 93aed984..2cdcb1a1 100644 --- a/data/compile.json +++ b/data/compile.json @@ -791,6 +791,7 @@ "Source/UI/Quest/UIQuestDisplay.cpp": 2, "Source/UI/Quest/UIRecommendedQuestInfo.cpp": 2, "Source/UI/Quest/UIRenewQuestUI.cpp": 2, + "Source/UI/SelectPackageItemBox/UISelectPackageItemBox.cpp": 2, "Source/UI/Shop/ItemDrawing.cpp": 2, "Source/UI/Shop/MerchantShopRefresh.cpp": 2, "Source/UI/Shop/PriceColor.cpp": 2,