Page 1 of 1

Change receips of vanilla items

Posted: Sun Dec 03, 2017 3:11 pm
by Guardian667
Objective
I'm trying to redefine receips of vanilla items by setting the new receip in a data.lua file. This works fine for some items, for others not.

Success example iron-gear-wheel

Code: Select all

data.raw.recipe["iron-gear-wheel"].expensive.ingredients =
{
	{"iron-plate", 10},
	{"copper-plate", 2}
}
Failure example steam-engine

Code: Select all

data.raw.recipe["steam-engine"].expensive.incredients =
{
    {"iron-gear-wheel", 50},
    {"pipe", 15},
    {"iron-plate", 150}
}
Result
Inside the game, in the creafting menu, both items are highlighted as modified by my mod. But only the receip for the iron gear wheel contains the new values.

Re: Change receips of vanilla items

Posted: Sun Dec 03, 2017 9:29 pm
by Klonan
Image

Re: Change receips of vanilla items

Posted: Sun Dec 03, 2017 11:54 pm
by Guardian667
THX for your reply. I'm a foolish dumbass :-D

I'm also working on a program for calculating production costs, which I'm going to use for the balancing process and, no surprise, I have a class named Incredient. Feels like with every line of code my bug count increments ...