X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=mods%2Fmain%2Fgrass_spread.lua;h=9f399f3ea92e052695933e30f60a2fc15de30835;hb=851177f7b7b4e96b74cca786236dc88334ede7d1;hp=c94307b65e162921795131f776bea15646b0395e;hpb=210e3cdc10794f004a9b33da04ddcebac8e235d9;p=Crafter.git diff --git a/mods/main/grass_spread.lua b/mods/main/grass_spread.lua index c94307b..9f399f3 100644 --- a/mods/main/grass_spread.lua +++ b/mods/main/grass_spread.lua @@ -1,17 +1,17 @@ --grass spread abm minetest.register_abm({ - label = "Grass Grow", - nodenames = {"main:dirt"}, - neighbors = {"main:grass"}, - interval = 10, - chance = 2000, - action = function(pos) - local light = minetest.get_node_light(pos, nil) - --print(light) - if light < 10 then - --print("failed to grow grass at "..dump(pos)) - return - end - minetest.set_node(pos,{name="main:grass"}) - end, + label = "Grass Grow", + nodenames = {"main:dirt"}, + neighbors = {"main:grass"}, + interval = 10, + chance = 2000, + action = function(pos) + local light = minetest.get_node_light(pos, nil) + --print(light) + if light < 10 then + --print("failed to grow grass at "..dump(pos)) + return + end + minetest.set_node(pos,{name="main:grass"}) + end, })