//
// EditorSoundConfigInfoLayer::buildSummary from 0x785f24 to 0x786210 (748 bytes)
//
// 3 xrefs:
// > EditorSoundConfigInfoLayer::downloadEditorSoundFinished @ 0x786318
// > EditorSoundConfigInfoLayer::init @ 0x787864
// > EditorSoundConfigInfoLayer::FLAlert_Clicked @ 0x7888aa
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:59:32 +0000
//
void __fastcall EditorSoundConfigInfoLayer::buildSummary(EditorSoundConfigInfoLayer *this)
{
int v2; // r2
const char *v3; // r2
int v4; // r1
int v5; // r3
char *v6; // r1
int v7; // r1
float v8; // s16
unsigned int i; // r10
char *v10; // r0
int v11; // r6
cocos2d::CCLabelBMFont *v12; // r4
void (__fastcall *v13)(cocos2d::CCLabelBMFont *, char *); // r11
void (__fastcall *v14)(cocos2d::CCLabelBMFont *, char *); // r3
const char *v15; // r2
cocos2d::CCString *v16; // r0
const char *CString; // r6
size_t v18; // r0
const char *v19; // r2
cocos2d::CCLabelBMFont *v20; // r0
int v21; // r6
void (__fastcall *v22)(int, char *); // r11
void (__fastcall *v23)(int, char *); // r3
void (__fastcall *v24)(cocos2d::CCLabelBMFont *, char *); // r11
float v25; // s16
float v26; // s18
float v27; // r0
void (__fastcall *v28)(int, char *); // r4
float v29; // s16
float v30; // r1
int v31; // [sp+24h] [bp-40h] BYREF
float v32; // [sp+28h] [bp-3Ch] BYREF
float v33; // [sp+2Ch] [bp-38h]
char v34; // [sp+30h] [bp-34h] BYREF
char v35; // [sp+31h] [bp-33h]
char v36; // [sp+32h] [bp-32h]
_DWORD v37[3]; // [sp+38h] [bp-2Ch] BYREF
char **v38; // [sp+44h] [bp-20h] BYREF
char **v39; // [sp+48h] [bp-1Ch]
int v40[2]; // [sp+50h] [bp-14h] BYREF
cocos2d::CCLabelBMFont *v41; // [sp+58h] [bp-Ch]
v2 = *((_DWORD *)this + 206);
if ( v2 )
{
v31 = *(_DWORD *)(v2 + 320);
(*(void (__fastcall **)(int, int))(*(_DWORD *)v31 + 292))(v31, 1);
cocos2d::CCSize::CCSize((cocos2d::CCSize *)&v32, (const cocos2d::CCSize *)(*((_DWORD *)this + 206) + 324));
v4 = *((_DWORD *)this + 187);
v37[0] = &v32;
v37[1] = &v31;
v37[2] = this;
if ( v4 && *(_BYTE *)(v4 + 384) )
{
std::string::basic_string(v40, v4 + 372);
EditorSFXManager::summarizeBlob((int)&v38, (unsigned __int8 *)v40);
std::string::~string((int)v40);
if ( v38 == v39 )
{
sub_7848C4((int)v37, (cocos2d::CCLabelBMFont *)"No sounds in this pack.", (const char *)v38, (int)v39);
}
else
{
v8 = -8.0;
for ( i = 0; i < ((char *)v39 - (char *)v38) >> 4; ++i )
{
v10 = (char *)EditorSFXManager::actionToString((EditorSFXManager *)v38[4 * i], v7);
v11 = v38[4 * i + 2] - v38[4 * i + 1];
if ( !v10 )
v10 = "Action";
v12 = (cocos2d::CCLabelBMFont *)cocos2d::CCLabelBMFont::create(
(cocos2d::CCLabelBMFont *)v10,
"bigFont.fnt",
"Action");
v13 = *(void (__fastcall **)(cocos2d::CCLabelBMFont *, char *))(*(_DWORD *)v12 + 148);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v34, 0.0, 0.5);
v13(v12, &v34);
(*(void (__fastcall **)(cocos2d::CCLabelBMFont *, int))(*(_DWORD *)v12 + 80))(v12, 1051260355);
cocos2d::CCLabelBMFont::limitLabelWidth(v12, v32 - 90.0, 0.33, 0.2);
v14 = *(void (__fastcall **)(cocos2d::CCLabelBMFont *, char *))(*(_DWORD *)v12 + 536);
v34 = -1;
v35 = -36;
v36 = 120;
v14(v12, &v34);
v15 = "Sounds";
if ( v11 >> 2 == 1 )
v15 = "Sound";
v16 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(
(cocos2d::CCString *)": %d %s",
(const char *)(v11 >> 2),
v15,
"Sound");
CString = (const char *)cocos2d::CCString::getCString(v16);
v40[0] = 0;
v40[1] = 0;
v41 = nullptr;
v18 = strlen(CString);
std::string::__init(v40, CString, v18);
if ( (v40[0] & 1) != 0 )
v20 = v41;
else
v20 = (cocos2d::CCLabelBMFont *)((char *)v40 + 1);
v21 = cocos2d::CCLabelBMFont::create(v20, "bigFont.fnt", v19);
v22 = *(void (__fastcall **)(int, char *))(*(_DWORD *)v21 + 148);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v34, 0.0, 0.5);
v22(v21, &v34);
(*(void (__fastcall **)(int, int))(*(_DWORD *)v21 + 80))(v21, 1051260355);
v23 = *(void (__fastcall **)(int, char *))(*(_DWORD *)v21 + 536);
v34 = 120;
v35 = -1;
v36 = -116;
v23(v21, &v34);
v24 = *(void (__fastcall **)(cocos2d::CCLabelBMFont *, char *))(*(_DWORD *)v12 + 92);
v25 = v8 - 9.0;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v34, 12.0, v25);
v24(v12, &v34);
(*(void (__fastcall **)(int, cocos2d::CCLabelBMFont *))(*(_DWORD *)v31 + 228))(v31, v12);
v26 = *(float *)(*(int (__fastcall **)(cocos2d::CCLabelBMFont *))(*(_DWORD *)v12 + 164))(v12);
v27 = (*(float (__fastcall **)(cocos2d::CCLabelBMFont *))(*(_DWORD *)v12 + 68))(v12);
v28 = *(void (__fastcall **)(int, char *))(*(_DWORD *)v21 + 92);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v34, (float)((float)(v26 * v27) + 12.0) + 4.0, v25);
v28(v21, &v34);
(*(void (__fastcall **)(int, int))(*(_DWORD *)v31 + 228))(v31, v21);
v8 = v25 - 9.0;
std::string::~string((int)v40);
}
v29 = 8.0 - v8;
if ( v29 >= v33 )
v30 = v29;
else
v30 = v33;
ScrollableContentLayer::setContentHeight(*((ScrollableContentLayer **)this + 206), v30);
}
std::__vector_base>>::~__vector_base(&v38);
}
else
{
v5 = *((unsigned __int8 *)this + 764);
if ( *((_BYTE *)this + 764) )
{
v6 = "Loading...";
}
else if ( v4 )
{
v5 = *(_DWORD *)(v4 + 264);
if ( v5 <= 0 )
v6 = "No sound data.";
else
v6 = "Loading...";
}
else
{
v6 = "No sound data.";
}
sub_7848C4((int)v37, (cocos2d::CCLabelBMFont *)v6, v3, v5);
}
}
}