k2
This commit is contained in:
parent
ab65faccfb
commit
b6c08c7613
7 changed files with 75 additions and 48 deletions
|
|
@ -1,7 +1,6 @@
|
||||||
-- Matter recipes for Krastorio2
|
-- Matter recipes for Krastorio2
|
||||||
if mods["Krastorio2"] then
|
if mods["Krastorio2"] then
|
||||||
local util = require("data-util");
|
local util = require("data-util");
|
||||||
local matter = require("__Krastorio2__/lib/public/data-stages/matter-util")
|
|
||||||
|
|
||||||
data:extend(
|
data:extend(
|
||||||
{
|
{
|
||||||
|
|
@ -20,6 +19,7 @@ data:extend(
|
||||||
scale = 1.4,
|
scale = 1.4,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
effects = {},
|
||||||
prerequisites = {"kr-matter-processing"},
|
prerequisites = {"kr-matter-processing"},
|
||||||
unit =
|
unit =
|
||||||
{
|
{
|
||||||
|
|
@ -28,45 +28,58 @@ data:extend(
|
||||||
{
|
{
|
||||||
{"production-science-pack", 1},
|
{"production-science-pack", 1},
|
||||||
{"utility-science-pack", 1},
|
{"utility-science-pack", 1},
|
||||||
{"matter-tech-card", 1}
|
{"kr-matter-tech-card", 1}
|
||||||
},
|
},
|
||||||
time = 45
|
time = 45
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
local flake_graphite_matter =
|
util.k2matter({
|
||||||
{
|
k2matter = {
|
||||||
item_name = "flake-graphite",
|
material = {
|
||||||
minimum_conversion_quantity = 10,
|
name = "flake-graphite",
|
||||||
matter_value = 5,
|
type = "item",
|
||||||
|
amount = 10,
|
||||||
|
},
|
||||||
|
matter_count = 5,
|
||||||
energy_required = 1,
|
energy_required = 1,
|
||||||
need_stabilizer = false,
|
needs_stabilizer = false,
|
||||||
unlocked_by_technology = "carbon-matter-processing"
|
allow_productivity = true,
|
||||||
|
unlocked_by = "carbon-matter-processing"
|
||||||
}
|
}
|
||||||
matter.createMatterRecipe(flake_graphite_matter)
|
})
|
||||||
|
|
||||||
local graphite_matter =
|
util.k2matter({
|
||||||
{
|
k2matter = {
|
||||||
item_name = "graphite",
|
material = {
|
||||||
minimum_conversion_quantity = 10,
|
name = "graphite",
|
||||||
matter_value = 7.5,
|
type = "item",
|
||||||
|
amount = 10,
|
||||||
|
},
|
||||||
|
matter_count = 7.5,
|
||||||
energy_required = 2,
|
energy_required = 2,
|
||||||
|
needs_stabilizer = true,
|
||||||
|
allow_productivity = true,
|
||||||
only_deconversion = true,
|
only_deconversion = true,
|
||||||
need_stabilizer = true,
|
unlocked_by = "carbon-matter-processing"
|
||||||
unlocked_by_technology = "carbon-matter-processing"
|
|
||||||
}
|
}
|
||||||
matter.createMatterRecipe(graphite_matter)
|
})
|
||||||
|
|
||||||
local diamond_matter =
|
util.k2matter({
|
||||||
{
|
k2matter = {
|
||||||
item_name = "diamond",
|
material = {
|
||||||
minimum_conversion_quantity = 1,
|
name = "diamond",
|
||||||
matter_value = 8,
|
type = "item",
|
||||||
|
amount = 1,
|
||||||
|
},
|
||||||
|
matter_count = 8,
|
||||||
energy_required = 2,
|
energy_required = 2,
|
||||||
|
needs_stabilizer = true,
|
||||||
|
allow_productivity = true,
|
||||||
only_deconversion = true,
|
only_deconversion = true,
|
||||||
need_stabilizer = true,
|
unlocked_by = "carbon-matter-processing"
|
||||||
unlocked_by_technology = "carbon-matter-processing"
|
|
||||||
}
|
}
|
||||||
matter.createMatterRecipe(diamond_matter)
|
})
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -32,18 +32,18 @@ data:extend({
|
||||||
},
|
},
|
||||||
ingredients = {
|
ingredients = {
|
||||||
{type="item", name="flake-graphite", amount=10},
|
{type="item", name="flake-graphite", amount=10},
|
||||||
{type="fluid", name="water", amount=25, catalyst_amount=25},
|
{type="fluid", name="water", amount=25, ignored_by_stats=25, ignored_by_productivity=25},
|
||||||
{type="fluid", name="hydrogen-chloride", amount=25},
|
{type="fluid", name="kr-hydrogen-chloride", amount=25},
|
||||||
},
|
},
|
||||||
results = {
|
results = {
|
||||||
{type="item", name="graphite", amount=18},
|
{type="item", name="graphite", amount=18},
|
||||||
{type="fluid", name="kr-dirty-water", amount=25, catalyst_amount=25},
|
{type="fluid", name="kr-dirty-water", amount=25, ignored_by_stats=25, ignored_by_productivity=25},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
type = "recipe",
|
type = "recipe",
|
||||||
name = "kr-dirty-water-filtration-graphite",
|
name = "dirty-water-filtration-graphite",
|
||||||
category = "fluid-filtration",
|
category = "kr-fluid-filtration",
|
||||||
icons =
|
icons =
|
||||||
{
|
{
|
||||||
{
|
{
|
||||||
|
|
@ -133,18 +133,18 @@ data:extend({
|
||||||
{ icon = util.k2assets().."/icons/fluids/heavy-water.png", icon_size = 64, icon_mipmaps = 3,},
|
{ 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}},
|
{ icon = "__bzcarbon__/graphics/icons/graphene.png", icon_size = 128, scale=0.25, shift= {-8, -8}},
|
||||||
},
|
},
|
||||||
category = "electrolysis",
|
category = "kr-electrolysis",
|
||||||
subgroup = "fluid-recipes",
|
subgroup = "fluid-recipes",
|
||||||
order = "y06[heavy-water]",
|
order = "y06[heavy-water]",
|
||||||
enabled = false,
|
enabled = false,
|
||||||
energy_required = 60,
|
energy_required = 60,
|
||||||
ingredients = {
|
ingredients = {
|
||||||
{type="item", name="graphene", amount=1, catalyst_amount=1},
|
{type="item", name="graphene", amount=1, ignored_by_stats=1, ignored_by_productivity=1},
|
||||||
{type="fluid", name="water", amount=500},
|
{type="fluid", name="water", amount=500},
|
||||||
},
|
},
|
||||||
results = {
|
results = {
|
||||||
{type="item", name="graphene", amount=1, probability=.8, catalyst_amount=1},
|
{type="item", name="graphene", amount=1, probability=.8, ignored_by_stats=1, ignored_by_productivity=1},
|
||||||
{type="fluid", name="heavy-water", amount=40},
|
{type="fluid", name="kr-heavy-water", amount=40},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ if mods["space-age"] then
|
||||||
graphite_category = "basic-crushing"
|
graphite_category = "basic-crushing"
|
||||||
end
|
end
|
||||||
if mods.Krastorio2 then
|
if mods.Krastorio2 then
|
||||||
graphite_category = "crushing"
|
graphite_category = "kr-crushing"
|
||||||
end
|
end
|
||||||
|
|
||||||
data:extend({
|
data:extend({
|
||||||
|
|
@ -277,6 +277,7 @@ data:extend({
|
||||||
order = "b-b"
|
order = "b-b"
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
local ammonia = mods.Krastorio2 and "kr-ammonia" or "ammonia"
|
||||||
data:extend({
|
data:extend({
|
||||||
-- graphene
|
-- graphene
|
||||||
{
|
{
|
||||||
|
|
@ -302,7 +303,8 @@ data:extend({
|
||||||
energy_required = 5,
|
energy_required = 5,
|
||||||
ingredients = (mods["space-age"] or mods.Krastorio2) and {
|
ingredients = (mods["space-age"] or mods.Krastorio2) and {
|
||||||
{type="item", name="graphite", amount=1},
|
{type="item", name="graphite", amount=1},
|
||||||
{type="fluid", name="ammonia", amount=5},
|
{type="fluid", name=ammonia, amount=5},
|
||||||
|
{type="fluid", name="water", amount=10},
|
||||||
{type="fluid", name="sulfuric-acid", amount=5},
|
{type="fluid", name="sulfuric-acid", amount=5},
|
||||||
} or {
|
} or {
|
||||||
{type="item", name="graphite", amount=1},
|
{type="item", name="graphite", amount=1},
|
||||||
|
|
@ -382,7 +384,7 @@ data:extend({
|
||||||
ingredients = mods.Krastorio2 and
|
ingredients = mods.Krastorio2 and
|
||||||
{
|
{
|
||||||
{type="item", name="graphite", amount=2},
|
{type="item", name="graphite", amount=2},
|
||||||
{type="fluid", name="nitrogen", amount=2},
|
{type="fluid", name="kr-nitrogen", amount=2},
|
||||||
} or
|
} or
|
||||||
{
|
{
|
||||||
{type="item", name="graphite", amount=2},
|
{type="item", name="graphite", amount=2},
|
||||||
|
|
@ -473,8 +475,8 @@ data:extend({
|
||||||
{"production-science-pack", 1},
|
{"production-science-pack", 1},
|
||||||
{"utility-science-pack", 1},
|
{"utility-science-pack", 1},
|
||||||
{"space-science-pack", 1},
|
{"space-science-pack", 1},
|
||||||
{"matter-tech-card", 1},
|
{"kr-matter-tech-card", 1},
|
||||||
{"advanced-tech-card", 1},
|
{"kr-advanced-tech-card", 1},
|
||||||
}) or
|
}) or
|
||||||
{
|
{
|
||||||
{"automation-science-pack", 1},
|
{"automation-science-pack", 1},
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
Version: 2.0.17
|
Version: 2.0.17
|
||||||
Date: 2025-05-03
|
Date: 2025-05-03
|
||||||
Changes:
|
Changes:
|
||||||
- K2: Compatbility updates
|
- K2: Compatbility updates (with thanks to autechr3 and pla)
|
||||||
---------------------------------------------------------------------------------------------------
|
---------------------------------------------------------------------------------------------------
|
||||||
Version: 2.0.16
|
Version: 2.0.16
|
||||||
Date: 2025-04-20
|
Date: 2025-04-20
|
||||||
|
|
|
||||||
|
|
@ -10,6 +10,13 @@ require("compatibility/orewashing")
|
||||||
-- require("omni")
|
-- require("omni")
|
||||||
|
|
||||||
local util = require("data-util");
|
local util = require("data-util");
|
||||||
|
|
||||||
|
if util.me.use_flake_graphite() then
|
||||||
|
if mods.Krastorio2 then
|
||||||
|
require("tech-triggers") -- For K2 this has to be in data updates as K2 unsafely access the tech research unit
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
util.add_gleba_rock("flake-graphite")
|
util.add_gleba_rock("flake-graphite")
|
||||||
util.add_gleba_rock("rough-diamond", 2, 3)
|
util.add_gleba_rock("rough-diamond", 2, 3)
|
||||||
|
|
||||||
|
|
|
||||||
10
data.lua
10
data.lua
|
|
@ -21,13 +21,9 @@ end
|
||||||
util.add_fluid_mining()
|
util.add_fluid_mining()
|
||||||
|
|
||||||
if util.me.use_flake_graphite() then
|
if util.me.use_flake_graphite() then
|
||||||
util.set_tech_trigger("fluid-mining", {type="craft-fluid", fluid="steam", amount=500})
|
if not mods.Krastorio2 then
|
||||||
util.set_prerequisite("fluid-mining", {"steam-power"})
|
require("tech-triggers")
|
||||||
util.add_unlock("steam-power", "copper-cable")
|
end
|
||||||
util.add_unlock("steam-power", "small-electric-pole")
|
|
||||||
util.set_prerequisite("electric-mining-drill", {"steam-power"})
|
|
||||||
util.set_tech_trigger("electric-mining-drill", {type="craft-item", item="small-electric-pole", count=10})
|
|
||||||
util.set_prerequisite("graphite-processing", {"fluid-mining", "electric-mining-drill"})
|
|
||||||
else
|
else
|
||||||
util.set_prerequisite("graphite-processing", {})
|
util.set_prerequisite("graphite-processing", {})
|
||||||
end
|
end
|
||||||
|
|
|
||||||
9
tech-triggers.lua
Normal file
9
tech-triggers.lua
Normal file
|
|
@ -0,0 +1,9 @@
|
||||||
|
local util = require("data-util");
|
||||||
|
|
||||||
|
util.set_tech_trigger("fluid-mining", {type="craft-fluid", fluid="steam", amount=500})
|
||||||
|
util.set_prerequisite("fluid-mining", {"steam-power"})
|
||||||
|
util.add_unlock("steam-power", "copper-cable")
|
||||||
|
util.add_unlock("steam-power", "small-electric-pole")
|
||||||
|
util.set_prerequisite("electric-mining-drill", {"steam-power"})
|
||||||
|
util.set_tech_trigger("electric-mining-drill", {type="craft-item", item="small-electric-pole", count=10})
|
||||||
|
util.set_prerequisite("graphite-processing", {"fluid-mining", "electric-mining-drill"})
|
||||||
Loading…
Add table
Add a link
Reference in a new issue