graphite, diamonds, graphene, fullerenes, etc
2
.gitignore
vendored
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
*.bak
|
||||
*.blend*
|
||||
128
README.md
|
|
@ -1,8 +1,8 @@
|
|||
# Mod
|
||||
# Graphite & Diamonds
|
||||
|
||||
[factorio mod page](https://mods.factorio.com/mod/bzmod)
|
||||
[factorio mod page](https://mods.factorio.com/mod/bzcarbon)
|
||||
|
||||
Adds ... to the base game
|
||||
Adds elemental carbon resources and intermediates to the base game
|
||||
|
||||
## Version History
|
||||
See changelog.txt
|
||||
|
|
@ -13,5 +13,127 @@ See changelog.txt
|
|||
|
||||
## Thanks to
|
||||
- [snouz](https://github.com/snouz) (logo inspiration, ore graphics templates)
|
||||
- [YassineMrabet](https://commons.wikimedia.org/wiki/File:Fullerene.png) (initial fullerene image, CC license, see link)
|
||||
|
||||
### Localization
|
||||
|
||||
|
||||
|
||||
|
||||
## FAQ
|
||||
|
||||
#### Why is X used in this recipe?
|
||||
I try to stick to the vanilla factorio spirit, with a slight edge towards more realistic. For this mod:
|
||||
|
||||
- Graphite used for resistors, lubricant, refractory, batteries, gaskets, nuclear reactors, etc.
|
||||
- Diamonds used for grinding grit, drilling, bearings, high-tech electronics, etc.
|
||||
- Graphene used for high-tech circuits, armor, satellites, filters, batteries, etc.
|
||||
- Fullerenes used for biological things and making nanotubes
|
||||
- Nanotubes used as an advanced material for alternative recipes
|
||||
- Carbon black used for plastics, as a conductor and as a pigment
|
||||
|
||||
|
||||
## Main
|
||||
|
||||
“We celebrate the tree that stretches to the sky, but it is the ground we should ultimately thank.” - *Becky Chambers*
|
||||
|
||||
----
|
||||
|
||||
|
||||
**CAVEAT** This mod is still an alpha version. Large balance changes, breaking changes, and many other changes may happen until it is in beta. This is my most ambitious "resource" mod to date, so it may take a little time to settle.
|
||||
|
||||
----
|
||||
|
||||
|
||||
Adds elemental carbon items to the game, including flake graphite, graphite, diamonds, graphene, and optionally fullerenes, nanotubes, and carbon black. Modifies several recipes to use these new intermediates.
|
||||
|
||||
If you enjoy vanilla Factorio, Krastorio 2, or Space Exploration, and would like to add a new resource, this mod might be what you're looking for.
|
||||
|
||||
If you use this alongside the other [Very BZ mods](https://mods.factorio.com/mod/bzvery), the game will become quite a bit more complex. While still less than Angelbob/Pyanodon, it's a big step up from vanilla.
|
||||
|
||||
If you want a vanilla-esque game with a few tweaks, try with just this mod, or a simpler one like [Titanium](https://mods.factorio.com/mod/bztitanium) or [Lead](https://mods.factorio.com/mod/bzlead).
|
||||
|
||||
----
|
||||
|
||||
Flake graphite is a mineable resource that is processed into graphite. Graphite can be used in certain recipes, and can be further processed into diamonds and graphene. Optionally (default on), graphite can be processed into fullerenes and then nanotubes. Also optionally (default off), carbon black is available as a byproduct of oil processing, used to make plastic.
|
||||
|
||||
|
||||
Supported compatible mods:
|
||||
- Space Exploration & AAI
|
||||
- Krastorio 2 & Rich Rocks Requiem
|
||||
- Several smaller mods like Deadlock Stacking, Deadlock Crating, mining drill mods, etc
|
||||
|
||||
Planned but not yet supported: RSO (see faq), Omnimatter, FE+, 5Dim's, Simple Compress, and much more.
|
||||
|
||||
Many other mods are compatible, but not yet fully supported. Compatibility suggestions always appreciated.
|
||||
|
||||
|
||||
----
|
||||
Special thanks to
|
||||
|
||||
- The community, for all the suggestions, feedback, and bug reports!
|
||||
- [snouz](https://mods.factorio.com/user/snouz) (recolored ore graphics, thumbnail style)
|
||||
- [YassineMrabet](https://commons.wikimedia.org/wiki/File:Fullerene.png) (initial fullerene image, CC license, see link)
|
||||
|
||||
----
|
||||
|
||||
### Detailed list of changes (incomplete)
|
||||
|
||||
#### Vanilla
|
||||
|
||||
|
||||
- Electronic circuit (graphite replaces some copper)
|
||||
- Battery (graphite added)
|
||||
- Lubricant (some oil changed to graphite)
|
||||
- Module 2s (diamond added)
|
||||
- Assembler 3 (diamond added)
|
||||
- Low density structure (diamond added)
|
||||
|
||||
- Centrifuge (diamond added)
|
||||
- Nuclear reactor (graphite added)
|
||||
|
||||
- Power Armor Mk2 (graphene added)
|
||||
- Rocket control unit (graphene added)
|
||||
- Satellite (graphene added)
|
||||
|
||||
If fullerenes and nanotubes enabled
|
||||
|
||||
- Capsules (fullerenes)
|
||||
- Alternate recipe for LDS (nanotubes)
|
||||
|
||||
If carbon black enabled
|
||||
|
||||
- Carbon black byproduct of oil processing
|
||||
- Plastic (coal changed to carbon black)
|
||||
|
||||
|
||||
#### Krastorio 2
|
||||
- Lithium sulfur battery (graphene)
|
||||
- Reactors (graphite)
|
||||
- Drills (diamonds)
|
||||
- Improved pollution filter (graphene)
|
||||
- Matter research data (graphene)
|
||||
- Advanced solar panel (graphene)
|
||||
|
||||
If fullerenes and nanotubes enabled
|
||||
|
||||
- Viruses (fullerenes)
|
||||
- Biomass (fullerenes)
|
||||
- Alternate imersite recipes (nanotubes)
|
||||
|
||||
#### Space Exploration
|
||||
|
||||
- Material testing pack (graphite)
|
||||
- Particle accelerator/collider (graphite)
|
||||
- Secure canister (graphite)
|
||||
|
||||
- Naquium (graphene & graphite)
|
||||
- Various data (various, with improved outputs)
|
||||
- Nanomaterial (graphene)
|
||||
|
||||
If fullerenes and nanotubes enabled
|
||||
|
||||
- Vitalic reagent (fullerenes)
|
||||
- Medpack 2
|
||||
- Nanomaterial (alternate recipe)
|
||||
- Aeroframe scaffold (alternate recipe)
|
||||
|
|
|
|||
71
carbon-recipe-final-k2.lua
Normal file
|
|
@ -0,0 +1,71 @@
|
|||
local bzutil = require("__bzcarbon__.data-util");
|
||||
local util = require("util")
|
||||
if mods.Krastorio2 then
|
||||
if bzutil.me.use_fullerenes() then
|
||||
-- Add extra nanotube recipes.
|
||||
-- This could be moved to data-updates in future if necessary
|
||||
data:extend({
|
||||
{
|
||||
type = "recipe",
|
||||
name = "imersium-plate-nanotubes",
|
||||
icons = {
|
||||
{ icon = data.raw.item["imersium-plate"].icon, icon_size = data.raw.item["imersium-plate"].icon_size},
|
||||
{ icon = "__bzcarbon__/graphics/icons/nanotube.png", icon_size = 128, scale=0.125, shift= {-8, -8}},
|
||||
},
|
||||
category = "smelting",
|
||||
subgroup = "raw-material",
|
||||
order = "e00-a2[imersium-plate]",
|
||||
enabled = false,
|
||||
energy_required = 32,
|
||||
ingredients = {
|
||||
{"nanotubes", 6},
|
||||
table.unpack(util.table.deepcopy(data.raw.recipe["imersium-plate"].ingredients)),
|
||||
},
|
||||
result = "imersium-plate",
|
||||
result_count = 6,
|
||||
},
|
||||
{
|
||||
type = "recipe",
|
||||
name = "imersium-beam-nanotubes",
|
||||
icons = {
|
||||
{ icon = data.raw.item["imersium-beam"].icon, icon_size = data.raw.item["imersium-beam"].icon_size},
|
||||
{ icon = "__bzcarbon__/graphics/icons/nanotube.png", icon_size = 128, scale=0.125, shift= {-8, -8}},
|
||||
},
|
||||
category = "smelting-crafting",
|
||||
subgroup = "smelting-crafting",
|
||||
order = data.raw.item["imersium-beam"].order.."z",
|
||||
enabled = false,
|
||||
energy_required = 12,
|
||||
ingredients = {
|
||||
{"nanotubes", 4},
|
||||
table.unpack(util.table.deepcopy(data.raw.recipe["kr-s-c-imersium-beam"].ingredients)),
|
||||
},
|
||||
result = "imersium-beam",
|
||||
result_count = 2,
|
||||
},
|
||||
{
|
||||
type = "recipe",
|
||||
name = "imersium-gear-wheel-nanotubes",
|
||||
icons = {
|
||||
{ icon = data.raw.item["imersium-gear-wheel"].icon, icon_size = data.raw.item["imersium-gear-wheel"].icon_size},
|
||||
{ icon = "__bzcarbon__/graphics/icons/nanotube.png", icon_size = 128, scale=0.125, shift= {-8, -8}},
|
||||
},
|
||||
category = "smelting-crafting",
|
||||
subgroup = "smelting-crafting",
|
||||
order = data.raw.item["imersium-gear-wheel"].order.."z",
|
||||
enabled = false,
|
||||
energy_required = 12,
|
||||
ingredients = {
|
||||
{"nanotubes", 2},
|
||||
table.unpack(util.table.deepcopy(data.raw.recipe["kr-s-c-imersium-gear-wheel"].ingredients)),
|
||||
},
|
||||
result = "imersium-gear-wheel",
|
||||
result_count = 2,
|
||||
},
|
||||
})
|
||||
|
||||
bzutil.add_effect("nanotubes", {type="unlock-recipe", recipe="imersium-plate-nanotubes"})
|
||||
bzutil.add_effect("nanotubes", {type="unlock-recipe", recipe="imersium-beam-nanotubes"})
|
||||
bzutil.add_effect("nanotubes", {type="unlock-recipe", recipe="imersium-gear-wheel-nanotubes"})
|
||||
end
|
||||
end
|
||||
|
|
@ -1,15 +1,15 @@
|
|||
local util = require("__bzlead__.data-util");
|
||||
local util = require("__bzcarbon__.data-util");
|
||||
|
||||
if mods["Rich-Rocks-Requiem"] then
|
||||
if data.raw.recipe["rrr-stone-processing"] then
|
||||
table.insert(data.raw.recipe["rrr-stone-processing"].results,
|
||||
{name = "lead-ore", probability = 0.25, amount = 1}
|
||||
{name = "flake-graphite", probability = 0.35, amount = 1}
|
||||
)
|
||||
end
|
||||
|
||||
if data.raw.recipe["rrr-raw-ores-processing"] then
|
||||
table.insert(data.raw.recipe["rrr-raw-ores-processing"].results,
|
||||
{name = "lead-ore", probability = 0.75, amount = 10}
|
||||
{name = "flake-graphite", probability = 0.65, amount = 10}
|
||||
)
|
||||
end
|
||||
|
||||
55
carbon-recipe-final-se.lua
Normal file
|
|
@ -0,0 +1,55 @@
|
|||
local util = require("util")
|
||||
local bzutil = require("__bzcarbon__.data-util");
|
||||
|
||||
if mods["space-exploration"] then
|
||||
if bzutil.me.use_fullerenes() then
|
||||
-- Add an extra nanotube aeroframe scaffold recipe.
|
||||
-- This could be moved to data-updates in future if necessary
|
||||
data:extend({
|
||||
{
|
||||
type = "recipe",
|
||||
name = "aeroframe-scaffold-nanotubes",
|
||||
icons = {
|
||||
{ icon = data.raw.item["se-aeroframe-scaffold"].icon, icon_size = data.raw.item["se-aeroframe-scaffold"].icon_size},
|
||||
{ icon = "__bzcarbon__/graphics/icons/nanotube.png", icon_size = 128, scale=0.125, shift= {-8, -8}},
|
||||
},
|
||||
category = "crafting",
|
||||
order = data.raw.item["se-aeroframe-scaffold"].order.."z",
|
||||
enabled = false,
|
||||
energy_required = 2,
|
||||
ingredients = {
|
||||
{"nanotubes", 2},
|
||||
table.unpack(util.table.deepcopy(data.raw.recipe["se-aeroframe-scaffold"].ingredients)),
|
||||
},
|
||||
result = "se-aeroframe-scaffold",
|
||||
result_count = 2,
|
||||
},
|
||||
{
|
||||
type = "recipe",
|
||||
name = "nanomaterial-nanotubes",
|
||||
icons = {
|
||||
{ icon = data.raw.item["se-nanomaterial"].icon, icon_size = data.raw.item["se-nanomaterial"].icon_size},
|
||||
{ icon = "__bzcarbon__/graphics/icons/nanotube.png", icon_size = 128, scale=0.125, shift= {-8, -8}},
|
||||
},
|
||||
category = data.raw.recipe["se-nanomaterial"].category,
|
||||
order = data.raw.item["se-nanomaterial"].order.."z",
|
||||
subgroup = data.raw.item["se-nanomaterial"].subgroup,
|
||||
enabled = false,
|
||||
energy_required = data.raw.recipe["se-nanomaterial"].energy_required,
|
||||
ingredients = {
|
||||
{"nanotubes", 2},
|
||||
table.unpack(util.table.deepcopy(data.raw.recipe["se-nanomaterial"].ingredients)),
|
||||
},
|
||||
results = {
|
||||
table.unpack(util.table.deepcopy(data.raw.recipe["se-nanomaterial"].results)),
|
||||
}
|
||||
}
|
||||
})
|
||||
bzutil.add_to_product("nanomaterial-nanotubes", "se-nanomaterial", 16)
|
||||
bzutil.add_effect("nanotubes", {type="unlock-recipe", recipe="aeroframe-scaffold-nanotubes"})
|
||||
bzutil.add_effect("se-nanomaterial", {type="unlock-recipe", recipe="nanomaterial-nanotubes"})
|
||||
|
||||
-- core mining balancing
|
||||
bzutil.add_to_product("se-core-fragment-omni", "graphite", -3)
|
||||
end
|
||||
end
|
||||
33
carbon-recipe-final-stacking.lua
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
-- Deadlock stacking recipes
|
||||
|
||||
local util = require("__bzcarbon__.data-util");
|
||||
|
||||
if deadlock then
|
||||
deadlock.add_stack("flake-graphite", "__bzcarbon__/graphics/icons/stacked/flake-graphite-stacked.png", "deadlock-stacking-2", 64)
|
||||
deadlock.add_stack("graphite", "__bzcarbon__/graphics/icons/stacked/graphite-stacked.png", "deadlock-stacking-2", 128)
|
||||
deadlock.add_stack("diamond", "__bzcarbon__/graphics/icons/stacked/diamond-stacked.png" , "deadlock-stacking-2", 128)
|
||||
deadlock.add_stack("graphene", "__bzcarbon__/graphics/icons/stacked/graphene-stacked.png" , "deadlock-stacking-2", 128)
|
||||
if util.me.use_fullerenes() then
|
||||
deadlock.add_stack("fullerenes", "__bzcarbon__/graphics/icons/stacked/fullerene-stacked.png", "deadlock-stacking-2", 128)
|
||||
deadlock.add_stack("nanotubes", "__bzcarbon__/graphics/icons/stacked/nanotube-stacked.png", "deadlock-stacking-2", 128)
|
||||
end
|
||||
if util.me.use_carbon_black() then
|
||||
deadlock.add_stack("carbon-black", "__bzcarbon__/graphics/icons/stacked/carbon-black-stacked.png", "deadlock-stacking-2", 64)
|
||||
end
|
||||
end
|
||||
|
||||
-- Deadlock crating recipes
|
||||
if deadlock_crating then
|
||||
deadlock_crating.add_crate("flake-graphite", "deadlock-crating-2")
|
||||
deadlock_crating.add_crate("graphite", "deadlock-crating-2")
|
||||
deadlock_crating.add_crate("diamonds", "deadlock-crating-2")
|
||||
deadlock_crating.add_crate("graphene", "deadlock-crating-2")
|
||||
if util.me.use_fullerenes() then
|
||||
deadlock_crating.add_crate("fullerenes", "deadlock-crating-2")
|
||||
deadlock_crating.add_crate("nanotubes", "deadlock-crating-2")
|
||||
end
|
||||
if util.me.use_carbon_black() then
|
||||
deadlock_crating.add_crate("carbon-black", "deadlock-crating-2")
|
||||
end
|
||||
end
|
||||
|
||||
29
carbon-recipe-k2.lua
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
local util = require("__bzcarbon__.data-util");
|
||||
|
||||
if mods.Krastorio2 then
|
||||
data:extend({
|
||||
{
|
||||
type = "recipe",
|
||||
name = "heavy-water-graphene",
|
||||
icons = {
|
||||
{ icon = util.k2assets().."/icons/fluids/heavy-water.png", icon_size = 64, icon_mipmaps = 3,},
|
||||
{ icon = "__bzcarbon__/graphics/icons/graphene.png", icon_size = 128, scale=0.25, shift= {-8, -8}},
|
||||
},
|
||||
category = "electrolysis",
|
||||
subgroup = "fluid-recipes",
|
||||
order = "y06[heavy-water]",
|
||||
enabled = false,
|
||||
energy_required = 60,
|
||||
ingredients = {
|
||||
{type="item", name="graphene", amount=1, catalyst_amount=1},
|
||||
{type="fluid", name="water", amount=500},
|
||||
},
|
||||
results = {
|
||||
{type="item", name="graphene", amount=1, probability=.8, catalyst_amount=1},
|
||||
{type="fluid", name="heavy-water", amount=40},
|
||||
},
|
||||
}
|
||||
})
|
||||
util.add_effect("graphene", {type="unlock-recipe", recipe="heavy-water-graphene"})
|
||||
util.add_prerequisite("fullerenes", "kr-atmosphere-condensation")
|
||||
end
|
||||
34
carbon-recipe-modules.lua
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
-- Enable prod modules for all recipes
|
||||
local util = require("__bzcarbon__.data-util");
|
||||
|
||||
recipes = {
|
||||
"graphite",
|
||||
"synthetic-diamond",
|
||||
|
||||
"graphene",
|
||||
"heavy-water-graphene",
|
||||
|
||||
"fullerenes",
|
||||
"nanotubes",
|
||||
"low-density-structure-nanotubes",
|
||||
"imersium-plate-nanotubes",
|
||||
"imersium-beam-nanotubes",
|
||||
"imersium-gear-wheel-nanotubes",
|
||||
"aeroframe-scaffold-nanotubes",
|
||||
"nanomaterial-nanotubes",
|
||||
-- NOTE: Carbon black recipes do not allow prod modules
|
||||
}
|
||||
|
||||
for i, recipe in pairs(recipes) do
|
||||
if data.raw.recipe[recipe] then
|
||||
for j, module in pairs(data.raw.module) do
|
||||
if module.effect then
|
||||
for effect_name, effect in pairs(module.effect) do
|
||||
if effect_name == "productivity" and effect.bonus > 0 and module.limitation and #module.limitation > 0 then
|
||||
table.insert(module.limitation, recipe)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
28
carbon-recipe-se.lua
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
local util = require("__bzcarbon__.data-util");
|
||||
if mods["space-exploration"] then
|
||||
data:extend({
|
||||
{
|
||||
type = "recipe",
|
||||
name = "diamond-synthesis-vulcanite",
|
||||
category = "smelting",
|
||||
order = "g[diamond]",
|
||||
energy_required = 40,
|
||||
enabled = false,
|
||||
always_show_made_in = true,
|
||||
allow_as_intermediate = false,
|
||||
ingredients = {
|
||||
{name = "graphite", amount = 20},
|
||||
{name = "se-vulcanite-block", amount = 1},
|
||||
},
|
||||
results = {
|
||||
{name = "diamond", amount = 3},
|
||||
},
|
||||
icons =
|
||||
{
|
||||
{ icon = "__bzcarbon__/graphics/icons/diamond.png", icon_size = 128},
|
||||
{ icon = "__space-exploration-graphics__/graphics/icons/vulcanite-block.png", icon_size = 64, scale=0.25, shift= {-10, -10}},
|
||||
},
|
||||
},
|
||||
})
|
||||
util.add_effect("se-processing-vulcanite", {type="unlock-recipe", recipe="diamond-synthesis-vulcanite"})
|
||||
end
|
||||
225
carbon-recipe-updates.lua
Normal file
|
|
@ -0,0 +1,225 @@
|
|||
local util = require("__bzcarbon__.data-util");
|
||||
|
||||
-- TECHS
|
||||
util.add_prerequisite("steel-processing", "graphite-processing")
|
||||
|
||||
util.add_prerequisite("low-density-structure", "synthetic-diamond-processing")
|
||||
util.add_prerequisite("advanced-electronics-2", "synthetic-diamond-processing")
|
||||
util.add_prerequisite("production-science-pack", "synthetic-diamond-processing")
|
||||
util.add_prerequisite("uranium-processing", "synthetic-diamond-processing")
|
||||
|
||||
util.add_prerequisite("power-armor-mk2", "graphene")
|
||||
util.add_prerequisite("rocket-control-unit", "graphene")
|
||||
|
||||
|
||||
-- fullerenes & nanotubes
|
||||
if util.me.use_fullerenes() then
|
||||
util.add_prerequisite("graphene", "fullerenes")
|
||||
util.add_prerequisite("military-3", "fullerenes")
|
||||
util.replace_some_ingredient("poison-capsule", "coal", 9, "fullerenes", 90)
|
||||
util.replace_some_ingredient("slowdown-capsule", "coal", 4, "fullerenes", 40)
|
||||
-- K2
|
||||
util.add_ingredient("kr-biter-virus", "fullerenes", 100)
|
||||
util.add_ingredient("kr-creep-virus", "fullerenes", 100)
|
||||
util.replace_some_ingredient("kr-biomass-growing", "petroleum-gas", 25, "fullerenes", 25)
|
||||
-- SE
|
||||
util.add_ingredient("se-vitalic-reagent", "fullerenes", 4)
|
||||
util.add_ingredient("se-medpack-2", "fullerenes", 100)
|
||||
end
|
||||
|
||||
|
||||
-- carbon black
|
||||
if util.me.use_carbon_black() then
|
||||
|
||||
-- Plastic from carbon black, carbon black from oil processing
|
||||
util.replace_ingredient("plastic-bar", "coal", "carbon-black")
|
||||
util.add_product("basic-oil-processing", {"carbon-black", 1})
|
||||
util.add_product("advanced-oil-processing", {"carbon-black", 1})
|
||||
util.add_product("light-oil-cracking", {"carbon-black", 1})
|
||||
util.add_product("heavy-oil-cracking", {"carbon-black", 1})
|
||||
|
||||
--K2
|
||||
if mods.bztitanium then
|
||||
util.add_ingredient("kr-black-reinforced-plate", "carbon-black", 5)
|
||||
util.add_ingredient("kr-white-reinforced-plate", "titanium-plate", 1)
|
||||
end
|
||||
|
||||
util.add_effect("plastics", {type="unlock-recipe", recipe="carbon-black"})
|
||||
util.add_effect("plastics", {type="unlock-recipe", recipe="graphite-carbon-black"})
|
||||
|
||||
end
|
||||
|
||||
|
||||
util.replace_some_ingredient("electronic-circuit", "copper-cable", 1, "graphite", 1)
|
||||
util.add_ingredient("battery", "graphite", 1)
|
||||
util.add_ingredient("pump", "graphite", 2)
|
||||
if mods.bzzirconium then
|
||||
-- TODO CRUCIBLE RECIPE HERE
|
||||
else
|
||||
util.add_ingredient("electric-furnace", "graphite", 5)
|
||||
end
|
||||
|
||||
util.add_ingredient("speed-module-2", "diamond", 4)
|
||||
util.add_ingredient("effectivity-module-2", "diamond", 4)
|
||||
util.add_ingredient("productivity-module-2", "diamond", 4)
|
||||
util.add_ingredient("assembling-machine-3", "diamond", 4)
|
||||
util.add_ingredient("low-density-structure", "diamond", 1)
|
||||
util.add_ingredient("centrifuge", "diamond", 10)
|
||||
|
||||
if mods.Krastorio2 then
|
||||
util.replace_some_ingredient("steel-plate", "iron-plate", 2, "graphite", 4)
|
||||
util.add_ingredient("tungsten-carbide", "graphite", 4)
|
||||
elseif mods.bzfoundry then
|
||||
util.replace_some_ingredient("steel-plate", "iron-plate", 1, "graphite", 1)
|
||||
util.replace_some_ingredient("tungsten-carbide", "tungsten-plate", 1, "graphite", 1)
|
||||
end
|
||||
|
||||
util.multiply_recipe("lubricant", 2)
|
||||
util.replace_some_ingredient("lubricant", "heavy-oil", 10, "graphite", 1)
|
||||
|
||||
util.add_ingredient("nuclear-reactor", "graphite", 500)
|
||||
|
||||
util.add_ingredient("power-armor-mk2", "graphene", 30)
|
||||
util.add_ingredient("rocket-control-unit", "graphene", 1)
|
||||
util.add_ingredient("satellite", "graphene", 100)
|
||||
|
||||
-- K2
|
||||
util.add_ingredient("empty-dt-fuel", "graphite", 1)
|
||||
util.add_ingredient("kr-steel-pump", "graphite", 2)
|
||||
|
||||
util.add_ingredient("kr-electrolysis-plant", "graphite", 10)
|
||||
util.add_ingredient("kr-fusion-reactor", "graphite", 350)
|
||||
util.add_ingredient("kr-antimatter-reactor", "graphite", 350)
|
||||
util.add_ingredient("kr-electric-mining-drill-mk3", "diamond", 5)
|
||||
util.add_ingredient("kr-quarry-drill", "diamond", 20)
|
||||
util.add_ingredient("advanced-exoskeleton-equipment", "diamond", 10)
|
||||
|
||||
util.add_ingredient("improved-pollution-filter", "graphene", 1)
|
||||
util.add_ingredient("lithium-sulfur-battery", "graphene", 1)
|
||||
util.add_ingredient("matter-research-data", "graphene", 5)
|
||||
util.add_ingredient("kr-advanced-solar-panel", "graphene", 5)
|
||||
util.add_ingredient("imersite-solar-panel-equipment", "graphene", 5)
|
||||
util.add_ingredient("kr-advanced-chemical-plant", "graphene", 20)
|
||||
util.add_ingredient("empty-antimatter-fuel-cell", "graphene", 10)
|
||||
|
||||
util.add_prerequisite("kr-lithium-sulfur-battery", "graphene")
|
||||
util.set_tech_recipe("kr-lithium-sulfur-battery",
|
||||
{
|
||||
{"automation-science-pack", 1},
|
||||
{"logistic-science-pack", 1},
|
||||
{"chemical-science-pack", 1},
|
||||
{"production-science-pack", 1},
|
||||
{"utility-science-pack", 1},
|
||||
})
|
||||
util.set_tech_recipe("kr-robot-battery",
|
||||
{
|
||||
{"automation-science-pack", 1},
|
||||
{"logistic-science-pack", 1},
|
||||
{"chemical-science-pack", 1},
|
||||
{"production-science-pack", 1},
|
||||
{"utility-science-pack", 1},
|
||||
})
|
||||
util.set_tech_recipe("kr-battery-mk3-equipment",
|
||||
{
|
||||
{"automation-science-pack", 1},
|
||||
{"logistic-science-pack", 1},
|
||||
{"chemical-science-pack", 1},
|
||||
{"production-science-pack", 1},
|
||||
{"utility-science-pack", 1},
|
||||
})
|
||||
|
||||
|
||||
|
||||
-- AAI Industry
|
||||
util.add_ingredient("area-mining-drill", "diamond", 8)
|
||||
|
||||
-- Space Exploration
|
||||
util.add_ingredient("se-material-testing-pack", "graphite", 1)
|
||||
util.add_ingredient("se-space-particle-accelerator", "graphite", 10)
|
||||
util.add_ingredient("se-space-particle-collider", "graphite", 10)
|
||||
util.add_ingredient("se-canister", "graphite", 1)
|
||||
util.add_ingredient("se-naquium-ingot", "graphite", 1)
|
||||
util.replace_some_ingredient("se-naquium-powder", "se-vitalic-acid", 2, "graphene", 2)
|
||||
|
||||
util.add_ingredient("se-quantum-processor", "graphene", 1)
|
||||
util.add_ingredient("se-space-solar-panel-2", "graphene", 4)
|
||||
util.add_ingredient("se-biochemical-resistance-data", "graphene", 1)
|
||||
util.add_ingredient("se-tensile-strength-data", "graphene", 1)
|
||||
util.add_ingredient("se-space-biochemical-facility", "graphene", 4)
|
||||
util.add_ingredient("se-space-genetics-facility", "graphene", 20)
|
||||
util.add_ingredient("se-space-growth-facility", "graphene", 4)
|
||||
util.add_ingredient("se-nanomaterial", "graphene", 1)
|
||||
util.add_ingredient("se-void-probe", "graphene", 100)
|
||||
|
||||
util.add_ingredient("se-space-radiator-2", "diamond", 16)
|
||||
util.add_ingredient("se-rigidity-data", "diamond", 1)
|
||||
util.add_to_product("se-rigidity-data", "se-rigidity-data", 1)
|
||||
util.add_ingredient("se-hot-thermodynamics-data", "diamond", 1)
|
||||
util.add_to_product("se-hot-thermodynamics-data", "se-hot-thermodynamics-data", 1)
|
||||
util.add_ingredient("se-compressive-strength-data", "diamond", 1)
|
||||
util.add_to_product("se-compressive-strength-data", "se-compressive-strength-data", 1)
|
||||
|
||||
|
||||
|
||||
|
||||
-- Realistic Reactors
|
||||
util.add_ingredient("realistic-reactor", "graphite", 100)
|
||||
util.add_ingredient("breeder-reactor", "graphite", 100)
|
||||
|
||||
-- Plutonium Energy
|
||||
util.add_ingredient("MOX-reactor", "graphite", 400)
|
||||
|
||||
-- RFP
|
||||
util.add_ingredient("rfp-reactor", "graphite", 1000)
|
||||
util.add_ingredient("rfp-aneutronic-reactor", "graphite", 5000)
|
||||
|
||||
|
||||
-- vortik's deep core mining
|
||||
util.add_ingredient("vtk-deepcore-mining-moho", "diamond", 10)
|
||||
util.add_ingredient("vtk-deepcore-mining-drone", "diamond", 1)
|
||||
util.add_ingredient("vtk-deepcore-mining-drill", "diamond", 20)
|
||||
util.add_ingredient("vtk-deepcore-mining-drill-advanced", "diamond", 50)
|
||||
|
||||
-- Advanced Mining Drills
|
||||
util.add_ingredient("elite-mining-drill", "diamond", 5)
|
||||
util.add_ingredient("ultimate-mining-drill", "diamond", 10)
|
||||
|
||||
-- Skandragon
|
||||
util.add_ingredient("skan-elite-mining-drill", "diamond", 4)
|
||||
util.add_ingredient("skan-ultimate-mining-drill", "diamond", 4)
|
||||
|
||||
-- Hiladdar
|
||||
util.add_ingredient("hsmd-electric-mining-drill-mk3", "diamond", 3)
|
||||
util.add_ingredient("hsmd-electric-mining-drill-mk4", "diamond", 3)
|
||||
util.add_ingredient("hsmd-electric-mining-drill-mk5", "diamond", 3)
|
||||
util.add_ingredient("hsmd-electric-mining-drill-mk6", "diamond", 3)
|
||||
|
||||
-- Zombies
|
||||
util.add_ingredient("electric-mining-drill-mk2", "diamond", 2)
|
||||
util.add_ingredient("edrill-1to2", "diamond", 2)
|
||||
util.add_ingredient("electric-mining-drill-mk3", "diamond", 2)
|
||||
util.add_ingredient("electric-mining-drill-mk4", "diamond", 2)
|
||||
util.add_ingredient("electric-mining-drill-mk5", "diamond", 2)
|
||||
util.add_ingredient("electric-mining-drill-mk6", "diamond", 2)
|
||||
if not mods["zombiesextended-core"] then
|
||||
util.add_ingredient("electric-mining-drill-mk1", "tungsten-carbide", 5)
|
||||
end
|
||||
|
||||
-- Tiny
|
||||
util.add_ingredient("tiny-electric-mining-drill-3", "diamond", 2)
|
||||
util.add_ingredient("tiny-electric-mining-drill-5", "diamond", 3)
|
||||
|
||||
-- TA Miners
|
||||
util.add_ingredient("moho_extractor", "diamond", 50)
|
||||
util.add_ingredient("mantle_extractor", "diamond", 100)
|
||||
|
||||
-- other mining drills
|
||||
util.add_ingredient("electric-mining-drill-lv2", "diamond", 5)
|
||||
util.add_ingredient("advanced-electric-mining-drill", "diamond", 5)
|
||||
util.add_ingredient("omega-drill", "diamond", 15)
|
||||
util.add_ingredient("omega-drill-mk2", "diamond", 30)
|
||||
util.add_ingredient("passive-furnace", "diamond", 2)
|
||||
util.add_ingredient("quarry-mk3", "diamond", 10)
|
||||
|
||||
-- FastFurnaces
|
||||
util.add_ingredient("reika-fast-electric-mining-drill", "diamond", 1)
|
||||
449
carbon-recipe.lua
Normal file
|
|
@ -0,0 +1,449 @@
|
|||
-- Graphite etc
|
||||
|
||||
local util = require("__bzcarbon__.data-util");
|
||||
|
||||
local graphite_category = "advanced-crafting"
|
||||
if mods["space-exploration"] then
|
||||
graphite_category = "pulverising"
|
||||
end
|
||||
if mods.Krastorio2 then
|
||||
graphite_category = "crushing"
|
||||
end
|
||||
|
||||
data:extend({
|
||||
{ type = "recipe-category", name = "diamond-synthesis"},
|
||||
})
|
||||
|
||||
data:extend({
|
||||
{
|
||||
type = "item",
|
||||
name = "graphite",
|
||||
icon = "__bzcarbon__/graphics/icons/graphite.png",
|
||||
icon_size = 128,
|
||||
pictures = {
|
||||
{filename="__bzcarbon__/graphics/icons/graphite.png", size=128, scale=0.125},
|
||||
{filename="__bzcarbon__/graphics/icons/graphite-1.png", size=128, scale=0.125},
|
||||
{filename="__bzcarbon__/graphics/icons/graphite-2.png", size=128, scale=0.125},
|
||||
},
|
||||
subgroup = "raw-material",
|
||||
order = "g[graphite]",
|
||||
stack_size = util.get_stack_size(100)
|
||||
},
|
||||
{
|
||||
type = "recipe",
|
||||
name = "graphite",
|
||||
category = graphite_category,
|
||||
order = "d[graphite]",
|
||||
icons = (mods["Krastorio2"] and
|
||||
{
|
||||
{ icon = "__bzcarbon__/graphics/icons/graphite.png", icon_size = 128},
|
||||
{ icon = "__bzcarbon__/graphics/icons/flake-graphite.png", icon_size = 64, icon_mipmaps = 3, scale=0.25, shift= {-8, -8}},
|
||||
} or nil),
|
||||
normal = (mods["Krastorio2"] and
|
||||
{
|
||||
enabled = false,
|
||||
energy_required = 5,
|
||||
ingredients = {{"flake-graphite", 10}},
|
||||
results = {{type="item", name= "graphite", amount=10}},
|
||||
} or
|
||||
{
|
||||
enabled = false,
|
||||
--energy_required = 128/45,
|
||||
energy_required = 0.5,
|
||||
ingredients = {{"flake-graphite", 1}},
|
||||
result = "graphite"
|
||||
}),
|
||||
expensive =
|
||||
{
|
||||
enabled = false,
|
||||
--energy_required = 256/45,
|
||||
energy_required = 1,
|
||||
ingredients = {{"flake-graphite", 2}},
|
||||
result = "graphite"
|
||||
}
|
||||
},
|
||||
{
|
||||
type = "technology",
|
||||
name = "graphite-processing",
|
||||
icon_size = 128,
|
||||
-- icon = "__bzcarbon__/graphics/technology/graphite-processing.png",
|
||||
icon = "__bzcarbon__/graphics/icons/graphite.png",
|
||||
effects =
|
||||
{
|
||||
{
|
||||
type = "unlock-recipe",
|
||||
recipe = "graphite"
|
||||
},
|
||||
},
|
||||
unit =
|
||||
{
|
||||
count = 30,
|
||||
ingredients =
|
||||
{
|
||||
{"automation-science-pack", 1},
|
||||
},
|
||||
time = 10,
|
||||
},
|
||||
prerequisites = {"automation"},
|
||||
order = "b-b"
|
||||
},
|
||||
|
||||
|
||||
-- diamonds
|
||||
{
|
||||
type = "item",
|
||||
name = "diamond",
|
||||
icon = "__bzcarbon__/graphics/icons/diamond.png",
|
||||
icon_size = 128,
|
||||
subgroup = "raw-material",
|
||||
order = "g[diamond]",
|
||||
stack_size = util.get_stack_size(100)
|
||||
},
|
||||
{
|
||||
type = "recipe",
|
||||
name = "synthetic-diamond",
|
||||
category = "diamond-synthesis",
|
||||
order = "d[diamond]",
|
||||
icons = (mods["Krastorio2"] and
|
||||
{
|
||||
{ icon = "__bzcarbon__/graphics/icons/diamond.png", icon_size = 128},
|
||||
{ icon = "__bzcarbon__/graphics/icons/graphite-2.png", icon_size = 128, scale=0.125, shift= {-8, -8}},
|
||||
} or nil),
|
||||
normal = (mods["Krastorio2"] and
|
||||
{
|
||||
enabled = false,
|
||||
energy_required = 20,
|
||||
ingredients = {{"graphite", 10}},
|
||||
results = {{type="item", name= "diamond", amount=1}},
|
||||
} or
|
||||
{
|
||||
enabled = false,
|
||||
energy_required = 20,
|
||||
ingredients = {{"graphite", 10}},
|
||||
result = "diamond"
|
||||
}),
|
||||
expensive =
|
||||
{
|
||||
enabled = false,
|
||||
energy_required = 30,
|
||||
ingredients = {{"graphite", 20}},
|
||||
result = "diamond"
|
||||
}
|
||||
},
|
||||
{
|
||||
type = "technology",
|
||||
name = "synthetic-diamond-processing",
|
||||
icon_size = 128,
|
||||
icon = "__bzcarbon__/graphics/icons/diamond.png",
|
||||
effects =
|
||||
{
|
||||
{
|
||||
type = "unlock-recipe",
|
||||
recipe = "synthetic-diamond"
|
||||
},
|
||||
},
|
||||
unit =
|
||||
{
|
||||
count = 100,
|
||||
ingredients =
|
||||
{
|
||||
{"automation-science-pack", 1},
|
||||
{"logistic-science-pack", 1},
|
||||
{"chemical-science-pack", 1},
|
||||
},
|
||||
time = 15,
|
||||
},
|
||||
prerequisites = {"chemical-science-pack"},
|
||||
order = "b-b"
|
||||
},
|
||||
|
||||
-- graphene
|
||||
{
|
||||
type = "item",
|
||||
name = "graphene",
|
||||
icon = "__bzcarbon__/graphics/icons/graphene.png",
|
||||
icon_size = 128,
|
||||
subgroup = "intermediate-product",
|
||||
order = "g[graphite]",
|
||||
stack_size = util.get_stack_size(200)
|
||||
},
|
||||
{
|
||||
type = "recipe",
|
||||
name = "graphene",
|
||||
category = "chemistry",
|
||||
order = "d[graphite]",
|
||||
enabled = false,
|
||||
energy_required = 6,
|
||||
ingredients = mods.Krastorio2 and {
|
||||
{type="item", name="graphite", amount=1},
|
||||
{type="fluid", name="ammonia", amount=5},
|
||||
{type="fluid", name="sulfuric-acid", amount=5},
|
||||
} or {
|
||||
{type="item", name="graphite", amount=1},
|
||||
{type="fluid", name="water", amount=10},
|
||||
{type="fluid", name="sulfuric-acid", amount=10},
|
||||
},
|
||||
result = "graphene"
|
||||
},
|
||||
{
|
||||
type = "technology",
|
||||
name = "graphene",
|
||||
icon_size = 128,
|
||||
icon = "__bzcarbon__/graphics/icons/graphene.png",
|
||||
effects =
|
||||
{
|
||||
{
|
||||
type = "unlock-recipe",
|
||||
recipe = "graphene"
|
||||
},
|
||||
},
|
||||
unit =
|
||||
{
|
||||
count = 400,
|
||||
ingredients = mods["space-exploration"] and {
|
||||
{"automation-science-pack", 1},
|
||||
{"logistic-science-pack", 1},
|
||||
{"chemical-science-pack", 1},
|
||||
} or
|
||||
{
|
||||
{"automation-science-pack", 1},
|
||||
{"logistic-science-pack", 1},
|
||||
{"chemical-science-pack", 1},
|
||||
{"production-science-pack", 1},
|
||||
{"utility-science-pack", 1},
|
||||
},
|
||||
time = 60,
|
||||
},
|
||||
prerequisites = mods["space-exploration"] and {"chemical-science-pack"} or {"utility-science-pack"},
|
||||
order = "b-b"
|
||||
},
|
||||
})
|
||||
|
||||
-- fullerenes
|
||||
if util.me.use_fullerenes() then
|
||||
function lds_recipe()
|
||||
if mods.bztitanium then
|
||||
if mods.bzzirconium then
|
||||
return {
|
||||
{type="item", name="titanium-plate", amount=2},
|
||||
{type="item", name="nanotubes", amount=2},
|
||||
{type="item", name="plastic-bar", amount=2},
|
||||
{type="item", name="zirconia", amount=2},
|
||||
{type="item", name="diamond", amount=1},
|
||||
}
|
||||
end
|
||||
return {
|
||||
{type="item", name="titanium-plate", amount=2},
|
||||
{type="item", name="nanotubes", amount=5},
|
||||
{type="item", name="plastic-bar", amount=5},
|
||||
{type="item", name="diamond", amount=1},
|
||||
}
|
||||
elseif mods.bzzirconium then
|
||||
return {
|
||||
{type="item", name="zirconia", amount=5},
|
||||
{type="item", name="copper-plate", amount=5},
|
||||
{type="item", name="nanotubes", amount=5},
|
||||
{type="item", name="plastic-bar", amount=2},
|
||||
{type="item", name="diamond", amount=1},
|
||||
}
|
||||
else
|
||||
return {
|
||||
{type="item", name="copper-plate", amount=10},
|
||||
{type="item", name="nanotubes", amount=5},
|
||||
{type="item", name="plastic-bar", amount=5},
|
||||
{type="item", name="diamond", amount=1},
|
||||
}
|
||||
end
|
||||
end
|
||||
|
||||
data:extend({
|
||||
{
|
||||
type = "item",
|
||||
name = "fullerenes",
|
||||
icon = "__bzcarbon__/graphics/icons/Fullerene.png",
|
||||
icon_size = 128,
|
||||
subgroup = "intermediate-product",
|
||||
order = "g[graphite-fullerenes]",
|
||||
stack_size = util.get_stack_size(200),
|
||||
},
|
||||
{
|
||||
type = "recipe",
|
||||
name = "fullerenes",
|
||||
category = "chemistry",
|
||||
order = "d[graphite-fullerenes]",
|
||||
enabled = false,
|
||||
energy_required = 1,
|
||||
ingredients = mods.Krastorio2 and
|
||||
{
|
||||
{type="item", name="graphite", amount=2},
|
||||
{type="fluid", name="nitrogen", amount=2},
|
||||
} or
|
||||
{
|
||||
{type="item", name="graphite", amount=2},
|
||||
},
|
||||
result = "fullerenes",
|
||||
result_count = 20,
|
||||
},
|
||||
{
|
||||
type = "technology",
|
||||
name = "fullerenes",
|
||||
icon_size = 128,
|
||||
icon = "__bzcarbon__/graphics/icons/Fullerene.png",
|
||||
effects =
|
||||
{
|
||||
{
|
||||
type = "unlock-recipe",
|
||||
recipe = "fullerenes",
|
||||
},
|
||||
},
|
||||
unit =
|
||||
{
|
||||
count = 100,
|
||||
ingredients = {
|
||||
{"automation-science-pack", 1},
|
||||
{"logistic-science-pack", 1},
|
||||
{"chemical-science-pack", 1},
|
||||
},
|
||||
time = 60,
|
||||
},
|
||||
prerequisites = {"oil-processing", "chemical-science-pack"},
|
||||
order = "b-b"
|
||||
},
|
||||
-- nanotubes
|
||||
{
|
||||
type = "item",
|
||||
name = "nanotubes",
|
||||
icon = "__bzcarbon__/graphics/icons/nanotube.png",
|
||||
icon_size = 128,
|
||||
subgroup = "intermediate-product",
|
||||
order = "g[graphite-nanotubes]",
|
||||
stack_size = util.get_stack_size(200),
|
||||
},
|
||||
{
|
||||
type = "recipe",
|
||||
name = "nanotubes",
|
||||
icon = "__bzcarbon__/graphics/icons/nanotube.png",
|
||||
icon_size = 128,
|
||||
category = "chemistry",
|
||||
subgroup = "intermediate-product",
|
||||
order = "d[graphite-nanotubes]",
|
||||
enabled = false,
|
||||
energy_required = 20,
|
||||
ingredients = {
|
||||
{type="item", name="fullerenes", amount=1},
|
||||
{type="item", name="iron-plate", amount=1, catalyst_amount=1},
|
||||
{type="fluid", name="sulfuric-acid", amount=10, catalyst_amount=10},
|
||||
},
|
||||
results = {
|
||||
{type="item", name="nanotubes", amount=1},
|
||||
{type="item", name="iron-plate", amount=1, probability=0.95, catalyst_amount=1},
|
||||
{type="fluid", name="sulfuric-acid", amount=9, catalyst_amount=9},
|
||||
mods.Krastorio2 and {type="fluid", name="dirty-water", amount=1, catalyst_amount=1} or nil,
|
||||
},
|
||||
},
|
||||
{
|
||||
type = "recipe",
|
||||
name = "low-density-structure-nanotubes",
|
||||
icons = {
|
||||
{ icon = "__base__/graphics/icons/low-density-structure.png", icon_size = 64, icon_mipmaps = 4},
|
||||
{ icon = "__bzcarbon__/graphics/icons/nanotube.png", icon_size = 128, scale=0.125, shift= {-8, -8}},
|
||||
},
|
||||
category = "advanced-crafting",
|
||||
order = "o[low-density-structure-nanotubes]",
|
||||
enabled = false,
|
||||
energy_required = 20,
|
||||
ingredients = lds_recipe(),
|
||||
result = "low-density-structure",
|
||||
result_count = 1,
|
||||
},
|
||||
{
|
||||
type = "technology",
|
||||
name = "nanotubes",
|
||||
icon_size = 128,
|
||||
icon = "__bzcarbon__/graphics/icons/nanotube.png",
|
||||
effects =
|
||||
{
|
||||
{
|
||||
type = "unlock-recipe",
|
||||
recipe = "nanotubes",
|
||||
},
|
||||
{
|
||||
type = "unlock-recipe",
|
||||
recipe = "low-density-structure-nanotubes",
|
||||
},
|
||||
},
|
||||
unit =
|
||||
{
|
||||
count = 1000,
|
||||
ingredients =
|
||||
(mods.Krastorio2 and not mods["space-exploration"] and
|
||||
{
|
||||
{"production-science-pack", 1},
|
||||
{"utility-science-pack", 1},
|
||||
{"space-science-pack", 1},
|
||||
{"matter-tech-card", 1},
|
||||
{"advanced-tech-card", 1},
|
||||
}) or
|
||||
{
|
||||
{"automation-science-pack", 1},
|
||||
{"logistic-science-pack", 1},
|
||||
{"chemical-science-pack", 1},
|
||||
{"production-science-pack", 1},
|
||||
{"utility-science-pack", 1},
|
||||
{"space-science-pack", 1},
|
||||
},
|
||||
time = 60,
|
||||
},
|
||||
prerequisites = {"space-science-pack"},
|
||||
order = "b-b"
|
||||
},
|
||||
})
|
||||
end
|
||||
|
||||
-- carbon black
|
||||
if util.me.use_carbon_black() then
|
||||
data:extend({
|
||||
{
|
||||
type = "item",
|
||||
name = "carbon-black",
|
||||
icon = "__bzcarbon__/graphics/icons/carbon-black.png",
|
||||
icon_size = 64,
|
||||
icon_mipmaps = 3,
|
||||
subgroup = "intermediate-product",
|
||||
order = "g[graphite-carbon-black]",
|
||||
stack_size = util.get_stack_size(100),
|
||||
},
|
||||
{
|
||||
type = "recipe",
|
||||
name = "carbon-black",
|
||||
category = "chemistry",
|
||||
order = "d[graphite-carbon-black]",
|
||||
enabled = false,
|
||||
energy_required = 1,
|
||||
ingredients = {
|
||||
{type="item", name="coal", amount=1},
|
||||
},
|
||||
result = "carbon-black",
|
||||
result_count = 1,
|
||||
},
|
||||
{
|
||||
type = "recipe",
|
||||
name = "graphite-carbon-black",
|
||||
icons = {
|
||||
{ icon = "__bzcarbon__/graphics/icons/carbon-black.png", icon_size = 64, icon_mipmaps = 3},
|
||||
{ icon = "__bzcarbon__/graphics/icons/graphite.png", icon_size = 128},
|
||||
},
|
||||
category = "chemistry",
|
||||
order = "d[graphite]",
|
||||
enabled = false,
|
||||
energy_required = 1,
|
||||
ingredients = {
|
||||
{type="item", name="carbon-black", amount=10},
|
||||
},
|
||||
result = "graphite",
|
||||
result_count = 1,
|
||||
},
|
||||
})
|
||||
end
|
||||
|
||||
|
||||
|
|
@ -2,4 +2,7 @@
|
|||
Version: 0.0.1
|
||||
Date: 2021-11-29
|
||||
Features:
|
||||
- Alpha version
|
||||
- Alpha version (things might change, possibly a lot)
|
||||
- Adds Flake Graphite, Graphite, Diamonds, Graphene
|
||||
- Optionally adds Fullerenes (default on), Carbon black (default off)
|
||||
- Initial compatibility with Krastorio 2, Space Exploration
|
||||
|
|
|
|||
|
|
@ -1,46 +1,29 @@
|
|||
require("lead-recipe-final-stacking")
|
||||
require("lead-recipe-modules")
|
||||
require("lead-recipe-colors")
|
||||
require("lead-recipe-final-5d")
|
||||
require("lead-recipe-final-rrr")
|
||||
require("carbon-recipe-final-stacking")
|
||||
require("carbon-recipe-final-k2")
|
||||
require("carbon-recipe-final-se")
|
||||
require("carbon-recipe-final-rrr")
|
||||
|
||||
require("carbon-recipe-modules") -- Should be last import
|
||||
|
||||
----
|
||||
local util = require("__bzcarbon__.data-util");
|
||||
|
||||
local util = require("__bzlead__.data-util");
|
||||
|
||||
if (not mods["pyrawores"] and not mods["bobplates"] and not mods["angelssmelting"]) then
|
||||
-- If furnaces are treated as furnaces, we need 2 outputs
|
||||
-- Only electric smelters can make Diamonds
|
||||
function diamondsInElectricSmelter(entity)
|
||||
if entity.energy_source.type == "electric" then
|
||||
local isSmelter = false
|
||||
for j, category in pairs(entity.crafting_categories) do
|
||||
if category == "smelting" then
|
||||
isSmelter = true
|
||||
end
|
||||
end
|
||||
if isSmelter then
|
||||
table.insert(entity.crafting_categories,"diamond-synthesis")
|
||||
end
|
||||
end
|
||||
end
|
||||
for i, entity in pairs(data.raw.furnace) do
|
||||
if entity.result_inventory_size ~= nil and entity.result_inventory_size < 2 and util.contains(entity.crafting_categories, "smelting") then
|
||||
entity.result_inventory_size = 2
|
||||
end
|
||||
diamondsInElectricSmelter(entity)
|
||||
end
|
||||
for i, entity in pairs(data.raw["assembling-machine"]) do
|
||||
diamondsInElectricSmelter(entity)
|
||||
end
|
||||
|
||||
if mods["Krastorio2"] then
|
||||
util.replace_ingredient("rifle-magazine", "iron-plate", "lead-plate")
|
||||
util.replace_ingredient("anti-material-rifle-magazine", "iron-plate", "lead-plate")
|
||||
util.replace_some_ingredient("kr-crusher", "iron-beam", 5, "lead-plate", 5)
|
||||
util.replace_ingredient("kr-shelter", "iron-plate", "lead-plate")
|
||||
util.add_ingredient("kr-advanced-furnace", "lead-plate", 20)
|
||||
util.replace_ingredient("uranium-fuel-cell", "steel-plate", "lead-plate")
|
||||
util.replace_some_ingredient("kr-fluid-storage-1", "steel-plate", 10, "lead-plate", 10)
|
||||
util.replace_some_ingredient("kr-fluid-storage-2", "steel-plate", 30, "lead-plate", 30)
|
||||
end
|
||||
|
||||
if mods["modmashsplintergold"] then
|
||||
if mods["Krastorio2"] then
|
||||
util.replace_ingredient("rifle-magazine-with-gold", "iron-plate", "lead-plate")
|
||||
util.replace_ingredient("anti-material-rifle-magazine-with-gold", "iron-plate", "lead-plate")
|
||||
end
|
||||
end
|
||||
|
||||
if mods["space-exploration"] then
|
||||
-- Organization
|
||||
data.raw.item["lead-plate"].subgroup = "plates"
|
||||
data.raw.recipe["lead-plate"].subgroup = "plates"
|
||||
|
||||
-- core mining balancing
|
||||
util.add_to_product("se-core-fragment-omni", "lead-ore", -4)
|
||||
end
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
require("lead-recipe-updates")
|
||||
require("lead-matter")
|
||||
require("omni")
|
||||
require("carbon-recipe-updates")
|
||||
require("map-gen-preset-updates")
|
||||
require("strange-matter")
|
||||
|
||||
-- require("carbon-matter")
|
||||
-- require("omni")
|
||||
-- require("strange-matter")
|
||||
|
|
|
|||
|
|
@ -109,7 +109,7 @@ end
|
|||
-- Add a given quantity of product to a given recipe.
|
||||
-- Only works for recipes with multiple products
|
||||
function util.add_product(recipe_name, product)
|
||||
if data.raw.recipe[recipe_name] and data.raw.item[product] then
|
||||
if data.raw.recipe[recipe_name] and (data.raw.item[product[1]] or data.raw.item[product.name]) then
|
||||
add_product(data.raw.recipe[recipe_name], product)
|
||||
add_product(data.raw.recipe[recipe_name].normal, product)
|
||||
add_product(data.raw.recipe[recipe_name].expensive, product)
|
||||
|
|
@ -274,6 +274,31 @@ function has_ingredient(recipe, ingredient)
|
|||
return false
|
||||
end
|
||||
|
||||
-- Remove a product from a recipe, WILL NOT remove the only product
|
||||
function util.remove_product(recipe_name, old)
|
||||
if me.bypass[recipe_name] then return end
|
||||
if data.raw.recipe[recipe_name] then
|
||||
remove_product(data.raw.recipe[recipe_name], old)
|
||||
remove_product(data.raw.recipe[recipe_name].normal, old)
|
||||
remove_product(data.raw.recipe[recipe_name].expensive, old)
|
||||
end
|
||||
end
|
||||
|
||||
function remove_product(recipe, old)
|
||||
index = -1
|
||||
if recipe ~= nil and recipe.results ~= nil then
|
||||
for i, result in pairs(recipe.results) do
|
||||
if result.name == old or result[1] == old then
|
||||
index = i
|
||||
break
|
||||
end
|
||||
end
|
||||
if index > -1 then
|
||||
table.remove(recipe.results, index)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
-- Replace one product with another in a recipe
|
||||
function util.replace_product(recipe_name, old, new)
|
||||
if data.raw.recipe[recipe_name] then
|
||||
|
|
|
|||
14
data.lua
|
|
@ -1,9 +1,7 @@
|
|||
require("lead-ore")
|
||||
require("lead-ore-particle")
|
||||
require("lead-recipe")
|
||||
require("other-entities")
|
||||
require("lead-enriched") -- Enriched Ti for Krastorio 2
|
||||
require("lead-recipe-se") -- Space Exploration special recipes (depends on K2 if present)
|
||||
require("lead-compressed")
|
||||
require("lead-sim")
|
||||
require("graphite")
|
||||
require("graphite-particle")
|
||||
|
||||
require("carbon-recipe")
|
||||
require("carbon-recipe-k2") -- must be after carbon-recipe
|
||||
require("carbon-recipe-se")
|
||||
|
||||
|
|
|
|||
BIN
graphics/entity/ores/graphite.png
Normal file
|
After Width: | Height: | Size: 543 KiB |
BIN
graphics/entity/ores/hr-graphite.png
Normal file
|
After Width: | Height: | Size: 1.9 MiB |
BIN
graphics/entity/ores/hr-graphite.xcf
Normal file
|
Before Width: | Height: | Size: 2.3 MiB |
|
Before Width: | Height: | Size: 638 KiB |
|
Before Width: | Height: | Size: 370 B After Width: | Height: | Size: 370 B |
|
Before Width: | Height: | Size: 342 B After Width: | Height: | Size: 342 B |
|
Before Width: | Height: | Size: 310 B After Width: | Height: | Size: 310 B |
|
Before Width: | Height: | Size: 299 B After Width: | Height: | Size: 299 B |
|
Before Width: | Height: | Size: 148 B After Width: | Height: | Size: 148 B |
|
Before Width: | Height: | Size: 127 B After Width: | Height: | Size: 127 B |
|
Before Width: | Height: | Size: 125 B After Width: | Height: | Size: 125 B |
|
Before Width: | Height: | Size: 122 B After Width: | Height: | Size: 122 B |
|
Before Width: | Height: | Size: 812 B After Width: | Height: | Size: 812 B |
|
Before Width: | Height: | Size: 711 B After Width: | Height: | Size: 711 B |
|
Before Width: | Height: | Size: 572 B After Width: | Height: | Size: 572 B |
|
Before Width: | Height: | Size: 627 B After Width: | Height: | Size: 627 B |
|
Before Width: | Height: | Size: 239 B After Width: | Height: | Size: 239 B |
|
Before Width: | Height: | Size: 215 B After Width: | Height: | Size: 215 B |
|
Before Width: | Height: | Size: 202 B After Width: | Height: | Size: 202 B |
|
Before Width: | Height: | Size: 203 B After Width: | Height: | Size: 203 B |
BIN
graphics/icons/Fullerene.png
Normal file
|
After Width: | Height: | Size: 31 KiB |
BIN
graphics/icons/Fullerene.xcf
Normal file
BIN
graphics/icons/carbon-black.png
Normal file
|
After Width: | Height: | Size: 7.2 KiB |
BIN
graphics/icons/carbon-black.xcf
Normal file
|
Before Width: | Height: | Size: 10 KiB |
BIN
graphics/icons/diamond.png
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
graphics/icons/diamond.xcf
Normal file
|
Before Width: | Height: | Size: 40 KiB |
|
Before Width: | Height: | Size: 38 KiB |
|
Before Width: | Height: | Size: 36 KiB |
|
Before Width: | Height: | Size: 35 KiB |
BIN
graphics/icons/flake-graphite-1.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
graphics/icons/flake-graphite-1.xcf
Normal file
BIN
graphics/icons/flake-graphite-2.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
graphics/icons/flake-graphite-2.xcf
Normal file
BIN
graphics/icons/flake-graphite-3.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
graphics/icons/flake-graphite-3.xcf
Normal file
BIN
graphics/icons/flake-graphite.png
Normal file
|
After Width: | Height: | Size: 9.8 KiB |
BIN
graphics/icons/flake-graphite.xcf
Normal file
BIN
graphics/icons/graphene.png
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
graphics/icons/graphene.xcf
Normal file
BIN
graphics/icons/graphite-1.png
Normal file
|
After Width: | Height: | Size: 19 KiB |
BIN
graphics/icons/graphite-1.xcf
Normal file
BIN
graphics/icons/graphite-2.png
Normal file
|
After Width: | Height: | Size: 19 KiB |
BIN
graphics/icons/graphite-2.xcf
Normal file
BIN
graphics/icons/graphite.png
Normal file
|
After Width: | Height: | Size: 21 KiB |
BIN
graphics/icons/graphite.xcf
Normal file
BIN
graphics/icons/nanotube.png
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
graphics/icons/nanotube.xcf
Normal file
BIN
graphics/icons/stacked/carbon-black-stacked.png
Normal file
|
After Width: | Height: | Size: 5.1 KiB |
BIN
graphics/icons/stacked/carbon-black-stacked.xcf
Normal file
|
Before Width: | Height: | Size: 18 KiB |
BIN
graphics/icons/stacked/diamond-stacked.png
Normal file
|
After Width: | Height: | Size: 21 KiB |
BIN
graphics/icons/stacked/diamond-stacked.xcf
Normal file
|
Before Width: | Height: | Size: 33 KiB |
BIN
graphics/icons/stacked/flake-graphite-stacked.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
graphics/icons/stacked/flake-graphite-stacked.xcf
Normal file
BIN
graphics/icons/stacked/fullerene-stacked.png
Normal file
|
After Width: | Height: | Size: 41 KiB |
BIN
graphics/icons/stacked/fullerene-stacked.xcf
Normal file
BIN
graphics/icons/stacked/graphene-stacked.png
Normal file
|
After Width: | Height: | Size: 26 KiB |
BIN
graphics/icons/stacked/graphene-stacked.xcf
Normal file
BIN
graphics/icons/stacked/graphite-stacked.png
Normal file
|
After Width: | Height: | Size: 21 KiB |
BIN
graphics/icons/stacked/graphite-stacked.xcf
Normal file
BIN
graphics/icons/stacked/nanotube-stacked.png
Normal file
|
After Width: | Height: | Size: 21 KiB |
BIN
graphics/icons/stacked/nanotube-stacked.xcf
Normal file
|
Before Width: | Height: | Size: 15 KiB |
|
Before Width: | Height: | Size: 16 KiB |
|
Before Width: | Height: | Size: 18 KiB |
|
Before Width: | Height: | Size: 10 KiB |