The lower limit of 2 makes sense. But how do you arrive at the upper limit of 100?Twinsen wrote:I didn't read through all this, but I changed how the maximum number of ingredients is calculated. Most of the cases of stack inserters waiting seemingly for no reason should be fixed since machines will accept more ingredients now.
For anyone interested here is the exact formula I used:This will be in 0.16 unless some major flaws are found.Code: Select all
//1.166 is a magic number representing the maximum number of seconds it takes for a base game inserter to do one cycle. //the calculated overload multiplier is the number of crafts we can complete during one inserter full swing + 1 return Math::clamp(uint32_t(std::ceil(1.166 / (recipeCraftingTime / craftingMachineCraftingSpeed))) + 1, 2, 100);
[0.15.23] inserter waits too long
Moderator: ickputzdirwech
Re: [0.15.23] inserter waits too long
Re: [0.15.23] inserter waits too long
Just something to avoid ridiculous numbers for very short recipes and/or very fast assembling machines.
- featherwinglove
- Filter Inserter
- Posts: 579
- Joined: Sat Jun 25, 2016 6:14 am
- Contact:
Re: [0.15.23] inserter waits too long
...but that'll reintroduce the bug!Twinsen wrote:Just something to avoid ridiculous numbers for very short recipes and/or very fast assembling machines.
Re: [0.15.23] inserter waits too long
If you're doing more than 100 recipes a second you'd need to be using a very fast assembler and 2.5 blue belts of items input and output, you would be using more than one inserted for each
My Mod ideas - https://forums.factorio.com/forum/vie ... 49#p107558
Re: [0.15.23] inserter waits too long
I'm pretty sure the devs have said that any assembler is limited to only complete one recipe per game update (so 60 per second). To even get close to that you probably need either a heavily modded game, or a mod that adds ridiculously short recipes. For the both situations you can use something like https://mods.factorio.com/mods/darkfrei/5xProduction. For the second case you can also get the recipes fixed to not be ridiculously fast and/or just live with it. (After all if the recipe is ridiculously fast, you really don't need lots of speed module beacons as well).
- Deadly-Bagel
- Smart Inserter
- Posts: 1498
- Joined: Wed Jul 13, 2016 10:12 am
- Contact:
Re: [0.15.23] inserter waits too long
An unforseen consequence may be found where very high-cost items have strangely low build-times. Take a Locomotive for example, 20 Engines and 30 Steel is quite a lot of resource but 0.5s is barely any time to put it all together. If installed in an Assembly Machine 2 it will request 4x the recipe, a whopping EIGHTY Electric Engines and 120 Steel, and I assume it will insist on filling all of one before proceeding to the next as it currently does? Even 40 engines is quite a hefty cost just to start assembly, but 80?
With this change should come a review of the build time of similar expensive recipes.
With this change should come a review of the build time of similar expensive recipes.
Money might be the root of all evil, but ignorance is the heart.
Re: [0.15.23] inserter waits too long
I hope those 0.5 recipes are placeholders. A locomotive should take a while to assemble.Deadly-Bagel wrote:With this change should come a review of the build time of similar expensive recipes.
Even the recipes where 0.5 makes sense, like iron sticks or copper cable, should have time and counts multiplied by 5 to give reasonable response times and possible also slightly reduce ups.
My Mods: mods.factorio.com
Re: [0.15.23] inserter waits too long
Yay fixes!
Now my other pet peeve with inserters, deadlock...
This deadlock already exists for targeting chests. If an inserter is targeting a full chest it will still try to pick up items from a belt, then hold them over the chest until a spot opens up. This also applies to railcars. The issue on railcars is you can lock slots in them. If you have several types of items going into the car the inserters can deadlock on one type of item and then get completely stuck.
Now my other pet peeve with inserters, deadlock...
mrvn wrote:And then the inserter picks up 12 iron ore to insert into the furnace and the furnace runs out of fuel. Now the inserter is stuck trying to deposit the iron ore and can't pick up some more coal or wood and you have a deadlock.Notxarb wrote:See, what the devs should do is make it so that inserters pick up a full hand of items first, bring it over to the machine, and then decide whether to deposit the items or not. That way, the items are immediately available once the machine goes below <2x the amount of items required, and while it uses those the inserter can go and get another hand ready.
This deadlock already exists for targeting chests. If an inserter is targeting a full chest it will still try to pick up items from a belt, then hold them over the chest until a spot opens up. This also applies to railcars. The issue on railcars is you can lock slots in them. If you have several types of items going into the car the inserters can deadlock on one type of item and then get completely stuck.
- Deadly-Bagel
- Smart Inserter
- Posts: 1498
- Joined: Wed Jul 13, 2016 10:12 am
- Contact:
Re: [0.15.23] inserter waits too long
Where you need exact quantities of items in a chest you can now use the circuit network, with trains too to some degree (only becomes an issue when carriage counts conflict with each other).
Money might be the root of all evil, but ignorance is the heart.
Re: [0.15.23] inserter waits too long
Actually, upon reflection, if you use long-handed inserters, then an assembly machine has no less than 24 entry/exit points, because each edge where you can insert or remove something can be serviced by two long-handed inserters.Kyralessa wrote: ↑Mon Sep 11, 2017 7:43 pmSpeaking as a programmer, I know some of us find the word bug too whimsical and use the word defect instead, as it has a more uncompromising sound to it.
So is this a defect in the game?
No, it isn't.
The developers intended for things to go at certain speeds. If something in your factory isn't keeping up, it's not a defect in the game. It's a defect in your factory design. You need to find a different design that can keep up.
An assembly machine of any variety has no less than 12 entry/exit points. Why would you think you're only allowed to use one per ingredient?
Re: [0.15.23] inserter waits too long
As I recently experienced that deadlock already happens in assemblers. In Industrial Revolution a refinery needs a lot of ingredeiences. More than a stacks worth. That causes the assembler to only accept exactly 2x the recipe in items. That leaves the inserter picking up items because the assembler is below 2x the recipe but unable to insert them all because the hand contents exceed 2x the recipe.Cribbit wrote: ↑Tue Oct 17, 2017 6:03 pmYay fixes!
Now my other pet peeve with inserters, deadlock...
mrvn wrote:And then the inserter picks up 12 iron ore to insert into the furnace and the furnace runs out of fuel. Now the inserter is stuck trying to deposit the iron ore and can't pick up some more coal or wood and you have a deadlock.Notxarb wrote:See, what the devs should do is make it so that inserters pick up a full hand of items first, bring it over to the machine, and then decide whether to deposit the items or not. That way, the items are immediately available once the machine goes below <2x the amount of items required, and while it uses those the inserter can go and get another hand ready.
This deadlock already exists for targeting chests. If an inserter is targeting a full chest it will still try to pick up items from a belt, then hold them over the chest until a spot opens up. This also applies to railcars. The issue on railcars is you can lock slots in them. If you have several types of items going into the car the inserters can deadlock on one type of item and then get completely stuck.
Re: [0.15.23] inserter waits too long
That shouldn't cause any actual problems if you limit each inserter to only loading one ingredient.mrvn wrote: ↑Thu Nov 07, 2019 1:25 pmAs I recently experienced that deadlock already happens in assemblers. In Industrial Revolution a refinery needs a lot of ingredeiences. More than a stacks worth. That causes the assembler to only accept exactly 2x the recipe in items. That leaves the inserter picking up items because the assembler is below 2x the recipe but unable to insert them all because the hand contents exceed 2x the recipe.Cribbit wrote: ↑Tue Oct 17, 2017 6:03 pmYay fixes!
Now my other pet peeve with inserters, deadlock...
mrvn wrote:And then the inserter picks up 12 iron ore to insert into the furnace and the furnace runs out of fuel. Now the inserter is stuck trying to deposit the iron ore and can't pick up some more coal or wood and you have a deadlock.Notxarb wrote:See, what the devs should do is make it so that inserters pick up a full hand of items first, bring it over to the machine, and then decide whether to deposit the items or not. That way, the items are immediately available once the machine goes below <2x the amount of items required, and while it uses those the inserter can go and get another hand ready.
This deadlock already exists for targeting chests. If an inserter is targeting a full chest it will still try to pick up items from a belt, then hold them over the chest until a spot opens up. This also applies to railcars. The issue on railcars is you can lock slots in them. If you have several types of items going into the car the inserters can deadlock on one type of item and then get completely stuck.
Re: [0.15.23] inserter waits too long
Unless you have a requester chest requesting all items needed with one inserter feeding the assembler. Why shjould you need more?Zavian wrote: ↑Tue Nov 12, 2019 9:59 amThat shouldn't cause any actual problems if you limit each inserter to only loading one ingredient.mrvn wrote: ↑Thu Nov 07, 2019 1:25 pmAs I recently experienced that deadlock already happens in assemblers. In Industrial Revolution a refinery needs a lot of ingredeiences. More than a stacks worth. That causes the assembler to only accept exactly 2x the recipe in items. That leaves the inserter picking up items because the assembler is below 2x the recipe but unable to insert them all because the hand contents exceed 2x the recipe.
Re: [0.15.23] inserter waits too long
Phrased another way. If you don't want your factory to be able to deadlock in that situation then design your factory to avoid the deadlock. The same thing can happen with train loading as well. All the same solutions should work. (The other common alternative is to limit inserter stack size to 1).mrvn wrote: ↑Thu Nov 14, 2019 10:08 amUnless you have a requester chest requesting all items needed with one inserter feeding the assembler. Why shjould you need more?Zavian wrote: ↑Tue Nov 12, 2019 9:59 amThat shouldn't cause any actual problems if you limit each inserter to only loading one ingredient.mrvn wrote: ↑Thu Nov 07, 2019 1:25 pmAs I recently experienced that deadlock already happens in assemblers. In Industrial Revolution a refinery needs a lot of ingredeiences. More than a stacks worth. That causes the assembler to only accept exactly 2x the recipe in items. That leaves the inserter picking up items because the assembler is below 2x the recipe but unable to insert them all because the hand contents exceed 2x the recipe.
Re: [0.15.23] inserter waits too long
Oh yeah, won't that be fun for something needing 400 concrete. 12 times as long to load.Zavian wrote: ↑Thu Nov 14, 2019 11:01 amPhrased another way. If you don't want your factory to be able to deadlock in that situation then design your factory to avoid the deadlock. The same thing can happen with train loading as well. All the same solutions should work. (The other common alternative is to limit inserter stack size to 1).mrvn wrote: ↑Thu Nov 14, 2019 10:08 amUnless you have a requester chest requesting all items needed with one inserter feeding the assembler. Why shjould you need more?Zavian wrote: ↑Tue Nov 12, 2019 9:59 amThat shouldn't cause any actual problems if you limit each inserter to only loading one ingredient.mrvn wrote: ↑Thu Nov 07, 2019 1:25 pmAs I recently experienced that deadlock already happens in assemblers. In Industrial Revolution a refinery needs a lot of ingredeiences. More than a stacks worth. That causes the assembler to only accept exactly 2x the recipe in items. That leaves the inserter picking up items because the assembler is below 2x the recipe but unable to insert them all because the hand contents exceed 2x the recipe.
I would rather see the devs fix the formula for how much items an assembler will accept to be N*reciep + inserter bonus.