//
// cocos2d::extension::CCControlSlider::locationFromTouch from 0x5a3d64 to 0x5a3de6 (130 bytes)
//
// 2 xrefs:
// > cocos2d::extension::CCControlSlider::ccTouchBegan @ 0x5a3f08
// > cocos2d::extension::CCControlSlider::ccTouchMoved @ 0x5a3f9a
//
// 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
//
cocos2d::CCPoint *cocos2d::extension::CCControlSlider::locationFromTouch(
cocos2d::CCPoint *__return_ptr retstr,
cocos2d::extension::CCControlSlider *a2,
cocos2d::CCTouch *a3)
{
int v5; // r2
bool v6; // r3
float x; // s16
float v8; // r3
cocos2d::CCPoint v10; // [sp+4h] [bp+0h] BYREF
cocos2d::CCTouch::getLocation(retstr, a3);
cocos2d::CCNode::convertToNodeSpace(&v10, a2, retstr);
cocos2d::CCPoint::operator=((PlayerObject *)retstr, COERCE_FLOAT(&v10), v5, v6);
if ( retstr->x < 0.0 )
{
v8 = 0.0;
LABEL_5:
retstr->x = v8;
return retstr;
}
x = retstr->x;
if ( x > *(float *)(*(int (__fastcall **)(int))(*(_DWORD *)a2[1].m_uIndexInArray + 156))(a2[1].m_uIndexInArray) )
{
v8 = *(float *)(*(int (__fastcall **)(int))(*(_DWORD *)a2[1].m_uIndexInArray + 156))(a2[1].m_uIndexInArray);
goto LABEL_5;
}
return retstr;
}