//
// cocos2d::CCCardinalSplineTo::copyWithZone from 0x1002be870 to 0x1002be95b (235 bytes)
//
// 4 xrefs:
// > ??> @ 0x100b0efa8
// > ??> @ 0x100b0f038
// > ??> @ 0x100b0f110
// > ??> @ 0x100b0f1b8
//
// 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:04 +0000
//
_DWORD *__fastcall cocos2d::CCCardinalSplineTo::copyWithZone(__int64 a1, void **a2)
{
_DWORD *v2; // rbx
void **v3; // r15
__int64 v4; // r12
__int64 v5; // rdi
int v7; // [rsp+Ch] [rbp-24h]
if ( a2 && (v2 = *a2) != nullptr )
{
v3 = nullptr;
}
else
{
v2 = operator new(0x80u);
cocos2d::CCAction::CCAction(v2);
v2[20] = 0;
*(_QWORD *)v2 = off_100B0EFA8;
*((_OWORD *)v2 + 6) = 0;
sub_1002782A0((_QWORD *)v2 + 14);
sub_1002782A0((_QWORD *)v2 + 15);
v3 = (void **)operator new(8u);
cocos2d::CCZone::CCZone(v3, (__int64)v2);
a2 = v3;
}
cocos2d::CCActionInterval::copyWithZone(a1, a2);
v4 = *(_QWORD *)(a1 + 96);
v7 = *(_DWORD *)(a1 + 108);
if ( (unsigned __int8)cocos2d::CCActionInterval::initWithDuration(v2, *(float *)(a1 + 80)) )
{
cocos2d::CCObject::retain(v4);
v5 = *((_QWORD *)v2 + 12);
if ( v5 )
cocos2d::CCObject::release(v5);
*((_QWORD *)v2 + 12) = v4;
v2[27] = v7;
}
if ( v3 )
operator delete(v3);
return v2;
}