//
// GJUINode::updateButtonPositions from 0x10004ac18 to 0x10004acf4 (220 bytes)
//
// 5 xrefs:
// > GJUINode::loadFromConfig @ 0x100049924
// > GJUINode::init @ 0x10004ab1c
// > GJUINode::init @ 0x10004ab34
// > GJUINode::updateDragRadius @ 0x10004ad00
// > GJUINode::updateButtonScale @ 0x10004add0
//
// 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 GJUINode::updateButtonPositions(GJUINode *a1)
{
cocos2d::CCSprite_vtbl *v2; // x8
__n128 v3; // q0
cocos2d::CCSprite *m_firstSprite; // x20
float v5; // s8
float m_radius; // s9
__n128 v7; // q1
__n128 v8; // q0
cocos2d::CCSprite *m_secondSprite; // x19
__n128 v10; // q1
int v11; // [xsp+8h] [xbp-28h] BYREF
if ( a1->m_secondSprite )
{
v2 = a1->m_firstSprite->__vftable;
if ( a1->m_modeB )
{
((void (*)(void))v2->setPosition)();
}
else
{
v3.n128_f64[0] = ((double (*)(void))v2->getScale)();
m_firstSprite = a1->m_firstSprite;
v5 = v3.n128_f32[0] * m_firstSprite->m_obRect.size.width;
m_radius = a1->m_radius;
v3.n128_f32[0] = (float)(v5 * -0.5) - m_radius;
v7.n128_u32[0] = 0;
sub_100022980(v3, v7, &v11);
v8 = ((__n128 (__fastcall *)(cocos2d::CCSprite *, int *))m_firstSprite->setPosition)(m_firstSprite, &v11);
m_secondSprite = a1->m_secondSprite;
v8.n128_f32[0] = m_radius + (float)(v5 * 0.5);
v10.n128_u32[0] = 0;
sub_100022980(v8, v10, &v11);
((void (__fastcall *)(cocos2d::CCSprite *, int *))m_secondSprite->setPosition)(m_secondSprite, &v11);
}
}
}