//
// sub_1800C9E90 from 0x1800c9e90 to 0x1800c9ee7 (87 bytes)
//
// 2 xrefs:
// > ??> @ 0x18016c670
// > ??> @ 0x1801fe418
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
__int64 __fastcall sub_1800C9E90(__int64 a1, int a2)
{
unsigned int v2; // ebx
__int64 result; // rax
v2 = a2;
result = sub_1800C7B70(a1, a2);
if ( !(_DWORD)result )
{
result = (*(__int64 (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 40) + 280LL))(*(_QWORD *)(a1 + 40), v2);
if ( !(_DWORD)result )
{
if ( (*(_DWORD *)(*(_QWORD *)(a1 + 40) + 88LL) & 0x80u) == 0 )
v2 &= 0xFFFFFFF8;
return (*(__int64 (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 192) + 192LL))(*(_QWORD *)(a1 + 192), v2);
}
}
return result;
}