diff options
author | Thomas Rudin <thomas@rudin.io> | 2019-10-09 21:57:28 +0200 |
---|---|---|
committer | Thomas Rudin <thomas@rudin.io> | 2019-10-09 21:57:28 +0200 |
commit | 3839b34a256701b54c9cb9f5a1091e4a257815da (patch) | |
tree | 57734ecfa3e677b55ae463e5a1e5ae078991f926 | |
parent | 3582abf84cf9dd3a1e4a227cb48db2e6bdbb811c (diff) | |
download | mesecons_debug-3839b34a256701b54c9cb9f5a1091e4a257815da.tar.gz mesecons_debug-3839b34a256701b54c9cb9f5a1091e4a257815da.zip |
flush before re-init
Diffstat (limited to '')
-rw-r--r-- | overrides.lua | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/overrides.lua b/overrides.lua index 3af4d22..61fc2aa 100644 --- a/overrides.lua +++ b/overrides.lua @@ -57,6 +57,7 @@ minetest.register_globalstep(function(dtime) if reenable_seconds < 1 then -- re-enable again enabled = true + mesecon.queue.actions = {} end end @@ -75,6 +76,8 @@ minetest.register_chatcommand("mesecons_enable", { description = "enables the mesecons globlastep", privs = {mesecons_debug=true}, func = function() + -- flush actions, while we are on it + mesecon.queue.actions = {} enabled = true return true, "mesecons enabled" end @@ -85,8 +88,6 @@ minetest.register_chatcommand("mesecons_disable", { privs = {mesecons_debug=true}, func = function() enabled = false - -- flush actions, while we are on it - mesecon.queue.actions = {} return true, "mesecons disabled" end }) |