this post was submitted on 10 May 2026
21 points (100.0% liked)

Games

21299 readers
45 users here now

Tabletop, DnD, board games, and minecraft. Also Animal Crossing.

Rules

founded 5 years ago
MODERATORS
 

So, I have 2 train routes for exports, highlighted for visibility:

  • A cement train that runs between the red line (at the end of which is a loading station for cement) and the customs house at the far end of the green line
  • A gravel train that runs from the aggregate loading station at the end of the blue line to the same customs house

Here's the behavior I want:

  • When returning from the green route, a train has right-of-way to return to its loading station
  • If a train arrives at the intersection from the red or blue route, it should proceed only if there is no train on the green line; otherwise, it should wait until the green line is clear

I'm not entirely sure how semaphores work and no combination of them seems to do the trick. I get trains unable to return from the customs house, trains colliding, or trains forever deadlocked at the junction. I've watched/read like 3 different tutorials and I'm still not sure what I'm supposed to do.

you are viewing a single comment's thread
view the rest of the comments
[โ€“] Carl@hexbear.net 4 points 6 days ago* (last edited 6 days ago) (1 children)

If you want a simple rail like this, the way to think of is like this:

  1. Your semaphores divide the track into segments
  2. Only one train can be on a segment at a time
  3. The trains will stop at the semaphore and wait for the segment ahead of them to clear before proceeding

these rules mean that

a) You need at least n+1 segments of track for it to be possible for your trains to move (n is the number of trains)
b) Each "branch" of the shared line can only service a single train (since two trains trying to enter/exit a branch simultaneously will get stuck)

So for this setup, you need two semaphores to make it work

  • On the red rail, right before the junction, going in two directions
  • On the blue rail, right before the junction, going in two directions

This should split your track into three sections, which is enough if you have 2 trains. Assuming that only one train is traveling to the red branch, and only one train traveling to the blue branch, this setup should provide exactly the behavior you're after, where a train on the green section causes a train trying to enter it to wait.

That said, it's a LOT easier to make trains work seamlessly with dual parallel tracks (one going in each direction, using one-way semaphores to force the trains to use the correct side, and having junctions at the customs house to allow trains to start/end on any track). If cost is a concern, you can create what i'm going to call a "one and a half" track by adding a "passing lane" halfway between the customs house and your town, and using semaphores to make each side of the "passing lane" one-way (make sure the passing/waiting track section is at least as long as your longest train!).

[โ€“] BeanisBrain@hexbear.net 4 points 6 days ago* (last edited 6 days ago)

Thanks, that got it to work! The trains are running properly now.

That said, it's a LOT easier to make trains work seamlessly with dual parallel tracks (one going in each direction, using one-way semaphores to force the trains to use the correct side, and having junctions at the customs house to allow trains to start/end on any track). If cost is a concern, you can create what i'm going to call a "one and a half" track by adding a "passing lane" halfway between the customs house and your town, and using semaphores to make each side of the "passing lane" one-way (make sure the passing/waiting track section is at least as long as your longest train!).

I'll give it a shot, thanks for the suggestion. I feel like I'm slowly getting the hang of semaphores so I might be able to make this work.