1
0
mirror of https://github.com/mt-mods/biome_lib.git synced 2024-12-26 02:40:17 +01:00

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 :-)
This commit is contained in:
Vanessa Dannenberg 2021-04-01 09:02:41 -04:00
parent 26dbbb5a67
commit 9ed4858518

View File

@ -353,7 +353,7 @@ function biome_lib:populate_surfaces(biome, nodes_or_function_or_model, snodes,
return 0 return 0
end 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 tries = 0
local spawned = false local spawned = false
while tries < 2 and not spawned do while tries < 2 and not spawned do