Wooden logistics: Change compatibility to stick closer to how wooden logistics does things (breaking change)
This commit is contained in:
parent
52725edc46
commit
3115b51e4e
7 changed files with 261 additions and 238 deletions
|
|
@ -8,4 +8,5 @@ require("lane-splitters")
|
||||||
require("wood-industry")
|
require("wood-industry")
|
||||||
require("crushing-industry")
|
require("crushing-industry")
|
||||||
require("canal-excavator")
|
require("canal-excavator")
|
||||||
require("diversitree")
|
require("diversitree")
|
||||||
|
require("wood-logistics")
|
||||||
125
lignumis/prototypes/compatibility/wood-logistics.lua
Normal file
125
lignumis/prototypes/compatibility/wood-logistics.lua
Normal file
|
|
@ -0,0 +1,125 @@
|
||||||
|
local Item = require("__cf-lib__/data/Item")
|
||||||
|
local Recipe = require("__cf-lib__/data/Recipe")
|
||||||
|
local Technology = require("__cf-lib__/data/Technology")
|
||||||
|
|
||||||
|
if not mods["wood-logistics"] then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
local basic_circuit_board = settings.startup["lignumis-basic-circuit-board"].value
|
||||||
|
|
||||||
|
|
||||||
|
-- Lumber
|
||||||
|
if settings.startup["wood-logistics-lumber"].value then
|
||||||
|
Recipe:new("lumber"):addCategory("wood-processing")
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
-- Lumber mill
|
||||||
|
if settings.startup["wood-logistics-lumber-mill"].value then
|
||||||
|
local lumberMill = data.raw["assembling-machine"]["lumber-mill"]
|
||||||
|
table.assign(lumberMill, {
|
||||||
|
energy_source = {
|
||||||
|
type = "burner",
|
||||||
|
fuel_categories = { "chemical" },
|
||||||
|
effectivity = 1,
|
||||||
|
fuel_inventory_size = 3,
|
||||||
|
emissions_per_minute = { pollution = 10, noise = 100 },
|
||||||
|
},
|
||||||
|
surface_conditions = {
|
||||||
|
{
|
||||||
|
property = has_oxygen and "oxygen" or "pressure",
|
||||||
|
min = 3
|
||||||
|
},
|
||||||
|
{
|
||||||
|
property = "gravity",
|
||||||
|
min = 1
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
table.insert(lumberMill.crafting_categories, "wood-processing")
|
||||||
|
|
||||||
|
data.raw.item["lumber-mill"].default_import_location = "lignumis"
|
||||||
|
|
||||||
|
table.assign(data.raw.recipe["lumber-mill"], {
|
||||||
|
additional_categories = { "wood-processing" },
|
||||||
|
ingredients = table.trim({
|
||||||
|
{ type = "item", name = "stone-brick", amount = 40 },
|
||||||
|
{ type = "item", name = "lumber", amount = 50 },
|
||||||
|
{ type = "item", name = "wooden-gear-wheel", amount = 50 },
|
||||||
|
{ type = "item", name = "gold-plate", amount = basic_circuit_board and 20 or 40 },
|
||||||
|
basic_circuit_board and { type = "item", name = "basic-circuit-board", amount = 20 } or nil,
|
||||||
|
{ type = "item", name = "burner-assembling-machine", amount = 2 }
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
Recipe:new("lumber-mill")
|
||||||
|
:clone("lumber-mill-copper")
|
||||||
|
:assign({
|
||||||
|
localised_name = { "entity-name.lumber-mill" },
|
||||||
|
icons = {
|
||||||
|
{ icon = data.raw.item["lumber-mill"].icon },
|
||||||
|
{ icon = basic_circuit_board and "__base__/graphics/icons/copper-plate.png" or "__base__/graphics/icons/electronic-circuit.png", scale = 0.25, shift = { 8, 8 } }
|
||||||
|
}
|
||||||
|
})
|
||||||
|
:replaceIngredient("gold-plate", "copper-plate")
|
||||||
|
:apply()
|
||||||
|
|
||||||
|
Technology:new(basic_circuit_board and "copper-processing" or "electronics"):addRecipe("lumber-mill-copper")
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
-- Wooden belts
|
||||||
|
if settings.startup["wood-logistics-belts"].value then
|
||||||
|
Recipe:new("wood-transport-belt")
|
||||||
|
:replaceIngredient("copper-cable", "wooden-gear-wheel", 1)
|
||||||
|
:assign({
|
||||||
|
additional_categories = { "wood-processing" }
|
||||||
|
})
|
||||||
|
|
||||||
|
Recipe:new("wood-underground-belt")
|
||||||
|
:assign({
|
||||||
|
additional_categories = { "wood-processing" }
|
||||||
|
})
|
||||||
|
|
||||||
|
Recipe:new("wood-splitter")
|
||||||
|
:replaceIngredient("copper-cable", basic_circuit_board and "basic-circuit-board" or "gold-cable", basic_circuit_board and 5 or nil)
|
||||||
|
:assign({
|
||||||
|
additional_categories = { "wood-processing" }
|
||||||
|
})
|
||||||
|
|
||||||
|
if not basic_circuit_board then
|
||||||
|
Recipe:new("wood-splitter")
|
||||||
|
:clone("wood-splitter-electronic-circuit")
|
||||||
|
:replaceIngredient(basic_circuit_board and "gold-cable" or "basic-circuit-board", "electronic-circuit", 2)
|
||||||
|
:assign({
|
||||||
|
localised_name = { "entity-name.wood-splitter" },
|
||||||
|
icons = {
|
||||||
|
{ icon = data.raw.item["wood-splitter"].icon },
|
||||||
|
{ icon = "__base__/graphics/icons/electronic-circuit.png", scale = 0.25, shift = { 8, 8 } }
|
||||||
|
}
|
||||||
|
})
|
||||||
|
:unlockedByTechnology("electronics")
|
||||||
|
:apply()
|
||||||
|
end
|
||||||
|
|
||||||
|
Item:new("wood-transport-belt")
|
||||||
|
:itemsPerRocket(200)
|
||||||
|
:defaultImportLocation("lignumis")
|
||||||
|
Item:new("wood-underground-belt")
|
||||||
|
:itemsPerRocket(100)
|
||||||
|
:defaultImportLocation("lignumis")
|
||||||
|
Item:new("wood-splitter")
|
||||||
|
:itemsPerRocket(100)
|
||||||
|
:defaultImportLocation("lignumis")
|
||||||
|
|
||||||
|
Technology:new("wood-logistics"):assign({
|
||||||
|
prerequisites = { "wood-science-pack" },
|
||||||
|
unit = {
|
||||||
|
count = 10,
|
||||||
|
ingredients = { { "wood-science-pack", 1 } },
|
||||||
|
time = 10
|
||||||
|
}
|
||||||
|
})
|
||||||
|
Technology:new("logistics"):setPrerequisites({ "automation-science-pack" })
|
||||||
|
end
|
||||||
|
|
@ -14,7 +14,10 @@ data:extend({
|
||||||
|
|
||||||
local has_oxygen = data.raw["surface-property"]["oxygen"] ~= nil
|
local has_oxygen = data.raw["surface-property"]["oxygen"] ~= nil
|
||||||
|
|
||||||
if not mods["wood-logistics"] then
|
if mods["wood-logistics"] then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
LumberMill.EntityBuilder:new()
|
LumberMill.EntityBuilder:new()
|
||||||
:burnerEnergySource({ emissions_per_minute = { noise = 100 } })
|
:burnerEnergySource({ emissions_per_minute = { noise = 100 } })
|
||||||
:baseProductivity(0.5)
|
:baseProductivity(0.5)
|
||||||
|
|
@ -80,59 +83,6 @@ if not mods["wood-logistics"] then
|
||||||
})
|
})
|
||||||
|
|
||||||
Technology:new(basic_circuit_board and "copper-processing" or "electronics"):addRecipe("lumber-mill-copper")
|
Technology:new(basic_circuit_board and "copper-processing" or "electronics"):addRecipe("lumber-mill-copper")
|
||||||
else
|
|
||||||
table.assign(data.raw["assembling-machine"]["lumber-mill"], {
|
|
||||||
energy_source = {
|
|
||||||
type = "burner",
|
|
||||||
fuel_categories = { "chemical" },
|
|
||||||
effectivity = 1,
|
|
||||||
fuel_inventory_size = 3,
|
|
||||||
emissions_per_minute = { pollution = 10, noise = 100 },
|
|
||||||
},
|
|
||||||
crafting_categories = { "wood-processing" },
|
|
||||||
energy_usage = "1000kW",
|
|
||||||
module_slots = 4,
|
|
||||||
max_health = 500,
|
|
||||||
surface_conditions = {
|
|
||||||
{
|
|
||||||
property = has_oxygen and "oxygen" or "pressure",
|
|
||||||
min = 3
|
|
||||||
},
|
|
||||||
{
|
|
||||||
property = "gravity",
|
|
||||||
min = 1
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
data.raw.item["lumber-mill"].default_import_location = "lignumis"
|
|
||||||
|
|
||||||
table.assign(data.raw.recipe["lumber-mill"], {
|
|
||||||
additional_categories = { "wood-processing" },
|
|
||||||
ingredients = table.trim({
|
|
||||||
{ type = "item", name = "stone-brick", amount = 40 },
|
|
||||||
{ type = "item", name = "lumber", amount = 50 },
|
|
||||||
{ type = "item", name = "wooden-gear-wheel", amount = 50 },
|
|
||||||
{ type = "item", name = "gold-plate", amount = basic_circuit_board and 20 or 40 },
|
|
||||||
basic_circuit_board and { type = "item", name = "basic-circuit-board", amount = 20 } or nil,
|
|
||||||
{ type = "item", name = "burner-assembling-machine", amount = 2 }
|
|
||||||
})
|
|
||||||
})
|
|
||||||
|
|
||||||
Recipe:new("lumber-mill")
|
|
||||||
:clone("lumber-mill-copper")
|
|
||||||
:assign({
|
|
||||||
localised_name = { "entity-name.lumber-mill" },
|
|
||||||
icons = {
|
|
||||||
{ icon = data.raw.item["lumber-mill"].icon },
|
|
||||||
{ icon = basic_circuit_board and "__base__/graphics/icons/copper-plate.png" or "__base__/graphics/icons/electronic-circuit.png", scale = 0.25, shift = { 8, 8 } }
|
|
||||||
}
|
|
||||||
})
|
|
||||||
:replaceIngredient("gold-plate", "copper-plate")
|
|
||||||
:apply()
|
|
||||||
|
|
||||||
Technology:new(basic_circuit_board and "copper-processing" or "electronics"):addRecipe("lumber-mill-copper")
|
|
||||||
end
|
|
||||||
|
|
||||||
Recipe:new("wooden-chest"):addCategory("wood-processing")
|
Recipe:new("wooden-chest"):addCategory("wood-processing")
|
||||||
Recipe:new("small-electric-pole"):addCategory("wood-processing")
|
Recipe:new("small-electric-pole"):addCategory("wood-processing")
|
||||||
|
|
@ -1,39 +1,38 @@
|
||||||
local item_sounds = require("__base__.prototypes.item_sounds")
|
local item_sounds = require("__base__.prototypes.item_sounds")
|
||||||
local Recipe = require("__cf-lib__/data/Recipe")
|
|
||||||
|
|
||||||
if not mods["wood-logistics"] then
|
if mods["wood-logistics"] and settings.startup["wood-logistics-lumber"].value then
|
||||||
data:extend({
|
return
|
||||||
{
|
end
|
||||||
type = "item",
|
|
||||||
name = "lumber",
|
data:extend({
|
||||||
icon = Lignumis.graphics .. "icons/lumber.png",
|
{
|
||||||
pictures = {
|
type = "item",
|
||||||
{ filename = Lignumis.graphics .. "icons/lumber.png", size = 64, scale = 0.5 },
|
name = "lumber",
|
||||||
{ filename = Lignumis.graphics .. "icons/lumber-1.png", size = 64, scale = 0.5 },
|
icon = Lignumis.graphics .. "icons/lumber.png",
|
||||||
{ filename = Lignumis.graphics .. "icons/lumber-2.png", size = 64, scale = 0.5 },
|
pictures = {
|
||||||
},
|
{ filename = Lignumis.graphics .. "icons/lumber.png", size = 64, scale = 0.5 },
|
||||||
subgroup = "intermediate-product",
|
{ filename = Lignumis.graphics .. "icons/lumber-1.png", size = 64, scale = 0.5 },
|
||||||
order = "A[basic-intermediates]-c[lumber]",
|
{ filename = Lignumis.graphics .. "icons/lumber-2.png", size = 64, scale = 0.5 },
|
||||||
inventory_move_sound = item_sounds.wood_inventory_move,
|
|
||||||
pick_sound = item_sounds.wood_inventory_pickup,
|
|
||||||
drop_sound = item_sounds.wood_inventory_move,
|
|
||||||
stack_size = 100,
|
|
||||||
random_tint_color = { 1.0, 0.95, 0.9, 1.0 },
|
|
||||||
fuel_category = "wood",
|
|
||||||
fuel_value = "4MJ"
|
|
||||||
},
|
},
|
||||||
{
|
subgroup = "intermediate-product",
|
||||||
type = "recipe",
|
order = "A[basic-intermediates]-c[lumber]",
|
||||||
name = "lumber",
|
inventory_move_sound = item_sounds.wood_inventory_move,
|
||||||
category = "crafting",
|
pick_sound = item_sounds.wood_inventory_pickup,
|
||||||
additional_categories = { "wood-processing" },
|
drop_sound = item_sounds.wood_inventory_move,
|
||||||
allow_productivity = true,
|
stack_size = 100,
|
||||||
allow_as_intermediate = true,
|
random_tint_color = { 1.0, 0.95, 0.9, 1.0 },
|
||||||
ingredients = { { type = "item", name = "wood", amount = 2 } },
|
fuel_category = "wood",
|
||||||
results = { { type = "item", name = "lumber", amount = 1 } },
|
fuel_value = "4MJ"
|
||||||
energy_required = 1
|
},
|
||||||
}
|
{
|
||||||
})
|
type = "recipe",
|
||||||
else
|
name = "lumber",
|
||||||
Recipe:new("lumber"):addCategory("wood-processing")
|
category = "crafting",
|
||||||
end
|
additional_categories = { "wood-processing" },
|
||||||
|
allow_productivity = true,
|
||||||
|
allow_as_intermediate = true,
|
||||||
|
ingredients = { { type = "item", name = "wood", amount = 2 } },
|
||||||
|
results = { { type = "item", name = "lumber", amount = 1 } },
|
||||||
|
energy_required = 1
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
@ -1,151 +1,108 @@
|
||||||
local BeltFactory = require(MF.logistics .. "Belts")
|
local BeltFactory = require(MF.logistics .. "Belts")
|
||||||
local Belt = BeltFactory("wood", "brown", "slow")
|
local Belt = BeltFactory("wood", "brown", "slow")
|
||||||
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
|
local basic_circuit_board = settings.startup["lignumis-basic-circuit-board"].value
|
||||||
|
|
||||||
if not mods["wood-logistics"] then
|
if mods["wood-logistics"] and settings.startup["wood-logistics-belts"].value then
|
||||||
Belt.EntityBuilder:new()
|
return
|
||||||
:itemsPerSecond(7.5)
|
end
|
||||||
:nextTier("")
|
|
||||||
:undergroundDistance(4)
|
Belt.EntityBuilder:new()
|
||||||
:animationSpeedMultiplier(1.01)
|
:itemsPerSecond(7.5)
|
||||||
:apply({
|
:nextTier("")
|
||||||
transportBelt = {
|
:undergroundDistance(4)
|
||||||
emissions_per_second = { noise = 2 / 60 }
|
:animationSpeedMultiplier(1.01)
|
||||||
},
|
:apply({
|
||||||
undergroundBelt = {
|
transportBelt = {
|
||||||
emissions_per_second = { noise = 7.5 / 60 },
|
emissions_per_second = { noise = 2 / 60 }
|
||||||
factoriopedia_simulation = {
|
},
|
||||||
init =
|
undergroundBelt = {
|
||||||
[[
|
emissions_per_second = { noise = 7.5 / 60 },
|
||||||
game.simulation.camera_position = {0, 0.5}
|
factoriopedia_simulation = {
|
||||||
game.simulation.camera_zoom = 1.8
|
init =
|
||||||
game.surfaces[1].create_entities_from_blueprint_string
|
[[
|
||||||
{
|
game.simulation.camera_position = {0, 0.5}
|
||||||
string = "0eNqVUNsKgzAM/Zc81+FEBfsrYwwvQQKaltpuivjvS3Wwh8HGnkKSc0tWaIaA1hF70CtMXNvEm6R31MV+Bl0oWECfNwXUGp5AXwRGPddDBHA9Imh4GNMlgTt0vTNSkwYHD5EjsznSrwqQPXnCQ2JvlhuHsUEnAPVdSoE1k7ANv2KlpyOYVLHpyGF7bHMFfrFRidiGGOLDLPvXLP9tZoLf3eRO8jjK5P1YBXd0004oyqzKq6ooqzLNinLbnvlmf6E=",
|
game.simulation.camera_zoom = 1.8
|
||||||
position = {-0.5, 0}
|
game.surfaces[1].create_entities_from_blueprint_string
|
||||||
}
|
{
|
||||||
]]
|
string = "0eNqVUNsKgzAM/Zc81+FEBfsrYwwvQQKaltpuivjvS3Wwh8HGnkKSc0tWaIaA1hF70CtMXNvEm6R31MV+Bl0oWECfNwXUGp5AXwRGPddDBHA9Imh4GNMlgTt0vTNSkwYHD5EjsznSrwqQPXnCQ2JvlhuHsUEnAPVdSoE1k7ANv2KlpyOYVLHpyGF7bHMFfrFRidiGGOLDLPvXLP9tZoLf3eRO8jjK5P1YBXd0004oyqzKq6ooqzLNinLbnvlmf6E=",
|
||||||
|
position = {-0.5, 0}
|
||||||
}
|
}
|
||||||
},
|
]]
|
||||||
splitter = {
|
|
||||||
emissions_per_second = { noise = 20 / 60 }
|
|
||||||
}
|
}
|
||||||
})
|
},
|
||||||
|
splitter = {
|
||||||
|
emissions_per_second = { noise = 20 / 60 }
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
local splitter_item = Belt.ItemBuilder:new()
|
local splitter_item = Belt.ItemBuilder:new()
|
||||||
:itemsPerRocket("transportBelt", 200)
|
:itemsPerRocket("transportBelt", 200)
|
||||||
:itemsPerRocket("undergroundBelt", 100)
|
:itemsPerRocket("undergroundBelt", 100)
|
||||||
:itemsPerRocket("splitter", 100)
|
:itemsPerRocket("splitter", 100)
|
||||||
:order("0")
|
:order("0")
|
||||||
:apply()
|
:apply()
|
||||||
.splitter
|
.splitter
|
||||||
|
|
||||||
Belt.RecipeBuilder:new()
|
Belt.RecipeBuilder:new()
|
||||||
:beltAmount(2)
|
:beltAmount(2)
|
||||||
:ingredients("transportBelt", {
|
:ingredients("transportBelt", {
|
||||||
{ type = "item", name = "lumber", amount = 1 },
|
{ type = "item", name = "lumber", amount = 1 },
|
||||||
{ type = "item", name = "wooden-gear-wheel", amount = 1 }
|
{ type = "item", name = "wooden-gear-wheel", amount = 1 }
|
||||||
})
|
})
|
||||||
:ingredients("undergroundBelt", {
|
:ingredients("undergroundBelt", {
|
||||||
{ type = "item", name = "lumber", amount = 1 },
|
{ type = "item", name = "lumber", amount = 1 },
|
||||||
{ type = "item", name = "wood-transport-belt", amount = 4 },
|
{ type = "item", name = "wood-transport-belt", amount = 4 },
|
||||||
})
|
})
|
||||||
:ingredients("splitter", {
|
:ingredients("splitter", {
|
||||||
{ type = "item", name = "wood-transport-belt", amount = 2 },
|
{ type = "item", name = "wood-transport-belt", amount = 2 },
|
||||||
{ type = "item", name = "lumber", amount = 2 },
|
{ type = "item", name = "lumber", amount = 2 },
|
||||||
basic_circuit_board and { type = "item", name = "basic-circuit-board", amount = 5 } or
|
basic_circuit_board and { type = "item", name = "basic-circuit-board", amount = 5 } or
|
||||||
{ type = "item", name = "gold-cable", amount = 10 }
|
{ type = "item", name = "gold-cable", amount = 10 }
|
||||||
})
|
})
|
||||||
:apply({
|
:apply({
|
||||||
transportBelt = {
|
transportBelt = {
|
||||||
additional_categories = { "wood-processing" }
|
|
||||||
},
|
|
||||||
undergroundBelt = {
|
|
||||||
additional_categories = { "wood-processing" }
|
|
||||||
},
|
|
||||||
splitter = {
|
|
||||||
additional_categories = { "wood-processing" }
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
Belt.TechnologyBuilder:new()
|
|
||||||
:prerequisites({ "wood-science-pack" })
|
|
||||||
:ingredients({ { "wood-science-pack", 1 } })
|
|
||||||
:count(10)
|
|
||||||
:time(10)
|
|
||||||
:apply()
|
|
||||||
|
|
||||||
if not basic_circuit_board then
|
|
||||||
data:extend({
|
|
||||||
Belt.RecipeBuilder:new()
|
|
||||||
:ingredients("splitter", {
|
|
||||||
{ type = "item", name = "wood-transport-belt", amount = 2 },
|
|
||||||
{ type = "item", name = "lumber", amount = 2 },
|
|
||||||
{ type = "item", name = "electronic-circuit", amount = 2 }
|
|
||||||
})
|
|
||||||
:build({
|
|
||||||
splitter = {
|
|
||||||
name = "wood-splitter-electronic-circuit",
|
|
||||||
localised_name = { "entity-name.wood-splitter" },
|
|
||||||
icons = {
|
|
||||||
{ icon = splitter_item.icon },
|
|
||||||
{ icon = "__base__/graphics/icons/electronic-circuit.png", scale = 0.25, shift = { 8, 8 } }
|
|
||||||
},
|
|
||||||
additional_categories = { "wood-processing" }
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.splitter
|
|
||||||
})
|
|
||||||
|
|
||||||
table.insert(data.raw.technology["electronics"].effects, {
|
|
||||||
type = "unlock-recipe",
|
|
||||||
recipe = "wood-splitter-electronic-circuit"
|
|
||||||
})
|
|
||||||
end
|
|
||||||
|
|
||||||
else
|
|
||||||
Recipe:new("wood-transport-belt")
|
|
||||||
:replaceIngredient("copper-cable", "wooden-gear-wheel", 1)
|
|
||||||
:assign({
|
|
||||||
additional_categories = { "wood-processing" }
|
additional_categories = { "wood-processing" }
|
||||||
})
|
},
|
||||||
|
undergroundBelt = {
|
||||||
Recipe:new("wood-underground-belt")
|
|
||||||
:assign({
|
|
||||||
additional_categories = { "wood-processing" }
|
additional_categories = { "wood-processing" }
|
||||||
})
|
},
|
||||||
|
splitter = {
|
||||||
Recipe:new("wood-splitter")
|
|
||||||
:replaceIngredient("copper-cable", basic_circuit_board and "basic-circuit-board" or "gold-cable", basic_circuit_board and 5 or nil)
|
|
||||||
:assign({
|
|
||||||
additional_categories = { "wood-processing" }
|
additional_categories = { "wood-processing" }
|
||||||
})
|
}
|
||||||
|
})
|
||||||
|
|
||||||
if not basic_circuit_board then
|
Belt.TechnologyBuilder:new()
|
||||||
Recipe:new("wood-splitter")
|
:prerequisites({ "wood-science-pack" })
|
||||||
:clone("wood-splitter-electronic-circuit")
|
:ingredients({ { "wood-science-pack", 1 } })
|
||||||
:replaceIngredient(basic_circuit_board and "gold-cable" or "basic-circuit-board", "electronic-circuit", 2)
|
:count(10)
|
||||||
:assign({
|
:time(10)
|
||||||
localised_name = { "entity-name.wood-splitter" },
|
:apply()
|
||||||
icons = {
|
|
||||||
{ icon = data.raw.item["wood-splitter"].icon },
|
if not basic_circuit_board then
|
||||||
{ icon = "__base__/graphics/icons/electronic-circuit.png", scale = 0.25, shift = { 8, 8 } }
|
data:extend({
|
||||||
|
Belt.RecipeBuilder:new()
|
||||||
|
:ingredients("splitter", {
|
||||||
|
{ type = "item", name = "wood-transport-belt", amount = 2 },
|
||||||
|
{ type = "item", name = "lumber", amount = 2 },
|
||||||
|
{ type = "item", name = "electronic-circuit", amount = 2 }
|
||||||
|
})
|
||||||
|
:build({
|
||||||
|
splitter = {
|
||||||
|
name = "wood-splitter-electronic-circuit",
|
||||||
|
localised_name = { "entity-name.wood-splitter" },
|
||||||
|
icons = {
|
||||||
|
{ icon = splitter_item.icon },
|
||||||
|
{ icon = "__base__/graphics/icons/electronic-circuit.png", scale = 0.25, shift = { 8, 8 } }
|
||||||
|
},
|
||||||
|
additional_categories = { "wood-processing" }
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
:unlockedByTechnology("electronics")
|
.splitter
|
||||||
:apply()
|
})
|
||||||
end
|
|
||||||
|
|
||||||
Item:new("wood-transport-belt")
|
table.insert(data.raw.technology["electronics"].effects, {
|
||||||
:itemsPerRocket(200)
|
type = "unlock-recipe",
|
||||||
:defaultImportLocation("lignumis")
|
recipe = "wood-splitter-electronic-circuit"
|
||||||
Item:new("wood-underground-belt")
|
})
|
||||||
:itemsPerRocket(100)
|
|
||||||
:defaultImportLocation("lignumis")
|
|
||||||
Item:new("wood-splitter")
|
|
||||||
:itemsPerRocket(100)
|
|
||||||
:defaultImportLocation("lignumis")
|
|
||||||
end
|
end
|
||||||
|
|
@ -70,7 +70,9 @@ if settings.startup["lignumis-vanilla-lab"].value then
|
||||||
Recipe:new("transport-belt"):unlockedByTechnology("iron-processing")
|
Recipe:new("transport-belt"):unlockedByTechnology("iron-processing")
|
||||||
else
|
else
|
||||||
Recipe:new("lab"):replaceIngredient("transport-belt", "wood-transport-belt")
|
Recipe:new("lab"):replaceIngredient("transport-belt", "wood-transport-belt")
|
||||||
Recipe:new("transport-belt"):unlockedByTechnology("logistics")
|
if not mods["wood-logistics"] or not settings.startup["wood-logistics-belts"].value then
|
||||||
|
Recipe:new("transport-belt"):unlockedByTechnology("logistics")
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -6,15 +6,4 @@ local Settings = require("__cf-lib__/settings/Settings")
|
||||||
local force = Settings.force
|
local force = Settings.force
|
||||||
local default = Settings.default
|
local default = Settings.default
|
||||||
|
|
||||||
force("wood-logistics-lumber", true)
|
force("wood-logistics-woodtronics", false)
|
||||||
force("wood-logistics-lumber-mill", true)
|
|
||||||
force("wood-logistics-woodtronics", false)
|
|
||||||
force("wood-logistics-belts", true)
|
|
||||||
force("wood-logistics-belts-modify", false)
|
|
||||||
default("wood-logistics-belts-circuits", true)
|
|
||||||
force("wood-logistics-inserter", false)
|
|
||||||
default("wood-logistics-rail-cost", 0)
|
|
||||||
default("wood-logistics-cargo-wagon", false)
|
|
||||||
force("wood-logistics-assembling-machine", false)
|
|
||||||
default("wood-logistics-nerf-small-electric-pole", false)
|
|
||||||
force("wood-logistics-repair-pack-cost", 0)
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue