feat: puljen må låne stoppet flows gyllevogn/spreder fra parkering (Stop alle satte Supercis'erne på plads; F27 fik MEGA) — 1.62.318

This commit is contained in:
2026-10-17 12:05:47 +02:00
parent 92b053dd91
commit 05eeef8a2c
4 changed files with 12 additions and 7 deletions
+3 -2
View File
@@ -584,7 +584,8 @@ function ADPool.collect(adEnv, isBusy)
local specs = connect ~= nil and ADCpBridge.getSpecs(vehicle) or nil
local role = specs ~= nil and ADPool.roleOf(specs) or nil
-- flowvogne: kun et sovende flows vogn må lånes (ADFlowWagons.isLendable)
local held = role ~= nil and ADFlowWagons ~= nil and ADFlowWagons.isLendableWagon ~= nil and not ADFlowWagons.isLendableWagon(ADRunsController.getVehicleId(vehicle))
local held = role ~= nil and ADFlowWagons ~= nil and ADFlowWagons.isLendableWagon ~= nil
and not ADFlowWagons.isLendableWagon(ADRunsController.getVehicleId(vehicle), vehicle.spec_sprayer ~= nil)
if role ~= nil and not held and not targeted[connect.id] then
local x, z = positionOf(vehicle)
local carries, capacity = ADPool.cargoOf(vehicle)
@@ -641,7 +642,7 @@ function ADPool.overview(adEnv)
attachedTo = attacher ~= nil and ADRuns.vehicleLabel(attacher) or nil,
quarantineMin = id ~= nil and ADPool.quarantineMinutes(id, nowMs) or 0,
reserved = id ~= nil and ADPool.isReserved(id),
flowName = id ~= nil and ADFlowWagons ~= nil and ADFlowWagons.isLendableWagon ~= nil and not ADFlowWagons.isLendableWagon(id)
flowName = id ~= nil and ADFlowWagons ~= nil and ADFlowWagons.isLendableWagon ~= nil and not ADFlowWagons.isLendableWagon(id, vehicle.spec_sprayer ~= nil)
and tostring(ADFlowWagons.ownerOf(ADRunsController.store.runs, id).name) or nil,
})
table.insert(implements, {id = id, label = ADRuns.vehicleLabel(vehicle), role = role, status = key, arg = arg})