//
// FMODAudioEngine::stopAllEffects from 0x1400598e0 to 0x1400599f2 (274 bytes)
//
// 13 xrefs:
// > FMODAudioEngine::clearAllAudio @ 0x140055319
// > FMODAudioEngine::unloadAllEffects @ 0x140059ada
// > CustomSFXWidget::onPlayback @ 0x1400c1c6e
// > CustomSFXWidget::FLAlert_Clicked @ 0x1400c282f
// > EditorUI::onPlayback @ 0x140111c0b
// > LevelEditorLayer::onStopPlaytest @ 0x1402e0ddf
// > PlayLayer::destroyPlayer @ 0x1403b403a
// > PlayLayer::resetLevel @ 0x1403b8f97
// > PlayLayer::resumeAndRestart @ 0x1403ba437
// > SetupReverbPopup::onPlay @ 0x140446e24
// > SetupReverbPopup::onClose @ 0x1404470fb
// > SetupSFXPopup::onClose @ 0x1404485c0
// > ??> @ 0x1406c5244
//
// 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
//
void FMODAudioEngine::stopAllEffects(FMODAudioEngine *a1)
{
std::_List_val>>::_Nodeptr Myhead; // rdi
__int64 *i; // rbx
std::_List_val>>::_Nodeptr v4; // rdi
__int64 *j; // rbx
FMOD::ChannelControl::stop(a1->m_globalChannel);
Myhead = a1->m_globalChannelGroups._List._Mypair._Myval2._Myhead;
for ( i = *(__int64 **)Myhead; i != (__int64 *)Myhead; i = (__int64 *)*i )
{
FMOD::ChannelControl::stop((FMOD::ChannelControl *)i[3]);
FMOD::ChannelGroup::release((FMOD::ChannelGroup *)i[3]);
}
v4 = a1->m_reverbChannelGroups._List._Mypair._Myval2._Myhead;
for ( j = *(__int64 **)v4; j != (__int64 *)v4; j = (__int64 *)*j )
{
FMOD::ChannelControl::stop((FMOD::ChannelControl *)j[3]);
FMOD::ChannelGroup::release((FMOD::ChannelGroup *)j[3]);
}
sub_14005D290(&a1->m_globalChannelGroups);
sub_14005D290(&a1->m_reverbChannelGroups);
sub_14005E0D0(&a1->m_audioState.m_volumeForEffectGroups);
sub_14005E0D0(&a1->m_audioState.m_volumeModForEffectGroups);
sub_14005E0D0(&a1->m_audioState.m_pitchForEffectGroups);
sub_14005E0D0(&a1->m_audioState.m_volumeForEffectChannels);
sub_14005E0D0(&a1->m_audioState.m_volumeModForEffectChannels);
sub_14005E0D0(&a1->m_audioState.m_pitchForEffectChannels);
sub_14005E0D0(&a1->m_audioState.m_intervalForEffects);
}