! ----------------------------------------------------------------------------
! All Quiet on the Library Front
! An Interactive-Fiction Vignette by Michael Phillips (mike@lawlib.wm.edu)
! (c) 1995
!
! Like the game, this source code is provided 'AS IS', and no warrantee
! express or implied should be assumed.
!
! My home page, which includes the source code to Release 1 for those
! who are interested, is at:
! http://skaro.lawlib.wm.edu/~mike/
! The IF-related stuff is all at:
! http://skaro.lawlib.wm.edu/~mike/if/
!
! LIBRARY was compiled with Inform 5.5 (v1502) and the 5/12(951024)
! Inform Libraries. It has been tested with xip, jzip, and xzip under
! Linux 1.2.13, and zip, jzip, and wzip under DOS 5.0 (and Windows 3.11).
! It will likely run on any interpreter which can handle a version 5
! Z-Machine story file.
! ----------------------------------------------------------------------------
! Necessary variables, constants, etc.
Switches v5dx;
Constant Story "ALL QUIET ON THE LIBRARY FRONT";
Constant Headline "^An Interactive Vignette^";
Release 2;
Constant MAX_SCORE 30;
Constant OBJECT_SCORE 0;
Constant ROOM_SCORE 0;
Constant TASKS_PROVIDED;
Constant NUMBER_TASKS 10;
Global task_scores -> 5 5 2 5 2 5 2 1 1 2;
Fake_Action Invoke;
Fake_Action FixGates;
Statusline time;
Global XYZZYUsed = 0; ! 1 after XYZZY used
Global quotes_on = 1; ! 1 if on, 0 if off (probably backwards)
Include "Parser";
Include "VerbLib";
! ----------------------------------------------------------------------------
! The last thing required to implement tasks for the FULL SCORE.
! ----------------------------------------------------------------------------
[ PrintTaskName a;
if (a==0) "getting key";
if (a==1) "getting the biography";
if (a==2) "disabling the security gates";
if (a==3) "recovering the novel";
if (a==4) "delivering the novel";
if (a==5) "finding the Encyclopedia Frobozzica";
if (a==6) "delivering the printout";
if (a==7) "trying a magic word";
if (a==8) "discovering the red herring";
if (a==9) "disposing of the red herring";
];
! ----------------------------------------------------------------------------
! Here are some pretty quotations. Well, I think they're cute, appropriate,
! and nifty, so there!
! ----------------------------------------------------------------------------
Array quote_done -> 10;
Global next_quote = -1;
[ Quote i;
if (quote_done->i==0) { quote_done->i = 1; next_quote = i; }
];
! 0 = Reference Librarian
! 1 = Rare Books Room
! 2 = Novel
! 3 = Wandering for Way Too Long on the second floor
! 4 = Technician
! 5 = attendant's novel
[ AfterPrompt;
if (quotes_on==1) {
switch(next_quote)
{ 0: box "[She] is one of the secret masters of the"
"world: a librarian. They control information."
"Don't ever piss one off."
""
" -- Spider Robinson, The Callahan Touch";
1: box "No book is of much importance, the vital thing"
"is, What do you yourself think?"
""
" -- Elbert Hubbard, Philistine, vol. xviii.";
2: box "Books for general reading always smell badly."
"The odor of common people hangs about them."
""
" -- Friedrich Wilhelm Nietzsche";
3: box " And [a library] distorts space. It distorts"
"it into polyfractal L-space."
" So, while the Dewey system has its fine points,"
"when you're setting out to look something up in"
"the multidimensional folds of L-space, what you"
"really need is a ball of string."
""
" -- Terry Pratchett, Guards! Guards!";
4: box "Meek young men grow up in libraries."
""
" -- Ralph Waldo Emerson,"
" Nature, Addresses and Lectures:"
" The American Scholar";
5: box "A best-seller is the gilded tombstone of a"
"mediocre talent."
""
" -- Logan Pearsall Smith";
}
}
next_quote = -1;
];
! ----------------------------------------------------------------------------
! A note on the structure -- I found it useful to implement the room first
! (with a few notes to myself), followed by the scenery objects within,
! followed by NPC's.
!
! There is nothing particularly tricky about the implementation, so comments
! are sparse. Feel free to write me (mike@lawlib.wm.edu) with any
! questions you might have.
!
! Note that each NPC has the ASK and ANSWER routines duplicated. This is
! due to a change in the libraries and is necessary to respond to multiple
! variations on ASK, ANSWER, and others. There is probably a much cleverer
! way of doing this, but I haven't figured it out yet. If you have, please
! let me know!
!
! Those descriptions which have changed since Release 1 were inspired by
! suggestions from Margot Koval (mckova@mail.wm.edu through the end of
! the year).
! ----------------------------------------------------------------------------
! ----------------------------------------------------------------------------
! This is the Lobby. Among the features are a circulation desk (with
! attendant), security gates, and card catalog.
! ----------------------------------------------------------------------------
Object Lobby "Lobby"
has light
!has general
! if player has tried to leave without the book
with name "entrance",
description "This is the entrance to the library. The circulation \
desk dominates the room, seemingly cobbled together over the \
course of several generations from an assortment of desks and \
tables. A pair of security gates stands before the front doors \
to prevent people from stealing books. A card catalog lurks \
in a dark and dusty corner of the room, seemingly cringing away \
from the harsh flourescent light. Glass doors to the west lead \
to the book stacks; an archway to the northwest is labelled \
~Duplicating Services~; a door to the north bears a sign marked \
~Private~ in large friendly letters; and the exit is to the \
east",
nw_to G_Flr_Copiers,
before [;
Go:
if (noun==w_obj) {
print "^You push the glass doors open. Their hydraulics hiss \
faintly.^";
PlayerTo(G_Flr_Stacks);
rtrue;
}
if (noun==e_obj or out_obj) {
if (parent(R_Key) ~= Circ_Attendant)
"Whoops! You really need to return that key to the \
circulation desk!";
if (parent(ID_Card) ~= player)
"Hey, don't forget your ID card! You can't eat without \
it, and there's a looooong week-end of writing ahead of \
you!";
if (parent(book) ~= player)
"You're leaving without the book? You can't afford to \
do that, you'll flunk out!";
if (Sec_Gates hasnt general)
"The alarm goes off as you try to leave, and, shamed, you \
turn back to the distrustful stare of the circulation \
desk attendant.";
if (Circ_Attendant hasnt general)
"As you are about to cross the threshold out, the guy at \
the circulation desk says, ~Hey, you can't leave with the \
book!~";
if (Ref_Librarian hasnt general)
"The reference librarian comes into the lobby, huffing \
and puffing. ~I'm sorry, but we can't allow you out of \
the library with that valuable book.~ She heads back to \
the stacks as you turn away from the gates.";
lookmode=2;
PlayerTo(End_Game);
rtrue;
}
if (noun==n_obj) {
if (Circ_Attendant hasnt general) {
if (Private_Door hasnt general)
"Perhaps you should examine the sign first.";
"You take another look at the sign, think of \
Rottweilers, and decide to choose another course.";
};
print "You sneak through the door marked PRIVATE.^";
PlayerTo(G_Flr_Private);
rtrue;
}
! The following basically gives LOOK away for free.
Look, Examine:
the_time = the_time - 1;
if (the_time < 900) the_time = 900;
];
Object Card_Catalog "card catalog" Lobby
has scenery
with name "card" "catalog",
description "Almost no light penetrates this corner of the room. The \
card catalog is in the usual shape, a box on legs with a myriad \
of small drawers, each labelled in crabbed writing. However, \
the entire card catalog is festooned with cobwebs. The dust on \
top is so thick that it looks like grubby grey felt.";
Object Cat_Drawer "card catalog drawer" Lobby
has container scenery
with name "drawer" "drawers",
description [;
if (self has open)
"The card catalog drawer is open.";
"The card catalog drawer is closed. With all that dust, maybe \
it wouldn't be a good idea to disturb it.";
],
before [;
Open:
give self open;
"You pull on one of the brass handles, and the attached \
drawer comes out with a piercing squeal. You hardly notice \
the noise, however, because you're too busy coughing from the \
cloud of dust this action stirs up. When your eyes finally \
stop watering, the drawer is open, exposing a series of \
small, yellowed bits of paper.";
Close:
give self ~open;
"With a shudder in anticipation of the dust, you push the \
drawer closed. The slight squeal almost sounds like a sigh.";
];
Object Parchment "pile of yellowed paper" Cat_Drawer
with name "yellow" "bits" "of" "paper" "parchment",
description [;
print "You peer at the yellowed surface in confusion. These \
aren't normal index cards, they're ";
style bold;
print "parchment";
style roman;
". Not only that, but you don't recognize the language \
they're written in! Looks like this isn't going to be \
much help at all.";
],
before [;
Take: "What are you going to do with a bit of yellowed parchment?";
];
Object Sec_Gates "security gates" Lobby
has scenery
!has general
! if currently being repaired by the technician
with name "security" "gates",
description [;
if (self has general)
"A panel is open in the side of one gate, which is currently \
being worked on by the technician. It looks like the gates \
are shut down, and you can leave the library without them \
going off! The lights on top are out.";
"The gates are made of gunmetal-grey plastic, and a set of little \
red lights on top seem to watch you menacingly.";
],
before [;
Disable:
"Software was your specialty, not hardware.";
];
Object Pieces "Pieces-Parts" Lobby
has scenery
with name "pieces" "parts" "piece" "part" "hardware",
description [;
if (Sec_Gates has general)
"Wow, what a lot of hardware on the floor!";
"You can't see any such thing.";
],
before [;
Take:
if (Sec_Gates has general)
"The glare the technician shoots your way as your hand \
reaches for the parts convinces you they should probably \
be left alone.";
"You can't see any such thing.";
];
Object Gate_Lights "security gate lights" Lobby
has scenery
with name "little" "red" "lights" "light",
description [;
if (Sec_Gates has general)
"They look like dark, empty eye sockets.";
"They glitter malignantly at you.";
],
before [;
Take: "The lights are securely fastened to the gates.";
];
Object Circ_Desk "circulation desk" Lobby
has scenery
with name "circ" "circulation" "desk" "barrier",
description "The signs of careful scavenging of whatever materials \
came to hand are present. There are many outdated notices and \
signs posted on the walls nearby.";
Object Signs "outdated signs and notices" Lobby
has scenery,
with name "outdated" "signs" "notices" "posters" "suggestions" "board" "calendar" "calendars",
description "There are notices of closing times for each of the past \
ten years, posters mentioning upcoming events of 1951, calendars \
which are decades old, and a suggestion board that has a note \
saying the library could use some more books.";
Object Private_Door "private door" Lobby
has scenery,
with name "private" "door" "sign",
description [;
give self general;
"The sign on the northern door says ~Private~ in large friendly \
letters, the same kind of lettering which is usually seen on \
signs saying ~Attack-Trained Rottweilers Patrolling Premises \
After Business Hours~.";
];
! ----------------------------------------------------------------------------
! The Circ Desk Attendant
! ----------------------------------------------------------------------------
Object Circ_Attendant "circulation desk attendant" Lobby
has animate transparent
with name "attendant" "staff" "kid" "him" "he" "student" "alan",
description [;
if (self has general)
"The circulation desk attendant is thoroughly engrossed in \
the novel ~Debt of Honor~, by Tom Clancy.";
"He's leafing through a dog-eared copy of Tom Clancy's \
~Without Remorse~, looking terminally bored. He is wearing a \
nametag.";
],
life [;
Give:
if (noun == ID_Card) {
move ID_Card to Circ_Attendant;
move R_Key to player;
if (R_Key hasnt general)
Achieved(0);
give R_Key general;
"The circulation attendant gives you the key to the \
Rare Books Room, and he holds your ID card in exchange.";
}
if (noun == R_Key) {
if (R_Door has open) "~Did you remember to close the \
door?~";
if (R_Door hasnt locked) "~Did you remember to lock the \
door?~";
move ID_Card to player;
move R_Key to Circ_Attendant;
"The circulation attendant puts the key away, then he \
returns your ID card.";
}
if (noun == novel) {
if (self hasnt general)
Achieved(4);
give self general;
move novel to Circ_Attendant;
"The circulation attendant gets a big smile on his face. \
~I wondered where that had gotten off to!~ He \
immediately becomes immersed in the novel.";
}
"~I don't need that.~";
Kiss: "~Yuck! Get away from me! I hate that mushy stuff!~ \
He turns away, muttering about technothrillers being better \
than ~that durn romantic stuff~.";
Attack: "The desk attendant cowers. ~Don't hit me!~";
ThrowAt: "The desk attendant ducks, sighs, and returns the item \
from behind the circulation desk. ~You appear to have \
dropped this.~";
Show:
if (noun==ID_Card)
"~You need to give me the card before I can give you \
the key.~";
if (self has general)
"The attendant seems immersed in ~Debt of Honor~, and you \
are utterly unable to get his attention.";
if (noun==R_Key)
"~You need to give me the key before I can return your \
ID card.~";
if (noun==novel)
"~I've been looking for that ever since I lost it! \
Could you please give it to me?~";
"He doesn't appear to be interested other than his book.";
Ask:
if (second=='book' or 'bio' or 'biography' ||
second=='graham' or 'nelson' or 'help' ||
second=='find' or 'assistance' or 'where')
"~Try talking to the reference librarian.~";
if (second=='key' or 'rare' or 'room')
"~You need to give me your ID card in order to get the \
key to the Rare Books Room.~";
if (second=='reference' or 'librarian')
"~Try going through those doors, she's probably at her \
desk.~";
if (second=='novel' or 'debt' or 'of' ||
second=='honor' or 'technothriller') {
if (self has general)
"~Thanks for finding it,~ he murmurs as he continues \
reading.";
"He glances up at you. ~Yeah, it gets pretty dull around \
here on Friday afternoons, and I've already read this one \
six times.~ He sighs heavily. ~If only I hadn't lost \
that copy of ~Debt of Honor~ in the stacks. I've only \
read that one four times, and not within the past three \
months.~ Dejected, he goes back to flipping the pages.";
}
"He shrugs, and continues reading.";
Tell:
if (second=='novel' or 'debt' or 'of' ||
second=='honor' or 'technothriller') {
if (self has general)
"~Thanks for finding it,~ he murmers as he continues \
reading.";
"~Did you find it?~ he asks intently. ~I would really \
like to have it back!~";
}
Answer:
if (noun=='book' or 'bio' or 'biography' ||
noun=='graham' or 'nelson' or 'help' ||
noun=='find' or 'assistance' or 'where')
"~Try talking to the reference librarian.~";
if (noun=='key' or 'rare' or 'room')
"~You need to give me your ID card in order to get the \
key to the Rare Books Room.~";
if (noun=='reference' or 'librarian')
"~Try going through those doors, she's probably at her \
desk.~";
if (noun=='novel' or 'debt' or 'of' ||
noun=='honor' or 'technothriller') {
if (self has general)
"~Thanks for finding it,~ he murmurs as he continues \
reading.";
"~Yeah, a couple days ago I lost a novel upstairs.~";
}
"He shrugs, and continues reading.";
];
Object Circ_Nametag "Alan's nametag" Circ_Attendant
has proper
with name "alan^s" "name" "tag" "nametag",
description "~Hi, I'm Alan.~";
! ----------------------------------------------------------------------------
! Note: this novel is removed when the player finds the other novel, to
! avoid (a) name conflicts and (b) my having to learn how to use
! parse_name :-) a vain hope at best, given the much larger project(s) I
! am now working on, but let's let me have that illusion for the moment.
! ----------------------------------------------------------------------------
Object old_novel "~Without Remorse~" Lobby
has scenery
with name "dog" "eared" "dog-eared" "copy" "of" "without" "remorse" "novel",
description [;
Quote(5);
"This is a dog-eared copy of Tom Clancy's ~Without Remorse~, \
truly a dreadful reading selection.";
];
! ----------------------------------------------------------------------------
! The Rare Books Room Key
! ----------------------------------------------------------------------------
Object R_Key "key" Circ_Attendant
with name "key" "wood" "keychain" "chain",
description "This key is on a flourescent yellow keychain, which \
is, in turn, attached to a rather large chunk of wood. The \
whole thing is awkward, and difficult to hide within a backpack \
(not that you have one with you) or a pocket.";
! ----------------------------------------------------------------------------
! The photocopier room
! It includes a sign, a photocopier, and a copy company technician who
! fries himself!
!
! Idea of room and technician from Fred M. Sloniker
! ----------------------------------------------------------------------------
Object G_Flr_Copiers "Duplicating Services"
has light,
with name "duplicating services",
se_to Lobby,
out_to Lobby,
cant_go "Maybe you should go out through the doors to the southeast.",
description [;
if (Copier_Techie has general)
"This room is filled with acrid smoke, and a smoldering pile \
of burned and melted wiring is in one corner.";
"This is the copier room. There is only one copier here, and it \
bears a sign which proclaims it to be out of order. The tangled \
mess of wires spilling out of its mechanical belly reinforces \
the statement.";
],
before [;
Smell:
if (Copier_Techie has general)
"The air has an awful, burned smell to it.";
! The following basically gives LOOK away for free.
Look, Examine: the_time = the_time - 1;
];
Object Copier_Techie "copier technician" G_Flr_Copiers
has animate
!has general
!if fried
with name "smoking" "ash" "techie" "technician",
number 100,
description [;
if (self has general)
"The technician is now a smoking pile of ash.";
"A middle-aged, slender man is bent over, half inside the \
copier, attempting to clear a paper jam and fix some other \
problems. He looks very busy.";
],
Life [;
ThrowAt, Attack:
if (self has general)
"Harm a pile of ash? Yeah, right.";
"You shouldn't do that, he's repairing the copier!";
Kiss:
if (self has general)
"Kiss ash? Ewwwww.....";
"He's busy at the moment, and very dirty.";
Ask, Answer, Tell, Order, Show, Give:
if (self has general)
"How do you expect to do that to a pile of ashes?";
"He waves you off irritably. ~I'm busy right now!~";
],
each_turn [ i;
if (self.number > 10)
self.number = random(4) + 1;
if (self hasnt general) {
self.number = self.number - 1;
if (self.number<=0) {
give self general;
give self concealed;
"^The repairman yelps as he touches the wrong wire, and \
with an ear-splitting *POP*, vanishes in a cloud of \
greasy smoke...\
^^Looks like there's no chance of getting a copy made \
now.....";
} else {
i = random(3);
if (i==1) "^The technician curses under his breath as he \
reaches into the copier and yanks on some unseen \
component.";
if (i==2) "^The technician pulls out a piece of wire and \
adds it to the collection.";
if (i==3) "^The technician kicks the copier, muttering \
under his breath.";
}
}
i = random(10);
if (i==1)
"^The ash continues to smoke, leaving an acrid odor in the \
air.";
];
Object Copying_Machine "photocopier" G_Flr_Copiers
has scenery
with name "photo" "copier" "copying" "machine" "xerox" "photocopier" "mangled" "mass" "burned" "wiring" "collection",
description [;
if (Copier_Techie has general)
"This mangled mass of burned wiring was once a photocopier.";
"The photocopier appears to be out of order, and a technician \
is currently working on it.";
],
before [;
Smell:
if (Copier_Techie has general)
"The ex-copier smells of ozone and other unpleasant things.";
Repair:
"Unfortunately, you don't know how. You muse that it might be \
a useful skill to pick up if you don't get that book and pass \
this class, though.";
];
Object Copier_Sign "copier sign" G_Flr_Copiers
has scenery
with name "out" "of" "order" "sign",
description [;
if (Copier_Techie has general)
"What sign? It was burned to ash!";
"This sign reads 'Out of Order -- Do Not Use!'";
];
! ----------------------------------------------------------------------------
! Technical Services
!
! Idea to have room behind PRIVATE sign (and how to get there) from
! Thorsten Franz
! ----------------------------------------------------------------------------
Object G_Flr_Private "Technical Services"
has light,
with name "technical services",
out_to Lobby,
s_to Lobby,
cant_go "All the offices are locked up, perhaps it is better to \
go out through the doors to the south.",
description "This appears to be the Technical Services area, where \
books are normally catalogued. All of the offices are locked \
up, however, and no one is around. Maybe you shouldn't be here, \
and maybe it is time to leave through the doors to the south \
before the attendant notices or a librarian walks in on you and \
kicks you out!",
before [;
! The following basically gives LOOK away for free.
Look, Examine: the_time = the_time - 1;
];
! ----------------------------------------------------------------------------
! The Ground Floor Stacks. The only thing of particular interest here is the
! reference librarian, who will be coded after the basic layout is done.
! ----------------------------------------------------------------------------
Object G_Flr_Stacks "Ground Floor Stacks"
has light,
with name "ground floor stacks",
description "This cavernous room is lit with flickering flourescent \
lighting which makes the ceiling look even lower than it really \
is. It is filled with half-empty shelves, upon which rest the \
dusty boxes of many early games. To one side sits a massive, \
ancient desk, its surface cluttered with paperwork. A sign on \
the wall indicates that this is the reference desk, which would \
make the prim young woman sitting behind it the reference \
librarian. A doorway to the north is labelled ~Stairs~, and \
glass doors lead east to the lobby.",
before [;
Smell: "You're not sure exactly what the combination of books and \
old game boxes would smell like, but this room gives you \
something to compare it to.";
],
e_to Lobby,
out_to Lobby,
n_to G_Flr_Stairwell;
Object G_Flr_Shelves "ground floor shelves" G_Flr_Stacks
has scenery,
with name "shelves" "stacks" "books" "boxes" "games",
description "The games on these shelves range from every installment \
of the Zork series, through something simply marked as LTOI. \
There is a special shelf devoted to a game called, simply, \
~Curses~, with labels like ~R12~, ~R14~, ~R15~, and ~Curses95~. \
Other shelves cover ~Christminster~, ~Theatre~, ~Balances~, and \
many, many others.\
^^Off in one corner are several magazines dedicated to IF, \
including XYZZYNews and SPAG.",
before [;
! The following basically gives LOOK away for free.
Look, Examine: the_time = the_time - 1;
];
Object G_Flr_Games "ground floor games" G_Flr_Stacks
has scenery,
with name "theatre" "balances" "curses" "curses95" "christminster" "ltoi" "box" "game",
description "Wow, what a complete collection of games!",
before [;
Take:
"You're in enough trouble grade-wise, now is not the time to \
get involved in a game!";
];
Object Ref_Desk "reference desk" G_Flr_Stacks
has scenery,
with name "reference" "desk" "brown desk",
description "The squat, brown desk is covered with papers, printouts, \
games, and source listings. It looks like the reference \
librarian has her hands full cataloging all this information!";
Object Ref_Paperwork "paperwork" G_Flr_Stacks
has scenery,
with name "stack" "paperwork",
description "There are stacks upon stacks of papers, printouts, \
games, and source listings upon the desk.",
before [;
Take:
print "You reach for the paperwork on the desk and barely \
snatch your hand back in time to evade the wicked point \
of the pencil! The librarian glares at you, makes a few \
notations on her paperwork, then resumes ";
if (Ref_Librarian has general)
"cataloging the Encyclopedia Frobozzica.";
"her prim pose.";
];
Object Ref_Sign "reference sign" G_Flr_Stacks
has scenery,
with name "sign",
description "The sign reads ~Reference Librarian~, so it's a good \
bet that the person sitting at the desk is the reference \
librarian.";
Object Ref_Doors "reference doors" G_Flr_Stacks
has scenery,
with name "doors" "double" "double-doors",
description "These glass-paned doors lead to the Lobby.";
Object Ref_Lights "reference lights" G_Flr_Stacks
has scenery
with name "flourescent" "light" "lights" "bulb" "bulbs",
description "The same eye-aching, brain-melting, cheap flourescent \
lighting which is installed everywhere here at the College. \
Perhaps slightly more flickering than usual.",
before [;
Take: "These lights are indeed a pathetic lot, but there's no \
need to remove them.";
];
Object Magazines "magazines" G_Flr_Stacks
has scenery,
with name "xyzzy" "xyzzynews" "news" "spag" "stack" "magazines",
description "These IF magazines include XYZZYNews (named for an \
old magic word from ~Colossal Caves~) and SPAG, the Society \
for the Preservation of Adventure Games.";
! ----------------------------------------------------------------------------
! The Reference Librarian
! ----------------------------------------------------------------------------
Object Ref_Librarian "reference librarian" G_Flr_Stacks
has animate female transparent
!has general
! if she is looking at the encyclopedia
with name "reference" "librarian" "ref" "lib" "harried" "woman" "marion",
description [;
if (self has general)
"The reference librarian is furiously arguing with the \
library's computer system, trying to get the Encyclopedia \
Frobozzica into the not-yet-ready online catalog.";
"She is an extremely proper young woman. She has her hands \
folded neatly in front of her on the desk, and a pencil so \
sharp it looks like it would make a decent stiletto is tucked \
behind one ear. She watches the room, and you, like a hungry \
hawk. Pinned to her jacket is a nametag.";
],
life [;
Kiss: "You take another look at the wicked-looking pencil and \
change your mind.";
Attack, ThrowAt:
"No way! That's against library policy, and you can't \
afford to get thrown out at this late date. Besides, \
she looks like she's a pretty mean hand with that pencil.";
Give:
if (noun==Frobozzica) {
if (self hasnt general)
Achieved(6);
give self general;
move Frobozzica to Ref_Librarian;
"~Wow, a copy of the Encyclopedia Frobozzica! I've been \
wanting one of those! I need to add it to the \
collection right away.~ She begins furiously working at \
the computer at her desk.";
}
"~I don't need that, but thanks anyways.~";
Show:
if (noun==Frobozzica)
"~I've been waiting for a printout of that! Would you \
please give it to me?~";
if (noun==book)
"~That book should be returned to the Rare Books Room.~";
"She sniffs and turns back to her work.";
Order:
"She sniffs and turns back to her work.";
Ask, Tell:
if (second=='book')
"~What sort of book? We have many books here!~";
if (second=='biography' or 'graham' or 'nelson')
"~Ah, that valuable book. We keep it locked away, in \
the Rare Books Room.~";
if (second=='rare' or 'books' or 'room' ||
second=='where')
"~The Rare Books Room is on the second floor. Stairs are \
north of here. You will need the key, though.~";
if (second=='key' or 'locked' or 'lock')
"~The key may be obtained at the circulation desk.~";
if (second=='techie' or 'technician')
"~Ah, yes, he is currently printing some very important \
information out for me.~";
if (second=='printout' or 'encyclopedia' or 'frobozzica')
"~I am waiting for the Encyclopedia Frobozzica, which the \
technician is currently printing out for me.~";
if (second=='attendant' or 'circulation')
"~He's always reading. I think he lost a book recently.~";
if (second=='novel')
"~I'm pretty certain the circulation desk attendant lost \
a novel upstairs recently.~";
"The reference librarian looks at you sternly and asks that \
you please be quiet.";
Answer:
if (noun=='book')
"~What sort of book? We have many books here!~";
if (noun=='biography' or 'graham' or 'nelson')
"~Ah, that valuable book. We keep it locked away, in \
the Rare Books Room.~";
if (noun=='rare' or 'books' or 'room' ||
noun=='where')
"~The Rare Books Room is on the second floor. Stairs are \
north of here. You will need the key, though.~";
if (noun=='key' or 'locked' or 'lock' ||
noun=='may')
"~The key may be obtained at the circulation desk.~";
if (noun=='techie' or 'technician')
"~Ah, yes, he is currently printing some very important \
information out for me.~";
if (noun=='printout' or 'encyclopedia' or 'frobozzica')
"~I am waiting for the Encyclopedia Frobozzica, which the \
technician is currently printing out for me.~";
if (noun=='attendant' or 'circulation')
"~He's always reading. I think he lost a book recently.~";
if (noun=='novel')
"~I'm pretty certain the circulation desk attendant lost \
a novel upstairs recently.~";
"The reference librarian looks at you sternly and asks that \
you please be quiet.";
],
before [;
Examine: Quote(0);
];
Object Ref_Nametag "Marion's nametag" Ref_Librarian
with name "marion^s" "name" "tag" "nametag",
description "~Hi! I'm Marion.~";
Object Pencil "sharp pencil" Ref_Librarian
with name "sharp" "pencil" "stiletto",
description "Its point glimmers in the flourescent light like some \
malignant weapon.",
before [;
Take:
"The searing glare which the reference librarian shoots at \
you causes you to reconsider.";
];
! ----------------------------------------------------------------------------
! The Ground Floor Stairs.
! ----------------------------------------------------------------------------
Object G_Flr_Stairwell "Ground Floor Stairwell"
has light,
with name "ground floor stairs",
description "Grungy stairs lead upwards, to the second level. A \
damaged picture hangs on the wall. The door to the ground floor \
shelving area is to the south.",
before [;
Smell: "There is a slight, fishy odor.";
! The following basically gives LOOK away for free.
Look, Examine: the_time = the_time - 1;
],
u_to S_Flr_Stairwell,
s_to G_Flr_Stacks,
out_to G_Flr_Stacks;
Object G_Flr_Painting "ground floor painting" G_Flr_Stairwell
has scenery,
with name "damaged" "dusty" "picture" "painting" "activision" "logo",
description "This defaced painting may once have been a company \
logo of some sort, but it has been damaged severely by some \
sort of sharp instrument. All that remains is a letter A to \
the left, some sort of check mark in the middle, and the letter \
N at the far right.";
! Fred Sloniker suggested a vandalized A---V----n logo.
! Nifty idea, so I have implemented it.
Object G_Flr_Stairs "stairs" G_Flr_Stairwell
has scenery,
!general if red herring found
with name "stairs" "steps" "stairway" "stair" "dust" "bunnies",
description "These grungy stairs lead upwards. Dust bunnies romp \
and play all over the place, and the dust sure seems thick. \
Maybe the cleaning staff is on vacation.",
before [;
! The following basically gives LOOK away for free.
Look, Examine: the_time = the_time - 1;
LookUnder:
if (self has general)
"You find nothing.";
give self general;
move Red_Herring to player;
Achieved(8);
"You found a red herring!";
];
Object Red_Herring "red herring"
!has nothing
! No, really!
with name "red" "herring" "fish",
description "This is a smelly, reddish fish.";
! ----------------------------------------------------------------------------
! The Second Floor Stairs
! ----------------------------------------------------------------------------
Object S_Flr_Stairwell "Second Floor Stairwell"
has light,
with name "second floor stairs",
description "Grungy stairs lead downwards. The lights are dim, and \
a painting hangs on the wall. A door to the south appears to \
open into a room of shelves.",
before [;
Smell:
"You sneeze from inhaling the dust!";
! The following basically gives LOOK away for free.
Look, Examine: the_time = the_time - 1;
],
d_to G_Flr_Stairwell,
s_to S_Flr_Stacks,
out_to S_Flr_Stacks;
Object S_Flr_Stairs "stairs" S_Flr_Stairwell
has scenery,
with name "stairs" "steps" "stairway" "stair" "dust",
description "The stairs wind down into the dinginess. They could \
use a good sweeping and mopping, or even some traffic to cut \
through all the dust.";
! ----------------------------------------------------------------------------
! The GRUE, which sits invisibly, and will eat the fish if it is given
! to it.
! ----------------------------------------------------------------------------
Object Grue "grue" S_Flr_Stairwell
has animate concealed,
with name "black" "picture" "painting" "plaque" "grue" "canvas",
description "This painting could pass for a black canvas. \
The small plaque below it has ~Grue~ engraved.",
life [;
ThrowAt, Attack: "Defacing paintings? Why?";
Touch, Kiss, Show, Tell, Ask, Answer: "It's just a painting.";
Give:
if (noun == Red_Herring) {
remove Red_Herring;
Achieved(9);
"It almost appears as if an indescribable blackness forms \
in the painting and reaches out, taking the herring. It \
is followed by a terrible gnawing noise, and then all is \
silent again.";
}
"Give something to a painting? You've got to be kidding!";
];
! ----------------------------------------------------------------------------
! The Second Floor Stacks
! ----------------------------------------------------------------------------
Object S_Flr_Stacks "Second Floor Stacks"
has light,
!has general
! after the 'maze of twisty shelves' joke
with name "second floor stacks",
description [;
if (self hasnt general) {
print "You are in a maze of twisty shelves, all alike.\
^^(Well, okay, not really)^^";
give self general;
}
"This cavernous room is filled with shelves as far as the eye \
can see. A doorway to the east is labelled ~Computer Room~, \
and the stairwell lies to the north.";
],
n_to S_Flr_Stairwell,
in_to R_Door,
s_to R_Door,
out_to S_Flr_Stairwell,
e_to Computer_Lab,
before [;
Go:
if (noun == w_obj) {
Quote(3);
the_time = the_time + 3 + random(7);
"You wander out into the vast dusty maze of the bare \
shelves for a few minutes, but quickly realize that this \
is getting you no nearer your goal and return to the \
center of the room.";
}
! The following basically gives LOOK away for free.
Look, Examine: the_time = the_time - 1;
];
Object S_Flr_Shelves "Second Floor Shelves" S_Flr_Stacks
has scenery,
!has general
! if the novel "Debt of Honor" has been found
with name "stacks" "shelves" "books" "games" "labels",
description "These shelves are bare, although they seem to be \
well-dusted. Labels are already on the sides, despite the lack of \
a collection. The labels read ~FTP~ on the far left, ~GMD~ in the \
middle and ~DE~ on the far right. \
^^It is a very confusing order, not Dewey Decimal or \
alphabetical. At a guess, it is the Library of Congress \
classification system.",
before [;
LookUnder, Search:
if (self has general)
"The shelves are bare, and surprisingly free of dust.";
Quote(2);
give self general;
move novel to player;
remove old_novel;
Achieved(3);
"Tucked away in a corner, you find the novel ~Debt of Honor~, \
by Tom Clancy. Someone must've lost it!";
];
Object S_Flr_Lights "second floor lights" S_Flr_Stacks
has scenery,
with name "amber" "sconce" "sconces" "lights" "light" "bulb" "bulbs",
description "The small amber bulbs flicker pathetically.",
before [;
Take: "You reach for the small amber bulbs, then hesitate. After \
a moment, you decide to leave them alone. They look pathetic \
enough where they are.";
];
Object R_Door "rare books door" S_Flr_Stacks
has static door openable locked lockable,
with name "rare" "door",
description "Elaborate wrought-iron sconces are attached to the walls \
on either side, but since this is a library and would go up in \
an instant if flame were introduced, they are occupied by \
pathetic little amber light bulbs which glow dimly. A small \
plaque of polished brass is attached to the wall under one \
sconce. There is engraving above the door, on the heavy lintel.",
!"It is a heavy, wooden door with a sign reading \
! ~Rare Books Room~ on it.",
door_dir S_Flr_Stacks,
door_to Rare_Books_Room,
describe [;
if (self has open) "^The door stands open.";
if (self hasnt locked) "^The door is unlocked but shut.";
if (self hasnt general)
"^A heavy wooden door bars the way to the rare books room. \
A sign indicates that the key may be obtained from the \
circulation desk.";
"^A heavy wooden door bars the way to the rare books room.";
],
before [;
Unlock:
give self general;
],
found_in S_Flr_Stacks,
with_key R_Key;
Object S_Flr_Plaque "plaque" S_Flr_Stacks
has scenery
with name "plaque" "sign",
description "~The key to the rare-books room may be obtained at the \
front desk.~",
before [;
Take: "You pry at the polished brass plaque with your \
fingernails, but it refuses to yield to your determined \
assault.";
];
Object S_Flr_Engraving "engraving" S_Flr_Stacks
has scenery
with name "engraving" "lintel",
description "~Abandon Hope, All Ye Who Enter Here.~",
before [;
Take: "And just how do you propose to remove the engraving \
from the plaque?";
];
! ----------------------------------------------------------------------------
! The novel
! ----------------------------------------------------------------------------
Object novel "copy of ~Debt of Honor~"
!has nothing
! no, really!
with name "debt" "honor" "novel" "paperback" "tom" "clancy" "techno" "thriller" "technothriller" "copy" "of",
description "A rollicking read, but not quite suited to your tastes \
(which run more towards fiction with a good atmosphere, \
memorable characters, and a certain level of interaction with \
the plot).";
! ----------------------------------------------------------------------------
! The Computer Lab. This room has a number of computers, but more
! importantly, it has a printout of the Encyclopedia Frobozzica (to use
! on the Reference Librarian), and the Technician, who can be convinced
! to screw up the gates.
! ----------------------------------------------------------------------------
Object Computer_Lab "Computer Lab"
has light,
with name "computer lab",
description "This entire room hums with the combined output of several \
dozen computers. All of them are hopelessly out of date, but \
at least they're still good for word processing.\
^^A bank of printers on one side of the room frantically churns \
out paper.",
w_to S_Flr_Stacks,
out_to S_Flr_Stacks,
before [;
! The following basically gives LOOK away for free.
Look, Examine: the_time = the_time - 1;
];
Object Computer_Screens "Computer Screens" Computer_Lab
has scenery,
with name "computer" "computers" "screen" "screens" "terminal" "terminals",
description "The faintly-glowing, phosphorescent screens are \
displaying various IF games in different positions. There are \
also some screen dumps, and the technician's terminal is showing \
a maze of twisty Web pages, all alike.";
Object Print_Out "Print Out" Computer_Lab
has scenery,
with name "printout" "printouts" "print" "printer" "printers",
description "The printer is churning away at the source for a \
very complicated game, while a stack of printouts is piled \
nearby.",
before [;
Take:
if (Technician hasnt general) {
<>
}
"Wow, there's a lot of printouts here! You couldn't possibly \
carry all of them.";
Search, Examine:
if (Technician hasnt general) {
<>
}
if (Frobozzica has general) {
"You find nothing.";
}
give Frobozzica general;
move Frobozzica to player;
Achieved(5);
"Wow, a complete copy of the ~Encyclopedia Frobozzica~! \
You take it, as it might prove useful.";
];
! ----------------------------------------------------------------------------
! The Technician
!
! Note the customization of several actions, and the description which alters
! depending on whether or not he is currently repairing the gates.
! ----------------------------------------------------------------------------
Object Technician "technician" Computer_Lab
has animate transparent
!has general
! if the technician is downstairs, repairing the gates
with name "technician" "techie" "man" "tom" "thom" "thomas" "tommy",
description [;
Quote(4);
print "This frazzled-looking man is thin and angular. He wears \
thick, slightly rose-tinted glasses, and exhibits nervous \
twitching. He is wearing a nametag.^^";
if (self has general)
"He has opened up one of the security gates and is tinkering \
with its innards, muttering bitterly to himself all the while.";
"He is leafing through a manual for security systems, and \
cursing the unreliability of the security gates.";
],
life [;
Attack, ThrowAt:
"He looks harmless enough. No need to do that!";
Kiss:
"Geeky-looking guys in glasses turn you on, eh?";
Give:
if (noun==Frobozzica)
"~No, that's for the librarians. I don't need it.~";
"The technician refuses. ~With my computers, I have all \
I need!~";
Show:
if (noun==Frobozzica)
"~That printout is for the librarians.~";
Ask, Tell:
if (self has general)
"~Hey, I gotta fix these gates before going home. Go \
pester the librarians, or something.~";
if (second=='security' or 'gates' or 'problem' ||
second=='broken' or 'fix' or 'entrance' ||
second=='gate' or 'tower' or 'towers') {
<>;
}
"~Yeah, sure. Whatever. Don't distract me. I have work \
to do for the librarians.~";
Answer:
if (self has general)
"~Hey, I gotta fix these gates before going home. Go \
pester the librarians, or something.~";
if (noun=='security' or 'gates' or 'problem' ||
noun=='broken' or 'fix' or 'entrance' ||
noun=='gate' or 'tower' or 'towers') {
<>;
}
"~Yeah, sure. Whatever. Don't distract me. I have work \
to do for the librarians.~";
],
orders [;
Go: "~I wish I could leave! I have to finish this printout \
for the librarians.~";
Disable, Tie, Repair: <>;
default: "~Yeah, whatever. Leave me alone, I have work to do.~";
],
before [;
Invoke:
if (self hasnt general) {
"The technician blocks you. ~Uh-uh! Those printouts \
are for the librarians, so keep your hands off!~";
}
FixGates:
if (self has general)
"~What does it look like I'm doing?~";
Achieved(2);
move self to Lobby;
move Invective to Computer_Lab;
give Sec_Gates general;
give self general;
"The technician throws his hands up in frustration, slams \
the manual shut, tucks it under one arm and heads for the \
stairs. The air behind him positively smokes from the stream \
of invective he's producing.";
];
Object Tech_Nametag "Tom's nametag" Technician
has proper
with name "tom^s" "name" "tag" "nametag",
description "~Hi! My name is Tom.~";
Object How_To_Book "howto manual" Technician
!has general
! if the entire description has been used
with name "how-to" "howto" "how" "to" "manual" "security" "gates" "technical",
description [;
if (Technician has general)
"You can't see any such thing.";
if (self has general)
"What a complicated series of diagrams!";
give self general;
"This is a very complicated and technical manual. Hmmmm, \
maybe you'd understand it better if you had concentrated on \
hardware instead of software. Quite frankly, the circuit \
diagrams and instructions are incomprehensible. Better leave \
that sort of work to a professional!\
^^On the other hand, it would make a nice door stop.";
];
Object Invective "invective" Computer_Lab
has scenery
with name "stream" "invective",
description [;
if (Technician has general) "The air positively smokes";
"You can't see any such thing.";
],
before [;
Listen:
if (Technician has general)
"Far too technical for you to comprehend.";
"You can't see any such thing.";
];
! ----------------------------------------------------------------------------
! The Encyclopedia Frobozzica
!
! Note that this does *not* start in a room! It only becomes available after
! the player *searches* the printouts (which, of course, requires that the
! technician is not in the room).
!
! Note also that this is not the same as the Encyclopedia Frobozzica
! example on the Inform programming pages.
! ----------------------------------------------------------------------------
Object Frobozzica "printout of the Encyclopedia Frobozzica"
!has general
! if the player has found it
with name "encyclopedia" "frobozzica" "printout",
description "This is a lengthy printout of the life and times of the \
entire Zork series, cross-referenced and annotated. It appears \
to have been printed from a World-Wide Web page. There sure is \
a lot of information in it! \
^^(Unfortunately, none of it is even remotely useful to you at \
the present time.)";
! ----------------------------------------------------------------------------
! The Rare Books Room
! ----------------------------------------------------------------------------
Object Rare_Books_Room "Rare Books Room"
has light,
with name "rare books room",
description [;
Quote(1);
"The shelves are nearly bare, although there is a complete \
set of the ~New Zork Times~, a box labeled ~Avalon~, and \
several biographies of various computer game authors. The \
door out is to the north";
],
out_to S_Flr_Stacks,
n_to S_Flr_Stacks,
before [;
! The following basically gives LOOK away for free.
Look, Examine: the_time = the_time - 1;
];
Object Biographies "biographies" Rare_Books_Room
has scenery,
with name "books" "biographies" "various" "computer" "game" "authors",
description "There are half a dozen biographies of computer game \
authors, including William Gates III, who is said to have \
produced a game called, simply, ~Microsloth Windoesn't~.";
Object New_Zork_Times "new zork times" Rare_Books_Room
has scenery,
with name "new" "zork" "times",
description "Wow, a complete set!";
Object Avalon "avalon" Rare_Books_Room
has scenery,
with name "avalon",
description [;
print "Whoa, you thought this game was merely a legend, but \
here is a ";
style bold;
print "real copy";
style roman;
"!";
];
! ----------------------------------------------------------------------------
! The Book (the object of your search!)
! ----------------------------------------------------------------------------
Object book "biography of Graham Nelson" Rare_Books_Room
with name "book" "bio" "biography" "graham" "nelson" "grimoire" "text",
description "This charming little book details the life and times \
of Graham Nelson, author of ~Inform~, ~Curses~, ~Jigsaw~, \
and other fascinating IF adventures. It will be invaluable \
in saving your tail, given that you have slacked off all \
semester long!",
before [;
Take:
if (self hasnt general)
Achieved(1);
give self general;
];
! ----------------------------------------------------------------------------
! The ID Card, which begins in the player's possession (this is a convenient
! place to define it)
! ----------------------------------------------------------------------------
Object ID_Card "ID card"
with name "id" "card" "id card",
article "an",
description "This small, plastic card has all sorts of information \
about you, most of it at least half wrong, and a picture of you \
that doesn't look anything like you at all.";
! ----------------------------------------------------------------------------
! This is not the most clever way of handling this, but it does work (and it
! works nicely). The endgame should probably be handled in a subroutine of
! some sort rather than in the description of a special room. Note that this
! method (using the description) requires that look_mode be set to anything
! but SUPERBRIEF before moving the player to the room! I chose to reset
! it to VERBOSE (look_mode = 2) just before moving the player from the Lobby.
! ----------------------------------------------------------------------------
Object End_Game "End Game"
has light,
with description [;
if (book notin player) {
deadflag = 3;
"You are kicked out of the library without the needed \
biography, and so you flunk the course, drop out of college \
in disgrace, and spend the rest of your days as the peon \
who sorts the hate mail in Microsoft's mail room.\
^^Life sucks, doesn't it?";
}
deadflag = 2;
print "^^You succeed in gaining the biography, and you exit the \
library. The paper is written over the week-end, you return \
the book on Monday (of course), and you pass the class with \
flying colors (despite slacking off for the whole semester), and \
you graduate from college. \
^^Shortly thereafter, you meet an investor who loves IF, and you \
write a wildly successful game, get rich off of it, and live \
the rest of your life thanking all the IF authors of the past.";
];
! ----------------------------------------------------------------------------
! One last item -- the daemon which will announce how long until closing,
! and kick the player out if it passes 5:00 p.m.
! ----------------------------------------------------------------------------
Object Kick_Out "kick out"
with daemon [;
if (the_time == 960)
"^A voice over the PA system announces ~It is now 4:00. The \
library will be closing in one hour.~";
if (the_time == 990)
"^A voice over the PA system announces ~It is now 4:30. The \
library will be closing in half an hour.~";
if (the_time == 1005)
"^A voice over the PA system announces ~It is now 4:45. The \
library will be closing in fifteen minutes.~";
if (the_time == 1015)
"^A voice over the PA system announces ~It is now 4:55. The \
library will be closing in five minutes.~";
if (the_time == 1020) {
print "^A voice over the PA system announces ~The library \
is closing!~";
if (book in player) {
remove book;
print "^The librarian escorting you out of the library \
relieves you of the biography.^";
}
PlayerTo(End_Game);
}
];
[ DeathMessage;
if (deadflag == 3)
print "YOU HAVE LOST!";
];
[ TitlePage i;
@erase_window -1; print "^^^^^^^^^^^^^^";
i = 0->33; if (i==0) i=80; i=(i-46)/2;
style bold; font off; spaces(i);
print " ALL QUIET ON THE LIBRARY FRONT^";
style roman; print "^^"; spaces(i);
print " [Please press SPACE to begin.]^";
font on;
box "Every library should try to be complete"
"on something, if it were only the history"
"of pinheads."
""
" -- Oliver Wendell Holmes,"
" The Poet at the Breakfast-Table";
do { @read_char 1 0 0 i; } until (i==32 or 10 or 13);
@erase_window -1;
];
[ Initialise;
TitlePage();
location = Lobby;
move ID_Card to player;
! 930 = 15*60 + 30 = 15:00 = 3:00 p.m.
SetTime(900, 1);
StartDaemon(Kick_Out);
lookmode=2;
print "^You are a student at Anycollege, in Anytown, and it's \
the end of the semester! You've been slacking off all \
semester long, and it's catching up to you. \
That final paper is due for your Computer Science class \
(~The History of IF Games~), and you desperately need to \
check out a comprehensive book on Graham Nelson, one of the \
foremost authors of the obscure genre of interactive-fiction. \
You know there is exactly one such book, but you have no idea \
where it might be! \
^^The first time player should probably type ~help~.^^";
];
[ XyzzySub;
if (XYZZYUsed == 0) {
Achieved(7);
XYZZYUsed = 1;
}
"You invoke an ancient word of power, and a hollow voice whispers \
in your ear, ~Quiet, please. No talking in the library.~";
];
! ----------------------------------------------------------------------------
! Not the best set of hints in the world, but they seem to be adequate for
! most needs.
! ----------------------------------------------------------------------------
[ HintsSub;
if (R_Key hasnt general)
"It might be a good idea to find the biography and get to wherever \
it is!";
if (book hasnt general)
"Hmmmm, maybe you should find and get the book!";
if (Sec_Gates hasnt general)
"Surely there's a way to disable the gates! Uh, could you get \
someone to help you with it or to do it for you? (You never were \
that good at hardware problems!)";
if (Circ_Attendant hasnt general)
"Hmmmm, I wonder if there isn't something that could distract the \
circulation attendant.....";
if (Ref_Librarian hasnt general)
"I wonder what could possibly interest the librarian enough to get \
her to overlook your pilfering?";
"Maybe heading out of the lobby will get you away!";
];
[ InfoSub;
"ALL QUIET ON THE LIBRARY FRONT was written by Michael S. Phillips \
(mike@@64lawlib.wm.edu) for the 1995 interactive fiction \
competition. \
^^For those who are curious, LIBRARY took 5th out of 6 in the Inform \
category. \
^^The command for the hints is ~hints~.
^^From time to time, boxed quotations will be displayed. To turn these \
off, use the command ~quotes off~ (and ~quotes on~ to re-enable them, \
of course). ~Quotes~ will print out whether they are currently on or \
off.";
];
[ HelpMenu;
if (menu_item == 1) {
item_name = "Introduction (or what has gone before)";
item_width = 19;
rfalse;
}
if (menu_item == 2) {
item_name = "Release Information";
item_width = 9;
rfalse;
}
if (menu_item == 3) {
item_name = "Licensing Information";
item_width = 10;
rfalse;
}
if (menu_item == 4) {
item_name = "Credit where credit is due";
item_width = 12;
rfalse;
}
if (menu_item == 5) {
item_name = "Changes since the first release";
item_width = 15;
rfalse;
}
if (menu_item == 6) {
item_name = "About FTP.GMD.DE";
item_width = 8;
rfalse;
}
if (menu_item == 7) {
item_name = "About Inform";
item_width = 6;
rfalse;
}
if (menu_item == 8) {
item_name = "Critiques (not for the faint of heart)";
item_width = 18;
rfalse;
}
if (menu_item == 9) {
item_name = "You asked for a hint, and your hint is...";
item_width = 20;
rfalse;
}
if (menu_item == 0) {
item_name = "About this game...";
item_width = 9;
return 9;
}
! This is here to catch any additions to the menu which were not updated
! here, or any typos in the if statements.
"HELP MENU BUG: did not match title";
];
[ HelpInfo;
if (menu_item == 1) {
HelpIntroSub();
rtrue;
}
if (menu_item == 2) {
InfoSub();
rtrue;
}
if (menu_item == 3) {
HelpLicenseSub();
rtrue;
}
if (menu_item == 4) {
HelpCreditsSub();
rtrue;
}
if (menu_item == 5) {
HelpChangesSub();
rtrue;
}
if (menu_item == 6) {
HelpGMDSub();
rtrue;
}
if (menu_item == 7) {
HelpInformSub();
rtrue;
}
if (menu_item == 8) {
HelpCommentsSub();
rtrue;
}
if (menu_item == 9) {
HintsSub();
rtrue;
}
! This is here to catch any additions to the menu or typos which may
! not have a match.
"HELP MENU BUG! Did not match up function call.";
];
[ HelpMenuSub;
DoMenu("The LIBRARY help menu:^\
^ Introduction (the story so far...)\
^ Information about the game\
^ License\
^ Credits\
^ Changes\
^ About ftp.gmd.de\
^ About Inform\
^ Post-contest comments on the game\
^ Need a hint?^",
#r$HelpMenu, #r$HelpInfo);
];
[ HelpLicenseSub;
"This game is (c) 1995 Michael S. Phillips. It may be freely distributed \
electronically, provided it remains unmodified (in other words, it can be \
uuencoded, MIME-encoded, etc., but not hacked up and re-distributed). \
^^It was written for the 1995 interactive fiction competition using \
Inform, the free Z-Machine game compiler written by Graham Nelson and \
available, along with various higher-quality games (many referenced \
herein), at ftp.gmd.de. \
^^Though it uses the Infocom Z-Machine file format, no code is derived \
from Infocom sources.";
];
[ HelpIntroSub;
"The Computer Science class on Interactive Fiction (CS 441) sounded \
really interesting when you signed up for it. Of course, with all the \
IF games to play, you slacked off all semester, and here it is, finals \
time, and you're in trouble. \
^^However, to get yourself out of the hole you dug for yourself, the \
professor has stated that an in-depth paper studying Graham Nelson \
(author of the Inform compiler, used in the course) will get you a \
passing grade. \
^^You know there's a biography on him somewhere in the pitiful library \
this university has, but you've never set foot in the library before! \
So, all you have to do is find this book and get out the door with it. \
The professor was kind enough to point out that the book is \
non-circulating, which means you can't check it out. \
^^Oh yes, due to budget constraints, the library is no longer open on \
week-ends, and it's Friday afternoon. The library closes at 5:00 p.m., \
and the paper is due Monday morning at 8:00 a.m.
^^This game defaults to ~Verbose~ mode. To return to normal game play, \
use the command ~Brief~.";
];
[ HelpInformSub;
"Inform is written and maintained by Graham Nelson, who is also the \
author of ~Curses~, ~Balances~, and ~Jigsaw~. The current version (as \
of this writing) is Inform 5.5, with library 5/12, which were used to \
compile this game. \
^^Inform takes the source file(s) and generates a machine-independent \
Z-code file, which may be run on any of several Z-machine interpreters. \
The Z-machine format was invented and first used by Infocom. \
^^Inform is available from ftp.gmd.de, in the directory \
/if-archive/infocom/compilers/inform. Documentation, a number of \
example games and pre-compiled binaries of inform are available.";
];
[ HelpGMDSub;
"The big repository of Interactive Fiction on the Internet is ftp.gmd.de, \
which is probably where this game was found. Check out \
/if-archive/competition for the other competition game files, and \
/if-archive/games/infocom for the Inform-based games such as ~Curses~, \
~Theatre~, ~Jigsaw~, ~Christminster~, ~Balances~, ~Paperchase~, ~Busted~ \
and others.\
^^Also look in /if-archive/infocom/compilers/inform for information \
about Inform, the free Infocom Z-Machine game compiler.";
];
[ HelpCreditsSub;
"This vignette was written by Michael S. Phillips, based (extremely) \
loosely on the library in which he works. The author may be reached at \
mike@@64lawlib.wm.edu, or, if that mail inexplicably bounces, at \
msphil@@64facstaff.wm.edu.\
^^He would like to express thanks to Gareth Rees for his excellent \
tutorial and programming page (check it out at \
http://www.cl.cam.ac.uk/users/gdr11/inform/) and to Graham Nelson for \
Inform, ~Curses~, ~Jigsaw~, and a few kind words, and all the folks on \
rec.arts.int-fiction and rec.games.int-fiction for rekindling his \
interest in interactive fiction (not to mention their insightful \
commentary). \
^^Special thanks go to Ryan Ambrose, Kathryn Phillips, John Burnham, and \
J. C. Thieme for play-testing, and to Thorsten Franz, Fred Sloniker, \
Carrie Fabbro-Davisson, and Matthew McDonald for their ideas and comments \
(without which there would not have been a Release 2), and to Michael \
Kinyon and Palmer Davis for additional testing of Release 2. \
^^Very special thanks to Margot Koval for suggestions, assistance, and \
the assurance that she had fun playing the game.\
^^Oh yes, and Gerry Kevin Wilson, for running the competition and for \
not getting mad about the use of Avalon in this game :-)";
];
[ HelpChangesSub;
"Changes in LIBRARY:
^^Release 2:\
^ added: photocopier room, Technical Services, tasks (for \
FULL SCORE), boxed quotations (plus related verbs), credits for those \
who helped, suggested, and playtested; \
^ changed: picture in ground floor stairwell, help system into a menu, \
new and improved descriptions and NPC reactions, internal improvements\
^^Release 1: First release, for the 1995 Interactive Fiction contest";
];
[ HelpCommentsSub;
"Some reactions from the world of rec.arts.int-fiction:\
^^~Solidly put together, but never manages to get past its rather \
pedestrian premise.~^ -- P----- D----\
^^~Two thumbs down.~^ -- S----- & E----\
^^~I wasn't able to solve it. Felt vaguely skimpy.~^ -- A----- \
P------\
^^~I wasn't either...Also, I wasn't very engaged by the atmosphere or \
story...I realize that it was a first effort, and I strongly encourage \
the author to keep it up.~^ -- M------ K-----\
^^~Weird, I found this way too easy...~^ -- T----- B-----\
^^~Ok, for Toonesia, you either get the setting or you don't. Library \
at least gives you a clue.~^ -- J---- C------\
^^~Heh heh heh... this game sucked...~^ B-----\
^^~Huh huh... he said 'sucked'...~^ B-------\
^^~LIBRARY...never really drew me in.~^ -- N--- d-M----\
^^~I imagine Graham [Nelson] feels embarrassed rather than pleased; I \
know I would.~^ -- G----- R---\
^^~Library: This, like museum and The One, suffer from an ameturish feel \
to them...The characters were all one-dimensional, and the plot and \
problems are reletivly simplistic. On the plus sides...the game worked \
well (no bugs) and on the whole was believable.~^ -- E- H----";
];
[ BadHelpSub;
"I didn't understand that request for help. The words known to the help \
subsystem are: author, changes, comments, ftp, inform, intro, and \
license.";
];
[ DisableSub;
"You're not sure how to do that.";
];
[ RepairSub;
"You're not sure how to do that.";
];
[ QuotesOnSub;
if (quotes_on==1)
"Quotes are already enabled.";
quotes_on = 1;
"Quotes are now enabled.";
];
[ QuotesOffSub;
if (quotes_on==0)
"Quotes are already disabled.";
quotes_on = 0;
"Quotes are now disabled.";
];
[ QuotesCheckSub;
print "Quotes are currently ";
if (quotes_on==0) {
print "disabled"
} else print "enabled";
".";
];
! Fix for ITF's 'Bad optional num'? NO!
[ ParseNoun x y;
x=x; y=y; return -1;
];
Include "Grammar";
Verb "xyzzy"
* -> Xyzzy;
Verb "hint" "hints"
* -> Hints;
Verb "info"
* -> Info;
Verb "help"
* -> HelpMenu
* "xxx" -> Info
* "license" -> HelpLicense
* "licence" -> HelpLicense
* "intro" -> HelpIntro
* "introduction" -> HelpIntro
* "author" -> HelpCredits
* "credits" -> HelpCredits
* "ftp" -> HelpGMD
* "gmd" -> HelpGMD
* "ftp.gmd.de" -> HelpGMD
* "inform" -> HelpInform
* "changes" -> HelpChanges
* "comments" -> HelpComments
* "quotes" -> HelpComments
* special -> BadHelp;
Verb "disable"
* noun -> Disable;
Verb "repair"
* noun -> Repair;
Verb "quotes"
* "on" -> QuotesOn
* "off" -> QuotesOff
* -> QuotesCheck;
end;