From 7b088215cba3ee36a87e2569404cc764412462af Mon Sep 17 00:00:00 2001 From: KiwiHawk <59639+KiwiHawk@users.noreply.github.com> Date: Wed, 29 May 2024 20:13:16 +1200 Subject: [PATCH 01/12] Power armor 2 prerequisites --- bobwarfare/prototypes/technology/technology-updates.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bobwarfare/prototypes/technology/technology-updates.lua b/bobwarfare/prototypes/technology/technology-updates.lua index 047a1674e..83bc6efe1 100644 --- a/bobwarfare/prototypes/technology/technology-updates.lua +++ b/bobwarfare/prototypes/technology/technology-updates.lua @@ -579,10 +579,12 @@ bobmods.lib.tech.add_prerequisite("power-armor", "advanced-electronics") -- By default, electric engines are Blue Science if (not mods["bobplates"]) and (not mods["boblogistics"]) then bobmods.lib.tech.remove_prerequisite("power-armor", "electric-engine") + bobmods.lib.tech.add_prerequisite("power-armor-mk2", "electric-engine") end bobmods.lib.tech.remove_science_pack("power-armor-mk2", "utility-science-pack") bobmods.lib.tech.remove_prerequisite("power-armor-mk2", "military-4") bobmods.lib.tech.add_prerequisite("power-armor-mk2", "military-3") +bobmods.lib.tech.add_prerequisite("power-armor-mk2", "low-density-structure") bobmods.lib.tech.replace_prerequisite("battery-mk2-equipment", "power-armor", "chemical-science-pack") From b2ea2a697cd19cd1b0e843a488d3570d84bf8847 Mon Sep 17 00:00:00 2001 From: KiwiHawk <59639+KiwiHawk@users.noreply.github.com> Date: Wed, 29 May 2024 20:16:10 +1200 Subject: [PATCH 02/12] Night vision ingredients and prerequisites --- bobequipment/prototypes/recipe/equipment.lua | 3 ++- bobequipment/prototypes/technology/equipment.lua | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/bobequipment/prototypes/recipe/equipment.lua b/bobequipment/prototypes/recipe/equipment.lua index 94806c5df..ab9b81e0d 100644 --- a/bobequipment/prototypes/recipe/equipment.lua +++ b/bobequipment/prototypes/recipe/equipment.lua @@ -152,6 +152,7 @@ data:extend({ }, }) +bobmods.lib.recipe.replace_ingredient("night-vision-equipment", "advanced-circuit", "electronic-circuit") data:extend({ { type = "recipe", @@ -160,7 +161,7 @@ data:extend({ energy_required = 10, ingredients = { { "night-vision-equipment", 1 }, - { "processing-unit", 5 }, + { "advanced-circuit", 5 }, { "plastic-bar", 2 }, }, result = "night-vision-equipment-2", diff --git a/bobequipment/prototypes/technology/equipment.lua b/bobequipment/prototypes/technology/equipment.lua index c11c99c36..1f3c03fbe 100644 --- a/bobequipment/prototypes/technology/equipment.lua +++ b/bobequipment/prototypes/technology/equipment.lua @@ -374,8 +374,8 @@ data:extend({ }), order = "g-g-b", prerequisites = { + "chemical-science-pack", "night-vision-equipment", - "advanced-electronics-2", }, effects = { { @@ -405,6 +405,7 @@ data:extend({ icon_mipmaps = 4, order = "g-g-c", prerequisites = { + "advanced-electronics-2", "night-vision-equipment-2", "production-science-pack", }, From aa02979177924c81e0a84bff5a786b31164ff158 Mon Sep 17 00:00:00 2001 From: KiwiHawk <59639+KiwiHawk@users.noreply.github.com> Date: Wed, 29 May 2024 20:28:18 +1200 Subject: [PATCH 03/12] Personal Battery Ingredients --- bobequipment/prototypes/recipe/equipment.lua | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/bobequipment/prototypes/recipe/equipment.lua b/bobequipment/prototypes/recipe/equipment.lua index ab9b81e0d..bd406e6dc 100644 --- a/bobequipment/prototypes/recipe/equipment.lua +++ b/bobequipment/prototypes/recipe/equipment.lua @@ -58,7 +58,13 @@ data:extend({ }, }) -data.raw.recipe["battery-mk2-equipment"].ingredients = { { "battery-equipment", 2 }, { "processing-unit", 5 } } +bobmods.lib.recipe.remove_ingredient("battery-equipment", "steel-plate") +bobmods.lib.recipe.add_ingredient("battery-equipment", { "electronic-circuit", 5 } ) + +data.raw.recipe["battery-mk2-equipment"].ingredients = { + { "battery-equipment", 2 }, + { "advanced-circuit", 5 }, +} data:extend({ { From b7d6c7d543a33ba398b060298f6834360610f2de Mon Sep 17 00:00:00 2001 From: KiwiHawk <59639+KiwiHawk@users.noreply.github.com> Date: Wed, 29 May 2024 20:31:40 +1200 Subject: [PATCH 04/12] Belt Immunity Equipment Ingredients --- bobequipment/prototypes/recipe/equipment.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bobequipment/prototypes/recipe/equipment.lua b/bobequipment/prototypes/recipe/equipment.lua index bd406e6dc..53e2715e9 100644 --- a/bobequipment/prototypes/recipe/equipment.lua +++ b/bobequipment/prototypes/recipe/equipment.lua @@ -330,3 +330,5 @@ data:extend({ result = "exoskeleton-equipment-3", }, }) + +bobmods.lib.recipe.replace_ingredient("belt-immunity-equipment", "advanced-circuit", "electronic-circuit") From 934ad22a0c0a36a1cec7e057f04ed09e29d63a37 Mon Sep 17 00:00:00 2001 From: KiwiHawk <59639+KiwiHawk@users.noreply.github.com> Date: Wed, 29 May 2024 20:31:52 +1200 Subject: [PATCH 05/12] Personal Battery Prerequisites --- bobequipment/prototypes/technology/equipment.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/bobequipment/prototypes/technology/equipment.lua b/bobequipment/prototypes/technology/equipment.lua index 1f3c03fbe..0429b89e9 100644 --- a/bobequipment/prototypes/technology/equipment.lua +++ b/bobequipment/prototypes/technology/equipment.lua @@ -179,6 +179,7 @@ data:extend({ }), order = "g-i-d", prerequisites = { + "advanced-electronics-2", "bob-battery-equipment-3", "production-science-pack", }, From 6a886c9ff85a7cf1927ae8fdbfbf899c9e30549f Mon Sep 17 00:00:00 2001 From: KiwiHawk <59639+KiwiHawk@users.noreply.github.com> Date: Wed, 29 May 2024 20:47:52 +1200 Subject: [PATCH 06/12] Exoskeleton equipment and prerequisites --- bobequipment/prototypes/recipe/equipment.lua | 1 + bobequipment/prototypes/recipe/updates.lua | 2 -- bobequipment/prototypes/technology/equipment.lua | 2 ++ bobequipment/prototypes/technology/technology-updates.lua | 8 ++++++-- 4 files changed, 9 insertions(+), 4 deletions(-) diff --git a/bobequipment/prototypes/recipe/equipment.lua b/bobequipment/prototypes/recipe/equipment.lua index 53e2715e9..53f7e7f6b 100644 --- a/bobequipment/prototypes/recipe/equipment.lua +++ b/bobequipment/prototypes/recipe/equipment.lua @@ -302,6 +302,7 @@ data:extend({ }, }) +bobmods.lib.recipe.replace_ingredient("exoskeleton-equipment", "processing-unit", "advanced-circuit") data:extend({ { type = "recipe", diff --git a/bobequipment/prototypes/recipe/updates.lua b/bobequipment/prototypes/recipe/updates.lua index d3fbb1ef6..e543f4619 100644 --- a/bobequipment/prototypes/recipe/updates.lua +++ b/bobequipment/prototypes/recipe/updates.lua @@ -347,8 +347,6 @@ if data.raw.item["silicon-wafer"] then bobmods.lib.recipe.add_ingredient("solar-panel-equipment-3", { "silicon-wafer", 8 }) end -bobmods.lib.recipe.replace_ingredient("exoskeleton-equipment", "processing-unit", "advanced-circuit") - if data.raw.item["advanced-processing-unit"] then bobmods.lib.recipe.replace_ingredient("energy-shield-mk3-equipment", "processing-unit", "advanced-processing-unit") bobmods.lib.tech.add_prerequisite("bob-energy-shield-equipment-3", "advanced-electronics-3") diff --git a/bobequipment/prototypes/technology/equipment.lua b/bobequipment/prototypes/technology/equipment.lua index 0429b89e9..385238989 100644 --- a/bobequipment/prototypes/technology/equipment.lua +++ b/bobequipment/prototypes/technology/equipment.lua @@ -687,6 +687,8 @@ data:extend({ }, }) +bobmods.lib.tech.remove_prerequisite("exoskeleton-equipment", "advanced-electronics-2") + data:extend({ { type = "technology", diff --git a/bobequipment/prototypes/technology/technology-updates.lua b/bobequipment/prototypes/technology/technology-updates.lua index b7245be95..1182a48c7 100644 --- a/bobequipment/prototypes/technology/technology-updates.lua +++ b/bobequipment/prototypes/technology/technology-updates.lua @@ -1,8 +1,12 @@ -if mods["boblogistics"] then - -- Bob's Logistics mod removes blue science from Electric engine and Robotics +if mods["boblogistics"] or mods["bobplates"] then + -- Bob's Logistics mod and Bob's MCI mod remove blue science from Electric engine and Robotics bobmods.lib.tech.remove_science_pack("exoskeleton-equipment", "chemical-science-pack") bobmods.lib.tech.remove_prerequisite("exoskeleton-equipment", "advanced-electronics-2") +end + +if mods["boblogistics"] then + -- Bob's Logistics mod removes blue science from Electric engine bobmods.lib.tech.remove_prerequisite("personal-roboport-equipment", "chemical-science-pack") bobmods.lib.tech.remove_science_pack("personal-roboport-equipment", "chemical-science-pack") From 3c3fd824613e4fa60c8310ad87b7a3b0d215459f Mon Sep 17 00:00:00 2001 From: KiwiHawk <59639+KiwiHawk@users.noreply.github.com> Date: Wed, 29 May 2024 21:00:57 +1200 Subject: [PATCH 07/12] Laser Defense Equipment ingredients and prerequisites --- bobequipment/prototypes/recipe/equipment.lua | 9 ++++++--- bobequipment/prototypes/recipe/updates.lua | 9 +++------ bobequipment/prototypes/technology/equipment.lua | 4 ++++ 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/bobequipment/prototypes/recipe/equipment.lua b/bobequipment/prototypes/recipe/equipment.lua index 53f7e7f6b..a0e447d26 100644 --- a/bobequipment/prototypes/recipe/equipment.lua +++ b/bobequipment/prototypes/recipe/equipment.lua @@ -231,8 +231,11 @@ data:extend({ }, }) -data.raw.recipe["personal-laser-defense-equipment"].ingredients = - { { "steel-plate", 5 }, { "electronic-circuit", 5 }, { "battery", 3 } } +data.raw.recipe["personal-laser-defense-equipment"].ingredients = { + { "steel-plate", 5 }, + { "advanced-circuit", 5 }, + { "battery", 3 } +} data:extend({ { @@ -256,7 +259,7 @@ data:extend({ ingredients = { { "personal-laser-defense-equipment-2", 1 }, { "steel-plate", 5 }, - { "advanced-circuit", 5 }, + { "processing-unit", 5 }, { "battery", 3 }, }, result = "personal-laser-defense-equipment-3", diff --git a/bobequipment/prototypes/recipe/updates.lua b/bobequipment/prototypes/recipe/updates.lua index e543f4619..853824e76 100644 --- a/bobequipment/prototypes/recipe/updates.lua +++ b/bobequipment/prototypes/recipe/updates.lua @@ -364,12 +364,9 @@ if data.raw.item["advanced-processing-unit"] then bobmods.lib.tech.add_prerequisite("night-vision-equipment-3", "advanced-electronics-3") bobmods.lib.recipe.replace_ingredient("solar-panel-equipment-4", "processing-unit", "advanced-processing-unit") bobmods.lib.tech.add_prerequisite("solar-panel-equipment-4", "advanced-electronics-3") - bobmods.lib.recipe.replace_ingredient( - "personal-laser-defense-equipment-6", - "processing-unit", - "advanced-processing-unit" - ) - bobmods.lib.tech.add_prerequisite("personal-laser-defense-equipment-6", "advanced-electronics-3") + bobmods.lib.recipe.replace_ingredient("personal-laser-defense-equipment-5", "processing-unit", "advanced-processing-unit") + bobmods.lib.recipe.replace_ingredient("personal-laser-defense-equipment-6", "processing-unit", "advanced-processing-unit") + bobmods.lib.tech.add_prerequisite("personal-laser-defense-equipment-5", "advanced-electronics-3") bobmods.lib.recipe.replace_ingredient("exoskeleton-equipment-3", "processing-unit", "advanced-processing-unit") bobmods.lib.tech.add_prerequisite("exoskeleton-equipment-3", "advanced-electronics-3") end diff --git a/bobequipment/prototypes/technology/equipment.lua b/bobequipment/prototypes/technology/equipment.lua index 385238989..c280b2c63 100644 --- a/bobequipment/prototypes/technology/equipment.lua +++ b/bobequipment/prototypes/technology/equipment.lua @@ -531,6 +531,8 @@ data.raw["technology"]["personal-laser-defense-equipment"].icons = icon_size = 128, }) bobmods.lib.tech.remove_prerequisite("personal-laser-defense-equipment", "low-density-structure") +bobmods.lib.tech.remove_prerequisite("personal-laser-defense-equipment", "military-3") +bobmods.lib.tech.remove_science_pack("personal-laser-defense-equipment", "chemical-science-pack") data:extend({ { @@ -542,6 +544,7 @@ data:extend({ }), order = "g-m-b", prerequisites = { + "chemical-science-pack", "personal-laser-defense-equipment", }, effects = { @@ -571,6 +574,7 @@ data:extend({ }), order = "g-m-c", prerequisites = { + "advanced-electronics-2", "personal-laser-defense-equipment-2", "production-science-pack", }, From b785218b5842e4f3a484b759e0b6418d249f62e6 Mon Sep 17 00:00:00 2001 From: KiwiHawk <59639+KiwiHawk@users.noreply.github.com> Date: Wed, 29 May 2024 21:04:23 +1200 Subject: [PATCH 08/12] Discharge defense equipment prerequisites --- bobwarfare/prototypes/technology/technology-updates.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/bobwarfare/prototypes/technology/technology-updates.lua b/bobwarfare/prototypes/technology/technology-updates.lua index 83bc6efe1..17f449caf 100644 --- a/bobwarfare/prototypes/technology/technology-updates.lua +++ b/bobwarfare/prototypes/technology/technology-updates.lua @@ -588,3 +588,4 @@ bobmods.lib.tech.add_prerequisite("power-armor-mk2", "military-3") bobmods.lib.tech.add_prerequisite("power-armor-mk2", "low-density-structure") bobmods.lib.tech.replace_prerequisite("battery-mk2-equipment", "power-armor", "chemical-science-pack") +bobmods.lib.tech.replace_prerequisite("discharge-defense-equipment", "power-armor", "advanced-electronics-2") From 825eee8c837fd386ef24e5692d850e0083457da2 Mon Sep 17 00:00:00 2001 From: KiwiHawk <59639+KiwiHawk@users.noreply.github.com> Date: Wed, 29 May 2024 21:51:22 +1200 Subject: [PATCH 09/12] Exoskeleton prerequisites --- bobequipment/prototypes/technology/equipment.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/bobequipment/prototypes/technology/equipment.lua b/bobequipment/prototypes/technology/equipment.lua index c280b2c63..2e50e8761 100644 --- a/bobequipment/prototypes/technology/equipment.lua +++ b/bobequipment/prototypes/technology/equipment.lua @@ -692,6 +692,7 @@ data:extend({ }) bobmods.lib.tech.remove_prerequisite("exoskeleton-equipment", "advanced-electronics-2") +bobmods.lib.tech.add_prerequisite("exoskeleton-equipment", "advanced-electronics") data:extend({ { From 33b0d4178f4c99817b85b56040d316fd0270827d Mon Sep 17 00:00:00 2001 From: KiwiHawk <59639+KiwiHawk@users.noreply.github.com> Date: Wed, 29 May 2024 23:43:11 +1200 Subject: [PATCH 10/12] Power armor ingredients and prerequisites --- bobwarfare/prototypes/recipe/armor-recipe.lua | 4 +- .../prototypes/recipe/recipe-updates.lua | 49 ++++++++++--------- bobwarfare/prototypes/technology/armor.lua | 6 ++- .../technology/technology-updates.lua | 43 +++++++++------- 4 files changed, 57 insertions(+), 45 deletions(-) diff --git a/bobwarfare/prototypes/recipe/armor-recipe.lua b/bobwarfare/prototypes/recipe/armor-recipe.lua index 663048dba..3f9bcf527 100644 --- a/bobwarfare/prototypes/recipe/armor-recipe.lua +++ b/bobwarfare/prototypes/recipe/armor-recipe.lua @@ -33,8 +33,8 @@ data:extend({ { "processing-unit", 50 }, { "steel-plate", 25 }, { "iron-plate", 25 }, - { "effectivity-module-3", 5 }, - { "speed-module-3", 5 }, + { "effectivity-module-2", 5 }, + { "speed-module-2", 5 }, }, result = "bob-power-armor-mk3", }, diff --git a/bobwarfare/prototypes/recipe/recipe-updates.lua b/bobwarfare/prototypes/recipe/recipe-updates.lua index 87c65fb33..5cf6dc59b 100644 --- a/bobwarfare/prototypes/recipe/recipe-updates.lua +++ b/bobwarfare/prototypes/recipe/recipe-updates.lua @@ -300,28 +300,33 @@ if data.raw.item["diamond-5"] then bobmods.lib.recipe.add_ingredient("bob-laser-turret-5", { "diamond-5", 1 }) end -if data.raw.module["effectivity-module-4"] then - bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk3", "effectivity-module-3", "effectivity-module-4") -end - -if data.raw.module["speed-module-4"] then - bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk3", "speed-module-3", "speed-module-4") -end - -if data.raw.module["effectivity-module-6"] then - bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk4", "effectivity-module-3", "effectivity-module-6") -end - -if data.raw.module["speed-module-6"] then - bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk4", "speed-module-3", "speed-module-6") -end - -if data.raw.module["effectivity-module-8"] then - bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk5", "effectivity-module-3", "effectivity-module-8") -end - -if data.raw.module["speed-module-8"] then - bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk5", "speed-module-3", "speed-module-8") +if mods["bobmodules"] then + if data.raw.module["effectivity-module-4"] then + bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk3", "effectivity-module-2", "effectivity-module-4") + end + + if data.raw.module["speed-module-4"] then + bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk3", "speed-module-2", "speed-module-4") + end + + if data.raw.module["effectivity-module-6"] then + bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk4", "effectivity-module-3", "effectivity-module-6") + end + + if data.raw.module["speed-module-6"] then + bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk4", "speed-module-3", "speed-module-6") + end + + if data.raw.module["effectivity-module-8"] then + bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk5", "effectivity-module-3", "effectivity-module-8") + end + + if data.raw.module["speed-module-8"] then + bobmods.lib.recipe.replace_ingredient("bob-power-armor-mk5", "speed-module-3", "speed-module-8") + end +else + bobmods.lib.recipe.replace_ingredient("power-armor-mk2", "speed-module-2", "speed-module") + bobmods.lib.recipe.replace_ingredient("power-armor-mk2", "effectivity-module-2", "effectivity-module") end if data.raw.item["alien-artifact"] then diff --git a/bobwarfare/prototypes/technology/armor.lua b/bobwarfare/prototypes/technology/armor.lua index e0f1d22a5..66128e6c7 100644 --- a/bobwarfare/prototypes/technology/armor.lua +++ b/bobwarfare/prototypes/technology/armor.lua @@ -61,9 +61,9 @@ data:extend({ icon = "__bobwarfare__/graphics/icons/technology/power-armor-mk3.png", icon_size = 64, prerequisites = { - "effectivity-module-3", + "effectivity-module-2", "power-armor-mk2", - "speed-module-3", + "speed-module-2", "production-science-pack", }, effects = { @@ -93,6 +93,8 @@ data:extend({ icon_size = 64, prerequisites = { "bob-power-armor-3", + "effectivity-module-3", + "speed-module-3", "utility-science-pack", }, effects = { diff --git a/bobwarfare/prototypes/technology/technology-updates.lua b/bobwarfare/prototypes/technology/technology-updates.lua index 17f449caf..4cf2c9632 100644 --- a/bobwarfare/prototypes/technology/technology-updates.lua +++ b/bobwarfare/prototypes/technology/technology-updates.lua @@ -526,30 +526,35 @@ if data.raw.recipe["gun-cotton-synthetic"] then bobmods.lib.tech.add_recipe_unlock("cordite-processing", "gun-cotton-synthetic") end -if data.raw.technology["speed-module-4"] then - bobmods.lib.tech.remove_prerequisite("bob-power-armor-3", "speed-module-3") - bobmods.lib.tech.add_prerequisite("bob-power-armor-3", "speed-module-4") -end +if mods["bobmodules"] then + if data.raw.technology["speed-module-4"] then + bobmods.lib.tech.remove_prerequisite("bob-power-armor-3", "speed-module-2") + bobmods.lib.tech.add_prerequisite("bob-power-armor-3", "speed-module-4") + end -if data.raw.technology["effectivity-module-4"] then - bobmods.lib.tech.remove_prerequisite("bob-power-armor-3", "effectivity-module-3") - bobmods.lib.tech.add_prerequisite("bob-power-armor-3", "effectivity-module-4") -end + if data.raw.technology["effectivity-module-4"] then + bobmods.lib.tech.remove_prerequisite("bob-power-armor-3", "effectivity-module-2") + bobmods.lib.tech.add_prerequisite("bob-power-armor-3", "effectivity-module-4") + end -if data.raw.technology["speed-module-6"] then - bobmods.lib.tech.add_prerequisite("bob-power-armor-4", "speed-module-6") -end + if data.raw.technology["speed-module-6"] then + bobmods.lib.tech.add_prerequisite("bob-power-armor-4", "speed-module-6") + end -if data.raw.technology["effectivity-module-6"] then - bobmods.lib.tech.add_prerequisite("bob-power-armor-4", "effectivity-module-6") -end + if data.raw.technology["effectivity-module-6"] then + bobmods.lib.tech.add_prerequisite("bob-power-armor-4", "effectivity-module-6") + end -if data.raw.technology["speed-module-8"] then - bobmods.lib.tech.add_prerequisite("bob-power-armor-5", "speed-module-8") -end + if data.raw.technology["speed-module-8"] then + bobmods.lib.tech.add_prerequisite("bob-power-armor-5", "speed-module-8") + end -if data.raw.technology["effectivity-module-8"] then - bobmods.lib.tech.add_prerequisite("bob-power-armor-5", "effectivity-module-8") + if data.raw.technology["effectivity-module-8"] then + bobmods.lib.tech.add_prerequisite("bob-power-armor-5", "effectivity-module-8") + end +else + bobmods.lib.tech.replace_prerequisite("power-armor-mk2", "speed-module-2", "speed-module") + bobmods.lib.tech.replace_prerequisite("power-armor-mk2", "effectivity-module-2", "effectivity-module") end if mods["boblogistics"] then From 0476a4fdeb74cd782fb44026d7ed999f63a0b3a5 Mon Sep 17 00:00:00 2001 From: KiwiHawk <59639+KiwiHawk@users.noreply.github.com> Date: Wed, 29 May 2024 23:53:47 +1200 Subject: [PATCH 11/12] Energy shield ingredients and prerequisites --- bobequipment/prototypes/recipe/equipment.lua | 3 ++- bobequipment/prototypes/recipe/updates.lua | 3 +-- bobequipment/prototypes/technology/equipment.lua | 2 ++ 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/bobequipment/prototypes/recipe/equipment.lua b/bobequipment/prototypes/recipe/equipment.lua index a0e447d26..81462cf72 100644 --- a/bobequipment/prototypes/recipe/equipment.lua +++ b/bobequipment/prototypes/recipe/equipment.lua @@ -1,7 +1,8 @@ bobmods.lib.recipe.replace_ingredient("energy-shield-equipment", "advanced-circuit", "electronic-circuit") data.raw.recipe["energy-shield-mk2-equipment"].ingredients = { { "energy-shield-equipment", 2 }, - { "advanced-circuit", 5 } + { "advanced-circuit", 5 }, + { "productivity-module", 1 }, } data:extend({ diff --git a/bobequipment/prototypes/recipe/updates.lua b/bobequipment/prototypes/recipe/updates.lua index 853824e76..0a990a58a 100644 --- a/bobequipment/prototypes/recipe/updates.lua +++ b/bobequipment/prototypes/recipe/updates.lua @@ -348,9 +348,8 @@ if data.raw.item["silicon-wafer"] then end if data.raw.item["advanced-processing-unit"] then - bobmods.lib.recipe.replace_ingredient("energy-shield-mk3-equipment", "processing-unit", "advanced-processing-unit") - bobmods.lib.tech.add_prerequisite("bob-energy-shield-equipment-3", "advanced-electronics-3") bobmods.lib.recipe.replace_ingredient("energy-shield-mk4-equipment", "processing-unit", "advanced-processing-unit") + bobmods.lib.tech.add_prerequisite("bob-energy-shield-equipment-4", "advanced-electronics-3") bobmods.lib.recipe.replace_ingredient("energy-shield-mk5-equipment", "processing-unit", "advanced-processing-unit") bobmods.lib.recipe.replace_ingredient("energy-shield-mk6-equipment", "processing-unit", "advanced-processing-unit") bobmods.lib.recipe.replace_ingredient("battery-mk4-equipment", "processing-unit", "advanced-processing-unit") diff --git a/bobequipment/prototypes/technology/equipment.lua b/bobequipment/prototypes/technology/equipment.lua index 2e50e8761..acb0ea3bf 100644 --- a/bobequipment/prototypes/technology/equipment.lua +++ b/bobequipment/prototypes/technology/equipment.lua @@ -3,6 +3,7 @@ data.raw["technology"]["energy-shield-mk2-equipment"].icons = bobmods.equipment. icon_size = 128, }) bobmods.lib.tech.remove_prerequisite("energy-shield-mk2-equipment", "low-density-structure") +bobmods.lib.tech.add_prerequisite("energy-shield-mk2-equipment", "productivity-module") data:extend({ { @@ -14,6 +15,7 @@ data:extend({ }), order = "g-e-c", prerequisites = { + "advanced-electronics-2", "energy-shield-mk2-equipment", "productivity-module-2", "production-science-pack", From b711904781a29f265023f3113e0552c47c675458 Mon Sep 17 00:00:00 2001 From: StyLuaFormatter Date: Sun, 2 Jun 2024 01:58:13 +0000 Subject: [PATCH 12/12] Format Code --- bobequipment/prototypes/recipe/equipment.lua | 4 ++-- bobequipment/prototypes/recipe/updates.lua | 12 ++++++++++-- bobequipment/prototypes/technology/equipment.lua | 2 +- bobwarfare/prototypes/recipe/recipe-updates.lua | 2 +- .../prototypes/technology/technology-updates.lua | 2 +- 5 files changed, 15 insertions(+), 7 deletions(-) diff --git a/bobequipment/prototypes/recipe/equipment.lua b/bobequipment/prototypes/recipe/equipment.lua index 81462cf72..4b452039e 100644 --- a/bobequipment/prototypes/recipe/equipment.lua +++ b/bobequipment/prototypes/recipe/equipment.lua @@ -60,7 +60,7 @@ data:extend({ }) bobmods.lib.recipe.remove_ingredient("battery-equipment", "steel-plate") -bobmods.lib.recipe.add_ingredient("battery-equipment", { "electronic-circuit", 5 } ) +bobmods.lib.recipe.add_ingredient("battery-equipment", { "electronic-circuit", 5 }) data.raw.recipe["battery-mk2-equipment"].ingredients = { { "battery-equipment", 2 }, @@ -235,7 +235,7 @@ data:extend({ data.raw.recipe["personal-laser-defense-equipment"].ingredients = { { "steel-plate", 5 }, { "advanced-circuit", 5 }, - { "battery", 3 } + { "battery", 3 }, } data:extend({ diff --git a/bobequipment/prototypes/recipe/updates.lua b/bobequipment/prototypes/recipe/updates.lua index 0a990a58a..5101278f1 100644 --- a/bobequipment/prototypes/recipe/updates.lua +++ b/bobequipment/prototypes/recipe/updates.lua @@ -363,8 +363,16 @@ if data.raw.item["advanced-processing-unit"] then bobmods.lib.tech.add_prerequisite("night-vision-equipment-3", "advanced-electronics-3") bobmods.lib.recipe.replace_ingredient("solar-panel-equipment-4", "processing-unit", "advanced-processing-unit") bobmods.lib.tech.add_prerequisite("solar-panel-equipment-4", "advanced-electronics-3") - bobmods.lib.recipe.replace_ingredient("personal-laser-defense-equipment-5", "processing-unit", "advanced-processing-unit") - bobmods.lib.recipe.replace_ingredient("personal-laser-defense-equipment-6", "processing-unit", "advanced-processing-unit") + bobmods.lib.recipe.replace_ingredient( + "personal-laser-defense-equipment-5", + "processing-unit", + "advanced-processing-unit" + ) + bobmods.lib.recipe.replace_ingredient( + "personal-laser-defense-equipment-6", + "processing-unit", + "advanced-processing-unit" + ) bobmods.lib.tech.add_prerequisite("personal-laser-defense-equipment-5", "advanced-electronics-3") bobmods.lib.recipe.replace_ingredient("exoskeleton-equipment-3", "processing-unit", "advanced-processing-unit") bobmods.lib.tech.add_prerequisite("exoskeleton-equipment-3", "advanced-electronics-3") diff --git a/bobequipment/prototypes/technology/equipment.lua b/bobequipment/prototypes/technology/equipment.lua index acb0ea3bf..e3645542e 100644 --- a/bobequipment/prototypes/technology/equipment.lua +++ b/bobequipment/prototypes/technology/equipment.lua @@ -489,7 +489,7 @@ data:extend({ { "automation-science-pack", 1 }, { "logistic-science-pack", 1 }, { "chemical-science-pack", 1 }, - { "production-science-pack", 1} + { "production-science-pack", 1 }, }, }, }, diff --git a/bobwarfare/prototypes/recipe/recipe-updates.lua b/bobwarfare/prototypes/recipe/recipe-updates.lua index 5cf6dc59b..58682c1fc 100644 --- a/bobwarfare/prototypes/recipe/recipe-updates.lua +++ b/bobwarfare/prototypes/recipe/recipe-updates.lua @@ -540,7 +540,7 @@ bobmods.lib.recipe.replace_ingredient("modular-armor", "advanced-circuit", "elec bobmods.lib.recipe.replace_ingredient("power-armor", "processing-unit", "advanced-circuit") bobmods.lib.recipe.add_ingredient("power-armor", { "modular-armor", 1 }) -- By default, electric engines are Blue Science -if (not mods["bobplates"]) and (not mods["boblogistics"]) then +if (not mods["bobplates"]) and not mods["boblogistics"] then bobmods.lib.recipe.remove_ingredient("power-armor", "electric-engine-unit") end diff --git a/bobwarfare/prototypes/technology/technology-updates.lua b/bobwarfare/prototypes/technology/technology-updates.lua index 4cf2c9632..c35fb324a 100644 --- a/bobwarfare/prototypes/technology/technology-updates.lua +++ b/bobwarfare/prototypes/technology/technology-updates.lua @@ -582,7 +582,7 @@ bobmods.lib.tech.remove_prerequisite("power-armor", "advanced-electronics-2") bobmods.lib.tech.add_prerequisite("power-armor", "military-science-pack") bobmods.lib.tech.add_prerequisite("power-armor", "advanced-electronics") -- By default, electric engines are Blue Science -if (not mods["bobplates"]) and (not mods["boblogistics"]) then +if (not mods["bobplates"]) and not mods["boblogistics"] then bobmods.lib.tech.remove_prerequisite("power-armor", "electric-engine") bobmods.lib.tech.add_prerequisite("power-armor-mk2", "electric-engine") end