//
// PlayerObject::hardFlipGravity from 0x1003fa700 to 0x1003fa790 (144 bytes)
//
// 1 xrefs:
// > GJBaseGameLayer::checkRepellPlayer @ 0x100131731
//
// 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:29:59 +0000
//
__int64 __fastcall PlayerObject::hardFlipGravity(__int64 a1, double a2)
{
__int64 result; // rax
__m128d v3; // xmm0
double v4; // xmm1_8
__m128d v5; // xmm3
result = PlayerObject::flipGravity(a1, *(_BYTE *)(a1 + 2423) ^ 1u, 1, a2);
if ( *(_BYTE *)(a1 + 2423) )
v3 = (__m128d)0x4000000000000000uLL;
else
v3 = (__m128d)0xC000000000000000LL;
v4 = _mm_cvtepi32_pd(_mm_cvttpd_epi32(v3)).f64[0];
if ( v3.f64[0] != v4 )
{
v3.f64[0] = (v3.f64[0] - v4) * 1000.0;
v5 = _mm_or_pd(_mm_and_pd((__m128d)xmmword_100A04960, v3), (__m128d)xmmword_100A04D50);
v5.f64[0] = v5.f64[0] + v3.f64[0];
v3.f64[0] = _mm_round_sd((__m128d)0LL, v5, 11).f64[0] / 1000.0 + v4;
}
*(double *)(a1 + 2392) = v3.f64[0];
return result;
}