fix: markmarkører bruges aldrig som salgssted (v1.62.61)

This commit is contained in:
2026-10-07 21:44:31 +02:00
parent d25937c115
commit 514da163a9
3 changed files with 10 additions and 2 deletions
+8 -1
View File
@@ -680,9 +680,16 @@ local function isServiceMarker(marker)
return ADFieldWork ~= nil and ADFieldWork.isServiceMarker ~= nil and ADFieldWork.isServiceMarker(marker) == true
end
-- Andre (ikke-salgs) bygningers læsse- og aflæsningsmarkører (palleskur, silo, stald, fabrik): {[waypoint-id] = true}.
-- Andre (ikke-salgs) bygningers læsse- og aflæsningsmarkører (palleskur, silo, stald, fabrik) og markernes markører
-- (in-game 7/10: 'Oil Mill' uden egen markør fik markmarkøren "F21"): {[waypoint-id] = true}.
local function foreignMarkerIds(adEnv, farmId)
local ids = {}
if ADFields ~= nil and ADFields.list ~= nil then
local okFields, fields = pcall(ADFields.list)
for _, info in ipairs(okFields and fields or {}) do
if info.markerId ~= nil then ids[info.markerId] = true end
end
end
if ADBuildings == nil or ADBuildings.list == nil then return ids end
local ok, buildings = pcall(ADBuildings.list, adEnv, farmId)
for _, building in ipairs(ok and buildings or {}) do