Request feature: nearest depot calculation by road.
Moderator: Optera
Request feature: nearest depot calculation by road.
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.
Re: Request feature: nearest depot calculation by road.
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.
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.
My Mods: mods.factorio.com
Re: Request feature: nearest depot calculation by road.
Ok. I will wait for.
Re: Request feature: nearest depot calculation by road.
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?
Re: Request feature: nearest depot calculation by road.
That's how network id works if you leave requesters at ANY.
My Mods: mods.factorio.com
Re: Request feature: nearest depot calculation by road.
But in this case i need to set all requesters with the same id.