//
// TimeSpeedControl::timeSliderChanged from 0x100977b30 to 0x100977c4e (286 bytes)
//
// 1 xrefs:
// > TimeSpeedControl::init @ 0x100977869
//
// 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:38:56 +0000
//
__int64 __fastcall TimeSpeedControl::timeSliderChanged(__int64 a1, float *a2)
{
__m128 Value; // xmm0
__m128 v3; // xmm2
__int64 v4; // rax
int v5; // xmm0_4
__int64 v6; // r14
__int64 result; // rax
float v8; // xmm0_4
__int64 v9; // rbx
char *v10; // rax
__int64 CString; // rax
float v12; // [rsp+Ch] [rbp-14h]
Value = SliderThumb::getValue(a2);
Value.f32[0] = (float)((float)(Value.f32[0] * 1.9) + 0.1) * 10.0;
v3 = _mm_or_ps(_mm_and_ps((__m128)xmmword_100A035F0, Value), (__m128)xmmword_100A03600);
v3.f32[0] = v3.f32[0] + Value.f32[0];
v12 = _mm_round_ss((__m128)0LL, v3, 11).f32[0] / 10.0;
*(float *)(*(_QWORD *)(a1 + 320) + 13112LL) = v12;
v4 = GameManager::sharedState();
if ( (unsigned __int8)GameManager::getGameVariable(v4, "0183") )
v5 = 1065353216;
else
v5 = LODWORD(v12);
v6 = *(_QWORD *)(a1 + 320);
*(_DWORD *)(v6 + 13116) = v5;
result = GameManager::sharedState();
v8 = v12;
if ( v6 == *(_QWORD *)(result + 544) && v12 != 1.0 )
{
v8 = v12;
result = *(_QWORD *)(GameManager::sharedState() + 544);
*(_BYTE *)(result + 14186) = 1;
}
v9 = *(_QWORD *)(a1 + 336);
if ( v9 )
{
v10 = sub_10088E820("%.01fx", v8);
CString = cocos2d::CCString::getCString((__int64)v10);
return (*(__int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v9 + 928LL))(v9, CString);
}
return result;
}