3 minetest
.register_node("mesecons_switch:mesecon_switch_off", {
4 tiles
= {"jeija_mesecon_switch_side.png", "jeija_mesecon_switch_side.png", "jeija_mesecon_switch_side.png", "jeija_mesecon_switch_side.png", "jeija_mesecon_switch_side.png", "jeija_mesecon_switch_off.png"},
6 groups
= {dig_immediate
=2},
8 sounds
= hades_sounds
.node_sound_stone_defaults(),
9 mesecons
= {receptor
= {
10 state
= mesecon
.state
.off
12 on_punch
= function(pos
, node
)
13 minetest
.swap_node(pos
, {name
= "mesecons_switch:mesecon_switch_on", param2
= node
.param2
})
14 mesecon
:receptor_on(pos
)
15 minetest
.sound_play("mesecons_switch", {pos
=pos
}, true)
19 minetest
.register_node("mesecons_switch:mesecon_switch_on", {
20 tiles
= {"jeija_mesecon_switch_side.png", "jeija_mesecon_switch_side.png", "jeija_mesecon_switch_side.png", "jeija_mesecon_switch_side.png", "jeija_mesecon_switch_side.png", "jeija_mesecon_switch_on.png"},
22 groups
= {dig_immediate
=2,not_in_creative_inventory
=1},
23 drop
="mesecons_switch:mesecon_switch_off 1",
24 sounds
= hades_sounds
.node_sound_stone_defaults(),
25 mesecons
= {receptor
= {
26 state
= mesecon
.state
.on
28 on_punch
= function(pos
, node
)
29 minetest
.swap_node(pos
, {name
= "mesecons_switch:mesecon_switch_off", param2
= node
.param2
})
30 mesecon
:receptor_off(pos
)
31 minetest
.sound_play("mesecons_switch", {pos
=pos
}, true)
35 minetest
.register_craft({
36 output
= "mesecons_switch:mesecon_switch_off 2",
38 {"hades_core:steel_ingot", "hades_core:cobble", "hades_core:steel_ingot"},
39 {"group:mesecon_conductor_craftable","", "group:mesecon_conductor_craftable"},