// // GJColorSetupLayer::init from 0x5c17e0 to 0x5c1d18 (1336 bytes) // // 1 xrefs: // > GJColorSetupLayer::create @ 0x5c1e8a // // 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:53:50 +0000 // GameManager *__fastcall GJColorSetupLayer::init(GJColorSetupLayer *this, LevelSettingsObject *a2) { GameManager *v4; // r9 int v5; // r6 cocos2d::CCDirector *v6; // r0 int v7; // r7 void (__fastcall *v8)(int, _BYTE *); // r8 int (__fastcall *v9)(int, _BYTE *); // r8 cocos2d::CCDictionary *v10; // r0 cocos2d::CCObject *v11; // r0 cocos2d::CCDictionary *v12; // r0 cocos2d::CCObject *v13; // r0 cocos2d::CCArray *v14; // r0 cocos2d::CCObject *v15; // r0 cocos2d::CCArray *v16; // r0 cocos2d::CCObject *v17; // r0 cocos2d::CCMenu *v18; // r0 int v19; // r0 const char *v20; // r2 int v21; // r7 void (__fastcall *v22)(int, _BYTE *); // r8 float v23; // s15 const char *v24; // r2 cocos2d::CCObject *v25; // r7 float v26; // r0 ColorChannelSprite *v27; // r0 cocos2d::CCObject *v28; // r8 int v29; // r8 int v30; // r7 int v31; // r1 const cocos2d::CCPoint *v32; // r6 const char *v33; // r1 int v34; // r7 int v35; // r0 const char *v36; // r1 cocos2d::CCSprite *v37; // r11 int v38; // r0 int v39; // r8 void (__fastcall *v40)(int, _BYTE *); // r11 ButtonSprite *v41; // r0 int v42; // r6 const cocos2d::CCPoint *v43; // r10 void (__fastcall *v44)(int, _BYTE *); // r8 int v45; // r1 float v47; // [sp+10h] [bp-74h] void (__fastcall *v48)(int, _DWORD *); // [sp+14h] [bp-70h] void (__fastcall *v49)(cocos2d::CCLabelBMFont *, _BYTE *); // [sp+14h] [bp-70h] cocos2d::CCLabelBMFont *v50; // [sp+1Ch] [bp-68h] cocos2d::CCPoint *v51; // [sp+24h] [bp-60h] float v52; // [sp+2Ch] [bp-58h] BYREF float v53; // [sp+30h] [bp-54h] _BYTE v54[8]; // [sp+34h] [bp-50h] BYREF _BYTE v55[8]; // [sp+3Ch] [bp-48h] BYREF int (__fastcall *v56)(GJColorSetupLayer *, cocos2d::CCObject *); // [sp+44h] [bp-40h] int v57; // [sp+48h] [bp-3Ch] _DWORD (*v58)(GJColorSetupLayer *__hidden, cocos2d::CCObject *); // [sp+4Ch] [bp-38h] int v59; // [sp+50h] [bp-34h] _DWORD v60[2]; // [sp+54h] [bp-30h] BYREF _DWORD v61[2]; // [sp+5Ch] [bp-28h] BYREF _BYTE v62[8]; // [sp+64h] [bp-20h] BYREF _BYTE v63[16]; // [sp+6Ch] [bp-18h] BYREF v4 = FLAlertLayer::init(this, 150); if ( v4 ) { *((_DWORD *)this + 132) = a2; v5 = 1; *((_BYTE *)this + 468) = 1; v6 = (cocos2d::CCDirector *)cocos2d::CCObject::retain(a2); cocos2d::CCDirector::sharedDirector(v6); cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)&v52); cocos2d::CCRect::CCRect((cocos2d::CCRect *)v63, 0.0, 0.0, 80.0, 80.0); v7 = cocos2d::extension::CCScale9Sprite::create("GJ_square01.png", v63); (*(void (__fastcall **)(int, int))(*(_DWORD *)v7 + 456))(v7, 255); v8 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v7 + 160); cocos2d::CCSize::CCSize((cocos2d::CCSize *)v63, 450.0, 300.0); v8(v7, v63); (*(void (__fastcall **)(_DWORD, int, int))(**((_DWORD **)this + 115) + 232))(*((_DWORD *)this + 115), v7, -2); v9 = *(int (__fastcall **)(int, _BYTE *))(*(_DWORD *)v7 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v63, v52 * 0.5, v53 * 0.5); v10 = (cocos2d::CCDictionary *)v9(v7, v63); v11 = (cocos2d::CCObject *)cocos2d::CCDictionary::create(v10); *((_DWORD *)this + 133) = v11; v12 = (cocos2d::CCDictionary *)cocos2d::CCObject::retain(v11); v13 = (cocos2d::CCObject *)cocos2d::CCDictionary::create(v12); *((_DWORD *)this + 134) = v13; v14 = (cocos2d::CCArray *)cocos2d::CCObject::retain(v13); v15 = (cocos2d::CCObject *)cocos2d::CCArray::create(v14); *((_DWORD *)this + 135) = v15; v16 = (cocos2d::CCArray *)cocos2d::CCObject::retain(v15); v17 = (cocos2d::CCObject *)cocos2d::CCArray::create(v16); *((_DWORD *)this + 136) = v17; v18 = (cocos2d::CCMenu *)cocos2d::CCObject::retain(v17); *((_DWORD *)this + 138) = 24; *((_DWORD *)this + 139) = 42; v19 = cocos2d::CCMenu::create(v18); *((_DWORD *)this + 111) = v19; (*(void (__fastcall **)(_DWORD, int, int))(**((_DWORD **)this + 115) + 232))(*((_DWORD *)this + 115), v19, 10); v21 = cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)"Select Custom Color:", "goldFont.fnt", v20); (*(void (__fastcall **)(int, int))(*(_DWORD *)v21 + 80))(v21, 1061997773); (*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 115) + 228))(*((_DWORD *)this + 115), v21); v22 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v21 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v63, v52 * 0.5, (float)(v53 * 0.5) + 130.0); v22(v21, v63); v23 = (float)(v52 * 0.5) - 132.5; cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v54, v23, (float)(v53 * 0.5) + 100.0); while ( v5 <= *((_DWORD *)this + 138) ) { v25 = (cocos2d::CCObject *)cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)" ", "bigFont.fnt", v24); (*(void (__fastcall **)(cocos2d::CCObject *, int))(*(_DWORD *)v25 + 80))(v25, 1050253722); (*(void (__fastcall **)(_DWORD, cocos2d::CCObject *))(**((_DWORD **)this + 115) + 228))( *((_DWORD *)this + 115), v25); cocos2d::CCArray::addObject(*((cocos2d::CCArray **)this + 135), v25); v26 = floorf((float)((v5 - 1) / 6)); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v63, (float)((v5 - 1) % 6) * 53.0, (float)-(int)v26 * 53.0); cocos2d::CCPoint::operator+(v60, v54, v63); v27 = (ColorChannelSprite *)(*(int (__fastcall **)(cocos2d::CCObject *, _DWORD *))(*(_DWORD *)v25 + 92))(v25, v60); v28 = (cocos2d::CCObject *)ColorChannelSprite::create(v27); (*(void (__fastcall **)(cocos2d::CCObject *, int))(*(_DWORD *)v28 + 80))(v28, 1061997773); (*(void (__fastcall **)(cocos2d::CCObject *, void *))(*(_DWORD *)v28 + 480))(v28, &unk_BEE0D8); cocos2d::CCArray::addObject(*((cocos2d::CCArray **)this + 136), v28); v56 = GJColorSetupLayer::onColor; v57 = 0; v29 = CCMenuItemSpriteExtra::create((int)v28, 0, (int)this, (int)GJColorSetupLayer::onColor, 0); (*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 111) + 228))(*((_DWORD *)this + 111), v29); v48 = *(void (__fastcall **)(int, _DWORD *))(*(_DWORD *)v29 + 92); v51 = *((cocos2d::CCPoint **)this + 111); v30 = (*(int (__fastcall **)(cocos2d::CCObject *))(*(_DWORD *)v25 + 96))(v25); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v63, 0.0, -22.0); cocos2d::CCPoint::operator+(v62, v30, v63); cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v61, v51); v48(v29, v61); v31 = v5++; (*(void (__fastcall **)(int, int))(*(_DWORD *)v29 + 36))(v29, v31); } GJColorSetupLayer::updateSpriteColors(this); v32 = *((const cocos2d::CCPoint **)this + 111); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v63, v52 * 0.5, v53 * 0.5); cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v55, v32); v34 = cocos2d::CCSprite::createWithSpriteFrameName((cocos2d::CCSprite *)"GJ_arrow_01_001.png", v33); (*(void (__fastcall **)(int, int))(*(_DWORD *)v34 + 80))(v34, 1065353216); v58 = GJColorSetupLayer::onPage; v59 = 0; v35 = CCMenuItemSpriteExtra::create(v34, 0, (int)this, (int)GJColorSetupLayer::onPage, 0); *((_DWORD *)this + 140) = v35; (*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 111) + 228))(*((_DWORD *)this + 111), v35); v50 = *((cocos2d::CCLabelBMFont **)this + 140); v49 = *(void (__fastcall **)(cocos2d::CCLabelBMFont *, _BYTE *))(*(_DWORD *)v50 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v63, -190.0, 0.0); cocos2d::CCPoint::operator+(v62, v55, v63); v49(v50, v62); CCMenuItemSpriteExtra::setSizeMult(*((_DWORD *)this + 140), 2.0); (*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 140) + 36))(*((_DWORD *)this + 140), 1); v37 = (cocos2d::CCSprite *)cocos2d::CCSprite::createWithSpriteFrameName( (cocos2d::CCSprite *)"GJ_arrow_01_001.png", v36); (*(void (__fastcall **)(cocos2d::CCSprite *, int))(*(_DWORD *)v37 + 80))(v37, 1065353216); cocos2d::CCSprite::setFlipX(v37, 1); v60[0] = GJColorSetupLayer::onPage; v60[1] = 0; v38 = CCMenuItemSpriteExtra::create((int)v37, 0, (int)this, (int)GJColorSetupLayer::onPage, 0); *((_DWORD *)this + 141) = v38; (*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 111) + 228))(*((_DWORD *)this + 111), v38); v39 = *((_DWORD *)this + 141); v40 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v39 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v63, 190.0, 0.0); cocos2d::CCPoint::operator+(v62, v55, v63); v40(v39, v62); CCMenuItemSpriteExtra::setSizeMult(*((_DWORD *)this + 141), 2.0); (*(void (__fastcall **)(_DWORD, _DWORD))(**((_DWORD **)this + 141) + 36))(*((_DWORD *)this + 141), 0); v41 = ButtonSprite::create( (ButtonSprite *)"OK", (const char *)&word_28, 0, 0.8, 1, "goldFont.fnt", "GJ_button_01.png", (const char *)0x41F00000, v47); v61[0] = GJColorSetupLayer::onClose; v61[1] = 0; v42 = CCMenuItemSpriteExtra::create((int)v41, 0, (int)this, (int)GJColorSetupLayer::onClose, 0); (*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 111) + 228))(*((_DWORD *)this + 111), v42); v43 = *((const cocos2d::CCPoint **)this + 111); v44 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v42 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v63, v52 * 0.5, (float)(v53 * 0.5) - 126.0); cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v62, v43); v44(v42, v62); v45 = *(_DWORD *)(*((_DWORD *)this + 132) + 340); *((_DWORD *)this + 137) = v45; GJColorSetupLayer::showPage(this, v45); } return v4; }
GD Web Decomp Icon

GD Web Decomp

Raw Source