Wall levers are now made of nodeboxes.

This commit is contained in:
Vanessa Ezekowitz 2012-08-07 07:12:49 -04:00
parent 43ca443510
commit b89a77fac6
8 changed files with 51 additions and 14 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 540 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 520 B

After

Width:  |  Height:  |  Size: 533 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 552 B

After

Width:  |  Height:  |  Size: 556 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 480 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 482 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 377 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 404 B

View File

@ -1,33 +1,70 @@
-- WALL LEVER -- WALL LEVER
minetest.register_node("mesecons_walllever:wall_lever_off", { minetest.register_node("mesecons_walllever:wall_lever_off", {
drawtype = "signlike", drawtype = "nodebox",
tile_images = {"jeija_wall_lever_off.png"}, tiles = {
"jeija_wall_lever_tb_off.png",
"jeija_wall_lever_tb_off.png",
"jeija_wall_lever_sides_off.png",
"jeija_wall_lever_sides_off.png",
"jeija_wall_lever_back.png",
"jeija_wall_lever_off.png"
},
inventory_image = "jeija_wall_lever_off.png", inventory_image = "jeija_wall_lever_off.png",
wield_image = "jeija_wall_lever_off.png", wield_image = "jeija_wall_lever_off.png",
paramtype = "light", paramtype = "light",
paramtype2 = "wallmounted",
legacy_wallmounted = true,
walkable = false, walkable = false,
selection_box = {
type = "wallmounted",
},
groups = {dig_immediate=2}, groups = {dig_immediate=2},
description="Lever", description="Lever",
selection_box = {
type = "fixed",
fixed = { -6/16, -8/16, 11/32, 6/16, 8/16, 8/16 },
},
node_box = {
type = "fixed",
fixed = {
{ -6/16, -6/16, 7/16, 6/16, 6/16, 8/16 },
{ -5/16, -3/16, 13/32, 5/16, 3/16, 7/16 },
{ -4/16, -2/16, 12/32, 4/16, 2/16, 13/32 },
{ -2/16, -1/16, 11/32, 2/16, 1/16, 12/32 },
{ -1/16, -8/16, 13/32, 1/16, -3/16, 7/16 },
{ -1/16, -8/16, 12/32, 1/16, -2/16, 13/32 },
{ -1/16, -8/16, 11/32, 1/16, -1/16, 12/32 },
},
},
}) })
minetest.register_node("mesecons_walllever:wall_lever_on", { minetest.register_node("mesecons_walllever:wall_lever_on", {
drawtype = "signlike", drawtype = "nodebox",
tile_images = {"jeija_wall_lever_on.png"}, tiles = {
"jeija_wall_lever_tb_on.png",
"jeija_wall_lever_tb_on.png",
"jeija_wall_lever_sides_on.png",
"jeija_wall_lever_sides_on.png",
"jeija_wall_lever_back.png",
"jeija_wall_lever_on.png"
},
inventory_image = "jeija_wall_lever_on.png", inventory_image = "jeija_wall_lever_on.png",
paramtype = "light", paramtype = "light",
paramtype2 = "wallmounted",
legacy_wallmounted = true,
walkable = false, walkable = false,
selection_box = {
type = "wallmounted",
},
groups = {dig_immediate=2,not_in_creative_inventory=1}, groups = {dig_immediate=2,not_in_creative_inventory=1},
drop = '"mesecons_walllever:wall_lever_off" 1', drop = '"mesecons_walllever:wall_lever_off" 1',
description="Lever", description="Lever",
selection_box = {
type = "fixed",
fixed = { -6/16, -8/16, 11/32, 6/16, 8/16, 8/16 },
},
node_box = {
type = "fixed",
fixed = {
{ -6/16, -6/16, 7/16, 6/16, 6/16, 8/16 },
{ -5/16, -3/16, 13/32, 5/16, 3/16, 7/16 },
{ -4/16, -2/16, 12/32, 4/16, 2/16, 13/32 },
{ -2/16, -1/16, 11/32, 2/16, 1/16, 12/32 },
{ -1/16, 3/16, 13/32, 1/16, 8/16, 7/16 },
{ -1/16, 2/16, 12/32, 1/16, 8/16, 13/32 },
{ -1/16, 1/16, 11/32, 1/16, 8/16, 12/32 },
},
},
after_dig_node = function(pos, oldnode) after_dig_node = function(pos, oldnode)
mesecon:receptor_off(pos, mesecon.button_get_rules(oldnode.param2)) mesecon:receptor_off(pos, mesecon.button_get_rules(oldnode.param2))
end end