?

Log in

   Journal    Friends    Archive    Profile    Memories
 

Anchorhead: the first five rooms - Informalize

mikegentryMay. 17th, 2006 11:04 am Anchorhead: the first five rooms

I've been quiet around here lately; I was on vacation for a week and busy working on my project the rest of the time. I've just finished a milestone, however: the first five rooms of Anchorhead, fully implemented.

I'm posting the full source code here for anyone interested. There's some interesting stuff in there -- a simple system for generating and disposing of quantities of various kinds of water, several new verbs, even a small hack into Inform 6. Please feel free to peruse it, compile and play it -- certainly tell me if you see any bugs.

My impressions of Inform 7 after putting this together have only improved. There is a learning curve, especially if you're used to doing things in I6, and there is some merit to the complaints that the natural language syntax is more structured than it invites you to think it is, but both of these are hurdles quickly overcome with practice. Once I got the basic ideas down, I found coding in I7 to be far more straightforward than I6. My favorite feature by far is the ability to track actions and states by referring them to the past tense. Where before I would have to set up a procedure to flag an arbitrary variable, and then set up a procedure in some entirely different place to check that variable, now I can just ask, "Have we pushed this button before? No? Then do this." It's a great example of how much better I7 is for directly and succinctly talking about the state of the game-world.

--------------------

"Anchorhead" by Michael Gentry.

The story headline is "the Director's Cut". The story genre is "Horror". The release number is 1. The story creation year is 2006.

The story description is "You take a deep breath of salty air as the first raindrops begin to spatter the pavement, and the swollen, slate-colored clouds that blanket the sky mutter ominous portents amongst themselves over the little coastal town of Anchorhead.

Squinting up into the storm, you wonder how everything managed to happen so fast. Here you are, over a thousand miles from home, getting ready to move into the ancestral mansion of a clan of relatives so far removed that not even Michael has ever heard of them. And you've only been married since June and none of this was any of your idea in the first place, and already it's starting to rain.

Anchorhead is an interactive tale of Lovecraftian Horror. It contains adult themes and written depictions of graphic violence."

Use American dialect, the serial comma, no scoring, full-length room descriptions, and sequential action.

Include Basic Screen Effects by Emily Short, Plurality by Emily Short, and Locksmith by Emily Short.



Volume - The World

Book - Metaphysics

Part - Kinds

Chapter - Modifications of Basic Kinds

A container can be leaky or waterproof. A container is usually leaky.

A door can be passed through. A door is usually not passed through.

After going through a door (called the portal): change the portal to passed through; continue the action.

Before listing nondescript items: repeat with item running through closed doors in the room begin; change item to unmarked for listing; end repeat.

Rule for writing a paragraph about doors (called portal): if the portal is open, say "The [printed name] is standing open."

Chapter - New Kinds

A key is a kind of thing.

A thing can be providing liquid. A thing is usually not providing liquid.

A liquid is a kind of thing. Instead of taking or dropping a liquid when the noun is in a container (called the vessel), perform the current action on the vessel. Instead of touching a liquid, say "You dip your fingertips in [the noun]." Instead of eating a liquid, try drinking the noun.

Liquid Storage Limbo is a room. "This is where we keep discrete quantities of liquid before they enter play."


Part - Rules



Book - Environment

Part - Regions

The Outdoors is a region.

The City Streets is a region in the Outdoors.

The Real Estate Area is a region. Instead of listening to the location when the location is in the Real Estate Area, follow the buzzing fly rule.

Part - Backdrops

Chapter - The Ground

The ground is a backdrop. The ground is everywhere. The ground is scenery.
Rule for printing the name of the ground:
    if the location is in the Outdoors, say "ground";
    otherwise say "floor".

Instead of putting something on the ground, try dropping the noun.
Instead of entering the ground while the player is in a container or the player is in a supporter, try exiting.
Instead of entering the ground, say "You're on it already."
Instead of getting off the ground, say "There's nowhere else to stand."

Chapter - The Rain

The rain is a backdrop in the Outdoors. "It's coming down in uneven spatters, broken by intermittent gusts. There are days when you enjoy such weather, but this has to be the most thoroughly depressing rain you've ever experienced in your life." Understand "raindrops", "raindrop", "downpour" or "drizzle" as the rain.

Instead of drinking or tasting the rain, say "You catch a few drops on your tongue, and make a face. It tastes dirty, unwholesome."

Instead of touching or taking the rain, say "You hold your hand out, to feel the cold drops strike your upturned palm."

The rain is providing liquid.

Dampness is a number that varies. When play begins, change the dampness to zero.

Definition: a player-character is exposed if rain is in the location and (the umbrella is not carried by the player or the umbrella is not open).

The getting wet rule is listed in the every turn rules. This is the getting wet rule:
    if the player is exposed and soaked is not noticeable begin;
        change the dampness to dampness plus 1;
        if the dampness > 6 begin;
            now soaked is noticeable;
            say "You are now, sadly, entirely soaked.";
        otherwise;
            say "You are getting wet.";
        end if;
    end if.

The rain description rule is listed in the every turn rules. This is the rain description rule:
    if rain is in the location and a random chance of 1 in 10 succeeds begin;
        choose a random row in the Table of Rain Effects;
        say "[Effect entry][paragraph break]";
    end if.

Table of Rain Effects
Effect
"The rain slackens off momentarily to a weak drizzle, then returns afresh in a brief, freezing downpour."
"The clouds overhead mutter restlessly to themselves."
"Overhead, the swollen clouds flicker ominously with a greenish haze of sheet lightning."
"A sudden gust of wind blows a cold spray of rain into your face."

