kids encyclopedia robot

Inform facts for kids

Kids Encyclopedia Facts
Quick facts for kids
Inform
Inform 7 IDE Icon.png
Original author(s) Graham Nelson
Developer(s) Graham Nelson
Stable release
10.1.1 / August 21, 2022 (2022-08-21)
Operating system Microsoft Windows, Mac OS X, Linux, others
Type Interactive fiction development and play
License Artistic 2.0

Inform is a special programming language and system. It helps people create interactive fiction games. These are like "choose your own adventure" stories, but on a computer. You type commands, and the game tells you what happens next.

A person named Graham Nelson first made Inform in 1993. Inform helps turn your game ideas into files that computers can play. These files work on special computer programs called virtual machines. Inform has changed a lot over time. The first versions came out between 1993 and 1996.

Around 1996, Graham Nelson made a new version called Inform 6. This version became very popular for writing interactive fiction. In 2006, he released Inform 7. This was a completely new language. It lets you write game rules using everyday English words, almost like writing a story!

Play Games Anywhere: Z-Machine and Glulx

Inform helps turn your game code into "story files." These files are made for two special virtual machines: Glulx or Z-code. Think of a virtual machine as a pretend computer inside your real computer. It lets games run on many different devices.

Glulx is usually the default choice. It can handle bigger and more complex games.

The Z-machine was first made in 1979 by a company called Infocom. They used it for their own interactive fiction games. Because Z-machine games can run on almost any computer, your game can be played by many people. Inform first only made games for the Z-machine.

Later, a person named Andrew Plotkin made a new virtual machine called Glulx. He designed Glulx to fix some old limits of the Z-machine. He also helped Inform 6 work with Glulx. Now, both Inform 6 and Inform 7 can create games for both Z-machine and Glulx.

Inform 6: The Classic Game Maker

Inform 1–6
Paradigm object-oriented, procedural
Designed by Graham Nelson
Developer Graham Nelson
First appeared 1993
Stable release
6.32 / 2010
Preview release
6.33 / May 10, 2014 (2014-05-10)
OS Microsoft Windows, Mac OS X, Linux, others
License Freeware and Artistic License 2.0
Influenced by
Z-machine, C
Influenced
Inform 7

Inform 6 was a big step forward for interactive fiction. It became a very popular tool for game creators.

The Inform 6 system has two main parts. First, there's the Inform compiler. This tool takes your game's code and turns it into a playable story file. Second, there's the Inform library. This is a collection of ready-made software. It helps with tricky parts of game making. For example, it understands what players type and keeps track of things in the game world. The name Inform also refers to the Inform programming language itself.

Even though Inform 6 was made for interactive fiction, people used it for other things too. They made a simple BASIC interpreter and even a Tetris game!

How Inform 6 Works

The Inform 6 programming language uses "objects." In a game, an object can be anything. It could be a room, a character, or an item like a key. These objects are connected in a special way, like a family tree. For example, a "living room" object might "hold" a "salesman" object. The salesman might then "hold" a "briefcase" object. And the briefcase could "hold" "paperwork." This helps the game know where everything is.

