> see also: https://discord.com/channels/1214952937 ... 5710294087
if a crafting machine finished crafting but lacks the materials to begin progress on the next recipe it will not output a working signal that tick,
this is especially noticeable if a recipe finishes in exactly 1 tick or even quicker, here is an example that uses only official mods, go ahead and place it:
Code: Select all
0eNqNU9tugzAM/Rc/B4lL6QYfsF/YQ4UQF0Ot0YSFQMeq/PsMTKXrijaUl9jHx/Y54QJ502OrSRqIL0CFkh3Ehwt0VMusmWIyOyHEoLEYiwY1CHjvs4bMyMEGa5RlpkewAkiW+AGxZ8WDcmywMJoKByXqenS4IeoqK/Cm0reJAJSGDOEyxXwZU9mfcu4ce+JvOgGt6phByak7szqhAJ7V5T55X1Wo044+mcNzr9808V0rXzxY/J45mJl5YWDdjFZNmuMxG0jpCaExK1OuphbTiiR1RywhNrpHseTOSr+RrNfYD2i6amjGdppkIG1YeriOtiCcl0nDb7L/V72CtY+9ZEMMnhYHqLwxsWsRS+ekyr5BJ5idW4CMkynJgUVUTDAXrredgM5kxdtswkbG28z4m5nAJpbPb/OCddc+Z/Ds2dbD8DdUmB7jmfT8Eg++8EQgvCRZVmbg+t8IGFB3M2+496NdFIXh07O7dyNrvwCykSVP
next grab yourself a stack of iron gears and keep it in your editor inventory,
now open up the recycler and put two iron gears inside of it: now press the "1 tick" (numpad .) button in the editor's time control and notice both signals light up: now do the same thing but only insert one iron gear, notice how the "read working" does not light up at all: now run this command, it'll insert an iron gear for you every tick, notice how now every tick it outputs a "recipe finished" signal, but never a "working" signal:
Code: Select all
/c script.on_event(defines.events.on_tick, function ()
local recyclers = game.surfaces["nauvis"].find_entities_filtered{name = "recycler"}
for _, recycler in ipairs(recyclers) do
recycler.get_inventory(defines.inventory.furnace_source).insert({name = "iron-gear-wheel", count = 1})
end
end)
duplicate? how naughty, well this title seems a little clearer and more discoverable and attention grabbing, feel free to merge them if its _that_ bad to do.