Method | Defined By | ||
---|---|---|---|
Angle(pStartPos:Point, pEndPos:Point):Point [static]
Returns a vector based on two points given
| AngleUtil | ||
AngleOfRotation(nRot:Number):Point [static]
Returns a vector based on a degree (0-360)
| AngleUtil | ||
DegreeToRad(nDegree:Number):Number [static]
Converts a degree to radians
| AngleUtil | ||
GetRad(pStartPos:Point, pEndPos:Point):Number [static]
Returns the radian based on two points given. | AngleUtil | ||
RadToDegree(nRad:Number):Number [static]
Converts a radian to degrees
| AngleUtil | ||
Rotation(pStartPos:Point, pEndPos:Point):Number [static]
Returns the degree (0-360) based on two points given. | AngleUtil | ||
SlowRotation(nOriginalRot:Number, nAngle:Number, nSpeed:Number = 0.9):Number [static]
Returns a degree (0-360) based on the original degree, a new degree, and the speed to rotate towards. | AngleUtil |
Angle | () | method |
public static function Angle(pStartPos:Point, pEndPos:Point):Point
Returns a vector based on two points given
Parameters
pStartPos:Point — The first point
| |
pEndPos:Point — The second point
|
Point —
|
AngleOfRotation | () | method |
public static function AngleOfRotation(nRot:Number):Point
Returns a vector based on a degree (0-360)
Parameters
nRot:Number — The degree
|
Point —
|
DegreeToRad | () | method |
public static function DegreeToRad(nDegree:Number):Number
Converts a degree to radians
Parameters
nDegree:Number — The degree
|
Number —
|
GetRad | () | method |
public static function GetRad(pStartPos:Point, pEndPos:Point):Number
Returns the radian based on two points given.
Parameters
pStartPos:Point — The first point
| |
pEndPos:Point — The second point
|
Number —
|
RadToDegree | () | method |
public static function RadToDegree(nRad:Number):Number
Converts a radian to degrees
Parameters
nRad:Number — The radian
|
Number —
|
Rotation | () | method |
public static function Rotation(pStartPos:Point, pEndPos:Point):Number
Returns the degree (0-360) based on two points given.
Parameters
pStartPos:Point — The first point
| |
pEndPos:Point — The second point
|
Number —
|
SlowRotation | () | method |
public static function SlowRotation(nOriginalRot:Number, nAngle:Number, nSpeed:Number = 0.9):Number
Returns a degree (0-360) based on the original degree, a new degree, and the speed to rotate towards.
Parameters
nOriginalRot:Number — The original degree
| |
nAngle:Number — The degree to rotate to
| |
nSpeed:Number (default = 0.9 ) — The speed of the rotation
|
Number —
|