{"type": "func", "start": 5372532656, "end": 5372533317, "name": "PlayLayer::dPlayLayer", "pseudocode": "// \n// PlayLayer::dPlayLayer from 0x1403a57b0 to 0x1403a5a45 (661 bytes)\n// \n// 2 xrefs:\n// > sub_1403A50E0 @ 0x1403a50ef\n// > <???> @ 0x1406d6b30\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 PlayLayer::dPlayLayer(__int64 a1, __int64 a2, __int64 a3, float a4)\n{\n  cocos2d::CCEGLView *v5; // rax\n  cocos2d::CCObject *v6; // rcx\n  cocos2d::CCObject *v7; // rcx\n  cocos2d::CCObject *v8; // rcx\n  cocos2d::CCObject *v9; // rcx\n  cocos2d::CCObject *v10; // rcx\n  cocos2d::CCObject *v11; // rcx\n  cocos2d::CCObject *v12; // rcx\n  cocos2d::CCObject *v13; // rcx\n  cocos2d::CCObject *v14; // rcx\n  cocos2d::CCObject *v15; // rcx\n  cocos2d::CCObject *v16; // rcx\n  __int64 v17; // rax\n  void *v18; // rax\n  __int64 v19; // rax\n  FMODAudioEngine *v20; // rax\n  __int64 v21; // rax\n  __int64 v22; // rdx\n  __int64 v23; // r8\n\n  *(_QWORD *)a1 = &PlayLayer::`vftable';\n  *(_QWORD *)(a1 + 320) = &PlayLayer::`vftable';\n  *(_QWORD *)(a1 + 328) = &PlayLayer::`vftable';\n  *(_QWORD *)(a1 + 336) = &PlayLayer::`vftable';\n  *(_QWORD *)(a1 + 344) = &PlayLayer::`vftable';\n  *(_QWORD *)(a1 + 352) = &PlayLayer::`vftable';\n  *(_QWORD *)(a1 + 408) = &PlayLayer::`vftable';\n  *(_QWORD *)(a1 + 14240) = &PlayLayer::`vftable';\n  *(_QWORD *)(a1 + 14248) = &PlayLayer::`vftable';\n  *(_QWORD *)(a1 + 14256) = &PlayLayer::`vftable';\n  *(_BYTE *)(cocos2d::CCEGLView::sharedOpenGLView() + 237) = 0;\n  v5 = (cocos2d::CCEGLView *)cocos2d::CCEGLView::sharedOpenGLView();\n  cocos2d::CCEGLView::showCursor(v5, 1);\n  v6 = *(cocos2d::CCObject **)(a1 + 2168);\n  if ( v6 )\n    cocos2d::CCObject::release(v6);\n  v7 = *(cocos2d::CCObject **)(a1 + 14472);\n  if ( v7 )\n    cocos2d::CCObject::release(v7);\n  v8 = *(cocos2d::CCObject **)(a1 + 3504);\n  if ( v8 )\n    cocos2d::CCObject::release(v8);\n  v9 = *(cocos2d::CCObject **)(a1 + 14616);\n  if ( v9 )\n    cocos2d::CCObject::release(v9);\n  v10 = *(cocos2d::CCObject **)(a1 + 3496);\n  if ( v10 )\n    cocos2d::CCObject::release(v10);\n  v11 = *(cocos2d::CCObject **)(a1 + 14504);\n  if ( v11 )\n    cocos2d::CCObject::release(v11);\n  v12 = *(cocos2d::CCObject **)(a1 + 14464);\n  if ( v12 )\n    cocos2d::CCObject::release(v12);\n  v13 = *(cocos2d::CCObject **)(a1 + 14864);\n  if ( v13 )\n    cocos2d::CCObject::release(v13);\n  v14 = *(cocos2d::CCObject **)(a1 + 14520);\n  if ( v14 )\n    cocos2d::CCObject::release(v14);\n  v15 = *(cocos2d::CCObject **)(a1 + 14480);\n  if ( v15 )\n    cocos2d::CCObject::release(v15);\n  v16 = *(cocos2d::CCObject **)(a1 + 14528);\n  if ( v16 )\n    cocos2d::CCObject::release(v16);\n  v17 = qword_1406C2ED8;\n  if ( !qword_1406C2ED8 )\n  {\n    v18 = operator new(0x668u);\n    qword_1406C2ED8 = sub_14017AB00((__int64)v18);\n    (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);\n    v17 = qword_1406C2ED8;\n  }\n  if ( *(_QWORD *)(v17 + 520) == a1 )\n    *(_QWORD *)(v17 + 520) = 0;\n  v19 = qword_1406C2E88;\n  if ( !qword_1406C2E88 )\n  {\n    v20 = (FMODAudioEngine *)operator new(0x888u);\n    qword_1406C2E88 = (__int64)FMODAudioEngine::FMODAudioEngine(v20);\n    (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2E88 + 72LL))(qword_1406C2E88);\n    v19 = qword_1406C2E88;\n  }\n  *(_BYTE *)(v19 + 544) = 0;\n  v21 = cocos2d::CCDirector::sharedDirector(v16);\n  *(_BYTE *)((*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v21 + 176LL))(v21) + 92) = 0;\n  sub_14005E430(a1 + 14920);\n  sub_14005E430(a1 + 14896);\n  sub_1403BB610(a1 + 14872);\n  sub_14005D100(a1 + 14664);\n  sub_14005D870((void **)(a1 + 14648));\n  sub_1403BB6B0(a1 + 14392);\n  sub_14005D100(a1 + 14368);\n  sub_14005D100(a1 + 14344);\n  sub_14005D100(a1 + 14320);\n  sub_140069BA0((__int64 *)(a1 + 14280));\n  GJBaseGameLayer::dGJBaseGameLayer(a1, v22, v23, a4);\n}", "assembly": "; \n; PlayLayer::dPlayLayer from 0x1403a57b0 to 0x1403a5a45 (661 bytes)\n; \n; 2 xrefs:\n; > sub_1403A50E0 @ 0x1403a50ef\n; > <???> @ 0x1406d6b30\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, 0x1403a57b0\nsub     rsp, 20h                                                       ; +0x2, 0x1403a57b2\nmov     rbx, rcx                                                       ; +0x6, 0x1403a57b6\nlea     rax, ??_7PlayLayer@@6B@; const PlayLayer::`vftable'            ; +0x9, 0x1403a57b9\nmov     [rcx], rax                                                     ; +0x10, 0x1403a57c0\nlea     rax, ??_7PlayLayer@@6B@_0; const PlayLayer::`vftable'          ; +0x13, 0x1403a57c3\nmov     [rcx+140h], rax                                                ; +0x1a, 0x1403a57ca\nlea     rax, ??_7PlayLayer@@6B@_1; const PlayLayer::`vftable'          ; +0x21, 0x1403a57d1\nmov     [rcx+148h], rax                                                ; +0x28, 0x1403a57d8\nlea     rax, ??_7PlayLayer@@6B@_2; const PlayLayer::`vftable'          ; +0x2f, 0x1403a57df\nmov     [rcx+150h], rax                                                ; +0x36, 0x1403a57e6\nlea     rax, ??_7PlayLayer@@6B@_3; const PlayLayer::`vftable'          ; +0x3d, 0x1403a57ed\nmov     [rcx+158h], rax                                                ; +0x44, 0x1403a57f4\nlea     rax, ??_7PlayLayer@@6B@_4; const PlayLayer::`vftable'          ; +0x4b, 0x1403a57fb\nmov     [rcx+160h], rax                                                ; +0x52, 0x1403a5802\nlea     rax, ??_7PlayLayer@@6B@_5; const PlayLayer::`vftable'          ; +0x59, 0x1403a5809\nmov     [rcx+198h], rax                                                ; +0x60, 0x1403a5810\nlea     rax, ??_7PlayLayer@@6B@_6; const PlayLayer::`vftable'          ; +0x67, 0x1403a5817\nmov     [rcx+37A0h], rax                                               ; +0x6e, 0x1403a581e\nlea     rax, ??_7PlayLayer@@6B@_7; const PlayLayer::`vftable'          ; +0x75, 0x1403a5825\nmov     [rcx+37A8h], rax                                               ; +0x7c, 0x1403a582c\nlea     rax, ??_7PlayLayer@@6B@_8; const PlayLayer::`vftable'          ; +0x83, 0x1403a5833\nmov     [rcx+37B0h], rax                                               ; +0x8a, 0x1403a583a\ncall    cs:?sharedOpenGLView@CCEGLView@cocos2d@@SAPEAV12@XZ; cocos2d::CCEGLView::sharedOpenGLView(void) ; +0x91, 0x1403a5841\nmov     byte ptr [rax+0EDh], 0                                         ; +0x97, 0x1403a5847\ncall    cs:?sharedOpenGLView@CCEGLView@cocos2d@@SAPEAV12@XZ; cocos2d::CCEGLView::sharedOpenGLView(void) ; +0x9e, 0x1403a584e\nmov     rcx, rax                                                       ; +0xa4, 0x1403a5854\nmov     dl, 1                                                          ; +0xa7, 0x1403a5857\ncall    cs:?showCursor@CCEGLView@cocos2d@@QEAAX_N@Z; cocos2d::CCEGLView::showCursor(bool) ; +0xa9, 0x1403a5859\nmov     rcx, [rbx+878h]                                                ; +0xaf, 0x1403a585f\ntest    rcx, rcx                                                       ; +0xb6, 0x1403a5866\njz      short loc_1403A5871                                            ; +0xb9, 0x1403a5869\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0xbb, 0x1403a586b\nmov     rcx, [rbx+3888h]                                               ; +0xc1, 0x1403a5871\ntest    rcx, rcx                                                       ; +0xc8, 0x1403a5878\njz      short loc_1403A5883                                            ; +0xcb, 0x1403a587b\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0xcd, 0x1403a587d\nmov     rcx, [rbx+0DB0h]                                               ; +0xd3, 0x1403a5883\ntest    rcx, rcx                                                       ; +0xda, 0x1403a588a\njz      short loc_1403A5895                                            ; +0xdd, 0x1403a588d\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0xdf, 0x1403a588f\nmov     rcx, [rbx+3918h]                                               ; +0xe5, 0x1403a5895\ntest    rcx, rcx                                                       ; +0xec, 0x1403a589c\njz      short loc_1403A58A7                                            ; +0xef, 0x1403a589f\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0xf1, 0x1403a58a1\nmov     rcx, [rbx+0DA8h]                                               ; +0xf7, 0x1403a58a7\ntest    rcx, rcx                                                       ; +0xfe, 0x1403a58ae\njz      short loc_1403A58B9                                            ; +0x101, 0x1403a58b1\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0x103, 0x1403a58b3\nmov     rcx, [rbx+38A8h]                                               ; +0x109, 0x1403a58b9\ntest    rcx, rcx                                                       ; +0x110, 0x1403a58c0\njz      short loc_1403A58CB                                            ; +0x113, 0x1403a58c3\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0x115, 0x1403a58c5\nmov     rcx, [rbx+3880h]                                               ; +0x11b, 0x1403a58cb\ntest    rcx, rcx                                                       ; +0x122, 0x1403a58d2\njz      short loc_1403A58DD                                            ; +0x125, 0x1403a58d5\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0x127, 0x1403a58d7\nmov     rcx, [rbx+3A10h]                                               ; +0x12d, 0x1403a58dd\ntest    rcx, rcx                                                       ; +0x134, 0x1403a58e4\njz      short loc_1403A58EF                                            ; +0x137, 0x1403a58e7\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0x139, 0x1403a58e9\nmov     rcx, [rbx+38B8h]                                               ; +0x13f, 0x1403a58ef\ntest    rcx, rcx                                                       ; +0x146, 0x1403a58f6\njz      short loc_1403A5901                                            ; +0x149, 0x1403a58f9\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0x14b, 0x1403a58fb\nmov     rcx, [rbx+3890h]                                               ; +0x151, 0x1403a5901\ntest    rcx, rcx                                                       ; +0x158, 0x1403a5908\njz      short loc_1403A5913                                            ; +0x15b, 0x1403a590b\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0x15d, 0x1403a590d\nmov     rcx, [rbx+38C0h]                                               ; +0x163, 0x1403a5913\ntest    rcx, rcx                                                       ; +0x16a, 0x1403a591a\njz      short loc_1403A5925                                            ; +0x16d, 0x1403a591d\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0x16f, 0x1403a591f\nmov     rax, cs:qword_1406C2ED8                                        ; +0x175, 0x1403a5925\ntest    rax, rax                                                       ; +0x17c, 0x1403a592c\njnz     short loc_1403A595A                                            ; +0x17f, 0x1403a592f\nmov     ecx, 668h; Size                                                ; +0x181, 0x1403a5931\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x186, 0x1403a5936\nmov     rcx, rax                                                       ; +0x18b, 0x1403a593b\ncall    sub_14017AB00                                                  ; +0x18e, 0x1403a593e\nmov     cs:qword_1406C2ED8, rax                                        ; +0x193, 0x1403a5943\nmov     rdx, [rax]                                                     ; +0x19a, 0x1403a594a\nmov     rcx, rax                                                       ; +0x19d, 0x1403a594d\ncall    qword ptr [rdx+48h]                                            ; +0x1a0, 0x1403a5950\nmov     rax, cs:qword_1406C2ED8                                        ; +0x1a3, 0x1403a5953\ncmp     [rax+208h], rbx                                                ; +0x1aa, 0x1403a595a\njnz     short loc_1403A596E                                            ; +0x1b1, 0x1403a5961\nmov     qword ptr [rax+208h], 0                                        ; +0x1b3, 0x1403a5963\nmov     rax, cs:qword_1406C2E88                                        ; +0x1be, 0x1403a596e\ntest    rax, rax                                                       ; +0x1c5, 0x1403a5975\njnz     short loc_1403A59A3                                            ; +0x1c8, 0x1403a5978\nmov     ecx, 888h; Size                                                ; +0x1ca, 0x1403a597a\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x1cf, 0x1403a597f\nmov     rcx, rax                                                       ; +0x1d4, 0x1403a5984\ncall    FMODAudioEngine__FMODAudioEngine                               ; +0x1d7, 0x1403a5987\nmov     cs:qword_1406C2E88, rax                                        ; +0x1dc, 0x1403a598c\nmov     rdx, [rax]                                                     ; +0x1e3, 0x1403a5993\nmov     rcx, rax                                                       ; +0x1e6, 0x1403a5996\ncall    qword ptr [rdx+48h]                                            ; +0x1e9, 0x1403a5999\nmov     rax, cs:qword_1406C2E88                                        ; +0x1ec, 0x1403a599c\nmov     byte ptr [rax+220h], 0                                         ; +0x1f3, 0x1403a59a3\ncall    cs:?sharedDirector@CCDirector@cocos2d@@SAPEAV12@XZ; cocos2d::CCDirector::sharedDirector(void) ; +0x1fa, 0x1403a59aa\nmov     rdx, [rax]                                                     ; +0x200, 0x1403a59b0\nmov     rcx, rax                                                       ; +0x203, 0x1403a59b3\ncall    qword ptr [rdx+0B0h]                                           ; +0x206, 0x1403a59b6\nmov     byte ptr [rax+5Ch], 0                                          ; +0x20c, 0x1403a59bc\nlea     rcx, [rbx+3A48h]                                               ; +0x210, 0x1403a59c0\ncall    sub_14005E430                                                  ; +0x217, 0x1403a59c7\nlea     rcx, [rbx+3A30h]                                               ; +0x21c, 0x1403a59cc\ncall    sub_14005E430                                                  ; +0x223, 0x1403a59d3\nlea     rcx, [rbx+3A18h]                                               ; +0x228, 0x1403a59d8\ncall    sub_1403BB610                                                  ; +0x22f, 0x1403a59df\nlea     rcx, [rbx+3948h]                                               ; +0x234, 0x1403a59e4\ncall    sub_14005D100                                                  ; +0x23b, 0x1403a59eb\nlea     rcx, [rbx+3938h]                                               ; +0x240, 0x1403a59f0\ncall    sub_14005D870                                                  ; +0x247, 0x1403a59f7\nlea     rcx, [rbx+3838h]                                               ; +0x24c, 0x1403a59fc\ncall    sub_1403BB6B0                                                  ; +0x253, 0x1403a5a03\nlea     rcx, [rbx+3820h]                                               ; +0x258, 0x1403a5a08\ncall    sub_14005D100                                                  ; +0x25f, 0x1403a5a0f\nlea     rcx, [rbx+3808h]                                               ; +0x264, 0x1403a5a14\ncall    sub_14005D100                                                  ; +0x26b, 0x1403a5a1b\nlea     rcx, [rbx+37F0h]                                               ; +0x270, 0x1403a5a20\ncall    sub_14005D100                                                  ; +0x277, 0x1403a5a27\nlea     rcx, [rbx+37C8h]                                               ; +0x27c, 0x1403a5a2c\ncall    sub_140069BA0                                                  ; +0x283, 0x1403a5a33\nmov     rcx, rbx                                                       ; +0x288, 0x1403a5a38\nadd     rsp, 20h                                                       ; +0x28b, 0x1403a5a3b\npop     rbx                                                            ; +0x28f, 0x1403a5a3f\njmp     GJBaseGameLayer__dGJBaseGameLayer                              ; +0x290, 0x1403a5a40", "xrefs": ["sub_1403A50E0 @ 0x1403a50ef", "<???> @ 0x1406d6b30"], "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"}