I've made a mod that adds two recipes. The first creates an item; the second destroys it.
Now, if I click the destroying recipe too many times, it uses the first recipe to create new items to be destroyed.
I don't wan that. I want it to only destroy items that are already in player's inventory.
How can I block a recipe from auto-crafting it's ingredients?
How to block auto-crafting ingredients a recipe
How to block auto-crafting ingredients a recipe
I am a translator. And what did you do for Factorio?
Check out my mod "Realistic Ores" and my other mods!
Check out my mod "Realistic Ores" and my other mods!
- Deadlock989
- Smart Inserter
- Posts: 2529
- Joined: Fri Nov 06, 2015 7:41 pm
Re: How to block auto-crafting ingredients a recipe
Setting allow_as_intermediate = false in a recipe stops it from being used as an intermediate step in any other hand-crafted recipe.
Setting allow_intermediates = false in a recipe stops it from searching for intermediates to supply any missing ingredients when hand-crafting.
Setting allow_intermediates = false in a recipe stops it from searching for intermediates to supply any missing ingredients when hand-crafting.
Re: How to block auto-crafting ingredients a recipe
Thanks! This solved my problem.
Although it's a little weird that you have to set allow_as_intermediate to false when allow_intermediates is false.
I don't see any reason for that.
(If any admin reads this: please change the name of the thread to "How to block auto-crafting ingredients of a recipe". I don't think that I can do that by myself at this point.)
Although it's a little weird that you have to set allow_as_intermediate to false when allow_intermediates is false.
I don't see any reason for that.
(If any admin reads this: please change the name of the thread to "How to block auto-crafting ingredients of a recipe". I don't think that I can do that by myself at this point.)
I am a translator. And what did you do for Factorio?
Check out my mod "Realistic Ores" and my other mods!
Check out my mod "Realistic Ores" and my other mods!
- Deadlock989
- Smart Inserter
- Posts: 2529
- Joined: Fri Nov 06, 2015 7:41 pm
Re: How to block auto-crafting ingredients a recipe
I don't think you have to. See the original request thread: viewtopic.php?f=65&t=58848<NO_NAME> wrote:Thanks! This solved my problem.
Although it's a little weird that you have to set allow_as_intermediate to false when allow_intermediates is false.
I don't see any reason for that.
I set them both but only for readability.
Re: How to block auto-crafting ingredients a recipe
Yes, you have to. I tried to set only allow_intermediates but Factorio refused to start. The error message explicitly told that I have to set allow_as_intermediate too.Deadlock989 wrote:I don't think you have to. See the original request thread: viewtopic.php?f=65&t=58848
I set them both but only for readability.
I don't think that this restriction is necessary. I can imagine a recipe that should not auto-craft its ingredients but still can be used by other recipes. There is no contradiction here.
Anyway, I see that allow_intermediates was your idea, so thank you even more

I am a translator. And what did you do for Factorio?
Check out my mod "Realistic Ores" and my other mods!
Check out my mod "Realistic Ores" and my other mods!