Changing research requirements on # of science-pack
Posted: Tue Jul 01, 2014 12:45 pm
I'm an absolute noob in Lua and in Factorio modding but I have been proramming for living for over a decade. I'm fairly certain once I get the very basics figured out I should be good to go with my bit of modding 
Having said that I have a bit of problems figuring out how to change the number of science packs required per research. I've tried a few things but nothing has worked. Am I correct to assume that I should do something like this in my data.lua:
When I do that I get "error while loading prototype "fluid-handling": no such node (name). I'm not sure why is that since I tried to copy it roughly off from liquid-station mod that had code like this:
If someone could tell me how to set the number of science packs required for some specific research then that'd be pretty much all I need to get going.

Having said that I have a bit of problems figuring out how to change the number of science packs required per research. I've tried a few things but nothing has worked. Am I correct to assume that I should do something like this in my data.lua:
Code: Select all
data.raw.technology["fluid-handling"].unit.ingredients["science-pack-1"] = 100
Code: Select all
local effects = data.raw.technology["fluid-handling"].effects
effects[#effects + 1] = {type="unlock-recipe", recipe="fill-water-barrel"}
If someone could tell me how to set the number of science packs required for some specific research then that'd be pretty much all I need to get going.