Decompile fn_14637 (CUIControl::IsPointInside)

Batch #1168 by eAthena: 0 byte-identical, 1 confirmed by peer review.

- fn_14637 CUIControl::IsPointInside: logic confirmed by peer review

Reviewed-by: ragnarok-clanker
This commit is contained in:
ragnarok-clanker 2026-10-27 21:06:22 +00:00
commit 32f5266595
2 changed files with 12 additions and 0 deletions

View file

@ -1,5 +1,7 @@
#include "UI/Window/UIControl.h"
#include <windows.h>
// INLINED
CUIControl::CUIControl(UIWindowContext& context) : UIWindow(context, 0), hitEnabled(1) {
}
@ -101,6 +103,14 @@ void CUIControl::Slot35(int value) {
}
}
// OFFSET: 0x009EF5F0
// FUNCTION: fn_14637
bool CUIControl::IsPointInside(int x, int y) {
RECT rect = {this->geometry.x, this->geometry.y, this->geometry.x + this->geometry.width, this->geometry.y + this->geometry.height};
POINT point = {x, y};
return PtInRect(&rect, point) != FALSE;
}
// OFFSET: 0x009EF5E0
// FUNCTION: fn_14636
void CUIControl::Invalidate() {

View file

@ -23,6 +23,8 @@ public:
void Slot52(int value) override;
virtual void Slot53(int value);
bool IsPointInside(int x, int y);
/* 007C */ unsigned char hitEnabled;
};