improve settingtypes and get settings only on load

This commit is contained in:
DS-Minetest
2018-01-02 17:42:08 +01:00
parent 309056e2c8
commit b599d17ecd
5 changed files with 35 additions and 24 deletions

View File

@ -1,11 +1,13 @@
-- The BLINKY_PLANT
local blinky_plant_interval = mesecon.setting("blinky_plant_interval", 3)
local toggle_timer = function (pos)
local timer = minetest.get_node_timer(pos)
if timer:is_started() then
timer:stop()
else
timer:start(mesecon.setting("blinky_plant_interval", 3))
timer:start(blinky_plant_interval)
end
end