Functions
average
- average(args: number[]): number
-
Parameters
Returns number
binomialCoefficient
- binomialCoefficient(n: number, k: number): number
-
Parameters
Returns number
clamp
- clamp(value: number, min: number, max: number): number
-
Parameters
-
value: number
-
min: number
-
max: number
Returns number
getDiff
- getDiff(num1: number, num2: number): number
-
Parameters
-
num1: number
-
num2: number
Returns number
hash2Numbers
- hash2Numbers(x: number, y: number): number
-
Parameters
Returns number
hash3Numbers
- hash3Numbers(x: number, y: number, z: number): number
-
Parameters
-
x: number
-
y: number
-
z: number
Returns number
isPowerOf2
- isPowerOf2(value: number): boolean
-
Parameters
Returns boolean
lamp
- lamp(min: number, max: number, scale: number): number
-
Parameters
-
min: number
-
max: number
-
scale: number
Returns number
lerp
- lerp(a: number, b: number, val: number): number
-
Parameters
-
a: number
-
b: number
-
val: number
Returns number
log2i
- log2i(value: number): number
-
Parameters
Returns number
pad
- pad(num: number, size: number): string
-
Parameters
Returns string
random
- random(min: number, max: number): number
-
Parameters
Returns number
randomInt
- randomInt(min: number, max: number): number
-
Parameters
Returns number
roundToDecimals
- roundToDecimals(num: number, decimals?: number, type?: "floor" | "ceil" | "round"): string
-
Parameters
-
num: number
-
decimals: number = 2
-
type: "floor" | "ceil" | "round" = "round"
Returns string
toDegrees
- toDegrees(radians: number): number
-
Parameters
Returns number
toRadians
- toRadians(degrees: number): number
-
Parameters
Returns number
use randomFloatBetween instead;