//
// cocos2d::CCTextureAtlas::insertQuads from 0x8002c4 to 0x80032a (102 bytes)
//
// 0 xrefs:
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:01:19 +0000
//
_DWORD *__fastcall cocos2d::CCTextureAtlas::insertQuads(_DWORD *result, int a2, unsigned int a3, int a4)
{
unsigned int v6; // r1
_DWORD *v7; // r5
unsigned int v8; // r2
unsigned int v9; // r6
int v10; // r2
int v11; // r7
int v12; // r8
const void *v13; // r1
void *v14; // r0
v6 = result[21];
v7 = result;
v8 = result[17] + a4;
result[17] = v8;
v9 = a4 + a3;
if ( v6 < v8 )
result[21] = v8;
else
result[21] = v6;
v10 = v8 + ~a3 - a4;
if ( v10 > 0 )
result = memmove((void *)(result[20] + 96 * v9), (const void *)(result[20] + 96 * a3), 96 * v10);
v11 = 96 * a3;
v12 = a2 - 96 * a3;
while ( a3 < v9 )
{
v13 = (const void *)(v12 + v11);
++a3;
v14 = (void *)(v7[20] + v11);
v11 += 96;
result = memcpy(v14, v13, 0x60u);
}
*((_BYTE *)v7 + 64) = 1;
return result;
}