//
// SecretLayer5::showDialog from 0x6e4468 to 0x6e48c4 (1116 bytes)
//
// 0 xrefs:
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:57:23 +0000
//
unsigned int __fastcall SecretLayer5::showDialog(SecretLayer5 *this, int a2)
{
int v3; // r5
unsigned int result; // r0
cocos2d::CCArray *v5; // r4
cocos2d::CCObject *v6; // r0
cocos2d::CCObject *v7; // r0
cocos2d::CCObject *v8; // r0
cocos2d::CCObject *v9; // r0
cocos2d::CCObject *v10; // r0
cocos2d::CCObject *v11; // r0
cocos2d::CCObject *v12; // r0
cocos2d::CCObject *v13; // r0
cocos2d::CCObject *v14; // r0
cocos2d::CCObject *v15; // r0
int v16; // r2
cocos2d::CCLayerColor *v17; // r0
cocos2d::CCDirector *v18; // r4
int v19; // [sp+4h] [bp-24h]
int v20; // [sp+4h] [bp-24h]
int v21; // [sp+4h] [bp-24h]
int v22; // [sp+4h] [bp-24h]
int v23; // [sp+4h] [bp-24h]
int v24; // [sp+4h] [bp-24h]
int v25; // [sp+Ch] [bp-1Ch] BYREF
int v26; // [sp+10h] [bp-18h]
int v27; // [sp+14h] [bp-14h]
int v28; // [sp+18h] [bp-10h] BYREF
int v29; // [sp+1Ch] [bp-Ch]
int v30; // [sp+20h] [bp-8h]
v3 = a2 - 1;
result = cocos2d::CCArray::create(this);
v5 = (cocos2d::CCArray *)result;
switch ( v3 )
{
case 0:
v25 = 0;
v26 = 0;
v27 = 0;
std::string::__init(&v25, "The Gatekeeper", 0xEu);
v28 = 0;
v29 = 0;
v30 = 0;
std::string::__init(&v28, "This is random message 1", 0x18u);
LOWORD(v19) = -1;
BYTE2(v19) = -1;
v6 = (cocos2d::CCObject *)DialogObject::create((int)&v25, (int)&v28, 3, 1065353216, 1, v19);
cocos2d::CCArray::addObject(v5, v6);
std::string::~string((int)&v28);
std::string::~string((int)&v25);
v25 = 0;
v26 = 0;
v27 = 0;
std::string::__init(&v25, "The Gatekeeper", 0xEu);
v28 = 0;
v29 = 0;
v30 = 0;
std::string::__init(&v28, "Random message 1 end", 0x14u);
LOWORD(v20) = -1;
BYTE2(v20) = -1;
v7 = (cocos2d::CCObject *)DialogObject::create((int)&v25, (int)&v28, 3, 1065353216, 0, v20);
cocos2d::CCArray::addObject(v5, v7);
goto LABEL_7;
case 1:
v25 = 0;
v26 = 0;
v27 = 0;
std::string::__init(&v25, "The Gatekeeper", 0xEu);
v28 = 0;
v29 = 0;
v30 = 0;
std::string::__init(&v28, "This is random message 2", 0x18u);
LOWORD(v19) = -1;
BYTE2(v19) = -1;
v8 = (cocos2d::CCObject *)DialogObject::create((int)&v25, (int)&v28, 3, 1065353216, 1, v19);
cocos2d::CCArray::addObject(v5, v8);
std::string::~string((int)&v28);
std::string::~string((int)&v25);
v25 = 0;
v26 = 0;
v27 = 0;
std::string::__init(&v25, "The Gatekeeper", 0xEu);
v28 = 0;
v29 = 0;
v30 = 0;
std::string::__init(&v28, "Random message 2 end", 0x14u);
LOWORD(v21) = -1;
BYTE2(v21) = -1;
v9 = (cocos2d::CCObject *)DialogObject::create((int)&v25, (int)&v28, 3, 1065353216, 0, v21);
cocos2d::CCArray::addObject(v5, v9);
goto LABEL_7;
case 2:
v25 = 0;
v26 = 0;
v27 = 0;
std::string::__init(&v25, "The Gatekeeper", 0xEu);
v28 = 0;
v29 = 0;
v30 = 0;
std::string::__init(&v28, "This is random message 3", 0x18u);
LOWORD(v19) = -1;
BYTE2(v19) = -1;
v10 = (cocos2d::CCObject *)DialogObject::create((int)&v25, (int)&v28, 3, 1065353216, 1, v19);
cocos2d::CCArray::addObject(v5, v10);
std::string::~string((int)&v28);
std::string::~string((int)&v25);
v25 = 0;
v26 = 0;
v27 = 0;
std::string::__init(&v25, "The Gatekeeper", 0xEu);
v28 = 0;
v29 = 0;
v30 = 0;
std::string::__init(&v28, "Random message 3 end", 0x14u);
LOWORD(v22) = -1;
BYTE2(v22) = -1;
v11 = (cocos2d::CCObject *)DialogObject::create((int)&v25, (int)&v28, 3, 1065353216, 0, v22);
cocos2d::CCArray::addObject(v5, v11);
goto LABEL_7;
case 3:
v25 = 0;
v26 = 0;
v27 = 0;
std::string::__init(&v25, "The Gatekeeper", 0xEu);
v28 = 0;
v29 = 0;
v30 = 0;
std::string::__init(&v28, "This is random message 4", 0x18u);
LOWORD(v19) = -1;
BYTE2(v19) = -1;
v12 = (cocos2d::CCObject *)DialogObject::create((int)&v25, (int)&v28, 3, 1065353216, 1, v19);
cocos2d::CCArray::addObject(v5, v12);
std::string::~string((int)&v28);
std::string::~string((int)&v25);
v25 = 0;
v26 = 0;
v27 = 0;
std::string::__init(&v25, "The Gatekeeper", 0xEu);
v28 = 0;
v29 = 0;
v30 = 0;
std::string::__init(&v28, "Random message 4 end", 0x14u);
LOWORD(v23) = -1;
BYTE2(v23) = -1;
v13 = (cocos2d::CCObject *)DialogObject::create((int)&v25, (int)&v28, 3, 1065353216, 0, v23);
cocos2d::CCArray::addObject(v5, v13);
goto LABEL_7;
case 4:
v25 = 0;
v26 = 0;
v27 = 0;
std::string::__init(&v25, "The Gatekeeper", 0xEu);
v28 = 0;
v29 = 0;
v30 = 0;
std::string::__init(&v28, "This is random message 5", 0x18u);
LOWORD(v19) = -1;
BYTE2(v19) = -1;
v14 = (cocos2d::CCObject *)DialogObject::create((int)&v25, (int)&v28, 3, 1065353216, 1, v19);
cocos2d::CCArray::addObject(v5, v14);
std::string::~string((int)&v28);
std::string::~string((int)&v25);
v25 = 0;
v26 = 0;
v27 = 0;
std::string::__init(&v25, "The Gatekeeper", 0xEu);
v28 = 0;
v29 = 0;
v30 = 0;
std::string::__init(&v28, "Random message 5 end", 0x14u);
LOWORD(v24) = -1;
BYTE2(v24) = -1;
v15 = (cocos2d::CCObject *)DialogObject::create((int)&v25, (int)&v28, 3, 1065353216, 0, v24);
cocos2d::CCArray::addObject(v5, v15);
LABEL_7:
std::string::~string((int)&v28);
std::string::~string((int)&v25);
v17 = DialogLayer::createWithObjects(v5, (cocos2d::CCArray *)((char *)&dword_0 + 2), v16);
*((_DWORD *)v17 + 122) = (char *)this + 324;
v18 = v17;
(*(void (__fastcall **)(SecretLayer5 *, cocos2d::CCLayerColor *, int))(*(_DWORD *)this + 232))(this, v17, 100);
DialogLayer::updateChatPlacement(v18, 0);
result = DialogLayer::animateIn(v18, 2u);
break;
default:
return result;
}
return result;
}