Normalize180

native clearscope static double Normalize180(double ang)

Note: This feature is for ZScript only.

Usage

Normalizes the given angle to a range of [-180, 180]. Useful if it's unknown what the actual range of the angle will be (such as with the player's angle).

Parameters

  • ang - The angle to normalize

Return value

Returns the normalized angle.

Examples

Note: This article lists no examples. If you make use of this feature in your own project(s) or know of any basic examples that could be shared, please add them. This will make it easier to understand for future authors seeking assistance. Your contributions are greatly appreciated.
This article is issued from Zdoom. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.