//
// cocos2d::extension::CCControlStepper::updateLayoutUsingTouchLocation from 0x7ad988 to 0x7ada6e (230 bytes)
//
// 2 xrefs:
// > cocos2d::extension::CCControlStepper::ccTouchBegan @ 0x7adad4
// > cocos2d::extension::CCControlStepper::ccTouchMoved @ 0x7adb4a
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:00:04 +0000
//
int __fastcall cocos2d::extension::CCControlStepper::updateLayoutUsingTouchLocation(int a1, float *a2)
{
float v4; // s16
float v5; // s15
int v6; // r0
float v7; // s16
float v8; // s15
int v9; // r0
int (*v10)(void); // r3
v4 = *a2;
v5 = *(float *)(*(int (__fastcall **)(_DWORD))(**(_DWORD **)(a1 + 356) + 164))(*(_DWORD *)(a1 + 356));
v6 = *(_DWORD *)(a1 + 356);
if ( v4 < v5 && *(double *)(a1 + 376) > *(double *)(a1 + 392) )
{
*(_DWORD *)(a1 + 420) = 0;
(*(void (__fastcall **)(int, void *))(*(_DWORD *)v6 + 480))(v6, &unk_BF16B3);
v10 = *(int (**)(void))(**(_DWORD **)(a1 + 360) + 480);
}
else
{
v7 = *a2;
v8 = *(float *)(*(int (__fastcall **)(int))(*(_DWORD *)v6 + 164))(v6);
v9 = *(_DWORD *)(a1 + 356);
if ( v7 < v8 || *(double *)(a1 + 376) >= *(double *)(a1 + 400) )
{
*(_DWORD *)(a1 + 420) = 2;
(*(void (__fastcall **)(int, void *))(*(_DWORD *)v9 + 480))(v9, &unk_BF16B0);
v10 = *(int (**)(void))(**(_DWORD **)(a1 + 360) + 480);
}
else
{
*(_DWORD *)(a1 + 420) = 1;
(*(void (__fastcall **)(int, void *))(*(_DWORD *)v9 + 480))(v9, &unk_BF16B0);
v10 = *(int (**)(void))(**(_DWORD **)(a1 + 360) + 480);
}
}
return v10();
}