//
// MessagesProfilePage::loadMessagesFinished from 0x5efe38 to 0x5efeea (178 bytes)
//
// 1 xrefs:
// > `non-virtual thunk to'MessagesProfilePage::loadMessagesFinished @ 0x5efeee
//
// 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:54:27 +0000
//
int __fastcall MessagesProfilePage::loadMessagesFinished(MessagesProfilePage *this, int **a2, const char *a3)
{
int result; // r0
int v6; // r4
GameLevelManager *v7; // r0
int *v8; // r2
int v9; // r3
int *v10; // r2
int *v11; // r3
int v12; // r1
int v13; // t1
GJAccountManager *v14; // r6
int v15; // r0
int v16; // r0
result = MessagesProfilePage::isCorrect(this, a3);
if ( result )
{
MessagesProfilePage::setupCommentsBrowser(this, (cocos2d::CCArray *)a2);
(*(void (__fastcall **)(_DWORD, _DWORD))(**((_DWORD **)this + 141) + 172))(*((_DWORD *)this + 141), 0);
(*(void (__fastcall **)(_DWORD, _DWORD))(**((_DWORD **)this + 139) + 172))(*((_DWORD *)this + 139), 0);
(*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 146) + 172))(*((_DWORD *)this + 146), 1);
v6 = *((unsigned __int8 *)this + 536);
if ( !*((_BYTE *)this + 536) )
{
if ( a2 )
{
v7 = (GameLevelManager *)cocos2d::CCArray::count((cocos2d::CCArray *)a2);
if ( v7 )
{
v8 = a2[13];
v9 = *v8;
if ( *v8 )
{
v10 = (int *)v8[3];
v11 = &v10[v9 - 1];
while ( v10 <= v11 )
{
v13 = *v10++;
v12 = v13;
if ( !v13 )
break;
if ( !*(_BYTE *)(v12 + 324) )
++v6;
}
}
else
{
v6 = 0;
}
v14 = (GJAccountManager *)GameLevelManager::sharedState(v7);
v15 = GJAccountManager::sharedState(v14);
v16 = GameLevelManager::userInfoForAccountID(
(cocos2d::CCDictionary **)v14,
*(_DWORD *)(v15 + 280) - *(_DWORD *)(v15 + 284));
if ( v16 )
{
if ( *(_DWORD *)(v16 + 524) < v6 )
*(_DWORD *)(v16 + 524) = v6;
}
}
}
}
return MessagesProfilePage::updateSelectUI(this);
}
return result;
}