RandomDataGenerator#RandomDataGenerator

new RandomDataGenerator(seeds)

An extremely useful repeatable random data generator.

Based on Nonsense by Josh Faul https://github.com/jocafa/Nonsense.

The random number genererator is based on the Alea PRNG, but is modified.

  • https://github.com/coverslide/node-alea
  • https://github.com/nquinlan/better-random-numbers-for-javascript-mirror
  • http://baagoe.org/en/wiki/Better_random_numbers_for_javascript (original, perm. 404)
Parameters
Name Type Argument Description
seeds Array.<any> | string <optional>

An array of values to use as the seed, or a generator state (from {#state}).

Source code: math/RandomDataGenerator.js (Line 23)
doc_phaser
2017-02-14 11:06:45
Comments
Leave a Comment

Please login to continue.