I'll ask a more simple question. Let's say no matter how but I have calculated the rotation of a line between an object center and a mouse (angle). Starting at North aka 0, going a CW circle to 359 near North. I ask AS3 to "object.rotation = angle;" every frame . I have 2 text areas that show the values "angle" and "object.rotation". After 180 object.rotation becomes -180 and goes backwards to 0. Why so?
Even more simple. I get value A, then say A = B. Then ask computer to show A and show B. At 180 to 360, B=B-360.
Rotation is satisfactory, but the numbers are wrong. Need explanation why numbers misfit. Need an advice on how to make object rotation range 0-360 and be directly determined by a number I input. "angle" in my case.
Meaning if I input rotation 2892 it should be it(yes,8*360+12), not 12, not -348... even though these represent the same rotation visually.