diff options
author | Jeija <jeija@mesecons.net> | 2014-11-22 22:09:26 +0100 |
---|---|---|
committer | Jeija <jeija@mesecons.net> | 2014-11-22 22:09:26 +0100 |
commit | f977ac821aa2f6c7053ec7f65d289c57de1e91a8 (patch) | |
tree | 2d025fd6483e1ac3e4c409a356d2015aada00778 /mesecons_pressureplates/init.lua | |
parent | 80d136125ef8f17af85d0045800d5e761ace3229 (diff) |
Re-implement settings system:
Settings can now be retrieved by mesecon.setting(<name>, <default>) and can be modified without
editing the source code by adding the setting to minetest.conf
For instance, you can add mesecon.blinky_plant_interval = 0.5 to minetest.conf in order to
increase the blinking speed.
Rewrite the blinky plant with nodetimers.
Fixes #161
Diffstat (limited to 'mesecons_pressureplates/init.lua')
-rw-r--r-- | mesecons_pressureplates/init.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mesecons_pressureplates/init.lua b/mesecons_pressureplates/init.lua index e9fdf7f..d01e6e5 100644 --- a/mesecons_pressureplates/init.lua +++ b/mesecons_pressureplates/init.lua @@ -59,7 +59,7 @@ function mesecon.register_pressure_plate(basename, description, textures_off, te pressureplate_basename = basename, on_timer = pp_on_timer, on_construct = function(pos) - minetest.get_node_timer(pos):start(PRESSURE_PLATE_INTERVAL) + minetest.get_node_timer(pos):start(mesecon.setting("pplate_interval", 0.1)) end, },{ mesecons = {receptor = { state = mesecon.state.off, rules = mesecon.rules.pplate }}, |