//
// sub_1800BF7F0 from 0x1800bf7f0 to 0x1800bf859 (105 bytes)
//
// 2 xrefs:
// > ??> @ 0x18016c118
// > ??> @ 0x1801fd9a4
//
// 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_1800BF7F0(__int64 a1, __int64 a2, int a3)
{
int v5; // eax
int v6; // [rsp+38h] [rbp+10h] BYREF
if ( !a2 || a3 != 1 )
return 2147942487LL;
if ( (*(unsigned int (__fastcall **)(_QWORD, int *))(**(_QWORD **)(a1 + 8) + 16LL))(*(_QWORD *)(a1 + 8), &v6) )
return 1;
v5 = v6;
*(_OWORD *)a2 = 0;
*(_OWORD *)(a2 + 16) = 0;
*(_OWORD *)(a2 + 32) = 0;
*(_OWORD *)(a2 + 48) = 0;
*(_OWORD *)(a2 + 64) = 0;
*(_DWORD *)(a2 + 16) = v5;
*(_DWORD *)(a2 + 8) = 2;
return 0;
}