From c1542a48d104aa81995bdadbbba115c6081818b0 Mon Sep 17 00:00:00 2001 From: Joachim Stolberg Date: Tue, 26 Oct 2021 21:58:28 +0200 Subject: [PATCH] Fix sequencer bugs --- basis/laser_lib.lua | 2 +- logic/collector.lua | 2 +- logic/sequencer.lua | 3 +++ logic/sequencer2.lua | 4 ++-- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/basis/laser_lib.lua b/basis/laser_lib.lua index 9df03cb..802b3c3 100644 --- a/basis/laser_lib.lua +++ b/basis/laser_lib.lua @@ -102,7 +102,7 @@ for _, size in ipairs(SIZES) do physical = false, collide_with_objects = false, pointable = false, - static_save = true, + static_save = false, visual_size = {x = size, y = 0.05, z = 0.05}, glow = 14, shaded = true, diff --git a/logic/collector.lua b/logic/collector.lua index e03e391..414b491 100644 --- a/logic/collector.lua +++ b/logic/collector.lua @@ -86,8 +86,8 @@ local function on_timer(pos,elapsed) if nvm.idx > #nvm.poll_numbers then nvm.idx = 1 - send_event(nvm, meta) if nvm.stored_state ~= nvm.common_state then + send_event(nvm, meta) local own_number = meta:get_string("own_number") meta:set_string("infotext", S("TA4 State Collector").." "..own_number..': "'..lStates[nvm.common_state]..'"') nvm.stored_state = nvm.common_state diff --git a/logic/sequencer.lua b/logic/sequencer.lua index 42b887d..2784c11 100644 --- a/logic/sequencer.lua +++ b/logic/sequencer.lua @@ -114,6 +114,9 @@ local function check_rules(pos, elapsed) nvm.index = get_next_slot(nvm.index, nvm.rules, nvm.endless) if nvm.index ~= nil and offs ~= nil and nvm.running then -- after the last rule a pause with 1 or more sec is required + if nvm.index == 1 and offs < 1 then + offs = 1 + end if offs > 0 then -- we can't restart the timer within the function om_timer minetest.after(0, restart_timer, pos, offs) diff --git a/logic/sequencer2.lua b/logic/sequencer2.lua index 6c281b9..c21b538 100644 --- a/logic/sequencer2.lua +++ b/logic/sequencer2.lua @@ -270,8 +270,8 @@ minetest.register_craft({ output = "techage:ta4_sequencer", recipe = { {"default:steel_ingot", "dye:blue", "default:steel_ingot"}, - {"techage:ta4_ramchip", "default:mese_crystal", "techage:wlanchip"}, - {"techage:aluminum", "group:wood","techage:aluminum"}, + {"techage:ta4_ramchip", "default:mese_crystal", "techage:ta4_wlanchip"}, + {"techage:aluminum", "group:wood", "techage:aluminum"}, }, })