Objects can also have "attributes." These are like special tags. For example, an object might be tagged as `scenery` (something you can't pick up) or `edible` (something you can eat). These tags help the game understand how players can interact with objects.

Here is a very simple example of Inform 6 code. It just makes the game say "Hello, World!"

! Square brackets define a routine. This is the Main routine, which takes no arguments.
[ Main;
    print "Hello, World!^";
];

The Inform 6 library is super helpful. It handles almost all the hard work in making an interactive fiction game. It has a "parser" that understands what the player types. So, if you type "take key," the parser figures out you want to pick up the key. The library also keeps track of all the objects, rooms, and other things in your game world.

Example Inform 6 Game Code

Here is a longer example of Inform 6 code. It uses the Inform library to create a small game scene.

Constant Story "Hello Deductible";
Constant Headline "^An Interactive Example^";

Include "Parser";
Include "VerbLib";

[ Initialise;
    location = Living_Room;
    "Hello World";
];

Object Kitchen "Kitchen";
Object Front_Door "Front Door";

Object Living_Room "Living Room"
    with
        description "A comfortably furnished living room.",
        n_to Kitchen,
        s_to Front_Door,
    has light;

Object -> Salesman "insurance salesman"
    with
        name 'insurance' 'salesman' 'man',
        description "An insurance salesman in a tacky polyester
              suit.  He seems eager to speak to you.",
        before [;
            Listen:
                move Insurance_Paperwork to player;
                "The salesman bores you with a discussion
                 of life insurance policies.  From his
                 briefcase he pulls some paperwork which he
                 hands to you.";
        ],
    has animate;

Object -> -> Briefcase "briefcase"
    with
        name 'briefcase' 'case',
        description "A slightly worn, black briefcase.",
    has container;

Object -> -> -> Insurance_Paperwork "insurance paperwork"
    with
        name 'paperwork' 'papers' 'insurance' 'documents' 'forms',
        description "Page after page of small legalese.";

Include "Grammar";

Famous Games Made with Inform 6

Many popular interactive fiction games were made using Inform 6 or earlier versions:

  • Curses (1993), by Graham Nelson. This was the very first game made with Inform.
  • Zork: The Undiscovered Underground (1997). This game was given away for free to promote another Zork game.
  • Anchorhead (1998), by Michael S. Gentry. A highly-rated horror story.
  • Photopia (1998), by Adam Cadre. This game was special because it had almost no puzzles. It won a big award!
  • Varicella (1999), by Adam Cadre. This game won several awards, including "Best Game."
  • Galatea (2000), by Emily Short. This game focuses on talking to a statue. It has one of the most complex talking systems for a computer character.
  • Slouching Towards Bedlam (2003), by Star C. Foster and Daniel Ravipinto. This game mixes saving and loading into the story itself. It won awards and got a very high score in a competition.

Inform 7: Writing Games in English

Inform 7
Inform 7 IDE Icon.png
Paradigm natural-language, declarative, procedural
Designed by Graham Nelson
Developer Graham Nelson
First appeared 2006
Stable release
6M62 / December 24, 2015; 9 years ago (2015-12-24)
OS Microsoft Windows, Mac OS X, Linux, others
License Freeware (before 2022); Artistic License 2.0 (since 2022)
Website http://inform7.com/
Influenced by
Inform 6, Natural-language programming

Inform 7 was released in 2006. It's a very different way to make games. It lets you write game rules using sentences that sound like normal English.

Inform 7 has three main parts. First, the Inform 7 IDE. This is a special program with tools to help you make and test your game. Second, the Inform 7 compiler. This takes your English-like code and turns it into something the computer understands. Third, "The Standard Rules." This is a core set of rules that every Inform 7 game uses.

Inform 7 also uses parts of Inform 6. The Inform 7 compiler first turns your code into Inform 6 code. Then, the Inform 6 compiler turns that into a playable story file. Inform 7 can also create "Blorb" files. These files include the game along with things like cover art. Inform 7 tools work on Mac OS X, Microsoft Windows, and Linux computers.

As of 2023, Inform 7 is still being worked on. Since April 2022, it is "open source." This means anyone can look at and help improve its code.

Inform 7's Special Tools (IDE)

Inform 7 code and skein
The Inform 7 IDE on Mac OS X showing source code and the skein
Inform 7 map and transcript
The Inform 7 IDE on Mac OS X showing the Index Map and the transcript

Inform 7 comes with a special program called an IDE. This program helps you write and test your game. It has a text editor where you type your code. The editor uses different colors for different parts of your code. This makes it easier to read. For example, comments are smaller and in a different color.

The IDE also has a built-in game player. As you test your game, the IDE keeps track of your progress. It has a "skein" view. This shows your commands like a branching tree. You can quickly go back to any point in the game and try a different path. This is great for testing! You can also add notes to your paths.

There's also a "transcript" view. This records everything you type and everything the game says. You can mark correct game responses as "blessed." If you play the game again, the IDE will show you if anything changes. This helps you find mistakes.

The IDE also helps you see how your game is organized. It can show your code as a map or a table of contents. If you click on something in the map, it takes you right to that part of your code.

The IDE has two side-by-side screens. You can put your code on one side and your game or notes on the other. It's designed to feel like you're working with a book.

Inform 7 Programming Language

Inform 7 is special because you write rules using normal sentences. For example, if you write "John wears a hat," Inform 7 understands many things. It knows "John" is a person. It knows a "hat" is something that can be worn. And it sets John as wearing the hat. It figures out these details from your sentences.

Another cool thing is that Inform 7 helps you track connections between things. It already knows about things like one object being inside another. But you can also add your own connections. You could track which characters in your game like each other. Or which characters have met before.

Inform 7 is made just for writing interactive fiction. It lets you describe your game world in a very clear way. This makes the code easy to read, almost like a story.

Example Inform 7 Game Code

In Inform 7, your code looks like full sentences. Blank lines and how you indent your text are important. Here's a very simple Inform 7 program:

"Hello, World!" by "I.F. Author"

The world is a room.

When play begins, say "Hello, World!"

Here is the "Hello Deductible" example rewritten in Inform 7. See how it uses more natural language?

"Hello Deductible" by "I.F. Author"

The story headline is "An Interactive Example".

The Living Room is a room. "A comfortably furnished living room."
The Kitchen is north of the Living Room.
The Front Door is south of the Living Room.
The Front Door is a door. The Front Door is closed and locked.

The insurance salesman is a man in the Living Room. The description is "An insurance salesman in a tacky polyester suit. He seems eager to speak to you." Understand "man" as the insurance salesman.

A briefcase is carried by the insurance salesman. The description is "A slightly worn, black briefcase."  Understand "case" as the briefcase.

The insurance paperwork is in the briefcase. The description is "Page after page of small legalese." Understand "papers" or "documents" or "forms" as the paperwork.

Instead of listening to the insurance salesman: 
        say "The salesman bores you with a discussion of life insurance policies. From his briefcase he pulls some paperwork which he hands to you.";
        move the insurance paperwork to the player.

Famous Games Made with Inform 7

  • Mystery House Possessed (2005), by Emily Short. This was the first Inform 7 game released to the public.
  • Bronze and Damnatio Memoriae (2006), also by Emily Short.
  • The Reliques of Tolti-Aph (2006), by Graham Nelson.
  • Floatpoint (2006), by Emily Short. This game won first place in a big competition. It also won awards for its setting and characters.
  • Rendition (2007), by nespresso. This game was a political art experiment.

See also

kids search engine
Inform Facts for Kids. Kiddle Encyclopedia.