//
// GameManager::removeIconDelegate from 0x71f3a0 to 0x71f4ac (268 bytes)
//
// 2 xrefs:
// > SimplePlayer::~SimplePlayer @ 0x8b9510
// > ??> @ 0xf7690
//
// 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:52:22 +0000
//
_QWORD *__fastcall GameManager::removeIconDelegate(_QWORD *this, int a2)
{
_QWORD *v2; // x22
_QWORD *v4; // x24
__int64 v5; // x2
int v6; // w21
char *v7; // x0
unsigned __int64 v8; // x19
__int64 v9; // x4
__int64 v10; // x3
char *v11; // x4
signed __int64 v12; // x20
char *v13; // x20
unsigned __int64 v14; // x0
char *v15; // x0
char *v16; // x20
v2 = this + 158;
v4 = (_QWORD *)*(this + 157);
if ( v4 != this + 158 )
{
do
{
v5 = v4[5];
v6 = 0;
v7 = (char *)v4[6];
v8 = 0;
v9 = (__int64)&v7[-v5];
while ( 1 )
{
v10 = v5 + 8 * v8;
if ( v8 >= v9 >> 3 )
break;
while ( *(_DWORD *)(*(_QWORD *)(v5 + 8 * v8) + 664LL) != a2 )
{
v8 = ++v6;
v10 = v5 + 8LL * v6;
if ( v6 >= (unsigned __int64)(v9 >> 3) )
goto LABEL_6;
}
v11 = v7;
v12 = (signed __int64)&v7[-v10 - 8];
if ( v12 >> 3 )
{
v15 = (char *)memmove((void *)v10, (const void *)(v10 + 8), v12);
v11 = (char *)v4[6];
v16 = &v15[v12];
v5 = v4[5];
v14 = ~((unsigned __int64)(v11 - 8 - v16) >> 3);
if ( v16 == v11 )
goto LABEL_12;
LABEL_10:
v7 = &v11[8 * v14];
v4[6] = v7;
v9 = (__int64)&v7[-v5];
}
else
{
v13 = v7 - 8;
v14 = -1;
if ( v13 != v11 )
goto LABEL_10;
LABEL_12:
v7 = v11;
v9 = (__int64)&v11[-v5];
}
}
LABEL_6:
this = std::__tree_next *>(v4);
v4 = this;
}
while ( v2 != this );
}
return this;
}