summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--asphalt/init.lua2
-rw-r--r--asphaltstairs/init.lua16
-rw-r--r--constructionarea/init.lua4
-rw-r--r--delineator/init.lua2
-rw-r--r--emergencyphone/init.lua2
-rw-r--r--labels/init.lua22
-rw-r--r--manholes/init.lua6
-rw-r--r--roadsigns/pole.lua4
-rw-r--r--roadsigns/signs.lua16
-rw-r--r--roadsigns/workshop.lua36
-rw-r--r--roadworks/init.lua24
-rw-r--r--steelsupport/init.lua2
-rw-r--r--streetlamps/init.lua10
-rw-r--r--streetsconcrete/init.lua14
-rw-r--r--streetsmod/forms.lua8
-rw-r--r--streetsmod/init.lua23
-rw-r--r--trafficlight/init.lua21
-rw-r--r--trafficlight/pole.lua33
18 files changed, 116 insertions, 129 deletions
diff --git a/asphalt/init.lua b/asphalt/init.lua
index 76dc607..706ca81 100644
--- a/asphalt/init.lua
+++ b/asphalt/init.lua
@@ -2,7 +2,7 @@
Streets Mod: All kinds of asphalt
]]
minetest.register_node(":streets:asphalt",{
- description = S(S("Asphalt")),
+ description = streets.S(streets.S("Asphalt")),
tiles = {"streets_asphalt.png"},
groups = {cracky=3}
})
diff --git a/asphaltstairs/init.lua b/asphaltstairs/init.lua
index c035749..1ac3de8 100644
--- a/asphaltstairs/init.lua
+++ b/asphaltstairs/init.lua
@@ -10,7 +10,7 @@ if type(register_stair_slab_panel_micro) ~= "function" then return end
-- Asphalt solid line
-- Stair
minetest.register_node(":streets:asphalt_solid_line_stair",{
- description = S("Asphalt stair"),
+ description = streets.S("Asphalt stair"),
tiles = {"streets_asphalt.png^streets_asphalt_solid_line.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png^streets_asphalt_solid_line.png"},
groups = {cracky = 3},
paramtype = "light",
@@ -42,7 +42,7 @@ if type(register_stair_slab_panel_micro) ~= "function" then return end
})
-- Slab
minetest.register_node(":streets:asphalt_solid_line_slab",{
- description = S("Asphalt slab"),
+ description = streets.S("Asphalt slab"),
tiles = {"streets_asphalt.png^streets_asphalt_solid_line.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png^streets_asphalt_solid_line.png"},
groups = {cracky = 3},
paramtype = "light",
@@ -67,7 +67,7 @@ if type(register_stair_slab_panel_micro) ~= "function" then return end
-- Asphalt dashed line
-- Stair
minetest.register_node(":streets:asphalt_dashed_line_stair",{
- description = S("Asphalt stair"),
+ description = streets.S("Asphalt stair"),
tiles = {"streets_asphalt.png^streets_asphalt_dashed_line.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png^streets_asphalt_dashed_line.png"},
groups = {cracky = 3},
paramtype = "light",
@@ -99,7 +99,7 @@ if type(register_stair_slab_panel_micro) ~= "function" then return end
})
-- Slab
minetest.register_node(":streets:asphalt_dashed_line_slab",{
- description = S("Asphalt slab"),
+ description = streets.S("Asphalt slab"),
tiles = {"streets_asphalt.png^streets_asphalt_dashed_line.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png^streets_asphalt_dashed_line.png"},
groups = {cracky = 3},
paramtype = "light",
@@ -122,7 +122,7 @@ if type(register_stair_slab_panel_micro) ~= "function" then return end
})
-- Asphalt outer line
minetest.register_node(":streets:asphalt_side_stair_l",{
- description = S("Asphalt stair"),
+ description = streets.S("Asphalt stair"),
tiles = {"streets_asphalt.png^streets_asphalt_side.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png^streets_asphalt_side.png"},
groups = {cracky = 3},
paramtype = "light",
@@ -137,7 +137,7 @@ if type(register_stair_slab_panel_micro) ~= "function" then return end
}
})
minetest.register_node(":streets:asphalt_side_stair_r",{
- description = S(S("Asphalt stair")),
+ description = streets.S(streets.S("Asphalt stair")),
tiles = {"streets_asphalt.png^streets_asphalt_side_r.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png^streets_asphalt_side_r.png"},
groups = {cracky = 3},
paramtype = "light",
@@ -180,7 +180,7 @@ if type(register_stair_slab_panel_micro) ~= "function" then return end
})
---------------------------------------------------------------------
minetest.register_node(":streets:asphalt_side_slab_l",{
- description = S(S("Asphalt slab")),
+ description = streets.S(streets.S("Asphalt slab")),
tiles = {"streets_asphalt.png^streets_asphalt_side.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png^streets_asphalt_side.png"},
groups = {cracky = 3},
paramtype = "light",
@@ -194,7 +194,7 @@ if type(register_stair_slab_panel_micro) ~= "function" then return end
}
})
minetest.register_node(":streets:asphalt_side_slab_r",{
- description = S(S("Asphalt slab")),
+ description = streets.S(streets.S("Asphalt slab")),
tiles = {"streets_asphalt.png^streets_asphalt_side_r.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png","streets_asphalt.png^streets_asphalt_side_r.png"},
groups = {cracky = 3},
paramtype = "light",
diff --git a/constructionarea/init.lua b/constructionarea/init.lua
index b521f3e..4bf83e9 100644
--- a/constructionarea/init.lua
+++ b/constructionarea/init.lua
@@ -1,5 +1,5 @@
minetest.register_node(":streets:constructionfence_bottom",{
- description = S("Construction fence"),
+ description = streets.S("Construction fence"),
tiles = {"streets_fence_fromtop.png","streets_fence_fromtop.png","streets_fence_fromtop.png","streets_fence_fromtop.png","streets_fence_bottom.png","streets_fence_bottom.png"},
groups = {cracky = 2,},
paramtype = "light",
@@ -35,7 +35,7 @@ minetest.register_node(":streets:constructionfence_bottom",{
})
minetest.register_node(":streets:constructionfence_top",{
- description = S("Construction fence"),
+ description = streets.S("Construction fence"),
tiles = {"streets_fence_fromtop.png","streets_fence_fromtop.png","streets_fence_fromtop.png","streets_fence_fromtop.png","streets_fence_top.png","streets_fence_top.png"},
groups = {cracky = 2, not_in_creative_inventory = 1},
paramtype = "light",
diff --git a/delineator/init.lua b/delineator/init.lua
index 09158d2..cf78142 100644
--- a/delineator/init.lua
+++ b/delineator/init.lua
@@ -2,7 +2,7 @@
StreetsMod: Delineator
]]
minetest.register_node(":streets:delineator", {
- description = S("Delineator"),
+ description = streets.S("Delineator"),
tiles = {"streets_delineator_top.png","streets_delineator.png"},
drawtype = "nodebox",
paramtype = "light",
diff --git a/emergencyphone/init.lua b/emergencyphone/init.lua
index 4f4d1c7..d5cb5ae 100644
--- a/emergencyphone/init.lua
+++ b/emergencyphone/init.lua
@@ -2,7 +2,7 @@
StreetsMod: Emergency Phone
]]
minetest.register_node(":streets:emergencyphone",{
- description = S("Emergency Phone"),
+ description = streets.S("Emergency Phone"),
tiles = {"streets_sos_top.png","streets_sos_bottom.png","streets_sos_side.png","streets_sos_side.png","streets_sos_side.png","streets_sos_front.png"},
groups = {cracky = 3},
paramtype2 = "facedir",
diff --git a/labels/init.lua b/labels/init.lua
index e2a8606..c46a990 100644
--- a/labels/init.lua
+++ b/labels/init.lua
@@ -2,7 +2,7 @@
StreetsMod: All kinds of asphalt with labels
]]
minetest.register_node(":streets:asphalt_sideline",{
- description = S("Asphalt with sideline"),
+ description = streets.S("Asphalt with sideline"),
groups = {cracky=3},
tiles = {"streets_asphalt.png^streets_asphalt_side.png","streets_asphalt.png"},
paramtype2 = "facedir"
@@ -18,7 +18,7 @@ minetest.register_craft({
})
minetest.register_node(":streets:asphalt_solid_line",{
- description = S("Asphalt with solid line"),
+ description = streets.S("Asphalt with solid line"),
groups = {cracky=3},
tiles = {"streets_asphalt.png^streets_asphalt_solid_line.png","streets_asphalt.png"},
paramtype2 = "facedir"
@@ -34,7 +34,7 @@ minetest.register_craft({
})
minetest.register_node(":streets:asphalt_dashed_line",{
- description = S("Asphalt with dashed line"),
+ description = streets.S("Asphalt with dashed line"),
groups = {cracky=3},
tiles = {"streets_asphalt.png^streets_asphalt_dashed_line.png","streets_asphalt.png"},
paramtype2 = "facedir"
@@ -50,7 +50,7 @@ minetest.register_craft({
})
minetest.register_node(":streets:asphalt_outer_edge",{
- description = S("Asphalt with sideline (edge)"),
+ description = streets.S("Asphalt with sideline (edge)"),
groups = {cracky=3},
tiles = {"streets_asphalt.png^streets_asphalt_outer_edge.png","streets_asphalt.png"},
paramtype2 = "facedir"
@@ -66,7 +66,7 @@ minetest.register_craft({
})
minetest.register_node(":streets:asphalt_parking",{
- description = S("Asphalt with parking label"),
+ description = streets.S("Asphalt with parking label"),
groups = {cracky=3},
tiles = {"streets_asphalt.png^streets_parking.png","streets_asphalt.png"},
paramtype2 = "facedir"
@@ -82,7 +82,7 @@ minetest.register_craft({
})
minetest.register_node(":streets:asphalt_arrow_straight",{
- description = S("Asphalt with arrow"),
+ description = streets.S("Asphalt with arrow"),
groups = {cracky=3},
tiles = {"streets_asphalt.png^streets_arrow_straight.png","streets_asphalt.png"},
paramtype2 = "facedir"
@@ -98,7 +98,7 @@ minetest.register_craft({
})
minetest.register_node(":streets:asphalt_arrow_left",{
- description = S("Asphalt with arrow"),
+ description = streets.S("Asphalt with arrow"),
groups = {cracky=3},
tiles = {"streets_asphalt.png^streets_arrow_left.png","streets_asphalt.png"},
paramtype2 = "facedir"
@@ -114,7 +114,7 @@ minetest.register_craft({
})
minetest.register_node(":streets:asphalt_arrow_right",{
- description = S("Asphalt with arrow"),
+ description = streets.S("Asphalt with arrow"),
groups = {cracky=3},
tiles = {"streets_asphalt.png^streets_arrow_right.png","streets_asphalt.png"},
paramtype2 = "facedir"
@@ -130,7 +130,7 @@ minetest.register_craft({
})
minetest.register_node(":streets:asphalt_arrow_straight_left",{
- description = S("Asphalt with arrow"),
+ description = streets.S("Asphalt with arrow"),
groups = {cracky=3},
tiles = {"streets_asphalt.png^streets_arrow_straight_left.png","streets_asphalt.png"},
paramtype2 = "facedir"
@@ -146,7 +146,7 @@ minetest.register_craft({
})
minetest.register_node(":streets:asphalt_arrow_straight_right",{
- description = S("Asphalt with arrow"),
+ description = streets.S("Asphalt with arrow"),
groups = {cracky=3},
tiles = {"streets_asphalt.png^streets_arrow_straight_right.png","streets_asphalt.png"},
paramtype2 = "facedir"
@@ -162,7 +162,7 @@ minetest.register_craft({
})
minetest.register_node(":streets:asphalt_arrow_alldirs",{
- description = S("Asphalt with arrow"),
+ description = streets.S("Asphalt with arrow"),
groups = {cracky=3},
tiles = {"streets_asphalt.png^streets_arrow_alldirs.png","streets_asphalt.png"},
paramtype2 = "facedir"
diff --git a/manholes/init.lua b/manholes/init.lua
index bcd7d39..b9a2f40 100644
--- a/manholes/init.lua
+++ b/manholes/init.lua
@@ -2,13 +2,13 @@
StreetsMod: Manholes in asphalt
]]
minetest.register_node(":streets:manhole",{
- description = S("Simple manhole"),
+ description = streets.S("Simple manhole"),
tiles = {"streets_asphalt.png^streets_manhole.png","streets_asphalt.png"},
groups = {cracky=3}
})
minetest.register_node(":streets:manhole_adv_closed",{
- description = S("Advanced manhole"),
+ description = streets.S("Advanced manhole"),
tiles = {"streets_asphalt.png^streets_manhole_advanced.png","streets_asphalt.png"},
groups = {cracky=3},
drawtype = "nodebox",
@@ -36,7 +36,7 @@ minetest.register_node(":streets:manhole_adv_closed",{
end
})
minetest.register_node(":streets:manhole_adv_open",{
- description = S("Advanced manhole"),
+ description = streets.S("Advanced manhole"),
tiles = {"streets_asphalt.png^streets_manhole_advanced.png","streets_asphalt.png"},
groups = {cracky=3,not_in_creative_inventory=1},
drawtype = "nodebox",
diff --git a/roadsigns/pole.lua b/roadsigns/pole.lua
index 417ecdf..5d68398 100644
--- a/roadsigns/pole.lua
+++ b/roadsigns/pole.lua
@@ -2,7 +2,7 @@
StreetsMod: Poles and signs
]]
minetest.register_node(":streets:pole_bottom",{
- description = S("Pole"),
+ description = streets.S("Pole"),
tiles = {"streets_pole.png"},
groups = {cracky=2},
inventory_image = "streets_pole_inv.png",
@@ -42,7 +42,7 @@ minetest.register_node(":streets:pole_bottom",{
})
minetest.register_node(":streets:pole_top",{
- description = S("Y u no play minetest without cheating?"),
+ description = streets.S("Y u no play minetest without cheating?"),
tiles = {"streets_pole.png"},
groups = {cracky=2,not_in_creative_inventory=1},
paramtype = "light",
diff --git a/roadsigns/signs.lua b/roadsigns/signs.lua
index 3b8beb4..03b4139 100644
--- a/roadsigns/signs.lua
+++ b/roadsigns/signs.lua
@@ -1,5 +1,5 @@
minetest.register_node(":streets:sign_blank",{
- description = S("Empty sign"),
+ description = streets.S("Empty sign"),
tiles = {"streets_sign_back.png"},
inventory_image = "streets_sign_back.png",
wield_image = "streets_sign_back.png",
@@ -27,11 +27,11 @@ minetest.register_node(":streets:sign_blank",{
after_place_node = function(pos)
local meta = minetest.get_meta(pos)
- meta:set_string("infotext", S("Empty Sign"))
+ meta:set_string("infotext", streets.S("Empty Sign"))
end
})
minetest.register_node(":streets:sign_lava",{
- description = S("Warning sign (lava)"),
+ description = streets.S("Warning sign (lava)"),
tiles = {"streets_sign_lava.png"},
inventory_image = "streets_sign_lava.png",
wield_image = "streets_sign_lava.png",
@@ -59,12 +59,12 @@ minetest.register_node(":streets:sign_lava",{
after_place_node = function(pos)
local meta = minetest.get_meta(pos)
- meta:set_string("infotext", S("Warning: Careful of lava"))
+ meta:set_string("infotext", streets.S("Warning: Careful of lava"))
end
})
minetest.register_node(":streets:sign_water",{
- description = S("Warning sign (water)"),
+ description = streets.S("Warning sign (water)"),
tiles = {"streets_sign_water.png"},
inventory_image = "streets_sign_water.png",
wield_image = "streets_sign_water.png",
@@ -92,12 +92,12 @@ minetest.register_node(":streets:sign_water",{
after_place_node = function(pos)
local meta = minetest.get_meta(pos)
- meta:set_string("infotext", S("Warning: Water nearby"))
+ meta:set_string("infotext", streets.S("Warning: Water nearby"))
end
})
minetest.register_node(":streets:sign_construction",{
- description = S("Warning sign (Construction area)"),
+ description = streets.S("Warning sign (Construction area)"),
tiles = {"streets_sign_construction.png"},
inventory_image = "streets_sign_construction.png",
wield_image = "streets_sign_construction.png",
@@ -125,6 +125,6 @@ minetest.register_node(":streets:sign_construction",{
after_place_node = function(pos)
local meta = minetest.get_meta(pos)
- meta:set_string("infotext", S("Warning: Construction area, possible deep excavations"))
+ meta:set_string("infotext", streets.S("Warning: Construction area, possible deep excavations"))
end
})
diff --git a/roadsigns/workshop.lua b/roadsigns/workshop.lua
index 272285c..4854a98 100644
--- a/roadsigns/workshop.lua
+++ b/roadsigns/workshop.lua
@@ -4,17 +4,17 @@
local forms = {
inactive = {
"size[12,10]",
- "label[3.5,0;"..S("Sign workshop - Create signs for your roads!").."]",
- "label[0,0.5;"..S("Available signs:").."]",
+ "label[3.5,0;"..streets.S("Sign workshop - Create signs for your roads!").."]",
+ "label[0,0.5;"..streets.S("Available signs:").."]",
"list[context;streets:signworkshop_list;0,1;5,4]",
- "label[9,0.5;"..S("Needed stuff:").."]",
+ "label[9,0.5;"..streets.S("Needed stuff:").."]",
"list[context;streets:signworkshop_recipe;8,1;4,1]",
- "label[9,2;"..S("Put it here:").."]",
+ "label[9,2;"..streets.S("Put it here:").."]",
"list[context;streets:signworkshop_input;8,3;4,1]",
- "button[8,4;2,1;streets:signworkshop_send;"..S("Start!").."]",
- "label[5.8,0.5;"..S("Selected:").."]",
+ "button[8,4;2,1;streets:signworkshop_send;"..streets.S("Start!").."]",
+ "label[5.8,0.5;"..streets.S("Selected:").."]",
"list[context;streets:signworkshop_select;6,1;1,1]",
- "label[5.8,2.5;"..S("Output:").."]",
+ "label[5.8,2.5;"..streets.S("Output:").."]",
"list[context;streets:signworkshop_output;6,3;1,1]",
"list[current_player;main;2,6;8,1]",
"list[current_player;main;2,7.25;8,3;8]",
@@ -25,16 +25,16 @@ local forms = {
},
active = {
"size[12,10]",
- "label[3.5,0;"..S("Sign workshop - Create signs for your roads!").."]",
- "label[0,0.5;"..S("Available signs:").."]",
+ "label[3.5,0;"..streets.S("Sign workshop - Create signs for your roads!").."]",
+ "label[0,0.5;"..streets.S("Available signs:").."]",
"list[context;streets:signworkshop_list;0,1;5,4]",
- "label[9,0.5;"..S("Needed stuff:").."]",
+ "label[9,0.5;"..streets.S("Needed stuff:").."]",
"list[context;streets:signworkshop_recipe;8,1;4,1]",
- "label[9,2;"..S("Put it here:").."]",
+ "label[9,2;"..streets.S("Put it here:").."]",
"list[context;streets:signworkshop_input;8,3;4,1]",
- "label[5.8,0.5;"..S("Selected:").."]",
+ "label[5.8,0.5;"..streets.S("Selected:").."]",
"list[context;streets:signworkshop_select;6,1;1,1]",
- "label[5.8,2.5;"..S("Output:").."]",
+ "label[5.8,2.5;"..streets.S("Output:").."]",
"list[context;streets:signworkshop_output;6,3;1,1]",
"list[current_player;main;2,6;8,1]",
"list[current_player;main;2,7.25;8,3;8]",
@@ -46,7 +46,7 @@ local forms = {
}
}
minetest.register_node(":streets:signworkshop",{
- description = S("Sign workshop"),
+ description = streets.S("Sign workshop"),
tiles = {"streets_signworkshop_top.png","streets_signworkshop_bottom.png","streets_signworkshop_side.png","streets_signworkshop_side.png","streets_signworkshop_side.png","streets_signworkshop_front.png"},
groups = {cracky = 1, level = 2},
paramtype2 = "facedir",
@@ -65,7 +65,7 @@ minetest.register_node(":streets:signworkshop",{
inv:add_item("streets:signworkshop_list","streets:sign_water")
inv:add_item("streets:signworkshop_list","streets:sign_construction")
-- Meta
- meta:set_string("infotext",S("Sign workshop idle"))
+ meta:set_string("infotext",streets.S("Sign workshop idle"))
meta:set_string("idle","y")
end,
allow_metadata_inventory_put = function(pos, listname, index, stack, player)
@@ -129,14 +129,14 @@ minetest.register_node(":streets:signworkshop",{
if has[3] == nil then has[3] = { name = "" } end
if has[4] == nil then has[4] = { name = "" } end
if need[1].name == has[1].name and need[2].name == has[2].name and need[3].name == has[3].name and need[4].name == has[4].name then
- meta:set_string("infotext",S("Sign workshop working"))
+ meta:set_string("infotext",streets.S("Sign workshop working"))
meta:set_string("idle","n")
- meta:set_string("formspec",table.concat(forms.active) .. "label[8,4;"..S("Please wait %s seconds..."):format(def.time).."]")
+ meta:set_string("formspec",table.concat(forms.active) .. "label[8,4;"..streets.S("Please wait %s seconds..."):format(def.time).."]")
-- Clear input
inv:set_list("streets:signworkshop_input",{"","","",""})
minetest.after(def.time,function()
-- Reset infotext and meta
- meta:set_string("infotext",S("Sign workshop idle"))
+ meta:set_string("infotext",streets.S("Sign workshop idle"))
meta:set_string("idle","y")
meta:set_string("formspec",table.concat(forms.inactive))
-- Fill output
diff --git a/roadworks/init.lua b/roadworks/init.lua
index dfad72e..43dfbbc 100644
--- a/roadworks/init.lua
+++ b/roadworks/init.lua
@@ -6,7 +6,7 @@
local box = {-0.5,-0.5,-0.5,0.5,-0.45,0.5}
minetest.register_node(":streets:rw_asphalt_solid",{
- description = S("Solid line (yellow)"),
+ description = streets.S("Solid line (yellow)"),
tiles = {"streets_rw_solid_line.png","streets_rw_solid_line_curve.png","streets_rw_solid_line_tjunction.png","streets_rw_solid_line_crossing.png"},
drawtype = "raillike",
paramtype = "light",
@@ -23,7 +23,7 @@ minetest.register_node(":streets:rw_asphalt_solid",{
})
minetest.register_node(":streets:rw_asphalt_dashed",{
- description = S("Dashed line (yellow)"),
+ description = streets.S("Dashed line (yellow)"),
tiles = {"streets_rw_dashed_line.png","streets_rw_dashed_line_curve.png","streets_rw_dashed_line_tjunction.png","streets_rw_dashed_line_crossing.png"},
drawtype = "raillike",
paramtype = "light",
@@ -40,7 +40,7 @@ minetest.register_node(":streets:rw_asphalt_dashed",{
})
minetest.register_node(":streets:rw_cross",{
- description = S("Cross (yellow)"),
+ description = streets.S("Cross (yellow)"),
tiles = {"streets_rw_cross.png"},
drawtype = "signlike",
paramtype = "light",
@@ -56,7 +56,7 @@ minetest.register_node(":streets:rw_cross",{
})
minetest.register_node(":streets:rw_outer_edge",{
- description = S("Outer edge (yellow)"),
+ description = streets.S("Outer edge (yellow)"),
tiles = {"streets_rw_outer_edge.png","streets_rw_transparent.png"},
drawtype = "nodebox",
paramtype = "light",
@@ -77,7 +77,7 @@ minetest.register_node(":streets:rw_outer_edge",{
})
minetest.register_node(":streets:rw_parking",{
- description = S("Parking (yellow)"),
+ description = streets.S("Parking (yellow)"),
tiles = {"streets_rw_parking.png","streets_rw_transparent.png"},
drawtype = "nodebox",
paramtype = "light",
@@ -98,7 +98,7 @@ minetest.register_node(":streets:rw_parking",{
})
minetest.register_node(":streets:rw_alldirs",{
- description = S("Arrow (yellow)"),
+ description = streets.S("Arrow (yellow)"),
tiles = {"streets_rw_arrow_alldirs.png","streets_rw_transparent.png"},
drawtype = "nodebox",
paramtype = "light",
@@ -119,7 +119,7 @@ minetest.register_node(":streets:rw_alldirs",{
})
minetest.register_node(":streets:rw_left",{
- description = S("Arrow (yellow)"),
+ description = streets.S("Arrow (yellow)"),
tiles = {"streets_rw_arrow_left.png","streets_rw_transparent.png"},
drawtype = "nodebox",
paramtype = "light",
@@ -140,7 +140,7 @@ minetest.register_node(":streets:rw_left",{
})
minetest.register_node(":streets:rw_right",{
- description = S("Arrow (yellow)"),
+ description = streets.S("Arrow (yellow)"),
tiles = {"streets_rw_arrow_right.png","streets_rw_transparent.png"},
drawtype = "nodebox",
paramtype = "light",
@@ -161,7 +161,7 @@ minetest.register_node(":streets:rw_right",{
})
minetest.register_node(":streets:rw_straight_right",{
- description = S("Arrow (yellow)"),
+ description = streets.S("Arrow (yellow)"),
tiles = {"streets_rw_arrow_straight_right.png","streets_rw_transparent.png"},
drawtype = "nodebox",
paramtype = "light",
@@ -182,7 +182,7 @@ minetest.register_node(":streets:rw_straight_right",{
})
minetest.register_node(":streets:rw_straight_left",{
- description = S("Arrow (yellow)"),
+ description = streets.S("Arrow (yellow)"),
tiles = {"streets_rw_arrow_straight_left.png","streets_rw_transparent.png"},
drawtype = "nodebox",
paramtype = "light",
@@ -203,7 +203,7 @@ minetest.register_node(":streets:rw_straight_left",{
})
minetest.register_node(":streets:rw_straight",{
- description = S("Arrow (yellow)"),
+ description = streets.S("Arrow (yellow)"),
tiles = {"streets_rw_arrow_straight.png","streets_rw_transparent.png"},
drawtype = "nodebox",
paramtype = "light",
@@ -224,7 +224,7 @@ minetest.register_node(":streets:rw_straight",{
})
minetest.register_node(":streets:rw_sideline",{
- description = S("Sideline (yellow)"),
+ description = streets.S("Sideline (yellow)"),
tiles = {"streets_rw_asphalt_side.png","streets_rw_transparent.png"},
drawtype = "nodebox",
paramtype = "light",
diff --git a/steelsupport/init.lua b/steelsupport/init.lua
index 6217600..56cc084 100644
--- a/steelsupport/init.lua
+++ b/steelsupport/init.lua
@@ -2,7 +2,7 @@
StreetsMod: Steel support for hanging signs on highways etc.
]]
minetest.register_node(":streets:steel_support",{
- description = S("Steel support"),
+ description = streets.S("Steel support"),
tiles = {"streets_support.png"},
groups = {cracky = 1},
drawtype = "glasslike_framed",
diff --git a/streetlamps/init.lua b/streetlamps/init.lua
index bb80136..c7097f9 100644
--- a/streetlamps/init.lua
+++ b/streetlamps/init.lua
@@ -2,7 +2,7 @@
StreetsMod: Streetlamps
]]
--[[minetest.register_node(":streets:streetlamp_basic_controller",{
- description = S("Trafficlight"),
+ description = streets.S("Trafficlight"),
tiles = {"streets_lampcontroller_top.png","streets_lampcontroller_bottom.png","streets_lampcontroller_sides.png"},
groups = {cracky = 1, not_in_creative_inventory = 1},
drawtype = "nodebox",
@@ -41,7 +41,7 @@
minetest.register_node(":streets:streetlamp_basic_bottom",{
drop = "",
- description = S("Street lamp"),
+ description = streets.S("Street lamp"),
tiles = {"streets_lamps_basic_bottom.png"},
inventory_image = "streets_lamps_basi_inv.png",
groups = {cracky = 1},
@@ -63,7 +63,7 @@ minetest.register_node(":streets:streetlamp_basic_bottom",{
})
minetest.register_node(":streets:streetlamp_basic_middle",{
drop = "",
- description = S("U cheater U"),
+ description = streets.S("U cheater U"),
groups = {cracky = 1, not_in_creative_inventory = 1},
tiles = {"streets_lamps_basic_middle.png"},
paramtype = "light",
@@ -78,7 +78,7 @@ minetest.register_node(":streets:streetlamp_basic_middle",{
})
--[[minetest.register_node(":streets:streetlamp_basic_top_off",{
drop = "",
- description = S("U cheater U"),
+ description = streets.S("U cheater U"),
groups = {cracky = 1, not_in_creative_inventory = 1},
paramtype = "light",
drawtype = "nodebox",
@@ -93,7 +93,7 @@ minetest.register_node(":streets:streetlamp_basic_middle",{
})]]
minetest.register_node(":streets:streetlamp_basic_top_on",{
drop = "streets:streetlamp_basic_bottom",
- description = S("U cheater U"),
+ description = streets.S("U cheater U"),
groups = {cracky = 1, not_in_creative_inventory = 1},
tiles = {"streets_lamps_basic_top_top.png","streets_lamps_basic_top_top.png","streets_lamps_basic_top.png","streets_lamps_basic_top.png","streets_lamps_basic_top.png","streets_lamps_basic_top.png"},
paramtype = "light",
diff --git a/streetsconcrete/init.lua b/streetsconcrete/init.lua
index f4d0205..cb29ee9 100644
--- a/streetsconcrete/init.lua
+++ b/streetsconcrete/init.lua
@@ -5,7 +5,7 @@ if streets.extendedBy.technic == true then
minetest.register_alias("streets:concrete","technic:concrete")
-- Use technic's concrete block for the seperating wall
minetest.register_node(":streets:concrete_wall",{
- description = S("Concrete wall"),
+ description = streets.S("Concrete wall"),
tiles = {"technic_concrete_block.png"},
groups = {cracky=2},
drawtype = "nodebox",
@@ -28,7 +28,7 @@ if streets.extendedBy.technic == true then
}
})
minetest.register_node(":streets:concrete_wall_flat",{
- description = S("Concrete wall"),
+ description = streets.S("Concrete wall"),
tiles = {"technic_concrete_block.png"},
groups = {cracky=2},
drawtype = "nodebox",
@@ -52,7 +52,7 @@ if streets.extendedBy.technic == true then
elseif streets.extendedBy.prefab then
minetest.register_alias("streets:concrete","prefab:concrete")
minetest.register_node(":streets:concrete_wall",{
- description = S("Concrete wall"),
+ description = streets.S("Concrete wall"),
tiles = {"prefab_concrete.png"},
groups = {cracky=2},
drawtype = "nodebox",
@@ -75,7 +75,7 @@ elseif streets.extendedBy.prefab then
}
})
minetest.register_node(":streets:concrete_wall_flat",{
- description = S("Concrete wall"),
+ description = streets.S("Concrete wall"),
tiles = {"prefab_concrete.png"},
groups = {cracky=2},
drawtype = "nodebox",
@@ -99,12 +99,12 @@ elseif streets.extendedBy.prefab then
else
-- Register concrete block with streets' texture and then the seperating wall
minetest.register_node(":streets:concrete",{
- description = S("Concrete"),
+ description = streets.S("Concrete"),
tiles = {"streets_concrete.png"},
groups = {cracky=2}
})
minetest.register_node(":streets:concrete_wall",{
- description = S("Concrete wall"),
+ description = streets.S("Concrete wall"),
tiles = {"streets_concrete.png"},
groups = {cracky=2},
drawtype = "nodebox",
@@ -127,7 +127,7 @@ else
}
})
minetest.register_node(":streets:concrete_wall_flat",{
- description = S("Concrete wall"),
+ description = streets.S("Concrete wall"),
tiles = {"streets_concrete.png"},
groups = {cracky=2},
drawtype = "nodebox",
diff --git a/streetsmod/forms.lua b/streetsmod/forms.lua
index f412610..28ceb31 100644
--- a/streetsmod/forms.lua
+++ b/streetsmod/forms.lua
@@ -2,9 +2,9 @@ streets.forms.chatcmd = smartfs.create("streets:chatcmd", function(state)
state:size(10,6)
local tlist = state:element("list", { pos={x=0,y=1}, size={w=6,h=5}, name = "streets:chatcmd_modlist" } )
tlist:removeItem()
- for k, v in pairs(streets.extendedBy) do
- tlist:addItem(tostring(k) .. " " .. S("installed") .. ": " .. tostring(v))
+ for k, v in pairstreets.S(streets.extendedBy) do
+ tlist:addItem(tostring(k) .. " " .. streets.S("installed") .. ": " .. tostring(v))
end
- state:label(6.5, 1, "streets:chatcmd_version", S("Running version") .. ": " .. streets.version)
- state:label(6.5, 1.5, "streets:chatcmd_loadtime", S("Load time") .. ": " .. round(streets.load.fin - streets.load.start,4) .. "s")
+ state:label(6.5, 1, "streets:chatcmd_version", streets.S("Running version") .. ": " .. streets.version)
+ state:label(6.5, 1.5, "streets:chatcmd_loadtime", streets.S("Load time") .. ": " .. round(streets.load.fin - streets.load.start,4) .. "s")
end) \ No newline at end of file
diff --git a/streetsmod/init.lua b/streetsmod/init.lua
index fd43645..02cb238 100644
--- a/streetsmod/init.lua
+++ b/streetsmod/init.lua
@@ -5,19 +5,18 @@
Forum : http://bit.ly/12cPMeo
Depends : default
]]
--- kaeza: intllib
+streets = {}
+
+-- Kaeza intllib
-- Boilerplate to support localized strings if intllib mod is installed.
- --local S
- if (minetest.get_modpath("intllib")) then
- dofile(minetest.get_modpath("intllib").."/intllib.lua")
- S = intllib.Getter(minetest.get_current_modname())
+ if minetest.get_modpath("intllib") then
+ streets.S = intllib.Getter()
else
- S = function ( s ) return s end
+ streets.S = function(s) return s end
end
-- Create variable and tables
- print("Streets: " .. S("Creating variables and tables..."))
- streets = {}
+ print("Streets: " .. streets.S("Creating variables and tables..."))
streets.version = "1.4.4dev"
streets.modpath = minetest.get_modpath("streetsmod")
streets.extendedBy = {}
@@ -27,6 +26,8 @@
}
streets.forms = {}
+
+
-- Support for mimnetest_next's fancy inventories
if gui_bg and gui_bg_img and gui_slots and type(default.get_hotbar_bg) == "function" then
-- Everything fine :)
@@ -47,7 +48,7 @@
dofile(streets.modpath .. "/forms.lua")
-- Check for mods which change this mod's beahaviour
- print("Streets: " .. S("Checking installed mods..."))
+ print("Streets: " .. streets.S("Checking installed mods..."))
if minetest.get_modpath("wool") then
streets.extendedBy.wool = true
else
@@ -90,12 +91,12 @@
return math.floor(num * mult + 0.5) / mult
end
minetest.register_chatcommand("streets",{
- description = S("Check version of your installed StreetsMod and find information"),
+ description = streets.S("Check version of your installed StreetsMod and find information"),
func = function(name,param)
streets.forms.chatcmd:show(name);
end
})
-- Done
- print("Streets: " .. S("Setup completed, have fun with StreetsMod") .. " " .. streets.version .. "!")
+ print("Streets: " .. streets.S("Setup completed, have fun with StreetsMod") .. " " .. streets.version .. "!")
streets.load.fin = os.clock()
diff --git a/trafficlight/init.lua b/trafficlight/init.lua
index 7e6051a..86d3878 100644
--- a/trafficlight/init.lua
+++ b/trafficlight/init.lua
@@ -18,23 +18,6 @@ streets.tlBox = {
{-0.125,-0.3125,0.3125,-0.0625,-0.25,0.5}, --nodebox10
}
-streets.rules_pole = {
- {x= 0, y= 0, z=-1},
- {x= 1, y= 0, z= 0},
- {x=-1, y= 0, z= 0},
- {x= 0, y= 0, z= 1},
- {x= 1, y= 1, z= 0},
- {x= 1, y=-1, z= 0},
- {x=-1, y= 1, z= 0},
- {x=-1, y=-1, z= 0},
- {x= 0, y= 1, z= 1},
- {x= 0, y=-1, z= 1},
- {x= 0, y= 1, z=-1},
- {x= 0, y=-1, z=-1},
- {x= 0, y=-1, z= 0},
- {x= 0, y= 1, z= 0}
-}
-
streets.tlRythm = {
toRed = {
{name = "streets:trafficlight_top_yellow", pauseBefore = 0},
@@ -101,7 +84,7 @@ streets.on_digiline_receive = function(pos, node, channel, msg)
end
minetest.register_node(":streets:digiline_distributor",{
- description = S("Digiline distributor"),
+ description = streets.S("Digiline distributor"),
tiles = {"streets_lampcontroller_top.png","streets_lampcontroller_bottom.png","streets_lampcontroller_sides.png"},
groups = {cracky = 1},
digiline = {
@@ -114,7 +97,7 @@ minetest.register_node(":streets:digiline_distributor",{
})
minetest.register_node(":streets:trafficlight_top_off",{
- description = S("Trafficlight"),
+ description = streets.S("Trafficlight"),
drawtype="nodebox",
paramtype = "light",
paramtype2 = "facedir",
diff --git a/trafficlight/pole.lua b/trafficlight/pole.lua
index 46d77aa..a8815fc 100644
--- a/trafficlight/pole.lua
+++ b/trafficlight/pole.lua
@@ -1,20 +1,23 @@
--[[
StreetsMod: inDev Trafficlights
]]
-minetest.register_node(":digiline_vertical:wire", {
- description = "Vertical digiline",
- tiles = {"default_brick.png"},
- wield_image = "digiline_std_inv.png",
- paramtype = "light",
- digiline =
- {
- wire =
- {
- rules = streets.rules_pole
- }
- },
- groups = {dig_immediate = 3}
-})
+local rules_pole = {
+ {x= 0, y= 0, z=-1},
+ {x= 1, y= 0, z= 0},
+ {x=-1, y= 0, z= 0},
+ {x= 0, y= 0, z= 1},
+ {x= 1, y= 1, z= 0},
+ {x= 1, y=-1, z= 0},
+ {x=-1, y= 1, z= 0},
+ {x=-1, y=-1, z= 0},
+ {x= 0, y= 1, z= 1},
+ {x= 0, y=-1, z= 1},
+ {x= 0, y= 1, z=-1},
+ {x= 0, y=-1, z=-1},
+ {x= 0, y=-1, z= 0},
+ {x= 0, y= 1, z= 0}
+}
+
minetest.register_node(":streets:bigpole", {
description = "Pole",
paramtype = "light",
@@ -31,7 +34,7 @@ minetest.register_node(":streets:bigpole", {
on_place = minetest.rotate_node,
digiline = {
wire = {
- rules = streets.rules_pole
+ rules = rules_pole
}
}
})