1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-08-01 17:38:41 +00:00

Add range option to PseudoRandom:next()

This commit is contained in:
Perttu Ahola 2012-03-28 21:16:47 +03:00
parent 9a1df7bf38
commit 68625b047f
2 changed files with 17 additions and 3 deletions

View file

@ -632,7 +632,10 @@ methods:
PseudoRandom: A pseudorandom number generator
- Can be created via PseudoRandom(seed)
methods:
- next(): return next random number [0...32767]
- next(): return next integer random number [0...32767]
- next(min, max): return next integer random number [min...max]
(max - min) must be 32767 or <= 6553 due to the simple
implementation making bad distribution otherwise.
Registered entities
--------------------