//
// EditorSoundConfigInfoLayer::soundPackDescSaved from 0x1008f7b20 to 0x1008f7ddd (701 bytes)
//
// 2 xrefs:
// > sub_1008F7E40 @ 0x1008f7e4c
// > ??> @ 0x100bb60b0
//
// 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:37:59 +0000
//
void __fastcall EditorSoundConfigInfoLayer::soundPackDescSaved(__int64 a1, std::string *a2, std::string *a3)
{
__int64 v3; // r15
__int64 v6; // r15
std::string::pointer data; // rdi
__int64 v8; // rax
__int64 v9; // rax
int v10; // ecx
__int64 v11; // rax
__int64 v12; // r15
__int64 v13; // rax
int v14; // r12d
__int128 *v15; // rax
char v16; // r14
__int64 v17; // rax
char *v18; // rax
std::string __str; // [rsp+0h] [rbp-B0h] BYREF
__int128 v20; // [rsp+18h] [rbp-98h] BYREF
void *v21; // [rsp+28h] [rbp-88h]
std::string v22; // [rsp+30h] [rbp-80h] BYREF
std::string v23; // [rsp+50h] [rbp-60h] BYREF
__int128 v24; // [rsp+70h] [rbp-40h] BYREF
void *v25; // [rsp+80h] [rbp-30h]
v3 = *(_QWORD *)(a1 + 1088);
if ( !v3 )
return;
if ( (*(_BYTE *)&a2->__r_.__value_.__s.0 & 1) != 0 )
sub_10001AD30(&v22, a2->__r_.__value_.__l.__data_, a2->__r_.__value_.__l.__size_);
else
v22 = *a2;
LevelTools::base64EncodeString(&__str, &v22);
std::string::operator=((std::string *)(v3 + 400), &__str);
if ( (*(_BYTE *)&__str.__r_.__value_.__s.0 & 1) == 0 )
{
if ( (*(_BYTE *)&v22.__r_.__value_.__s.0 & 1) == 0 )
goto LABEL_7;
LABEL_10:
operator delete(v22.__r_.__value_.__l.__data_);
v6 = *(_QWORD *)(a1 + 1088);
if ( (*(_BYTE *)&a3->__r_.__value_.__s.0 & 1) == 0 )
goto LABEL_8;
LABEL_11:
sub_10001AD30(&v23, a3->__r_.__value_.__l.__data_, a3->__r_.__value_.__l.__size_);
goto LABEL_12;
}
operator delete(__str.__r_.__value_.__l.__data_);
if ( (*(_BYTE *)&v22.__r_.__value_.__s.0 & 1) != 0 )
goto LABEL_10;
LABEL_7:
v6 = *(_QWORD *)(a1 + 1088);
if ( (*(_BYTE *)&a3->__r_.__value_.__s.0 & 1) != 0 )
goto LABEL_11;
LABEL_8:
v23 = *a3;
LABEL_12:
data = (std::string::pointer)(v6 + 424);
std::string::operator=((std::string *)(v6 + 424), &v23);
if ( (*(_BYTE *)&v23.__r_.__value_.__s.0 & 1) != 0 )
{
data = v23.__r_.__value_.__l.__data_;
operator delete(v23.__r_.__value_.__l.__data_);
}
if ( *(_QWORD *)(a1 + 1088) )
{
if ( GJAccountManager::sharedState((__int64)data, (__int64)&v23) )
{
v8 = GJAccountManager::sharedState((__int64)data, (__int64)&v23);
if ( *(_DWORD *)(v8 + 352) > *(_DWORD *)(v8 + 356) )
{
v9 = GJAccountManager::sharedState((__int64)data, (__int64)&v23);
v10 = *(_DWORD *)(v9 + 352) - *(_DWORD *)(v9 + 356);
v11 = *(_QWORD *)(a1 + 1088);
if ( v10 == *(_DWORD *)(v11 + 340) && *(int *)(v11 + 316) > 0 && *(_DWORD *)(a1 + 1096) != 2 )
{
*(_QWORD *)(GameLevelManager::sharedState() + 1360) = a1 + 1064;
v12 = GameLevelManager::sharedState();
v13 = *(_QWORD *)(a1 + 1088);
v14 = *(_DWORD *)(v13 + 316);
if ( (*(_BYTE *)(v13 + 400) & 1) != 0 )
{
sub_10001AD30(&v24, *(const void **)(v13 + 416), *(_QWORD *)(v13 + 408));
}
else
{
v15 = (__int128 *)(v13 + 400);
v25 = *((void **)v15 + 2);
v24 = *v15;
}
v16 = sub_10055CCC0(v12, v14);
if ( (v24 & 1) != 0 )
operator delete(v25);
if ( v16 )
{
v17 = *(_QWORD *)(a1 + 1200);
if ( v17 )
{
*(_QWORD *)(v17 + 664) = 0;
*(_QWORD *)(a1 + 1200) = 0;
}
v21 = operator new(0x1Au);
*(_QWORD *)&v20 = 27;
*((_QWORD *)&v20 + 1) = 23;
strcpy((char *)v21, "Updating description...");
v18 = UploadActionPopup::create(a1 + 1072, &v20);
*(_QWORD *)(a1 + 1200) = v18;
if ( (v20 & 1) != 0 )
{
operator delete(v21);
v18 = *(char **)(a1 + 1200);
}
(*(void (__fastcall **)(char *))(*(_QWORD *)v18 + 1312LL))(v18);
}
}
}
}
}
}