From 0df7fcd05444feb8545c9acccf3c8e7ca018f137 Mon Sep 17 00:00:00 2001 From: webdesigner97 Date: Sat, 12 Oct 2013 11:54:52 +0200 Subject: Improved selectionbox --- trafficlight/init.lua | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'trafficlight') diff --git a/trafficlight/init.lua b/trafficlight/init.lua index 768c26a..1d3049d 100644 --- a/trafficlight/init.lua +++ b/trafficlight/init.lua @@ -17,12 +17,6 @@ minetest.register_node(":streets:trafficlight_bottom",{ {-0.1,0.25,-0.1,0.1,0.5,0.1} } }, - selection_box = { - type = "fixed", - fixed = { - {-0.25,-0.5,-0.25,0.25,2.5,0.25}, - } - } }) minetest.register_node(":streets:trafficlight_middle",{ @@ -54,6 +48,13 @@ minetest.register_node(":streets:trafficlight_controller",{ {-0.05,0.5,-0.05,0.05,1.6,0.05} } }, + selection_box = { + type = "fixed", + fixed = { + {-0.5,-0.5,-0.5,0.5,0.5,0.5}, + {-0.5,1.5,-0.5,0.5,4.5,0.5} + } + }, on_receive_fields = function(pos, formname, fields, sender) minetest.get_meta(pos):set_string("channel", fields.channel) end, -- cgit v1.2.3 From 5508d85d407282c391336bdcb8937a26f21e8c6d Mon Sep 17 00:00:00 2001 From: webdesigner97 Date: Wed, 16 Oct 2013 10:10:19 +0200 Subject: Lightened code --- trafficlight/init.lua | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'trafficlight') diff --git a/trafficlight/init.lua b/trafficlight/init.lua index 1d3049d..44e463a 100644 --- a/trafficlight/init.lua +++ b/trafficlight/init.lua @@ -1,7 +1,6 @@ --[[ StreetsMod: inDev Trafficlights ]] -if streets.extendedBy.mesecons and streets.extendedBy.digilines then minetest.register_node(":streets:trafficlight_bottom",{ description = "Cheater", groups = {not_in_creative_inventory = 1}, @@ -224,6 +223,4 @@ minetest.register_node(":streets:trafficlight_top_warn",{ }, pointable = false, light_source = 6, -}) - -end \ No newline at end of file +}) \ No newline at end of file -- cgit v1.2.3 From 114d1b173cd318e1a80d276b67b8d70362547a1b Mon Sep 17 00:00:00 2001 From: webdesigner97 Date: Sat, 19 Oct 2013 14:49:06 +0200 Subject: Added drop = '' to some nodes --- trafficlight/init.lua | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'trafficlight') diff --git a/trafficlight/init.lua b/trafficlight/init.lua index 44e463a..48d7a62 100644 --- a/trafficlight/init.lua +++ b/trafficlight/init.lua @@ -3,6 +3,7 @@ ]] minetest.register_node(":streets:trafficlight_bottom",{ description = "Cheater", + drop = "", groups = {not_in_creative_inventory = 1}, paramtype = "light", paramtype2 = "facedir", @@ -20,6 +21,7 @@ minetest.register_node(":streets:trafficlight_bottom",{ minetest.register_node(":streets:trafficlight_middle",{ description = "Cheater!", + drop = "", groups = {cracky = 1, not_in_creative_inventory = 1}, paramtype = "light", drawtype = "nodebox", @@ -117,6 +119,7 @@ minetest.register_node(":streets:trafficlight_controller",{ minetest.register_node(":streets:trafficlight_top_off",{ description = "U cheater U", + drop = "", groups = {cracky = 1, not_in_creative_inventory = 1}, paramtype = "light", paramtype2 = "facedir", @@ -134,6 +137,7 @@ minetest.register_node(":streets:trafficlight_top_off",{ minetest.register_node(":streets:trafficlight_top_red",{ description = "U cheater U", + drop = "", groups = {cracky = 1, not_in_creative_inventory = 1}, paramtype = "light", paramtype2 = "facedir", @@ -152,6 +156,7 @@ minetest.register_node(":streets:trafficlight_top_red",{ minetest.register_node(":streets:trafficlight_top_yellow",{ description = "U cheater U", + drop = "", groups = {cracky = 1, not_in_creative_inventory = 1}, paramtype = "light", paramtype2 = "facedir", @@ -170,6 +175,7 @@ minetest.register_node(":streets:trafficlight_top_yellow",{ minetest.register_node(":streets:trafficlight_top_redyellow",{ description = "U cheater U", + drop = "", groups = {cracky = 1, not_in_creative_inventory = 1}, paramtype = "light", paramtype2 = "facedir", @@ -188,6 +194,7 @@ minetest.register_node(":streets:trafficlight_top_redyellow",{ minetest.register_node(":streets:trafficlight_top_green",{ description = "U cheater U", + drop = "", groups = {cracky = 1, not_in_creative_inventory = 1}, paramtype = "light", paramtype2 = "facedir", @@ -206,6 +213,7 @@ minetest.register_node(":streets:trafficlight_top_green",{ minetest.register_node(":streets:trafficlight_top_warn",{ description = "U cheater U", + drop = "", groups = {cracky = 1, not_in_creative_inventory = 1}, paramtype = "light", paramtype2 = "facedir", -- cgit v1.2.3 From b5b9527658e7388bb17091d7269ffdf0ecae66b1 Mon Sep 17 00:00:00 2001 From: webdesigner97 Date: Sun, 24 Nov 2013 13:39:08 +0100 Subject: recipe --- trafficlight/init.lua | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'trafficlight') diff --git a/trafficlight/init.lua b/trafficlight/init.lua index 48d7a62..b3c8835 100644 --- a/trafficlight/init.lua +++ b/trafficlight/init.lua @@ -231,4 +231,13 @@ minetest.register_node(":streets:trafficlight_top_warn",{ }, pointable = false, light_source = 6, +}) + +minetest.register_craft({ + output = "streets:trafficlight_controller", + recipe = { + {"dye:red","",""}, + {"dye:yellow","",""}, + {"dye:green","",""} + } }) \ No newline at end of file -- cgit v1.2.3 From a88b2dcfd60e86205d562b8ba9c402f9345e5ee9 Mon Sep 17 00:00:00 2001 From: webdesigner97 Date: Sun, 24 Nov 2013 19:52:14 +0100 Subject: crafts and inv images --- trafficlight/init.lua | 1 + trafficlight/textures/streets_trafficlight_inv.png | Bin 0 -> 2772 bytes 2 files changed, 1 insertion(+) create mode 100644 trafficlight/textures/streets_trafficlight_inv.png (limited to 'trafficlight') diff --git a/trafficlight/init.lua b/trafficlight/init.lua index b3c8835..68a818e 100644 --- a/trafficlight/init.lua +++ b/trafficlight/init.lua @@ -38,6 +38,7 @@ minetest.register_node(":streets:trafficlight_middle",{ minetest.register_node(":streets:trafficlight_controller",{ description = "Trafficlight", + inventory_image = "streets_trafficlight_inv.png", tiles = {"streets_lampcontroller_top.png","streets_lampcontroller_bottom.png","streets_lampcontroller_sides.png"}, groups = {cracky = 1}, drawtype = "nodebox", diff --git a/trafficlight/textures/streets_trafficlight_inv.png b/trafficlight/textures/streets_trafficlight_inv.png new file mode 100644 index 0000000..fb76b72 Binary files /dev/null and b/trafficlight/textures/streets_trafficlight_inv.png differ -- cgit v1.2.3 From 4fab78d25b26bb9111aa5d5da0511c8395f0c5ca Mon Sep 17 00:00:00 2001 From: webdesigner97 Date: Sun, 24 Nov 2013 20:09:24 +0100 Subject: misc and screenshot --- trafficlight/init.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'trafficlight') diff --git a/trafficlight/init.lua b/trafficlight/init.lua index 68a818e..3eaa43a 100644 --- a/trafficlight/init.lua +++ b/trafficlight/init.lua @@ -54,7 +54,7 @@ minetest.register_node(":streets:trafficlight_controller",{ type = "fixed", fixed = { {-0.5,-0.5,-0.5,0.5,0.5,0.5}, - {-0.5,1.5,-0.5,0.5,4.5,0.5} + {-0.3,1.5,-0.3,0.3,4.5,0.3} } }, on_receive_fields = function(pos, formname, fields, sender) -- cgit v1.2.3