// // TimeSpeedControl::init from 0x7a22fc to 0x7a25ca (718 bytes) // // 1 xrefs: // > TimeSpeedControl::create @ 0x7a2672 // // 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:59:55 +0000 // int __fastcall TimeSpeedControl::init(Slider **this, GJBaseGameLayer *a2) { int v4; // r7 int v5; // r8 void (__fastcall *v6)(int, _DWORD *); // r9 void (__fastcall *v7)(int, _DWORD *); // r9 const char *v8; // r2 int v9; // r8 void (__fastcall *v10)(int, _DWORD *); // r9 SliderTouchLogic **v11; // r0 int v12; // r2 int v13; // r3 int v14; // r8 void (__fastcall *v15)(int, _DWORD); // r9 float v16; // r0 float v17; // s15 const char *v18; // r2 Slider *v19; // r0 int v20; // r8 void (__fastcall *v21)(int, _DWORD *); // r9 int v22; // r5 int (__fastcall *v23)(int, int); // r8 const char *v24; // r1 cocos2d::CCString *v25; // r0 int CString; // r0 cocos2d::CCMenu *v27; // r0 int v28; // r5 GameManager *v29; // r0 GameManager *v30; // r0 const char *v31; // r1 int v32; // r9 const char *v33; // r1 int v34; // r10 cocos2d::CCNodeRGBA *v35; // r0 int v36; // r5 void (__fastcall *v37)(int, _BYTE *); // r8 int v38; // r0 _BYTE v40[8]; // [sp+Ch] [bp-24h] BYREF GameManager *(__fastcall *v41)(TimeSpeedControl *, cocos2d::CCObject *); // [sp+14h] [bp-1Ch] int v42; // [sp+18h] [bp-18h] _DWORD v43[4]; // [sp+1Ch] [bp-14h] BYREF v4 = cocos2d::CCNode::init((cocos2d::CCNode *)this); if ( v4 ) { *(this + 66) = a2; cocos2d::CCRect::CCRect((cocos2d::CCRect *)v43, 0.0, 0.0, 80.0, 80.0); v5 = cocos2d::extension::CCScale9Sprite::create("GJ_square01.png", v43); v6 = *(void (__fastcall **)(int, _DWORD *))(*(_DWORD *)v5 + 160); cocos2d::CCSize::CCSize((cocos2d::CCSize *)v43, 36.0, 148.0); v6(v5, v43); (*((void (__fastcall **)(Slider **, int))*this + 57))(this, v5); v7 = *(void (__fastcall **)(int, _DWORD *))(*(_DWORD *)v5 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v43, 0.0, -14.0); v7(v5, v43); v9 = cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)"Time", "goldFont.fnt", v8); (*(void (__fastcall **)(int, int))(*(_DWORD *)v9 + 80))(v9, 1051931443); (*((void (__fastcall **)(Slider **, int, int))*this + 58))(this, v9, 1); v10 = *(void (__fastcall **)(int, _DWORD *))(*(_DWORD *)v9 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v43, 0.0, 47.0); v10(v9, v43); v41 = TimeSpeedControl::timeSliderChanged; v42 = 0; v11 = (SliderTouchLogic **)Slider::create((int)this, (int)TimeSpeedControl::timeSliderChanged, 0, 0.5); *(this + 67) = (Slider *)v11; Slider::setRotated(v11, 1, v12, v13); Slider::setBarVisibility(*(this + 67), 1); Slider::setSnap(*(this + 67), 0.47368, 0.03); Slider::setMaxOffset((SliderTouchLogic **)*(this + 67), 140.0); v14 = *((_DWORD *)*(this + 67) + 81); v15 = *(void (__fastcall **)(int, _DWORD))(*(_DWORD *)v14 + 64); v16 = COERCE_FLOAT((*(int (__fastcall **)(int))(*(_DWORD *)v14 + 68))(v14)); v15(v14, v16 * 0.7); (*((void (__fastcall **)(Slider **, _DWORD, int))*this + 58))(this, *(this + 67), 1); v17 = (float)(*((float *)*(this + 66) + 2787) - 0.1) / 1.9; if ( v17 >= 1.0 ) { v17 = 1.0; } else if ( v17 <= 0.0 ) { v17 = 0.0; } Slider::setValue(*(this + 67), v17); v19 = (Slider *)cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)"1.0x", "bigFont.fnt", v18); *(this + 68) = v19; (*(void (__fastcall **)(Slider *, int))(*(_DWORD *)v19 + 80))(v19, 1050253722); (*((void (__fastcall **)(Slider **, _DWORD, int))*this + 58))(this, *(this + 68), 1); v20 = (int)*(this + 68); v21 = *(void (__fastcall **)(int, _DWORD *))(*(_DWORD *)v20 + 92); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v43, 0.0, -48.0); v21(v20, v43); v22 = (int)*(this + 68); v23 = *(int (__fastcall **)(int, int))(*(_DWORD *)v22 + 464); v25 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat( (cocos2d::CCString *)"%.01fx", v24, *((float *)*(this + 66) + 2787)); CString = cocos2d::CCString::getCString(v25); v27 = (cocos2d::CCMenu *)v23(v22, CString); v28 = cocos2d::CCMenu::create(v27); (*(void (__fastcall **)(int, void *))(*(_DWORD *)v28 + 92))(v28, &unk_D2E700); v29 = (GameManager *)(*((int (__fastcall **)(Slider **, int, int))*this + 58))(this, v28, 1); v30 = (GameManager *)GameManager::sharedState(v29); LOBYTE(v23) = GameManager::getGameVariable(v30, "0183"); v32 = cocos2d::CCSprite::createWithSpriteFrameName((cocos2d::CCSprite *)"GJ_musicOnBtn_001.png", v31); v34 = cocos2d::CCSprite::createWithSpriteFrameName((cocos2d::CCSprite *)"GJ_musicOffBtn_001.png", v33); (*(void (__fastcall **)(int, int))(*(_DWORD *)v32 + 80))(v32, 1055286886); (*(void (__fastcall **)(int, int))(*(_DWORD *)v34 + 80))(v34, 1055286886); v43[1] = 0; v43[0] = TimeSpeedControl::onAudioTimeSpeedToggle; v35 = CCMenuItemToggler::create(v34, v32, (int)this, (int)TimeSpeedControl::onAudioTimeSpeedToggle, 0); *(this + 69) = v35; CCMenuItemToggler::toggle(v35, (unsigned __int8)v23 ^ 1); (*(void (__fastcall **)(int, _DWORD))(*(_DWORD *)v28 + 228))(v28, *(this + 69)); v36 = (int)*(this + 69); v37 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v36 + 92); v38 = (*(int (__fastcall **)(_DWORD))(*(_DWORD *)*(this + 68) + 96))(*(this + 68)); cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v40, 0.0, *(float *)(v38 + 4) - 20.0); v37(v36, v40); } return v4; }
GD Web Decomp Icon

GD Web Decomp

Raw Source