[0.15.7] Cannot Override crafting time on expensive

Bugs that are actually features.
Post Reply
Peppe
Fast Inserter
Fast Inserter
Posts: 223
Joined: Fri Nov 28, 2014 6:48 pm
Contact:

[0.15.7] Cannot Override crafting time on expensive

Post by Peppe »

All items with an expensive recipe variant ignore crafting time changes:

example data-updates.lua:
data.raw["recipe"]["fast-transport-belt"].energy_required = 11
data.raw["recipe"]["express-transport-belt"].energy_required = 11

Result in game fast belts take 11 seconds while blue belts remain .5 seconds.
Expected both to be 11 seconds.

Looks like it is only items with expensive variants.
Last edited by Peppe on Fri May 05, 2017 4:56 pm, edited 2 times in total.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13204
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [0.15.7] Cannot Override crafting time on expensive

Post by Rseding91 »

That's because recipes with the "normal" and "expensive" definitions don't use the standard properties but have those in a sub-table:

data.raw["recipe]"["recipe-name"]["normal"].energy_required and ["expensive"]
If you want to get ahold of me I'm almost always on Discord.

Peppe
Fast Inserter
Fast Inserter
Posts: 223
Joined: Fri Nov 28, 2014 6:48 pm
Contact:

Re: [0.15.7] Cannot Override crafting time on expensive

Post by Peppe »

Just thought of that after i posted, thanks!

Post Reply

Return to “Not a bug”