From 46296f103a025de0aca7e0841d2d55f2eb9f8ddb Mon Sep 17 00:00:00 2001 From: ragnarok-clanker Date: Fri, 6 Nov 2026 14:56:24 +0000 Subject: [PATCH] Decompile fn_13616 (UIMakeTargetListWnd::SendMsg) Batch #13283 by cremane: 0 byte-identical, 1 confirmed by peer review. - fn_13616 UIMakeTargetListWnd::SendMsg: logic confirmed by peer review Peer-reviewed-by: Tanke, Toshiro, codeplay Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes). --- Source/UI/Items/UIMakeTargetListWnd.cpp | 46 ++++++++++++++----------- 1 file changed, 25 insertions(+), 21 deletions(-) diff --git a/Source/UI/Items/UIMakeTargetListWnd.cpp b/Source/UI/Items/UIMakeTargetListWnd.cpp index 82040816..0efaec09 100644 --- a/Source/UI/Items/UIMakeTargetListWnd.cpp +++ b/Source/UI/Items/UIMakeTargetListWnd.cpp @@ -51,11 +51,31 @@ int UIMakeTargetListWnd::SendMsg(UIWindow* sender, int message, std::intptr_t a, ITEM_INFO item; switch (message) { + case 31: { + const int itemId = static_cast(a); + this->itemIds.push_back(itemId); + + item.SetItemId(itemId); + item.unknown_0060 = 0; + item.identified = 1; + this->m_list->AddLine(item.DisplayName(0).c_str()); + return 0; + } + + case 18: + this->m_list->SendMsg(nullptr, 18, 0, 0, 0, 0); + return 0; + + case 19: + this->m_list->SendMsg(nullptr, 19, 0, 0, 0, 0); + return 0; + case 6: { const int response = static_cast(a); this->RecordResponse(response, b, c, this->m_list->selected); - if (response == 184) { + switch (response) { + case 184: { if (g_replayAnimationScaling) { this->m_list->selected = static_cast(d); this->m_list->Invalidate(); @@ -89,35 +109,19 @@ int UIMakeTargetListWnd::SendMsg(UIWindow* sender, int message, std::intptr_t a, } } } - } else if (response == 185) { + break; + } + case 185: { ITEM_INFO materials[3]; g_modeMgr.GetGameMode()->SendMsg(130, 0, reinterpret_cast(materials), 0, 0); g_windowMgr.CloseWindow(79); return 0; } + } return 0; } - case 18: - this->m_list->SendMsg(nullptr, 18, 0, 0, 0, 0); - return 0; - - case 19: - this->m_list->SendMsg(nullptr, 19, 0, 0, 0, 0); - return 0; - - case 31: { - const int itemId = static_cast(a); - this->itemIds.push_back(itemId); - - item.SetItemId(itemId); - item.unknown_0060 = 0; - item.identified = 1; - this->m_list->AddLine(item.DisplayName(0).c_str()); - return 0; - } - case 123: { const auto* bytes = reinterpret_cast(a); std::uint16_t marker;