//
// cocos2d::extension::CCControl::hasVisibleParents from 0x10033de40 to 0x10033de94 (84 bytes)
//
// 2 xrefs:
// > cocos2d::extension::CCControlButton::ccTouchBegan @ 0x100340632
// > sub_1003406B0 @ 0x100340703
//
// 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:28:42 +0000
//
__int64 __fastcall cocos2d::extension::CCControl::hasVisibleParents(__int64 a1)
{
unsigned int v1; // r14d
__int64 v2; // rax
__int64 v3; // rbx
v2 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a1 + 512LL))(a1);
if ( v2 )
{
v3 = v2;
do
{
v1 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v3 + 352LL))(v3);
if ( !(_BYTE)v1 )
break;
v3 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v3 + 512LL))(v3);
}
while ( v3 );
}
else
{
LOBYTE(v1) = 1;
}
return v1;
}