mirror of
https://github.com/photonstorm/phaser
synced 2024-12-23 19:43:28 +00:00
24 lines
588 B
JavaScript
24 lines
588 B
JavaScript
/**
|
|
* @author Richard Davey <rich@photonstorm.com>
|
|
* @copyright 2020 Photon Storm Ltd.
|
|
* @license {@link https://opensource.org/licenses/MIT|MIT License}
|
|
*/
|
|
|
|
var CONST = require('./const');
|
|
|
|
/**
|
|
* Convert the given angle in radians, to the equivalent angle in degrees.
|
|
*
|
|
* @function Phaser.Math.RadToDeg
|
|
* @since 3.0.0
|
|
*
|
|
* @param {number} radians - The angle in radians to convert ot degrees.
|
|
*
|
|
* @return {number} The given angle converted to degrees.
|
|
*/
|
|
var RadToDeg = function (radians)
|
|
{
|
|
return radians * CONST.RAD_TO_DEG;
|
|
};
|
|
|
|
module.exports = RadToDeg;
|