//
// GJMessageCell::markAsRead from 0x73a1b0 to 0x73a24c (156 bytes)
//
// 3 xrefs:
// > GJMessageCell::onViewMessage @ 0x73a264
// > GJMessageCell::FLAlert_Clicked @ 0x73ba38
// > ??> @ 0xbace8
//
// 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 12:52:40 +0000
//
__int64 __fastcall GJMessageCell::markAsRead(__int64 this)
{
__int64 v1; // x1
GameLevelManager *v2; // x0
GJAccountManager *v3; // x19
__int64 v4; // x0
int v5; // w1
v1 = *(_QWORD *)(this + 576);
if ( !*(_BYTE *)(v1 + 424) )
{
*(_BYTE *)(v1 + 424) = 1;
v2 = (GameLevelManager *)(*(__int64 (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(this + 536) + 480LL))(
*(_QWORD *)(this + 536),
100);
if ( v2 )
v2 = (GameLevelManager *)(*(__int64 (__fastcall **)(GameLevelManager *, _QWORD))(*(_QWORD *)v2 + 344LL))(v2, 0);
v3 = (GJAccountManager *)GameLevelManager::sharedState(v2);
v4 = GJAccountManager::sharedState(v3);
this = GameLevelManager::userInfoForAccountID(v3, *(_DWORD *)(v4 + 352) - *(_DWORD *)(v4 + 356));
if ( this )
{
v5 = *(_DWORD *)(this + 692) - 1;
if ( v5 < 0 )
v5 = 0;
*(_DWORD *)(this + 692) = v5;
}
}
return this;
}