//
// DrawGridLayer::~DrawGridLayer from 0x787528 to 0x787670 (328 bytes)
//
// 5 xrefs:
// > `non-virtual thunk to'DrawGridLayer::~DrawGridLayer @ 0x787674
// > DrawGridLayer::~DrawGridLayer @ 0x787688
// > ??> @ 0xdb700
// > ??> @ 0xfecf8
// > ??> @ 0x1436218
//
// 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 12:53:25 +0000
//
// Alternative name is '_ZN13DrawGridLayerD2Ev'
void __fastcall DrawGridLayer::~DrawGridLayer(DrawGridLayer *this)
{
cocos2d::CCObject *v2; // x0
cocos2d::CCObject *v3; // x0
cocos2d::CCObject *v4; // x0
cocos2d::CCObject *v5; // x0
void *v6; // x0
void *v7; // x0
void *v8; // x0
_QWORD *v9; // x0
_QWORD *v10; // x20
__int64 v11; // x2
__int64 v12; // x0
_QWORD *v13; // x0
_QWORD *v14; // x20
void *v15; // x0
v2 = *((cocos2d::CCObject **)this + 67);
*(_QWORD *)this = &off_1436210;
*((_QWORD *)this + 40) = off_14366A0;
*((_QWORD *)this + 41) = &off_1436710;
*((_QWORD *)this + 42) = off_1436728;
*((_QWORD *)this + 43) = off_1436748;
*((_QWORD *)this + 44) = off_1436770;
if ( v2 )
cocos2d::CCObject::release(v2);
v3 = *((cocos2d::CCObject **)this + 68);
if ( v3 )
cocos2d::CCObject::release(v3);
v4 = *((cocos2d::CCObject **)this + 69);
if ( v4 )
cocos2d::CCObject::release(v4);
v5 = *((cocos2d::CCObject **)this + 70);
if ( v5 )
cocos2d::CCObject::release(v5);
v6 = *((void **)this + 51);
if ( v6 )
{
operator delete[](v6);
*((_QWORD *)this + 51) = 0;
v7 = *((void **)this + 52);
if ( !v7 )
goto LABEL_12;
goto LABEL_11;
}
v7 = *((void **)this + 52);
if ( v7 )
{
LABEL_11:
operator delete[](v7);
*((_QWORD *)this + 52) = 0;
}
LABEL_12:
v8 = *((void **)this + 53);
if ( v8 )
{
operator delete[](v8);
*((_QWORD *)this + 53) = 0;
}
if ( *((_QWORD *)this + 57) )
{
v9 = *((_QWORD **)this + 56);
if ( v9 )
{
do
{
v10 = (_QWORD *)*v9;
operator delete(v9);
v9 = v10;
}
while ( v10 );
}
v11 = *((_QWORD *)this + 55);
v12 = 0;
*((_QWORD *)this + 56) = 0;
if ( v11 )
{
do
*(_QWORD *)(*((_QWORD *)this + 54) + 8 * v12++) = 0;
while ( v12 != v11 );
}
*((_QWORD *)this + 57) = 0;
}
if ( (*((_BYTE *)this + 504) & 1) != 0 )
operator delete(*((void **)this + 65));
v13 = *((_QWORD **)this + 56);
if ( v13 )
{
do
{
v14 = (_QWORD *)*v13;
operator delete(v13);
v13 = v14;
}
while ( v14 );
}
v15 = *((void **)this + 54);
*((_QWORD *)this + 54) = 0;
if ( v15 )
operator delete(v15);
cocos2d::CCLayer::~CCLayer(this);
}