Request feature: nearest depot calculation by road.

Adds new train stops forming a highly configurable logistic network.

Moderator: Optera

Post Reply
zggz
Long Handed Inserter
Long Handed Inserter
Posts: 88
Joined: Thu Dec 07, 2017 6:40 pm
Contact:

Request feature: nearest depot calculation by road.

Post by zggz »

Now station choose free train on nearest depot on map. To calculate it mod uses distance on map between station and depot. Now we need to set personal depot for every production. Can we make calculation depend on road length? In this case we can do 1 depot for couple production without any problems.

User avatar
Optera
Smart Inserter
Smart Inserter
Posts: 2916
Joined: Sat Jun 11, 2016 6:41 am
Contact:

Re: Request feature: nearest depot calculation by road.

Post by Optera »

I assume by road length you mean path cost from Factorio's train pathfinder.

Short answer:
No

Long answer:
The API doesn't expose anything about pathfinder and reprogramming it in LUA would have terrible performance.
Once the pathfinder is exposed through the API I might switch over to using that instead of linear distance.

zggz
Long Handed Inserter
Long Handed Inserter
Posts: 88
Joined: Thu Dec 07, 2017 6:40 pm
Contact:

Re: Request feature: nearest depot calculation by road.

Post by zggz »

Ok. I will wait for.

zggz
Long Handed Inserter
Long Handed Inserter
Posts: 88
Joined: Thu Dec 07, 2017 6:40 pm
Contact:

Re: Request feature: nearest depot calculation by road.

Post by zggz »

Another idea: in depot we set something like network id and the same at stations that this serves. In this case trains come to station only from 1 depot. Can you do this?

User avatar
Optera
Smart Inserter
Smart Inserter
Posts: 2916
Joined: Sat Jun 11, 2016 6:41 am
Contact:

Re: Request feature: nearest depot calculation by road.

Post by Optera »

zggz wrote:
Mon Nov 12, 2018 4:17 pm
Another idea: in depot we set something like network id and the same at stations that this serves. In this case trains come to station only from 1 depot. Can you do this?
That's how network id works if you leave requesters at ANY.

zggz
Long Handed Inserter
Long Handed Inserter
Posts: 88
Joined: Thu Dec 07, 2017 6:40 pm
Contact:

Re: Request feature: nearest depot calculation by road.

Post by zggz »

But in this case i need to set all requesters with the same id.

Post Reply

Return to “Logistic Train Network”