Add flint, flint and steel
parent
89e1ca66ca
commit
f628e5086c
|
@ -197,6 +197,7 @@ Gambit (WTFPL):
|
|||
default_sign_wall_steel.png
|
||||
default_sign_wood.png
|
||||
default_sign_steel.png
|
||||
default_flint.png
|
||||
|
||||
asl97 (WTFPL):
|
||||
default_ice.png
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
default.register_craftitem("default:flint", {
|
||||
description = "Flint",
|
||||
inventory_image = "default_flint.png"
|
||||
})
|
||||
|
||||
-- Mese
|
||||
|
||||
default.register_craftitem("default:mese_crystal", {
|
||||
|
|
|
@ -6,4 +6,11 @@ default.register_node("default:gravel", {
|
|||
footstep = {name = "default_gravel_footstep", gain = 0.5},
|
||||
dug = {name = "default_gravel_footstep", gain = 1.0},
|
||||
}),
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {"default:flint"}, rarity = 16},
|
||||
{items = {"default:gravel"}}
|
||||
}
|
||||
}
|
||||
})
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 2.8 KiB |
|
@ -4,6 +4,7 @@ This mod is part of Minetest TNG
|
|||
License of source code:
|
||||
-----------------------
|
||||
Copyright (C) 2012 celeron55, Perttu Ahola <celeron55@gmail.com>
|
||||
Copyright (C) 2016 LNJ <lnj.git@gmail.com>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
|
@ -34,3 +35,6 @@ Muadtralk (CC BY-SA 3.0):
|
|||
|
||||
celeron55 (CC BY-SA 3.0):
|
||||
fire_basic_flame.png
|
||||
|
||||
Gambit (WTFPL):
|
||||
fire_flint_steel.png
|
||||
|
|
|
@ -36,6 +36,34 @@ minetest.register_node("fire:basic_flame", {
|
|||
on_blast = function() end, -- unaffected by explosions
|
||||
})
|
||||
|
||||
minetest.register_tool("fire:flint_and_steel", {
|
||||
description = "Flint and Steel",
|
||||
inventory_image = "fire_flint_steel.png",
|
||||
on_use = function(itemstack, user, pointed_thing)
|
||||
local player_name = user:get_player_name()
|
||||
local pt = pointed_thing
|
||||
|
||||
if pt.type == "node" and minetest.get_node(pt.above).name == "air" then
|
||||
if not minetest.is_protected(pt.above, player_name) then
|
||||
minetest.set_node(pt.above, {name="fire:basic_flame"})
|
||||
else
|
||||
minetest.chat_send_player(player_name, "This area is protected")
|
||||
end
|
||||
end
|
||||
|
||||
if not minetest.setting_getbool("creative_mode") then
|
||||
itemstack:add_wear(1000)
|
||||
return itemstack
|
||||
end
|
||||
end
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "fire:flint_and_steel",
|
||||
recipe = {
|
||||
{"default:flint", "default:steel_ingot"}
|
||||
}
|
||||
})
|
||||
|
||||
-- Get sound area of position
|
||||
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 2.9 KiB |
Loading…
Reference in New Issue