diff --git a/changelog.txt b/changelog.txt index 76266ed..7915fe4 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,4 +1,9 @@ --------------------------------------------------------------------------------------------------- +Version: 1.2.13 +Date: 2022-08-17 + Fixes: + - SE: Disable matter recipes at start +--------------------------------------------------------------------------------------------------- Version: 1.2.12 Date: 2022-08-16 Features: diff --git a/data-util.lua b/data-util.lua index e6677aa..45b3a28 100644 --- a/data-util.lua +++ b/data-util.lua @@ -89,6 +89,34 @@ function util.contains(table, sought) return false end + +-- se landfill +-- params: ore, icon_size +function util.se_landfill(params) + if mods["space-exploration"] then + if not params.icon_size then params.icon_size = 64 end + local lname="landfill-"..params.ore + data:extend({ + { + type = "recipe", + icons = { + { icon = "__base__/graphics/icons/landfill.png", icon_size = 64, icon_mipmaps = 3 }, + { icon = "__"..me.name.."__/graphics/icons/"..params.ore..".png", icon_size = params.icon_size, scale = 0.33*64/params.icon_size}, + }, + energy_required = 1, + enabled=false, + name = lname, + category = "hard-recycling", + order = "z-b-"..params.ore, + subgroup = "terrain", + result = "landfill", + ingredients = {{params.ore, 50}}, + } + }) + util.add_unlock("se-recycling-facility", lname) + end +end + -- se matter -- params: ore, energy_required, quant_out, quant_in, icon_size, stream_out function util.se_matter(params) @@ -117,6 +145,7 @@ function util.se_matter(params) icon_size = 64, scale = 0.5}, }, energy_required = params.energy_required, + enabled = false, ingredients = { {sedata, 1}, {type="fluid", name="se-particle-stream", amount=50}, @@ -127,7 +156,7 @@ function util.se_matter(params) {"se-contaminated-scrap", 1}, {type=item, name=sedata, amount=1, probability=.99}, {type=item, name=sejunk, amount=1, probability=.01}, - {type="fluid", name="se-space-coolant-hot", amount=25}, + {type="fluid", name="se-space-coolant-hot", amount=25, catalyst_amount=25}, } } }) @@ -136,6 +165,7 @@ function util.se_matter(params) if mods.Krastorio2 then local lname = params.ore.."-to-particle-stream" data:extend({ + enabled = false, { type = "recipe", name = lname, @@ -154,6 +184,7 @@ function util.se_matter(params) icon_size = 64, scale = 0.5}, }, energy_required = 30, + enabled = false, ingredients = { {"se-kr-matter-liberation-data", 1}, {params.ore, params.quant_in}, @@ -162,7 +193,7 @@ function util.se_matter(params) results = { {type=item, name="se-kr-matter-liberation-data", amount=1, probability=.99}, {type=item, name=sejunk, amount=1, probability=.01}, - {type="fluid", name="se-particle-stream", amount=params.stream_out}, + {type="fluid", name="se-particle-stream", amount=params.stream_out, catalyst_amount=50}, } } }) diff --git a/info.json b/info.json index e78e2df..1b014a9 100644 --- a/info.json +++ b/info.json @@ -1,6 +1,6 @@ { "name": "bzlead", - "version": "1.2.12", + "version": "1.2.13", "factorio_version": "1.1", "title": "Lead", "author": "Brevven", diff --git a/lead-recipe-se.lua b/lead-recipe-se.lua index ac8ceff..a3fd5d1 100644 --- a/lead-recipe-se.lua +++ b/lead-recipe-se.lua @@ -4,22 +4,7 @@ local util = require("data-util"); if mods["space-exploration"] then se_delivery_cannon_recipes[util.me.lead_ore] = {name= util.me.lead_ore} se_delivery_cannon_recipes[util.me.lead_plate] = {name= util.me.lead_plate} - - data:extend({ - { - type = "recipe", - icons = { - { icon = "__base__/graphics/icons/landfill.png", icon_size = 64, icon_mipmaps = 3 }, - { icon = "__bzlead__/graphics/icons/lead-ore.png", icon_size = 64, scale = 0.25}, - }, - name = "landfill-lead-ore", - category = "hard-recycling", - order = "z-b-lead", - subgroup = "terrain", - result = "landfill", - ingredients = {{"lead-ore", 50}}, - } - }) + util.se_landfill({ore="lead-ore"}) if string.sub(mods["space-exploration"], 1, 3) == "0.6" then util.se_matter({ore="lead-ore", energy_required=1, quant_out=10, stream_out=60})