I modded a custom recipe and locked it behind a vanilla technology. The lua script looks like this:
Code: Select all
data:extend{
  {
    type = "recipe",
    name = "recipe-electronic-circuit-plastic-bar",
    enabled = false,
    normal =
    {
      ingredients =
      {
        {"plastic-bar", 1},
        {"copper-cable", 3}
      },
      results={{type="item", name="electronic-circuit", amount=1}},
      main_product= "",
    },
    expensive =
    {
      ingredients =
      {
        {"plastic-bar", 2},
        {"copper-cable", 10}
      },
      results={{type="item", name="electronic-circuit", amount=1}},
      main_product= "",
    },
    subgroup = "intermediate-product",
    order = "electronic-circuit-9",
    icon = "__Electronic_Circuit_Plastic_Bar__/graphics/icons/recipe/electronic-circuit-plastic-bar.png",
    icon_size = 32,
  }
}
table.insert(data.raw.technology["plastics"].effects, {type = "unlock-recipe", recipe = "recipe-electronic-circuit-plastic-bar"})
How can I fix this?





