//
// FMOD::Sound::getNumSubSounds from 0xd8fcc to 0xd9040 (116 bytes)
//
// 4 xrefs:
// > FMOD::Sound::getNumSubSounds @ 0x10724c
// > ??> @ 0x6fd0
// > FMOD::Sound::getNumSubSounds @ 0x107244
// > ??> @ 0x1101e8
//
// This function is hookable on this platform (idp: arm, 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 12:14:54 +0000
//
__int64 __fastcall FMOD::Sound::getNumSubSounds(FMOD::Sound *this, int *a2)
{
unsigned int v2; // w21
char v3; // w8
__int64 v4; // x0
__int64 v6; // x0
int v7; // w8
char v8; // zf
__int64 v9; // x0
__int64 v10; // x8
_BYTE v11[296]; // [xsp+8h] [xbp-138h] BYREF
v2 = sub_DA3DC(this, a2);
if ( !v2 )
{
v6 = sub_DA368();
if ( !v7 || (v6 = sub_DA358(v6), v8) )
{
v9 = sub_DA478(v6);
v2 = (*(__int64 (__fastcall **)(__int64))(v10 + 168))(v9);
if ( !v2 )
return v2;
}
else
{
v2 = 46;
}
}
sub_DA344();
if ( v3 < 0 )
{
v4 = sub_DA540(v11);
sub_DA388(v4);
}
return v2;
}