Background for Skyrim SE

LibMathf


Inheritance Tree

No indexed scripts extend this script.

Properties
Events
Functions
floatfunctionAbs(floatf)NativeGlobal

Returns the absolute value of f

floatfunctionAcos(floatf)NativeGlobal

Returns the arc-cosine of f - the angle in radians whose cosine is f

floatfunctionAtan(floatf)NativeGlobal

Returns the arc-tangent of f - the angle in radians whose tangent is f

floatfunctionAtan2(floaty, floatx)NativeGlobal

Returns the angle in radians whose tan is y/x

boolfunctionApproximately(floata, floatb)NativeGlobal

Compares two floating point values and returns true if they are similar

floatfunctionAsin(floatf)NativeGlobal

Returns the arc-sine of f - the angle in radians whose sine is f

floatfunctionCeil(floatf)NativeGlobal

Returns the smallest number (as Float) greater than or equal to f

intfunctionCeilToInt(floatf)NativeGlobal

Returns the smallest number (as Int) greater than or equal to f

floatfunctionClamp(floatvalue, floatmin, floatmax)NativeGlobal

Returns value clamped between min and max

floatfunctionClamp01(floatvalue)NativeGlobal

Returns value clamped between 0 and 1

intfunctionClosestPowerOfTwo(intvalue)NativeGlobal

Returns the closest power of two number

floatfunctionCos(floatf)NativeGlobal

Returns the cosine of angle f

floatfunctionDeltaAngle(floatcurrent, floattarget)NativeGlobal

Calculates the shortest difference between two angles in degrees

floatfunctionExp(floatp)NativeGlobal

Returns e raised to the specified power

floatfunctionFloor(floatf)NativeGlobal

Returns the largest number (as Float) smaller than or equal to f

intfunctionFloorToInt(floatf)NativeGlobal

Returns the largest number (as Int) smaller than or equal to f

floatfunctionIfThen(boolvalue, floatt, floatf)NativeGlobal

Returns t if value is true or f if value is false

boolfunctionInRange(floatvalue, floatmin, floatmax)NativeGlobal

Returns true if value is between min and max

floatfunctionInverseLerp(floata, floatb, floatvalue)NativeGlobal

Calculates the linear parameter t that produces the interpolant value within the range [a, b]

boolfunctionIsPowerOfTwo(intn)NativeGlobal

Returns true if the number is power of two

floatfunctionLerp(floata, floatb, floatt)NativeGlobal

Linearly interpolates between a and b by t

floatfunctionLerpAngle(floata, floatb, floatt)NativeGlobal

Same as Lerp but makes sure the values interpolate correctly when they wrap around 360 degrees

floatfunctionLerpUnclamped(floata, floatb, floatt)NativeGlobal

Linearly interpolates between a and b by t with no limit to t

floatfunctionMax(floatx, floaty)NativeGlobal

Returns the largest of two numbers

floatfunctionMin(floatx, floaty)NativeGlobal

Returns the smallest of two numbers

floatfunctionMoveTowards(floatcurrent, floattarget, floatmaxDelta)NativeGlobal

Moves current value towards target

floatfunctionMoveTowardsAngle(floatcurrent, floattarget, floatmaxDelta)NativeGlobal

Same as MoveTowards but makes sure the values interpolate correctly when they wrap around 360 degrees

intfunctionNextPowerOfTwo(intn)NativeGlobal

Returns the next power of two greater than or equal to n

floatfunctionPingPong(floatt, floatlen)NativeGlobal

Returns number that will increment and decrement between 0 and length

floatfunctionLog(floatf)NativeGlobal

Returns the logarithm of a number

floatfunctionLog10(floatf)NativeGlobal

Returns the base 10 logarithm of a number

floatfunctionPow(floatf, floatp)NativeGlobal

Returns f raised to power p

floatfunctionRepeat(floatt, floatlen)NativeGlobal

Loops t so t is never larger than length and never smaller than 0

floatfunctionRound(floatf)NativeGlobal

Returns f (as Float) rounded to the nearest integer

intfunctionRoundToInt(floatf)NativeGlobal

Returns f (as Int) rounded to the nearest integer

floatfunctionSign(floatf)NativeGlobal

Returns the sign of f

floatfunctionSin(floatf)NativeGlobal

Returns the sine of angle f

floatfunctionSmoothStep(floatcurrent, floattarget, floatt)NativeGlobal

Interpolates between min and max with smoothing at the limits

floatfunctionSqrt(floatf)NativeGlobal

Returns square root of f

floatfunctionTan(floatf)NativeGlobal

Returns the tangent of angle f in radians

Some data provided by the Skyrim Creation Kit Wiki. Licensed under the Creative Commons Attribution-ShareAlike license.