forked from MineClone5/MineClone5
Make fire charge a normal igniter, too
This commit is contained in:
parent
556370c403
commit
f2bee2286f
|
@ -15,19 +15,18 @@ minetest.register_craftitem("mcl_fire:fire_charge", {
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- Ignite/light fire
|
||||||
if pointed_thing.type == "node" then
|
if pointed_thing.type == "node" then
|
||||||
if minetest.get_node(pointed_thing.under).name == "mcl_tnt:tnt" then
|
local nodedef = minetest.registered_nodes[node.name]
|
||||||
tnt.ignite(pointed_thing.under)
|
if nodedef and nodedef._on_ignite then
|
||||||
if not minetest.settings:get_bool("creative_mode") then
|
nodedef._on_ignite(user, pointed_thing)
|
||||||
itemstack:take_item()
|
|
||||||
end
|
|
||||||
else
|
else
|
||||||
mcl_fire.set_fire(pointed_thing)
|
mcl_fire.set_fire(pointed_thing)
|
||||||
|
end
|
||||||
if not minetest.settings:get_bool("creative_mode") then
|
if not minetest.settings:get_bool("creative_mode") then
|
||||||
itemstack:take_item()
|
itemstack:take_item()
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
|
||||||
return itemstack
|
return itemstack
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue