Is there a way to make a train skip a stop, or stay where it is?

Don't know how to use a machine? Looking for efficient setups? Stuck in a mission?
Post Reply
Destro_Night
Manual Inserter
Manual Inserter
Posts: 2
Joined: Tue Sep 06, 2022 7:07 pm
Contact:

Is there a way to make a train skip a stop, or stay where it is?

Post by Destro_Night »

I just had a questions on if the following was even possible, before I get home tonight and spend 3 hours trying to figure it out, only to find out it's not possible.

The TL:DR: Is there a way to make a train skip a stop, or stay where it is, if it's cargo is full or empty?

Long Form: So I have alot of resources far away, and have alot of long distance tracks to get there. The trains go out to the mines, come drop off the ore at smelters, and then the the mats go to the main bus. I have the mines wired to close the station if they don't have enough ore to fill a train. Sometimes it takes me a minute to realize the mines are slowing down (I'm playing space exploration, and I'm slow, cut me some slack). Now I have fueling stations, so every train in the network has a spot it goes to refuel. But if it doesn't have a mine to go to, and empty cargo, it will still go between it's home station and the drop off station. And that just burns unneeded fuel. It used to clog the network, but I have it pretty efficient now. But it would just be....idk, cool, if i could have the train chill at it's home station until it can actually go to the dropoff with ore. So, stay at home station if cargo empty and mine station closed, and not loop between home and dropoff stations endlessly..

I know "Be more attentive" is the most obvious solution, but is it the only solution?

User avatar
Nosferatu
Fast Inserter
Fast Inserter
Posts: 228
Joined: Fri Jan 20, 2017 4:48 pm
Contact:

Re: Is there a way to make a train skip a stop, or stay where it is?

Post by Nosferatu »

Don't close the mines instead reduce train limit to 0.
That should make them not skip them

Loewchen
Global Moderator
Global Moderator
Posts: 8322
Joined: Wed Jan 07, 2015 5:53 pm
Contact:

Re: Is there a way to make a train skip a stop, or stay where it is?

Post by Loewchen »

You cannot make a train skip a station while keeping the station available for other trains. What you could do is add a "holding station" after the refuel station and keep the train in it until there is something to do for it.

What you should do though is not disabling stations at all and instead create dynamic station limits and build holding bays for the trains to wait in until a stop gets available.

aka13
Filter Inserter
Filter Inserter
Posts: 688
Joined: Sun Sep 29, 2013 1:18 pm
Contact:

Re: Is there a way to make a train skip a stop, or stay where it is?

Post by aka13 »

Loewchen wrote:
Thu May 18, 2023 5:35 pm
You cannot make a train skip a station while keeping the station available for other trains. What you could do is add a "holding station" after the refuel station and keep the train in it until there is something to do for it.

What you should do though is not disabling stations at all and instead create dynamic station limits and build holding bays for the trains to wait in until a stop gets available.
Not skipping stations severely limits train options.
LTN did not became popular, because vanilla sheduling is so good and nice to use.
Pony/Furfag avatar? Opinion discarded.

Tertius
Filter Inserter
Filter Inserter
Posts: 675
Joined: Fri Mar 19, 2021 5:58 pm
Contact:

Re: Is there a way to make a train skip a stop, or stay where it is?

Post by Tertius »

I use this setup for long running ore trains:
  • all mines for the same ore have the same name
  • all smelter stations for the same ore+output product have the same name
  • 4 different stations on the schedule.
  • 1st station "<ore> depot empty train" and contains a stacker that is able to hold almost all trains. It's located near the base, but not within the base. Only one of this exists. No condition. Train limit is amount of stacker lanes.
  • 2nd station "<ore> pickup", condition "Inventory full". That's the mine station. Multiple.
  • 3rd station "<ore> depot for <material>" and contains a stacker that is able to hold almost all trains. It's located in front of the smelters for <material>. Only one of this exists. No condition. Train limit is amount of stacker lanes.
  • 4th station "<ore> delivery for <material>", condition "Inventory empty". That's the smelter. Multiple. This is also the refueling spot: A requester chest for fuel with inserter. Since every train will deliver its goods some point in time, and it will this somewhere within the base, it seems a good spot here.
Pickup stations have a circuit that divides the summed up chest content by the train capacity. This is the number of trains that can immediately be filled from the chests, so it is used as train limit. Since this number can be quite big, I limit it to 2 and make sure I have space for 1 train in front of the station.

Delivery stations have a circuit that subtracts the summed up chest content from the station capacity. This is then divided by the train capacity. This is the number of trains that can immediately fill the chests without waiting time, so it is used as train limit. Since this number can be quite big, I limit it to whatever space I have in front of the station - often only 1, sometimes 2.
Screenshot 2023-05-19 144536 1.png
Screenshot 2023-05-19 144536 1.png (188.66 KiB) Viewed 1533 times
This way trains never wait for chests slowly filling or slowly emptying, because a train is only admitted to a station if there is enough ore or enough space. You can see it in a way that every train gets its own reserved slot at a station, as soon enough ore or enough space has been accumulated to satisfy this slot.

Deactivating stations isn't a good solution for ore trains, because it can make trains stop right in the middle of nowhere and block the tracks, if by chance all stations with the same name are deactivated.

Additionally, it has been said by the devs that for 1.2, stations are not deactivated any more. Instead, it's internally mapped to train limit 0. This way trains cannot actually skip a station any more, which is the case if you currently deactivate a station. Currently, a train just continues with the next station on the schedule. So to not be surprised by a changed behavior in the upcoming 1.2, just don't use deactivating stations.

Amarula
Filter Inserter
Filter Inserter
Posts: 512
Joined: Fri Apr 27, 2018 1:29 pm
Contact:

Re: Is there a way to make a train skip a stop, or stay where it is?

Post by Amarula »

Tertius wrote:
Fri May 19, 2023 12:33 pm
Additionally, it has been said by the devs that for 1.2, stations are not deactivated any more. Instead, it's internally mapped to train limit 0. This way trains cannot actually skip a station any more, which is the case if you currently deactivate a station. Currently, a train just continues with the next station on the schedule. So to not be surprised by a changed behavior in the upcoming 1.2, just don't use deactivating stations.
Thanks for sharing the proposed change, I hadn't seen that posted before.

I don't use disabling to skip stops. I do 'abuse' the ability to disable a station in the case where the limit I want is either zero or one, and the condition for opening the stop is simple 'item < limit' or 'item > limit'. The reason I do it is because I can set that 'limit' with a single wire from the loading/unloading chests to the train stop. And from anywhere on the map, I can click on the train stop and see what the condition is and change it if needed.
To actually program the limit (at least so far), I would have to have at least one combinator wired to the chests to do the calculation and output the value of L. And while I could remotely see the input to, and output from the combinator, I couldn't tell what the condition is or change it unless I am right there (or I make a copy of the combinator and place it where I am, and change it if needed, and blueprint it not just copy, and then place the blueprint over the combinator, all of which is much more painful than tweaking the condition in the train stop itself).

I am quite happy with the proposed change to implement disabled stops as changing the train limit to zero, it will not hamper my designed train stop usage at all.
My own personal Factorio super-power - running out of power.

Tertius
Filter Inserter
Filter Inserter
Posts: 675
Joined: Fri Mar 19, 2021 5:58 pm
Contact:

Re: Is there a way to make a train skip a stop, or stay where it is?

Post by Tertius »

Amarula wrote:
Fri May 19, 2023 1:42 pm
To actually program the limit (at least so far), I would have to have at least one combinator wired to the chests to do the calculation and output the value of L. And while I could remotely see the input to, and output from the combinator, I couldn't tell what the condition is or change it unless I am right there (or I make a copy of the combinator and place it where I am, and change it if needed, and blueprint it not just copy, and then place the blueprint over the combinator, all of which is much more painful than tweaking the condition in the train stop itself).
In general, you're right. It's somewhat tedious to check and change combinator settings remotely.
"Copy"+paste works for me to transfer settings to a remote combinator. Doesn't need to be a blueprint. Internally, a copy is a shortcut blueprint, just the screen is skipped where you configure the blueprint and press the "create blueprint" button.

However, if you really need a blueprint instead of a copy, press Shift while drawing the outline for selecting the items for a copy. This will get you the blueprint creation screen for the copy. This enables you to explicitly include/exclude objects, trains, modules, fuel, station names and tile objects in the copy. The only difference between this shortcut and a blueprint created from a blank blueprint is that it's still in the clipboard if you drop it or place it on the ground. This is so convenient, I removed the "blueprint" button from the toolbar and only create blueprints this way.

Amarula
Filter Inserter
Filter Inserter
Posts: 512
Joined: Fri Apr 27, 2018 1:29 pm
Contact:

Re: Is there a way to make a train skip a stop, or stay where it is?

Post by Amarula »

Tertius wrote:
Fri May 19, 2023 2:18 pm
This is so convenient, I removed the "blueprint" button from the toolbar and only create blueprints this way.
Good to know - thank you!
My own personal Factorio super-power - running out of power.

Post Reply

Return to “Gameplay Help”