Inform 7 Home Page / Documentation


§17.8. Understanding names

So far in this chapter, Understand sentences have been used to give names to actions, but they can also be used to name objects - in particular, things and rooms.

This normally happens automatically. For instance, writing

The St Bernard is an animal in the Monastery Cages.

makes ST BERNARD refer to the dog, and MONASTERY CAGES refer to the room. But sometimes, as here, that isn't really enough. Why shouldn't the player type EXAMINE DOG? One way to allow this is to write:

Understand "dog" as the St Bernard.

Matters become more complicated when the player wants to refer to more than one object at once. When a kind is created, and the source text constructs multiple duplicate items of that kind, Inform generates a plural of the kind's name in order to understand commands referring to these multiples. For instance, given...

The Lake is a room. A duck is a kind of animal. Four ducks are in
    the Lake.

...the player can type TAKE DUCKS to try to pick up all four.

Once again the automatic behaviour can be enhanced:

Understand "birds" and "ruddy ducks" as the plural of duck.

Now TAKE BIRDS and TAKE DUCKS are equivalent. Plurals can even, strange as it may seem, be given for single things:

The magpie is in the Lake. Understand "birds" as the plural of the magpie.

And now TAKE BIRDS tries to take all four ducks and the magpie too.


arrow-up.png Start of Chapter 17: Understanding
arrow-left.png Back to §17.7. Understanding any, understanding rooms
arrow-right.png Onward to §17.9. Understanding kinds of value