//
// cocos2d::CCLayerRGBA::setOpacity from 0x1001c7d84 to 0x1001c7e18 (148 bytes)
//
// 12 xrefs:
// > sub_1001C7E18 @ 0x1001c7e1c
// > cocos2d::CCLayerColor::setOpacity @ 0x1001c86d4
// > sub_1001C86F0 @ 0x1001c8704
// > ??> @ 0x1008e44e8
// > ??> @ 0x1008ecb08
// > ??> @ 0x100905628
// > ??> @ 0x100906a70
// > ??> @ 0x100907938
// > ??> @ 0x10090dc30
// > ??> @ 0x100917b90
// > ??> @ 0x10093e8f8
// > ??> @ 0x10093f930
//
// This function is hookable on this platform (idp: arm, 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 11:00:18 +0000
//
__int64 __fastcall cocos2d::CCLayerRGBA::setOpacity(__int64 result, char a2)
{
__int64 v2; // x19
const void *v3; // x0
void *v4; // x0
void *v5; // x20
__int64 v6; // x1
*(_BYTE *)(result + 417) = a2;
*(_BYTE *)(result + 416) = a2;
if ( *(_BYTE *)(result + 424) == 1 )
{
v2 = result;
v3 = *(const void **)(result + 216);
if ( v3
&& (v4 = __dynamic_cast(
v3,
(const struct __class_type_info *)&`typeinfo for'cocos2d::CCNode,
(const struct __class_type_info *)&off_1008BD768,
-2)) != nullptr
&& (v5 = v4, (*(unsigned int (__fastcall **)(void *))(*(_QWORD *)v4 + 88LL))(v4)) )
{
v6 = (*(__int64 (__fastcall **)(void *))(*(_QWORD *)v5 + 24LL))(v5);
}
else
{
v6 = 255;
}
return (*(__int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v2 + 1176LL))(v2, v6);
}
return result;
}