Quote:
Originally Posted by Whistler
...it's this:
if (angle >= 180)
angle -= 360 * (int)(angle / 360 + 0.5); // 0.5 is INSIDE the (int)(...)
|
If you do this then your code will behave wrong for large values of angle, do you know that ? 9_9
The function will exit and the angle will still be overflown.