"allow_as_intermediate_only_when_no_alternatives" recipeflag
"allow_as_intermediate_only_when_no_alternatives" recipeflag
Basically a variant of "allow_as_intermediate", but which only deprioritizes the recipe for intermediate crafting, rather than making in not usable entirely. So a white-belt-to-yellow-belt recipe might be still able to be used to craft red belts, but only if there are no ingredients with which to craft yellow belts the "normal" way.

Re: "allow_as_intermediate_only_when_no_alternatives" recipeflag
With default value:Reika wrote:Basically a variant of "allow_as_intermediate", but which only deprioritizes the recipe for intermediate crafting, rather than making in not usable entirely. So a white-belt-to-yellow-belt recipe might be still able to be used to craft red belts, but only if there are no ingredients with which to craft yellow belts the "normal" way.
item.manual_intermediate_priority = 5
Re: "allow_as_intermediate_only_when_no_alternatives" recipeflag
The way the crafting system works this isn't possible and re-working it to be possible isn't something i think is worth it.
If you want to get ahold of me I'm almost always on Discord.
- bobingabout
- Smart Inserter
- Posts: 7352
- Joined: Fri May 09, 2014 1:01 pm
- Contact:
Re: "allow_as_intermediate_only_when_no_alternatives" recipeflag
This is one of those ancient bugs from bob's mods again... "I have wood in my inventory, but I can't craft a circuit because I'm not carrying synthetic wood", in this case, there were 2 circuit board recipes, one to make it out of wood, the other out of synthetic wood, and for some reason the circuit recipe was ALWAYS using the circuit board recipe that used synthetic wood, not regular wood.
Re: "allow_as_intermediate_only_when_no_alternatives" recipeflag
Yah, they'd need to do pathfinding through the ingredients graph from the desired product to the player's inventory. Doesn't seem that hard, but I don't know the code now so the changes could be daunting.bobingabout wrote: Fri Oct 19, 2018 8:01 am This is one of those ancient bugs from bob's mods again... "I have wood in my inventory, but I can't craft a circuit because I'm not carrying synthetic wood", in this case, there were 2 circuit board recipes, one to make it out of wood, the other out of synthetic wood, and for some reason the circuit recipe was ALWAYS using the circuit board recipe that used synthetic wood, not regular wood.