{"type": "func", "start": 4297423264, "end": 4297423413, "name": "GJRequestCell::markAsRead", "pseudocode": "// \n// GJRequestCell::markAsRead from 0x1002579a0 to 0x100257a35 (149 bytes)\n// \n// 0 xrefs:\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\nvoid __fastcall GJRequestCell::markAsRead(GJRequestCell *a1)\n{\n  __int64 v1; // rax\n  GameLevelManager *v2; // rbx\n  GJAccountManager *v3; // rax\n  GJUserScore *v4; // rax\n  int m_friendReqCount; // edx\n\n  if ( a1->m_score->m_newFriendRequest )\n  {\n    v1 = ((__int64 (__fastcall *)(cocos2d::CCLayer *, __int64))a1->m_mainLayer->getChildByTag)(a1->m_mainLayer, 100);\n    if ( v1 )\n      (*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v1 + 328LL))(v1, 0);\n    a1->m_score->m_newFriendRequest = 0;\n    v2 = GameLevelManager::sharedState();\n    v3 = GJAccountManager::sharedState();\n    v4 = GameLevelManager::userInfoForAccountID(v2, v3->m_accountID - v3->m_unkInt1);\n    if ( v4 )\n    {\n      m_friendReqCount = 1;\n      if ( v4->m_friendReqCount >= 2 )\n        m_friendReqCount = v4->m_friendReqCount;\n      v4->m_friendReqCount = m_friendReqCount - 1;\n    }\n  }\n}", "assembly": "; \n; GJRequestCell::markAsRead from 0x1002579a0 to 0x100257a35 (149 bytes)\n; \n; 0 xrefs:\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\npush    rbp                                                            ; +0x0, 0x1002579a0\nmov     rbp, rsp                                                       ; +0x1, 0x1002579a1\npush    rbx                                                            ; +0x4, 0x1002579a4\npush    rax                                                            ; +0x5, 0x1002579a5\nmov     rax, [rdi+240h]                                                ; +0x6, 0x1002579a6\ncmp     byte ptr [rax+2B0h], 1                                         ; +0xd, 0x1002579ad\njnz     short loc_100257A2E                                            ; +0x14, 0x1002579b4\nmov     rbx, rdi                                                       ; +0x16, 0x1002579b6\nmov     rdi, [rdi+218h]                                                ; +0x19, 0x1002579b9\nmov     rax, [rdi]                                                     ; +0x20, 0x1002579c0\nmov     esi, 64h ; 'd'                                                 ; +0x23, 0x1002579c3\ncall    qword ptr [rax+1D0h]                                           ; +0x28, 0x1002579c8\ntest    rax, rax                                                       ; +0x2e, 0x1002579ce\njz      short loc_1002579E1                                            ; +0x31, 0x1002579d1\nmov     rcx, [rax]                                                     ; +0x33, 0x1002579d3\nmov     rdi, rax                                                       ; +0x36, 0x1002579d6\nxor     esi, esi                                                       ; +0x39, 0x1002579d9\ncall    qword ptr [rcx+148h]                                           ; +0x3b, 0x1002579db\nmov     rax, [rbx+240h]                                                ; +0x41, 0x1002579e1\nmov     byte ptr [rax+2B0h], 0                                         ; +0x48, 0x1002579e8\ncall    GameLevelManager__sharedState                                  ; +0x4f, 0x1002579ef\nmov     rbx, rax                                                       ; +0x54, 0x1002579f4\ncall    GJAccountManager__sharedState                                  ; +0x57, 0x1002579f7\nmov     esi, [rax+160h]                                                ; +0x5c, 0x1002579fc\nsub     esi, [rax+164h]                                                ; +0x62, 0x100257a02\nmov     rdi, rbx                                                       ; +0x68, 0x100257a08\ncall    GameLevelManager__userInfoForAccountID                         ; +0x6b, 0x100257a0b\ntest    rax, rax                                                       ; +0x70, 0x100257a10\njz      short loc_100257A2E                                            ; +0x73, 0x100257a13\nmov     ecx, [rax+2A8h]                                                ; +0x75, 0x100257a15\ncmp     ecx, 2                                                         ; +0x7b, 0x100257a1b\nmov     edx, 1                                                         ; +0x7e, 0x100257a1e\ncmovge  edx, ecx                                                       ; +0x83, 0x100257a23\ndec     edx                                                            ; +0x86, 0x100257a26\nmov     [rax+2A8h], edx                                                ; +0x88, 0x100257a28\nadd     rsp, 8                                                         ; +0x8e, 0x100257a2e\npop     rbx                                                            ; +0x92, 0x100257a32\npop     rbp                                                            ; +0x93, 0x100257a33\nretn                                                                   ; +0x94, 0x100257a34", "xrefs": [], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}