//
// sub_1800027C0 from 0x1800027c0 to 0x180002884 (196 bytes)
//
// 2 xrefs:
// > ??> @ 0x180025918
// > ??> @ 0x18004b150
//
// 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:15:34 +0000
//
// Hidden C++ exception states: #wind=1
struct cocos2d::CCObject *__fastcall sub_1800027C0(struct cocos2d::CCObject *Block, __int64 a2)
{
char v2; // bp
__int64 v4; // rax
cocos2d::CCScheduler *v5; // rax
void **v6; // rsi
_QWORD **v7; // rcx
_QWORD *v8; // rcx
_QWORD *v9; // rbx
v2 = a2;
*(_QWORD *)Block = &cocos2d::extension::AssetsManager::Helper::`vftable';
v4 = cocos2d::CCDirector::sharedDirector(Block, a2);
v5 = (cocos2d::CCScheduler *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v4 + 112LL))(v4);
cocos2d::CCScheduler::unscheduleAllForTarget(v5, Block);
v6 = *((void ***)Block + 7);
if ( v6 )
{
v7 = (_QWORD **)*v6;
**((_QWORD **)*v6 + 1) = 0;
v8 = *v7;
if ( v8 )
{
do
{
v9 = (_QWORD *)*v8;
j_j_free(v8);
v8 = v9;
}
while ( v9 );
}
j_j_free(*v6);
j_j_free(v6);
}
cocos2d::CCObject::~CCObject(Block);
if ( (v2 & 1) != 0 )
j_j_free(Block);
return Block;
}