The rainwater is a kind of liquid. It has the description "Even though it's only water, it still somehow looks gray and dank." It has the indefinite article "some". Understand "rain water", "water", or "liquid" as rainwater. Three rainwaters are in Liquid Storage Limbo. Instead of tasting rainwater, say "It tastes bitter, but otherwise has no ill effects." Instead of drinking rainwater: say "You drink it down. It tastes bitter, but otherwise has no ill effects."; move the noun to Liquid Storage Limbo.

Instead of inserting rain into a waterproof container (called the vessel):
    say "You collect a small amount of rainwater in [the vessel].";
    move a random rainwater in Liquid Storage Limbo to the vessel.

Chapter - The Sky

The sky is a backdrop in the Outdoors. "The sky is an unbroken blanket of seething gray clouds in every direction." Instead of doing something other than listening to or examining with the sky, say "How optimistic of you."

Chapter - The Sea

The sea is a backdrop. It is in the Narrow Beach. It has the description "The sea is the color of old pewter, surging and chopping restlessly beneath the clouds." The sea is providing liquid. Understand "ocean", "water", "seawater", "wave", "waves", or "Atlantic" as the sea.

Instead of smelling the sea, say "The salty smell of all oceans, but beneath that there is a darker odor, a whiff of something corrupt and unclean."
Instead of smelling the location when the sea is in the location, say "You can smell the salty air of the sea."
Instead of tasting or drinking the sea, say "You've no wish to drink from these dismal waters."
Instead of listening to the sea, say "The rhythmic surging seems to call out to you hauntingly."
Instead of entering the sea, say "You would surely drown."
Instead of listening to the location when the sea is in the location, try listening to the sea.

Instead of throwing something at the sea, try inserting the noun into the sea.

Instead of inserting something into the sea:
    remove the noun from play;
    say "[The noun] hits the water with a splash, and in an instant it is lost beneath the waves."

Instead of pouring a liquid into the sea:
    move the noun to the Liquid Storage Limbo;
    say "You pour [the noun] into the sea, where it mingles with the larger water and is quickly lost."

The seawater is a kind of liquid. It has the description "It is greenish and murky, like the sea it came from." It has the indefinite article "some". Understand "sea water", "water", "salt water", "saltwater", or "liquid" as seawater. Three seawaters are in Liquid Storage Limbo. Instead of tasting seawater, say "It is salty and bitter." Instead of drinking seawater: say "Better not; the saltwater would make you sick." Instead of smelling seawater, say "It smells of the sea."

Instead of inserting the sea into a waterproof container (called the vessel):
    say "You collect a small amount of seawater in [the vessel].";
    move a random seawater in Liquid Storage Limbo to the vessel.

The tide rule is listed in the every turn rules. This is the tide rule:
    if the remainder after dividing the turn count by 10 is zero and the sea is in the location, say "Another wave crashes against the rocks, sending a cloud of spray into the air."

Chapter - The Buildings

Some buildings are a backdrop in the City Streets. "The crumbling buildings of Anchorhead, with their ubiquitous peaked rooftops and ancient, leaning gables, cluster thickly around you in every direction." Understand "building", "rooftop", "rooftops", "roof", "roofs", "gable", "gables", "leaning", "peaked", "town", "city", or "Anchorhead" as the buildings.

Instead of listening to the buildings, say "The buildings seem to confer with each other in muted creaks and groans, like old men sharing secrets."

Instead of entering, searching, or knocking on the buildings, say "All of the buildings seem to be closed and shuttered tight. Not a very trusting sort, these people."

Chapter - The Cobblestones

Some cobblestones are a backdrop in the City Streets. "The cobblestones are slick from the rain and worn with many
centuries' passage." Understand "cobblestone", "street", "cobble", or "cobbles" as the cobblestones.

Instead of putting something on the cobblestones, try dropping the noun.
Instead of entering the cobblestones while the player is in a container or the player is in a supporter, try exiting.
Instead of entering the cobblestones, say "You're on them already."
Instead of getting off the cobblestones, say "There's nowhere else to stand."

Chapter - The Train Whistle

[This is will eventually be its own object (i.e., the train), rather than just a rule.]

The train whistle rule is listed in the every turn rules. This is the train whistle rule:
    if the remainder after dividing the turn count by 50 is zero and the location is in the Outdoors, say "In the distance, you can hear the lonesome keening of a train whistle drifting on the wind."

Book - The Player

Part - Appearance

Instead of examining the player, say "You look good, considering[if the number of noticeable appearances is greater than zero] you're [list of noticeable appearances][end if]."

An appearance is a kind of thing. An appearance can be noticeable. Appearances are usually not noticeable.

Soaked is an appearance. It has the printed name "soaking wet".
Grimy is an appearance. It has the printed name "covered in grimy ash".
Filthy is an appearance. It has the printed name "filthy from splashing around in the sewers".
Oily is an appearance. It has the printed name "smeared with smelly fish oil".
Bloody is an appearance. It has the printed name "streaked with blood and gore".

Part - Knowledge

The player-character can be aware of Verlac or unaware of Verlac. The player is unaware of Verlac.

Part - Starting Inventory

The player is carrying an umbrella. The player is wearing some clothes, a trenchcoat, and a wedding ring.

Chapter - The Umbrella

