Skip to content

Commit

Permalink
added timer to tnt:tnt_burning for explosions
Browse files Browse the repository at this point in the history
By adding the timer to the tnt:tnt_burning node it will help mods add the block and cause an explosion after 4 seconds instead of doing nothing like in it's current state.
  • Loading branch information
tenplus1 authored and paramat committed Feb 18, 2016
1 parent b47a556 commit 36d18cb
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion mods/tnt/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,6 @@ minetest.register_node("tnt:tnt", {
if puncher:get_wielded_item():get_name() == "default:torch" then
minetest.sound_play("tnt_ignite", {pos=pos})
minetest.set_node(pos, {name="tnt:tnt_burning"})
minetest.get_node_timer(pos):start(4)
end
end,
on_blast = function(pos, intensity)
Expand All @@ -258,6 +257,9 @@ minetest.register_node("tnt:tnt_burning", {
light_source = 5,
drop = "",
sounds = default.node_sound_wood_defaults(),
on_construct = function(pos)
minetest.get_node_timer(pos):start(4)
end,
on_timer = boom,
-- unaffected by explosions
on_blast = function() end,
Expand Down

0 comments on commit 36d18cb

Please sign in to comment.