Math.js (system script)
From Spheriki
All Sphere functions that work with angles use the radian unit instead of degrees. The math.js system script converts degrees to radians and vice versa.
Contents |
[edit]
Usage
RequireSystemScript("math.js");
[edit]
Variables and functions of math.js
- DegressToRadians(degrees)
- converts degrees to radians.
- RadiansToDegrees(radians)
- converts radians to degrees.
[edit]
Example
This will display the system arrow rotated by 90 degrees (it'll point downwards):
RequireSystemScript("math.js");
var img = GetSystemArrow();
img.rotateBlit(0, 0, DegreesToRadians(90));
FlipScreen();
GetKey();
[edit]
See also
[edit]

