//
// sub_180097C30 from 0x180097c30 to 0x180097d37 (263 bytes)
//
// 3 xrefs:
// > sub_180012140 @ 0x180012277
// > FMOD::DSP::getParameterData @ 0x1800a2aea
// > ??> @ 0x1801faa34
//
// 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_180097C30(__int64 a1, int a2, _QWORD *a3, _DWORD *a4, __int64 a5, unsigned int a6)
{
char *v6; // rdi
__int64 v7; // r11
__int64 v11; // r10
__int64 result; // rax
__int64 v13; // rcx
int v14; // [rsp+30h] [rbp-68h] BYREF
__int64 v15; // [rsp+38h] [rbp-60h] BYREF
char v16; // [rsp+40h] [rbp-58h] BYREF
v6 = nullptr;
v7 = a2;
v15 = 0;
v14 = 0;
if ( (int)v7 < 0 )
return 31;
v11 = *(_QWORD *)(a1 + 232);
if ( !v11 || (int)v7 >= *(_DWORD *)(v11 + 96) )
return 31;
if ( !*(_QWORD *)(v11 + 168) )
return 68;
if ( **(_DWORD **)(*(_QWORD *)(v11 + 104) + 8 * v7) != 3 )
return 31;
v16 = 0;
v13 = a1 + 176;
*(_QWORD *)(a1 + 176) = a1;
if ( a5 || !*(_DWORD *)(a1 + 256) )
v6 = &v16;
result = (*(__int64 (__fastcall **)(__int64, _QWORD, __int64 *, int *, char *))(v11 + 168))(
v13,
(unsigned int)v7,
&v15,
&v14,
v6);
if ( !(_DWORD)result )
{
if ( a3 )
*a3 = v15;
if ( a4 )
*a4 = v14;
if ( a5 )
sub_1800B7D20(a5, v6, a6);
return 0;
}
return result;
}