Creation of signs_road mod
13
signs_road/LICENSE.txt
Normal file
@ -0,0 +1,13 @@
|
||||
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
|
||||
Version 2, December 2004
|
||||
|
||||
Copyright (C) 2004 Sam Hocevar <sam@hocevar.net>
|
||||
|
||||
Everyone is permitted to copy and distribute verbatim or modified
|
||||
copies of this license document, and changing it is allowed as long
|
||||
as the name is changed.
|
||||
|
||||
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
|
||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||
|
||||
0. You just DO WHAT THE FUCK YOU WANT TO.
|
34
signs_road/README.md
Normal file
@ -0,0 +1,34 @@
|
||||
# Signs Road
|
||||
|
||||
This mod provides road signs with text display. Text is locked if area is protected.
|
||||
|
||||
**Dependancies**: default, display\_lib, font\_lib, signs
|
||||
|
||||
**License**: WTFPL
|
||||
|
||||
## Recipes
|
||||
|
||||
**Blue Street Sign**
|
||||
|
||||
B W S
|
||||
S S S
|
||||
- - -
|
||||
|
||||
B = Blue Dye, W = White Dye, S = Steel Ingot
|
||||
|
||||
**Green Street Sign**
|
||||
|
||||
G W S
|
||||
S S S
|
||||
- - -
|
||||
|
||||
G = Green Dye, W = White Dye, S = Steel Ingot
|
||||
|
||||
**Black direction sign**
|
||||
|
||||
B W S
|
||||
S S -
|
||||
- - -
|
||||
|
||||
B = Black Dye, W = White Dye, S = Steel Ingot
|
||||
|
27
signs_road/crafts.lua
Normal file
@ -0,0 +1,27 @@
|
||||
minetest.register_craft({
|
||||
output = 'signs_road:blue_street',
|
||||
recipe = {
|
||||
{'dye:blue', 'dye:white', 'default:steel_ingot'},
|
||||
{'default:steel_ingot', 'default:steel_ingot', 'default:steel_ingot'},
|
||||
{'', '', ''},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = 'signs_road:green_street',
|
||||
recipe = {
|
||||
{'dye:green', 'dye:white', 'default:steel_ingot'},
|
||||
{'default:steel_ingot', 'default:steel_ingot', 'default:steel_ingot'},
|
||||
{'', '', ''},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = 'signs_road:black_right',
|
||||
recipe = {
|
||||
{'dye:black', 'dye:white', 'default:steel_ingot'},
|
||||
{'default:steel_ingot', 'default:steel_ingot', ''},
|
||||
{'', '', ''},
|
||||
}
|
||||
})
|
||||
|
4
signs_road/depends.txt
Normal file
@ -0,0 +1,4 @@
|
||||
default
|
||||
display_lib
|
||||
font_lib
|
||||
signs
|
14
signs_road/init.lua
Normal file
@ -0,0 +1,14 @@
|
||||
-- Signs mod by P.Y. Rollo
|
||||
--
|
||||
-- License: WTFPL
|
||||
|
||||
signs_road = {}
|
||||
signs_road.path = minetest.get_modpath("signs_road")
|
||||
|
||||
dofile(signs_road.path.."/nodes.lua")
|
||||
dofile(signs_road.path.."/crafts.lua")
|
||||
|
||||
|
||||
|
||||
|
||||
|
75
signs_road/nodes.lua
Normal file
@ -0,0 +1,75 @@
|
||||
|
||||
local models = {
|
||||
blue_street={
|
||||
depth = 1/16,
|
||||
width = 14/16,
|
||||
height = 12/16,
|
||||
entity_fields = {
|
||||
resolution = { x = 144, y = 64 },
|
||||
maxlines = 3,
|
||||
color="#fff",
|
||||
},
|
||||
node_fields = {
|
||||
description="Blue street sign",
|
||||
tiles={"signs_blue_street.png"},
|
||||
inventory_image="signs_blue_street_inventory.png",
|
||||
},
|
||||
},
|
||||
green_street={
|
||||
depth=1/32,
|
||||
width = 1,
|
||||
height = 6/16,
|
||||
entity_fields = {
|
||||
resolution = { x = 96, y = 64 },
|
||||
maxlines = 1,
|
||||
color="#fff",
|
||||
},
|
||||
node_fields = {
|
||||
description="Green street sign",
|
||||
tiles={"signs_green_street.png"},
|
||||
inventory_image="signs_green_street_inventory.png",
|
||||
},
|
||||
},
|
||||
black_right={
|
||||
depth=1/32,
|
||||
width = 1,
|
||||
height = 0.5,
|
||||
entity_fields = {
|
||||
resolution = { x = 96, y = 64 },
|
||||
maxlines = 1,
|
||||
color="#000",
|
||||
},
|
||||
node_fields = {
|
||||
description="Black direction sign",
|
||||
tiles={"signs_black_right.png"},
|
||||
inventory_image="signs_black_inventory.png",
|
||||
on_place=signs.on_place_direction,
|
||||
on_rotate=signs.on_rotate_direction,
|
||||
},
|
||||
},
|
||||
black_left={
|
||||
depth=1/32,
|
||||
width = 1,
|
||||
height = 0.5,
|
||||
entity_fields = {
|
||||
resolution = { x = 96, y = 64 },
|
||||
maxlines = 1,
|
||||
color="#000",
|
||||
},
|
||||
node_fields = {
|
||||
description="Black direction sign",
|
||||
tiles={"signs_black_left.png"},
|
||||
inventory_image="signs_black_inventory.png",
|
||||
groups={choppy=1,oddly_breakable_by_hand=1,not_in_creative_inventory=1},
|
||||
drop="signs:black_right",
|
||||
on_place=signs.on_place_direction,
|
||||
on_rotate=signs.on_rotate_direction,
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
for name, model in pairs(models)
|
||||
do
|
||||
signs.register_sign("signs_road", name, model)
|
||||
end
|
BIN
signs_road/textures/signs_black_inventory.png
Normal file
After Width: | Height: | Size: 265 B |
BIN
signs_road/textures/signs_black_left.png
Normal file
After Width: | Height: | Size: 263 B |
BIN
signs_road/textures/signs_black_right.png
Normal file
After Width: | Height: | Size: 258 B |
BIN
signs_road/textures/signs_blue_street.png
Normal file
After Width: | Height: | Size: 436 B |
BIN
signs_road/textures/signs_blue_street_inventory.png
Normal file
After Width: | Height: | Size: 472 B |
BIN
signs_road/textures/signs_green_street.png
Normal file
After Width: | Height: | Size: 274 B |
BIN
signs_road/textures/signs_green_street_inventory.png
Normal file
After Width: | Height: | Size: 279 B |