// // LevelSelectLayer::getColorValue from 0x100421dc0 to 0x100421ff8 (568 bytes) // // 1 xrefs: // > LevelSelectLayer::scrollLayerMoved @ 0x100421cd9 // // This function is hookable on this platform (idp: pc, 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:30:16 +0000 // __int64 __fastcall LevelSelectLayer::getColorValue(float a1, __int64 a2, unsigned int a3, unsigned int a4) { unsigned int v4; // ebx float v5; // xmm0_4 int v6; // r14d double v7; // xmm2_8 int v8; // r14d __int64 v9; // rax __int64 v10; // rax float v11; // xmm0_4 int v12; // ebx __int64 v13; // rax v4 = a4; v5 = fmaxf(fminf((float)(a1 / 0.66666669) + -0.2, 1.0), 0.0); if ( a3 && a3 == 22 * ((int)a3 / 22) ) { v6 = 3419173; v7 = v5; if ( !a4 ) goto LABEL_12; } else { while ( a3 >= 9 ) a3 = (int)a3 % 9; v8 = dword_100A0A308[a3]; v9 = GameManager::sharedState(); v6 = GameManager::colorForIdx(v9, v8); v7 = v5; if ( !v4 ) goto LABEL_12; } LODWORD(v10) = 3419173; if ( !((int)v4 % 22) ) { v11 = 0.0; if ( v7 <= 0.2 ) return ((int)(float)((float)((float)((v6 & 0xFF0000u) >> 16) * (float)(1.0 - v11)) + (float)((float)(((unsigned int)v10 & 0xFF0000) >> 16) * v11)) << 16) | ((unsigned __int8)(int)(float)((float)((float)BYTE1(v6) * (float)(1.0 - v11)) + (float)((float)BYTE1(v10) * v11)) << 8) | (unsigned int)(unsigned __int8)(int)(float)((float)((float)(unsigned __int8)v6 * (float)(1.0 - v11)) + (float)((float)(unsigned __int8)v10 * v11)); goto LABEL_14; } LABEL_12: while ( v4 >= 9 ) v4 = (int)v4 % 9; v12 = dword_100A0A308[v4]; v13 = GameManager::sharedState(); v10 = GameManager::colorForIdx(v13, v12); v11 = 0.0; if ( v7 > 0.2 ) { LABEL_14: if ( v7 >= 0.8 ) v11 = 1.0; else v11 = (v7 + -0.2) / 0.6; } return ((int)(float)((float)((float)((v6 & 0xFF0000u) >> 16) * (float)(1.0 - v11)) + (float)((float)(((unsigned int)v10 & 0xFF0000) >> 16) * v11)) << 16) | ((unsigned __int8)(int)(float)((float)((float)BYTE1(v6) * (float)(1.0 - v11)) + (float)((float)BYTE1(v10) * v11)) << 8) | (unsigned int)(unsigned __int8)(int)(float)((float)((float)(unsigned __int8)v6 * (float)(1.0 - v11)) + (float)((float)(unsigned __int8)v10 * v11)); }
GD Web Decomp Icon

GD Web Decomp

Raw Source