Skip to content

Commit

Permalink
Electronics adjustments (#281)
Browse files Browse the repository at this point in the history
* Change wood to carbon ratio

* Increase electronics cost

* Increase electronics cost, add insulated cable to combinators

* Increase electronics cost

* Recycling for combinators

* Switch blue boards from gold to silver

* Update technology-updates.lua

* Remove gold from blue boards

---------

Co-authored-by: KiwiHawk <59639+KiwiHawk@users.noreply.github.com>
  • Loading branch information
Qatavin and KiwiHawk authored Jan 9, 2025
1 parent 459d1c5 commit fed0aa0
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 22 deletions.
3 changes: 3 additions & 0 deletions bobelectronics/data-updates.lua
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,9 @@ if feature_flags["quality"] then
"circuit-board",
"superior-circuit-board",
"multi-layer-circuit-board",
"arithmetic-combinator",
"decider-combinator",
"constant-combinator",
})
if settings.startup["bobmods-colorupdate"].value == true then
bobmods.lib.recipe.update_recycling_recipe_icon(
Expand Down
29 changes: 14 additions & 15 deletions bobelectronics/prototypes/electronics.lua
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ if data.raw.item["solder-alloy"] then
{ type = "item", name = "solder-alloy", amount = 4 },
{ type = "item", name = "bob-resin", amount = 1 },
},
results = { { type = "item", name = "solder", amount = 8 } },
results = { { type = "item", name = "solder", amount = 5 } },
allow_decomposition = false,
allow_productivity = true,
},
Expand Down Expand Up @@ -157,7 +157,7 @@ data:extend({
energy_required = 2,
enabled = false,
ingredients = {
{ type = "item", name = "copper-cable", amount = 1 },
{ type = "item", name = "copper-cable", amount = 2 },
{ type = "item", name = "coal", amount = 1 },
},
results = { { type = "item", name = "basic-electronic-components", amount = 5 } },
Expand Down Expand Up @@ -186,7 +186,7 @@ data:extend({
energy_required = 3.5,
enabled = false,
ingredients = {
{ type = "item", name = "copper-cable", amount = 1 },
{ type = "item", name = "copper-cable", amount = 3 },
{ type = "item", name = "plastic-bar", amount = 1 },
},
results = { { type = "item", name = "electronic-components", amount = 5 } },
Expand Down Expand Up @@ -216,7 +216,7 @@ data:extend({
energy_required = 5,
enabled = false,
ingredients = {
{ type = "item", name = "copper-cable", amount = 1 },
{ type = "item", name = "copper-cable", amount = 4 },
{ type = "item", name = "plastic-bar", amount = 1 },
{ type = "fluid", name = "sulfuric-acid", amount = 5 },
},
Expand Down Expand Up @@ -247,9 +247,9 @@ data:extend({
energy_required = 7,
enabled = false,
ingredients = {
{ type = "item", name = "copper-cable", amount = 2 },
{ type = "item", name = "copper-cable", amount = 5 },
{ type = "item", name = "plastic-bar", amount = 1 },
{ type = "fluid", name = "sulfuric-acid", amount = 5 },
{ type = "fluid", name = "sulfuric-acid", amount = 10 },
},
results = { { type = "item", name = "processing-electronics", amount = 5 } },
allow_decomposition = false,
Expand Down Expand Up @@ -561,7 +561,7 @@ data:extend({
enabled = false,
ingredients = {
{ type = "item", name = "basic-circuit-board", amount = 1 },
{ type = "item", name = "basic-electronic-components", amount = 5 },
{ type = "item", name = "basic-electronic-components", amount = 4 },
},
results = { { type = "item", name = "electronic-circuit", amount = 1 } },
allow_decomposition = false,
Expand Down Expand Up @@ -620,9 +620,9 @@ data:extend({
enabled = false,
ingredients = {
{ type = "item", name = "superior-circuit-board", amount = 1 },
{ type = "item", name = "basic-electronic-components", amount = 2 },
{ type = "item", name = "electronic-components", amount = 4 },
{ type = "item", name = "intergrated-electronics", amount = 2 },
{ type = "item", name = "basic-electronic-components", amount = 4 },
{ type = "item", name = "electronic-components", amount = 8 },
{ type = "item", name = "intergrated-electronics", amount = 6 },
},
results = { { type = "item", name = "processing-unit", amount = 1 } },
allow_decomposition = false,
Expand Down Expand Up @@ -651,13 +651,12 @@ data:extend({
enabled = false,
ingredients = {
{ type = "item", name = "multi-layer-circuit-board", amount = 1 },
{ type = "item", name = "basic-electronic-components", amount = 1 },
{ type = "item", name = "electronic-components", amount = 2 },
{ type = "item", name = "intergrated-electronics", amount = 4 },
{ type = "item", name = "processing-electronics", amount = 1 },
{ type = "item", name = "basic-electronic-components", amount = 6 },
{ type = "item", name = "electronic-components", amount = 6 },
{ type = "item", name = "intergrated-electronics", amount = 8 },
{ type = "item", name = "processing-electronics", amount = 4 },
},
results = { { type = "item", name = "bob-advanced-processing-unit", amount = 1 } },
allow_decomposition = false,
allow_productivity = true,
},
})
16 changes: 12 additions & 4 deletions bobelectronics/prototypes/recipe-updates.lua
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,11 @@ else
bobmods.lib.recipe.add_ingredient("circuit-board", { type = "item", name = "copper-plate", amount = 1 })
end

if data.raw.item["silver-plate"] then
bobmods.lib.recipe.add_ingredient("superior-circuit-board", { type = "item", name = "silver-plate", amount = 1 })
end

if data.raw.item["bob-gold-plate"] then
bobmods.lib.recipe.add_ingredient("superior-circuit-board", { type = "item", name = "bob-gold-plate", amount = 1 })
bobmods.lib.recipe.add_ingredient("multi-layer-circuit-board", { type = "item", name = "bob-gold-plate", amount = 2 })
else
if data.raw.item["bob-tin-plate"] then
Expand All @@ -98,9 +101,14 @@ else
end
end

--Use this standard when adding solder: basic-electronic-components = 1/6 solder, electronic-components = 1/5 solder, intergrated-electronics = 1/4 solder, processing-electronics = 1/3 solder
if data.raw.item["solder"] then
bobmods.lib.recipe.add_ingredient("electronic-circuit", { type = "item", name = "solder", amount = 1 })
bobmods.lib.recipe.add_ingredient("advanced-circuit", { type = "item", name = "solder", amount = 1 })
bobmods.lib.recipe.add_ingredient("processing-unit", { type = "item", name = "solder", amount = 2 })
bobmods.lib.recipe.add_ingredient("bob-advanced-processing-unit", { type = "item", name = "solder", amount = 4 })
bobmods.lib.recipe.add_ingredient("advanced-circuit", { type = "item", name = "solder", amount = 2 })
bobmods.lib.recipe.add_ingredient("processing-unit", { type = "item", name = "solder", amount = 4 })
bobmods.lib.recipe.add_ingredient("bob-advanced-processing-unit", { type = "item", name = "solder", amount = 6 })
end

bobmods.lib.recipe.replace_ingredient("arithmetic-combinator", "copper-cable", "insulated-cable")
bobmods.lib.recipe.replace_ingredient("decider-combinator", "copper-cable", "insulated-cable")
bobmods.lib.recipe.replace_ingredient("constant-combinator", "copper-cable", "insulated-cable")
2 changes: 1 addition & 1 deletion bobelectronics/prototypes/technology-updates.lua
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ if mods["bobplates"] then
bobmods.lib.tech.add_prerequisite("bob-electronics", "bob-chemical-processing-1")
bobmods.lib.tech.add_prerequisite("bob-electronics", "bob-alloy-processing")
bobmods.lib.tech.add_prerequisite("advanced-circuit", "bob-silicon-processing")
bobmods.lib.tech.add_prerequisite("processing-unit", "bob-gold-processing")
bobmods.lib.tech.add_prerequisite("bob-advanced-processing-unit", "bob-gold-processing")
bobmods.lib.tech.add_recipe_unlock("bob-chemical-processing-2", "bob-ferric-chloride-solution")
bobmods.lib.tech.add_prerequisite("bob-chemical-processing-2", "bob-electronics")
bobmods.lib.tech.add_prerequisite("advanced-circuit", "bob-chemical-processing-2")
Expand Down
1 change: 0 additions & 1 deletion bobmodules/prototypes/recipe/electronics-updates.lua
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ if data.raw.item["bob-gold-plate"] then
"bob-module-processor-board-3",
{ type = "item", name = "bob-gold-plate", amount = 2 }
)
bobmods.lib.tech.add_prerequisite("processing-unit", "bob-gold-processing")
end

if data.raw.item["tinned-copper-cable"] then
Expand Down
2 changes: 1 addition & 1 deletion bobplates/prototypes/recipe/resource-recipe.lua
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ data:extend({
category = "smelting",
energy_required = 1.6,
ingredients = {
{ type = "item", name = "wood", amount = 2 },
{ type = "item", name = "wood", amount = 1 },
},
results = { { type = "item", name = "bob-carbon", amount = 1 } },
subgroup = "bob-resource",
Expand Down

0 comments on commit fed0aa0

Please sign in to comment.