Answers for "Angle calculation not working??"
http://answers.unity.com/questions/842191/angle-calculation-not-working.html
The latest answers for the question "Angle calculation not working??"Answer by zharik86
http://answers.unity.com/answers/842211/view.html
For most case, better use Mathf.Atan2:
float angle = Mathf.Atan2(target_pos.y, target_pos.x); //return angle in radians
But, in your line can be devision by 0 (target_pos.x = 0). Of course, you have exception. In Atan2() in this case angle is equal 90 degree. I hope that it will help you.Thu, 27 Nov 2014 19:26:59 GMTzharik86Answer by tanoshimi
http://answers.unity.com/answers/842194/view.html
"isn't working" doesn't give us much to go on when we can't see your code, know what value you expected, or got. Please post a reproducible example. You are working with radians, right?Thu, 27 Nov 2014 19:09:27 GMTtanoshimi