// // RateLevelLayer::init from 0x8c347c to 0x8c3858 (988 bytes) // // 2 xrefs: // > RateLevelLayer::create @ 0x8c39ac // > @ 0xc1a68 // // 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:56:32 +0000 // __int64 __fastcall RateLevelLayer::init(cocos2d::CCObject **this, int a2) { cocos2d::CCDirector *v4; // x0 unsigned int v5; // w26 unsigned int v7; // w20 cocos2d::CCDirector *v8; // x0 __int64 v9; // x21 void (__fastcall *v10)(__int64, _BYTE *); // x22 void (__fastcall *v11)(__int64, _BYTE *); // x22 const char *v12; // x2 __int64 v13; // x21 void (__fastcall *v14)(__int64, _BYTE *); // x22 cocos2d::CCArray *v15; // x0 cocos2d::CCObject *v16; // x0 cocos2d::CCArray *v17; // x0 cocos2d::CCMenu *v18; // x22 __int64 v19; // x0 cocos2d::CCString *v20; // x0 const char *v21; // x1 cocos2d::CCSprite *i; // x0 cocos2d::CCString *v23; // x0 cocos2d::CCObject *v24; // x21 __int64 v25; // x0 __int64 v26; // x1 cocos2d::CCObject *v27; // x21 cocos2d::CCNode *v28; // x21 const char *v29; // x1 __int64 v30; // x2 __int64 v31; // x3 bool v32; // w4 __int64 v33; // x5 const char *v34; // x6 __int64 v35; // x0 cocos2d::CCObject *v36; // x21 const char *v37; // x1 __int64 v38; // x2 __int64 v39; // x3 bool v40; // w4 __int64 v41; // x5 const char *v42; // x6 __int64 v43; // x0 __int64 v44; // x0 cocos2d::CCNode *v45; // x21 __int64 v46; // [xsp+68h] [xbp+68h] BYREF __int64 v47; // [xsp+70h] [xbp+70h] BYREF _BYTE v48[16]; // [xsp+78h] [xbp+78h] BYREF v4 = (cocos2d::CCDirector *)(unsigned __int8)FLAlertLayer::init((FLAlertLayer *)this, 75); v5 = (unsigned __int8)v4; if ( (_BYTE)v4 ) { *((_DWORD *)this + 170) = a2; v7 = 0; v8 = (cocos2d::CCDirector *)cocos2d::CCDirector::sharedDirector(v4); cocos2d::CCDirector::getWinSize(&v46, v8); cocos2d::CCRect::CCRect((cocos2d::CCRect *)v48, 0.0, 0.0, 80.0, 80.0); v9 = cocos2d::extension::CCScale9Sprite::create("GJ_square01.png", v48); v10 = *(void (__fastcall **)(__int64, _BYTE *))(*(_QWORD *)v9 + 320LL); cocos2d::CCSize::CCSize((cocos2d::CCSize *)v48, 360.0, 180.0); v10(v9, v48); (*(void (__fastcall **)(_QWORD, __int64, __int64))(*(_QWORD *)*(this + 73) + 464LL))(*(this + 73), v9, 0xFFFFFFFFLL); v11 = *(void (__fastcall **)(__int64, _BYTE *))(*(_QWORD *)v9 + 184LL); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v48, *(float *)&v46 * 0.5, *((float *)&v46 + 1) * 0.5); v11(v9, v48); v13 = cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)"Rate Difficulty", "bigFont.fnt", v12); v14 = *(void (__fastcall **)(__int64, _BYTE *))(*(_QWORD *)v13 + 184LL); cocos2d::CCPoint::CCPoint( (cocos2d::CCPoint *)v48, *(float *)&v46 * 0.5, (float)((float)(*((float *)&v46 + 1) * 0.5) + 90.0) - 20.0); v14(v13, v48); v15 = (cocos2d::CCArray *)(*(__int64 (__fastcall **)(_QWORD, __int64))(*(_QWORD *)*(this + 73) + 456LL))( *(this + 73), v13); v16 = (cocos2d::CCObject *)cocos2d::CCArray::create(v15); *(this + 84) = v16; v17 = (cocos2d::CCArray *)cocos2d::CCObject::retain(v16); v18 = (cocos2d::CCMenu *)cocos2d::CCArray::create(v17); v19 = cocos2d::CCMenu::create(v18); *(this + 69) = (cocos2d::CCObject *)v19; (*(void (__fastcall **)(_QWORD, __int64, __int64))(*(_QWORD *)*(this + 73) + 464LL))(*(this + 73), v19, 10); v20 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"difficulty_%02d_btn_001.png", nullptr); cocos2d::CCString::getCString(v20); for ( i = (cocos2d::CCSprite *)"difficulty_auto_btn_001.png"; ; i = (cocos2d::CCSprite *)cocos2d::CCString::getCString(v23) ) { v24 = (cocos2d::CCObject *)cocos2d::CCSprite::createWithSpriteFrameName(i, v21); cocos2d::CCArray::addObject(*(this + 84), v24); (*(void (__fastcall **)(cocos2d::CCObject *, float))(*(_QWORD *)v24 + 160LL))(v24, 1.0); v25 = CCMenuItemSpriteExtra::create((__int64)v24, 0, (__int64)this, (__int64)RateLevelLayer::selectRating, 0); v26 = v7; v27 = (cocos2d::CCObject *)v25; ++v7; (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v25 + 72LL))(v25, v26); (*(void (__fastcall **)(_QWORD, cocos2d::CCObject *))(*(_QWORD *)*(this + 69) + 456LL))(*(this + 69), v27); cocos2d::CCArray::addObject(v18, v27); if ( v7 == 7 ) break; v23 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"difficulty_%02d_btn_001.png", (const char *)v7); } v28 = *(this + 69); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v48, *(float *)&v46 * 0.5, *((float *)&v46 + 1) * 0.5); cocos2d::CCNode::convertToNodeSpace(&v47, v28, (const cocos2d::CCPoint *)v48); GameToolbox::alignItemsHorisontally((__int64)v18, (__int64)&v47, 0, 16.0); cocos2d::CCArray::removeAllObjects(v18); v35 = ButtonSprite::create((ButtonSprite *)"Cancel", v29, v30, v31, v32, v33, v34); v36 = (cocos2d::CCObject *)CCMenuItemSpriteExtra::create(v35, 0, (__int64)this, (__int64)RateLevelLayer::onClose, 0); (*(void (__fastcall **)(_QWORD, cocos2d::CCObject *))(*(_QWORD *)*(this + 69) + 456LL))(*(this + 69), v36); cocos2d::CCArray::addObject(v18, v36); v43 = ButtonSprite::create((ButtonSprite *)"Submit", v37, v38, v39, v40, v41, v42); v44 = CCMenuItemSpriteExtra::create(v43, 0, (__int64)this, (__int64)RateLevelLayer::onRate, 0); *(this + 83) = (cocos2d::CCObject *)v44; (*(void (__fastcall **)(_QWORD, __int64))(*(_QWORD *)*(this + 69) + 456LL))(*(this + 69), v44); cocos2d::CCArray::addObject(v18, *(this + 83)); v45 = *(this + 69); cocos2d::CCPoint::CCPoint( (cocos2d::CCPoint *)v48, *(float *)&v46 * 0.5, (float)((float)(*((float *)&v46 + 1) * 0.5) + -90.0) + 25.0); cocos2d::CCNode::convertToNodeSpace(&v47, v45, (const cocos2d::CCPoint *)v48); GameToolbox::alignItemsHorisontally((__int64)v18, (__int64)&v47, 0, 15.0); RateLevelLayer::selectRating((RateLevelLayer *)this, nullptr); } return v5; }
GD Web Decomp Icon

GD Web Decomp

Raw Source