Crossfire Server, Trunk
cf_random.cpp
Go to the documentation of this file.
1
#include <random>
2
3
static
std::mt19937
generator
;
4
5
uint32_t
cf_random
(
void
) {
6
return
generator
() % RAND_MAX;
7
}
8
9
void
cf_srandom
(
unsigned
long
seed) {
10
generator
.seed(seed);
11
}
cf_random
uint32_t cf_random(void)
Definition:
cf_random.cpp:5
cf_srandom
void cf_srandom(unsigned long seed)
Definition:
cf_random.cpp:9
generator
static std::mt19937 generator
Definition:
cf_random.cpp:3
crossfire-crossfire-server
common
cf_random.cpp
Generated by
1.8.17