//
// sub_1800DDB50 from 0x1800ddb50 to 0x1800ddbc1 (113 bytes)
//
// 2 xrefs:
// > FMOD::SoundGroup::getNumSounds @ 0x1800aa9f0
// > ??> @ 0x1801ff660
//
// 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_1800DDB50(__int64 a1, _DWORD *a2)
{
_QWORD *v5; // rax
int i; // ecx
if ( !a2 )
return 31;
FMOD_OS_CriticalSection_Enter(*((struct _RTL_CRITICAL_SECTION **)off_1801AED20 + 36));
v5 = *(_QWORD **)(a1 + 40);
for ( i = 0; v5 != (_QWORD *)(a1 + 40); ++i )
v5 = (_QWORD *)*v5;
*a2 = i;
FMOD_OS_CriticalSection_Leave(*((struct _RTL_CRITICAL_SECTION **)off_1801AED20 + 36));
return 0;
}