//
// GameLevelManager::onDeleteLevelControlsCompleted from 0x4c669c to 0x4c6790 (244 bytes)
//
// 1 xrefs:
// > GameLevelManager::handleIt @ 0x4daa9a
//
// 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 11:50:31 +0000
//
int __fastcall GameLevelManager::onDeleteLevelControlsCompleted(int a1, unsigned __int8 *a2, unsigned __int8 *a3)
{
const char *v6; // r0
const char *v7; // r9
_BOOL4 v8; // r5
int v9; // r0
void (*v10)(void); // r3
void (***v11)(void); // r0
int v13; // [sp+0h] [bp-2Ch] BYREF
int v14; // [sp+4h] [bp-28h]
int v15; // [sp+8h] [bp-24h]
int v16[3]; // [sp+Ch] [bp-20h] BYREF
int v17[3]; // [sp+18h] [bp-14h] BYREF
cocos2d::CCDictionary::removeObjectForKey(*(cocos2d::CCDictionary **)(a1 + 748));
v13 = 0;
v14 = 0;
v15 = 0;
sub_4C62E0(a3, "_", &v13);
if ( (unsigned int)(-1431655765 * ((v14 - v13) >> 2)) <= 1 )
{
v7 = nullptr;
}
else
{
if ( (*(_BYTE *)(v13 + 12) & 1) != 0 )
v6 = *(const char **)(v13 + 20);
else
v6 = (const char *)(v13 + 13);
v7 = (const char *)atoi(v6);
}
memset(v16, 0, sizeof(v16));
std::string::__init(v16, "-1", 2u);
v8 = sub_4A9CC4(a2, (unsigned __int8 *)v16);
std::string::~string((int)v16);
if ( v8 )
{
v9 = *(_DWORD *)(a1 + 888);
if ( v9 )
{
v10 = *(void (**)(void))(*(_DWORD *)v9 + 4);
LABEL_12:
v10();
}
}
else
{
memset(v17, 0, sizeof(v17));
std::string::__init(v17, &unk_B6B226, 0);
GameLevelManager::setLevelControlsTemplate((GameLevelManager *)a1, v7, (unsigned __int8 *)v17, 0);
std::string::~string((int)v17);
v11 = *(void (****)(void))(a1 + 888);
if ( v11 )
{
v10 = **v11;
goto LABEL_12;
}
}
return std::__vector_base::~__vector_base((int)&v13);
}