diff --git a/carbon-fiber.lua b/carbon-fiber.lua new file mode 100644 index 0000000..4be78c9 --- /dev/null +++ b/carbon-fiber.lua @@ -0,0 +1,30 @@ +local util = require("__bzcarbon__.data-util"); + +if util.me.use_fiber() then +data:extend({ + { + type = "item", + name = "carbon-fiber", + icon = "__bzcarbon__/graphics/icons/carbon-fiber.png", + icon_size = 128, + subgroup = "intermediate-product", + order = "g[graphite-carbon-fiber]", + stack_size = util.get_stack_size(100), + }, + { + type = "recipe", + name = "carbon-fiber", + category = "advanced-crafting", + order = "d[graphite-carbon-fiber]", + enabled = false, + energy_required = 1, + ingredients = { + {type="item", name="plastic", amount=1}, + {type="item", name="graphite", amount=1}, + }, + results = { + {type="item", name= "carbon-fiber", amount=1}, + } + }, +}) +end diff --git a/graphics/icons/carbon-fiber.png b/graphics/icons/carbon-fiber.png new file mode 100644 index 0000000..6c24870 Binary files /dev/null and b/graphics/icons/carbon-fiber.png differ diff --git a/graphics/icons/carbon-fiber.xcf b/graphics/icons/carbon-fiber.xcf new file mode 100644 index 0000000..e9f94e3 Binary files /dev/null and b/graphics/icons/carbon-fiber.xcf differ diff --git a/graphics/technology/carbon-fiber.png b/graphics/technology/carbon-fiber.png new file mode 100644 index 0000000..5f43401 Binary files /dev/null and b/graphics/technology/carbon-fiber.png differ diff --git a/me.lua b/me.lua index 7bceae8..2a137d0 100644 --- a/me.lua +++ b/me.lua @@ -3,6 +3,10 @@ local me = {} me.name = "bzcarbon" me.list = {} +function me.use_fiber() + return me.get_setting("bzcarbon-enable-carbon-fiber") == "yes" +end + function me.use_fullerenes() if me.get_setting("bz-all-intermediates") then return true end return me.get_setting("bzcarbon-enable-fullerenes") == "yes" diff --git a/settings.lua b/settings.lua index 7ea9a09..1a8852d 100644 --- a/settings.lua +++ b/settings.lua @@ -20,6 +20,13 @@ data:extend({ default_value = "no", allowed_values = {"no", "yes"}, }, + { + type = "string-setting", + name = "bzcarbon-enable-carbon-fiber", + setting_type = "startup", + default_value = "no", + allowed_values = {"no", "yes"}, + }, { type = "string-setting", name = "bzcarbon-enable-rough-diamond",