The umbrella can be openable. The umbrella can be open or closed. The umbrella is openable and open. The umbrella has indefinite article "your". It has description "Olive green, with a hook-shaped handle. It's a handy little thing when it rains. It's currently [if open]open[otherwise]closed[end if]." Understand "my", "green", "olive green", "handle" as the umbrella. Understand the open property as referring to the umbrella.

Instead of opening the umbrella when the location is not in the Outdoors, say "You'd look silly carrying an open umbrella indoors."

Instead of inserting the umbrella into a container when the umbrella is open: say "(closing the umbrella first)"; silently try closing the umbrella; continue the action.

Instead of opening the umbrella when the player is not the holder of the umbrella: say "(taking the umbrella first)"; silently try taking the umbrella; continue the action.

After going when the location is not in the Outdoors and the player has the umbrella and the umbrella is open: silently try closing the umbrella; say "You close your umbrella, as is your habit when coming indoors."; continue the action.

After going when rain is in the location and rain was not visible and the player encloses the umbrella and the umbrella is closed: silently try opening the umbrella; if the umbrella is open, say "The rain is still coming down, so you open your umbrella."; continue the action.

Chapter - Your Clothes

The clothes can be dirty. The clothes have indefinite article "[if clothes in player]your[otherwise]a pile of[end if]". The clothes have description "A tasteful ensemble in muted browns and greens (you've been an autumn person since you were old enough to match your own socks)[if clothes are dirty]. They're somewhat worse for the wear, after what you've been through, unfortunately[end if]." Understand "my", "tasteful", "muted", "brown", "green", "ensemble", "clothing", "pants", "trousers", "shirt", or "blouse" as clothes. Understand "pile" or "pile of" as the clothes when the clothes are not in the player.

Instead of taking off clothes when the location is not Master Bedroom, say "This really isn't the place for it."

Instead of taking off clothes when the player is wearing the trenchcoat, say "You'll have to remove your trenchcoat first."

Instead of searching the clothes when the player is wearing the clothes, say "You're all there."

Chapter - Your Trenchcoat

The trenchcoat is a player's holdall. The trenchcoat is not openable. It has indefinite article "your". It has description "In addition to looking very cool, your coat has several deep pockets in which you can fit just about anything." Understand "my", "trench", "coat", "pocket" or "pockets" as the trenchcoat.

Instead of wearing the trenchcoat when the player is not wearing clothes, say "You really should put on your clothes first."

After inserting something into the trenchcoat, say "You slip [the noun] into the pocket of your trenchcoat."

After printing the name of the trenchcoat while listing nondescript items: omit contents in listing.

Chapter - Your Wedding Ring

The wedding ring has the description "Just looking at it still makes you feel sentimental. You feel naked without it on, but sometimes you take it off just to read the inscription on the inside." Understand "my", "gold" or "band" as the wedding ring.

The inscription is part of the wedding ring. It has description "Engraved in tiny letters along the inside of the ring are your and Michael's initials, and your wedding date -- June 28." Understand "date", "wedding date", "initials", "my", "Michael's initials" or "engraved" as inscription.

Instead of doing something to the inscription when the player is wearing the ring, say "You can't see the inscription unless you take off the ring."



Volume - The Game

Book - The City

Part - The Real Estate Office

Chapter - Outside

The Cul-de-sac is a room in the City Streets. "A grim little cul-de-sac, tucked away in one corner of the claustrophobic tangle of narrow, twisting avenues that make up the older portion of Anchorhead. Like most of the streets in this city, it is ancient, shadowy, and leads essentially nowhere. The lane ends here at the real estate agent's office, which lies to the east, and winds its way back toward the center of town to the west. A narrow, garbage-choked alley opens to the southeast." The player is in the Cul-de-sac.

Instead of going inside in the Cul-de-sac, try going east.

Instead of going west in the Cul-de-sac, say "That part of the game has not yet been implemented."

Instead of going nowhere from the Cul-de-sac, say "The street only goes west from here. You can also enter the office to the east or the alley to the southeast."

The glass-paneled door is a locked lockable door. It is east of the Cul-de-sac and west of the Office. It has the description "[if the location is the Cul-de-Sac]The door has a glass panel with the name of the real estate company, 'Benson & Brackhurst,' stenciled across it[otherwise]You can make out the words 'tsruhkcarB & nosneB' stenciled across the glass. There is a latch on this side which can be turned to lock or unlock the door[end if]."

After examining the glass-paneled door when the player is in the Cul-de-sac, say "The blinds are drawn, the lights are off inside, and no one appears to be home[if The First Day is happening]. Odd, since the real estate agent knew you were coming today[end if]."

Understand "real estate", "office", "glass panel", "glass-paneled", "paneled" or "glass" as the glass-paneled door. Understand the open property as referring to the glass-paneled door. Understand the locked property as referring to the glass-paneled door.

Instead of knocking on the glass-paneled door for the first time, say "You rap on the glass sharply, peering through it into the dark room inside. Nobody answers. Strange; you just talked to the real estate agent -- Ms Myers, you think it was -- yesterday. She was supposed to meet you here."

Instead of attacking the glass-paneled door, say "You're not here to vandalize the place."

Instead of searching the glass-paneled door when the glass-paneled door is open, say "The door is open."

Instead of searching the glass-paneled door, say "[if location is the Cul-de-sac]Cupping your hands around your eyes and peering in, you can make out dim shadows in an empty office[otherwise]You see the gray, dismal streets of Anchorhead outside[end if]."

Instead of unlocking keylessly or locking keylessly the glass-paneled door when the player is in the Office, try turning the latch.

The latch is part of the glass-paneled door. It has the description "It's a little knob that you turn to lock or unlock the door." Understand "knob" as the latch.

