From 23d0f622411a02b0a806a85705345f38a4efc4ba Mon Sep 17 00:00:00 2001 From: kaadmy Date: Thu, 24 Sep 2015 11:48:49 -0700 Subject: [PATCH] tnt can now be detonated by weak torches and flint and steel --- mods/tnt/init.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/mods/tnt/init.lua b/mods/tnt/init.lua index b87739c..6217627 100644 --- a/mods/tnt/init.lua +++ b/mods/tnt/init.lua @@ -213,7 +213,9 @@ minetest.register_node( groups = {dig_immediate=2, mesecon=2}, sounds = default.node_sound_wood_defaults(), on_punch = function(pos, node, puncher) - if puncher:get_wielded_item():get_name() == "default:torch" then + local itemname = puncher:get_wielded_item():get_name() + + if itemname == "default:torch" or itemname == "default:torch_weak" or itemname == "default:flint_and_steel" then minetest.sound_play("tnt_ignite", {pos=pos}) minetest.set_node(pos, {name="tnt:tnt_burning"}) minetest.get_node_timer(pos):start(4)