2022-02-12 20:12:12 +01:00
|
|
|
local crossover_rules = {
|
|
|
|
{--first wire
|
|
|
|
{x=-1,y=0,z=0},
|
|
|
|
{x=1,y=0,z=0},
|
|
|
|
},
|
|
|
|
{--second wire
|
|
|
|
{x=0,y=0,z=-1},
|
|
|
|
{x=0,y=0,z=1},
|
|
|
|
},
|
|
|
|
}
|
2013-06-20 04:38:34 +02:00
|
|
|
|
|
|
|
local crossover_states = {
|
|
|
|
"mesecons_extrawires:crossover_off",
|
|
|
|
"mesecons_extrawires:crossover_01",
|
|
|
|
"mesecons_extrawires:crossover_10",
|
|
|
|
"mesecons_extrawires:crossover_on",
|
|
|
|
}
|
|
|
|
|
|
|
|
minetest.register_node("mesecons_extrawires:crossover_off", {
|
2017-01-22 13:39:10 +01:00
|
|
|
description = "Insulated Mesecon Crossover",
|
2017-01-01 17:58:21 +01:00
|
|
|
drawtype = "mesh",
|
|
|
|
mesh = "mesecons_extrawires_crossover.b3d",
|
2013-08-28 07:26:00 +02:00
|
|
|
tiles = {
|
2017-01-01 17:58:21 +01:00
|
|
|
"jeija_insulated_wire_ends_off.png",
|
|
|
|
"jeija_insulated_wire_sides_off.png",
|
|
|
|
"jeija_insulated_wire_sides_off.png",
|
2013-08-28 07:26:00 +02:00
|
|
|
"jeija_insulated_wire_ends_off.png"
|
|
|
|
},
|
2013-06-20 04:38:34 +02:00
|
|
|
paramtype = "light",
|
2017-10-31 22:50:39 +01:00
|
|
|
is_ground_content = false,
|
2013-06-20 04:38:34 +02:00
|
|
|
walkable = false,
|
|
|
|
stack_max = 99,
|
2018-08-26 23:17:35 +02:00
|
|
|
selection_box = {type="fixed", fixed={-16/32, -16/32, -16/32, 16/32, -5/32, 16/32}},
|
2015-02-13 23:02:09 +01:00
|
|
|
groups = {dig_immediate=3, mesecon=3},
|
2022-05-05 16:57:53 +02:00
|
|
|
sounds = mesecon.node_sound.default,
|
2013-06-20 04:38:34 +02:00
|
|
|
mesecons = {
|
|
|
|
conductor = {
|
|
|
|
states = crossover_states,
|
2022-02-12 20:12:12 +01:00
|
|
|
rules = crossover_rules,
|
2013-06-20 04:38:34 +02:00
|
|
|
}
|
|
|
|
},
|
2017-10-07 00:44:49 +02:00
|
|
|
on_blast = mesecon.on_blastnode,
|
2013-06-20 04:38:34 +02:00
|
|
|
})
|
|
|
|
|
|
|
|
minetest.register_node("mesecons_extrawires:crossover_01", {
|
|
|
|
description = "You hacker you!",
|
|
|
|
drop = "mesecons_extrawires:crossover_off",
|
2017-01-01 17:58:21 +01:00
|
|
|
drawtype = "mesh",
|
|
|
|
mesh = "mesecons_extrawires_crossover.b3d",
|
2013-08-28 07:26:00 +02:00
|
|
|
tiles = {
|
2017-01-01 17:58:21 +01:00
|
|
|
"jeija_insulated_wire_ends_on.png",
|
|
|
|
"jeija_insulated_wire_sides_on.png",
|
|
|
|
"jeija_insulated_wire_sides_off.png",
|
|
|
|
"jeija_insulated_wire_ends_off.png"
|
2013-08-28 07:26:00 +02:00
|
|
|
},
|
2013-06-20 04:38:34 +02:00
|
|
|
paramtype = "light",
|
2017-10-31 22:50:39 +01:00
|
|
|
is_ground_content = false,
|
2013-06-20 04:38:34 +02:00
|
|
|
walkable = false,
|
|
|
|
stack_max = 99,
|
2018-08-26 23:17:35 +02:00
|
|
|
selection_box = {type="fixed", fixed={-16/32, -16/32, -16/32, 16/32, -5/32, 16/32}},
|
2014-05-01 19:42:19 +02:00
|
|
|
groups = {dig_immediate=3, mesecon=3, not_in_creative_inventory=1},
|
2022-05-05 16:57:53 +02:00
|
|
|
sounds = mesecon.node_sound.default,
|
2013-06-20 04:38:34 +02:00
|
|
|
mesecons = {
|
|
|
|
conductor = {
|
|
|
|
states = crossover_states,
|
2022-02-12 20:12:12 +01:00
|
|
|
rules = crossover_rules,
|
2013-06-20 04:38:34 +02:00
|
|
|
}
|
|
|
|
},
|
2017-10-07 00:44:49 +02:00
|
|
|
on_blast = mesecon.on_blastnode,
|
2013-06-20 04:38:34 +02:00
|
|
|
})
|
|
|
|
|
|
|
|
minetest.register_node("mesecons_extrawires:crossover_10", {
|
|
|
|
description = "You hacker you!",
|
|
|
|
drop = "mesecons_extrawires:crossover_off",
|
2017-01-01 17:58:21 +01:00
|
|
|
drawtype = "mesh",
|
|
|
|
mesh = "mesecons_extrawires_crossover.b3d",
|
2013-08-28 07:26:00 +02:00
|
|
|
tiles = {
|
2017-01-01 17:58:21 +01:00
|
|
|
"jeija_insulated_wire_ends_off.png",
|
|
|
|
"jeija_insulated_wire_sides_off.png",
|
|
|
|
"jeija_insulated_wire_sides_on.png",
|
|
|
|
"jeija_insulated_wire_ends_on.png"
|
2013-08-28 07:26:00 +02:00
|
|
|
},
|
2013-06-20 04:38:34 +02:00
|
|
|
paramtype = "light",
|
2017-10-31 22:50:39 +01:00
|
|
|
is_ground_content = false,
|
2013-06-20 04:38:34 +02:00
|
|
|
walkable = false,
|
|
|
|
stack_max = 99,
|
2018-08-26 23:17:35 +02:00
|
|
|
selection_box = {type="fixed", fixed={-16/32, -16/32, -16/32, 16/32, -5/32, 16/32}},
|
2014-05-01 19:42:19 +02:00
|
|
|
groups = {dig_immediate=3, mesecon=3, not_in_creative_inventory=1},
|
2022-05-05 16:57:53 +02:00
|
|
|
sounds = mesecon.node_sound.default,
|
2013-06-20 04:38:34 +02:00
|
|
|
mesecons = {
|
|
|
|
conductor = {
|
|
|
|
states = crossover_states,
|
2022-02-12 20:12:12 +01:00
|
|
|
rules = crossover_rules,
|
2013-06-20 04:38:34 +02:00
|
|
|
}
|
|
|
|
},
|
2017-10-07 00:44:49 +02:00
|
|
|
on_blast = mesecon.on_blastnode,
|
2013-06-20 04:38:34 +02:00
|
|
|
})
|
|
|
|
|
|
|
|
minetest.register_node("mesecons_extrawires:crossover_on", {
|
|
|
|
description = "You hacker you!",
|
|
|
|
drop = "mesecons_extrawires:crossover_off",
|
2017-01-01 17:58:21 +01:00
|
|
|
drawtype = "mesh",
|
|
|
|
mesh = "mesecons_extrawires_crossover.b3d",
|
2013-08-28 07:26:00 +02:00
|
|
|
tiles = {
|
|
|
|
"jeija_insulated_wire_ends_on.png",
|
2017-01-01 17:58:21 +01:00
|
|
|
"jeija_insulated_wire_sides_on.png",
|
|
|
|
"jeija_insulated_wire_sides_on.png",
|
2013-08-28 07:26:00 +02:00
|
|
|
"jeija_insulated_wire_ends_on.png"
|
|
|
|
},
|
2013-06-20 04:38:34 +02:00
|
|
|
paramtype = "light",
|
2017-10-31 22:50:39 +01:00
|
|
|
is_ground_content = false,
|
2013-06-20 04:38:34 +02:00
|
|
|
walkable = false,
|
|
|
|
stack_max = 99,
|
2018-08-26 23:17:35 +02:00
|
|
|
selection_box = {type="fixed", fixed={-16/32, -16/32, -16/32, 16/32, -5/32, 16/32}},
|
2014-05-01 19:42:19 +02:00
|
|
|
groups = {dig_immediate=3, mesecon=3, not_in_creative_inventory=1},
|
2022-05-05 16:57:53 +02:00
|
|
|
sounds = mesecon.node_sound.default,
|
2013-06-20 04:38:34 +02:00
|
|
|
mesecons = {
|
|
|
|
conductor = {
|
|
|
|
states = crossover_states,
|
2022-02-12 20:12:12 +01:00
|
|
|
rules = crossover_rules,
|
2013-06-20 04:38:34 +02:00
|
|
|
}
|
|
|
|
},
|
2017-10-07 00:44:49 +02:00
|
|
|
on_blast = mesecon.on_blastnode,
|
2013-06-20 04:38:34 +02:00
|
|
|
})
|
|
|
|
|
|
|
|
minetest.register_craft({
|
|
|
|
type = "shapeless",
|
|
|
|
output = "mesecons_extrawires:crossover_off",
|
|
|
|
recipe = {
|
|
|
|
"mesecons_insulated:insulated_off",
|
|
|
|
"mesecons_insulated:insulated_off",
|
|
|
|
},
|
|
|
|
})
|
|
|
|
|
|
|
|
minetest.register_craft({
|
|
|
|
type = "shapeless",
|
|
|
|
output = "mesecons_insulated:insulated_off 2",
|
|
|
|
recipe = {
|
|
|
|
"mesecons_extrawires:crossover_off",
|
|
|
|
},
|
|
|
|
})
|