//
// GameLevelManager::onBlockUserCompleted from 0x4c28c0 to 0x4c29e6 (294 bytes)
//
// 1 xrefs:
// > GameLevelManager::handleIt @ 0x4dac1a
//
// 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:25 +0000
//
int __fastcall GameLevelManager::onBlockUserCompleted(GameLevelManager *a1, unsigned __int8 *a2, char *a3)
{
cocos2d::CCDictionary *v5; // r9
char v6; // r1
const char *v7; // r5
size_t v8; // r0
int SplitIntFromKey; // r0
const char *v10; // r5
_BOOL4 v11; // r8
int result; // r0
int v13; // r0
int v14; // r1
int v15; // r0
void (__fastcall ***v16)(_DWORD, const char *, int); // r0
int v17; // r2
int v18; // r3
int v19; // r3
int v20; // r2
int v21; // r3
int v22; // r2
int v23; // r3
int v24; // [sp+0h] [bp-14h] BYREF
int v25; // [sp+4h] [bp-10h]
int v26; // [sp+8h] [bp-Ch]
v5 = *((cocos2d::CCDictionary **)a1 + 187);
v24 = 0;
v6 = *a3;
v25 = 0;
v26 = 0;
if ( (v6 & 1) != 0 )
v7 = *((const char **)a3 + 2);
else
v7 = a3 + 1;
v8 = strlen(v7);
std::string::__init(&v24, v7, v8);
cocos2d::CCDictionary::removeObjectForKey(v5);
std::string::~string((int)&v24);
SplitIntFromKey = GameLevelManager::getSplitIntFromKey(a1, v7, 1u);
v24 = 0;
v25 = 0;
v26 = 0;
v10 = (const char *)SplitIntFromKey;
std::string::__init(&v24, "-1", 2u);
v11 = sub_4A9CC4(a2, (unsigned __int8 *)&v24);
std::string::~string((int)&v24);
if ( v11 )
{
result = *((_DWORD *)a1 + 222);
if ( result )
return (*(int (__fastcall **)(int, const char *, int))(*(_DWORD *)result + 4))(result, v10, 40);
}
else
{
v13 = GameLevelManager::userInfoForAccountID((cocos2d::CCDictionary **)a1, (int)v10);
v14 = v13;
if ( v13 )
{
*(_BYTE *)(v13 + 554) = 0;
*(_DWORD *)(v13 + 520) = 2;
v15 = *((_DWORD *)a1 + 221);
if ( v15 )
(*(void (__fastcall **)(int, int))(*(_DWORD *)v15 + 8))(v15, v14);
}
v16 = *((void (__fastcall ****)(_DWORD, const char *, int))a1 + 222);
if ( v16 )
(**v16)(v16, v10, 40);
GameLevelManager::friendRequestWasRemoved((cocos2d::CCDictionary **)a1, (int)v10, nullptr);
GameLevelManager::resetStoredUserList((int)a1, 1, v17, v18);
GameLevelManager::invalidateMessages((cocos2d::CCDictionary **)a1, nullptr, 1);
GameLevelManager::removeUserFromList((int)a1, (int)v10, 0, v19);
GameLevelManager::unfollowUser(a1, v10);
GameLevelManager::resetStoredUserList((int)a1, 3, v20, v21);
return GameLevelManager::resetStoredUserList((int)a1, 4, v22, v23);
}
return result;
}