The obligatory hello world program in inform:

[ Main;
  print "Hello, world!^";

Inform is a rather old programming language, but curiously enough it shares some of the attributes of many languages which (at the time of this writeup) are currently popular.

Inform is Object-Oriented

But not in the same way that languages like smalltalk, C++, or Java are. Inform does indeed have classes and the potential for inheritance and even multiple inheritance, but the more common way to use objects in inform is to define them inline. A simple object declaration looks like this:

Object old_book "old book"
    id 23,
    price 5,
    name "old" "book",
    description "A musty old book",
    [ appreciate;
      self.price = self.price + 1;

Inform is procedural

As opposed to rule-based (like prolog) or functional (like lisp or scheme), inform has functions and local variables. It is a common misconception that procedural and object-oriented are mutually exclusive. Java and C++ are both object-oriented and procedural. Here is as simple recursive function for computing factorials. Unfortunately, since inform numbers are only 16 bits, this code will only work for n from 0-7.

[ Factorial n;
  if (n == 1 or 0) return 1;
  return n * Factorial(n - 1);

Inform is byte-compiled

Like Java and C#, inform is compiled to an intermediate format that is subsequently interpreted. Inform compilers generate Z-machine files. Inform compilers and Z-machine interpreters exist for many different platforms. As a result, inform is very portable.

My highly subjective opinion of inform

Having only completed one game using inform, I can hardly call myself a master, but I think I got a pretty good feel for the language. My strongest impression of the language is that is is odd.

Inform itself is general enough for most purposes (except for the 16 bit number size, and lack of a floating point type), but it was designed for making interactive fiction. As a result, the standard libraries are completely tailored to this task, and inform really isn't good for anything else. In one respect, this is good, since it simplifies the task of creating game objects and greatly simplifies the herculean task of natural language parsing. However, in many ways inform is counter-intuitive and sometimes downright limiting.

The language is very terse, and the syntax does not closely resemble any other popular language (that I know of). For such a specific language, it is very complex. The manual (which you must read if you want to do anything of consequence in inform) is over 15,000 lines long. I guess my biggest complaint about inform is that it sometimes just seems to be inconsistent. From time to time, it's necessary to call a seemingly random library function just to enable a common feature (pushing a object from one room to another, for instance).

I find myself really split about inform. On one hand, I'd hate to write text adventures without it, and on the other, It can really be a pain to use. I guess this is probably why I don't plan to write any more adventure-like games in the future, but that's not to say that I regret writing the one that I did.

My Inform Game

As I previously mentioned, I completed only one game in inform. It was for Professor John Laird's EECS 494: Computer Game Development. I based my game on characters and plot points from Monty Python and the Holy Grail. However, in my game, you play the part of a lowly squire rather than a heroic knight. I called the game Squire, and if you're interested, you can find it here:

The Inform Designer's Manual Third edition by Graham Nelson was consulted in the creation of this writeup