// // SecretLayer2::onDoor from 0x4ede5c to 0x4edffa (414 bytes) // // 0 xrefs: // // This function is hookable on this platform! // // Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA // Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings // void SecretLayer2::onDoor(SecretLayer2 *a1, cocos2d::CCObject *a2) { GameManager *v3; // r0 cocos2d::CCDirector *v4; // r4 cocos2d::CCScene *v5; // r0 cocos2d::CCTransitionFade *v6; // r0 int m_doorDialogIndex; // r6 char *v8; // r1 DialogObject *v9; // r0 DialogLayer *v10; // r9 int v11; // [sp+4h] [bp-20h] _BYTE v12[4]; // [sp+10h] [bp-14h] BYREF char v13; // [sp+14h] [bp-10h] BYREF _BYTE v14[4]; // [sp+18h] [bp-Ch] BYREF v3 = GameManager::sharedState(); if ( GameManager::getUGV(v3, (const char *)&aO1i2r3e45s7t89[7]) ) { v4 = cocos2d::CCDirector::sharedDirector(); v5 = SecretLayer3::scene(); v6 = cocos2d::CCTransitionFade::create(0.5, v5); cocos2d::CCDirector::replaceScene(v4, v6); } else { sub_776584((int)v12, "Not allowed"); m_doorDialogIndex = a1->m_doorDialogIndex; if ( m_doorDialogIndex >= 0 ) { a1->m_doorDialogIndex = m_doorDialogIndex + 1; } else { rand(); a1->m_doorDialogIndex = lroundf(); } if ( a1->m_doorDialogIndex > 10 ) a1->m_doorDialogIndex = 0; switch ( a1->m_doorDialogIndex ) { case 0: v8 = "Sorry, I can't let you in."; goto LABEL_20; case 1: v8 = "Its too dangerous, just stay here."; goto LABEL_20; case 2: v8 = "Leave that alone..."; goto LABEL_20; case 3: v8 = "That area is off limits."; goto LABEL_20; case 4: v8 = "I keep that door locked.\nRubRub's orders."; goto LABEL_20; case 5: v8 = "I've only been down there once. Its pretty creepy."; goto LABEL_20; case 6: v8 = "Just forget about it."; goto LABEL_20; case 7: v8 = "Some things are best left alone."; goto LABEL_20; case 8: v8 = "Even I dont want to go down there."; goto LABEL_20; case 9: v8 = "Off. Limits."; goto LABEL_20; case 0xA: v8 = "Does the word locked mean nothing to you?"; LABEL_20: sub_7753D4((int)v12, v8); break; default: break; } sub_776584((int)&v13, "The Keymaster"); sub_775C20(v14); LOWORD(v11) = -1; BYTE2(v11) = -1; v9 = (DialogObject *)DialogObject::create( (DialogObject *)&v13, (std::string)v14, (std::string)2, 1065353216, 0.0, v11); v10 = DialogLayer::create(v9, (int)&dword_0 + 2); sub_774008(v14); sub_774008(&v13); a1->addChild_0(a1, v10, 100); DialogLayer::updateChatPlacement(v10, Center); DialogLayer::animateInRandomSide(v10); sub_774008(v12); } }
GD Web Decomp Icon

GD Web Decomp

Raw Source