// // SongOptionsLayer::init from 0x57cef0 to 0x57d640 (1872 bytes) // // 1 xrefs: // > SongOptionsLayer::create @ 0x57d6f0 // // 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:52:50 +0000 // GameManager *__fastcall SongOptionsLayer::init(SongOptionsLayer *this, CustomSongDelegate *a2) { GameManager *v4; // r0 int v5; // r6 void (__fastcall *v6)(int, _DWORD *); // r8 void (__fastcall *v7)(int, _DWORD *); // r8 const char *v8; // r2 int v9; // r6 void (__fastcall *v10)(int, _DWORD *); // r8 cocos2d::CCMenu *v11; // r0 int v12; // r0 int v13; // r0 int v14; // r8 const cocos2d::CCPoint *v15; // r11 int v16; // r10 int v17; // r0 int v18; // r10 const cocos2d::CCPoint *v19; // r11 int v20; // r8 int v21; // r0 int v22; // r8 const cocos2d::CCPoint *v23; // r9 int v24; // r11 const char *v25; // r1 int v26; // r0 int v27; // r10 void (__fastcall *v28)(int, _DWORD *); // r11 const char *v29; // r1 int v30; // r0 int v31; // r10 void (__fastcall *v32)(int, _DWORD *); // r11 const char *v33; // r2 int v34; // r11 int v35; // r6 int *v36; // r0 int v37; // r6 const char *v38; // r1 int v39; // r5 __int64 v40; // r0 cocos2d::CCString *v41; // r0 const char *CString; // r0 const char *v43; // r6 size_t v44; // r0 int v45; // r0 int v46; // r0 int v47; // r5 const cocos2d::CCPoint *v48; // r8 void (__fastcall *v49)(int, _BYTE *); // r7 char *v51; // [sp+8h] [bp-D4h] cocos2d::CCPoint *v52; // [sp+30h] [bp-ACh] cocos2d::CCPoint *v53; // [sp+30h] [bp-ACh] cocos2d::CCPoint *v54; // [sp+30h] [bp-ACh] GameManager *v55; // [sp+38h] [bp-A4h] int v56; // [sp+44h] [bp-98h] float v57; // [sp+48h] [bp-94h] BYREF float v58; // [sp+4Ch] [bp-90h] char v59[4]; // [sp+50h] [bp-8Ch] BYREF float v60; // [sp+54h] [bp-88h] _BYTE v61[8]; // [sp+58h] [bp-84h] BYREF char v62[4]; // [sp+60h] [bp-7Ch] BYREF float v63; // [sp+64h] [bp-78h] _BYTE v64[8]; // [sp+68h] [bp-74h] BYREF char v65[8]; // [sp+70h] [bp-6Ch] BYREF _BYTE v66[8]; // [sp+78h] [bp-64h] BYREF int (__fastcall *v67)(SongOptionsLayer *, cocos2d::CCObject *); // [sp+80h] [bp-5Ch] int v68; // [sp+84h] [bp-58h] int (__fastcall *v69)(SongOptionsLayer *, cocos2d::CCObject *); // [sp+88h] [bp-54h] int v70; // [sp+8Ch] [bp-50h] int (__fastcall *v71)(SongOptionsLayer *, cocos2d::CCObject *); // [sp+90h] [bp-4Ch] int v72; // [sp+94h] [bp-48h] int (__fastcall *v73)(SongOptionsLayer *, cocos2d::CCObject *); // [sp+98h] [bp-44h] int v74; // [sp+9Ch] [bp-40h] _DWORD v75[2]; // [sp+A0h] [bp-3Ch] BYREF int v76; // [sp+A8h] [bp-34h] BYREF int v77; // [sp+ACh] [bp-30h] int v78; // [sp+B0h] [bp-2Ch] _BYTE v79[16]; // [sp+B4h] [bp-28h] BYREF _DWORD v80[4]; // [sp+C4h] [bp-18h] BYREF v4 = FLAlertLayer::init(this, 75); v55 = v4; if ( v4 ) { *((_DWORD *)this + 130) = a2; cocos2d::CCDirector::sharedDirector(v4); cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)&v57); cocos2d::CCRect::CCRect((cocos2d::CCRect *)v80, 0.0, 0.0, 80.0, 80.0); v5 = cocos2d::extension::CCScale9Sprite::create("GJ_square01.png", v80); v6 = *(void (__fastcall **)(int, _DWORD *))(*(_DWORD *)v5 + 160); cocos2d::CCSize::CCSize((cocos2d::CCSize *)v80, 360.0, 220.0); v6(v5, v80); (*(void (__fastcall **)(_DWORD, int, int))(**((_DWORD **)this + 115) + 232))(*((_DWORD *)this + 115), v5, -1); v7 = *(void (__fastcall **)(int, _DWORD *))(*(_DWORD *)v5 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v80, v57 * 0.5, v58 * 0.5); v7(v5, v80); v9 = cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)"Settings", "bigFont.fnt", v8); v10 = *(void (__fastcall **)(int, _DWORD *))(*(_DWORD *)v9 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v80, v57 * 0.5, (float)((float)(v58 * 0.5) + 110.0) - 20.0); v10(v9, v80); v11 = (cocos2d::CCMenu *)(*(int (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 115) + 228))( *((_DWORD *)this + 115), v9); v12 = cocos2d::CCMenu::create(v11); *((_DWORD *)this + 111) = v12; (*(void (__fastcall **)(_DWORD, int, int))(**((_DWORD **)this + 115) + 232))(*((_DWORD *)this + 115), v12, 10); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v59, (float)(v57 * 0.5) - 140.0, (float)(v58 * 0.5) - 40.0); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v61, (float)(v57 * 0.5) + 30.0, v60); v76 = 0; v77 = 0; v78 = 0; std::string::__init(&v76, "Fade in", 7u); v13 = *((_DWORD *)this + 130); v68 = 0; v67 = SongOptionsLayer::onFadeIn; v14 = *(unsigned __int8 *)((*(int (__fastcall **)(int))(*(_DWORD *)v13 + 12))(v13) + 288); v15 = *((const cocos2d::CCPoint **)this + 111); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v80, (const cocos2d::CCPoint *)v59); v16 = *((_DWORD *)this + 115); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v79, 8.0, 0.0); GameToolbox::createToggleButton( (int)&v76, (int)v67, v68, v14, v15, (int)v80, (int)this, v16, 0.8, 0.6, 150.0, (int)v79, "bigFont.fnt", 0, 0, nullptr); std::string::~string((int)&v76); v76 = 0; v77 = 0; v78 = 0; std::string::__init(&v76, "Fade out", 8u); v17 = *((_DWORD *)this + 130); v70 = 0; v69 = SongOptionsLayer::onFadeOut; v18 = *(unsigned __int8 *)((*(int (__fastcall **)(int))(*(_DWORD *)v17 + 12))(v17) + 289); v19 = *((const cocos2d::CCPoint **)this + 111); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v75, 0.0, 0.0); cocos2d::CCPoint::operator+(v79, v61, v75); v20 = *((_DWORD *)this + 115); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v80, 8.0, 0.0); GameToolbox::createToggleButton( (int)&v76, (int)v69, v70, v18, v19, (int)v79, (int)this, v20, 0.8, 0.6, 150.0, (int)v80, "bigFont.fnt", 0, 0, nullptr); std::string::~string((int)&v76); v76 = 0; v77 = 0; v78 = 0; std::string::__init(&v76, "Dont Reset", 0xAu); v21 = *((_DWORD *)this + 130); v72 = 0; v71 = SongOptionsLayer::onSongPersistent; v22 = *(unsigned __int8 *)((*(int (__fastcall **)(int))(*(_DWORD *)v21 + 12))(v21) + 290); v23 = *((const cocos2d::CCPoint **)this + 111); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v75, 0.0, -40.0); cocos2d::CCPoint::operator+(v79, v59, v75); v24 = *((_DWORD *)this + 115); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v80, 8.0, 0.0); GameToolbox::createToggleButton( (int)&v76, (int)v71, v72, v22, v23, (int)v79, (int)this, v24, 0.8, 0.6, 150.0, (int)v80, "bigFont.fnt", 0, 0, nullptr); std::string::~string((int)&v76); v26 = cocos2d::CCSprite::createWithSpriteFrameName((cocos2d::CCSprite *)"GJ_closeBtn_001.png", v25); v74 = 0; v73 = SongOptionsLayer::onClose; v27 = CCMenuItemSpriteExtra::create(v26, 0, (int)this, (int)SongOptionsLayer::onClose, 0); CCMenuItemSpriteExtra::setSizeMult(v27, 1.5); (*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 111) + 228))(*((_DWORD *)this + 111), v27); v28 = *(void (__fastcall **)(int, _DWORD *))(*(_DWORD *)v27 + 92); v52 = *((cocos2d::CCPoint **)this + 111); cocos2d::CCPoint::CCPoint( (cocos2d::CCPoint *)v79, (float)((float)(v57 * 0.5) - 180.0) + 5.0, (float)((float)(v58 * 0.5) + 110.0) - 5.0); cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v80, v52); v28(v27, v80); v30 = cocos2d::CCSprite::createWithSpriteFrameName((cocos2d::CCSprite *)"GJ_infoIcon_001.png", v29); v75[1] = 0; v75[0] = SongOptionsLayer::onInfo; v31 = CCMenuItemSpriteExtra::create(v30, 0, (int)this, (int)SongOptionsLayer::onInfo, 0); CCMenuItemSpriteExtra::setSizeMult(v31, 2.0); (*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 111) + 228))(*((_DWORD *)this + 111), v31); v32 = *(void (__fastcall **)(int, _DWORD *))(*(_DWORD *)v31 + 92); v53 = *((cocos2d::CCPoint **)this + 111); cocos2d::CCPoint::CCPoint( (cocos2d::CCPoint *)v79, (float)((float)(v57 * 0.5) + 180.0) - 17.0, (float)((float)(v58 * 0.5) + 110.0) - 17.0); cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v80, v53); v32(v31, v80); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v62, v57 * 0.5, (float)(v58 * 0.5) + 25.0); v34 = cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)"Start Offset", "bigFont.fnt", v33); (*(void (__fastcall **)(int, int))(*(_DWORD *)v34 + 80))(v34, 1053609165); v54 = *(cocos2d::CCPoint **)(*(_DWORD *)v34 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v79, 0.0, 25.0); cocos2d::CCPoint::operator+(v80, v62, v79); ((void (__fastcall *)(int, _DWORD *))v54)(v34, v80); (*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 115) + 228))(*((_DWORD *)this + 115), v34); cocos2d::CCRect::CCRect((cocos2d::CCRect *)v79, 0.0, 0.0, 40.0, 40.0); cocos2d::CCRect::CCRect((cocos2d::CCRect *)v80, (const cocos2d::CCRect *)v79); v35 = cocos2d::extension::CCScale9Sprite::create("square02_small.png", v80); (*(void (__fastcall **)(int, int))(*(_DWORD *)v35 + 456))(v35, 100); cocos2d::CCSize::CCSize((cocos2d::CCSize *)v64, 100.0, 30.0); (*(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v35 + 160))(v35, v64); (*(void (__fastcall **)(_DWORD, int, int))(**((_DWORD **)this + 115) + 232))(*((_DWORD *)this + 115), v35, -1); (*(void (__fastcall **)(int, char *))(*(_DWORD *)v35 + 92))(v35, v62); v36 = CCTextInputNode::create( (CCTextInputNode *)0x42C80000, 50.0, "Seconds", "Thonburi", (const char *)&dword_18, "bigFont.fnt", v51); *((_DWORD *)this + 131) = v36; (*(void (__fastcall **)(_DWORD, int *, int))(**((_DWORD **)this + 115) + 232))(*((_DWORD *)this + 115), v36, 20); (*(void (__fastcall **)(_DWORD, char *))(**((_DWORD **)this + 131) + 92))(*((_DWORD *)this + 131), v62); CCTextInputNode::setMaxLabelScale(*((_DWORD *)this + 131), 0.7); CCTextInputNode::setMaxLabelWidth(*((_DWORD *)this + 131), 200.0); (*(void (__fastcall **)(_DWORD, _DWORD))(**(_DWORD **)(*((_DWORD *)this + 131) + 416) + 172))( *(_DWORD *)(*((_DWORD *)this + 131) + 416), 0); *(_DWORD *)(*((_DWORD *)this + 131) + 424) = 5; v37 = *((_DWORD *)this + 131); v76 = 0; v77 = 0; v78 = 0; std::string::__init(&v76, "0123456789.", 0xBu); CCTextInputNode::setAllowedChars(v37, (unsigned __int8 *)&v76); std::string::~string((int)&v76); LOWORD(v56) = -21896; BYTE2(v56) = -16; CCTextInputNode::setLabelPlaceholderColor(*((_DWORD *)this + 131), v56); CCTextInputNode::setLabelPlaceholderScale(*((_DWORD *)this + 131), 0.5); if ( *(float *)((*(int (__fastcall **)(_DWORD))(**((_DWORD **)this + 130) + 12))(*((_DWORD *)this + 130)) + 284) > 0.0 ) { v39 = *((_DWORD *)this + 131); v40 = ((__int64 (__fastcall *)(_DWORD))*(_DWORD *)(**((_DWORD **)this + 130) + 12))(*((_DWORD *)this + 130)); v41 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"%0.1f", (const char *)HIDWORD(v40), *(float *)(v40 + 284)); CString = (const char *)cocos2d::CCString::getCString(v41); v76 = 0; v77 = 0; v78 = 0; v43 = CString; v44 = strlen(CString); std::string::__init(&v76, v43, v44); CCTextInputNode::setString(v39, (int)&v76); std::string::~string((int)&v76); } v45 = cocos2d::CCSprite::createWithSpriteFrameName((cocos2d::CCSprite *)"GJ_playMusicBtn_001.png", v38); v80[1] = 0; v80[0] = SongOptionsLayer::onPlayback; v46 = CCMenuItemSpriteExtra::create(v45, 0, (int)this, (int)SongOptionsLayer::onPlayback, 0); *((_DWORD *)this + 132) = v46; (*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)this + 111) + 228))(*((_DWORD *)this + 111), v46); v47 = *((_DWORD *)this + 132); v48 = *((const cocos2d::CCPoint **)this + 111); v49 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v47 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v65, (float)(v57 * 0.5) + 100.0, v63); cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v66, v48); v49(v47, v66); } return v55; }
GD Web Decomp Icon

GD Web Decomp

Raw Source