[1.0.0] Recipe properties don't propagate to normal and expensive

Things that we aren't going to implement
GotLag
Filter Inserter
Filter Inserter
Posts: 532
Joined: Sat May 03, 2014 3:32 pm
Contact:

[1.0.0] Recipe properties don't propagate to normal and expensive

Post by GotLag »

If you set a property on a recipe which has normal and expensive modes, that property does not apply to those modes.
For example, the following has no effect in-game except to show that the recipe has been modded:

Code: Select all

data.raw.recipe["burner-mining-drill"].hidden = true
To actually hide the recipe, the following is required:

Code: Select all

data.raw.recipe["burner-mining-drill"].normal.hidden = true
data.raw.recipe["burner-mining-drill"].expensive.hidden = true
I'm not sure if this is intentional or not, but it was very confusing when I encountered it.
My suggestion is that a property definition should be automatically applied to normal/expensive modes unless those mode definitions also define that property.
Pi-C
Smart Inserter
Smart Inserter
Posts: 1742
Joined: Sun Oct 14, 2018 8:13 am
Contact:

Re: [1.0.0] Recipe properties don't propagate to normal and expensive

Post by Pi-C »

GotLag wrote: Sun Nov 01, 2020 11:59 am I'm not sure if this is intentional or not, but it was very confusing when I encountered it.
It is the expected behavior, see the paragraph above this:
If the recipe does not have a difficulty, this is located directly in the prototype. Otherwise, if the "normal" or "expensive" property exists, the recipe has difficulty. Then, the recipe data has to be specified for each difficulty instead of directly in the prototype.
Still, having the general recipe data (if no difficulties are defined) propagate to difficulties could be useful.
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!
Rseding91
Factorio Staff
Factorio Staff
Posts: 14643
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [1.0.0] Recipe properties don't propagate to normal and expensive

Post by Rseding91 »

That is working as intended. I highly recommend anyone making mods to enable the "check-unused-prototype-data" config option so you can see when you define prototype values that the game doesn't use.
If you want to get ahold of me I'm almost always on Discord.
Post Reply

Return to “Won't implement”