Fix possible bug in grass grow ABM

master
PilzAdam 2013-11-02 16:00:24 +01:00
parent a23024d754
commit 4c188a8ec3
1 changed files with 2 additions and 1 deletions

View File

@ -37,7 +37,8 @@ minetest.register_abm({
local pa = {x=pos.x, y=pos.y+1, z=pos.z}
local na = minetest.get_node(pa)
local da = minetest.registered_nodes[na.name]
if da and da.liquidtype == "none" and minetest.get_node_light(pa) >= 13 then
local light = minetest.get_node_light(pa) or 0
if da and da.liquidtype == "none" and light >= 13 then
minetest.set_node(pos, {name="base:dirt_with_grass"})
end
end,