Split mod
This commit is contained in:
parent
9d94502296
commit
efb0b6aad7
101 changed files with 803 additions and 786 deletions
4
lignumis-base/prototypes/integrations/Wood-Walls.lua
Normal file
4
lignumis-base/prototypes/integrations/Wood-Walls.lua
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
local recipe = data.raw.recipe["wooden-wall"]
|
||||
recipe.ingredients = { { type = "item", name = "lumber", amount = 4 } }
|
||||
recipe.results = { { type = "item", name = "wooden-wall", amount = 1 } }
|
||||
recipe.category = "wood-processing-or-assembling"
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
if not mods["astroponics"] then return end
|
||||
|
||||
local Technology = require("__cf-lib__/data/Technology")
|
||||
|
||||
-- This just undoes what astroponics changes to tree seeding
|
||||
Technology:new("tree-seeding"):addRecipe("wood-processing")
|
||||
Technology:new("astroponics"):removeRecipe("wood-processing")
|
||||
for i, effect in pairs(data.raw.technology["tree-seeding"].effects) do
|
||||
if effect.type == "change-recipe-productivity" and effect.recipe == "wood-processing" then
|
||||
table.remove(data.raw.technology["tree-seeding"].effects, i)
|
||||
end
|
||||
end
|
||||
51
lignumis-base/prototypes/integrations/astroponics.lua
Normal file
51
lignumis-base/prototypes/integrations/astroponics.lua
Normal file
|
|
@ -0,0 +1,51 @@
|
|||
if not mods["astroponics"] then return end
|
||||
|
||||
local infinite = settings.startup["lignumis-infinite-astroponics-productivity-research"].value
|
||||
|
||||
local base_levels = {
|
||||
type = "technology",
|
||||
name = "astroponics-productivity",
|
||||
icons = {
|
||||
{ icon = "__base__/graphics/icons/wood.png", icon_size = 64 },
|
||||
{ icon = "__astroponics__/graphics/icons/fluid/liquid-fertilizer.png", shift = { -32, -32 }, scale = 1.2 },
|
||||
{
|
||||
icon = "__core__/graphics/icons/technology/constants/constant-recipe-productivity.png",
|
||||
icon_size = 128,
|
||||
scale = 0.5,
|
||||
shift = { 50, 50 },
|
||||
floating = true
|
||||
}
|
||||
},
|
||||
essential = false,
|
||||
level = 1,
|
||||
max_level = 5,
|
||||
show_levels_info = true,
|
||||
effects = {
|
||||
{
|
||||
type = "change-recipe-productivity",
|
||||
recipe = "tree-astroponics",
|
||||
change = 0.1
|
||||
}
|
||||
},
|
||||
prerequisites = { "astroponics", "production-science-pack" },
|
||||
unit = {
|
||||
count_formula = "L*250",
|
||||
ingredients = {
|
||||
{ "wood-science-pack", 1 },
|
||||
{ "production-science-pack", 1 },
|
||||
{ "space-science-pack", 1 },
|
||||
},
|
||||
time = 60
|
||||
}
|
||||
}
|
||||
data:extend({ base_levels })
|
||||
|
||||
if infinite then
|
||||
local infinite_levels = table.deepcopy(base_levels)
|
||||
infinite_levels.name = "astroponics-productivity-6"
|
||||
infinite_levels.max_level = "infinite"
|
||||
infinite_levels.unit.count_formula = "2^(L-6)*1500"
|
||||
table.insert(infinite_levels.unit.ingredients, { "agricultural-science-pack", 1 })
|
||||
infinite_levels.prerequisites = { "astroponics-productivity", "agricultural-science-pack" }
|
||||
data:extend({ infinite_levels })
|
||||
end
|
||||
3
lignumis-base/prototypes/integrations/data.lua
Normal file
3
lignumis-base/prototypes/integrations/data.lua
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
require("vanilla")
|
||||
require("Wood-Walls")
|
||||
require("astroponics")
|
||||
2
lignumis-base/prototypes/integrations/updates.lua
Normal file
2
lignumis-base/prototypes/integrations/updates.lua
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
require("vanilla-updates")
|
||||
require("astroponics-updates")
|
||||
27
lignumis-base/prototypes/integrations/vanilla-updates.lua
Normal file
27
lignumis-base/prototypes/integrations/vanilla-updates.lua
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
-- Add wood and steam science packs as ingredients to technologies that require Nauvis science packs.
|
||||
for _, technology in pairs(data.raw.technology) do
|
||||
if not technology.lignumis_skip_science_packs and technology.unit and technology.unit.ingredients and not table.contains(Lignumis.science_blacklist, technology.name) then
|
||||
local ingredients = technology.unit.ingredients
|
||||
local noMatches = table.filter(ingredients, function(ingredient)
|
||||
return table.contains(Lignumis.science_pack_blacklist, ingredient[1])
|
||||
end)
|
||||
local yesMatches = table.filter(ingredients, function(ingredient)
|
||||
return table.contains(Lignumis.science_pack_whitelist, ingredient[1])
|
||||
end)
|
||||
if #noMatches == 0 and #yesMatches > 0 then
|
||||
table.insert(technology.unit.ingredients, { "wood-science-pack", 1 })
|
||||
table.insert(technology.unit.ingredients, { "steam-science-pack", 1 })
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
-- Add wood and steam science packs to all labs' inputs
|
||||
for _, lab in pairs(data.raw.lab) do
|
||||
if lab.inputs and not table.contains(Lignumis.lab_blacklist, lab.name) then
|
||||
lab.inputs = table.assign({
|
||||
"wood-science-pack",
|
||||
"steam-science-pack"
|
||||
}, lab.inputs)
|
||||
end
|
||||
end
|
||||
368
lignumis-base/prototypes/integrations/vanilla.lua
Normal file
368
lignumis-base/prototypes/integrations/vanilla.lua
Normal file
|
|
@ -0,0 +1,368 @@
|
|||
local Technology = require("__cf-lib__/data/Technology")
|
||||
local Recipe = require("__cf-lib__/data/Recipe")
|
||||
local Item = require("__cf-lib__/data/Item")
|
||||
|
||||
local basic_circuit_board = settings.startup["lignumis-basic-circuit-board"].value
|
||||
|
||||
-- Burner mining drill
|
||||
|
||||
local drill = data.raw["mining-drill"]["burner-mining-drill"]
|
||||
local drill_animation = drill.graphics_set.animation
|
||||
drill.resource_searching_radius = 1.99
|
||||
drill.icon = Lignumis.graphics .. "icons/burner-mining-drill.png"
|
||||
drill.impact_category = "wood"
|
||||
drill.radius_visualisation_picture = table.deepcopy(data.raw["mining-drill"]["electric-mining-drill"].radius_visualisation_picture)
|
||||
drill_animation.north.layers[1].filename = Lignumis.graphics .. "entity/burner-mining-drill/burner-mining-drill-N.png"
|
||||
drill_animation.east.layers[1].filename = Lignumis.graphics .. "entity/burner-mining-drill/burner-mining-drill-E.png"
|
||||
drill_animation.south.layers[1].filename = Lignumis.graphics .. "entity/burner-mining-drill/burner-mining-drill-S.png"
|
||||
drill_animation.west.layers[1].filename = Lignumis.graphics .. "entity/burner-mining-drill/burner-mining-drill-W.png"
|
||||
|
||||
local drill_item = data.raw["item"]["burner-mining-drill"]
|
||||
drill_item.icon = Lignumis.graphics .. "icons/burner-mining-drill.png"
|
||||
|
||||
local drill_recipe = data.raw["recipe"]["burner-mining-drill"]
|
||||
drill_recipe.category = "wood-processing-or-assembling"
|
||||
drill_recipe.ingredients = {
|
||||
{ type = "item", name = "stone-furnace", amount = 1 },
|
||||
{ type = "item", name = "wooden-gear-wheel", amount = basic_circuit_board and 2 or 3 },
|
||||
{ type = "item", name = "lumber", amount = basic_circuit_board and 2 or 3 },
|
||||
basic_circuit_board and { type = "item", name = "basic-circuit-board", amount = 2 } or nil
|
||||
}
|
||||
|
||||
|
||||
-- Burner inserter
|
||||
|
||||
local burner_inserter = data.raw["inserter"]["burner-inserter"]
|
||||
burner_inserter.icon = Lignumis.graphics .. "icons/burner-inserter.png"
|
||||
burner_inserter.hand_base_picture.filename = Lignumis.graphics .. "entity/burner-inserter/burner-inserter-hand-base.png"
|
||||
burner_inserter.hand_closed_picture.filename = Lignumis.graphics .. "entity/burner-inserter/burner-inserter-hand-closed.png"
|
||||
burner_inserter.hand_open_picture.filename = Lignumis.graphics .. "entity/burner-inserter/burner-inserter-hand-open.png"
|
||||
burner_inserter.platform_picture.sheet.filename = Lignumis.graphics .. "entity/burner-inserter/burner-inserter-platform.png"
|
||||
burner_inserter.energy_source.initial_fuel_percent = 0.15
|
||||
|
||||
data.raw.item["burner-inserter"].icon = Lignumis.graphics .. "icons/burner-inserter.png"
|
||||
|
||||
local burner_inserter_recipe = data.raw.recipe["burner-inserter"]
|
||||
burner_inserter_recipe.ingredients = {
|
||||
{ type = "item", name = "wooden-gear-wheel", amount = 1 },
|
||||
{ type = "item", name = "lumber", amount = 1 }
|
||||
}
|
||||
if settings.startup["lignumis-lumber-mill-more-recipes"].value then
|
||||
burner_inserter_recipe.category = "wood-processing-or-assembling"
|
||||
end
|
||||
|
||||
|
||||
-- Stone furnace
|
||||
|
||||
local stone_furnace = data.raw["furnace"]["stone-furnace"]
|
||||
stone_furnace.icon = Lignumis.graphics .. "icons/stone-furnace.png"
|
||||
stone_furnace.graphics_set.animation.layers[1].filename = Lignumis.graphics .. "entity/stone-furnace/stone-furnace.png"
|
||||
|
||||
local stone_furnace_remnants = data.raw["corpse"]["stone-furnace-remnants"]
|
||||
stone_furnace_remnants.icon = Lignumis.graphics .. "icons/stone-furnace.png"
|
||||
stone_furnace_remnants.animation[1].filename = Lignumis.graphics .. "entity/stone-furnace/stone-furnace-remnants.png"
|
||||
|
||||
|
||||
-- Lab
|
||||
|
||||
if settings.startup["lignumis-vanilla-lab"].value then
|
||||
Recipe:new("transport-belt"):unlockedByTechnology("iron-processing")
|
||||
else
|
||||
Recipe:new("lab"):replaceIngredient("transport-belt", "wood-transport-belt")
|
||||
Recipe:new("transport-belt"):unlockedByTechnology("logistics")
|
||||
end
|
||||
|
||||
|
||||
-- Gun turret
|
||||
data.raw["ammo-turret"]["gun-turret"].attack_parameters.range = 20
|
||||
Item:new("gun-turret"):itemsPerRocket(50)
|
||||
|
||||
|
||||
-- Agricultural tower
|
||||
|
||||
local agricultural_tower = data.raw["agricultural-tower"]["agricultural-tower"]
|
||||
if agricultural_tower.surface_conditions then
|
||||
for _, condition in pairs(agricultural_tower.surface_conditions) do
|
||||
if condition.property == "pressure" then
|
||||
condition.min = 900
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
-- Solar panal
|
||||
Item:new("solar-panel"):itemsPerRocket(50)
|
||||
|
||||
|
||||
-- Wood processing
|
||||
|
||||
local wood_processing = data.raw.recipe["wood-processing"]
|
||||
wood_processing.ingredients[1].amount = 1
|
||||
wood_processing.icon = data.raw.item["tree-seed"].icon
|
||||
|
||||
for _, tree in pairs(data.raw.tree) do
|
||||
local function isWoodResult(result)
|
||||
return result.name == "wood"
|
||||
end
|
||||
local minable = tree.minable
|
||||
if not minable then goto continue end
|
||||
local woodResults = minable.results and table.filter(minable.results, isWoodResult)
|
||||
local isRegularTree = (minable.result == "wood" and minable.count == 4) or (minable.results and #minable.results == 1 and #woodResults == 1 and woodResults[1].amount == 4)
|
||||
if not isRegularTree then goto continue end
|
||||
tree.minable.result = nil
|
||||
tree.minable.count = nil
|
||||
local woodResult = { type = "item", name = "wood", amount = nil, amount_min = 2, amount_max = 10 }
|
||||
if minable.results and #woodResults > 0 then
|
||||
table.assign(woodResults[1], woodResult)
|
||||
woodResults[1].amount = nil
|
||||
else
|
||||
minable.results = { woodResult }
|
||||
end
|
||||
::continue::
|
||||
end
|
||||
|
||||
local tree_plant = data.raw.plant["tree-plant"]
|
||||
tree_plant.growth_ticks = 5 * minute
|
||||
tree_plant.minable.results = { { type = "item", name = "wood", amount = 5 } }
|
||||
tree_plant.minable.count = nil
|
||||
tree_plant.surface_conditions[1].min = 900
|
||||
table.insert(tree_plant.autoplace.tile_restriction, "natural-gold-soil")
|
||||
|
||||
if mods["Diversitree"] then
|
||||
data.raw.plant["s6xdvt-fake-tree"].surface_conditions[1].min = 900
|
||||
end
|
||||
|
||||
table.insert(data.raw["assembling-machine"]["assembling-machine-1"].crafting_categories, "wood-processing-or-assembling")
|
||||
table.insert(data.raw["assembling-machine"]["assembling-machine-1"].crafting_categories, "organic-or-assembling")
|
||||
table.insert(data.raw["assembling-machine"]["assembling-machine-2"].crafting_categories, "wood-processing-or-assembling")
|
||||
table.insert(data.raw["assembling-machine"]["assembling-machine-3"].crafting_categories, "wood-processing-or-assembling")
|
||||
|
||||
|
||||
-- Disable vanilla early game recipes
|
||||
|
||||
data.raw.recipe["iron-plate"].enabled = false
|
||||
data.raw.recipe["iron-gear-wheel"].enabled = false
|
||||
data.raw.recipe["iron-chest"].enabled = false
|
||||
data.raw.recipe["copper-plate"].enabled = false
|
||||
data.raw.recipe["copper-cable"].enabled = false
|
||||
data.raw.recipe["transport-belt"].enabled = false
|
||||
|
||||
|
||||
-- Progressive recipes
|
||||
|
||||
if settings.startup["lignumis-belt-progression"].value then
|
||||
Recipe:new("transport-belt"):replaceIngredient("iron-plate", "wood-transport-belt", 2)
|
||||
Recipe:new("underground-belt"):replaceIngredient("transport-belt", "wood-underground-belt", 2)
|
||||
Recipe:new("splitter"):replaceIngredient("transport-belt", "wood-splitter", 1)
|
||||
Item:new("transport-belt"):itemsPerRocket(100)
|
||||
Item:new("underground-belt"):itemsPerRocket(50)
|
||||
Item:new("splitter"):itemsPerRocket(50)
|
||||
end
|
||||
|
||||
if settings.startup["lignumis-inserter-progression"].value then
|
||||
Recipe:new("inserter"):addIngredient("burner-inserter", 1)
|
||||
end
|
||||
|
||||
if settings.startup["lignumis-assembler-progression"].value then
|
||||
Recipe:new("assembling-machine-1"):addIngredient("burner-assembling-machine", 1)
|
||||
end
|
||||
|
||||
|
||||
-- Adjust vanilla technologies
|
||||
|
||||
local automation_science_pack_technology = data.raw.technology["automation-science-pack"]
|
||||
automation_science_pack_technology.enabled = false
|
||||
automation_science_pack_technology.visible_when_disabled = true
|
||||
automation_science_pack_technology.research_trigger = nil
|
||||
automation_science_pack_technology.unit = {
|
||||
count = 1,
|
||||
ingredients = {},
|
||||
time = 1
|
||||
}
|
||||
|
||||
if not mods["aai-industry"] then
|
||||
local electronics_technology = data.raw.technology["electronics"]
|
||||
electronics_technology.prerequisites = { "copper-processing" }
|
||||
|
||||
local steam_power_technology = data.raw.technology["steam-power"]
|
||||
steam_power_technology.prerequisites = { "iron-processing" }
|
||||
end
|
||||
|
||||
local automation_technology = data.raw.technology["automation"]
|
||||
automation_technology.ignore_tech_cost_multiplier = false
|
||||
|
||||
local landfill_technology = data.raw.technology["landfill"]
|
||||
landfill_technology.prerequisites = { "burner-automation" }
|
||||
landfill_technology.unit = {
|
||||
count = 50,
|
||||
ingredients = { { "wood-science-pack", 1 } },
|
||||
time = 15
|
||||
}
|
||||
|
||||
local robots_speed_technology_1 = data.raw.technology["worker-robots-speed-1"]
|
||||
robots_speed_technology_1.prerequisites = { "provisional-rocketry", "basic-construction-robotics-gold" }
|
||||
robots_speed_technology_1.unit = {
|
||||
count = 100,
|
||||
ingredients = { { "wood-science-pack", 1 }, { "steam-science-pack", 1 } },
|
||||
time = 15
|
||||
}
|
||||
|
||||
local robots_speed_technology_2 = data.raw.technology["worker-robots-speed-2"]
|
||||
robots_speed_technology_2.prerequisites = {
|
||||
"worker-robots-speed-1",
|
||||
"logistic-science-pack"
|
||||
}
|
||||
robots_speed_technology_2.unit = {
|
||||
count = 100,
|
||||
ingredients = { { "automation-science-pack", 1 }, { "logistic-science-pack", 1 } },
|
||||
time = 30
|
||||
}
|
||||
|
||||
local robots_speed_technology_3 = data.raw.technology["worker-robots-speed-3"]
|
||||
robots_speed_technology_3.prerequisites = { "robotics", "chemical-science-pack" }
|
||||
robots_speed_technology_3.unit = {
|
||||
count = 150,
|
||||
ingredients = { { "automation-science-pack", 1 }, { "logistic-science-pack", 1 }, { "chemical-science-pack", 1 } },
|
||||
time = 30
|
||||
}
|
||||
|
||||
local robots_speed_technology_4 = data.raw.technology["worker-robots-speed-4"]
|
||||
robots_speed_technology_4.prerequisites = { "worker-robots-speed-3", "utility-science-pack" }
|
||||
robots_speed_technology_4.unit.ingredients = {
|
||||
{ "automation-science-pack", 1 },
|
||||
{ "logistic-science-pack", 1 },
|
||||
{ "chemical-science-pack", 1 },
|
||||
{ "utility-science-pack", 1 }
|
||||
}
|
||||
|
||||
local physical_damage_technology_1 = data.raw.technology["physical-projectile-damage-1"]
|
||||
physical_damage_technology_1.prerequisites = { "basic-gun-turret" }
|
||||
physical_damage_technology_1.unit.ingredients = { { "wood-science-pack", 1 } }
|
||||
table.insert(physical_damage_technology_1.effects, {
|
||||
type = "turret-attack",
|
||||
turret_id = "basic-gun-turret",
|
||||
modifier = 0.2
|
||||
})
|
||||
|
||||
local weapon_speed_technology_1 = data.raw.technology["weapon-shooting-speed-1"]
|
||||
weapon_speed_technology_1.prerequisites = table.deepcopy(physical_damage_technology_1.prerequisites)
|
||||
weapon_speed_technology_1.unit.ingredients = table.deepcopy(physical_damage_technology_1.unit.ingredients)
|
||||
|
||||
local physical_damage_technology_2 = data.raw.technology["physical-projectile-damage-2"]
|
||||
physical_damage_technology_2.prerequisites = { "physical-projectile-damage-1", "steam-science-pack" }
|
||||
physical_damage_technology_2.unit.ingredients = { { "wood-science-pack", 1 }, { "steam-science-pack", 1 } }
|
||||
table.insert(physical_damage_technology_2.effects, {
|
||||
type = "turret-attack",
|
||||
turret_id = "basic-gun-turret",
|
||||
modifier = 0.2
|
||||
})
|
||||
|
||||
local weapon_speed_technology_2 = data.raw.technology["weapon-shooting-speed-2"]
|
||||
weapon_speed_technology_2.prerequisites = { "weapon-shooting-speed-1", "steam-science-pack" }
|
||||
weapon_speed_technology_2.unit.ingredients = table.deepcopy(physical_damage_technology_2.unit.ingredients)
|
||||
|
||||
local physical_damage_technology_3 = data.raw.technology["physical-projectile-damage-3"]
|
||||
physical_damage_technology_3.prerequisites = { "military-2", "logistic-science-pack" }
|
||||
physical_damage_technology_3.unit.ingredients = { { "automation-science-pack", 1 }, { "logistic-science-pack", 1 } }
|
||||
physical_damage_technology_3.upgrade = false
|
||||
table.insert(physical_damage_technology_3.effects, {
|
||||
type = "turret-attack",
|
||||
turret_id = "basic-gun-turret",
|
||||
modifier = 0.3
|
||||
})
|
||||
|
||||
local weapon_speed_technology_3 = data.raw.technology["weapon-shooting-speed-3"]
|
||||
weapon_speed_technology_3.prerequisites = { "military-2", "logistic-science-pack" }
|
||||
weapon_speed_technology_3.unit.ingredients = table.deepcopy(physical_damage_technology_3.unit.ingredients)
|
||||
weapon_speed_technology_3.upgrade = false
|
||||
|
||||
local physical_damage_technology_4 = data.raw.technology["physical-projectile-damage-4"]
|
||||
physical_damage_technology_4.prerequisites = { "physical-projectile-damage-3", "military-science-pack" }
|
||||
table.insert(physical_damage_technology_4.effects, {
|
||||
type = "turret-attack",
|
||||
turret_id = "basic-gun-turret",
|
||||
modifier = 0.3
|
||||
})
|
||||
|
||||
local weapon_speed_technology_4 = data.raw.technology["weapon-shooting-speed-4"]
|
||||
weapon_speed_technology_4.prerequisites = { "weapon-shooting-speed-3", "military-science-pack" }
|
||||
|
||||
local production_science_pack_technology = Technology:new("production-science-pack")
|
||||
production_science_pack_technology:replacePrerequisite("advanced-material-processing-2", "space-platform-thruster")
|
||||
production_science_pack_technology:addIngredients({ "space-science-pack" })
|
||||
if settings.startup["lignumis-technology-progression"].value then
|
||||
production_science_pack_technology:addIngredients({ "wood-science-pack", "steam-science-pack" })
|
||||
end
|
||||
|
||||
local utility_science_pack_technology = Technology:new("utility-science-pack")
|
||||
utility_science_pack_technology:setPrerequisites({ "space-platform-thruster" })
|
||||
utility_science_pack_technology:addIngredients({ "space-science-pack" })
|
||||
if settings.startup["lignumis-technology-progression"].value then
|
||||
utility_science_pack_technology:addIngredients({ "wood-science-pack", "steam-science-pack" })
|
||||
end
|
||||
|
||||
if not mods["planet-muluna"] then -- Muluna does the same
|
||||
Technology:new("logistic-robotics"):addRecipe("requester-chest")
|
||||
Technology:new("logistic-system"):removeRecipe("requester-chest")
|
||||
end
|
||||
|
||||
|
||||
-- Equipment
|
||||
|
||||
data.raw.armor["light-armor"].equipment_grid = "tiny-equipment-grid"
|
||||
data.raw.armor["heavy-armor"].equipment_grid = "very-small-equipment-grid"
|
||||
data.raw["equipment-grid"]["small-equipment-grid"].width = 6
|
||||
data.raw["equipment-grid"]["small-equipment-grid"].height = 6
|
||||
data.raw["equipment-grid"]["medium-equipment-grid"].width = 8
|
||||
data.raw["equipment-grid"]["medium-equipment-grid"].height = 8
|
||||
|
||||
|
||||
-- Always show Nauvis icon
|
||||
|
||||
local nauvis = data.raw.planet["nauvis"]
|
||||
nauvis.flags = nauvis.flags or {}
|
||||
table.insert(nauvis.flags, "always-show")
|
||||
|
||||
|
||||
-- Fulgora changes
|
||||
|
||||
if settings.startup["lignumis-fulgora-wood"].value then
|
||||
local recycling = data.raw.recipe["scrap-recycling"]
|
||||
table.insert(recycling.results, { type = "item", name = "wooden-gear-wheel", amount = 1, probability = 0.2 })
|
||||
local recycling_result_count = table.count(recycling.results)
|
||||
|
||||
local recycler = data.raw.furnace["recycler"]
|
||||
if recycler.result_inventory_size < recycling_result_count then
|
||||
recycler.result_inventory_size = recycling_result_count
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
-- Fix item weights
|
||||
|
||||
local function set_default_weight(item, items_per_rocket, type)
|
||||
data.raw[type or "item"][item].weight = data.raw[type or "item"][item].weight or 1000 * kg / items_per_rocket
|
||||
end
|
||||
set_default_weight("electronic-circuit", 2000)
|
||||
set_default_weight("advanced-circuit", 1000)
|
||||
set_default_weight("processing-unit", 300)
|
||||
set_default_weight("low-density-structure", 200)
|
||||
set_default_weight("rocket-fuel", 100)
|
||||
set_default_weight("inserter", 50)
|
||||
set_default_weight("fast-inserter", 50)
|
||||
set_default_weight("electric-mining-drill", 50)
|
||||
set_default_weight("pumpjack", 20)
|
||||
set_default_weight("repair-pack", 100, "repair-tool")
|
||||
set_default_weight("big-electric-pole", 50)
|
||||
set_default_weight("assembling-machine-1", 50)
|
||||
set_default_weight("assembling-machine-2", 50)
|
||||
set_default_weight("oil-refinery", 10)
|
||||
set_default_weight("accumulator", 50)
|
||||
set_default_weight("steam-engine", 10)
|
||||
set_default_weight("substation", 50)
|
||||
set_default_weight("radar", 50)
|
||||
set_default_weight("storage-tank", 50)
|
||||
set_default_weight("fast-transport-belt", 100)
|
||||
set_default_weight("fast-underground-belt", 50)
|
||||
set_default_weight("fast-splitter", 50)
|
||||
set_default_weight("steel-plate", 400)
|
||||
set_default_weight("steam-turbine", 10)
|
||||
Loading…
Add table
Add a link
Reference in a new issue