{"type": "func", "start": 5370832896, "end": 5370833451, "name": "EndLevelLayer::onRestartCheckpoint", "pseudocode": "// \n// EndLevelLayer::onRestartCheckpoint from 0x140206800 to 0x140206a2b (555 bytes)\n// \n// 2 xrefs:\n// > EndLevelLayer::customSetup @ 0x140204fcd\n// > <???> @ 0x14091b1ac\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:15 +0000\n// \n\n// Hidden C++ exception states: #wind=4\nvoid __fastcall EndLevelLayer::onRestartCheckpoint(__int64 a1)\n{\n  __int64 v2; // rcx\n  __int64 v3; // rdx\n  __int64 v4; // rcx\n  __int64 v5; // r8\n  __int64 v6; // r9\n  cocos2d::CCEGLView *v7; // rax\n  __int64 v8; // rcx\n  __int64 v9; // rax\n  __int64 v10; // r8\n  __int64 v11; // r9\n  int v12; // ecx\n  __int64 v13; // rbx\n  struct cocos2d::CCFiniteTimeAction *v14; // rax\n  struct cocos2d::CCAction *v15; // rbx\n  __int128 v16; // [rsp+30h] [rbp-28h] BYREF\n  __int64 v17; // [rsp+40h] [rbp-18h]\n  __int64 v18; // [rsp+48h] [rbp-10h]\n  void *v19; // [rsp+60h] [rbp+8h]\n  void *v20; // [rsp+60h] [rbp+8h]\n  void *v21; // [rsp+70h] [rbp+18h]\n\n  if ( !*(_BYTE *)(a1 + 619) )\n  {\n    *(_BYTE *)(a1 + 619) = 1;\n    v2 = qword_14090BFD0;\n    if ( !qword_14090BFD0 )\n    {\n      v19 = operator new(0x6E8u);\n      qword_14090BFD0 = GameManager::GameManager(v19);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);\n      v2 = qword_14090BFD0;\n    }\n    if ( !(unsigned __int8)GameManager::getGameVariable(v2, \"0024\") )\n    {\n      v7 = (cocos2d::CCEGLView *)cocos2d::CCEGLView::sharedOpenGLView(v4, v3, v5, v6);\n      cocos2d::CCEGLView::showCursor(v7, 0);\n    }\n    v8 = qword_14090BF60;\n    if ( !qword_14090BF60 )\n    {\n      v20 = operator new(0x8A8u);\n      qword_14090BF60 = FMODAudioEngine::FMODAudioEngine((__int64)v20);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BF60 + 72LL))(qword_14090BF60);\n      v8 = qword_14090BF60;\n    }\n    FMODAudioEngine::clearAllAudio(v8);\n    v9 = *(_QWORD *)(a1 + 608);\n    if ( *(_BYTE *)(v9 + 13024) && !*(_BYTE *)(v9 + 13025) )\n      PlayLayer::playPracticeMusic();\n    v16 = 0;\n    *(_QWORD *)&v16 = sub_14003D460(0x20u);\n    v17 = 16;\n    v18 = 31;\n    strcpy((char *)v16, \"playSound_01.ogg\");\n    v12 = qword_14090BF60;\n    if ( !qword_14090BF60 )\n    {\n      v21 = operator new(0x8A8u);\n      qword_14090BF60 = FMODAudioEngine::FMODAudioEngine((__int64)v21);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BF60 + 72LL))(qword_14090BF60);\n      v12 = qword_14090BF60;\n    }\n    FMODAudioEngine::playEffect(v12, (__int64)&v16, v10, v11, 1050253722);\n    (*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)a1 + 1072LL))(a1, 0);\n    (*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)a1 + 920LL))(a1, 0);\n    (*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)a1 + 1008LL))(a1, 0);\n    (*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)a1 + 992LL))(a1, 0);\n    v13 = cocos2d::CCCallFunc::create(*(_QWORD *)(a1 + 608), sub_140208964);\n    v14 = cocos2d::CCDelayTime::create(0.5);\n    v15 = cocos2d::CCSequence::create(v14, v13, 0);\n    (*(void (__fastcall **)(struct cocos2d::CCAction *, __int64))(*(_QWORD *)v15 + 64LL))(v15, 16);\n    cocos2d::CCNode::runAction(*(cocos2d::CCNode **)(a1 + 608), v15);\n  }\n}", "assembly": "; \n; EndLevelLayer::onRestartCheckpoint from 0x140206800 to 0x140206a2b (555 bytes)\n; \n; 2 xrefs:\n; > EndLevelLayer::customSetup @ 0x140204fcd\n; > <???> @ 0x14091b1ac\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:15 +0000\n; \nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x140206800\npush    rdi                                                            ; +0x5, 0x140206805\nsub     rsp, 50h                                                       ; +0x6, 0x140206806\nmov     rdi, rcx                                                       ; +0xa, 0x14020680a\ncmp     byte ptr [rcx+26Bh], 0                                         ; +0xd, 0x14020680d\njnz     loc_140206A20                                                  ; +0x14, 0x140206814\nmov     byte ptr [rcx+26Bh], 1                                         ; +0x1a, 0x14020681a\nmov     rcx, cs:qword_14090BFD0                                        ; +0x21, 0x140206821\ntest    rcx, rcx                                                       ; +0x28, 0x140206828\njnz     short loc_14020685F                                            ; +0x2b, 0x14020682b\nmov     ecx, 6E8h; Size                                                ; +0x2d, 0x14020682d\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x32, 0x140206832\nmov     [rsp+58h+arg_0], rax                                           ; +0x37, 0x140206837\nmov     rcx, rax                                                       ; +0x3c, 0x14020683c\ncall    GameManager__GameManager                                       ; +0x3f, 0x14020683f\nnop                                                                    ; +0x44, 0x140206844\nmov     cs:qword_14090BFD0, rax                                        ; +0x45, 0x140206845\nmov     rcx, [rax]                                                     ; +0x4c, 0x14020684c\nmov     rdx, [rcx+48h]                                                 ; +0x4f, 0x14020684f\nmov     rcx, rax                                                       ; +0x53, 0x140206853\ncall    rdx                                                            ; +0x56, 0x140206856\nmov     rcx, cs:qword_14090BFD0                                        ; +0x58, 0x140206858\nlea     rdx, a0024; \"0024\"                                             ; +0x5f, 0x14020685f\ncall    GameManager__getGameVariable                                   ; +0x66, 0x140206866\ntest    al, al                                                         ; +0x6b, 0x14020686b\njnz     short loc_140206880                                            ; +0x6d, 0x14020686d\ncall    cs:?sharedOpenGLView@CCEGLView@cocos2d@@SAPEAV12@XZ; cocos2d::CCEGLView::sharedOpenGLView(void) ; +0x6f, 0x14020686f\nmov     rcx, rax                                                       ; +0x75, 0x140206875\nxor     edx, edx                                                       ; +0x78, 0x140206878\ncall    cs:?showCursor@CCEGLView@cocos2d@@QEAAX_N@Z; cocos2d::CCEGLView::showCursor(bool) ; +0x7a, 0x14020687a\nmov     rcx, cs:qword_14090BF60                                        ; +0x80, 0x140206880\ntest    rcx, rcx                                                       ; +0x87, 0x140206887\njnz     short loc_1402068BE                                            ; +0x8a, 0x14020688a\nmov     ecx, 8A8h; Size                                                ; +0x8c, 0x14020688c\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x91, 0x140206891\nmov     [rsp+58h+arg_0], rax                                           ; +0x96, 0x140206896\nmov     rcx, rax                                                       ; +0x9b, 0x14020689b\ncall    FMODAudioEngine__FMODAudioEngine                               ; +0x9e, 0x14020689e\nnop                                                                    ; +0xa3, 0x1402068a3\nmov     cs:qword_14090BF60, rax                                        ; +0xa4, 0x1402068a4\nmov     rcx, [rax]                                                     ; +0xab, 0x1402068ab\nmov     rdx, [rcx+48h]                                                 ; +0xae, 0x1402068ae\nmov     rcx, rax                                                       ; +0xb2, 0x1402068b2\ncall    rdx                                                            ; +0xb5, 0x1402068b5\nmov     rcx, cs:qword_14090BF60                                        ; +0xb7, 0x1402068b7\ncall    FMODAudioEngine__clearAllAudio                                 ; +0xbe, 0x1402068be\nmov     rax, [rdi+260h]                                                ; +0xc3, 0x1402068c3\ncmp     byte ptr [rax+32E0h], 0                                        ; +0xca, 0x1402068ca\njz      short loc_1402068E1                                            ; +0xd1, 0x1402068d1\ncmp     byte ptr [rax+32E1h], 0                                        ; +0xd3, 0x1402068d3\njnz     short loc_1402068E1                                            ; +0xda, 0x1402068da\ncall    PlayLayer__playPracticeMusic                                   ; +0xdc, 0x1402068dc\nlea     rax, [rsp+58h+var_28]                                          ; +0xe1, 0x1402068e1\nmov     [rsp+58h+arg_0], rax                                           ; +0xe6, 0x1402068e6\nxorps   xmm0, xmm0                                                     ; +0xeb, 0x1402068eb\nmovups  [rsp+58h+var_28], xmm0                                         ; +0xee, 0x1402068ee\nxor     eax, eax                                                       ; +0xf3, 0x1402068f3\nmov     [rsp+58h+var_18], rax                                          ; +0xf5, 0x1402068f5\nmov     [rsp+58h+var_10], rax                                          ; +0xfa, 0x1402068fa\nmov     ecx, 20h ; ' '                                                 ; +0xff, 0x1402068ff\ncall    sub_14003D460                                                  ; +0x104, 0x140206904\nmov     qword ptr [rsp+58h+var_28], rax                                ; +0x109, 0x140206909\nmov     [rsp+58h+var_18], 10h                                          ; +0x10e, 0x14020690e\nmov     [rsp+58h+var_10], 1Fh                                          ; +0x117, 0x140206917\nmovups  xmm0, cs:xmmword_14070E0E0                                     ; +0x120, 0x140206920\nmovups  xmmword ptr [rax], xmm0                                        ; +0x127, 0x140206927\nmov     byte ptr [rax+10h], 0                                          ; +0x12a, 0x14020692a\nmov     rcx, cs:qword_14090BF60                                        ; +0x12e, 0x14020692e\ntest    rcx, rcx                                                       ; +0x135, 0x140206935\njnz     short loc_14020696C                                            ; +0x138, 0x140206938\nmov     ecx, 8A8h; Size                                                ; +0x13a, 0x14020693a\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x13f, 0x14020693f\nmov     [rsp+58h+arg_10], rax                                          ; +0x144, 0x140206944\nmov     rcx, rax                                                       ; +0x149, 0x140206949\ncall    FMODAudioEngine__FMODAudioEngine                               ; +0x14c, 0x14020694c\nnop                                                                    ; +0x151, 0x140206951\nmov     cs:qword_14090BF60, rax                                        ; +0x152, 0x140206952\nmov     rcx, [rax]                                                     ; +0x159, 0x140206959\nmov     rdx, [rcx+48h]                                                 ; +0x15c, 0x14020695c\nmov     rcx, rax                                                       ; +0x160, 0x140206960\ncall    rdx                                                            ; +0x163, 0x140206963\nmov     rcx, cs:qword_14090BF60                                        ; +0x165, 0x140206965\nmovss   xmm0, cs:dword_140834EA0                                       ; +0x16c, 0x14020696c\nmovss   [rsp+58h+var_38], xmm0                                         ; +0x174, 0x140206974\nxorps   xmm3, xmm3                                                     ; +0x17a, 0x14020697a\nmovss   xmm2, cs:flt_140835080                                         ; +0x17d, 0x14020697d\nlea     rdx, [rsp+58h+var_28]                                          ; +0x185, 0x140206985\ncall    FMODAudioEngine__playEffect                                    ; +0x18a, 0x14020698a\nmov     rax, [rdi]                                                     ; +0x18f, 0x14020698f\nxor     edx, edx                                                       ; +0x192, 0x140206992\nmov     rcx, rdi                                                       ; +0x194, 0x140206994\ncall    qword ptr [rax+430h]                                           ; +0x197, 0x140206997\nmov     rax, [rdi]                                                     ; +0x19d, 0x14020699d\nxor     edx, edx                                                       ; +0x1a0, 0x1402069a0\nmov     rcx, rdi                                                       ; +0x1a2, 0x1402069a2\ncall    qword ptr [rax+398h]                                           ; +0x1a5, 0x1402069a5\nmov     rax, [rdi]                                                     ; +0x1ab, 0x1402069ab\nxor     edx, edx                                                       ; +0x1ae, 0x1402069ae\nmov     rcx, rdi                                                       ; +0x1b0, 0x1402069b0\ncall    qword ptr [rax+3F0h]                                           ; +0x1b3, 0x1402069b3\nmov     rax, [rdi]                                                     ; +0x1b9, 0x1402069b9\nxor     edx, edx                                                       ; +0x1bc, 0x1402069bc\nmov     rcx, rdi                                                       ; +0x1be, 0x1402069be\ncall    qword ptr [rax+3E0h]                                           ; +0x1c1, 0x1402069c1\nlea     rdx, sub_140208964                                             ; +0x1c7, 0x1402069c7\nmov     rcx, [rdi+260h]                                                ; +0x1ce, 0x1402069ce\ncall    cs:?create@CCCallFunc@cocos2d@@SAPEAV12@PEAVCCObject@2@P832@EAAXXZ@Z; cocos2d::CCCallFunc::create(cocos2d::CCObject *,void (cocos2d::CCObject::*)(void)) ; +0x1d5, 0x1402069d5\nmov     rbx, rax                                                       ; +0x1db, 0x1402069db\nmovss   xmm0, cs:dword_140834F20                                       ; +0x1de, 0x1402069de\ncall    cs:?create@CCDelayTime@cocos2d@@SAPEAV12@M@Z; cocos2d::CCDelayTime::create(float) ; +0x1e6, 0x1402069e6\nmov     rcx, rax                                                       ; +0x1ec, 0x1402069ec\nxor     r8d, r8d                                                       ; +0x1ef, 0x1402069ef\nmov     rdx, rbx                                                       ; +0x1f2, 0x1402069f2\ncall    cs:?create@CCSequence@cocos2d@@SAPEAV12@PEAVCCFiniteTimeAction@2@ZZ; cocos2d::CCSequence::create(cocos2d::CCFiniteTimeAction *,...) ; +0x1f5, 0x1402069f5\nmov     rbx, rax                                                       ; +0x1fb, 0x1402069fb\nmov     rcx, [rax]                                                     ; +0x1fe, 0x1402069fe\nmov     r8, [rcx+40h]                                                  ; +0x201, 0x140206a01\nmov     edx, 10h                                                       ; +0x205, 0x140206a05\nmov     rcx, rax                                                       ; +0x20a, 0x140206a0a\ncall    r8                                                             ; +0x20d, 0x140206a0d\nmov     rdx, rbx                                                       ; +0x210, 0x140206a10\nmov     rcx, [rdi+260h]                                                ; +0x213, 0x140206a13\ncall    cs:?runAction@CCNode@cocos2d@@QEAAPEAVCCAction@2@PEAV32@@Z; cocos2d::CCNode::runAction(cocos2d::CCAction *) ; +0x21a, 0x140206a1a\nmov     rbx, [rsp+58h+arg_8]                                           ; +0x220, 0x140206a20\nadd     rsp, 50h                                                       ; +0x225, 0x140206a25\npop     rdi                                                            ; +0x229, 0x140206a29\nretn                                                                   ; +0x22a, 0x140206a2a", "xrefs": ["EndLevelLayer::customSetup @ 0x140204fcd", "<???> @ 0x14091b1ac"], "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"}