mirror of
https://github.com/luanti-org/luanti.git
synced 2025-08-11 17:51:04 +00:00
Docs: Recommend against using PseudoRandom
This commit is contained in:
parent
e985b7a0bf
commit
a8cf10b0b5
1 changed files with 5 additions and 0 deletions
|
@ -8180,6 +8180,11 @@ Can be obtained using `player:get_meta()`.
|
|||
A 16-bit pseudorandom number generator.
|
||||
Uses a well-known LCG algorithm introduced by K&R.
|
||||
|
||||
> [!NOTE]
|
||||
> `PseudoRandom` is slower and has worse random distribution than `PcgRandom`.
|
||||
> Use `PseudoRandom` only if you need output to match the well-known LCG algorithm introduced by K&R.
|
||||
> Otherwise, use `PcgRandom`.
|
||||
|
||||
* constructor `PseudoRandom(seed)`
|
||||
* `seed`: 32-bit signed number
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue