// // SupportLayer::customSetup from 0x7dd2cc to 0x7ddc70 (2468 bytes) // // 2 xrefs: // > @ 0x54fc0 // > @ 0x1181858 // // 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 SupportLayer::customSetup(SupportLayer *a1) { cocos2d::CCDirector *v2; // x0 const char *v3; // x6 cocos2d::CCNode *v4; // x0 CCMenuItemSpriteExtra *v5; // x27 const char *v6; // x6 cocos2d::CCNode *v7; // x0 CCMenuItemSpriteExtra *v8; // x26 const char *v9; // x6 cocos2d::CCNode *v10; // x0 CCMenuItemSpriteExtra *v11; // x25 const char *v12; // x6 cocos2d::CCNode *v13; // x0 CCMenuItemSpriteExtra *v14; // x24 const char *v15; // x6 cocos2d::CCNode *v16; // x0 CCMenuItemSpriteExtra *v17; // x22 cocos2d::CCNode *v18; // x21 void (__fastcall *v19)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x27 void (__fastcall *v20)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x26 void (__fastcall *v21)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x22 void (__fastcall *v22)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x22 void *v23; // x0 GJAccountManager *v24; // x0 const char *v25; // x6 cocos2d::CCNode *v26; // x0 CCMenuItemSpriteExtra *v27; // x25 void (__fastcall *v28)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x26 float v29; // s9 float v30; // s8 cocos2d::CCMenu *v31; // x21 cocos2d::CCSprite *v32; // x25 void (__fastcall *v33)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x24 cocos2d::CCSprite *v34; // x0 CCMenuItemSpriteExtra *v35; // x24 void (__fastcall *v36)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x27 __int64 v37; // x0 cocos2d::CCSprite *v38; // x24 cocos2d::CCSprite *v39; // x0 const cocos2d::CCPoint *(__fastcall *v40)(cocos2d::CCNode *__hidden); // x1 void (__fastcall *v41)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // x25 __int64 v42; // x0 cocos2d::CCSprite *v43; // x0 CCMenuItemSpriteExtra *v44; // x25 void (__fastcall *v45)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x27 __int64 v46; // x0 cocos2d::CCLabelBMFont *v47; // x22 cocos2d::CCSprite *v48; // x0 const cocos2d::CCPoint *(__fastcall *v49)(cocos2d::CCNode *__hidden); // x1 void (__fastcall *v50)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x24 __int64 v51; // x0 AchievementManager *v52; // x0 cocos2d::CCLabelBMFont *v53; // x22 void (__fastcall *v54)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x24 cocos2d::CCFadeTo *v55; // x0 GameStatsManager *v56; // x26 const char *v57; // x6 int isSpecialChestUnlocked; // w28 void *v59; // x0 cocos2d::CCNode *v60; // x0 CCMenuItemSpriteExtra *v61; // x24 CCMenuItemSpriteExtra *v62; // x0 const cocos2d::CCPoint *(__fastcall *getPosition)(cocos2d::CCNode *__hidden); // x1 void (__fastcall *v64)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x25 __int64 v65; // x27 unsigned int *v66; // x1 int v67; // w2 unsigned int *v68; // x1 int v69; // w2 void (__fastcall *setPosition)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // [xsp+88h] [xbp+88h] void (__fastcall *v71)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // [xsp+88h] [xbp+88h] float v72; // [xsp+B0h] [xbp+B0h] float v73; // [xsp+B4h] [xbp+B4h] cocos2d::CCPoint v74; // [xsp+B8h] [xbp+B8h] BYREF cocos2d::CCPoint v75; // [xsp+C0h] [xbp+C0h] BYREF cocos2d::CCPoint v76; // 0:kr08_8.8 cocos2d::CCPoint v77; // 0:kr10_8.8 cocos2d::CCPoint v78; // 0:kr18_8.8 cocos2d::SEL_MenuHandler v79; // 0:x2.16 cocos2d::SEL_MenuHandler v80; // 0:x2.16 cocos2d::SEL_MenuHandler v81; // 0:x2.16 cocos2d::SEL_MenuHandler v82; // 0:x2.16 cocos2d::SEL_MenuHandler v83; // 0:x2.16 cocos2d::SEL_MenuHandler v84; // 0:x2.16 cocos2d::SEL_MenuHandler v85; // 0:x2.16 cocos2d::SEL_MenuHandler v86; // 0:x2.16 cocos2d::SEL_MenuHandler v87; // 0:x2.16 v2 = cocos2d::CCDirector::sharedDirector(); cocos2d::CCDirector::getWinSize(v2); v4 = (cocos2d::CCNode *)ButtonSprite::create( (ButtonSprite *)"Links", (const char *)&dword_44 + 2, 0, 1, 0.5, "bigFont.fnt", "GJ_button_01.png", v3, 30.0); v79.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v79.adj = (size_t)SupportLayer::onLinks; v5 = CCMenuItemSpriteExtra::create(v4, nullptr, v79); v7 = (cocos2d::CCNode *)ButtonSprite::create( (ButtonSprite *)"Contact", (const char *)&dword_44 + 2, 0, 1, 0.5, "bigFont.fnt", "GJ_button_01.png", v6, 30.0); v80.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v80.adj = (size_t)SupportLayer::onEmail; v8 = CCMenuItemSpriteExtra::create(v7, nullptr, v80); v10 = (cocos2d::CCNode *)ButtonSprite::create( (ButtonSprite *)"Privacy", (const char *)&dword_44 + 2, 0, 1, 0.5, "bigFont.fnt", "GJ_button_01.png", v9, 30.0); v81.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v81.adj = (size_t)SupportLayer::onPrivacy; v11 = CCMenuItemSpriteExtra::create(v10, nullptr, v81); v13 = (cocos2d::CCNode *)ButtonSprite::create( (ButtonSprite *)"ToS", (const char *)&dword_44 + 2, 0, 1, 0.5, "bigFont.fnt", "GJ_button_01.png", v12, 30.0); v82.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v82.adj = (size_t)SupportLayer::onTOS; v14 = CCMenuItemSpriteExtra::create(v13, nullptr, v82); v16 = (cocos2d::CCNode *)ButtonSprite::create( (ButtonSprite *)"SFX", (const char *)&dword_44 + 2, 0, 1, 0.5, "bigFont.fnt", "GJ_button_01.png", v15, 30.0); v83.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v83.adj = (size_t)SupportLayer::onSFX; v17 = CCMenuItemSpriteExtra::create(v16, nullptr, v83); v18 = (cocos2d::CCNode *)cocos2d::CCMenu::create((cocos2d::CCMenu *)v5, v8, v11, v14, v17, 0); setPosition = v18->setPosition; cocos2d::CCPoint::CCPoint(&v75, v72 * 0.5, (float)(v73 * 0.5) + 60.0); setPosition(v18, &v75); v71 = v5->setPosition; cocos2d::CCPoint::CCPoint(&v75, -100.0, 20.0); v71(v5, &v75); v19 = v8->setPosition; cocos2d::CCPoint::CCPoint(&v75, 0.0, 20.0); v19(v8, &v75); v20 = v17->setPosition; cocos2d::CCPoint::CCPoint(&v75, 100.0, 20.0); v20(v17, &v75); v21 = v11->setPosition; cocos2d::CCPoint::CCPoint(&v75, -50.0, -20.0); v21(v11, &v75); v22 = v14->setPosition; cocos2d::CCPoint::CCPoint(&v75, 50.0, -20.0); v22(v14, &v75); sub_D153B8((int)&v75, "Low Detail Mode"); LOBYTE(v14) = !GameManager::sharedState()->m_performanceMode; cocos2d::CCPoint::CCPoint(&v74, (float)(v72 * 0.5) + -160.0, (float)(v73 * 0.5) + -90.0); SupportLayer::createToggleButton( (__int64)a1, (__int64)&v75, (void (__cdecl *)(cocos2d::CCObject *))SupportLayer::onLowDetail, 0, (bool)v14, v18, &v74, nullptr); v23 = (void *)(*(_QWORD *)&v75 - 24LL); if ( (__int64 *)(*(_QWORD *)&v75 - 24LL) != &qword_124B6B0 ) { if ( &pthread_create ) { v66 = (unsigned int *)(*(_QWORD *)&v75 - 8LL); do v67 = __ldaxr(v66); while ( __stlxr(v67 - 1, v66) ); } else { v67 = *(_DWORD *)(*(_QWORD *)&v75 - 8LL); *(_DWORD *)(*(_QWORD *)&v75 - 8LL) = v67 - 1; } if ( v67 <= 0 ) operator delete(v23); } v24 = GJAccountManager::sharedState(); if ( v24->m_accountID - v24->m_unkInt1 > 0 ) { v26 = (cocos2d::CCNode *)ButtonSprite::create( (ButtonSprite *)"Req", (const char *)&qword_D8 + 4, 0, 0, 0.4, "bigFont.fnt", "GJ_button_04.png", v25, 25.0); v84.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v84.adj = (size_t)SupportLayer::onRequestAccess; v27 = CCMenuItemSpriteExtra::create(v26, nullptr, v84); v18->addChild(v18, v27); v28 = v27->setPosition; cocos2d::CCPoint::CCPoint(&v74, (float)(v72 * 0.5) + 150.0, (float)(v73 * 0.5) + -90.0); v76 = cocos2d::CCNode::convertToNodeSpace(v18, &v74); ((void (__fastcall *)(CCMenuItemSpriteExtra *, cocos2d::CCPoint *, float, float))v28)(v27, &v75, v76.x, v76.y); if ( (float)((float)rand() * 4.6566e-10) > 0.9 ) { v56 = GameStatsManager::sharedState(); sub_D153B8((int)&v75, "0023"); isSpecialChestUnlocked = (unsigned __int8)GameStatsManager::isSpecialChestUnlocked((__int64)v56, (char **)&v75); v59 = (void *)(*(_QWORD *)&v75 - 24LL); if ( (__int64 *)(*(_QWORD *)&v75 - 24LL) != &qword_124B6B0 ) { if ( &pthread_create ) { v68 = (unsigned int *)(*(_QWORD *)&v75 - 8LL); do v69 = __ldaxr(v68); while ( __stlxr(v69 - 1, v68) ); } else { v69 = *(_DWORD *)(*(_QWORD *)&v75 - 8LL); *(_DWORD *)(*(_QWORD *)&v75 - 8LL) = v69 - 1; } if ( v69 <= 0 ) operator delete(v59); } if ( !isSpecialChestUnlocked ) { v60 = (cocos2d::CCNode *)ButtonSprite::create( (ButtonSprite *)"?", (const char *)&qword_D8 + 4, 0, 0, 0.6, "goldFont.fnt", "GJ_button_05.png", v57, 25.0); v87.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v87.adj = (size_t)SupportLayer::onGetReward; v61 = CCMenuItemSpriteExtra::create(v60, nullptr, v87); v18->addChild(v18, v61); v62 = v27; getPosition = v27->getPosition; v64 = v61->setPosition; v65 = (__int64)getPosition(v62); cocos2d::CCPoint::CCPoint(&v74, -50.0, 0.0); cocos2d::CCPoint::operator+(&v75, v65, &v74); v64(v61, &v75); } } } a1->m_mainLayer->addChild_0(a1->m_mainLayer, v18, 1); v29 = (float)(v72 * 0.5) + -55.0; v30 = (float)(v72 * 0.5) + 45.0; v31 = cocos2d::CCMenu::create(); v32 = cocos2d::CCSprite::createWithSpriteFrameName("developedBy_001.png"); a1->m_mainLayer->addChild(a1->m_mainLayer, v32); v33 = v32->setPosition; cocos2d::CCPoint::CCPoint(&v75, v29, (float)(v73 * 0.5) + 0.0); v33(v32, &v75); v34 = cocos2d::CCSprite::createWithSpriteFrameName("robtoplogo_small.png"); v85.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v85.adj = (size_t)SupportLayer::onRobTop; v35 = CCMenuItemSpriteExtra::create(v34, nullptr, v85); v31->addChild(v31, v35); v36 = v35->setPosition; v37 = (__int64)v32->getPosition(v32); cocos2d::CCPoint::CCPoint(&v74, v30, *(float *)(v37 + 4)); v77 = cocos2d::CCNode::convertToNodeSpace(v31, &v74); ((void (__fastcall *)(CCMenuItemSpriteExtra *, cocos2d::CCPoint *, float, float))v36)(v35, &v75, v77.x, v77.y); v38 = cocos2d::CCSprite::createWithSpriteFrameName("poweredBy_001.png"); a1->m_mainLayer->addChild(a1->m_mainLayer, v38); v39 = v32; v40 = v32->getPosition; v41 = v38->setPosition; v42 = (__int64)v40(v39); cocos2d::CCPoint::CCPoint(&v75, v29, *(float *)(v42 + 4) - 35.0); v41(v38, &v75); v43 = cocos2d::CCSprite::createWithSpriteFrameName("cocos2DxLogo.png"); v86.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v86.adj = (size_t)SupportLayer::onCocos2d; v44 = CCMenuItemSpriteExtra::create(v43, nullptr, v86); v31->addChild(v31, v44); v45 = v44->setPosition; v46 = (__int64)v38->getPosition(v38); cocos2d::CCPoint::CCPoint(&v74, v30, *(float *)(v46 + 4)); v78 = cocos2d::CCNode::convertToNodeSpace(v31, &v74); ((void (__fastcall *)(CCMenuItemSpriteExtra *, cocos2d::CCPoint *, float, float))v45)(v44, &v75, v78.x, v78.y); v47 = cocos2d::CCLabelBMFont::create(); v47->setScale(v47, 0.35); a1->m_mainLayer->addChild(a1->m_mainLayer, v47); v48 = v38; v49 = v38->getPosition; v50 = v47->setPosition; v51 = (__int64)v49(v48); cocos2d::CCPoint::CCPoint(&v75, v72 * 0.5, *(float *)(v51 + 4) - 26.0); v50(v47, &v75); v52 = AchievementManager::sharedState(); if ( !AchievementManager::isAchievementEarned(v52, "geometry.ach.secret08") ) { v53 = cocos2d::CCLabelBMFont::create(); a1->addChild_0(a1, v53, 3); v53->setScale(v53, 0.5); v53->setColor(v53, (const cocos2d::ccColor3B *)&off_ED3570); v53->setOpacity(v53, 0); v54 = v53->setPosition; cocos2d::CCPoint::CCPoint(&v75, v72 - 32.0, 8.0); v54(v53, &v75); v55 = cocos2d::CCFadeTo::create(10.0, (unsigned __int8)&qword_60 + 4); cocos2d::CCNode::runAction(v53, v55); } a1->m_mainLayer->addChild_0(a1->m_mainLayer, v31, 2); }
GD Web Decomp Icon

GD Web Decomp

Raw Source