//
// FMODAudioEngine::countActiveEffects from 0x1003e2f30 to 0x1003e3010 (224 bytes)
//
// 1 xrefs:
// > PlayLayer::updateInfoLabel @ 0x1000b078e
//
// 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 FMODAudioEngine::countActiveEffects(FMODAudioEngine *a1)
{
std::__hash_node_base, void *> *>::__next_pointer next; // r12
int i; // r15d
__int128 v3; // xmm0
int v4; // ebx
__int128 v6; // [rsp+20h] [rbp-50h] BYREF
void *__p; // [rsp+30h] [rbp-40h]
__int16 v8; // [rsp+38h] [rbp-38h]
unsigned __int64 value; // [rsp+40h] [rbp-30h]
value = a1->m_channelIDToChannel.__table_.__p2_.__value_;
next = a1->m_fmodMusic.__table_.__p1_.__value_.__next_;
for ( i = 0; next; next = next->__next_ )
{
v3 = *(_OWORD *)&next[3].__next_;
if ( ((__int64)next[5].__next_ & 1) != 0 )
{
sub_100006B70(&v6, next[7].__next_, (unsigned __int64)next[6].__next_, *(double *)&v3);
}
else
{
__p = next[7].__next_;
v6 = *(_OWORD *)&next[5].__next_;
}
v8 = (__int16)next[8].__next_;
v4 = 0;
if ( (v6 & 1) != 0 )
operator delete(__p);
LOBYTE(v4) = (int)v3 > 0;
i += v4;
}
return value - i;
}