diff options
author | Jeija <norrepli@gmail.com> | 2012-12-09 00:42:30 +0100 |
---|---|---|
committer | Jeija <norrepli@gmail.com> | 2012-12-09 00:42:30 +0100 |
commit | b37bdbf55cf6d3205d5dd7a2491a8bd855cbbd76 (patch) | |
tree | ffc05ac9f096fc635535701cd287d4e5ad6b5073 /mesecons_detector | |
parent | cf6080f7237af1c55a6d80bea4725dcb5c8cb1eb (diff) |
Port a lot more (basically everything apart from gates, pistons and extrawire crossing) to the new nodedef system. There are some problems with wall button and wall lever (in the way they visually connect to wires)
Diffstat (limited to 'mesecons_detector')
-rw-r--r-- | mesecons_detector/init.lua | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/mesecons_detector/init.lua b/mesecons_detector/init.lua index 1d5b214..2394e96 100644 --- a/mesecons_detector/init.lua +++ b/mesecons_detector/init.lua @@ -9,8 +9,7 @@ minetest.register_node("mesecons_detector:object_detector_off", { groups = {cracky=3}, description="Player Detector", mesecons = {receptor = { - state = mesecon.state.off, - rules = mesecon.rules.pressurplatelike + state = mesecon.state.off }} }) @@ -21,8 +20,7 @@ minetest.register_node("mesecons_detector:object_detector_on", { groups = {cracky=3,not_in_creative_inventory=1}, drop = 'mesecons_detector:object_detector_off', mesecons = {receptor = { - state = mesecon.state.on, - rules = mesecon.rules.pressurplatelike + state = mesecon.state.on }} }) @@ -50,7 +48,7 @@ minetest.register_abm( end local objpos=obj:getpos() minetest.env:add_node(pos, {name="mesecons_detector:object_detector_on"}) - mesecon:receptor_on(pos, mesecon:get_rules("pressureplate")) + mesecon:receptor_on(pos) end end end, @@ -78,7 +76,7 @@ minetest.register_abm( end if objectfound==0 then minetest.env:add_node(pos, {name="mesecons_detector:object_detector_off"}) - mesecon:receptor_off(pos, mesecon:get_rules("pressureplate")) + mesecon:receptor_off(pos) end end, }) |