Instead of turning the latch when the glass-paneled door is open, say "You'll need to close the door first."

Instead of turning the latch:
    if the glass-paneled door is locked begin;
        say "You unlock the glass-paneled door.";
        change the glass-paneled door to unlocked;
    otherwise;
        say "You lock the glass-paneled door.";
        change the glass-paneled door to locked;
    end if.

Instead of doing something other than examining with the latch when the player is not in the Office, say "You can't get to the latch from this side."

Chapter - Inside

The Office is in the Real Estate Area. "Pallid gray light trickles in through the drawn blinds. The agent's desk is deserted, strewn with papers, a telephone and answering machine sitting silently on one corner. A glass-paneled door leads west to the street, and the file room lies east."

Some window blinds are here. "Drawn, and coated with dust." They are ambiguously plural and scenery. Understand "venetian", "blind", or "cord" as the blinds. Instead of pulling or opening the blinds, say "The cord seems to be jammed; the blinds won't open." Instead of searching the blinds, say "You see the dreary street outside."

The real estate agent's desk is here. The description of it is "The top of the desk is littered with paperwork. A telephone sits on one corner next to a digital answering machine. There is a small drawer to one side." The agent's desk is fixed in place and a supporter.

Section - The Desk

Instead of taking the agent's desk, say "That's hardly portable."

Instead of opening, closing, locking keylessly, or unlocking keylessly the agent's desk, perform the current action on the drawer.

Instead of locking the agent's desk with something, try locking the drawer with the second noun.
Instead of unlocking the agent's desk with something, try unlocking the drawer with the second noun.

After searching the agent's desk when the drawer is open: try searching the drawer; continue the action.

Before listing nondescript items of the Office, change the agent's desk to unmarked for listing.

Before listing contents of the agent's desk:
    change answering machine to unmarked for listing;
    change telephone to unmarked for listing;
    change paperwork to unmarked for listing;
    if the styrofoam cup is not handled, change the styrofoam cup to unmarked for listing.

Rule for writing a paragraph about the agent's desk:
    if the styrofoam cup is not handled, say "Someone has left a cup of coffee out, unfinished and cold."

The drawer is part of the agent's desk. It is an openable, closed, locked container. Understand "desk drawer" as the drawer.



Some paperwork is on the agent's desk. It is ambiguously plural. It has the printed name "papers". It has the description "Notes, messages, files -- the sorts of things most desks tend to accumulate over the course of a busy day. Nothing with any relevance to your predicament, however." Understand "paper", "papers", "note", "notes", "message", "messages", "files", or "file" as the paperwork. Instead of searching the paperwork, try examining the paperwork. Instead of taking the paperwork, say "None of this looks important enough to take."


The styrofoam cup is an open, waterproof container on the agent's desk.

Rule for printing the name of the styrofoam cup while listing contents:
    say "styrofoam cup[if a liquid is in the cup] filled with [list of things in the styrofoam cup][end if]";
    omit contents in listing.

Instead of inserting something into the styrofoam cup while the noun is not a liquid and the noun is not providing liquid, say "The cup is too small and flimsy to be a good container for anything other than small quantities of liquid."

The coffee is a liquid in the styrofoam cup. The indefinite article of the coffee is "some cold, murky". It has the description "Muddy-looking and unappetizing. Who knows how long it's been sitting out?" Instead of tasting or drinking the coffee, say "You take one sip and nearly gag. Awful stuff!" Instead of smelling the coffee, say "It smells nasty." Understand "cold" and "murky" as coffee.


The telephone is on the agent's desk. Understand "phone", "receiver", or "handset" as the telephone. Instead of calling while the telephone is visible, say "You start to dial out, but you can't get anything but a busy signal no matter how much you jiggle the receiver." Instead of taking or lifting the telephone, say "You start to dial out, but you can't get anything but a busy signal no matter how much you jiggle the receiver."

Section - The Answering Machine

The answering machine is on the agent's desk. It has the description "A simple digital answering machine, with a small display indicating messages received, a button labeled [bold type]PLAY[roman type], and a button labeled [bold type]DELETE[roman type]." Instead of taking the answering machine, say "You aren't here to burglarize the place." Instead of playing or listening to the answering machine, try pushing the play button. Understand "message" or "messages" as the answering machine.

The digital display is part of the answering machine. Instead of examining the digital display: if we have pushed the delete button, say "There are no messages."; otherwise say "The display indicates there is one message on the machine[if we have pushed the play button], which has been checked[end if]."  

The play button is part of the answering machine.

After pushing the play button:
    if we have pushed the delete button begin;
        say "The machine beeps and does nothing.";
    otherwise;
        say "For a while there is nothing but a quiet hiss, followed by intermittent skirls of static. It sounds like one of those annoying glitches where the caller hangs up but the machine keeps recording anyway. Then, barely audible through the static, you detect what sounds like a human voice whispering a single word:[paragraph break]";
        say "[italic type]'Verlac.'[roman type][line break]";
        say "The machine beeps.[line break]";
        if the player is unaware of Verlac begin;
            say "A brief shudder ripples up your back. You remember now, 'Verlac' is the name of this branch of Michael's family.";
            now the player is aware of Verlac;
        end if;
    end if;

The delete button is part of the answering machine. After pushing the delete button, say "The machine beeps."

Section - The Letter

The agent's letter is in the desk drawer. It has the description "It consists of several pages torn from a yellow legal pad, each page covered on both sides, top to bottom, with erratic, frightened handwriting. It is dated three days ago -- the day you arrived in Anchorhead."

