117
rated 0 times
[
123]
[
6]
/ answers: 1 / hits: 18484
/ 14 Years ago, thu, july 22, 2010, 12:00:00
I'm creating a simple 2D game in javascript/canvas.
I need to figure out the angle of a certain object relative to my position.
So: say I'm at (10,10) and the object is at (10,5) - that would result in 90 degrees (as positive Y is down, negative Y is up)
(10,10) vs (10,15) would be 270 degrees.
How would I go about this?
More From » math