mirror of
https://github.com/Xevion/project-cybersyn.git
synced 2025-12-14 12:12:42 -06:00
manager gui inventory: only include requests GTEQ threshold
This commit is contained in:
@@ -132,6 +132,12 @@ function inventory_tab.build(map_data, player_data)
|
|||||||
inventory_provided[item.name] = inventory_provided[item.name] + count
|
inventory_provided[item.name] = inventory_provided[item.name] + count
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
|
local r_threshold = station.item_thresholds and station.item_thresholds[item.name] or station.r_threshold
|
||||||
|
if station.is_stack and item_type == "item" then
|
||||||
|
r_threshold = r_threshold*get_stack_size(map_data, item.name)
|
||||||
|
end
|
||||||
|
|
||||||
|
if -count >= r_threshold then
|
||||||
if inventory_requested[item.name] == nil then
|
if inventory_requested[item.name] == nil then
|
||||||
inventory_requested[item.name] = count
|
inventory_requested[item.name] = count
|
||||||
else
|
else
|
||||||
@@ -141,6 +147,7 @@ function inventory_tab.build(map_data, player_data)
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
local deliveries = station.deliveries
|
local deliveries = station.deliveries
|
||||||
if deliveries then
|
if deliveries then
|
||||||
|
|||||||
Reference in New Issue
Block a user