// // RateLevelLayer::init from 0x5111dc to 0x5114a6 (714 bytes) // // 1 xrefs: // > RateLevelLayer::create @ 0x51160e // // This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False! // // 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 11:51:32 +0000 // GameManager *__fastcall RateLevelLayer::init(cocos2d::CCObject **this, cocos2d::CCObject *a2) { GameManager *v4; // r0 GameManager *v5; // r10 const char *v6; // r9 int v7; // r5 void (__fastcall *v8)(int, _BYTE *); // r7 void (__fastcall *v9)(int, _BYTE *); // r7 const char *v10; // r2 int v11; // r5 void (__fastcall *v12)(int, _BYTE *); // r7 cocos2d::CCArray *v13; // r0 cocos2d::CCObject *v14; // r0 cocos2d::CCArray *v15; // r0 cocos2d::CCMenu *v16; // r8 cocos2d::CCObject *v17; // r0 cocos2d::CCString *v18; // r12 cocos2d::CCString *v19; // r0 cocos2d::CCSprite *CString; // r0 const char *v21; // r1 cocos2d::CCSprite *v22; // r3 cocos2d::CCObject *v23; // r7 int v24; // r0 const char *v25; // r1 cocos2d::CCObject *v26; // r7 const cocos2d::CCPoint *v27; // r11 const char *v28; // r1 ButtonSprite *v29; // r0 cocos2d::CCObject *v30; // r11 const char *v31; // r1 ButtonSprite *v32; // r0 int v33; // r0 const cocos2d::CCPoint *v34; // r11 int v35; // r2 cocos2d::CCString *v37; // [sp+Ch] [bp-48h] float v38; // [sp+14h] [bp-40h] BYREF float v39; // [sp+18h] [bp-3Ch] int (__fastcall *v40)(RateLevelLayer *, cocos2d::CCObject *, int); // [sp+1Ch] [bp-38h] int v41; // [sp+20h] [bp-34h] int (__fastcall ***(__fastcall *v42)(RateLevelLayer *, cocos2d::CCObject *))(_DWORD); // [sp+24h] [bp-30h] int v43; // [sp+28h] [bp-2Ch] RateLevelLayer *(__fastcall *v44)(RateLevelLayer *, cocos2d::CCObject *); // [sp+2Ch] [bp-28h] int v45; // [sp+30h] [bp-24h] _BYTE v46[8]; // [sp+34h] [bp-20h] BYREF _BYTE v47[16]; // [sp+3Ch] [bp-18h] BYREF v4 = FLAlertLayer::init((FLAlertLayer *)this, 75); v5 = v4; if ( v4 ) { *(this + 132) = a2; cocos2d::CCDirector::sharedDirector(v4); v6 = nullptr; cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)&v38); cocos2d::CCRect::CCRect((cocos2d::CCRect *)v47, 0.0, 0.0, 80.0, 80.0); v7 = cocos2d::extension::CCScale9Sprite::create("GJ_square01.png", v47); v8 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v7 + 160); cocos2d::CCSize::CCSize((cocos2d::CCSize *)v47, 360.0, 180.0); v8(v7, v47); (*(void (__fastcall **)(_DWORD, int, int))(*(_DWORD *)*(this + 115) + 232))(*(this + 115), v7, -1); v9 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v7 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v47, v38 * 0.5, v39 * 0.5); v9(v7, v47); v11 = cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)"Rate Difficulty", "bigFont.fnt", v10); v12 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v11 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v47, v38 * 0.5, (float)((float)(v39 * 0.5) + 90.0) - 20.0); v12(v11, v47); v13 = (cocos2d::CCArray *)(*(int (__fastcall **)(_DWORD, int))(*(_DWORD *)*(this + 115) + 228))(*(this + 115), v11); v14 = (cocos2d::CCObject *)cocos2d::CCArray::create(v13); *(this + 131) = v14; v15 = (cocos2d::CCArray *)cocos2d::CCObject::retain(v14); v16 = (cocos2d::CCMenu *)cocos2d::CCArray::create(v15); v17 = (cocos2d::CCObject *)cocos2d::CCMenu::create(v16); *(this + 111) = v17; (*(void (__fastcall **)(_DWORD, cocos2d::CCObject *, int))(*(_DWORD *)*(this + 115) + 232))(*(this + 115), v17, 10); v18 = (cocos2d::CCString *)"difficulty_%02d_btn_001.png"; do { v37 = v18; v19 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(v18, v6); CString = (cocos2d::CCSprite *)cocos2d::CCString::getCString(v19); if ( v6 ) v22 = CString; else v22 = (cocos2d::CCSprite *)"difficulty_auto_btn_001.png"; v23 = (cocos2d::CCObject *)cocos2d::CCSprite::createWithSpriteFrameName(v22, v21); cocos2d::CCArray::addObject(*(this + 131), v23); (*(void (__fastcall **)(cocos2d::CCObject *, int))(*(_DWORD *)v23 + 80))(v23, 1065353216); v40 = RateLevelLayer::selectRating; v41 = 0; v24 = CCMenuItemSpriteExtra::create((int)v23, 0, (int)this, (int)RateLevelLayer::selectRating, 0); v25 = v6++; v26 = (cocos2d::CCObject *)v24; (*(void (__fastcall **)(int, const char *))(*(_DWORD *)v24 + 36))(v24, v25); (*(void (__fastcall **)(_DWORD, cocos2d::CCObject *))(*(_DWORD *)*(this + 111) + 228))(*(this + 111), v26); cocos2d::CCArray::addObject(v16, v26); v18 = v37; } while ( v6 != &byte_7 ); v27 = *(this + 111); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v47, v38 * 0.5, v39 * 0.5); cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v46, v27); GameToolbox::alignItemsHorisontally(*(float *)&v16, 16.0, (int)v46, 0); cocos2d::CCArray::removeAllObjects(v16); v29 = ButtonSprite::create((ButtonSprite *)"Cancel", v28); v42 = RateLevelLayer::onClose; v43 = 0; v30 = (cocos2d::CCObject *)CCMenuItemSpriteExtra::create((int)v29, 0, (int)this, (int)RateLevelLayer::onClose, 0); (*(void (__fastcall **)(_DWORD, cocos2d::CCObject *))(*(_DWORD *)*(this + 111) + 228))(*(this + 111), v30); cocos2d::CCArray::addObject(v16, v30); v32 = ButtonSprite::create((ButtonSprite *)"Submit", v31); v44 = RateLevelLayer::onRate; v45 = 0; v33 = CCMenuItemSpriteExtra::create((int)v32, 0, (int)this, (int)RateLevelLayer::onRate, 0); *(this + 130) = (cocos2d::CCObject *)v33; (*(void (__fastcall **)(_DWORD, int))(*(_DWORD *)*(this + 111) + 228))(*(this + 111), v33); cocos2d::CCArray::addObject(v16, *(this + 130)); v34 = *(this + 111); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v47, v38 * 0.5, (float)((float)(v39 * 0.5) - 90.0) + 25.0); cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v46, v34); GameToolbox::alignItemsHorisontally(*(float *)&v16, 15.0, (int)v46, 0); RateLevelLayer::selectRating((RateLevelLayer *)this, nullptr, v35); } return v5; }
GD Web Decomp Icon

GD Web Decomp

Raw Source