//
// GameLevelManager::onReadFriendRequestCompleted from 0x1005235f0 to 0x1005236bb (203 bytes)
//
// 1 xrefs:
// > GameLevelManager::handleIt @ 0x10051bcd1
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
void __fastcall GameLevelManager::onReadFriendRequestCompleted(__int64 a1, double a2, __int64 a3, __int64 a4)
{
const char *v4; // rbx
__int64 v5; // r14
size_t v6; // rax
size_t v7; // r15
char *v8; // r12
size_t v9; // r13
_QWORD __dst[2]; // [rsp+0h] [rbp-40h] BYREF
void *__p; // [rsp+10h] [rbp-30h]
if ( (*(_BYTE *)a4 & 1) != 0 )
v4 = *(const char **)(a4 + 16);
else
v4 = (const char *)(a4 + 1);
v5 = *(_QWORD *)(a1 + 608);
v6 = strlen(v4);
if ( v6 >= 0xFFFFFFFFFFFFFFF8LL )
sub_100006BF0(a2);
v7 = v6;
if ( v6 >= 0x17 )
{
v9 = 26;
if ( (v6 | 7) != 0x17 )
v9 = (v6 | 7) + 1;
v8 = (char *)operator new(v9);
__p = v8;
__dst[0] = v9 + 1;
__dst[1] = v7;
goto LABEL_11;
}
LOBYTE(__dst[0]) = 2 * v6;
v8 = (char *)__dst + 1;
if ( v6 )
LABEL_11:
memmove(v8, v4, v7);
v8[v7] = 0;
cocos2d::CCDictionary::removeObjectForKey_1(v5, (char *)__dst);
if ( (__dst[0] & 1) != 0 )
operator delete(__p);
}