38 #ifdef CHECK_MEMORY_LEAKS 40 #endif // CHECK_MEMORY_LEAKS 60 oc.
addDescription(
"random",
"Random Number",
"Initialises the random number generator with the current system time");
64 oc.
addDescription(
"seed",
"Random Number",
"Initialises the random number generator with the given value");
76 int s2 = (int)(s & 0xffff) ^ (s >> 16);
void doRegister(const std::string &name, Option *v)
Adds an option under the given name.
static void insertRandOptions()
Initialises the given options container with random number options.
int getInt(const std::string &name) const
Returns the int-value of the named option (only for Option_Integer)
bool getBool(const std::string &name) const
Returns the boolean-value of the named option (only for Option_Bool)
static OptionsCont & getOptions()
Retrieves the options.
static void initRandGlobal(MTRand *which=0)
Reads the given random number options and initialises the random number generator in accordance...
void addSynonyme(const std::string &name1, const std::string &name2, bool isDeprecated=false)
Adds a synonyme for an options name (any order)
void addOptionSubTopic(const std::string &topic)
Adds an option subtopic.
static uint32 hash(time_t t, clock_t c)
void seed(const uint32 oneSeed)
static MTRand myRandomNumberGenerator
the random number generator to use
A storage for options typed value containers)
void addDescription(const std::string &name, const std::string &subtopic, const std::string &description)
Adds a description for an option.