// // cocos2d::CCMenu::alignItemsHorizontallyWithPadding from 0x7dbfa0 to 0x7dc116 (374 bytes) // // 11 xrefs: // > FLAlertLayer::init @ 0x3cc164 // > CCTextInputMenu::init @ 0x3dbc6a // > MenuLayer::init @ 0x3fa3aa // > PauseLayer::customSetup @ 0x490e8c // > EditLevelLayer::init @ 0x4a1678 // > GJGarageLayer::setupPage @ 0x50f498 // > GJGarageLayer::setupIconSelect @ 0x50fc8a // > GJTransformControl::init @ 0x6efa1e // > EditorUI::setupCreateMenu @ 0x70c17c // > DailyRecallUnlockPopup::init @ 0x742de6 // > cocos2d::CCMenu::alignItemsHorizontally @ 0x7dc12a // // 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 12:00:45 +0000 // float __fastcall cocos2d::CCMenu::alignItemsHorizontallyWithPadding(cocos2d::CCMenu *this, float a2) { cocos2d::CCArray *v4; // r0 float v5; // s16 int v6; // r3 _DWORD *v7; // r3 const void **v8; // r4 const void **v9; // r5 float result; // r0 const void *v11; // r0 const void *v12; // t1 void *v13; // r0 void *v14; // r9 float v15; // s17 int v16; // r3 _DWORD *v17; // r3 int v18; // r4 float *v19; // r3 unsigned int v20; // r5 float *v21; // r8 float v22; // s16 float v23; // t1 float v24; // r4 void (__fastcall *v25)(_DWORD, float *); // r10 float v26; // s19 float v27; // r0 float v28; // s19 float v29[2]; // [sp+Ch] [bp-Ch] BYREF v4 = *((cocos2d::CCArray **)this + 48); v5 = -a2; if ( v4 ) { if ( cocos2d::CCArray::count(v4) ) { v6 = *((_DWORD *)this + 48); if ( v6 ) { v7 = *(_DWORD **)(v6 + 52); if ( *v7 ) { v8 = (const void **)v7[3]; v9 = &v8[*v7] + 0x3FFFFFFF; while ( v8 <= v9 ) { v12 = *v8++; v11 = v12; if ( !v12 ) break; v13 = _dynamic_cast( v11, (const struct __class_type_info *)&`typeinfo for'cocos2d::CCObject, (const struct __class_type_info *)&`typeinfo for'cocos2d::CCNode, 0); v14 = v13; if ( v13 ) { v15 = *(float *)(*(int (__fastcall **)(void *))(*(_DWORD *)v13 + 164))(v13); v5 = v5 + (float)(a2 + (float)(v15 * (*(float (__fastcall **)(void *))(*(_DWORD *)v14 + 68))(v14))); } } } } } } result = *((float *)this + 48); if ( result != 0.0 ) { result = COERCE_FLOAT(cocos2d::CCArray::count((cocos2d::CCArray *)LODWORD(result))); if ( result != 0.0 ) { v16 = *((_DWORD *)this + 48); if ( v16 ) { v17 = *(_DWORD **)(v16 + 52); if ( *v17 ) { v18 = *v17 + 0x40000000; v19 = (float *)v17[3]; v20 = (unsigned int)&v19[v18 - 1]; v21 = v19; v22 = -(float)(v5 * 0.5); while ( (unsigned int)v21 <= v20 ) { v23 = *v21++; result = v23; if ( v23 == 0.0 ) break; result = COERCE_FLOAT( _dynamic_cast( (const void *)LODWORD(result), (const struct __class_type_info *)&`typeinfo for'cocos2d::CCObject, (const struct __class_type_info *)&`typeinfo for'cocos2d::CCNode, 0)); v24 = result; if ( result != 0.0 ) { v25 = *(void (__fastcall **)(_DWORD, float *))(*(_DWORD *)LODWORD(result) + 92); v26 = *(float *)(*(int (__fastcall **)(float))(*(_DWORD *)LODWORD(result) + 164))(COERCE_FLOAT(LODWORD(result))); v27 = (*(float (__fastcall **)(float))(*(_DWORD *)LODWORD(v24) + 68))(COERCE_FLOAT(LODWORD(v24))); cocos2d::CCPoint::CCPoint(v29, v22 + (float)((float)(v26 * v27) * 0.5), 0.0); v25(LODWORD(v24), v29); v28 = *(float *)(*(int (__fastcall **)(float))(*(_DWORD *)LODWORD(v24) + 164))(COERCE_FLOAT(LODWORD(v24))); result = (*(float (__fastcall **)(float))(*(_DWORD *)LODWORD(v24) + 68))(COERCE_FLOAT(LODWORD(v24))); v22 = v22 + (float)(a2 + (float)(v28 * result)); } } } } } } return result; }
GD Web Decomp Icon

GD Web Decomp

Raw Source