{"type": "func", "start": 5370920832, "end": 5370920932, "name": "GameLevelManager::getLocalLevel", "pseudocode": "// \n// GameLevelManager::getLocalLevel from 0x14021bf80 to 0x14021bfe4 (100 bytes)\n// \n// 3 xrefs:\n// > GameLevelManager::onUploadLevelCompleted @ 0x14022a200\n// > GameLevelManager::onUploadLevelCompleted @ 0x14022a22d\n// > <???> @ 0x14091ba40\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:28:23 +0000\n// \n\nstruct cocos2d::CCObject *__fastcall GameLevelManager::getLocalLevel(__int64 a1, int a2)\n{\n  unsigned int v3; // ebx\n  cocos2d::CCArray *v4; // rdi\n  struct cocos2d::CCObject *result; // rax\n\n  v3 = 0;\n  v4 = *(cocos2d::CCArray **)(LocalLevelManager::sharedState(a1) + 368);\n  if ( !cocos2d::CCArray::count(v4) )\n    return nullptr;\n  while ( 1 )\n  {\n    result = cocos2d::CCArray::objectAtIndex(v4, v3);\n    if ( *((_DWORD *)result + 306) == a2 )\n      break;\n    if ( ++v3 >= cocos2d::CCArray::count(v4) )\n      return nullptr;\n  }\n  return result;\n}", "assembly": "; \n; GameLevelManager::getLocalLevel from 0x14021bf80 to 0x14021bfe4 (100 bytes)\n; \n; 3 xrefs:\n; > GameLevelManager::onUploadLevelCompleted @ 0x14022a200\n; > GameLevelManager::onUploadLevelCompleted @ 0x14022a22d\n; > <???> @ 0x14091ba40\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:28:23 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x14021bf80\nmov     [rsp+arg_8], rsi                                               ; +0x5, 0x14021bf85\npush    rdi                                                            ; +0xa, 0x14021bf8a\nsub     rsp, 20h                                                       ; +0xb, 0x14021bf8b\nmov     esi, edx                                                       ; +0xf, 0x14021bf8f\ncall    LocalLevelManager__sharedState                                 ; +0x11, 0x14021bf91\nxor     ebx, ebx                                                       ; +0x16, 0x14021bf96\nmov     rdi, [rax+170h]                                                ; +0x18, 0x14021bf98\nmov     rcx, rdi                                                       ; +0x1f, 0x14021bf9f\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x22, 0x14021bfa2\ntest    eax, eax                                                       ; +0x28, 0x14021bfa8\njz      short loc_14021BFD2                                            ; +0x2a, 0x14021bfaa\nnop     dword ptr [rax+00h]                                            ; +0x2c, 0x14021bfac\nmov     edx, ebx                                                       ; +0x30, 0x14021bfb0\nmov     rcx, rdi                                                       ; +0x32, 0x14021bfb2\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0x35, 0x14021bfb5\ncmp     [rax+4C8h], esi                                                ; +0x3b, 0x14021bfbb\njz      short loc_14021BFD4                                            ; +0x41, 0x14021bfc1\nmov     rcx, rdi                                                       ; +0x43, 0x14021bfc3\ninc     ebx                                                            ; +0x46, 0x14021bfc6\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x48, 0x14021bfc8\ncmp     ebx, eax                                                       ; +0x4e, 0x14021bfce\njb      short loc_14021BFB0                                            ; +0x50, 0x14021bfd0\nxor     eax, eax                                                       ; +0x52, 0x14021bfd2\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x54, 0x14021bfd4\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x59, 0x14021bfd9\nadd     rsp, 20h                                                       ; +0x5e, 0x14021bfde\npop     rdi                                                            ; +0x62, 0x14021bfe2\nretn                                                                   ; +0x63, 0x14021bfe3", "xrefs": ["GameLevelManager::onUploadLevelCompleted @ 0x14022a200", "GameLevelManager::onUploadLevelCompleted @ 0x14022a22d", "<???> @ 0x14091ba40"], "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"}