//
// FMODAudioEngine::loadAndPlayMusic from 0x1001b9eb0 to 0x1001b9f6c (188 bytes)
//
// 3 xrefs:
// > CreateGuidelinesLayer::playMusic @ 0x100085cc8
// > FindBPMLayer::playMusic @ 0x100086ab4
// > SongOptionsLayer::onPlayback @ 0x1001c450c
//
// 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::loadAndPlayMusic(__int64 a1, __int64 a2, int a3, __int64 a4)
{
void *__p[2]; // [xsp+0h] [xbp-40h] BYREF
__int64 v9; // [xsp+10h] [xbp-30h]
if ( *(char *)(a2 + 23) < 0 )
{
sub_1000097D0(__p, *(void **)a2, *(_QWORD *)(a2 + 8));
}
else
{
*(_OWORD *)__p = *(_OWORD *)a2;
v9 = *(_QWORD *)(a2 + 16);
}
FMODAudioEngine::loadMusic(a1, (__int128 *)__p, 0, a4, 0, 0, 1.0, 0.0, 1.0);
if ( SHIBYTE(v9) < 0 )
operator delete(__p[0]);
if ( a3 )
FMODAudioEngine::setMusicTimeMS(a1, a3, 0, a4);
return FMODAudioEngine::resumeMusic(a1, a4);
}