Quantum Resource Distribution

by eliont

Special chest can send placed items to ship quantum storage unit and retrieve from it. Also works for player inventory. It's make resource management more like RTS for playing combat-oriented settings/mods like Warp Drive Machine. Item transportation works across each surface, but not between them. UPS-friendly. Works with factorissimo-2-notnotmelon_3.x.x.

Content
1 year, 10 months ago
1.1 - 2.0
1.29K
Logistics Logistic network Circuit network Storage

b Planet Bug Fix (Quantum Storage Interface)

7 days ago

functions.lua, replace set_combinator

function set_combinator(entity)
local surface_name = get_surface_name(entity.surface)
if script.active_mods["AdeptusRiftbreaker"] then surface_name = "riftbreaker" end
if not storage.pool[surface_name] then return end
local surface_content = storage.pool[surface_name]
local control = entity.get_control_behavior()
if not control then return end

local group_name = "QuantumResourceDistribution#" .. entity.unit_number
local section = control.get_section(1)
if not section then
control.add_section(group_name)
return
end

local index = 1
section.group = group_name

for i = 1,section.filters_count do
section.clear_slot(i)
end

for name,data in pairs(surface_content) do
if item_prototype(name) then
if data['amount'] > 0 then
section.set_slot(index,{value=name,min=data['amount']})
index = index + 1
end
end
end

end

New response