//
// GJBaseGameLayer::getGroundHeight from 0x100100060 to 0x100100163 (259 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:21:20 +0000
//
float __fastcall GJBaseGameLayer::getGroundHeight(__int64 a1, __int64 a2, unsigned int a3)
{
__m128 v3; // xmm0
__int64 v4; // rcx
__m128 v5; // xmm2
__int64 v6; // rbx
float v7; // xmm0_4
float v9; // [rsp+0h] [rbp-20h]
v3 = (__m128)0x43960000u;
while ( a3 - 23 < 2 )
{
a3 = *(_DWORD *)(a1 + 1256);
if ( a3 - 23 < 2 )
goto LABEL_12;
}
if ( a3 <= 0x29 )
{
v4 = 0x20004080020LL;
if ( _bittest64(&v4, a3) )
{
if ( *(_BYTE *)(a1 + 1010) != 1 )
return v3.f32[0];
goto LABEL_13;
}
if ( a3 == 16 )
{
v3 = (__m128)0x43700000u;
if ( *(_BYTE *)(a1 + 1010) != 1 )
return v3.f32[0];
goto LABEL_13;
}
}
LABEL_12:
v3 = (__m128)0x43870000u;
if ( *(_BYTE *)(a1 + 1010) != 1 )
return v3.f32[0];
LABEL_13:
v5 = _mm_cmpeq_ss((__m128)0x43700000u, v3);
LODWORD(v9) = _mm_andnot_ps(v5, v3).u32[0] | v5.i32[0] & 0x43870000;
v6 = *(_QWORD *)(a1 + 8LL * (*(_DWORD *)(a2 + 916) == *(_DWORD *)(*(_QWORD *)(a1 + 3256) + 916LL)) + 3256);
if ( (unsigned __int8)PlayerObject::isFlying(v6) )
{
v7 = 300.0;
}
else if ( *(_BYTE *)(v6 + 2419) )
{
v7 = 240.0;
}
else
{
v7 = 270.0;
}
v3.f32[0] = fmaxf(v7, v9);
return v3.f32[0];
}