//
// sub_180108F80 from 0x180108f80 to 0x180108ffa (122 bytes)
//
// 2 xrefs:
// > ??> @ 0x1801b07e8
// > ??> @ 0x180201688
//
// 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 10:54:32 +0000
//
__int64 __fastcall sub_180108F80(__int64 *a1, int a2, int *a3, _BYTE *a4)
{
__int64 v5; // r9
int v6; // edx
__int64 v8; // rax
int v9; // r9d
v5 = *a1;
v6 = a2 - 2;
if ( v6 )
{
if ( v6 != 1 )
return 31;
v8 = *(int *)(v5 + 760);
*a3 = v8;
if ( a4 )
{
sub_1800B7D20(a4, off_1801B0730[v8], 32);
return 0;
}
}
else
{
v9 = *(_DWORD *)(v5 + 748);
*a3 = v9;
if ( a4 )
sub_1800B7CA0((int)a4, 32, "%d", v9);
}
return 0;
}