//
// sub_5B594 from 0x5b594 to 0x5b5e8 (84 bytes)
//
// 1 xrefs:
// > FMOD::System::getRecordPosition @ 0xba254
//
// 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_5B594(int a1, int a2, _DWORD *a3)
{
int result; // r0
int v7; // r0
int v8; // r1
int v9; // r1
bool v10; // zf
result = sub_5B0B8(a1);
if ( !result )
{
if ( a2 < 0 || *(_DWORD *)(a1 + 1144) <= a2 )
{
return 31;
}
else
{
v7 = *(_DWORD *)(a1 + 1156);
if ( a3 )
{
v8 = *(_DWORD *)(v7 + 44 * a2 + 40);
if ( v8 )
v9 = *(_DWORD *)(v8 + 48);
else
v9 = 0;
*a3 = v9;
}
v10 = *(unsigned __int8 *)(v7 + 44 * a2 + 20) << 31 == 0;
result = 0;
if ( v10 )
return 80;
}
}
return result;
}