//
// cocos2d::CCTMXLayer::updateTileForGID from 0x804268 to 0x804354 (236 bytes)
//
// 1 xrefs:
// > cocos2d::CCTMXLayer::setTileGID @ 0x804cea
//
// 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:22 +0000
//
_DWORD *__fastcall cocos2d::CCTMXLayer::updateTileForGID(cocos2d::CCTMXLayer *this, int a2, const cocos2d::CCPoint *a3)
{
unsigned int v6; // r7
_DWORD *v7; // r5
unsigned int v8; // r0
int v9; // r3
float v11[4]; // [sp+Ch] [bp-24h] BYREF
float v12[4]; // [sp+1Ch] [bp-14h] BYREF
cocos2d::CCTMXTilesetInfo::rectForGID((cocos2d::CCTMXTilesetInfo *)v11, *((_DWORD *)this + 77));
cocos2d::CCRect::CCRect(
(cocos2d::CCRect *)v12,
v11[0] / *((float *)this + 90),
v11[1] / *((float *)this + 90),
v11[2] / *((float *)this + 90),
v11[3] / *((float *)this + 90));
cocos2d::CCRect::operator=(v11, v12);
v6 = (int)(float)(*(float *)a3 + (float)(*((float *)a3 + 1) * *((float *)this + 72)));
cocos2d::CCRect::CCRect((cocos2d::CCRect *)v12, (const cocos2d::CCRect *)v11);
v7 = (_DWORD *)cocos2d::CCTMXLayer::reusedTileWithRect((int)this, (int)v12);
cocos2d::CCPoint::CCPoint(v12, a3);
cocos2d::CCTMXLayer::setupTileSprite((unsigned __int8 *)this, (int)v7, v12, a2);
v8 = cocos2d::CCTMXLayer::atlasIndexForExistantZ(this, v6);
v9 = *v7;
v7[72] = v8;
(*(void (__fastcall **)(_DWORD *, int))(v9 + 600))(v7, 1);
(*(void (__fastcall **)(_DWORD *))(*v7 + 396))(v7);
*(_DWORD *)(*((_DWORD *)this + 76) + 4 * v6) = a2;
return v7;
}