//
// CreateParticlePopup::updateColorSprite from 0x100467f70 to 0x10046805b (235 bytes)
//
// 0 xrefs:
//
// 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:30 +0000
//
__int64 __fastcall CreateParticlePopup::updateColorSprite(_QWORD **a1, int a2)
{
__int64 result; // rax
float *v3; // rax
__m128 v4; // xmm0
__int64 *v5; // rdi
__int64 v6; // rax
char *v7; // rsi
float *v8; // rax
__m128 v9; // xmm0
_QWORD v10[2]; // [rsp+0h] [rbp-10h] BYREF
v10[0] = result;
if ( a2 == 2 )
{
v8 = (float *)(*(__int64 (__fastcall **)(_QWORD *))(*a1[89] + 1384LL))(a1[89]);
v9 = (__m128)*(unsigned __int64 *)v8;
BYTE6(v10[0]) = (int)(float)(255.0 * v8[2]);
WORD2(v10[0]) = ((unsigned __int8)(int)(float)(_mm_movehdup_ps(v9).f32[0] * 255.0) << 8)
| (unsigned __int8)(int)(float)(v9.f32[0] * 255.0);
v5 = a1[119];
v6 = *v5;
v7 = (char *)v10 + 4;
}
else
{
if ( a2 != 1 )
return result;
v3 = (float *)(*(__int64 (__fastcall **)(_QWORD *))(*a1[89] + 1352LL))(a1[89]);
v4 = (__m128)*(unsigned __int64 *)v3;
BYTE2(v10[0]) = (int)(float)(255.0 * v3[2]);
LOWORD(v10[0]) = ((unsigned __int8)(int)(float)(_mm_movehdup_ps(v4).f32[0] * 255.0) << 8)
| (unsigned __int8)(int)(float)(v4.f32[0] * 255.0);
v5 = a1[118];
v6 = *v5;
v7 = (char *)v10;
}
return (*(__int64 (__fastcall **)(__int64 *, char *))(v6 + 960))(v5, v7);
}