//
// SetupSequenceTriggerPopup::onChangeOrder from 0x1004de880 to 0x1004de916 (150 bytes)
//
// 1 xrefs:
// > SetupSequenceTriggerPopup::init @ 0x1004dde30
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
void __fastcall SetupSequenceTriggerPopup::onChangeOrder(SetupSequenceTriggerPopup *a1, cocos2d::CCObject *a2)
{
int v2; // r14d
SequenceTriggerGameObject *m_gameObject; // r12
int v4; // eax
_BOOL4 v5; // r15d
CCMenuItemSpriteExtra *m_selectedButton; // r14
int v7; // eax
if ( a1->m_selectedButton )
{
v2 = ((__int64 (__fastcall *)(cocos2d::CCObject *))a2->getTag)(a2);
m_gameObject = (SequenceTriggerGameObject *)a1->m_gameObject;
v4 = ((__int64 (__fastcall *)(CCMenuItemSpriteExtra *))a1->m_selectedButton->getTag)(a1->m_selectedButton);
if ( SequenceTriggerGameObject::reorderTarget(m_gameObject, v4, v2 != 3) )
{
v5 = v2 == 3;
m_selectedButton = a1->m_selectedButton;
v7 = ((__int64 (__fastcall *)(CCMenuItemSpriteExtra *))m_selectedButton->getTag)(m_selectedButton);
((void (__fastcall *)(CCMenuItemSpriteExtra *, _QWORD))m_selectedButton->setTag)(
m_selectedButton,
(unsigned int)(v7 + 2 * v5 - 1));
SetupSequenceTriggerPopup::updateGroupIDButtons(a1);
}
}
}