//
// sub_10042F0F0 from 0x10042f0f0 to 0x10042f22d (317 bytes)
//
// 1 xrefs:
// > SFXBrowser::init @ 0x10042d73d
//
// 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 12:30:21 +0000
//
__int64 __fastcall sub_10042F0F0(__int64 a1)
{
__int64 result; // rax
__int64 v2; // rcx
unsigned int v3; // eax
__int64 v4; // rbx
_QWORD v5[2]; // [rsp+0h] [rbp-20h] BYREF
void *__p; // [rsp+10h] [rbp-10h]
result = GameManager::sharedState();
if ( *(_QWORD *)(result + 552) )
{
result = *(_QWORD *)(GameManager::sharedState() + 552);
if ( *(_QWORD *)(result + 3272) )
{
v2 = *(_QWORD *)(*(_QWORD *)(GameManager::sharedState() + 552) + 3272LL);
v3 = *(unsigned __int8 *)(v2 + 608);
if ( (v3 & 1) != 0 )
{
result = *(_QWORD *)(v2 + 616);
if ( !result )
return result;
}
else
{
result = v3 >> 1;
if ( !result )
return result;
}
__p = operator new(0x70u);
v5[0] = 113;
v5[1] = 104;
strcpy(
(char *)__p,
"This deletes your custom SFX folders and replaces them with this level's shared setup. Continue?");
v4 = FLAlertLayer::create_1(a1 + 696, "Replace SFX Folders", v5, "Cancel", "Replace", 300.0);
if ( (v5[0] & 1) != 0 )
operator delete(__p);
(*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v4 + 72LL))(v4, 11);
return (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v4 + 1312LL))(v4);
}
}
return result;
}