{"type": "func", "start": 5371749024, "end": 5371749257, "name": "GameStatsManager::hasCompletedChallenge", "pseudocode": "// \n// GameStatsManager::hasCompletedChallenge from 0x1402e62a0 to 0x1402e6389 (233 bytes)\n// \n// 4 xrefs:\n// > ChallengesPage::claimItem @ 0x14009f17f\n// > GameLevelManager::onGetGJChallengesCompleted @ 0x14025f2d2\n// > GameStatsManager::dataLoaded @ 0x1402f7e36\n// > <???> @ 0x14091dff0\n// \n// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:29:50 +0000\n// \n\n// Hidden C++ exception states: #wind=1\n_BOOL8 __fastcall GameStatsManager::hasCompletedChallenge(__int64 a1, __int64 a2)\n{\n  cocos2d::CCString *v3; // rax\n  const char *CString; // rax\n  size_t v5; // r8\n  bool v6; // bl\n  void *v7; // rcx\n  void *Block[2]; // [rsp+38h] [rbp-30h] BYREF\n  __int128 v10; // [rsp+48h] [rbp-20h]\n\n  v3 = cocos2d::CCString::createWithFormat(\"c%i%i\", *(_DWORD *)(a2 + 104), *(_DWORD *)(a2 + 96));\n  CString = cocos2d::CCString::getCString(v3);\n  *(_OWORD *)Block = 0;\n  v10 = 0;\n  v5 = -1;\n  do\n    ++v5;\n  while ( CString[v5] );\n  sub_14003D230(Block, CString, v5);\n  v6 = cocos2d::CCDictionary::objectForKey(*(_QWORD *)(a1 + 816), Block) != 0;\n  if ( *((_QWORD *)&v10 + 1) > 0xFu )\n  {\n    v7 = Block[0];\n    if ( (unsigned __int64)(*((_QWORD *)&v10 + 1) + 1LL) >= 0x1000 )\n    {\n      v7 = *((void **)Block[0] - 1);\n      if ( (unsigned __int64)((char *)Block[0] - (char *)v7 - 8) > 0x1F )\n        invoke_watson(nullptr, nullptr, nullptr, 0, 0);\n    }\n    j_j_free(v7);\n  }\n  return v6;\n}", "assembly": "; \n; GameStatsManager::hasCompletedChallenge from 0x1402e62a0 to 0x1402e6389 (233 bytes)\n; \n; 4 xrefs:\n; > ChallengesPage::claimItem @ 0x14009f17f\n; > GameLevelManager::onGetGJChallengesCompleted @ 0x14025f2d2\n; > GameStatsManager::dataLoaded @ 0x1402f7e36\n; > <???> @ 0x14091dff0\n; \n; This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:29:50 +0000\n; \npush    rbx                                                            ; +0x0, 0x1402e62a0\nsub     rsp, 60h                                                       ; +0x2, 0x1402e62a2\nmov     rax, cs:__security_cookie                                      ; +0x6, 0x1402e62a6\nxor     rax, rsp                                                       ; +0xd, 0x1402e62ad\nmov     [rsp+68h+var_10], rax                                          ; +0x10, 0x1402e62b0\nmov     rbx, rcx                                                       ; +0x15, 0x1402e62b5\nmov     r8d, [rdx+60h]                                                 ; +0x18, 0x1402e62b8\nmov     edx, [rdx+68h]                                                 ; +0x1c, 0x1402e62bc\nlea     rcx, aCII; \"c%i%i\"                                             ; +0x1f, 0x1402e62bf\ncall    cs:?createWithFormat@CCString@cocos2d@@SAPEAV12@PEBDZZ; cocos2d::CCString::createWithFormat(char const *,...) ; +0x26, 0x1402e62c6\nmov     rcx, rax                                                       ; +0x2c, 0x1402e62cc\ncall    cs:?getCString@CCString@cocos2d@@QEBAPEBDXZ; cocos2d::CCString::getCString(void) ; +0x2f, 0x1402e62cf\nxorps   xmm0, xmm0                                                     ; +0x35, 0x1402e62d5\nmovups  xmmword ptr [rsp+68h+Block], xmm0                              ; +0x38, 0x1402e62d8\nxorps   xmm1, xmm1                                                     ; +0x3d, 0x1402e62dd\nmovdqu  [rsp+68h+var_20], xmm1                                         ; +0x40, 0x1402e62e0\nmov     r8, 0FFFFFFFFFFFFFFFFh                                         ; +0x46, 0x1402e62e6\nnop     dword ptr [rax]                                                ; +0x4d, 0x1402e62ed\ninc     r8                                                             ; +0x50, 0x1402e62f0\ncmp     byte ptr [rax+r8], 0                                           ; +0x53, 0x1402e62f3\njnz     short loc_1402E62F0                                            ; +0x58, 0x1402e62f8\nmov     rdx, rax                                                       ; +0x5a, 0x1402e62fa\nlea     rcx, [rsp+68h+Block]                                           ; +0x5d, 0x1402e62fd\ncall    sub_14003D230                                                  ; +0x62, 0x1402e6302\nnop                                                                    ; +0x67, 0x1402e6307\nlea     rdx, [rsp+68h+Block]                                           ; +0x68, 0x1402e6308\nmov     rcx, [rbx+330h]                                                ; +0x6d, 0x1402e630d\ncall    cs:?objectForKey@CCDictionary@cocos2d@@QEAAPEAVCCObject@2@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z; cocos2d::CCDictionary::objectForKey(std::string const &) ; +0x74, 0x1402e6314\ntest    rax, rax                                                       ; +0x7a, 0x1402e631a\nsetnz   bl                                                             ; +0x7d, 0x1402e631d\nmov     rdx, qword ptr [rsp+68h+var_20+8]                              ; +0x80, 0x1402e6320\ncmp     rdx, 0Fh                                                       ; +0x85, 0x1402e6325\njbe     short loc_1402E6373                                            ; +0x89, 0x1402e6329\ninc     rdx                                                            ; +0x8b, 0x1402e632b\nmov     rcx, [rsp+68h+Block]; Block                                    ; +0x8e, 0x1402e632e\nmov     rax, rcx                                                       ; +0x93, 0x1402e6333\ncmp     rdx, 1000h                                                     ; +0x96, 0x1402e6336\njb      short loc_1402E636E                                            ; +0x9d, 0x1402e633d\nadd     rdx, 27h ; '''                                                 ; +0x9f, 0x1402e633f\nmov     rcx, [rcx-8]                                                   ; +0xa3, 0x1402e6343\nsub     rax, rcx                                                       ; +0xa7, 0x1402e6347\nsub     rax, 8                                                         ; +0xaa, 0x1402e634a\ncmp     rax, 1Fh                                                       ; +0xae, 0x1402e634e\njbe     short loc_1402E636E                                            ; +0xb2, 0x1402e6352\nmov     [rsp+68h+Reserved], 0; Reserved                                ; +0xb4, 0x1402e6354\nxor     r9d, r9d; LineNo                                               ; +0xbd, 0x1402e635d\nxor     r8d, r8d; FileName                                             ; +0xc0, 0x1402e6360\nxor     edx, edx; FunctionName                                         ; +0xc3, 0x1402e6363\nxor     ecx, ecx; Expression                                           ; +0xc5, 0x1402e6365\ncall    cs:_invoke_watson                                              ; +0xc7, 0x1402e6367\nalign 2                                                                ; +0xcd, 0x1402e636d\ncall    j_j_free                                                       ; +0xce, 0x1402e636e\nmovzx   eax, bl                                                        ; +0xd3, 0x1402e6373\nmov     rcx, [rsp+68h+var_10]                                          ; +0xd6, 0x1402e6376\nxor     rcx, rsp; StackCookie                                          ; +0xdb, 0x1402e637b\ncall    __security_check_cookie                                        ; +0xde, 0x1402e637e\nadd     rsp, 60h                                                       ; +0xe3, 0x1402e6383\npop     rbx                                                            ; +0xe7, 0x1402e6387\nretn                                                                   ; +0xe8, 0x1402e6388", "xrefs": ["ChallengesPage::claimItem @ 0x14009f17f", "GameLevelManager::onGetGJChallengesCompleted @ 0x14025f2d2", "GameStatsManager::dataLoaded @ 0x1402f7e36", "<???> @ 0x14091dff0"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}