We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6bfa9ec commit f61d358Copy full SHA for f61d358
docs/scripting/scripts.lib/mulberry32.mdx
@@ -2,7 +2,7 @@
2
title: .mulberry32()
3
---
4
5
-A function that gets a random number from a numerical seed based on the mulberry32 RNG.
+A function that returns a PRNG function from a numerical seed based on the mulberry32 algorithm.
6
7
## Syntax
8
@@ -18,15 +18,16 @@ The number to serve as the seed for RNG.
18
19
### Return
20
21
-Returns a number.
+Returns a function.
22
23
## Example
24
25
```js
26
function(context, args) {
27
const l = #fs.scripts.lib();
28
const my_number = 1337;
29
+ const rng = l.mulberry32(my_number);
30
- return l.mulberry32(my_number);
31
+ return rng();
32
}
33
```
0 commit comments