//
// cocos2d::CCShatteredTiles3D::update from 0xd3a23c to 0xd3a530 (756 bytes)
//
// 2 xrefs:
// > ??> @ 0xbdec8
// > ??> @ 0x1514ca8
//
// 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 13:07:25 +0000
//
__int64 __fastcall cocos2d::CCShatteredTiles3D::update(cocos2d::CCShatteredTiles3D *this, float a2)
{
float v3; // s1
float v4; // s8
int v5; // w23
float v6; // s0
int v7; // w22
float v8; // s9
int v9; // w0
int v10; // w4
_BYTE v12[8]; // [xsp+50h] [xbp+50h] BYREF
float v13; // [xsp+58h] [xbp+58h] BYREF
float v14; // [xsp+5Ch] [xbp+5Ch]
float v15; // [xsp+60h] [xbp+60h]
float v16; // [xsp+64h] [xbp+64h]
float v17; // [xsp+68h] [xbp+68h]
float v18; // [xsp+6Ch] [xbp+6Ch]
float v19; // [xsp+70h] [xbp+70h]
float v20; // [xsp+74h] [xbp+74h]
float v21; // [xsp+78h] [xbp+78h]
float v22; // [xsp+7Ch] [xbp+7Ch]
float v23; // [xsp+80h] [xbp+80h]
float v24; // [xsp+84h] [xbp+84h]
if ( !*((_BYTE *)this + 104) )
{
v3 = *((float *)this + 23);
if ( v3 > 0.0 )
{
v4 = 0.0;
v5 = 0;
v6 = *((float *)this + 24);
do
{
v7 = 0;
v8 = 0.0;
if ( v6 > 0.0 )
{
do
{
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v12, v4, v8);
cocos2d::CCTiledGrid3DAction::originalTile(this, (const cocos2d::CCPoint *)v12, (__int64)&v13);
v13 = v13 + (float)(rand() % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
v16 = v16 + (float)(rand() % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
v19 = v19 + (float)(rand() % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
v22 = v22 + (float)(rand() % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
v14 = v14 + (float)(rand() % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
v17 = v17 + (float)(rand() % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
v20 = v20 + (float)(rand() % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
v9 = rand();
v10 = *((unsigned __int8 *)this + 105);
v23 = v23 + (float)(v9 % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
if ( v10 )
{
v15 = v15 + (float)(rand() % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
v18 = v18 + (float)(rand() % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
v21 = v21 + (float)(rand() % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
v24 = v24 + (float)(rand() % (2 * *((_DWORD *)this + 25)) - *((_DWORD *)this + 25));
}
++v7;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v12, v4, v8);
cocos2d::CCTiledGrid3DAction::setTile((__int64)this, (__int64)v12, (__int64)&v13);
v8 = (float)v7;
v6 = *((float *)this + 24);
}
while ( (float)v7 < v6 );
v3 = *((float *)this + 23);
}
v4 = (float)++v5;
}
while ( (float)v5 < v3 );
}
*((_BYTE *)this + 104) = 1;
}
return _stack_chk_guard;
}