// // LevelEditorLayer::updateObjectColors from 0x78bd64 to 0x78c294 (1328 bytes) // // 3 xrefs: // > LevelEditorLayer::manualUpdateObjectColors @ 0x78c2dc // > GJSmartBlockPreview::addPreview @ 0xb0d82c // > @ 0xff280 // // This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True! // // 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:53:27 +0000 // __int64 __fastcall LevelEditorLayer::updateObjectColors(LevelEditorLayer *this, cocos2d::CCArray *a2) { unsigned int v4; // w22 unsigned __int8 *v5; // x0 unsigned __int64 v6; // x0 __int64 v7; // x19 __int64 MainColor; // x23 GJEffectManager *v9; // x26 int MainColorMode; // w0 int v11; // s0 signed int v12; // w26 int v13; // w23 GJEffectManager *v14; // x0 int active; // w0 int v16; // w3 unsigned int v17; // w1 __int64 v18; // x27 unsigned int GroupID; // w0 __int64 v20; // x0 signed int v21; // w1 __int64 v22; // x1 int v23; // w0 float v24; // s0 float v25; // s8 signed int v26; // w23 unsigned int v27; // w1 GJEffectManager *v28; // x26 int v29; // w0 float v30; // s0 int v32; // w23 signed int v33; // w28 unsigned int v34; // w1 __int64 v35; // x27 unsigned int v36; // w0 __int64 v37; // x0 signed int v38; // w1 __int64 v39; // x1 int v40; // w0 float v41; // s0 float v42; // s8 signed int v43; // w23 unsigned int v44; // w1 GJEffectManager *v45; // x26 int v46; // w0 float v47; // s0 __int64 SecondaryColor; // x23 GJEffectManager *v49; // x26 int SecondaryColorMode; // w0 int v51; // s0 __int64 v52; // x0 int v53; // w1 int v54; // w0 unsigned __int64 v55; // [xsp+70h] [xbp+70h] int v56; // [xsp+80h] [xbp+80h] __int64 v57; // [xsp+88h] [xbp+88h] BYREF __int64 v58; // [xsp+90h] [xbp+90h] BYREF v4 = 0; v5 = (unsigned __int8 *)(*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 493) + 944LL))(*((_QWORD *)this + 493)); v6 = GameToolbox::transformColor(v5, 0.0, -0.3, 0.4); LOWORD(v56) = v6; BYTE2(v56) = BYTE2(v6); while ( v4 < (unsigned int)cocos2d::CCArray::count(a2) ) { v7 = cocos2d::CCArray::objectAtIndex(a2, v4); MainColor = GameObject::getMainColor((GameObject *)v7); v9 = *((GJEffectManager **)this + 269); MainColorMode = GameObject::getMainColorMode((GameObject *)v7); GJEffectManager::activeOpacityForIndex(v9, MainColorMode); *(_DWORD *)(MainColor + 8) = v11; if ( GameObject::hasSecondaryColor((GameObject *)v7) ) { SecondaryColor = GameObject::getSecondaryColor((GameObject *)v7); v49 = *((GJEffectManager **)this + 269); SecondaryColorMode = GameObject::getSecondaryColorMode((GameObject *)v7); GJEffectManager::activeOpacityForIndex(v49, SecondaryColorMode); *(_DWORD *)(SecondaryColor + 8) = v51; } v12 = 0; v13 = GameObject::getMainColorMode((GameObject *)v7); v14 = *((GJEffectManager **)this + 269); LOWORD(v57) = -1; BYTE2(v57) = -1; active = GJEffectManager::activeColorForIndex(v14, v13); v16 = *(__int16 *)(v7 + 1168); LOWORD(v57) = active; BYTE2(v57) = BYTE2(active); if ( v16 > 0 ) { do { v17 = v12; v18 = *((_QWORD *)this + 269); ++v12; GroupID = GameObject::getGroupID((GameObject *)v7, v17); v20 = GJEffectManager::colorForGroupID(v18, GroupID, &v57, *(unsigned __int8 *)(v7 + 1038) ^ 1u); v21 = *(__int16 *)(v7 + 1168); LOWORD(v57) = v20; BYTE2(v57) = BYTE2(v20); } while ( v21 > v12 ); } v22 = *(_QWORD *)(v7 + 1096); if ( *(float *)(v22 + 16) != *(float *)&dword_155C6B0 || *(float *)(v22 + 20) != *(float *)&dword_155C6B4 || *(float *)(v22 + 24) != *(float *)&dword_155C6B8 || *(unsigned __int16 *)(v22 + 28) != (unsigned __int16)word_155C6BC ) { v23 = GJEffectManager::colorForEffect(*((_QWORD *)this + 269), v57, *(_QWORD *)(v22 + 16), *(_QWORD *)(v22 + 24)); LOWORD(v57) = v23; BYTE2(v57) = BYTE2(v23); } (*(void (__fastcall **)(__int64, __int64 *))(*(_QWORD *)v7 + 1584LL))(v7, &v57); if ( v13 <= 0 ) { v25 = 1.0; } else { GJEffectManager::activeOpacityForIndex(*((GJEffectManager **)this + 269), v13); v25 = v24; } if ( *(__int16 *)(v7 + 1168) > 0 ) { v26 = 0; do { v27 = v26; v28 = *((GJEffectManager **)this + 269); ++v26; v29 = GameObject::getGroupID((GameObject *)v7, v27); GJEffectManager::opacityModForGroup(v28, v29); v25 = v25 * v30; } while ( *(__int16 *)(v7 + 1168) > v26 ); } *(float *)(*(_QWORD *)(v7 + 1096) + 8LL) = v25; if ( !GameObject::hasSecondaryColor((GameObject *)v7) ) goto LABEL_17; v32 = GameObject::getSecondaryColorMode((GameObject *)v7); LOWORD(v58) = -1; BYTE2(v58) = -1; if ( v32 == 1012 ) { v55 = v55 & 0xFFFF000000000000LL | 0x1003E19999ALL; v54 = GJEffectManager::colorForEffect(*((_QWORD *)this + 269), v57, 0x3F26666600000000LL, v55); LOWORD(v58) = v54; BYTE2(v58) = BYTE2(v54); } else if ( v32 > 0 ) { v52 = GJEffectManager::activeColorForIndex(*((GJEffectManager **)this + 269), v32); v53 = *(__int16 *)(v7 + 1168); LOWORD(v58) = v52; BYTE2(v58) = BYTE2(v52); if ( v53 > 0 ) { LABEL_25: v33 = 0; do { v34 = v33; v35 = *((_QWORD *)this + 269); ++v33; v36 = GameObject::getGroupID((GameObject *)v7, v34); v37 = GJEffectManager::colorForGroupID(v35, v36, &v58, 0); v38 = *(__int16 *)(v7 + 1168); LOWORD(v58) = v37; BYTE2(v58) = BYTE2(v37); } while ( v38 > v33 ); } } else if ( *(__int16 *)(v7 + 1168) > 0 ) { goto LABEL_25; } v39 = *(_QWORD *)(v7 + 1104); if ( *(float *)(v39 + 16) != *(float *)&dword_155C6B0 || *(float *)(v39 + 20) != *(float *)&dword_155C6B4 || *(float *)(v39 + 24) != *(float *)&dword_155C6B8 || *(unsigned __int16 *)(v39 + 28) != (unsigned __int16)word_155C6BC ) { v40 = GJEffectManager::colorForEffect(*((_QWORD *)this + 269), v58, *(_QWORD *)(v39 + 16), *(_QWORD *)(v39 + 24)); LOWORD(v58) = v40; BYTE2(v58) = BYTE2(v40); } (*(void (__fastcall **)(__int64, __int64 *))(*(_QWORD *)v7 + 1592LL))(v7, &v58); if ( v32 <= 0 ) { v42 = 1.0; } else { GJEffectManager::activeOpacityForIndex(*((GJEffectManager **)this + 269), v32); v42 = v41; } if ( *(__int16 *)(v7 + 1168) > 0 ) { v43 = 0; do { v44 = v43; v45 = *((GJEffectManager **)this + 269); ++v43; v46 = GameObject::getGroupID((GameObject *)v7, v44); GJEffectManager::opacityModForGroup(v45, v46); v42 = v42 * v47; } while ( *(__int16 *)(v7 + 1168) > v43 ); } *(float *)(*(_QWORD *)(v7 + 1104) + 8LL) = v42; LABEL_17: ++v4; if ( *(_BYTE *)(v7 + 887) ) AnimatedGameObject::updateChildSpriteColor(v7, v56); } return _stack_chk_guard; }
GD Web Decomp Icon

GD Web Decomp

Raw Source