//
// sub_180071060 from 0x180071060 to 0x18007109b (59 bytes)
//
// 1 xrefs:
// > ??> @ 0x1801ad230
//
// 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:53:30 +0000
//
__int64 __fastcall sub_180071060(__int64 *a1, int a2, unsigned int a3)
{
__int64 v3; // r9
__int64 result; // rax
unsigned int v5; // edx
unsigned int v6; // ecx
v3 = *a1;
if ( a2 )
{
v5 = *(_DWORD *)(v3 + 1160);
if ( v5 )
{
result = 0;
v6 = v5 - a3;
if ( v5 <= a3 )
v6 = 0;
*(_DWORD *)(v3 + 1160) = v6;
}
else
{
return 11;
}
}
else
{
*(_DWORD *)(v3 + 1160) = 4;
return 0;
}
return result;
}