One of the things I find useful in developing a very plot-oriented piece of IF is to leverage the scenes mechanism as much as possible, designing as follows. I’m not sure this really qualifies as advice so much as some personal experience that may or may not suit others’ writing styles — people tend to approach IF design in different ways. Still, FWIW:
— Start by listing all the scenes I expect to feature in the game. If the game is too branching for a straight list, then make a flowchart instead — but know from the beginning what I think all the elements are going to be. The scene list will change and will be revised, but having something to shoot for makes it easier to motivate myself, track progress, and avoid that moment where I realize I don’t really know how to do the next bit. Besides, if there’s some part of the game plot that is a little fuzzy in my mind, that often means that there’s a problem with it that I just haven’t faced squarely yet. It’s better to deal with that at the beginning than to try to patch and compensate later.
— Create a heading for each scene; that way, viewing the contents pane will give an overview of the plot of the game, too. In comments, write up a short description of what I expect each scene to do. (Does the player have to accomplish something? Learn something? Observe a series of events? Make a choice?)
— In a separate portion of the code (usually at the beginning of the program), make headings for the settings the game has to use. The idea here is that the game is being designed like a staged play: the action may move on and off the sets at different times. I may not actually create all the settings at once.
— As I go along, write each scene to contain complete set-up and take-down information in the “when (the scene) begins…” and “when (the scene) ends…” rules. At the beginning of a scene, I move in everything that the scene needs — any prop objects, any characters that need to be in that scene. At the end of a scene, I take it all away again. I don’t expect elements of a set to stay from the previous scene. I have one phrase that moves all the non-permanent objects out of play, and I call it whenever I need to strip the sets.
This might sound a little laborious, but it helps protect against bugs if, later on, I decide to change the sequence of scenes or add a plot branch.
— Create the sets the first time each one is needed, but be mindful also of the later scenes where the same set is going to need to be used. I don’t write them all in a big clump in advance for a couple of reasons: I get bored if I spend too many hours working just on scenery with no action. Besides, the elements that need to be on the stage are often obvious only when I’ve started the scene (a vase for the NPC to smash, a fireplace for the player to burn a letter, etc). At the same time, remembering the later scenes that will use the same set helps me be sensible about writing descriptions (or remembering that the description of something may have to be conditional, to fit multiple points in the plot).
— To test sets and kick the tires properly, turn off all scenes (by making sure that the first one never starts — just comment out the ‘when play begins’ bit, if appropriate). Spend some time in the location and play around with things while there’s nothing distracting going on. Sometimes playtesting a set while a scene is going on means that objects on the set change or the scene ends before I’ve gotten a chance to give things a serious try.
— To work on scenes late in the game, and for testing purposes in general, again comment out the beginning of the first scene and instead have the game begin with the scene I’m interested in. (“Dramatic Climax begins when play begins.”)
— Develop a testing script to make sure that certain commands give sensible output in every single scene. That might include
LOOK — does the room description really fit this particular scene? Does it draw attention to the right things? Does it reflect the protagonist’s state of mind at this moment in the plot?
EXAMINE ME — does the character description sound right for what is going on right now?
WAIT, LISTEN, etc., and perhaps other commands that ought to be very reactive to change in the plot sequence, depending on
Go systematically through every scene in the game and run the test script. Revise any output that is unsatisfactory.
One of my remaining frustrations is that it’s not currently possible to write rules such as
When a movie-like scene begins: …
because the rulebooks for scene beginnings and endings are created specially for each scene; they don’t take variables. That’s something Graham and I have discussed a number of times, and there are some technical reasons (which may or may not prove binding) why it hasn’t changed yet. We’ll see what happens there.