Stop rampant mushroom spread.
This commit is contained in:
parent
c4dd513d88
commit
1da72bfa40
1 changed files with 4 additions and 0 deletions
4
abms.lua
4
abms.lua
|
@ -143,6 +143,10 @@ minetest.register_abm({
|
|||
interval = 200 * fun_caves.time_factor,
|
||||
chance = 25,
|
||||
action = function(pos, node)
|
||||
-- Clumsy, but it's the best way to limit them to caves.
|
||||
if pos.y > 0 then
|
||||
return
|
||||
end
|
||||
local pos_up = {x=pos.x,y=pos.y+1,z=pos.z}
|
||||
local node_up = get_node_or_nil(pos_up)
|
||||
if not node_up then
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue