adding more logic to the angle curve function to better predict a curve.
fixing merge error.