Static Public Member Functions | |
static float | AddToFloat (UPARAM(ref) float &A, const float B) |
Adds to a given float in-place (equivalent to +=) More... | |
static void | AddToFloatWithLimit (UPARAM(ref) float &A, const float B, const float Limit, float &Result, bool &HitLimit) |
Adds to a given float in-place (+=) and clamps it to the specified limit. More... | |
static float | FloatAverage (const float A, const float B) |
Returns the average of two floats. More... | |
static float | FloatArrayAverage (const TArray< float > &Array) |
Returns the average of an array of floats. More... | |
static float | FloatArraySum (const TArray< float > &Array) |
Returns the sum of an array of floats. More... | |
static int32 | AddToInt (UPARAM(ref) int32 &A, const int32 B) |
Adds to a given int in-place (equivalent to +=) More... | |
static void | AddToIntWithLimit (UPARAM(ref) int32 &A, const int32 B, const int32 Limit, int32 &Result, bool &HitLimit) |
Adds to a given int in-place (+=) and clamps it to the specified limit. More... | |
static int32 | IntArraySum (const TArray< int32 > &Array) |
Returns the sum of an array of ints. More... | |
static float | AngleDelta (const float A, const float B) |
Returns the signed shortest distance between two angles. More... | |
static bool | IsPointInBox2D (const FVector2D Point, const FBox2D Box) |
Returns whether a point is inside the given box. More... | |
static int32 | SystemRand () |
Returns a random integer using the system rand() function. More... | |
static void | FindClosestPoint (const FVector Point, const TArray< FVector > Points, FVector &Closest, int32 &ClosestIndex) |
Finds the closest point in a set. More... | |
static void | ClampIntReflect (const int32 Value, const int32 Min, const int32 Max, int32 &Result, bool &Reflected) |
Clamps an int to the specified range, reflecting overshoots back into the range. More... | |
static float | AngleBetweenVectors (const FVector A, const FVector B) |
Gets the angle (in degrees) between two vectors. More... | |
static float | MapAngleTo180 (const float Value) |
Remaps an angle to [-180°, 180°]. More... | |
static float | ClampZeroToOne (const float Value) |
Compact shortcut to clamp a float to [0, 1]. More... | |
|
static |
Adds to a given float in-place (equivalent to +=)
A | The float to add to |
B | The value to add |
|
static |
Adds to a given float in-place (+=) and clamps it to the specified limit.
A | The float to add to |
B | The value to add |
Limit | The limit to clamp the value to |
Result | The new value |
HitLimit | True if the addition exceeded the given limit |
|
static |
Adds to a given int in-place (equivalent to +=)
A | The integer to add to |
B | The value to add |
|
static |
Adds to a given int in-place (+=) and clamps it to the specified limit.
A | The int to add to |
B | The value to add |
Limit | The limit to clamp the value to |
Result | The new value |
HitLimit | True if the addition exceeded the given limit |
|
static |
Gets the angle (in degrees) between two vectors.
A | Vector argument |
B | Vector argument |
Angle | in degrees |
|
static |
Returns the signed shortest distance between two angles.
A | The source angle |
B | The target angle |
|
static |
Clamps an int to the specified range, reflecting overshoots back into the range.
Value | Value to clamp |
Min | Minimum value |
Max | Maximum value |
Result | Clamped and reflected integer |
Reflected | True if the int needed reflecting |
|
static |
Compact shortcut to clamp a float to [0, 1].
Value | Float input |
Angle | remapped to [-180°, 180°] |
|
static |
Finds the closest point in a set.
Point | Point to check distance against |
Points | Points to check for closest |
Closest | The closest point |
ClosestIndex | Index of the closest point |
|
static |
Returns the average of an array of floats.
Array | The array to get the average of |
|
static |
Returns the sum of an array of floats.
Array | The array to get the sum of |
|
static |
Returns the average of two floats.
A | The first value |
B | The second value |
|
static |
Returns the sum of an array of ints.
Array | The array to get the sum of |
|
static |
Returns whether a point is inside the given box.
Point | The point to test |
Box | The bounds to test for |
|
static |
Remaps an angle to [-180°, 180°].
Value | Float input |
Angle | remapped to [-180°, 180°] |
|
static |
Returns a random integer using the system rand() function.