Class: MT19937
Functions
| Name | Description |
|---|---|
.new(seed) |
Methods
| Name | Description |
|---|---|
:pick(table) | |
:randInt(min,max) | |
:randReal(min,max) | |
:randSeed() |
Function declarations
Function: new
lua
function MT19937.new(
seed
) endParameters:
- seed (
integer)
Returns:
Method declarations
Method: pick
lua
function MT19937:pick(
table
) endParameters:
- table (
table) - The table to randomly pick from, must be an array, index starting from 1
Returns:
any
Method: randInt
lua
function MT19937:randInt(
min,
max
) endParameters:
- min (
integer) - Inclusive - max (
integer) - Inclusive
Returns:
integer
Method: randReal
lua
function MT19937:randReal(
min,
max
) endParameters:
- min (
number) - max (
number)
Returns:
number
Method: randSeed
lua
function MT19937:randSeed() endReturns:
integer
