//
// GJBaseGameLayer::opacityForObject from 0x140340290 to 0x140340322 (146 bytes)
//
// 5 xrefs:
// > ??> @ 0x14076b798
// > ??> @ 0x14078b210
// > ??> @ 0x1408b770c
// > ??> @ 0x1408b771c
// > ??> @ 0x14091fd24
//
// 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:39 +0000
//
__m128 __fastcall GJBaseGameLayer::opacityForObject(__int64 a1, __int64 a2)
{
int v2; // eax
__int128 v4; // xmm1
__int64 v5; // rdi
unsigned __int64 v6; // rbx
__int64 v7; // r14
__int64 v8; // rbp
__int64 v9; // rax
__int64 v10; // rdx
v2 = *(__int16 *)(a2 + 1176);
v4 = 0x3F800000u;
if ( *(__int16 *)(a2 + 1176) > 0 && v2 > 0 )
{
v5 = 0;
v6 = 0;
v7 = *(_QWORD *)(a1 + 2408);
v8 = (unsigned int)v2;
do
{
if ( v6 <= 9 && (v9 = *(_QWORD *)(a2 + 1168)) != 0 )
v10 = (unsigned int)*(__int16 *)(v5 + v9);
else
v10 = 0;
++v6;
*(float *)&v4 = *(float *)&v4 * GJEffectManager::opacityModForGroup(v7, v10);
v5 += 2;
--v8;
}
while ( v8 );
}
return (__m128)v4;
}