Math (Module)

From Doomsday Wiki
Jump to: navigation, search

Module that provides math-related functions.


random ( )

Returns a random number between 0 and 1.

randInt ( low : Number, high : Number )

Returns a random integer in the range low ... high. The range is inclusive at both ends, so this is possible:

$ Math.randInt(0, 3)3