pos-sys-cam: better tresholds for considering data invalid
Also this position system already works with the PID positioning already in placestriker
parent
375f812d79
commit
52a557e88e
|
@ -60,7 +60,7 @@ void PositionSysCamera::update()
|
|||
int posya = CAMERA_GOAL_ATK_Y - distya;
|
||||
int posyd = CAMERA_GOAL_DEF_Y + distyd;
|
||||
|
||||
if ((distxd * distxa < 0) || (CURRENT_DATA_READ.atkSeen && CURRENT_DATA_READ.defSeen && posya - posyd > 25)) data_valid = false;
|
||||
if (((distxd * distxa < 0) && abs(distxd - distxa) > 10) || (CURRENT_DATA_READ.atkSeen && CURRENT_DATA_READ.defSeen && abs(posya - posyd) > 25)) data_valid = false;
|
||||
|
||||
if (data_valid)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue