//
// SetupReverbPopup::onPlay from 0x1405dc240 to 0x1405dc331 (241 bytes)
//
// 2 xrefs:
// > SetupReverbPopup::init @ 0x1405dc167
// > ??> @ 0x14092ec70
//
// This function is hookable on this platform (idp: pc, 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:34:59 +0000
//
// Hidden C++ exception states: #wind=3
__int64 __fastcall SetupReverbPopup::onPlay(__int64 a1)
{
_QWORD *v2; // rcx
__int64 result; // rax
__int64 v4; // rbx
__int64 v5; // rcx
__int64 v6; // rcx
void *v7; // [rsp+30h] [rbp+8h]
void *v8; // [rsp+30h] [rbp+8h]
void *v9; // [rsp+30h] [rbp+8h]
v2 = (_QWORD *)qword_14090BF60;
if ( !qword_14090BF60 )
{
v7 = operator new(0x8A8u);
qword_14090BF60 = FMODAudioEngine::FMODAudioEngine((__int64)v7);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BF60 + 72LL))(qword_14090BF60);
v2 = (_QWORD *)qword_14090BF60;
}
result = FMODAudioEngine::stopAllEffects(v2);
v4 = *(_QWORD *)(a1 + 680);
if ( v4 )
{
v5 = qword_14090BF60;
if ( !qword_14090BF60 )
{
v8 = operator new(0x8A8u);
qword_14090BF60 = FMODAudioEngine::FMODAudioEngine((__int64)v8);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BF60 + 72LL))(qword_14090BF60);
v5 = qword_14090BF60;
}
FMODAudioEngine::updateReverb(v5, *(_DWORD *)(v4 + 1992), 0);
if ( !qword_14090BFD0 )
{
v9 = operator new(0x6E8u);
qword_14090BFD0 = GameManager::GameManager((__int64)v9);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);
}
return GameManager::playSFXTrigger(v6, v4);
}
return result;
}