forked from MineClone5/MineClone5
Move flint and steel to fire mod
This commit is contained in:
parent
3c1957b5b9
commit
1b76a91d6b
|
@ -401,12 +401,6 @@ minetest.register_craft({
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craft({
|
|
||||||
type = 'shapeless',
|
|
||||||
output = 'mcl_core:flint_and_steel',
|
|
||||||
recipe = { 'mcl_core:steel_ingot', 'mcl_core:flint'},
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_craft({
|
minetest.register_craft({
|
||||||
output = 'mcl_core:shears',
|
output = 'mcl_core:shears',
|
||||||
recipe = {
|
recipe = {
|
||||||
|
|
|
@ -312,33 +312,6 @@ minetest.register_tool("mcl_core:sword_diamond", {
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
-- Flint and Steel
|
|
||||||
minetest.register_tool("mcl_core:flint_and_steel", {
|
|
||||||
description = "Flint and Steel",
|
|
||||||
inventory_image = "default_tool_flint_and_steel.png",
|
|
||||||
liquids_pointable = false,
|
|
||||||
stack_max = 1,
|
|
||||||
groups = { tool = 1 },
|
|
||||||
tool_capabilities = {
|
|
||||||
full_punch_interval = 1.0,
|
|
||||||
max_drop_level=0,
|
|
||||||
groupcaps={
|
|
||||||
flamable = {uses=65, maxlevel=1},
|
|
||||||
}
|
|
||||||
},
|
|
||||||
on_use = function(itemstack, user, pointed_thing)
|
|
||||||
if pointed_thing.type == "node" then
|
|
||||||
if minetest.get_node(pointed_thing.under).name == "mcl_tnt:tnt" then
|
|
||||||
tnt.ignite(pointed_thing.under)
|
|
||||||
else
|
|
||||||
mcl_core.set_fire(pointed_thing)
|
|
||||||
itemstack:add_wear(66000/65) -- 65 uses
|
|
||||||
return itemstack
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end,
|
|
||||||
})
|
|
||||||
|
|
||||||
--Shears
|
--Shears
|
||||||
minetest.register_tool("mcl_core:shears", {
|
minetest.register_tool("mcl_core:shears", {
|
||||||
description = "Shears",
|
description = "Shears",
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
mcl_core
|
|
@ -0,0 +1,32 @@
|
||||||
|
-- Flint and Steel
|
||||||
|
minetest.register_tool("mcl_fire:flint_and_steel", {
|
||||||
|
description = "Flint and Steel",
|
||||||
|
inventory_image = "mcl_fire_flint_and_steel.png",
|
||||||
|
liquids_pointable = false,
|
||||||
|
stack_max = 1,
|
||||||
|
groups = { tool = 1 },
|
||||||
|
tool_capabilities = {
|
||||||
|
full_punch_interval = 1.0,
|
||||||
|
max_drop_level=0,
|
||||||
|
groupcaps={
|
||||||
|
flamable = {uses=65, maxlevel=1},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
on_use = function(itemstack, user, pointed_thing)
|
||||||
|
if pointed_thing.type == "node" then
|
||||||
|
if minetest.get_node(pointed_thing.under).name == "mcl_tnt:tnt" then
|
||||||
|
tnt.ignite(pointed_thing.under)
|
||||||
|
else
|
||||||
|
mcl_core.set_fire(pointed_thing)
|
||||||
|
itemstack:add_wear(66000/65) -- 65 uses
|
||||||
|
return itemstack
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = 'shapeless',
|
||||||
|
output = 'mcl_core:flint_and_steel',
|
||||||
|
recipe = { 'mcl_core:steel_ingot', 'mcl_core:flint'},
|
||||||
|
})
|
|
@ -191,7 +191,7 @@ minetest.register_abm({
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
|
|
||||||
|
dofile(minetest.get_modpath(minetest.get_current_modname()).."/flint_and_steel.lua")
|
||||||
|
|
||||||
local time_to_load= os.clock() - init
|
local time_to_load= os.clock() - init
|
||||||
print(string.format("[MOD] "..minetest.get_current_modname().." loaded in %.4f s", time_to_load))
|
print(string.format("[MOD] "..minetest.get_current_modname().." loaded in %.4f s", time_to_load))
|
||||||
|
|
||||||
|
|
||||||
|
|
Before Width: | Height: | Size: 282 B After Width: | Height: | Size: 282 B |
Loading…
Reference in New Issue