//
// GJEffectManager::calculateBaseActiveColors from 0x140365760 to 0x140365813 (179 bytes)
//
// 6 xrefs:
// > GJEffectManager::processColors @ 0x14036564c
// > GJEffectManager::loadFromState @ 0x14036f181
// > PlayLayer::loadDefaultColors @ 0x1405109d8
// > ??> @ 0x1408baa7c
// > ??> @ 0x1408baa8c
// > ??> @ 0x14092162c
//
// 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 11:30:54 +0000
//
void __fastcall GJEffectManager::calculateBaseActiveColors(__int64 a1)
{
__int64 v1; // rdi
__int64 v2; // rdi
__int64 i; // rbx
__int64 v4; // rdi
__int64 v5; // rax
unsigned __int16 v6; // cx
char v7; // dl
__int64 v8; // rax
float v9[6]; // [rsp+20h] [rbp-18h] BYREF
unsigned __int16 v10; // [rsp+40h] [rbp+8h] BYREF
char v11; // [rsp+42h] [rbp+Ah]
char v12; // [rsp+48h] [rbp+10h] BYREF
v1 = *(_QWORD *)(a1 + 336);
if ( v1 )
{
v2 = *(_QWORD *)(v1 + 56);
if ( v2 )
{
for ( i = *(_QWORD *)(v2 + 288); ; i = *(_QWORD *)(i + 288) )
{
v4 = *(_QWORD *)(v2 + 264);
v5 = *(_QWORD *)(v4 + 344);
v6 = *(_WORD *)(v4 + 324);
v7 = *(_BYTE *)(v4 + 326);
v10 = v6;
v11 = v7;
if ( v5 && *(int *)(v5 + 120) > 0 && !*(_BYTE *)(v5 + 126) )
{
*(_OWORD *)v9 = *(_OWORD *)(v5 + 104);
v8 = GameToolbox::transformColor((__int64)&v12, &v10, v9);
v6 = *(_WORD *)v8;
v7 = *(_BYTE *)(v8 + 2);
}
*(_WORD *)(v4 + 327) = v6;
*(_BYTE *)(v4 + 329) = v7;
v2 = i;
if ( !i )
break;
}
}
}
}