//
// SecretLayer5::showFirstDialog from 0xbc5fdc to 0xbc63cc (1008 bytes)
//
// 3 xrefs:
// > ??> @ 0x6f088
// > SecretLayer5::init @ 0xbc8bb4
// > ??> @ 0x1542c48
//
// This function is hookable on this platform (idp: arm, 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 13:03:32 +0000
//
__int64 __fastcall SecretLayer5::showFirstDialog(SecretLayer5 *this)
{
GameManager *v2; // x0
cocos2d::CCArray *v3; // x0
cocos2d::CCArray *v4; // x21
cocos2d::CCObject *v5; // x0
cocos2d::CCObject *v6; // x0
cocos2d::CCObject *v7; // x0
cocos2d::CCObject *v8; // x0
cocos2d::CCObject *v9; // x0
cocos2d::CCNode *v10; // x19
__int64 v12; // [xsp+58h] [xbp+58h] BYREF
__int64 v13; // [xsp+60h] [xbp+60h]
void *v14; // [xsp+68h] [xbp+68h]
__int64 v15; // [xsp+70h] [xbp+70h] BYREF
__int64 v16; // [xsp+78h] [xbp+78h]
void *v17; // [xsp+80h] [xbp+80h]
v2 = (GameManager *)GameManager::sharedState(_stack_chk_guard);
v3 = (cocos2d::CCArray *)GameManager::setUGV(v2, "38", 1u);
v4 = (cocos2d::CCArray *)cocos2d::CCArray::create(v3);
v12 = 0;
v13 = 0;
v14 = nullptr;
std::string::__init(&v12, "The Wraith", 0xAu);
v15 = 0;
v16 = 0;
v17 = nullptr;
std::string::__init(
&v15,
"Great... Just what I needed.\nAnother visitor to my prison.",
0x56u);
v5 = (cocos2d::CCObject *)DialogObject::create((char *)&v12, (char *)&v15, 54, 1, 0xFFFFFF, 1.0);
cocos2d::CCArray::addObject(v4, v5);
if ( (v15 & 1) != 0 )
operator delete(v17);
if ( (v12 & 1) != 0 )
operator delete(v14);
v12 = 0;
v13 = 0;
v14 = nullptr;
std::string::__init(&v12, "The Wraith", 0xAu);
v15 = 0;
v16 = 0;
v17 = nullptr;
std::string::__init(
&v15,
"Must be my lucky day... or yours.\nI don't really have days anymore.",
0x5Fu);
v6 = (cocos2d::CCObject *)DialogObject::create((char *)&v12, (char *)&v15, 53, 0, 0xFFFFFF, 1.0);
cocos2d::CCArray::addObject(v4, v6);
if ( (v15 & 1) != 0 )
operator delete(v17);
if ( (v12 & 1) != 0 )
operator delete(v14);
v12 = 0;
v13 = 0;
v14 = nullptr;
std::string::__init(&v12, "The Wraith", 0xAu);
v15 = 0;
v16 = 0;
v17 = nullptr;
std::string::__init(
&v15,
"I wasn't always like this, you know.\n"
"I used to be something, greater...",
0x73u);
v7 = (cocos2d::CCObject *)DialogObject::create((char *)&v12, (char *)&v15, 55, 0, 0xFFFFFF, 1.0);
cocos2d::CCArray::addObject(v4, v7);
if ( (v15 & 1) != 0 )
operator delete(v17);
if ( (v12 & 1) != 0 )
operator delete(v14);
v12 = 0;
v13 = 0;
v14 = nullptr;
std::string::__init(&v12, "The Wraith", 0xAu);
v15 = 0;
v16 = 0;
v17 = nullptr;
std::string::__init(&v15, "Now instead, I get to listen to you.\nWhat a treat...", 0x48u);
v8 = (cocos2d::CCObject *)DialogObject::create((char *)&v12, (char *)&v15, 53, 0, 0xFFFFFF, 1.0);
cocos2d::CCArray::addObject(v4, v8);
if ( (v15 & 1) != 0 )
operator delete(v17);
if ( (v12 & 1) != 0 )
operator delete(v14);
v12 = 0;
v13 = 0;
v14 = nullptr;
std::string::__init(&v12, "The Wraith", 0xAu);
v15 = 0;
v16 = 0;
v17 = nullptr;
std::string::__init(&v15, "Go on, or don't.\nNot like I can stop you.", 0x45u);
v9 = (cocos2d::CCObject *)DialogObject::create((char *)&v12, (char *)&v15, 56, 0, 0xFFFFFF, 1.0);
cocos2d::CCArray::addObject(v4, v9);
if ( (v15 & 1) != 0 )
operator delete(v17);
if ( (v12 & 1) != 0 )
operator delete(v14);
v10 = (cocos2d::CCNode *)DialogLayer::createWithObjects(v4, (cocos2d::CCArray *)byte_4);
(*(void (__fastcall **)(SecretLayer5 *, cocos2d::CCNode *, __int64))(*(_QWORD *)this + 464LL))(this, v10, 100);
DialogLayer::updateChatPlacement((__int64)v10, 0);
DialogLayer::animateIn(v10, 2u);
*((_BYTE *)this + 544) = 0;
(*(void (__fastcall **)(_QWORD, __int64))(**((_QWORD **)this + 58) + 1000LL))(*((_QWORD *)this + 58), 1);
return _stack_chk_guard;
}