2012-12-08 22:28:46 +01:00
|
|
|
-- CODE NOT ACTIVE
|
|
|
|
|
2012-12-15 23:53:03 +01:00
|
|
|
local crossing_get_rules = function(node)
|
|
|
|
--TODO: calculate the real port states and use rules to link to them only if
|
2012-09-09 13:34:21 +02:00
|
|
|
end
|
|
|
|
|
2012-12-15 23:53:03 +01:00
|
|
|
minetest.register_node("mesecons_extrawires:crossing_on", {
|
|
|
|
drawtype = "nodebox",
|
2012-12-22 02:24:43 +01:00
|
|
|
tiles = {"jeija_insulated_wire_sides_on.png"},
|
2012-12-15 23:53:03 +01:00
|
|
|
paramtype = "light",
|
|
|
|
walkable = false,
|
|
|
|
stack_max = 99,
|
|
|
|
selection_box = {type="fixed", fixed={-16/32-0.0001, -18/32, -16/32-0.001, 16/32+0.001, -5/32, 16/32+0.001}},
|
|
|
|
node_box = {
|
|
|
|
type = "fixed",
|
|
|
|
fixed = {
|
|
|
|
{ -16/32-0.001, -17/32, -3/32, 16/32+0.001, -13/32, 3/32 },
|
|
|
|
{ -3/32, -17/32, -16/32-0.001, 3/32, -13/32, -6/32 },
|
|
|
|
{ -3/32, -13/32, -9/32, 3/32, -6/32, -6/32 },
|
|
|
|
{ -3/32, -9/32, -9/32, 3/32, -6/32, 9/32 },
|
|
|
|
{ -3/32, -13/32, 6/32, 3/32, -6/32, 9/32 },
|
|
|
|
{ -3/32, -17/32, 6/32, 3/32, -13/32, 16/32+0.001 },
|
|
|
|
},
|
|
|
|
},
|
|
|
|
groups = {dig_immediate=3, mesecon=3, mesecon_conductor_craftable=1, not_in_creative_inventory=1},
|
|
|
|
mesecons = {
|
|
|
|
receptor = {
|
|
|
|
state = mesecon.state.on,
|
|
|
|
rules = crossing_get_rules,
|
|
|
|
}
|
|
|
|
},
|
|
|
|
})
|
2012-09-09 13:34:21 +02:00
|
|
|
|
|
|
|
minetest.register_craft({
|
|
|
|
type = "shapeless",
|
|
|
|
output = "mesecons_extrawires:crossing",
|
|
|
|
recipe = {
|
|
|
|
"mesecons_insulated:insulated_off",
|
|
|
|
"mesecons_insulated:insulated_off",
|
|
|
|
},
|
|
|
|
})
|
|
|
|
|
|
|
|
minetest.register_craft({
|
|
|
|
type = "shapeless",
|
|
|
|
output = "mesecons_insulated:insulated_off 2",
|
|
|
|
recipe = {
|
|
|
|
"mesecons_extrawires:crossing",
|
|
|
|
},
|
|
|
|
})
|