Your model file doesn't have vehicle lanes defined, only cargo lanes. That's OK, but it does mean that you will need to use vehicleNodeOverride for the truck terminal as well.
I think this might be what is causing your crash, although I can't say for sure.
Also, I think you will want to break each of your truck and rail tracks into two sections, so you can use a node that is in the middle of the road/track section. Something like this:
Google Translate:
In Ihrer Modelldatei sind keine Fahrzeugspuren definiert, sondern nur Frachtspuren. Das ist in Ordnung, bedeutet aber, dass Sie vehicleNodeOverride auch für das LKW-Terminal verwenden müssen.
Ich vermute, das könnte die Ursache für Ihren Absturz sein, kann es aber nicht mit Sicherheit sagen.
Außerdem sollten Sie Ihre LKW- und Gleisstrecken in zwei Abschnitte unterteilen, um einen Knotenpunkt in der Mitte des Straßen-/Gleisabschnitts verwenden zu können. Etwa so:
-- 1. Straße (edgeList 0)
table.insert(result.edgeLists, {
type = "STREET",
params = {
type = "standard/country_small_new.lua",
tramTrackType = "NO"
},
edges = {
{ { -20, 13, 0 }, { 20, 0, 0 } }, -- node 0
{ { 0, 13, 0 }, { 20, 0, 0 } }, -- node 1
},
snapNodes = { 0, 1 }
})
-- 2. Straße (edgeList 1)
table.insert(result.edgeLists, {
type = "STREET",
params = {
type = "standard/country_small_new.lua",
tramTrackType = "NO"
},
edges = {
{ { 0, 13, 0 }, { 20, 0, 0 } }, -- node 2
{ { 20, 13, 0 }, { 20, 0, 0 } }, -- node 3
},
snapNodes = { 0, 1 }
})
local tangent = { length/2, 0, 0 }
-- 3. Hauptgleis (edgeList 2)
table.insert(result.edgeLists, {
type = "TRACK",
params = {
type = "standard.lua",
catenary = false
},
edges = {
{ { -length / 2, -11.4, 0 }, tangent }, -- node 4
{ { 0, -11.4, 0 }, tangent }, -- node 5
},
snapNodes = { 0, 1 }
})
-- 4. Hauptgleis (edgeList 3)
table.insert(result.edgeLists, {
type = "TRACK",
params = {
type = "standard.lua",
catenary = false
},
edges = {
{ { 0, -11.4, 0 }, tangent }, -- node 6
{ { length / 2, -11.4, 0 }, tangent }, -- node 7
},
snapNodes = { 0, 1 }
})
-- 5. bis n. zusätzliche Gleise (edgeList 2..n)
local numTracks = tonumber(params.additionalTracks) or 0
for i = 1, numTracks do
local yOffset = -11.4 - (i * spacing)
table.insert(result.edgeLists, {
type = "TRACK",
params = {
type = "standard.lua",
catenary = false
},
edges = {
{ { -length / 2, yOffset, 0 }, tangent },
{ { length / 2, yOffset, 0 }, tangent },
},
snapNodes = {}
})
end
-- Terminals
result.terminalGroups = {
{
terminals = { { 0, 0 } }, -- Modell 0, Terminal 0 (Truck)
vehicleNodeOverride = 2
},
{
terminals = { { 0, 1 } }, -- Modell 0, Terminal 1 (Rail)
vehicleNodeOverride = 6
}
}
-- Stationen
result.stations = {
{
terminals = { 0, }, pool = {moreCapacity = length*5}, --extra storage, just for fun
tag = 0 -- Road
},
{
terminals = { 1, }, pool = {moreCapacity = length*5},
tag = 1 -- Rail
}
}
Alles anzeigen