Section - The Filing Cabinet

The File Room is east of the Office. "Peering through the murk, you can make out the blocky outlines of filing cabinets lining the walls and a doorway to the west. A window high up on the south wall lets in a very faint illumination." The File Room is in the Real Estate Area.

Instead of going outside when in the File Room, try going south.

Some filing cabinets are in the File Room. "Ordinary filing cabinets, sorted alphabetically." They are scenery. Understand "files", "file", "cabinet", "drawer", or "drawers" as the filing cabinets.

Instead of opening the filing cabinets, try searching the filing cabinets.

Instead of consulting the filing cabinets about something: if the topic understood includes "Verlac", change the player to aware of Verlac; follow the file searching rule.

Instead of searching the cabinets for the first time: if the player is unaware of Verlac, say "You search in vain for some mention of your husband's name. It dawns on you that the property is most likely listed under the family's original, ancestral name. Which, you realize with some embarassment, you have completely forgotten."; otherwise follow the file searching rule.

Instead of searching the cabinets, follow the file searching rule.

This is the file searching rule:
    if the keyring is not discovered and the player is aware of Verlac begin;
        say "Strange; the file on the Verlac property is cleaned out. Title, deed, all the papers, all of it gone. In the back of the drawer, however, is a set of keys that must have slipped out of the hanging folder. You quickly pocket them.";
        move the keyring to the player;
        change the keyring to discovered;
    otherwise;
        say "The only file that would be of interest to you is the one on the [if the player is aware of Verlac]Verlac [end if]house, [if the keyring is discovered]and that's been cleaned out[otherwise]and that's the one file you can't find[end if].";
    end if.



Section - The Keyring

The keyring is a portable supporter. It can be discovered. It is not discovered. Instead of examining the keyring, try searching the keyring. Understand "keys" as the keyring.

Before putting something on the keyring: ignore the can't put onto something being carried rule; if the noun is not a key, instead say "The keyring can only hold keys."

Rule for printing the name of the keyring while listing contents of something:
    if the number of keys on the keyring is zero, say "empty keyring"; otherwise say "keyring with";
    if the number of keys on the keyring is one, say " one key on it";
    if the number of keys on the keyring is two, say " a couple of keys on it";
    if the number of keys on the keyring is at least three and the number of keys is at most five, say " several keys on it";
    if the number of keys on the keyring is at least six, say " a great big jangling pile of keys on it".

After printing the name of the keyring, omit contents in listing.

A key called the key to the house is on the keyring. A key called the key to the cellar is on the keyring.

Instead of taking a key when the noun is on the keyring, try taking the keyring. Instead of dropping a key when the noun is on the keyring: try dropping the keyring.

Before locking something with a key while the second noun is on the keyring and the keyring is not in the player:
    say "(first taking the keyring)";
    silently try taking the keyring.

Before unlocking something with a key while the second noun is on the keyring and the keyring is not in the player:
    say "(first taking the keyring)";
    silently try taking the keyring.

Understand "lock [something] with [a key on the keyring]" as locking it with.
Understand "unlock [something] with [a key on the keyring]" as unlocking it with.
Understand "open [something] with [a key on the keyring]" as unlocking it with.

Understand "remove [a key]" as removing it from.

Rule for supplying a missing second noun while removing from:
    if the noun is a key and the noun is on the keyring, change the second noun to the keyring;
    otherwise say "You'll have to specify what you want to remove it from."

Section - The Fly

The fly is a backdrop in the Real Estate Area. Instead of doing something to the fly, say "You can't see it -- but you can hear it buzzing around somewhere nearby." Understand "buzzing" as the fly.

Every turn: if the fly is in the location and a random chance of 1 in 20 succeeds, follow the buzzing fly rule.

This is the buzzing fly rule: choose a random row in the Table of Fly Noises; say "You hear a fly buzzing around [noise entry]."

Table of Fly Noises
noise
"somewhere in the room"
"right around your head"
"somewhere nearby"
"somewhere in the next room"
"right over the back of your neck"


Chapter - The Alley

The Alley is a room in the City Streets. "This narrow aperture between two buildings is nearly blocked with piles of rotting cardboard boxes and overstuffed garbage cans. Ugly, half-crumbling brick walls to either side totter oppressively over you. The alley ends here at a tall, wooden fence."

Instead of going outside in the Alley, try going northwest. Instead of going inside in the Alley, try going north.

Instead of going nowhere from the Alley, say "The only exit from the alley is to the northwest[if the wooden fence is passed through or we have examined the wooden fence], or you could crawl through the fence to the east[end if]."

The alley entrance is an open, unopenable, scenery door. It is southeast of the Cul-de-sac and northwest of the Alley. It has the description "The alley leads [if location is the Cul-de-sac]southeast, around the side of the office[otherwise]back out to the street[end if]." Understand "aperture" as the alley entrance. Instead of smelling the alley entrance, say "Smells pretty rancid in there."

An alley wall is in the Alley. It is scenery. Understand "walls", "brick", or "bricks" as the alley wall. Instead of climbing the alley wall, say "You cannot find any purchase on the steep, crumbling brick."

Some cardboard boxes are in the Alley. "The boxes are filthy, slimy and soaked with rain." They are ambiguously plural and scenery. Understand "filthy", "slimy", "rotting", or "box" as the cardboard boxes.

Instead of smelling the cardboard boxes, say "They smell of fungus and damp rot."

