Use minetest.swap_node() instead of mesecons' version, Minor code changes

here and there to facilitate this.
This commit is contained in:
Vanessa Ezekowitz
2013-11-30 20:20:01 -05:00
parent 669e3d0880
commit f46bc329de
15 changed files with 40 additions and 44 deletions

View File

@ -6,7 +6,7 @@ function mesecon:lightstone_add(name, base_item, texture_off, texture_on)
sounds = default.node_sound_stone_defaults(),
mesecons = {effector = {
action_on = function (pos, node)
mesecon:swap_node(pos, "mesecons_lightstone:lightstone_" .. name .. "_on")
minetest.swap_node(pos, {name = "mesecons_lightstone:lightstone_" .. name .. "_on", param2 = node.param2})
end
}}
})
@ -18,7 +18,7 @@ function mesecon:lightstone_add(name, base_item, texture_off, texture_on)
sounds = default.node_sound_stone_defaults(),
mesecons = {effector = {
action_off = function (pos, node)
mesecon:swap_node(pos, "mesecons_lightstone:lightstone_" .. name .. "_off")
minetest.swap_node(pos, {name = "mesecons_lightstone:lightstone_" .. name .. "_off", param2 = node.param2})
end
}}
})