There is a code for adding unlocking a recipe when researching a technology:
Code: Select all
if data.raw["technology"]["military-4"] then
table.insert(data.raw["technology"]["military-4"].effects, {type = "unlock-recipe",recipe = "dragons-breath-shotgun-shell"})
end
Something like this:
Code: Select all
if data.raw["technology"]["military-4"] then
table.remove( ..., {type = "unlock-recipe",recipe = "piercing-shotgun-shell"})
end
Code: Select all
if data.raw["technology"]["military-4"] then
table.replace( ... , {type = "unlock-recipe",recipe = "piercing-shotgun-shell"} to {type = "unlock-recipe",recipe = "dragons-breath-shotgun-shell"})
end
I would be very grateful for your help!