Difference between revisions of "love.math.getRandomSeed"

(Created page)
 
(No difference)

Revision as of 01:54, 2 December 2013

Available since LÖVE 0.9.0
This function is not supported in earlier versions.

Gets the state of the random number generator.

The state is split into two numbers due to Lua's use of doubles for all number values - doubles can't accurately represent integer values above 2^53.

Function

Synopsis

low, high = love.math.getRandomState( )

Arguments

None.

Returns

number low
Integer number representing the lower 32 bits of the random number generator's 64 bit state value.
number high
Integer number representing the higher 32 bits of the random number generator's 64 bit state value.

See Also

Other Languages