Writing IF

Picking a language

One of the first decisions you’ll need to make before you do serious work on your own piece of interactive fiction is what tools you will use to create it. While you could program IF in a general purpose programming language, most people choose to use a language or design system specially created for writing IF. This reduces the amount of work involved, and it usually produces a more polished, more widely-portable product, as well.

Even so, there are quite a few different options, from simple graphical interfaces that allow you to choose functionality from menus to sophisticated and powerful programming languages. A good place to look in order to compare systems is the “Cloak of Darkness” page. This page shows source code for the same short scenario, implemented in many different IF languages. This is a wonderful way to get a feel for how code compares in practice.

Your choice may also be affected by the format you want your work to take. Some IF systems are better than others at running on small platforms such as handheld devices. Some are better at providing multimedia extras like graphics, sound effects, and hyperlinks. If you plan to develop for an unusual system or in an unusual format, be sure to consider that also when you select a coding language.

My own interactive fiction has been written in Inform 6 and Inform 7. Despite the sequential version numbers, Inform 7 is considerably different from Inform 6: it is designed to be friendly to new authors, but is also tremendously flexible and powerful. (Disclaimer: I have been involved in the development of Inform 7, so I am naturally biased. Please do take a serious look at the different systems out there and decide which one best suits your skills and objectives. I have also collaborated on a work in TADS 3, another popular and very powerful system. Those deciding between Inform 7 and TADS 3 may be especially interested in Brass Lantern’s comparative article by Eric Eve, who has experience writing substantial games in each language.)

Studying design

Another thing you may want to do before beginning your own game is to familiarize yourself with the field. Play IF; read reviews of IF. (The reviews section of this site contains a number of links to IF review sites and recommendation lists.) You’ll find that there are some generally accepted bits of wisdom about how to create a smooth game. You may not decide to follow the generally accepted wisdom, of course — it’s your game, and you’re the boss. But studying other games and reading reviews can make you more aware of flaws that can appear in IF works, and how to avoid them.

Studying code style

You may also find it useful to look at some source code for games that do things you find interesting — or just games written in your target language, to give you a feel for how other authors handle common issues. A search for “source code” on IFDB turns up quite a number of games with provided source in many common IF and all-purpose languages.

Creation process

Depending on the kind of IF you want to write, planning might come in a variety of forms — notes about plot and character, a diagram of possible puzzle progress, a map of rooms. And naturally the process of writing the work will be heavily determined by the kind of language you choose to write in.

A number of “Making of IF” articles can be found on ifwiki, describing challenges that other authors have faced and how they resolved them.

Polishing your work

You should expect to spend some time beta-testing your IF after it is written: that is, having some people other than yourself play the game and alert you to problems. They may find outright errors of coding and bugs; they may find places where the game logic is not clear enough; they may find typos and writing problems. All of these things are good to have checked by someone else. Generally speaking, it is a good idea to have at least two people look at your game, and sometimes quite a few more, depending on how large the work is and how complicated it is.

It is also usually a good idea to make sure that you’ve got someone on your beta-testing team who represents what you think of as your target audience. If you’re writing IF that you hope will interest seasoned players of traditional IF, you may want to look for a tester or two from the community. If you’re writing for novice players, you might want to share your work with someone who has never played IF before. (That’s not to say you can’t mix and match the skill levels of your beta-testers, of course.)

A time-honored tradition is to rope in helpless friends, roommates, and family members to look at your IF, but you may also recruit by posting requests for beta-testers on the intfiction forum, or by asking around on ifMUD.

Publishing

A very common way to distribute interactive fiction is to upload the file to the Interactive Fiction Archive. You may also want to create an entry for it at IFDB, where you will be able to upload cover art, create a description, and give players a link to the game file and any peripheral websites you might have made. This will let players know your game exists. (You can do this even if you’re hosting your game on your own site rather than uploading it to the archive.) Once a game is listed in IFDB, players will be able to add their reviews and rankings, and add the game to their recommendation lists. (Even if you don’t create an IFDB entry, it is likely that sooner or later someone else will, assuming you announce your game to the community at all. IFDB aims to have a record for every work of IF, commercial or freeware, even those which are no longer readily accessible to play. But you can jump-start the process and increase awareness of your work by making the entry yourself.)

Another publishing approach is to enter your work into a competition, in which case there may be special rules about how and when your work may be released (but, on the other hand, it may receive more immediate attention than a game released on its own).

Publishing interactive fiction commercially is difficult and requires a substantial extra commitment of time and energy, as well as a plan for marketing and outreach. Nonetheless, there are a few hardy souls who have done so, to modest profits.