diff --git a/graphics/icons/gyro.png b/graphics/icons/gyro.png new file mode 100644 index 0000000..bfc6005 Binary files /dev/null and b/graphics/icons/gyro.png differ diff --git a/graphics/icons/stacked/gyro-stacked.png b/graphics/icons/stacked/gyro-stacked.png new file mode 100644 index 0000000..3f780e7 Binary files /dev/null and b/graphics/icons/stacked/gyro-stacked.png differ diff --git a/graphics/technology/gyro.png b/graphics/technology/gyro.png new file mode 100644 index 0000000..25ac35d Binary files /dev/null and b/graphics/technology/gyro.png differ diff --git a/prototypes/gyro.lua b/prototypes/gyro.lua new file mode 100644 index 0000000..f15df9c --- /dev/null +++ b/prototypes/gyro.lua @@ -0,0 +1,68 @@ +local util = require("data-util"); + +if util.me.use_gyros() then +gyro_ingredients = { -- outputs 4 + {"copper-cable", 2}, + {"silica", 1}, + {"silicon", 4}} + +gyro_prereqs = {util.me.silicon_processing} +if mods.bzcarbon then + table.insert(gyro_ingredients, {"diamond", 1}) + table.insert(gyro_prereqs, "diamond-processing") +end +if mods.bztungsten then + table.insert(gyro_ingredients, {"tungsten-plate", 1}) + table.insert(gyro_prereqs, "tungsten-processing") +elseif mods.bztitanium then + table.insert(gyro_ingredients, {"titanium-plate", 1}) + table.insert(gyro_prereqs, "titanium-processing") +elseif mods.Krastorio2 then + table.insert(gyro_ingredients, {"rare-metals", 1}) + -- table.insert(gyro_prereqs, "titanium-processing") +end + + +data:extend({ + { + type = "item", + name = "gyro", + icon = "__bzsilicon__/graphics/icons/gyro.png", + icon_size = 128, + subgroup = "intermediate-product", + order = "s[silicon]-z-gyro", + stack_size = util.get_stack_size(200) + }, + { + type = "recipe", + name = "gyro", + category = "crafting", + subgroup = "intermediate-product", + enabled = false, + energy_required = 12, + ingredients = gyro_ingredients, + result = "gyro", + result_count = 4, + }, + { + type = "technology", + name = "gyro", + icon_size = 256, + icon = "__bzsilicon__/graphics/technology/gyro.png", + effects = {{type = "unlock-recipe", recipe="gyro"}}, + unit = + { + count = 100, + ingredients = + { + {"automation-science-pack", 1}, + {"logistic-science-pack", 1}, + {"chemical-science-pack", 1}, + }, + time = 30 + }, + prerequisites = gyro_prereqs, + order = "b-b" + }, +}) +end