[This is preliminary documentation and is subject to change.]
Static class with various functions for common conversions.
Inheritance Hierarchy
RageMathHelper
Namespace: Rage
Assembly: RagePluginHook (in RagePluginHook.dll) Version: 0.0.0.0 (0.56.1131.11510)
Syntax
The MathHelper type exposes the following members.
Properties
Name | Description | |
---|---|---|
RandomizationSeed |
Methods
Name | Description | |
---|---|---|
AreDigitsIdentical |
Gets whether all digits in the specified number are identical.
| |
AverageT | ||
ChooseT(ICollectionT) |
Gets a random object from the specified collection.
| |
ChooseT(T) |
Gets a random object from the specified array.
| |
ClampT |
Gets the specified value between the specified minimum and maximum values.
| |
ConvertDegreesToRadians |
Converts the specified angle in degrees to its equivalent in radians.
| |
ConvertDirectionToHeading |
Converts the specified direction to a heading.
| |
ConvertHeadingToDirection |
Converts the specified heading to its equivalent direction.
| |
ConvertKilometersPerHourToMetersPerSecond |
Converts the specified value from kilometers per hour to meters per second.
| |
ConvertKilometersPerHourToMilesPerHour |
Converts the specified value from kilometers per hour to miles per hour.
| |
ConvertMetersPerSecondToKilometersPerHour |
Converts the specified value from meters per second to kilometers per hour.
| |
ConvertMetersPerSecondToKilometersPerHourRounded |
Converts the specified value from meters per second to kilometers per hour and rounds the result.
| |
ConvertMetersPerSecondToMilesPerHour |
Converts the specified value from meters per second to miles per hour.
| |
ConvertMilesPerHourToKilometersPerHour |
Converts the specified value from miles per hour to kilometers per hour.
| |
ConvertMilesPerHourToMetersPerSecond |
Converts the specified value from miles per hour to meters per second.
| |
ConvertRadiansToDegrees(Double) |
Converts the specified angle in radians to its equivalent in degrees.
| |
ConvertRadiansToDegrees(Single) |
Converts the specified angle in radians to its equivalent in degrees.
| |
Faculty |
Gets the faculty of the specified number.
| |
GetChance(Int32) |
Gets a chance.
| |
GetChance(Int32, Int32) |
Gets a chance.
| |
GetNumberLength |
Gets the length of the specified number.
| |
GetOffsetPosition | ||
GetRandomAlphaNumericCharacter |
Gets a random alpha numeric character.
| |
GetRandomDouble |
Gets a random double precision floating point number between the specified minimum and maximum value, inclusive.
| |
GetRandomInteger(Int32) |
Gets a random integer between 0, inclusive, and the specified maximum value, exclusive.
| |
GetRandomInteger(Int32, Int32) |
Gets a random integer between the specified minimum and maximum value, inclusive.
| |
GetRandomSingle |
Gets a random single precision floating point number between the specified minimum and maximum value, inclusive.
| |
InterpolateLinearlyTo(Single, Single, Single, Single) | ||
InterpolateLinearlyTo(Rotator, Rotator, Single, Single) | ||
InterpolateLinearlyTo(Vector2, Vector2, Single, Single) | ||
InterpolateLinearlyTo(Vector3, Vector3, Single, Single) | ||
InterpolateTo(Single, Single, Single, Single) | ||
InterpolateTo(Rotator, Rotator, Single, Single) | ||
InterpolateTo(Vector2, Vector2, Single, Single) | ||
InterpolateTo(Vector3, Vector3, Single, Single) | ||
IsPowerOfTwo |
Determines whether the specified number is a power of two.
| |
IsZeroOrPowerOfTwo |
Determines whether the specified number is zero or a power of two.
| |
Lerp(Double, Double, Single) |
Gets a new value between the specified start and end values, designated by the percentage.
| |
Lerp(Int32, Int32, Single) |
Gets a new value between the specified start and end values, designated by the percentage.
| |
Lerp(Int64, Int64, Single) |
Gets a new value between the specified start and end values, designated by the percentage.
| |
Lerp(Single, Single, Single) |
Gets a new value between the specified start and end values, designated by the percentage.
| |
MaxT | ||
MedianT |
Gets the median from the specified values.
| |
MinT | ||
Normalize |
Normalizes the specified value.
| |
NormalizeHeading |
Normalizes the specified heading.
| |
RotateHeading |
Rotates the specified heading the specified number of degrees, and returns the normalized result.
| |
RoundToLowerTenth(Int32) |
Rounds the specified integer to the nearest lower tenth.
| |
RoundToLowerTenth(Single) |
Rounds the specified float to the nearest lower tenth integer.
| |
Square(Double) |
Gets the specified value multiplied by itself.
| |
Square(Int32) |
Gets the specified value multiplied by itself.
| |
Square(Int64) |
Gets the specified value multiplied by itself.
| |
Square(Single) |
Gets the specified value multiplied by itself.
| |
UnLerp(Double, Double, Double) |
Gets the original percentage provided to Lerp, given the start, end and lerped value.
| |
UnLerp(Int32, Int32, Int32) |
Gets the original percentage provided to Lerp, given the start, end and lerped value.
| |
UnLerp(Int64, Int64, Int64) |
Gets the original percentage provided to Lerp, given the start, end and lerped value.
| |
UnLerp(Single, Single, Single) |
Gets the original percentage provided to Lerp, given the start, end and lerped value.
|
See Also