//
// sub_1800DDBD0 from 0x1800ddbd0 to 0x1800ddc6f (159 bytes)
//
// 2 xrefs:
// > FMOD::SoundGroup::getSound @ 0x1800aaac9
// > ??> @ 0x1801ff66c
//
// 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:54:14 +0000
//
__int64 __fastcall sub_1800DDBD0(__int64 a1, int a2, _QWORD *a3)
{
int v3; // ebx
_QWORD *v7; // rax
v3 = 0;
if ( !a3 )
return 31;
*a3 = 0;
FMOD_OS_CriticalSection_Enter(*((struct _RTL_CRITICAL_SECTION **)off_1801AED20 + 36));
v7 = *(_QWORD **)(a1 + 40);
if ( v7 == (_QWORD *)(a1 + 40) )
{
LABEL_5:
FMOD_OS_CriticalSection_Leave(*((struct _RTL_CRITICAL_SECTION **)off_1801AED20 + 36));
return 31;
}
while ( v3 != a2 )
{
v7 = (_QWORD *)*v7;
++v3;
if ( v7 == (_QWORD *)(a1 + 40) )
goto LABEL_5;
}
*a3 = v7[2];
FMOD_OS_CriticalSection_Leave(*((struct _RTL_CRITICAL_SECTION **)off_1801AED20 + 36));
return 0;
}