// // CreatorLayer::onSecretVault from 0x7dc2f8 to 0x7dc618 (800 bytes) // // 3 xrefs: // > @ 0x94c18 // > CreatorLayer::init @ 0x7dd12c // > @ 0x1544058 // // 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 12:54:24 +0000 // __int64 __fastcall CreatorLayer::onSecretVault(CreatorLayer *this, cocos2d::CCObject *a2) { GameStatsManager *v3; // x0 cocos2d::CCDirector *Stat; // x0 char v5; // cf char v6; // zf int v7; // w0 unsigned int v8; // w0 DialogLayer *v9; // x0 int v10; // w2 DialogLayer *v11; // x21 SecretLayer2 *v13; // x20 cocos2d::CCTransitionFade *v14; // x0 cocos2d::CCScene *v15; // x1 cocos2d::CCScene *v16; // x0 __int64 v17; // [xsp+30h] [xbp+30h] BYREF size_t v18; // [xsp+38h] [xbp+38h] void *v19; // [xsp+40h] [xbp+40h] __int64 v20[2]; // [xsp+48h] [xbp+48h] BYREF void *v21; // [xsp+58h] [xbp+58h] __int64 v22; // [xsp+60h] [xbp+60h] BYREF size_t v23; // [xsp+68h] [xbp+68h] void *v24; // [xsp+70h] [xbp+70h] v3 = (GameStatsManager *)GameStatsManager::sharedState(_stack_chk_guard); Stat = (cocos2d::CCDirector *)GameStatsManager::getStat(v3, "13"); if ( (int)Stat > 49 ) { v13 = (SecretLayer2 *)cocos2d::CCDirector::sharedDirector(Stat); v14 = (cocos2d::CCTransitionFade *)SecretLayer2::scene(v13); v16 = (cocos2d::CCScene *)cocos2d::CCTransitionFade::create(v14, 0.5, v15); cocos2d::CCDirector::replaceScene(v13, v16); } else { v17 = 0; v18 = 0; v19 = nullptr; std::string::__init(&v17, "zzz", 3u); v7 = *((_DWORD *)this + 120); if ( v7 < 0 ) v8 = llroundf((float)((float)rand() * 4.6566e-10) * 10.0); else v8 = v7 + 1; *((_DWORD *)this + 120) = v8; if ( !(!v6 & v5) ) { switch ( v8 ) { case 0u: goto LABEL_5; case 1u: std::string::assign(&v17, "I can't let you in."); break; case 2u: std::string::assign(&v17, "Player used knock.\nIt's not very effective."); break; case 3u: std::string::assign(&v17, "Don't you have something better to do?"); break; case 4u: std::string::assign(&v17, "That is a bad idea..."); break; case 5u: std::string::assign(&v17, "..."); break; case 6u: std::string::assign(&v17, "I guess you don't like rules..."); break; case 7u: std::string::assign(&v17, "RubRub told me not to let anyone in."); break; case 8u: std::string::assign(&v17, "This is not the door you are looking for."); break; case 9u: std::string::assign(&v17, "I don't understand why you keep clicking..."); break; case 0xAu: std::string::assign(&v17, "Trust me, you don't want to come in here."); break; default: *((_DWORD *)this + 120) = 0; LABEL_5: std::string::assign(&v17, "You are not ready..."); break; } } v20[0] = 0; v20[1] = 0; v21 = nullptr; std::string::__init(v20, "The Keymaster", 0xDu); v22 = 0; v23 = 0; v24 = nullptr; if ( (v17 & 1) != 0 ) { std::string::__init(&v22, v19, v18); } else { v22 = v17; v23 = v18; v24 = v19; } v9 = (DialogLayer *)DialogObject::create(v20, &v22, 2, 0, 0xFFFFFF, 1.0); v11 = (DialogLayer *)DialogLayer::create(v9, (DialogObject *)((char *)&dword_0 + 2), v10); if ( (v22 & 1) != 0 ) operator delete(v24); if ( (v20[0] & 1) != 0 ) operator delete(v21); (*(void (__fastcall **)(CreatorLayer *, DialogLayer *, __int64))(*(_QWORD *)this + 464LL))(this, v11, 100); DialogLayer::updateChatPlacement(v11, 0); DialogLayer::animateInRandomSide(v11); if ( (v17 & 1) != 0 ) operator delete(v19); } return _stack_chk_guard; }