From 87442f0c31dd4d4ae0d31ff9415f29502d5c1975 Mon Sep 17 00:00:00 2001 From: Jeija Date: Thu, 21 Jun 2012 20:33:01 +0200 Subject: Experimental 3D Delayer --- mesecons_delayer/init.lua | 112 +++++++++++++++++++++++++++++++++++++++------- 1 file changed, 96 insertions(+), 16 deletions(-) (limited to 'mesecons_delayer/init.lua') diff --git a/mesecons_delayer/init.lua b/mesecons_delayer/init.lua index 6eb9d7b..1a0da70 100644 --- a/mesecons_delayer/init.lua +++ b/mesecons_delayer/init.lua @@ -1,49 +1,89 @@ minetest.register_node("mesecons_delayer:delayer_off_1", { description = "Delayer", - drawtype = "raillike", + drawtype = "nodebox", tile_images = {"mesecons_delayer_off_1.png"}, inventory_image = "mesecons_delayer_off_1.png", wield_image = "mesecons_delayer_off_1.png", walkable = false, - selection_box = {type = "fixed",}, + selection_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, groups = {bendy=2,snappy=1,dig_immediate=2}, paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + is_ground_content = true, drop = 'mesecons_delayer:delayer_off_1', }) minetest.register_node("mesecons_delayer:delayer_off_2", { description = "Delayer", - drawtype = "raillike", + drawtype = "nodebox", tile_images = {"mesecons_delayer_off_2.png"}, inventory_image = "mesecons_delayer_off_2.png", walkable = false, - selection_box = {type = "fixed",}, + selection_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, groups = {bendy=2,snappy=1,dig_immediate=2}, paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + is_ground_content = true, drop = 'mesecons_delayer:delayer_off_1', }) minetest.register_node("mesecons_delayer:delayer_off_3", { description = "Delayer", - drawtype = "raillike", + drawtype = "nodebox", tile_images = {"mesecons_delayer_off_3.png"}, inventory_image = "mesecons_delayer_off_3.png", walkable = false, - selection_box = {type = "fixed",}, + selection_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, groups = {bendy=2,snappy=1,dig_immediate=2}, paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + is_ground_content = true, drop = 'mesecons_delayer:delayer_off_1', }) minetest.register_node("mesecons_delayer:delayer_off_4", { description = "Delayer", - drawtype = "raillike", + drawtype = "nodebox", tile_images = {"mesecons_delayer_off_4.png"}, inventory_image = "mesecons_delayer_off_4.png", walkable = false, - selection_box = {type = "fixed",}, + selection_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, groups = {bendy=2,snappy=1,dig_immediate=2}, paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + is_ground_content = true, drop = 'mesecons_delayer:delayer_off_1', }) @@ -53,49 +93,89 @@ minetest.register_node("mesecons_delayer:delayer_off_4", { minetest.register_node("mesecons_delayer:delayer_on_1", { description = "Delayer", - drawtype = "raillike", + drawtype = "nodebox", tile_images = {"mesecons_delayer_on_1.png"}, inventory_image = "mesecons_delayer_on_1.png", walkable = false, - selection_box = {type = "fixed",}, + selection_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, groups = {bendy=2,snappy=1,dig_immediate=2}, paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + is_ground_content = true, drop = 'mesecons_delayer:delayer_off_1', }) minetest.register_node("mesecons_delayer:delayer_on_2", { description = "Delayer", - drawtype = "raillike", + drawtype = "nodebox", tile_images = {"mesecons_delayer_on_2.png"}, inventory_image = "mesecons_delayer_on_2.png", walkable = false, - selection_box = {type = "fixed",}, + selection_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, groups = {bendy=2,snappy=1,dig_immediate=2}, paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + is_ground_content = true, drop = 'mesecons_delayer:delayer_off_1', }) minetest.register_node("mesecons_delayer:delayer_on_3", { description = "Delayer", - drawtype = "raillike", + drawtype = "nodebox", tile_images = {"mesecons_delayer_on_3.png"}, inventory_image = "mesecons_delayer_on_3.png", walkable = false, - selection_box = {type = "fixed",}, + selection_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, groups = {bendy=2,snappy=1,dig_immediate=2}, paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + is_ground_content = true, drop = 'mesecons_delayer:delayer_off_1', }) minetest.register_node("mesecons_delayer:delayer_on_4", { description = "Delayer", - drawtype = "raillike", + drawtype = "nodebox", tile_images = {"mesecons_delayer_on_4.png"}, inventory_image = "mesecons_delayer_on_4.png", walkable = false, - selection_box = {type = "fixed",}, + selection_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, + node_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, + }, groups = {bendy=2,snappy=1,dig_immediate=2}, paramtype = "light", + paramtype2 = "facedir", + sunlight_propagates = true, + is_ground_content = true, drop = 'mesecons_delayer:delayer_off_1', }) -- cgit v1.2.3