Seeded random number generator to get reproducible sequences of values.

Constructor

inlinenew(seed:Float)

Variables

read onlyseed:Float

Methods

shuffle<T>(arr:Array<T>):Void

Shuffle an Array. This operation affects the array in place. The shuffle algorithm used is a variation of the Fisher Yates Shuffle. Adapted to use seeded random instead of built-in Math.random()

inlinerandom():Float

Returns a float number between [0,1)

inlinebetween(min:Int, max:Int):Int

Return an integer between [min, max).

inlinereset(?initialSeed:Float):Void

Reset the initial value to that of the current seed.