Thursday, September 6, 2007

Desert adventure: A new tiny interactive fiction story

I spent all day yesterday making an interactive fiction story called Desert adventure. This is classic late-1970s early-1980s adventure: Our adventurer is all alone in a desert near an oasis, and has to find the treasures.

This is an original adventure for the Scott Adams' adventure interpreter language, and is, to the extent of my knowledge, the first original adventure for Scott's language in over 20 years.

While Inform, Adrift, and what not are more capable than Scott's language at making complicated adventures, Scott's system has the advantage of being extremely compact, being originally designed to run on a system with only 16 or 24 kilobytes (yes, kilobytes) of memory. For example, my implementation of Cloak of Darkness for Scott's system is under 3,000 bytes in size. Compare this to the Z-machine version of the same game, which is over 50,000 bytes in size.

The program to run Scott Adams' adventures is under 20k in size; the Z machine interpreter is about 80k in size, and other interpreters are even bigger.

My goal in making this adventure was to make a playable, very small adventure that people can freely include with programs like ScottFree.

In particular, I wanted the adventure to fit in under 6 2048-byte blocks (12288 bytes), which it barely does.

To play this game, play it online or download it here (80k zip file). This zipfile includes a Windows program for running Scott Adams adventures, a version of ScottFree for *NIX (including MacOS X in a terminal) updated to not have bugs when compiled in a modern version of GCC, and a z-machine version for people who don't feel comfortable compiling ScottFree.

- Sam

Update: 2007/09/10: Updated version to 1.1 and added note there is now a z-machine version of Desert Adventure. 2007/09/11: Added online version