diff options
Diffstat (limited to 'mesecons_random')
-rw-r--r-- | mesecons_random/depends.txt | 2 | ||||
-rw-r--r-- | mesecons_random/init.lua | 33 |
2 files changed, 35 insertions, 0 deletions
diff --git a/mesecons_random/depends.txt b/mesecons_random/depends.txt new file mode 100644 index 0000000..0aa5cc3 --- /dev/null +++ b/mesecons_random/depends.txt @@ -0,0 +1,2 @@ +mesecons +experimental diff --git a/mesecons_random/init.lua b/mesecons_random/init.lua new file mode 100644 index 0000000..751e252 --- /dev/null +++ b/mesecons_random/init.lua @@ -0,0 +1,33 @@ +--Launch TNT + +mesecon:register_on_signal_on(function(pos, node) + if node.name=="experimental:tnt" then + minetest.env:remove_node(pos) + minetest.env:add_entity(pos, "experimental:tnt") + nodeupdate(pos) + end +end) + +-- REMOVE_STONE + +minetest.register_node("mesecons_random:removestone", { + tile_images = {"jeija_removestone.png"}, + inventory_image = minetest.inventorycube("jeija_removestone_inv.png"), + material = minetest.digprop_stonelike(1.0), + description="Removestone", +}) + +minetest.register_craft({ + output = '"mesecons_random:removestone" 4', + recipe = { + {'', '"default:cobble"',''}, + {'"default:cobble"', '"mesecons:mesecon_off"', '"default:cobble"'}, + {'', '"default:cobble"',''}, + } +}) + +mesecon:register_on_signal_on(function(pos, node) + if node.name=="mesecons_random:removestone" then + minetest.env:remove_node(pos) + end +end) |