Utils

tracker.Utils (Class)

Static Members

uniformFrequencyList(values: Array<Int>, frequencies: Array<Float>, size: Int): Array<Int>

Generate an uniform list of the requested size, containing values uniformly repartited from frequencies.

Name Type Description
values Array<Int> the values to put in list
frequencies Array<Float>
size Int the size of the final list
Returns
Array<Int>

uniqueId(): String

Provides an identifier which is garanteed to be unique on the current session. It however doesn't garantee that this identifier is not predictable.

Returns
String

base62Id(?val: Int): String
Name Type Default
val Int (optional)
Returns
String

encodeChangesetData(data: String): String
Name Type
data String
Returns
String

decodeChangesetData(rawData: String): AnonStruct
Name Type
rawData String
Returns
AnonStruct

equalAny(a: Any, b: Any): Bool

Used as a workaround in targets like C++ to compare arrays because in some situation basic equality check won't work without typing the objects as Any or Dynamic.

Name Type
a Any
b Any
Returns
Bool

Private Members