cos

Returns the cosine of val.

Syntax:

GML Code Example

cos(val);


Argument Description
val The angle (in radians) to return the cosine of.


Returns: Real


Description

In a right angled triangle cos(val) = Adjacent / Hypotenuse where val is one of the three angles. This function will always return a number between 1 and -1.


Example:

GML Code Example

val = cos( 0 );

This will set val to 1.





No Examples Submitted

Does this page need better examples? Be the first to Submit

No Edits Suggested

Is this page unclear or not descriptive enough? Suggest an edit to the page and with enough upvotes your changes will be made.

No Questions Have Been Ask

Do you have a question about this page? Ask it Here