Remove that condition and action where you said if width > 50
Instead, replace the distance(Self.X, Self.Y, TouchCoordX, TouchCoordY) with:
Set width to: min(50, distance(Self.X, Self.Y, Touch.CoordX, Touch.CoordY))
That above will take the minimum value of the two, if the distance is larger, it will choose 50.
In the 2nd event (with Has TouchID), also add: Is in Touch
If doesn't work, share your c3p