From 9ed485851823560e80abaeef3291c78af4c69f80 Mon Sep 17 00:00:00 2001 From: Vanessa Dannenberg Date: Thu, 1 Apr 2021 09:02:41 -0400 Subject: [PATCH] take the integer of that last division I added always round up. otherwise it'll break the `for` loop if a mod supplies a value not divisible by 25 :-) --- init.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/init.lua b/init.lua index 76e5064..db565f0 100644 --- a/init.lua +++ b/init.lua @@ -353,7 +353,7 @@ function biome_lib:populate_surfaces(biome, nodes_or_function_or_model, snodes, return 0 end - for i = 1, math.min(biome.max_count/25, num_in_biome_nodes) do + for i = 1, math.min(math.ceil(biome.max_count/25), num_in_biome_nodes) do local tries = 0 local spawned = false while tries < 2 and not spawned do