{"type": "func", "start": 4299956304, "end": 4299956446, "name": "EndLevelLayer::onEdit", "pseudocode": "// \n// EndLevelLayer::onEdit from 0x1004c2050 to 0x1004c20de (142 bytes)\n// \n// 1 xrefs:\n// > EndLevelLayer::customSetup @ 0x1004c105e\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 EndLevelLayer::onEdit(EndLevelLayer *a1, cocos2d::CCObject *a2)\n{\n  FMODAudioEngine *v2; // rax\n  cocos2d::CCDelayTime *v3; // r14\n  cocos2d::CCCallFunc *v4; // rax\n  cocos2d::CCSequence *v5; // rax\n\n  if ( !a1->m_exiting )\n  {\n    a1->m_exiting = 1;\n    cocos2d::CCNode::stopAllActions(a1->m_playLayer);\n    cocos2d::CCNode::unscheduleAllSelectors(a1->m_playLayer);\n    v2 = FMODAudioEngine::sharedEngine();\n    FMODAudioEngine::stopAllMusic(v2, 1);\n    PlayLayer::removeAllObjects(a1->m_playLayer);\n    v3 = cocos2d::CCDelayTime::create(0.0);\n    v4 = cocos2d::CCCallFunc::create(a1, (cocos2d::SEL_CallFunc)(unsigned __int64)EndLevelLayer::goEdit);\n    v5 = sub_1003B5760(v3, v4, 0);\n    cocos2d::CCNode::runAction(a1, v5);\n  }\n}", "assembly": "; \n; EndLevelLayer::onEdit from 0x1004c2050 to 0x1004c20de (142 bytes)\n; \n; 1 xrefs:\n; > EndLevelLayer::customSetup @ 0x1004c105e\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\ncmp     byte ptr [rdi+26Bh], 0                                         ; +0x0, 0x1004c2050\njz      short loc_1004C205A                                            ; +0x7, 0x1004c2057\nretn                                                                   ; +0x9, 0x1004c2059\npush    rbp                                                            ; +0xa, 0x1004c205a\nmov     rbp, rsp                                                       ; +0xb, 0x1004c205b\npush    r14                                                            ; +0xe, 0x1004c205e\npush    rbx                                                            ; +0x10, 0x1004c2060\nmov     byte ptr [rdi+26Bh], 1                                         ; +0x11, 0x1004c2061\nmov     rax, [rdi+260h]                                                ; +0x18, 0x1004c2068\nmov     rbx, rdi                                                       ; +0x1f, 0x1004c206f\nmov     rdi, rax                                                       ; +0x22, 0x1004c2072\ncall    cocos2d__CCNode__stopAllActions                                ; +0x25, 0x1004c2075\nmov     rdi, [rbx+260h]                                                ; +0x2a, 0x1004c207a\ncall    cocos2d__CCNode__unscheduleAllSelectors                        ; +0x31, 0x1004c2081\ncall    FMODAudioEngine__sharedEngine                                  ; +0x36, 0x1004c2086\nmov     rdi, rax                                                       ; +0x3b, 0x1004c208b\nmov     esi, 1                                                         ; +0x3e, 0x1004c208e\ncall    FMODAudioEngine__stopAllMusic                                  ; +0x43, 0x1004c2093\nmov     rdi, [rbx+260h]                                                ; +0x48, 0x1004c2098\ncall    PlayLayer__removeAllObjects                                    ; +0x4f, 0x1004c209f\nxorps   xmm0, xmm0                                                     ; +0x54, 0x1004c20a4\ncall    cocos2d__CCDelayTime__create                                   ; +0x57, 0x1004c20a7\nmov     r14, rax                                                       ; +0x5c, 0x1004c20ac\nlea     rsi, EndLevelLayer__goEdit                                     ; +0x5f, 0x1004c20af\nmov     rdi, rbx                                                       ; +0x66, 0x1004c20b6\nxor     edx, edx                                                       ; +0x69, 0x1004c20b9\ncall    cocos2d__CCCallFunc__create                                    ; +0x6b, 0x1004c20bb\nmov     rdi, r14                                                       ; +0x70, 0x1004c20c0\nmov     rsi, rax                                                       ; +0x73, 0x1004c20c3\nxor     edx, edx                                                       ; +0x76, 0x1004c20c6\nxor     eax, eax                                                       ; +0x78, 0x1004c20c8\ncall    sub_1003B5760                                                  ; +0x7a, 0x1004c20ca\nmov     rdi, rbx                                                       ; +0x7f, 0x1004c20cf\nmov     rsi, rax                                                       ; +0x82, 0x1004c20d2\npop     rbx                                                            ; +0x85, 0x1004c20d5\npop     r14                                                            ; +0x86, 0x1004c20d6\npop     rbp                                                            ; +0x88, 0x1004c20d8\njmp     cocos2d__CCNode__runAction                                     ; +0x89, 0x1004c20d9", "xrefs": ["EndLevelLayer::customSetup @ 0x1004c105e"], "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"}