//
// cocos2d::CCAnimation::create from 0x100281170 to 0x100281266 (246 bytes)
//
// 2 xrefs:
// > cocos2d::CCAnimate::reverse @ 0x1003a5f59
// > cocos2d::CCAnimationCache::parseVersion1 @ 0x100461aed
//
// 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:27:43 +0000
//
_DWORD *__fastcall cocos2d::CCAnimation::create(__int64 a1, int a2, float a3)
{
_DWORD *v3; // rbx
__int64 v4; // rax
__int64 v5; // rdi
__int64 v6; // r14
unsigned int *v7; // rax
__int64 v8; // rcx
unsigned __int64 v9; // rax
unsigned __int64 v10; // rcx
v3 = operator new(0x58u);
cocos2d::CCObject::CCObject(v3);
*(_QWORD *)v3 = off_100AFE1F8;
v3[14] = 0;
v3[16] = 0;
*((_QWORD *)v3 + 9) = 0;
*((_BYTE *)v3 + 80) = 0;
*((float *)v3 + 15) = a3;
v3[21] = a2;
v4 = sub_1007FEC00(a1);
v5 = *((_QWORD *)v3 + 9);
if ( v5 == v4 )
{
v6 = *((_QWORD *)v3 + 9);
if ( !v5 )
goto LABEL_13;
goto LABEL_9;
}
v6 = v4;
if ( v4 )
{
cocos2d::CCObject::retain(v4);
v5 = *((_QWORD *)v3 + 9);
}
if ( v5 )
cocos2d::CCObject::release(v5);
*((_QWORD *)v3 + 9) = v6;
if ( v6 )
{
LABEL_9:
v7 = *(unsigned int **)(v6 + 56);
v8 = *v7;
if ( *v7 )
{
v9 = *((_QWORD *)v7 + 2);
v10 = v9 + 8 * v8 - 8;
do
{
if ( !*(_QWORD *)v9 )
break;
*((float *)v3 + 14) = *(float *)(*(_QWORD *)v9 + 64LL) + *((float *)v3 + 14);
v9 += 8LL;
}
while ( v9 <= v10 );
}
}
LABEL_13:
cocos2d::CCObject::autorelease(v3);
return v3;
}