{"type": "func", "start": 6443246896, "end": 6443247000, "name": "cocos2d::CCDirector::popToSceneInStack", "pseudocode": "// \n// cocos2d::CCDirector::popToSceneInStack from 0x1800c2530 to 0x1800c2598 (104 bytes)\n// \n// 2 xrefs:\n// > <???> @ 0x18014cf68\n// > <???> @ 0x1801c34f8\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:22:25 +0000\n// \n\nvoid __fastcall cocos2d::CCDirector::popToSceneInStack(cocos2d::CCDirector *this, struct cocos2d::CCScene *a2)\n{\n  __int64 v2; // rax\n  char v3; // r10\n  int v6; // edx\n  unsigned int *v7; // rcx\n  __int64 v8; // rax\n  struct cocos2d::CCScene **v9; // rcx\n  struct cocos2d::CCScene **v10; // r8\n\n  v2 = *((_QWORD *)this + 37);\n  v3 = 0;\n  v6 = 0;\n  if ( v2 )\n  {\n    v7 = *(unsigned int **)(v2 + 56);\n    v8 = *v7;\n    if ( (_DWORD)v8 )\n    {\n      v9 = *((struct cocos2d::CCScene ***)v7 + 2);\n      v10 = &v9[v8 - 1];\n      if ( v9 <= v10 )\n      {\n        while ( *v9 )\n        {\n          ++v6;\n          if ( *v9 == a2 )\n          {\n            v3 = 1;\n            break;\n          }\n          if ( ++v9 > v10 )\n            return;\n        }\n      }\n    }\n  }\n  if ( !v3 )\n    v6 = 0;\n  if ( v6 > 0 )\n    cocos2d::CCDirector::popToSceneStackLevel(this, v6);\n}", "assembly": "; \n; cocos2d::CCDirector::popToSceneInStack from 0x1800c2530 to 0x1800c2598 (104 bytes)\n; \n; 2 xrefs:\n; > <???> @ 0x18014cf68\n; > <???> @ 0x1801c34f8\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:22:25 +0000\n; \npush    rbx                                                            ; +0x0, 0x1800c2530\nmov     rax, [rcx+128h]                                                ; +0x2, 0x1800c2532\nxor     ebx, ebx                                                       ; +0x9, 0x1800c2539\nxor     r10b, r10b                                                     ; +0xb, 0x1800c253b\nmov     r9, rdx                                                        ; +0xe, 0x1800c253e\nmov     r11, rcx                                                       ; +0x11, 0x1800c2541\nmov     edx, ebx                                                       ; +0x14, 0x1800c2544\ntest    rax, rax                                                       ; +0x16, 0x1800c2546\njz      short loc_1800C2583                                            ; +0x19, 0x1800c2549\nmov     rcx, [rax+38h]                                                 ; +0x1b, 0x1800c254b\nmov     eax, [rcx]                                                     ; +0x1f, 0x1800c254f\ntest    eax, eax                                                       ; +0x21, 0x1800c2551\njz      short loc_1800C2583                                            ; +0x23, 0x1800c2553\nmov     rcx, [rcx+10h]                                                 ; +0x25, 0x1800c2555\nlea     r8, [rax-1]                                                    ; +0x29, 0x1800c2559\nlea     r8, [rcx+r8*8]                                                 ; +0x2d, 0x1800c255d\ncmp     rcx, r8                                                        ; +0x31, 0x1800c2561\nja      short loc_1800C2583                                            ; +0x34, 0x1800c2564\nmov     rax, [rcx]                                                     ; +0x36, 0x1800c2566\ntest    rax, rax                                                       ; +0x39, 0x1800c2569\njz      short loc_1800C2583                                            ; +0x3c, 0x1800c256c\ninc     edx                                                            ; +0x3e, 0x1800c256e\ncmp     rax, r9                                                        ; +0x40, 0x1800c2570\njz      short loc_1800C2580                                            ; +0x43, 0x1800c2573\nadd     rcx, 8                                                         ; +0x45, 0x1800c2575\ncmp     rcx, r8                                                        ; +0x49, 0x1800c2579\njbe     short loc_1800C2566                                            ; +0x4c, 0x1800c257c\npop     rbx                                                            ; +0x4e, 0x1800c257e\nretn                                                                   ; +0x4f, 0x1800c257f\nmov     r10b, 1                                                        ; +0x50, 0x1800c2580\ntest    r10b, r10b                                                     ; +0x53, 0x1800c2583\ncmovz   edx, ebx; int                                                  ; +0x56, 0x1800c2586\ntest    edx, edx                                                       ; +0x59, 0x1800c2589\njle     short loc_1800C2596                                            ; +0x5b, 0x1800c258b\nmov     rcx, r11; this                                                 ; +0x5d, 0x1800c258d\npop     rbx                                                            ; +0x60, 0x1800c2590\njmp     ?popToSceneStackLevel@CCDirector@cocos2d@@QEAAXH@Z; cocos2d::CCDirector::popToSceneStackLevel(int) ; +0x61, 0x1800c2591\npop     rbx                                                            ; +0x66, 0x1800c2596\nretn                                                                   ; +0x67, 0x1800c2597", "xrefs": ["<???> @ 0x18014cf68", "<???> @ 0x1801c34f8"], "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"}