//
// cocos2d::extension::CCControlPotentiometer::isTouchInside from 0x180008cf0 to 0x180008de3 (243 bytes)
//
// 3 xrefs:
// > ??> @ 0x180027910
// > ??> @ 0x180032408
// > ??> @ 0x18004b8dc
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 12:15:37 +0000
//
bool __fastcall cocos2d::extension::CCControlPotentiometer::isTouchInside(
cocos2d::extension::CCControlPotentiometer *this,
struct cocos2d::CCTouch *a2)
{
float *v3; // rbx
const struct cocos2d::CCPoint *v4; // rax
float *v5; // rax
float v6; // xmm6_4
float v7; // xmm7_4
float v8; // xmm8_4
float v9; // xmm7_4
float v10; // xmm6_4
char v12; // [rsp+60h] [rbp+8h] BYREF
char v13; // [rsp+70h] [rbp+18h] BYREF
char v14; // [rsp+78h] [rbp+20h] BYREF
(*(void (__fastcall **)(cocos2d::extension::CCControlPotentiometer *, char *, struct cocos2d::CCTouch *))(*(_QWORD *)this + 1112LL))(
this,
&v12,
a2);
v3 = (float *)cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v13, (const struct cocos2d::CCPoint *)&v12);
v4 = (const struct cocos2d::CCPoint *)(*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 60) + 200LL))(*((_QWORD *)this + 60));
v5 = (float *)cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v14, v4);
v6 = *v5 - *v3;
v7 = v5[1] - v3[1];
v8 = *(float *)(*(__int64 (__fastcall **)(cocos2d::extension::CCControlPotentiometer *))(*(_QWORD *)this + 320LL))(this)
* 0.5;
v9 = (float)(v7 * v7) + (float)(v6 * v6);
if ( v9 < 0.0 )
v10 = sqrtf(v9);
else
v10 = fsqrt(v9);
return fminf(
v8,
*(float *)((*(__int64 (__fastcall **)(cocos2d::extension::CCControlPotentiometer *))(*(_QWORD *)this + 320LL))(this)
+ 4)
* 0.5) > v10;
}