update signs_lib, basic_signs, street_signs, and digistuff
This commit is contained in:
parent
6d7ce5db1f
commit
5556c8b83e
@ -9,20 +9,6 @@ dofile(basic_signs.path .. "/crafting.lua")
|
||||
local S, NS = dofile(basic_signs.path .. "/intllib.lua")
|
||||
basic_signs.gettext = S
|
||||
|
||||
local cbox
|
||||
|
||||
-- array : color, translated color, default text color
|
||||
local sign_colors = {
|
||||
{"green", S("green"), "f"},
|
||||
{"yellow", S("yellow"), "0"},
|
||||
{"red", S("red"), "f"},
|
||||
{"white_red", S("white_red"), "4"},
|
||||
{"white_black", S("white_black"), "0"},
|
||||
{"orange", S("orange"), "0"},
|
||||
{"blue", S("blue"), "f"},
|
||||
{"brown", S("brown"), "f"},
|
||||
}
|
||||
|
||||
function basic_signs.determine_sign_type(pos, placer, itemstack, pointed_thing)
|
||||
local playername = placer:get_player_name()
|
||||
local pt_name = minetest.get_node(pointed_thing.under).name
|
||||
@ -57,137 +43,66 @@ function basic_signs.determine_sign_type(pos, placer, itemstack, pointed_thing)
|
||||
return itemstack
|
||||
end
|
||||
|
||||
for _, onpole in ipairs({"", "_onpole"}) do
|
||||
minetest.override_item("default:sign_wall_wood", {
|
||||
after_place_node = basic_signs.determine_sign_type
|
||||
})
|
||||
|
||||
local nci = nil
|
||||
local pole_mount_tex = nil
|
||||
signs_lib.register_sign("basic_signs:sign_wall_locked", {
|
||||
description = S("Locked Sign"),
|
||||
tiles = {
|
||||
"basic_signs_sign_wall_locked.png",
|
||||
"signs_lib_sign_wall_steel_edges.png",
|
||||
},
|
||||
inventory_image = "basic_signs_sign_wall_locked_inv.png",
|
||||
locked = true,
|
||||
entity_info = "standard",
|
||||
})
|
||||
|
||||
if onpole == "_onpole" then
|
||||
nci = 1
|
||||
pole_mount_tex = "signs_lib_pole_mount.png" -- the metal straps on back, if needed
|
||||
end
|
||||
minetest.register_alias("locked_sign:sign_wall_locked", "basic_signs:sign_wall_locked")
|
||||
|
||||
local wood_groups = table.copy(signs_lib.standard_wood_groups)
|
||||
wood_groups.not_in_creative_inventory = nci
|
||||
local steel_groups = table.copy(signs_lib.standard_steel_groups)
|
||||
steel_groups.not_in_creative_inventory = nci
|
||||
-- array : color, translated color, default text color
|
||||
|
||||
cbox = signs_lib.make_selection_boxes(35, 25, onpole)
|
||||
local sign_colors = {
|
||||
{"green", S("green"), "f"},
|
||||
{"yellow", S("yellow"), "0"},
|
||||
{"red", S("red"), "f"},
|
||||
{"white_red", S("white_red"), "4"},
|
||||
{"white_black", S("white_black"), "0"},
|
||||
{"orange", S("orange"), "0"},
|
||||
{"blue", S("blue"), "f"},
|
||||
{"brown", S("brown"), "f"},
|
||||
}
|
||||
|
||||
minetest.override_item("default:sign_wall_wood"..onpole, {
|
||||
after_place_node = basic_signs.determine_sign_type
|
||||
})
|
||||
local cbox = signs_lib.make_selection_boxes(35, 25, true, 0, 0, 0, true)
|
||||
|
||||
minetest.register_node("basic_signs:sign_wall_locked"..onpole, {
|
||||
description = S("Locked Sign"),
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
for i, color in ipairs(sign_colors) do
|
||||
signs_lib.register_sign("basic_signs:sign_wall_steel_"..color[1], {
|
||||
description = S("Sign (@1, steel)", color[2]),
|
||||
paramtype2 = "facedir",
|
||||
selection_box = cbox,
|
||||
mesh = "signs_lib_standard_wall_sign"..onpole..".obj",
|
||||
mesh = "signs_lib_standard_wall_sign_facedir.obj",
|
||||
tiles = {
|
||||
"basic_signs_sign_wall_locked.png",
|
||||
"basic_signs_steel_"..color[1]..".png",
|
||||
"signs_lib_sign_wall_steel_edges.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "basic_signs_sign_wall_locked_inv.png",
|
||||
wield_image = "basic_signs_sign_wall_locked_inv.png",
|
||||
groups = wood_groups,
|
||||
default_color = "0",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
after_place_node = function(pos, placer, itemstack, pointed_thing)
|
||||
signs_lib.after_place_node(pos, placer, itemstack, pointed_thing, true)
|
||||
end,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
can_dig = signs_lib.can_modify,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
number_of_lines = signs_lib.standard_lines,
|
||||
horiz_scaling = signs_lib.standard_hscale,
|
||||
vert_scaling = signs_lib.standard_vscale,
|
||||
line_spacing = signs_lib.standard_lspace,
|
||||
font_size = signs_lib.standard_fsize,
|
||||
x_offset = signs_lib.standard_xoffs,
|
||||
y_offset = signs_lib.standard_yoffs,
|
||||
chars_per_line = signs_lib.standard_cpl,
|
||||
inventory_image = "basic_signs_steel_"..color[1].."_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
default_color = color[3],
|
||||
entity_info = {
|
||||
mesh = "signs_lib_standard_wall_sign_entity"..onpole..".obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
mesh = "signs_lib_standard_wall_sign_entity.obj",
|
||||
yaw = signs_lib.standard_yaw
|
||||
},
|
||||
drop = "basic_signs:sign_wall_locked"
|
||||
})
|
||||
table.insert(signs_lib.lbm_restore_nodes, "basic_signs:sign_wall_locked"..onpole)
|
||||
table.insert(signs_lib.lbm_restore_nodes, "locked_sign:sign_wall_locked"..onpole)
|
||||
|
||||
minetest.register_alias("locked_sign:sign_wall_locked", "basic_signs:sign_wall_locked")
|
||||
|
||||
cbox = signs_lib.make_selection_boxes(35, 25, onpole, 0, 0, 0, true)
|
||||
|
||||
for i, color in ipairs(sign_colors) do
|
||||
minetest.register_node("basic_signs:sign_wall_steel_"..color[1]..onpole, {
|
||||
description = S("Sign (@1, steel)", color[2]),
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "facedir",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "signs_lib_standard_wall_sign_facedir"..onpole..".obj",
|
||||
tiles = {
|
||||
"basic_signs_steel_"..color[1]..".png",
|
||||
"signs_lib_sign_wall_steel_edges.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "basic_signs_steel_"..color[1].."_inv.png",
|
||||
wield_image = "basic_signs_steel_"..color[1].."_inv.png",
|
||||
groups = steel_groups,
|
||||
default_color = color[3],
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.facedir_rotate,
|
||||
number_of_lines = signs_lib.standard_lines,
|
||||
horiz_scaling = signs_lib.standard_hscale,
|
||||
vert_scaling = signs_lib.standard_vscale,
|
||||
line_spacing = signs_lib.standard_lspace,
|
||||
font_size = signs_lib.standard_fsize,
|
||||
x_offset = signs_lib.standard_xoffs,
|
||||
y_offset = signs_lib.standard_yoffs,
|
||||
chars_per_line = signs_lib.standard_cpl,
|
||||
entity_info = {
|
||||
mesh = "signs_lib_standard_wall_sign_entity"..onpole..".obj",
|
||||
yaw = signs_lib.standard_yaw
|
||||
},
|
||||
drop = "basic_signs:sign_wall_steel_"..color[1]
|
||||
})
|
||||
table.insert(signs_lib.lbm_restore_nodes, "basic_signs:sign_wall_steel_"..color[1]..onpole)
|
||||
table.insert(signs_lib.lbm_restore_nodes, "signs:sign_wall_"..color[1]..onpole)
|
||||
|
||||
minetest.register_alias("signs:sign_wall_"..color[1], "basic_signs:sign_wall_steel_"..color[1])
|
||||
|
||||
end
|
||||
table.insert(signs_lib.lbm_restore_nodes, "signs:sign_wall_"..color[1])
|
||||
minetest.register_alias("signs:sign_wall_"..color[1], "basic_signs:sign_wall_steel_"..color[1])
|
||||
end
|
||||
|
||||
cbox = signs_lib.make_selection_boxes(35, 34.5, false, 0, -1.25, -19.69, true)
|
||||
|
||||
local nci_wood_groups = table.copy(signs_lib.standard_wood_groups)
|
||||
nci_wood_groups.not_in_creative_inventory = 1
|
||||
|
||||
minetest.register_node("basic_signs:yard_sign", {
|
||||
signs_lib.register_sign("basic_signs:yard_sign", {
|
||||
description = "Wooden yard sign",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "facedir",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
selection_box = signs_lib.make_selection_boxes(35, 34.5, false, 0, -1.25, -19.69, true),
|
||||
mesh = "basic_signs_yard_sign.obj",
|
||||
tiles = {
|
||||
"signs_lib_sign_wall_wooden.png",
|
||||
@ -195,44 +110,18 @@ minetest.register_node("basic_signs:yard_sign", {
|
||||
"default_wood.png"
|
||||
},
|
||||
inventory_image = "default_sign_wood.png",
|
||||
wield_image = "default_sign_wood.png",
|
||||
groups = nci_wood_groups,
|
||||
default_color = "0",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.facedir_rotate,
|
||||
number_of_lines = signs_lib.standard_lines,
|
||||
horiz_scaling = signs_lib.standard_hscale,
|
||||
vert_scaling = signs_lib.standard_vscale,
|
||||
line_spacing = signs_lib.standard_lspace,
|
||||
font_size = signs_lib.standard_fsize,
|
||||
x_offset = signs_lib.standard_xoffs,
|
||||
y_offset = signs_lib.standard_yoffs,
|
||||
chars_per_line = signs_lib.standard_cpl,
|
||||
entity_info = {
|
||||
mesh = "basic_signs_yard_sign_entity.obj",
|
||||
yaw = signs_lib.standard_yaw
|
||||
},
|
||||
drop = "default:sign_wall_wood"
|
||||
drop = "default:sign_wall_wood",
|
||||
allow_onpole = false
|
||||
})
|
||||
table.insert(signs_lib.lbm_restore_nodes, "basic_signs:yard_sign")
|
||||
table.insert(signs_lib.lbm_restore_nodes, "signs:sign_yard")
|
||||
minetest.register_alias("signs:sign_yard", "basic_signs:yard_sign")
|
||||
|
||||
cbox = signs_lib.make_selection_boxes(35, 32, false, 0, 3, -18.5, true)
|
||||
|
||||
minetest.register_node("basic_signs:hanging_sign", {
|
||||
signs_lib.register_sign("basic_signs:hanging_sign", {
|
||||
description = "Wooden sign, hanging",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "facedir",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
selection_box = signs_lib.make_selection_boxes(35, 32, false, 0, 3, -18.5, true),
|
||||
mesh = "basic_signs_hanging_sign.obj",
|
||||
tiles = {
|
||||
"signs_lib_sign_wall_wooden.png",
|
||||
@ -240,36 +129,16 @@ minetest.register_node("basic_signs:hanging_sign", {
|
||||
"basic_signs_ceiling_hangers.png"
|
||||
},
|
||||
inventory_image = "default_sign_wood.png",
|
||||
wield_image = "default_sign_wood.png",
|
||||
groups = nci_wood_groups,
|
||||
default_color = "0",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.facedir_rotate,
|
||||
number_of_lines = signs_lib.standard_lines,
|
||||
horiz_scaling = signs_lib.standard_hscale,
|
||||
vert_scaling = signs_lib.standard_vscale,
|
||||
line_spacing = signs_lib.standard_lspace,
|
||||
font_size = signs_lib.standard_fsize,
|
||||
x_offset = signs_lib.standard_xoffs,
|
||||
y_offset = signs_lib.standard_yoffs,
|
||||
chars_per_line = signs_lib.standard_cpl,
|
||||
entity_info = {
|
||||
mesh = "basic_signs_hanging_sign_entity.obj",
|
||||
yaw = signs_lib.standard_yaw
|
||||
},
|
||||
drop = "default:sign_wall_wood"
|
||||
drop = "default:sign_wall_wood",
|
||||
allow_onpole = false
|
||||
})
|
||||
table.insert(signs_lib.lbm_restore_nodes, "basic_signs:hanging_sign")
|
||||
|
||||
table.insert(signs_lib.lbm_restore_nodes, "signs:sign_yard")
|
||||
table.insert(signs_lib.lbm_restore_nodes, "signs:sign_hanging")
|
||||
minetest.register_alias("signs:sign_yard", "basic_signs:yard_sign")
|
||||
minetest.register_alias("signs:sign_hanging", "basic_signs:hanging_sign")
|
||||
|
||||
-- insert the old wood sign-on-fencepost into signs_lib's conversion LBM
|
||||
|
||||
table.insert(signs_lib.old_fenceposts_with_signs, "signs:sign_post")
|
||||
signs_lib.old_fenceposts["signs:sign_post"] = "default:fence_wood"
|
||||
signs_lib.old_fenceposts_replacement_signs["signs:sign_post"] = "default:sign_wall_wood_onpole"
|
||||
|
@ -1,10 +1,10 @@
|
||||
# Blender v2.79 (sub 0) OBJ File: 'basic_signs wooden hanging sign.blend'
|
||||
# www.blender.org
|
||||
o Plane
|
||||
v 0.406250 -0.281250 -0.039062
|
||||
v -0.406250 -0.281250 -0.039062
|
||||
v 0.406250 0.281250 -0.039063
|
||||
v -0.406250 0.281250 -0.039063
|
||||
v 0.406250 -0.281250 -0.042969
|
||||
v -0.406250 -0.281250 -0.042969
|
||||
v 0.406250 0.281250 -0.042969
|
||||
v -0.406250 0.281250 -0.042969
|
||||
vt 0.000000 0.000000
|
||||
vt 1.000000 0.000000
|
||||
vt 1.000000 1.000000
|
||||
|
@ -1,10 +1,10 @@
|
||||
# Blender v2.79 (sub 0) OBJ File: 'basic_signs wooden yard sign.blend'
|
||||
# www.blender.org
|
||||
o Plane
|
||||
v 0.406250 -0.218750 -0.070312
|
||||
v -0.406250 -0.218750 -0.070312
|
||||
v 0.406250 0.343750 -0.070313
|
||||
v -0.406250 0.343750 -0.070313
|
||||
v 0.406250 -0.218750 -0.074219
|
||||
v -0.406250 -0.218750 -0.074219
|
||||
v 0.406250 0.343750 -0.074219
|
||||
v -0.406250 0.343750 -0.074219
|
||||
vt 0.000000 0.000000
|
||||
vt 1.000000 0.000000
|
||||
vt 1.000000 1.000000
|
||||
|
@ -10,7 +10,8 @@ Textures WITH "adwaita" in the file name - These are icons by the GNOME Project,
|
||||
|
||||
Depends:
|
||||
Required: digilines (base only) and mesecons (base only)
|
||||
Only needed for craft recipes: default, mesecons_luacontroller, basic_materials
|
||||
Optional: mesecons_noteblock (for digilines noteblock), mesecons_mvps (for digilines piston), mesecons_luacontroller (for I/O expander)
|
||||
Only needed for craft recipes: default, basic_materials
|
||||
|
||||
|
||||
How to use digilines buttons:
|
||||
@ -66,3 +67,7 @@ Send a number representing a time in seconds, from 0.5 to 3600. When the time ex
|
||||
How to use the junction box:
|
||||
These are just plain digilines conductors (like digimese) but can skip over one node to another junction box or certain other nodes.
|
||||
As in, [digiline][junction box][dirt][junction box][digiline] will work to transmit signals "through" the dirt.
|
||||
|
||||
How to use the I/O expander:
|
||||
After setting a channel, send a table (same format as a Luacontroller's "port" table) to set the output states.
|
||||
A table in this same format will be sent back whenever an input changes or you manually poll it by sending a "GET" message.
|
||||
|
@ -14,6 +14,9 @@ local components = {
|
||||
"piston",
|
||||
"timer",
|
||||
}
|
||||
|
||||
if minetest.get_modpath("mesecons_luacontroller") then table.insert(components,"ioexpander") end
|
||||
|
||||
for _,name in ipairs(components) do
|
||||
dofile(string.format("%s%s%s.lua",minetest.get_modpath(minetest.get_current_modname()),DIR_DELIM,name))
|
||||
end
|
||||
|
176
digistuff/ioexpander.lua
Normal file
176
digistuff/ioexpander.lua
Normal file
@ -0,0 +1,176 @@
|
||||
local explode_port_states = function(state)
|
||||
local port = {}
|
||||
port.a = state%2 == 1
|
||||
port.b = state%4 >= 2
|
||||
port.c = state%8 >= 4
|
||||
port.d = state%16 >= 8
|
||||
return port
|
||||
end
|
||||
|
||||
local implode_port_states = function(port)
|
||||
local state = 0
|
||||
if port.a then state = state + 1 end
|
||||
if port.b then state = state + 2 end
|
||||
if port.c then state = state + 4 end
|
||||
if port.d then state = state + 8 end
|
||||
return state
|
||||
end
|
||||
|
||||
local gettiles = function(state)
|
||||
tiles = {
|
||||
"digistuff_ioexp_top.png",
|
||||
"jeija_microcontroller_bottom.png",
|
||||
"jeija_microcontroller_sides.png",
|
||||
"jeija_microcontroller_sides.png",
|
||||
"jeija_microcontroller_sides.png",
|
||||
"jeija_microcontroller_sides.png"
|
||||
}
|
||||
local port = explode_port_states(state)
|
||||
for p,v in pairs(port) do
|
||||
if v then
|
||||
tiles[1] = tiles[1].."^jeija_luacontroller_LED_"..string.upper(p)..".png"
|
||||
end
|
||||
end
|
||||
return tiles
|
||||
end
|
||||
|
||||
local ioexp_get_on_rules = function(state)
|
||||
local port = explode_port_states(state)
|
||||
local rules = {}
|
||||
if port.a then table.insert(rules,vector.new(-1,0,0)) end
|
||||
if port.b then table.insert(rules,vector.new(0,0,1)) end
|
||||
if port.c then table.insert(rules,vector.new(1,0,0)) end
|
||||
if port.d then table.insert(rules,vector.new(0,0,-1)) end
|
||||
return rules
|
||||
end
|
||||
|
||||
local ioexp_get_off_rules = function(state)
|
||||
local port = explode_port_states(state)
|
||||
local rules = {}
|
||||
if not port.a then table.insert(rules,vector.new(-1,0,0)) end
|
||||
if not port.b then table.insert(rules,vector.new(0,0,1)) end
|
||||
if not port.c then table.insert(rules,vector.new(1,0,0)) end
|
||||
if not port.d then table.insert(rules,vector.new(0,0,-1)) end
|
||||
return rules
|
||||
end
|
||||
|
||||
local ioexp_digiline_send = function(pos)
|
||||
local meta = minetest.get_meta(pos)
|
||||
local channel = meta:get_string("channel")
|
||||
local port = {
|
||||
a = meta:get_int("aon") == 1,
|
||||
b = meta:get_int("bon") == 1,
|
||||
c = meta:get_int("con") == 1,
|
||||
d = meta:get_int("don") == 1,
|
||||
}
|
||||
local outstate = explode_port_states(meta:get_int("outstate"))
|
||||
for k,v in pairs(outstate) do port[k] = port[k] or v end
|
||||
digiline:receptor_send(pos,digiline.rules.default,channel,port)
|
||||
end
|
||||
|
||||
local ioexp_handle_digilines = function(pos,node,channel,msg)
|
||||
local meta = minetest.get_meta(pos)
|
||||
if channel ~= meta:get_string("channel") then return end
|
||||
if msg == "GET" then
|
||||
ioexp_digiline_send(pos)
|
||||
return
|
||||
end
|
||||
if type(msg) ~= "table" then return end
|
||||
local state = implode_port_states(msg)
|
||||
node.name = "digistuff:ioexpander_"..state
|
||||
meta:set_int("outstate",state)
|
||||
minetest.swap_node(pos,node)
|
||||
for _,i in ipairs(ioexp_get_on_rules(state)) do
|
||||
mesecon.receptor_on(pos,{i})
|
||||
end
|
||||
for _,i in ipairs(ioexp_get_off_rules(state)) do
|
||||
mesecon.receptor_off(pos,{i})
|
||||
end
|
||||
end
|
||||
|
||||
local ioexp_rule_to_port = function(rule)
|
||||
if rule.x < 0 then return "a"
|
||||
elseif rule.z > 0 then return "b"
|
||||
elseif rule.x > 0 then return "c"
|
||||
elseif rule.z < 0 then return "d" end
|
||||
end
|
||||
|
||||
local ioexp_handle_mesecons = function(pos,_,rule,state)
|
||||
local meta = minetest.get_meta(pos)
|
||||
local port = ioexp_rule_to_port(rule)
|
||||
if not port then return end
|
||||
local meta = minetest.get_meta(pos)
|
||||
meta:set_int(port.."on",state == "on" and 1 or 0)
|
||||
ioexp_digiline_send(pos)
|
||||
end
|
||||
|
||||
for i=0,15,1 do
|
||||
local offstate = i == 0
|
||||
minetest.register_node("digistuff:ioexpander_"..i, {
|
||||
description = offstate and "Digilines I/O Expander" or string.format("Digilines I/O Expander (on state %X - you hacker you!)",i),
|
||||
groups = offstate and {cracky = 3,} or {cracky = 3,not_in_creative_inventory = 1,},
|
||||
on_construct = function(pos)
|
||||
local meta = minetest.get_meta(pos)
|
||||
meta:set_string("formspec","field[channel;Channel;${channel}")
|
||||
meta:set_int("aon",0)
|
||||
meta:set_int("bon",0)
|
||||
meta:set_int("con",0)
|
||||
meta:set_int("don",0)
|
||||
meta:set_int("outstate",i)
|
||||
end,
|
||||
tiles = gettiles(i),
|
||||
inventory_image = "digistuff_ioexp_top.png",
|
||||
drawtype = "nodebox",
|
||||
drop = "digistuff:ioexpander_0",
|
||||
selection_box = {
|
||||
--From luacontroller
|
||||
type = "fixed",
|
||||
fixed = { -8/16, -8/16, -8/16, 8/16, -5/16, 8/16 },
|
||||
},
|
||||
node_box = {
|
||||
--From Luacontroller
|
||||
type = "fixed",
|
||||
fixed = {
|
||||
{-8/16, -8/16, -8/16, 8/16, -7/16, 8/16}, -- Bottom slab
|
||||
{-5/16, -7/16, -5/16, 5/16, -6/16, 5/16}, -- Circuit board
|
||||
{-3/16, -6/16, -3/16, 3/16, -5/16, 3/16}, -- IC
|
||||
}
|
||||
},
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
on_receive_fields = function(pos, formname, fields, sender)
|
||||
local name = sender:get_player_name()
|
||||
if minetest.is_protected(pos,name) and not minetest.check_player_privs(name,{protection_bypass=true}) then
|
||||
minetest.record_protection_violation(pos,name)
|
||||
return
|
||||
end
|
||||
local meta = minetest.get_meta(pos)
|
||||
if fields.channel then meta:set_string("channel",fields.channel) end
|
||||
end,
|
||||
mesecons = {
|
||||
effector = {
|
||||
rules = ioexp_get_off_rules(i),
|
||||
action_change = ioexp_handle_mesecons,
|
||||
},
|
||||
receptor = {
|
||||
state = mesecon.state.on,
|
||||
rules = ioexp_get_on_rules(i),
|
||||
},
|
||||
},
|
||||
digiline = {
|
||||
receptor = {},
|
||||
effector = {
|
||||
action = ioexp_handle_digilines,
|
||||
},
|
||||
},
|
||||
})
|
||||
end
|
||||
|
||||
minetest.register_craft({
|
||||
output = "digistuff:ioexpander_0",
|
||||
recipe = {
|
||||
{"","mesecons:wire_00000000_off","",},
|
||||
{"digilines:wire_std_00000000","basic_materials:silicon","mesecons:wire_00000000_off",},
|
||||
{"","mesecons:wire_00000000_off","",},
|
||||
}
|
||||
})
|
BIN
digistuff/textures/digistuff_ioexp_top.png
Normal file
BIN
digistuff/textures/digistuff_ioexp_top.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 10 KiB |
@ -15,11 +15,19 @@ signs_lib.standard_vscale = 1
|
||||
signs_lib.standard_lspace = 1
|
||||
signs_lib.standard_fsize = 15
|
||||
signs_lib.standard_xoffs = 4
|
||||
signs_lib.standard_yoffs = 2
|
||||
signs_lib.standard_yoffs = 0
|
||||
signs_lib.standard_cpl = 35
|
||||
|
||||
signs_lib.standard_wood_groups = {sign = 1, choppy = 2, flammable = 2, oddly_breakable_by_hand = 3}
|
||||
signs_lib.standard_steel_groups = {sign = 1, cracky = 2, oddly_breakable_by_hand = 3}
|
||||
signs_lib.standard_wood_groups = table.copy(minetest.registered_items["default:sign_wall_wood"].groups)
|
||||
signs_lib.standard_wood_groups.sign = 1
|
||||
signs_lib.standard_wood_groups.attached_node = nil
|
||||
|
||||
signs_lib.standard_steel_groups = table.copy(minetest.registered_items["default:sign_wall_steel"].groups)
|
||||
signs_lib.standard_steel_groups.sign = 1
|
||||
signs_lib.standard_steel_groups.attached_node = nil
|
||||
|
||||
signs_lib.standard_wood_sign_sounds = table.copy(minetest.registered_items["default:sign_wall_wood"].sounds)
|
||||
signs_lib.standard_steel_sign_sounds = table.copy(minetest.registered_items["default:sign_wall_steel"].sounds)
|
||||
|
||||
signs_lib.standard_yaw = {
|
||||
0,
|
||||
@ -561,7 +569,7 @@ minetest.register_entity("signs_lib:text", {
|
||||
-- make selection boxes
|
||||
-- sizex/sizey specified in inches because that's what MUTCD uses.
|
||||
|
||||
function signs_lib.make_selection_boxes(sizex, sizey, onpole, xoffs, yoffs, zoffs, fdir)
|
||||
function signs_lib.make_selection_boxes(sizex, sizey, foo, xoffs, yoffs, zoffs, is_facedir)
|
||||
|
||||
local tx = (sizex * 0.0254 ) / 2
|
||||
local ty = (sizey * 0.0254 ) / 2
|
||||
@ -569,34 +577,18 @@ function signs_lib.make_selection_boxes(sizex, sizey, onpole, xoffs, yoffs, zoff
|
||||
local yo = yoffs and yoffs * 0.0254 or 0
|
||||
local zo = zoffs and zoffs * 0.0254 or 0
|
||||
|
||||
if onpole == "_onpole" then
|
||||
if not fdir then
|
||||
return {
|
||||
type = "wallmounted",
|
||||
wall_side = { -0.5 - 0.3125 + zo, -ty + yo, -tx + xo, -0.4375 - 0.3125 + zo, ty + yo , tx + xo },
|
||||
wall_top = {-0.5, -0.5, -0.5, 0.5, 0.5, 0.5 },
|
||||
wall_bottom = {-0.5, -0.5, -0.5, 0.5, 0.5, 0.5 },
|
||||
}
|
||||
else
|
||||
return {
|
||||
type = "fixed",
|
||||
fixed = { -tx + xo, -ty + yo, 0.5 + 0.3125 + zo, tx + xo, ty + yo, 0.4375 + 0.3125 + zo }
|
||||
}
|
||||
end
|
||||
if not is_facedir then
|
||||
return {
|
||||
type = "wallmounted",
|
||||
wall_side = { -0.5 + zo, -ty + yo, -tx + xo, -0.4375 + zo, ty + yo, tx + xo },
|
||||
wall_top = { -tx - xo, 0.5 + zo, -ty + yo, tx - xo, 0.4375 + zo, ty + yo},
|
||||
wall_bottom = { -tx - xo, -0.5 + zo, -ty + yo, tx - xo, -0.4375 + zo, ty + yo }
|
||||
}
|
||||
else
|
||||
if not fdir then
|
||||
return {
|
||||
type = "wallmounted",
|
||||
wall_side = { -0.5 + zo, -ty + yo, -tx + xo, -0.4375 + zo, ty + yo, tx + xo },
|
||||
wall_top = { -tx - xo, 0.5 + zo, -ty + yo, tx - xo, 0.4375 + zo, ty + yo},
|
||||
wall_bottom = { -tx - xo, -0.5 + zo, -ty + yo, tx - xo, -0.4375 + zo, ty + yo }
|
||||
}
|
||||
else
|
||||
return {
|
||||
type = "fixed",
|
||||
fixed = { -tx + xo, -ty + yo, 0.5 + zo, tx + xo, ty + yo, 0.4375 + zo}
|
||||
}
|
||||
end
|
||||
return {
|
||||
type = "fixed",
|
||||
fixed = { -tx + xo, -ty + yo, 0.5 + zo, tx + xo, ty + yo, 0.4375 + zo}
|
||||
}
|
||||
end
|
||||
end
|
||||
|
||||
@ -605,9 +597,6 @@ function signs_lib.check_for_pole(pos, pointed_thing)
|
||||
local pnode = minetest.get_node(ppos)
|
||||
local pdef = minetest.registered_items[pnode.name]
|
||||
|
||||
print(dump(pos))
|
||||
print(dump(ppos))
|
||||
|
||||
if (signs_lib.allowed_poles[pnode.name]
|
||||
or (pdef and pdef.drawtype == "fencelike")
|
||||
or string.find(pnode.name, "default:fence_")
|
||||
@ -618,18 +607,19 @@ function signs_lib.check_for_pole(pos, pointed_thing)
|
||||
)
|
||||
and
|
||||
(pos.x ~= ppos.x or pos.z ~= ppos.z) then
|
||||
print("signs_lib.check_for_pole returned true")
|
||||
return true
|
||||
end
|
||||
end
|
||||
|
||||
function signs_lib.after_place_node(pos, placer, itemstack, pointed_thing, locked)
|
||||
local playername = placer:get_player_name()
|
||||
local def = minetest.registered_items[itemstack:get_name()]
|
||||
|
||||
local ppos = minetest.get_pointed_thing_position(pointed_thing)
|
||||
local pnode = minetest.get_node(ppos)
|
||||
local pdef = minetest.registered_items[pnode.name]
|
||||
local playername = placer:get_player_name()
|
||||
|
||||
if signs_lib.check_for_pole(pos, pointed_thing) then
|
||||
if (def.allow_onpole ~= false) and signs_lib.check_for_pole(pos, pointed_thing) then
|
||||
local node = minetest.get_node(pos)
|
||||
minetest.swap_node(pos, {name = itemstack:get_name().."_onpole", param2 = node.param2})
|
||||
end
|
||||
@ -644,6 +634,154 @@ function signs_lib.register_fence_with_sign()
|
||||
minetest.log("warning", "[signs_lib] ".."Attempt to call no longer used function signs_lib.register_fence_with_sign()")
|
||||
end
|
||||
|
||||
--[[
|
||||
The main sign registration function
|
||||
===================================
|
||||
|
||||
Example minimal recommended def for writable signs:
|
||||
|
||||
signs_lib.register_sign("foo:my_cool_sign", {
|
||||
description = "Wooden cool sign",
|
||||
inventory_image = "signs_lib_sign_cool_inv.png",
|
||||
tiles = {
|
||||
"signs_lib_sign_cool.png",
|
||||
"signs_lib_sign_cool_edges.png"
|
||||
},
|
||||
number_of_lines = 2,
|
||||
horiz_scaling = 0.8,
|
||||
vert_scaling = 1,
|
||||
line_spacing = 9,
|
||||
font_size = 31,
|
||||
x_offset = 7,
|
||||
y_offset = 4,
|
||||
chars_per_line = 40,
|
||||
entity_info = "standard"
|
||||
})
|
||||
|
||||
* default def assumes a wallmounted sign with on-pole being allowed.
|
||||
|
||||
*For signs that can't support onpole, include in the def:
|
||||
allow_onpole = false,
|
||||
|
||||
* "standard" entity info implies the standard wood/steel sign model, in
|
||||
wallmounted mode. For facedir signs using the standard model, use:
|
||||
|
||||
entity_info = {
|
||||
mesh = "signs_lib_standard_wall_sign_entity.obj",
|
||||
yaw = signs_lib.standard_yaw
|
||||
},
|
||||
|
||||
]]--
|
||||
|
||||
function signs_lib.register_sign(name, rdef)
|
||||
|
||||
local def = table.copy(rdef)
|
||||
|
||||
if rdef.entity_info == "standard" then
|
||||
def.entity_info = {
|
||||
mesh = "signs_lib_standard_wall_sign_entity.obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
}
|
||||
elseif rdef.entity_info then
|
||||
def.entity_info = rdef.entity_info
|
||||
end
|
||||
|
||||
if rdef.entity_info then
|
||||
def.on_rightclick = rdef.on_rightclick or signs_lib.construct_sign
|
||||
def.on_construct = rdef.on_construct or signs_lib.construct_sign
|
||||
def.on_destruct = rdef.on_destruct or signs_lib.destruct_sign
|
||||
def.on_receive_fields = rdef.on_receive_fields or signs_lib.receive_fields
|
||||
def.on_punch = rdef.on_punch or signs_lib.update_sign
|
||||
def.number_of_lines = rdef.number_of_lines or signs_lib.standard_lines
|
||||
def.horiz_scaling = rdef.horiz_scaling or signs_lib.standard_hscale
|
||||
def.vert_scaling = rdef.vert_scaling or signs_lib.standard_vscale
|
||||
def.line_spacing = rdef.line_spacing or signs_lib.standard_lspace
|
||||
def.font_size = rdef.font_size or signs_lib.standard_fsize
|
||||
def.x_offset = rdef.x_offset or signs_lib.standard_xoffs
|
||||
def.y_offset = rdef.y_offset or signs_lib.standard_yoffs
|
||||
def.chars_per_line = rdef.chars_per_line or signs_lib.standard_cpl
|
||||
def.default_color = rdef.default_color or "0"
|
||||
if rdef.locked and not rdef.after_place_node then
|
||||
def.after_place_node = function(pos, placer, itemstack, pointed_thing)
|
||||
signs_lib.after_place_node(pos, placer, itemstack, pointed_thing, true)
|
||||
end
|
||||
else
|
||||
def.after_place_node = rdef.after_place_node or signs_lib.after_place_node
|
||||
end
|
||||
end
|
||||
|
||||
def.paramtype = rdef.paramtype or "light"
|
||||
def.paramtype2 = rdef.paramtype2 or "wallmounted"
|
||||
def.drawtype = rdef.drawtype or "mesh"
|
||||
def.mesh = rdef.mesh or "signs_lib_standard_wall_sign.obj"
|
||||
def.wield_image = rdef.wield_image or def.inventory_image
|
||||
def.drop = rdef.drop or name
|
||||
def.sounds = rdef.sounds or signs_lib.standard_wood_sign_sounds
|
||||
def.on_rotate = rdef.on_rotate or signs_lib.wallmounted_rotate
|
||||
|
||||
if rdef.on_rotate then
|
||||
def.on_rotate = rdef.on_rotate
|
||||
elseif rdef.drawtype == "wallmounted" then
|
||||
def.on_rotate = signs_lib.wallmounted_rotate
|
||||
else
|
||||
def.on_rotate = signs_lib.facedir_rotate
|
||||
end
|
||||
|
||||
if rdef.groups then
|
||||
def.groups = rdef.groups
|
||||
else
|
||||
def.groups = signs_lib.standard_wood_groups
|
||||
end
|
||||
|
||||
local cbox = signs_lib.make_selection_boxes(35, 25, allow_onpole)
|
||||
|
||||
def.selection_box = rdef.selection_box or cbox
|
||||
def.node_box = table.copy(rdef.node_box or rdef.selection_box or cbox)
|
||||
|
||||
if def.sunlight_propagates ~= false then
|
||||
def.sunlight_propagates = true
|
||||
end
|
||||
|
||||
minetest.register_node(":"..name, def)
|
||||
table.insert(signs_lib.lbm_restore_nodes, name)
|
||||
|
||||
if rdef.allow_onpole ~= false then
|
||||
|
||||
local opdef = table.copy(def)
|
||||
|
||||
local offset = 0.3125
|
||||
if opdef.uses_slim_pole_mount then
|
||||
offset = 0.35
|
||||
end
|
||||
|
||||
if opdef.paramtype2 == "wallmounted" then
|
||||
opdef.node_box.wall_side[1] = def.node_box.wall_side[1] - offset
|
||||
opdef.node_box.wall_side[4] = def.node_box.wall_side[4] - offset
|
||||
|
||||
opdef.selection_box.wall_side[1] = def.selection_box.wall_side[1] - offset
|
||||
opdef.selection_box.wall_side[4] = def.selection_box.wall_side[4] - offset
|
||||
else
|
||||
opdef.node_box.fixed[3] = def.node_box.fixed[3] + offset
|
||||
opdef.node_box.fixed[6] = def.node_box.fixed[6] + offset
|
||||
|
||||
opdef.selection_box.fixed[3] = def.selection_box.fixed[3] + offset
|
||||
opdef.selection_box.fixed[6] = def.selection_box.fixed[6] + offset
|
||||
end
|
||||
|
||||
opdef.groups.not_in_creative_inventory = 1
|
||||
opdef.tiles[3] = "signs_lib_pole_mount.png"
|
||||
opdef.mesh = string.gsub(opdef.mesh, ".obj$", "_onpole.obj")
|
||||
opdef.on_rotate = nil
|
||||
|
||||
|
||||
if opdef.entity_info then
|
||||
opdef.entity_info.mesh = string.gsub(opdef.entity_info.mesh, ".obj$", "_onpole.obj")
|
||||
end
|
||||
minetest.register_node(":"..name.."_onpole", opdef)
|
||||
table.insert(signs_lib.lbm_restore_nodes, name.."_onpole")
|
||||
end
|
||||
end
|
||||
|
||||
-- restore signs' text after /clearobjects and the like, the next time
|
||||
-- a block is reloaded by the server.
|
||||
|
||||
|
BIN
signs_lib/models/basic_signs wooden sign.blend
Normal file
BIN
signs_lib/models/basic_signs wooden sign.blend
Normal file
Binary file not shown.
@ -1,10 +1,10 @@
|
||||
# Blender v2.79 (sub 0) OBJ File: 'basic_signs wooden sign.blend'
|
||||
# www.blender.org
|
||||
o text_entity_Plane
|
||||
v 0.406250 -0.281250 0.429688
|
||||
v -0.406250 -0.281250 0.429688
|
||||
v 0.406250 0.281250 0.429688
|
||||
v -0.406250 0.281250 0.429688
|
||||
v 0.406250 -0.281250 0.425781
|
||||
v -0.406250 -0.281250 0.425781
|
||||
v 0.406250 0.281250 0.425781
|
||||
v -0.406250 0.281250 0.425781
|
||||
vt 0.000000 0.000000
|
||||
vt 1.000000 0.000000
|
||||
vt 1.000000 1.000000
|
||||
|
@ -1,10 +1,10 @@
|
||||
# Blender v2.79 (sub 0) OBJ File: 'basic_signs wooden sign.blend'
|
||||
# www.blender.org
|
||||
o text_entity.001_Plane
|
||||
v 0.406250 -0.281250 0.742188
|
||||
v -0.406250 -0.281250 0.742188
|
||||
v 0.406250 0.281250 0.742188
|
||||
v -0.406250 0.281250 0.742188
|
||||
v 0.406250 -0.281250 0.738281
|
||||
v -0.406250 -0.281250 0.738281
|
||||
v 0.406250 0.281250 0.738281
|
||||
v -0.406250 0.281250 0.738281
|
||||
vt 0.000000 0.000000
|
||||
vt 1.000000 0.000000
|
||||
vt 1.000000 1.000000
|
||||
|
BIN
signs_lib/models/street_signs OM3.blend
Normal file
BIN
signs_lib/models/street_signs OM3.blend
Normal file
Binary file not shown.
@ -1,105 +1,30 @@
|
||||
-- Definitions for standard minetest_game wooden and steel wall signs
|
||||
|
||||
for _, onpole in ipairs({"", "_onpole"}) do
|
||||
signs_lib.register_sign("default:sign_wall_wood", {
|
||||
description = "Wooden wall sign",
|
||||
inventory_image = "signs_lib_sign_wall_wooden_inv.png",
|
||||
tiles = {
|
||||
"signs_lib_sign_wall_wooden.png",
|
||||
"signs_lib_sign_wall_wooden_edges.png",
|
||||
},
|
||||
entity_info = "standard"
|
||||
})
|
||||
|
||||
local nci = nil
|
||||
local on_rotate = signs_lib.wallmounted_rotate
|
||||
local pole_mount_tex = nil
|
||||
signs_lib.register_sign("default:sign_wall_steel", {
|
||||
description = "Steel wall sign",
|
||||
inventory_image = "signs_lib_sign_wall_steel_inv.png",
|
||||
tiles = {
|
||||
"signs_lib_sign_wall_steel.png",
|
||||
"signs_lib_sign_wall_steel_edges.png",
|
||||
},
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
locked = true,
|
||||
entity_info = "standard"
|
||||
})
|
||||
|
||||
if onpole == "_onpole" then
|
||||
nci = 1
|
||||
on_rotate = nil
|
||||
pole_mount_tex = "signs_lib_pole_mount.png" -- the metal straps on back, if needed
|
||||
end
|
||||
-- insert the old wood sign-on-fencepost into signs_lib's conversion LBM
|
||||
|
||||
local wood_groups = table.copy(signs_lib.standard_wood_groups)
|
||||
wood_groups.not_in_creative_inventory = nci
|
||||
local steel_groups = table.copy(signs_lib.standard_steel_groups)
|
||||
steel_groups.not_in_creative_inventory = nci
|
||||
|
||||
cbox = signs_lib.make_selection_boxes(35, 25, onpole)
|
||||
|
||||
minetest.register_node(":default:sign_wall_wood"..onpole, {
|
||||
description = "Wooden wall sign",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "signs_lib_standard_wall_sign"..onpole..".obj",
|
||||
tiles = {
|
||||
"signs_lib_sign_wall_wooden.png",
|
||||
"signs_lib_sign_wall_wooden_edges.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "signs_lib_sign_wall_wooden_inv.png",
|
||||
wield_image = "signs_lib_sign_wall_wooden_inv.png",
|
||||
groups = wood_groups,
|
||||
default_color = "0",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
number_of_lines = signs_lib.standard_lines,
|
||||
horiz_scaling = signs_lib.standard_hscale,
|
||||
vert_scaling = signs_lib.standard_vscale,
|
||||
line_spacing = signs_lib.standard_lspace,
|
||||
font_size = signs_lib.standard_fsize,
|
||||
x_offset = signs_lib.standard_xoffs,
|
||||
y_offset = signs_lib.standard_yoffs,
|
||||
chars_per_line = signs_lib.standard_cpl,
|
||||
entity_info = {
|
||||
mesh = "signs_lib_standard_wall_sign_entity"..onpole..".obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "default:sign_wall_wood"
|
||||
})
|
||||
table.insert(signs_lib.lbm_restore_nodes, "default:sign_wall_wood"..onpole)
|
||||
|
||||
minetest.register_node(":default:sign_wall_steel"..onpole, {
|
||||
description = "Steel wall sign",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "signs_lib_standard_wall_sign"..onpole..".obj",
|
||||
tiles = {
|
||||
"signs_lib_sign_wall_steel.png",
|
||||
"signs_lib_sign_wall_steel_edges.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "signs_lib_sign_wall_steel_inv.png",
|
||||
wield_image = "signs_lib_sign_wall_steel_inv.png",
|
||||
groups = wood_groups,
|
||||
default_color = "0",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
after_place_node = function(pos, placer, itemstack, pointed_thing)
|
||||
signs_lib.after_place_node(pos, placer, itemstack, pointed_thing, true)
|
||||
end,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
can_dig = signs_lib.can_modify,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
number_of_lines = signs_lib.standard_lines,
|
||||
horiz_scaling = signs_lib.standard_hscale,
|
||||
vert_scaling = signs_lib.standard_vscale,
|
||||
line_spacing = signs_lib.standard_lspace,
|
||||
font_size = signs_lib.standard_fsize,
|
||||
x_offset = signs_lib.standard_xoffs,
|
||||
y_offset = signs_lib.standard_yoffs,
|
||||
chars_per_line = signs_lib.standard_cpl,
|
||||
entity_info = {
|
||||
mesh = "signs_lib_standard_wall_sign_entity"..onpole..".obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "default:sign_wall_steel"
|
||||
})
|
||||
table.insert(signs_lib.lbm_restore_nodes, "default:sign_wall_steel"..onpole)
|
||||
end
|
||||
table.insert(signs_lib.old_fenceposts_with_signs, "signs:sign_post")
|
||||
signs_lib.old_fenceposts["signs:sign_post"] = "default:fence_wood"
|
||||
signs_lib.old_fenceposts_replacement_signs["signs:sign_post"] = "default:sign_wall_wood_onpole"
|
||||
|
480
street_signs/models/street_signs_object_marker_type_3_onpole.obj
Normal file
480
street_signs/models/street_signs_object_marker_type_3_onpole.obj
Normal file
@ -0,0 +1,480 @@
|
||||
# Blender v2.79 (sub 0) OBJ File: 'street signs OM3.blend'
|
||||
# www.blender.org
|
||||
o Cube_Cube_front-back
|
||||
v -0.152400 -0.793750 0.407200
|
||||
v -0.149953 -0.793750 0.422651
|
||||
v -0.142851 -0.793750 0.436589
|
||||
v -0.131789 -0.793750 0.447651
|
||||
v -0.117851 -0.793750 0.454753
|
||||
v -0.102400 -0.793750 0.457200
|
||||
v 0.102400 -0.793750 0.457200
|
||||
v 0.117851 -0.793750 0.454753
|
||||
v 0.131789 -0.793750 0.447651
|
||||
v 0.142851 -0.793750 0.436589
|
||||
v 0.149953 -0.793750 0.422651
|
||||
v 0.152400 -0.793750 0.407200
|
||||
v 0.152400 -0.793750 -0.407200
|
||||
v 0.149953 -0.793750 -0.422651
|
||||
v 0.142851 -0.793750 -0.436589
|
||||
v 0.131789 -0.793750 -0.447651
|
||||
v 0.117851 -0.793750 -0.454753
|
||||
v 0.102400 -0.793750 -0.457200
|
||||
v -0.102400 -0.793750 -0.457200
|
||||
v -0.117851 -0.793750 -0.454753
|
||||
v -0.131789 -0.793750 -0.447651
|
||||
v -0.142851 -0.793750 -0.436589
|
||||
v -0.149953 -0.793750 -0.422651
|
||||
v -0.152400 -0.793750 -0.407200
|
||||
v 0.152400 -0.843750 0.407200
|
||||
v 0.149953 -0.843750 0.422651
|
||||
v 0.142851 -0.843750 0.436589
|
||||
v 0.131789 -0.843750 0.447651
|
||||
v 0.117851 -0.843750 0.454753
|
||||
v 0.102400 -0.843750 0.457200
|
||||
v -0.102400 -0.843750 0.457200
|
||||
v -0.117851 -0.843750 0.454753
|
||||
v -0.131789 -0.843750 0.447651
|
||||
v -0.142851 -0.843750 0.436589
|
||||
v -0.149953 -0.843750 0.422651
|
||||
v -0.152400 -0.843750 0.407200
|
||||
v -0.152400 -0.843750 -0.407200
|
||||
v -0.149953 -0.843750 -0.422651
|
||||
v -0.142851 -0.843750 -0.436589
|
||||
v -0.131789 -0.843750 -0.447651
|
||||
v -0.117851 -0.843750 -0.454753
|
||||
v -0.102400 -0.843750 -0.457200
|
||||
v 0.102400 -0.843750 -0.457200
|
||||
v 0.117851 -0.843750 -0.454753
|
||||
v 0.131789 -0.843750 -0.447651
|
||||
v 0.142851 -0.843750 -0.436589
|
||||
v 0.149953 -0.843750 -0.422651
|
||||
v 0.152400 -0.843750 -0.407200
|
||||
v 0.102400 -0.843750 0.457200
|
||||
v 0.102400 -0.793750 0.457200
|
||||
v -0.102400 -0.793750 0.457200
|
||||
v -0.102400 -0.843750 0.457200
|
||||
v -0.152400 -0.843750 -0.407200
|
||||
v -0.152400 -0.843750 0.407200
|
||||
v -0.152400 -0.793750 0.407200
|
||||
v -0.152400 -0.793750 -0.407200
|
||||
v -0.102400 -0.843750 -0.457200
|
||||
v -0.102400 -0.793750 -0.457200
|
||||
v 0.102400 -0.793750 -0.457200
|
||||
v 0.102400 -0.843750 -0.457200
|
||||
v 0.117851 -0.793750 -0.454753
|
||||
v 0.117851 -0.843750 -0.454753
|
||||
v 0.131789 -0.793750 -0.447651
|
||||
v 0.131789 -0.843750 -0.447651
|
||||
v 0.142851 -0.793750 -0.436589
|
||||
v 0.142851 -0.843750 -0.436589
|
||||
v 0.149953 -0.793750 -0.422651
|
||||
v 0.149953 -0.843750 -0.422651
|
||||
v 0.152400 -0.793750 -0.407200
|
||||
v 0.152400 -0.843750 -0.407200
|
||||
v 0.117851 -0.843750 0.454753
|
||||
v 0.117851 -0.793750 0.454753
|
||||
v 0.131789 -0.843750 0.447651
|
||||
v 0.131789 -0.793750 0.447651
|
||||
v 0.142851 -0.843750 0.436589
|
||||
v 0.142851 -0.793750 0.436589
|
||||
v 0.149953 -0.843750 0.422651
|
||||
v 0.149953 -0.793750 0.422651
|
||||
v 0.152400 -0.843750 0.407200
|
||||
v 0.152400 -0.793750 0.407200
|
||||
v -0.117851 -0.793750 0.454753
|
||||
v -0.117851 -0.843750 0.454753
|
||||
v -0.131789 -0.793750 0.447651
|
||||
v -0.131789 -0.843750 0.447651
|
||||
v -0.142851 -0.793750 0.436589
|
||||
v -0.142851 -0.843750 0.436589
|
||||
v -0.149953 -0.793750 0.422651
|
||||
v -0.149953 -0.843750 0.422651
|
||||
v -0.117851 -0.843750 -0.454753
|
||||
v -0.117851 -0.793750 -0.454753
|
||||
v -0.131789 -0.843750 -0.447651
|
||||
v -0.131789 -0.793750 -0.447651
|
||||
v -0.142851 -0.843750 -0.436589
|
||||
v -0.142851 -0.793750 -0.436589
|
||||
v -0.149953 -0.843750 -0.422651
|
||||
v -0.149953 -0.793750 -0.422651
|
||||
v 0.119048 -0.843750 0.156250
|
||||
v 0.119048 -0.875000 0.156250
|
||||
v 0.119048 -0.843750 0.125000
|
||||
v 0.119048 -0.875000 0.125000
|
||||
v -0.119048 -0.843750 0.125000
|
||||
v -0.119048 -0.843750 0.156250
|
||||
v -0.119048 -0.875000 0.156250
|
||||
v -0.119048 -0.875000 0.125000
|
||||
v 0.119048 -1.117188 0.156250
|
||||
v 0.119048 -0.843750 0.156250
|
||||
v 0.119048 -1.117188 0.125000
|
||||
v 0.119048 -0.843750 0.125000
|
||||
v 0.156250 -1.117188 0.156250
|
||||
v 0.156250 -0.843750 0.156250
|
||||
v 0.156250 -1.117188 0.125000
|
||||
v 0.156250 -0.843750 0.125000
|
||||
v -0.156250 -1.117188 0.156250
|
||||
v -0.156250 -0.843750 0.156250
|
||||
v -0.156250 -1.117188 0.125000
|
||||
v -0.156250 -0.843750 0.125000
|
||||
v -0.119047 -1.117188 0.156250
|
||||
v -0.119047 -0.843750 0.156250
|
||||
v -0.119047 -1.117188 0.125000
|
||||
v -0.119047 -0.843750 0.125000
|
||||
v 0.156250 -1.156250 0.156250
|
||||
v -0.156250 -1.156250 0.156250
|
||||
v 0.156250 -1.156250 0.125000
|
||||
v -0.156250 -1.156250 0.125000
|
||||
v 0.156250 -1.117188 0.156250
|
||||
v -0.156250 -1.117188 0.156250
|
||||
v 0.156250 -1.117188 0.125000
|
||||
v -0.156250 -1.117188 0.125000
|
||||
v -0.156250 -0.843750 0.125000
|
||||
v 0.156250 -0.843750 0.125000
|
||||
v -0.156250 -0.843750 0.156250
|
||||
v 0.156250 -0.843750 0.156250
|
||||
v 0.119048 -0.843750 -0.125000
|
||||
v 0.119048 -0.875000 -0.125000
|
||||
v 0.119048 -0.843750 -0.156250
|
||||
v 0.119048 -0.875000 -0.156250
|
||||
v -0.119048 -0.843750 -0.156250
|
||||
v -0.119048 -0.843750 -0.125000
|
||||
v -0.119048 -0.875000 -0.125000
|
||||
v -0.119048 -0.875000 -0.156250
|
||||
v 0.119048 -1.117188 -0.125000
|
||||
v 0.119048 -0.843750 -0.125000
|
||||
v 0.119048 -1.117188 -0.156250
|
||||
v 0.119048 -0.843750 -0.156250
|
||||
v 0.156250 -1.117188 -0.125000
|
||||
v 0.156250 -0.843750 -0.125000
|
||||
v 0.156250 -1.117188 -0.156250
|
||||
v 0.156250 -0.843750 -0.156250
|
||||
v -0.156250 -1.117188 -0.125000
|
||||
v -0.156250 -0.843750 -0.125000
|
||||
v -0.156250 -1.117188 -0.156250
|
||||
v -0.156250 -0.843750 -0.156250
|
||||
v -0.119048 -1.117188 -0.125000
|
||||
v -0.119048 -0.843750 -0.125000
|
||||
v -0.119048 -1.117188 -0.156250
|
||||
v -0.119048 -0.843750 -0.156250
|
||||
v 0.156250 -1.156250 -0.125000
|
||||
v -0.156250 -1.156250 -0.125000
|
||||
v 0.156250 -1.156250 -0.156250
|
||||
v -0.156250 -1.156250 -0.156250
|
||||
v 0.156250 -1.117188 -0.125000
|
||||
v -0.156250 -1.117188 -0.125000
|
||||
v 0.156250 -1.117188 -0.156250
|
||||
v -0.156250 -1.117188 -0.156250
|
||||
v -0.156250 -0.843750 -0.156250
|
||||
v 0.156250 -0.843750 -0.156250
|
||||
v -0.156250 -0.843750 -0.125000
|
||||
v 0.156250 -0.843750 -0.125000
|
||||
vt 0.500000 0.945319
|
||||
vt 0.495986 0.962217
|
||||
vt 0.484335 0.977460
|
||||
vt 0.466190 0.989557
|
||||
vt 0.443325 0.997324
|
||||
vt 0.417979 1.000000
|
||||
vt 0.082021 1.000000
|
||||
vt 0.056675 0.997324
|
||||
vt 0.033810 0.989557
|
||||
vt 0.015665 0.977460
|
||||
vt 0.004014 0.962217
|
||||
vt 0.000000 0.945319
|
||||
vt 0.000000 0.054681
|
||||
vt 0.004014 0.037783
|
||||
vt 0.015665 0.022540
|
||||
vt 0.033810 0.010443
|
||||
vt 0.056675 0.002676
|
||||
vt 0.082021 0.000000
|
||||
vt 0.417979 0.000000
|
||||
vt 0.443325 0.002676
|
||||
vt 0.466190 0.010443
|
||||
vt 0.484335 0.022540
|
||||
vt 0.495986 0.037783
|
||||
vt 0.500000 0.054681
|
||||
vt 0.500000 0.945319
|
||||
vt 0.504014 0.962217
|
||||
vt 0.515665 0.977460
|
||||
vt 0.533810 0.989557
|
||||
vt 0.556675 0.997324
|
||||
vt 0.582021 1.000000
|
||||
vt 0.917979 1.000000
|
||||
vt 0.943325 0.997324
|
||||
vt 0.966190 0.989557
|
||||
vt 0.984335 0.977460
|
||||
vt 0.995986 0.962217
|
||||
vt 1.000000 0.945319
|
||||
vt 1.000000 0.054681
|
||||
vt 0.995986 0.037783
|
||||
vt 0.984335 0.022540
|
||||
vt 0.966190 0.010443
|
||||
vt 0.943325 0.002676
|
||||
vt 0.917979 0.000000
|
||||
vt 0.582021 0.000000
|
||||
vt 0.556675 0.002676
|
||||
vt 0.533810 0.010443
|
||||
vt 0.515665 0.022540
|
||||
vt 0.504014 0.037783
|
||||
vt 0.500000 0.054681
|
||||
vt 0.164042 0.000000
|
||||
vt 0.164042 0.999996
|
||||
vt 0.835958 0.999996
|
||||
vt 0.835958 0.000000
|
||||
vt 0.054681 0.000000
|
||||
vt 0.945319 0.000000
|
||||
vt 0.945319 1.000000
|
||||
vt 0.054681 1.000000
|
||||
vt 0.835958 0.000003
|
||||
vt 0.835958 1.000000
|
||||
vt 0.164042 1.000000
|
||||
vt 0.164042 0.000003
|
||||
vt 0.113350 1.000000
|
||||
vt 0.113350 0.000003
|
||||
vt 0.067621 1.000000
|
||||
vt 0.067621 0.000003
|
||||
vt 0.022540 1.000000
|
||||
vt 0.022540 0.000000
|
||||
vt 0.037783 1.000000
|
||||
vt 0.037783 0.000000
|
||||
vt 0.054681 1.000000
|
||||
vt 0.054681 0.000000
|
||||
vt 0.113350 0.000000
|
||||
vt 0.113350 0.999996
|
||||
vt 0.067621 0.000000
|
||||
vt 0.067621 0.999996
|
||||
vt 0.000000 0.000000
|
||||
vt 0.000000 0.999996
|
||||
vt 0.977460 1.000000
|
||||
vt 0.977460 0.000000
|
||||
vt 0.962217 0.000000
|
||||
vt 0.962217 1.000000
|
||||
vt 0.945319 0.000000
|
||||
vt 0.945319 1.000000
|
||||
vt 0.886650 0.999996
|
||||
vt 0.886650 0.000000
|
||||
vt 0.932379 0.999996
|
||||
vt 0.932379 0.000000
|
||||
vt 0.977460 1.000000
|
||||
vt 0.977460 0.000000
|
||||
vt 0.962217 1.000000
|
||||
vt 0.962217 0.000000
|
||||
vt 0.886650 0.000003
|
||||
vt 0.886650 1.000000
|
||||
vt 0.932379 0.000003
|
||||
vt 0.932379 1.000000
|
||||
vt 1.000000 0.000003
|
||||
vt 1.000000 1.000000
|
||||
vt 0.022540 1.000000
|
||||
vt 0.022540 0.000000
|
||||
vt 0.037783 0.000000
|
||||
vt 0.037783 1.000000
|
||||
vt 0.781250 0.664062
|
||||
vt 0.781250 0.992188
|
||||
vt 0.921875 0.992188
|
||||
vt 0.921875 0.664062
|
||||
vt 0.703125 0.093750
|
||||
vt 0.156250 0.093750
|
||||
vt 0.156250 0.031250
|
||||
vt 0.703125 0.031250
|
||||
vt 0.703125 0.578125
|
||||
vt 0.156250 0.578125
|
||||
vt 0.156250 0.507812
|
||||
vt 0.703125 0.507812
|
||||
vt 0.312500 0.640625
|
||||
vt 0.312500 0.992188
|
||||
vt 0.453125 0.992188
|
||||
vt 0.453125 0.640625
|
||||
vt 0.234375 0.640625
|
||||
vt 0.234375 0.992188
|
||||
vt 0.312500 0.992188
|
||||
vt 0.312500 0.640625
|
||||
vt 0.234375 0.640625
|
||||
vt 0.234375 0.992188
|
||||
vt 0.093750 0.992188
|
||||
vt 0.093750 0.640625
|
||||
vt 0.015625 0.992188
|
||||
vt 0.015625 0.640625
|
||||
vt 0.312500 0.640625
|
||||
vt 0.312500 0.992188
|
||||
vt 0.453125 0.992188
|
||||
vt 0.453125 0.640625
|
||||
vt 0.234375 0.640625
|
||||
vt 0.234375 0.992188
|
||||
vt 0.312500 0.992188
|
||||
vt 0.312500 0.640625
|
||||
vt 0.234375 0.640625
|
||||
vt 0.234375 0.992188
|
||||
vt 0.093750 0.992188
|
||||
vt 0.093750 0.640625
|
||||
vt 0.015625 0.992188
|
||||
vt 0.015625 0.640625
|
||||
vt 0.781250 0.664062
|
||||
vt 0.781250 0.992188
|
||||
vt 0.921875 0.992188
|
||||
vt 0.921875 0.664062
|
||||
vt 0.484375 0.664062
|
||||
vt 0.484375 0.992188
|
||||
vt 0.562500 0.992188
|
||||
vt 0.562500 0.664062
|
||||
vt 0.703125 0.992188
|
||||
vt 0.703125 0.664062
|
||||
vt 0.234375 0.593750
|
||||
vt 0.234375 0.640625
|
||||
vt 0.093750 0.640625
|
||||
vt 0.093750 0.593750
|
||||
vt 0.453125 0.640625
|
||||
vt 0.453125 0.593750
|
||||
vt 0.312500 0.593750
|
||||
vt 0.312500 0.640625
|
||||
vt 0.781250 0.664062
|
||||
vt 0.781250 0.992188
|
||||
vt 0.921875 0.992188
|
||||
vt 0.921875 0.664062
|
||||
vt 0.703125 0.093750
|
||||
vt 0.156250 0.093750
|
||||
vt 0.156250 0.031250
|
||||
vt 0.703125 0.031250
|
||||
vt 0.703125 0.578125
|
||||
vt 0.156250 0.578125
|
||||
vt 0.156250 0.507812
|
||||
vt 0.703125 0.507812
|
||||
vt 0.312500 0.640625
|
||||
vt 0.312500 0.992188
|
||||
vt 0.453125 0.992188
|
||||
vt 0.453125 0.640625
|
||||
vt 0.234375 0.640625
|
||||
vt 0.234375 0.992188
|
||||
vt 0.312500 0.992188
|
||||
vt 0.312500 0.640625
|
||||
vt 0.234375 0.640625
|
||||
vt 0.234375 0.992188
|
||||
vt 0.093750 0.992188
|
||||
vt 0.093750 0.640625
|
||||
vt 0.015625 0.992188
|
||||
vt 0.015625 0.640625
|
||||
vt 0.312500 0.640625
|
||||
vt 0.312500 0.992188
|
||||
vt 0.453125 0.992188
|
||||
vt 0.453125 0.640625
|
||||
vt 0.234375 0.640625
|
||||
vt 0.234375 0.992188
|
||||
vt 0.312500 0.992188
|
||||
vt 0.312500 0.640625
|
||||
vt 0.234375 0.640625
|
||||
vt 0.234375 0.992188
|
||||
vt 0.093750 0.992188
|
||||
vt 0.093750 0.640625
|
||||
vt 0.015625 0.992188
|
||||
vt 0.015625 0.640625
|
||||
vt 0.781250 0.664062
|
||||
vt 0.781250 0.992188
|
||||
vt 0.921875 0.992188
|
||||
vt 0.921875 0.664062
|
||||
vt 0.484375 0.664062
|
||||
vt 0.484375 0.992188
|
||||
vt 0.562500 0.992188
|
||||
vt 0.562500 0.664062
|
||||
vt 0.703125 0.992188
|
||||
vt 0.703125 0.664062
|
||||
vt 0.234375 0.593750
|
||||
vt 0.234375 0.640625
|
||||
vt 0.093750 0.640625
|
||||
vt 0.093750 0.593750
|
||||
vt 0.453125 0.640625
|
||||
vt 0.453125 0.593750
|
||||
vt 0.312500 0.593750
|
||||
vt 0.312500 0.640625
|
||||
vn 0.0000 1.0000 0.0000
|
||||
vn 0.0000 -1.0000 -0.0000
|
||||
vn 0.0000 0.0000 1.0000
|
||||
vn -1.0000 0.0000 0.0000
|
||||
vn -0.0000 0.0000 -1.0000
|
||||
vn 0.1564 0.0000 -0.9877
|
||||
vn 0.4540 0.0000 -0.8910
|
||||
vn 0.7071 0.0000 -0.7071
|
||||
vn 0.8910 0.0000 -0.4540
|
||||
vn 0.9877 0.0000 -0.1564
|
||||
vn 0.1564 0.0000 0.9877
|
||||
vn 0.4540 0.0000 0.8910
|
||||
vn 0.7071 0.0000 0.7071
|
||||
vn 0.8910 0.0000 0.4540
|
||||
vn 0.9877 0.0000 0.1564
|
||||
vn -0.1564 0.0000 0.9877
|
||||
vn -0.4540 0.0000 0.8910
|
||||
vn -0.7071 0.0000 0.7071
|
||||
vn -0.8910 0.0000 0.4540
|
||||
vn -0.9877 0.0000 0.1564
|
||||
vn -0.1564 0.0000 -0.9877
|
||||
vn -0.4540 0.0000 -0.8910
|
||||
vn -0.7071 0.0000 -0.7071
|
||||
vn -0.8910 0.0000 -0.4540
|
||||
vn -0.9877 0.0000 -0.1564
|
||||
vn 1.0000 0.0000 -0.0000
|
||||
g Cube_Cube_front-back_Cube_Cube_front-back_front-back
|
||||
s 1
|
||||
f 1/1/1 2/2/1 3/3/1 4/4/1 5/5/1 6/6/1 7/7/1 8/8/1 9/9/1 10/10/1 11/11/1 12/12/1 13/13/1 14/14/1 15/15/1 16/16/1 17/17/1 18/18/1 19/19/1 20/20/1 21/21/1 22/22/1 23/23/1 24/24/1
|
||||
f 25/25/2 26/26/2 27/27/2 28/28/2 29/29/2 30/30/2 31/31/2 32/32/2 33/33/2 34/34/2 35/35/2 36/36/2 37/37/2 38/38/2 39/39/2 40/40/2 41/41/2 42/42/2 43/43/2 44/44/2 45/45/2 46/46/2 47/47/2 48/48/2
|
||||
g Cube_Cube_front-back_Cube_Cube_front-back_edges
|
||||
f 49/49/3 50/50/3 51/51/3 52/52/3
|
||||
f 53/53/4 54/54/4 55/55/4 56/56/4
|
||||
f 57/57/5 58/58/5 59/59/5 60/60/5
|
||||
f 60/60/6 59/59/6 61/61/6 62/62/6
|
||||
f 62/62/7 61/61/7 63/63/7 64/64/7
|
||||
f 64/64/8 63/63/8 65/65/8 66/66/8
|
||||
f 66/66/9 65/65/9 67/67/9 68/68/9
|
||||
f 68/68/10 67/67/10 69/69/10 70/70/10
|
||||
f 50/50/11 49/49/11 71/71/11 72/72/11
|
||||
f 72/72/12 71/71/12 73/73/12 74/74/12
|
||||
f 74/74/13 73/73/13 75/75/13 76/76/13
|
||||
f 76/77/14 75/78/14 77/79/14 78/80/14
|
||||
f 78/80/15 77/79/15 79/81/15 80/82/15
|
||||
f 52/52/16 51/51/16 81/83/16 82/84/16
|
||||
f 82/84/17 81/83/17 83/85/17 84/86/17
|
||||
f 84/86/18 83/85/18 85/87/18 86/88/18
|
||||
f 86/88/19 85/87/19 87/89/19 88/90/19
|
||||
f 88/90/20 87/89/20 55/55/20 54/54/20
|
||||
f 58/58/21 57/57/21 89/91/21 90/92/21
|
||||
f 90/92/22 89/91/22 91/93/22 92/94/22
|
||||
f 92/94/23 91/93/23 93/95/23 94/96/23
|
||||
f 94/97/24 93/98/24 95/99/24 96/100/24
|
||||
f 96/100/25 95/99/25 53/53/25 56/56/25
|
||||
f 79/81/26 70/70/26 69/69/26 80/82/26
|
||||
g Cube_Cube_front-back_Cube_Cube_front-back_pole_mount
|
||||
s off
|
||||
f 132/101/2 131/102/2 129/103/2 130/104/2
|
||||
f 100/105/5 104/106/5 101/107/5 99/108/5
|
||||
f 97/109/3 102/110/3 103/111/3 98/112/3
|
||||
f 98/112/2 103/111/2 104/106/2 100/105/2
|
||||
f 105/113/4 106/114/4 108/115/4 107/116/4
|
||||
f 107/117/5 108/118/5 112/119/5 111/120/5
|
||||
f 111/121/26 112/122/26 110/123/26 109/124/26
|
||||
f 109/124/3 110/123/3 106/125/3 105/126/3
|
||||
f 113/127/4 114/128/4 116/129/4 115/130/4
|
||||
f 115/131/5 116/132/5 120/133/5 119/134/5
|
||||
f 119/135/26 120/136/26 118/137/26 117/138/26
|
||||
f 117/138/3 118/137/3 114/139/3 113/140/3
|
||||
f 121/141/2 122/142/2 124/143/2 123/144/2
|
||||
f 123/145/5 124/146/5 128/147/5 127/148/5
|
||||
f 127/148/1 128/147/1 126/149/1 125/150/1
|
||||
f 125/150/3 126/149/3 122/142/3 121/141/3
|
||||
f 123/151/26 127/152/26 125/153/26 121/154/26
|
||||
f 128/155/4 124/156/4 122/157/4 126/158/4
|
||||
f 168/159/2 167/160/2 165/161/2 166/162/2
|
||||
f 136/163/5 140/164/5 137/165/5 135/166/5
|
||||
f 133/167/3 138/168/3 139/169/3 134/170/3
|
||||
f 134/170/2 139/169/2 140/164/2 136/163/2
|
||||
f 141/171/4 142/172/4 144/173/4 143/174/4
|
||||
f 143/175/5 144/176/5 148/177/5 147/178/5
|
||||
f 147/179/26 148/180/26 146/181/26 145/182/26
|
||||
f 145/182/3 146/181/3 142/183/3 141/184/3
|
||||
f 149/185/4 150/186/4 152/187/4 151/188/4
|
||||
f 151/189/5 152/190/5 156/191/5 155/192/5
|
||||
f 155/193/26 156/194/26 154/195/26 153/196/26
|
||||
f 153/196/3 154/195/3 150/197/3 149/198/3
|
||||
f 157/199/2 158/200/2 160/201/2 159/202/2
|
||||
f 159/203/5 160/204/5 164/205/5 163/206/5
|
||||
f 163/206/1 164/205/1 162/207/1 161/208/1
|
||||
f 161/208/3 162/207/3 158/200/3 157/199/3
|
||||
f 159/209/26 163/210/26 161/211/26 157/212/26
|
||||
f 164/213/4 160/214/4 158/215/4 162/216/4
|
@ -1,7 +1,6 @@
|
||||
-- Class D signs
|
||||
|
||||
local S = signs_lib.gettext
|
||||
local cbox
|
||||
local groups = table.copy(signs_lib.standard_steel_groups)
|
||||
|
||||
local cbox = {
|
||||
type = "fixed",
|
||||
@ -14,24 +13,15 @@ local cbox = {
|
||||
}
|
||||
}
|
||||
|
||||
minetest.register_node("street_signs:sign_basic", {
|
||||
signs_lib.register_sign("street_signs:sign_basic", {
|
||||
description = "D3-1a: Generic intersection street name sign",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "facedir",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_basic.obj",
|
||||
tiles = { "street_signs_basic.png" },
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2},
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
default_color = "f",
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.facedir_rotate,
|
||||
number_of_lines = 2,
|
||||
horiz_scaling = 0.8,
|
||||
vert_scaling = 1,
|
||||
@ -43,7 +33,8 @@ minetest.register_node("street_signs:sign_basic", {
|
||||
entity_info = {
|
||||
mesh = "street_signs_basic_entity.obj",
|
||||
yaw = signs_lib.standard_yaw
|
||||
}
|
||||
},
|
||||
allow_onpole = false
|
||||
})
|
||||
|
||||
cbox = {
|
||||
@ -54,28 +45,18 @@ cbox = {
|
||||
{ -1/32, 1/16, -1/32, 1/32, 2/16, 1/32 },
|
||||
{ -8/16, -4/16, -1/32, 8/16, 1/16, 1/32 },
|
||||
{ -1/16, -8/16, -1/16, 1/16, -4/16, 1/16 },
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
minetest.register_node("street_signs:sign_basic_top_only", {
|
||||
signs_lib.register_sign("street_signs:sign_basic_top_only", {
|
||||
description = "D3-1a: Generic intersection street name sign (top only)",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "facedir",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_basic_top_only.obj",
|
||||
tiles = { "street_signs_basic.png" },
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2},
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
default_color = "f",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.facedir_rotate,
|
||||
number_of_lines = 2,
|
||||
horiz_scaling = 0.8,
|
||||
vert_scaling = 1,
|
||||
@ -87,156 +68,80 @@ minetest.register_node("street_signs:sign_basic_top_only", {
|
||||
entity_info = {
|
||||
mesh = "street_signs_basic_top_only_entity.obj",
|
||||
yaw = signs_lib.standard_yaw
|
||||
}
|
||||
},
|
||||
allow_onpole = false
|
||||
})
|
||||
|
||||
table.insert(signs_lib.lbm_restore_nodes, "street_signs:sign_basic")
|
||||
table.insert(signs_lib.lbm_restore_nodes, "street_signs:sign_basic_top_only")
|
||||
cbox = signs_lib.make_selection_boxes(24, 24)
|
||||
|
||||
for _, onpole in ipairs({"", "_onpole"}) do
|
||||
signs_lib.register_sign("street_signs:sign_service_hospital", {
|
||||
description = "D9-2: General service: hospital",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24.obj",
|
||||
tiles = { "street_signs_service_hospital.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_service_hospital_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
})
|
||||
|
||||
local nci = nil
|
||||
local on_rotate = signs_lib.wallmounted_rotate
|
||||
local pole_mount_tex = nil
|
||||
signs_lib.register_sign("street_signs:sign_service_handicapped", {
|
||||
description = "D9-6: General service: handicapped",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24.obj",
|
||||
tiles = { "street_signs_service_handicapped.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_service_handicapped_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
})
|
||||
|
||||
if onpole == "_onpole" then
|
||||
nci = 1
|
||||
on_rotate = nil
|
||||
pole_mount_tex = "signs_lib_pole_mount.png"
|
||||
end
|
||||
signs_lib.register_sign("street_signs:sign_service_fuel", {
|
||||
description = "D9-7: General service: fuel/gas",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24.obj",
|
||||
tiles = { "street_signs_service_fuel.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_service_fuel_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
})
|
||||
|
||||
cbox = signs_lib.make_selection_boxes(24, 24, onpole)
|
||||
signs_lib.register_sign("street_signs:sign_service_food", {
|
||||
description = "D9-8: General service: food",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24.obj",
|
||||
tiles = { "street_signs_service_food.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_service_food_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_service_hospital"..onpole, {
|
||||
description = "D9-2: General service: hospital",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24"..onpole..".obj",
|
||||
tiles = { "street_signs_service_hospital.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_service_hospital_inv.png",
|
||||
wield_image = "street_signs_service_hospital_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
drop = "street_signs:sign_service_hospital"
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_service_handicapped"..onpole, {
|
||||
description = "D9-6: General service: handicapped",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24"..onpole..".obj",
|
||||
tiles = { "street_signs_service_handicapped.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_service_handicapped_inv.png",
|
||||
wield_image = "street_signs_service_handicapped_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
drop = "street_signs:sign_service_handicapped"
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_service_fuel"..onpole, {
|
||||
description = "D9-7: General service: fuel/gas",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24"..onpole..".obj",
|
||||
tiles = { "street_signs_service_fuel.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_service_fuel_inv.png",
|
||||
wield_image = "street_signs_service_fuel_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
drop = "street_signs:sign_service_fuel"
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_service_food"..onpole, {
|
||||
description = "D9-8: General service: food",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24"..onpole..".obj",
|
||||
tiles = { "street_signs_service_food.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_service_food_inv.png",
|
||||
wield_image = "street_signs_service_food_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
drop = "street_signs:sign_service_food"
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_service_lodging"..onpole, {
|
||||
description = "D9-9: General service: lodging",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24"..onpole..".obj",
|
||||
tiles = { "street_signs_service_lodging.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_service_lodging_inv.png",
|
||||
wield_image = "street_signs_service_lodging_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
drop = "street_signs:sign_service_lodging"
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_service_ev_charging"..onpole, {
|
||||
description = "D9-11b: General service: EV charging",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24"..onpole..".obj",
|
||||
tiles = { "street_signs_service_ev_charging.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_service_ev_charging_inv.png",
|
||||
wield_image = "street_signs_service_ev_charging_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
drop = "street_signs:sign_service_ev_charging"
|
||||
})
|
||||
end
|
||||
signs_lib.register_sign("street_signs:sign_service_lodging", {
|
||||
description = "D9-9: General service: lodging",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24.obj",
|
||||
tiles = { "street_signs_service_lodging.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_service_lodging_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
})
|
||||
|
||||
signs_lib.register_sign("street_signs:sign_service_ev_charging", {
|
||||
description = "D9-11b: General service: EV charging",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_24x24.obj",
|
||||
tiles = { "street_signs_service_ev_charging.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_service_ev_charging_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
})
|
||||
|
@ -1,146 +1,82 @@
|
||||
-- Class-M signs
|
||||
|
||||
local S = signs_lib.gettext
|
||||
local cbox
|
||||
local cbox = signs_lib.make_selection_boxes(36, 36)
|
||||
|
||||
for _, onpole in ipairs({"", "_onpole"}) do
|
||||
signs_lib.register_sign("street_signs:sign_us_route", {
|
||||
description = "M1-4: Generic \"US Route\" sign",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_36x36.obj",
|
||||
tiles = {
|
||||
"street_signs_us_route.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_us_route_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
number_of_lines = 1,
|
||||
horiz_scaling = 3.5,
|
||||
vert_scaling = 1.4,
|
||||
line_spacing = 6,
|
||||
font_size = 31,
|
||||
x_offset = 8,
|
||||
y_offset = 11,
|
||||
chars_per_line = 3,
|
||||
entity_info = {
|
||||
mesh = "street_signs_generic_sign_36x36_entity.obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
})
|
||||
|
||||
local nci = nil
|
||||
local on_rotate = signs_lib.wallmounted_rotate
|
||||
local pole_mount_tex = nil
|
||||
signs_lib.register_sign("street_signs:sign_us_interstate", {
|
||||
description = "M1-1: Generic US Interstate sign",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_interstate_shield.obj",
|
||||
tiles = {
|
||||
"street_signs_us_interstate.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_us_interstate_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
default_color = "f",
|
||||
number_of_lines = 1,
|
||||
horiz_scaling = 4.3,
|
||||
vert_scaling = 1.4,
|
||||
line_spacing = 6,
|
||||
font_size = 31,
|
||||
x_offset = 8,
|
||||
y_offset = 14,
|
||||
chars_per_line = 3,
|
||||
entity_info = {
|
||||
mesh = "street_signs_interstate_shield_entity.obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
})
|
||||
|
||||
if onpole == "_onpole" then
|
||||
nci = 1
|
||||
on_rotate = nil
|
||||
pole_mount_tex = "signs_lib_pole_mount.png"
|
||||
end
|
||||
cbox = signs_lib.make_selection_boxes(48, 18)
|
||||
|
||||
cbox = signs_lib.make_selection_boxes(36, 36, onpole)
|
||||
signs_lib.register_sign("street_signs:sign_detour_right_m4_10", {
|
||||
description = "M4-10: Detour sign (to right)",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_48x18.obj",
|
||||
tiles = {
|
||||
"street_signs_detour_right_m4_10.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_detour_right_m4_10_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_us_route"..onpole, {
|
||||
description = "M1-4: Generic \"US Route\" sign",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_36x36"..onpole..".obj",
|
||||
tiles = { "street_signs_us_route.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_us_route_inv.png",
|
||||
wield_image = "street_signs_us_route_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
number_of_lines = 1,
|
||||
horiz_scaling = 3.5,
|
||||
vert_scaling = 1.4,
|
||||
line_spacing = 6,
|
||||
font_size = 31,
|
||||
x_offset = 8,
|
||||
y_offset = 11,
|
||||
chars_per_line = 3,
|
||||
entity_info = {
|
||||
mesh = "street_signs_generic_sign_36x36_entity"..onpole..".obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "street_signs:sign_us_route"
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_us_interstate"..onpole, {
|
||||
description = "M1-1: Generic US Interstate sign",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_interstate_shield"..onpole..".obj",
|
||||
tiles = { "street_signs_us_interstate.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_us_interstate_inv.png",
|
||||
wield_image = "street_signs_us_interstate_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "f",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
number_of_lines = 1,
|
||||
horiz_scaling = 4.3,
|
||||
vert_scaling = 1.4,
|
||||
line_spacing = 6,
|
||||
font_size = 31,
|
||||
x_offset = 8,
|
||||
y_offset = 14,
|
||||
chars_per_line = 3,
|
||||
entity_info = {
|
||||
mesh = "street_signs_interstate_shield_entity"..onpole..".obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "street_signs:sign_us_interstate"
|
||||
})
|
||||
|
||||
cbox = signs_lib.make_selection_boxes(48, 18, onpole)
|
||||
|
||||
minetest.register_node("street_signs:sign_detour_right_m4_10"..onpole, {
|
||||
description = "M4-10: Detour sign (to right)",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_48x18"..onpole..".obj",
|
||||
tiles = { "street_signs_detour_right_m4_10.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_detour_right_m4_10_inv.png",
|
||||
wield_image = "street_signs_detour_right_m4_10_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
drop = "street_signs:sign_detour_right_m4_10"
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_detour_left_m4_10"..onpole, {
|
||||
description = "M4-10: Detour sign (to left)",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_48x18"..onpole..".obj",
|
||||
tiles = { "street_signs_detour_left_m4_10.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_detour_left_m4_10_inv.png",
|
||||
wield_image = "street_signs_detour_left_m4_10_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
drop = "street_signs:sign_detour_left_m4_10"
|
||||
})
|
||||
|
||||
table.insert(signs_lib.lbm_restore_nodes, "street_signs:sign_us_route"..onpole)
|
||||
table.insert(signs_lib.lbm_restore_nodes, "street_signs:sign_us_interstate"..onpole)
|
||||
end
|
||||
signs_lib.register_sign("street_signs:sign_detour_left_m4_10", {
|
||||
description = "M4-10: Detour sign (to left)",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_sign_48x18.obj",
|
||||
tiles = {
|
||||
"street_signs_detour_left_m4_10.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_detour_left_m4_10_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
})
|
||||
|
@ -1,25 +1,20 @@
|
||||
-- Class-OM signs
|
||||
|
||||
local S = signs_lib.gettext
|
||||
local cbox
|
||||
local cbox = signs_lib.make_selection_boxes(12, 36, nil)
|
||||
|
||||
for _, d in ipairs({"l", "c", "r"}) do
|
||||
|
||||
cbox = signs_lib.make_selection_boxes(12, 36, nil)
|
||||
|
||||
minetest.register_node("street_signs:sign_object_marker_type3_"..d, {
|
||||
signs_lib.register_sign("street_signs:sign_object_marker_type3_"..d, {
|
||||
description = "OM3-"..string.upper(d)..": Type 3 object marker",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_object_marker_type_3.obj",
|
||||
tiles = { "street_signs_object_marker_type3_"..d..".png",
|
||||
tiles = {
|
||||
"street_signs_object_marker_type3_"..d..".png",
|
||||
"street_signs_sign_edge.png"
|
||||
},
|
||||
inventory_image = "street_signs_object_marker_type3_"..d.."_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2},
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
uses_slim_pole_mount = true,
|
||||
})
|
||||
end
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1,182 +1,110 @@
|
||||
-- Misc./Generic signs
|
||||
|
||||
local S = signs_lib.gettext
|
||||
local cbox
|
||||
local cbox = signs_lib.make_selection_boxes(36, 36)
|
||||
|
||||
for _, onpole in ipairs({"", "_onpole"}) do
|
||||
signs_lib.register_sign("street_signs:sign_warning_3_line", {
|
||||
description = "W3-4: Generic US diamond \"warning\" sign (3-line, yellow)",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_warning_36x36.obj",
|
||||
tiles = {
|
||||
"street_signs_warning.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_warning_3_line_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
number_of_lines = 3,
|
||||
horiz_scaling = 1.75,
|
||||
vert_scaling = 1.75,
|
||||
line_spacing = 1,
|
||||
font_size = 15,
|
||||
x_offset = 6,
|
||||
y_offset = 19,
|
||||
chars_per_line = 15,
|
||||
entity_info = {
|
||||
mesh = "street_signs_warning_36x36_entity.obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "street_signs:sign_warning_3_line"
|
||||
})
|
||||
|
||||
local nci = nil
|
||||
local pole_mount_tex = nil
|
||||
signs_lib.register_sign("street_signs:sign_warning_4_line", {
|
||||
description = "W23-2: Generic US diamond \"warning\" sign (4-line, yellow)",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_warning_36x36.obj",
|
||||
tiles = {
|
||||
"street_signs_warning.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_warning_4_line_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
number_of_lines = 4,
|
||||
horiz_scaling = 1.75,
|
||||
vert_scaling = 1.75,
|
||||
line_spacing = 1,
|
||||
font_size = 15,
|
||||
x_offset = 6,
|
||||
y_offset = 25,
|
||||
chars_per_line = 15,
|
||||
entity_info = {
|
||||
mesh = "street_signs_warning_36x36_entity.obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "street_signs:sign_warning_4_line"
|
||||
})
|
||||
|
||||
if onpole == "_onpole" then
|
||||
nci = 1
|
||||
pole_mount_tex = "signs_lib_pole_mount.png"
|
||||
end
|
||||
|
||||
cbox = signs_lib.make_selection_boxes(36, 36, onpole)
|
||||
|
||||
minetest.register_node("street_signs:sign_warning_3_line"..onpole, {
|
||||
description = "W3-4: Generic US diamond \"warning\" sign (3-line, yellow)",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_warning_36x36"..onpole..".obj",
|
||||
tiles = { "street_signs_warning.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_warning_3_line_inv.png",
|
||||
wield_image = "street_signs_warning_3_line_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
number_of_lines = 3,
|
||||
horiz_scaling = 1.75,
|
||||
vert_scaling = 1.75,
|
||||
line_spacing = 1,
|
||||
font_size = 15,
|
||||
x_offset = 6,
|
||||
y_offset = 19,
|
||||
chars_per_line = 15,
|
||||
entity_info = {
|
||||
mesh = "street_signs_warning_36x36_entity"..onpole..".obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "street_signs:sign_warning_3_line"
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_warning_4_line"..onpole, {
|
||||
description = "W23-2: Generic US diamond \"warning\" sign (4-line, yellow)",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_warning_36x36"..onpole..".obj",
|
||||
tiles = { "street_signs_warning.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_warning_4_line_inv.png",
|
||||
wield_image = "street_signs_warning_4_line_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
number_of_lines = 4,
|
||||
horiz_scaling = 1.75,
|
||||
vert_scaling = 1.75,
|
||||
line_spacing = 1,
|
||||
font_size = 15,
|
||||
x_offset = 6,
|
||||
y_offset = 25,
|
||||
chars_per_line = 15,
|
||||
entity_info = {
|
||||
mesh = "street_signs_warning_36x36_entity"..onpole..".obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "street_signs:sign_warning_4_line"
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_warning_orange_3_line"..onpole, {
|
||||
description = "W3-4: Generic US diamond \"warning\" sign (3-line, orange)",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_warning_36x36"..onpole..".obj",
|
||||
tiles = { "street_signs_warning_orange.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_warning_orange_3_line_inv.png",
|
||||
wield_image = "street_signs_warning_orange_3_line_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
number_of_lines = 3,
|
||||
horiz_scaling = 1.75,
|
||||
vert_scaling = 1.75,
|
||||
line_spacing = 1,
|
||||
font_size = 15,
|
||||
x_offset = 6,
|
||||
y_offset = 19,
|
||||
chars_per_line = 15,
|
||||
entity_info = {
|
||||
mesh = "street_signs_warning_36x36_entity"..onpole..".obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "street_signs:sign_warning_orange_3_line"
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_warning_orange_4_line"..onpole, {
|
||||
description = "W23-2: Generic US diamond \"warning\" sign (4-line, orange)",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_warning_36x36"..onpole..".obj",
|
||||
tiles = { "street_signs_warning_orange.png",
|
||||
"street_signs_sign_edge.png",
|
||||
pole_mount_tex
|
||||
},
|
||||
inventory_image = "street_signs_warning_orange_4_line_inv.png",
|
||||
wield_image = "street_signs_warning_orange_4_line_inv.png",
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2, not_in_creative_inventory = nci},
|
||||
default_color = "0",
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
after_place_node = signs_lib.after_place_node,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
number_of_lines = 4,
|
||||
horiz_scaling = 1.75,
|
||||
vert_scaling = 1.75,
|
||||
line_spacing = 1,
|
||||
font_size = 15,
|
||||
x_offset = 6,
|
||||
y_offset = 25,
|
||||
chars_per_line = 15,
|
||||
entity_info = {
|
||||
mesh = "street_signs_warning_36x36_entity"..onpole..".obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "street_signs:sign_warning_orange_4_line"
|
||||
})
|
||||
|
||||
table.insert(signs_lib.lbm_restore_nodes, "street_signs:sign_warning_3_line"..onpole)
|
||||
table.insert(signs_lib.lbm_restore_nodes, "street_signs:sign_warning_4_line"..onpole)
|
||||
table.insert(signs_lib.lbm_restore_nodes, "street_signs:sign_warning_orange_3_line"..onpole)
|
||||
table.insert(signs_lib.lbm_restore_nodes, "street_signs:sign_warning_orange_4_line"..onpole)
|
||||
end
|
||||
signs_lib.register_sign("street_signs:sign_warning_orange_3_line", {
|
||||
description = "W3-4: Generic US diamond \"warning\" sign (3-line, orange)",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_warning_36x36.obj",
|
||||
tiles = {
|
||||
"street_signs_warning_orange.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_warning_orange_3_line_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
number_of_lines = 3,
|
||||
horiz_scaling = 1.75,
|
||||
vert_scaling = 1.75,
|
||||
line_spacing = 1,
|
||||
font_size = 15,
|
||||
x_offset = 6,
|
||||
y_offset = 19,
|
||||
chars_per_line = 15,
|
||||
entity_info = {
|
||||
mesh = "street_signs_warning_36x36_entity.obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "street_signs:sign_warning_orange_3_line"
|
||||
})
|
||||
|
||||
signs_lib.register_sign("street_signs:sign_warning_orange_4_line", {
|
||||
description = "W23-2: Generic US diamond \"warning\" sign (4-line, orange)",
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_warning_36x36.obj",
|
||||
tiles = {
|
||||
"street_signs_warning_orange.png",
|
||||
"street_signs_sign_edge.png",
|
||||
},
|
||||
inventory_image = "street_signs_warning_orange_4_line_inv.png",
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
number_of_lines = 4,
|
||||
horiz_scaling = 1.75,
|
||||
vert_scaling = 1.75,
|
||||
line_spacing = 1,
|
||||
font_size = 15,
|
||||
x_offset = 6,
|
||||
y_offset = 25,
|
||||
chars_per_line = 15,
|
||||
entity_info = {
|
||||
mesh = "street_signs_warning_36x36_entity.obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
},
|
||||
drop = "street_signs:sign_warning_orange_4_line"
|
||||
})
|
||||
for _, s in ipairs(street_signs.big_sign_sizes) do
|
||||
local size = s[1]
|
||||
local nlines = s[2]
|
||||
@ -191,21 +119,13 @@ for _, s in ipairs(street_signs.big_sign_sizes) do
|
||||
wall_top = { -s[8][3], -s[8][1], s[8][2], -s[8][6], -s[8][4], s[8][5] },
|
||||
wall_bottom = { s[8][3], s[8][1], s[8][2], s[8][6], s[8][4], s[8][5] }
|
||||
}
|
||||
|
||||
for _, c in ipairs(street_signs.big_sign_colors) do
|
||||
|
||||
local color = c[1]
|
||||
local defc = c[2]
|
||||
|
||||
minetest.register_node("street_signs:sign_highway_"..size.."_"..color, {
|
||||
|
||||
signs_lib.register_sign("street_signs:sign_highway_"..size.."_"..color, {
|
||||
description = "Generic highway sign ("..nlines.."-line, "..size..", "..color..")",
|
||||
inventory_image = "street_signs_generic_highway_"..size.."_"..color.."_inv.png",
|
||||
wield_image = "street_signs_generic_highway_"..size.."_"..color.."_inv.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_highway_"..size..".obj",
|
||||
tiles = {
|
||||
@ -214,13 +134,8 @@ for _, s in ipairs(street_signs.big_sign_sizes) do
|
||||
"street_signs_generic_highway_edges.png"
|
||||
},
|
||||
default_color = defc,
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2},
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
number_of_lines = nlines,
|
||||
chars_per_line = nchars,
|
||||
horiz_scaling = hscale,
|
||||
@ -232,18 +147,13 @@ for _, s in ipairs(street_signs.big_sign_sizes) do
|
||||
entity_info = {
|
||||
mesh = "street_signs_generic_highway_"..size.."_entity.obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
}
|
||||
},
|
||||
allow_onpole = false
|
||||
})
|
||||
|
||||
minetest.register_node("street_signs:sign_highway_widefont_"..size.."_"..color, {
|
||||
|
||||
signs_lib.register_sign("street_signs:sign_highway_widefont_"..size.."_"..color, {
|
||||
description = "Generic highway sign (Wide font, "..nlines.."-line, "..size..", "..color..")",
|
||||
inventory_image = "street_signs_generic_highway_"..size.."_"..color.."_inv.png",
|
||||
wield_image = "street_signs_generic_highway_"..size.."_"..color.."_inv.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "wallmounted",
|
||||
drawtype = "mesh",
|
||||
node_box = cbox,
|
||||
selection_box = cbox,
|
||||
mesh = "street_signs_generic_highway_"..size..".obj",
|
||||
tiles = {
|
||||
@ -252,13 +162,8 @@ for _, s in ipairs(street_signs.big_sign_sizes) do
|
||||
"street_signs_generic_highway_edges.png"
|
||||
},
|
||||
default_color = defc,
|
||||
groups = {sign = 1, choppy=2, dig_immediate=2},
|
||||
on_rightclick = signs_lib.construct_sign,
|
||||
on_construct = signs_lib.construct_sign,
|
||||
on_destruct = signs_lib.destruct_sign,
|
||||
on_receive_fields = signs_lib.receive_fields,
|
||||
on_punch = signs_lib.update_sign,
|
||||
on_rotate = signs_lib.wallmounted_rotate,
|
||||
groups = signs_lib.standard_steel_groups,
|
||||
sounds = signs_lib.standard_steel_sign_sounds,
|
||||
number_of_lines = nlines,
|
||||
chars_per_line = math.ceil(nchars/1.4),
|
||||
horiz_scaling = hscale/1.4,
|
||||
@ -270,12 +175,8 @@ for _, s in ipairs(street_signs.big_sign_sizes) do
|
||||
entity_info = {
|
||||
mesh = "street_signs_generic_highway_"..size.."_entity.obj",
|
||||
yaw = signs_lib.wallmounted_yaw
|
||||
}
|
||||
},
|
||||
allow_onpole = false
|
||||
})
|
||||
|
||||
table.insert(signs_lib.lbm_restore_nodes, "street_signs:sign_highway_"..size.."_"..color)
|
||||
table.insert(signs_lib.lbm_restore_nodes, "street_signs:sign_highway_widefont_"..size.."_"..color)
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user