//
// sub_10096B850 from 0x10096b850 to 0x10096b9a4 (340 bytes)
//
// 2 xrefs:
// > ScrollableContentLayer::applyContentPosition @ 0x10096b156
// > sub_10096B820 @ 0x10096b83e
//
// 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:50 +0000
//
__int64 __fastcall sub_10096B850(__int64 a1)
{
__int64 result; // rax
__int64 v2; // rdi
__int64 (__fastcall *v3)(__int64, __int64); // rcx
__int64 v4; // r15
float v5; // xmm2_4
float v6; // xmm1_4
__int64 v7; // rbx
__int64 v8; // rbx
float v9; // [rsp-2Ch] [rbp-2Ch] BYREF
float v10; // [rsp-24h] [rbp-24h]
result = a1;
v2 = *(_QWORD *)(a1 + 488);
if ( v2 )
{
v3 = *(__int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v2 + 344LL);
if ( (float)(*(float *)(result + 432) - *(float *)(result + 4LL * (*(unsigned __int8 *)(result + 584) ^ 1u) + 424)) <= 0.0 )
{
return v3(v2, 0);
}
else
{
v4 = result;
v10 = *(float *)(result + 432) - *(float *)(result + 4LL * (*(unsigned __int8 *)(result + 584) ^ 1u) + 424);
v3(v2, 1);
v5 = *(float *)(v4 + 428) + -6.0;
v6 = fminf(v5, fmaxf(8.0, (float)(*(float *)(v4 + 428) / *(float *)(v4 + 432)) * v5));
v10 = (float)(*(float *)(v4 + 428) + -3.0)
- (float)(fminf(1.0, fmaxf(0.0, *(float *)(v4 + 436) / v10)) * (float)(v5 - v6));
v7 = *(_QWORD *)(v4 + 488);
sub_100278260(&v9, 3.0, v6);
(*(void (__fastcall **)(__int64, float *))(*(_QWORD *)v7 + 320LL))(v7, &v9);
v8 = *(_QWORD *)(v4 + 488);
sub_100278250(&v9, (float)(*(float *)(v4 + 424) + -2.0) + *(float *)(v4 + 500), v10 + *(float *)(v4 + 504));
return (*(__int64 (__fastcall **)(__int64, float *))(*(_QWORD *)v8 + 184LL))(v8, &v9);
}
}
return result;
}