Instead of opening, closing, taking, pushing, pulling, or searching the cardboard boxes, say "The wet cardboard falls apart in your hands."



Section - The Garbage Can Puzzle

The garbage can is in the Alley. "It is stuffed to overflowing with slowly decomposing refuse." It is enterable, ambiguously plural, scenery, and a supporter. Understand "overstuffed", "stuffed", "cans", "bin", "bins", "refuse", "trash", "lid", "trashcan", or "trashcans" as the garbage can.

Instead of taking the garbage can, say "The garbage can is too heavy to carry, but you could probably push it around."

Instead of smelling something when the garbage can is in the location, say "The reek of decomposing garbage is nearly overpowering."

Instead of pushing the garbage can, say "You push the garbage can around aimlessly."

Instead of opening or searching the garbage can, say "There is no way you are digging through that garbage."

Instead of climbing the garbage can, try entering the garbage can.

After entering the garbage can, say "You clamber onto the wobbling garbage can, precariously balanced[if garbage can is positioned]. You can just reach the lower edge of the window from here[end if]."

After exiting when the player was on the the garbage can, say "Carefully, you descend."

Instead of going down when the player is on the garbage can: try exiting.

Before going when the player is on the garbage can: ignore the can't travel in what's not a vehicle rule; if the noun is not inside and the noun is not north and the noun is not the transom window, say "(first climbing down from the garbage can)".


The transom window is an openable, closed door. Rule for writing a paragraph about the transom window: if the location is the Alley, say "High up on the wall of the northern building there is a narrow, transom-style window[if garbage can is positioned]. One of the garbage cans is pushed up against the wall directly underneath it[end if]." Before listing nondescript items of the File Room, change the transom window to unmarked for listing. It has description "About eighteen inches wide, a foot tall. Hinges along the top allow it to swing out. It's currently [if open]open[otherwise]closed[end if]." The transom window is north of the Alley and south of the File Room. Understand "narrow" as the transom window. Understand the open property as referring to the transom window.

Instead of doing something other than examining with the transom window when the location is not the File Room and the player is not on the garbage can, say "The window is too high for you to reach."

Instead of doing something other than examining with the transom window when the player is on the garbage can and the garbage can is not positioned, say "You still can't quite reach it. Maybe if you pushed the garbage can closer..."

Instead of knocking on the transom window, say "You rap sharply on the glass, but no one answers."

Instead of searching the transom window: if the location is the Alley, say "Peering in[if the transom window is closed] through the foggy glass[end if], you can see what looks like a file room."; otherwise say "You can see the damp, dirty alley outside."

Instead of attacking the transom window, say "You're not here to vandalize the place."

Instead of lifting the transom window, try opening the transom window.

The garbage can can be positioned. The garbage can is not positioned.

Instead of pushing the garbage can under the transom window when the player is on the garbage can, say "You'll have to get down first."

Instead of pushing the garbage can under the transom window: if the can is positioned, say "The garbage can is already under the window."; otherwise say "Grunting and holding your breath, you manhandle one of the filthy cans under the window."; now the can is positioned.

After going through the transom window: say "It's a tight squeeze, but you just manage to wriggle through, dropping [if the location is the File Room]quietly to the floor inside[otherwise]gracelessly into the alley outside[end if]."; continue the action.



Chapter - The Fence and the Beach

The wooden fence is an open, unopenable, scenery door. It is east of the Alley and west of the Narrow Beach. It has the description "One of the boards seems to be loose down at the bottom. You could probably just squeeze through." Understand "gap", "loose board", or "board" as the wooden fence.

Instead of climbing the wooden fence, say "The fence is much too high for you to climb[if the player is on the garbage can], even standing on the garbage can[end if]."

Instead of touching, attacking, or pushing the wooden fence, try examining the fence.

Instead of pushing the garbage can under the wooden fence, say "You manage to scoot the garbage can slightly closer to the fence, but it's clear that even standing on it, you wouldn't be able to climb over."

Before going through the wooden fence:
    if the location is the Alley, say "Dropping to your hands and knees, you wriggle underneath the loose board and scramble down a muddy slope."; otherwise say "[if the wooden fence is passed through]You pick your way up the slope, push the loose board aside, and slip back in through the gap[otherwise]At the top of the slope you find a tall, wooden fence with a loose board near the bottom; pushing it aside, you manage to wriggle through the gap[end if]."

The Narrow Beach is a room in the Outdoors. "A narrow strip of sand tucked away between two outcroppings in the predominantly rocky shoreline, accessible only from a steep, muddy slope to the west. The sand is filthy and strewn with rocks, seaweed, litter and other bits of storm-tossed detritus."

Instead of going up in the Narrow Beach, try going west.

Instead of going nowhere from the Narrow Beach, say "The rocky outcropping block your way to the north and south; the only way back is up the slope to the west. Or, perhaps, into the pipe."

Some outcroppings are in the Narrow Beach. They are ambiguously plural and scenery. They have the description "The steep, rocky outcroppings extend into the water on either end of the narrow beach." Instead of climbing the outcroppings, say "The rocks are too steep and jagged for you to navigate." Understand "rocks", "outcropping", "rocky outcropping", or "rocky outcroppings" as the outcroppings.

The detritus is in the Narrow Beach. It is scenery. It has the description "Nothing of any worth or interest here, just drifts of trash." Instead of taking or searching the detritus, try examining the detritus. Understand "sand", "seaweed", "litter", "trash", or "garbage" as the detritus. Instead of digging the detritus, say "There's no buried treasure here. It's just a lot of dirty sand."

