From eaeebd900b8416f63fd3306a12f042babed62899 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Tue, 14 Feb 2017 03:30:10 +0100 Subject: [PATCH] Add TNT support to dispenser --- mods/redstone/mcl_dispensers/init.lua | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/mods/redstone/mcl_dispensers/init.lua b/mods/redstone/mcl_dispensers/init.lua index c791b3f2c..81206f384 100644 --- a/mods/redstone/mcl_dispensers/init.lua +++ b/mods/redstone/mcl_dispensers/init.lua @@ -94,10 +94,20 @@ local dispenserdef = { end inv:set_stack("main", stack_id, stack) + elseif iname == "mcl_tnt:tnt" then + -- Place and ignite TNT + if dropnodedef.buildable_to then + minetest.set_node(droppos, {name = iname}) + tnt.ignite(droppos) + + stack:take_item() + inv:set_stack("main", stack_id, stack) + end elseif igroups.head or igroups.shulker_box or iname == "mcl_farming:pumpkin_face" then -- Place head, shulker box, or pumpkin if dropnodedef.buildable_to then minetest.set_node(droppos, {name = iname, param2 = node.param2}) + stack:take_item() inv:set_stack("main", stack_id, stack) end