Vector3.Angle
Unity3D/Problems 2016. 12. 3. 04:13it is quite simpe if you know the conditions clearly.
This image illustrates it (i am using x/z axis):
the code would be like:
so what we do here is set the Vector A along the z-axis and the Vector B along the x/z plane.
The important thing to understand is that (if i'm not mixed up) Vector3.Angle always calculates the angle from the Vector3.zero to the actual Points.
'Unity3D > Problems' 카테고리의 다른 글
DEBUG: Star ting Auth Transition. Op: SIGN_IN status: ERROR_TIMEOUT (0) | 2018.10.25 |
---|---|
CompareApproximately , fRoot (0) | 2017.02.21 |
게임에서 내적과 외적(Dot Product and Cross Product in Game) (0) | 2016.12.01 |
평면과 다른 지점에 있는 물체 구하기 (0) | 2016.11.01 |
Unity 포물선 운동 구현 (C#) (15) | 2016.10.21 |