{"type": "func", "start": 5371953856, "end": 5371954156, "name": "LevelSelectLayer::scene", "pseudocode": "// \n// LevelSelectLayer::scene from 0x1403182c0 to 0x1403183ec (300 bytes)\n// \n// 5 xrefs:\n// > GameManager::returnToLastScene @ 0x14018a05e\n// > LevelAreaLayer::onBack @ 0x1402c632d\n// > MenuLayer::onPlay @ 0x140335a2b\n// > SecretLayer4::onBack @ 0x1403f36e2\n// > <???> @ 0x1406d4a18\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\n// local variable allocation has failed, the output may be wrong!\n// Hidden C++ exception states: #wind=1\ncocos2d::CCScene *LevelSelectLayer::scene(int a1)\n{\n  cocos2d::CCScene *v2; // rsi\n  __int64 v3; // rdx\n  __int64 v4; // rcx\n  LevelSelectLayer *v5; // rdi\n\n  v2 = (cocos2d::CCScene *)cocos2d::CCScene::create(*(_QWORD *)&a1);\n  *(_QWORD *)(cocos2d::CCApplication::sharedApplication(v4, v3) + 224) = v2;\n  v5 = (LevelSelectLayer *)operator new(0x1D8u);\n  cocos2d::CCLayer::CCLayer(v5);\n  v5->cocos2d::CCLayer::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable = (LevelSelectLayer_vtbl *)&LevelSelectLayer::`vftable';\n  v5->cocos2d::CCLayer::cocos2d::CCTouchDelegate::__vftable = (cocos2d::CCTouchDelegate_vtbl *)&LevelSelectLayer::`vftable';\n  v5->cocos2d::CCLayer::cocos2d::CCAccelerometerDelegate::__vftable = (cocos2d::CCAccelerometerDelegate_vtbl *)&LevelSelectLayer::`vftable';\n  v5->cocos2d::CCLayer::cocos2d::CCKeypadDelegate::__vftable = (cocos2d::CCKeypadDelegate_vtbl *)&LevelSelectLayer::`vftable';\n  v5->cocos2d::CCLayer::cocos2d::CCKeyboardDelegate::__vftable = (cocos2d::CCKeyboardDelegate_vtbl *)&LevelSelectLayer::`vftable';\n  v5->cocos2d::CCLayer::cocos2d::CCMouseDelegate::__vftable = (cocos2d::CCMouseDelegate_vtbl *)&LevelSelectLayer::`vftable';\n  v5->BoomScrollLayerDelegate::__vftable = (BoomScrollLayerDelegate_vtbl *)&LevelSelectLayer::`vftable';\n  v5->DynamicScrollDelegate::__vftable = (DynamicScrollDelegate_vtbl *)&LevelSelectLayer::`vftable';\n  v5->m_width = 0.0;\n  v5->m_backgroundSprite = nullptr;\n  v5->m_groundLayer = nullptr;\n  v5->m_scrollLayer = nullptr;\n  *(_QWORD *)&v5->m_unknown = 0;\n  v5->m_masterDetectiveUnlocked = 0;\n  if ( LevelSelectLayer::init(v5, a1) )\n  {\n    cocos2d::CCObject::autorelease(v5);\n  }\n  else\n  {\n    ((void (__fastcall *)(LevelSelectLayer *, __int64))v5->~LevelSelectLayer)(v5, 1);\n    v5 = nullptr;\n  }\n  v2->addChild_1(v2, v5);\n  return v2;\n}", "assembly": "; \n; LevelSelectLayer::scene from 0x1403182c0 to 0x1403183ec (300 bytes)\n; \n; 5 xrefs:\n; > GameManager::returnToLastScene @ 0x14018a05e\n; > LevelAreaLayer::onBack @ 0x1402c632d\n; > MenuLayer::onPlay @ 0x140335a2b\n; > SecretLayer4::onBack @ 0x1403f36e2\n; > <???> @ 0x1406d4a18\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\nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x1403182c0\nmov     [rsp+arg_10], rbp                                              ; +0x5, 0x1403182c5\nmov     [rsp+arg_18], rsi                                              ; +0xa, 0x1403182ca\npush    rdi                                                            ; +0xf, 0x1403182cf\nsub     rsp, 20h                                                       ; +0x10, 0x1403182d0\nmov     ebx, ecx                                                       ; +0x14, 0x1403182d4\ncall    cs:?create@CCScene@cocos2d@@SAPEAV12@XZ; cocos2d::CCScene::create(void) ; +0x16, 0x1403182d6\nmov     rsi, rax                                                       ; +0x1c, 0x1403182dc\ncall    cs:?sharedApplication@CCApplication@cocos2d@@SAPEAV12@XZ; cocos2d::CCApplication::sharedApplication(void) ; +0x1f, 0x1403182df\nmov     [rax+0E0h], rsi                                                ; +0x25, 0x1403182e5\nmov     ecx, 1D8h; Size                                                ; +0x2c, 0x1403182ec\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x31, 0x1403182f1\nmov     rdi, rax                                                       ; +0x36, 0x1403182f6\nmov     [rsp+28h+arg_8], rax                                           ; +0x39, 0x1403182f9\nmov     rcx, rax                                                       ; +0x3e, 0x1403182fe\ncall    cs:??0CCLayer@cocos2d@@QEAA@XZ; cocos2d::CCLayer::CCLayer(void) ; +0x41, 0x140318301\nlea     rax, ??_7LevelSelectLayer@@6B@; const LevelSelectLayer::`vftable' ; +0x47, 0x140318307\nmov     [rdi], rax                                                     ; +0x4e, 0x14031830e\nlea     rax, ??_7LevelSelectLayer@@6B@_0; const LevelSelectLayer::`vftable' ; +0x51, 0x140318311\nmov     [rdi+140h], rax                                                ; +0x58, 0x140318318\nlea     rax, ??_7LevelSelectLayer@@6B@_1; const LevelSelectLayer::`vftable' ; +0x5f, 0x14031831f\nmov     [rdi+148h], rax                                                ; +0x66, 0x140318326\nlea     rax, ??_7LevelSelectLayer@@6B@_2; const LevelSelectLayer::`vftable' ; +0x6d, 0x14031832d\nmov     [rdi+150h], rax                                                ; +0x74, 0x140318334\nlea     rax, ??_7LevelSelectLayer@@6B@_3; const LevelSelectLayer::`vftable' ; +0x7b, 0x14031833b\nmov     [rdi+158h], rax                                                ; +0x82, 0x140318342\nlea     rax, ??_7LevelSelectLayer@@6B@_4; const LevelSelectLayer::`vftable' ; +0x89, 0x140318349\nmov     [rdi+160h], rax                                                ; +0x90, 0x140318350\nlea     rax, ??_7LevelSelectLayer@@6B@_5; const LevelSelectLayer::`vftable' ; +0x97, 0x140318357\nmov     [rdi+198h], rax                                                ; +0x9e, 0x14031835e\nlea     rax, ??_7LevelSelectLayer@@6B@_6; const LevelSelectLayer::`vftable' ; +0xa5, 0x140318365\nmov     [rdi+1A0h], rax                                                ; +0xac, 0x14031836c\nxor     ebp, ebp                                                       ; +0xb3, 0x140318373\nmov     [rdi+1A8h], ebp                                                ; +0xb5, 0x140318375\nmov     [rdi+1B0h], rbp                                                ; +0xbb, 0x14031837b\nmov     [rdi+1B8h], rbp                                                ; +0xc2, 0x140318382\nmov     [rdi+1C0h], rbp                                                ; +0xc9, 0x140318389\nmov     [rdi+1C8h], rbp                                                ; +0xd0, 0x140318390\nmov     [rdi+1D0h], bpl                                                ; +0xd7, 0x140318397\nmov     edx, ebx                                                       ; +0xde, 0x14031839e\nmov     rcx, rdi                                                       ; +0xe0, 0x1403183a0\ncall    LevelSelectLayer__init                                         ; +0xe3, 0x1403183a3\nmov     rcx, rdi                                                       ; +0xe8, 0x1403183a8\ntest    al, al                                                         ; +0xeb, 0x1403183ab\njz      short loc_1403183B7                                            ; +0xed, 0x1403183ad\ncall    cs:?autorelease@CCObject@cocos2d@@QEAAPEAV12@XZ; cocos2d::CCObject::autorelease(void) ; +0xef, 0x1403183af\njmp     short loc_1403183C5                                            ; +0xf5, 0x1403183b5\nmov     rax, [rdi]                                                     ; +0xf7, 0x1403183b7\nmov     edx, 1                                                         ; +0xfa, 0x1403183ba\ncall    qword ptr [rax+8]                                              ; +0xff, 0x1403183bf\nmov     rdi, rbp                                                       ; +0x102, 0x1403183c2\nmov     rax, [rsi]                                                     ; +0x105, 0x1403183c5\nmov     rdx, rdi                                                       ; +0x108, 0x1403183c8\nmov     rcx, rsi                                                       ; +0x10b, 0x1403183cb\ncall    qword ptr [rax+1C0h]                                           ; +0x10e, 0x1403183ce\nmov     rax, rsi                                                       ; +0x114, 0x1403183d4\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x117, 0x1403183d7\nmov     rbp, [rsp+28h+arg_10]                                          ; +0x11c, 0x1403183dc\nmov     rsi, [rsp+28h+arg_18]                                          ; +0x121, 0x1403183e1\nadd     rsp, 20h                                                       ; +0x126, 0x1403183e6\npop     rdi                                                            ; +0x12a, 0x1403183ea\nretn                                                                   ; +0x12b, 0x1403183eb", "xrefs": ["GameManager::returnToLastScene @ 0x14018a05e", "LevelAreaLayer::onBack @ 0x1402c632d", "MenuLayer::onPlay @ 0x140335a2b", "SecretLayer4::onBack @ 0x1403f36e2", "<???> @ 0x1406d4a18"], "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"}