From 922c094330c7ccc8861e687553abf0e6a2ecfe0c Mon Sep 17 00:00:00 2001 From: ragnarok-clanker Date: Thu, 5 Nov 2026 01:20:31 +0000 Subject: [PATCH] Decompile 2 functions in Source/UI/Buttons/UIButton.cpp Batch #11558 by dori: 0 byte-identical, 2 confirmed by peer review. - fn_10858 UIButton::Slot28: logic confirmed by peer review - fn_10875 UIButton::ResetCursor: logic confirmed by peer review Peer-reviewed-by: Yommy, KWDev, Tanke, cremane Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes). --- Source/UI/Buttons/UIButton.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Source/UI/Buttons/UIButton.cpp b/Source/UI/Buttons/UIButton.cpp index d64d6f12a..9e22e1c20 100644 --- a/Source/UI/Buttons/UIButton.cpp +++ b/Source/UI/Buttons/UIButton.cpp @@ -4,6 +4,7 @@ #include "UI/Window/UINewSelectCharWnd.h" #include "Contents/MessageTable.h" #include "Client/Mode/CMode.h" +#include "Client/Mode/ModeMgr.h" #include "Client/Mode/ModeEvents.h" #include "Resource/Bitmap/BitmapResource.h" #include "Resource/ResourceMgr.h" @@ -119,7 +120,7 @@ void UIButton::Slot28(int x, int y) { screenY = (screenY + window->geometry.y); } - static_cast(g_charViewMode)->ShowTooltip(this->m_tooltip.c_str(), screenX, screenY, -1, false, true); + g_modeMgr.gameMode->ShowTooltip(this->m_tooltip.c_str(), screenX, screenY, -1, false, true); } if (this->m_disabled == 0) { @@ -141,7 +142,7 @@ void UIButton::Slot29(int x, int y) { // OFFSET: 0x0085F950 // FUNCTION: fn_10875 void UIButton::ResetCursor(int, int) { - static_cast(g_charViewMode)->SetCursorAction(this->m_disabled != 0 ? 0 : 2); + g_modeMgr.gameMode->SetCursorAction(this->m_disabled != 0 ? 0 : 2); } // OFFSET: 0x0085EED0