[2.0.28] Furnace interaction with item+fluid ingredients should be clarified

Place to report issues and suggest improvements to the API documentation.
HermanyAI
Manual Inserter
Manual Inserter
Posts: 2
Joined: Fri Dec 16, 2016 11:35 pm
Contact:

[2.0.28] Furnace interaction with item+fluid ingredients should be clarified

Post by HermanyAI »

Imagine if recycling recipes required a fluid. Say you specify the fluid as 2nd ingredient:

Code: Select all

data:extend({{
    type = "recipe",
    ...
    ingredients = {
        {type = "item", name = item_name, amount = 1},
        {type = "fluid", name = "promethium-emulsion", amount = fluid_requirement}
    },
    ...
}})
Game would recognize this setup when the furnace entity has an input fluidbox, showing it as 2nd ingredient in GUI, and that the fluid is required to select those recipes.
Image
But inserting an item would actually fail even with fluid present
Image
because it implicitly hints a restriction on ingredient order with that tooltip. Despite the fact it's also 2nd in ingredient list, it actually expects the mod to put fluid ingredient 1st as well:

Code: Select all

    ...
    ingredients = {
        {type = "fluid", name = "promethium-emulsion", amount = fluid_requirement},
        {type = "item", name = item_name, amount = 1}
    },
    ...
for it to actually work.
Image

I haven't seen this quirk documented anywhere within RecipePrototype and FurnacePrototype, and a mod has had this exact setup before in 1.1 - Industrial Revolution 3 and its Electroplater, which even has 2 different input fluids and recipes associated to both.

This is a feature not used in base game so it's understandable for it to not be mentioned, but now that i've bumped into it, i suppose mentioning something along the lines of:
If the furnace has input fluidboxes, all recipes available to the furnace must specify their fluid ingredients first.
to the description of FurnacePrototype should be enough.
curiosity
Filter Inserter
Filter Inserter
Posts: 561
Joined: Wed Sep 11, 2019 4:13 pm
Contact:

Re: [2.0.28] Furnace interaction with item+fluid ingredients should be clarified

Post by curiosity »

I think, this is a bug. Ingredient list was never order-dependent.
Post Reply

Return to “Documentation Improvement Requests”