//
// SetupSequenceTriggerPopup::updateGroupIDButtons from 0x10026b29c to 0x10026b58c (752 bytes)
//
// 4 xrefs:
// > SetupSequenceTriggerPopup::init @ 0x10026af70
// > sub_10026B0E0 @ 0x10026b198
// > SetupSequenceTriggerPopup::onDeleteSelected @ 0x10026b1e4
// > sub_10026B1E8 @ 0x10026b288
//
// 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 11:01:43 +0000
//
void __fastcall SetupSequenceTriggerPopup::updateGroupIDButtons(_QWORD *a1)
{
__int64 v2; // x0
unsigned int v3; // w0
__int64 v4; // x21
__int64 v5; // x20
__int64 v6; // x0
__int64 v7; // x26
unsigned __int64 v8; // x27
__int64 v9; // x0
unsigned int v10; // w28
float v11; // s9
__int64 v12; // x20
float v13; // s0
__n128 v14; // q0
__int64 v15; // x8
__int64 v16; // x24
unsigned __int64 v17; // x20
__int64 v18; // x21
__int64 v19; // x9
int v20; // w8
int v21; // w9
__int64 v22; // x0
const std::string::value_type *v23; // x0
__int64 v24; // x1
__int64 v25; // x0
const std::string::value_type *CString; // x0
std::string *v27; // x0
const char *v28; // x5
void *v29; // x0
__int64 v30; // x25
double v31; // d0
float32x2_t v32; // [xsp+18h] [xbp-98h] BYREF
float32x2_t v33; // [xsp+20h] [xbp-90h] BYREF
std::string v34; // [xsp+28h] [xbp-88h] BYREF
float32x2_t v35; // [xsp+40h] [xbp-70h] BYREF
__int64 v36; // [xsp+48h] [xbp-68h] BYREF
v2 = a1[127];
if ( v2 )
{
v3 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v2 + 64LL))(v2);
a1[127] = 0;
v4 = v3;
}
else
{
v4 = 0xFFFFFFFFLL;
}
if ( (unsigned int)sub_1002E757C(a1[129]) )
{
v5 = 0;
do
{
v6 = sub_1002E75A0(a1[129], v5);
(*(void (__fastcall **)(__int64))(*(_QWORD *)v6 + 520LL))(v6);
v5 = (unsigned int)(v5 + 1);
}
while ( (unsigned int)v5 < (unsigned int)sub_1002E757C(a1[129]) );
}
sub_1002E7674(a1[129]);
v7 = a1[85];
v8 = *(_QWORD *)(v7 + 1848) - *(_QWORD *)(v7 + 1840);
v9 = cocos2d::CCDirector::sharedDirector();
cocos2d::CCDirector::getWinSize(v9, &v36);
if ( v8 <= 0xA0 )
v10 = 5;
else
v10 = 10;
if ( v8 <= 0xA0 )
v11 = 66.0;
else
v11 = 35.0;
v12 = a1[69];
v13 = -2.0;
if ( v8 > 0xA0 )
v13 = -4.5;
sub_1000262BC(
(float *)&v34,
(float)(*(float *)&v36 * 0.5) + (float)(v13 * v11),
(float)(*((float *)&v36 + 1) * 0.5) + 34.0);
cocos2d::CCNode::convertToNodeSpace(&v35, v12, &v34, v14);
v15 = *(_QWORD *)(v7 + 1840);
if ( *(_QWORD *)(v7 + 1848) != v15 )
{
v16 = 0;
v17 = 0;
v18 = 16 * v4;
do
{
v19 = v15 + v16;
memset(&v34, 0, sizeof(v34));
v20 = *(_DWORD *)(v15 + v16);
v21 = *(_DWORD *)(v19 + 8);
if ( v8 <= 0xA0 )
{
v25 = sub_1003065B0("%i-%i", v20, v21);
CString = (const std::string::value_type *)cocos2d::CCString::getCString(v25);
std::string::assign(&v34, CString);
v24 = 40;
}
else
{
v22 = sub_1003065B0("%i\n%i", v20, v21);
v23 = (const std::string::value_type *)cocos2d::CCString::getCString(v22);
std::string::assign(&v34, v23);
v24 = 15;
}
if ( (v34.__r_.__value_.__r.__words[2] & 0x8000000000000000LL) == 0LL )
v27 = &v34;
else
v27 = (std::string *)v34.__r_.__value_.__r.__words[0];
if ( v18 == v16 )
v28 = "GJ_button_03.png";
else
v28 = "GJ_button_04.png";
v29 = ButtonSprite::create_1((__int64)v27, v24, 0, 1, (__int64)"bigFont.fnt", (__int64)v28, 0.35, 30.0);
v30 = CCMenuItemSpriteExtra::create(v29, 0, a1, SetupSequenceTriggerPopup::onSelect, 0);
(*(void (__fastcall **)(__int64, unsigned __int64))(*(_QWORD *)v30 + 72LL))(v30, v17);
(*(void (__fastcall **)(_QWORD, __int64))(*(_QWORD *)a1[69] + 456LL))(a1[69], v30);
sub_1000262BC((float *)&v32, v11 * (float)((unsigned int)v17 % v10), (float)((unsigned int)v17 / v10) * -38.0);
*(float32x2_t *)&v31 = sub_100026318(&v35, &v32, &v33);
(*(void (__fastcall **)(__int64, float32x2_t *, double))(*(_QWORD *)v30 + 184LL))(v30, &v33, v31);
sub_1002E74E0(a1[129], v30);
if ( v18 == v16 )
a1[127] = v30;
if ( SHIBYTE(v34.__r_.__value_.__r.__words[2]) < 0 )
operator delete(v34.__r_.__value_.__l.__data_);
if ( v17 > 0x12 )
break;
++v17;
v15 = *(_QWORD *)(v7 + 1840);
v16 += 16;
}
while ( (*(_QWORD *)(v7 + 1848) - v15) >> 4 > v17 );
}
}