From 1baf16beebfe4577745e8e20b4a7237e04b6d38b Mon Sep 17 00:00:00 2001 From: Simon Brodtmann Date: Mon, 6 Oct 2025 10:55:27 +0200 Subject: [PATCH 1/7] gitignore --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index e69de29..723ef36 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +.idea \ No newline at end of file From d8dd67f5d33e4cec8b2b6a359da3769a401c1169 Mon Sep 17 00:00:00 2001 From: Simon Brodtmann Date: Mon, 6 Oct 2025 10:55:55 +0200 Subject: [PATCH 2/7] Make variable local --- recipes/silicon-vulcanite.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/silicon-vulcanite.lua b/recipes/silicon-vulcanite.lua index 962ac5b..c2d3d11 100644 --- a/recipes/silicon-vulcanite.lua +++ b/recipes/silicon-vulcanite.lua @@ -8,7 +8,7 @@ if mods["space-exploration"] then end se_delivery_cannon_recipes["silica"] = {name= "silica"} if mods["Krastorio2"] then - recipe = data.raw.recipe["silicon-vulcanite"] + local recipe = data.raw.recipe["silicon-vulcanite"] recipe.ingredients = { {"silica", 18}, string.sub(mods["space-exploration"], 1, 3) == "0.6" and From 2eccd9b53f50193aec6d94bc89278a447813e518 Mon Sep 17 00:00:00 2001 From: Simon Brodtmann Date: Mon, 6 Oct 2025 11:57:26 +0200 Subject: [PATCH 3/7] Fix silicon-vulcanite --- recipes/silicon-vulcanite.lua | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/recipes/silicon-vulcanite.lua b/recipes/silicon-vulcanite.lua index c2d3d11..19bf8f9 100644 --- a/recipes/silicon-vulcanite.lua +++ b/recipes/silicon-vulcanite.lua @@ -8,16 +8,16 @@ if mods["space-exploration"] then end se_delivery_cannon_recipes["silica"] = {name= "silica"} if mods["Krastorio2"] then - local recipe = data.raw.recipe["silicon-vulcanite"] + local recipe = data.raw.recipe["se-kr-silicon-with-vulcanite"] recipe.ingredients = { - {"silica", 18}, + {type="item", name="silica", amount=18}, string.sub(mods["space-exploration"], 1, 3) == "0.6" and - {type="fluid", name="se-pyroflux", amount=10} or {"se-vulcanite-block", 1}, + {type="fluid", name="se-pyroflux", amount=10} or {type="item", name="se-vulcanite-block", amount=1}, } recipe.category = "smelting" -- now uses pyroflux so can't be kiln in se 0.6 recipe.energy_required=21.6 recipe.results = { - {name = "silicon", amount = 6}, + {type="item", name = "kr-silicon", amount = 6}, } if string.sub(mods["space-exploration"], 1, 3) == "0.6" then table.insert(recipe.ingredients, {"kr-coke", 1}) @@ -39,12 +39,12 @@ if mods["space-exploration"] then always_show_made_in = true, allow_as_intermediate = false, ingredients = { - {name = "silica", amount = 20}, + {type="item", name = "silica", amount = 20}, string.sub(mods["space-exploration"], 1, 3) == "0.6" and - {type="fluid", name="se-pyroflux", amount=10} or {"se-vulcanite-block", 1}, + {type="fluid", name="se-pyroflux", amount=10} or {type="item", name="se-vulcanite-block", amount=1}, }, results = { - {name = "silicon", amount = 3}, + {type="item", name = "silicon", amount = 3}, }, icons = { { icon = "__bzsilicon__/graphics/icons/silicon.png", icon_size = 64, icon_mipmaps = 3 }, From 0d55409e6496221469ac4809c7062a023f6d2977 Mon Sep 17 00:00:00 2001 From: Simon Brodtmann Date: Tue, 7 Oct 2025 13:22:24 +0200 Subject: [PATCH 4/7] Fix compatibility with Bio Industries --- me.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/me.lua b/me.lua index bd93651..4e05a87 100644 --- a/me.lua +++ b/me.lua @@ -10,11 +10,11 @@ end function me.more_intermediates() if me.get_setting("bz-all-intermediates") then return true end - return mods["Bio_Industries"] or me.get_setting("bzsilicon-more-intermediates") == "yes" + return mods["Bio_Industries_2"] or me.get_setting("bzsilicon-more-intermediates") == "yes" end function me.use_bio_crushed_stone() - return mods["Bio_Industries"] and me.get_setting("bzsilicon-bio-crushed-stone") == true + return mods["Bio_Industries_2"] and me.get_setting("bzsilicon-bio-crushed-stone") == true end function me.get_setting(name) From 5c588c915e407781f8e13d569721976a3605db60 Mon Sep 17 00:00:00 2001 From: Simon Brodtmann Date: Wed, 8 Oct 2025 22:25:31 +0200 Subject: [PATCH 5/7] Update dependencies --- info.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/info.json b/info.json index 71ede75..a354f6f 100644 --- a/info.json +++ b/info.json @@ -11,7 +11,7 @@ "? Krastorio2", "? Krastorio2-spaced-out", "? space-exploration", - "? 248k", + "? 248k-Redux", "? aai-industry", "? modmashsplinterelectronics", "? bztitanium", From d23c195fa828d67fc7b7a9309389bcaf797bb80c Mon Sep 17 00:00:00 2001 From: Simon Brodtmann Date: Sat, 11 Oct 2025 18:23:07 +0200 Subject: [PATCH 6/7] Mod compatibility fixes --- prototypes/silica-recipe.lua | 9 --------- prototypes/silicon-recipe.lua | 13 ++----------- recipe-updates.lua | 9 +++++---- recipes/silicon-vulcanite.lua | 2 +- 4 files changed, 8 insertions(+), 25 deletions(-) diff --git a/prototypes/silica-recipe.lua b/prototypes/silica-recipe.lua index af205c4..8da893d 100644 --- a/prototypes/silica-recipe.lua +++ b/prototypes/silica-recipe.lua @@ -30,15 +30,6 @@ data:extend( allow_productivity = true, ingredients = {util.item("stone-crushed", 4)}, results = {util.item("silica", 5)}, - -- } or mods["aai-industry"] and { - -- type = "recipe", - -- name = "silica", - -- category = mods["space-age"] and "basic-crushing" or "crafting", - -- enabled = false, - -- energy_required = 0.5, - -- allow_productivity = true, - -- ingredients = {util.item("sand", 1)}, - -- results = {util.item("silica", 1)}, } or { type = "recipe", diff --git a/prototypes/silicon-recipe.lua b/prototypes/silicon-recipe.lua index 7b651d6..75e904a 100644 --- a/prototypes/silicon-recipe.lua +++ b/prototypes/silicon-recipe.lua @@ -6,7 +6,7 @@ if util.k2() then util.remove_raw("recipe", "kr-silicon") util.remove_recipe_effect("kr-silicon-processing", "kr-silicon") if mods["Sebs-Electrics"] then - util.add_unlock("kr-silicon-processing", "silicon") + util.add_unlock("kr-silicon-processing", "kr-silicon") end end local prerequisites = {} @@ -40,15 +40,6 @@ data:extend( allow_productivity = true, ingredients = {util.item("silica", 10)}, results = {util.item("silicon", 1)} - -- expensive = - -- { - -- enabled = false, - -- energy_required = 3.2, - -- ingredients = {{"silica", 10}}, - -- result = "silicon", - -- result_count = 1 - -- }, - }, (not util.k2()) and { @@ -209,7 +200,7 @@ if not mods["space-age"] then end end util.add_effect("kr-fluids-chemistry", {type="unlock-recipe", recipe="kr-hydrogen-chloride"}) -util.add_unlock("kr-silicon-processing", "silicon") +util.add_unlock("kr-silicon-processing", mods.Krastorio2 and "kr-silicon" or "silicon") if util.me.more_intermediates() and not mods["space-age"] then diff --git a/recipe-updates.lua b/recipe-updates.lua index 1bcc52c..0988805 100644 --- a/recipe-updates.lua +++ b/recipe-updates.lua @@ -140,7 +140,7 @@ if not util.k2() then else util.add_ingredient("concrete", "silica", 15); if not mods["aai-industry"] then - util.add_ingredient("concrete", "sand", 10); + util.add_ingredient("concrete", "kr-sand", 10); end end @@ -280,11 +280,12 @@ end -- Sand in crusher. If sand comes from stone, silica comes from sand if mods["space-age"] then - if data.raw.item["sand"] and data.raw.recipe["sand"] and #data.raw.recipe["sand"].ingredients == 1 then - data.raw.recipe["sand"].category = "basic-crushing" + local sand = mods["Krastorio2"] and "kr-sand" or "sand" + if data.raw.item[sand] and data.raw.recipe[sand] and #data.raw.recipe[sand].ingredients == 1 then + data.raw.recipe[sand].category = "basic-crushing" log(serpent.block(data.raw.recipe.sand)) if data.raw.recipe.sand.ingredients[1].name == "stone" then - util.replace_ingredient("silica", "stone", "sand", 1) + util.replace_ingredient("silica", "stone", sand, 1) util.set_product_amount("silica", "silica", 1) util.set_recipe_time("silica", 0.5) end diff --git a/recipes/silicon-vulcanite.lua b/recipes/silicon-vulcanite.lua index 19bf8f9..a5da764 100644 --- a/recipes/silicon-vulcanite.lua +++ b/recipes/silicon-vulcanite.lua @@ -22,7 +22,7 @@ if mods["space-exploration"] then if string.sub(mods["space-exploration"], 1, 3) == "0.6" then table.insert(recipe.ingredients, {"kr-coke", 1}) recipe.icons = { - { icon = "__Krastorio2Assets__/icons/items-with-variations/silicon/silicon.png", icon_size = 64}, + { icon = "__Krastorio2Assets__/icons/items/silicon.png", icon_size = 64}, { icon = "__space-exploration-graphics__/graphics/icons/fluid/pyroflux.png", icon_size = 64, scale=0.25, shift= {-10, -10}}, } end From 9cf62985ffd20244fd7bc82a2bfd7bdee6a29f6b Mon Sep 17 00:00:00 2001 From: Simon Brodtmann Date: Mon, 13 Oct 2025 17:39:06 +0200 Subject: [PATCH 7/7] Fix some SE conditions --- recipes/silicon-vulcanite.lua | 29 +++++++++-------------------- 1 file changed, 9 insertions(+), 20 deletions(-) diff --git a/recipes/silicon-vulcanite.lua b/recipes/silicon-vulcanite.lua index a5da764..36eceb0 100644 --- a/recipes/silicon-vulcanite.lua +++ b/recipes/silicon-vulcanite.lua @@ -1,7 +1,7 @@ local util = require("data-util"); if mods["space-exploration"] then - if string.sub(mods["space-exploration"], 1, 3) == "0.6" and data.raw["item-subgroup"]["stone"] then + if data.raw["item-subgroup"]["stone"] then util.set_item_subgroup("silica", "stone") util.set_item_subgroup("silicon", "stone") util.set_subgroup("silicon", "stone") @@ -11,21 +11,18 @@ if mods["space-exploration"] then local recipe = data.raw.recipe["se-kr-silicon-with-vulcanite"] recipe.ingredients = { {type="item", name="silica", amount=18}, - string.sub(mods["space-exploration"], 1, 3) == "0.6" and - {type="fluid", name="se-pyroflux", amount=10} or {type="item", name="se-vulcanite-block", amount=1}, + {type="fluid", name="se-pyroflux", amount=10}, } recipe.category = "smelting" -- now uses pyroflux so can't be kiln in se 0.6 recipe.energy_required=21.6 recipe.results = { {type="item", name = "kr-silicon", amount = 6}, } - if string.sub(mods["space-exploration"], 1, 3) == "0.6" then - table.insert(recipe.ingredients, {"kr-coke", 1}) - recipe.icons = { - { icon = "__Krastorio2Assets__/icons/items/silicon.png", icon_size = 64}, - { icon = "__space-exploration-graphics__/graphics/icons/fluid/pyroflux.png", icon_size = 64, scale=0.25, shift= {-10, -10}}, - } - end + table.insert(recipe.ingredients, { type = "item", name = "kr-coke", amount = 1 }) + recipe.icons = { + { icon = "__Krastorio2Assets__/icons/items/silicon.png", icon_size = 64}, + { icon = "__space-exploration-graphics__/graphics/icons/fluid/pyroflux.png", icon_size = 64, scale=0.25, shift= {-10, -10}}, + } else se_delivery_cannon_recipes["silicon"] = {name= "silicon"} data:extend({ @@ -40,26 +37,18 @@ if mods["space-exploration"] then allow_as_intermediate = false, ingredients = { {type="item", name = "silica", amount = 20}, - string.sub(mods["space-exploration"], 1, 3) == "0.6" and - {type="fluid", name="se-pyroflux", amount=10} or {type="item", name="se-vulcanite-block", amount=1}, + {type="fluid", name="se-pyroflux", amount=10}, }, results = { {type="item", name = "silicon", amount = 3}, }, icons = { { icon = "__bzsilicon__/graphics/icons/silicon.png", icon_size = 64, icon_mipmaps = 3 }, - string.sub(mods["space-exploration"], 1, 3) == "0.6" and - { icon = "__space-exploration-graphics__/graphics/icons/fluid/pyroflux.png", icon_size = 64, scale=0.25, shift= {-10, -10}} or - { icon = "__space-exploration-graphics__/graphics/icons/vulcanite-block.png", icon_size = 64, scale=0.25, shift= {-10, -10}}, + { icon = "__space-exploration-graphics__/graphics/icons/fluid/pyroflux.png", icon_size = 64, scale=0.25, shift= {-10, -10}} }, }, }) - if string.sub(mods["space-exploration"], 1, 3) == "0.6" then util.add_effect("se-vulcanite-smelting", {type = "unlock-recipe", recipe= "silicon-smelting-vulcanite"}) util.add_effect("se-pyroflux-smelting", {type = "unlock-recipe", recipe= "silicon-smelting-vulcanite"}) - else - table.insert(data.raw.technology["se-processing-vulcanite"].effects, - {type = "unlock-recipe", recipe= "silicon-smelting-vulcanite"}) - end end end