Depollute the code - 04 - bloody brown mushrooms

This commit is contained in:
Zweihorn 2019-05-19 12:55:59 +02:00 committed by Yves Quemener
parent c32552f8ef
commit 5c82aa3d14
1 changed files with 4 additions and 1 deletions

View File

@ -241,7 +241,10 @@ function flowers.mushroom_spread(pos, node)
end
local pos2 = positions[math.random(#positions)]
pos2.y = pos2.y + 1
if minetest.get_node_light(pos2, 0.5) <= 3 then
if minetest.get_node_light(pos, 0.5) > 3 then
if minetest.get_node_light(pos, nil) == 15 then
minetest.remove_node(pos)
end
minetest.set_node(pos2, {name = node.name})
end
end