diff --git a/RULESET.md b/RULESET.md index a476690..f4ccccb 100644 --- a/RULESET.md +++ b/RULESET.md @@ -6,5 +6,3 @@ - Iris uses xorshift32 for randomisation. - The seed is set once at the beginning through user input. You can add more ways to set the seed, but the user has to be able to set it themselves. -- Every randomisation advances the state by 1 -- Every specified action and advances the state by the specified amount, if an amount is specified. If not, it **doesn't advance the state** diff --git a/iris_c/main.c b/iris_c/main.c index 68c1093..8096fc6 100644 --- a/iris_c/main.c +++ b/iris_c/main.c @@ -3,7 +3,8 @@ int main() { set_random_seed(1842); - uint32_t num = random_u32(); - printf("%u\n", num); + for (int i = 0; i < 10; i++) { + printf("%u\n", random_u32()); + } return 0; } diff --git a/iris_c/random.c b/iris_c/random.c index 3cc1019..9f0e11a 100644 --- a/iris_c/random.c +++ b/iris_c/random.c @@ -22,9 +22,3 @@ uint32_t random_range(uint32_t max) { } while (r >= threshold); return r % max; } - -void advance_state(uint32_t n) { - for (uint32_t i = 0; i < n; i++) { - random_u32(); - } -} diff --git a/iris_c/random.h b/iris_c/random.h index 1882808..602c23e 100644 --- a/iris_c/random.h +++ b/iris_c/random.h @@ -6,6 +6,5 @@ void set_random_seed(uint32_t seed); uint32_t random_u32(void); uint32_t random_range(uint32_t max); -void advance_state(uint32_t n); #endif