//
// LoadingLayer::scene from 0x140468f70 to 0x14046907e (270 bytes)
//
// 3 xrefs:
// > AppDelegate::applicationDidFinishLaunching @ 0x140098535
// > GameManager::reloadAllStep5 @ 0x140287ba1
// > ??> @ 0x140927ff8
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:32:35 +0000
//
// Hidden C++ exception states: #wind=1
__int64 __fastcall LoadingLayer::scene(__int64 a1, __int64 a2, __int64 a3, __int64 a4)
{
unsigned __int8 v4; // bl
__int64 v5; // rsi
cocos2d::CCLayer *v6; // rdi
v4 = a1;
v5 = cocos2d::CCScene::create(a1, a2, a3, a4);
v6 = (cocos2d::CCLayer *)operator new(0x1C8u);
cocos2d::CCLayer::CCLayer(v6);
*(_QWORD *)v6 = &LoadingLayer::`vftable';
*((_QWORD *)v6 + 40) = &LoadingLayer::`vftable';
*((_QWORD *)v6 + 41) = &LoadingLayer::`vftable';
*((_QWORD *)v6 + 42) = &LoadingLayer::`vftable';
*((_QWORD *)v6 + 43) = &LoadingLayer::`vftable';
*((_QWORD *)v6 + 44) = &LoadingLayer::`vftable';
*((_WORD *)v6 + 204) = 0;
*((_DWORD *)v6 + 103) = 0;
*((_QWORD *)v6 + 52) = 0;
*((_QWORD *)v6 + 53) = 0;
*((_QWORD *)v6 + 54) = 0;
*((_QWORD *)v6 + 55) = 0;
*((_BYTE *)v6 + 448) = 0;
if ( (unsigned __int8)LoadingLayer::init(v6, v4) )
{
cocos2d::CCObject::autorelease(v6);
}
else
{
(*(void (__fastcall **)(cocos2d::CCLayer *, __int64))(*(_QWORD *)v6 + 8LL))(v6, 1);
v6 = nullptr;
}
(*(void (__fastcall **)(__int64, cocos2d::CCLayer *))(*(_QWORD *)v5 + 464LL))(v5, v6);
return v5;
}