The muddy slope is in the Narrow Beach. It is scenery. It has the description "The muddy slope leads up and to the west." Instead of climbing the muddy slope, try going west.

Section - The Outflow Pipe

The outflow pipe is inside from the Narrow Beach and outside from the Outflow Tunnel. It is an open, unopenable, door. It has the description "The concrete pipe is about a foot and a half in diameter. Looking in, you can only see about three feet before the inner walls of the pipe disappear into blackness."

Rule for writing a paragraph about the outflow pipe: if the location is the Narrow Beach, say "Near the bottom of the slope, a sewage outflow pipe juts out over the beach, about three feet above the ground. A thin stream of acrid-smelling sewer water trickles out over the lip of the pipe, forming a puddle in the sand."; otherwise stop. Before listing nondescript items of the Outflow Tunnel: change the outflow pipe to unmarked for listing.

Instead of entering the outflow pipe: if the location is the Narrow Beach, try going inside; otherwise say "You're already in the pipe."

Instead of searching the outflow pipe, try examining the outflow pipe.

Instead of inserting something into the outflow pipe when the location is the Narrow Beach, say "It's probably not a good idea to stick anything down a dark, smelly sewer pipe; you might lose it."

Before going through the outflow pipe when the location is the Narrow Beach:
    if the Outflow Tunnel is not visited begin;
        instead say "You don't really feel like crawling head first into a smelly, filthy, pitch black sewer pipe.";
     otherwise;
        say "Well, you've already been through this pipe from the other end, and at this point you can't get much dirtier than you already are, so... taking a deep breath[if the player carries the umbrella and the umbrella is open] and closing your umbrella[end if], you duck your head and wriggle your way into the pipe.

Note to self: if you ever make it through this alive, you'd better get one hell of an anniversary present come next June.";
    if the player carries the umbrella and the umbrella is open, change the umbrella to closed;
    end if.

Before going through the outflow pipe when the location is the Outflow Tunnel, say "You reach the end of the pipe and wriggle your way out, dropping awkwardly to the sand."

The trickle of sewage is in the Narrow Beach. It is scenery and providing liquid. It has the description "The water coming out of the pipe is foul-smelling and brown." Understand "puddle", "sewer", "water", "brown", "stream" or "waste" as the trickle.

Instead of tasting or drinking the trickle, say "You must be joking."

Instead of smelling the trickle, say "It smells, appropriately enough, like a sewer. You'd rather not imagine what must get dumped into this pipe further upstream."

The sewer water is a kind of liquid. It has the description "It is foul-smelling and brown." It has the indefinite article "some". Understand "sewage", "waste", or "liquid" as sewer water. Three sewer waters are in Liquid Storage Limbo. Instead of tasting or drinking sewer water, say "You must be joking." Instead of smelling sewer water, say "It smells terrible, as you'd expect."

Instead of inserting the trickle into a waterproof container (called the vessel):
    say "You gingerly hold [the vessel] under the trickle of sewage, and manage to collect a small amount of sewer water wiithout getting too much of it on yourself.";
    move a random sewer water in Liquid Storage Limbo to the vessel.







Book - The Verlac Mansion

The Master Bedroom is a room.

The Bathroom is a room.

