{"type": "func", "start": 5370170896, "end": 5370171115, "name": "GameLevelManager::hasLikedAccountItem", "pseudocode": "// \n// GameLevelManager::hasLikedAccountItem from 0x140164e10 to 0x140164eeb (219 bytes)\n// \n// 9 xrefs:\n// > GameLevelManager::hasLikedItemFullCheck @ 0x140164dab\n// > GameLevelManager::hasLikedItemFullCheck @ 0x140164dc3\n// > GameLevelManager::hasLikedItemFullCheck @ 0x140164dcf\n// > GameLevelManager::hasLikedItemFullCheck @ 0x140164de9\n// > LevelInfoLayer::updateSideButtons @ 0x1402fea76\n// > LevelInfoLayer::updateSideButtons @ 0x1402fea94\n// > LevelListLayer::updateSideButtons @ 0x140307c2e\n// > LevelListLayer::updateSideButtons @ 0x140307c4c\n// > <???> @ 0x1406cacb0\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\n// Hidden C++ exception states: #wind=1\nbool GameLevelManager::hasLikedAccountItem(GameLevelManager *a1, LikeItemType a2, int a3, bool a4, int a5)\n{\n  cocos2d::CCString *v6; // rax\n  const char *CString; // rax\n  size_t v8; // r8\n  bool v9; // bl\n  void *v10; // rcx\n  void *Block[2]; // [rsp+30h] [rbp-38h] BYREF\n  __int128 v14; // [rsp+40h] [rbp-28h]\n\n  v6 = cocos2d::CCString::createWithFormat(\"like_%i_%i_%i_%i\", a2, a3, a4, a5);\n  CString = cocos2d::CCString::getCString(v6);\n  *(_OWORD *)Block = 0;\n  v14 = 0;\n  v8 = -1;\n  do\n    ++v8;\n  while ( CString[v8] );\n  sub_14003A930(Block, CString, v8);\n  v9 = cocos2d::CCDictionary::objectForKey(a1->m_likedLevels, Block) != 0;\n  if ( *((_QWORD *)&v14 + 1) > 0xFu )\n  {\n    v10 = Block[0];\n    if ( (unsigned __int64)(*((_QWORD *)&v14 + 1) + 1LL) >= 0x1000 )\n    {\n      v10 = *((void **)Block[0] - 1);\n      if ( (unsigned __int64)((char *)Block[0] - (char *)v10 - 8) > 0x1F )\n        invalid_parameter_noinfo_noreturn();\n    }\n    j_j_free(v10);\n  }\n  return v9;\n}", "assembly": "; \n; GameLevelManager::hasLikedAccountItem from 0x140164e10 to 0x140164eeb (219 bytes)\n; \n; 9 xrefs:\n; > GameLevelManager::hasLikedItemFullCheck @ 0x140164dab\n; > GameLevelManager::hasLikedItemFullCheck @ 0x140164dc3\n; > GameLevelManager::hasLikedItemFullCheck @ 0x140164dcf\n; > GameLevelManager::hasLikedItemFullCheck @ 0x140164de9\n; > LevelInfoLayer::updateSideButtons @ 0x1402fea76\n; > LevelInfoLayer::updateSideButtons @ 0x1402fea94\n; > LevelListLayer::updateSideButtons @ 0x140307c2e\n; > LevelListLayer::updateSideButtons @ 0x140307c4c\n; > <???> @ 0x1406cacb0\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    rbx                                                            ; +0x0, 0x140164e10\nsub     rsp, 60h                                                       ; +0x2, 0x140164e12\nmov     rax, cs:__security_cookie                                      ; +0x6, 0x140164e16\nxor     rax, rsp                                                       ; +0xd, 0x140164e1d\nmov     [rsp+68h+var_18], rax                                          ; +0x10, 0x140164e20\nmov     rbx, rcx                                                       ; +0x15, 0x140164e25\nmov     eax, [rsp+68h+arg_20]                                          ; +0x18, 0x140164e28\nmovzx   r9d, r9b                                                       ; +0x1f, 0x140164e2f\nmov     [rsp+68h+var_48], eax                                          ; +0x23, 0x140164e33\nlea     rcx, aLikeIIII; \"like_%i_%i_%i_%i\"                             ; +0x27, 0x140164e37\ncall    cs:?createWithFormat@CCString@cocos2d@@SAPEAV12@PEBDZZ; cocos2d::CCString::createWithFormat(char const *,...) ; +0x2e, 0x140164e3e\nmov     rcx, rax                                                       ; +0x34, 0x140164e44\ncall    cs:?getCString@CCString@cocos2d@@QEBAPEBDXZ; cocos2d::CCString::getCString(void) ; +0x37, 0x140164e47\nxorps   xmm0, xmm0                                                     ; +0x3d, 0x140164e4d\nmovups  xmmword ptr [rsp+68h+Block], xmm0                              ; +0x40, 0x140164e50\nxorps   xmm1, xmm1                                                     ; +0x45, 0x140164e55\nmovdqu  [rsp+68h+var_28], xmm1                                         ; +0x48, 0x140164e58\nmov     r8, 0FFFFFFFFFFFFFFFFh                                         ; +0x4e, 0x140164e5e\ninc     r8                                                             ; +0x55, 0x140164e65\ncmp     byte ptr [rax+r8], 0                                           ; +0x58, 0x140164e68\njnz     short loc_140164E65                                            ; +0x5d, 0x140164e6d\nmov     rdx, rax                                                       ; +0x5f, 0x140164e6f\nlea     rcx, [rsp+68h+Block]                                           ; +0x62, 0x140164e72\ncall    sub_14003A930                                                  ; +0x67, 0x140164e77\nnop                                                                    ; +0x6c, 0x140164e7c\nlea     rdx, [rsp+68h+Block]                                           ; +0x6d, 0x140164e7d\nmov     rcx, [rbx+188h]                                                ; +0x72, 0x140164e82\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 &) ; +0x79, 0x140164e89\ntest    rax, rax                                                       ; +0x7f, 0x140164e8f\nsetnz   bl                                                             ; +0x82, 0x140164e92\nmov     rdx, qword ptr [rsp+68h+var_28+8]                              ; +0x85, 0x140164e95\ncmp     rdx, 0Fh                                                       ; +0x8a, 0x140164e9a\njbe     short loc_140164ED5                                            ; +0x8e, 0x140164e9e\ninc     rdx                                                            ; +0x90, 0x140164ea0\nmov     rcx, [rsp+68h+Block]; Block                                    ; +0x93, 0x140164ea3\nmov     rax, rcx                                                       ; +0x98, 0x140164ea8\ncmp     rdx, 1000h                                                     ; +0x9b, 0x140164eab\njb      short loc_140164ED0                                            ; +0xa2, 0x140164eb2\nadd     rdx, 27h ; '''                                                 ; +0xa4, 0x140164eb4\nmov     rcx, [rcx-8]                                                   ; +0xa8, 0x140164eb8\nsub     rax, rcx                                                       ; +0xac, 0x140164ebc\nadd     rax, 0FFFFFFFFFFFFFFF8h                                        ; +0xaf, 0x140164ebf\ncmp     rax, 1Fh                                                       ; +0xb3, 0x140164ec3\njbe     short loc_140164ED0                                            ; +0xb7, 0x140164ec7\ncall    cs:_invalid_parameter_noinfo_noreturn                          ; +0xb9, 0x140164ec9\nalign 10h                                                              ; +0xbf, 0x140164ecf\ncall    j_j_free                                                       ; +0xc0, 0x140164ed0\nmovzx   eax, bl                                                        ; +0xc5, 0x140164ed5\nmov     rcx, [rsp+68h+var_18]                                          ; +0xc8, 0x140164ed8\nxor     rcx, rsp; StackCookie                                          ; +0xcd, 0x140164edd\ncall    __security_check_cookie                                        ; +0xd0, 0x140164ee0\nadd     rsp, 60h                                                       ; +0xd5, 0x140164ee5\npop     rbx                                                            ; +0xd9, 0x140164ee9\nretn                                                                   ; +0xda, 0x140164eea", "xrefs": ["GameLevelManager::hasLikedItemFullCheck @ 0x140164dab", "GameLevelManager::hasLikedItemFullCheck @ 0x140164dc3", "GameLevelManager::hasLikedItemFullCheck @ 0x140164dcf", "GameLevelManager::hasLikedItemFullCheck @ 0x140164de9", "LevelInfoLayer::updateSideButtons @ 0x1402fea76", "LevelInfoLayer::updateSideButtons @ 0x1402fea94", "LevelListLayer::updateSideButtons @ 0x140307c2e", "LevelListLayer::updateSideButtons @ 0x140307c4c", "<???> @ 0x1406cacb0"], "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"}