//
// GJRequestCell::onViewFriendRequest from 0x100139fac to 0x10013a030 (132 bytes)
//
// 1 xrefs:
// > GJRequestCell::loadFromScore @ 0x10012f198
//
// 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 10:59:28 +0000
//
__int64 __fastcall GJRequestCell::onViewFriendRequest(__int64 result)
{
__int64 v1; // x8
__int64 v2; // x19
__int64 v3; // x0
__int64 v4; // x20
char v5; // w8
__int64 v6; // x0
v1 = *(_QWORD *)(result + 552);
if ( v1 )
{
if ( *(int *)(v1 + 376) >= 1 )
{
v2 = result;
v3 = GameLevelManager::sharedState();
result = GameLevelManager::friendRequestFromAccountID(v3, *(_DWORD *)(*(_QWORD *)(v2 + 552) + 376LL));
if ( result )
{
v4 = result;
if ( (*(_BYTE *)(v2 + 568) & 1) != 0 )
{
v5 = 1;
}
else
{
GJRequestCell::markAsRead(v2);
v5 = *(_BYTE *)(v2 + 568);
}
v6 = FriendRequestPopup::create(v4, v5 & 1);
return (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v6 + 1312LL))(v6);
}
}
}
return result;
}