[These are currently just stubs so that the full implementation of the player's clothes will work correctly.]



Volume - The Plot

Book - When Play Begins

When play begins:
    display the boxed quotation
"The oldest and strongest emotion of mankind
is fear, and the oldest and strongest kind of fear
is fear of the unknown.
-- H. P. Lovecraft";
    show the current quotation;
    say "

    ";
    center "[bold type]A N C H O R H E A D[roman type]


    ";
    center "press R to restore, any other key to begin

    ";
    let keystroke be the chosen letter;
    if keystroke is 114 or keystroke is 82, try restoring the game;
    clear the screen;
    say "


[italic type]November[roman type].

You take a deep breath of salty air as the first raindrops begin to spatter the pavement, and the swollen, slate-colored clouds that blanket the sky mutter ominous portents amongst themselves over the little coastal town of Anchorhead.

Squinting up into the storm, you wonder how everything managed to happen so fast. The strange phone call over a month ago, from a lawyer claiming to represent the estate of some distant branch of Michael's family... then the sudden whirlwind of planning and decisions, the legal details and travel arrangements, the packing up and shipping away of your entire home, your entire life...

Now suddenly here you are, after driving for the past two days straight, over a thousand miles away from the familiar warmth of Texas, getting ready to move into the ancestral mansion of a clan of relatives so far removed that not even Michael has ever heard of them. And you've only been married since June and none of this was any of your idea in the first place, and already it's starting to rain.

These days, you often find yourself feeling confused and uprooted.

You shake yourself and force the melancholy thoughts from your head, trying to focus on the errand at hand. You're to meet with the real estate agent and pick up the keys to your new house while Michael runs across town to take care of some paperwork at the university. He'll be back to pick you up in a few minutes, and then the two of you can begin the long, precarious process of settling in.

A sullen belch emanates from the clouds, and the rain starts coming down harder -- fat, cold drops smacking loudly against the cobblestones. Shouldn't it be snowing in New England at this time of year? With a sigh, you open your umbrella.";
    pause the game;
    clear the screen;
    display the boxed quotation
"I was far from home, and the spell of the eastern
sea was upon me.
-- H. P. Lovecraft";
    show the current quotation;
    say "


    ";
    center "THE FIRST DAY

    ";
    wait for any key;
    clear the screen;
    say "





    ";


Book - Scenes

Part - The First Day

The First Day is a scene. The First Day begins when play begins.

When First Day begins: change the left hand status line to " [the player's surroundings]"; change the right hand status line to "the first day ".




Volume - Gameplay

Book - New Actions

Part - Calling Things

Calling is an action applying to one topic.

Understand "call [text]" as calling. Understand the command "phone" as "call".

Report calling: if First Day is happening, say "Of course, you left your cell phone in your purse, and you left your purse in the car with Michael."; otherwise say "You're miles from any working phone."

Part - Knocking On Things

Knocking on is an action applying to one touchable thing and requiring light.

Understand "knock on [something]" as knocking on. Understand the command "rap" as "knock".

Report knocking on: say "No one answers."

Part - Filling Things

Understand the command "fill" as something new.

Filling it with is an action applying to two touchable things and requiring light.

Understand "fill [something] with [something]" as filling it with.

Check filling it with while the second noun is not a liquid: instead try inserting the second noun into the noun.
Check filling it with while the noun is not a container: instead say "[The noun] can't contain things."
Check filling it with while the noun is a closed container: instead say "[The noun] is closed."
Check filling it with while the noun is a leaky container: instead say "[The noun] is not waterproof; [the second noun] would leak out."
Check filling it with while the second noun is in a waterproof container (called the vessel): instead try pouring the second noun into the noun.

Report filling it with:
    say "That would accomplish little."

Part - Lifting Things

Lifting is an action applying to one touchable thing and requiring light.

Understand "lift [something]" as lifting.
Understand "lift up [something]" as lifting.
Understand "lift [something] up" as lifting.

Understand the command "raise" as "lift".

Report lifting: say "That would accomplish little."

Part - Playing Things

Playing is an action applying to one touchable thing and requiring light.

Understand "play [something]" as playing.

Report playing: say "That would accomplish little."

Part - Pouring Things Into Things

Pouring it into is an action applying to two touchable things and requiring light.

Understand "pour [something]" as pouring it into.
Understand "pour out [something]" as pouring it into.
Understand "pour [something] out" as pouring it into.
Understand "pour [something] on/onto/in/into [something]" as pouring it into.

Understand the command "spill" or "dump" as "pour".

Rule for supplying a missing second noun while pouring: change the second noun to the ground.

Check pouring it into while the noun is not a liquid:
    if the noun contains a liquid (called the contents), try pouring the contents into the second noun;
    otherwise say "You can't pour [the noun]; it's not a liquid."; stop.
Check pouring it into while the noun contains a liquid (called the contents): instead perform the current action on the contents with the second noun.
Check pouring it into while the noun is not in a waterproof container: instead say "You don't have [the noun]."
Check pouring it into while the noun is in a waterproof container (called the vessel):
    if the vessel is not carried by the player begin;
        say "(first taking [the vessel])";
        silently try taking the vessel;
    end if.
Check pouring it into while the second noun is not a container and the second noun is not the ground: instead say "That would only make a mess."
Check pouring it into while the second noun is a closed container: instead say "[The second noun] is closed."
Check pouring it into while the second noun is a leaky container: instead say "[The second noun] is not waterproof; [the noun] would leak out."
Check pouring it into while the number of things in the second noun is greater than zero: instead say "There is already something in [the second noun]."


Carry out pouring it into: if the second noun is the ground, move the noun to Liquid Storage Limbo; otherwise move the noun to the second noun.

Report pouring it into: if the second noun is the ground, say "[The noun] spills out onto [the second noun], where it quickly trickles away."; otherwise say "You pour [the noun] into [the second noun]."

Part - Pushing Things Under Things

Pushing it under is an action applying to two touchable things and requiring light.
Understand "push [something] under/to/near/towards/toward [something]" as pushing it under.
Understand "push [something] close/closer to [something]" as pushing it under.
Understand "pull [something] under/to/near/towards/toward [something]" as pushing it under.
Understand "pull [something] close/closer to [something]" as pushing it under.

Report pushing it under: say "That would accomplish little."


Book - Altered Grammar

Understand the command "out" as something new.
    Instead of going outside while the player is in an enterable container, try exiting.

Book - Synonyms

Understand the command "bolt" as "lock".

Understand the command "peer" or "peek" as "look".

Understand the command "unlatch" or "unbolt" as "unlock".

Book - Custom Responses

The description of a thing is usually "Just [if the noun acts plural]some[otherwise]an[end if] ordinary-looking [noun]."

Book - Inform 6 Hacks

To perform the current action on (something - an object):
    (- <<(action) {something}>>; -)

To perform the current action on (something - an object) with (another - an object):
    (- <<(action) {something} {another}>>; -)

5 comments - Leave a commentPrevious Entry Share Next Entry

Comments:

From:blacksnail
Date:May 17th, 2006 04:50 pm (UTC)
(Link)
Spectacular. This is great stuff.
From:zigguratbuilder
Date:May 17th, 2006 07:40 pm (UTC)
(Link)
I had to kill all pouring/liquid references to get it to load, but otherwise it's solid. Rocking rock rock.

-Andy
From:mikegentry
Date:May 17th, 2006 07:50 pm (UTC)
(Link)
Make sure you have the latest build - 3L95. I know it won't compile on anything earlier, though I'm not sure if it's the liquid rules specifically that break it.
From:prog
Date:May 17th, 2006 09:53 pm (UTC)
(Link)
This is great. I just posted it to Digg as an excellent source code example; hope that's OK.
From:mikegentry
Date:May 17th, 2006 11:52 pm (UTC)
(Link)
No problem.