Class: RandomSeed

RandomSeed

a class for managing seed string and randomize game, RandomSeed is a singleton when import it

new RandomSeed ()

constructor is a private function, no access from outside

Methods

getSeed ()string

get seed string
Returns:
Type Description
string

getSeedNumber ()number

get the number which converts from seed string
Returns:
Type Description
number

random (min, max)number

get random number by using seed
Name Type Description
min number minimum of the random will return
max number maximum of the random will return
Returns:
Type Description
number

setSeed (seed)

set new seed to the instance
Name Type Description
seed string seed string