FFUOEUJREZ6KR4BZFLM7ORBKTNLJC5WVTACO26NTKNQ37MDTKN5AC
if (skip_size <= 1) @compileError("`skip_size must be > 1`");
var rnd_tmp = std.rand.DefaultPrng.init(@intCast(u64, std.time.milliTimestamp()));
if (skip_size <= 1) {
std.log.err("skip_size {d} not allowed, must be > 1", .{skip_size});
return error.InvalidSkipSize;
}
// while (self.rnd.float(f32) < (1.0 / self.skip_size) and
// level < self.max_level) level += 1;
while (level < self.max_level) {
const r = self.rnd.float(f32);
// FIXME: strange r values...
std.debug.print("r: {d}\n", .{r});
if (r < 1 / self.skip_size) level += 1 else break;
}
std.debug.print("{d}\n", .{level});
const random = self.rnd.random();
while (random.float(f32) < (1 / self.skip_size) and
level < self.max_level) level += 1;