// // EditLevelLayer::setupLevelInfo from 0x1001fc3b0 to 0x1001fcb17 (1895 bytes) // // 1 xrefs: // > EditLevelLayer::init @ 0x1001fb350 // // 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 __fastcall EditLevelLayer::setupLevelInfo(EditLevelLayer *a1) { cocos2d::CCDirector *v2; // rsi cocos2d::CCArray *v3; // r14 cocos2d::CCNode *v4; // r15 cocos2d::CCNode *v5; // r12 cocos2d::CCNode *v6; // r13 cocos2d::CCSprite *v7; // rsi cocos2d::CCNode_vtbl *v8; // rax cocos2d::CCSprite *v9; // rsi cocos2d::CCNode_vtbl *v10; // rax cocos2d::CCSprite *v11; // rsi cocos2d::CCNode_vtbl *v12; // rax const char *data; // rdi cocos2d::CCLabelBMFont *v14; // r12 const char *v15; // rdi cocos2d::CCLabelBMFont *v16; // r13 GJGameLevel *m_level; // rax const std::string::value_type *v18; // rsi const char *v19; // rdi __int64 v20; // r15 cocos2d::CCDirector *v21; // rax double v22; // xmm0_8 cocos2d::CCString *v23; // rax const char *CString; // rax cocos2d::CCLabelBMFont *v25; // r14 GJGameLevel *v26; // rcx const char *v27; // rax cocos2d::CCString *v28; // rax cocos2d::CCString *v29; // rax cocos2d::CCLabelBMFont *v30; // r15 cocos2d::CCDirector *v31; // rax double v32; // xmm0_8 float *v33; // rax GJGameLevel *v34; // rax char v35; // cl int m_coins; // edx char v37; // [rsp+0h] [rbp-A0h] char v38; // [rsp+0h] [rbp-A0h] cocos2d::CCSprite *v39; // [rsp+8h] [rbp-98h] cocos2d::CCSprite *v40; // [rsp+10h] [rbp-90h] int v41; // [rsp+18h] [rbp-88h] BYREF cocos2d::CCNode *v42; // [rsp+20h] [rbp-80h] cocos2d::CCNode *v43; // [rsp+28h] [rbp-78h] cocos2d::CCNode *v44; // [rsp+30h] [rbp-70h] _BYTE v45[8]; // [rsp+38h] [rbp-68h] BYREF cocos2d::CCSprite *v46; // [rsp+40h] [rbp-60h] _BYTE v47[8]; // [rsp+48h] [rbp-58h] BYREF cocos2d::CCLabelBMFont *v48; // [rsp+50h] [rbp-50h] std::string v49; // [rsp+58h] [rbp-48h] BYREF _BYTE v50[48]; // [rsp+70h] [rbp-30h] BYREF double v51; // 0:xmm0_8.8 cocos2d::CCPoint v52; // 0:xmm1_8.8 v2 = cocos2d::CCDirector::sharedDirector(); *(cocos2d::CCSize *)&v51 = cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)&v41); v3 = (cocos2d::CCArray *)sub_10071F9E0(&v41, v2); v4 = cocos2d::CCNode::create(); ((void (__fastcall *)(EditLevelLayer *, cocos2d::CCNode *, double))a1->addChild)(a1, v4, v51); v5 = cocos2d::CCNode::create(); ((void (__fastcall *)(EditLevelLayer *, cocos2d::CCNode *))a1->addChild)(a1, v5); v6 = cocos2d::CCNode::create(); ((void (__fastcall *)(EditLevelLayer *, cocos2d::CCNode *))a1->addChild)(a1, v6); v7 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_timeIcon_001.png"); v8 = v4->__vftable; v42 = v4; v39 = v7; ((void (__fastcall *)(cocos2d::CCNode *))v8->addChild)(v4); v9 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_noteIcon_001.png"); v10 = v5->__vftable; v43 = v5; v40 = v9; ((void (__fastcall *)(cocos2d::CCNode *))v10->addChild)(v5); v11 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_infoIcon_001.png"); v12 = v6->__vftable; v44 = v6; v46 = v11; ((void (__fastcall *)(cocos2d::CCNode *))v12->addChild)(v6); GJGameLevel::lengthKeyToString(&v49, (unsigned int)a1->m_level->m_levelLength); if ( (*(_BYTE *)&v49.__r_.__value_.__s.0 & 1) != 0 ) data = v49.__r_.__value_.__l.__data_; else data = v49.__r_.__value_.__s.__data_; v14 = cocos2d::CCLabelBMFont::create_3(data, "bigFont.fnt"); if ( (*(_BYTE *)&v49.__r_.__value_.__s.0 & 1) != 0 ) operator delete(v49.__r_.__value_.__l.__data_); ((void (__fastcall *)(cocos2d::CCNode *, cocos2d::CCLabelBMFont *))v42->addChild)(v42, v14); if ( (float)(100.0 / *(float *)((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v14->getContentSize)(v14)) <= 0.5 ) ((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v14->getContentSize)(v14); ((void (__fastcall *)(cocos2d::CCLabelBMFont *))v14->setScale)(v14); GJGameLevel::getSongName(&v49); if ( (*(_BYTE *)&v49.__r_.__value_.__s.0 & 1) != 0 ) v15 = v49.__r_.__value_.__l.__data_; else v15 = v49.__r_.__value_.__s.__data_; v16 = cocos2d::CCLabelBMFont::create_3(v15, "bigFont.fnt"); if ( (*(_BYTE *)&v49.__r_.__value_.__s.0 & 1) != 0 ) operator delete(v49.__r_.__value_.__l.__data_); ((void (__fastcall *)(cocos2d::CCNode *, cocos2d::CCLabelBMFont *))v43->addChild)(v43, v16); if ( (float)(100.0 / *(float *)((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v16->getContentSize)(v16)) <= 0.5 ) ((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v16->getContentSize)(v16); ((void (__fastcall *)(cocos2d::CCLabelBMFont *))v16->setScale)(v16); *(_WORD *)&v49.__r_.__value_.__l.0 = 0; m_level = a1->m_level; if ( m_level->m_isUploaded ) { v18 = "Uploaded"; LABEL_19: std::string::assign(&v49, v18); goto LABEL_20; } if ( m_level->m_isVerified.random - m_level->m_isVerified.seed == 1 ) { v18 = "Verified"; goto LABEL_19; } std::string::assign(&v49, "Unverified"); if ( a1->m_level->m_coins > 0 ) { std::string::assign(&v49, "Unverified\nReq. Coins: "); v34 = a1->m_level; v35 = 1; if ( v34->m_firstCoinVerified.random - v34->m_firstCoinVerified.seed != 1 ) { std::string::append(&v49, "1"); v34 = a1->m_level; v35 = 0; } m_coins = v34->m_coins; if ( m_coins >= 2 ) { if ( v34->m_secondCoinVerified.random - v34->m_secondCoinVerified.seed != 1 ) { if ( !v35 ) std::string::append(&v49, ", "); std::string::append(&v49, "2"); v34 = a1->m_level; m_coins = v34->m_coins; v35 = 0; } if ( m_coins >= 3 && v34->m_thirdCoinVerified.random - v34->m_thirdCoinVerified.seed != 1 ) { if ( !v35 ) std::string::append(&v49, ", "); std::string::append(&v49, "3"); } } } LABEL_20: if ( (*(_BYTE *)&v49.__r_.__value_.__s.0 & 1) != 0 ) v19 = v49.__r_.__value_.__l.__data_; else v19 = v49.__r_.__value_.__s.__data_; v48 = cocos2d::CCLabelBMFont::create_3(v19, "bigFont.fnt"); ((void (__fastcall *)(cocos2d::CCNode *, cocos2d::CCLabelBMFont *))v44->addChild)(v44, v48); cocos2d::CCLabelBMFont::limitLabelWidth(v48, 100.0, 0.5, 0.0); v20 = ((__int64 (__fastcall *)(cocos2d::CCSprite *))v46->getPosition)(v46); sub_10028CBE0(v47, 0.0, 2.0); sub_10028CCE0(v50, v20); ((void (__fastcall *)(cocos2d::CCSprite *, _BYTE *))v46->setPosition)(v46, v50); sub_100720270(v3); sub_10071FCD0(v3, v39); sub_10071FCD0(v3, v14); sub_10028CC60(v50); GameToolbox::alignItemsHorisontally(v3, 4.0, (cocos2d::CCPoint)0x40000000LL, (bool)v50); sub_100720270(v3); sub_10071FCD0(v3, v40); sub_10071FCD0(v3, v16); sub_10028CC60(v50); GameToolbox::alignItemsHorisontally(v3, 4.0, (cocos2d::CCPoint)0x40000000LL, (bool)v50); sub_100720270(v3); sub_10071FCD0(v3, v46); sub_10071FCD0(v3, v48); sub_10028CC60(v50); GameToolbox::alignItemsHorisontally(v3, 4.0, (cocos2d::CCPoint)0x40000000LL, (bool)v50); sub_100720270(v3); sub_10071FCD0(v3, v42); sub_10071FCD0(v3, v43); sub_10071FCD0(v3, v44); LODWORD(v48) = v41; v21 = cocos2d::CCDirector::sharedDirector(); v22 = sub_100484D80(v21); v52.y = *((float *)&v22 + 1); v52.x = *(float *)&v22 + 55.0; sub_10028CBE0(v50, *(float *)&v48 * 0.5, *(float *)&v22 + 55.0); GameToolbox::alignItemsHorisontally(v3, 140.0, v52, (bool)v50); v23 = (cocos2d::CCString *)sub_1007AB580("Version: %i", v37); CString = cocos2d::CCString::getCString(v23); v25 = cocos2d::CCLabelBMFont::create_3(CString, "goldFont.fnt"); ((void (__fastcall *)(EditLevelLayer *, cocos2d::CCLabelBMFont *))a1->addChild)(a1, v25); v26 = a1->m_level; if ( v26->m_levelID.random != v26->m_levelID.seed ) { v28 = (cocos2d::CCString *)sub_1007AB580("ID: %i", v38); v27 = cocos2d::CCString::getCString(v28); if ( a1->m_level->m_originalLevel.random == a1->m_level->m_originalLevel.seed ) goto LABEL_28; goto LABEL_27; } v27 = "ID: na"; if ( v26->m_originalLevel.random != v26->m_originalLevel.seed ) { LABEL_27: v29 = (cocos2d::CCString *)sub_1007AB580("%s (%i)", v38); v27 = cocos2d::CCString::getCString(v29); } LABEL_28: v30 = cocos2d::CCLabelBMFont::create_3(v27, "goldFont.fnt"); ((void (__fastcall *)(EditLevelLayer *, cocos2d::CCLabelBMFont *))a1->addChild)(a1, v30); LODWORD(v48) = v41; v31 = cocos2d::CCDirector::sharedDirector(); v32 = sub_100484D80(v31); sub_10028CBE0(v50, *(float *)&v48 * 0.5, *(float *)&v32 + 14.0); sub_10028CBE0(v45, -75.0, 0.0); sub_10028CCE0(v47, v50); ((void (__fastcall *)(cocos2d::CCLabelBMFont *, _BYTE *))v25->setPosition)(v25, v47); sub_10028CBE0(v45, 75.0, 0.0); sub_10028CCE0(v47, v50); ((void (__fastcall *)(cocos2d::CCLabelBMFont *, _BYTE *))v30->setPosition)(v30, v47); ((void (__fastcall *)(cocos2d::CCLabelBMFont *, float))v25->setScale)(v25, 0.60000002); if ( *(float *)((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v30->getContentSize)(v30) > 150.0 ) { v33 = (float *)((__int64 (__fastcall *)(cocos2d::CCLabelBMFont *))v30->getContentSize)(v30); ((void (__fastcall *)(cocos2d::CCLabelBMFont *, float))v30->setScale)(v30, 150.0 / *v33); } if ( ((float (__fastcall *)(cocos2d::CCLabelBMFont *))v30->getScale)(v30) < 0.60000002 ) ((void (__fastcall *)(cocos2d::CCLabelBMFont *, float))v30->getScale)(v30, 0.60000002); ((void (__fastcall *)(cocos2d::CCLabelBMFont *, double))v30->setScale)(v30, COERCE_DOUBLE(1058642330)); if ( (*(_BYTE *)&v49.__r_.__value_.__s.0 & 1) != 0 ) operator delete(v49.__r_.__value_.__l.__data_); }