libtcod
Loading...
Searching...
No Matches
mersenne.h File Reference

Random number generator functions. More...

#include "mersenne_types.h"
#include "portability.h"

Go to the source code of this file.

Functions

TCOD_RandomTCOD_random_get_instance (void)
TCOD_RandomTCOD_random_new (TCOD_random_algo_t algo)
TCOD_RandomTCOD_random_save (TCOD_Random *mersenne)
void TCOD_random_restore (TCOD_Random *mersenne, TCOD_Random *backup)
TCOD_RandomTCOD_random_new_from_seed (TCOD_random_algo_t algo, uint32_t seed)
void TCOD_random_delete (TCOD_Random *mersenne)
void TCOD_random_set_distribution (TCOD_Random *mersenne, TCOD_distribution_t distribution)
int TCOD_random_get_int (TCOD_Random *mersenne, int min, int max)
float TCOD_random_get_float (TCOD_Random *mersenne, float min, float max)
double TCOD_random_get_double (TCOD_Random *mersenne, double min, double max)
int TCOD_random_get_int_mean (TCOD_Random *mersenne, int min, int max, int mean)
float TCOD_random_get_float_mean (TCOD_Random *mersenne, float min, float max, float mean)
double TCOD_random_get_double_mean (TCOD_Random *mersenne, double min, double max, double mean)
TCOD_dice_t TCOD_random_dice_new (const char *s)
int TCOD_random_dice_roll (TCOD_Random *mersenne, TCOD_dice_t dice)
int TCOD_random_dice_roll_s (TCOD_Random *mersenne, const char *s)

Detailed Description

Random number generator functions.