mirror of
https://github.com/sbrl/Minetest-WorldEditAdditions.git
synced 2024-11-22 15:33:00 +00:00
//maze: fix some areas of generated mazes not being explored
This commit is contained in:
parent
cf2d3f408c
commit
39103a046f
2 changed files with 2 additions and 4 deletions
|
@ -140,5 +140,5 @@ function worldeditadditions.erode.snowballs(heightmap_initial, heightmap, height
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
return true, ""..#stats_steps.." snowballs simulated, max "..params.max_steps.." steps (average ~"..worldeditadditions.average(stats_steps)..")"
|
return true, ""..#stats_steps.." snowballs simulated, max "..params.max_steps.." steps (averaged ~"..worldeditadditions.average(stats_steps).." steps)"
|
||||||
end
|
end
|
||||||
|
|
|
@ -95,9 +95,7 @@ local function generate_maze(seed, width, height, path_length, path_width)
|
||||||
cx = cx + path_length
|
cx = cx + path_length
|
||||||
end
|
end
|
||||||
|
|
||||||
if #directions > 1 then
|
|
||||||
table.insert(nodes, { x = cx, y = cy })
|
table.insert(nodes, { x = cx, y = cy })
|
||||||
end
|
|
||||||
else
|
else
|
||||||
table.remove(nodes, curnode)
|
table.remove(nodes, curnode)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue