Random

IRandomModule provides a centralized location for the generation of random numbers. Any module that relies upon randomness should check for the existence of a random module (e.g. (IRandomModule) model.getModule(IRandomModule.class)) and use the returned instance. If no random module is installed, random behavior should not be enabled. This allows one to easily enable/disable random behavior. By centralizing the random generation, you can more easily guarantee repeatable behavior for a given random seed.

There is a single default implementation.

Default

DefaultRandomModule

Parameters

  • RandomSeed : default automatically generated.
  • TimeRandomizer : default 3. Sets the seed for the time randomization used for the equal distribution (time * ((randomizer-1)/randomizer))