Page 1 of 1

A Needed Stack Size Option For Inserters With Filters Set

Posted: Mon Sep 08, 2025 6:05 pm
by KeithFromCanada
TL;DR
Add the 'Each' signal to 'Set Stack Size' for inserters to use the count of the first item in the filters list or, if there are signal(s) matching the item(s) available for pickup, use the signal count of whatever item is going to be picked up.

What?
I have a defences resupply train. To avoid having to add and maintain filters to the cargo wagon, I multiply its contents by -1, add them to the signals from a constant combinator that sets the desired amount, then feed that through a selection combinator to choose the highest need, and finally feed that to the inserters loading the cargo wagon. This works great, except I have to either have a second set of inserters that remove any excess, set the stack size to 1, or have one inserter for each item* to avoid creeping excess filling up the wagon.

*(Setting stack size to the (single) item type being transferred will insert the maximum amount until the desired quantity drops below that, whereupon the stack size will be automatically set to the exact number needed to fulfill the request. It's a nifty trick and I wish I could remember who I snagged it from.)

If the 'Set stack size' option allowed for the 'Each' signal to be set--which uses the count of the item in the first slot of the filters list--then the handy trick mentioned above could be used with an arbitrary item list to ensure that only the exact amount of a requested item will be inserted.

Factorio Set Stack Size Idea.png
Factorio Set Stack Size Idea.png (116.9 KiB) Viewed 121 times
(In this image, the current ammo count is 191 out of 200, so the stack size is automatically set to 9 to deliver exactly the amount required.)

Why?
It will allow delivering exactly as much of an arbitrary item as necessary without requiring a lot of messy circuits/etc. on the player's part.

Re: A Needed Stack Size Option For Inserters With Filters Set

Posted: Mon Sep 08, 2025 8:04 pm
by KillingTimeItself
this would admittedly be a pretty nice QOL change for us using a circuit enabled mixed loading setup. Currently you need two additional combinators to make this work nicely, one for setting the stack size, and one for delaying the filter timing so it's actually functional. Though its not like this is a huge technical limitation, just sort of arbitrary.

But i assume there's a reason the devs didn't implement it so who knows why.