//
// sub_1800E78E0 from 0x1800e78e0 to 0x1800e7969 (137 bytes)
//
// 2 xrefs:
// > FMOD::System::setSoftwareFormat @ 0x1800b19d3
// > ??> @ 0x1801fff24
//
// 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_1800E78E0(__int64 a1, int a2, int a3, int a4)
{
if ( *(_BYTE *)(a1 + 8) )
return 27;
if ( a2 && (unsigned int)(a2 - 8000) > 0x2CEC0 || a3 >= 9 || a3 == 1 && !a4 )
return 31;
if ( a4 > 32 )
return 64;
if ( a2 )
*(_DWORD *)(a1 + 1744) = a2;
*(_DWORD *)(a1 + 70452) = a3;
if ( a3 != 1 )
a4 = sub_180096E30(a3);
*(_DWORD *)(a1 + 1748) = a4;
return 0;
}