C# 클래스 Project290.Mathematics.RotationHelper

This static public class is used to convert from a Vector2 to an angle or vice versa.
파일 보기 프로젝트 열기: scastle/Solitude

공개 메소드들

메소드 설명
AngleToVector2 ( float angle ) : Vector2

Converts the specified angle into a vector of magnitude 1.

Vector2ToAngle ( float x, float y ) : float

Takes as a paramter a vector and returns the angle in radians corresponding to the vector.

메소드 상세

AngleToVector2() 공개 정적인 메소드

Converts the specified angle into a vector of magnitude 1.
public static AngleToVector2 ( float angle ) : Vector2
angle float The angle.
리턴 Vector2

Vector2ToAngle() 공개 정적인 메소드

Takes as a paramter a vector and returns the angle in radians corresponding to the vector.
public static Vector2ToAngle ( float x, float y ) : float
x float The x coordinate.
y float The y cooordinate.
리턴 float