forked from minetest/minetest_game
Add steel sign + Update wooden sign texture
This commit is contained in:
parent
f80fafbcfb
commit
aa676ab878
@ -27,7 +27,6 @@ Cisoun's WTFPL texture pack:
|
|||||||
default_lava.png
|
default_lava.png
|
||||||
default_leaves.png
|
default_leaves.png
|
||||||
default_sapling.png
|
default_sapling.png
|
||||||
default_sign_wall.png
|
|
||||||
default_stone.png
|
default_stone.png
|
||||||
default_tree.png
|
default_tree.png
|
||||||
default_tree_top.png
|
default_tree_top.png
|
||||||
@ -178,6 +177,7 @@ Gambit (WTFPL):
|
|||||||
default_paper.png
|
default_paper.png
|
||||||
default_diamond_block.png
|
default_diamond_block.png
|
||||||
default_ladder_steel.png
|
default_ladder_steel.png
|
||||||
|
default_sign_wall_wood.png
|
||||||
|
|
||||||
asl97 (WTFPL):
|
asl97 (WTFPL):
|
||||||
default_ice.png
|
default_ice.png
|
||||||
|
@ -32,7 +32,7 @@ minetest.register_alias("water_source", "default:water_source")
|
|||||||
minetest.register_alias("lava_flowing", "default:lava_flowing")
|
minetest.register_alias("lava_flowing", "default:lava_flowing")
|
||||||
minetest.register_alias("lava_source", "default:lava_source")
|
minetest.register_alias("lava_source", "default:lava_source")
|
||||||
minetest.register_alias("torch", "default:torch")
|
minetest.register_alias("torch", "default:torch")
|
||||||
minetest.register_alias("sign_wall", "default:sign_wall")
|
minetest.register_alias("sign_wall", "default:sign_wall_wood")
|
||||||
minetest.register_alias("furnace", "default:furnace")
|
minetest.register_alias("furnace", "default:furnace")
|
||||||
minetest.register_alias("chest", "default:chest")
|
minetest.register_alias("chest", "default:chest")
|
||||||
minetest.register_alias("locked_chest", "default:chest_locked")
|
minetest.register_alias("locked_chest", "default:chest_locked")
|
||||||
@ -76,4 +76,5 @@ minetest.register_alias("default:pinetree", "default:pine_tree")
|
|||||||
minetest.register_alias("default:pinewood", "default:pine_wood")
|
minetest.register_alias("default:pinewood", "default:pine_wood")
|
||||||
|
|
||||||
minetest.register_alias("default:ladder", "default:ladder_wood")
|
minetest.register_alias("default:ladder", "default:ladder_wood")
|
||||||
|
minetest.register_alias("default:sign_wall", "default:sign_wall_wood")
|
||||||
|
|
||||||
|
@ -43,7 +43,16 @@ minetest.register_craft({
|
|||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craft({
|
minetest.register_craft({
|
||||||
output = 'default:sign_wall',
|
output = 'default:sign_wall_steel 3',
|
||||||
|
recipe = {
|
||||||
|
{'default:steel_ingot', 'default:steel_ingot', 'default:steel_ingot'},
|
||||||
|
{'default:steel_ingot', 'default:steel_ingot', 'default:steel_ingot'},
|
||||||
|
{'', 'group:stick', ''},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'default:sign_wall_wood 3',
|
||||||
recipe = {
|
recipe = {
|
||||||
{'group:wood', 'group:wood', 'group:wood'},
|
{'group:wood', 'group:wood', 'group:wood'},
|
||||||
{'group:wood', 'group:wood', 'group:wood'},
|
{'group:wood', 'group:wood', 'group:wood'},
|
||||||
|
@ -146,7 +146,8 @@ default:chest_locked
|
|||||||
|
|
||||||
default:bookshelf
|
default:bookshelf
|
||||||
|
|
||||||
default:sign_wall
|
default:sign_wall_wood
|
||||||
|
default:sign_wall_steel
|
||||||
|
|
||||||
default:ladder_wood
|
default:ladder_wood
|
||||||
default:ladder_steel
|
default:ladder_steel
|
||||||
@ -1610,49 +1611,60 @@ minetest.register_node("default:bookshelf", {
|
|||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
|
|
||||||
|
local function register_sign(material, desc, def)
|
||||||
|
minetest.register_node("default:sign_wall_" .. material, {
|
||||||
|
description = desc .. " Sign",
|
||||||
|
drawtype = "nodebox",
|
||||||
|
tiles = {"default_sign_wall_" .. material .. ".png"},
|
||||||
|
inventory_image = "default_sign_" .. material .. ".png",
|
||||||
|
wield_image = "default_sign_" .. material .. ".png",
|
||||||
|
paramtype = "light",
|
||||||
|
paramtype2 = "wallmounted",
|
||||||
|
sunlight_propagates = true,
|
||||||
|
is_ground_content = false,
|
||||||
|
walkable = false,
|
||||||
|
node_box = {
|
||||||
|
type = "wallmounted",
|
||||||
|
wall_top = {-0.4375, 0.4375, -0.3125, 0.4375, 0.5, 0.3125},
|
||||||
|
wall_bottom = {-0.4375, -0.5, -0.3125, 0.4375, -0.4375, 0.3125},
|
||||||
|
wall_side = {-0.5, -0.3125, -0.4375, -0.4375, 0.3125, 0.4375},
|
||||||
|
},
|
||||||
|
groups = def.groups,
|
||||||
|
legacy_wallmounted = true,
|
||||||
|
sounds = def.sounds,
|
||||||
|
|
||||||
minetest.register_node("default:sign_wall", {
|
on_construct = function(pos)
|
||||||
description = "Sign",
|
--local n = minetest.get_node(pos)
|
||||||
drawtype = "nodebox",
|
local meta = minetest.get_meta(pos)
|
||||||
tiles = {"default_sign.png"},
|
meta:set_string("formspec", "field[text;;${text}]")
|
||||||
inventory_image = "default_sign_wall.png",
|
meta:set_string("infotext", "\"\"")
|
||||||
wield_image = "default_sign_wall.png",
|
end,
|
||||||
paramtype = "light",
|
on_receive_fields = function(pos, formname, fields, sender)
|
||||||
paramtype2 = "wallmounted",
|
--print("Sign at "..minetest.pos_to_string(pos).." got "..dump(fields))
|
||||||
sunlight_propagates = true,
|
local player_name = sender:get_player_name()
|
||||||
is_ground_content = false,
|
if minetest.is_protected(pos, player_name) then
|
||||||
walkable = false,
|
minetest.record_protection_violation(pos, player_name)
|
||||||
node_box = {
|
return
|
||||||
type = "wallmounted",
|
end
|
||||||
wall_top = {-0.4375, 0.4375, -0.3125, 0.4375, 0.5, 0.3125},
|
local meta = minetest.get_meta(pos)
|
||||||
wall_bottom = {-0.4375, -0.5, -0.3125, 0.4375, -0.4375, 0.3125},
|
if not fields.text then return end
|
||||||
wall_side = {-0.5, -0.3125, -0.4375, -0.4375, 0.3125, 0.4375},
|
minetest.log("action", (player_name or "") .. " wrote \"" ..
|
||||||
},
|
fields.text .. "\" to sign at " .. minetest.pos_to_string(pos))
|
||||||
groups = {choppy = 2, dig_immediate = 2, attached_node = 1},
|
meta:set_string("text", fields.text)
|
||||||
legacy_wallmounted = true,
|
meta:set_string("infotext", '"' .. fields.text .. '"')
|
||||||
sounds = default.node_sound_defaults(),
|
end,
|
||||||
|
})
|
||||||
|
end
|
||||||
|
|
||||||
on_construct = function(pos)
|
register_sign("wood", "Wooden", {
|
||||||
--local n = minetest.get_node(pos)
|
sounds = default.node_sound_wood_defaults(),
|
||||||
local meta = minetest.get_meta(pos)
|
groups = {choppy = 2, attached_node = 1, flammable = 2}
|
||||||
meta:set_string("formspec", "field[text;;${text}]")
|
|
||||||
meta:set_string("infotext", "\"\"")
|
|
||||||
end,
|
|
||||||
on_receive_fields = function(pos, formname, fields, sender)
|
|
||||||
--print("Sign at "..minetest.pos_to_string(pos).." got "..dump(fields))
|
|
||||||
if minetest.is_protected(pos, sender:get_player_name()) then
|
|
||||||
minetest.record_protection_violation(pos, sender:get_player_name())
|
|
||||||
return
|
|
||||||
end
|
|
||||||
local meta = minetest.get_meta(pos)
|
|
||||||
if not fields.text then return end
|
|
||||||
minetest.log("action", (sender:get_player_name() or "") .. " wrote \"" ..
|
|
||||||
fields.text .. "\" to sign at " .. minetest.pos_to_string(pos))
|
|
||||||
meta:set_string("text", fields.text)
|
|
||||||
meta:set_string("infotext", '"' .. fields.text .. '"')
|
|
||||||
end,
|
|
||||||
})
|
})
|
||||||
|
|
||||||
|
register_sign("steel", "Steel", {
|
||||||
|
sounds = default.node_sound_defaults(),
|
||||||
|
groups = {cracky = 2, attached_node = 1}
|
||||||
|
})
|
||||||
|
|
||||||
minetest.register_node("default:ladder_wood", {
|
minetest.register_node("default:ladder_wood", {
|
||||||
description = "Wooden Ladder",
|
description = "Wooden Ladder",
|
||||||
|
Binary file not shown.
Before Width: | Height: | Size: 442 B |
BIN
mods/default/textures/default_sign_steel.png
Normal file
BIN
mods/default/textures/default_sign_steel.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.1 KiB |
Binary file not shown.
Before Width: | Height: | Size: 416 B |
BIN
mods/default/textures/default_sign_wall_steel.png
Normal file
BIN
mods/default/textures/default_sign_wall_steel.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.1 KiB |
BIN
mods/default/textures/default_sign_wall_wood.png
Normal file
BIN
mods/default/textures/default_sign_wall_wood.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.3 KiB |
BIN
mods/default/textures/default_sign_wood.png
Normal file
BIN
mods/default/textures/default_sign_wood.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.3 KiB |
Loading…
Reference in New Issue
Block a user