//
// FMODAudioEngine::countActiveMusic from 0x1001b7d94 to 0x1001b7dfc (104 bytes)
//
// 2 xrefs:
// > PlayLayer::updateInfoLabel @ 0x100140b34
// > FMODAudioEngine::countActiveEffects @ 0x1001b7d80
//
// 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 11:00:11 +0000
//
__int64 __fastcall FMODAudioEngine::countActiveMusic(__int64 a1)
{
_QWORD *v1; // x20
__int64 v2; // x19
_BYTE v4[8]; // [xsp+8h] [xbp-48h] BYREF
int v5; // [xsp+10h] [xbp-40h]
void *__p; // [xsp+20h] [xbp-30h]
char v7; // [xsp+37h] [xbp-19h]
v1 = *(_QWORD **)(a1 + 336);
if ( !v1 )
return 0;
LODWORD(v2) = 0;
do
{
sub_1001BC290(v4, v1 + 2);
if ( v5 <= 0 )
v2 = (unsigned int)v2;
else
v2 = (unsigned int)(v2 + 1);
if ( v7 < 0 )
operator delete(__p);
v1 = (_QWORD *)*v1;
}
while ( v1 );
return v2;
}