//
// MessageThreadsPage::friendPicked from 0xc688b8 to 0xc68a74 (444 bytes)
//
// 3 xrefs:
// > `non-virtual thunk to'MessageThreadsPage::friendPicked @ 0xc68a7c
// > ??> @ 0xc6940
// > ??> @ 0x14ec1c8
//
// 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 13:05:26 +0000
//
__int64 __fastcall MessageThreadsPage::friendPicked(MessageThreadsPage *this, GJUserScore *a2)
{
cocos2d::CCArray *v4; // x0
signed int i; // w19
bool v6; // zf
bool v7; // cc
cocos2d::CCArray *v8; // x0
cocos2d::CCDirector *v9; // x0
__int64 *v10; // x19
__int64 v11; // x3
void (__fastcall *v12)(__int64 *, __int64, __int64); // x23
__int64 v13; // x0
__int64 v15[2]; // [xsp+48h] [xbp+48h] BYREF
void *v16; // [xsp+58h] [xbp+58h]
__int64 v17[2]; // [xsp+60h] [xbp+60h] BYREF
void *v18; // [xsp+70h] [xbp+70h]
if ( a2 )
{
if ( *((int *)a2 + 94) > 0 )
{
v4 = *((cocos2d::CCArray **)this + 110);
if ( v4 )
{
for ( i = 0; ; ++i )
{
v7 = i < (int)cocos2d::CCArray::count(v4);
v8 = *((cocos2d::CCArray **)this + 110);
if ( !v7 )
break;
v6 = *(_DWORD *)(cocos2d::CCArray::objectAtIndex(v8, i) + 376) == *((_DWORD *)a2 + 94);
v4 = *((cocos2d::CCArray **)this + 110);
if ( v6 )
{
cocos2d::CCArray::removeObjectAtIndex(v4, i, 1);
MessageThreadsPage::refreshUserFilterBtn(this);
return _stack_chk_guard;
}
}
v9 = (cocos2d::CCDirector *)cocos2d::CCArray::count(v8);
if ( (unsigned int)v9 <= 9 )
{
cocos2d::CCArray::addObject(*((cocos2d::CCArray **)this + 110), a2);
MessageThreadsPage::refreshUserFilterBtn(this);
}
else
{
v10 = *(__int64 **)(cocos2d::CCDirector::sharedDirector(v9) + 272);
v11 = *v10;
v15[0] = 0;
v15[1] = 0;
v12 = *(void (__fastcall **)(__int64 *, __int64, __int64))(v11 + 464);
v16 = nullptr;
std::string::__init(v15, "Filter limit reached", 0x14u);
v17[0] = 0;
v17[1] = 0;
v18 = nullptr;
std::string::__init(v17, &byte_11B8890, 0);
v13 = TextAlertPopup::create((char *)v15, 150, (char *)v17, 0.5, 0.6);
v12(v10, v13, 1000);
if ( (v17[0] & 1) != 0 )
operator delete(v18);
if ( (v15[0] & 1) != 0 )
operator delete(v16);
}
}
}
}
return _stack_chk_guard;
}