Replace minetest.env: with minetest.

This commit is contained in:
Calinou 2014-05-07 19:43:36 +02:00
parent f405ae1595
commit c979440808
1 changed files with 3 additions and 3 deletions

View File

@ -576,9 +576,9 @@ minetest.register_tool("maptools:pick_admin_with_drops", {
minetest.register_on_punchnode(function(pos, node, puncher)
if puncher:get_wielded_item():get_name() == "maptools:pick_admin"
and minetest.env:get_node(pos).name ~= "air" then
minetest.log("action", minetest.env:get_node(pos).name .. " was removed using an Admin Pickaxe at " .. minetest.pos_to_string(pos) .. ".")
minetest.env:remove_node(pos) -- The node is removed directly, which means it even works on non-empty containers and group-less nodes.
and minetest.get_node(pos).name ~= "air" then
minetest.log("action", minetest.get_node(pos).name .. " was removed using an Admin Pickaxe at " .. minetest.pos_to_string(pos) .. ".")
minetest.remove_node(pos) -- The node is removed directly, which means it even works on non-empty containers and group-less nodes.
end
end)