From c277590fc2159a6a3599272e8320f600879a75ec Mon Sep 17 00:00:00 2001 From: Vanessa Ezekowitz Date: Sun, 30 Jun 2013 23:55:07 -0400 Subject: Phased out all deprecated minetest.env:* uses in favor of minetest.* --- leafdecay.lua | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'leafdecay.lua') diff --git a/leafdecay.lua b/leafdecay.lua index 7c75f11..be22ba4 100644 --- a/leafdecay.lua +++ b/leafdecay.lua @@ -9,8 +9,8 @@ if moretrees.enable_leafdecay then interval = moretrees.leafdecay_delay, chance = moretrees.leafdecay_chance, action = function(pos, node, active_object_count, active_object_count_wider) - if not minetest.env:find_node_near(pos, moretrees.leafdecay_radius, "moretrees:"..treename.."_trunk") then - minetest.env:remove_node(pos) + if not minetest.find_node_near(pos, moretrees.leafdecay_radius, "moretrees:"..treename.."_trunk") then + minetest.remove_node(pos) nodeupdate(pos) end end @@ -23,8 +23,8 @@ if moretrees.enable_leafdecay then interval = moretrees.leafdecay_delay, chance = moretrees.leafdecay_chance, action = function(pos, node, active_object_count, active_object_count_wider) - if not minetest.env:find_node_near(pos, moretrees.leafdecay_radius, {"default:jungletree", "moretrees:jungletree_trunk"}) then - minetest.env:remove_node(pos) + if not minetest.find_node_near(pos, moretrees.leafdecay_radius, {"default:jungletree", "moretrees:jungletree_trunk"}) then + minetest.remove_node(pos) nodeupdate(pos) end end @@ -35,8 +35,8 @@ if moretrees.enable_leafdecay then interval = moretrees.leafdecay_delay, chance = moretrees.leafdecay_chance, action = function(pos, node, active_object_count, active_object_count_wider) - if not minetest.env:find_node_near(pos, moretrees.leafdecay_radius, "moretrees:fir_trunk") then - minetest.env:remove_node(pos) + if not minetest.find_node_near(pos, moretrees.leafdecay_radius, "moretrees:fir_trunk") then + minetest.remove_node(pos) nodeupdate(pos) end end @@ -47,8 +47,8 @@ if moretrees.enable_leafdecay then interval = moretrees.leafdecay_delay, chance = moretrees.leafdecay_chance, action = function(pos, node, active_object_count, active_object_count_wider) - if not minetest.env:find_node_near(pos, moretrees.palm_leafdecay_radius, "moretrees:palm_trunk") then - minetest.env:remove_node(pos) + if not minetest.find_node_near(pos, moretrees.palm_leafdecay_radius, "moretrees:palm_trunk") then + minetest.remove_node(pos) nodeupdate(pos) end end @@ -61,8 +61,8 @@ if moretrees.enable_default_leafdecay then interval = moretrees.default_leafdecay_delay, chance = moretrees.default_leafdecay_chance, action = function(pos, node, active_object_count, active_object_count_wider) - if not minetest.env:find_node_near(pos, moretrees.default_leafdecay_radius, {"default:tree"}) then - minetest.env:remove_node(pos) + if not minetest.find_node_near(pos, moretrees.default_leafdecay_radius, {"default:tree"}) then + minetest.remove_node(pos) nodeupdate(pos) end end -- cgit v1.2.3