//
// SongInfoObject::getTagsString from 0x9718bc to 0x971c44 (904 bytes)
//
// 3 xrefs:
// > CustomSongWidget::updateSongInfo @ 0x869e18
// > SongInfoLayer::create @ 0x9064d4
// > ??> @ 0x73498
//
// 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 12:57:41 +0000
//
__int64 *__usercall SongInfoObject::getTagsString@(
__int64 *__return_ptr a1@,
SongInfoObject *this@,
unsigned __int8 a3@)
{
int v4; // w28
char *v6; // x19
__int64 v7; // x1
char *v8; // x25
MusicDownloadManager *v9; // x19
MusicDownloadManager *v10; // x0
int v11; // w22
int v12; // w23
int v13; // w21
MusicDownloadManager *v14; // x0
unsigned __int8 v15; // w2
char *v16; // x1
size_t v17; // x2
char *v18; // x19
size_t v19; // x2
char *v20; // x1
__int64 v21; // x1
__int64 v22; // x1
__int64 v23; // x1
MusicDownloadManager *v25; // x1
MusicDownloadManager *v26; // x1
cocos2d::CCString *v27; // x0
size_t v28; // x0
size_t v29; // x2
char *v30; // x1
char *CString; // [xsp+68h] [xbp+68h]
__int64 v32; // [xsp+78h] [xbp+78h] BYREF
size_t v33; // [xsp+80h] [xbp+80h]
void *v34; // [xsp+88h] [xbp+88h]
__int64 v35; // [xsp+90h] [xbp+90h] BYREF
size_t v36; // [xsp+98h] [xbp+98h]
void *v37; // [xsp+A0h] [xbp+A0h]
v4 = a3;
if ( !a3 )
{
v6 = (char *)this + 648;
v7 = *((_BYTE *)this + 648) >> 1;
if ( (*((_BYTE *)this + 648) & 1) != 0 )
v7 = *((_QWORD *)this + 82);
if ( !v7 )
goto LABEL_5;
*a1 = 0;
a1[1] = 0;
a1[2] = 0;
if ( (*((_BYTE *)this + 648) & 1) != 0 )
{
LABEL_37:
std::string::__init(a1, *((void **)v6 + 2), *((_QWORD *)v6 + 1));
return a1;
}
LABEL_31:
v23 = *((_QWORD *)v6 + 1);
*a1 = *(_QWORD *)v6;
a1[1] = v23;
a1[2] = *((_QWORD *)v6 + 2);
return a1;
}
v6 = (char *)this + 672;
v22 = *((_BYTE *)this + 672) >> 1;
if ( (*((_BYTE *)this + 672) & 1) != 0 )
v22 = *((_QWORD *)this + 85);
if ( v22 )
{
*a1 = 0;
a1[1] = 0;
a1[2] = 0;
if ( (*((_BYTE *)this + 672) & 1) != 0 )
goto LABEL_37;
goto LABEL_31;
}
LABEL_5:
if ( *((_QWORD *)this + 80) )
{
v32 = 0;
v33 = 0;
v8 = (char *)this + 632;
v34 = nullptr;
std::string::__init(&v32, &byte_11B8890, 0);
v9 = *((MusicDownloadManager **)this + 78);
v10 = (MusicDownloadManager *)", ";
v11 = 0;
v12 = 1;
while ( v8 != (char *)v9 )
{
v13 = *((_DWORD *)v9 + 7);
v14 = (MusicDownloadManager *)MusicDownloadManager::sharedState(v10);
MusicDownloadManager::nameForTagID(v14, v13, &v35);
v15 = v35;
if ( (v35 & 1) != 0 )
{
if ( !v36 )
goto LABEL_41;
if ( v12 )
goto LABEL_11;
}
else
{
if ( !((int)(unsigned __int8)v35 >> 1) )
goto LABEL_15;
if ( v12 )
{
LABEL_40:
v17 = v15 >> 1;
v16 = (char *)&v35 + 1;
goto LABEL_12;
}
}
std::string::append((__int64)&v32, ", ", 2u);
v15 = v35;
if ( (v35 & 1) == 0 )
goto LABEL_40;
LABEL_11:
v16 = (char *)v37;
v17 = v36;
LABEL_12:
std::string::append((__int64)&v32, v16, v17);
if ( ++v11 > 3 && v4 )
{
if ( (int)(*((_QWORD *)this + 80) - v11) > 0 )
{
v27 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(
(cocos2d::CCString *)" +%i",
(const char *)((unsigned int)*((_QWORD *)this + 80) - v11));
CString = (char *)cocos2d::CCString::getCString(v27);
v28 = strlen(CString);
std::string::append((__int64)&v32, CString, v28);
}
if ( (v35 & 1) != 0 )
operator delete(v37);
LABEL_49:
v18 = (char *)this + 672;
if ( (__int64 *)((char *)this + 672) != &v32 )
{
if ( (v32 & 1) != 0 )
{
v30 = (char *)v34;
v29 = v33;
}
else
{
v29 = (unsigned __int8)v32 >> 1;
v30 = (char *)&v32 + 1;
}
std::string::assign((__int64 *)this + 84, v30, v29);
}
*a1 = 0;
a1[1] = 0;
a1[2] = 0;
if ( (*((_BYTE *)this + 672) & 1) != 0 )
goto LABEL_54;
LABEL_24:
v21 = *((_QWORD *)v18 + 1);
*a1 = *(_QWORD *)v18;
a1[1] = v21;
a1[2] = *((_QWORD *)v18 + 2);
goto LABEL_25;
}
v12 = 0;
if ( (v35 & 1) != 0 )
LABEL_41:
operator delete(v37);
LABEL_15:
v10 = *((MusicDownloadManager **)v9 + 1);
if ( !v10 )
{
do
{
v25 = v9;
v9 = *((MusicDownloadManager **)v9 + 2);
v10 = *(MusicDownloadManager **)v9;
if ( v25 == *(MusicDownloadManager **)v9 )
break;
v26 = v9;
v9 = *((MusicDownloadManager **)v9 + 2);
v10 = *(MusicDownloadManager **)v9;
}
while ( v26 != *(MusicDownloadManager **)v9 );
continue;
}
do
{
v9 = v10;
v10 = *(MusicDownloadManager **)v10;
}
while ( v10 );
}
if ( v4 )
goto LABEL_49;
v18 = (char *)this + 648;
if ( (__int64 *)((char *)this + 648) != &v32 )
{
if ( (v32 & 1) != 0 )
{
v20 = (char *)v34;
v19 = v33;
}
else
{
v19 = (unsigned __int8)v32 >> 1;
v20 = (char *)&v32 + 1;
}
std::string::assign((__int64 *)this + 81, v20, v19);
}
*a1 = 0;
a1[1] = 0;
a1[2] = 0;
if ( (*((_BYTE *)this + 648) & 1) == 0 )
goto LABEL_24;
LABEL_54:
std::string::__init(a1, *((void **)v18 + 2), *((_QWORD *)v18 + 1));
LABEL_25:
if ( (v32 & 1) != 0 )
operator delete(v34);
}
else
{
*a1 = 0;
a1[1] = 0;
a1[2] = 0;
std::string::__init(a1, &byte_11B8890, 0);
}
return a1;
}