2018-12-31 20:32:28 +08:00
require ( " recipe " )
table.insert ( data.raw [ " technology " ] [ " military-2 " ] . effects , { type = " unlock-recipe " , recipe = " 17-military-science-pack " } )
table.insert ( data.raw [ " technology " ] [ " advanced-electronics " ] . effects , { type = " unlock-recipe " , recipe = " 17-chemical-science-pack " } )
table.insert ( data.raw [ " technology " ] [ " advanced-material-processing-2 " ] . effects , { type = " unlock-recipe " , recipe = " 17-production-science-pack " } )
table.insert ( data.raw [ " technology " ] [ " advanced-electronics-2 " ] . effects , { type = " unlock-recipe " , recipe = " 17-utility-science-pack " } )
2019-01-03 23:37:46 +08:00
2019-01-06 10:36:19 +08:00
table.insert ( data.raw [ " technology " ] [ " advanced-electronics-2 " ] . effects , { type = " unlock-recipe " , recipe = " rocket-control-unit " } )
2019-01-03 23:37:46 +08:00
table.insert ( data.raw [ " technology " ] [ " advanced-electronics-2 " ] . effects , { type = " unlock-recipe " , recipe = " 17-low-density-structure " } ) --LDS unlock for pre-rocket bases
2019-01-06 10:36:19 +08:00
table.insert ( data.raw [ " technology " ] [ " advanced-material-processing-2 " ] . effects , { type = " unlock-recipe " , recipe = " rocket-fuel " } )
if not settings.startup [ " 017-old-science " ] . value then
2019-01-10 12:54:43 +08:00
local function hide ( name , technology )
data.raw [ " recipe " ] [ name ] . hidden = true
local effects = data.raw [ " technology " ] [ technology ] . effects
for _ = 1 , # effects do
if effects [ _ ] . type == " unlock-recipe " and effects [ _ ] . recipe == name then
effects [ _ ] = nil
end
end
end
hide ( " science-pack-3 " , " advanced-electronics " )
hide ( " military-science-pack " , " military-2 " )
hide ( " production-science-pack " , " advanced-material-processing-2 " )
hide ( " high-tech-science-pack " , " advanced-electronics-2 " )
2019-01-08 13:36:47 +08:00
data.raw [ " recipe " ] [ " low-density-structure " ] . normal.hidden = true
data.raw [ " recipe " ] [ " low-density-structure " ] . expensive.hidden = true
elseif settings.startup [ " 017-old-science " ] . value then
table.insert ( data.raw [ " technology " ] [ " advanced-electronics-2 " ] . effects , { type = " unlock-recipe " , recipe = " low-density-structure " } )
data.raw [ " recipe " ] [ " science-pack-3 " ] . hidden = false
data.raw [ " recipe " ] [ " military-science-pack " ] . hidden = false
data.raw [ " recipe " ] [ " production-science-pack " ] . hidden = false
data.raw [ " recipe " ] [ " high-tech-science-pack " ] . hidden = false
data.raw [ " recipe " ] [ " low-density-structure " ] . normal.hidden = false
data.raw [ " recipe " ] [ " low-density-structure " ] . expensive.hidden = false
2019-01-03 23:37:46 +08:00
end