//
// GameLevelManager::onMuteUserCompleted from 0x14024f920 to 0x14024fb0e (494 bytes)
//
// 2 xrefs:
// > GameLevelManager::handleIt @ 0x14021b4f3
// > ??> @ 0x14091c46c
//
// 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:28:42 +0000
//
// Hidden C++ exception states: #wind=2
void __fastcall GameLevelManager::onMuteUserCompleted(__int64 a1, const void **a2, _QWORD *a3, char a4)
{
_BYTE *v8; // rdx
__int64 v9; // rdx
__int64 v10; // rcx
__int64 v11; // r8
__int64 v12; // r9
unsigned __int64 v13; // rax
size_t v14; // rax
size_t v15; // r8
_QWORD *v16; // rdx
const char *v17; // rcx
unsigned int v18; // r15d
char *v19; // r8
const void *v20; // rcx
unsigned __int64 v21; // rbp
size_t v22; // r8
__int64 v23; // rcx
__int64 v24; // rcx
__int64 v25; // rcx
char *String[2]; // [rsp+48h] [rbp-50h] BYREF
__int128 v27; // [rsp+58h] [rbp-40h]
v8 = a3;
if ( a3[3] > 0xFu )
v8 = (_BYTE *)*a3;
GameLevelManager::removeDLFromActive(a1, v8);
*(_OWORD *)String = 0;
v27 = 0;
v13 = a3[2];
if ( v13 < 5 )
sub_14003F4D0(v10, v9, v11, v12);
v14 = v13 - 5;
v15 = -1;
if ( v14 != -1 )
v15 = v14;
v16 = a3;
if ( a3[3] > 0xFu )
v16 = (_QWORD *)*a3;
sub_14003D230(String, (char *)v16 + 5, v15);
v17 = (const char *)String;
if ( *((_QWORD *)&v27 + 1) > 0xFu )
v17 = String[0];
v18 = atoi(v17);
if ( *((_QWORD *)&v27 + 1) > 0xFu )
{
v19 = String[0];
if ( (unsigned __int64)(*((_QWORD *)&v27 + 1) + 1LL) >= 0x1000 )
{
v19 = *((char **)String[0] - 1);
if ( (unsigned __int64)(String[0] - v19 - 8) > 0x1F )
invoke_watson(nullptr, nullptr, nullptr, 0, 0);
}
j_j_free(v19);
}
*(_OWORD *)String = 0;
*(_QWORD *)&v27 = 2;
*((_QWORD *)&v27 + 1) = 15;
strcpy((char *)String, "-1");
v20 = a2;
if ( (unsigned __int64)a2[3] > 0xF )
v20 = *a2;
v21 = (unsigned __int64)a2[2];
v22 = v21;
if ( v21 > 2 )
v22 = 2;
if ( !memcmp(v20, String, v22) && v21 == 2 )
{
if ( a4 )
{
v23 = *(_QWORD *)(a1 + 528);
if ( v23 )
(*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v23 + 40LL))(v23, v18);
}
}
else
{
GameLevelManager::resetStoredUserList(a1, 4);
v24 = *(_QWORD *)(a1 + 1496);
if ( v24 )
(*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v24 + 24LL))(v24, 4);
if ( a4 )
{
v25 = *(_QWORD *)(a1 + 528);
if ( v25 )
(*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v25 + 32LL))(v25, v18);
}
}
sub_14003D310((__int64)a2);
sub_14003D310((__int64)a3);
}