To schedule or not to schedule: managing a closed circuit train

Hi all,

I am working on an IF in which I have several areas I want to connect with a closed circuit (basically a train looping around the entire scene). I can find code examples for Inform to make it work with relative/absolute scheduling, but I am wondering: is this the best approach? What if we want a player to move around without “waiting” until the next scheduled train arrives? I.e. simulate the train arriving just as the player enters the station? Since the game is not multiplayer? What would be a preferred approach?

Kind Regards,



If the train is always going to be arriving just as we need it and will always be ready to go, isn’t that just a glorified door or, maybe an elevator would be a more appropriate comparison?

Enter train, select destination, display flavor text, player arrives in a new area (or room as far as I7 cares).

Enter elevator, select destination, display flavor text, player arrives on a new floor (or room as far as I7 cares).

Please correct me if I’m wrong.

As far as not being necessary, sure. I think the intermittent availability of the train is meant for immersion and simulation, not because it aids the actual gameplay. If the schedule negatively impacts your game, ditch it. It’s your game, right?


I can agree with Pinkunz above. You can add some flavor text that your player character is waiting for a train, and then you’ll board it.

Unless you want to use the train schedule itself as a game mechanic (such as having things happen if you board the train at 12:14am or something), in which you can have the player character get to the station, have flavor text when it waits, and have something happen. The train schedule may be immersive, but think about how it aids gameplay (as said above again). If you make a schedule, players may think certain actions/events/etc come from boarding the train at certain times or waiting in a particular way. It’s sort of the regular game design idea that “everything should be there for a purpose.”

I hope that makes sense!


I’d rather not wait around for a train as a player. Coding-wise, it’s much easier, too. I suppose you could have the train still go on a loop from A-> B → C → D → A and so the player might need to wait a turn or 2 to get where they’re going, or you could give the player a menu when they board: Do you want to get off the train at A, B, C, or D?

I suppose it depends on whether or not you want to code the train as an actual place where things happen, or not.

1 Like

Whoa thanks for the feedback all, it gives me something to ponder. I do want to avoid people getting the wrong idea (oh if the train follows a fixed schedule, maybe I need to catch a specific train), but if I do not put up any train schedule I would expect people not to worry about it. In my current design the train basically uses relative scheduling, but I was not sure how to handle the ‘you just missed the train, an all too common occurrence IRL’, and spamming waits until the train loops around did not sound like a good idea. The train is part of the problem (or solution, depending on how one looks at things), I guess I will need to invite some friendly people over to have a look if things work out (I am still trying to work things out and get them to properly work with Inform7). Maybe I can make a single ‘wait’ skip until the train arrives? I can imagine that’s basically what ‘wait’ at a station location would imply :p.

Cheers and thanks for all the feedback!

1 Like

Another reason to do the “train actually moves from place to place between turns” version would be to modify the pacing of a scene, for one reason or another. Maybe there’s an NPC on the train who will deliver exposition over the course of the four turns it takes to get from A to D, and the player is already used to how the train system works so they’re willing to type “wait” a few times. Or perhaps you can do something disruptive at the moment you know the train leaves from A, which means you have quite a while to cover your tracks before the detective at A can get to you.

On a technical level, I recommend Hidden Prompt by Daniel Stelzer, which lets you “hide the command prompt”: when you do this, the prompt changes from “>” to “]”, and pressing enter without typing anything will be interpreted as “wait” (or another command of your choosing). Pressing any other key will make the “>” prompt reappear. I created it specifically for situations like this, where you might want to just keep waiting until something happens, or might want to take another action if something dramatic pops up.

It currently only works for 9.3 and earlier, because it depends on Command Preloading which depends on I6 inclusions which I haven’t updated yet. But I’m putting it at the top of my list of extensions to update.


Just to echo the others, I think it depends on what you’re looking to do – a train ride can provide a pacing element, and an introduction to a new environment a la Half Life. But if it’s all simulated, that could get boring if there’s a lot of back and forth the player needs to do. Personally, I might require the player to do things manually one time, then unlock a fast travel command. It sounds like you’ve got the train-simulation piece cover, but here’s a cut at what the fast-travel option could look like:

A railstation is a kind of room.

Union Station Lobby is a room.  Union Station Platform is a railstation.  Union Station Platform is north of Union Station lobby.  Penn Station Platform is a railstation.  North Station Platform is a railstation.

Railgoing is an action applying to one thing.  Understand "take train to [any railstation]" as railgoing.

Check railgoing:
	If the location is not a railstation, say "You can't catch the train here!" instead;
	If the location is the noun, say "You're already at [noun]!" instead.
Carry out railgoing:
	Say "After a [one of]short[or]long[or]tedious[at random] wait, you get on the train to [noun].  You pass the time by [one of]napping[or]reading[or]chatting to other passengers[at random], and then debark at your destination.";
	Move the player to noun.

You could flesh this out to only allow fast travel to visited stations, and you might also want to also have the railgoing action adjust the world clock and location of the simulated train for consistency, but hopefully this is helpful!