//
// sub_59724 from 0x59724 to 0x59794 (112 bytes)
//
// 1 xrefs:
// > FMOD::System::getSpeakerPosition @ 0xb8900
//
// 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
//
int __fastcall sub_59724(int a1, int a2, _DWORD *a3, _DWORD *a4, _BYTE *a5)
{
int v5; // r5
v5 = *(_DWORD *)(a1 + 69188);
if ( v5 != 5 )
{
if ( v5 != 4 )
goto LABEL_10;
if ( (a2 | 1) != 3 )
{
if ( (a2 | 1) == 5 )
a2 -= 2;
goto LABEL_10;
}
return 31;
}
if ( a2 == 3 )
return 31;
if ( (a2 | 1) == 5 )
--a2;
LABEL_10:
if ( a2 >= *(_DWORD *)(a1 + 1188) )
return 31;
if ( a3 )
*a3 = *(_DWORD *)(a1 + 48 * a2 + 69200);
if ( a4 )
*a4 = *(_DWORD *)(a1 + 48 * a2 + 69208);
if ( a5 )
*a5 = *(_BYTE *)(a1 + 48 * a2 + 69232);
return 0;
}