Fire / tnt: Make flint-and-steel use node on_ignite functions

Add on_ignite functions to tnt, gunpowder, coalblock.
This commit is contained in:
Fernando Carmona Varo 2016-10-24 22:24:49 +02:00 committed by paramat
parent 6464db97e7
commit 3601aac35c

@ -418,7 +418,10 @@ minetest.register_node("tnt:gunpowder", {
end, end,
on_burn = function(pos) on_burn = function(pos)
minetest.set_node(pos, {name = "tnt:gunpowder_burning"}) minetest.set_node(pos, {name = "tnt:gunpowder_burning"})
end end,
on_ignite = function(pos, igniter)
minetest.set_node(pos, {name = "tnt:gunpowder_burning"})
end,
}) })
minetest.register_node("tnt:gunpowder_burning", { minetest.register_node("tnt:gunpowder_burning", {
@ -563,7 +566,10 @@ function tnt.register_tnt(def)
}, },
on_burn = function(pos) on_burn = function(pos)
minetest.set_node(pos, {name = name .. "_burning"}) minetest.set_node(pos, {name = name .. "_burning"})
end end,
on_ignite = function(pos, igniter)
minetest.set_node(pos, {name = name .. "_burning"})
end,
}) })
end end