aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhistoricalsource <historicalsoftware@textfiles.com>2019-04-14 01:53:40 -0400
committerhistoricalsource <historicalsoftware@textfiles.com>2019-04-14 01:53:40 -0400
commit7edaa119516a4de4e5d253708d1cb0f3e8a2aa25 (patch)
tree0a485af279c382e097d2771aa5bf1f54bea4cc3d
downloadlurkinghorror-7edaa119516a4de4e5d253708d1cb0f3e8a2aa25.tar.gz
lurkinghorror-7edaa119516a4de4e5d253708d1cb0f3e8a2aa25.tar.bz2
lurkinghorror-7edaa119516a4de4e5d253708d1cb0f3e8a2aa25.zip
Revision 203 (Original Source)
-rw-r--r--README.md1
-rw-r--r--cs.zil7087
-rw-r--r--debug.zil35
-rw-r--r--desc.zil295
-rw-r--r--frob.zil1663
-rw-r--r--globals.zil650
-rw-r--r--green.zil659
-rw-r--r--h1.zil35
-rw-r--r--h1.zipbin0 -> 128986 bytes
-rw-r--r--h1freq.xzap200
-rw-r--r--hacker.zil950
-rw-r--r--interrupts.zil27
-rw-r--r--misc.zil917
-rw-r--r--parser.zil1793
-rw-r--r--pc.zil529
-rw-r--r--record.zil30
-rw-r--r--syntax.zil737
-rw-r--r--verbs.zil2216
-rw-r--r--yuggoth.zil302
19 files changed, 18126 insertions, 0 deletions
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..4cdd04e
--- /dev/null
+++ b/README.md
@@ -0,0 +1 @@
+# lurkinghorror
diff --git a/cs.zil b/cs.zil
new file mode 100644
index 0000000..0d4c058
--- /dev/null
+++ b/cs.zil
@@ -0,0 +1,7087 @@
+"CS for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+"Computer Center: three floors plus basement and roof. has a computer
+ room, a terminal room, an elevator, etc."
+
+<OBJECT OFFICE-DOOR
+ (IN LOCAL-GLOBALS)
+ (SYNONYM OFFICE DOOR DOORS)
+ (ADJECTIVE CLOSED DARK LOCKED)
+ (DESC "office")
+ (FLAGS NDESCBIT DOORBIT OPENABLE)
+ (GENERIC GENERIC-DOOR-F)
+ (ACTION OFFICE-DOOR-F)>
+
+<ROUTINE OFFICE-DOOR-F ()
+ <TELL "The offices are inaccessible." CR>>
+
+<ROUTINE GENERIC-DOOR-F ()
+ <COND (<HERE? ,CHEMISTRY-BLDG>
+ ,ALCHEMY-DOOR)
+ (<HERE? ,INF-1 ,INF-3>
+ ,OUTSIDE-DOOR)>>
+
+<ROOM SMITH-ST
+ (IN ROOMS)
+ (DESC "Smith Street")
+ (SOUTH TO COMP-CENTER)
+ (IN TO COMP-CENTER)
+ (WEST "Impenetrable snow drifts block the street.")
+ (EAST TO SMITH-ST-2)
+ (GLOBAL OUTSIDE-DOOR)
+ (ACTION SMITH-ST-F)
+ (FLAGS ONBIT OUTSIDE)>
+
+<ROUTINE SMITH-ST-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+'SMITH-ST " runs east and west along the north side of the main campus
+area. At the moment, it is an arctic wasteland of howling wind and
+drifting snow. On the other side of the street, barely visible, are
+the lidless eyes of streetlights. The street hasn't been plowed, or
+if it has been, it did no good." CR>)
+ (<AND <RARG? ENTER>
+ <NOT <EQUAL? ,OHERE ,SMITH-ST-2>>>
+ <EXIT-TO-COLD>)>>
+
+<ROOM SMITH-ST-2
+ (IN ROOMS)
+ (DESC "Smith Street")
+ (SOUTH TO TEMPORARY-LAB)
+ (IN TO TEMPORARY-LAB)
+ (WEST TO SMITH-ST)
+ (EAST "Impenetrable snow drifts block the street.")
+ (GLOBAL OUTSIDE-DOOR)
+ (ACTION SMITH-ST-2-F)
+ (FLAGS ONBIT OUTSIDE)>
+
+<ROUTINE SMITH-ST-2-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+'SMITH-ST " runs west towards the computer center here. To the south is
+a dilapidated grey wooden building. The street is an impassable sea of
+blowing and drifting snow." CR>)
+ (<RARG? ENTER>
+ <COND (<EQUAL? ,OHERE ,TEMPORARY-LAB>
+ <EXIT-TO-COLD>)>)>>
+
+<GLOBAL FREEZE-COUNT 0>
+
+<GLOBAL FREEZING
+ <LTABLE (PURE)
+"Bitter, bone-cracking cold assaults you continuously. The
+temperature and the blizzard conditions are both horrible."
+"You can feel the cold worming its way through your layers of
+clothing and biting into your flesh."
+"You can no longer feel the tips of your fingers. As for your toes,
+they have long since ceased to report."
+"Your eyes are icing up."
+"Each breath you take is like swallowing knives.">>
+
+<ROUTINE I-FREEZE-TO-DEATH ()
+ <COND (<NOT <FSET? ,HERE ,OUTSIDE>>
+ <RFALSE>)
+ (<G? <SETG FREEZE-COUNT <+ ,FREEZE-COUNT 1>> 5>
+ <CRLF>
+ <JIGS-UP
+"You are suffused with a warm, blissful numbness. It is marred only by
+the knowledge that before you wake again, you will die.">)
+ (ELSE
+ <QUEUE I-FREEZE-TO-DEATH 4>
+ <TELL CR <GET ,FREEZING ,FREEZE-COUNT> CR>)>>
+
+<ROUTINE CS-BEGS ()
+ <COND (<AND <VERB? WALK>
+ <AND <NOT <EQUAL? ,P-WALK-DIR ,P?SOUTH>>
+ <OR <NOT <HERE? ,CS-BASEMENT>>
+ <NOT <EQUAL? ,P-WALK-DIR ,P?DOWN ,P?IN>>>>>
+ <MOVE-FROM-DOORS>)
+ (<P? ENTER <>>
+ <NEW-PRSO ,ELEVATOR>
+ <RTRUE>)>>
+
+<ROOM COMP-CENTER
+ (IN ROOMS)
+ (DESC "Computer Center")
+ (NORTH TO SMITH-ST)
+ (IN PER CS-ELEVATOR-ENTER)
+ (SOUTH PER CS-ELEVATOR-ENTER)
+ (UP TO CS-2ND)
+ (DOWN TO CS-BASEMENT)
+ (FLOOR 1)
+ (FLAGS ONBIT)
+ (GLOBAL ELEVATOR ;ELEVATOR-DOOR-1 UP-BUTTON DOWN-BUTTON)
+ (ACTION COMP-CENTER-F)>
+
+<ROUTINE COMP-CENTER-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+,THE-LOBBY 'COMP-CENTER ". ">
+ <ELEVATOR-AND-BUTTONS>
+ <TELL "to the south.">
+ <DESCRIBE-STAIRS>
+ <TELL
+S "To the north is " 'SMITH-ST "." CR>)
+ (<RARG? BEG>
+ <CS-BEGS>)
+ (<RARG? ENTER>
+ <EXIT-FROM-COLD>)>>
+
+<ROOM CS-2ND
+ (IN ROOMS)
+ (DESC "Second Floor")
+ (NORTH TO TERMINAL-ROOM)
+ (WEST TO KITCHEN)
+ (SOUTH PER CS-ELEVATOR-ENTER)
+ (IN PER CS-ELEVATOR-ENTER)
+ (UP TO CS-3RD)
+ (DOWN TO COMP-CENTER)
+ (FLOOR 2)
+ (FLAGS ONBIT)
+ (GLOBAL ELEVATOR ;ELEVATOR-DOOR-2 UP-BUTTON DOWN-BUTTON)
+ (ACTION CS-2ND-F)>
+
+<ROUTINE DESCRIBE-ELEVATOR-AND-BUTTONS ()
+ <TELL
+" floor of the " 'COMP-CENTER ". ">
+ <ELEVATOR-AND-BUTTONS>
+ <TELL "on the south side of the hallway.">>
+
+<ROUTINE ELEVATOR-AND-BUTTONS ()
+ <TELL "An elevator and call button">
+ <COND (<NOT <HERE? CS-3RD CS-BASEMENT>> <TELL "s">)>
+ <TELL " are ">>
+
+<ROUTINE CS-2ND-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"This is the second">
+ <DESCRIBE-ELEVATOR-AND-BUTTONS>
+ <TELL " A large, noisy room is to the north.">
+ <DESCRIBE-STAIRS>
+ <TELL
+"To the west
+a corridor leads into a smaller room." CR>)
+ (<RARG? BEG>
+ <CS-BEGS>)>>
+
+<ROOM CS-3RD
+ (IN ROOMS)
+ (DESC "Third Floor")
+ (NORTH "There is a glass wall in the way.")
+ (IN PER CS-ELEVATOR-ENTER)
+ (SOUTH PER CS-ELEVATOR-ENTER)
+ (UP TO CS-ROOF)
+ (OUT TO CS-ROOF)
+ (DOWN TO CS-2ND)
+ (FLOOR 3)
+ (FLAGS ONBIT)
+ (GLOBAL ELEVATOR DOWN-BUTTON OUTSIDE-DOOR)
+ (ACTION CS-3RD-F)
+ (THINGS
+ <PSEUDO (COMPUTER EQUIPMENT RANDOM-PSEUDO)
+ (<> COMPUTER RANDOM-PSEUDO)
+ (<> GLASS RANDOM-PSEUDO)
+ (GLASS WALL RANDOM-PSEUDO)
+ (GLASS WINDOW RANDOM-PSEUDO)>)>
+
+<ROUTINE CS-3RD-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"This is the third">
+ <DESCRIBE-ELEVATOR-AND-BUTTONS>
+ <DESCRIBE-STAIRS>
+ <TELL
+S "To the north is ""a glass wall beyond which
+you can see a computer room crammed with computer equipment. A stairway
+leads up." CR>)
+ (<RARG? BEG>
+ <CS-BEGS>)>>
+
+<ROOM CS-ROOF
+ (IN ROOMS)
+ (DESC "Roof")
+ (DOWN TO CS-3RD)
+ (IN TO CS-3RD)
+ (GLOBAL OUTSIDE-DOOR)
+ (ACTION CS-ROOF-F)
+ (FLAGS ONBIT OUTSIDE)>
+
+<ROUTINE CS-ROOF-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"This is the roof of the " 'COMP-CENTER ". A door leads to the stairway.
+The roof is covered with tarred pea gravel and drifted snow. The wind
+howls around your ears. To the south and southeast you can dimly see the
+looming shapes of the Great Dome and the Brown Building." CR>)
+ (<RARG? BEG>
+ <ROOF-BEGS>)
+ (<RARG? ENTER>
+ <TELL "You push through the door to the roof. ">
+ <EXIT-TO-COLD>)
+ (<RARG? LEAVE>
+ <EXIT-FROM-COLD>)>>
+
+<ROOM TERMINAL-ROOM
+ (IN ROOMS)
+ (DESC "Terminal Room")
+ (LDESC
+"This is a large room crammed with computer terminals, small
+computers, and printers. An exit leads south. Banners, posters, and
+signs festoon the walls. Most of the tables are covered with waste
+paper, old pizza boxes, and empty Coke cans. There are usually a lot of
+people here, but tonight it's almost deserted.")
+ (SOUTH PER HACKER-EXIT) ;CS-2ND
+ (OUT PER HACKER-EXIT) ;CS-2ND
+ (ACTION TERMINAL-ROOM-F)
+ (GLOBAL PROGRAM OUTLET)
+ (FLAGS ONBIT)
+ (THINGS <PSEUDO (<> BANNER RANDOM-PSEUDO)
+ (<> POSTER RANDOM-PSEUDO)
+ (<> SIGN RANDOM-PSEUDO)
+ (<> SIGNS RANDOM-PSEUDO)>)>
+
+<ROUTINE HACKER-EXIT ()
+ <COND (<OR <HELD? ,PC> <HELD? ,CHAIR>>
+ <TELL
+,HACKER-PREVENTS ,YOU-CANT "walk off with that!
+It's Tech property!\"" CR>
+ <RFALSE>)
+ (ELSE ,CS-2ND)>>
+
+<ROUTINE TERMINAL-ROOM-F (RARG)
+ <COND ;(<RARG? LOOK>
+ <TELL
+ CR>)
+ (<RARG? BEG>
+ <COND (<AND <NOT <VERB? TELL>> <GAME-VERB?>>
+ <RFALSE>)
+ (<QUEUED? I-HACKER-HELPS>
+ <COND (<P? (RUB POINT CLICK HELP)
+ (MENU-BOX MORE-BOX <>)>
+ <TELL
+,HACKER-PREVENTS "Who's the hacker here?\" he snarls." CR>)>)
+ (<QUEUED? I-COMPULSION>
+ <COND (<P? (RUB POINT CLICK PUSH ATTACK) MORE-BOX>
+ <RFALSE>)
+ (<P? READ ,ODD-PAPER>
+ <RFALSE>)
+ (ELSE
+ <COND (<VERB? TELL HELLO>
+ <TELL
+"Your throat tightens, and no sound issues forth. ">)
+ (<VERB? INVENTORY LAMP-OFF>
+ <TELL
+"Your body refuses to obey your brain's command. ">)>
+ <TELL
+"Instead, you find your finger moving towards the MORE box, and you touch
+it. The screen feels oddly cold." CR>
+ <COND (<VERB? TELL>
+ <END-QUOTE>)
+ (ELSE <RTRUE>)>)>)>)
+ (<AND <RARG? ENTER>
+ <EQUAL? ,OHERE ,PLATFORM-ROOM>>
+ <QUEUE I-HACKER-HELPS -1>
+ <TELL
+"You are awakened by the thump of your head hitting the terminal
+in front of you. Falling asleep over term papers! It must have been a
+nightmare. Embarrassed, you glance around. Yes, the hacker is looking
+in your direction. He must have heard the thump." CR CR>)>>
+
+<GLOBAL HACKER-HELP 0>
+
+<ROUTINE I-HACKER-HELPS ()
+ <COND (<HERE? ,TERMINAL-ROOM>
+ <SETG HACKER-HELP <+ ,HACKER-HELP 1>>
+ <CRLF>
+ <COND (<EQUAL? ,HACKER-HELP 1>
+ <TELL
+S "The hacker wanders ""over, trying to look nonchalant">
+ <COND (<IN? ,PLAYER ,CHAIR>
+ <MOVE ,PLAYER ,HERE>
+ <FCLEAR ,HACKER ,CONTBIT>
+ <MOVE ,HACKER ,CHAIR>
+ <TELL
+" as he takes over your chair">)>
+ <TELL ". \"Losing,
+huh?\" he asks wittily. He ">
+ <COND (<FSET? ,PC ,POWERBIT>
+ <TELL "glances at">)
+ (ELSE
+ <TELL "turns on">)>
+ <TELL
+" your terminal, which displays a pattern of snow and unusual characters.
+He appears somewhat excited." CR>)
+ (<EQUAL? ,HACKER-HELP 2>
+ <TELL
+"The hacker, mumbling under his breath,
+begins a flurry of activity. First the screen returns to something
+nearly normal, then windows begin popping up like toadstools after a
+rain. The screen looks a lot like the top of his terminal table (or the
+bottom of a trash can)." CR>)
+ (<EQUAL? ,HACKER-HELP 3>
+ <TELL
+"The hacker types furiously, and the screen displays what to you looks
+like an explosion in a teletype factory. After a while he says. \"Chomping
+file system. Your directory has gone seriously west. I fixed it.\" He
+checks the screen. \"It was mixed up on the file server with some files
+from the Department of
+Alchemy.\" He grunts. \"People's names for their nodes are getting
+weird. This one is called 'Lovecraft.'\" He pauses. \"Your paper is gone,
+though. Sorry. Maybe they could help you down there.\"" CR>)
+ (ELSE
+ <MOVE ,HACKER ,TERMINAL-ROOM>
+ <FSET ,HACKER ,CONTBIT>
+ <DEQUEUE I-HACKER-HELPS>
+ <TELL
+S "The hacker wanders " "back to his terminal and returns to
+his hacking." CR>)>)
+ (ELSE <DEQUEUE I-HACKER-HELPS>)>>
+
+<ROOM CS-BASEMENT
+ (IN ROOMS)
+ (DESC "Basement")
+ (UP TO COMP-CENTER)
+ (SOUTH PER CS-ELEVATOR-ENTER)
+ (IN PER CS-ELEVATOR-ENTER)
+ (EAST TO TEMPORARY-BASEMENT)
+ (WEST TO AERO-BASEMENT)
+ (DOWN PER CS-PIT-ENTER)
+ (FLOOR 0)
+ (FLAGS ONBIT)
+ (GLOBAL ELEVATOR ELEVATOR-DOOR-B UP-BUTTON CABLE STEAM-PIPES)
+ (ACTION CS-BASEMENT-F)>
+
+<ROUTINE CS-PIT-ENTER ()
+ <COND (<WINNER? ,URCHIN> <RFALSE>)
+ (<AND <FSET? ,ELEVATOR-DOOR-B ,OPENBIT>
+ <NOT <ZERO? ,ELEVATOR-LOC>>>
+ <TELL
+"You drop to the floor below, which isn't all that far down.">
+ <COND (,HOLDING-DOORS?
+ <SETG HOLDING-DOORS? <>>
+ <FCLEAR ,ELEVATOR-DOOR-B ,OPENBIT>
+ <ELEVATOR-WANTED?>
+ <TELL
+" The doors shut as soon as you release them">
+ <IN-DARK?>)
+ (ELSE <CRLF>)>
+ <CRLF>
+ ,ELEVATOR-PIT)
+ (ELSE
+ <CANT-GO>
+ <RFALSE>)>>
+
+<ROUTINE CS-BASEMENT-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"Bare concrete walls line a wide corridor leading east and west. ">
+ <ELEVATOR-AND-BUTTONS>
+ <TELL "to the south.">
+ <DESCRIBE-STAIRS>
+ <TELL S
+"From floor to ceiling run wire channels and steam pipes.|">)
+ (<RARG? BEG>
+ <CS-BEGS>)>>
+
+<ROOM TEMPORARY-BASEMENT
+ (IN ROOMS)
+ (DESC "Temporary Basement")
+ (LDESC
+"During the Second World War, some temporary buildings were built to house
+war-related research. Naturally, these buildings, though flimsy and ugly,
+are still around. This is the basement of one of them. The basement
+extends west, a stairway leads up, and a large passage is to the east.")
+ (WEST TO CS-BASEMENT)
+ (EAST TO DEAD-STORAGE)
+ (UP TO TEMPORARY-LAB)
+ (FLAGS ONBIT)>
+
+<ROOM DEAD-STORAGE
+ (IN ROOMS)
+ (DESC "Dead Storage")
+ (WEST TO TEMPORARY-BASEMENT)
+ (EAST PER STORAGE-EXIT)
+ (IN PER STORAGE-EXIT)
+ (GLOBAL JUNK)
+ (ACTION DEAD-STORAGE-F)>
+
+<ROUTINE DEAD-STORAGE-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"This is a storage room. It contains an incredible assemblage of discarded
+junk. Some of it is so old and mouldering that you can't be sure where one
+bit of junk stops and the next begins. It's piled to the ceiling on
+ancient, rotting pallets">
+ <COND (<L? ,JUNK-MOVED? ,JUNK-MOVES-NEEDED>
+ <TELL
+"; you can't even see the east wall.">)
+ (ELSE
+ <TELL
+". A narrow path winds eastward through the junk.">)>
+ <CRLF>)
+ (<RARG? BEG>
+ <COND (<P? THROUGH ROOMS>
+ <DO-WALK ,P?EAST>)
+ (<P? MOVE CORRIDOR>
+ <NEW-PRSO ,JUNK>
+ <RTRUE>)>)>>
+
+<GLOBAL JUNK-MOVED? <>>
+<CONSTANT JUNK-MOVES-NEEDED 3>
+
+<ROUTINE STORAGE-EXIT ()
+ <COND (<WINNER? ,URCHIN> <RFALSE>)
+ (<G? ,JUNK-MOVED? ,JUNK-MOVES-NEEDED> ,STORAGE-ROOM)
+ (,JUNK-MOVED?
+ <TELL
+"There is still no path all the way through the junk, but you can now
+tell for sure that there's a room to the east." CR>
+ <RFALSE>)
+ (ELSE
+ <TELL
+"You climb around on the junk for a while, and you get the impression that
+there is an opening 'way on the east wall, but there is so much stuff in
+the way that you can't get to it." CR>
+ <RFALSE>)>>
+
+<OBJECT JUNK
+ (IN LOCAL-GLOBALS)
+ (DESC "junk")
+ (SYNONYM JUNK DEBRIS PALLET PILE)
+ (ADJECTIVE MOULDERING OLD PILE)
+ (FLAGS NDESCBIT NOABIT)
+ (ACTION JUNK-F)>
+
+<ROUTINE JUNK-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"Looking more closely only emphasizes how completely entropy has taken
+over this room." CR>)
+ (<VERB? MOVE PRY>
+ <TELL
+"You have obviously underestimated the amount of junk in here. It's
+not only voluminous, it's heavy." CR>)
+ (<VERB? SEARCH>
+ <TELL
+"You find many worthless items of hardware, old discarded memos and
+papers, but nothing of any use or value." CR>)>>
+
+<OBJECT FORKLIFT
+ (IN AERO-BASEMENT)
+ (DESC "forklift")
+ (SYNONYM FORKLIFT LIFT)
+ (ADJECTIVE FORK)
+ (FLAGS VEHBIT SURFACEBIT OPENBIT CONTBIT SEARCHBIT)
+ (ACTION FORKLIFT-F)>
+
+<GLOBAL FORKLIFT-WONT-FIT "The forklift won't fit into the ">
+
+<GLOBAL A-DEAD-FORKLIFT " a forklift that isn't running.">
+
+<ROUTINE FORKLIFT-F ("OPT" (RARG <>) "AUX" O)
+ <COND (<RARG? BEG>
+ <COND (<P? OPEN MANHOLE-COVER FORKLIFT>
+ <RFALSE>)
+ (<AND <VERB? LEAP BOARD MUNG>
+ ,PRSO
+ <NOT <IN? ,PRSO ,FORKLIFT>>
+ <NOT <PRSO? ,FORKLIFT>>>
+ <PERFORM ,V?DRIVE-ON ,FORKLIFT ,PRSO>
+ <RTRUE>)
+ (<VERB? DRIVE-ON DRIVE-TO> <RFALSE>)
+ (<P? THROUGH JUNK>
+ <TELL
+"The forklift isn't that powerful." CR>)
+ (<VERB? WALK>
+ <COND (<EQUAL? ,P-WALK-DIR ,P?DOWN>
+ <PERFORM ,V?DISEMBARK>
+ <RTRUE>)
+ (<NOT <FSET? ,FORKLIFT ,POWERBIT>>
+ <TELL
+,YOU-CANT "go anywhere in" ,A-DEAD-FORKLIFT CR>)
+ (<AND <IN? ,FORKLIFT ,DEAD-STORAGE>
+ <EQUAL? ,P-WALK-DIR ,P?EAST>>
+ <COND (<G? ,JUNK-MOVED? ,JUNK-MOVES-NEEDED>
+ <GOTO ,STORAGE-ROOM>)
+ (<NOT ,JUNK-MOVED?>
+ <TELL
+"There is no path through the junk for you, much less for a forklift." CR>)
+ (ELSE
+ <TELL
+,YOU-HAVE-TO "move some more junk first, I'm afraid." CR>)>)
+ (<OR <AND <IN? ,FORKLIFT ,AERO-BASEMENT>
+ <EQUAL? ,P-WALK-DIR ,P?WEST ,P?UP>>
+ <AND <IN? ,FORKLIFT ,TEMPORARY-BASEMENT>
+ <EQUAL? ,P-WALK-DIR ,P?UP>>>
+ <TELL
+,FORKLIFT-WONT-FIT "stairwell." CR>)
+ (<IN? ,FORKLIFT ,CS-BASEMENT>
+ <COND (<AND <EQUAL? ,P-WALK-DIR
+ ,P?SOUTH ,P?IN ,P?DOWN>
+ <FSET? ,ELEVATOR-DOOR-B ,OPENBIT>>
+ <TELL ,FORKLIFT-WONT-FIT>
+ <COND (<ELEVATOR-HERE?>
+ <TELL "elevator." CR>)
+ (ELSE <TELL "shaft." CR>)>)
+ (<EQUAL? ,P-WALK-DIR ,P?UP>
+ <TELL
+,FORKLIFT-WONT-FIT "stairwell." CR>)>)>)
+ (<P? LAMP-ON FORKLIFT>
+ <COND (<NOT <FSET? ,PRSO ,POWERBIT>>
+ <FSET ,FORKLIFT ,POWERBIT>
+ <TELL
+"The forklift sputters to life." CR>)
+ (ELSE
+ <TELL "It's wheezing away already." CR>)>)
+ (<P? (LAMP-OFF STOP) FORKLIFT>
+ <COND (<FSET? ,PRSO ,POWERBIT>
+ <FCLEAR ,FORKLIFT ,POWERBIT>
+ <TELL
+"The forklift coughs once, and dies." CR>)
+ (ELSE
+ <ITS-ALREADY-X "off">)>)
+ (<OR <P? MOVE>
+ <P? PRY * FORKLIFT>>
+ <COND (<NOT ,LIT>
+ <TELL ,TOO-DARK>)
+ (<NOT <FSET? ,FORKLIFT ,POWERBIT>>
+ <TELL
+,YOU-CANT "move anything with" ,A-DEAD-FORKLIFT CR>)
+ (<PRSO? ,JUNK>
+ <COND (<HERE? ,STORAGE-ROOM>
+ <TELL
+S "There's nothing ""on pallets here, hence the forklift is useless." CR>)
+ (<NOT ,JUNK-MOVED?>
+ <SETG JUNK-MOVED? 1>
+ <TELL
+"You have a little trouble using the forklift, but it's not really all
+that hard. You start clearing junk, moving it around and trying to
+create a passage." CR>
+ <RTRUE>)
+ (<G? <SETG JUNK-MOVED? <+ ,JUNK-MOVED? 1>>
+ ,JUNK-MOVES-NEEDED>
+ <COND (<G? ,JUNK-MOVED?
+ <+ ,JUNK-MOVES-NEEDED 1>>
+ <TELL
+"I suppose you're planning to clear the entire room? You've made a nice
+path to the next room already." CR>)
+ (ELSE
+ <TELL
+"You've built a fairly narrow (about one forklift wide) path through the
+junk. You can see an opening into a further storage room beyond this
+one." CR>)>)
+ (ELSE
+ <TELL
+"You continue moving junk, becoming more proficient with the forklift." CR>)>)
+ (ELSE
+ <TELL
+"The forklift is ineffective in manipulating " THE ,PRSO ,PERIOD>)>)
+ (<SET O <NOT-REACHABLE?>>
+ <CANT-REACH-FROM-VEHICLE .O>)>)
+ (<RARG? <>>
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This is a rusty ">
+ <COND (<FSET? ,FORKLIFT ,POWERBIT>
+ <TELL "and wheezing ">)>
+ <TELL "old forklift. It looks like you could
+control it fairly easily, though." CR>)
+ (<VERB? LAMP-ON LAMP-OFF STOP>
+ <TELL
+,YOU-HAVE-TO "get in it first." CR>)
+ (<P? (MOVE PRY) JUNK FORKLIFT>
+ <TELL
+"You're trying to operate the forklift by telepathy?" CR>)>)>>
+
+<ROOM STORAGE-ROOM
+ (IN ROOMS)
+ (DESC "Ancient Storage")
+ (LDESC
+"What's deader than dead storage? That's what's in this room. Most of the
+contents have collapsed or rusted back to the primordial ooze. There is
+mold growing on some of the unidentifiable piles. Stagnant
+puddles of water pollute the floor. You can now believe how old some of these
+foundations are said to be.")
+ (WEST TO DEAD-STORAGE)
+ (DOWN PER MANHOLE-EXIT)
+ (VALUE 5)
+ (GLOBAL JUNK POOL)
+ (ACTION STORAGE-ROOM-F)>
+
+<ROUTINE STORAGE-ROOM-F (RARG)
+ <COND (<RARG? ENTER>
+ <FCLEAR ,MANHOLE ,NDESCBIT>
+ <MOVE ,MANHOLE ,HERE>)>>
+
+<ROUTINE MANHOLE-EXIT ()
+ <COND (<NOT <IN? ,MANHOLE-COVER ,MANHOLE>>
+ <SETG SCORE <+ ,SCORE ,MANHOLE-SCORE>>
+ <SETG MANHOLE-SCORE 0>
+ ,BRICK-TUNNEL)
+ (ELSE
+ <COND (<WINNER? ,PLAYER>
+ <TELL
+S "There is a ""steel cover on the manhole." CR>)>
+ <RFALSE>)>>
+
+<OBJECT MANHOLE
+ (IN STORAGE-ROOM)
+ (DESC "manhole")
+ (SYNONYM MANHOLE HOLE RING)
+ (ADJECTIVE MAN STEEL)
+ (FLAGS OPENBIT CONTBIT SEARCHBIT RMUNGBIT DOORBIT)
+ (CAPACITY 200)
+ (DESCFCN MANHOLE-DESC)
+ (ACTION MANHOLE-F)>
+
+<ROUTINE MANHOLE-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <COND (<IN? ,MANHOLE-COVER ,MANHOLE>
+ <TELL
+S "There is a ""closed, disused-looking manhole here.">)
+ (ELSE
+ <TELL
+S "There is an open ""manhole here.">)>
+ <RFATAL>)>>
+
+<ROUTINE MANHOLE-F ()
+ <COND (<VERB? EXAMINE>
+ <COND (<NOT <IN? ,MANHOLE-COVER ,MANHOLE>>
+ <TELL
+"It's a manhole.">
+ <COND (<HERE? ,STORAGE-ROOM>
+ <TELL
+" It's very dark inside, but you can see that crude
+brick handholds provide a slippery path down. Cool air rises out of
+the hole.">)>
+ <CRLF>)
+ (ELSE
+ <TELL
+"It's a steel ring set in the ">
+ <COND (<HERE? ,STORAGE-ROOM>
+ <TELL "floor">)
+ (ELSE <TELL "ceiling">)>
+ <TELL ". It's probably a manhole." CR>)>)
+ (<VERB? LOOK-INSIDE LOOK-DOWN>
+ <COND (<IN? ,MANHOLE-COVER ,MANHOLE>
+ <TELL "You see only the cover." CR>)
+ (<HERE? ,BRICK-TUNNEL>
+ <TELL
+"You can't see much." CR>)
+ (ELSE
+ <TELL
+"You can see a dark, grimy tunnel below." CR>)>)
+ (<P? (PUT PUT-ON) * MANHOLE>
+ <COND (<PRSO? ,MANHOLE-COVER> <RFALSE>)
+ (<NOT <IN? ,MANHOLE-COVER ,MANHOLE>>
+ <MOVE ,PRSO ,BRICK-TUNNEL>
+ <TELL
+"You drop " THE ,PRSO ", and it hits the ground not far below." CR>)
+ (ELSE
+ <TELL "The manhole is covered right now." CR>)>)
+ (<P? (THROUGH BOARD CLIMB-DOWN) MANHOLE>
+ <COND (<HERE? ,STORAGE-ROOM>
+ <DO-WALK ,P?DOWN>)
+ (ELSE <DO-WALK ,P?UP>)>)
+ (<P? (RAISE PRY MOVE) MANHOLE>
+ <PERFORM-PRSA ,MANHOLE-COVER ,PRSI>
+ <RTRUE>)
+ (<VERB? OPEN>
+ <COND (<PRSI? ,CROWBAR>
+ <NEW-VERB ,V?PRY>
+ <RTRUE>)
+ (<IN? ,MANHOLE-COVER ,MANHOLE>
+ <TELL
+"The only way would seem to be to remove the manhole cover." CR>)>)
+ (<VERB? CLOSE>
+ <PERFORM ,V?PUT ,MANHOLE-COVER ,MANHOLE>
+ <RTRUE>)>>
+
+<OBJECT MANHOLE-COVER
+ (IN MANHOLE)
+ (DESC "manhole cover")
+ (FDESC
+"In one corner of the room a manhole cover is partly buried in the dirt and
+crud.")
+ (SYNONYM COVER DISC DISK)
+ (ADJECTIVE MANHOLE OLD RUSTY STEEL)
+ (FLAGS TAKEBIT TRYTAKEBIT SURFACEBIT CONTBIT OPENBIT
+ SEARCHBIT)
+ (SIZE 200)
+ (ACTION MANHOLE-COVER-F)>
+
+<ROUTINE MANHOLE-COVER-F ()
+ <COND (<PRSO? ,MANHOLE-COVER>
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's an old, rusty, steel " 'MANHOLE-COVER>
+ <COND (<IN? ,MANHOLE-COVER ,MANHOLE>
+ <TELL
+" set in a steel ring embedded in the ">
+ <COND (<HERE? ,STORAGE-ROOM> <TELL "floor">)
+ (ELSE <TELL "ceiling">)>)>
+ <TELL "." CR>)
+ (<VERB? TAKE TAKE-OFF>
+ <COND (<IN? ,MANHOLE-COVER ,MANHOLE>
+ <TELL
+,YOU-CANT S "get a good grip on " "it; it's heavy and in a steel ring;
+impossible to just ">
+ <COND (<HERE? ,STORAGE-ROOM>
+ <TELL "drag it away." CR>)
+ (ELSE
+ <TELL "push it off." CR>)>)>)
+ (<P? (CLIMB-ON STEP-ON)>
+ <TELL ,WASTE-OF-TIME>)
+ (<AND <P? (PRY OPEN) * CROWBAR>
+ <IN? ,MANHOLE-COVER ,MANHOLE>>
+ <MOVE ,MANHOLE-COVER ,STORAGE-ROOM>
+ <TELL
+"You lever the " 'MANHOLE-COVER " aside">
+ <COND (<HERE? ,STORAGE-ROOM>
+ <TELL ", and crusted dirt falls into a dark">
+ <COND (<FSET? ,MANHOLE ,RMUNGBIT>
+ <TELL ", partly obstructed">)>
+ <TELL " hole below." CR>)
+ (ELSE <TELL "." CR>)>)
+ (<P? (PUSH-TO PUT-ON PUT) * MANHOLE>
+ <MOVE ,MANHOLE-COVER ,MANHOLE>
+ <TELL
+"You manage to shove the " 'MANHOLE-COVER " back over the hole." CR>)
+ (<VERB? OPEN>
+ <COND (<IN? ,MANHOLE-COVER ,MANHOLE>
+ <TELL "An interesting idea, but how?" CR>)>)
+ (<VERB? MOVE RAISE>
+ <COND (<NOT <IN? ,MANHOLE-COVER ,MANHOLE>>
+ <TELL
+"You move it a little way, but it's very heavy." CR>)
+ (ELSE
+ <TELL
+"It doesn't budge." CR>)>)
+ (<VERB? PUSH>
+ <COND (<IN? ,MANHOLE-COVER ,MANHOLE>
+ <TELL
+"It's sitting inside a steel ring, so pushing it does nothing." CR>)>)
+ (<VERB? CUT MUNG>
+ <TELL
+"The cover is heavy.">
+ <COND (,PRSI
+ <TELL
+" Your " 'PRSI " won't thank you for this.">)>
+ <CRLF>)>)>>
+
+<ROOM BRICK-TUNNEL
+ (IN ROOMS)
+ (DESC "Brick Tunnel")
+ (UP PER BRICK-TUNNEL-EXIT)
+ (NORTH TO CAVE-ROOM)
+ (SOUTH TO UNDER-ALCHEMY-LAB)
+ (ACTION BRICK-TUNNEL-F)
+ (THINGS <PSEUDO (<> BRICKS RANDOM-PSEUDO)
+ (<> STONES RANDOM-PSEUDO)>)>
+
+<GLOBAL MANHOLE-SCORE 5>
+
+<ROUTINE BRICK-TUNNEL-EXIT ()
+ <COND (<NOT <IN? ,MANHOLE-COVER ,MANHOLE>>
+ ,STORAGE-ROOM)
+ (ELSE
+ <TELL
+S "There is a " 'MANHOLE-COVER " blocking your way." CR>
+ <RFALSE>)>>
+
+<ROUTINE BRICK-TUNNEL-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"This is an ancient tunnel constructed of roughly
+mortared bricks and stones. ">
+ <COND (<ZERO? ,MANHOLE-SCORE>
+ <TELL "A slippery and almost invisible set of
+handholds leads up. ">)>
+ <TELL "The tunnel continues a long way north and south from here." CR>)
+ (<RARG? ENTER>
+ <FSET ,MANHOLE ,NDESCBIT>
+ <MOVE ,MANHOLE ,HERE>
+ <COND (<AND <EQUAL? ,OHERE ,STORAGE-ROOM>
+ <FSET? ,MANHOLE ,RMUNGBIT>>
+ <FCLEAR ,MANHOLE ,RMUNGBIT>
+ <TELL
+S "You push your way through ""cobwebs, damp fungus,
+and other obstructions." CR CR>)
+ (<EQUAL? ,OHERE ,UNDER-ALCHEMY-LAB>
+ <TELL ,DOWN-LONG-TUNNEL>)>)
+ (<RARG? LEAVE>
+ <COND (<EQUAL? ,OHERE ,UNDER-ALCHEMY-LAB ,CAVE-ROOM>
+ <TELL ,DOWN-LONG-TUNNEL>)>)>>
+
+<GLOBAL DOWN-LONG-TUNNEL "You make your way along the long tunnel.||">
+
+<ROOM CAVE-ROOM
+ (IN ROOMS)
+ (DESC "Renovated Cave")
+ (SOUTH TO BRICK-TUNNEL)
+ (DOWN TO CAVE-ALTAR)
+ (GLOBAL SLAB CARVINGS)
+ (ACTION CAVE-ROOM-F)>
+
+<ROUTINE CAVE-ROOM-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"You are in a huge, cave-like construction. A path leads down to a
+floor partly covered with rough concrete. The walls and ceiling
+are high and reinforced with beams of wood, iron, and steel. In the center
+of the floor you can see a large, flat " 'SLAB ". The only
+exit is behind you to the south." CR>)>>
+
+<OBJECT SLAB
+ (IN CAVE-ALTAR)
+ (DESC "slab of granite")
+ (SYNONYM SLAB ALTAR)
+ (ADJECTIVE GRANITE)
+ (FLAGS NDESCBIT SEARCHBIT VEHBIT OPENBIT SURFACEBIT CONTBIT)
+ (CAPACITY 200)
+ (ACTION SLAB-F)>
+
+<ROUTINE SLAB-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The slab is roughly circular, made of indifferently dressed New England
+granite, and about three feet high.">
+ <COND (<HERE? ,CAVE-ALTAR>
+ <TELL " It is carved all over with odd glyphs,
+symbols, and strange animal (or part-animal?) figures. The top is covered
+with a brown stain shading to red at the edges.">)>
+ <CRLF>)
+ (<VERB? BOARD RUB READ PUSH>
+ <COND (<HERE? ,CAVE-ROOM>
+ <TELL ,ARENT-CLOSE-ENOUGH>)
+ (<VERB? READ>
+ <NEW-PRSO ,CARVINGS>
+ <RTRUE>)
+ (<AND <VERB? RUB>
+ ,PRSI
+ <NOT <PRSI? ,HANDS>>>
+ <TELL ,NOTHING-HAPPENS>)
+ (ELSE
+ <TELL
+"An inexplicable revulsion prevents you from touching it." CR>)>)
+ (<VERB? WALK-TO>
+ <COND (<HERE? ,CAVE-ROOM>
+ <DO-WALK ,P?DOWN>)
+ (ELSE
+ <TELL
+S "You approach the " "slab warily. It is disquieting to look at." CR>)>)>>
+
+<OBJECT CARVING-SYMBOL
+ (IN SLAB)
+ (DESC "incised symbol")
+ (SYNONYM SYMBOL)
+ (ADJECTIVE INCISED LARGE)
+ (FLAGS NDESCBIT)
+ (GENERIC GENERIC-SYMBOL-F)
+ (ACTION CARVING-SYMBOL-F)>
+
+<ROUTINE CARVING-SYMBOL-F ()
+ <COND (<VERB? EXAMINE READ>
+ <TELL
+"The symbol appears to be the oldest thing carved on the altar.
+It is beautifully incised in the rocks. Its age is apparent from
+its wear and the overlay of newer carvings and scratchings over it. ">
+ <TELL-SYMBOL ,CARVINGS>
+ <CRLF>)>>
+
+<OBJECT CARVINGS
+ (IN LOCAL-GLOBALS)
+ (DESC "carvings")
+ (SYNONYM CARVINGS GRAFFITI CREATURE PEOPLE)
+ (ADJECTIVE CARVED STAINED OBSCENE REVOLTING INDESCRIBABLE)
+ (FLAGS NDESCBIT READBIT SEARCHBIT OPENBIT CONTBIT)
+ (GENERIC GENERIC-CREATURE-F)
+ (ACTION CARVINGS-F)>
+
+<ROUTINE CARVINGS-F ()
+ <COND (<VERB? EXAMINE READ>
+ <COND (<HERE? ,CAVE-ALTAR>
+ <TELL
+"The carvings are in a variety of styles. Some are almost like graffiti,
+and have carved dates as early as 1655 and as recent as last year. Some
+are creatures, or people, or combinations of the two. Some are obscene,
+or revolting, or just indescribable. One is a strange " 'CARVING-SYMBOL ".
+Most are at least partly spotted with brown stains." CR>)
+ (ELSE
+ <TELL ,ARENT-CLOSE-ENOUGH>)>)
+ (<VERB? RUB>
+ <NEW-PRSO ,SLAB>
+ <RTRUE>)>>
+
+<GLOBAL ARENT-CLOSE-ENOUGH "You aren't close enough.|">
+
+<ROOM CAVE-ALTAR
+ (IN ROOMS)
+ (DESC "Before the Altar")
+ (UP TO CAVE-ROOM)
+ (GLOBAL ;SLAB CARVINGS)
+ (ACTION CAVE-ALTAR-F)>
+
+<ROUTINE CAVE-ALTAR-F (RARG)
+ <COND (<RARG? LOOK>
+ <THIS-IS-IT ,CARVING-SYMBOL>
+ <TELL
+"You are at the bottom of the cave. The huge " 'SLAB " in the center
+is a sort of altar. It is carved with strange and
+disturbing symbols, the largest of which looks very familiar. Some
+of the symbols are obscured by rusty red stains. Nearby
+is an iron plate set in the concrete of the floor." CR>)
+ (<RARG? BEG>
+ <COND (<AND <P? FIND STUDENTS>
+ ,SEEN-PIT?>
+ <TELL
+"You no longer need to look for them. You now understand the stains
+on the altar." CR>)
+ (<AND <VERB? WALK>
+ <EQUAL? ,P-WALK-DIR ,P?DOWN>
+ ,SEEN-PIT?>
+ <TELL
+"You're joking." CR>)>)
+ (<RARG? ENTER>
+ <COND (<FSET? ,IRON-PLATE ,OPENBIT>
+ <QUEUE I-PANEL-NOISES -1>)>)>>
+
+<OBJECT KNIFE
+ (IN CAVE-ALTAR)
+ (DESC "knife")
+ (FDESC
+"Lying to one side of the altar stone is a sharp, thin-bladed
+knife.")
+ (SYNONYM KNIFE BLADE)
+ (ADJECTIVE SHARP THIN THIN-BLADED)
+ (FLAGS TAKEBIT WEAPONBIT TOOLBIT)
+ (ACTION KNIFE-F)>
+
+<ROUTINE KNIFE-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This small knife is clean, sharp, and has a long, thin blade
+and a wooden handle. Only the tip of the blade appears at all dull or
+used." CR>)
+ (<VERB? SHARPEN>
+ <TELL
+"The blade doesn't look any different after this operation." CR>)>>
+
+<OBJECT IRON-PLATE
+ (IN CAVE-ALTAR)
+ (DESC "iron plate")
+ (SYNONYM PLATE HOLE PANEL OPENING)
+ (ADJECTIVE IRON)
+ (FLAGS AN NDESCBIT CONTBIT TRANSBIT OPENABLE)
+ (ACTION IRON-PLATE-F)>
+
+<ROUTINE IRON-PLATE-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The plate is iron, about two feet square, and ">
+ <COND (<NOT <FSET? ,IRON-PLATE ,OPENBIT>>
+ <TELL "looks like it could be slid ">)>
+ <TELL "open. A curious feature of the plate
+is that it has upward projecting dents in it which appear to have
+been punched from below.">
+ <CRLF>)
+ (<VERB? OPEN MOVE>
+ <COND (,SEEN-PIT?
+ <TELL S
+"You would sooner die than open that panel again.|">)
+ (<NOT <FSET? ,PRSO ,OPENBIT>>
+ <FSET ,PRSO ,OPENBIT>
+ <QUEUE I-PANEL-NOISES -1>
+ <TELL
+"You slide open the panel, revealing a dark pit below. Immediately,
+there is a response from below." CR>)>)
+ (<VERB? RAISE>
+ <TELL
+"It doesn't lift, it slides." CR>)
+ (<P? PUT * ,IRON-PLATE>
+ <COND (<FSET? ,PRSI ,OPENBIT>
+ <REMOVE ,PRSO>
+ <COND (<FSET? ,PRSO ,FOODBIT>
+ <TELL
+"Sounds of ghoulish excitement issue from the opening." CR>)
+ (ELSE
+ <TELL
+"The sounds from below increase in intensity." CR>)>)
+ (ELSE
+ <TELL "The panel isn't open." CR>)>)
+ (<VERB? CLOSE>
+ <COND (<FSET? ,PRSO ,OPENBIT>
+ <FCLEAR ,PRSO ,OPENBIT>
+ <DEQUEUE I-PANEL-NOISES>
+ <TELL
+"You close the panel. You no longer hear the noises, much to your
+relief." CR>)>)
+ (<VERB? LISTEN>
+ <COND (,SEEN-PIT?
+ <TELL
+,UNABLE "do that again." CR>)
+ (<FSET? ,IRON-PLATE ,OPENBIT>
+ <TELL
+"Disturbing noises issue from the open panel." CR>)
+ (ELSE
+ <TELL
+"You hear very faint noises through the closed panel." CR>)>)
+ (<VERB? LOOK-INSIDE LOOK-UNDER REACH-IN LEAP BOARD>
+ <COND (,SEEN-PIT?
+ <TELL S
+"You would sooner die than open that panel again.|">)
+ (<FSET? ,IRON-PLATE ,OPENBIT>
+ <FCLEAR ,IRON-PLATE ,OPENBIT>
+ <DEQUEUE I-PANEL-NOISES>
+ <SETG SEEN-PIT? T>
+ <TELL
+"You peer through the hole, shining your light into the stygian darkness
+below. The commotion below is growing louder, and suddenly you catch a
+glimpse of things moving in the pit. Without consciously realizing you
+have done it, you slam the panel shut, reeling away from the source of
+such images. Now you know what has been done with the
+missing students." CR>)
+ (ELSE
+ <TELL-OPEN-CLOSED ,PRSO>)>)>>
+
+<GLOBAL UNABLE "You find yourself unable to ">
+
+<GLOBAL SEEN-PIT? <>>
+
+<ROUTINE I-PANEL-NOISES ("OPT" (NOCR? <>))
+ <COND (<NOT <HERE? ,CAVE-ALTAR ,CAVE-ROOM>>
+ <DEQUEUE I-PANEL-NOISES>
+ <RFALSE>)
+ (<AND <NOT .NOCR?> <VERB? LISTEN>>
+ <RFALSE>)
+ (<HERE? ,CAVE-ALTAR>
+ <COND (<NOT .NOCR?> <CRLF>)>
+ <TELL
+"A low, guttural, groaning and snarling issues from the opening." CR>)
+ (ELSE
+ <COND (<NOT .NOCR?> <CRLF>)>
+ <TELL
+"You can still hear faint groans and snarls from the larger cave." CR>)>>
+
+<ROOM UNDER-ALCHEMY-LAB
+ (IN ROOMS)
+ (DESC "Cinderblock Tunnel")
+ (NORTH TO BRICK-TUNNEL)
+ (UP PER UNDER-ALCHEMY-LAB-EXIT)
+ (GLOBAL ALCHEMY-TRAP-DOOR LAB LADDER)
+ (ACTION UNDER-ALCHEMY-LAB-F)>
+
+<ROUTINE UNDER-ALCHEMY-LAB-EXIT ()
+ <COND (<NOT <FSET? ,ALCHEMY-TRAP-DOOR ,OPENBIT>>
+ <COND (<WINNER? ,PLAYER>
+ <THIS-IS-IT ,ALCHEMY-TRAP-DOOR>
+ <TELL
+"The trapdoor isn't open." CR>)>
+ <RFALSE>)
+ (ELSE
+ ,ALCHEMY-LAB)>>
+
+<ROUTINE UNDER-ALCHEMY-LAB-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"This is a tunnel whose walls are cinderblock, with a concrete floor and
+ceiling. A metal ladder leads up to ">
+ <AN-OPEN/CLOSED ,ALCHEMY-TRAP-DOOR>
+ <TELL " in the ceiling, and the
+tunnel continues north, where the cinderblock walls become brick." CR>)>>
+
+<ROUTINE AN-OPEN/CLOSED (DOOR)
+ <COND (<FSET? .DOOR ,OPENBIT> <TELL "an open ">)
+ (ELSE <TELL "a closed ">)>
+ <TELL D .DOOR>>
+
+<ROOM TEMPORARY-LAB
+ (IN ROOMS)
+ (DESC "Temporary Lab")
+ (LDESC
+"This is a laboratory of some sort. It takes up most of the building on
+this level, all the interior walls having been knocked down. (One reason
+these temporary buildings are still here is their
+flexibility: no one cares if they get more or less destroyed.) A stairway
+leads down, and a door leads north.")
+ (NORTH TO SMITH-ST-2)
+ (OUT TO SMITH-ST-2)
+ (DOWN TO TEMPORARY-BASEMENT)
+ (GLOBAL OUTSIDE-DOOR)
+ (ACTION TEMPORARY-LAB-F)>
+
+<ROUTINE TEMPORARY-LAB-F (RARG)
+ <COND (<RARG? ENTER>
+ <DEQUEUE I-FREEZE-TO-DEATH>
+ <COND (<G? ,FREEZE-COUNT 0>
+ <SETG FREEZE-COUNT 0>
+ <TELL
+,PUSH-INTO "comparative warmth of a laboratory." CR CR>)>)>>
+
+<GLOBAL PUSH-INTO "You push your way into the ">
+
+<OBJECT FLASK
+ (IN TEMPORARY-LAB)
+ (DESC "metal flask")
+ (SYNONYM FLASK)
+ (ADJECTIVE LARGE METAL DEWAR)
+ (FLAGS TAKEBIT CONTBIT SEARCHBIT OPENABLE)
+ (SIZE 50)
+ (CAPACITY 9)
+ (CONTFCN FLASK-CONT)
+ (ACTION FLASK-F)>
+
+<ROUTINE FLASK-CONT (RARG)
+ <COND (<VERB? TAKE>
+ <COND (<AND <IN? ,NITROGEN ,FLASK>
+ <NOT <PRSO? ,NITROGEN>>>
+ <REMOVE ,PRSO>
+ <TELL
+"You manage to fish " THE ,PRSO " out without freezing your fingers
+somehow, but it's frozen solid. It's also fragile. It
+shatters into a million pieces, and is gone." CR>)>)>>
+
+<ROUTINE FLASK-F ()
+ <COND (<PRSO? ,FLASK>
+ <COND (<VERB? EXAMINE>
+ <TELL
+S "This is a large ""metal flask, about the size of a water cooler bottle. ">
+ <COND (<FSET? ,FLASK ,OPENBIT>
+ <TELL
+"The flask is open">
+ <COND (<IN? ,NITROGEN ,FLASK>
+ <TELL
+", and a thin, cold mist flows out of it">)>
+ <TELL ,PERIOD>)
+ (ELSE
+ <TELL-OPEN-CLOSED ,FLASK>)>)
+ (<VERB? RUB>
+ <TELL
+"The metal of the flask is ">
+ <COND (<IN? ,NITROGEN ,FLASK>
+ <TELL "very ">)>
+ <TELL "cold." CR>)
+ (<VERB? OPEN>
+ <COND (<NOT <FSET? ,FLASK ,OPENBIT>>
+ <FSET ,FLASK ,OPENBIT>
+ <TELL
+"You open the flask">
+ <COND (<IN? ,NITROGEN ,FLASK>
+ <MOVE ,MIST ,HERE>
+ <QUEUE I-NITROGEN-GOES 3>
+ <TELL
+", and a cold, white mist boils out">)>
+ <TELL ,PERIOD>)>)
+ (<VERB? CLOSE>
+ <COND (<FSET? ,FLASK ,OPENBIT>
+ <DEQUEUE I-NITROGEN-GOES>
+ <QUEUE I-MIST-GOES 2>
+ <FCLEAR ,FLASK ,OPENBIT>
+ <TELL
+"You screw the flask closed." CR>)>)
+ (<VERB? FILL>
+ <CANT-FILL-IT>)
+ (<AND <VERB? POUR>
+ <IN? ,NITROGEN ,FLASK>>
+ <NEW-PRSO ,NITROGEN>
+ <RTRUE>)>)
+ (<AND <P? PUT * FLASK>
+ <G? <GETP ,PRSO ,P?SIZE>
+ <GETP ,FLASK ,P?CAPACITY>>>
+ <TELL "The neck of " THE ,FLASK " is too small." CR>)>>
+
+<OBJECT MIST
+ (DESC "mist")
+ (SYNONYM MIST GAS)
+ (ADJECTIVE THIN COLD THICK BLACK)
+ (ACTION MIST-F)>
+
+<ROUTINE MIST-F ()
+ <COND (<NOT ,TIED-UP?>
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The mist is boiling up ">
+ <COND (<IN? ,NITROGEN ,FLASK>
+ <TELL "out of the flask">)
+ (ELSE
+ <TELL "off of the ground">)>
+ <TELL ". It is thin, white, and cold." CR>)
+ (<VERB? RUB>
+ <TELL
+"The mist is very cold." CR>)
+ (<VERB? SMELL>
+ <TELL
+"The mist is odorless." CR>)>)>>
+
+<ROUTINE I-MIST-GOES ("AUX" L)
+ <COND (<NOT <QUEUED? I-NITROGEN-GOES>>
+ <SET L <LOC ,MIST>>
+ <REMOVE ,MIST>
+ <COND (<HERE? .L>
+ <TELL CR
+"The mist dissipates." CR>)>)>>
+
+<OBJECT NITROGEN
+ (IN FLASK)
+ (DESC "cold liquid")
+ (SYNONYM NITROGEN LIQUID)
+ (ADJECTIVE LIQUID THIN COLD)
+ (FLAGS TAKEBIT WEAPONBIT)
+ (ACTION NITROGEN-F)>
+
+<ROUTINE NITROGEN-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The flask contains a clear, " 'NITROGEN " with a thin white mist
+boiling off of it." CR>)
+ (<VERB? TAKE RUB>
+ <TELL
+"The liquid is extremely cold. In fact, you burn your finger on it." CR>)
+ (<VERB? SMELL>
+ <TELL
+"The liquid has no smell." CR>)
+ (<VERB? POUR PUT DROP THROW>
+ <REMOVE ,NITROGEN>
+ <DEQUEUE I-NITROGEN-GOES>
+ <QUEUE I-MIST-GOES 2>
+ <COND (<PRSI? ,FLASK>
+ <TELL ,GOOD-TRICK>)
+ (<AND ,PRSI
+ <FSET? ,PRSI ,PERSON>
+ <NOT <PRSI? ,ME ,HAND>>>
+ <SWAP-VERB ,V?ATTACK>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"The freezing liquid pours out">
+ <COND (,PRSI
+ <TELL " onto " THE ,PRSI>)>
+ <TELL ", boiling into cold mist almost immediately">
+ <COND (,PRSI
+ <COND (<OR <HELD? ,PRSI>
+ <INTRINSIC? ,PRSI>>
+ <JIGS-UP
+", but not before it freezes you as well.">
+ <RFATAL>)
+ (<FSET? ,PRSI ,SLIMEBIT>
+ <FCLEAR ,PRSI ,SLIMEBIT>)
+ (<FSET? ,PRSI ,TAKEBIT>
+ <REMOVE ,PRSI>
+ <TELL
+", but " THE ,PRSI " freezes and then shatters from the cold">)>)>
+ <TELL "." CR>)>)>>
+
+<GLOBAL NITROGEN-CNT 5>
+
+<ROUTINE I-NITROGEN-GOES ()
+ <COND (<IN? ,NITROGEN ,FLASK>
+ <QUEUE I-NITROGEN-GOES 3>
+ <SETG NITROGEN-CNT <- ,NITROGEN-CNT 1>>
+ <COND (<ZERO? ,NITROGEN-CNT>
+ <DEQUEUE I-NITROGEN-GOES>
+ <QUEUE I-MIST-GOES 2>
+ <REMOVE ,NITROGEN>
+ <RFALSE>)
+ (ELSE
+ <COND (<ACCESSIBLE? ,FLASK>
+ <TELL CR
+"Cold white mist continues to boil out of the flask." CR>)>)>)>>
+
+<ROOM CS-ELEVATOR-ROOM
+ (IN ROOMS)
+ (DESC "Elevator")
+ (OUT PER CS-ELEVATOR-EXIT)
+ (NORTH PER CS-ELEVATOR-EXIT)
+ (GLOBAL ELEVATOR GRAFFITI ;ELEVATOR-DOOR)
+ (FLAGS ONBIT)
+ (ACTION CS-ELEVATOR-ROOM-F)>
+
+<ROUTINE CS-ELEVATOR-ROOM-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"This is a battered, rather dirty elevator. The fake wood walls are
+scratched and marred with graffiti. ">
+ <ELEVATOR-DOORS-OPEN-CLOSED ,ELEVATOR-DOOR>
+ <TELL ,TO-THE-RIGHT "doors is an
+area with " 'FLOOR-BUTTON "s (B and 1 through 3), an " 'OPEN-BUTTON ", a "
+'CLOSE-BUTTON ", a " 'STOP-SWITCH ", and an " 'ALARM-BUTTON ".">
+ <TELL-BUTTON 0 %<ASCII !\B>>
+ <TELL-BUTTON 1 %<ASCII !\1>>
+ <TELL-BUTTON 2 %<ASCII !\2>>
+ <TELL-BUTTON 3 %<ASCII !\3>>
+ <TELL
+" Below these is an " 'ACCESS-PANEL " which is ">
+ <OPEN-CLOSED ,ACCESS-PANEL>)
+ (<RARG? BEG>
+ <COND (<VERB? DISEMBARK>
+ <DO-WALK ,P?NORTH>)>)>>
+
+<GLOBAL TO-THE-RIGHT " To the right of the ">
+
+<ROUTINE TELL-BUTTON (N C)
+ <COND (<BTST <GET ,BUTTONS .N> ,E-GO>
+ <TELL " The \"">
+ <PRINTC .C>
+ <TELL "\" button is glowing.">)>>
+
+<OBJECT ACCESS-PANEL
+ (IN CS-ELEVATOR-ROOM)
+ (DESC "access panel")
+ (SYNONYM PANEL)
+ (ADJECTIVE ACCESS)
+ (CAPACITY 20)
+ (FLAGS NDESCBIT AN CONTBIT SEARCHBIT OPENABLE)
+ (ACTION ACCESS-PANEL-F)>
+
+<ROUTINE ACCESS-PANEL-F ()
+ <COND (<VERB? EXAMINE>
+ <COND (<NOT <FSET? ,ACCESS-PANEL ,OPENBIT>>
+ <TELL
+"This panel presumably opens to access the inner maintenance controls
+of the elevator." CR>)
+ (ELSE
+ <TELL
+"The panel conceals a small space which probably contained maintenance
+controls for the elevator once, but these have been torn out by someone,
+leaving a bare metal cavity. ">
+ <DESCRIBE-SENT ,ACCESS-PANEL>
+ <CRLF>)>)>>
+
+<OBJECT FLASHLIGHT
+ (IN ACCESS-PANEL)
+ (DESC "flashlight")
+ (SYNONYM FLASHLIGHT LIGHT LAMP)
+ (ADJECTIVE FLASH)
+ (FLAGS TAKEBIT LIGHTBIT)
+ (ACTION FLASHLIGHT-F)>
+
+<ROUTINE FLASHLIGHT-F ("AUX" OLIT)
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The flashlight is a heavy-duty shop-style light.">
+ <COND (<FSET? ,FLASHLIGHT ,ONBIT>
+ <TELL S " It is currently ""on.">)>
+ <CRLF>)
+ (<VERB? LAMP-ON>
+ <COND (<NOT <FSET? ,FLASHLIGHT ,LIGHTBIT>>
+ <TELL
+,IT-SEEMS-TO-BE "burned out." CR>)
+ (<FSET? ,FLASHLIGHT ,ONBIT>
+ <TELL
+"It is!" CR>)
+ (ELSE
+ <FSET ,FLASHLIGHT ,ONBIT>
+ <QUEUE I-FLASHLIGHT <GET ,FLASHLIGHT-TABLE 0>>
+ <TELL CTHE ,FLASHLIGHT " clicks on." CR>
+ <SET OLIT ,LIT>
+ <SETG LIT <LIT? ,HERE>>
+ <COND (<AND <NOT .OLIT> ,LIT>
+ <CRLF>
+ <V-LOOK>)>
+ <RTRUE>)>)
+ (<VERB? LAMP-OFF>
+ <COND (<NOT <FSET? ,FLASHLIGHT ,ONBIT>>
+ <TELL
+"It is!" CR>)
+ (ELSE
+ <FCLEAR ,FLASHLIGHT ,ONBIT>
+ <PUT ,FLASHLIGHT-TABLE 0 <DEQUEUE I-FLASHLIGHT>>
+ <TELL
+CTHE ,FLASHLIGHT " clicks off">
+ <IN-DARK? T>)>)
+ (<VERB? OPEN>
+ <TELL
+"It doesn't open. It appears to be one of those rechargeable lights,
+so you can't easily get at the battery." CR>)>>
+
+<ROUTINE I-FLASHLIGHT ("AUX" (HERE? <>) OLIT)
+ <COND (<SET HERE? <EQUAL? <META-LOC ,FLASHLIGHT> ,HERE>>
+ <TELL CR CTHE ,FLASHLIGHT <GET ,FLASHLIGHT-TABLE 1>>)>
+ <SETG FLASHLIGHT-TABLE <REST ,FLASHLIGHT-TABLE 4>>
+ <COND (<ZERO? <GET ,FLASHLIGHT-TABLE 0>>
+ <FCLEAR ,FLASHLIGHT ,ONBIT>
+ <FCLEAR ,FLASHLIGHT ,LIGHTBIT>
+ <COND (.HERE?
+ <TELL CTHE ,FLASHLIGHT " has burned out">
+ <IN-DARK? T>)>)
+ (ELSE
+ <QUEUE I-FLASHLIGHT <GET ,FLASHLIGHT-TABLE 0>>)>
+ <COND (.HERE? <CRLF>)>>
+
+<GLOBAL FLASHLIGHT-TABLE
+ <TABLE 200
+ " is a little dimmer now."
+ 100
+ " is producing much less light."
+ 50
+ " is very dim."
+ 25
+ " is flickering."
+ 5
+ " is practically out."
+ 1
+ " fails."
+ 0>>
+
+<ROUTINE THIS-FLOOR-DOOR ()
+ <COND (<HERE? ,CS-BASEMENT ,ELEVATOR-PIT> ,ELEVATOR-DOOR-B)
+ (<HERE? ,COMP-CENTER> ,ELEVATOR-DOOR-1)
+ (<HERE? ,CS-2ND> ,ELEVATOR-DOOR-2)
+ (<HERE? ,CS-3RD> ,ELEVATOR-DOOR-3)>>
+
+<ROUTINE DOOR-AT-ELEVATOR ()
+ <COND (<EQUAL? ,ELEVATOR-LOC 0> ,ELEVATOR-DOOR-B)
+ (<EQUAL? ,ELEVATOR-LOC 1> ,ELEVATOR-DOOR-1)
+ (<EQUAL? ,ELEVATOR-LOC 2> ,ELEVATOR-DOOR-2)
+ (ELSE ,ELEVATOR-DOOR-3)>>
+
+<ROUTINE FLOOR-SHAFT ()
+ <COND (<HERE? ,CS-BASEMENT ,ELEVATOR-PIT> ,SHAFT-B)
+ (<HERE? ,COMP-CENTER> ,SHAFT-1)
+ (<HERE? ,CS-2ND> ,SHAFT-2)
+ (<HERE? ,CS-3RD> ,SHAFT-3)>>
+
+<OBJECT OPEN-BUTTON
+ (IN CS-ELEVATOR-ROOM)
+ (DESC "open button")
+ (SYNONYM BUTTON)
+ (ADJECTIVE OPEN)
+ (FLAGS NDESCBIT AN)
+ (ACTION OPEN-BUTTON-F)>
+
+<ROUTINE OPEN-BUTTON-F ()
+ <COND (<VERB? PUSH>
+ <COND (,ELEVATOR-STOPPED?
+ <QUEUE I-ELEVATOR-DOOR-CLOSES 2>
+ <COND (<FSET? ,ELEVATOR-DOOR ,OPENBIT>
+ <TELL "The doors stay open." CR>)
+ (ELSE
+ <FSET <DOOR-AT-ELEVATOR> ,OPENBIT>
+ <FSET ,ELEVATOR-DOOR ,OPENBIT>
+ <TELL "The doors spring open." CR>)>)
+ (ELSE
+ <TELL
+,STILL-MOVING " " ,NOTHING-HAPPENS>)>)>>
+
+<OBJECT CLOSE-BUTTON
+ (IN CS-ELEVATOR-ROOM)
+ (DESC "close button")
+ (SYNONYM BUTTON)
+ (ADJECTIVE CLOSE)
+ (FLAGS NDESCBIT)
+ (ACTION CLOSE-BUTTON-F)>
+
+<ROUTINE CLOSE-BUTTON-F ()
+ <COND (<VERB? PUSH>
+ <COND (,ELEVATOR-STOPPED?
+ <COND (<FSET? ,ELEVATOR-DOOR ,OPENBIT>
+ <QUEUE I-ELEVATOR-DOOR-CLOSES 2>
+ <TELL "You push the button." CR>)
+ (ELSE
+ <TELL "The door is already closed." CR>)>)
+ (ELSE
+ <TELL
+S "The elevator is ""moving, the door is closed." CR>)>)>>
+
+<OBJECT FLOOR-BUTTON
+ (IN CS-ELEVATOR-ROOM)
+ (DESC "floor button")
+ (SYNONYM BUTTON)
+ (ADJECTIVE FLOOR INTNUM)
+ (FLAGS NDESCBIT)
+ (ACTION FLOOR-BUTTON-F)>
+
+<OBJECT BASEMENT-BUTTON
+ (IN CS-ELEVATOR-ROOM)
+ (DESC "B button")
+ (SYNONYM BUTTON)
+ (ADJECTIVE B BASEMENT)
+ (FLAGS NDESCBIT)
+ (ACTION FLOOR-BUTTON-F)>
+
+<ROUTINE FLOOR-BUTTON-F ("AUX" OLD)
+ <COND (<VERB? PUSH>
+ <COND (<PRSO? ,BASEMENT-BUTTON>
+ <SETG P-NUMBER 0>)>
+ <COND (<G? ,P-NUMBER 3>
+ <TELL
+"There are only three floors and a basement in this building." CR>)
+ (<EQUAL? ,P-NUMBER ,ELEVATOR-LOC>
+ <COND (<HERE? ,CS-ELEVATOR-ROOM>
+ <TELL
+"The button doesn't light." CR>)
+ (ELSE <RTRUE>)>)
+ (ELSE
+ <SET OLD <GET ,BUTTONS ,P-NUMBER>>
+ <COND (<NOT <BTST .OLD ,E-GO>>
+ <PUT ,BUTTONS ,P-NUMBER <BOR .OLD ,E-GO>>
+ <QUEUE I-ELEVATOR-MOVES 1>
+ <COND (,ELEVATOR-STOPPED?
+ <PICK-ELEVATOR-DIRECTION>)>
+ <COND (<HERE? ,CS-ELEVATOR-ROOM>
+ <TELL
+"The button for the " <GET ,FLOOR-NAMES ,P-NUMBER> S " begins to glow.|">)
+ (ELSE <RTRUE>)>)
+ (ELSE
+ <COND (<HERE? ,CS-ELEVATOR-ROOM>
+ <TELL ,ALREADY-GLOWING>)
+ (ELSE <RTRUE>)>)>)>)>>
+
+<GLOBAL FLOOR-NAMES
+ <TABLE (PURE) "basement" "first floor" "second floor" "third floor">>
+
+<ROUTINE ELEVATOR-HERE? ()
+ <COND (<HERE? ,CS-ELEVATOR-ROOM> <RTRUE>)
+ (<AND <GETPT ,HERE ,P?FLOOR>
+ <EQUAL? <GETP ,HERE ,P?FLOOR> ,ELEVATOR-LOC>>
+ <RTRUE>)
+ (ELSE <RFALSE>)>>
+
+<ROUTINE ELEVATOR-WANTED? ()
+ <COND (<OR <NOT <ZERO? <GET ,BUTTONS 0>>>
+ <NOT <ZERO? <GET ,BUTTONS 1>>>
+ <NOT <ZERO? <GET ,BUTTONS 2>>>
+ <NOT <ZERO? <GET ,BUTTONS 3>>>>
+ <QUEUE I-ELEVATOR-MOVES 1>)>>
+
+<ROUTINE I-ELEVATOR-DOOR-OPENS ()
+ <QUEUE I-ELEVATOR-DOOR-CLOSES 2>
+ <COND (<NOT <FSET? ,ELEVATOR-DOOR ,OPENBIT>>
+ <SETG ELEVATOR-STOPPED? 3>
+ <FSET <DOOR-AT-ELEVATOR> ,OPENBIT>
+ <FSET ,ELEVATOR-DOOR ,OPENBIT>
+ <COND (<ELEVATOR-HERE?>
+ <TELL CR CTHE ,ELEVATOR-DOOR " slide open." CR>)>)>>
+
+"called when door closes on its own"
+
+<ROUTINE CHAIN-IN-DOOR? ()
+ <COND (<AND ,CHAIN-HOOKED?
+ <EQUAL? <META-LOC ,HOOK> ,HERE>
+ <OR <HELD? ,CHAIN>
+ <IN? ,CHAIN ,HERE>>>
+ ,CHAIN)>>
+
+"called when door closes on its own"
+
+<ROUTINE I-ELEVATOR-DOOR-CLOSES ("AUX" W)
+ <COND (<NOT <FSET? ,ELEVATOR-DOOR ,OPENBIT>>
+ <RFALSE>)
+ (<OR <SET W <FIRST? <DOOR-AT-ELEVATOR>>>
+ ,HOLDING-DOORS?
+ <SET W <CHAIN-IN-DOOR?>>>
+ <QUEUE I-ELEVATOR-DOOR-CLOSES 2>
+ <COND (<ELEVATOR-HERE?>
+ <TELL CR
+CTHE ,ELEVATOR-DOOR " bounce against ">
+ <COND (.W <TELL THE .W>)
+ (ELSE <TELL "your body">)>
+ <TELL ", trying to close." CR>)>)
+ (ELSE
+ <ELEVATOR-WANTED?>
+ <FCLEAR ,ELEVATOR-DOOR ,OPENBIT>
+ <FCLEAR <DOOR-AT-ELEVATOR> ,OPENBIT>
+ <COND (<ELEVATOR-HERE?>
+ <TELL CR CTHE ,ELEVATOR-DOOR " slide closed." CR>)>)>>
+
+"called when door released after being held open by person or object"
+
+<ROUTINE CLOSE-ELEVATOR-DOOR (DOOR)
+ <SETG HOLDING-DOORS? <>>
+ <SETG ELEVATOR-STOPPED? 1>
+ <ELEVATOR-WANTED?>
+ <FCLEAR .DOOR ,OPENBIT>
+ <COND (<ELEVATOR-HERE?>
+ <FCLEAR ,ELEVATOR-DOOR ,OPENBIT>)
+ (ELSE
+ <REMOVE <FLOOR-SHAFT>>)>>
+
+<ROUTINE PICK-ELEVATOR-DIRECTION ("AUX" ZERO ONE TWO THREE)
+ <COND (<EQUAL? ,ELEVATOR-LOC 0>
+ <SETG ELEVATOR-DIRECTION 1>)
+ (<EQUAL? ,ELEVATOR-LOC 3>
+ <SETG ELEVATOR-DIRECTION -1>)
+ (ELSE
+ <SET ZERO <GET ,BUTTONS 0>>
+ <SET ONE <GET ,BUTTONS 1>>
+ <SET TWO <GET ,BUTTONS 2>>
+ <SET THREE <GET ,BUTTONS 3>>
+ <COND (<EQUAL? ,ELEVATOR-DIRECTION -1>
+ <COND (<EQUAL? ,ELEVATOR-LOC 1>
+ <COND (<ZERO? .ZERO>
+ <SETG ELEVATOR-DIRECTION 1>)>)
+ (<EQUAL? ,ELEVATOR-LOC 2>
+ <COND (<AND <ZERO? .ZERO>
+ <ZERO? .ONE>>
+ <SETG ELEVATOR-DIRECTION 1>)>)>)
+ (<EQUAL? ,ELEVATOR-DIRECTION 1>
+ <COND (<EQUAL? ,ELEVATOR-LOC 2>
+ <COND (<ZERO? .THREE>
+ <SETG ELEVATOR-DIRECTION -1>)>)
+ (<EQUAL? ,ELEVATOR-LOC 1>
+ <COND (<AND <ZERO? .TWO>
+ <ZERO? .THREE>>
+ <SETG ELEVATOR-DIRECTION -1>)>)>)>)>>
+
+"T if elevator called from another floor than current one"
+
+<ROUTINE ELEVATOR-CALLED? ()
+ <COND (<AND <NOT <ZERO? <GET ,BUTTONS 0>>>
+ <NOT <ZERO? ,ELEVATOR-LOC>>>
+ <RTRUE>)
+ (<AND <NOT <ZERO? <GET ,BUTTONS 1>>>
+ <NOT <EQUAL? ,ELEVATOR-LOC 1>>>
+ <RTRUE>)
+ (<AND <NOT <ZERO? <GET ,BUTTONS 2>>>
+ <NOT <EQUAL? ,ELEVATOR-LOC 2>>>
+ <RTRUE>)
+ (<AND <NOT <ZERO? <GET ,BUTTONS 3>>>
+ <NOT <EQUAL? ,ELEVATOR-LOC 3>>>
+ <RTRUE>)>>
+
+<ROUTINE NO-HIGHER-UP-CALLS? ("AUX" (ZERO <GET ,BUTTONS 0>)
+ (ONE <GET ,BUTTONS 1>) (TWO <GET ,BUTTONS 2>)
+ (THREE <GET ,BUTTONS 3>))
+ <COND (<ZERO? ,ELEVATOR-LOC>
+ <COND (<OR <BTST .ONE <+ ,E-UP ,E-GO>>
+ <BTST .TWO <+ ,E-UP ,E-GO>>
+ <BTST .THREE <+ ,E-UP ,E-GO>>>
+ <RFALSE>)
+ (ELSE <RTRUE>)>)
+ (<EQUAL? ,ELEVATOR-LOC 1>
+ <COND (<OR <BTST .TWO <+ ,E-UP ,E-GO>>
+ <BTST .THREE <+ ,E-UP ,E-GO>>>
+ <RFALSE>)
+ (ELSE <RTRUE>)>)
+ (<EQUAL? ,ELEVATOR-LOC 2>
+ <COND (<BTST .THREE <+ ,E-UP ,E-GO>>
+ <RFALSE>)
+ (ELSE <RTRUE>)>)
+ (<EQUAL? ,ELEVATOR-LOC 3>
+ <RTRUE>)>>
+
+<ROUTINE NO-LOWER-DOWN-CALLS? ("AUX" (ZERO <GET ,BUTTONS 0>)
+ (ONE <GET ,BUTTONS 1>) (TWO <GET ,BUTTONS 2>)
+ (THREE <GET ,BUTTONS 3>))
+ <COND (<ZERO? ,ELEVATOR-LOC>
+ <RTRUE>)
+ (<EQUAL? ,ELEVATOR-LOC 1>
+ <COND (<BTST .ZERO <+ ,E-DOWN ,E-GO>>
+ <RFALSE>)
+ (ELSE <RTRUE>)>)
+ (<EQUAL? ,ELEVATOR-LOC 2>
+ <COND (<OR <BTST .ZERO <+ ,E-DOWN ,E-GO>>
+ <BTST .ONE <+ ,E-DOWN ,E-GO>>>
+ <RFALSE>)
+ (ELSE <RTRUE>)>)
+ (<EQUAL? ,ELEVATOR-LOC 3>
+ <COND (<OR <BTST .ZERO <+ ,E-DOWN ,E-GO>>
+ <BTST .ONE <+ ,E-DOWN ,E-GO>>
+ <BTST .TWO <+ ,E-DOWN ,E-GO>>>
+ <RFALSE>)
+ (ELSE <RTRUE>)>
+ <RTRUE>)>>
+
+<GLOBAL BRICK-WALL-SCORE 5>
+
+<ROUTINE I-ELEVATOR-MOVES ("AUX" OLD STOPPING?)
+ <QUEUE I-ELEVATOR-MOVES 1>
+ <COND (<OR <FSET? ,ELEVATOR-DOOR ,OPENBIT>
+ <FSET? ,ELEVATOR-DOOR-B ,OPENBIT>
+ <FSET? ,ELEVATOR-DOOR-1 ,OPENBIT>
+ <FSET? ,ELEVATOR-DOOR-2 ,OPENBIT>
+ <FSET? ,ELEVATOR-DOOR-3 ,OPENBIT>>
+ <RFALSE>)>
+ <COND (<AND ,ELEVATOR-STOPPED?
+ <ELEVATOR-CALLED?>>
+ <SETG ELEVATOR-STOPPED? <- ,ELEVATOR-STOPPED? 1>>
+ <COND (<ZERO? ,ELEVATOR-STOPPED?>
+ <COND (<OR <HERE? ,ELEVATOR-PIT>
+ <AND <HERE? ,STEAM-TUNNEL-EAST>
+ <EQUAL? ,BRICK-FLAG ,BF-BOTH>>>
+ <TELL CR
+"A loud mechanical whining ">
+ <COND (<HERE? ,ELEVATOR-PIT>
+ <TELL
+"begins above you." CR>)
+ (ELSE
+ <TELL
+"is audible through the hole." CR>)>)
+ (<HERE? ,CS-ELEVATOR-ROOM>
+ <TELL CR
+"The elevator begins to move " <COND (<G? ,ELEVATOR-DIRECTION 0> "upward")
+ (ELSE "downward")> ,PERIOD>)
+ (<GETPT ,HERE ,P?FLOOR>
+ <TELL CR
+"You hear the elevator begin moving." CR>)>)>)
+ (ELSE
+ <COND (<OR <AND <ZERO? ,ELEVATOR-LOC>
+ <L? ,ELEVATOR-DIRECTION 0>>
+ <AND <EQUAL? ,ELEVATOR-LOC 3>
+ <G? ,ELEVATOR-DIRECTION 0>>>
+ ;<TELL
+"** Elevator confused at " N ,ELEVATOR-LOC " **" CR>
+ <PICK-ELEVATOR-DIRECTION>)
+ (ELSE
+ <SETG ELEVATOR-LOC
+ <+ ,ELEVATOR-LOC ,ELEVATOR-DIRECTION>>
+ <COND (<ZERO? ,ELEVATOR-LOC>
+ <MOVE ,ELEVATOR-CEILING ,SHAFT-1>
+ <FSET ,ELEVATOR-FLOOR ,NDESCBIT>
+ <MOVE ,ELEVATOR-FLOOR ,ELEVATOR-PIT>)
+ (<EQUAL? ,ELEVATOR-LOC 1>
+ <MOVE ,ELEVATOR-CEILING ,SHAFT-2>
+ <MOVE ,ELEVATOR-FLOOR ,SHAFT-B>
+ <COND (<EQUAL? ,CHAIN-HOOKED? ,HOOK>
+ <MOVE ,CHAIN ,ELEVATOR-PIT>
+ <COND (<HERE? ,ELEVATOR-PIT>
+ <TELL CR
+"A greasy chain descends out of the shaft into a pile at your feet." CR>)>)>)
+ (<EQUAL? ,ELEVATOR-LOC 2>
+ <MOVE ,ELEVATOR-CEILING ,SHAFT-3>
+ <MOVE ,ELEVATOR-FLOOR ,SHAFT-1>
+ <COND (<AND ,CHAIN-LOOPED? ,CHAIN-HOOKED?>
+ <FSET ,CHAIN-2 ,INVISIBLE>
+ ;<REMOVE ,CHAIN-2>
+ <SETG CHAIN-LOOPED? <>>
+ <COND (<FSET? ,CHAIN-2 ,LOCKED>
+ <FCLEAR ,ELEVATOR-PIT ,TOUCHBIT>
+ <REMOVE ,ROD>
+ <REMOVE ,PADLOCK>
+ <FCLEAR ,CHAIN-2 ,LOCKED>
+ <SETG PADLOCK-ON? <>>
+ <SETG BRICK-WALL-FLAG T>
+ <SETG SCORE
+ <+ ,SCORE ,BRICK-WALL-SCORE>>
+ <SETG BRICK-WALL-SCORE 0>
+ <COND (<HEAR-CHAIN?>
+ <CHAIN-NOISES>
+ <TELL
+"tearing, rending sound, then a rumbling
+crash." CR>)
+ (<HERE? ,ELEVATOR-PIT>
+ <TELL CR
+"The length of chain grows taut, pulling at the rod.
+Suddenly, the bricks give up, and a steel reinforcing rod pulls free
+of the shattered wall. It flies across the room, impaling you with
+uncanny precision." CR>
+ <JIGS-UP>)>)
+ (ELSE
+ <COND (<HEAR-CHAIN?>
+ <CHAIN-NOISES>
+ <TELL
+"metallic sliding sound, then silence." CR>)
+ (<HERE? ,ELEVATOR-PIT>
+ <TELL CR
+"The chain slides off the rod and away into the air." CR>)>)>)
+ (,CHAIN-HOOKED?
+ <COND (<IN? ,CHAIN ,WINNER>
+ <REMOVE ,CHAIN>
+ <TELL CR
+"Suddenly, the chain is torn from your grasp!" CR>)
+ (<IN? ,CHAIN ,ELEVATOR-PIT>
+ <REMOVE ,CHAIN>)>)>)
+ (<EQUAL? ,ELEVATOR-LOC 3>
+ <REMOVE ,ELEVATOR-CEILING>
+ <MOVE ,ELEVATOR-FLOOR ,SHAFT-2>)>)>
+ <SET OLD <GET ,BUTTONS ,ELEVATOR-LOC>>
+ <COND (<G? ,ELEVATOR-DIRECTION 0>
+ <COND (<BTST .OLD ,E-UP>
+ <SET STOPPING? ,UP-BUTTON>)
+ (<AND <BTST .OLD ,E-DOWN>
+ <NO-HIGHER-UP-CALLS?>>
+ <PICK-ELEVATOR-DIRECTION>
+ <SET STOPPING? ,DOWN-BUTTON>)>)
+ (<L? ,ELEVATOR-DIRECTION 0>
+ <COND (<BTST .OLD ,E-DOWN>
+ <SET STOPPING? ,DOWN-BUTTON>)
+ (<AND <BTST .OLD ,E-UP>
+ <NO-LOWER-DOWN-CALLS?>>
+ <PICK-ELEVATOR-DIRECTION>
+ <SET STOPPING? ,UP-BUTTON>)>)>
+ <COND (<OR .STOPPING? <BTST .OLD ,E-GO>>
+ <COND (<NOT .STOPPING?>
+ <COND (<OR <AND <G? ,ELEVATOR-DIRECTION 0>
+ <NO-HIGHER-UP-CALLS?>>
+ <AND <L? ,ELEVATOR-DIRECTION 0>
+ <NO-LOWER-DOWN-CALLS?>>>
+ <PICK-ELEVATOR-DIRECTION>)>)>
+ <PUT ,BUTTONS
+ ,ELEVATOR-LOC
+ <COND (<EQUAL? .STOPPING? ,UP-BUTTON>
+ <BAND .OLD ,E-DOWN>)
+ (<EQUAL? .STOPPING? ,DOWN-BUTTON>
+ <BAND .OLD ,E-UP>)
+ (ELSE 0)>>
+ <DEQUEUE I-ELEVATOR-MOVES>
+ <SETG ELEVATOR-STOPPED? 3>
+ <QUEUE I-ELEVATOR-DOOR-OPENS 1>
+ <COND (<HERE? ,ELEVATOR-PIT>
+ <COND (<ZERO? ,ELEVATOR-LOC>
+ <JIGS-UP
+"The machinery stops. Unfortunately, before doing so it squashed you
+into the concrete floor. Yuck!">
+ <RFATAL>)
+ (ELSE
+ <TELL CR
+"The noise stops." CR>)>)
+ (<AND <HERE? ,STEAM-TUNNEL-EAST>
+ <EQUAL? ,BRICK-FLAG ,BF-BOTH>>
+ <TELL CR
+S "The whining noise ""in the hole stops." CR>)
+ (<HERE? ,CS-ELEVATOR-ROOM>
+ <TELL CR
+"The elevator slows and comes to a stop.">
+ <COND (<BTST .OLD ,E-GO>
+ <TELL
+" The button for the " <GET ,FLOOR-NAMES ,ELEVATOR-LOC> " blinks off.">)>
+ <CRLF>)
+ (<AND <EQUAL? .STOPPING? ,UP-BUTTON ,DOWN-BUTTON>
+ <NOT <HERE? ,CS-ELEVATOR-ROOM>>
+ <ELEVATOR-HERE?>>
+ <TELL CR
+CTHE .STOPPING? " blinks off." CR>)
+ (<GETPT ,HERE ,P?FLOOR>
+ <TELL CR
+"You no longer" ,HEAR-THE-ELEVATOR>)>)
+ (<NOT ,ELEVATOR-STOPPED?>
+ <COND (<HERE? ELEVATOR-PIT>
+ <TELL CR
+S "The whining noise ""is moving ">
+ <COND (<G? ,ELEVATOR-DIRECTION 0>
+ <TELL "away from you">)
+ (ELSE
+ <TELL "closer to you">
+ <COND (<EQUAL? ,ELEVATOR-LOC 1>
+ <TELL
+". In fact, it's very close. It must be just above your head">)>)>
+ <TELL ,PERIOD>)
+ (<AND <HERE? STEAM-TUNNEL-EAST>
+ <EQUAL? ,BRICK-FLAG ,BF-BOTH>>
+ <TELL CR
+S "The whining noise ""from the hole is getting "
+ <COND (<G? ,ELEVATOR-DIRECTION 0>
+ "softer")
+ (ELSE "louder")> ,PERIOD>)
+ (<HERE? CS-ELEVATOR-ROOM>
+ <TELL CR
+"The elevator continues to move " <COND (<G? ,ELEVATOR-DIRECTION 0> "upward")
+ (ELSE "downward")> ,PERIOD>)
+ (<GETPT ,HERE ,P?FLOOR>
+ <TELL CR
+"You" ,HEAR-THE-ELEVATOR>)>)>)>>
+
+<GLOBAL HEAR-THE-ELEVATOR " hear the elevator moving.|">
+
+<ROUTINE HEAR-CHAIN? ()
+ <COND (<ELEVATOR-HERE?> <RTRUE>)
+ (<HERE? ,CS-BASEMENT
+ ,COMP-CENTER
+ ,CS-2ND
+ ,CS-3RD
+ ,STEAM-TUNNEL
+ ,STEAM-TUNNEL-EAST>
+ <RTRUE>)>>
+
+<ROUTINE CHAIN-NOISES ()
+ <TELL CR "From ">
+ <COND (<HERE? ,STEAM-TUNNEL
+ ,STEAM-TUNNEL-EAST>
+ <TELL "the pit">)
+ (ELSE <TELL "below">)>
+ <TELL ", you hear a ">>
+
+<OBJECT ALARM-BUTTON
+ (IN CS-ELEVATOR-ROOM)
+ (DESC "alarm button")
+ (SYNONYM BUTTON)
+ (ADJECTIVE ALARM)
+ (FLAGS NDESCBIT AN)
+ (ACTION ALARM-BUTTON-F)>
+
+<ROUTINE ALARM-BUTTON-F ()
+ <COND (<VERB? PUSH>
+ <TELL
+"For as long as you hold the button down, an ear-splitting alarm bell
+rings." CR>)>>
+
+<OBJECT STOP-SWITCH
+ (IN CS-ELEVATOR-ROOM)
+ (DESC "stop switch")
+ (SYNONYM SWITCH)
+ (ADJECTIVE STOP)
+ (FLAGS NDESCBIT)
+ (ACTION STOP-SWITCH-F)>
+
+<ROUTINE STOP-SWITCH-F ()
+ <COND (<VERB? TURN LAMP-ON LAMP-OFF>
+ <TELL
+"You flip the switch, but" ,LC-NOTHING-HAPPENS CR>)>>
+
+<GLOBAL LC-NOTHING-HAPPENS " nothing happens.">
+
+<OBJECT ELEVATOR
+ (IN LOCAL-GLOBALS)
+ (DESC "elevator")
+ (SYNONYM ELEVATOR)
+ (FLAGS AN VEHBIT)
+ (ACTION ELEVATOR-F)>
+
+<ROUTINE ELEVATOR-F ("AUX" DOOR)
+ <COND (<VERB? EXAMINE>
+ <COND (<HERE? ,CS-ELEVATOR-ROOM>
+ <PERFORM ,V?LOOK>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"You aren't in it." CR>)>)
+ (<VERB? LOOK-INSIDE>
+ <COND (<FSET? <SET DOOR <DOOR-AT-ELEVATOR>> ,OPENBIT>
+ <TELL
+"There is an elevator there, unsurprisingly." CR>)
+ (ELSE
+ <TELL-OPEN-CLOSED .DOOR>)>)
+ (<P? (THROUGH BOARD) ELEVATOR>
+ <COND (<HERE? ,CS-ELEVATOR-ROOM>
+ <TELL ,ALREADY-IN-IT CR>)
+ (ELSE <DO-WALK ,P?SOUTH>)>)
+ (<VERB? SAY>
+ <COND (<HERE? ,CS-ELEVATOR-ROOM>
+ <TELL ,YOURE-IN-IT>)
+ (ELSE
+ <TELL
+"You'll to press one of the call buttons (up or down)." CR>)>)
+ (<P? (PUT THROW) * ELEVATOR>
+ <COND (<HERE? ,CS-ELEVATOR-ROOM>
+ <TELL ,YOURE-IN-IT>)
+ (<FSET? ,ELEVATOR-DOOR ,OPENBIT>
+ <MOVE ,PRSO ,CS-ELEVATOR-ROOM>
+ <TELL "Thrown." CR>)>)
+ (<VERB? OPEN>
+ <NEW-PRSO <COND (<HERE? ,CS-ELEVATOR-ROOM> ,ELEVATOR-DOOR)
+ (ELSE <THIS-FLOOR-DOOR>)>>
+ <RTRUE>)>>
+
+<OBJECT ELEVATOR-DOOR
+ (IN CS-ELEVATOR-ROOM)
+ (DESC "elevator doors")
+ (SYNONYM DOOR DOORS)
+ (ADJECTIVE ELEVATOR)
+ (FLAGS NDESCBIT AN DOORBIT OPENABLE)
+ (ACTION ELEVATOR-DOOR-F)>
+
+<ROUTINE ELEVATOR-DOOR-F ()
+ <COND (<VERB? OPEN>
+ <PERFORM ,V?PUSH ,OPEN-BUTTON>
+ <RTRUE>)
+ (<VERB? CLOSE>
+ <PERFORM ,V?PUSH ,CLOSE-BUTTON>
+ <RTRUE>)
+ (<VERB? THROUGH>
+ <DO-WALK ,P?NORTH>
+ <RTRUE>)
+ (ELSE
+ <COND (<EQUAL? ,ELEVATOR-LOC 0>
+ <REDIRECT ,ELEVATOR-DOOR ,ELEVATOR-DOOR-B>)
+ (<EQUAL? ,ELEVATOR-LOC 1>
+ <REDIRECT ,ELEVATOR-DOOR ,ELEVATOR-DOOR-1>)
+ (<EQUAL? ,ELEVATOR-LOC 2>
+ <REDIRECT ,ELEVATOR-DOOR ,ELEVATOR-DOOR-2>)
+ (<EQUAL? ,ELEVATOR-LOC 3>
+ <REDIRECT ,ELEVATOR-DOOR ,ELEVATOR-DOOR-3>)>)>>
+
+<OBJECT ELEVATOR-DOOR-B
+ (IN CS-BASEMENT ;LOCAL-GLOBALS)
+ (DESC "elevator doors")
+ (SYNONYM DOOR DOORS)
+ (ADJECTIVE ELEVATOR)
+ (FLAGS SEARCHBIT AN CONTBIT DOORBIT OPENABLE)
+ (CONTFCN ELEVATOR-DOOR-CONT)
+ (DESCFCN ELEVATOR-DOORS-DESC)
+ (ACTION ELEVATOR-DOORS-F)>
+
+<OBJECT ELEVATOR-DOOR-1
+ (IN COMP-CENTER ;LOCAL-GLOBALS)
+ (DESC "elevator doors")
+ (SYNONYM DOOR DOORS)
+ (ADJECTIVE ELEVATOR)
+ (FLAGS SEARCHBIT AN CONTBIT DOORBIT OPENABLE)
+ (CONTFCN ELEVATOR-DOOR-CONT)
+ (DESCFCN ELEVATOR-DOORS-DESC)
+ (ACTION ELEVATOR-DOORS-F)>
+
+<OBJECT ELEVATOR-DOOR-2
+ (IN CS-2ND ;LOCAL-GLOBALS)
+ (DESC "elevator doors")
+ (SYNONYM DOOR DOORS)
+ (ADJECTIVE ELEVATOR)
+ (FLAGS SEARCHBIT AN CONTBIT DOORBIT OPENABLE)
+ (CONTFCN ELEVATOR-DOOR-CONT)
+ (DESCFCN ELEVATOR-DOORS-DESC)
+ (ACTION ELEVATOR-DOORS-F)>
+
+<OBJECT ELEVATOR-DOOR-3
+ (IN CS-3RD ;LOCAL-GLOBALS)
+ (DESC "elevator doors")
+ (SYNONYM DOOR DOORS)
+ (ADJECTIVE ELEVATOR)
+ (FLAGS SEARCHBIT AN CONTBIT DOORBIT OPENABLE)
+ (CONTFCN ELEVATOR-DOOR-CONT)
+ (DESCFCN ELEVATOR-DOORS-DESC)
+ (ACTION ELEVATOR-DOORS-F)>
+
+<ROUTINE ELEVATOR-DOORS-DESC (RARG DOOR)
+ <COND (<RARG? OBJDESC?>
+ <COND (<FSET? .DOOR ,OPENBIT> <RTRUE>)
+ (ELSE <RFATAL>)>)
+ (ELSE
+ <BUTTON-GLOWING ,UP-BUTTON ,E-UP>
+ <BUTTON-GLOWING ,DOWN-BUTTON ,E-DOWN>
+ <ELEVATOR-DOORS-OPEN-CLOSED .DOOR>)>>
+
+<ROUTINE BUTTON-GLOWING (OBJ BIT
+ "AUX" (F <GETP ,HERE ,P?FLOOR>))
+ <COND (<AND <GLOBAL-IN? .OBJ ,HERE>
+ <BTST <GET ,BUTTONS .F> .BIT>>
+ <TELL CTHE .OBJ " is glowing. ">)>>
+
+<ROUTINE ELEVATOR-DOORS-OPEN-CLOSED (DOOR "AUX" H?)
+ <TELL CTHE ,ELEVATOR-DOOR " are ">
+ <COND (<FSET? .DOOR ,OPENBIT>
+ <COND (<FIRST? .DOOR>
+ <TELL
+"wedged open with " A <FIRST? .DOOR> ", revealing ">
+ <COND (<SET H? <ELEVATOR-HERE?>>
+ <TELL "the elevator">)
+ (ELSE <TELL "a dim " 'SHAFT-B>)>
+ <TELL " beyond.">
+ <COND (<NOT .H?>
+ <CRLF>
+ <CRLF>
+ <SHAFT-DESC>)>)
+ (ELSE
+ <TELL "open.">)>)
+ (ELSE <TELL "closed.">)>>
+
+<ROUTINE ELEVATOR-DOOR-CONT (RARG "AUX" L)
+ <COND (<VERB? TAKE>
+ <SET L <LOC ,PRSO>>
+ <COND (<EQUAL? <ITAKE> T>
+ <REMOVE-WEDGER ,PRSO .L>
+ <RTRUE>)
+ (ELSE <RTRUE>)>)>>
+
+<ROUTINE OPEN-ELEVATOR-DOOR ()
+ <FSET ,PRSO ,OPENBIT>
+ <COND (<ELEVATOR-HERE?>
+ <FSET ,ELEVATOR-DOOR ,OPENBIT>)
+ (ELSE
+ <COND (<HERE? ,ELEVATOR-PIT>
+ <MOVE ,SHAFT-B ,CS-BASEMENT>)
+ (ELSE
+ <MOVE <FLOOR-SHAFT> ,HERE>)>)>>
+
+<ROUTINE REMOVE-WEDGER (WEDGER DOOR)
+ <FCLEAR .WEDGER ,NDESCBIT>
+ <CLOSE-ELEVATOR-DOOR .DOOR>
+ <COND (<VERB? TAKE>
+ <TELL "You take ">)
+ (ELSE <TELL "You pull ">)>
+ <TELL THE .WEDGER " away, and the doors spring shut">
+ <IN-DARK?>>
+
+<GLOBAL HOLDING-DOORS? <>>
+
+<ROUTINE RELEASE-ELEVATOR-DOORS (D)
+ <COND (,HOLDING-DOORS?
+ <CLOSE-ELEVATOR-DOOR .D>
+ <TELL
+S "You release the ""doors, which spring shut">
+ <IN-DARK?>
+ <RTRUE>)>>
+
+"called when releasing doors because player moved"
+
+<ROUTINE MOVE-FROM-DOORS ("AUX" (D <THIS-FLOOR-DOOR>) H)
+ <SET H <RELEASE-ELEVATOR-DOORS .D>>
+ <COND (<END-OF-CHAIN? .H>)
+ (ELSE <RFALSE>)>>
+
+<ROUTINE END-OF-CHAIN? ("OPT" (H <>))
+ <COND (<AND <HELD? ,CHAIN>
+ <OR ,CHAIN-LOOPED? ,CHAIN-HOOKED?>>
+ <COND (.H <CRLF>)>
+ <TELL S
+"You reach the end of your chain pretty quickly.|">)>>
+
+<ROUTINE ALREADY-WEDGED ()
+ <TELL
+"It's already wedged open with " A <FIRST? ,PRSO> ,PERIOD>>
+
+<ROUTINE NOT-WHILE-MOVING? ()
+ <COND (<AND <QUEUED? I-ELEVATOR-MOVES>
+ <NOT ,ELEVATOR-STOPPED?>>
+ <TELL
+"Not while the elevator is moving!" CR>)>>
+
+<ROUTINE FORCE-DOORS ()
+ <TELL
+"You force the ">
+ <COND (<HERE? ,ELEVATOR-PIT> <TELL "plates">)
+ (ELSE <TELL "doors">)>
+ <TELL " apart with ">
+ <COND (<PRSI? <> ,HANDS>
+ <TELL "your hands">)
+ (ELSE
+ <TELL THE ,PRSI>)>>
+
+<ROUTINE ELEVATOR-DOORS-F ("AUX" (TMP <>) AUTO (EH? <ELEVATOR-HERE?>))
+ <COND (<VERB? EXAMINE>
+ <COND (<HERE? ,ELEVATOR-PIT>
+ <TELL
+"You are looking at the inside of an">
+ <COND (<FSET? ,ELEVATOR-DOOR-B ,OPENBIT>
+ <TELL " open">)>
+ <TELL " elevator door">
+ <COND (<FIRST? ,PRSO>
+ <TELL
+". It's held open by " A <FIRST? ,PRSO>>)>
+ <TELL ,PERIOD>)
+ (ELSE
+ <ELEVATOR-DOORS-OPEN-CLOSED ,PRSO>
+ <CRLF>)>)
+ (<VERB? CLOSE RELEASE>
+ <COND (<FSET? ,PRSO ,OPENBIT>
+ <COND (.EH?
+ <TELL
+"The elevator usually does that itself." CR>)
+ (<SET TMP <FIRST? ,PRSO>>
+ <MOVE .TMP ,HERE>
+ <REMOVE-WEDGER .TMP ,PRSO>
+ <RTRUE>)
+ (ELSE
+ <RELEASE-ELEVATOR-DOORS ,PRSO>)>)
+ (ELSE
+ <TELL "They're closed already." CR>)>)
+ (<VERB? LOOK-INSIDE>
+ <COND (<FSET? ,PRSO ,OPENBIT>
+ <TELL "You can see the ">
+ <COND (<HERE? ,ELEVATOR-PIT>
+ <TELL
+"basement of the " 'COMP-CENTER "." CR>)
+ (.EH?
+ <TELL ,THE-INTERIOR ,PERIOD>)
+ (ELSE
+ <TELL
+'SHAFT-B ". ">
+ <PERFORM-PRSA <FLOOR-SHAFT>>
+ <RTRUE>)>)
+ (ELSE
+ <TELL
+"They're closed, opaque, and otherwise non-transparent." CR>)>)
+ (<VERB? THROUGH>
+ <DO-WALK ,P?SOUTH>
+ <RTRUE>)
+ (<P? PUT * (ELEVATOR-DOOR-B
+ ELEVATOR-DOOR-1
+ ELEVATOR-DOOR-2
+ ELEVATOR-DOOR-3)>
+ <COND (<FIRST? ,PRSI>
+ <TELL
+CTHE <FIRST? ,PRSI> " is already holding it open." CR>)
+ (<FSET? ,PRSI ,OPENBIT>
+ <SWAP-VERB ,V?WEDGE>
+ <RTRUE>)
+ (ELSE
+ <TELL
+,YOU-CANT "until it's open." CR>)>)
+ (<VERB? OPEN PRY>
+ <COND (<FSET? ,PRSO ,OPENBIT>
+ <COND (<FIRST? ,PRSO>
+ <ALREADY-WEDGED>)
+ (,HOLDING-DOORS?
+ <TELL ,HOLDING-IS-ALL " It's not easy." CR>)
+ (.EH?
+ <ALREADY-OPEN>)>)
+ (.EH?
+ <COND (<HERE? ,CS-ELEVATOR-ROOM>
+ <TELL
+"You are in the elevator">)
+ (ELSE
+ <TELL
+S "The elevator is ""here">)>
+ <TELL
+", so the doors will open when you press ">
+ <COND (<HERE? ,CS-ELEVATOR-ROOM>
+ <TELL THE ,OPEN-BUTTON "." CR>)
+ (ELSE
+ <TELL "a call button." CR>)>)
+ (<PRSI? <> ,HANDS ,CROWBAR
+ ,AXE ,BOLT-CUTTER ,KNIFE>
+ <COND (<NOT-WHILE-MOVING?> <RTRUE>)>
+ <SETG HOLDING-DOORS? T>
+ <OPEN-ELEVATOR-DOOR>
+ <FORCE-DOORS>
+ <TELL ", barely able to hold them open. Beyond you
+see ">
+ <COND (<HERE? ,ELEVATOR-PIT>
+ <TELL
+"the basement." CR>)
+ (ELSE
+ <COND (<HERE? ,CS-BASEMENT>
+ <TELL
+"the bottom of the " 'SHAFT-B " only a few feet below. ">)
+ (ELSE
+ <TELL
+"the " 'SHAFT-B ". ">)>
+ <SHAFT-DESC>
+ <CRLF>
+ <RTRUE>)>)
+ (ELSE
+ <WITH-PRSI?>)>)
+ (<P? PUT-BETWEEN * (ELEVATOR-DOOR-B
+ ELEVATOR-DOOR-1
+ ELEVATOR-DOOR-2
+ ELEVATOR-DOOR-3)>
+ <SWAP-VERB ,V?WEDGE>
+ <RTRUE>)
+ (<P? WEDGE (ELEVATOR-DOOR-B
+ ELEVATOR-DOOR-1
+ ELEVATOR-DOOR-2
+ ELEVATOR-DOOR-3)>
+ <COND (<PRSO? ,PRSI>
+ <TELL-YUKS>
+ <RTRUE>)
+ (<FIRST? ,PRSO>
+ <ALREADY-WEDGED>
+ <RTRUE>)>
+ <COND (<NOT-WHILE-MOVING?>
+ <RTRUE>)
+ (<NOT <FSET? ,PRSO ,OPENBIT>>
+ <FORCE-DOORS>
+ <TELL ", revealing ">
+ <COND (<OR <HERE? ,ELEVATOR-PIT>
+ <AND <HERE? ,CS-ELEVATOR-ROOM>
+ <EQUAL? ,ELEVATOR-LOC 0>>>
+ <TELL
+"the basement of the " 'COMP-CENTER ". ">)
+ (<HERE? ,CS-ELEVATOR-ROOM>
+ <COND (<EQUAL? ,ELEVATOR-LOC 1>
+ <TELL "a lobby." CR>)
+ (ELSE
+ <TELL
+"a corridor." CR>)>)
+ (<NOT .EH?>
+ <SET TMP T>
+ <TELL
+"a dark " 'SHAFT-B ". ">)
+ (ELSE
+ <TELL ,THE-INTERIOR ". ">)>)>
+ <COND (<EQUAL? ,PRSI ,CROWBAR ,BOLT-CUTTER ,AXE>
+ <OPEN-ELEVATOR-DOOR>
+ <FSET ,PRSI ,NDESCBIT>
+ <SETG HOLDING-DOORS? <>>
+ <MOVE ,PRSI ,PRSO>
+ <TELL
+CTHE ,PRSI " wedges nicely between the doors, holding them securely
+open.">
+ <COND (.TMP
+ <TELL " ">
+ <SHAFT-DESC>)>
+ <CRLF>
+ <RTRUE>)
+ (<EQUAL? ,PRSI ,PLASTIC-CONTAINER>
+ <SET TMP <ROB ,PRSI ,HERE>>
+ <REMOVE ,PRSI>
+ <TELL
+"The plastic container holds the doors open for a moment, and then
+is crushed by the force.">
+ <COND (.TMP
+ <TELL
+" The contents of the container spill to the ground.">)>
+ <CRLF>)
+ (ELSE
+ <TELL
+,YOU-CANT "wedge the door with " A ,PRSI ,PERIOD>)>)>>
+
+<GLOBAL HOLDING-IS-ALL "Holding the doors open is all you can do.">
+
+<GLOBAL THE-INTERIOR "the interior of the elevator">
+
+<OBJECT UP-BUTTON
+ (IN LOCAL-GLOBALS)
+ (DESC "up-arrow")
+ (SYNONYM BUTTON ARROW)
+ (ADJECTIVE UP-ARROW CALL ELEVATOR)
+ (FLAGS NDESCBIT AN)
+ (ACTION UP-BUTTON-F)>
+
+<OBJECT DOWN-BUTTON
+ (IN LOCAL-GLOBALS)
+ (DESC "down-arrow")
+ (SYNONYM BUTTON ARROW)
+ (ADJECTIVE DOWN-ARROW CALL ELEVATOR)
+ (FLAGS NDESCBIT)
+ (ACTION DOWN-BUTTON-F)>
+
+<ROUTINE DESCRIBE-STAIRS ()
+ <TELL " Stairs also lead ">
+ <COND (<HERE? ,COMP-CENTER ,CS-2ND>
+ <TELL "up and down">)
+ (<HERE? ,CS-BASEMENT>
+ <TELL "up">)
+ (ELSE <TELL "down">)>
+ <TELL ", for the energetic. ">>
+
+<ROUTINE UP-BUTTON-F ("OPT" (BIT ,E-UP)"AUX" OLD FLOOR)
+ <SET FLOOR <GETP ,HERE ,P?FLOOR>>
+ <SET OLD <GET ,BUTTONS .FLOOR>>
+ <COND (<VERB? EXAMINE>
+ <COND (<BTST .OLD .BIT>
+ <TELL CTHE ,PRSO " is glowing." CR>)>)
+ (<VERB? PUSH>
+ <COND (<NOT <BTST .OLD .BIT>>
+ <COND (<AND ,ELEVATOR-STOPPED?
+ <EQUAL? <GETP ,HERE ,P?FLOOR>
+ ,ELEVATOR-LOC>>
+ <DEQUEUE I-ELEVATOR-MOVES>
+ <QUEUE I-ELEVATOR-DOOR-OPENS 1>
+ <TELL
+"You push " THE ,PRSO ,PERIOD>)
+ (ELSE
+ <PUT ,BUTTONS .FLOOR <BOR .BIT .OLD>>
+ <COND (,ELEVATOR-STOPPED?
+ <PICK-ELEVATOR-DIRECTION>
+ <COND (<NOT <QUEUED?
+ I-ELEVATOR-DOOR-CLOSES>>
+ <QUEUE I-ELEVATOR-MOVES 1 T>)>)>
+ <TELL
+CTHE ,PRSO S " begins to glow.|">)>)
+ (ELSE
+ <TELL ,ALREADY-GLOWING>)>)>>
+
+<GLOBAL ALREADY-GLOWING "That button is already glowing.|">
+
+<ROUTINE DOWN-BUTTON-F ()
+ <UP-BUTTON-F ,E-DOWN>>
+
+<CONSTANT E-GO 1> ;"elevator told to go to a floor"
+<CONSTANT E-UP 2> ;"elevator told to come to a floor"
+<CONSTANT E-DOWN 4> ;"elevator told to come to a floor"
+
+<GLOBAL BUTTONS <TABLE 0 0 0 0>>
+<GLOBAL ELEVATOR-LOC:NUMBER 1>
+<GLOBAL ELEVATOR-DIRECTION 1> ;"down"
+<GLOBAL ELEVATOR-STOPPED? 1>
+
+<ROUTINE CS-ELEVATOR-ENTER ()
+ <COND (<WINNER? ,URCHIN> <RFALSE>)
+ (<AND ,ELEVATOR-STOPPED?
+ <EQUAL? ,ELEVATOR-LOC <GETP ,HERE ,P?FLOOR>>>
+ <COND (<FSET? <DOOR-AT-ELEVATOR> ,OPENBIT>
+ <COND (<END-OF-CHAIN?> <RFALSE>)
+ (ELSE ,CS-ELEVATOR-ROOM)>)
+ (ELSE
+ <TELL
+CTHE ,ELEVATOR-DOOR " aren't open." CR>
+ <RFALSE>)>)
+ (<AND <HERE? ,CS-BASEMENT>
+ <FSET? ,ELEVATOR-DOOR-B ,OPENBIT>>
+ <CS-PIT-ENTER>)
+ (<AND <FSET? <THIS-FLOOR-DOOR> ,OPENBIT>
+ <FIRST? <THIS-FLOOR-DOOR>>>
+ <TELL
+"You would fall ">
+ <COND (<IN? ,ELEVATOR-FLOOR ,HERE>
+ <TELL "onto the machinery">)
+ (ELSE
+ <TELL ,INTO-THE-SHAFT>)>
+ <TELL ". Not a pretty fate." CR>
+ <RFALSE>)
+ (ELSE
+ <TELL "The elevator isn't here." CR>
+ <RFALSE>)>>
+
+<GLOBAL INTO-THE-SHAFT "into the elevator shaft">
+
+<ROUTINE CS-ELEVATOR-EXIT ()
+ <COND (,ELEVATOR-STOPPED?
+ <COND (<NOT <FSET? <DOOR-AT-ELEVATOR> ,OPENBIT>>
+ <TELL CTHE ,ELEVATOR-DOOR " are closed." CR>
+ <RFALSE>)
+ (<ZERO? ,ELEVATOR-LOC>
+ ,CS-BASEMENT)
+ (<EQUAL? ,ELEVATOR-LOC 1>
+ ,COMP-CENTER)
+ (<EQUAL? ,ELEVATOR-LOC 2>
+ ,CS-2ND)
+ (<EQUAL? ,ELEVATOR-LOC 3>
+ ,CS-3RD)>)
+ (ELSE
+ <TELL ,STILL-MOVING CR>
+ <RFALSE>)>>
+
+<GLOBAL STILL-MOVING "The elevator is still moving.">
+
+<ROOM AERO-STAIRS
+ (IN ROOMS)
+ (DESC "Stairway")
+ (LDESC
+"A dimly lit stairway leads up and down from here. A corridor continues
+east.")
+ (UP TO AERO-LOBBY)
+ (EAST TO AERO-BASEMENT)
+ (DOWN TO SUB-BASEMENT)
+ (FLAGS ONBIT)>
+
+<ROOM AERO-BASEMENT
+ (IN ROOMS)
+ (DESC "Aero Basement")
+ (LDESC
+"This basement level room is made of smooth, damp-seeming concrete.
+Fluorescent lights cast harsh shadows. To the west is a stairway, and
+to the east the basement area continues.")
+ (EAST TO CS-BASEMENT)
+ (WEST TO AERO-STAIRS)
+ ;(ACTION AERO-BASEMENT-F)
+ (FLAGS ONBIT)>
+
+;<ROUTINE AERO-BASEMENT-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+ CR>)>>
+
+<ROUTINE HEAVY-JUNK? (WHO "AUX" (F <FIRST? .WHO>))
+ <REPEAT ()
+ <COND (<NOT .F> <RFALSE>)
+ (<AND <EQUAL? .F ,HAND>
+ <FSET? .F ,PERSON>>)
+ (<EQUAL? .F ,CROWBAR>)
+ (<G? <GETP .F ,P?SIZE> 5>
+ <RETURN .F>)>
+ <SET F <NEXT? .F>>>>
+
+<ROUTINE TOMB-SQUEEZE ("AUX" TMP)
+ <COND (<WINNER? ,PLAYER>
+ <COND (<SET TMP <HEAVY-JUNK? ,WINNER>>
+ <TELL "It's too tight a fit carrying " THE .TMP ,PERIOD>
+ <THIS-IS-IT .TMP>
+ <>)
+ (<HERE? ,TOMB>
+ ,SUB-BASEMENT)
+ (ELSE
+ ,TOMB)>)
+ (ELSE
+ <COND (<IN? ,WINNER ,TOMB>
+ ,SUB-BASEMENT)
+ (ELSE
+ ,TOMB)>)>>
+
+<ROOM SUB-BASEMENT
+ (IN ROOMS)
+ (DESC "Subbasement")
+ (LDESC
+"This is the subbasement of the Aeronautical Engineering Building. A
+stairway leads up. A narrow
+crack in the northwest corner of the room opens into a larger
+space.")
+ (UP TO AERO-STAIRS)
+ (NW PER TOMB-SQUEEZE)
+ ;(ACTION SUB-BASEMENT-F)
+ (FLAGS ONBIT)>
+
+;<ROUTINE SUB-BASEMENT-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+ CR>)>>
+
+<ROOM TOMB
+ (IN ROOMS)
+ (DESC "Tomb")
+ (SE PER TOMB-SQUEEZE)
+ (OUT PER TOMB-SQUEEZE)
+ (DOWN TO TUNNEL IF ACCESS-HATCH IS OPEN)
+ (FLAGS ONBIT)
+ (ACTION TOMB-F)
+ (GLOBAL GLOBAL-HOLE LADDER GRAFFITI ACCESS-HATCH)>
+
+<ROUTINE TOMB-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL "This is a tiny, narrow, ill-fitting room. It
+appears to have been a left over space from the joining of two
+preexisting buildings. It is roughly coffin shaped. The walls are
+covered by decades of overlaid graffiti, but there is one which is
+painted in huge fluorescent letters that were apparently impossible
+for later artists to completely deface. On the floor is a rusty access
+hatch">
+ <COND (<EQUAL? ,PADLOCK-ON? ,ACCESS-HATCH>
+ <TELL " locked with a huge padlock">)
+ (<FSET? ,ACCESS-HATCH ,OPENBIT>
+ <TELL " which is open">)>
+ <TELL ,PERIOD>)
+ (<RARG? BEG>
+ <COND (<P? (READ EXAMINE) (GRAFFITI WALL)>
+ <TELL
+"It reads \"The Tomb of the Unknown Tool.\"" CR>)
+ (<P? (THROW DROP) * GLOBAL-HOLE>
+ <MOVE ,PRSO ,TUNNEL>
+ <TELL "Gone." CR>)>)>>
+
+<OBJECT LADDER
+ (IN LOCAL-GLOBALS)
+ (DESC "ladder")
+ (SYNONYM LADDER)
+ (ADJECTIVE RUSTY IRON METAL SHORT)
+ (FLAGS NDESCBIT)
+ (ACTION LADDER-F)>
+
+<ROUTINE LADDER-F ()
+ <COND (<VERB? EXAMINE>
+ <COND (<HERE? ,TOMB ,TUNNEL>
+ <TELL
+"It's a rusty ladder made of welded iron set in the wall." CR>)>)
+ (<VERB? CLIMB-UP>
+ <DO-WALK ,P?UP>)
+ (<VERB? CLIMB-DOWN>
+ <DO-WALK ,P?DOWN>)
+ (<VERB? CLIMB-FOO>
+ <COND (<HERE? ,TOMB ,INSIDE-DOME ,ALCHEMY-LAB>
+ <DO-WALK ,P?DOWN>)
+ (<HERE? ,TUNNEL ,BROWN-ROOF ,UNDER-ALCHEMY-LAB>
+ <DO-WALK ,P?UP>)>)>>
+
+<OBJECT ACCESS-HATCH
+ (IN LOCAL-GLOBALS)
+ (DESC "hatch")
+ (SYNONYM HATCH)
+ (ADJECTIVE ACCESS RUSTY)
+ (FLAGS DOORBIT OPENABLE NDESCBIT LOCKED SEARCHBIT SURFACEBIT CONTBIT)
+ (ACTION ACCESS-HATCH-F)>
+
+<ROUTINE UNLOCK-PADLOCK-FIRST ()
+ <TELL
+CTHE ,PADLOCK " locks " THE ,PADLOCK-ON? " in place" ,PERIOD>>
+
+<ROUTINE ALREADY-LOCKED-TO ()
+ <TELL
+CTHE ,PADLOCK " is already locked to " THE ,PADLOCK-ON? ,PERIOD>>
+
+<ROUTINE ACCESS-HATCH-F ()
+ <COND (<VERB? EXAMINE>
+ <COND (<EQUAL? <GET ,P-NAMW 0> ,W?HOLE>
+ <NEW-VERB ,V?LOOK-INSIDE>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"The hatch is made of stamped, ridged steel. It was originally painted
+institutional grey, but has been the victim of innumerable graffiti
+artists since. You can still make out the stencilled warning
+\"Authorized personnel only\" which has been carefully prefixed by
+\"UN,\" and suffixed by \"This means you!\" both in a disgusting fiery
+red. The hatch is ">
+ <COND (<EQUAL? ,PADLOCK-ON? ,ACCESS-HATCH>
+ <TELL "locked with a padlock">)
+ (ELSE <TELL "unlocked">)>
+ <TELL ,PERIOD>)>)
+ (<VERB? UNLOCK>
+ <NEW-PRSO ,PADLOCK>
+ <RTRUE>)
+ (<VERB? OPEN RAISE>
+ <COND (<FSET? ,PRSO ,LOCKED>
+ <UNLOCK-PADLOCK-FIRST>)
+ (<NOT <FSET? ,PRSO ,OPENBIT>>
+ <PUT-GLOBAL ,HERE 0 ,GLOBAL-HOLE>
+ <PUT-GLOBAL ,HERE 1 ,LADDER>
+ <FSET ,PRSO ,OPENBIT>
+ <FSET ,TUNNEL ,ONBIT>
+ <FSET ,TUNNEL-EAST ,ONBIT>
+ <FSET ,TUNNEL-WEST ,ONBIT>
+ <TELL
+"The hatch is heavy, and its hinges are rusty, but ">
+ <COND (<HERE? ,TUNNEL>
+ <TELL "it opens." CR>)
+ (ELSE
+ <TELL
+"you pull and strain
+and it opens with a scream of metal. Revealed below is a rusty ladder
+leading down. Warm, fetid air coils up out of the hole. There is a burned
+out (no, smashed) utility light set in the wall a few feet down." CR>)>)>)
+ (<VERB? CLOSE LOWER>
+ <COND (<FSET? ,PRSO ,OPENBIT>
+ <PUT-GLOBAL ,HERE 0 0>
+ <PUT-GLOBAL ,HERE 1 0>
+ <FCLEAR ,TUNNEL ,ONBIT>
+ <FCLEAR ,TUNNEL-EAST ,ONBIT>
+ <FCLEAR ,TUNNEL-WEST ,ONBIT>
+ <FCLEAR ,ACCESS-HATCH ,OPENBIT>
+ <TELL "The hatch closes">
+ <IN-DARK?>)>)
+ (<OR <P? LOCK ACCESS-HATCH PADLOCK>
+ <P? PUT-ON PADLOCK ACCESS-HATCH>>
+ <COND (,PADLOCK-ON?
+ <ALREADY-LOCKED-TO>)
+ (<FSET? ,ACCESS-HATCH ,LOCKED>
+ <TELL ,IT-ALREADY-IS>)
+ (ELSE
+ <SETG PADLOCK-ON? ,ACCESS-HATCH>
+ <FSET ,PADLOCK ,NDESCBIT>
+ <FCLEAR ,PADLOCK ,OPENBIT>
+ <FSET ,PADLOCK ,LOCKED>
+ <MOVE ,PADLOCK ,ACCESS-HATCH>
+ <FSET ,ACCESS-HATCH ,LOCKED>
+ <FCLEAR ,ACCESS-HATCH ,OPENBIT>
+ <TELL
+"Locked up safe and secure!" CR>)>)
+ (<VERB? LOOK-INSIDE>
+ <COND (<FSET? ,PRSO ,OPENBIT>
+ <TELL "You see a">
+ <COND (<HERE? ,TOMB>
+ <TELL
+" dark" S " hole leading down." CR>)
+ (ELSE
+ <TELL
+"n oddly shaped small room." CR>)>)
+ (ELSE
+ <TELL-OPEN-CLOSED ,PRSO>)>)
+ (<VERB? THROUGH>
+ <COND (<HERE? ,TUNNEL>
+ <DO-WALK ,P?UP>)
+ (<HERE? ,TOMB>
+ <DO-WALK ,P?DOWN>)>)>>
+
+<OBJECT PADLOCK
+ (IN ACCESS-HATCH)
+ (DESC "padlock")
+ (SYNONYM PADLOCK LOCK)
+ (ADJECTIVE PAD HUGE)
+ (FLAGS NDESCBIT TAKEBIT TRYTAKEBIT LOCKED OPENABLE)
+ (ACTION PADLOCK-F)>
+
+<GLOBAL PADLOCK-ON? ACCESS-HATCH>
+
+<ROUTINE PADLOCK-F ("AUX" LP)
+ <COND (<VERB? EXAMINE>
+ <TELL
+S "The padlock has ""been spray painted many times by graffiti artists.
+It's currently fluorescent purple. In spite of the many coats of
+paint, the lock manages to be rusty and, in fact, almost slimy-looking.
+The padlock is ">
+ <COND (<FSET? ,PADLOCK ,LOCKED>
+ <TELL "locked">
+ <COND (,PADLOCK-ON?
+ <TELL " to " THE ,PADLOCK-ON?>)>)
+ (ELSE <TELL "unlocked">)>
+ <TELL ,PERIOD>)
+ (<VERB? READ>
+ <TELL
+S "The padlock has ""no identifiable brand or symbol on it." CR>)
+ (<AND <VERB? TAKE> ,PADLOCK-ON?>
+ <UNLOCK-PADLOCK-FIRST>)
+ (<VERB? PUT-ON>
+ <SWAP-VERB ,V?LOCK>
+ <RTRUE>)
+ (<VERB? LOCK CLOSE TIE>
+ <COND (,PADLOCK-ON?
+ <ALREADY-LOCKED-TO>)
+ (<PRSI? <> ,MASTER-KEY>
+ <FSET ,PRSO ,LOCKED>
+ <FCLEAR ,PRSO ,OPENBIT>
+ <TELL
+"Okay, you've now closed the padlock." CR>)
+ (<AND <PRSI? ,PADLOCK>
+ <NOT <PRSO? CHAIN CHAIN-1 CHAIN-2 ACCESS-HATCH>>>
+ <CANT-LOCK ,PRSO>)
+ (<PRSO? ,PADLOCK>
+ <COND (<PRSI? CHAIN CHAIN-1 CHAIN-2 ACCESS-HATCH>
+ <PERFORM ,V?LOCK ,PRSI ,PADLOCK>
+ <RTRUE>)
+ (ELSE
+ <CANT-LOCK ,PRSI>)>)>)
+ (<OR <VERB? UNLOCK>
+ <AND <VERB? OPEN> <FSET? ,PADLOCK ,LOCKED>>>
+ <COND (<NOT <FSET? ,PRSO ,LOCKED>>
+ <TELL ,IT-ALREADY-IS>)
+ (<NOT ,PRSI>
+ <TELL
+,YOU-HAVE-TO "use a key for that." CR>)
+ (<PRSI? ,MASTER-KEY>
+ <COND (,PADLOCK-ON?
+ <SET LP <LOC ,PADLOCK>>
+ <FCLEAR .LP ,LOCKED>
+ <COND (<IN? .LP ,LOCAL-GLOBALS>
+ <MOVE ,PADLOCK ,HERE>)
+ (ELSE
+ <MOVE ,PADLOCK <LOC .LP>>)>)>
+ <FCLEAR ,PADLOCK ,NDESCBIT>
+ <FCLEAR ,PADLOCK ,LOCKED>
+ <FSET ,PADLOCK ,OPENBIT>
+ <TELL
+"The lock, though rusty and unwilling, opens">
+ <COND (,PADLOCK-ON?
+ <TELL ", releasing " THE ,PADLOCK-ON?>)>
+ <SETG PADLOCK-ON? <>>
+ <TELL ,PERIOD>)
+ (<PRSI? ,KEY-1 ,KEY-2 ,KEY-3 ,KEY-4>
+ <TELL
+CTHE ,PRSI S " doesn't appear to ""open this lock." CR>)
+ (<NOT ,PRSI>
+ <TELL S "You don't have ""a key." CR>)
+ (ELSE
+ <TELL
+,YOU-CANT "open this lock with " A ,PRSI "!" CR>)>)
+ (<P? (MUNG CUT ATTACK) PADLOCK>
+ <COND (<PRSI? ,SMOOTH-STONE>
+ <TELL
+"You smash against the padlock with the stone. As expected, there is
+no result. In fact, both stone and padlock are unmarred." CR>)
+ (<PRSI? ,AXE>
+ <TELL
+"All you succeed in doing is blunting the axe a little." CR>)
+ (ELSE
+ <TELL
+"In spite of its present defacement, this is a good padlock. Your
+feeble attempts have no effect." CR>)>)>>
+
+<ROUTINE CANT-LOCK (OBJ)
+ <TELL
+CTHE ,PADLOCK " can't lock onto " THE .OBJ ,PERIOD>>
+
+<OBJECT GRAFFITI
+ (IN LOCAL-GLOBALS)
+ (DESC "graffiti")
+ (SYNONYM GRAFFITI LETTERS)
+ (ADJECTIVE HUGE FLUORESCENT)
+ (ACTION GRAFFITI-F)>
+
+<ROUTINE GRAFFITI-F ()
+ <COND (<VERB? READ EXAMINE>
+ <TELL "\"" <PICK-ONE ,GRAFFITI-TABLE> "\"" CR>)>>
+
+<CONSTANT GRAFFITI-TABLE
+ <LTABLE 0
+ "Kilroy was here."
+ "Tech is hell."
+ "I.H.T.F.P."
+ "'God is dead' --Nietzsche|
+'Nietzsche is dead' --God">>
+
+<ROUTINE STEAM-EXIT ()
+ <COND (<FSET? ,PRESSURE-VALVE ,OPENBIT>
+ <COND (<WINNER? ,PLAYER>
+ <TELL
+"You would be plunging into scalding steam. Not such a smart idea, if
+you ask me." CR>)>
+ <RFALSE>)
+ (<HERE? ,TUNNEL> ,TUNNEL-EAST)
+ (ELSE ,TUNNEL)>>
+
+<ROUTINE RATS-EXIT ("AUX" H)
+ <COND (<AND <IN? ,RATS ,HERE>
+ <NOT ,ON-CABLE?>>
+ <SETG RATS-HERE <+ ,RATS-HERE 1>>
+ <TELL
+"You plunge into the mass of rats, but there are too many of them, and
+you can't force your way past." CR>
+ <RFALSE>)
+ (<HERE? ,TUNNEL-WEST> ,TUNNEL-ENTRANCE)
+ (<HERE? ,TUNNEL> ,TUNNEL-WEST)
+ (<HERE? ,TUNNEL-EAST>
+ <STEAM-EXIT>)
+ (<HERE? ,STEAM-TUNNEL> ,TUNNEL-EAST)
+ (<HERE? ,STEAM-TUNNEL-EAST> ,STEAM-TUNNEL)>>
+
+<ROOM TUNNEL
+ (IN ROOMS)
+ (DESC "Steam Tunnel")
+ (UP TO TOMB IF ACCESS-HATCH IS OPEN)
+ (EAST PER STEAM-EXIT) ;TUNNEL-EAST
+ (WEST PER RATS-EXIT) ;TUNNEL-WEST
+ (ACTION TUNNEL-F)
+ (VALUE 5)
+ (GLOBAL ACCESS-HATCH LADDER CABLE STEAM-PIPES)>
+
+<ROUTINE TUNNEL-F (RARG)
+ <COND (<RARG? LOOK>
+ <TUNNEL-AND-PIPE>
+ <TELL
+"You have
+gone from the arctic to the tropics. The concrete tunnel has odd molds
+and fungi growing on its walls and ceiling, and the floor is squishy.
+Torn clots of insulation litter the floor.
+Along the ceiling runs a thick tangle of coaxial
+cable. The tunnel heads east and west. A rusty metal ladder leads up."
+CR>)
+ (<RARG? BEG>
+ <COND (,RATS-HERE
+ <COND (<AND <VERB? WALK>
+ <EQUAL? ,P-WALK-DIR ,P?UP>>
+ ;<COND (<NOT <LOC ,DEAD-RAT>>
+ <MOVE ,DEAD-RAT ,HERE>)>
+ ;<SETG RATS-HERE 0>
+ <SETG ON-CABLE? <>>
+ <TELL
+"You force your way through the mass of rats, grabbing onto the rusty
+ladder like a mast on a stormy sea, and begin to pull your way up. A few
+rats drop off, squealing in anger. You climb higher, reaching the hatch,
+as the last of the rats drops to the floor below." CR CR>
+ <RFALSE>)
+ (<FOOD-FOR-RATS>)>)>)
+ (<RARG? ENTER>
+ <COND (<NOT <ZERO? <GETP ,PRESSURE-VALVE ,P?VALUE>>>
+ <DEQUEUE I-RATS-GO-AWAY>
+ <QUEUE I-RATS -1>)>)>>
+
+;<GLOBAL FLASK-SCORE 5> ;"for getting flask into steam tunnel"
+
+<ROUTINE THROW-FOOD ()
+ <REMOVE ,PRSO>
+ <TELL
+"A small contingent of rats falls greedily upon " THE ,PRSO ", biting
+and scratching, fighting desperately for it. The rest of the rats are
+not distracted, however." CR>>
+
+<OBJECT CROWBAR
+ (IN TEMPORARY-BASEMENT)
+ (DESC "crowbar")
+ (SYNONYM CROWBAR BAR)
+ (ADJECTIVE RUSTY)
+ (SIZE 10)
+ (FLAGS TAKEBIT WEAPONBIT)
+ ;(ACTION CROWBAR-F)>
+
+;<ROUTINE CROWBAR-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a rusty, somewhat battered crowbar." CR>)>>
+
+<ROOM TUNNEL-EAST
+ (IN ROOMS)
+ (DESC "Steam Tunnel")
+ (WEST PER RATS-EXIT) ;TUNNEL
+ (EAST TO STEAM-TUNNEL)
+ (GLOBAL CABLE STEAM-PIPES)
+ (ACTION TUNNEL-EAST-F)>
+
+<ROUTINE TUNNEL-EAST-F (RARG)
+ <COND (<RARG? LOOK>
+ <TUNNEL-AND-PIPE>
+ <TELL
+"A thick bundle of coaxial cable runs east to
+west along the ceiling. There is a pressure release valve on the steam
+pipe here.">
+ <COND (<FSET? ,PRESSURE-VALVE ,OPENBIT>
+ <TELL " The valve is" ,WIDE-OPEN>)>
+ <CRLF>)
+ (<RARG? BEG>
+ <FOOD-FOR-RATS>)>>
+
+<ROUTINE FOOD-FOR-RATS ()
+ <COND (,RATS-HERE
+ <COND (<OR <VERB? DROP>
+ <P? GIVE * ,RATS>>
+ <COND (<FSET? ,PRSO ,FOODBIT>
+ <THROW-FOOD>)>)>)>>
+
+<ROOM STEAM-TUNNEL
+ (IN ROOMS)
+ (DESC "Steam Tunnel")
+ (LDESC
+"The steam tunnel is narrow here, and its construction is more archaic.
+It's now mostly brick, although the floor is concrete. The steam pipe
+and coaxial cable continue along their appointed paths. The tunnel is
+damp and even a little muddy.")
+ (WEST PER RATS-EXIT) ;TUNNEL-EAST
+ (EAST TO STEAM-TUNNEL-EAST)
+ (GLOBAL CABLE STEAM-PIPES)
+ (ACTION STEAM-TUNNEL-F)>
+
+<ROUTINE STEAM-TUNNEL-F (RARG)
+ <COND ;(<RARG? LOOK>
+ <TELL
+ CR>)
+ (<RARG? BEG>
+ <FOOD-FOR-RATS>)>>
+
+<ROOM STEAM-TUNNEL-EAST
+ (IN ROOMS)
+ (DESC "Steam Tunnel")
+ (WEST PER RATS-EXIT) ;STEAM-TUNNEL
+ (EAST "The tunnel ends here, in a dank, dripping brick wall.")
+ (SOUTH PER ELEVATOR-PIT-ENTER)
+ (GLOBAL CABLE STEAM-PIPES ROD CHAIN-2)
+ (ACTION STEAM-TUNNEL-EAST-F)>
+
+<ROUTINE ELEVATOR-PIT-ENTER ()
+ <COND (,BRICK-WALL-FLAG
+ <COND (<ZERO? ,ELEVATOR-LOC>
+ <TELL
+"A " 'ELEVATOR-FLOOR " blocks your way." CR>
+ <RFALSE>)
+ (ELSE
+ ,ELEVATOR-PIT)>)
+ (ELSE
+ <TELL "You are trying to walk through a brick wall." CR>
+ <RFALSE>)>>
+
+<ROUTINE STEAM-TUNNEL-EAST-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"The steam pipe and coaxial cable turn upwards and disappear into the
+ceiling here. The tunnel itself comes to an end in a grimy, damp, and
+dripping triad of crumbling brick walls.">
+ <COND (<AND <NOT ,BRICK-WALL-FLAG>
+ <NOT ,BRICK-FLAG>>
+ <TELL
+" The south wall looks particularly decrepit.">)>
+ <CRLF>)
+ (<RARG? BEG>
+ <COND (<P? RUB AIR>
+ <NEW-PRSO ,BRICK-WALL>
+ <RTRUE>)
+ (<P? THROUGH GLOBAL-HOLE>
+ <DO-WALK ,P?SOUTH>)
+ (ELSE
+ <FOOD-FOR-RATS>)>)
+ (<RARG? ENTER>
+ <MOVE-WALL ,A?SOUTH>
+ <COND (<NOT ,BRICK-WALL-FLAG>
+ <COND (<NOT <BTST ,BRICK-FLAG ,BF-TUNNEL>>
+ <MOVE ,BROKEN-BRICK ,BRICK-WALL>)
+ (<NOT <BTST ,BRICK-FLAG ,BF-PIT>>
+ <MOVE ,NEW-BRICK ,BRICK-WALL>)>)>
+ <RANDOM-ELEVATOR-MOTION>
+ ;<COND (<HELD? ,FLASK>
+ <SETG SCORE <+ ,SCORE ,FLASK-SCORE>>
+ <SETG FLASK-SCORE 0>)>
+ <COND (<AND <NOT <ZERO? <GETP ,PRESSURE-VALVE ,P?VALUE>>>
+ <NOT <FSET? ,PRESSURE-VALVE ,OPENBIT>>>
+ <DEQUEUE I-RATS-GO-AWAY>
+ <QUEUE I-RATS -1>)>)>>
+
+<OBJECT NEW-BRICK
+ (DESC "new brick")
+ (SYNONYM BRICK ;BRICKS)
+ (ADJECTIVE LOOSE NEW RECENT NEWER NEW-LOOKING)
+ (FLAGS NDESCBIT TAKEBIT WEAPONBIT)
+ (ACTION NEW-BRICK-F)>
+
+<ROUTINE NEW-BRICK-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a new brick. It appears to be of relatively recent vintage." CR>)
+ (<P? (PRY ATTACK) * CROWBAR>
+ <COND (<IN? ,PRSO ,BRICK-WALL>
+ <NEW-PRSO ,BRICK-WALL>
+ <RTRUE>)
+ (ELSE
+ <TRY-ANOTHER-BRICK>)>)>>
+
+<ROUTINE TRY-ANOTHER-BRICK ()
+ <TELL
+,YOUVE-ALREADY "pried that brick loose, maybe you should attack the
+wall again." CR>>
+
+<OBJECT BROKEN-BRICK
+ (DESC "broken brick")
+ (SYNONYM BRICK ;BRICKS)
+ (ADJECTIVE LOOSE SLIMY CRUMBLING BROKEN OLD OLDER)
+ (FLAGS NDESCBIT TAKEBIT WEAPONBIT)
+ (ACTION BROKEN-BRICK-F)>
+
+<ROUTINE BROKEN-BRICK-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a crumbling, broken brick. Little bits of mortar still cling
+to it." CR>)
+ (<P? (PRY ATTACK) * CROWBAR>
+ <COND (<IN? ,PRSO ,BRICK-WALL>
+ <NEW-PRSO ,BRICK-WALL>
+ <RTRUE>)
+ (ELSE
+ <TRY-ANOTHER-BRICK>)>)
+ (<VERB? REPAIR>
+ <TELL
+CTHE ,PRSO " isn't that broken." CR>)>>
+
+<OBJECT ROD
+ (IN LOCAL-GLOBALS)
+ (DESC "reinforcing rod")
+ (SYNONYM ROD)
+ (ADJECTIVE RUSTY STEEL REINFORCING)
+ (FLAGS INVISIBLE)
+ (ACTION ROD-F)>
+
+<ROUTINE ROD-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's rusty, obviously didn't help the wall all that much, and runs up
+and down through the hole you have made.">
+ <COND (,CHAIN-LOOPED?
+ <TELL
+" There is a length of greasy chain wrapped around it.">
+ <TELL-IF-LOCKED>)>
+ <CRLF>)
+ (<AND <P? (TAKE UNTIE) CHAIN ROD>
+ ,CHAIN-LOOPED?>
+ <PERFORM-PRSA ,CHAIN-2 ,ROD>
+ <RTRUE>)
+ (<P? LOCK (CHAIN CHAIN-2) ROD>
+ <COND (<AND ,CHAIN-LOOPED?
+ <HELD? ,PADLOCK>>
+ <PERFORM-PRSA ,CHAIN-2 ,PADLOCK>
+ <RTRUE>)
+ (<HELD? ,PADLOCK>
+ <TELL
+"The hasp of the padlock won't fit around the rod." CR>)
+ (ELSE
+ <TELL
+"You don't seem to have anything to lock it with." CR>)>)
+ (<VERB? PRY MOVE>
+ <TELL
+"It's pretty solidly mortared in." CR>)>>
+
+<OBJECT BRICK-HOLE
+ (DESC "hole")
+ (SYNONYM HOLE)
+ (ADJECTIVE SMALL LARGE HUGE)
+ (FLAGS NDESCBIT OPENBIT CONTBIT SEARCHBIT)
+ (ACTION BRICK-HOLE-F)>
+
+<ROUTINE BRICK-HOLE-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL S "There is a ">
+ <COND (,BRICK-WALL-FLAG
+ <TELL
+"huge hole here, where the wall has collapsed." CR>)
+ (<EQUAL? ,BRICK-FLAG ,BF-BOTH>
+ <TELL
+"large hole here, with a reinforcing rod running through it." CR>)
+ (<HOLE-IN-BRICKS?>
+ <TELL
+"small hole in the wall where a brick was removed." CR>)>)
+ (<P? PUT * BRICK-HOLE>
+ <COND (,BRICK-WALL-FLAG
+ <TELL
+"The hole that's there now is big enough for you to walk through.
+Hence, no such luck." CR>)
+ (ELSE
+ <MOVE ,PRSO ,HERE>
+ <TELL
+"You put " THE ,PRSO " in the hole, but ">
+ <COND (<PRSO? ,NEW-BRICK ,BROKEN-BRICK>
+ <TELL
+"it doesn't fit very tightly any more, so ">)
+ (ELSE
+ <TELL
+"as the hole is irregular, ">)>
+ <TELL
+"it falls out again and drops to the floor." CR>)>)
+ (<VERB? THROUGH>
+ <COND (,BRICK-WALL-FLAG
+ <DO-WALK <COND (<HERE? ,ELEVATOR-PIT>
+ ,P?NORTH)
+ (ELSE ,P?SOUTH)>>)
+ (ELSE
+ <TELL
+"The hole is the size of a brick. You are somewhat larger." CR>)>)
+ (<VERB? LOOK-INSIDE>
+ <REDIRECT ,BRICK-HOLE ,BRICK-WALL>)
+ (<VERB? REACH-IN>
+ <COND (,BRICK-WALL-FLAG
+ <TELL
+"Plenty of room there." CR>)
+ (<EQUAL? ,BRICK-FLAG ,BF-BOTH>
+ <TELL
+"You reach in and touch the reinforcing rod." CR>)
+ (ELSE
+ <TELL
+"When you reach in you get the impression there is some metal in the
+hole." CR>)>)>>
+
+<ROUTINE HOLE-IN-BRICKS? ()
+ <OR <EQUAL? ,BRICK-FLAG ,BF-BOTH>
+ <AND <HERE? ,STEAM-TUNNEL-EAST>
+ <EQUAL? ,BRICK-FLAG ,BF-TUNNEL>>
+ <AND <HERE? ,ELEVATOR-PIT>
+ <EQUAL? ,BRICK-FLAG ,BF-PIT>>>>
+
+<OBJECT BRICK-WALL
+ (IN STEAM-TUNNEL-EAST)
+ (DESC "brick wall")
+ (SYNONYM WALL WALLS BRICKS ;GROOVE MORTAR)
+ (ADJECTIVE SOUTH ;NORTH BRICK DAMP DRIPPING CRUMBLING)
+ (FLAGS SEARCHBIT OPENBIT CONTBIT)
+ (CONTFCN BRICK-WALL-CONT)
+ (DESCFCN BRICK-WALL-DESC)
+ (ACTION BRICK-WALL-F)>
+
+<ROUTINE BRICK-WALL-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?>
+ <COND (<OR ,BRICK-WALL-FLAG <HOLE-IN-BRICKS?>>
+ <RTRUE>)
+ (ELSE <RFATAL>)>)
+ (ELSE
+ <TELL "The ">
+ <COND (<HERE? ,STEAM-TUNNEL-EAST>
+ <TELL "southern ">)>
+ <TELL 'BRICK-WALL>
+ <COND (,BRICK-WALL-FLAG
+ <TELL " has an enormous hole ripped in it.">)
+ (ELSE
+ <TELL " has a hole in it.">
+ <COND (<NOT <FSET? ,ROD ,INVISIBLE>>
+ <TELL-ABOUT-ROD>)>)>
+ <RFATAL>)>>
+
+<ROUTINE BRICK-WALL-CONT (RARG)
+ <COND (<VERB? TAKE MOVE>
+ <TELL
+,YOU-CANT S "get a good grip on " THE ,PRSO " with your fingers." CR>)>>
+
+<ROUTINE BRICK-WALL-F ()
+ <COND (<VERB? EXAMINE>
+ <COND (<HERE? ,STEAM-TUNNEL-EAST>
+ <TELL CTHE ,BRICK-WALL " ">
+ <COND (,BRICK-WALL-FLAG
+ <TELL
+"is demolished. There is now a large hole leading south into
+another room." CR>)
+ (<HOLE-IN-BRICKS?>
+ <DESCRIBE-WALL-HOLE "a new-looking"
+ "pretty bad">)
+ (ELSE
+ <TELL
+"is in terrible shape. It's aged and crumbling,
+with grooves between bricks where the mortar has fallen out." CR>)>)
+ (ELSE
+ <TELL CTHE ,BRICK-WALL " ">
+ <COND (,BRICK-WALL-FLAG
+ <TELL
+"is quite ruined. Fortunately it wasn't structural. There are
+big chunks of brick and concrete all over the floor here." CR>)
+ (<HOLE-IN-BRICKS?>
+ <DESCRIBE-WALL-HOLE "an older, crumbly"
+ "okay">)
+ (ELSE
+ <TELL
+"is in pretty good shape. It's relatively new, and
+you can only see one or two loose-looking bricks." CR>)>)>)
+ (<VERB? TAKE MOVE>
+ <TELL
+"Though there are loose bricks, they aren't loose enough for you to
+just pry them out with your fingers." CR>)
+ (<VERB? LISTEN>
+ <COND (<NOT ,BRICK-FLAG>
+ <TELL
+"You place your ear to the wall, slimy and dank as it is, and hear
+nothing. However, you feel a weak current of cool air coming from between
+some of the bricks." CR>)
+ (ELSE
+ <TELL ,COOL-AIR-FLOWING>
+ <COND (<QUEUED? I-ELEVATOR-MOVES>
+ <TELL
+", and you can hear mechanical noises on the other side">)>
+ <TELL ,PERIOD>)>)
+ (<VERB? RUB>
+ <TELL
+"The wall is slimy, dank, and damp. ">
+ <COND (<NOT ,BRICK-FLAG>
+ <TELL
+"You feel a weak current of cool air coming from between some of the
+bricks." CR>)
+ (ELSE
+ <TELL ,COOL-AIR-FLOWING ,PERIOD>)>)
+ (<VERB? ATTACK MUNG>
+ <TELL "It doesn't do much">
+ <COND (<NOT ,BRICK-FLAG>
+ <TELL
+" but loosen a brick in the wall">)>
+ <TELL ,PERIOD>)
+ (<VERB? TAKE-OFF>
+ <COND (<NOT <EQUAL? ,BRICK-FLAG ,BF-BOTH>>
+ <TELL
+S "There is a ""loose brick in the wall, but you can't remove it with
+your hands." CR>)
+ (ELSE
+ <TELL "There aren't any more loose bricks." CR>)>)
+ (<VERB? LOOK-INSIDE>
+ <COND (<HERE? ,STEAM-TUNNEL-EAST>
+ <COND (,BRICK-WALL-FLAG
+ <TELL
+S "There is a ""small rectangular room on the other side of the wall." CR>)
+ (<EQUAL? ,BRICK-FLAG ,BF-BOTH>
+ <TELL
+S "There is an open ""space, a small room containing some machinery."
+,CANT-SEE-TOO-WELL>)
+ (<HOLE-IN-BRICKS?>
+ <TELL ,INSIDE-OF-HOLE>)
+ (ELSE
+ <TELL ,CRACKS-AND-MORTAR>)>)
+ (ELSE
+ <COND (,BRICK-WALL-FLAG
+ <TELL
+"You see and dark and grimy tunnel leading west." CR>)
+ (<EQUAL? ,BRICK-FLAG ,BF-BOTH>
+ <TELL
+"There is some sort of tunnel." ,CANT-SEE-TOO-WELL>)
+ (<HOLE-IN-BRICKS?>
+ <TELL ,INSIDE-OF-HOLE>)
+ (ELSE
+ <TELL ,CRACKS-AND-MORTAR>)>)>)
+ (<VERB? LOWER>
+ <TELL
+"You aren't strong enough to pull down a brick wall." CR>)
+ (<P? (PRY ATTACK) BRICK-WALL CROWBAR>
+ <COND (,BRICK-WALL-FLAG
+ <TELL
+"The hole is already quite large, and further demolition would have
+to involve structural supports." CR>)
+ (<NOT ,BRICK-FLAG>
+ <COND (<HERE? ,ELEVATOR-PIT>
+ <FCLEAR ,NEW-BRICK ,NDESCBIT>
+ <MOVE ,NEW-BRICK ,HERE>
+ <CHANGE-ADJECTIVE ,NEW-BRICK 0>
+ <MOVE ,BROKEN-BRICK ,BRICK-WALL>
+ <SETG BRICK-FLAG <BOR ,BRICK-FLAG ,BF-PIT>>)
+ (ELSE
+ <FCLEAR ,BROKEN-BRICK ,NDESCBIT>
+ <MOVE ,BROKEN-BRICK ,HERE>
+ <CHANGE-ADJECTIVE ,BROKEN-BRICK 0>
+ <MOVE ,NEW-BRICK ,BRICK-WALL>
+ <SETG BRICK-FLAG <BOR ,BRICK-FLAG ,BF-TUNNEL>>)>
+ <MOVE ,BRICK-HOLE ,HERE>
+ <TELL ,WALL-YIELDS "pulls out of the wall." CR>)
+ (<NOT <EQUAL? ,BRICK-FLAG ,BF-BOTH>>
+ <MOVE ,BRICK-HOLE ,HERE>
+ <SETG BRICK-FLAG ,BF-BOTH>
+ <TELL ,WALL-YIELDS>
+ <FCLEAR ,ROD ,INVISIBLE>
+ <COND (<IN? ,BROKEN-BRICK ,BRICK-WALL>
+ <FCLEAR ,BROKEN-BRICK ,NDESCBIT>
+ <MOVE ,BROKEN-BRICK ,STEAM-TUNNEL-EAST>
+ <CHANGE-ADJECTIVE ,BROKEN-BRICK 0>
+ <BRICK-DROPS ,STEAM-TUNNEL-EAST>)
+ (ELSE
+ <FCLEAR ,NEW-BRICK ,NDESCBIT>
+ <MOVE ,NEW-BRICK ,ELEVATOR-PIT>
+ <CHANGE-ADJECTIVE ,NEW-BRICK 0>
+ <BRICK-DROPS ,ELEVATOR-PIT>)>
+ <TELL
+", making a hole through the wall. You can see a rusty steel reinforcing
+rod in the hole.">
+ <COND (<AND <HERE? ,STEAM-TUNNEL-EAST>
+ <NOT ,ELEVATOR-STOPPED?>>
+ <TELL " You hear a whining noise through
+the hole.">)>
+ <CRLF>)
+ (ELSE
+ <TELL
+"There don't seem to be any more bricks as loose as the first two." CR>)>)>>
+
+<GLOBAL INSIDE-OF-HOLE "You see another loose brick inside the hole.|">
+
+<GLOBAL COOL-AIR-FLOWING
+"There is cool air flowing out of the hole">
+
+<ROUTINE BRICK-DROPS (THIS-SIDE)
+ <COND (<HERE? .THIS-SIDE>
+ <TELL
+"comes loose and drops to the ground">)
+ (ELSE
+ <TELL
+"drops to the floor on the other side">)>>
+
+<GLOBAL CRACKS-AND-MORTAR
+"The cracks and crumbled mortar only go partway through.|">
+
+<ROUTINE DESCRIBE-WALL-HOLE (BRICK OK)
+ <TELL "has a brick-size hole ">
+ <COND (<EQUAL? ,BRICK-FLAG ,BF-BOTH>
+ <TELL
+"through it where bricks have been pried out. A steel rod is visible">)
+ (<HOLE-IN-BRICKS?>
+ <TELL
+"in it where a brick was removed. You can see " .BRICK " brick">)>
+ <TELL " in the hole. The rest of the wall is in " .OK " shape." CR>>
+
+<GLOBAL CANT-SEE-TOO-WELL " You can't see too well, though.|">
+
+<GLOBAL WALL-YIELDS
+"The wall grudgingly yields to your efforts. A brick, less well mortared than
+its fellows, ">
+
+<ROOM ELEVATOR-PIT
+ (IN ROOMS)
+ (DESC "Concrete Box")
+ (NORTH TO STEAM-TUNNEL-EAST IF BRICK-WALL-FLAG)
+ (UP PER PIT-DOOR-EXIT)
+ (OUT PER PIT-DOOR-EXIT)
+ (GLOBAL ELEVATOR-DOOR-B ROD CHAIN-2)
+ (VALUE 5)
+ (ACTION ELEVATOR-PIT-F)
+ (THINGS <PSEUDO (<> SHAFT SHAFT-PSEUDO)
+ (RAILROAD RAILS RANDOM-PSEUDO)>)>
+
+<ROUTINE THROUGH-THE (OBJ)
+ <COND (<FSET? .OBJ ,WEARBIT>
+ <TELL " through " THE .OBJ>)>>
+
+<ROUTINE PIT-DOOR-EXIT ()
+ <COND (<FIRST? ,ELEVATOR-DOOR-B>
+ <COND (,RATS-HERE
+ <COND (<L? ,RATS-HERE 2>
+ <SETG RATS-HERE 2>)>
+ <TELL
+"You leap up the wall towards the basement, but the rats are faster!
+They bite your fingers">
+ <THROUGH-THE ,GLOVES>
+ <TELL ", and you release your hold, tumbling back to
+the pit!" CR>
+ <RFALSE>)
+ (ELSE
+ <TELL
+"You climb up the gritty wall and out into the basement." CR CR>
+ ,CS-BASEMENT)>)
+ (<FSET? ,ELEVATOR-DOOR-B ,OPENBIT>
+ <TELL
+"You try to climb up while holding the doors open, but it's just
+outside the realm of possibility." CR>
+ <RFALSE>)
+ (ELSE
+ <TELL
+"There is no apparent way through the closed " 'ELEVATOR-DOOR "." CR>
+ <RFALSE>)>>
+
+<GLOBAL BRICK-FLAG <>> ;"0 = no bricks out
+ 1 = brick in pit out
+ 2 = brick in tunnel out
+ 3 = both bricks out"
+<CONSTANT BF-PIT 1>
+<CONSTANT BF-TUNNEL 2>
+<CONSTANT BF-BOTH 3>
+
+<GLOBAL BRICK-WALL-FLAG <>> ;"destroyed the wall"
+
+<ROUTINE TELL-ABOUT-ROD ()
+ <COND (<NOT <FSET? ,ROD ,INVISIBLE>>
+ <TELL
+" There is a vertical reinforcing rod visible in the middle of the hole.">
+ <COND (,CHAIN-LOOPED?
+ <TELL
+" A chain is" ,LOOPED-AROUND-ROD>
+ <COND (,CHAIN-HOOKED?
+ <TELL " and disappears up into the shaft">)
+ (<IN? ,CHAIN ,ELEVATOR-PIT>
+ <TELL " and trails down onto the floor">)>
+ <TELL ".">
+ <COND (<EQUAL? ,PADLOCK-ON? ,CHAIN-2>
+ <TELL
+" A padlock secures the chain.">)>)>)>>
+
+<GLOBAL LOOPED-AROUND-ROD " looped around the rod">
+
+<ROUTINE ELEVATOR-PIT-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"This small room is pretty bare and featureless. The north wall is
+brick and the other three walls are concrete. The east and west walls
+are adorned with rails not unlike railroad rails. Above you ">
+ <COND (<IN? ,ELEVATOR-FLOOR ,SHAFT-B>
+ <TELL
+"and out of reach, the shaft is blocked by something." CR>)
+ (ELSE
+ <TELL
+"is an empty shaft. On the north side of the shaft is an elevator
+door">
+ <COND (<FIRST? ,ELEVATOR-DOOR-B>
+ <TELL
+" wedged open by " A <FIRST? ,ELEVATOR-DOOR-B>>)
+ (<FSET? ,ELEVATOR-DOOR-B ,OPENBIT>
+ <TELL
+" which you are holding open">)>
+ <TELL ,PERIOD>)>)
+ (<RARG? ENTER>
+ <MOVE-WALL ,A?NORTH>
+ <COND (<NOT ,BRICK-WALL-FLAG>
+ <COND (<NOT <BTST ,BRICK-FLAG ,BF-PIT>>
+ <MOVE ,NEW-BRICK ,BRICK-WALL>)
+ (<NOT <BTST ,BRICK-FLAG ,BF-TUNNEL>>
+ <MOVE ,BROKEN-BRICK ,BRICK-WALL>)>)>
+ <RANDOM-ELEVATOR-MOTION>)
+ (<RARG? BEG>
+ <COND (<AND <VERB? WALK>
+ <NOT <EQUAL? ,P-WALK-DIR ,P?UP>>
+ <HELD? ,CHAIN>
+ ,CHAIN-HOOKED?>
+ <TELL S
+"You reach the end of your chain pretty quickly.|">)
+ (<P? RUB AIR>
+ <NEW-PRSO ,BRICK-WALL>
+ <RTRUE>)
+ (<P? THROUGH GLOBAL-HOLE>
+ <DO-WALK ,P?NORTH>)
+ (<P? LOOK-UP ROOMS>
+ <TELL
+"You see an " 'SHAFT-B "." CR>)
+ (<AND <VERB? WALK>
+ <NOT <EQUAL? ,P-WALK-DIR ,P?UP ,P?OUT>>>
+ <MOVE-FROM-DOORS>)
+ (<P? LISTEN (<> NOISE)>
+ <COND (<NOT ,ELEVATOR-STOPPED?>
+ <TELL
+"You hear the whine of powerful machinery." CR>)
+ (<AND ,BRICK-WALL-FLAG
+ <IN-TUNNEL? ,RATS>>
+ <TELL ,RATS-CHITTERING>)>)>)>>
+
+<ROUTINE MOVE-WALL (A)
+ <MOVE ,BRICK-WALL ,HERE>
+ <CHANGE-ADJECTIVE ,BRICK-WALL 0 .A>
+ <COND (<OR ,BRICK-WALL-FLAG
+ <HOLE-IN-BRICKS?>>
+ <MOVE ,BRICK-HOLE ,HERE>)>>
+
+<GLOBAL RATS-CHITTERING "You hear the chittering of rats.|">
+
+<ROUTINE RANDOM-ELEVATOR-MOTION ()
+ <COND (<PROB 25>
+ <SETG P-NUMBER <- <RANDOM 4> 1>>
+ <PERFORM ,V?PUSH ,FLOOR-BUTTON>
+ <RTRUE>)>>
+
+<OBJECT ELEVATOR-CEILING
+ (IN SHAFT-2)
+ (DESC "tangle of machinery")
+ (SYNONYM TANGLE MACHINE)
+ (FLAGS NDESCBIT OPENBIT SEARCHBIT CONTBIT SURFACEBIT)>
+
+<OBJECT ELEVATOR-FLOOR
+ (IN SHAFT-B)
+ (DESC "tangle of machinery")
+ (SYNONYM TANGLE MACHINE)
+ (FLAGS NDESCBIT OPENBIT SEARCHBIT CONTBIT)
+ (ACTION ELEVATOR-FLOOR-F)>
+
+<ROUTINE ELEVATOR-FLOOR-F ()
+ <COND (<VERB? EXAMINE LOOK-INSIDE>
+ <TELL
+CTHE ,ELEVATOR-FLOOR " is most notable for a metal hook">
+ <COND (,CHAIN-HOOKED?
+ <TELL " with a chain hanging on it">)>
+ <TELL ,PERIOD>)
+ (<P? (TIE PUT PUT-ON) CHAIN>
+ <COND (<NOT ,CHAIN-HOOKED?>
+ <TELL
+"Only the hook seems capable of such a use, so you try that. ">)>
+ <NEW-PRSI ,HOOK>
+ <RTRUE>)>>
+
+<OBJECT SHAFT-B
+ (DESC "elevator shaft")
+ (SYNONYM SHAFT)
+ (ADJECTIVE ELEVATOR)
+ (FLAGS NDESCBIT AN SEARCHBIT OPENBIT CONTBIT VEHBIT)
+ (ACTION SHAFT-F)>
+
+<OBJECT SHAFT-1
+ (DESC "elevator shaft")
+ (SYNONYM SHAFT)
+ (ADJECTIVE ELEVATOR)
+ (FLAGS NDESCBIT AN SEARCHBIT OPENBIT CONTBIT VEHBIT)
+ (ACTION SHAFT-F)>
+
+<OBJECT SHAFT-2
+ (DESC "elevator shaft")
+ (SYNONYM SHAFT)
+ (ADJECTIVE ELEVATOR)
+ (FLAGS NDESCBIT AN SEARCHBIT OPENBIT CONTBIT VEHBIT)
+ (ACTION SHAFT-F)>
+
+<OBJECT SHAFT-3
+ (DESC "elevator shaft")
+ (SYNONYM SHAFT)
+ (ADJECTIVE ELEVATOR)
+ (FLAGS NDESCBIT AN SEARCHBIT OPENBIT CONTBIT VEHBIT)
+ (ACTION SHAFT-F)>
+
+<ROUTINE SHAFT-DESC ("AUX" (OBJ <FLOOR-SHAFT>))
+ <COND (<OR <IN? ,ELEVATOR-FLOOR .OBJ>
+ <IN? ,ELEVATOR-CEILING .OBJ>>
+ <TELL
+"In the " 'SHAFT-B " " A ,ELEVATOR-FLOOR " is visible.">
+ <COND (<IN? ,ELEVATOR-FLOOR .OBJ>
+ <TELL
+" One bit of the tangle is very much like a hook">
+ <COND (,CHAIN-HOOKED?
+ <TELL
+", and indeed, a chain is hanging from it">
+ <COND (<HELD? ,CHAIN>
+ <TELL
+". You are holding the other end of the chain">)
+ (ELSE
+ <TELL
+". The other end of the chain is ">
+ <COND (<IN? ,CHAIN ,HERE>
+ <TELL "on the floor">)
+ (<EQUAL? <META-LOC ,CHAIN>
+ ,HERE>
+ <TELL "in "
+ THE <LOC ,CHAIN>>)
+ (ELSE
+ <TELL
+"dangling in the shaft below">)>)>)>
+ <TELL ".">)
+ (<IN? ,ELEVATOR-CEILING .OBJ>
+ <TELL
+" The machinery has that malevolent mechanical appearance that means
+danger.">)>)
+ (ELSE
+ <TELL
+"The dark shaft opens like a waiting mouth.">)>
+ <RFATAL>>
+
+<ROUTINE LIKE-A-SHAFT ()
+ <TELL
+,IT-LOOKS-LIKE A ,SHAFT-B "." CR>>
+
+<ROUTINE SHAFT-F ()
+ <COND (<VERB? EXAMINE LOOK-INSIDE>
+ <TELL
+"The dark, grimy " 'SHAFT-B " extends up ">
+ <COND (<IN? ,ELEVATOR-FLOOR ,PRSO>
+ <TELL
+"to " A ,ELEVATOR-FLOOR " just above the ceiling level">)
+ (ELSE
+ <TELL "into dimness">)>
+ <TELL " and down ">
+ <COND (<IN? ,ELEVATOR-CEILING ,PRSO>
+ <TELL
+"to a tangle of dangerous-looking lifting machinery at about floor level">)
+ (<HERE? ,CS-BASEMENT>
+ <TELL
+"to a concrete-lined pit below">)
+ (ELSE
+ <TELL "into a dark pit below">)>
+ <COND (<IN? ,ELEVATOR-FLOOR ,PRSO>
+ <TELL
+". " CTHE ,ELEVATOR-FLOOR " includes a hook-like protrusion just inside
+the door">
+ <COND (,CHAIN-HOOKED?
+ <TELL
+". A greasy chain is hooked onto the protrusion, ">
+ <COND (<HELD? ,CHAIN>
+ <TELL "terminating in your hands">)
+ (ELSE
+ <TELL "dropping into the pit">)>)>)>
+ <TELL ,PERIOD>)
+ (<VERB? LOOK-UP>
+ <LIKE-A-SHAFT>)
+ (<P? PUT * (SHAFT-B SHAFT-1 SHAFT-2 SHAFT-3)>
+ <COND (<G? ,ELEVATOR-LOC <GETP ,HERE ,P?FLOOR>>
+ <COND (<AND <PRSO? ,CHAIN>
+ <G? ,ELEVATOR-LOC 1>>
+ <REMOVE ,PRSO> ;"do better eventually?")
+ (ELSE
+ <MOVE ,PRSO ,ELEVATOR-PIT>)>)
+ (ELSE
+ <MOVE ,PRSO ,ELEVATOR-CEILING>)>
+ <TELL "Dropped." CR>)
+ (<VERB? THROUGH BOARD>
+ <COND (<HERE? CS-BASEMENT>
+ <DO-WALK ,P?DOWN>)
+ (ELSE
+ <TELL
+"It's a long way down." CR>)>)>>
+
+<OBJECT HOOK
+ (IN ELEVATOR-FLOOR)
+ (DESC "hook")
+ (SYNONYM HOOK PROTRUSION)
+ (FLAGS NDESCBIT)
+ (ACTION HOOK-F)>
+
+<ROUTINE HOOK-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The hook is actually a very strong looking welded protrusion on the
+bottom of the elevator, but it is hook-like.">
+ <COND (,CHAIN-HOOKED?
+ <TELL
+" One end of a chain is hooked onto it, in fact.">)>
+ <CRLF>)
+ (<AND <P? (TAKE UNTIE) CHAIN HOOK>
+ ,CHAIN-HOOKED?>
+ <NEW-PRSO ,CHAIN-1>
+ <RTRUE>)>>
+
+<OBJECT CHAIN ;"chain in hand or on ground"
+ (IN ELEVATOR-PIT)
+ (DESC "greasy chain")
+ (SYNONYM CHAIN)
+ (ADJECTIVE GREASY)
+ (FLAGS TAKEBIT SURFACEBIT CONTBIT SEARCHBIT)
+ (SIZE 20)
+ (DESCFCN CHAIN-DESC)
+ (GENERIC GENERIC-CHAIN-F)
+ (ACTION CHAIN-F)>
+
+<ROUTINE GENERIC-CHAIN-F ()
+ <COND (<LOC ,CHAIN> ,CHAIN)
+ (<LOC ,CHAIN-2> ,CHAIN-2)
+ (ELSE ,CHAIN-1)>>
+
+<OBJECT CHAIN-1 ;"chain on hook"
+ (DESC "greasy chain")
+ (SYNONYM CHAIN)
+ (ADJECTIVE GREASY)
+ (FLAGS NDESCBIT TAKEBIT SURFACEBIT CONTBIT SEARCHBIT)
+ (SIZE 20)
+ (DESCFCN CHAIN-DESC)
+ (GENERIC GENERIC-CHAIN-F)
+ (ACTION CHAIN-F)>
+
+<OBJECT CHAIN-2 ;"chain on rod"
+ (IN LOCAL-GLOBALS)
+ (DESC "greasy chain")
+ (SYNONYM CHAIN)
+ (ADJECTIVE GREASY)
+ (FLAGS INVISIBLE NDESCBIT TAKEBIT SURFACEBIT CONTBIT SEARCHBIT OPENBIT)
+ (SIZE 20)
+ (DESCFCN CHAIN-DESC)
+ (GENERIC GENERIC-CHAIN-F)
+ (ACTION CHAIN-F)>
+
+<GLOBAL CHAIN-HOOKED? <>>
+<GLOBAL CHAIN-LOOPED? <>>
+
+<ROUTINE CHAIN-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?>
+ <COND (<AND <NOT <HELD? ,CHAIN>>
+ <OR <AND ,CHAIN-HOOKED? <HERE? ,CS-BASEMENT>>
+ <AND ,CHAIN-LOOPED? <HERE? ,ELEVATOR-PIT>>>>
+ <RFATAL>)
+ (ELSE <RTRUE>)>)
+ (ELSE
+ <TELL "There is ">
+ <COND (<OR <AND <HERE? ,ELEVATOR-PIT>
+ ,CHAIN-LOOPED?>
+ <AND <HERE? ,CS-BASEMENT ,ELEVATOR-PIT>
+ ,CHAIN-HOOKED?>>
+ <TELL "one end of ">)>
+ <TELL "a greasy length of chain ">
+ <COND (<NOT <FSET? ,CHAIN ,TOUCHBIT>>
+ <TELL "coiled ">)>
+ <TELL "on the floor here.">)>>
+
+<ROUTINE TELL-IF-LOCKED ()
+ <COND (<FSET? ,CHAIN-2 ,LOCKED>
+ <TELL
+" The chain is locked with a padlock.">)>>
+
+<GLOBAL IT-DANGLES " and it dangles in the elevator shaft">
+<GLOBAL HOOKED-TO-HOOK " and it's hooked to the hook">
+
+<ROUTINE CHAIN-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This is a length of rather greasy chain. It looks strong">
+ <COND (<AND <HERE? ,ELEVATOR-PIT>
+ ,CHAIN-LOOPED?
+ ,CHAIN-HOOKED?>
+ <TELL
+,HOOKED-TO-HOOK " and" ,LOOPED-AROUND-ROD>)
+ (,CHAIN-HOOKED?
+ <COND (<HERE? ,CS-BASEMENT>
+ <COND (<EQUAL? <META-LOC ,HOOK> ,HERE>
+ <TELL ,HOOKED-TO-HOOK>)
+ (<ELEVATOR-HERE?>)
+ (ELSE
+ <TELL ,IT-DANGLES>)>)
+ (<HERE? ,ELEVATOR-PIT>
+ <TELL
+" and it disappears up " ,INTO-THE-SHAFT>)>)
+ (,CHAIN-LOOPED?
+ <COND (<HERE? ,ELEVATOR-PIT>
+ <TELL
+" and it's" ,LOOPED-AROUND-ROD>)
+ (<HERE? ,CS-BASEMENT>
+ <TELL ,IT-DANGLES>)>)>
+ <TELL ".">
+ <COND (<HERE? ,ELEVATOR-PIT>
+ <TELL-IF-LOCKED>)>
+ <CRLF>)
+ (<VERB? TAKE>
+ <COND (<AND ,CHAIN-HOOKED?
+ ,CHAIN-LOOPED?>
+ <TELL ,YOU-HAVE-TO>
+ <COND (<HERE? ,CS-BASEMENT>
+ <TELL "unhook">)
+ (<FSET? ,CHAIN-2 ,LOCKED>
+ <TELL "unlock">)
+ (ELSE
+ <TELL "unwrap">)>
+ <TELL " it first." CR>)
+ (<AND ,CHAIN-LOOPED?
+ <OR <PRSI? ,ROD>
+ <HELD? ,CHAIN>
+ <NOT <ACCESSIBLE? ,CHAIN>>>>
+ <PERFORM ,V?UNTIE ,CHAIN-2 ,ROD>
+ <RTRUE>)
+ (<AND ,CHAIN-HOOKED?
+ <OR <PRSI? ,HOOK>
+ <HELD? ,CHAIN>
+ <NOT <ACCESSIBLE? ,CHAIN>>>>
+ <PERFORM ,V?UNTIE ,CHAIN-1>
+ <RTRUE>)>)
+ (<AND <VERB? CLIMB-UP CLIMB-FOO CLIMB-DOWN>
+ ,CHAIN-HOOKED?>
+ <TELL
+"The chain is too greasy to climb">
+ <COND (<FSET? ,GLOVES ,WEARBIT>
+ <TELL ", even wearing the gloves">)>
+ <TELL ,PERIOD>)
+ (<P? UNLOCK (CHAIN-2 CHAIN) MASTER-KEY>
+ <COND (<AND <FSET? ,CHAIN-2 ,LOCKED>
+ ,CHAIN-LOOPED?>
+ <NEW-PRSO ,PADLOCK>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"The chain isn't locked up." CR>)>)
+ (<AND <P? UNLOCK (CHAIN-2 CHAIN) <>>
+ <HELD? ,MASTER-KEY>>
+ <PERFORM-PRSA ,PADLOCK ,MASTER-KEY>
+ <RTRUE>)
+ (<P? (LOCK TIE) (CHAIN CHAIN-1 CHAIN-2) PADLOCK>
+ <COND (<FSET? ,PADLOCK ,LOCKED>
+ <TELL CTHE ,PADLOCK " is locked already." CR>)
+ (<AND <PRSO? ,CHAIN ,CHAIN-2>
+ <NOT <FSET? ,CHAIN-2 ,LOCKED>>
+ ,CHAIN-LOOPED?>
+ <SETG PADLOCK-ON? ,CHAIN-2>
+ <MOVE ,PADLOCK ,CHAIN-2>
+ <FSET ,PADLOCK ,LOCKED>
+ <FCLEAR ,PADLOCK ,OPENBIT>
+ <FSET ,PADLOCK ,NDESCBIT>
+ <FSET ,CHAIN-2 ,LOCKED>
+ <TELL
+"You lock the chain with the padlock. It now forms a secure loop around
+the rod." CR>)
+ (ELSE
+ <TELL
+"That's pretty pointless, as the chain isn't currently securing
+anything." CR>)>)
+ (<P? (TIE ;PUT PUT-ON) (CHAIN CHAIN-1 CHAIN-2)>
+ <COND (<PRSI? ,CHAIN ,CHAIN-1 ,CHAIN-2>
+ <TELL S
+"I'm not sure how you are proposing to do that.|">
+ <RTRUE>)
+ (<AND ,CHAIN-HOOKED? ,CHAIN-LOOPED?>
+ <TELL
+,YOUVE-ALREADY "attached the ends of the chain to the hook and the rod.">
+ <COND (<NOT <PRSI? ,ROD ,HOOK>>
+ <TELL
+" " ,YOU-HAVE-TO "retrieve one first.">)
+ (<HERE? ,ELEVATOR-PIT>
+ <TELL
+" There isn't enough extra chain to reach that far.">)>
+ <CRLF>
+ <RTRUE>)>
+ <COND (<PRSI? ,ROD>
+ <COND (<NOT ,CHAIN-LOOPED?>
+ <FCLEAR ,CHAIN-2 ,INVISIBLE>
+ ;<MOVE ,CHAIN-2 ,ELEVATOR-PIT>
+ <SETG CHAIN-LOOPED? ,ROD>
+ <TELL
+"You wrap the chain around the rod, but find it too thick to actually
+tie it.">
+ <COND (,CHAIN-HOOKED?
+ <REMOVE ,CHAIN>
+ <TELL
+" A few feet hangs on one side of the rod, and the rest curves up from
+the rod towards the floor of the elevator.">)>
+ <CRLF>)
+ (ELSE
+ <TELL
+,YOUVE-ALREADY "wrapped the chain around the rod." CR>)>)
+ (<PRSI? ,HOOK>
+ <COND (<NOT ,CHAIN-HOOKED?>
+ <COND (<AND <HELD? ,CHAIN> <NOT ,CHAIN-LOOPED?>>
+ <MOVE ,CHAIN ,HERE>
+ <TELL
+"You stretch out towards the hook, find that the whole chain is just too
+much weight, and put most of it on the floor. Much easier! ">)>
+ <MOVE ,CHAIN-1 <LOC ,HOOK>>
+ <SETG CHAIN-HOOKED? ,HOOK>
+ <COND (,CHAIN-LOOPED? <REMOVE ,CHAIN>)
+ (ELSE
+ <MOVE ,CHAIN ,HERE>)>
+ <TELL
+"You hook the chain to the hook, where it looks quite secure." CR>)
+ (ELSE
+ <TELL
+"One end of the chain is all that will fit." CR>)>)
+ (ELSE
+ <TELL
+"The chain won't attach to " THE ,PRSI ,PERIOD>)>)
+ (<P? PUT * (CHAIN CHAIN-1 CHAIN-2)>
+ <TELL S
+"I'm not sure how you are proposing to do that.|">)
+ (<VERB? UNTIE TAKE-OFF>
+ <COND (<PRSI? ,ROD>
+ <COND (,CHAIN-LOOPED?
+ <COND (<FSET? ,CHAIN-2 ,LOCKED>
+ <UNLOCK-PADLOCK-FIRST>)
+ (ELSE
+ <FSET ,CHAIN-2 ,INVISIBLE>
+ ;<REMOVE ,CHAIN-2>
+ <COND (<NOT <HELD? ,CHAIN>>
+ <MOVE ,CHAIN ,ELEVATOR-PIT>
+ <THIS-IS-IT ,CHAIN>)>
+ <SETG CHAIN-LOOPED? <>>
+ <REMOVE-CHAIN-FROM "untie">)>)
+ (ELSE
+ <TELL ,ITS-NOT-TIED>)>)
+ (<PRSI? HOOK>
+ <COND (,CHAIN-HOOKED?
+ <REMOVE-CHAIN-FROM "remove">
+ <REMOVE ,CHAIN-1>
+ <COND (<NOT <HELD? ,CHAIN>>
+ <MOVE ,CHAIN ,HERE>
+ <THIS-IS-IT ,CHAIN>)>
+ <SETG CHAIN-HOOKED? <>>
+ <RTRUE>)
+ (ELSE
+ <TELL ,ITS-NOT-TIED>)>)
+ (ELSE
+ <COND (<AND ,CHAIN-HOOKED?
+ <ACCESSIBLE? ,HOOK>>
+ <PERFORM ,V?UNTIE ,CHAIN-1 ,HOOK>)
+ (<AND ,CHAIN-LOOPED?
+ <ACCESSIBLE? ,ROD>>
+ <PERFORM ,V?UNTIE ,CHAIN-2 ,ROD>)
+ (ELSE
+ <TELL ,ITS-NOT-TIED>)>
+ <RTRUE>)>)
+ (<VERB? MOVE>
+ <COND (<HERE? ,CS-BASEMENT>
+ <COND (,CHAIN-HOOKED? <PULL-HOOK>)
+ (,CHAIN-LOOPED? <PULL-ROD>)>)
+ (<HERE? ,ELEVATOR-PIT>
+ <COND (,CHAIN-LOOPED? <PULL-ROD>)
+ (,CHAIN-HOOKED? <PULL-HOOK>)>)>)>>
+
+<ROUTINE REMOVE-CHAIN-FROM (VRB)
+ <TELL "You " .VRB " the chain from " THE ,PRSI "." CR>>
+
+<ROUTINE PULL-HOOK ()
+ <TELL "It's pretty securely hooked.">
+ <PRETTY-SECURE>>
+
+<ROUTINE PULL-ROD ()
+ <COND (<FSET? ,CHAIN-2 ,LOCKED>
+ <TELL
+"You pull as hard as you can, but you can't pull the rod out.">
+ <PRETTY-SECURE>)
+ (ELSE
+ <SETG CHAIN-LOOPED? <>>
+ <FSET ,CHAIN-2 ,INVISIBLE>
+ ;<REMOVE ,CHAIN-2>
+ <COND (<NOT <HELD? ,CHAIN>>
+ <MOVE ,CHAIN ,ELEVATOR-PIT>)>
+ <TELL
+"It clatters along the rod and then falls off." CR>)>>
+
+<ROUTINE PRETTY-SECURE ()
+ <COND (<AND ,CHAIN-LOOPED?
+ <FSET? ,CHAIN-2 ,LOCKED>>
+ <TELL
+" In fact, it feels pretty secure all around.">)>
+ <CRLF>>
+
+<OBJECT PRESSURE-VALVE
+ (IN TUNNEL-EAST)
+ (DESC "pressure valve")
+ (SYNONYM VALVE)
+ (ADJECTIVE PRESSURE RELEASE STEAM)
+ (VALUE 5)
+ (FLAGS NDESCBIT OPENABLE)
+ (ACTION PRESSURE-VALVE-F)>
+
+<ROUTINE PRESSURE-VALVE-F ()
+ <COND (<VERB? EXAMINE>
+ <COND (<NOT <GET ,P-NAMW 0>>
+ <COND (<FSET? ,PRESSURE-VALVE ,OPENBIT>
+ <TELL
+"It looks like live steam." CR>)
+ (<NOT <ZERO? ,VALVE-OPENED?>>
+ <TELL
+"It's just a trickle." CR>)
+ (ELSE
+ <TELL S "It's closed.|">)>)
+ (ELSE
+ <TELL
+"It looks pretty rusty, but appears to be in working order. ">
+ <COND (<FSET? ,PRESSURE-VALVE ,OPENBIT>
+ <TELL
+"In fact, it's" ,WIDE-OPEN CR>)
+ (<NOT <ZERO? ,VALVE-OPENED?>>
+ <TELL
+,IT-SEEMS-TO-BE "partly open." CR>)
+ (ELSE <TELL S "It's closed.|">)>)>)
+ (<VERB? TURN>
+ <COND (<FSET? ,PRESSURE-VALVE ,OPENBIT>
+ <NEW-VERB ,V?CLOSE>)
+ (ELSE
+ <NEW-VERB ,V?OPEN>)>
+ <RTRUE>)
+ (<AND <VERB? ATTACK>
+ <FSET? ,PRSI ,WEAPONBIT>>
+ <OPEN-VALVE>)
+ (<AND <VERB? OPEN PRY>
+ ,PRSI
+ <FSET? ,PRSI ,WEAPONBIT>>
+ <OPEN-VALVE>)
+ (<AND <VERB? OPEN>
+ <OR <NOT <ZERO? ,VALVE-OPENED?>>
+ <FSET? ,PRESSURE-VALVE ,RMUNGBIT>>>
+ <OPEN-VALVE>)
+ (<AND <VERB? OPEN>
+ <ZERO? ,VALVE-OPENED?>>
+ <TELL
+"It's too rusty. You pull and strain, but" ,LC-NOTHING-HAPPENS CR>)
+ (<VERB? CLOSE LAMP-OFF>
+ <COND (<FSET? ,PRESSURE-VALVE ,OPENBIT>
+ <SETG VALVE-OPENED? 0>
+ <FSET ,PRESSURE-VALVE ,RMUNGBIT>
+ <FCLEAR ,PRESSURE-VALVE ,OPENBIT>
+ <TELL
+"The valve closes, more easily than it opened." CR>)
+ (ELSE
+ <TELL ,IT-ALREADY-IS>)>)>>
+
+<GLOBAL WIDE-OPEN " wide open and spewing live steam.">
+
+<ROUTINE OPEN-VALVE ()
+ <COND (<FSET? ,PRESSURE-VALVE ,OPENBIT>
+ <ALREADY-OPEN>)
+ (ELSE
+ <COND (<FSET? ,PRESSURE-VALVE ,RMUNGBIT>
+ <SETG VALVE-OPENED? 1>)>
+ <COND (<G? <SETG VALVE-OPENED? <+ ,VALVE-OPENED? 1>> 1>
+ <FSET ,PRESSURE-VALVE ,OPENBIT>
+ <DEQUEUE I-RATS>
+ <MOVE ,RATS ,GLOBAL-OBJECTS>
+ <TELL
+"The valve screeches open. A jet spray of live steam issues from it,
+filling the tunnel in front of you.">
+ <COND (,RATS-HERE
+ <SCORE-OBJECT ,PRESSURE-VALVE>
+ <MOVE ,DEAD-RAT ,HERE>
+ <SETG RATS-HERE 0>
+ <TELL
+" The rats are caught in the full force of the blast. Horrible squeals
+can be heard from the midst of the steam cloud, and scalded rats charge
+past you, all interest in anything but flight forgotten.">
+ <COND (<IN? ,DEAD-RAT ,HERE>
+ <TELL
+" One of their number remains, dead.">)>)>)
+ (ELSE
+ <TELL
+"The valve, with a horrible scream of tortured metal, gives a little,
+and a small trickle of steam issues forth.">
+ <COND (,RATS-HERE
+ <TELL " This further agitates the
+rats.">)>)>
+ <CRLF>)>>
+
+<GLOBAL VALVE-OPENED? 0>
+
+<ROOM TUNNEL-WEST
+ (IN ROOMS)
+ (DESC "Steam Tunnel")
+ (EAST TO TUNNEL)
+ (WEST PER RATS-EXIT) ;TUNNEL-ENTRANCE
+ (GLOBAL CABLE STEAM-PIPES)
+ (ACTION TUNNEL-WEST-F)>
+
+<ROUTINE TUNNEL-AND-PIPE ()
+ <TELL
+"This dank and grimy tunnel is largely filled with an imperfectly
+insulated steam pipe. The tunnel is uncomfortably hot and damp. ">>
+
+<ROUTINE TUNNEL-WEST-F (RARG)
+ <COND (<RARG? LOOK>
+ <TUNNEL-AND-PIPE>
+ <TELL
+"A bundle of coaxial cable runs along the ceiling,
+festooned with damp mold and cobwebs. The tunnel continues west." CR>)
+ (<RARG? BEG>
+ <COND (<AND ,RATS-HERE
+ <VERB? DROP>
+ <FSET? ,PRSO ,FOODBIT>>
+ <THROW-FOOD>)>)>>
+
+<OBJECT STEAM-PIPES
+ (IN LOCAL-GLOBALS)
+ (DESC "steam pipes")
+ (SYNONYM PIPE PIPES)
+ (ADJECTIVE STEAM)
+ (FLAGS NDESCBIT)>
+
+<OBJECT CABLE
+ (IN LOCAL-GLOBALS)
+ (DESC "coaxial cable")
+ (SYNONYM CABLE CHANNEL WIRE WIRES)
+ (ADJECTIVE COAXIAL COAX WIRE WIRES STEAM)
+ (FLAGS NDESCBIT VEHBIT)
+ (ACTION CABLE-F)>
+
+<GLOBAL ON-CABLE? <>>
+
+<ROUTINE CABLE-F ("OPT" (RARG <>))
+ <COND (<VERB? EXAMINE>
+ <COND (<HERE? ,CS-BASEMENT>
+ <TELL S
+"From floor to ceiling run wire channels and steam pipes.|">)
+ (ELSE
+ <TELL
+"The cable runs overhead in a fat bundle. It looks like the kind
+you've seen connecting nodes of the local net. This clump
+is pretty grotty looking, festooned with damp cobwebs, and stained with
+something that dripped from the ceiling." CR>)>)
+ (<VERB? TAKE>
+ <YOU-CANT-X-THAT "take">)
+ (<VERB? CUT MUNG>
+ <COND (<PRSI? <> ,HANDS>
+ <TELL-YUKS>)
+ (<PRSI? ,BOLT-CUTTER ,AXE>
+ <TELL
+"You begin cutting the cables, and after a while you realize that the
+inner cables look different, sort of dead white and slimy. Then you
+notice that the cables you have cut are knitting back together." CR>)
+ (ELSE
+ <TELL
+,YOU-CANT "expect to cut cable with " A ,PRSI ,PERIOD>)>)
+ (<VERB? FOLLOW>
+ <TELL "It runs ">
+ <COND (<HERE? ,CS-BASEMENT>
+ <TELL
+"from floor to ceiling." CR>)
+ (<HERE? ,STEAM-TUNNEL-EAST ,TUNNEL-ENTRANCE>
+ <TELL
+"down from the ceiling and off to the ">
+ <COND (<HERE? ,STEAM-TUNNEL-EAST>
+ <TELL "west." CR>)
+ (ELSE <TELL "east." CR>)>)
+ (ELSE
+ <TELL
+"east and west along the ceiling." CR>)>)
+ (<VERB? CLIMB-FOO CLIMB-ON BOARD>
+ <COND (<HERE? ,CS-BASEMENT>
+ <TELL-YUKS>)
+ (,ON-CABLE?
+ <TELL ,YOU-ARE ,PERIOD>)
+ (ELSE
+ <SETG ON-CABLE? T>
+ <QUEUE I-CABLE-FALL 2>
+ <TELL
+"You leap, grab the damp and moldy bundle of cable, and hang suspended
+off the floor.">
+ <COND (,RATS-HERE
+ <TELL
+" " ,YOU-ARE-NOW "somewhat out of reach of the rats.">)>
+ <CRLF>)>)>>
+
+<ROUTINE I-CABLE-FALL ()
+ <TELL CR
+"Your grip on the cable, never too secure, loosens">
+ <SETG ON-CABLE? <>>
+ <COND (,RATS-HERE
+ <TELL " fatally as an
+Einstein among rats, who was crawling along the cable itself, bites your
+fingers">
+ <THROUGH-THE ,GLOVES>
+ <TELL ". You fall, landing among the delighted rats." CR CR>
+ <JIGS-UP
+"They swarm over you, a small army of furry bodies, and you are
+consumed in short order.">)
+ (ELSE <TELL ", and you drop to the floor." CR>)>>
+
+<ROUTINE I-RATS ("AUX" (ORAT <LOC ,RATS>))
+ <COND (<IN? ,RATS ,GLOBAL-OBJECTS>
+ <MOVE ,RATS ,TUNNEL-WEST>
+ <COND (<IN-TUNNEL?>
+ <TELL CR
+"You can hear, in the distance, a chittering, scratching sound." CR>)>
+ <RTRUE>)
+ (<NOT <IN? ,RATS ,HERE>>
+ <COND (<NOT <ZERO? ,RATS-HERE>>
+ <COND (<IN-TUNNEL?>
+ <MOVE ,RATS ,HERE>)
+ (<OR <AND <HERE? ,TOMB>
+ <FSET? ,ACCESS-HATCH ,OPENBIT>>
+ <AND <HERE? ,CS-BASEMENT>
+ <FSET? ,ELEVATOR-DOOR-B
+ ,OPENBIT>>>
+ <QUEUE I-RATS-GO-AWAY 4 T>
+ <TELL CR
+"From below you can hear the chittering of the rats." CR>
+ <RTRUE>)
+ (<HERE? ,TOMB ,CS-BASEMENT>
+ <QUEUE I-RATS-GO-AWAY 2 T>)>)
+ (<HERE? ,TOMB ,CS-BASEMENT>
+ <QUEUE I-RATS-GO-AWAY 2 T>)
+ (<G? <SETG RATS-WAITING <+ ,RATS-WAITING 1>> 3>
+ <COND (<IN? ,RATS ,TUNNEL-WEST>
+ <MOVE ,RATS ,TUNNEL>)
+ (<IN? ,RATS ,TUNNEL>
+ <MOVE ,RATS ,TUNNEL-EAST>)
+ (<IN? ,RATS ,TUNNEL-EAST>
+ <MOVE ,RATS ,STEAM-TUNNEL>)
+ (<IN? ,RATS ,STEAM-TUNNEL>
+ <MOVE ,RATS ,STEAM-TUNNEL-EAST>)
+ (<AND <IN? ,RATS ,STEAM-TUNNEL-EAST>
+ ,BRICK-WALL-FLAG>
+ <MOVE ,RATS ,ELEVATOR-PIT>)>
+ <COND (<IN? ,RATS ,HERE>
+ <SETG RATS-WAITING 0>)>)>)>
+ <COND (<IN? ,RATS ,HERE>
+ <CRLF>
+ <COND (<NOT <HERE? .ORAT>>
+ <COND (,RATS-HERE
+ <TELL
+"The rats follow, surging around you. ">)
+ (ELSE
+ <TELL
+"A troop of rats appears out of the darkness. ">)>)>
+ <SETG RATS-HERE <+ ,RATS-HERE 1>>
+ <COND (,ON-CABLE?
+ <TELL
+"The rats leap toward you, maddened that you are out of reach!" CR>)
+ (<EQUAL? ,RATS-HERE 1>
+ <TELL
+"The rats are momentarily
+startled by your presence, but soon the bolder ones begin to approach.
+There are more rats here than you have ever seen." CR>)
+ (<EQUAL? ,RATS-HERE 2>
+ <TELL
+"The rats attack! Slimy, snarling, and hungry, they swarm over your
+feet, biting at your legs">
+ <THROUGH-THE ,BOOTS>
+ <TELL " and clinging desperately to your feet." CR>)
+ (<EQUAL? ,RATS-HERE 3>
+ <TELL
+"The troop of rats surges around you, scenting blood and the kill. There
+are rats clinging all over you, their nasty teeth biting down in a dozen
+places." CR>)
+ (ELSE
+ <I-RATS-GO-AWAY>
+ <JIGS-UP
+"A particularly nasty rat, wise in the ways of death, makes its way
+up your arm to your neck. For a moment it stares at you, its
+yellow eyes hungry, and then it reaches your jugular. As you lose
+consciousness, you think for a moment that you see the rat laugh,
+exposing its own neck, and on its neck is branded a symbol.">)>)
+ (<IN-TUNNEL? ,RATS>
+ <COND (<NOT <IN-TUNNEL?>>
+ <RFALSE>)
+ (<EQUAL? ,RATS-WAITING 1>
+ <TELL CR
+"The sound is louder. It sounds like small animals. Is it rats?" CR>)
+ (<EQUAL? ,RATS-WAITING 2>
+ <TELL CR
+"The sound continues. It's almost certainly rats." CR>)
+ (ELSE
+ <TELL CR
+"The rat sounds are growing louder, but you still can't see any rats." CR>)>)>>
+
+<ROUTINE IN-TUNNEL? ("OPT" (WHO <>) "AUX" L)
+ <COND (<NOT .WHO> <SET WHO ,PLAYER>)>
+ <SET L <LOC .WHO>>
+ <COND (<EQUAL? .L ,TUNNEL-WEST ,TUNNEL ,TUNNEL-EAST
+ ,STEAM-TUNNEL ,STEAM-TUNNEL-EAST>
+ <RTRUE>)
+ (<AND <EQUAL? .L ,ELEVATOR-PIT>
+ ,BRICK-WALL-FLAG>
+ <RTRUE>)>>
+
+<ROUTINE I-RATS-GO-AWAY ()
+ <DEQUEUE I-RATS>
+ <MOVE ,RATS ,GLOBAL-OBJECTS>
+ <SETG RATS-HERE 0>
+ <SETG RATS-WAITING 0>
+ <RFALSE>>
+
+<GLOBAL RATS-WAITING 0> ;"rats in tunnel-west, waiting"
+<GLOBAL RATS-HERE 0> ;"rats seen you?"
+
+<OBJECT DEAD-RAT
+ (DESC "dead rat")
+ (SYNONYM RAT)
+ (ADJECTIVE DEAD)
+ (FLAGS SEARCHBIT TAKEBIT OPENBIT CONTBIT)
+ (HEAT 0)
+ (GENERIC GENERIC-RAT-F)
+ (ACTION DEAD-RAT-F)>
+
+<ROUTINE DEAD-RAT-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This rat appears to have been stepped on. A small trickle of blood has
+clotted around its mouth. Branded into its neck is a strange symbol." CR>)
+ (<VERB? TAKE>
+ <COND (<NOT <FSET? ,PRSO ,TOUCHBIT>>
+ <COND (<EQUAL? <ITAKE> T>
+ <TELL
+"As you take the dead rat, it moves, but then you realize that it's only
+lice and fleas bailing out." CR>)
+ (ELSE <RTRUE>)>)>)
+ (<P? PUT * DEAD-RAT>
+ <SQUISH-RAT>)
+ (<VERB? BOARD STEP-ON>
+ <TELL
+"You crush the rat. You hear its bones snap. What a sadist!" CR>)
+ (<VERB? EAT>
+ <TELL
+"You dangle the rat over your mouth by its tail. You think about it.
+You lower the rat towards your face. You think some more. Fortunately
+for your health, you change your mind." CR>)>>
+
+<ROUTINE SQUISH-RAT ()
+ <TELL
+CTHE ,PRSO " hits ">
+ <COND (<PRSI? ,RATS> <TELL "a rat">)
+ (ELSE <TELL "the rat">)>
+ <TELL " with a satisfying squish." CR>>
+
+<OBJECT RAT-SYMBOL
+ (IN DEAD-RAT)
+ (DESC "branded symbol")
+ (SYNONYM SYMBOL)
+ (ADJECTIVE BRANDED STRANGE INCOMPREHENSIBLE)
+ (FLAGS NDESCBIT)
+ (SIZE 0)
+ (GENERIC GENERIC-SYMBOL-F)
+ (ACTION RAT-SYMBOL-F)>
+
+<GLOBAL SEEN-SYMBOL? <>>
+
+<GLOBAL SYMBOL-APPEARS
+"The symbol, on close examination, appears to have been ">
+
+<ROUTINE RAT-SYMBOL-F ()
+ <COND (<VERB? EXAMINE READ>
+ <TELL
+,SYMBOL-APPEARS "scarred into
+the hide of the rat. There is no hair growing on it, and although it
+looks like scar tissue, the color is wrong -- a sort of purplish
+green. ">
+ <TELL-SYMBOL ,DEAD-RAT>
+ <CRLF>)>>
+
+<ROUTINE GENERIC-SYMBOL-F ()
+ <COND (<EQUAL? ,P-IT-OBJECT
+ ,TATTOO ,STONE-SYMBOL ,RAT-SYMBOL
+ ,PENTAGRAM ,CARVING-SYMBOL ,CARTON>
+ ,P-IT-OBJECT)
+ (<EQUAL? ,P-IT-OBJECT ,HAND>
+ ,TATTOO)
+ (<EQUAL? ,P-IT-OBJECT ,SMOOTH-STONE>
+ ,STONE-SYMBOL)
+ (<EQUAL? ,P-IT-OBJECT ,DEAD-RAT>
+ ,RAT-SYMBOL)
+ (<EQUAL? ,P-IT-OBJECT ,CARVINGS>
+ ,CARVING-SYMBOL)
+ (<EQUAL? ,P-IT-OBJECT ,CARTON>
+ ,CARTON)>>
+
+<ROUTINE TELL-SYMBOL (OBJ)
+ <TELL "The symbol ">
+ <COND (<NOT ,SEEN-SYMBOL?>
+ <SETG SEEN-SYMBOL? .OBJ>
+ <TELL
+"is like nothing you've ever seen, and yet somehow
+you know it has meaning.">)
+ (<NOT <EQUAL? ,SEEN-SYMBOL? .OBJ>>
+ <TELL
+"looks oddly familiar.">)
+ (ELSE
+ <TELL
+"seems just as odd as before.">)>>
+
+<OBJECT RATS
+ (IN GLOBAL-OBJECTS)
+ (DESC "sewer rats")
+ (SYNONYM RAT RATS)
+ (ADJECTIVE LIVE SEWER)
+ (DESCFCN RATS-DESC)
+ (FLAGS NOABIT)
+ (GENERIC GENERIC-RAT-F)
+ (ACTION RATS-F)>
+
+<ROUTINE GENERIC-RAT-F ()
+ <COND (<ACCESSIBLE? ,DEAD-RAT> ,DEAD-RAT)
+ (ELSE ,RATS)>>
+
+<ROUTINE RATS-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <TELL
+"There are rats here.">)>>
+
+<ROUTINE RATS-F ()
+ <COND (<AND <IN? ,RATS ,GLOBAL-OBJECTS>
+ <NOT <VERB? TELL-ABOUT ASK-ABOUT TELL-ME-ABOUT>>>
+ <TELL "There are no rats here." CR>)
+ (<VERB? EXAMINE>
+ <TELL
+"These are strange rats. They don't look like the usual sewer rats.
+There is more white in their fur, even dirty and
+encrusted as it is. Some are furless, and others piebald.
+Many of the older ones are scarred and look particularly
+cunning." CR>)
+ (<VERB? SMELL>
+ <TELL
+"You catch a sharp odor over the background of damp and sewage.
+It's metallic, almost stinging. It's the odor of fresh blood." CR>)
+ (<AND <VERB? THROW>
+ <FSET? ,PRSO ,FOODBIT>>
+ <THROW-FOOD>)
+ (<VERB? ATTACK KILL>
+ <TELL
+"You strike out at the rats, but several clamp onto your hand. The
+pain is horrible. The rest are all the more frenzied by the drops
+of blood." CR>)
+ (<VERB? KICK>
+ <TELL
+"You kick, throwing off a few biting at your foot and leg">
+ <THROUGH-THE ,BOOTS><TELL ". These smash
+squealing into the wall, but others take their places." CR>)
+ (<P? PUT * RATS>
+ <SQUISH-RAT>)
+ (<VERB? STEP-ON>
+ <TELL
+"You smash a rat, but it's one of hundreds." CR>)
+ (<VERB? LISTEN>
+ <TELL
+CTHE ,RATS " sound annoyed and hungry." CR>)>>
+
+<ROOM MASS-AVE
+ (IN ROOMS)
+ (DESC "Mass. Ave.")
+ (LDESC
+"This is the main entrance to the campus buildings.
+Blinding snow obscures the stately Grecian columns and rounded
+dome to the east. You can barely make out the inscription on
+the pediment (which reads \"George Vnderwood Edwards, Fovnder;
+P. David Lebling, Architect\").
+West across Massachusetts Avenue are
+other buildings, but you can't see them.")
+ (EAST TO INF-1)
+ (IN TO INF-1)
+ (GLOBAL OUTSIDE-DOOR)
+ (FLAGS OUTSIDE ONBIT)
+ (ACTION MASS-AVE-F)>
+
+<ROUTINE MASS-AVE-F (RARG)
+ <COND ;(<RARG? LOOK>
+ <TELL
+ CR>)
+ (<RARG? ENTER>
+ <EXIT-TO-COLD>)
+ (<RARG? LEAVE>
+ <EXIT-FROM-COLD>)>>
+
+<ROUTINE EXIT-FROM-COLD ()
+ <DEQUEUE I-FREEZE-TO-DEATH>
+ <COND (<G? ,FREEZE-COUNT 0>
+ <SETG FREEZE-COUNT 0>
+ <TELL
+,PUSH-INTO "welcoming warmth inside." CR CR>)>>
+
+<ROOM CHEMISTRY-BLDG
+ (IN ROOMS)
+ (DESC "Chemistry Building")
+ (NORTH TO INF-5)
+ (SOUTH TO ALCHEMY-DEPT IF ALCHEMY-DOOR IS OPEN)
+ (GLOBAL ALCHEMY-DOOR ALCHEMY-WINDOW OFFICE-DOOR)
+ (FLAGS ONBIT)
+ (ACTION CHEMISTRY-BLDG-F)>
+
+<ROUTINE CHEMISTRY-BLDG-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"This corridor is lined with closed, dark offices. At the south end of
+the corridor is a door with a light shining behind it. ">
+ <COND (<FSET? ,ALCHEMY-DOOR ,OPENBIT>
+ <TELL "The door is open.">)
+ (ELSE
+ <TELL
+"There is something written on the door.">)>
+ <CRLF>)
+ (<RARG? ENTER>
+ <COND (<AND <EQUAL? ,OHERE ,ALCHEMY-DEPT>
+ <NOT ,PROF-DEAD?>>
+ <SETG LEFT-ALCHEMY? T>
+ <FSET ,ALCHEMY-DOOR ,LOCKED>
+ <FCLEAR ,ALCHEMY-DOOR ,OPENBIT>
+ <TELL
+"The door closes behind you." CR CR>)>)>>
+
+<OBJECT ALCHEMY-DOOR
+ (IN LOCAL-GLOBALS)
+ (DESC "Alchemy Department door")
+ (SYNONYM DOOR)
+ (ADJECTIVE ALCHEMY DEPART DEPT)
+ (FLAGS DOORBIT OPENABLE NDESCBIT READBIT LOCKED)
+ (ACTION ALCHEMY-DOOR-F)>
+
+<ROUTINE ALCHEMY-DOOR-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This is a standard Tech door. It's made of black-painted wood and has a ">
+ <COND (<FSET? ,ALCHEMY-WINDOW ,RMUNGBIT>
+ <TELL "badly cracked ">)>
+ <TELL 'ALCHEMY-WINDOW " with ">
+ <COND (<HERE? ,ALCHEMY-DEPT>
+ <TELL "something painted on the other side.">)
+ (ELSE
+ <TELL "\"Department of Alchemy\" painted on it.">)>
+ <COND (<AND <HERE? ,CHEMISTRY-BLDG>
+ <FSET? ,ALCHEMY-DEPT ,ONBIT>
+ <NOT ,PROF-DEAD?>>
+ <TELL
+" There is a light on inside.">)>
+ <CRLF>)
+ (<VERB? LOOK-INSIDE>
+ <COND (<HERE? ,ALCHEMY-DEPT>
+ <TELL "You are inside it already." CR>)
+ (<NOT <FSET? ,ALCHEMY-DEPT ,ONBIT>>
+ <TELL
+"It's dark inside." CR>)
+ (<NOT ,PROF-DEAD?>
+ <TELL
+"Every so often, you see a shadow move across the window." CR>)
+ (ELSE
+ <TELL
+"You don't see anything in particular, other than that the light is on
+inside." CR>)>)
+ (<VERB? READ>
+ <COND (<HERE? ,CHEMISTRY-BLDG>
+ <TELL
+"Painted on the door, in calligraphy indistinguishable from any other
+door at Tech, is the phrase \"Department of Alchemy.\" You always used
+to wonder what was behind that door." CR>)
+ (ELSE <TELL ,YOU-CANT "read it from this side." CR>)>)
+ (<P? UNLOCK>
+ <COND (<FSET? ,PRSO ,LOCKED>
+ <COND (<PRSI? ,MASTER-KEY>
+ <COND (<HERE? ,CHEMISTRY-BLDG>
+ <QUEUE I-ANSWER-DOOR 3 T>)>
+ <RFALSE>)
+ (<PRSI? ,KEY-1 ,KEY-2 ,KEY-3 ,KEY-4>
+ <TELL
+"It doesn't even fit the lock." CR>)>)
+ (<HERE? ,ALCHEMY-DEPT>
+ <TELL
+"You don't need to unlock it to open it from this side." CR>)>)
+ (<VERB? KNOCK KICK ATTACK>
+ <TELL "You knock on the door.">
+ <COND (<HERE? ,CHEMISTRY-BLDG>
+ <QUEUE I-ANSWER-DOOR 3 T>
+ <TELL
+" The hollow sound reverberates down the hall.
+You sort of wish you had knocked more softly.">)>
+ <CRLF>)
+ (<VERB? THROUGH>
+ <COND (<HERE? ,ALCHEMY-DEPT>
+ <DO-WALK ,P?NORTH>)
+ (<HERE? ,CHEMISTRY-BLDG>
+ <DO-WALK ,P?SOUTH>)>)>>
+
+<GLOBAL LEFT-ALCHEMY? <>>
+
+<OBJECT ALCHEMY-WINDOW
+ (IN LOCAL-GLOBALS)
+ (DESC "frosted glass window")
+ (SYNONYM WINDOW GLASS)
+ (ADJECTIVE FROSTED GLASS)
+ (FLAGS NDESCBIT READBIT TRANSBIT)
+ (ACTION ALCHEMY-WINDOW-F)>
+
+<ROUTINE ALCHEMY-WINDOW-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a frosted glass window. It's more or less opaque.">
+ <COND (<FSET? ,ALCHEMY-WINDOW ,RMUNGBIT>
+ <TELL
+" It's covered with a maze of cracks.">)>
+ <CRLF>)
+ (<VERB? READ KNOCK>
+ <NEW-PRSO ,ALCHEMY-DOOR>
+ <RTRUE>)
+ (<VERB? MUNG ATTACK>
+ <COND (<HERE? ,CHEMISTRY-BLDG>
+ <QUEUE I-ANSWER-DOOR 3 T>)>
+ <COND (<PRSI? <> ,HANDS>
+ <TELL
+S "There is no effect"", other than your hands getting somewhat sore and
+a lot of noise being produced." CR>)
+ (<NOT <FSET? ,PRSI ,WEAPONBIT>>
+ <TELL
+CTHE ,PRSI " bounces harmlessly off the glass." CR>)
+ (<FSET? ,PRSO ,RMUNGBIT>
+ <TELL
+"Further attacks do little to worsen the damage." CR>)
+ (ELSE
+ <FSET ,PRSO ,RMUNGBIT>
+ <TELL
+"You smash the glass, and cracks spread all over the pane from the point
+of impact. The window remains whole, though, as it's made of wire
+reinforced glass." CR>)>)>>
+
+<ROUTINE I-ANSWER-DOOR ()
+ <COND (<HERE? ,CHEMISTRY-BLDG>
+ <COND (<NOT ,PROF-DEAD?>
+ <MOVE ,PROFESSOR ,ALCHEMY-DEPT>
+ <QUEUE I-PROFESSOR -1>
+ <TELL CR
+"The door opens partway, revealing a professorial man
+in a white lab coat. He smiles. ">
+ <COND (<NOT ,LEFT-ALCHEMY?>
+ <TELL "\"Good evening! I don't get many visitors
+this late. You're not one of my students, are you?\"">)
+ (ELSE
+ <TELL "\"Back for another visit, are you?\"">)>
+ <TELL " He ushers you
+into the room without waiting for an answer, closing the door behind
+you." CR CR>
+ <GOTO ,ALCHEMY-DEPT>)
+ (ELSE
+ <TELL CR
+"There is no sign of life behind the door." CR>)>)>>
+
+<OBJECT SIGNUP
+ (IN ALCHEMY-DEPT)
+ (DESC "sign-up sheet")
+ (FDESC
+"Taped to the wall to the right of the archway is a sign-up sheet.")
+ (SYNONYM SHEET)
+ (ADJECTIVE SIGNUP SIGN-UP)
+ (FLAGS TAKEBIT TRYTAKEBIT READBIT)
+ (ACTION SIGNUP-F)>
+
+<ROUTINE SIGNUP-F ()
+ <COND (<VERB? EXAMINE READ>
+ <TELL
+"This appears to be a sign-up sheet for the lab. Strangely, although
+few daytime segments are used, almost all of the nighttime ones are.
+Most seem to have been taken by two different people, the professor
+and another, presumably one of his graduate students.">
+ <FSET ,SIGNUP ,RMUNGBIT>
+ <COND (<OR <FSET? ,NOTE ,RMUNGBIT>
+ ,REMEMBERED-STUDENT?>
+ <TELL
+" With a start, you realize that the author of the suicide note was the
+heavy user of the lab.">)
+ (ELSE
+ <QUEUE I-REMEMBER-STUDENT 4>
+ <TELL
+" The name of the graduate student is oddly familiar.">)>
+ <CRLF>)
+ (<VERB? TAKE>
+ <COND (<IN? ,PROFESSOR ,HERE>
+ <TELL
+"\"You can't take that! It's the only way we have to keep track of who's
+signed up to use the lab.\"" CR>)>)>>
+
+<GLOBAL REMEMBERED-STUDENT? <>>
+
+<ROUTINE I-REMEMBER-STUDENT ()
+ <SETG REMEMBERED-STUDENT? T>
+ <TELL CR
+"Suddenly, you remember why the graduate student's name was familiar.
+He was a missing student, until his body was found smashed
+and broken at the base of the tallest building on campus." CR>>
+
+<OBJECT ARCHWAY
+ (IN LOCAL-GLOBALS)
+ (DESC "archway")
+ (SYNONYM ARCH ARCHWAY)
+ (FLAGS NDESCBIT)
+ (ACTION ARCHWAY-F)>
+
+<ROUTINE ARCHWAY-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This archway, part of the oldest section of Tech, is between a lab
+and the headquarters of the Alchemy Department.">
+ <COND (<AND <HERE? ,ALCHEMY-DEPT>
+ <NOT <FSET? ,SIGNUP ,TOUCHBIT>>>
+ <TELL
+,TO-THE-RIGHT "archway is a sheet of paper. It looks like a sign-up
+sheet.">)>
+ <CRLF>)
+ (<P? THROUGH>
+ <COND (<HERE? ,ALCHEMY-LAB>
+ <DO-WALK ,P?NORTH>)
+ (ELSE
+ <DO-WALK ,P?SOUTH>)>)>>
+
+<OBJECT LAB
+ (IN LOCAL-GLOBALS)
+ (DESC "laboratory")
+ (SYNONYM LAB LABORATORY)
+ (ADJECTIVE ALCHEMY)
+ (ACTION LAB-F)>
+
+<ROUTINE LAB-F ()
+ <COND (<VERB? ENTER THROUGH>
+ <COND (<HERE? ,ALCHEMY-DEPT>
+ <DO-WALK ,P?SOUTH>)
+ (<HERE? ,UNDER-ALCHEMY-LAB>
+ <COND (<FSET? ,ALCHEMY-TRAP-DOOR ,OPENBIT>
+ <DO-WALK ,P?UP>)
+ (ELSE
+ <TELL ,REFERRING CR>)>)
+ (ELSE
+ <TELL ,ALREADY-IN-IT CR>)>)
+ (<P? THROW * LAB>
+ <MOVE ,PRSO ,ALCHEMY-LAB>
+ <TELL "Thrown." CR>)
+ (<VERB? DROP>
+ <DO-WALK ,P?NORTH>)
+ (<VERB? LOOK-INSIDE>
+ <COND (<HERE? ,ALCHEMY-DEPT>
+ <LIKE-A-PRSO "looks">)
+ (<HERE? ,UNDER-ALCHEMY-LAB>
+ <COND (<AND ,LIT
+ <FSET? ,ALCHEMY-TRAP-DOOR ,OPENBIT>>
+ <LIKE-A-PRSO "looks">)
+ (ELSE
+ <TELL ,REFERRING CR>)>)
+ (ELSE
+ <TELL ,ALREADY-IN-IT CR>)>)>>
+
+<ROOM ALCHEMY-DEPT
+ (IN ROOMS)
+ (DESC "Department of Alchemy")
+ (NORTH TO CHEMISTRY-BLDG IF ALCHEMY-DOOR IS OPEN)
+ (SOUTH PER ALCHEMY-LAB-ENTER)
+ (GLOBAL ALCHEMY-DOOR ALCHEMY-WINDOW ARCHWAY OUTLET LAB)
+ (FLAGS ONBIT)
+ (ACTION ALCHEMY-DEPT-F)>
+
+<ROUTINE ALCHEMY-LAB-ENTER ()
+ <COND (<WINNER? ,URCHIN> <RFALSE>)
+ (<IN? ,PROFESSOR ,ALCHEMY-DEPT>
+ <COND (<LAB-ENTER?> <CRLF> ,ALCHEMY-LAB)
+ (ELSE <RFALSE>)>)
+ (ELSE ,ALCHEMY-LAB)>>
+
+<ROUTINE LAB-ENTER? ()
+ <COND (<NOT ,PROF-SEEN-NOTE?>
+ <TELL
+CTHE ,PROFESSOR " stops you, not too gently. \"Sorry,\" he says, although
+he doesn't sound too sorry. \"There are very delicate experiments going
+on in the lab. You might hurt something.\" All you can see before he
+guides you away from the archway is a great deal of odd
+apparatus and equipment." CR>
+ <RFALSE>)
+ (ELSE
+ <MOVE ,PROFESSOR ,ALCHEMY-LAB>
+ <FSET ,ALCHEMY-LAB ,ONBIT>
+ <TELL
+"\"Ah! You'd like to see the lab?\" the professor asks in a rather
+unctuous tone. \"Come right in!\" He ushers you through the archway
+into the lab, following quickly behind you and turning on the lights." CR>)>>
+
+<GLOBAL PROF-SEEN-NOTE? <>>
+<GLOBAL PROF-MAD? <>>
+
+;<GLOBAL PROF-CNT 0>
+
+;<GLOBAL PROF-TBL
+ <LTABLE "ever so gently"
+ "not so gently"
+ "roughly"
+ "manhandling you">>
+
+<GLOBAL TIED-UP? 0>
+
+<GLOBAL PROF-FLAG <>>
+
+<ROUTINE I-PROFESSOR ()
+ <COND (<HERE? ,ALCHEMY-LAB ,UNDER-ALCHEMY-LAB ,BRICK-TUNNEL>
+ <SETG TIED-UP? <+ ,TIED-UP? 1>>
+ <COND (<EQUAL? ,TIED-UP? 1>
+ <MOVE ,PLAYER ,PENTAGRAM>
+ <TELL CR
+CTHE ,PROFESSOR " guides you to the center of the lab, where a
+strange pentagonal symbol is chalked on the floor. ">
+ <COND (<FSET? ,PENTAGRAM ,RMUNGBIT>
+ <TELL "He repairs some scuff marks on it,
+muttering about sloppy students. He then ">)
+ (ELSE
+ <TELL "He ">)>
+ <TELL "cuts one of the
+chalk lines with a small knife you had not previously noticed, pushes
+you into the center of the chalked symbol, and redraws the line, muttering
+softly and rhythmically as he does so. \"There, that's done. Don't
+move from there, it'll only make things worse for you.\" He makes some
+odd gestures at the archway and then goes over to the lab bench." CR>)
+ (<EQUAL? ,TIED-UP? 2>
+ <TELL CR
+CTHE ,PROFESSOR " is preparing something at the lab bench. \"Alchemy is
+my chosen field, and I've gotten ridiculed for it. It's like
+chemistry, except that chemists don't recognize that some natural laws
+are enforced by persons, not physics. Some of them
+will grant power, or knowledge, but they must be placated, or even bribed.
+They're not of this earth, not demons or devils, and they aren't always
+friendly. To me it's just an unpleasant necessity on the path to power.
+When I'm done, they won't laugh anymore!\"" CR>)
+ (<EQUAL? ,TIED-UP? 3>
+ <TELL CR
+CTHE ,PROFESSOR " enters another pentagram, and begins a highly
+choreographed ritual. \"This may seem a little silly to you, but the
+symbology is what's important. Certain alignments, certain aspects.
+In a few moments, it won't matter anyway,\" he remarks. \"There is very
+little room for error here, so be calm.\" He chants, he brandishes
+strange instruments, moves about
+inside the pentagram, and occasionally points to you. It becomes clear
+exactly what he meant by the word \"bribe.\"" CR>)
+ (<EQUAL? ,TIED-UP? 4>
+ <TELL CR
+"The chant grows more complex">
+ <COND (<FSET? ,PENTAGRAM ,RMUNGBIT>
+ <TELL
+", the professor having difficulty with the almost unpronounceable words">)>
+ <TELL ", with rhythms and cadences that make
+you want to stop your ears. The room appears to be getting darker." CR>)
+ (<EQUAL? ,TIED-UP? 5>
+ <MOVE ,MIST ,HERE>
+ <TELL CR
+"A thick black mist begins to form in the room. Parts are darker, and
+parts lighter, and the dark parts form a disturbing shape. The professor
+chants and calls more loudly now">
+ <COND (<NOT <IN? ,PLAYER ,PENTAGRAM>>
+ <TELL ", clearly terrified of what may
+happen">)
+ (<FSET? ,PENTAGRAM ,RMUNGBIT>
+ <TELL ", his voice rising in a kind of
+hysteria">)>
+ <TELL ", and you realize the calls are being
+answered." CR>)
+ (<EQUAL? ,TIED-UP? 6>
+ <TELL CR
+"The room is now freezing cold, though the windows are shuttered and
+tightly curtained. Low, bone-rattling vibrations shake the room in
+cadence with the chant. The black mist is growing thicker. The professor ">
+ <COND (<NOT <IN? ,PLAYER ,PENTAGRAM>>
+ <TELL
+"is alternately looking at you and at the mist." CR>)
+ (<FSET? ,PENTAGRAM ,RMUNGBIT>
+ <TELL
+"gestures in your direction, an overtone of terror in his voice." CR>)
+ (ELSE
+ <TELL
+"chants more rapidly, producing strange guttural sounds, scarcely
+human." CR>)>)
+ (<EQUAL? ,TIED-UP? 7>
+ <COND (<HERE? ,ALCHEMY-LAB>
+ <TELL CR
+"The black mist swirls wildly around the room, and a deep bass voice
+gibbers out of thin air. ">
+ <COND (<NOT <IN? ,PLAYER ,PENTAGRAM>>
+ <TELL
+"\"No!\" screams the professor, and jumps toward you out of his own
+pentagram. He realizes what he has done, and tries to reenter, but the
+mist grabs at him." CR>)
+ (ELSE
+ <TELL CTHE ,PROFESSOR>
+ <COND (<FSET? ,PENTAGRAM ,RMUNGBIT>
+ <TELL
+" points madly toward you, and the mist follows." CR>)
+ (ELSE
+ <TELL
+"'s brow drips with sweat." CR>)>)>)
+ (ELSE
+ <TELL CR
+"You hear a deep bass voice, and a softer, pleading baritone." CR>)>)
+ (<EQUAL? ,TIED-UP? 8>
+ <REMOVE ,MIST>
+ <COND (<OR <IN? ,PLAYER ,PENTAGRAM>
+ <IN? ,PLAYER ,ALCHEMY-LAB>>
+ <CRLF>
+ <JIGS-UP
+"A thing like a tentacle with a demonic face wraps slowly around you.
+The room recedes into a great distance as you are pulled
+away. Before you die, you see what the tentacle is a part of.">)
+ (ELSE
+ <SETG TIED-UP? 0>
+ <ROB ,PROFESSOR ,ALCHEMY-LAB>
+ <MOVE ,PROFESSOR ,GLOBAL-OBJECTS>
+ <SCORE-OBJECT ,PROFESSOR>
+ <SETG PROF-DEAD? T>
+ <FCLEAR ,ALCHEMY-LAB ,TOUCHBIT>
+ <FCLEAR ,ALCHEMY-LAB ,ONBIT>
+ <DEQUEUE I-PROFESSOR>
+ <TELL CR
+"From above, you hear a thunderous noise, a maniacal scream, and
+then the sound of equipment smashing. ">
+ <COND (<FSET? ,ALCHEMY-TRAP-DOOR ,OPENBIT>
+ <FCLEAR ,ALCHEMY-TRAP-DOOR ,OPENBIT>
+ <TELL
+"The trapdoor slams shut, but around it">)
+ (ELSE
+ <TELL
+"Around the trapdoor">)>
+ <TELL
+" pours a blinding flash of light. Finally you hear an almost
+inaudible whimper, then nothing. The light fades">
+ <IN-DARK?>)>)>)
+ (<HERE? ,ALCHEMY-DEPT>
+ <TELL CR
+CTHE ,PROFESSOR " ">
+ <COND (<NOT ,PROF-FLAG>
+ <SETG PROF-FLAG T>
+ <TELL "gazes">)
+ (ELSE
+ <TELL "continues to gaze">)>
+ <TELL " at you ">
+ <COND (<AND ,PROF-MAD?
+ ,PROF-SEEN-NOTE?>
+ <TELL "with a distinctly predatory air." CR>)
+ (,PROF-MAD?
+ <TELL "with malign intent." CR>)
+ (ELSE
+ <TELL "in a bored and distracted way." CR>)>)
+ (ELSE
+ <DEQUEUE I-PROFESSOR>
+ <RFALSE>)>>
+
+<GLOBAL PROF-DEAD? <>>
+
+<OBJECT PENTAGRAM
+ (IN ALCHEMY-LAB)
+ (DESC "pentagram")
+ (SYNONYM PENTAG SHAPE LINE LINES)
+ (ADJECTIVE CHALK PENTAG)
+ (FLAGS NDESCBIT VEHBIT OPENBIT CONTBIT SEARCHBIT)
+ (CAPACITY 200)
+ (ACTION PENTAGRAM-F)>
+
+<ROUTINE PENTAGRAM-F ("OPT" (RARG <>) "AUX" O)
+ <COND (<RARG? BEG>
+ <COND (<AND <VERB? READ LOOK-INSIDE>
+ <NOT-REACHABLE?>>
+ <TELL
+,YOU-CANT-SEE THE ,PRSO " well enough from here to do that." CR>)
+ (<P? POUR * (<> ,GROUND)>
+ <NEW-PRSI ,PENTAGRAM>
+ <RTRUE>)
+ (<P? BOARD PENTAGRAM>
+ <TELL ,ALREADY-IN-IT CR>)
+ (<VERB? WALK>
+ <RFALSE> ;"all exits are handled in exit routines")
+ (<VERB? DISEMBARK EXIT>
+ <COND (<NOT ,TIED-UP?>
+ <MOVE ,WINNER ,HERE>
+ <CROSS-PENTAGRAM "out of">)
+ (<NOT <FSET? ,PENTAGRAM ,RMUNGBIT>>
+ <TELL
+"Your feet approach the chalk line, and then stop. You can't push your
+way out." CR>)
+ (ELSE
+ <MOVE ,WINNER ,HERE>
+ <TELL
+S "You push your way through ""a soft spot just over the scuff marks, and
+are outside the pentagram. The air is thick and close." CR>)>)
+ (<SET O <NOT-REACHABLE?>>
+ <COND (<FSET? ,PENTAGRAM ,RMUNGBIT>
+ <CANT-REACH-FROM-VEHICLE .O>)
+ (ELSE
+ <TELL
+"Your hand won't pass over the chalk line." CR>)>)>)
+ (<RARG? <>>
+ <COND (<VERB? EXAMINE>
+ <TELL
+"For want of a better word, call this a pentagram. It isn't
+particularly pentagonal, but it's an odd shape chalked on the floor,
+and it's roughly pentagonal." CR>)
+ (<P? PUT * PENTAGRAM>
+ <COND (<IDROP>
+ <MOVE ,PRSO ,PENTAGRAM>
+ <TELL "Dropped." CR>)
+ (ELSE <RTRUE>)>)
+ (<VERB? BOARD>
+ <MOVE ,PLAYER ,PENTAGRAM>
+ <CROSS-PENTAGRAM "into">)
+ (<P? POUR (COKE NITROGEN) *>
+ <COND (<FSET? ,PENTAGRAM ,RMUNGBIT>
+ <TELL
+"The pentagram is now almostly entirely effaced." CR>)
+ (ELSE
+ <TELL
+CTHE ,PRSO " pours on the ground, spreading towards the lines of the
+pentagram. As it reaches the nearest line, it begins to smoke and boil
+away, but never quite touches the chalk." CR>)>)
+ (<VERB? RUB MUNG CUT ERASE OPEN>
+ <COND (<PRSI? <> ,HANDS ,FEET>
+ <TELL
+"You try, but no part of your body will touch the chalk lines." CR>)
+ (<FSET? ,PENTAGRAM ,RMUNGBIT>
+ <TELL
+"You scuff it up some more." CR>)
+ (<PRSI? ,KNIFE>
+ <FSET ,PENTAGRAM ,RMUNGBIT>
+ <TELL
+"You cut the outer lines of the pentagram. It no longer completely
+encloses you.">
+ <PROF-REACTS>)
+ (<OR <FSET? ,PRSI ,WEAPONBIT>
+ <FSET? ,PRSI ,TOOLBIT>>
+ <TELL
+CTHE ,PRSI " passes over the chalk line, but doesn't have any effect on
+it." CR>)
+ (ELSE
+ <TELL
+CTHE ,PRSI " doesn't even touch the chalk line." CR>)>)
+ (<VERB? CLOSE>
+ <COND (<FSET? ,PENTAGRAM ,RMUNGBIT>
+ <TELL
+S "You don't have " "a piece of chalk to close it with. Besides, you don't
+know the incantation." CR>)>)>)>>
+
+<ROUTINE CROSS-PENTAGRAM (DIR)
+ <TELL
+"You get " .DIR " the pentagram, being careful not to further scuff the
+chalk." CR>>
+
+<ROUTINE PROF-REACTS ()
+ <COND (,TIED-UP?
+ <TELL
+" The professor sees what you've done out of the corner of his eye.">
+ <COND (<G? ,TIED-UP? 2>
+ <TELL
+" He stares, horrified. \"Stop, don't move!\" he says between verses of
+the chant. The chant takes on a pleading tone.">)
+ (ELSE
+ <ROB ,PLAYER <>>
+ <FCLEAR ,PENTAGRAM ,RMUNGBIT>
+ <TELL
+" He quickly slides over and redraws the pentagram. This time he performs
+a thorough search, removing all your possessions, tut-tutting all the
+while.">)>)>
+ <CRLF>>
+
+<ROUTINE ALCHEMY-DEPT-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"This office is clinically clean, shiny, and modern. It looks like
+something out of a science fiction movie. ">
+ <COND (<FSET? ,ALCHEMY-DOOR ,OPENBIT>
+ <TELL "An open">)
+ (ELSE <TELL "A closed">)>
+ <TELL " door to the north leads
+back into the corridor and an archway opens to the south." CR>)
+ (<RARG? ENTER>
+ <COND (<AND <EQUAL? ,OHERE ,CHEMISTRY-BLDG>
+ <NOT ,PROF-DEAD?>>
+ <FCLEAR ,ALCHEMY-DOOR ,LOCKED>
+ <FCLEAR ,ALCHEMY-DOOR ,OPENBIT>)>)>>
+
+<ROOM ALCHEMY-LAB
+ (IN ROOMS)
+ (DESC "Lab")
+ (NORTH PER ALCHEMY-LAB-EXIT)
+ (DOWN PER ALCHEMY-LAB-DOWN-EXIT)
+ (GLOBAL ARCHWAY ALCHEMY-TRAP-DOOR OUTLET LAB)
+ (ACTION ALCHEMY-LAB-F)>
+
+<ROUTINE ALCHEMY-LAB-DOWN-EXIT ()
+ <COND (<AND ,LAB-BENCH-MOVED?
+ <FSET? ,ALCHEMY-TRAP-DOOR ,OPENBIT>>
+ <MOVE ,WINNER ,HERE>
+ ,UNDER-ALCHEMY-LAB)
+ (,LAB-BENCH-MOVED?
+ <TELL "The trapdoor bars your way." CR>
+ <RFALSE>)
+ (ELSE
+ <TELL "There is no obvious way down from here." CR>
+ <RFALSE>)>>
+
+<ROUTINE ALCHEMY-LAB-EXIT ()
+ <COND (,TIED-UP?
+ <COND (<FSET? ,PENTAGRAM ,RMUNGBIT>
+ <TELL
+"You find the archway barred by a force you can't push through." CR>)
+ (ELSE
+ <TELL
+"You find it very hard to move. Your feet reach the chalk line and then
+seem to meet resistance, though there is nothing there but the chalk." CR>)>
+ <RFALSE>)
+ (ELSE
+ <MOVE ,WINNER ,HERE>
+ ,ALCHEMY-DEPT)>>
+
+<ROUTINE ALCHEMY-LAB-F (RARG)
+ <COND (<RARG? LOOK>
+ <COND (<NOT ,PROF-DEAD?>
+ <TELL
+"The lab is an ultramodern, fully equipped chemistry lab. Unfortunately,
+or perhaps fortunately, you aren't a chemistry major, so the equipment
+might as well be magical.">)
+ (ELSE
+ <TELL
+"The lab is a shambles. It looks like something red and sticky has
+been spread over the walls, ceiling, and floor. Much of the equipment,
+particularly that near the center of the room, has been destroyed.">)>
+ <COND (,LAB-BENCH-MOVED?
+ <TELL " There is ">
+ <AN-OPEN/CLOSED ,ALCHEMY-TRAP-DOOR>
+ <TELL " in the floor." CR>)
+ (ELSE <CRLF>)>)
+ (<RARG? BEG>
+ <COND (<P? EXAMINE GROUND>
+ <NEW-PRSO ,PENTAGRAM>
+ <RTRUE>)
+ (<VERB? EXAMINE READ LOOK-INSIDE
+ ASK-ABOUT TELL-ME-ABOUT TELL-ABOUT>
+ <RFALSE>)
+ (<AND <IN? ,PROFESSOR ,HERE>
+ <EQUAL? ,VAT ,PRSO ,PRSI>>
+
+ <COND (<L? ,TIED-UP? 3>
+ <TELL
+CTHE ,PROFESSOR ", none too gently, prevents you. \"Plenty of time for that
+later,\" he cautions you." CR>)
+ (<EQUAL? ,PERFORM-DEPTH 1>
+ <TELL
+CTHE ,PROFESSOR " watches you in horror, stumbling over his ritual." CR CR>
+ <RFALSE>)>)>)>>
+
+<OBJECT ALCHEMY-TRAP-DOOR
+ (IN LOCAL-GLOBALS)
+ (DESC "metal plate")
+ (SYNONYM TRAPDOOR DOOR PLATE)
+ (ADJECTIVE TRAP METAL)
+ (FLAGS DOORBIT NDESCBIT OPENABLE)
+ (ACTION ALCHEMY-TRAP-DOOR-F)>
+
+<GLOBAL IT-LIFTS-BUT "It lifts a few inches, but then hits ">
+
+<ROUTINE ALCHEMY-TRAP-DOOR-F ()
+ <COND (<HERE? ,ALCHEMY-LAB>
+ <COND (<VERB? EXAMINE>
+ <TELL
+,IT-LOOKS-LIKE "a hinged metal plate. There is a handle on one edge." CR>)
+ (<VERB? THROUGH>
+ <DO-WALK ,P?DOWN>)
+ (<VERB? OPEN RAISE>
+ <COND (<NOT ,LAB-BENCH-MOVED?>
+ <TELL
+,IT-LIFTS-BUT "the lab bench and goes no further." CR>)
+ (<NOT <FSET? ,PRSO ,OPENBIT>>
+ <FSET ,ALCHEMY-TRAP-DOOR ,OPENBIT>
+ <TELL
+"It swings open easily." CR>)>)
+ (<VERB? LOOK-INSIDE>
+ <COND (<FSET? ,ALCHEMY-TRAP-DOOR ,OPENBIT>
+ <TELL
+"You see a dark tunnel below." CR>)
+ (ELSE
+ <TELL
+"Your X-ray eyes appear to be nonfunctional today." CR>)>)>)
+ (ELSE
+ <COND (<VERB? EXAMINE>
+ <TELL
+,IT-LOOKS-LIKE "a metal plate in the ceiling." CR>)
+ (<VERB? THROUGH>
+ <DO-WALK ,P?UP>)
+ (<VERB? OPEN RAISE PUSH>
+ <COND (<NOT ,LAB-BENCH-MOVED?>
+ <TELL
+,IT-LIFTS-BUT "something and goes no
+further." CR>)
+ (<NOT <FSET? ,PRSO ,OPENBIT>>
+ <FSET ,ALCHEMY-TRAP-DOOR ,OPENBIT>
+ <TELL
+"It pushes open easily." CR>)>)
+ (<VERB? LOOK-INSIDE LOOK-BEHIND>
+ <COND (<NOT ,LIT>
+ <TELL ,TOO-DARK>)
+ (<FSET? ,ALCHEMY-TRAP-DOOR ,OPENBIT>
+ <TELL
+"You see a laboratory." CR>)
+ (ELSE
+ <TELL
+"Pushing the plate up as far as you can, you can see part of a workroom or
+lab of some kind." CR>)>)>)>>
+
+<OBJECT STUDENTS
+ (IN GLOBAL-OBJECTS)
+ (DESC "missing students")
+ (SYNONYM STUDENTS TOOLS)
+ (ADJECTIVE MISSING GRADUATE GRAD)
+ (FLAGS NDESCBIT PERSON)
+ (ACTION STUDENTS-F)>
+
+<ROUTINE STUDENTS-F ()
+ <GLOBAL-URCHINS-F ,STUDENTS>>
+
+<OBJECT GLOBAL-URCHINS
+ (IN GLOBAL-OBJECTS)
+ (DESC "missing urchins")
+ (SYNONYM URCHIN KIDS CHILDREN)
+ (ADJECTIVE MISSING)
+ (FLAGS NDESCBIT PERSON)
+ (ACTION GLOBAL-URCHINS-F)>
+
+<ROUTINE YOU-SEE-NO (OBJ)
+ <TELL
+"You see no " D .OBJ "." CR>>
+
+<ROUTINE GLOBAL-URCHINS-F ("OPT" (OBJ <>))
+ <COND (<NOT .OBJ> <SET OBJ ,GLOBAL-URCHINS>)>
+ <COND (<OR <WINNER? .OBJ>
+ <VERB? TELL SAY HELLO>>
+ <TELL
+"There is no reply." CR>
+ <COND (<PRSO? .OBJ>
+ <END-QUOTE>
+ <RFATAL>)
+ (ELSE <RTRUE>)>)
+ (<OR <HOSTILE-VERB?>
+ <VERB? SHOW SEARCH FIND>
+ <P? (EXAMINE TELL-ABOUT) .OBJ>>
+ <YOU-SEE-NO .OBJ>)
+ (<VERB? HELP UNTIE>
+ <BEYOND-HELP>)
+ (<P? WHAT (URCHINS GLOBAL-URCHINS)>
+ <TELL
+"That's what students call the local children who sometimes hang
+around Tech. They are usually blamed when anything is stolen,
+generally mistrusted, and often booted off campus by the campus
+police." CR>)>>
+
+<ROUTINE BEYOND-HELP ()
+ <TELL "They ">
+ <COND (<AND <EQUAL? ,PRSO ,STUDENTS> ,SEEN-PIT?>
+ <TELL "are">)
+ (ELSE <TELL "may be">)>
+ <TELL " beyond help." CR>>
+
+<OBJECT LOVECRAFT
+ (IN ALCHEMY-LAB)
+ (DESC "Alchemy Department computer")
+ (SYNONYM LOVECRAFT PC COMPUTER SCREEN)
+ (ADJECTIVE ALCHEMY DEPART)
+ (FLAGS READBIT AN)
+ (TEXT "Written with a marking pen on the display is \"Lovecraft.\"")
+ (SIZE 30)
+ (ACTION LOVECRAFT-F)>
+
+<ROUTINE LOVECRAFT-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This machine looks just like the ones in the terminal room. ">
+ <TELL <GETP ,PRSO ,P?TEXT>>
+ <COND (<NOT <FSET? ,LOVECRAFT ,POWERBIT>>
+ <TELL " It's turned off.">)>
+ <CRLF>)
+ (<VERB? WHO>
+ <TELL
+"I suggest you consult your local library or any practitioner of
+the occult arts." CR>)
+ (<VERB? LAMP-ON>
+ <COND (<NOT <FSET? ,LOVECRAFT ,POWERBIT>>
+ <FSET ,LOVECRAFT ,POWERBIT>
+ <TELL
+"You turn the machine on, it performs a quick self-check, and then displays
+a message on the screen: "
+S "\"Unable to boot because: No disk inserted. Please
+insert a dismountable disk.\"">
+ <COND (<IN? ,PROFESSOR ,HERE>
+ <TELL
+" The professor, who has been watching you, smiles.">)>
+ <CRLF>)
+ (ELSE
+ <TELL
+"It's on, for what little good that will do you." CR>)>)
+ (<VERB? LAMP-OFF>
+ <COND (<FSET? ,LOVECRAFT ,POWERBIT>
+ <COMPUTER-POWERS-OFF>)
+ (ELSE
+ <ITS-ALREADY-X "off">)>)>>
+
+<OBJECT RING
+ (IN PROFESSOR)
+ (DESC "brass hyrax")
+ (SYNONYM RING HYRAX)
+ (ADJECTIVE BRASS GOLD)
+ (FLAGS TAKEBIT TRYTAKEBIT TOUCHBIT)
+ (ACTION RING-F)>
+
+<ROUTINE RING-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The G.U.E. Tech class ring is a gold ring depicting a hyrax
+eating a twig. Such rings are familiarly known as \"brass
+hyraxes.\"" CR>)
+ (<AND <VERB? TAKE-OFF>
+ <FSET? ,GLOVES ,WEARBIT>>
+ <TELL
+,YOU-HAVE-TO "take off your gloves first." CR>)
+ (<VERB? WEAR>
+ <COND (<FSET? ,GLOVES ,WEARBIT>
+ <TELL
+CTHE ,RING " won't go on over the gloves." CR>)
+ (<EQUAL? <IWEAR> T>
+ <TELL
+"It fits surprisingly well." CR>)
+ (ELSE <RTRUE>)>)>>
+
+<OBJECT PROFESSOR
+ (IN ALCHEMY-DEPT)
+ (DESC "professor")
+ (SYNONYM PROFESSOR ALCHEMY MAN PROF)
+ (FLAGS PERSON OPENBIT CONTBIT SEARCHBIT)
+ (VALUE 5)
+ (CONTFCN PROFESSOR-F)
+ (DESCFCN PROFESSOR-DESC)
+ (ACTION PROFESSOR-F)>
+
+<ROUTINE PROFESSOR-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <TELL CTHE ,PROFESSOR " is ">
+ <COND (<G? ,TIED-UP? 2>
+ <TELL "performing a strange ritual ">)>
+ <TELL "here.">
+ <RFATAL>)>>
+
+<ROUTINE PROFESSOR-F ("OPT" (RARG <>))
+ <COND (<RARG? CONTAINER>
+ <COND (<OR <VERB? EXAMINE TAKE SHOW WEAR>
+ <AND <WINNER? ,PROFESSOR>
+ <VERB? GIVE>>>
+ <COND (<PRSO? ,RING>
+ <SETG PROF-MAD? T>
+ <TELL
+"He thrusts his hand into his pocket." CR>)
+ (ELSE
+ <TELL
+"\"You'll get it. All in good time.\"" CR>)>)>)
+ (<WINNER? ,PROFESSOR>
+ <COND (<VERB? GIVE> <RFALSE>)
+ (<VERB? TELL-ME-ABOUT>
+ <COND (<G? ,TIED-UP? 2>
+ <TELL
+CTHE ,PROFESSOR " is intently following his ritual and won't be
+distracted." CR>)
+ (<PRSO? ,ODD-PAPER>
+ <SETG PROF-MAD? T>
+ <TELL
+"\"I don't like your insinuations.\"" CR>)
+ (<PRSO? ,RING>
+ <TELL
+"\"Just a trinket.\"" CR>)
+ (<PRSO? ,LAB>
+ <COND (<LAB-ENTER?>
+ <CRLF>
+ <GOTO ,ALCHEMY-LAB>)
+ (ELSE <RTRUE>)>)
+ (<PRSO? ,SIGNUP>
+ <TELL
+"\"We don't have much lab space. Everyone has to sign up for lab time.\"" CR>)
+ (<PRSO? ,STUDENTS>
+ <TELL
+"\"I don't know anything about them. Tech is high-pressure.
+Some people can't take it.\"" CR>)
+ (<PRSO? ,NOTE>
+ <COND (,PROF-SEEN-NOTE?
+ <TELL
+"\"Obviously a nut case. He knew he was going to
+flunk out, and this is clearly an attempt to put the blame somewhere
+else.\"" CR>)
+ (ELSE
+ <TELL
+"\"What note is that?\" he asks, nervously." CR>)>)
+ (<PRSO? ,VAT>
+ <TELL
+"\"Just a little experiment of mine. The label is just a joke.\"" CR>)
+ (<PRSO? ,LOVECRAFT>
+ <TELL
+"\"The machines in our department have names like that. Lovecraft
+wrote some stories about alchemy. We've got Paracelsus, Dunsany,
+and a couple of others, too.\"" CR>)>)
+ (,TIED-UP?
+ <TELL
+,NO-RESPONSE CR>)
+ (ELSE
+ <TELL
+CTHE ,PROFESSOR " looks at you in much the way a cat looks at
+a mouse." CR>)>)
+ (<AND ,PROF-DEAD?
+ <NOT <ABSTRACT-VERB?>>>
+ <TELL CTHE ,PROFESSOR " is no more." CR>)
+ (<VERB? EXAMINE>
+ <TELL
+"The man looks like a professor. He's wearing a white lab coat, rather
+stained with chemicals, and a G.U.E. Tech class ring. ">
+ <COND (<HERE? ,ALCHEMY-DEPT>
+ <TELL
+"He watches you with an ambiguously predatory air." CR>)
+ (ELSE
+ <TELL
+"He's working on something at the lab bench in front of him." CR>)>)
+ ;(<P? ASK-FOR PROFESSOR>
+ <PERFORM ,V?TAKE ,PRSI>
+ <RTRUE>)
+ (<P? (SHOW GIVE) * PROFESSOR>
+ <COND (<G? ,TIED-UP? 2>
+ <TELL
+CTHE ,PROFESSOR " is nervously following his ritual." CR>)
+ (<PRSO? ,SMOOTH-STONE ,HAND ,KNIFE>
+ <SETG PROF-MAD? T>
+ <MOVE ,PRSO ,PROFESSOR>
+ <TELL
+"\"Very interesting! I'll take that!\"" CR>)
+ (<PRSO? ,NOTE>
+ <SETG PROF-SEEN-NOTE? T>
+ <SETG PROF-MAD? T>
+ <MOVE ,NOTE ,PROFESSOR>
+ <TELL
+"He reads it carefully. \"What drivel! This just confirms my suspicions.
+He had clearly gone over the edge. Drug use, drinking, insanity.
+It's only too bad that I didn't realize what was happening. I might have
+helped him.\"" CR>)
+ (ELSE
+ <TELL
+"He doesn't seem interested." CR>)>)
+ (<VERB? THROW> <RFALSE>)
+ (<HOSTILE-VERB?>
+ <COND (<G? ,TIED-UP? 6>
+ <TELL
+"The mist protects him, almost possessively." CR>)
+ (<G? ,TIED-UP? 2>
+ <TELL
+CTHE ,PROFESSOR ", in his pentagram, is invulnerable." CR>)
+ (ELSE
+ <SETG PROF-MAD? T>
+ <TELL
+"With contemptuous ease, the professor prevents you.">
+ <COND (<AND ,PRSI <FSET? ,PRSI ,WEAPONBIT>>
+ <MOVE ,PRSI ,PROFESSOR>
+ <TELL
+" \"I'll take this,\" he says. \"Just for safekeeping.\" He makes "
+THE ,PRSI " disappear.">)>
+ <CRLF>)>)>>
+
+<OBJECT LAB-BENCH
+ (IN ALCHEMY-LAB)
+ (DESC "lab bench")
+ (SYNONYM BENCH)
+ (ADJECTIVE LAB)
+ (FLAGS SURFACEBIT OPENBIT CONTBIT SEARCHBIT)
+ (CAPACITY 200)
+ (ACTION LAB-BENCH-F)>
+
+<ROUTINE LAB-BENCH-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The bench is a chemistry lab bench. It has a marble top, and casters
+at each corner. Various equipment litters the bench, none of which you
+recognize">
+ <COND (<FIRST? ,LAB-BENCH>
+ <TELL
+", but the lab bench also contains ">
+ <DESCRIBE-REST ,LAB-BENCH>)>
+ <TELL ,PERIOD>)
+ (<VERB? LOOK-UNDER>
+ <COND (<NOT ,LAB-BENCH-MOVED?>
+ <TELL
+"You can see a metal plate beneath the bench. Only part
+of it is visible." CR>)
+ (ELSE
+ <TELL "Nothing but concrete floor there." CR>)>)
+ (<VERB? MOVE PUSH>
+ <COND (<NOT ,LAB-BENCH-MOVED?>
+ <SETG LAB-BENCH-MOVED? T>
+ <TELL
+"It's heavy, but it moves, revealing a hinged metal trapdoor beneath." CR>)
+ (ELSE
+ <TELL "It rolls a little." CR>)>)>>
+
+<GLOBAL LAB-BENCH-MOVED? <>>
+
+<OBJECT VAT
+ (IN LAB-BENCH)
+ (DESC "vat")
+ (SYNONYM VAT LABEL)
+ (ADJECTIVE VAT BUBBLING GLASS PYREX STICKY)
+ (FLAGS TAKEBIT READBIT OPENBIT CONTBIT TRANSBIT SEARCHBIT)
+ (CAPACITY 20)
+ (SIZE 20)
+ (TEXT
+"The text is a long chemical-sounding name typed on a
+label affixed to the container. Below is written in pencil
+\"Elixir of Life.\"")
+ (CONTFCN VAT-CONT-F)
+ (ACTION VAT-F)>
+
+<ROUTINE VAT-CONT-F (RARG)
+ <COND (<VERB? TAKE>
+ <COND (<PRSO? ,ELIXIR>
+ <TELL
+,YOU-CANT "take it, it's a liquid." CR>
+ <RTRUE>)
+ (<EQUAL? <ITAKE> <> ,M-FATAL>
+ <RTRUE>)
+ (<AND <PRSO? ,HAND>
+ <FSET? ,HAND ,PERSON>>
+ <TELL
+"You grab the wiggling hand and draw it forth, newly animated, from the
+vat.">)
+ (ELSE
+ <TELL
+"You reach into the liquid, fish around rapidly due to the
+horrible feel of the chemicals, and draw out " THE ,PRSO ".">)>
+ <TELL
+" As it emerges, the elixir flows off.">
+ <COND (<AND <PRSO? ,HAND>
+ <FSET? ,HAND ,PERSON>>
+ <SETG SCORE <+ ,SCORE ,HAND-ANIMATED-SCORE>>
+ <SETG HAND-ANIMATED-SCORE 0>
+ <TELL
+" The hand scuttles up your arm and perches quietly on your
+shoulder.">)>
+ <CRLF>)>>
+
+<ROUTINE VAT-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+S "This is a large ""(a couple of liters, at least) glass or pyrex vat. It
+has a label stuck to it. ">
+ <DESCRIBE-SENT ,VAT>
+ <CRLF>)
+ (<AND <P? PUT * VAT>
+ <IN? ,ELIXIR ,VAT>>
+ <COND (<PRSO? ,DEAD-RAT>
+ <REMOVE ,DEAD-RAT>
+ <TELL
+"You dip the dead rat into the elixir. Almost immediately it convulses,
+begins to flop around in the liquid, and then springs out onto the
+floor! It scurries away before you can catch it." CR>)
+ (<PRSO? ,HAND>
+ <MOVE ,HAND ,VAT>
+ <COND (<FSET? ,HAND ,PERSON>
+ <TELL
+"Nothing unusual happens (compared to the first time, anyway)." CR>)
+ (ELSE
+ <QUEUE I-ANIMATE-HAND -1>
+ <TELL
+"When you dip the mummified hand in the liquid, the elixir begins to
+bubble furiously. You can't really see the hand, except when
+a finger pokes up every so often." CR>)>)
+ (<PRSO-TOO-BIG?>
+ <TELL ,NO-ROOM CR>)
+ (ELSE
+ <FCLEAR ,PRSO ,WEARBIT>
+ <MOVE ,PRSO ,VAT>
+ <TELL
+"You drop " THE ,PRSO " into the vat, where it is completely covered
+by the tarry liquid." CR>)>)
+ (<VERB? OPEN CLOSE>
+ <TELL-YUKS>)
+ (<P? POUR VAT>
+ <NEW-PRSO ,ELIXIR>
+ <RTRUE>)
+ (<VERB? REACH-IN>
+ <TELL
+"You feel the thick tarry liquid." CR>)>>
+
+<OBJECT ELIXIR
+ (IN VAT)
+ (DESC "tarry liquid")
+ (SYNONYM LIQUID ELIXIR LIFE)
+ (ADJECTIVE TARRY BLACK ELIXIR)
+ (FLAGS TAKEBIT TRYTAKEBIT)
+ (ACTION ELIXIR-F)>
+
+<ROUTINE ELIXIR-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The elixir is thick and tarry. Torpid bubbles break the
+surface every so often, though you can find no source of heat to
+produce them." CR>)
+ (<VERB? DRINK>
+ <TELL
+"It would be like drinking road tar." CR>)
+ (<VERB? RUB>
+ <TELL
+"You touch the liquid with your finger. It's very unpleasant.
+The liquid is stingingly hot. You pull your finger out, and
+it is some time before it feels normal again." CR>)
+ (<P? TAKE * <>>
+ <COND (<IN? ,ELIXIR ,VAT>
+ <NEW-PRSO ,VAT>
+ <RTRUE>)>)
+ (<P? (POUR DROP THROW) ELIXIR>
+ <TELL
+"Remember those ketchup commercials? Remember how slow the winning
+ketchup was? Well, this is a lot slower. The liquid has a very
+high surface tension, and pours so slowly that you'd be here all night
+waiting for it to finish." CR>)
+ (<P? PUT * ,ELIXIR>
+ <NEW-PRSI ,VAT>)>>
+
+<GLOBAL HAND-ANIMATED-SCORE 5>
+
+<GLOBAL ANIMATION-COUNT 0>
+
+<ROUTINE I-ANIMATE-HAND ("AUX" (HERE? <>))
+ <COND (<NOT <IN? ,HAND ,VAT>>
+ <DEQUEUE I-ANIMATE-HAND>
+ <RFALSE>)>
+ <COND (<EQUAL? <META-LOC ,VAT> ,HERE>
+ <SET HERE? T>)>
+ <COND (<OR <G? <SETG ANIMATION-COUNT <+ ,ANIMATION-COUNT 1>> 2>
+ <FSET? ,HAND ,PERSON>>
+ <FSET ,HAND ,PERSON>
+ <COND (.HERE?
+ <TELL CR
+"The hand is trying to crawl out of the vat.">
+ <COND (<NOT <FSET? ,HAND ,PERSON>>
+ <TELL
+" The fingers flex and grab at the slippery sides, but in vain.">)>
+ <CRLF>)>)
+ (<EQUAL? ,ANIMATION-COUNT 1>
+ <COND (.HERE?
+ <TELL CR
+"The hand bobs to the surface. It's odd, but it looked like one of the
+fingers moved." CR>)>)
+ (ELSE
+ <COND (.HERE?
+ <TELL CR
+"The hand splashes to the surface. The fingers are moving!" CR>)>)>>
+
+<ROOM ENGINEERING-BLDG
+ (IN ROOMS)
+ (DESC "Engineering Building")
+ (LDESC
+"This building extends a long way south from the Infinite Corridor. It
+too is full of closed, locked offices.")
+ (EAST "The offices are all closed, locked, and dark.")
+ (WEST "The offices are all closed, locked, and dark.")
+ (SOUTH "The offices are all closed, locked, and dark.")
+ (NORTH TO INF-1)
+ (FLAGS ONBIT)
+ (GLOBAL OFFICE-DOOR)>
+
+<ROOM INF-1
+ (IN ROOMS)
+ (DESC "Infinite Corridor")
+ (SIZE 1)
+ (WEST TO MASS-AVE)
+ (OUT TO MASS-AVE)
+ (EAST PER WAXER-EXIT) ;INF-2
+ (NORTH TO AERO-LOBBY)
+ (SOUTH TO ENGINEERING-BLDG)
+ (GLOBAL POWER-CORD GLOBAL-MAINTENANCE-MAN GLOBAL-FLOOR-WAXER
+ OUTSIDE-DOOR OFFICE-DOOR)
+ (FLAGS ONBIT)
+ (ACTION INF-F)>
+
+<ROOM INF-2
+ (IN ROOMS)
+ (DESC "Infinite Corridor")
+ (SIZE 2)
+ (WEST TO INF-1)
+ (EAST PER WAXER-EXIT) ;INF-3
+ (NORTH "The offices are all closed, locked, and dark.")
+ (SOUTH "The offices are all closed, locked, and dark.")
+ (GLOBAL POWER-CORD GLOBAL-FLOOR-WAXER GLOBAL-MAINTENANCE-MAN
+ OFFICE-DOOR)
+ (FLAGS ONBIT)
+ (ACTION INF-F)>
+
+<ROOM INF-3
+ (IN ROOMS)
+ (DESC "Infinite Corridor")
+ (SIZE 3)
+ (WEST TO INF-2)
+ (EAST PER WAXER-EXIT) ;INF-4
+ (UP TO GREAT-DOME)
+ (SOUTH PER GREAT-COURT-EXIT)
+ (OUT PER GREAT-COURT-EXIT)
+ (GLOBAL POWER-CORD GLOBAL-FLOOR-WAXER GLOBAL-MAINTENANCE-MAN
+ OFFICE-DOOR OUTSIDE-DOOR)
+ (FLAGS ONBIT)
+ (ACTION INF-F)>
+
+<GLOBAL DOOR-WARNING <>>
+
+<ROUTINE GREAT-COURT-EXIT ()
+ <COND (<WINNER? ,URCHIN> <RFALSE>)
+ (,DOOR-WARNING ,GREAT-COURT)
+ (ELSE
+ <SETG DOOR-WARNING T>
+ <TELL
+"Remember, this is one of the doors that's always locked at night.
+You won't be able to get back in if you go out." CR>
+ <RFALSE>)>>
+
+<ROOM INF-4
+ (IN ROOMS)
+ (DESC "Infinite Corridor")
+ (SIZE 4)
+ (WEST TO INF-3)
+ (EAST PER WAXER-EXIT) ;INF-5
+ (NORTH "The offices are all closed, locked, and dark.")
+ (SOUTH "The offices are all closed, locked, and dark.")
+ (GLOBAL POWER-CORD GLOBAL-FLOOR-WAXER GLOBAL-MAINTENANCE-MAN OFFICE-DOOR)
+ (FLAGS ONBIT)
+ (ACTION INF-F)>
+
+<ROOM INF-5
+ (IN ROOMS)
+ (SIZE 5)
+ (DESC "Infinite Corridor")
+ (WEST TO INF-4)
+ (NORTH PER WAXER-EXIT) ;NUTRITION-BLDG
+ (SOUTH PER WAXER-EXIT) ;CHEMISTRY-BLDG
+ (GLOBAL POWER-CORD GLOBAL-FLOOR-WAXER GLOBAL-MAINTENANCE-MAN)
+ (FLAGS ONBIT)
+ (ACTION INF-F)>
+
+<ROUTINE WAXER-EXIT ()
+ <COND (<WINNER? ,URCHIN> <INF-EAST-EXIT <LOC ,URCHIN>>)
+ (<AND <IN? ,FLOOR-WAXER ,HERE>
+ <IN? ,MAINTENANCE-MAN ,FLOOR-WAXER>>
+ <THIS-IS-IT ,MAINTENANCE-MAN>
+ <COND (,CORD-SEVERED?
+ <MAINT-DESCENDS>
+ <COND (<IN? ,FLOOR-WAX <LOC ,MAINTENANCE-MAN>>
+ <INF-EAST-EXIT ,HERE>)>)
+ (ELSE
+ <TELL
+"In a deft maneuver, " THE ,MAINTENANCE-MAN " steers the " 'FLOOR-WAXER " into
+your path, blocking your advance." CR>)>
+ <RFALSE>)
+ (<AND ,CORD-SEVERED?
+ <IN? ,MAINTENANCE-MAN ,HERE>
+ <FSET? ,MAINTENANCE-MAN ,PERSON>
+ <NOT <IN? ,FLOOR-WAX ,HERE>>>
+ <THIS-IS-IT ,MAINTENANCE-MAN>
+ <TELL
+CTHE ,MAINTENANCE-MAN S " lurches toward you" ", grasping and panting. There is
+no way to go around him." CR>
+ <RFALSE>)
+ (ELSE
+ <INF-EAST-EXIT ,HERE>)>>
+
+<ROUTINE INF-EAST-EXIT (L)
+ <COND (<EQUAL? .L ,INF-1>
+ ,INF-2)
+ (<EQUAL? .L ,INF-2>
+ ,INF-3)
+ (<EQUAL? .L ,INF-3>
+ ,INF-4)
+ (<EQUAL? .L ,INF-4>
+ ,INF-5)
+ (<EQUAL? .L ,INF-5>
+ <COND (<EQUAL? ,P-WALK-DIR ,P?NORTH>
+ ,NUTRITION-BLDG)
+ (ELSE
+ ,CHEMISTRY-BLDG)>)>>
+
+<ROUTINE INF-F (RARG "AUX" L)
+ <COND (<RARG? LOOK>
+ <TELL
+"The so-called infinite corridor runs from east to west in the main
+campus building.">
+ <COND (<HERE? ,INF-1>
+ <TELL " This is the west end.">)
+ (<HERE? ,INF-2 ,INF-3 ,INF-4>
+ <TELL " The corridor extends both ways from here.">)
+ (<HERE? ,INF-5>
+ <TELL " This is the east end.">)>
+ <COND (<HERE? ,INF-2 ,INF-4>
+ <TELL
+" Many closed and locked offices are to the north and south.">)
+ (<HERE? ,INF-1>
+ <TELL
+" Side corridors lead north and south, and a set of doors leads west into
+the howling blizzard.">)
+ (<HERE? ,INF-3>
+ <TELL
+" A stairway leads up, and a door leads out to the Great Court.">)
+ (<HERE? ,INF-5>
+ <TELL
+" The corridor branches north and south here.">)>
+ <CRLF>)
+ (<RARG? END>
+ <COND (<AND <NOT <IN? ,FLOOR-WAXER ,HERE>>
+ <VERB? WALK LOOK>>
+ <TELL CR
+S "There is a ""largish machine ">
+ <COND (<NOT ,CORD-SEVERED?>
+ <TELL "being operated ">)>
+ <TELL ,DOWN-THE-HALL>
+ <FLOOR-WAXER-DIRECTION>
+ <CRLF>)>)
+ (<RARG? ENTER>
+ <SETG DOOR-WARNING <>>
+ <COND (<EQUAL? ,OHERE ,INF-1 ,INF-2 ,INF-3 ,INF-4 ,INF-5>)
+ (<AND <NOT <FSET? ,HERE ,TOUCHBIT>>
+ <NOT <QUEUE I-WAXER-MOVES 10 T>>>
+ T)
+ (<AND <IN? ,MAINTENANCE-MAN ,HERE>
+ <FSET? ,MAINTENANCE-MAN ,PERSON>>
+ <QUEUE I-MAINT-ATTACK -1>)>)>>
+
+<ROUTINE FLOOR-WAXER-DIRECTION ("AUX" L)
+ <SET L <LOC ,FLOOR-WAXER>>
+ <COND (<OR <HERE? ,INF-1>
+ <AND <HERE? ,INF-2>
+ <EQUAL? .L ,INF-3 ,INF-4 ,INF-5>>
+ <AND <HERE? ,INF-3>
+ <EQUAL? .L ,INF-4 ,INF-5>>
+ <AND <HERE? ,INF-4>
+ <EQUAL? .L ,INF-5>>>
+ <TELL "east.">)
+ (ELSE
+ <TELL "west.">)>>
+
+<OBJECT GLOBAL-MAINTENANCE-MAN
+ (IN LOCAL-GLOBALS)
+ (DESC "maintenance man")
+ (SYNONYM MAN)
+ (ADJECTIVE MAINTENANCE)
+ (FLAGS PERSON)
+ (GENERIC GENERIC-MAINTENANCE-MAN-F)
+ (ACTION GLOBAL-MAINTENANCE-MAN-F)>
+
+<ROUTINE GENERIC-MAINTENANCE-MAN-F ()
+ <COND (<EQUAL? <META-LOC ,MAINTENANCE-MAN> ,HERE>
+ ,MAINTENANCE-MAN)
+ (ELSE
+ ,GLOBAL-MAINTENANCE-MAN)>>
+
+<ROUTINE GLOBAL-MAINTENANCE-MAN-F ()
+ <COND (<VERB? EXAMINE FIND>
+ <COND (<LOC ,MAINTENANCE-MAN>
+ <MAINTENANCE-MAN-F>)
+ (ELSE
+ <YOU-SEE-NO ,MAINTENANCE-MAN>)>)
+ (<AND <P? POUR * GLOBAL-MAINTENANCE-MAN>
+ <HERE? ,GREAT-DOME>
+ <IN? ,MAINTENANCE-MAN ,INF-3>>
+ <RFALSE>)
+ (<NOT <ABSTRACT-VERB?>>
+ <TELL "He's not here, but he might be soon!" CR>
+ <COND (<VERB? TELL>
+ <END-QUOTE>)
+ (ELSE <RTRUE>)>)>>
+
+<OBJECT MAINTENANCE-MAN
+ (IN FLOOR-WAXER)
+ (DESC "maintenance man")
+ (SYNONYM MAN)
+ (ADJECTIVE MAINTENANCE)
+ (FLAGS PERSON)
+ (GENERIC GENERIC-MAINTENANCE-MAN-F)
+ (ACTION MAINTENANCE-MAN-F)>
+
+<ROUTINE MAINTENANCE-MAN-F ("AUX" W)
+ <COND (<WINNER? ,MAINTENANCE-MAN>
+ <COND (<NOT <EQUAL? <META-LOC ,MAINTENANCE-MAN> ,HERE>>
+ <TELL "He" ,IS-DOWN-THE-HALL>)
+ (ELSE
+ <COND (,CORD-SEVERED?
+ <TELL
+"He snarls at you angrily.">)
+ (ELSE
+ <TELL
+"He replies in a language you do not recognize.">)>
+ <TELL " The words are
+guttural and jarring." CR>)>
+ <END-QUOTE>)
+ (<VERB? EXAMINE>
+ <COND (,CORD-SEVERED?
+ <TELL
+CTHE ,MAINTENANCE-MAN " is very annoyed with you." CR>)
+ (ELSE
+ <TELL
+"He looks tired, bored, almost zombie-like." CR>)>)
+ (<VERB? SHOW GIVE>
+ <TELL
+"He doesn't react." CR>)
+ (<OR <VERB? ATTACK KILL>
+ <P? THROW * ,MAINTENANCE-MAN>>
+ <COND (<NOT <VERB? THROW>>
+ <SET W ,PRSI>)
+ (ELSE
+ <SET W ,PRSO>)>
+ <COND (<OR <VERB? THROW> <EQUAL? .W ,AXE>>
+ <MOVE .W <META-LOC ,MAINTENANCE-MAN>>)>
+ <COND (<EQUAL? .W <> ,HANDS>
+ <TELL
+,YOU-CANT "hurt him with your hands!" CR>)
+ (ELSE
+ <TELL CTHE .W " ">
+ <COND (<IN? ,MAINTENANCE-MAN ,FLOOR-WAXER>
+ <COND (<VERB? THROW>
+ <TELL
+S "misses by a mile""!" CR>)
+ (ELSE
+ <TELL
+"can't reach him in " THE ,FLOOR-WAXER "!" CR>)>)
+ (<QUEUED? I-MAINT-DISSOLVES>
+ <TELL
+S "misses by a mile"" as " THE ,MAINTENANCE-MAN " slips again!" CR>)
+ (<EQUAL? .W ,AXE>
+ <COND (<VERB? THROW>
+ <TELL
+"sails through the air, end over end, and makes a direct hit in">)
+ (ELSE
+ <TELL
+"chops into">)>
+ <TELL
+" his chest, where it sticks. Ed Ames would be proud. The force of the
+blow staggers him a
+bit. He looks down at the axe with a certain perplexity, then pulls it
+free, the wound making a sickening sucking sound." CR>)
+ (<EQUAL? .W ,SMOOTH-STONE>
+ <TELL
+"hits him right between the eyes. He falls to the ground,
+stunned. There is now what looks like a large burn mark on his forehead.
+He ignores it and rises." CR>)
+ (<EQUAL? .W ,NITROGEN>
+ <TELL
+"makes a good show, but none actually gets on him." CR>)
+ (<FSET? .W ,WEAPONBIT>
+ <COND (<OR <VERB? THROW> <EQUAL? .W ,AXE>>
+ <TELL
+"sails toward him, but he bats it">)
+ (ELSE
+ <TELL
+"is pushed">)>
+ <TELL " contemptuously aside,
+barely slowing his advance." CR>)
+ (ELSE
+ <TELL
+"does about as much damage as a piece of thistledown." CR>)>)>)
+ (<VERB? WALK-AROUND>
+ <COND (,CORD-SEVERED?
+ <TELL
+,YOU-CANT "evade him." CR>)>)>>
+
+<GLOBAL WAX-WEST? <>>
+
+<ROUTINE I-WAXER-MOVES ("AUX" (L <LOC ,FLOOR-WAXER>) NL TMP)
+ <QUEUE I-WAXER-MOVES 5>
+ <COND (<AND ,WAX-WEST? <EQUAL? .L ,INF-1>>
+ <SETG WAX-WEST? <>>)
+ (<AND <NOT ,WAX-WEST?> <EQUAL? .L ,INF-5>>
+ <SETG WAX-WEST? T>)>
+ <COND (,WAX-WEST?
+ <COND (<AND <EQUAL? .L ,INF-3>
+ <HERE? ,GREAT-DOME ,TOP-OF-DOME
+ ,DOME-ROOF ,ON-DOME>>
+ <SETG WAX-WEST? <>>
+ <RFALSE>)
+ (<HERE? .L>
+ <SETG WAX-WEST? <>>
+ <TELL CR
+CTHE ,FLOOR-WAXER " continues waxing a section of floor nearby. "
+CTHE ,MAINTENANCE-MAN " operating it stares at you suspiciously." CR>
+ <RTRUE>)>
+ <COND (<EQUAL? .L ,INF-2>
+ <SET NL ,INF-1>)
+ (<EQUAL? .L ,INF-3>
+ <SET NL ,INF-2>)
+ (<EQUAL? .L ,INF-4>
+ <SET NL ,INF-3>)
+ (<EQUAL? .L ,INF-5>
+ <SET NL ,INF-4>)>)
+ (ELSE
+ <COND (<EQUAL? .L ,INF-4>
+ <SET NL ,INF-5>)
+ (<EQUAL? .L ,INF-3>
+ <SET NL ,INF-4>)
+ (<EQUAL? .L ,INF-2>
+ <SET NL ,INF-3>)
+ (<EQUAL? .L ,INF-1>
+ <SET NL ,INF-2>)>)>
+ <MOVE ,FLOOR-WAXER .NL>
+ <COND (<EQUAL? .NL ,INF-1> <SET TMP ,POWER-CORD>)
+ (ELSE <SET TMP ,GLOBAL-FLOOR-WAXER>)>
+ <PUT-GLOBAL ,INF-1 0 .TMP>
+ <COND (<EQUAL? .NL ,INF-1 ,INF-2> <SET TMP ,POWER-CORD>)
+ (ELSE <SET TMP ,GLOBAL-FLOOR-WAXER>)>
+ <PUT-GLOBAL ,INF-2 0 .TMP>
+ <COND (<EQUAL? .NL ,INF-4 ,INF-5> <SET TMP ,POWER-CORD>)
+ (ELSE <SET TMP ,GLOBAL-FLOOR-WAXER>)>
+ <PUT-GLOBAL ,INF-4 0 .TMP>
+ <COND (<EQUAL? .NL ,INF-5> <SET TMP ,POWER-CORD>)
+ (ELSE <SET TMP ,GLOBAL-FLOOR-WAXER>)>
+ <PUT-GLOBAL ,INF-5 0 .TMP>
+ <COND (<HERE? .NL>
+ <TELL CR
+CTHE ,FLOOR-WAXER ", approaching from the ">
+ <COND (,WAX-WEST? <TELL "east">)
+ (ELSE <TELL "west">)>
+ <TELL ", is now here." CR>)
+ (<HERE? .L>
+ <TELL CR
+CTHE ,FLOOR-WAXER " waxes away to the ">
+ <COND (,WAX-WEST? <TELL "west">)
+ (ELSE <TELL "east">)>
+ <TELL ,PERIOD>)>>
+
+<ROUTINE CHANGE-ADJECTIVE (OBJ P "OPT" (NEW 0)
+ "AUX" (G <GETPT .OBJ ,P?ADJECTIVE>))
+ <COND (.G <PUTB .G .P .NEW>)>>
+
+<ROUTINE PUT-GLOBAL (OBJ P VAL "AUX" (G <GETPT .OBJ ,P?GLOBAL>))
+ <COND (.G <PUTB .G .P .VAL>)>>
+
+<OBJECT GLOBAL-FLOOR-WAXER
+ (IN LOCAL-GLOBALS)
+ (DESC "floor waxer")
+ (SYNONYM WAXER POLISHER MACHINE)
+ (ADJECTIVE FLOOR LARGE NOISY)
+ (FLAGS NDESCBIT VEHBIT SURFACEBIT ONBIT OPENBIT CONTBIT SEARCHBIT)
+ (GENERIC GENERIC-FLOOR-WAXER-F)
+ (ACTION GLOBAL-FLOOR-WAXER-F)>
+
+<ROUTINE GENERIC-FLOOR-WAXER-F ()
+ <COND (<IN? ,FLOOR-WAXER ,HERE> ,FLOOR-WAXER)
+ (ELSE ,GLOBAL-FLOOR-WAXER)>>
+
+<ROUTINE GLOBAL-FLOOR-WAXER-F ()
+ <COND (<VERB? WALK-TO>
+ <COND (<HERE? ,INF-1>
+ <DO-WALK ,P?EAST>)
+ (<HERE? ,INF-2>
+ <COND (<IN? ,FLOOR-WAXER ,INF-1>
+ <DO-WALK ,P?WEST>)
+ (ELSE <DO-WALK ,P?EAST>)>)
+ (<HERE? ,INF-3>
+ <COND (<OR <IN? ,FLOOR-WAXER ,INF-1>
+ <IN? ,FLOOR-WAXER ,INF-2>>
+ <DO-WALK ,P?WEST>)
+ (ELSE <DO-WALK ,P?EAST>)>)
+ (<HERE? ,INF-4>
+ <COND (<IN? ,FLOOR-WAXER ,INF-5>
+ <DO-WALK ,P?EAST>)
+ (ELSE <DO-WALK ,P?WEST>)>)
+ (ELSE
+ <DO-WALK ,P?WEST>)>)
+ (<HOSTILE-VERB?>
+ <TELL "It" ,IS-DOWN-THE-HALL>)
+ (ELSE
+ <FLOOR-WAXER-F>)>>
+
+<GLOBAL IS-DOWN-THE-HALL "'s down the hall, not here.|">
+
+<OBJECT FLOOR-WAXER
+ (IN INF-2)
+ (DESC "floor waxer")
+ (SYNONYM WAXER POLISHER MACHINE)
+ (ADJECTIVE FLOOR LARGE NOISY)
+ (FLAGS VEHBIT SURFACEBIT POWERBIT OPENBIT CONTBIT SEARCHBIT)
+ (DESCFCN FLOOR-WAXER-DESC)
+ (CONTFCN FLOOR-WAXER-F)
+ (GENERIC GENERIC-FLOOR-WAXER-F)
+ (ACTION FLOOR-WAXER-F)>
+
+<ROUTINE FLOOR-WAXER-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <COND (<IN? ,MAINTENANCE-MAN ,FLOOR-WAXER>
+ <TELL
+"A " 'MAINTENANCE-MAN " is here, riding a " 'FLOOR-WAXER ".">)
+ (ELSE
+ <TELL
+"A disabled " 'FLOOR-WAXER " looms nearby.">)>
+ <RFATAL>)>>
+
+<ROUTINE FLOOR-WAXER-F ("OPT" (RARG <>))
+ <COND (<RARG? BEG>
+ <COND (<AND <VERB? WALK>
+ <EQUAL? ,P-WALK-DIR ,P?DOWN>>
+ <PERFORM ,V?DISEMBARK>
+ <RTRUE>)
+ (<VERB? WALK LAMP-OFF LAMP-ON STOP>
+ <TELL
+CTHE ,POWER-CORD " is severed. It's not going anywhere." CR>)>)
+ (<RARG? CONTAINER>
+ <COND (<AND <VERB? TAKE>
+ <NOT <IN? ,WINNER ,FLOOR-WAXER>>>
+ <CANT-REACH-THAT>
+ <RTRUE>)>)
+ (<RARG? <>>
+ <COND (<VERB? EXAMINE>
+ <COND (<PRSO? ,GLOBAL-FLOOR-WAXER>
+ <TELL
+,YOU-CANT "see it too clearly, but it looks like a large waxing
+machine." CR>)
+ (ELSE
+ <TELL
+"It's a large " 'FLOOR-WAXER ", big enough to ride in">
+ <COND (<IN? ,MAINTENANCE-MAN ,FLOOR-WAXER>
+ <TELL
+", and in fact there is " A ,MAINTENANCE-MAN " riding it">)>
+ <TELL
+". It actually looks sort of like a small bulldozer. ">
+ <COND (,CORD-SEVERED?
+ <TELL
+"The severed remnant of " THE ,POWER-CORD " graces one end.">)
+ (ELSE
+ <TELL
+"A " 'POWER-CORD " connects it to the wall.">)>
+ <CRLF>)>)
+ (<VERB? LISTEN>
+ <COND (,CORD-SEVERED?
+ <TELL "It's very quiet." CR>)
+ (ELSE
+ <TELL
+"It makes a ghastly whirring, whining sound.">
+ <COND (<IN? ,FLOOR-WAXER ,HERE>
+ <TELL
+" This close, it's almost unbearable.">)>
+ <CRLF>)>)
+ (<VERB? BOARD>
+ <COND (<PRSO? ,GLOBAL-FLOOR-WAXER>
+ <TELL
+"It's not here!" CR>)
+ (<IN? ,MAINTENANCE-MAN ,PRSO>
+ <TELL CTHE ,MAINTENANCE-MAN>
+ <COND (,CORD-SEVERED?
+ <TELL
+" catches you with a surprisingly strong punch as
+you try to climb aboard. You fall to the floor, taken aback." CR>)
+ (ELSE
+ <TELL
+" prevents you. He says something that probably
+means \"No riders, buddy\" (freely translated)." CR>)>)>)
+ (<VERB? UNPLUG>
+ <NEW-PRSO ,POWER-CORD>
+ <RTRUE>)
+ (<VERB? LAMP-OFF STOP>
+ <TELL
+"You'd have to be riding in it to turn it off." CR>)
+ (<VERB? LOOK-UNDER>
+ <TELL
+"You see a nice, shiny floor." CR>)
+ (<HOSTILE-VERB?>
+ <TELL
+"The waxer is pretty sturdy. These things have been waxing the floors
+here for decades." CR>)
+ (<VERB? WALK-AROUND>
+ <COND (<NOT ,CORD-SEVERED?>
+ <TELL
+,YOU-CANT "evade it." CR>)>)>)>>
+
+<OBJECT WALL-SOCKET
+ (IN INF-3)
+ (DESC "wall socket")
+ (SYNONYM SOCKET)
+ (ADJECTIVE WALL ELECTRIC)
+ (DESCFCN WALL-SOCKET-DESC)>
+
+<ROUTINE WALL-SOCKET-DESC (RARG OBJ "AUX" L)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <TELL
+S "There is a ""wall socket on one wall, and a heavy-duty " 'POWER-CORD
+" is plugged into it. The cord ">
+ <COND (,CORD-SEVERED?
+ <TELL "terminates in a severed stump">)
+ (ELSE
+ <TELL "leads ">
+ <SET L <LOC ,FLOOR-WAXER>>
+ <COND (<EQUAL? .L ,HERE>
+ <TELL "to a large " 'FLOOR-WAXER>)
+ (<EQUAL? .L ,INF-1 ,INF-2>
+ <TELL "away to the west">)
+ (<EQUAL? .L ,INF-4 ,INF-5>
+ <TELL "away to the east">)>)>
+ <TELL ".">)>>
+
+<OBJECT POWER-CORD
+ (IN LOCAL-GLOBALS)
+ (DESC "power cord")
+ (SYNONYM CORD PLUG)
+ (ADJECTIVE POWER ELECTRIC)
+ (FLAGS NDESCBIT)
+ (ACTION POWER-CORD-F)>
+
+<GLOBAL CORD-SEVERED? <>>
+
+<ROUTINE POWER-CORD-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+CTHE ,POWER-CORD>
+ <COND (<NOT ,CORD-SEVERED?> <TELL " connects">)
+ (ELSE <TELL ", now a mere stub, formerly connected">)>
+ <TELL " a wall socket ">
+ <COND (<HERE? ,INF-1 ,INF-2>
+ <TELL ,DOWN-THE-HALL "east ">)
+ (<HERE? ,INF-3>
+ <TELL S "on the wall here"" ">)
+ (ELSE
+ <TELL ,DOWN-THE-HALL "west ">)>
+ <TELL "with " THE ,FLOOR-WAXER "." CR>)
+ (<VERB? TAKE UNPLUG MOVE PRY>
+ <TELL
+"You pull at " THE ,POWER-CORD ", but it won't come loose!" CR>)
+ (<VERB? FOLLOW>
+ <TELL
+CTHE ,POWER-CORD " goes from a wall socket ">
+ <COND (<HERE? ,INF-1 ,INF-2>
+ <TELL "to the east">)
+ (<HERE? ,INF-3>
+ <TELL S "on the wall here">)
+ (ELSE
+ <TELL "to the west">)>
+ <TELL " to " A ,FLOOR-WAXER " which is ">
+ <COND (<IN? ,FLOOR-WAXER ,HERE>
+ <TELL "here.">)
+ (ELSE
+ <TELL "to the ">
+ <FLOOR-WAXER-DIRECTION>)>
+ <COND (,CORD-SEVERED?
+ <TELL " Of course, the cord is severed.">)>
+ <CRLF>)
+ (<P? (CUT MUNG ATTACK) POWER-CORD>
+ <COND (<PRSI? <> ,HANDS>
+ <TELL
+"You'll need more than your hands to sever this cord!" CR>)
+ (,CORD-SEVERED?
+ <TELL
+,YOUVE-ALREADY "sliced it once! Trying to make salami?" CR>)
+ (<PRSI? ,AXE>
+ <SETG CORD-SEVERED? T>
+ <DEQUEUE I-WAXER-MOVES>
+ <QUEUE I-MAINT-ATTACK 2>
+ <TELL
+"The axe crashes against the floor, and " THE ,POWER-CORD " severs! The
+whine of " THE ,FLOOR-WAXER " slows, and " THE ,MAINTENANCE-MAN " jerks to
+alertness." CR>)
+ (ELSE
+ <TELL
+"You hit the cord with " THE ,PRSI ", but it has no effect." CR>)>)
+ (<VERB? REPAIR>
+ <COND (,CORD-SEVERED?
+ <TELL
+"It's beyond repair." CR>)>)>>
+
+<GLOBAL DOWN-THE-HALL "down the hall to the ">
+
+<ROUTINE SEE-MM? ()
+ <COND (<IN? ,MAINTENANCE-MAN ,HERE> <RTRUE>)
+ (<HERE? ,INF-1 ,INF-2 ,INF-3 ,INF-4 ,INF-5>
+ <RTRUE>)
+ (<AND <HERE? ,GREAT-DOME ,TOP-OF-DOME>
+ <IN? ,MAINTENANCE-MAN ,INF-3>>
+ <RTRUE>)>>
+
+<ROUTINE MAINT-DESCENDS ("OPT" (INT? <>))
+ <QUEUE I-MAINT-ATTACK -1>
+ <MOVE ,MAINTENANCE-MAN <LOC ,FLOOR-WAXER>>
+ <COND (<SEE-MM?>
+ <COND (.INT? <CRLF>)>
+ <TELL
+CTHE ,MAINTENANCE-MAN ", growling foul-sounding imprecations, descends
+from " THE ,FLOOR-WAXER " and ">
+ <COND (.INT? <TELL "heads towards you.">)
+ (ELSE <TELL "blocks your way.">)>
+ <COND (<IN? ,FLOOR-WAX <LOC ,MAINTENANCE-MAN>>
+ <SETG SEEN-MM-SLIP? T>
+ <TELL
+" But almost immediately, he slips on the floor wax.">)>
+ <CRLF>)>>
+
+<GLOBAL SEEN-MM-SLIP? <>>
+
+<GLOBAL MAINT-SCORE 5>
+
+<ROUTINE I-MAINT-ATTACK ("AUX" L TMP TMP1 (MM-WAITS? <>))
+ <COND (<IN? ,MAINTENANCE-MAN ,FLOOR-WAXER>
+ <MAINT-DESCENDS T>)
+ (<IN? ,FLOOR-WAX <LOC ,MAINTENANCE-MAN>>
+ <QUEUE I-MAINT-DISSOLVES 4 T>
+ <SETG SCORE <+ ,SCORE ,MAINT-SCORE>>
+ <SETG MAINT-SCORE 0>
+ <COND (<SEE-MM?>
+ <TELL CR
+CTHE ,MAINTENANCE-MAN> <COND (,SEEN-MM-SLIP?
+ <TELL
+" continues slipping, falling, standing, and so on.">)
+ (ELSE
+ <SETG SEEN-MM-SLIP? T>
+ <TELL
+" reaches the wax and immediately slips and falls.">)>
+ <TELL
+" He reminds you of a badly made windup toy." CR>)>)
+ (ELSE
+ <SET L <LOC ,MAINTENANCE-MAN>>
+ <COND (<IN? ,MAINTENANCE-MAN ,HERE>
+ <TELL CR
+CTHE ,MAINTENANCE-MAN " stares with maniacal intensity at your throat.">)
+ (ELSE
+ <COND (<NOT <HERE? ,INF-1 ,INF-2 ,INF-3 ,INF-4 ,INF-5>>
+ <SET MM-WAITS? T>
+ <SETG MAINT-ATTACK-COUNT 5>)>
+ <COND (<HERE? ,GREAT-DOME ,TOP-OF-DOME ,DOME-ROOF
+ ,ON-DOME>
+ <COND (<EQUAL? .L ,INF-5>
+ <MOVE ,MAINTENANCE-MAN ,INF-4>)
+ (<EQUAL? .L ,INF-4>
+ <MOVE ,MAINTENANCE-MAN ,INF-3>)>)
+ (ELSE
+ <COND (<EQUAL? .L ,INF-5>
+ <MOVE ,MAINTENANCE-MAN ,INF-4>)
+ (<EQUAL? .L ,INF-4>
+ <MOVE ,MAINTENANCE-MAN ,INF-3>)
+ (<EQUAL? .L ,INF-3>
+ <MOVE ,MAINTENANCE-MAN ,INF-2>)
+ (<EQUAL? .L ,INF-2>
+ <MOVE ,MAINTENANCE-MAN ,INF-1>)>)>
+ <COND (<HERE? ,GREAT-DOME ,TOP-OF-DOME>
+ <COND (<EQUAL? .L ,INF-3>
+ <MM-WAITS-PATIENTLY "below">
+ <RTRUE>)
+ (ELSE
+ <RFALSE>)>)
+ (<HERE? ,MASS-AVE>
+ <COND (<EQUAL? .L ,INF-1>
+ <MM-WAITS-PATIENTLY "inside">
+ <RTRUE>)
+ (ELSE
+ <RFALSE>)>)
+ (.MM-WAITS?
+ <COND (<EQUAL? .L
+ ,ENGINEERING-BLDG
+ ,AERO-LOBBY>
+ <MM-WAITS-PATIENTLY "in the corridor">
+ <RTRUE>)
+ (ELSE
+ <RFALSE>)>)
+ (ELSE
+ <TELL CR
+CTHE ,MAINTENANCE-MAN S " lurches toward you" " with surprising speed.">)>)>
+ <SET L <LOC ,MAINTENANCE-MAN>>
+ <COND (<AND <IN? ,MAINTENANCE-MAN ,HERE>
+ <IN? ,FLOOR-WAX ,HERE>>
+ <SETG SEEN-MM-SLIP? T>
+ <TELL
+" Just as he is about to grab you he slips on the wax. His hand whips
+by, inches from your throat, and he drops to the floor, screaming in
+frustration." CR>)
+ (<AND <IN? ,FLOOR-WAX .L>
+ <SEE-MM?>>
+ <SETG SEEN-MM-SLIP? T>
+ <TELL
+" He encounters the floor wax, slips, and drops to the floor, screaming
+in frustration." CR>)
+ (<G? <SETG MAINT-ATTACK-COUNT <+ ,MAINT-ATTACK-COUNT 1>>
+ 4>
+ <COND (<NOT <HERE? ,GREAT-DOME ,TOP-OF-DOME ,ON-DOME
+ ,DOME-ROOF ,MASS-AVE>>
+ <DEQUEUE I-MAINT-ATTACK>
+ <JIGS-UP
+" He grabs you by the throat and lifts you off the ground with one hand.
+The hand feels very cold. Just as you
+expire, you realize you have never seen him blink.">)>)
+ (<IN? ,MAINTENANCE-MAN ,HERE>
+ <CRLF>
+ <RTRUE>)
+ (ELSE
+ <COND (<AND <SET TMP <GETP ,HERE ,P?SIZE>>
+ <SET TMP1 <GETP .L ,P?SIZE>>>
+ <SET TMP <- .TMP1 .TMP>>
+ <TELL " He is ">
+ <COND (<EQUAL? .TMP 1>
+ <TELL "nearly upon you.">)
+ (ELSE
+ <COND (<EQUAL? .TMP 2>
+ <TELL "some ways down">)
+ (<EQUAL? .TMP 3>
+ <TELL "quite a way down">)
+ (<EQUAL? .TMP 4>
+ <TELL "at the far end of">)>
+ <TELL " the corridor.">)>)>
+ <CRLF>)>)>>
+
+<ROUTINE MM-WAITS-PATIENTLY (WHERE)
+ <TELL CR
+CTHE ,MAINTENANCE-MAN " waits patiently " .WHERE "." CR>>
+
+<GLOBAL MAINT-ATTACK-COUNT 0>
+
+<ROUTINE I-MAINT-DISSOLVES ()
+ <REMOVE ,MAINTENANCE-MAN>
+ <DEQUEUE I-MAINT-ATTACK>
+ <COND (<HERE? ,INF-1 ,INF-2 ,INF-3 ,INF-4 ,INF-5>
+ <TELL CR
+CTHE ,MAINTENANCE-MAN " appears to shorten and almost dissolve. There is a
+great commotion, as though he is undergoing a convulsion of some sort,
+and then he appears to explode into a crowd of small squealing creatures.
+These, seeing you, scuttle off in the opposite direction and disappear." CR>)>>
+
+<OBJECT PLASTIC-CONTAINER
+ (IN INF-1)
+ (DESC "plastic container")
+ (SYNONYM CONTAINER LABEL)
+ (ADJECTIVE PLASTIC)
+ (FLAGS TAKEBIT CONTBIT READBIT SEARCHBIT OPENABLE)
+ (CAPACITY 30)
+ (SIZE 15)
+ (ACTION PLASTIC-CONTAINER-F)
+ (TEXT "\"Frobozz Magic Floor Wax (and Dessert Topping)\"")>
+
+<ROUTINE PLASTIC-CONTAINER-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a plain plastic container with something written on it. ">
+ <LOOK-IN-CONTAINER>)
+ (<VERB? OPEN>
+ <COND (<NOT <FSET? ,PLASTIC-CONTAINER ,OPENBIT>>
+ <FSET ,PLASTIC-CONTAINER ,OPENBIT>
+ <TELL
+"You pull off the seal and open the container, revealing a smelly,
+viscous liquid." CR>)>)
+ (<VERB? CLOSE>
+ <COND (<FSET? ,PLASTIC-CONTAINER ,OPENBIT>
+ <TELL
+"The container can't be resealed." CR>)>)
+ (<VERB? LOOK-INSIDE>
+ <LOOK-IN-CONTAINER>)
+ (<VERB? POUR>
+ <COND (<NOT <FSET? ,PLASTIC-CONTAINER ,OPENBIT>>
+ <TELL "The container isn't open." CR>)
+ (<IN? ,FLOOR-WAX ,PRSO>
+ <NEW-PRSO ,FLOOR-WAX>
+ <RTRUE>)
+ (ELSE <V-POUR>)>)
+ (<VERB? FILL>
+ <CANT-FILL-IT>)>>
+
+<ROUTINE LOOK-IN-CONTAINER ()
+ <COND (<NOT <FSET? ,PRSO ,OPENBIT>>
+ <TELL-OPEN-CLOSED ,PRSO>
+ <RTRUE>)
+ (<FIRST? ,PRSO>
+ <DESCRIBE-SENT ,PRSO>)
+ (ELSE
+ <TELL "It appears to be empty.">)>
+ <CRLF>>
+
+<ROUTINE CANT-FILL-IT ()
+ <TELL ,YOU-CANT>
+ <COND (,PRSI
+ <TELL
+"get " THE ,PRSI " into the container." CR>)
+ (ELSE
+ <TELL
+"fill " THE ,PRSO ,PERIOD>)>>
+
+<OBJECT FLOOR-WAX
+ (IN PLASTIC-CONTAINER)
+ (DESC "floor wax")
+ (SYNONYM WAX TOPPING LIQUID)
+ (ADJECTIVE FLOOR DESSERT SMELLY VISCOUS)
+ (FLAGS NOABIT TRYTAKEBIT TAKEBIT TOUCHBIT)
+ (DESCFCN FLOOR-WAX-DESC)
+ (ACTION FLOOR-WAX-F)>
+
+<ROUTINE FLOOR-WAX-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?>
+ <COND (<IN? <LOC ,FLOOR-WAX> ,ROOMS>
+ <RTRUE>)>)
+ (ELSE
+ <TELL
+S "The floor here is ""covered with slippery, messy floor wax.">)>>
+
+<ROUTINE FLOOR-WAX-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+,IT-SEEMS-TO-BE "floor wax." CR>)
+ (<VERB? TAKE>
+ <TELL
+"It's a liquid, not a solid." CR>)
+ (<AND <VERB? STEP-ON>
+ <IN? ,FLOOR-WAX ,HERE>>
+ <TELL
+"It's pretty slippery, all right. You can't walk on it very easily." CR>)
+ (<OR <P? PUT HANDS>
+ <VERB? RUB>>
+ <TELL
+"It feels like floor wax. It's very slippery." CR>)
+ (<VERB? SMELL>
+ <TELL
+"It smells very pungent." CR>)
+ (<VERB? PUT>
+ <COND (<OR <PRSI? ,GROUND>
+ <FSET? ,PRSI ,CONTBIT>>
+ <NEW-VERB ,V?POUR>
+ <RTRUE>)>)
+ (<VERB? POUR DROP>
+ <COND (<IN? ,PRSO ,PLASTIC-CONTAINER>
+ <COND (<AND ,PRSI
+ <OR <HELD? ,PRSI>
+ <AND <FSET? ,PRSI ,CONTBIT>
+ <GETP ,PRSI ,P?CAPACITY>>>>
+ <TELL
+"Without a funnel, you are doomed to failure. It'll end up all over
+everything." CR>)
+ (ELSE
+ <MOVE ,FLOOR-WAX ,HERE>
+ <COND (<NOT <PRSI? ,GROUND ,CORRIDOR
+ ,GLOBAL-MAINTENANCE-MAN
+ <>>>
+ <TELL
+"You pour it all over " THE ,PRSI ", and of course it pours right
+off onto the floor.">)
+ (ELSE
+ <COND (<HERE? ,TOP-OF-DOME
+ ,GREAT-DOME>
+ <MOVE ,FLOOR-WAX ,INF-3>
+ <TELL
+"The wax cascades down onto the corridor floor below, like Quasimodo's
+molten lead.">)
+ (ELSE
+ <TELL
+"It pours out and spreads like ants at a picnic.">)>)>
+ <COND (<NOT <FSET? ,HERE ,OUTSIDE>>
+ <TELL " The floor is now
+covered from wall to wall with slippery floor wax.">)>
+ <COND (<IN? ,MAINTENANCE-MAN <LOC ,FLOOR-WAX>>
+ <SETG SEEN-MM-SLIP? T>
+ <TELL
+" " CTHE ,MAINTENANCE-MAN ", attempting to get closer to you, enters the
+waxed part of the floor. He begins to slip and slide, barely able
+to maintain his balance, much less advance.">)>
+ <CRLF>)>)
+ (ELSE
+ <TELL
+"There is no more wax to pour." CR>)>)>>
+
+<OBJECT EMERGENCY-CABINET
+ (IN INF-4)
+ (DESC "emergency cabinet")
+ (SYNONYM CABINET GLASS SIGN WINDOW)
+ (ADJECTIVE EMERGENCY)
+ (FLAGS CONTBIT TRANSBIT READBIT AN SEARCHBIT OPENABLE)
+ (CAPACITY 100)
+ (DESCFCN EMERGENCY-CABINET-DESC)
+ (ACTION EMERGENCY-CABINET-F)
+ (TEXT "\"In case of emergency, break glass.\"")>
+
+<ROUTINE EMERGENCY-CABINET-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <TELL
+S "There is a ">
+ <COND (<FSET? .OBJ ,RMUNGBIT> <TELL "formerly ">)>
+ <TELL "glass-fronted emergency cabinet here.">
+ <COND (<FSET? .OBJ ,RMUNGBIT> <RTRUE>)
+ (ELSE <RFATAL>)>)>>
+
+<ROUTINE EMERGENCY-CABINET-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's one of those little cabinets you see in institutional buildings that
+usually contains a fire hose and a fire axe. ">
+ <COND (<IN? ,AXE ,PRSO>
+ <TELL
+"This one seems to only have an axe. ">)>
+ <TELL "It ">
+ <COND (<FSET? ,PRSO ,RMUNGBIT>
+ <TELL "had">)
+ (ELSE
+ <TELL "has">)>
+ <TELL " a transparent
+window">
+ <COND (<FSET? ,PRSO ,RMUNGBIT>
+ <TELL
+" but apparently some vandal smashed it">)>
+ <TELL ". There is writing on the cabinet." CR>)
+ (<VERB? OPEN>
+ <COND (<NOT <FSET? ,PRSO ,RMUNGBIT>>
+ <TELL
+"You should read the sign." CR>)>)
+ (<VERB? LOOK-INSIDE>
+ <TELL
+"Inside the cabinet you see ">
+ <DESCRIBE-REST ,EMERGENCY-CABINET>
+ <TELL ,PERIOD>)
+ (<P? (MUNG ATTACK) ,EMERGENCY-CABINET>
+ <COND (<FSET? ,EMERGENCY-CABINET ,RMUNGBIT>
+ <TELL
+"The cabinet is already smashed." CR>)
+ (<PRSI? <> ,HANDS>
+ <COND (<NOT <FSET? ,GLOVES ,WEARBIT>>
+ <TELL
+"You hit at the glass with your hands, but you can't hit hard
+enough to break it: you might cut yourself on the glass." CR>)
+ (ELSE
+ <FSET ,EMERGENCY-CABINET ,OPENBIT>
+ <FSET ,EMERGENCY-CABINET ,RMUNGBIT>
+ <TELL
+"Wearing the heavy gloves, you confidently smash the glass with a
+blow of your hands!" CR>)>)
+ (<FSET? ,PRSI ,WEAPONBIT>
+ <COND (<NOT <FSET? ,EMERGENCY-CABINET ,RMUNGBIT>>
+ <FSET ,EMERGENCY-CABINET ,OPENBIT>
+ <FSET ,EMERGENCY-CABINET ,RMUNGBIT>
+ <TELL
+"The glass smashes with a satisfying crash!" CR>)>)
+ (<PRSI? ,PLASTIC-CONTAINER>
+ <TELL
+"The light plastic bounces off the cabinet." CR>)
+ (ELSE
+ <TELL
+"The glass survives unscathed." CR>)>)>>
+
+<OBJECT AXE
+ (IN EMERGENCY-CABINET)
+ (DESC "fire axe")
+ (SYNONYM AXE AX)
+ (ADJECTIVE FIRE)
+ (FLAGS TRYTAKEBIT TAKEBIT WEAPONBIT)
+ (SIZE 10)>
+
+<ROOM NUTRITION-BLDG
+ (IN ROOMS)
+ (DESC "Fruits and Nuts")
+ (LDESC
+"This is the central corridor of the
+Nutrition Building. The main building is south, and a stairway leads
+down.")
+ (SOUTH TO INF-5)
+ (DOWN TO BROWN-TUNNEL)
+ (FLAGS ONBIT)>
+
+<ROOM BROWN-TUNNEL
+ (IN ROOMS)
+ (DESC "Cluttered Passage")
+ (LDESC
+"This cluttered passage leads southeast. It is full of apparently discarded
+electronic equipment, old rusty file cabinets, and other detritus. A stairway
+also leads up.")
+ (UP TO NUTRITION-BLDG)
+ (SE TO BROWN-BASEMENT)
+ (FLAGS ONBIT)
+ (THINGS <PSEUDO (ELECTRIC EQUIPMENT RANDOM-PSEUDO)
+ (FILE CABINET RANDOM-PSEUDO)
+ (<> DETRITUS RANDOM-PSEUDO)>)>
+
+<ROOM AERO-LOBBY
+ (IN ROOMS)
+ (DESC "Aero Lobby")
+ (DOWN TO AERO-STAIRS)
+ (SOUTH TO INF-1)
+ (FLAGS ONBIT)
+ (ACTION AERO-LOBBY-F)>
+
+<ROUTINE AERO-LOBBY-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+,THE-LOBBY "Aeronautical Engineering Building. Stairs
+lead down and a corridor heads south towards the main building." CR>)>>
+
+<ROOM GREAT-DOME
+ (IN ROOMS)
+ (DESC "Great Dome")
+ (DOWN TO INF-3)
+ (UP "There is no stairway.")
+ (FLAGS ONBIT)
+ (GLOBAL TENTACLE GLOBAL-FLOOR-WAXER GLOBAL-MAINTENANCE-MAN)
+ (ACTION GREAT-DOME-F)>
+
+<ROUTINE GREAT-DOME-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"Here a walkway circles the base of a huge ornate dome. Below is the
+Infinite Corridor.">
+ <COND (<NOT <FSET? ,DOME-LADDER ,TOUCHBIT>>
+ <TELL
+" From stories of Tech Exploring trips, you recall that there is supposed to
+be a ladder here.">
+ <COND (<NOT <FSET? ,TENTACLE ,INVISIBLE>>
+ <TELL
+" On the other hand, there is a shiny rope-like thing hanging near
+where the ladder used to be, and leading upward.">)>)>
+ <COND (<IN? ,FLOOR-WAXER ,INF-3>
+ <TELL
+" Below you, in the corridor, you can see " A ,FLOOR-WAXER>
+ <COND (<NOT ,CORD-SEVERED?>
+ <TELL
+", busily waxing the floor">)>
+ <TELL ".">)>
+ <CRLF>)
+ (<RARG? BEG>
+ <COND (<AND <VERB? WALK>
+ <EQUAL? ,P-WALK-DIR ,P?UP>
+ <HERE? ,LADDER-BOTTOM?>>
+ <PERFORM ,V?CLIMB-UP ,DOME-LADDER>
+ <RTRUE>)>)>>
+
+<OBJECT TENTACLE
+ (IN LOCAL-GLOBALS)
+ (DESC "ropy strand")
+ (SYNONYM ROPE STRAND TENTACLE)
+ (ADJECTIVE ROPY STICKY WET)
+ (FLAGS NDESCBIT)
+ (ACTION TENTACLE-F)>
+
+<ROUTINE TENTACLE-WETNESS ()
+ <TELL
+"It's wet, and when you touch it, some of the wetness sticks to your ">
+ <COND (<FSET? ,GLOVES ,WEARBIT>
+ <TELL "gloves">)
+ (ELSE
+ <TELL "hands, and stings">)>>
+
+<ROUTINE TENTACLE-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The strand is wet and glistening. It extends upward into the dome,
+leading to a narrow catwalk." CR>)
+ (<VERB? TAKE RUB>
+ <TENTACLE-WETNESS>
+ <TELL ". The strand twitches a little when you touch it." CR>)
+ (<VERB? CLIMB-UP CLIMB-FOO>
+ <COND (<HERE? ,GREAT-DOME>
+ <COND (<FSET? ,GLOVES ,WEARBIT>
+ <TELL
+"The wet stuff on the strand sticks to the gloves, but doesn't otherwise
+affect you. You have a little trouble climbing up to the catwalk, but
+grab the rail just before your strength gives out. You heave yourself
+up onto the catwalk." CR CR>
+ <GOTO ,TOP-OF-DOME>)
+ (ELSE
+ <TELL
+S "You start to climb " "up the strand, but the glistening wet stuff begins
+to burn your hands. You get a few feet up before the pain is too much.
+You drop back to the floor." CR>)>)>)>>
+
+<ROOM TOP-OF-DOME
+ (IN ROOMS)
+ (DESC "Top of Dome")
+ (OUT TO DOME-ROOF IF DOME-DOOR IS OPEN)
+ (NORTH TO DOME-ROOF IF DOME-DOOR IS OPEN)
+ (FLAGS ONBIT)
+ (GLOBAL TENTACLE DOME-DOOR GLOBAL-MAINTENANCE-MAN
+ DOME GLOBAL-FLOOR-WAXER)
+ (VALUE 5)
+ (ACTION TOP-OF-DOME-F)>
+
+<ROUTINE TOP-OF-DOME-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"Inside the great dome, near the top, a metal catwalk is precariously perched.
+There is no way further up, but a small metal door is set in the side of
+the dome.">
+ <COND (<FSET? ,DOME-DOOR ,OPENBIT>
+ <TELL
+" Frigid wind and snow blow through the open door.">)>
+ <CRLF>)
+ (<RARG? BEG>
+ <COND (<VERB? WALK>
+ <COND (<AND <EQUAL? ,P-WALK-DIR ,P?UP>
+ <HERE? ,LADDER-BOTTOM?>>
+ <PERFORM ,V?CLIMB-UP ,DOME-LADDER>
+ <RTRUE>)
+ (<AND <EQUAL? ,P-WALK-DIR ,P?DOWN>
+ <HERE? ,LADDER-TOP?>>
+ <PERFORM ,V?CLIMB-DOWN ,DOME-LADDER>
+ <RTRUE>)>)>)
+ (<RARG? ENTER>
+ <COND (<EQUAL? ,OHERE ,DOME-ROOF>
+ <EXIT-FROM-COLD>)
+ (<NOT <FSET? ,TENTACLE ,INVISIBLE>>
+ <FSET ,TENTACLE ,INVISIBLE>
+ <TELL
+"You stand up on the catwalk, catching your breath for a moment.
+Your eyes stray along the strand you climbed. It trails along the
+catwalk, where it joins something large and squishy squatting at
+the far side. A single, bright-blue eye opens in the squishy mass,
+and the tentacle (for that's what it is) retracts. The mass almost
+flows through the spaces in the catwalk railing and drops to the
+floor fifteen feet below. Before you can react, it's gone." CR CR>)>)>>
+
+<OBJECT CATWALK
+ (IN TOP-OF-DOME)
+ (DESC "catwalk")
+ (SYNONYM CATWALK EDGE SIDE RAILING)
+ (ADJECTIVE METAL)
+ (FLAGS NDESCBIT)>
+
+<OBJECT DOME-LADDER
+ (IN TOP-OF-DOME)
+ (DESC "wooden ladder")
+ (SYNONYM LADDER)
+ (ADJECTIVE WOODEN)
+ (SIZE 120)
+ (FLAGS TAKEBIT)
+ (DESCFCN DOME-LADDER-DESC)
+ (ACTION DOME-LADDER-F)>
+
+<GLOBAL LADDER-TOP? <>>
+<GLOBAL LADDER-BOTTOM? <>>
+
+<ROUTINE DOME-LADDER-DESC ("OPT" RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <COND (<NOT <FSET? ,DOME-LADDER ,TOUCHBIT>>
+ <TELL
+"Where the pulpy mass was squatting, a wooden ladder lies on the catwalk.">)
+ (ELSE
+ <TELL "A wooden ladder ">
+ <COND (<HERE? ,LADDER-TOP?>
+ <TELL "leads down from">)
+ (<HERE? ,LADDER-BOTTOM?>
+ <TELL "leads up from">)
+ (ELSE
+ <TELL "rests">)>
+ <TELL " here.">)>)>>
+
+<ROUTINE DOME-LADDER-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"There is the same wet stuff on the ladder as on the tentacle." CR>)
+ (<VERB? RUB>
+ <TENTACLE-WETNESS>
+ <TELL ,PERIOD>)
+ (<VERB? TAKE>
+ <COND (<EQUAL? <ITAKE> T>
+ <SETG LADDER-TOP? <>>
+ <SETG LADDER-BOTTOM? <>>
+ <TELL
+"It's a heavy ladder, but you manage to take it." CR>)
+ (ELSE <RTRUE>)>)
+ (<VERB? RAISE LAMP-ON>
+ <FSET ,DOME-LADDER ,TOUCHBIT>
+ <COND (<EQUAL? ,LADDER-TOP? ,TOP-OF-DOME>
+ <COND (<HERE? ,TOP-OF-DOME>
+ <MOVE ,DOME-LADDER ,HERE>
+ <SETG LADDER-TOP? <>>
+ <SETG LADDER-BOTTOM? <>>
+ <TELL
+"With a great effort, the ladder being quite heavy (it's a Type I), you
+pull the ladder up and lay it on the catwalk." CR>)
+ (ELSE
+ <TELL
+"The ladder is already set up." CR>)>)
+ (<HERE? ,GREAT-DOME>
+ <SETG LADDER-TOP? ,TOP-OF-DOME>
+ <SETG LADDER-BOTTOM? ,GREAT-DOME>
+ <MOVE ,DOME-LADDER ,HERE>
+ <TELL
+"You raise the ladder, leaning it against the catwalk above." CR>)
+ (<HERE? ,ELEVATOR-PIT>
+ <COND (<AND <FSET? ,ELEVATOR-DOOR-B ,OPENBIT>
+ <NOT <FIRST? ,ELEVATOR-DOOR-B>>>
+ <TELL
+,YOU-CANT "raise a ladder and hold the doors open at the same time!" CR>)
+ (ELSE
+ <ONLY-A-FEW-FEET>)>)
+ (ELSE
+ <TELL
+"There isn't much here to climb up to." CR>)>)
+ (<OR <VERB? LOWER>
+ <P? PUT-ON * CATWALK>>
+ <FSET ,DOME-LADDER ,TOUCHBIT>
+ <COND (<HERE? ,TOP-OF-DOME>
+ <COND (<NOT ,LADDER-TOP?>
+ <MOVE ,DOME-LADDER ,HERE>
+ <SETG LADDER-TOP? ,TOP-OF-DOME>
+ <SETG LADDER-BOTTOM? ,GREAT-DOME>
+ <TELL
+"You lower the ladder to the walkway below. It's just the right
+length to climb down." CR>)
+ (ELSE
+ <TELL
+,YOU-CANT "lower it from here." CR>)>)
+ (<HERE? ,CS-BASEMENT>
+ <ONLY-A-FEW-FEET>)
+ (<NOT ,LADDER-TOP?>
+ <TELL
+"It's already taken down." CR>)
+ (ELSE
+ <SETG LADDER-TOP? <>>
+ <SETG LADDER-BOTTOM? <>>
+ <TELL "Lowered." CR>)>)
+ (<VERB? CLIMB-FOO>
+ <COND (<HERE? ,LADDER-BOTTOM?>
+ <NEW-VERB ,V?CLIMB-UP>
+ <RTRUE>)
+ (<HERE? ,LADDER-TOP?>
+ <NEW-VERB ,V?CLIMB-DOWN>
+ <RTRUE>)
+ (ELSE <LADDER-NOT-UP>)>)
+ (<VERB? CLIMB-UP>
+ <COND (<EQUAL? ,LADDER-BOTTOM? ,HERE>
+ <TELL
+,YOU-SCRAMBLE-UP "ladder." CR CR>
+ <MOVE ,DOME-LADDER ,LADDER-TOP?>
+ <GOTO ,LADDER-TOP?>)
+ (<EQUAL? ,LADDER-TOP? ,HERE>
+ <LADDER-EXTENDS "down" "up">)
+ (ELSE
+ <LADDER-NOT-UP>)>)
+ (<VERB? CLIMB-DOWN>
+ <COND (<EQUAL? ,LADDER-TOP? ,HERE>
+ <TELL
+"You scramble down the ladder." CR CR>
+ <MOVE ,DOME-LADDER ,LADDER-BOTTOM?>
+ <GOTO ,LADDER-BOTTOM?>)
+ (<EQUAL? ,LADDER-BOTTOM? ,HERE>
+ <LADDER-EXTENDS "up" "down">)
+ (ELSE <LADDER-NOT-UP>)>)
+ (<VERB? WALK-UNDER>
+ <COND (<EQUAL? ,LADDER-BOTTOM? ,HERE>
+ <TELL
+"You trepidatiously walk under the ladder. Nothing seems to happen." CR>)
+ (ELSE
+ <TELL
+"There's no ladder set up here." CR>)>)>>
+
+<ROUTINE LADDER-EXTENDS (U D)
+ <TELL
+"The ladder extends " .U " from here, not " .D "." CR>>
+
+<ROUTINE ONLY-A-FEW-FEET ()
+ <TELL
+"It's only a few feet ">
+ <COND (<HERE? ,ELEVATOR-PIT> <TELL "up">)
+ (ELSE <TELL "down">)>
+ <TELL ". You don't need a ladder for that!" CR>>
+
+<ROUTINE LADDER-NOT-UP ()
+ <COND (<HELD? ,DOME-LADDER>
+ <TELL
+"Climbing it while holding it would be a neat trick." CR>)
+ (ELSE
+ <TELL
+"The ladder doesn't go anywhere yet." CR>)>>
+
+<OBJECT GLOVES
+ (IN TEMPORARY-BASEMENT)
+ (DESC "pair of electrician's gloves")
+ (SYNONYM GLOVES GLOVE)
+ (ADJECTIVE WORK RUBBER ELECTRIC)
+ (FLAGS TAKEBIT)
+ (ACTION GLOVES-F)>
+
+<ROUTINE GLOVES-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This is a pair of electrician's rubber gloves. They look well used but
+serviceable." CR>)
+ (<VERB? LOOK-INSIDE>
+ <TELL
+"They're kind of dirty inside, but there's nothing nasty hidden there." CR>)
+ (<OR <P? PUT-ON HAND GLOVES>
+ <P? PUT-ON GLOVES HAND>>
+ <TELL
+"It's much too big." CR>)
+ (<OR <VERB? WEAR>
+ <P? PUT-ON HANDS GLOVES>
+ <P? PUT-ON GLOVES HANDS>>
+ <COND (<EQUAL? <IWEAR> T>
+ <TELL
+"You put on the gloves. They're a little big, but not really such
+a bad fit at all." CR>)
+ (ELSE <RTRUE>)>)>>
+
+<OBJECT DOME-DOOR
+ (IN LOCAL-GLOBALS)
+ (DESC "door")
+ (SYNONYM DOOR)
+ (ADJECTIVE SMALL METAL)
+ (FLAGS NDESCBIT DOORBIT OPENABLE)
+ (ACTION DOME-DOOR-F)>
+
+<ROUTINE DOME-DOOR-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a small metal door, the same color as the dome." CR>)
+ (<VERB? THROUGH>
+ <COND (<HERE? ,TOP-OF-DOME>
+ <DO-WALK ,P?OUT>)
+ (ELSE <DO-WALK ,P?IN>)>)
+ (<AND <VERB? OPEN>
+ <NOT <FSET? ,DOME-DOOR ,OPENBIT>>>
+ <FSET ,DOME-DOOR ,OPENBIT>
+ <TELL
+"You open the door, and freezing air, blowing snow, and howling wind
+enter and whip around you." CR>)
+ (<AND <VERB? CLOSE>
+ <FSET? ,DOME-DOOR ,OPENBIT>>
+ <FCLEAR ,DOME-DOOR ,OPENBIT>
+ <TELL
+"You close the door, shutting out the blizzard." CR>)>>
+
+<ROOM DOME-ROOF
+ (IN ROOMS)
+ (DESC "Roof of Great Dome")
+ (LDESC
+"You are perched precariously on the roof of the Great Dome. A set of
+narrow indentations in the dome provides a dangerous route to the very
+tip-top of the dome.")
+ (IN TO TOP-OF-DOME IF DOME-DOOR IS OPEN)
+ (SOUTH TO TOP-OF-DOME IF DOME-DOOR IS OPEN)
+ (UP TO ON-DOME)
+ (GLOBAL DOME-DOOR DOME)
+ (FLAGS ONBIT OUTSIDE)
+ (ACTION DOME-ROOF-F)>
+
+<ROUTINE DOME-ROOF-F (RARG)
+ <COND ;(<RARG? LOOK>
+ <TELL
+ CR>)
+ (<RARG? ENTER>
+ <COND (<EQUAL? ,OHERE ,TOP-OF-DOME>
+ <EXIT-TO-COLD>)>)>>
+
+<ROUTINE EXIT-TO-COLD ()
+ <QUEUE I-FREEZE-TO-DEATH 2 T>
+ <TELL
+"You enter the freezing, biting cold of the blizzard." CR CR>>
+
+<ROOM ON-DOME
+ (IN ROOMS)
+ (DESC "On the Great Dome")
+ (LDESC
+"This is the very top of the Great Dome, a favorite place for Tech
+fraternities to install cows, Volkswagen Beetles, giant birthday candles,
+and other bizarre objects. The top is flat, round, and about five feet
+in diameter. It's very windy, which has kept the snow from
+accumulating here. The only way off is down.")
+ (DOWN TO DOME-ROOF)
+ (FLAGS ONBIT OUTSIDE)
+ (GLOBAL DOME)
+ (ACTION ON-DOME-F)>
+
+<GLOBAL YOU-SCRAMBLE-UP "You scramble up ">
+
+<ROUTINE ON-DOME-F (RARG)
+ <COND ;(<RARG? LOOK>
+ <TELL
+ CR>)
+ (<RARG? ENTER>
+ <TELL
+,YOU-SCRAMBLE-UP "icy surface of the dome, almost slipping a few
+times, but finally you make it to the top." CR CR>)
+ (<RARG? BEG>
+ <COND (<AND <VERB? WALK>
+ <NOT <EQUAL? ,P-WALK-DIR ,P?DOWN>>>
+ <TELL
+"There is nowhere to go but down." CR>)
+ (ELSE <ROOF-BEGS>)>)>>
+
+<OBJECT BRONZE-PLUG
+ (IN ON-DOME)
+ (DESC "bronze plug")
+ (FDESC "In the exact center of the flat area is a bronze plug.")
+ (SYNONYM PLUG)
+ (ADJECTIVE CYLINDRICAL BRONZE)
+ (FLAGS TAKEBIT TRYTAKEBIT WEAPONBIT)
+ (ACTION BRONZE-PLUG-F)>
+
+<ROUTINE BRONZE-PLUG-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This is a cylindrical bronze plug about two inches in diameter">
+ <COND (<NOT <FSET? ,PRSO ,TOUCHBIT>>
+ <TELL
+". It is set in the center of the flat part of the dome.">)
+ (ELSE
+ <TELL " and one inch high.">)>
+ <CRLF>)
+ (<AND <VERB? TAKE>
+ <NOT <FSET? ,PRSO ,RMUNGBIT>>>
+ <PERFORM ,V?PRY ,PRSO ,HANDS>
+ <RTRUE>)
+ (<VERB? RAISE MOVE PRY OPEN>
+ <COND (<FSET? ,BRONZE-PLUG ,RMUNGBIT>
+ <TELL ,YOUVE-ALREADY "removed it." CR>)
+ (<EQUAL? <ITAKE> T>
+ <FSET ,BRONZE-PLUG ,RMUNGBIT>
+ <MOVE ,SECRET-HOLE ,HERE>
+ <TELL
+"You pry the plug out of its socket, revealing a cylindrical hole about
+the same diameter but somewhat deeper. ">
+ <COND (<NOT <FSET? ,NOTE ,TOUCHBIT>>
+ <TELL
+S "There is a ""piece of paper in the hole.">)
+ (<FIRST? ,SECRET-HOLE>
+ <DESCRIBE-SENT ,SECRET-HOLE>)
+ (ELSE
+ <TELL "The hole is empty.">)>
+ <CRLF>)
+ (ELSE <RTRUE>)>)
+ (<P? PUT BRONZE-PLUG SECRET-HOLE>
+ <FCLEAR ,BRONZE-PLUG ,RMUNGBIT>
+ <REMOVE ,SECRET-HOLE>
+ <MOVE ,BRONZE-PLUG ,HERE>
+ <TELL
+"You insert the plug in the hole." CR>)>>
+
+<OBJECT SECRET-HOLE
+ (DESC "cylindrical hole")
+ (SYNONYM HOLE)
+ (ADJECTIVE CYLINDRICAL)
+ (CAPACITY 5)
+ (FLAGS CONTBIT OPENBIT SEARCHBIT)>
+
+<OBJECT NOTE
+ (IN SECRET-HOLE)
+ (DESC "piece of paper")
+ (SYNONYM PAPER NOTE)
+ (ADJECTIVE PIECE SUICIDE)
+ (FLAGS TAKEBIT READBIT)
+ (VALUE 5)
+ (ACTION NOTE-F)>
+
+<ROUTINE NOTE-F ()
+ <COND (<VERB? EXAMINE READ>
+ <COND (<NOT <HELD? ,NOTE>>
+ <MOVE ,NOTE ,WINNER>
+ <TAKING-FIRST ,NOTE>)>
+ <FSET ,NOTE ,RMUNGBIT>
+ <TELL
+"You unroll the piece of paper and read the shaky handwriting:|
+|
+\"I can no longer face
+what I've been doing. I can't sleep, I start at the slightest noise,
+and even dulling my senses with alcohol or drugs is no longer enough.
+I refuse to participate in what he is doing any more. Either he is
+insane, or I am insane, or (and this is what I fear most) the universe
+itself is insane. I have only one final warning: I am the only suicide,
+but I will not be the final death.\"|
+|
+The name signed to it is ">
+ <COND (<OR <FSET? ,SIGNUP ,RMUNGBIT>
+ ,REMEMBERED-STUDENT?>
+ <TELL
+"that of the Alchemy Department graduate student.">)
+ (ELSE
+ <QUEUE I-REMEMBER-STUDENT 5>
+ <TELL
+"oddly familiar.">)>
+ <CRLF>)>>
diff --git a/debug.zil b/debug.zil
new file mode 100644
index 0000000..0ac49b5
--- /dev/null
+++ b/debug.zil
@@ -0,0 +1,35 @@
+"DEBUG for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+%<DEBUG-CODE <GLOBAL ZDEBUG <>>>
+
+%<DEBUG-CODE <SYNTAX $DEBUG = V-$DEBUG>>
+
+%<DEBUG-CODE
+ <ROUTINE V-$DEBUG ()
+ <COND (<SETG ZDEBUG <NOT ,ZDEBUG>>
+ <TELL-ON>)
+ (T <TELL-OFF>)>>>
+
+%<DEBUG-CODE <ROUTINE TELL-ON () <TELL "On." CR>>>
+%<DEBUG-CODE <ROUTINE TELL-OFF () <TELL "Off." CR>>>
+
+%<DEBUG-CODE <SYNTAX $BLORPLE OBJECT = V-$BLORPLE>>
+
+%<DEBUG-CODE <SYNTAX $CHEAT = V-$CHEAT>>
+
+%<DEBUG-CODE
+ <SYNTAX $TAKE OBJECT = V-$TAKE>>
+
+%<DEBUG-CODE
+ <ROUTINE V-$TAKE ("AUX" CUBE)
+ <MOVE ,PRSO ,WINNER>
+ <FCLEAR ,PRSO ,NDESCBIT>
+ <FCLEAR ,PRSO ,INVISIBLE>
+ <TELL ,TAKEN>>>
+
+%<DEBUG-CODE
+ <ROUTINE TELL-C-INTS ()
+ <TELL "[MaxInts: " N </ <- ,C-TABLELEN ,C-MAXINTS> ,C-INTLEN>
+ "]" CR>>> \ No newline at end of file
diff --git a/desc.zil b/desc.zil
new file mode 100644
index 0000000..71d62a1
--- /dev/null
+++ b/desc.zil
@@ -0,0 +1,295 @@
+"DESC for
+ Your Game
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+"The fabled new describers, as updated and modified to conform to the
+latest bug fixes. See ZD:DESC.DOC for details. See Z:DESC.ZIL for
+the source."
+
+<CONSTANT M-OBJDESC? 9> ;"modify if necessary for games with other M-..."
+
+<GLOBAL DESCRIBED-ROOM? <>>
+
+<ROUTINE DESCRIBE-ROOM ("OPTIONAL" (LOOK? <>) "AUX" V? STR AV)
+ <COND (<NOT ,LIT>
+ <TELL "It is pitch black." CR>
+ <RFALSE>)>
+ <COND (<IN? ,HERE ,ROOMS> <TELL 'HERE>)>
+ <SET AV <LOC ,WINNER>>
+ <COND (<FSET? .AV ,VEHBIT>
+ <COND (<FSET? .AV ,SURFACEBIT>
+ <TELL ", on ">)
+ (ELSE
+ <TELL ", in ">)>
+ <TELL THE .AV>)>
+ <CRLF>
+ <SET V? <OR .LOOK? <EQUAL? ,VERBOSITY 2>>>
+ <COND (<NOT <FSET? ,HERE ,TOUCHBIT>>
+ <FSET ,HERE ,TOUCHBIT>
+ <COND (,VERBOSITY <SET V? T>)>)>
+ <SETG DESCRIBED-ROOM? .V?>
+ <COND (.V?
+ <COND (<AND <NOT <EQUAL? ,HERE .AV>>
+ <FSET? .AV ,VEHBIT>
+ <APPLY <GETP .AV ,P?ACTION> ,M-LOOK>>
+ <RTRUE>)
+ (<APPLY <GETP ,HERE ,P?ACTION> ,M-LOOK>
+ <RTRUE>)
+ (<SET STR <GETP ,HERE ,P?LDESC>>
+ <TELL .STR CR>)>)>
+ T>
+
+<ROUTINE DESCRIBE-OBJECTS ("AUX" O STR (AV <LOC ,WINNER>) TMP)
+ <SET O <FIRST? ,HERE>>
+ <COND (<NOT .O> <RFALSE>)>
+ <REPEAT () ;"FDESCS and MISC."
+ <COND (<NOT .O> <RETURN>)
+ (<AND <DESCRIBABLE? .O>
+ <NOT <FSET? .O ,TOUCHBIT>>
+ <SET STR <GETP .O ,P?FDESC>>>
+ <THIS-IS-IT .O>
+ <CRLF>
+ <TELL .STR>
+ <COND (<FSET? .O ,CONTBIT>
+ <DESCRIBE-CONTENTS .O
+ T
+ <+ ,D-ALL?
+ ,D-PARA?>>)>
+ <CRLF>)>
+ <SET O <NEXT? .O>>>
+ <SET O <FIRST? ,HERE>>
+ <REPEAT () ;"DESCFCNS and LDESCS"
+ <COND (<NOT .O> <RETURN>)
+ (<OR <NOT <DESCRIBABLE? .O>>
+ <AND <GETP .O ,P?FDESC>
+ <NOT <FSET? .O ,TOUCHBIT>>>>
+ T)
+ (<AND <SET STR <GETP .O ,P?DESCFCN>>
+ <SET TMP <APPLY .STR ,M-OBJDESC? .O>>>
+ <COND (<NOT <EQUAL? .TMP ,M-FATAL>>
+ <THIS-IS-IT .O>
+ <CRLF>
+ <COND (<SET STR <APPLY .STR ,M-OBJDESC .O>>
+ <COND (<AND <FSET? .O ,CONTBIT>
+ <N==? .STR ,M-FATAL>>
+ <DESCRIBE-CONTENTS
+ .O
+ T
+ <+ ,D-ALL?
+ ,D-PARA?>>)>)>
+ <CRLF>)>)
+ (<SET STR <GETP .O ,P?LDESC>>
+ <THIS-IS-IT .O>
+ <CRLF>
+ <TELL .STR>
+ <COND (<FSET? .O ,CONTBIT>
+ <DESCRIBE-CONTENTS .O
+ T
+ <+ ,D-ALL?
+ ,D-PARA?>>)>
+ <CRLF>)>
+ <SET O <NEXT? .O>>>
+ <DESCRIBE-CONTENTS ,HERE <> <>>
+ <COND (<AND .AV <NOT <EQUAL? ,HERE .AV>>>
+ <DESCRIBE-CONTENTS .AV <> <>>)>>
+
+<CONSTANT D-ALL? 1> ;"print everything?"
+<CONSTANT D-PARA? 2> ;"started paragraph yet?"
+
+"<DESCRIBE-CONTENTS object-whose-contents-to-describe
+ level: -1 means only top level (default)
+ <> means top-level (include crlf)
+ T for all other levels
+ or string to print
+ all?: t if not being called from room-desc >
+
+Prints nothing and rfalses if there was nothing to list.
+
+'The wall crumbles to dust, revealing ' <DESCRIBE-CONTENTS .OBJ> "
+
+<ROUTINE DESCRIBE-CONTENTS (OBJ "OPTIONAL" (LEVEL -1) (ALL? ,D-ALL?)
+ "AUX" (F <>) N (1ST? T) (IT? <>) (TWO? <>)
+ (START? <>) (PARA? <>) DB)
+ <COND (<EQUAL? .LEVEL 2>
+ <SET LEVEL T>
+ <SET PARA? T>
+ <SET START? T>)
+ (<BTST .ALL? ,D-PARA?>
+ <SET PARA? T>)>
+ <SET N <FIRST? .OBJ>>
+ <COND (<OR .START?
+ <IN? .OBJ ,ROOMS>
+ <FSET? .OBJ ,PERSON>
+ <AND .N
+ <FSET? .OBJ ,CONTBIT>
+ <OR <FSET? .OBJ ,OPENBIT>
+ <FSET? .OBJ ,TRANSBIT>>
+ <OR <EQUAL? .LEVEL -1>
+ <FSET? .OBJ ,SEARCHBIT>>>>
+ <REPEAT ()
+ <COND (<OR <NOT .N>
+ <AND <DESCRIBABLE? .N>
+ <OR <BTST .ALL? ,D-ALL?>
+ <SIMPLE-DESC? .N>>>>
+ <COND (.F
+ <COND (.1ST?
+ <SET 1ST? <>>
+ <COND (<EQUAL? .LEVEL <> T>
+ <COND (<NOT .START?>
+ <COND (<NOT .PARA?>
+ <SET PARA? T>
+ <CRLF>)
+ (<EQUAL? .LEVEL T>
+ <TELL " ">)>
+ <DESCRIBE-START .OBJ .N>)>)
+ (<NOT <EQUAL? .LEVEL -1>>
+ <TELL .LEVEL>)>)
+ (.N
+ <TELL ", ">)
+ (ELSE
+ <TELL " and ">)>
+ <TELL A .F>
+ <DESCRIBE-SPECIAL .F>
+ <COND (<AND <NOT .IT?> <NOT .TWO?>>
+ <SET IT? .F>)
+ (T
+ <SET TWO? T>
+ <SET IT? <>>)>)>
+ <SET F .N>)>
+ <COND (.N <SET N <NEXT? .N>>)>
+ <COND (<AND <NOT .F> <NOT .N>>
+ <COND (<AND .IT? <NOT .TWO?>>
+ <THIS-IS-IT .IT?>)>
+ <COND (<AND .1ST? .START?>
+ <TELL " nothing">
+ <RFALSE>)
+ (<AND <NOT .1ST?>
+ <EQUAL? .LEVEL <> T>>
+ <COND (<EQUAL? .OBJ ,HERE>
+ <TELL " here">)>
+ <TELL ".">)>
+ <RETURN>)>>
+ <COND (<EQUAL? .LEVEL <> T>
+ <SET F <FIRST? .OBJ>>
+ <REPEAT ()
+ <COND (<NOT .F> <RETURN>)
+ (<AND <FSET? .F ,CONTBIT>
+ <DESCRIBABLE? .F T>
+ <OR <BTST .ALL? ,D-ALL?>
+ <SIMPLE-DESC? .F>>>
+ <SET DB ,D-BIT>
+ <SETG D-BIT <>>
+ <COND (<DESCRIBE-CONTENTS
+ .F
+ T
+ <COND (.PARA?
+ <+ ,D-ALL?
+ ,D-PARA?>)
+ (ELSE ,D-ALL?)>>
+ <SET 1ST? <>>
+ <SET PARA? T>)>
+ <SETG D-BIT .DB>)>
+ <SET F <NEXT? .F>>>)>
+ <COND (<AND <NOT .1ST?>
+ <EQUAL? .LEVEL <> T>
+ <EQUAL? .OBJ ,HERE <LOC ,WINNER>>>
+ <CRLF>)>
+ <NOT .1ST?>)>>
+
+"DESCRIBE-START -- add starters for special classes of objects here"
+
+<ROUTINE DESCRIBE-START (OBJ N)
+ <COND (<EQUAL? .OBJ ,HERE>
+ <TELL "There is ">)
+ (<EQUAL? .OBJ ,PLAYER>
+ <COND (<EQUAL? ,D-BIT ,WEARBIT>
+ <TELL " You are wearing ">)
+ (T
+ <TELL "You are carrying ">)>)
+ (<FSET? .OBJ ,PERSON>
+ ;<COND (<NOT <FSET? .OBJ ,NOTHEBIT>>
+ <TELL "The ">)> ;"hand is only one this clause catches"
+ <TELL CTHE .OBJ " wears ">)
+ (<FSET? .OBJ ,SURFACEBIT>
+ <TELL "Sitting on " THE .OBJ " is ">)
+ (ELSE
+ <TELL CTHE .OBJ " contains ">)>>
+
+"DESCRIBE-SPECIAL -- add special trailers to object descriptions here"
+
+<ROUTINE DESCRIBE-SPECIAL (OBJ)
+ <COND (<FSET? .OBJ ,ONBIT>
+ <TELL " (providing light)">)
+ ;(<EQUAL? .OBJ ,SLIME>
+ <TELL " (crawling up your arm)">)
+ (<FSET? .OBJ ,SLIMEBIT>
+ <TELL " (slimed)">)
+ (<AND <EQUAL? .OBJ ,HAND>
+ <FSET? ,HAND ,PERSON>
+ <IN? ,HAND ,PLAYER>>
+ <TELL " (perched on your shoulder)">)
+ ;(<FSET? .OBJ ,WEARBIT>
+ <TELL " (being worn)">)>>
+
+"determines if an object is describable at all."
+
+<GLOBAL D-BIT <>> ;"bit to screen objects"
+
+<ROUTINE DESCRIBABLE? (OBJ "OPT" (CONT? <>))
+ <COND (<FSET? .OBJ ,INVISIBLE> <RFALSE>)
+ (<EQUAL? .OBJ ,WINNER> <RFALSE>)
+ (<AND <EQUAL? .OBJ <LOC ,WINNER>>
+ <NOT <EQUAL? ,HERE <LOC ,WINNER>>>>
+ <RFALSE>)
+ (<AND <NOT .CONT?> <FSET? .OBJ ,NDESCBIT>>
+ <RFALSE>)
+ (,D-BIT
+ <COND (<G? ,D-BIT 0>
+ <COND (<FSET? .OBJ ,D-BIT> <RTRUE>)
+ (ELSE <RFALSE>)>)
+ (<NOT <FSET? .OBJ <- ,D-BIT>>>
+ <RTRUE>)
+ (ELSE <RFALSE>)>)
+ (ELSE
+ <RTRUE>)>>
+
+"Determines, for DESCRIBE-OBJECTS, if an object has a simple description
+(not a FDESC, LDESC, or whatever)."
+
+<ROUTINE SIMPLE-DESC? (OBJ "AUX" STR)
+ <COND (<AND <GETP .OBJ ,P?FDESC>
+ <NOT <FSET? .OBJ ,TOUCHBIT>>>
+ <RFALSE>)
+ (<AND <SET STR <GETP .OBJ ,P?DESCFCN>>
+ <APPLY .STR ,M-OBJDESC? .OBJ>>
+ <RFALSE>)
+ (<GETP .OBJ ,P?LDESC> <RFALSE>)
+ (ELSE <RTRUE>)>>
+
+
+
+"DESCRIBE-REST finishes 'Opening the crocodile's mouth reveals '"
+
+<ROUTINE DESCRIBE-REST (OBJ)
+ <COND (<NOT <DESCRIBE-CONTENTS .OBJ>>
+ <TELL "nothing">)>
+ <RTRUE>>
+
+"DESCRIBE-SENT does the whole ball of wax"
+
+<ROUTINE DESCRIBE-SENT (OBJ)
+ <COND (<NOT <DESCRIBE-CONTENTS .OBJ <> <+ ,D-ALL? ,D-PARA?>>>
+ <TELL "The " D .OBJ " is empty.">)>
+ <RTRUE>>
+
+"DESCRIBE-NOTHING returns false if nothing was described"
+
+;<ROUTINE DESCRIBE-NOTHING ()
+ <COND (<DESCRIBE-CONTENTS ,PRSO 2>
+ <COND (<NOT <IN? ,WINNER ,PRSO>>
+ <CRLF>)>
+ <RTRUE>)
+ (T ;"nothing"
+ <RFALSE>)>>
+
+;"END" \ No newline at end of file
diff --git a/frob.zil b/frob.zil
new file mode 100644
index 0000000..b97490b
--- /dev/null
+++ b/frob.zil
@@ -0,0 +1,1663 @@
+"FROB for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+<ROOM TUNNEL-ENTRANCE
+ (IN ROOMS)
+ (DESC "Tunnel Entrance")
+ (LDESC
+"The tunnel continues west from here, becoming narrow, muddy, and
+forbidding. The walls no longer seem to be as finished as they were.
+The steam pipe and coaxial cable disappear into the ceiling at this
+point. The temperature has dropped considerably, as well.")
+ (EAST TO TUNNEL-WEST)
+ (WEST TO MUDDY-TUNNEL)
+ (DOWN TO MUDDY-TUNNEL)
+ (IN TO MUDDY-TUNNEL)
+ (GLOBAL CABLE)>
+
+<ROOM MUDDY-TUNNEL
+ (IN ROOMS)
+ (DESC "Muddy Tunnel")
+ (LDESC
+"The tunnel you came through continues down, barely large enough to
+enter. It is made of sticky gelatinous mud that's been pushed by
+something into a semblance of a passage.")
+ (DOWN TO LARGE-CHAMBER)
+ (UP TO TUNNEL-ENTRANCE)
+ (EAST TO TUNNEL-ENTRANCE)
+ (GLOBAL POOL)
+ ;(ACTION MUDDY-TUNNEL-F)>
+
+;<ROUTINE MUDDY-TUNNEL-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+ CR>)>>
+
+<ROOM LARGE-CHAMBER
+ (IN ROOMS)
+ (DESC "Large Chamber")
+ (UP TO MUDDY-TUNNEL)
+ (DOWN PER LAIR-EXIT) ;"LAIR"
+ (GLOBAL GLOBAL-HOLE)
+ (ACTION LARGE-CHAMBER-F)>
+
+<ROUTINE LAIR-EXIT ()
+ <COND (,URCHIN-FLAG
+ <TELL
+"A few of the urchins grab feebly at you as you pass, but none is a
+serious barrier." CR CR>
+ ,LAIR-1)
+ (<IN? ,URCHINS ,SLOTS>
+ <TELL
+"Something is blocking the downward passage. It's moving, slowly and
+painfully, trying to climb up." CR>
+ <RFALSE>)
+ (ELSE
+ <TELL
+"The urchins lurch, almost as one, into your way, grabbing at you feebly
+but effectively. Their pale, limp hands can't grab you, but they can
+stop you. There is no way past." CR>
+ <RFALSE>)>>
+
+<GLOBAL URCHIN-FLAG <>>
+
+<ROUTINE LARGE-CHAMBER-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"This is a wide spot in the tunnel, just as wet and muddy as elsewhere.
+The walls are slimy as well. Numerous slots or
+indentations about two feet wide and a foot high open here and there. ">
+ <COND (<LOC ,URCHINS>
+ <COND (,URCHIN-FLAG
+ <TELL
+"Stubs of the wire still ">)
+ (ELSE
+ <TELL
+"Thin, wire or ropelike growths emerge
+from a hole further down and ">)>
+ <COND (<IN? ,URCHINS ,SLOTS>
+ <TELL "enter each of the slots. There is
+background noise here, almost loud enough to hear clearly.">)
+ (<IN? ,URCHINS ,HERE>
+ <TELL "envelop the head of each urchin. The
+urchins are ">
+ <COND (,URCHIN-FLAG
+ <TELL "catatonic.">)
+ (ELSE
+ <TELL
+"saying or chanting something repetitive and monotonal,
+almost machinelike.">)>)>)
+ (ELSE
+ <TELL
+"There is a" S " hole leading down.">)>
+ <CRLF>)
+ (<RARG? ENTER>
+ <SETG LAIR-FLAG <>> ;"normally what lair room you're in"
+ <QUEUE I-URCHINS -1>)
+ (<RARG? BEG>
+ <COND (<P? THROUGH GLOBAL-HOLE>
+ <DO-WALK ,P?DOWN>)
+ (<P? EXAMINE GLOBAL-HOLE>
+ <TELL
+"It's a slimy, muddy hole, but it's the only way down." CR>)
+ (<AND <VERB? WALK>
+ <NOT <EQUAL? ,P-WALK-DIR ,P?DOWN ,P?UP>>>
+ <PERFORM ,V?THROUGH ,SLOTS>
+ <RTRUE>)
+ (<P? LISTEN (NOISE <>)>
+ <NEW-PRSO <COND (<IN? ,URCHINS ,SLOTS>
+ ,SLOTS)
+ (ELSE
+ ,URCHINS)>>
+ <RTRUE>)>)>>
+
+<OBJECT URCHINS
+ (IN SLOTS)
+ (DESC "urchins")
+ (SYNONYM URCHIN CHILDREN KIDS KID)
+ (FLAGS INVISIBLE PERSON NOABIT)
+ (DESCFCN URCHINS-DESC)
+ (ACTION URCHINS-F)>
+
+<ROUTINE URCHINS-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <TELL "There are urchins here.">)>>
+
+<GLOBAL NO-RESPONSE "There is no response.">
+
+<ROUTINE URCHINS-F ()
+ <COND (<WINNER? URCHINS>
+ <COND (,URCHIN-FLAG
+ <TELL
+,NO-RESPONSE " It's as though they don't hear you." CR>)
+ (ELSE
+ <TELL
+"The urchins turn to you in unison. They smile, revealing red, broken
+teeth. They never stop their deep-voiced, incomprehensible chant." CR>)>
+ <END-QUOTE>)
+ (<VERB? EXAMINE>
+ <TELL
+"These are not normal looking urchins. Their clothes are
+muddy and tattered. They are barefoot in midwinter, and covered with
+mud. Around their heads are draped the ">
+ <COND (,URCHIN-FLAG <TELL "stubs of the ">)>
+ <TELL
+"ropy growths that you've been
+noticing in this area. Although their eyes are open, they stare
+catatonically." CR>)
+ (<OR <HOSTILE-VERB?>
+ <VERB? SEARCH>>
+ <TELL "They ignore you." CR>)
+ (<VERB? HELP UNTIE>
+ <BEYOND-HELP>)
+ (<P? (GIVE SHOW) * (,URCHINS ,GLOBAL-URCHINS)>
+ <TELL
+"They ignore your offer, caught up in something only they can
+sense." CR>)
+ (<VERB? WAKE>
+ <TELL "They seem quite awake." CR>)
+ (<VERB? LISTEN>
+ <TELL
+"The strange chant never stops. They don't move their lips to make it.
+It resonates deep within their chests." CR>)
+ (<VERB? TELL> <RFALSE>)
+ (ELSE
+ <GLOBAL-URCHINS-F>)>>
+
+<OBJECT URCHIN-CLOTHES
+ (IN URCHIN)
+ (DESC "clothes")
+ (SYNONYM PARKA HAT SHOES)
+ (ADJECTIVE SKI BUMPY BULKY)
+ (FLAGS NDESCBIT TRYTAKEBIT TAKEBIT)
+ (ACTION URCHIN-CLOTHES-F)>
+
+<ROUTINE URCHIN-CLOTHES-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It bulges in odd places." CR>)
+ (<VERB? TAKE OPEN RUB LOOK-INSIDE LOOK-UNDER SEARCH>
+ <TELL
+"\"Hey! Keep off, sucker!">
+ <COND (<EQUAL? <GET ,P-NAMW 0> ,W?PARKA>
+ <TELL " " ,YOU-CANT "scare me!">)>
+ <TELL "\"" CR>)>>
+
+<OBJECT URCHIN
+ (IN AERO-LOBBY)
+ (DESC "urchin")
+ (SYNONYM URCHIN CHILD KID YOURSELF)
+ (ADJECTIVE YOUNG)
+ (FLAGS PERSON AN SEARCHBIT OPENBIT CONTBIT)
+ (DESCFCN URCHIN-DESC)
+ (ACTION URCHIN-F)>
+
+<ROUTINE URCHIN-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <TELL
+"Slouching nearby is an urchin.">
+ <COND (<NOT <FSET? ,URCHIN ,TOUCHBIT>>
+ <FSET ,URCHIN ,TOUCHBIT>
+ <URCHIN-FIRST-LOOK>)>
+ <RFATAL>)>>
+
+<ROUTINE URCHIN-FIRST-LOOK ()
+ <TELL " He's " ,URCHIN-LDESC ". He's jumpy,
+and looks suspiciously at you.">>
+
+<GLOBAL URCHIN-LDESC
+ "a youngish teenager wearing a ski hat, running shoes,
+and a bulky, suspiciously bumpy, threadbare parka">
+
+<ROUTINE URCHIN-F ("AUX" MANY?)
+ <COND (<WINNER? URCHIN>
+ <COND (<VERB? LEAVE>
+ <TELL
+"\"Hey! You go away, sucker.\"">)
+ (<VERB? TELL-ME-ABOUT YES NO>
+ <COND (<PRSO? ,URCHIN>
+ <TELL
+"\"I just came in to get out of the snow. I wouldn't come in here if
+it wasn't snowing.\"">)
+ (<PRSO? ,STUDENTS>
+ <TELL
+"\"Hey, you guys got students gone missing? We got kids gone missing!\"
+He looks at you suspiciously. \"You ain't the one done it, are ya?\"">)
+ (<PRSO? ,GLOBAL-URCHINS>
+ <TELL
+"\"The word is out on the street, man. Don't go to Tech, or you're gonna
+be gone, ya know? I wouldn't be here myself if I had a warm place to go.\"">)
+ (ELSE
+ <TELL
+"He doesn't reply.">)>)
+ (<AND <VERB? WHERE>
+ <FSET? ,PRSO ,TAKEBIT>>
+ <TELL
+"\"I didn't take it!\"">)
+ (<OR <VERB? TAKE OPEN UNLOCK WALK FOLLOW>
+ <HOSTILE-VERB?>>
+ <TELL
+"\"I don't take no orders from bozos!\"">)
+ (ELSE
+ <TELL
+"\"I don't hafta say anything. I ain't done nothing.\"">)>
+ <TELL " He seems very nervous about talking to you." CR>)
+ (<VERB? EXAMINE>
+ <TELL
+"This is an urchin.">
+ <URCHIN-FIRST-LOOK>
+ <CRLF>)
+ (<VERB? SMELL>
+ <TELL
+"He smells damp. There is also a slight odor of fast food." CR>)
+ (<OR <P? (SHOW GIVE) HAND>
+ <P? (SCARE RUB) * HAND>>
+ <COND (<FSET? ,HAND ,PERSON>
+ <REMOVE ,URCHIN>
+ <DEQUEUE I-URCHIN>
+ <FCLEAR ,BOLT-CUTTER ,INVISIBLE>
+ <MOVE ,BOLT-CUTTER ,HERE>
+ <TELL
+"The urchin sees the hand twitching. \"I heard what happens around here!
+I'm not gettin' fed to a monster!\" He lets loose a scream of fear
+and zooms away. Some">
+ <COND (<SET MANY? <ROB ,URCHIN ,HERE>>
+ <TELL " things drop">)
+ (ELSE <TELL "thing drops">)>
+ <TELL " from beneath his parka as he departs.
+He slows for a moment, decides not to retrieve ">
+ <COND (.MANY? <TELL "them">)
+ (ELSE <TELL "it">)>
+ <TELL ", and disappears
+into the distance." CR>)
+ (ELSE
+ <TELL
+"He stares at the hand, scared but holding his ground. \"What's that?\"
+he says, voice quavering." CR>)>)
+ (<P? GIVE * URCHIN>
+ <TELL
+"\"My momma said never take nothin' from no stranger.\"">
+ <COND (<AND <FSET? ,PRSO ,FOODBIT>
+ <NOT <PRSO? ,COKE>>>
+ <REMOVE ,PRSO>
+ <TELL " He takes " THE ,PRSO " anyway, disposing
+of it in record time. \"On the other hand, I'm hungry,\" he remarks.">)>
+ <CRLF>)
+ (<P? TELL-ABOUT * HAND>
+ <TELL
+"\"You expect me to believe garbage like that?\" the urchin sneers." CR>)
+ (<P? SHOW * URCHIN>
+ <COND (<PRSO? ,MASTER-KEY>
+ <TELL
+"\"I got one already.\"" CR>)
+ (<PRSO? ,DEAD-RAT>
+ <TELL
+"\"I seen a lot of those.\"" CR>)
+ (ELSE
+ <TELL
+"He makes an unconvincing show of disinterest." CR>)>)
+ (<HOSTILE-VERB?>
+ <COND (<VERB? THROW> <MOVE ,PRSO ,HERE>)>
+ <COND (<NOT <FSET? ,URCHIN ,RMUNGBIT>>
+ <FSET ,URCHIN ,RMUNGBIT>
+ <TELL
+"The urchin backs off, and then draws a very large switchblade out of his
+coat pocket. \"You watch out,\" he says, \"I know how to use this. Get
+outa here!\"" CR>)
+ (<PRSI? <> ,HANDS>
+ <TELL
+"The urchin laughs in your face, fending you off with his switchblade." CR>)
+ (<FSET? ,PRSI ,WEAPONBIT>
+ <JIGS-UP
+"\"I told you to back off, you clown! You guys been takin' my friends!
+Well, I'm gonna take one of you!\" He knifes you with surprising
+dexterity. You exsanguinate.">)>)
+ (<VERB? SCARE>
+ <TELL
+"How do you propose to do that?" CR>)
+ (<VERB? WHAT>
+ <NEW-PRSO ,URCHINS>
+ <RTRUE>)
+ (<AND <VERB? FOLLOW>
+ <NOT <IN? ,URCHIN ,HERE>>>
+ <TELL
+"He got away clean. " ,YOU-CANT "follow him." CR>)>>
+
+<GLOBAL URCHIN-TABLE <TABLE 0 0 0 0 0 0 0 0 0 0 0 0 0>>
+
+;<SYNTAX $URCHIN = V-$URCHIN>
+
+;<GLOBAL URCHIN-DEBUG <>>
+
+;<ROUTINE V-$URCHIN ()
+ <SETG URCHIN-DEBUG <NOT ,URCHIN-DEBUG>>>
+
+<ROUTINE I-URCHIN ("AUX" (TMP 0) S RM ORM OWINNER UL)
+ <QUEUE I-URCHIN 10>
+ <PUT ,URCHIN-TABLE 0 0>
+ <SET OWINNER ,WINNER>
+ <SETG WINNER ,URCHIN>
+ <SET UL <LOC ,URCHIN>>
+ <COND (<AND <IN? ,URCHIN ,HERE>
+ <PROB 80>
+ <NOT <EQUAL? <META-LOC ,MAINTENANCE-MAN> ,HERE>>>
+ <COND (,LIT
+ <TELL CR
+"The urchin looks around nervously, obviously thinking of flight, but
+decides against it." CR>)>)
+ (ELSE
+ <MAP-DIRECTIONS (D P .UL)
+ <SET S <PTSIZE .P>>
+ ;<COND (,URCHIN-DEBUG
+ <TELL "** ">
+ <COND (<EQUAL? .D ,P?NORTH> <TELL "North">)
+ (<EQUAL? .D ,P?NE> <TELL "NE">)
+ (<EQUAL? .D ,P?EAST> <TELL "East">)
+ (<EQUAL? .D ,P?SE> <TELL "SE">)
+ (<EQUAL? .D ,P?SOUTH> <TELL "South">)
+ (<EQUAL? .D ,P?SW> <TELL "SW">)
+ (<EQUAL? .D ,P?WEST> <TELL "West">)
+ (<EQUAL? .D ,P?NW> <TELL "NW">)
+ (<EQUAL? .D ,P?UP> <TELL "Up">)
+ (<EQUAL? .D ,P?DOWN> <TELL "Down">)
+ (<EQUAL? .D ,P?IN> <TELL "In">)
+ (<EQUAL? .D ,P?OUT> <TELL "Out">)
+ (ELSE <TELL N .D>)>
+ <TELL " ("
+ <COND (<EQUAL? .S ,UEXIT> "U")
+ (<EQUAL? .S ,NEXIT> "N")
+ (<EQUAL? .S ,CEXIT> "C")
+ (<EQUAL? .S ,DEXIT> "D")
+ (<EQUAL? .S ,FEXIT> "F")
+ (ELSE "?")>
+ "): ">)>
+ <SET RM <>>
+ <COND (<OR <EQUAL? .S ,UEXIT>
+ <AND <EQUAL? .S ,CEXIT>
+ <VALUE <GETB .P ,CEXITFLAG>>>
+ <AND <EQUAL? .S ,DEXIT>
+ <FSET? <GETB .P ,DEXITOBJ>
+ ,OPENBIT>>
+ <AND <EQUAL? .S ,FEXIT>
+ <SET RM <APPLY <GET .P ,FEXITFCN>>>>>
+ <COND (<NOT .RM> <SET RM <GETB .P ,REXIT>>)>
+ ;<COND (,URCHIN-DEBUG
+ <TELL D .RM>
+ <COND (<FSET? .RM ,OUTSIDE>
+ <TELL " (outside)">)>
+ <CRLF>)>
+ <COND (<AND <NOT <FSET? .RM ,OUTSIDE>>
+ <NOT <EQUAL? .RM ,TUNNEL>>
+ <NOT <EQUAL?
+ <META-LOC ,MAINTENANCE-MAN>
+ .RM>>>
+ <SET TMP <GET ,URCHIN-TABLE 0>>
+ <SET TMP <+ .TMP 1>>
+ <PUT ,URCHIN-TABLE 0 .TMP>
+ <PUT ,URCHIN-TABLE .TMP .RM>)>)
+ ;(ELSE
+ <COND (,URCHIN-DEBUG
+ <TELL "no" CR>)>)>>
+ <SETG WINNER .OWINNER>
+ <SET ORM <LOC ,URCHIN>>
+ <SET RM <RANDOM-ELEMENT ,URCHIN-TABLE>>
+ ;<COND (,URCHIN-DEBUG
+ <TELL "** => " D .RM CR>)>
+ <COND (<AND <HERE? .RM>
+ ,LIT>
+ <CRLF>
+ <COND (<NOT <FSET? ,URCHIN ,TOUCHBIT>>
+ <FSET ,URCHIN ,TOUCHBIT>
+ <TELL
+"An urchin (" ,URCHIN-LDESC ")">)
+ (ELSE
+ <TELL "The urchin">)>
+ <TELL
+" saunters nonchalantly into the room, notices you, and beats
+a hasty retreat." CR>)
+ (ELSE
+ <COND (<NOT <HERE? .ORM>> <ROB .ORM ,URCHIN>)>
+ <MOVE ,URCHIN .RM>
+ <ROB .RM ,URCHIN>
+ <COND (<HERE? .ORM>
+ <TELL CR
+"The urchin has disappeared." CR>)>)>)>>
+
+<OBJECT BOLT-CUTTER
+ (IN URCHIN)
+ (DESC "bolt cutter")
+ (SYNONYM CUTTER)
+ (ADJECTIVE BOLT CHAIN)
+ (FLAGS INVISIBLE TAKEBIT TOOLBIT WEAPONBIT)
+ (SIZE 10)
+ (VALUE 5)
+ (ACTION BOLT-CUTTER-F)>
+
+<ROUTINE BOLT-CUTTER-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This is a heavy duty bolt or chain cutter, standard equipment for local
+bicycle thieves. It will defeat any but the heaviest bicycle chains." CR>)
+ (<P? CUT (CHAIN CHAIN-1 CHAIN-2)>
+ <TELL "It's too thick." CR>)>>
+
+<OBJECT URCHIN-WIRE
+ (IN LARGE-CHAMBER)
+ (DESC "wire")
+ (SYNONYM WIRE ROPE GROWTH WIRES)
+ (ADJECTIVE THIN ROPY STREAMER ROPELIKE ROPES)
+ (FLAGS NDESCBIT)
+ (VALUE 5)
+ (ACTION URCHIN-WIRE-F)>
+
+<ROUTINE URCHIN-WIRE-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"These are thin, fibrous, ropy growths. They look very tough." CR>)
+ (<VERB? FOLLOW>
+ <TELL
+"They go from the ">
+ <COND (<IN? ,URCHINS ,SLOTS> <TELL "slots">)
+ (ELSE <TELL "urchins">)>
+ <TELL " down the tunnel." CR>)
+ (<P? (CUT MUNG) URCHIN-WIRE>
+ <COND (<PRSI? ,BOLT-CUTTER>
+ <SETG URCHIN-FLAG T>
+ <SCORE-OBJECT ,URCHIN-WIRE>
+ <REMOVE ,URCHIN-WIRE>
+ <TELL
+"You strain and push the two handles of the bolt cutter together with
+all your strength. At first it looks like nothing will happen, but then,
+with a loud click, the jaws cut the wire!|
+|
+The wire, as though under tension, rapidly begins to curl up,
+disappearing down the tunnel and away. ">
+ <COND (<IN? ,URCHINS ,SLOTS>
+ <FCLEAR ,URCHINS ,INVISIBLE>
+ <MOVE ,URCHINS ,HERE>
+ <TELL
+"Urchins burst forth from the slots. ">)>
+ <TELL "The effect on the urchins is
+electric (perhaps literally). They twitch, jerk spasmodically, and fall
+to the ground almost in unison. They have lost all interest in you." CR>)
+ (<AND ,PRSI
+ <OR <FSET? ,PRSI ,WEAPONBIT>
+ <FSET? ,PRSI ,TOOLBIT>>>
+ <TELL
+CTHE ,PRSI " drives the wire into the mud, but doesn't cut it." CR>)
+ (ELSE
+ <V-CUT>)>)>>
+
+<OBJECT SLOTS
+ (IN LARGE-CHAMBER)
+ (DESC "slot")
+ (SYNONYM SLOT SLOTS IDENTATIONS BURROW)
+ (ADJECTIVE SMALL NARROW)
+ (FLAGS NDESCBIT OPENBIT CONTBIT VEHBIT)
+ (ACTION SLOTS-F)>
+
+<ROUTINE SLOTS-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The slots are narrow burrows apparently dug by hand out of the mud of
+the chamber walls.">
+ <COND (<IN? ,URCHINS ,SLOTS>
+ <TELL
+" Most of the slots have a thin wire or rope heading
+into them. You begin to be quite certain that there is something moving
+inside the slot you are looking at.">)>
+ <CRLF>)
+ (<P? (THROUGH BOARD) SLOTS>
+ <TELL
+"You squeeze your way into one of the slots. The mud coats you with
+a cold, slimy coat which makes it barely possible to breathe.">
+ <COND (<IN? ,URCHINS ,SLOTS>
+ <TELL " You are
+about halfway in when your hands touch something fleshy in front of
+you. It's cold and dead. On the other hand, it moves.">)>
+ <TELL
+" You slide out with all the speed you can muster." CR>)
+ (<VERB? LOOK-INSIDE>
+ <TELL
+,YOU-CANT-SEE "anything but the wet walls of the burrow." CR>)
+ (<VERB? REACH-IN>
+ <COND (<NOT <IN? ,URCHINS ,SLOTS>>
+ <TELL
+,THERE-IS-NOTHING "in the slots but cold, wet mud." CR>)
+ (ELSE
+ <TELL
+"You reach inside, oblivious to the cold clammy mud. At first you feel
+nothing, but just at the limit of your stretch, you feel flesh. It's
+cold and dead. You jerk your hand back out." CR>)>)
+ (<VERB? LISTEN>
+ <COND (<IN? ,URCHINS ,SLOTS>
+ <TELL
+"The noise, as you listen more carefully, resolves itself into voices.
+They are chanting, but the words are unknown to you." CR>)>)>>
+
+<GLOBAL URCHIN-CNT 0>
+
+<ROUTINE I-URCHINS ()
+ <COND (<AND <HERE? ,LARGE-CHAMBER>
+ <NOT ,URCHIN-FLAG>>
+ <SETG URCHIN-CNT <+ ,URCHIN-CNT 1>>
+ <COND (<EQUAL? ,URCHIN-CNT 1>
+ <TELL CR
+"A small, furtive motion attracts your attention to the slots." CR>)
+ (<EQUAL? ,URCHIN-CNT 2>
+ <TELL CR
+"There is motion in the slots. In fact, there is motion in almost all
+of them." CR>)
+ (<IN? ,URCHINS ,SLOTS>
+ <FCLEAR ,URCHINS ,INVISIBLE>
+ <MOVE ,URCHINS ,LARGE-CHAMBER>
+ <TELL CR
+"Slowly, painfully, things emerge from the slots. They are pale, thin
+creatures with red mouths and staring eyes. Mold grows in their hair and
+wirelike streamers wrap their heads and join a bundle on the floor.
+You realize that these are urchins." CR>)
+ (ELSE <DEQUEUE I-URCHINS>)>)>>
+
+<ROOM LAIR-1
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "north")
+ (UP TO LARGE-CHAMBER)
+ (SOUTH TO LAIR-6)
+ (NORTH TO LAIR-2)
+ (EAST TO LAIR-1)
+ (ACTION LAIR-F)>
+
+<ROOM LAIR-2
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "down")
+ (EAST TO LAIR-1)
+ (WEST TO LAIR-7)
+ (UP TO LAIR-8)
+ (DOWN TO LAIR-3)
+ (ACTION LAIR-F)>
+
+<ROOM LAIR-3
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "south")
+ (WEST TO LAIR-7)
+ (SOUTH TO LAIR-4)
+ (NORTH TO LAIR-6)
+ (EAST TO LAIR-2)
+ (ACTION LAIR-F)>
+
+<ROOM LAIR-4
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "south")
+ (UP TO LAIR-3)
+ (EAST TO LAIR-10)
+ (DOWN TO LAIR-10)
+ (SOUTH TO LAIR-5)
+ (WEST TO LAIR-11)
+ (ACTION LAIR-F)>
+
+<ROOM LAIR-5
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "down")
+ (DOWN TO OUTER-LAIR)
+ (UP TO LAIR-5)
+ (NORTH TO LAIR-4)
+ (WEST TO LAIR-3)
+ (EAST TO LAIR-11)
+ (ACTION LAIR-F)>
+
+<ROOM LAIR-6
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "west")
+ (EAST TO LAIR-1)
+ (WEST TO LAIR-3)
+ (DOWN TO LAIR-8)
+ (NORTH TO LAIR-6)
+ (ACTION LAIR-F)>
+
+<ROOM LAIR-7
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "east")
+ (WEST TO LAIR-1)
+ (DOWN TO LAIR-7)
+ (UP TO LAIR-10)
+ (EAST TO LAIR-3)
+ (SOUTH TO LAIR-2)
+ (ACTION LAIR-F)>
+
+<ROOM LAIR-8
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "east")
+ (EAST TO LAIR-2)
+ (UP TO LAIR-6)
+ (DOWN TO LAIR-9)
+ (ACTION LAIR-F)>
+
+<ROOM LAIR-9
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "up")
+ (UP TO LAIR-2)
+ (EAST TO LAIR-8)
+ (NORTH TO LAIR-6)
+ (DOWN TO LAIR-10)
+ (ACTION LAIR-F)>
+
+<ROOM LAIR-10
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "west")
+ (NORTH TO LAIR-10)
+ (WEST TO LAIR-7)
+ (UP TO LAIR-9)
+ (ACTION LAIR-F)>
+
+<ROOM LAIR-11
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "east")
+ (EAST TO LAIR-9)
+ (UP TO LAIR-11)
+ (SOUTH TO LAIR-11)
+ (ACTION LAIR-F)>
+
+<ROOM OUTER-LAIR
+ (IN ROOMS)
+ (DESC "Wet Tunnel")
+ (POINT "south")
+ (UP TO LAIR-5)
+ (IN TO INNER-LAIR IF CURTAIN-DOOR IS OPEN)
+ (SOUTH TO INNER-LAIR IF CURTAIN-DOOR IS OPEN)
+ (FLAGS ONBIT)
+ (GLOBAL CURTAIN-DOOR POOL)
+ (ACTION LAIR-F)>
+
+<ROUTINE LAIR-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+"You are lost in narrow, wet tunnels burrowed through the mud. Muddy, oily
+water covers the floor.">
+ <COND (<HERE? ,OUTER-LAIR>
+ <COND (<IN? ,CURTAIN ,HERE>
+ <TELL
+" A curtain of moldy slime covers the south wall." CR>)
+ (ELSE
+ <TELL
+" There is an ancient door in the south wall. ">
+ <TELL-OPEN-CLOSED ,CURTAIN-DOOR>)>)
+ (ELSE <CRLF>)>)
+ (<RARG? LEAVE>
+ <SETG LAIR-FLAG <>>
+ <FCLEAR ,HERE ,TOUCHBIT>)
+ (<RARG? BEG>
+ <COND (<AND <HERE? ,OUTER-LAIR>
+ <IN? ,CURTAIN ,HERE>
+ <VERB? WALK>
+ <EQUAL? ,P-WALK-DIR ,P?SOUTH>>
+ <PERFORM ,V?THROUGH ,CURTAIN>
+ <RTRUE>)>)
+ (<RARG? END>
+ <COND (<AND <IN? ,HAND ,PLAYER>
+ <FSET? ,HAND ,PERSON>
+ <IN? ,RING ,HAND>
+ <NOT <HERE? ,LAIR-FLAG>>>
+ <SETG LAIR-FLAG ,HERE>
+ <HAND-POINTS>)>)>>
+
+<ROUTINE HAND-POINTS ()
+ <TELL CR
+"The hand ">
+ <COND (<IN? ,RING ,HAND>
+ <TELL
+"points its mutilated ring finger " <GETP ,HERE ,P?POINT> " and ">)>
+ <TELL "grips your shoulder tightly." CR>>
+
+<GLOBAL LAIR-FLAG <>>
+
+<OBJECT CURTAIN
+ (IN OUTER-LAIR)
+ (DESC "slime curtain")
+ (SYNONYM SLIME CURTAIN)
+ (ADJECTIVE SLIME GREEN WET MOLDY PHOSPHORESCENT)
+ (FLAGS NDESCBIT)
+ (VALUE 5)
+ (ACTION CURTAIN-F)>
+
+<ROUTINE CURTAIN-F ("AUX" W)
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The entire south wall is covered with a curtain of moldy phosphorescent
+slime. There is something about the slime that makes it appear unhealthy,
+as though the influences here are bad for anything living." CR>)
+ (<P? (POUR THROW) ,NITROGEN ,CURTAIN>
+ <REMOVE ,NITROGEN>
+ <DEQUEUE I-NITROGEN-GOES>
+ <QUEUE I-MIST-GOES 2>
+ <TELL
+"The liquid splashes onto the curtain, and a cold mist
+fills the room. The slime begins to freeze. ">
+ <COND (<L? ,NITROGEN-CNT 3>
+ <TELL
+"Patches of it shatter and fall, but the rest of the slime oozes into
+the ruined spots, and the curtain appears unharmed." CR>)
+ (ELSE
+ <SETG SCORE <+ ,SCORE 5>>
+ <REMOVE ,CURTAIN>
+ <FCLEAR ,CURTAIN-DOOR ,INVISIBLE>
+ <TELL
+"Nearly the entire curtain solidifies, shatters, and drops to the
+ground, revealing an ancient wooden door." CR>)>)
+ (<OR <HOSTILE-VERB?>
+ <P? (TAKE PRY THROUGH LOOK-BEHIND RAISE) CURTAIN>>
+ <COND (<PRSO? ,CURTAIN> <SET W ,PRSI>)
+ (ELSE <SET W ,PRSO>)>
+ <COND (<EQUAL? .W <> ,HANDS>
+ <DEQUEUE I-SLIME-OBJECT>
+ <QUEUE I-SLIME -1>
+ <COND (<AND <IN? ,GLOVES ,WINNER>
+ <FSET? ,GLOVES ,WEARBIT>>
+ <TELL
+"The curtain is very slick and wet. Some of it sticks to your gloves." CR>)
+ (<IN? ,SLIME ,WINNER>
+ <MORE-SLIME ,HANDS>)
+ (ELSE
+ <TELL
+"The feel is greasy, wet, and at first cold. Then you get a burning
+sensation, like that from a sea-nettle sting. You jerk
+away, but some of the slime sticks to you!" CR>)>
+ <MOVE ,SLIME ,WINNER>)
+ (ELSE
+ <COND (<VERB? THROW> <MOVE .W ,HERE>)>
+ <COND (<FSET? .W ,SLIMEBIT>
+ <MORE-SLIME .W>)
+ (ELSE
+ <FSET .W ,SLIMEBIT>
+ <QUEUE I-SLIME-OBJECT 2>
+ <TELL
+CTHE .W " touches the curtain, and immediately some of the
+slime attacks, flowing almost intelligently onto it. " CTHE .W
+" is now covered with slime." CR>)>)>)>>
+
+<ROUTINE MORE-SLIME (OBJ)
+ <TELL
+"More slime flows onto " THE .OBJ "." CR>>
+
+<OBJECT SLIME
+ (DESC "crawling slime")
+ (SYNONYM SLIME)
+ (ADJECTIVE CRAWLING)
+ (DESCFCN SLIME-DESC)
+ (ACTION SLIME-F)>
+
+<ROUTINE SLIME-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <TELL
+"There is slime crawling up your arm. It has reached your "
+<GET ,SLIMES ,SLIME-CNT> ".">)>>
+
+<ROUTINE SLIME-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's flowing, dark-green, and undulates slowly as it crawls up your
+arm." CR>)
+ (<VERB? RUB>
+ <TELL
+"You already did that once. Twice would be stupid!" CR>)
+ (<VERB? MUNG KILL>
+ <TELL
+S "There is no effect"". You only succeed in hurting your arm." CR>)
+ (<P? POUR NITROGEN>
+ <JIGS-UP
+"You succeed in pouring the freezing liquid all over your arm. This
+kills the slime. It also kills you, but then, one
+must make sacrifices, right?">)
+ (<VERB? DROP TAKE-OFF>
+ <TELL
+"You try to scrape it off, but to no avail. It just flows back into
+place around your arm." CR>)>>
+
+<ROUTINE I-SLIME-OBJECT ("OPT" (WHAT <>))
+ <COND (<NOT .WHAT> <SET WHAT ,WINNER>)>
+ <MAP-CONTENTS (W .WHAT)
+ <COND (<AND <FSET? .W ,SLIMEBIT>
+ <NOT <FSET? .W ,RMUNGBIT>>>
+ <FSET .W ,RMUNGBIT>
+ <COND (<EQUAL? .WHAT ,WINNER>
+ <MOVE ,SLIME .WHAT>
+ <DEQUEUE I-SLIME-OBJECT>
+ <QUEUE I-SLIME -1>
+ <TELL CR
+"The slime has now flowed from " THE .W>
+ <COND (<FSET? ,GLOVES ,WEARBIT>
+ <REMOVE ,GLOVES>
+ <TELL
+", devoured your gloves">)>
+ <TELL ", and begun attacking
+your hand." CR>
+ <RTRUE>)
+ (ELSE
+ <FSET .WHAT ,SLIMEBIT>
+ <QUEUE I-SLIME-OBJECT 1>)>)
+ (<AND <FSET? .W ,CONTBIT>
+ <FSET? .W ,OPENBIT>>
+ <I-SLIME-OBJECT .W>)>>>
+
+<ROUTINE I-SLIME ()
+ <COND (<IN? ,SLIME ,WINNER>
+ <COND (<AND <ZERO? ,SLIME-CNT>
+ <IN? ,GLOVES ,WINNER>
+ <FSET? ,GLOVES ,WEARBIT>>
+ <REMOVE ,GLOVES>
+ <TELL CR
+"The slime eats through your gloves! It begins to attack your hand,
+and you feel a hot, stinging sensation, like a sea-nettle sting." CR>)
+ (<G? <SETG SLIME-CNT <+ ,SLIME-CNT 1>> 5>
+ <DEQUEUE I-SLIME>
+ <CRLF>
+ <JIGS-UP
+"The slime engulfs your nose! You cough, choke, and begin to suffocate!
+You fall to the floor, splashing in the water. You either
+suffocate or drown. After you're dead, it makes no difference.">)
+ (ELSE
+ <TELL CR
+"The slime is creeping slowly up your arm! It's reached your "
+<GET ,SLIMES ,SLIME-CNT> ,PERIOD>)>)
+ (ELSE <DEQUEUE I-SLIME>)>>
+
+<GLOBAL SLIME-CNT 0>
+
+<GLOBAL SLIMES
+ <LTABLE (PURE)
+ "wrist"
+ "elbow"
+ "bicep"
+ "shoulder"
+ "neck">>
+
+<OBJECT CURTAIN-DOOR
+ (IN LOCAL-GLOBALS)
+ (DESC "ancient door")
+ (SYNONYM DOOR LOCK)
+ (ADJECTIVE ANCIENT WOODEN)
+ (FLAGS AN INVISIBLE NDESCBIT DOORBIT LOCKED OPENABLE)
+ (ACTION CURTAIN-DOOR-F)>
+
+<ROUTINE CURTAIN-DOOR-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This door, blackened by age, is
+built of ancient, rotting timbers, but still looks very strong. It is
+set in a rough-hewn arch. Oddly, in addition to an old, rusted-away
+lock, there is another which looks new and shiny. ">
+ <TELL-OPEN-CLOSED ,CURTAIN-DOOR>)
+ (<AND <HERE? ,INNER-LAIR>
+ <P? (LOCK UNLOCK) CURTAIN-DOOR MASTER-KEY>>
+ <TELL
+"The lock doesn't appear to work from this side!" CR>)
+ (<P? UNLOCK CURTAIN-DOOR MASTER-KEY>
+ <FCLEAR ,CURTAIN-DOOR ,LOCKED>
+ <TELL ,DOOR-NOW-UNLOCKED>)
+ (<P? (ATTACK MUNG) CURTAIN-DOOR>
+ <COND (<PRSI? <> ,HANDS>
+ <TELL
+"You only bruise your hands." CR>)
+ (ELSE
+ <TELL
+"The door is surprisingly solid." CR>)>)>>
+
+<GLOBAL DOOR-NOW-UNLOCKED "The door is now unlocked.|">
+
+<ROOM INNER-LAIR
+ (IN ROOMS)
+ (DESC "Inner Lair")
+ (UP TO OUTER-LAIR IF CURTAIN-DOOR IS OPEN)
+ (GLOBAL CURTAIN-DOOR POOL)
+ (POINT "down")
+ (FLAGS ONBIT)
+ (ACTION INNER-LAIR-F)>
+
+<ROUTINE INNER-LAIR-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+S "The floor here is ""a stagnant, slime infested pool of water.
+It feels to ">
+ <COND (<NOT <FSET? ,BOOTS ,WEARBIT>>
+ <TELL "your sodden feet to ">)>
+ <TELL "be about six inches deep.">
+ <COND (<IN? ,MASS ,HERE>
+ <TELL " Ropes
+or wires tumble down the slope, where they enter a
+large whitish mass which takes up much of the chamber. The noise is loud
+here, and comes from the mass, which undulates in synchrony
+with the noise.">)>
+ <TELL " Wan, sourceless light illuminates the chamber." CR>)
+ (<RARG? BEG>
+ <COND (<P? LISTEN (<> NOISE)>
+ <NEW-PRSO ,MASS>
+ <RTRUE>)>)
+ (<RARG? ENTER>
+ <FSET ,CURTAIN-DOOR ,LOCKED>
+ <FCLEAR ,CURTAIN-DOOR ,OPENBIT>
+ <QUEUE I-HAND-DIVES -1>
+ <MOVE ,HACKER ,LAIR-5>
+ <QUEUE I-HACKER-RETURNS 2>
+ <AS-YOU-ENTER-LEAVE "enter">)>>
+
+<ROUTINE I-HAND-DIVES ()
+ <COND (<FSET? ,HAND ,PERSON>
+ <COND (<HELD? ,HAND>
+ <MOVE ,HAND ,INNER-LAIR>
+ <TELL CR
+"Suddenly, the hand leaps from your shoulder into the slime-encrusted
+puddle. It dives beneath the water." CR>)
+ (<IN? ,HAND ,INNER-LAIR>
+ <TELL CR
+"The hand repeatedly dives and bobs to the surface in one part
+of" ,THE-POOL>)>)>>
+
+<GLOBAL THE-POOL " the pool near your feet.|">
+
+<GLOBAL LAIR-CNT 0>
+
+<GLOBAL HACKER-STARES "The hacker stares at ">
+
+<ROUTINE I-HACKER-RETURNS ("AUX" HERE?)
+ <SET HERE? <IN? ,HACKER ,HERE>>
+ <COND (<IN? ,HACKER ,INNER-LAIR>
+ <SETG LAIR-CNT <+ ,LAIR-CNT 1>>
+ <COND (<EQUAL? ,LAIR-CNT 1>
+ <TELL CR
+,HACKER-STARES "the thing in the cave. \"I got very suspicious
+about your problems with the net. I began to trace some coax, found
+some repeaters and bridges that weren't on the layout charts, and
+started following them. Anyway, here I am. That thing there, whatever
+it is, and those
+wires, are interfaced to the whole campus net. And that means it's tied
+into all the nets, commercial, government, even military,
+potentially.\"" CR>)
+ (<EQUAL? ,LAIR-CNT 2>
+ <TELL CR
+"\"I guess I better do something. It could be a serious compromise of
+system integrity if this thing isn't dealt with.\" He peers at the
+mass, as if evaluating it. He then reaches into a pocket and pulls out
+a small pair of wire strippers." CR>)
+ (<EQUAL? ,LAIR-CNT 3>
+ <FSET ,HACKER ,INVISIBLE>
+ <FSET ,HACKER ,RMUNGBIT>
+ <TELL CR
+"The hacker advances on the mass, apparently planning to cut some of
+the wires leading into it. As he approaches it, the sound stops completely,
+and the wires begin a frantic, looping, twining dance. The mass begins to
+flow towards the hacker almost as quickly as he walks toward it. They
+reach each other and begin to merge together. He screams; a long, ululating
+cry that echoes through the cavern. Then he is engulfed." CR>)
+ (<EQUAL? ,LAIR-CNT 4 5 6>
+ <TELL CR
+"The mass is bulging, vibrating, and rippling.">
+ <COND (<EQUAL? ,LAIR-CNT 6>
+ <TELL " A huge tear is forming near
+where the hacker was absorbed.">)>
+ <CRLF>)
+ (<EQUAL? ,LAIR-CNT 7>
+ <FCLEAR ,HACKER ,INVISIBLE>
+ <TELL CR
+"The hacker pulls himself out of the side of the mass. As he does, you
+think you can see many pairs of eyes appear briefly in the semitransparent
+mass, watching curiously. Wires and
+tentacles trail from his body, and tiny, almost rat-like creatures cling
+to his body everywhere, crawling about like ants. He walks slowly,
+jerkily towards you. \"Be one!\" he says, haltingly but fervently."
+CR>)
+ (<EQUAL? ,LAIR-CNT 8>
+ <TELL CR
+"The hacker grabs for you. \"Join us! Serve the master!\" he croaks. Some
+of the creatures leap onto you, biting at exposed skin." CR>)
+ (<EQUAL? ,LAIR-CNT 9>
+ <CRLF>
+ <JIGS-UP
+"The hacker is surprisingly strong. He
+drags you toward the thing in the corner, exhorting you
+to join it, and at last, forcibly, you do. You are not the first, or
+the last." T>)>
+ <RFATAL>)
+ (<IN? ,HACKER ,OUTER-LAIR>
+ <MOVE ,HACKER ,INNER-LAIR>
+ <TELL CR
+"You hear a stumbling noise behind you, turn and see the hacker staggering
+into the cavern." CR CR
+,HACKER-STARES "you, shocked. \"It's you! When I gave you my key,
+I never suspected you'd get this far!\"" CR>)
+ (<IN? ,HACKER ,LAIR-5>
+ <QUEUE I-HACKER-RETURNS -1>
+ <MOVE ,HACKER ,OUTER-LAIR>
+ <TELL CR
+"You hear noises outside the door." CR>)>>
+
+<OBJECT MASS
+ (IN INNER-LAIR)
+ (DESC "whitish mass")
+ (SYNONYM MASS)
+ (ADJECTIVE LARGE WHITE WHITISH)
+ (FLAGS NDESCBIT PERSON)
+ (ACTION MASS-F)>
+
+<ROUTINE MASS-F ()
+ <COND (<WINNER? ,MASS>
+ <TELL
+"When you speak, the noise stops, if only briefly. When it resumes, it's
+more insistent." CR>
+ <END-QUOTE>)
+ (ELSE
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The mass is strangely, even wrongly, shaped. It is hard to get a fix on
+what's wrong with it, but it doesn't look like it could or should exist
+in any sane universe. It quivers and bubbles as though air were pumping
+through it. Many wires, tentacles, and combinations of the two enter the
+mass from all sides, making it almost fuzzy in appearance." CR>)
+ (<VERB? LISTEN>
+ <TELL
+"You listen closely to the sounds, which are loud and at first seem random.
+The more you listen, the more you sense a strange regularity to them. You
+get impressions, one after another, of electronic music, a simple sine
+wave pattern, and telephone crosstalk. They are all overlaid with speech,
+or something like speech, nearer random babbling, or many people talking
+at once. You can't understand any of it, but it's so near intelligibility
+that you feel that if you moved closer, you just might get it." CR>)
+ (<VERB? GIVE SHOW>
+ <TELL
+"There is no reaction that you can detect." CR>)
+ (<VERB? RUB>
+ <PERFORM ,V?ATTACK
+ ,PRSO
+ <COND (,PRSI ,PRSI)
+ (ELSE ,HANDS)>>
+ <RTRUE>)
+ (<P? PUT-ON HIGH-VOLTAGE MASS>
+ <SWAP-VERB ,V?RUB>
+ <RTRUE>)
+ (<VERB? ATTACK THROUGH>
+ <COND (<PRSI? <> ,HANDS>
+ <TELL S "You approach the "
+ "mass and grab onto it.">
+ <JIGS-UP ,TOUCHING-MASS T>)
+ (<PRSI? ,HIGH-VOLTAGE>
+ <COND (<FSET? ,HIGH-VOLTAGE ,RMUNGBIT>
+ <TELL
+"Deftly avoiding the exposed wire, the">)
+ (ELSE
+ <TELL "The">)>
+ <TELL " tentacles grab you and pull you
+into the rippling slime.">
+ <JIGS-UP ,TOUCHING-MASS T>)
+ (<FSET? ,PRSI ,WEAPONBIT>
+ <REMOVE ,PRSI>
+ <TELL
+CTHE ,PRSI " is engulfed by the mass and disappears. The mass itself
+is unchanged." CR>)>)>)>>
+
+<GLOBAL TOUCHING-MASS
+" Immediately, your mind is
+overwhelmed with visions and vistas it cannot assimilate. As the mass
+pulls you into itself, it all becomes clearer, but it's much too late
+by then.">
+
+<OBJECT REPEATER
+ (IN INNER-LAIR)
+ (DESC "metal box")
+ (SYNONYM REPEATER BOX)
+ (ADJECTIVE LAN NETWORK METAL)
+ (FLAGS TRANSBIT CONTBIT SEARCHBIT OPENABLE)
+ (DESCFCN REPEATER-DESC)
+ (ACTION REPEATER-F)>
+
+<ROUTINE REPEATER-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <TELL
+"Set on the wall, incongruous in its surroundings, is a metal box. ">
+ <DESCRIBE-BOX>
+ <RFATAL>)>>
+
+<GLOBAL ENDS-IN-STUMP " ends in a blackened stump">
+
+<ROUTINE DESCRIBE-BOX ()
+ <TELL
+"On one side a coaxial cable enters the box. On the other, " A ,OUTPUT-CABLE
+" leads from the box ">
+ <COND (<IN? ,MASS ,HERE> <TELL "to the mass">)
+ (ELSE <TELL "and" ,ENDS-IN-STUMP>)>
+ <TELL ". ">
+ <COND (<FSET? ,REPEATER ,OPENBIT>
+ <TELL
+"The cover is off the box, revealing electronic innards.">)
+ (ELSE
+ <TELL
+S "There is a ""metal cover on the box.">)>>
+
+<ROUTINE REPEATER-F ()
+ <COND (<VERB? EXAMINE LOOK-INSIDE>
+ <DESCRIBE-BOX>
+ <COND (<FSET? ,REPEATER ,OPENBIT>
+ <TELL " ">
+ <DESCRIBE-CABLES>)
+ (ELSE <CRLF>)>
+ <RTRUE>)
+ (<P? OPEN REPEATER>
+ <NEW-PRSO ,REPEATER-COVER>
+ <RTRUE>)
+ (<P? CLOSE REPEATER>
+ <PERFORM ,V?PUT ,REPEATER-COVER ,REPEATER>
+ <RTRUE>)
+ (<P? PLUG * REPEATER>
+ <COND (<AND <FSET? ,REPEATER-COVER ,OPENBIT>
+ <NOT <IN? ,INPUT-CABLE ,INPUT-SOCKET>>>
+ <NEW-PRSI ,INPUT-SOCKET>)
+ (ELSE
+ <TELL
+"You'll have to be more specific." CR>)>)>>
+
+<OBJECT REPEATER-COVER
+ (IN REPEATER)
+ (DESC "metal cover")
+ (SYNONYM COVER SCREWS)
+ (ADJECTIVE METAL FINGER)
+ (FLAGS TAKEBIT OPENABLE)
+ (ACTION REPEATER-COVER-F)>
+
+<ROUTINE REPEATER-COVER-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a metal cover with simple finger screws to hold it on." CR>)
+ (<AND <VERB? UNTIE>
+ <FSET? ,REPEATER ,OPENBIT>>
+ <TELL "You already opened it." CR>)
+ (<OR <VERB? OPEN UNTIE>
+ <AND <VERB? TAKE TAKE-OFF>
+ <IN? ,REPEATER-COVER ,REPEATER>>>
+ <COND (<OR <NOT <VERB? TAKE TAKE-OFF>>
+ <EQUAL? <ITAKE> T>>
+ <FSET ,REPEATER ,OPENBIT>
+ <TELL
+"You remove the cover, revealing a plethora of electronic innards. ">
+ <DESCRIBE-CABLES>)
+ (ELSE
+ <RTRUE>)>)
+ (<OR <VERB? CLOSE>
+ <P? (PUT TIE) REPEATER-COVER REPEATER>>
+ <COND (<FSET? ,REPEATER ,OPENBIT>
+ <FCLEAR ,REPEATER ,OPENBIT>
+ <MOVE ,REPEATER-COVER ,REPEATER>
+ <TELL S "You screw it back on.|">)
+ (ELSE
+ <TELL
+"It's already screwed on tightly." CR>)>)>>
+
+<ROUTINE DESCRIBE-CABLES ()
+ <TELL "Most prominent are a socket ">
+ <COND (<IN? ,INPUT-CABLE ,INPUT-SOCKET>
+ <TELL
+"into which the coaxial cable is plugged">)
+ (ELSE
+ <TELL
+"(now empty) next to which a coaxial cable hangs">)>
+ <TELL ", and a connector into
+which the glistening " 'OUTPUT-CABLE " disappears." CR>>
+
+<OBJECT INPUT-CABLE
+ (IN INPUT-SOCKET)
+ (DESC "coaxial cable")
+ (SYNONYM CABLING CABLE)
+ (ADJECTIVE COAXIAL COAX)
+ (FLAGS NDESCBIT)
+ (ACTION INPUT-CABLE-F)>
+
+<ROUTINE INPUT-CABLE-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This looks like pretty standard coax to you. It appears almost
+spontaneously from high in the wall, and enters the box, where ">
+ <COND (<FSET? ,REPEATER ,OPENBIT>
+ <TELL "it's ">
+ <COND (<AND <FSET? ,INPUT-CABLE ,RMUNGBIT>
+ <NOT <IN? ,INPUT-CABLE ,INPUT-SOCKET>>>
+ <TELL
+"ends next to an empty socket.">)
+ (<FSET? ,INPUT-CABLE ,RMUNGBIT>
+ <TELL
+"cut.">)
+ (<NOT <IN? ,INPUT-CABLE ,INPUT-SOCKET>>
+ <TELL
+"hanging loose next to a socket.">)
+ (ELSE
+ <TELL
+"plugged into the socket.">)>)
+ (ELSE
+ <TELL "it " S "disappears from sight.">)>
+ <CRLF>)
+ (<VERB? UNPLUG UNTIE>
+ <COND (<IN? ,INPUT-CABLE ,INPUT-SOCKET>
+ <MOVE ,INPUT-CABLE ,REPEATER>
+ <TELL
+"You unscrew the cable. It now hangs unconnected inside the box." CR>)
+ (ELSE
+ <TELL ,IT-ALREADY-IS>)>)
+ (<VERB? TAKE>
+ <COND (<IN? ,INPUT-CABLE ,INPUT-SOCKET>
+ <NEW-VERB ,V?UNTIE>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"It's threaded through the box: impossible to take." CR>)>)
+ (<P? (PLUG TIE PUT) INPUT-CABLE INPUT-SOCKET>
+ <COND (<NOT <IN? ,INPUT-CABLE ,INPUT-SOCKET>>
+ <MOVE ,INPUT-CABLE ,INPUT-SOCKET>
+ <TELL S "You screw it back on.|">)
+ (ELSE
+ <TELL ,IT-ALREADY-IS>)>)
+ (<VERB? CUT>
+ <COND (<FSET? ,INPUT-CABLE ,RMUNGBIT>
+ <ITS-ALREADY-X "cut">)
+ (<PRSI? ,BOLT-CUTTER ,AXE>
+ <FSET ,INPUT-CABLE ,RMUNGBIT>
+ <TELL
+"You neatly snip the cable in two." CR>)
+ (ELSE
+ <PRSI-USELESS>)>)>>
+
+<OBJECT INPUT-SOCKET
+ (IN REPEATER)
+ (DESC "socket")
+ (SYNONYM SOCKET CONNECT)
+ (FLAGS NDESCBIT OPENBIT CONTBIT SEARCHBIT)
+ (ACTION INPUT-SOCKET-F)>
+
+<ROUTINE INPUT-SOCKET-F ()
+ <COND (<VERB? EXAMINE LOOK-INSIDE>
+ <COND (<IN? ,INPUT-CABLE ,INPUT-SOCKET>
+ <TELL
+"It has a coaxial cable plugged into it." CR>)
+ (ELSE
+ <TELL
+"It's empty." CR>)>)>>
+
+<OBJECT OUTPUT-CABLE
+ (IN REPEATER)
+ (DESC "cablelike appendage")
+ (SYNONYM CABLING CABLE APPENDAGE TENTACLE)
+ (ADJECTIVE OUTPUT CABLELIKE)
+ (FLAGS NDESCBIT)
+ (ACTION OUTPUT-CABLE-F)>
+
+<ROUTINE OUTPUT-CABLE-F ()
+ <COND (<VERB? EXAMINE>
+ <COND (<IN? ,MASS ,HERE>
+ <TELL
+"This is " A ,OUTPUT-CABLE " of the mass in the end of the cave.
+It enters the box and ">
+ <COND (<FSET? ,OUTPUT-CABLE ,RMUNGBIT>
+ <TELL "is cut.">)
+ (<FSET? ,REPEATER ,OPENBIT>
+ <TELL "connects to a connector inside it.">)
+ (ELSE
+ <TELL S "disappears from sight.">)>
+ <TELL
+" The cable twitches periodically." CR>)
+ (ELSE
+ <TELL
+CTHE ,OUTPUT-CABLE ,ENDS-IN-STUMP "." CR>)>)
+ (<OR <VERB? UNPLUG UNTIE>
+ <P? TAKE OUTPUT-CABLE>>
+ <TELL
+"There is no way to do that. The appendage and its socket
+blend together indistinguishably." CR>)
+ (<VERB? CUT ATTACK>
+ <COND (<FSET? ,OUTPUT-CABLE ,RMUNGBIT>
+ <ITS-ALREADY-X "cut">)
+ (<NOT <FSET? ,REPEATER ,OPENBIT>>
+ <TELL
+"The tentacle whips out of your way." CR>)
+ (<PRSI? ,BOLT-CUTTER ,AXE>
+ <FSET ,OUTPUT-CABLE ,RMUNGBIT>
+ <TELL
+"You cut the tentacle in two inside the box, where it can't get away,
+precipitating a deafening shriek from the direction of the mass." CR>)
+ (ELSE
+ <PRSI-USELESS>)>)>>
+
+<ROUTINE PRSI-USELESS ()
+ <TELL
+CTHE ,PRSI " is useless for this purpose." CR>>
+
+<OBJECT HIGH-VOLTAGE
+ (DESC "power line")
+ (SYNONYM LINE)
+ (ADJECTIVE POWER HIGH VOLTAGE)
+ (FLAGS TAKEBIT WEAPONBIT)
+ (ACTION HIGH-VOLTAGE-F)>
+
+<ROUTINE HIGH-VOLTAGE-F ()
+ <COND (<VERB? EXAMINE>
+ <COND (<FSET? ,HIGH-VOLTAGE ,RMUNGBIT>
+ <TELL
+"This is one end of a high voltage power line. The conductors are
+visible within the slashed outer insulation." CR>)
+ (<FSET? ,HIGH-VOLTAGE ,POWERBIT>
+ <TELL
+"This is a thick, hard cable. It reminds you of a high voltage
+power line." CR>)
+ (ELSE
+ <TELL "It's still under the water." CR>)>)
+ (<OR <VERB? TAKE>
+ <AND <VERB? MOVE> <NOT <HELD? ,PRSO>>>>
+ <DEQUEUE I-HAND-DIVES>
+ <COND (<NOT <EQUAL? <ITAKE> T>>
+ <RTRUE>)
+ (<FSET? ,HIGH-VOLTAGE ,RMUNGBIT>
+ <DEQUEUE I-LINE-IN-WATER>
+ <COND (<FSET? ,HIGH-VOLTAGE ,POWERBIT>
+ <TELL
+"You carefully grab the line just as it's about to drop into the
+water." CR>)
+ (<FSET? ,GLOVES ,WEARBIT>
+ <TELL "Taken." CR>)
+ (ELSE
+ <JIGS-UP
+"As you foolishly reach into the water for the line, your hands
+become electrified. Nanoseconds later, the rest of you does as well.">)>)
+ (ELSE
+ <FSET ,HIGH-VOLTAGE ,POWERBIT>
+ <TELL
+"You pull a length of the line out of the water. It's like holding a
+large, heavy snake." CR>)>)
+ (<VERB? MOVE>
+ <TELL
+,YOU-CANT "pull any more of it out." CR>)
+ (<OR <VERB? DROP>
+ <P? PUT * POOL>>
+ <MOVE ,HIGH-VOLTAGE ,HERE>
+ <TELL S "You release the ""line.">
+ <COND (<FSET? ,HIGH-VOLTAGE ,RMUNGBIT>
+ <QUEUE I-LINE-IN-WATER 2>)>
+ <CRLF>)
+ (<AND <P? RUB * HIGH-VOLTAGE>
+ <FSET? ,HIGH-VOLTAGE ,RMUNGBIT>>
+ <PERFORM ,V?ATTACK ,PRSO ,HIGH-VOLTAGE>
+ <RTRUE>)
+ (<P? (CUT ATTACK) HIGH-VOLTAGE>
+ <COND (<FSET? ,HIGH-VOLTAGE ,RMUNGBIT>
+ <ITS-ALREADY-X "cut">)
+ (<NOT <FSET? ,HIGH-VOLTAGE ,POWERBIT>>
+ <TELL
+"You splash around in the water, to no avail. You can't see the line." CR>)
+ (<PRSI? ,AXE>
+ <COND (<G? <SETG HV-CNT <+ ,HV-CNT 1>> 2>
+ <FSET ,HIGH-VOLTAGE ,RMUNGBIT>
+ <MOVE ,HIGH-VOLTAGE ,HERE>
+ <QUEUE I-LINE-IN-WATER 2>
+ <TELL
+"The line parts! The two ends begin to sink towards the water as they
+straighten out." CR>)
+ (<EQUAL? ,HV-CNT 2>
+ <TELL
+"Your blow cuts through more insulation and into the conductors." CR>)
+ (ELSE
+ <TELL
+"You strike the line with the axe, making a deep gash in the
+insulation." CR>)>)
+ (<PRSI? ,BOLT-CUTTER>
+ <TELL
+"The jaws of the bolt cutter won't open far enough to fit around the
+line." CR>)
+ (ELSE
+ <TELL
+"You'd probably have as much success trying to bite it in two." CR>)>)
+ (<P? (PUT PLUG TIE) HIGH-VOLTAGE INPUT-SOCKET>
+ <COND (<NOT <FSET? ,HIGH-VOLTAGE ,RMUNGBIT>>
+ <TELL
+"There's no end to the line that you could plug in." CR>)
+ (<FIRST? ,INPUT-SOCKET>
+ <TELL
+"There's already " A <FIRST? ,INPUT-SOCKET> " in the socket." CR>)
+ (ELSE
+ <TELL
+"You shove the exposed conductors into the socket, producing a shower of
+sparks!">
+ <COND (<NOT <FSET? ,GLOVES ,WEARBIT>>
+ <MOVE ,HIGH-VOLTAGE ,HERE>
+ <QUEUE I-LINE-IN-WATER 2>
+ <TELL
+" The sparks burn your hands! You jerk back, dropping the line!" CR>)
+ (<NOT <FSET? ,BOOTS ,WEARBIT>>
+ <JIGS-UP
+" You are standing in electrified water. You are even
+grounded. Do you know what this means? Can you say \"dead?\"">)
+ (<FSET? ,OUTPUT-CABLE ,RMUNGBIT>
+ <MOVE ,HIGH-VOLTAGE ,INPUT-SOCKET>
+ <TELL
+" The stump of the tentacle still connected to the connector
+shrivels and fries." CR>)
+ (<NOT <QUEUED? I-FROB-APPEARS>>
+ <MOVE ,HIGH-VOLTAGE ,INPUT-SOCKET>
+ <DEQUEUE I-HACKER-RETURNS>
+ <QUEUE I-FROB-APPEARS -1>
+ <TELL
+" The tentacle connected to the other socket begins to jerk and twitch
+spasmodically. The mass it's connected to quivers, and a horrible
+noise, almost like a huge machine running without oil, issues from
+the thing.">
+ <COND (<NOT <FSET? ,HACKER ,INVISIBLE>>
+ <TELL
+" The hacker screams soundlessly and drops into the water.">)>
+ <TELL CR CR
+"The mass begins to change shape, compacting, darkening. You can
+briefly see human outlines within the grey, gelatinous mass. They
+surround something larger, of a shape not human, not animal, like
+nothing you've seen before." CR>)
+ (ELSE <RTRUE>)>)>)
+ (<VERB? FOLLOW>
+ <COND (<FSET? ,HIGH-VOLTAGE ,POWERBIT>
+ <TELL
+"Both ends of the line disappear into the water and mud of the lair." CR>)>)>>
+
+<GLOBAL HV-CNT 0>
+
+<ROUTINE I-LINE-IN-WATER ()
+ <CRLF>
+ <COND (<FSET? ,HIGH-VOLTAGE ,POWERBIT>
+ <TELL
+"The exposed ends of the high voltage line drop into the water! ">
+ <FCLEAR ,HIGH-VOLTAGE ,POWERBIT>)>
+ <COND (<NOT <FSET? ,BOOTS ,WEARBIT>>
+ <JIGS-UP
+"Four thousand volts of electricity, only slightly attenuated by the resistance
+of the water, course through your body! The result is shocking.">)
+ (ELSE
+ <QUEUE I-LINE-IN-WATER -1>
+ <TELL
+"Sparks and bubbles burst from the electrified water." CR>)>>
+
+<OBJECT POOL
+ (IN LOCAL-GLOBALS)
+ (DESC "pool")
+ (SYNONYM POOL WATER PUDDLE)
+ (ADJECTIVE SLIME ENCRUSTED INFESTED)
+ (FLAGS NDESCBIT VEHBIT)
+ (ACTION POOL-F)>
+
+<ROUTINE POOL-F ()
+ <COND (<VERB? SWIM THROUGH BOARD STAND-ON LEAP WALK-AROUND>
+ <TELL
+,ALREADY-IN-IT " It covers most of the floor!" CR>)
+ (<VERB? PUT-UNDER>
+ <TELL
+CTHE ,PRSO " gets wet." CR>)
+ (<HERE? ,INNER-LAIR>
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The floor is covered by a pool of stagnant water. Near your
+feet there is a slightly deeper part that seems to have something in
+it." CR>)
+ (<VERB? DRINK DRINK-FROM FILL>
+ <TELL
+"You couldn't bear to drink the water from this pool." CR>)
+ (<VERB? LOOK-INSIDE>
+ <TELL
+,YOU-CANT-SEE "a thing, as the water is foul and murky." CR>)
+ (<VERB? REACH-IN SEARCH>
+ <COND (<LOC ,HIGH-VOLTAGE>
+ <TELL
+,YOU-FIND-NOTHING " you would wish to touch again." CR>)
+ (ELSE
+ <TELL
+S "You root around ""blindly in the gooey, slimy water. ">
+ <COND (<QUEUED? I-HAND-DIVES>
+ <DEQUEUE I-HAND-DIVES>
+ <MOVE ,HIGH-VOLTAGE ,HERE>
+ <TELL
+S "You feel something " "thick and slippery! A tentacle? No, it's cold and
+dead. " ,IT-SEEMS-TO-BE "a line of some kind, just below the
+surface." CR>)
+ (ELSE
+ <TELL
+,YOU-FIND-NOTHING "." CR>)>)>)
+ (<VERB? CROSS>
+ <PERFORM ,V?THROUGH ,MASS>
+ <RTRUE>)>)
+ (ELSE
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a pool of rather yucky water." CR>)
+ (<VERB? LOOK-INSIDE>
+ <TELL
+"It's about as clear as mud." CR>)
+ (<VERB? REACH-IN>
+ <TELL
+"It feels greasy, cold, and generally unpleasant." CR>)>)>>
+
+<OBJECT FROB
+ (DESC "thing")
+ (SYNONYM CREATURE THING BEING)
+ (FLAGS NDESCBIT PERSON)
+ (GENERIC GENERIC-CREATURE-F)
+ (ACTION FROB-F)>
+
+<ROUTINE FROB-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It is not from any wholesome place. It is the stuff of nightmares. It
+is the thing that waits in the dark, the thing that scratches at your
+windows late at night. It is not death, for next to this, death is a
+friend to be cherished." CR>)
+ (<P? THROW SMOOTH-STONE FROB>
+ <COND (<EQUAL? ,END-CNT 1>
+ <REMOVE ,SMOOTH-STONE>
+ <TELL
+"The stone hurtles through the air and is swallowed by the black nothing
+at its center. The creature howls in pain!" CR>)
+ (<EQUAL? ,END-CNT 2>
+ <REMOVE ,FROB>
+ <TELL
+"The stone smashes into the creature, sticking to its ichorous hide.
+The thing thrashes about, trying to bite at the stone, which is glowing
+brighter and brighter. Small hands issue from beneath its scales to tug
+in vain at the irritant. The creature begins to show gaping holes of
+dark, light-devouring nothingness around the stone. Its wings spread
+painfully, as though it were trying to fly away, and then fold. It
+widens its jaw in an almost human scream of agony. The black hole of
+its maw overwhelms it, and indeed the creature appears to be
+swallowing itself. At last, a grey cloud of greasy smoke surrounds the
+glowing stone, still suspended in midair. Then even that vanishes, and
+the stone drops to the ground, no longer glowing. The thing is gone." CR>
+ <MOVE ,SMOOTH-STONE ,HERE>
+ <FCLEAR ,SMOOTH-STONE ,TOUCHBIT>
+ <SETG SCORE 100>)>)
+ (<OR <P? RUB FROB SMOOTH-STONE>
+ <P? ATTACK FROB HIGH-VOLTAGE>>
+ <TELL
+,YOU-CANT "force yourself to get that close to it." CR>)
+ (<HOSTILE-VERB?>
+ <TELL
+"Defiantly, the creature shrugs off your puny attack." CR>)>>
+
+<GLOBAL END-CNT 0>
+
+<ROUTINE I-FROB-APPEARS ()
+ <SETG END-CNT <+ ,END-CNT 1>>
+ <COND (<EQUAL? ,END-CNT 1>
+ <REMOVE ,HACKER>
+ <REMOVE ,MASS>
+ <FSET ,OUTPUT-CABLE ,RMUNGBIT>
+ <SETG SCORE <+ ,SCORE 5>>
+ <MOVE ,FROB ,HERE>
+ <TELL CR
+"The gelatinous mass solidifies and compacts, leaving behind a
+litter of smoking debris. In the debris squats a being. Huge,
+misshapen, it stares at you with baleful yellow eyes. Its scaly wings
+beat slowly, driving a fetid stench through the stale air of the
+cavern. A barbed tongue slides across its broken, daggerlike fangs.">
+ <COND (<HELD? ,SMOOTH-STONE>
+ <TELL CR CR
+CTHE ,SMOOTH-STONE " vibrates. It starts to feel warm.">)>
+ <CRLF>)
+ (<EQUAL? ,END-CNT 2>
+ <TELL CR
+"The thing tenses, preparing to leap. Its mouth opens, revealing not
+the glistening interior, but a dead-black outline like a hole into
+nothingness.">
+ <COND (<HELD? ,SMOOTH-STONE>
+ <TELL CR CR
+CTHE ,SMOOTH-STONE " is now glowing with a bright-red heat that nevertheless
+fails to burn you.">)>
+ <CRLF>)
+ (<EQUAL? ,END-CNT 3>
+ <COND (<LOC ,FROB>
+ <TELL CR
+"The creature leaps, a mountain falling on you, and the darkness
+swallows you, never to brighten again.">
+ <COND (<HELD? ,SMOOTH-STONE>
+ <TELL CR CR
+CTHE ,SMOOTH-STONE ", all that's left where you were standing, drops quietly
+into the pool.">)>
+ <JIGS-UP <>>
+ <RFATAL>)>)>>
+
+<OBJECT BOOTS
+ (IN BROWN-BASEMENT)
+ (DESC "pair of rubber boots")
+ (SYNONYM BOOTS)
+ (ADJECTIVE RUBBER PAIR)
+ (FLAGS TAKEBIT)
+ (ACTION BOOTS-F)>
+
+<ROUTINE BOOTS-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"They are well-used rubber boots." CR>)
+ (<VERB? WEAR>
+ <COND (<EQUAL? <IWEAR> T>
+ <TELL "Snug, but okay." CR>)
+ (ELSE <RTRUE>)>)>>
+
+<ROUTINE IWEAR ()
+ <COND (<FSET? ,PRSO ,WEARBIT>
+ <TELL ,YOU-ARE ,PERIOD>
+ <RFALSE>)
+ (<NOT <HELD? ,PRSO>>
+ <TELL ,YOU-ARENT " holding that!" CR>
+ <RFALSE>)
+ (ELSE
+ <MOVE ,PRSO ,WINNER>
+ <FSET ,PRSO ,WEARBIT>
+ <RTRUE>)>> \ No newline at end of file
diff --git a/globals.zil b/globals.zil
new file mode 100644
index 0000000..71d3207
--- /dev/null
+++ b/globals.zil
@@ -0,0 +1,650 @@
+"GLOBALS for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+<DIRECTIONS ;"Do not change the order of the first 8 without consulting MARC!"
+ NORTH NE EAST SE SOUTH SW WEST NW UP DOWN IN OUT>
+
+<SYNONYM NORTH N>
+<SYNONYM SOUTH S>
+<SYNONYM EAST E>
+<SYNONYM WEST W>
+<SYNONYM DOWN D>
+<SYNONYM UP U>
+<SYNONYM NE NORTHEAST>
+<SYNONYM NW NORTHWEST>
+<SYNONYM SE SOUTHEAST>
+<SYNONYM SW SOUTHWEST>
+<SYNONYM IN AHEAD>
+
+<GLOBAL HERE <>>
+
+<GLOBAL LIT <>>
+
+<GLOBAL MOVES 0>
+
+<GLOBAL SCORE 0>
+
+;<GLOBAL DIR-TABLE
+ <PLTABLE 1 P?NORTH "north"
+ 2 P?EAST "east"
+ 4 P?WEST "west"
+ 8 P?SOUTH "south"
+ 16 P?NE "northeast"
+ 32 P?NW "northwest"
+ 64 P?SE "southeast"
+ 128 P?SW "southwest">>
+
+<CONSTANT DIR-BIT 1>
+<CONSTANT DIR-DIR 2>
+<CONSTANT DIR-NAME 3>
+
+;<ROUTINE DIR-BASE (DIR I O "AUX" (L <GET ,DIR-TABLE 0>))
+ <DO (CNT 0 .L 3)
+ <COND (<EQUAL? <GET ,DIR-TABLE <+ .CNT .I>> .DIR>
+ <RETURN <GET ,DIR-TABLE <+ .CNT .O>>>)>>>
+
+"global objects and associated routines"
+
+<OBJECT GLOBAL-OBJECTS
+ (FLAGS AN
+ CONTBIT
+ DOORBIT
+ INVISIBLE
+ LOCKED
+ NDESCBIT
+ NOABIT
+ NOTHEBIT
+ ONBIT
+ OUTSIDE
+ OPENBIT
+ PERSON
+ POWERBIT
+ ;RAIRBIT
+ READBIT
+ RLANDBIT
+ RMUNGBIT
+ ;RWATERBIT
+ SEARCHBIT
+ SLIMEBIT
+ SURFACEBIT
+ TAKEBIT
+ THE
+ TOOLBIT
+ TOUCHBIT
+ TRANSBIT
+ TRYTAKEBIT
+ VEHBIT
+ WEAPONBIT
+ WEARBIT)>
+
+<OBJECT LOCAL-GLOBALS
+ (IN GLOBAL-OBJECTS)
+ (SYNONYM ZZMGCK) ;"Yes, this needs to exist."
+ (DESCFCN 0)
+ (CONTFCN 0)
+ (GLOBAL GLOBAL-OBJECTS)
+ (FDESC "F")
+ (LDESC "F")
+ ;(NAME 0)
+ ;(PSEUDO "FOOBAR" V-WALK)
+ (THINGS 0)
+ (COUNT 0)
+ (SIZE 0)
+ (TEXT "")
+ (CAPACITY 0)>
+
+<OBJECT ROOMS
+ (IN TO ROOMS)>
+
+<GLOBAL P-DIRECTION <>>
+
+<OBJECT INTDIR
+ (IN GLOBAL-OBJECTS)
+ (DESC "direction")>
+
+<OBJECT INTNUM
+ (IN GLOBAL-OBJECTS)
+ (DESC "number")
+ (SYNONYM INTNUM)
+ (ADJECTIVE NUMBER)
+ (ACTION INTNUM-F)>
+
+<ROUTINE INTNUM-F ()
+ <COND (<PRSO? ,INTNUM>
+ <COND (<HERE? ,CS-ELEVATOR-ROOM>
+ <REDIRECT ,INTNUM ,FLOOR-BUTTON>
+ <RTRUE>)
+ (<HERE? ,KITCHEN>
+ <PUT ,P-ADJW 0 ,W?INTNUM>
+ <REDIRECT ,INTNUM ,CONTROLS>
+ <RTRUE>)
+ (<VERB? PUSH>
+ <TELL S "There's no number ""to push here." CR>)>)>>
+
+<OBJECT PSEUDO-OBJECT
+ (IN GLOBAL-OBJECTS)
+ (DESC "pseudo")
+ (ACTION ME-F)>
+
+<OBJECT IT
+ (IN GLOBAL-OBJECTS)
+ (SYNONYM IT THEM OBJECT FROB)
+ (DESC "it")
+ (FLAGS AN NOABIT NOTHEBIT NDESCBIT TOUCHBIT)>
+
+<OBJECT HIM
+ (IN GLOBAL-OBJECTS)
+ (SYNONYM HIM HER)
+ (DESC "him")
+ (FLAGS NOABIT NOTHEBIT NDESCBIT TOUCHBIT)>
+
+<OBJECT NOT-HERE-OBJECT
+ (DESC "it")
+ (FLAGS NOABIT NOTHEBIT)
+ (ACTION NOT-HERE-OBJECT-F)>
+
+"NOT-HERE-OBJECT-F returns false if it was successful in substituting
+an object for the not-here-object. if it returns true, it failed for
+some reason."
+
+<ROUTINE NOT-HERE-OBJECT-F ("AUX" TBL (PRSO? T) (X <>))
+ <COND (<AND <PRSO? ,NOT-HERE-OBJECT>
+ <PRSI? ,NOT-HERE-OBJECT>>
+ <TELL "Those things aren't here!" CR>
+ <RTRUE>)
+ (<PRSO? ,NOT-HERE-OBJECT>
+ <SET TBL ,P-PRSO>
+ <COND (<VERB? FOLLOW WAIT-FOR FIND
+ TELL WHAT WHERE WHO>
+ <SET X T>)>)
+ (T
+ <SET TBL ,P-PRSI>
+ <COND (<VERB? ASK-ABOUT ASK-FOR TELL-ABOUT>
+ <SET X T>)>
+ <SET PRSO? <>>)>
+ <COND (<AND .X <NOT <FIND-NOT-HERE .TBL .PRSO?>>>
+ <COND (<VERB? FOLLOW>
+ <TELL
+"I'm afraid that's not possible." CR>
+ <RTRUE>)
+ (<VERB? WAIT-FOR>
+ <COND (<AND <PRSO? ,RATS>
+ <IN-TUNNEL? ,RATS>
+ <IN-TUNNEL?>>
+ <TELL "All in good time..." CR>
+ <RTRUE>)
+ (ELSE
+ <COND (<PLURAL? ,PRSO>
+ <TELL "They're">)
+ (ELSE
+ <TELL "He's">)>
+ <TELL " not expected any time soon." CR>
+ <RTRUE>)>)
+ (<AND <VERB? TELL>
+ <OR <NOT <EQUAL? <LOC ,PRSO>
+ ,INF-1 ,INF-2 ,INF-3
+ ,INF-4 ,INF-5>>
+ <NOT <HERE? ,INF-1 ,INF-2 ,INF-3
+ ,INF-4 ,INF-5>>>>
+ ;<CANT-SEE-ANY-HERE .PRSO?>
+ ;<RTRUE>)
+ (ELSE
+ <RFALSE>)>)>
+ ;"Here is the default 'cant see any' printer"
+ <CANT-SEE-ANY-HERE .PRSO?>>
+
+<ROUTINE CANT-SEE-ANY-HERE (PRSO?)
+ <COND (<WINNER? ,PLAYER>
+ <TELL "You">)
+ (ELSE
+ <TELL CTHE ,WINNER>)>
+ <TELL " can't see any ">
+ <COND (,P-OFLAG
+ <COND (<PRINT-ADJT ,P-XADJNT>)>
+ <COND (,P-XNAM <PRINTB ,P-XNAM>)>)
+ (ELSE
+ <THING-PRINT .PRSO?>)>
+ <TELL " here." CR>
+ <END-QUOTE>>
+
+<ROUTINE FIND-NOT-HERE (TBL PRSO? "AUX" M-F OBJ)
+;"Special-case code goes here. <MOBY-FIND .TBL> returns # of matches. If 1,
+then P-MOBY-FOUND is it. You can treat the 0 and >1 cases alike or differently.
+Always return RFALSE (not handled) if you have resolved the problem."
+ <SET M-F <MOBY-FIND .TBL>>
+ %<DEBUG-CODE
+ <COND (,ZDEBUG
+ <TELL "[Found " N .M-F " obj]" CR>)>>
+ <COND (<EQUAL? 1 .M-F>
+ %<DEBUG-CODE
+ <COND (,ZDEBUG
+ <TELL "[Namely: " D ,P-MOBY-FOUND "]" CR>)>>
+ <COND (.PRSO?
+ <SETG PRSO ,P-MOBY-FOUND>)
+ (T
+ <SETG PRSI ,P-MOBY-FOUND>)>
+ <RFALSE>)
+ (T
+ ,NOT-HERE-OBJECT)>>
+
+<OBJECT LIGHT
+ (IN GLOBAL-OBJECTS)
+ (DESC "light")
+ (SYNONYM LIGHT LIGHTS)
+ (ACTION LIGHT-F)>
+
+<ROUTINE LIGHT-F ()
+ <COND (<VERB? LAMP-ON>
+ <COND (,LIT
+ <TELL ,IT-IS-ALREADY "light" ,PERIOD>)
+ (T
+ <TELL
+"You need a light source!" CR>)>)
+ (<VERB? LAMP-OFF>
+ <TELL ,WASTE-OF-TIME>)>>
+
+<OBJECT GLOBAL-HOLE
+ (IN LOCAL-GLOBALS)
+ (FLAGS NDESCBIT TOUCHBIT)
+ (DESC "hole")
+ (SYNONYM HOLE)
+ (ADJECTIVE MUDDY)
+ (ACTION GLOBAL-HOLE-F)>
+
+<ROUTINE GLOBAL-HOLE-F ()
+ <COND (<P? DIG GLOBAL-HOLE *>
+ <PERFORM ,V?DIG ,PRSI>
+ <RTRUE>)
+ (<VERB? REACH-IN>
+ <TELL ,YOU-FIND-NOTHING " of interest." CR>)>>
+
+<OBJECT CEILING
+ (IN GLOBAL-OBJECTS)
+ (FLAGS NDESCBIT TOUCHBIT)
+ (DESC "ceiling")
+ (SYNONYM CEILIN ROOF)
+ (ACTION CEILING-F)>
+
+<ROUTINE CEILING-F ()
+ <COND (<VERB? LOOK-UNDER>
+ <NEW-VERB ,V?LOOK>
+ <RTRUE>)>>
+
+<OBJECT AIR
+ (IN GLOBAL-OBJECTS)
+ (DESC "air")
+ (SYNONYM AIR COLD)
+ (FLAGS AN NOABIT)>
+
+<OBJECT FEET
+ (IN GLOBAL-OBJECTS)
+ (SYNONYM FEET FOOT)
+ (DESC "your feet")
+ (FLAGS NDESCBIT TOOLBIT TOUCHBIT NOABIT NOTHEBIT)>
+
+<OBJECT HANDS
+ (IN GLOBAL-OBJECTS)
+ (SYNONYM HANDS HAND)
+ (ADJECTIVE BARE MY)
+ (DESC "your hand")
+ (FLAGS NDESCBIT TOOLBIT TOUCHBIT NOABIT NOTHEBIT)
+ (GENERIC GENERIC-HAND-F)>
+
+<ROUTINE GENERIC-HAND-F ()
+ ,HAND>
+
+<OBJECT HEAD
+ (IN GLOBAL-OBJECTS)
+ (DESC "your head")
+ (SYNONYM HEAD FACE)
+ (ADJECTIVE YOUR MY)
+ (FLAGS NOABIT NOTHEBIT)>
+
+<OBJECT EYES
+ (IN GLOBAL-OBJECTS)
+ (DESC "your eyes")
+ (SYNONYM EYE EYES)
+ (ADJECTIVE YOUR MY)
+ (FLAGS NOABIT NOTHEBIT)
+ (ACTION EYES-F)>
+
+<ROUTINE EYES-F ()
+ <COND (<VERB? OPEN>
+ <TELL "They are." CR>)
+ (<VERB? CLOSE>
+ <TELL "That won't help." CR>)
+ (<NOT ,LIT>
+ <TELL ,TOO-DARK>)>>
+
+<OBJECT PLAYER
+ (IN TERMINAL-ROOM)
+ (SYNONYM PROTAG)
+ (DESC "it")
+ (FLAGS NDESCBIT INVISIBLE PERSON CONTBIT TRANSBIT)
+ (ACTION PLAYER-F)>
+
+<ROUTINE PLAYER-F ("AUX" DOOR)
+ <COND (,ON-CABLE?
+ <COND (<OR <P? DROP ROOMS>
+ <VERB? DISEMBARK TAKE TAKE-OFF>
+ <HOSTILE-VERB?>
+ <AND <VERB? WALK>
+ <EQUAL? ,P-WALK-DIR ,P?DOWN>>>
+ <SETG ON-CABLE? <>>
+ <TELL "You let go of the cable and drop to the floor">
+ <COND (,RATS-HERE
+ <COND (<L? ,RATS-HERE 2>
+ <SETG RATS-HERE 2>)>
+ <TELL
+" among the now-frenzied rats">)>
+ <TELL ,PERIOD>)>)
+ (,HOLDING-DOORS?
+ <SET DOOR <THIS-FLOOR-DOOR>>
+ <COND (<AND <NOT <PRSO? ,ELEVATOR-DOOR .DOOR>>
+ <NOT <PRSI? ,ELEVATOR-DOOR .DOOR>>
+ <NOT <GAME-VERB?>>
+ <NOT <PASSIVE-VERB?>>>
+ <TELL ,HOLDING-IS-ALL CR>)>)
+ (ELSE <RFALSE>)>>
+
+<OBJECT ME
+ (IN GLOBAL-OBJECTS)
+ (SYNONYM ME MYSELF SELF)
+ (DESC "yourself")
+ (FLAGS PERSON TOUCHBIT NOABIT NOTHEBIT)
+ (ACTION ME-F)>
+
+<ROUTINE MENTAL-COLLAPSE ()
+ <TELL
+"Talking to yourself is a sign of impending mental collapse." CR>>
+
+<ROUTINE ME-F ("AUX" OLIT)
+ <COND (<P? EXAMINE ,ME>
+ <V-DIAGNOSE>)
+ (<VERB? TELL HELP>
+ <MENTAL-COLLAPSE>
+ <END-QUOTE>)
+ (<VERB? LISTEN>
+ <TELL "Yes?" CR>)
+ (<VERB? WAKE>
+ <TELL ,YOU-ARE>
+ <TELL ,PERIOD>)
+ (<AND <WINNER? ,PLAYER>
+ <VERB? GIVE>>
+ <COND (<PRSO? ,ME>
+ <TELL ,WASTE-OF-TIME>)
+ (<PRSI? ,ME>
+ <COND (<IN? ,PRSO ,PLAYER>
+ <PRE-TAKE>)
+ (T
+ <PERFORM ,V?TAKE ,PRSO>
+ <RTRUE>)>)>)
+ (<VERB? MOVE>
+ <V-WALK-AROUND>)
+ (<VERB? SEARCH>
+ <V-INVENTORY>
+ <RTRUE>)
+ (<VERB? KILL MUNG BURY SMELL>
+ <JIGS-UP
+"Verdict: suicide while the balance of the mind was disturbed.">
+ <RTRUE>)
+ (<VERB? WHO>
+ <V-WHAT>)
+ (<VERB? FOLLOW>
+ <TELL
+"You're getting ahead of yourself." CR>)
+ (<VERB? LOOK-BEHIND>
+ <TELL
+"You look back over your shoulder. ">
+ <COND (<PROB 80>
+ <TELL
+S "There's nothing ""there." CR>)
+ (<PROB 80>
+ <TELL
+"Was that a flicker of movement in the distance?" CR>)
+ (ELSE
+ <TELL
+"You see something duck back into the shadows." CR>)>)>>
+
+<OBJECT GLOBAL-ROOM
+ (IN GLOBAL-OBJECTS)
+ (DESC "room")
+ (SYNONYM ROOM CHAMBER PLACE BASEMENT)
+ (ADJECTIVE AREA)
+ (ACTION GLOBAL-ROOM-F)>
+
+<ROUTINE GLOBAL-ROOM-F ()
+ <COND (<VERB? LOOK EXAMINE LOOK-INSIDE>
+ <V-LOOK>
+ <RTRUE>)
+ (<P? PUT * ,GLOBAL-ROOM>
+ <PERFORM ,V?DROP ,PRSO>
+ <RTRUE>)
+ (<VERB? THROUGH WALK-TO>
+ <V-WALK-AROUND>)
+ (<VERB? DROP LEAVE EXIT>
+ <DO-WALK ,P?OUT>)
+ (<VERB? WALK-AROUND>
+ <TELL
+"Walking around the room reveals nothing new. To move elsewhere, just type
+the desired direction." CR>)
+ (<VERB? LAMP-ON>
+ <NEW-PRSO ,LIGHT>
+ <RTRUE>)>>
+
+
+<SETG C-NORTH 1>
+<SETG C-EAST 2>
+<SETG C-WEST 4>
+<SETG C-SOUTH 8>
+<SETG C-NE 16>
+<SETG C-NW 32>
+<SETG C-SE 64>
+<SETG C-SW 128>
+
+<CONSTANT C-NORTH 1>
+<CONSTANT C-EAST 2>
+<CONSTANT C-WEST 4>
+<CONSTANT C-SOUTH 8>
+<CONSTANT C-NE 16>
+<CONSTANT C-NW 32>
+<CONSTANT C-SE 64>
+<CONSTANT C-SW 128>
+
+<OBJECT NORTH-WALL
+ (IN GLOBAL-OBJECTS)
+ (DESC "north wall")
+ (SYNONYM WALL)
+ (ADJECTIVE NORTH)
+ (GENERIC GENERIC-WALL-F)
+ (ACTION WALL-F)>
+
+<OBJECT EAST-WALL
+ (IN GLOBAL-OBJECTS)
+ (DESC "east wall")
+ (SYNONYM WALL)
+ (ADJECTIVE EAST)
+ (FLAGS AN)
+ (GENERIC GENERIC-WALL-F)
+ (ACTION WALL-F)>
+
+<OBJECT WEST-WALL
+ (IN GLOBAL-OBJECTS)
+ (DESC "west wall")
+ (SYNONYM WALL)
+ (ADJECTIVE WEST)
+ (GENERIC GENERIC-WALL-F)
+ (ACTION WALL-F)>
+
+<OBJECT SOUTH-WALL
+ (IN GLOBAL-OBJECTS)
+ (DESC "south wall")
+ (SYNONYM WALL)
+ (ADJECTIVE SOUTH)
+ (GENERIC GENERIC-WALL-F)
+ (ACTION WALL-F)>
+
+<OBJECT WALL
+ (IN GLOBAL-OBJECTS)
+ (DESC "wall")
+ (SYNONYM WALL WALLS)
+ (GENERIC GENERIC-WALL-F)
+ (ACTION WALL-F)>
+
+<ROUTINE GENERIC-WALL-F ()
+ ,WALL>
+
+<ROUTINE WALL-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL ,IT-LOOKS-LIKE "a wall." CR>)
+ (<VERB? LOWER MUNG>
+ <TELL ,YOU-CANT "pull down a wall that easily." CR>)>>
+
+<OBJECT DIRT
+ (IN GLOBAL-OBJECTS)
+ (DESC "dirt")
+ (SYNONYM RUBBLE DEBRIS DUST DIRT)
+ (FLAGS NOABIT)>
+
+<OBJECT GROUND
+ (IN GLOBAL-OBJECTS)
+ (SYNONYM FLOOR GROUND FIELD)
+ (ADJECTIVE STONE SANDY TINY LEVEL)
+ (DESC "floor")
+ ;(FLAGS NOABIT)
+ (ACTION GROUND-F)>
+
+<ROUTINE GROUND-F ()
+ <COND (<VERB? EXAMINE>
+ <COND ;(<FSET? ,HERE ,RAIRBIT>
+ <TELL
+"It's a long way down." CR>)
+ (ELSE
+ <TELL
+"It's still there." CR>)>)
+ (<P? PUT * ,GROUND>
+ <PERFORM ,V?BURY ,PRSO>
+ <RTRUE>)
+ (<VERB? CLIMB-UP CLIMB-ON CLIMB-FOO BOARD>
+ <TELL ,WASTE-OF-TIME>)
+ (<VERB? LOOK-UNDER>
+ <TELL
+"You never did master X-rays. Freshman physics was such a drag." CR>)>>
+
+<OBJECT CORRIDOR
+ (IN GLOBAL-OBJECTS)
+ (DESC "passage")
+ (SYNONYM PASSAGE CORRIDOR EXIT TUNNEL)
+ (ADJECTIVE LONG DARK STEAM)
+ (ACTION CORRIDOR-F)>
+
+<ROUTINE CORRIDOR-F ()
+ <COND (<VERB? THROUGH WALK-TO>
+ <V-WALK-AROUND>)
+ (<AND <VERB? FOLLOW CLIMB-DOWN>
+ <HERE? ,YUGGOTH ,BOWL-ROOM ,PLATFORM-ROOM>>
+ <DO-WALK ,P?DOWN>)
+ (<VERB? CLIMB-DOWN>
+ <COND (<HERE? ,DEAD-STORAGE>
+ <DO-WALK ,P?EAST>)>)>>
+
+;<OBJECT LOCAL-WATER
+ (SYNONYM WATER)
+ (ADJECTIVE FRESH SALT SEA)
+ (DESC "water")
+ (FLAGS NOABIT)
+ (ACTION WATER-F)>
+
+;<OBJECT WATER
+ (IN LOCAL-GLOBALS)
+ (SYNONYM WATER)
+ (DESC "water")
+ (FLAGS NDESCBIT NOABIT)
+ (ACTION WATER-F)>
+
+;<ROUTINE WATER-F ()
+ <COND (<P? (POUR THROW) ,LOCAL-WATER>
+ <COND (<AND <LOC ,PRSO>
+ <IN? <LOC ,PRSO> ,WINNER>>
+ <PERFORM ,V?POUR <LOC ,PRSO>>
+ <RTRUE>)
+ (ELSE
+ <DONT-HAVE-THAT>)>)
+ (<VERB? EAT DRINK DRINK-FROM>
+ <COND (<PRSO? ,LOCAL-WATER>
+ <COND (<IN? <LOC ,PRSO> ,WINNER>
+ <COND (<FSET? <LOC ,PRSO> ,OPENBIT>
+ <REMOVE ,PRSO>)
+ (ELSE
+ <TELL-OPEN-CLOSED <LOC ,PRSO>>
+ <RTRUE>)>)
+ (<NOT <GLOBAL-IN? ,WATER ,HERE>>
+ <TELL ,YOU-DONT-HAVE THE <LOC ,PRSO> ,PERIOD>
+ <RTRUE>)>)>
+ <COND (<OR <AND <PRSO? ,LOCAL-WATER>
+ <FSET? ,PRSO ,RMUNGBIT>>
+ ;<AND <PRSO? ,WATER>
+ <HERE? ;"ROOM WITH WATER">>>
+ <TELL
+"It's bitter and you spit it out immediately.">)
+ (ELSE
+ <TELL
+"That was refreshing, but you shouldn't drink untested water.">)>
+ <CRLF>)
+ (<VERB? REACH-IN RUB>
+ <TELL
+"It's wet." CR>)
+ (<VERB? LOOK-INSIDE LOOK-UNDER>
+ <MAKE-OUT>)
+ ;(<VERB? THROUGH LEAP>
+ <COND (<FSET? ,HERE ,RWATERBIT>
+ <TELL ,YOU-ARE ,PERIOD>)>)>>
+
+<ROUTINE RANDOM-PSEUDO ()
+ <COND (<AND <EQUAL? ,P-PNAM ,W?SHAFT>
+ <VERB? EXAMINE LOOK-UP>>
+ <LIKE-A-SHAFT>)
+ (<AND <EQUAL? ,P-PNAM ,W?TRIANGLE>
+ <VERB? EXAMINE>>
+ <TELL
+"It's \"Floppy Triangles,\" a work of modern sculpture." CR>)
+ (<VERB? EXAMINE LOOK-INSIDE LOOK-BEHIND>
+ <TELL S "You see nothing special about " "it." CR>)
+ (<VERB? TAKE>
+ <YOU-CANT-X-THAT "take">)>>
+
+"sleep, hunger, etc."
+
+;<GLOBAL LAST-SLEPT 40> ;"move when you last woke-up, for purposed of V-TIME"
+
+<OBJECT GLOBAL-SLEEP
+ (IN GLOBAL-OBJECTS)
+ (DESC "sleep")
+ (SYNONYM SLEEP NAP)
+ (FLAGS NOABIT NOTHEBIT)
+ (ACTION GLOBAL-SLEEP-F)>
+
+<ROUTINE GLOBAL-SLEEP-F ()
+ <COND (<VERB? WALK-TO TAKE>
+ <NEW-VERB ,V?SLEEP>
+ <RTRUE>)
+ (<VERB? FIND>
+ <TELL "Sleep anywhere." CR>)>>
+
+<OBJECT NOISE
+ (IN GLOBAL-OBJECTS)
+ (DESC "noise")
+ (SYNONYM NOISE SOUND)>
+
+<OBJECT SNOW
+ (IN GLOBAL-OBJECTS)
+ (DESC "snow")
+ (SYNONYM SNOW SNOWSTORM BLIZZARD)
+ (ACTION SNOW-F)>
+
+<ROUTINE SNOW-F ()
+ <COND (<VERB? EXAMINE>
+ <COND (<FSET? ,HERE ,OUTSIDE>
+ <TELL "It's still coming down." CR>)
+ (ELSE <TELL "You are inside." CR>)>)>>
diff --git a/green.zil b/green.zil
new file mode 100644
index 0000000..bfcf5ba
--- /dev/null
+++ b/green.zil
@@ -0,0 +1,659 @@
+"BROWN for
+ Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+<ROOM BROWN-BUILDING
+ (IN ROOMS)
+ (DESC "Brown Building")
+ (UP TO BROWN-TOP-FLOOR)
+ (DOWN TO BROWN-BASEMENT)
+ (SOUTH TO COURTYARD)
+ (OUT TO COURTYARD)
+ (FLAGS ONBIT)
+ (GLOBAL OUTSIDE-DOOR)
+ (ACTION BROWN-BUILDING-F)>
+
+<OBJECT BROWN-ELEVATOR
+ (IN BROWN-BUILDING)
+ (DESC "elevator doors")
+ (SYNONYM DOOR DOORS ELEVATOR)
+ (ADJECTIVE ELEVATOR)
+ (FLAGS NDESCBIT)
+ (ACTION BROWN-ELEVATOR-F)>
+
+<ROUTINE BROWN-ELEVATOR-F ()
+ <COND (<VERB? OPEN PRY WEDGE>
+ <TELL
+"It's broken." CR>)>>
+
+<GLOBAL THE-LOBBY "This is the lobby of the ">
+
+<ROUTINE BROWN-BUILDING-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+,THE-LOBBY "Brown Building, an eighteen-story skyscraper
+which houses the Meteorology Department and other outposts of the
+Earth Sciences. The elevator is out of order, but a long stairway leads up
+to the roof, and another leads
+down to the basement. A revolving door leads out into the night." CR>)>>
+
+<ROOM COURTYARD
+ (IN ROOMS)
+ (DESC "Small Courtyard")
+ (LDESC
+"This courtyard is a triumph of modern architecture. It is spare,
+cold, angular, overwhelming in size, and bears a striking resemblance
+to a wind tunnel whenever the breeze picks up. Right now this is true
+of the whole campus, though. A huge mass lurks nearby, and an almost
+featureless skyscraper is to the north.")
+ (IN TO BROWN-BUILDING)
+ (NORTH TO BROWN-BUILDING)
+ (GLOBAL OUTSIDE-DOOR)
+ (FLAGS ONBIT OUTSIDE)
+ (ACTION COURTYARD-F)
+ (THINGS <PSEUDO (FLOPPY TRIANGLE RANDOM-PSEUDO)
+ (HUGE MASS RANDOM-PSEUDO)>)>
+
+<ROUTINE COURTYARD-F (RARG)
+ <COND ;(<RARG? LOOK>
+ <TELL
+ CR>)
+ (<RARG? ENTER>
+ <EXIT-TO-COLD>)
+ (<RARG? LEAVE>
+ <EXIT-FROM-COLD>)>>
+
+<OBJECT OUTSIDE-DOOR
+ (IN LOCAL-GLOBALS)
+ (DESC "outside door")
+ (SYNONYM DOOR)
+ (ADJECTIVE OUTSIDE)
+ (FLAGS DOORBIT LOCKED NDESCBIT OPENABLE)
+ (GENERIC GENERIC-DOOR-F)
+ (ACTION OUTSIDE-DOOR-F)>
+
+<ROUTINE OUTSIDE-DOOR-F ()
+ <COND (<FSET? ,HERE ,OUTSIDE>
+ <COND (<VERB? THROUGH>
+ <DO-WALK ,P?IN>)
+ (<HERE? ,MASS-AVE ,SMITH-ST ,COURTYARD ,CS-ROOF>
+ <COND (<VERB? OPEN>
+ <TELL
+"The door opens from this side." CR>)
+ (<P? UNLOCK * MASTER-KEY>
+ <TELL
+"The door is not keyed to this key." CR>)>)
+ (<VERB? OPEN UNLOCK>
+ <TELL
+"The door is securely locked." CR>)>)
+ (ELSE
+ <COND (<VERB? THROUGH>
+ <DO-WALK ,P?OUT>)
+ (<VERB? OPEN>
+ <TELL
+"You can open the door, but it shuts automatically immediately
+thereafter." CR>)>)>>
+
+<ROOM GREAT-COURT
+ (IN ROOMS)
+ (DESC "Great Court")
+ (LDESC
+"In the spring and summer, this cheery green court is a haven from
+classwork. Right now, the majestic buildings of the main campus are
+almost invisible in the howling blizzard. A locked door bars your
+way to the north.")
+ (NORTH "The door is locked.")
+ (FLAGS ONBIT OUTSIDE)
+ (GLOBAL OUTSIDE-DOOR)
+ (ACTION GREAT-COURT-F)>
+
+<ROUTINE GREAT-COURT-F (RARG)
+ <COND ;(<RARG? LOOK>
+ <TELL
+ CR>)
+ (<RARG? ENTER>
+ <AS-YOU-ENTER-LEAVE "leave">
+ <EXIT-TO-COLD>)
+ ;(<RARG? LEAVE>
+ <EXIT-FROM-COLD>)>>
+
+<ROUTINE AS-YOU-ENTER-LEAVE (EL)
+ <TELL
+"As you " .EL ", the door closes and locks behind you." CR CR>>
+
+<ROOM BROWN-BASEMENT
+ (IN ROOMS)
+ (DESC "Brown Basement")
+ (LDESC
+"This is a cluttered basement below the Brown Building. Discarded equipment
+nearly blocks an already narrow hallway that terminates in a stairway leading
+up. The passage itself continues northwest.")
+ (UP TO BROWN-BUILDING)
+ (NW TO BROWN-TUNNEL)
+ (FLAGS ONBIT)
+ ;(ACTION BROWN-BASEMENT-F)
+ (THINGS <PSEUDO (ELECTRIC EQUIPMENT RANDOM-PSEUDO)
+ (FILE CABINET RANDOM-PSEUDO)
+ (<> DETRITUS RANDOM-PSEUDO)>)>
+
+;<ROUTINE BROWN-BASEMENT-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+ CR>)>>
+
+<ROOM BROWN-TOP-FLOOR
+ (IN ROOMS)
+ (DESC "Top Floor")
+ (LDESC
+"This is the top of the stairway. A door leads out to the roof here, and
+you can hear the wind blowing beyond. There is a sign on the door.")
+ (DOWN TO BROWN-BUILDING)
+ (WEST TO BROWN-ROOF IF ROOF-DOOR IS OPEN)
+ (OUT TO BROWN-ROOF IF ROOF-DOOR IS OPEN)
+ (FLAGS ONBIT)
+ (GLOBAL ROOF-DOOR)
+ ;(ACTION BROWN-TOP-FLOOR-F)>
+
+;<ROUTINE BROWN-TOP-FLOOR-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+ CR>)>>
+
+<OBJECT ROOF-DOOR
+ (IN LOCAL-GLOBALS)
+ (DESC "roof door")
+ (SYNONYM DOOR)
+ (ADJECTIVE ROOF)
+ (FLAGS DOORBIT LOCKED NDESCBIT OPENABLE)
+ (ACTION ROOF-DOOR-F)>
+
+<ROUTINE ROOF-DOOR-F ()
+ <COND (<AND <VERB? OPEN>
+ <NOT <FSET? ,ROOF-DOOR ,LOCKED>>
+ <NOT <FSET? ,ROOF-DOOR ,OPENBIT>>>
+ <FSET ,ROOF-DOOR ,OPENBIT>
+ <TELL
+"You push the door open">
+ <COND (<HERE? ,BROWN-TOP-FLOOR>
+ <TELL
+", revealing a windswept, snow-covered roof. Frigid
+wind whips snow into your face">)>
+ <TELL "." CR>)
+ (<P? UNLOCK * MASTER-KEY>
+ <FCLEAR ,PRSO ,LOCKED>
+ <TELL ,DOOR-NOW-UNLOCKED>)
+ (<P? LOCK * MASTER-KEY>
+ <FSET ,PRSO ,LOCKED>
+ <TELL
+"The door is now locked." CR>)
+ (<VERB? THROUGH>
+ <COND (<HERE? ,BROWN-ROOF>
+ <DO-WALK ,P?IN>)
+ (ELSE
+ <DO-WALK ,P?OUT>)>)>>
+
+<OBJECT ROOF-DOOR-SIGN
+ (IN BROWN-TOP-FLOOR)
+ (DESC "sign")
+ (SYNONYM SIGN)
+ (FLAGS READBIT NDESCBIT)
+ (TEXT
+"It says \"NO ADMITTANCE!\" In smaller, hand-written letters below,
+it says \"This means you!\" and below that in different handwriting,
+it says \"Who, me?\"")>
+
+<ROOM BROWN-ROOF
+ (IN ROOMS)
+ (DESC "Skyscraper Roof")
+ (LDESC
+"A low parapet surrounds a small roof here. The air conditioning cooling
+tower and the small protrusion containing the stairs are dwarfed by a
+semitransparent dome which towers above you. The blowing snow obscures
+all detail of the city across the river to the south.")
+ (IN PER BROWN-ROOF-EXIT) ;BROWN-TOP-FLOOR
+ (EAST PER BROWN-ROOF-EXIT)
+ (UP TO INSIDE-DOME)
+ (FLAGS ONBIT OUTSIDE)
+ (GLOBAL ROOF-DOOR LADDER DOME)
+ (ACTION BROWN-ROOF-F)>
+
+<ROUTINE BROWN-ROOF-EXIT ()
+ <COND (<IN? ,FLIER ,HERE>
+ <TELL
+"The dark shape, its foul stench overpowering the wind, ">
+ <COND (<IN? ,FLIER-SHAPE ,HERE>
+ <REMOVE ,FLIER-SHAPE>
+ <SETG FLIER-COUNT 3>
+ <TELL "drops from the dome and ">)>
+ <TELL "blocks your escape." CR>
+ <RFALSE>)
+ (<FSET? ,ROOF-DOOR ,OPENBIT>
+ ,BROWN-TOP-FLOOR)
+ (ELSE
+ <TELL "The door leading inside is closed." CR>
+ <RFALSE>)>>
+
+<ROUTINE BROWN-ROOF-F (RARG)
+ <COND ;(<RARG? LOOK>
+ <TELL
+ CR>)
+ (<RARG? ENTER>
+ <EXIT-TO-COLD>)
+ (<RARG? LEAVE>
+ <EXIT-FROM-COLD>)
+ (<RARG? BEG>
+ <ROOF-BEGS>)>>
+
+<ROUTINE ROOF-BEGS ()
+ <COND (<P? EXAMINE CEILING>
+ <TELL "It's made of ">
+ <COND (<HERE? ,ON-DOME>
+ <TELL "concrete." CR>)
+ (ELSE
+ <TELL "tiny, tarry cinders." CR>)>)
+ (<P? THROW-OFF * CEILING>
+ <COND (<AND <PRSO? SMOOTH-STONE>
+ <IN? ,FLIER ,HERE>>
+ <PERFORM ,V?ATTACK ,FLIER ,SMOOTH-STONE>
+ <RTRUE>)
+ (ELSE
+ <COND (<HERE? ,BROWN-ROOF>
+ <MOVE ,PRSO ,COURTYARD>)
+ (ELSE <REMOVE ,PRSO>)>
+ <OBJ-OFF-ROOF ,PRSO>)>)
+ (<VERB? LEAP>
+ <COND (<IN? ,FLIER ,HERE>
+ <TELL
+"The creature sees you preparing to leap, and springs toward you in a
+desperate effort, blood-red mouth contorted with a cry of frustration,
+but it's too late." CR>)>
+ <JIGS-UP
+"You leap over the edge. Freezing ice crystals hitting you in the face
+as you fall. Then you hit the ground, which is more unpleasant still.">)>>
+
+<OBJECT DOME
+ (IN LOCAL-GLOBALS)
+ (DESC "dome")
+ (SYNONYM DOME)
+ (ADJECTIVE LARGE WEATHER GREAT)
+ (FLAGS NDESCBIT)
+ (ACTION DOME-F)>
+
+<ROUTINE DOME-F ()
+ <COND (<VERB? THROUGH CLIMB-FOO>
+ <DO-WALK ,P?UP>)
+ (<HERE? ,BROWN-ROOF>
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The dome is large and semitransparent. It's made of some sort of
+milky-colored plastic. It dominates the roof. You can climb up to the
+entrance via a short ladder." CR>)>)
+ (ELSE
+ <COND (<VERB? LEAP>
+ <JIGS-UP
+"It was a long way down. It was quick, though.">)>)>>
+
+<ROOM INSIDE-DOME
+ (IN ROOMS)
+ (DESC "Inside Dome")
+ (LDESC
+"You are inside a large domed area. The dome contains equipment that
+makes it clear it is a weather observation station. For some reason,
+it also contains a small peach tree. Wind whistles outside, and snow
+blasts against the semitransparent material of the dome.")
+ (DOWN PER INSIDE-DOME-EXIT) ;BROWN-ROOF
+ (OUT PER INSIDE-DOME-EXIT)
+ (FLAGS ONBIT)
+ (GLOBAL GLOBAL-HOLE LADDER)
+ (ACTION INSIDE-DOME-F)
+ (THINGS
+ <PSEUDO (<> EQUIPMENT RANDOM-PSEUDO)
+ (<> DOME RANDOM-PSEUDO)>)>
+
+<ROUTINE INSIDE-DOME-EXIT ()
+ <COND (<IN? ,FLIER ,HERE>
+ <TELL
+"The creature is blocking your exit." CR>
+ <RFALSE>)
+ (ELSE
+ ,BROWN-ROOF)>>
+
+<ROUTINE INSIDE-DOME-F (RARG)
+ <COND ;(<RARG? LOOK>
+ <TELL
+ CR>)
+ (<RARG? ENTER>
+ <COND (<AND <ZERO? ,FLIER-COUNT>
+ <HELD? ,SMOOTH-STONE>>
+ <QUEUE I-FLIER -1>)>)
+ (<RARG? BEG>
+ <COND (<P? (DIG SEARCH) DIRT>
+ <NEW-PRSO ,TUB>
+ <RTRUE>)>)
+ (<RARG? END>
+ <COND (<AND <ZERO? ,FLIER-COUNT>
+ <HELD? ,HAND>>
+ <QUEUE I-FLIER -1>)>)>>
+
+<GLOBAL FLIER-COUNT 0>
+
+<ROUTINE I-FLIER ()
+ <COND (<AND <NOT <ZERO? ,FLIER-COUNT>>
+ <IN? ,FLIER ,GLOBAL-OBJECTS>>
+ <DEQUEUE I-FLIER>
+ <RFALSE>)>
+ <SETG FLIER-COUNT <+ ,FLIER-COUNT 1>>
+ <QUEUE I-FLIER -1>
+ <COND (<HERE? ,INSIDE-DOME>
+ <COND (<EQUAL? ,FLIER-COUNT 1>
+ <MOVE ,FLIER-SHAPE ,HERE>
+ <MOVE ,FLIER ,BROWN-ROOF>
+ <TELL CR
+"Something smashes against the glass of the dome! You turn
+and see a dark shape clinging to the outside of the structure." CR>)
+ (<EQUAL? ,FLIER-COUNT 2>
+ <TELL CR ,SHAPE-TWITCHES CR>)
+ (<EQUAL? ,FLIER-COUNT 3>
+ <REMOVE ,FLIER-SHAPE>
+ <TELL CR
+"The shape drops out of view." CR>)
+ (<EQUAL? ,FLIER-COUNT 4>
+ <TELL CR
+"You hear, on the ladder outside, hard claws painfully
+climbing towards the dome entrance." CR>)
+ (<AND <G=? ,FLIER-COUNT 5>
+ <NOT <IN? ,FLIER ,HERE>>>
+ <MOVE ,FLIER ,HERE>
+ <TELL CR
+"The creature enters the dome, screaming viciously at you, its
+claws reaching out to grasp and rend." CR>)
+ (ELSE
+ <FLIER-EATS-HAND?>)>)
+ (<HERE? ,BROWN-ROOF>
+ <COND (<EQUAL? ,FLIER-COUNT 1>
+ <MOVE ,FLIER-SHAPE ,INSIDE-DOME>
+ <MOVE ,FLIER ,BROWN-ROOF>
+ <TELL CR
+"You hear a strange confusion of wings, and then something
+dark and shapeless smashes against the dome above you!" CR>)
+ (<EQUAL? ,FLIER-COUNT 2>
+ <TELL CR ,SHAPE-TWITCHES CR>)
+ (<EQUAL? ,FLIER-COUNT 3>
+ <REMOVE ,FLIER-SHAPE>
+ <TELL CR
+"The shape drops, crunching into the snow almost next to you.
+Its scaly head turns toward you, eyes like coals
+staring into yours." CR>)
+ (<EQUAL? ,FLIER-COUNT 4>
+ <TELL CR
+"The shape rises, baring needle-sharp teeth and pumping its
+wings painfully in the gale." CR>)
+ (<EQUAL? ,FLIER-COUNT 5>
+ <TELL CR
+"The creature approaches, hissing at you as it nears." CR>)
+ (ELSE <FLIER-EATS-HAND?>)>)>>
+
+<GLOBAL SHAPE-TWITCHES
+"The dark shape moves. Above the howl of the wind you
+hear a high-pitched keening noise.">
+
+<ROUTINE FLIER-EATS-HAND? ("OPT" (NOCR? <>))
+ <COND (<AND <IN? ,FLIER ,HERE>
+ <OR .NOCR?
+ <IN? ,HAND ,PLAYER>
+ <IN? ,HAND ,HERE>>>
+ <MOVE ,FLIER ,GLOBAL-OBJECTS>
+ <COND (<NOT .NOCR?> <CRLF>)>
+ <TELL
+"In a snake-like strike, the creature ">
+ <COND (<IN? ,HAND ,WINNER>
+ <TELL
+"attacks! Its toothy jaws close on your hand! Not your hand, but the ">)
+ (ELSE
+ <TELL
+"snaps at the ">)>
+ <REMOVE ,HAND>
+ <COND (<NOT <FSET? ,HAND ,PERSON>>
+ <TELL "mummified ">)>
+ <TELL "hand you dug out of the
+tub! With a disgusting gobbling noise, the flier swallows the hand, and
+then, ">
+ <COND (<HERE? ,BROWN-ROOF>
+ <TELL
+"its wings beating feebly against the wind, it sails away into the gale.">)
+ (ELSE
+ <TELL
+"using its wings to push itself away, it scuttles out into the cold and
+away.">)>
+ <CRLF>)>>
+
+<OBJECT FLIER-SHAPE
+ (DESC "dark shape")
+ (SYNONYM SHAPE FLIER THING)
+ (ADJECTIVE DARK SHAPELESS)
+ (FLAGS NDESCBIT)
+ (ACTION FLIER-SHAPE-F)>
+
+<ROUTINE FLIER-SHAPE-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+,YOU-CANT "tell much from here. It's large and dark,
+but the dome obscures all detail." CR>)>>
+
+<OBJECT FLIER
+ (DESC "creature")
+ (SYNONYM SHAPE FLIER CREATURE)
+ (ADJECTIVE DARK)
+ (DESCFCN FLIER-DESC)
+ (GENERIC GENERIC-CREATURE-F)
+ (VALUE 5)
+ (ACTION FLIER-F)>
+
+<ROUTINE FLIER-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <TELL
+"A dark shape watches balefully from nearby.">)>>
+
+<ROUTINE FLIER-F ()
+ <COND (<IN? ,FLIER ,GLOBAL-OBJECTS>
+ <COND (<NOT <ABSTRACT-VERB?>>
+ <TELL
+"The creature has disappeared as though it never was." CR>)>)
+ (<VERB? EXAMINE>
+ <TELL
+"Like a black sheet flapping in the wind, the dark flier is hard to see.
+Red eyes glow like coals on its scaly, bullet-shaped head. Human-like
+hands clench and unclench. Sharp needles of teeth project wickedly from
+its twisted jaw." CR>)
+ (<VERB? SMELL>
+ <TELL
+"Its stench is that of a foul eater of carrion, overlaid with another
+smell you can't place, but which is even less appetizing." CR>)
+ (<AND <VERB? ATTACK KILL> <NOT <PRSI? ,SMOOTH-STONE>>>
+ <TELL
+"Hissing and screeching, the creature fends off your attack. Its
+head jerks from side to side, watching you." CR>)
+ (<VERB? GIVE>
+ <COND (<PRSO? ,HAND>
+ <FLIER-EATS-HAND? T>)
+ (<PRSO? ,SMOOTH-STONE>
+ <TELL
+CTHE ,PRSI " edges away." CR>)>)
+ (<AND <P? (THROW POUR) * FLIER>
+ <NOT <PRSO? ,SMOOTH-STONE ,ELIXIR>>>
+ <MOVE ,PRSO ,HERE>
+ <TELL
+"The creature darts to the side, dodging " THE ,PRSO ,PERIOD>)>>
+
+<OBJECT PEACH-TREE
+ (IN INSIDE-DOME)
+ (DESC "peach tree")
+ (SYNONYM TREE)
+ (ADJECTIVE PEACH)
+ (FLAGS NDESCBIT)
+ (ACTION PEACH-TREE-F)>
+
+<ROUTINE PEACH-TREE-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a small peach tree planted in a very large tub of
+earth. It appears healthy, although as it is wintertime, the tree
+has no leaves." CR>)
+ (<VERB? RUB>
+ <TELL
+"It feels like wood, but there is something slippery on it higher up." CR>)
+ (<P? (ATTACK CUT) * AXE>
+ <TELL
+"At the last second, you realize it would be an unspeakable act of
+vandalism." CR>)
+ (<VERB? SHAKE>
+ <TELL
+"You shake it, but nothing drops. Its branches are bare." CR>)
+ (<VERB? CLIMB-ON CLIMB-UP CLIMB-FOO>
+ <TELL
+S "You start to climb " "the tree, but
+as you get partway up, your hands encounter a slippery substance
+which covers the limbs at this height. Not only is it extremely unpleasant
+to touch, it makes the tree too slippery to climb any further." CR>)>>
+
+<OBJECT TUB
+ (IN INSIDE-DOME)
+ (DESC "tub of dirt")
+ (SYNONYM TUB DIRT EARTH)
+ (ADJECTIVE WOODEN LARGE)
+ (FLAGS NDESCBIT CONTBIT OPENBIT SEARCHBIT)
+ (CAPACITY 30)
+ (ACTION TUB-F)>
+
+<ROUTINE TUB-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The tub is full of dirt and \"condo chips\" (those pine bark
+chips that are spread around condos and shopping centers by the
+ton). The dirt has been disturbed recently." CR>)
+ (<VERB? DIG SEARCH LOOK-INSIDE>
+ <COND (<NOT <FSET? ,HAND ,TOUCHBIT>>
+ <FSET ,HAND ,TOUCHBIT>
+ <MOVE ,HAND ,TUB>
+ <SCORE-OBJECT ,HAND>
+ <TELL
+S "You root around ""in the dirt for a while, when you encounter something
+hard. Further exploration reveals it to be a dried, chewed
+looking human hand." CR>)
+ (ELSE
+ <TELL
+,YOU-FIND-NOTHING " further, which is something of a relief." CR>)>)>>
+
+<OBJECT TATTOO
+ (IN HAND)
+ (DESC "tattoo")
+ (SYNONYM TATTOO SYMBOL)
+ (ADJECTIVE STRANGE)
+ (FLAGS NDESCBIT)
+ (SIZE 0)
+ (GENERIC GENERIC-SYMBOL-F)
+ (ACTION TATTOO-F)>
+
+<ROUTINE TATTOO-F ()
+ <COND (<VERB? EXAMINE READ>
+ <TELL
+"The tattoo is old and faded. It was done in red ink and is very
+artistically drawn. ">
+ <TELL-SYMBOL ,HAND>
+ <CRLF>)
+ (<VERB? RUB>
+ <TELL
+"This part of the hand feels particularly cold." CR>)>>
+
+<OBJECT HAND
+ (DESC "human hand")
+ (SYNONYM HAND)
+ (ADJECTIVE DEAD MUMMIFIED HUMAN)
+ (VALUE 5)
+ (HEAT 0)
+ (FLAGS TAKEBIT SEARCHBIT OPENBIT CONTBIT)
+ (GENERIC GENERIC-HAND-F)
+ (CONTFCN HAND-F)
+ (ACTION HAND-F)>
+
+<ROUTINE HAND-F ("OPT" (RARG <>))
+ <COND (<RARG? CONTAINER>
+ <COND (<FSET? ,HAND ,PERSON>
+ <COND (<VERB? WEAR>
+ <TAKE-OUT-FIRST ,PRSO ,HAND>)
+ (<OR <NOT <VERB? TAKE>>
+ <NOT <HELD? ,HAND>>>
+ <NEW-PRSO ,HAND>)>)>)
+ (<WINNER? ,HAND>
+ <TELL
+"As you speak, the hand sits still, but there is
+no other noticeable result." CR>
+ <END-QUOTE>)
+ (<VERB? EXAMINE>
+ <COND (<FSET? ,HAND ,PERSON>
+ <TELL
+"There are stains, scars, ">
+ <COND (<IN? ,RING ,HAND>
+ <TELL A ,RING ", ">)>
+ <TELL "and a tattoo on the hand. ">
+ <COND (,LAIR-FLAG
+ <COND (<HELD? ,HAND>
+ <HAND-POINTS>)
+ (ELSE
+ <TELL
+"It's splashing in" ,THE-POOL>)>)
+ (ELSE
+ <TELL
+"It looks perfectly normal and alive, ignoring the fact that there
+is no arm attached to it. It doesn't appear to mind, so why should you?" CR>)>)
+ (ELSE
+ <TELL
+"The hand is very old. It's dry and very light, mummified in fact. There
+are stains, scars, and dried blood on it. There is a tattoo on the back
+of it. The hand appears to have been severed by the application of very
+sharp teeth, perhaps an animal's." CR>)>)
+ (<AND <PRSO? ,HAND>
+ <OR <VERB? TAKE PUT THROW>
+ <P? RUB * HAND>
+ <HOSTILE-VERB?>>
+ <FSET? ,HAND ,PERSON>>
+ <COND (<HERE? ,INNER-LAIR>
+ <TELL
+CTHE ,HAND ", muddy and wet, wiggles out of your grasp." CR>)
+ (<IN? ,HAND ,PLAYER>
+ <TELL
+CTHE ,HAND " scuttles away to your other shoulder." CR>)>)
+ (<P? PUT-ON RING HAND>
+ <COND (<FSET? ,HAND ,PERSON>
+ <FCLEAR ,RING ,WEARBIT>
+ <MOVE ,RING ,HAND>
+ <TELL
+"The ring fits the hand perfectly." CR>)
+ (ELSE
+ <TELL
+,YOU-CANT "get the ring onto the dry flesh of the hand." CR>)>)
+ (<P? (GIVE SHOW) * HAND>
+ <COND (<FSET? ,HAND ,PERSON>
+ <TELL "The hand ">
+ <COND (<IN? ,HAND ,VAT>
+ <TELL "is preoccupied." CR>)
+ (<FSET? ,PRSO ,PERSON>
+ <TELL "doesn't react." CR>)
+ (ELSE
+ <TELL
+"scurries to " THE ,PRSO " and touches it all over, much as a
+blind person would examine something." CR>)>)>)
+ (<P? RUB ,HAND>
+ <COND (<NOT <HELD? ,HAND>>
+ <NOT-HOLDING ,HAND>)
+ (<FSET? ,HAND ,PERSON>
+ <TELL
+"It's warm and dry." CR>)
+ (ELSE
+ <TELL
+"It's dry and cold. In fact, it's mummified." CR>)>)
+ (<AND <VERB? FOLLOW>
+ <HERE? ,INNER-LAIR>>
+ <TELL
+"The pool isn't that deep!" CR>)>>
diff --git a/h1.zil b/h1.zil
new file mode 100644
index 0000000..b08d85a
--- /dev/null
+++ b/h1.zil
@@ -0,0 +1,35 @@
+"H for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+<SNAME "H1">
+
+<PRINC "
+*** The Lurking Horror: Interactive Horror ***
+">
+
+<VERSION ZIP> ;"maybe ezip or xzip someday"
+<FREQUENT-WORDS?> ;"include frequent words"
+;<LONG-WORDS?> ;"make a table of long words"
+<SETG ZDEBUGGING? <>> ;"don't include debugging code"
+<SETG NEW-VOC? T> ;"allows words to be adj/noun/verb all at once!"
+<SET REDEFINE T> ;"don't stop and ask"
+
+<INSERT-FILE "MISC">
+<INSERT-FILE "PARSER">
+<INSERT-FILE "SYNTAX">
+<INSERT-FILE "DEBUG">
+<INSERT-FILE "RECORD">
+<INSERT-FILE "INTERRUPTS">
+<INSERT-FILE "DESC">
+<INSERT-FILE "VERBS">
+<INSERT-FILE "GLOBALS">
+<INSERT-FILE "CS">
+<INSERT-FILE "HACKER">
+<INSERT-FILE "PC">
+<INSERT-FILE "YUGGOTH">
+<INSERT-FILE "GREEN">
+<INSERT-FILE "FROB">
+
+<PROPDEF SIZE 5>
+<PROPDEF CAPACITY 0>
diff --git a/h1.zip b/h1.zip
new file mode 100644
index 0000000..a03dd60
--- /dev/null
+++ b/h1.zip
Binary files differ
diff --git a/h1freq.xzap b/h1freq.xzap
new file mode 100644
index 0000000..effeacc
--- /dev/null
+++ b/h1freq.xzap
@@ -0,0 +1,200 @@
+ .FSTR FSTR?1,"the " ;2376 1189
+ .FSTR FSTR?2,"The " ;1167 390
+ .FSTR FSTR?3,", " ;1157 1158
+ .FSTR FSTR?4,"You " ;954 319
+ .FSTR FSTR?5,"and " ;928 465
+ .FSTR FSTR?6,". " ;741 742
+ .FSTR FSTR?7,"It's " ;610 123
+ .FSTR FSTR?8,"you " ;598 300
+ .FSTR FSTR?9,"is " ;493 494
+ .FSTR FSTR?10,"your " ;486 163
+ .FSTR FSTR?11,"of " ;469 470
+ .FSTR FSTR?12,"to " ;426 427
+ .FSTR FSTR?13,"There " ;410 83
+ .FSTR FSTR?14,"with " ;378 127
+ .FSTR FSTR?15,"that " ;321 108
+ .FSTR FSTR?16,"are " ;306 154
+ .FSTR FSTR?17,"This " ;300 76
+ .FSTR FSTR?18,"something " ;296 38
+ .FSTR FSTR?19,"from " ;279 94
+ .FSTR FSTR?20,"into " ;273 92
+ .FSTR FSTR?21,"It " ;272 137
+ .FSTR FSTR?22,"in " ;251 252
+ .FSTR FSTR?23,"but " ;248 125
+ .FSTR FSTR?24,"through " ;222 38
+ .FSTR FSTR?25,"like " ;213 72
+ .FSTR FSTR?26,"can't " ;210 43
+ .FSTR FSTR?27,"doesn't " ;210 31
+ .FSTR FSTR?28,"elevator " ;189 28
+ .FSTR FSTR?29,"it " ;181 182
+ .FSTR FSTR?30,"don't " ;180 37
+ .FSTR FSTR?31,"almost " ;180 37
+ .FSTR FSTR?32,"already " ;180 31
+ .FSTR FSTR?33,"around " ;170 35
+ .FSTR FSTR?34,"appears " ;168 29
+ .FSTR FSTR?35,"have " ;162 55
+ .FSTR FSTR?36,"floor " ;160 41
+ .FSTR FSTR?37,"He " ;156 79
+ .FSTR FSTR?38,"it's " ;156 40
+ .FSTR FSTR?39,"looks " ;144 37
+ .FSTR FSTR?40,"which " ;140 36
+ .FSTR FSTR?41,"this " ;135 46
+ .FSTR FSTR?42,"on " ;133 134
+ .FSTR FSTR?43,"here" ;132 67
+ .FSTR FSTR?44,"for " ;132 67
+ .FSTR FSTR?45,"hacker " ;125 26
+ .FSTR FSTR?46,"about " ;124 32
+ .FSTR FSTR?47,"very " ;123 42
+ .FSTR FSTR?48,"out " ;120 61
+ .FSTR FSTR?49,"more " ;117 40
+ .FSTR FSTR?50,"chain " ;112 29
+ .FSTR FSTR?51,"some " ;111 38
+ .FSTR FSTR?52,"see " ;108 55
+ .FSTR FSTR?53,"other " ;108 28
+ .FSTR FSTR?54,"leads " ;108 28
+ .FSTR FSTR?55,"over " ;105 36
+ .FSTR FSTR?56,"floor" ;105 36
+ .FSTR FSTR?57,"isn't " ;105 22
+ .FSTR FSTR?58,"creature " ;105 16
+ .FSTR FSTR?59,"They " ;104 27
+ .FSTR FSTR?60,"revealing " ;104 14
+ .FSTR FSTR?61,"There's " ;104 14
+ .FSTR FSTR?62,"one " ;102 52
+ .FSTR FSTR?63,"can " ;102 52
+ .FSTR FSTR?64,"not " ;100 51
+ .FSTR FSTR?65,"tunnel " ;100 21
+ .FSTR FSTR?66,"anything " ;98 15
+ .FSTR FSTR?67,"all " ;96 49
+ .FSTR FSTR?68,"only " ;96 33
+ .FSTR FSTR?69,"door " ;96 33
+ .FSTR FSTR?70,"small " ;96 25
+ .FSTR FSTR?71,"covered " ;96 17
+ .FSTR FSTR?72,"little " ;95 20
+ .FSTR FSTR?73,"ladder " ;95 20
+ .FSTR FSTR?74,"begins " ;95 20
+ .FSTR FSTR?75,"Tunnel" ;95 20
+ .FSTR FSTR?76,"has " ;94 48
+ .FSTR FSTR?77,"open " ;93 32
+ .FSTR FSTR?78,"just " ;93 32
+ .FSTR FSTR?79,"as " ;92 93
+ .FSTR FSTR?80,"Your " ;92 24
+ .FSTR FSTR?81,"you" ;91 92
+ .FSTR FSTR?82,"nothing " ;90 16
+ .FSTR FSTR?83,"holding " ;90 16
+ .FSTR FSTR?84,"maintenance " ;90 10
+ .FSTR FSTR?85,"at " ;89 90
+ .FSTR FSTR?86,"there " ;88 23
+ .FSTR FSTR?87,"continues " ;88 12
+ .FSTR FSTR?88,"get " ;86 44
+ .FSTR FSTR?89,"then " ;84 29
+ .FSTR FSTR?90,"looking " ;84 15
+ .FSTR FSTR?91,"You're " ;84 13
+ .FSTR FSTR?92,"what " ;81 28
+ .FSTR FSTR?93,"its " ;80 41
+ .FSTR FSTR?94,"metal " ;80 21
+ .FSTR FSTR?95,"Department " ;80 9
+ .FSTR FSTR?96,"been " ;78 27
+
+
+;word frequency table of 96 most common words
+
+WORDS:: .TABLE
+ FSTR?1
+ FSTR?2
+ FSTR?3
+ FSTR?4
+ FSTR?5
+ FSTR?6
+ FSTR?7
+ FSTR?8
+ FSTR?9
+ FSTR?10
+ FSTR?11
+ FSTR?12
+ FSTR?13
+ FSTR?14
+ FSTR?15
+ FSTR?16
+ FSTR?17
+ FSTR?18
+ FSTR?19
+ FSTR?20
+ FSTR?21
+ FSTR?22
+ FSTR?23
+ FSTR?24
+ FSTR?25
+ FSTR?26
+ FSTR?27
+ FSTR?28
+ FSTR?29
+ FSTR?30
+ FSTR?31
+ FSTR?32
+ FSTR?33
+ FSTR?34
+ FSTR?35
+ FSTR?36
+ FSTR?37
+ FSTR?38
+ FSTR?39
+ FSTR?40
+ FSTR?41
+ FSTR?42
+ FSTR?43
+ FSTR?44
+ FSTR?45
+ FSTR?46
+ FSTR?47
+ FSTR?48
+ FSTR?49
+ FSTR?50
+ FSTR?51
+ FSTR?52
+ FSTR?53
+ FSTR?54
+ FSTR?55
+ FSTR?56
+ FSTR?57
+ FSTR?58
+ FSTR?59
+ FSTR?60
+ FSTR?61
+ FSTR?62
+ FSTR?63
+ FSTR?64
+ FSTR?65
+ FSTR?66
+ FSTR?67
+ FSTR?68
+ FSTR?69
+ FSTR?70
+ FSTR?71
+ FSTR?72
+ FSTR?73
+ FSTR?74
+ FSTR?75
+ FSTR?76
+ FSTR?77
+ FSTR?78
+ FSTR?79
+ FSTR?80
+ FSTR?81
+ FSTR?82
+ FSTR?83
+ FSTR?84
+ FSTR?85
+ FSTR?86
+ FSTR?87
+ FSTR?88
+ FSTR?89
+ FSTR?90
+ FSTR?91
+ FSTR?92
+ FSTR?93
+ FSTR?94
+ FSTR?95
+ FSTR?96
+ .ENDT
+
+ .ENDI
diff --git a/hacker.zil b/hacker.zil
new file mode 100644
index 0000000..2b456f6
--- /dev/null
+++ b/hacker.zil
@@ -0,0 +1,950 @@
+"HACKER for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+<OBJECT HACKER
+ (IN TERMINAL-ROOM)
+ (DESC "hacker")
+ (SYNONYM HACKER YOURSELF)
+ (FLAGS SEARCHBIT PERSON OPENBIT CONTBIT)
+ (DESCFCN HACKER-DESC)
+ (CONTFCN HACKER-F)
+ (ACTION HACKER-F)>
+
+<ROUTINE HACKER-DESC ("OPT" RARG OBJ)
+ <COND (<RARG? OBJDESC?> <RTRUE>)
+ (ELSE
+ <COND (<HERE? ,TERMINAL-ROOM>
+ <TELL
+"Sitting at a terminal is a hacker whom you recognize.">)
+ (ELSE
+ <TELL
+"A muddy, scratched-up hacker stands tiredly here.">)>
+ <RFATAL>)>>
+
+<GLOBAL TOTALLY-UNRESPONSIVE "He is totally unresponsive.|">
+
+<ROUTINE HACKER-F ("OPT" (RARG <>) "AUX" H)
+ <COND (<RARG? CONTAINER>
+ <COND (<VERB? TAKE MOVE>
+ <COND (<G? ,LAIR-CNT 6>
+ <TELL
+"You don't want to get that close to him." CR>)
+ (ELSE
+ <TELL
+"\"Hey! No snarfage, loser!\" You determine that this means, \"Stop!\"" CR>)>)>)
+ (<WINNER? ,HACKER>
+ <COND (<G? ,LAIR-CNT 6>
+ <TELL
+"The hacker replies, \"Meld!\"" CR>)
+ (<VERB? HELP>
+ <COND (<HERE? ,TERMINAL-ROOM>
+ <TELL "\"Be patient!\"" CR>)
+ (<FSET? ,SMOOTH-STONE ,TOUCHBIT>
+ <PERFORM ,V?TELL-ME-ABOUT ,PROGRAM>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"\"Help? I'm not a T.A. I've got work to do.\"" CR>)>)
+ (<P? WHO LOVECRAFT>
+ <NEW-VERB ,V?WHAT>
+ <RTRUE>)
+ (<VERB? TELL-ME-ABOUT WHAT>
+ <COND (<PRSO? ,HACKER>
+ <TELL
+"He's reluctant to boast." CR>)
+ (<PRSO? ,KEYRING ,KEY-1 ,KEY-2 ,KEY-3 ,KEY-4>
+ <COND (<GETPT ,MASTER-KEY ,P?VALUE>
+ <FSET ,MASTER-KEY ,TOUCHBIT>
+ <MOVE ,MASTER-KEY ,KEYRING>)>
+ <TELL
+"\"I've accumulated a few keys over the years. I'm a licensed locksmith,
+which helps. I can get into any room at Tech.\" He pulls the keyring
+out on its chain, and shows off a key you hadn't noticed before. \"This is
+a master key,\" he says." CR>)
+ (<PRSO? ,CHINESE-FOOD ,SNACK>
+ <TELL
+"\"Yeah! I'd love some yummy Chinese food. Szechuan style. Ummm!\"" CR>)
+ (<PRSO? ,MASTER-KEY>
+ <COND (<IN? ,MASTER-KEY ,GLOBAL-OBJECTS>
+ <TELL S
+"\"Who said anything about any master keys?\" he asks suspiciously.|">)
+ (ELSE
+ <THIS-IS-IT ,MASTER-KEY>
+ <TELL
+"\"That's one of my best keys. It's a Tech master key. Not that it really
+opens every door at Tech, but I'd say three out of five, at least. Naturally,
+some labs are off-limits even to this key.\"" CR>)>)
+ (<PRSO? ,STUDENTS>
+ <TELL
+"\"Missing students? I knew one of them slightly. Not the sort who would
+go away, you know? He was sort of hackeresque, not dumb for an undergrad,
+either. Not the type to disappear.\"" CR>)
+ (<PRSO? ,PROGRAM ,PC ,MENU-BOX ,YAK-WINDOW
+ ,HELP-KEY>
+ <COND (<ZERO? ,HACKER-HELP>
+ <TELL
+"\"You should consult the documentation.\" He's preoccupied with his
+own debugging." CR>)
+ (<QUEUED? I-HACKER-HELPS>
+ <TELL
+"\"I'm looking at it. Be patient. This isn't some little micro. We're
+on a hairy OS on a hairy net.\"" CR>)
+ (ELSE
+ <TELL
+"\"I already looked at it. The bug is fixed in the sources. Your paper
+is gone, unless those Alchemy chompers have a copy.\"" CR>)>)
+ (<PRSO? ,LOVECRAFT>
+ <TELL
+"\"Wasn't he a fantasy author?\"" CR>)
+ (<PRSO? ,SMOOTH-STONE>
+ <TELL
+"\"I've never seen one like that. Pretty tasteful, I'd say.\"" CR>)
+ (<PRSO? ,GLOBAL-URCHINS>
+ <TELL
+"\"There are always urchins around. I remember one or two who became
+hackers.\"" CR>)
+ (<PRSO? ,REPEATER ,INPUT-CABLE ,INPUT-SOCKET>
+ <TELL
+"\"I'll fix it!\"" CR>)
+ (ELSE
+ <TELL
+"The hacker studiously ignores you, loath to admit there is something he
+doesn't know about." CR>)>)
+ (<VERB? FOLLOW>
+ <COND (<HERE? ,INNER-LAIR>
+ <TELL "\"I'm here, aren't I?\"" CR>)
+ (ELSE
+ <TELL
+"\"I haven't got time. I have new versions of the system, the assembler,
+the editor, and the debugger to finish hacking.\"" CR>)>)
+ (<P? GIVE * ME>
+ <COND (<NOT <IN? ,CARTON ,HACKER>>
+ <QUEUE I-FOOD-HINT 2>)>
+ <COND (<PRSO? ,HELP-KEY>
+ <PERFORM ,V?HELP>
+ <RTRUE>)
+ (<PRSO? ,KEYRING>
+ <TELL
+"\"Well, I can't give you ">
+ <COND (<IN? ,CARTON ,HACKER>
+ <TELL "all ">)>
+ <TELL "my keys, I need them.\" He fondles his
+keyring proudly." CR>)
+ (<PRSO? ,MASTER-KEY>
+ <COND (<IN? ,MASTER-KEY ,GLOBAL-OBJECTS>
+ <TELL S
+"\"Who said anything about any master keys?\" he asks suspiciously.|">)
+ (<IN? ,CARTON ,HACKER>
+ <HACKER-LOANS-KEY>)
+ (ELSE
+ <TELL
+"\"Fat chance! This is a master key! What have you done for me
+lately?\"" CR>)>)
+ (<PRSO? ,KEY-1 ,KEY-2 ,KEY-3 ,KEY-4>
+ <TELL
+"\"Those are boring old keys. They don't open anything interesting.\"" CR>)
+ (ELSE
+ <TELL "\"I don't have that.\"" CR>)>)
+ (<VERB? TRADE>
+ <COND (<AND <PRSO? ,CHINESE-FOOD ,CARTON ,MASTER-KEY>
+ <PRSO? ,CHINESE-FOOD ,CARTON ,MASTER-KEY>>
+ <SETG HACKER-TRADE? T>
+ <TELL
+"\"You give me the food first.\"" CR>)
+ (ELSE
+ <TELL
+"\"That's not a good trade.\"" CR>)>)
+ (<VERB? HELLO>
+ <TELL
+"\"Greetingage.\"">
+ <COND (<HERE? ,TERMINAL-ROOM>
+ <TELL " He turns back to his hacking.">)>
+ <CRLF>)
+ (ELSE
+ <TELL "\"Mumble. Frotz.\"" CR>)>)
+ (<VERB? EXAMINE>
+ <COND (<HERE? ,INNER-LAIR>
+ <COND (<G? ,LAIR-CNT 6>
+ <TELL
+"He looks vacant-eyed and dangerous." CR>)
+ (ELSE
+ <TELL
+"He's muddy, wet, and tired looking." CR>)>)
+ (ELSE
+ <TELL "The hacker ">
+ <COND (<AND <NOT <ZERO? ,HACKER-HELP>>
+ <QUEUED? I-HACKER-HELPS>>
+ <TELL "is ">
+ <COND (<EQUAL? ,HACKER-HELP 1>
+ <TELL "star">)
+ (ELSE <TELL "sitt">)>
+ <TELL "ing at your terminal">
+ <COND (<G? ,HACKER-HELP 1>
+ <TELL ", typing furiously">)>
+ <TELL ". Every so
+often, he pauses briefly and twirls a lock of his hair. He is also
+humming under his breath.">)
+ (ELSE
+ <TELL
+"sits comfortably on an office chair facing a terminal table,
+or perhaps it's just a pile of old listings as tall as a terminal table.
+He is typing madly, using just two fingers, but achieves
+speeds that typists using all ten fingers only dream of. He is apparently
+debugging a large assembly language program, as the screen of his terminal
+looks like a spray of completely random characters.">)>
+ <TELL " The hacker is dressed
+in blue jeans, an old work shirt, and what might once have been running
+shoes. Hanging from his belt is an enormous ring of keys. He is in need
+of a bath." CR>)>)
+ (<VERB? THANK>
+ <COND (<G? ,LAIR-CNT 6>
+ <TELL "It doesn't impress him." CR>)
+ (<OR <HELD? ,MASTER-KEY>
+ <NOT <ZERO? ,HACKER-HELP>>>
+ <TELL
+"He blushes." CR>)>)
+ (<VERB? LISTEN>
+ <COND (<G? ,LAIR-CNT 6>
+ <TELL
+"He sounds like an insincere Moonie." CR>)
+ (ELSE
+ <TELL
+"He is humming something. It sounds classical, perhaps Bach?" CR>)>)
+ (<VERB? SMELL>
+ <TELL
+"Either the hacker, his clothing, or both are in need of cleaning." CR>)
+ (<P? TELL-ABOUT HACKER>
+ <COND (<G? ,LAIR-CNT 6>
+ <TELL
+"He doesn't appear to be listening." CR>)
+ (<PRSI? ,PROGRAM ,PC>
+ <COND (,HACKER-HELP
+ <TELL
+"He listens, more or less. The impression he gives is that non-hackers
+don't know anything about the bugs they cause." CR>)
+ (ELSE
+ <TELL
+"The hacker isn't too interested, and doesn't bother to get up and
+investigate more closely. He mumbles something about sending him a
+bug message, and returns to his work." CR>)>)
+ (<IN? ,PRSI ,PLAYER>
+ <PERFORM ,V?SHOW ,PRSI ,HACKER>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"The hacker shows little interest in your remarks." CR>)>)
+ (<VERB? SHOW>
+ <COND (<G? ,LAIR-CNT 6>
+ <TELL ,TOTALLY-UNRESPONSIVE>)
+ (<FSET? ,PRSO ,FOODBIT>
+ <TELL
+"\"Winnage! I could do with some of that.\"" CR>)
+ (<PRSO? ,SMOOTH-STONE>
+ <TELL
+"\"Odd-looking thing. Are you a rock-jock?\"" CR>)
+ (<PRSO? ,HAND>
+ <TELL
+"\"Mondo grosso!\"" CR>)
+ (<PRSO? ,DEAD-RAT>
+ <TELL
+"\"I have enough of those in my basement. Get rid of it!\"" CR>)
+ (ELSE
+ <TELL
+"He more or less grunts at you, but shows little interest in " THE ,PRSO
+,PERIOD>)>)
+ (<VERB? GIVE>
+ <COND (<G? ,LAIR-CNT 6>
+ <TELL ,TOTALLY-UNRESPONSIVE>)
+ (<AND <PRSO? ,CARTON ,CHINESE-FOOD>
+ <IN? ,CHINESE-FOOD ,CARTON>>
+ <DEQUEUE I-FOOD-HINT>
+ <SET H <GETP ,CHINESE-FOOD ,P?HEAT>>
+ <COND (<FSET? ,CHINESE-FOOD ,RMUNGBIT>
+ <REMOVE ,CARTON>
+ <TELL
+"\"Ouch! This is ridiculous! You've overcooked it. Look at those
+poor shrimp! It's ruined, chomper!\" He throws it away." CR>)
+ (<G=? .H 12>
+ <MOVE ,CARTON ,HACKER>
+ <REMOVE ,CHINESE-FOOD>
+ ;<SCORE-OBJECT ,CHINESE-FOOD>
+ <TELL
+"\"Ah! Serious food!\" He plunges into the food with all the delicacy
+and table manners of a shark at a feeding frenzy. Soon a satisfied
+expression appears on his face. ">
+ <COND (,HACKER-TRADE?
+ <HACKER-LOANS-KEY>)
+ (ELSE
+ <TELL
+"\"Now, what was it you were wanting?\" he asks." CR>)>)
+ (ELSE
+ <TELL
+"\"Yuck! This is">
+ <COND (<ZERO? .H> <TELL " cold">)
+ (ELSE
+ <TELL "n't warm enough">)>
+ <TELL "!\" He
+thrusts it back into your hands." CR>)>)
+ (<AND <PRSO? ,SNACK>
+ <NOT <FSET? ,SNACK ,RMUNGBIT>>>
+ <MOVE ,SNACK ,HACKER>
+ <TELL
+"\"Hey, thanks!\" He stuffs it down in no time.">
+ <AFTER-HACKER-EATS>)
+ (<PRSO? ,COKE>
+ <TELL
+"\"I only drink Diet Coke,\" he complains.">
+ <AFTER-HACKER-EATS>)
+ (ELSE
+ <TELL
+"\"No thanks, keep it for now.\"" CR>)>)
+ (<HOSTILE-VERB?>
+ <COND (<VERB? THROW>
+ <MOVE ,PRSO ,HERE>
+ <TELL "Thrown. ">)>
+ <COND (<G? ,LAIR-CNT 6>
+ <TELL
+"He is unharmed. \"It is peaceful within,\" he remarks." CR>)
+ (ELSE
+ <TELL
+"The hacker retreats. \"I know karate!\" he says, somewhat
+unconvincingly." CR>)>)>>
+
+<ROUTINE AFTER-HACKER-EATS ()
+ <COND (<NOT <IN? ,CARTON ,HACKER>>
+ <TELL
+" \"I could really do with some Chinese food, though.\"">)>
+ <CRLF>>
+
+<GLOBAL HACKER-TRADE? <>>
+
+<ROUTINE HACKER-LOANS-KEY ()
+ <SETG HACKER-TRADE? <>>
+ <MOVE ,MASTER-KEY ,PLAYER>
+ <SCORE-OBJECT ,MASTER-KEY>
+ <TELL
+"\"Well, I suppose I could loan you " THE ,MASTER-KEY " for a while. Just
+don't get into trouble, okay? I'll find you later, when I'm done with all this,
+and get it back.\" He hands you the key." CR>>
+
+<ROUTINE I-FOOD-HINT ()
+ <COND (<OR <NOT ,FOOD-COUNT>
+ <NOT <HERE? <LOC ,HACKER>>>>
+ <RFALSE>)
+ (ELSE
+ <COND (<G? <SETG FOOD-COUNT <+ ,FOOD-COUNT 1>>
+ <GET ,FOOD-HINTS 0>>
+ <SETG FOOD-COUNT <>>
+ <RFALSE>)
+ (ELSE
+ <QUEUE I-FOOD-HINT 2>
+ <TELL CR
+"The hacker turns to you and says, \"" <GET ,FOOD-HINTS ,FOOD-COUNT>
+"\"" CR>)>)>>
+
+<GLOBAL FOOD-COUNT:FIX 1>
+
+<GLOBAL FOOD-HINTS
+ <LTABLE (PURE)
+"I could stand a little snack, though."
+"I don't know where I can get something to eat, what with all the snow."
+"I'd hate to leave, with the machines so empty. On the other hand, I'm
+seriously starving."
+"Why don't you see if you can cons up some food? Then I might be able
+to do something for you.">>
+
+<OBJECT KEYRING
+ (IN HACKER)
+ (DESC "keyring")
+ (SYNONYM KEYRING RING KEYCHAIN)
+ (ADJECTIVE YOUR KEY)
+ (FLAGS NDESCBIT TAKEBIT CONTBIT SURFACEBIT OPENBIT)
+ (CONTFCN HACKER-F)
+ (ACTION KEYRING-F)>
+
+<ROUTINE KEYRING-F ()
+ <FSET ,KEYRING ,SEARCHBIT>
+ <COND (<VERB? EXAMINE>
+ <TELL
+"Hanging from the hacker's belt is a watchman's keyring. The large and almost
+full ring is connected by an extensible chain to a reel attached to the
+hacker's belt. It is difficult to lose such a keyring. ">
+ <AMONG-THE-KEYS>)
+ (<VERB? TAKE>
+ <TELL ,HACKER-PREVENTS "Chomp!\" he says." CR>)
+ (<VERB? LOOK-INSIDE>
+ <AMONG-THE-KEYS>)>>
+
+<GLOBAL HACKER-PREVENTS "The hacker prevents you. \"">
+
+<ROUTINE AMONG-THE-KEYS ()
+ <TELL
+"There are multitudinous keys hanging on the keyring. Among them are ">
+ <DESCRIBE-REST ,KEYRING>
+ <TELL ,PERIOD>>
+
+<OBJECT KEY-1
+ (IN KEYRING)
+ (DESC "red aluminum Yale key")
+ (SYNONYM KEY KEYS)
+ (ADJECTIVE YOUR RED ALUMINUM METAL YALE)
+ (FLAGS TAKEBIT)
+ (GENERIC GENERIC-KEY-F)>
+
+<OBJECT KEY-2
+ (IN KEYRING)
+ (DESC "green aluminum Yale key")
+ (SYNONYM KEY KEYS)
+ (ADJECTIVE YOUR GREEN ALUMINUM METAL YALE)
+ (FLAGS TAKEBIT)
+ (GENERIC GENERIC-KEY-F)>
+
+<OBJECT KEY-3
+ (IN KEYRING)
+ (DESC "green brass Yale key")
+ (SYNONYM KEY KEYS)
+ (ADJECTIVE YOUR GREEN BRASS METAL YALE)
+ (FLAGS TAKEBIT)
+ (GENERIC GENERIC-KEY-F)>
+
+<OBJECT KEY-4
+ (IN KEYRING)
+ (DESC "green aluminum Medeco key")
+ (SYNONYM KEY KEYS)
+ (ADJECTIVE YOUR GREEN ALUMINUM METAL MEDECO)
+ (FLAGS TAKEBIT)
+ (GENERIC GENERIC-KEY-F)>
+
+<ROUTINE GENERIC-KEY-F ()
+ <COND (<ACCESSIBLE? ,KEYRING>
+ ,KEYRING)>>
+
+<OBJECT MASTER-KEY
+ (IN GLOBAL-OBJECTS)
+ (DESC "master key")
+ (SYNONYM KEY)
+ (ADJECTIVE MASTER)
+ (FLAGS TAKEBIT TRYTAKEBIT)
+ (VALUE 5)
+ (ACTION MASTER-KEY-F)
+ (GENERIC GENERIC-KEY-F)>
+
+<ROUTINE MASTER-KEY-F ()
+ <COND (<AND <VERB? EXAMINE>
+ <NOT <IN? ,MASTER-KEY ,GLOBAL-OBJECTS>>>
+ <TELL
+"The key appears to be a master key. There is no indication of what locks
+it might fit, however." CR>)
+ (<AND <VERB? TAKE>
+ <IN? ,MASTER-KEY ,GLOBAL-OBJECTS>>
+ <TELL
+"You haven't seen any master key." CR>)>>
+
+<OBJECT CARTON
+ (IN REFRIGERATOR)
+ (DESC "cardboard carton")
+ (SYNONYM CARTON SYMBOL)
+ (ADJECTIVE CARDBOARD STRANGE SCRAWLED INCOMPREHENSIBLE)
+ (FLAGS READBIT TRYTAKEBIT TAKEBIT SEARCHBIT FOODBIT CONTBIT OPENABLE)
+ (CAPACITY 10)
+ (GENERIC GENERIC-SYMBOL-F)
+ (ACTION CARTON-F)>
+
+<ROUTINE CARTON-F ()
+ <COND (<OR <EQUAL? ,W?SYMBOL <GET ,P-NAMW 0>>
+ <EQUAL? ,W?SYMBOL <GET ,P-NAMW 1>>>
+ <CARTON-SYMBOL-F>)
+ (<VERB? EXAMINE>
+ <TELL
+"This is a cardboard carton with an incomprehensible symbol scrawled on
+the top." CR>)
+ (<VERB? READ>
+ <CARTON-SYMBOL-F>)
+ (<AND <VERB? SMELL>
+ <IN? ,CHINESE-FOOD ,CARTON>>
+ <NEW-PRSO ,CHINESE-FOOD>
+ <RTRUE>)
+ (<AND <VERB? RUB>
+ <IN? ,CHINESE-FOOD ,CARTON>
+ <G? <GETP ,CHINESE-FOOD ,P?HEAT> 8>>
+ <TELL
+"The carton feels warm." CR>)
+ (<VERB? EAT>
+ <TELL
+"You might find the contents more agreeable than the carton itself." CR>)>>
+
+<ROUTINE CARTON-SYMBOL-F ()
+ <COND (<VERB? EXAMINE READ>
+ <TELL
+S "It doesn't look like ""Chinese, English, or any other language you know. ">
+ <TELL-SYMBOL ,CARTON>
+ <CRLF>)>>
+
+<OBJECT CHINESE-FOOD
+ (IN CARTON)
+ (DESC "Chinese food")
+ (SYNONYM FOOD SHRIMP)
+ (ADJECTIVE CHINESE SZECHUAN)
+ (FLAGS NOABIT TAKEBIT TRYTAKEBIT FOODBIT)
+ ;(VALUE 5)
+ (HEAT 0)
+ (ACTION CHINESE-FOOD-F)>
+
+<ROUTINE HEAT (OBJ "AUX" (H <GETP .OBJ ,P?HEAT>))
+ <COND (<G=? .H 20> "radioactive")
+ (<G=? .H 16> "volcanic")
+ (<G=? .H 12> "hot")
+ (<G=? .H 8> "warm")
+ (<G=? .H 4> "lukewarm")
+ (ELSE "cold")>>
+
+<ROUTINE CHINESE-FOOD-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This is a carton of " <HEAT ,CHINESE-FOOD> " Szechuan shrimp. Lovely red peppers
+poke out of the sauce." CR>)
+ (<AND <VERB? TAKE>
+ <NOT ,PRSI>>
+ <COND (<IN? ,PRSO ,CARTON>
+ <TELL
+"If you take it out, it will spill
+all over you. Why not take the carton instead?" CR>)>)
+ (<AND <P? PUT ,CHINESE-FOOD>
+ <IN? ,CHINESE-FOOD ,CARTON>>
+ <NEW-PRSO ,CARTON>
+ <RTRUE>)
+ (<VERB? EAT TASTE>
+ <TELL
+"It's very (chemically) hot, spicy, and " <HEAT ,CHINESE-FOOD> ".">
+ <COND (<VERB? EAT>
+ <REMOVE ,CHINESE-FOOD>
+ <TELL
+" You immediately want to drink something to wash it down.">)>
+ <CRLF>)>>
+
+<OBJECT COKE
+ (IN REFRIGERATOR)
+ (DESC "two liter bottle of Classic Coke")
+ (SYNONYM COKE COCA-COLA CAP)
+ (ADJECTIVE TWO LITER BOTTLE CLASSIC)
+ (FLAGS TAKEBIT FOODBIT OPENABLE)
+ (SIZE 5)
+ (HEAT 0)
+ (ACTION COKE-F)>
+
+<ROUTINE COKE-F ("AUX" SIZ TIRE)
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This is a">
+ <SET SIZ <GETP ,COKE ,P?SIZE>>
+ <COND (<EQUAL? .SIZ 1> <TELL "n empty">)
+ (<EQUAL? .SIZ 2> <TELL " nearly empty">)
+ (<EQUAL? .SIZ 3> <TELL " partly full">)
+ (<EQUAL? .SIZ 4> <TELL " partly empty">)
+ (<EQUAL? .SIZ 5> <TELL " full">)>
+ <TELL
+" two-liter bottle of ">
+ <COND (<G? .SIZ 1> <TELL <HEAT ,COKE> " ">)>
+ <TELL "Classic Coke." CR>)
+ (<VERB? TASTE>
+ <TELL "Tastes like the real thing." CR>)
+ (<VERB? DRINK>
+ <COND (<G? <SET SIZ <GETP ,COKE ,P?SIZE>> 1>
+ <PUTP ,COKE ,P?SIZE <SET SIZ <- .SIZ 1>>>
+ <COND (<SET TIRE <QUEUED? I-TIRED>>
+ <COND (<G? ,AWAKE -1>
+ <SETG AWAKE <- ,AWAKE 1>>
+ <SETG FUMBLE-NUMBER <+ ,FUMBLE-NUMBER 1>>
+ <SETG LOAD-ALLOWED <+ ,LOAD-ALLOWED 10>>)>
+ <SET SIZ <+ <GET .TIRE ,C-TICK> 200>>
+ <PUT .TIRE ,C-TICK .SIZ>)>
+ <TELL
+"Delicious! Contains caffeine, one of the four basic food groups. Too
+bad they make it with fructose these days, instead of sucrose. You feel
+much more alert and awake now." CR>)
+ (ELSE
+ <TELL
+"The bottle is empty." CR>)>)
+ (<VERB? OPEN CLOSE>
+ <TELL
+"You fiddle with the cap for a while. What fun! Much better than working
+on your paper." CR>)
+ (<VERB? LOOK-INSIDE>
+ <TELL
+,IT-LOOKS-LIKE "the inside of a Coke bottle." CR>)
+ (<AND <VERB? SHAKE>
+ <G? <SET SIZ <GETP ,COKE ,P?SIZE>> 1>>
+ <TELL
+"The Coke fizzes up." CR>)
+ (<P? POUR COKE>
+ <COND (<EQUAL? <SET SIZ <GETP ,COKE ,P?SIZE>> 1>
+ <TELL
+"There is none left in the bottle." CR>)
+ (ELSE
+ <PUTP ,COKE ,P?SIZE 1>
+ <TELL
+"You pour the Coke on ">
+ <COND (,PRSI <TELL THE ,PRSI>)
+ (ELSE <TELL "the ground">)>
+ <TELL ", wasting it." CR>)>)>>
+
+<OBJECT SNACK
+ (IN KITCHEN-COUNTER)
+ (DESC "package of Funny Bones")
+ (SYNONYM PACKAGE FOOD BONES WRAPPER)
+ (ADJECTIVE FUNNY SNACK JUNK)
+ (FLAGS TAKEBIT FOODBIT READBIT OPENABLE)
+ (HEAT 0)
+ (TEXT "\"Funny Bones\"")
+ (ACTION SNACK-F)>
+
+<ROUTINE SNACK-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"This is a">
+ <COND (<FSET? ,SNACK ,RMUNGBIT>
+ <TELL "n empty">)
+ (<FSET? ,SNACK ,OPENBIT>
+ <TELL "n open">
+ <COND (<GETP ,SNACK ,P?HEAT>
+ <TELL ", " <HEAT ,SNACK>>)>)>
+ <TELL
+" " 'SNACK ", a snack food made with peanut butter
+and chocolate cake." CR>)
+ (<VERB? OPEN>
+ <COND (<NOT <FSET? ,SNACK ,OPENBIT>>
+ <FSET ,SNACK ,OPENBIT>
+ <TELL
+"You open the package, revealing yummy junk food inside." CR>)>)
+ (<VERB? EAT>
+ <COND (<FSET? ,SNACK ,RMUNGBIT>
+ <TELL
+"You already did. " S "There's nothing " "left but the wrapper." CR>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"You ">
+ <COND (<NOT <FSET? ,SNACK ,OPENBIT>>
+ <FSET ,SNACK ,OPENBIT>
+ <TELL "tear open the package and ">)>
+ <COND (<G? <GETP ,SNACK ,P?HEAT> 12>
+ <TELL
+"discover that they are too hot to eat." CR>)
+ (ELSE
+ <FSET ,SNACK ,RMUNGBIT>
+ <TELL
+"devour the delicious food-like substance." CR>)>)>)>>
+
+<OBJECT MICROWAVE
+ (IN KITCHEN)
+ (DESC "microwave oven")
+ (SYNONYM OVEN)
+ (ADJECTIVE MICROWAVE OVEN)
+ (FLAGS NDESCBIT SEARCHBIT CONTBIT TRANSBIT OPENABLE)
+ (CAPACITY 30)
+ (ACTION MICROWAVE-F)>
+
+<ROUTINE MICROWAVE-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The microwave oven hangs over the kitchen counter. It
+has more complicated controls than your pc. There is an LED
+readout above the controls. The microwave is ">
+ <COND (<QUEUED? I-MICROWAVE>
+ <TELL "on." CR>)
+ (ELSE
+ <TELL "off and it's ">
+ <OPEN-CLOSED ,MICROWAVE>)>)
+ (<VERB? LAMP-ON>
+ <PUT ,P-ADJW 0 ,W?START>
+ <PERFORM ,V?PUSH ,CONTROLS>
+ <RTRUE>)
+ (<VERB? LAMP-OFF>
+ <PUT ,P-ADJW 0 ,W?STOP>
+ <PERFORM ,V?PUSH ,CONTROLS>
+ <RTRUE>)
+ (<VERB? UNPLUG>
+ <CANT-GET-TO-PLUG>)
+ (<VERB? OPEN>
+ <COND (<NOT <FSET? ,MICROWAVE ,OPENBIT>>
+ <FSET ,MICROWAVE ,OPENBIT>
+ <TELL CTHE ,MICROWAVE>
+ <COND (<QUEUED? I-MICROWAVE>
+ <DEQUEUE I-MICROWAVE>
+ <TELL " shuts off, and">)>
+ <TELL " is now open." CR>)>)
+ (<VERB? CLOSE>
+ <CLOSE-A-DOOR>)>>
+
+<OBJECT READOUT
+ (IN KITCHEN)
+ (DESC "display")
+ (SYNONYM READOUT DISPLAY)
+ (ADJECTIVE LED)
+ (FLAGS NDESCBIT)
+ (ACTION READOUT-F)>
+
+<ROUTINE READOUT-F ("AUX" SEC)
+ <COND (<VERB? EXAMINE READ>
+ <TELL
+"The display is currently displaying ">
+ <COND (<ZERO? ,MICROWAVE-TIMER>
+ <TELL "the current time">)
+ (ELSE
+ <TELL N </ ,MICROWAVE-TIMER 60> ":">
+ <COND (<L? <SET SEC <MOD ,MICROWAVE-TIMER 60>> 10>
+ <TELL "0">)>
+ <TELL N .SEC>)>
+ <TELL " and the word \""
+ <GET ,MICROWAVE-TEMPS ,MICROWAVE-TEMP>
+ ".\"" CR>)>>
+
+<GLOBAL MICROWAVE-TIMER 0>
+<GLOBAL MICROWAVE-TBL <TABLE 0 0 0 0>>
+<GLOBAL MICROWAVE-TEMP 0>
+<GLOBAL MICROWAVE-TEMPS
+ <TABLE (PURE) "off" "warm" "low" "medium" "high">>
+
+<OBJECT CONTROLS
+ (IN KITCHEN)
+ (DESC "microwave controls")
+ (SYNONYM CONTROL BUTTON TIMER)
+ (ADJECTIVE INTNUM WM LO MED HIGH START STOP CLEAR)
+ (FLAGS NDESCBIT NOABIT)
+ (ACTION CONTROLS-F)>
+
+<ADJ-SYNONYM HIGH HI>
+
+<ROUTINE CONTROLS-F ("AUX" ADJ N)
+ <COND (<VERB? EXAMINE READ>
+ <TELL
+"There are controls labelled 0 to 9, WM, LO, MED, HI, START, CLEAR, and
+STOP. ">
+ <TELL-TIMER>)
+ (<P? TURN * ,INTNUM>
+ <CLEAR-MICROWAVE-TBL>
+ <SETG MICROWAVE-TIMER ,P-NUMBER>
+ <COND (<G? ,MICROWAVE-TIMER 3600>
+ <TELL
+,YOU-CANT "set it for that long a time." CR>
+ <RTRUE>)
+ (ELSE
+ <TELL-TIMER>)>)
+ (<VERB? RUB PUSH TYPE ENTER>
+ <COND (<NOT <SET ADJ <GET ,P-ADJW 0>>>)
+ (<EQUAL? .ADJ ,W?INTNUM>
+ <COND (<G? ,P-NUMBER 9>
+ <COND (,P-TIME?
+ <TELL
+"Why don't you try setting the timer to that?" CR>)
+ (ELSE
+ <TELL
+S "There's no number " "\"" N ,P-NUMBER "\" on the control panel!" CR>)>)
+ (ELSE
+ <PUT ,MICROWAVE-TBL 3 <GET ,MICROWAVE-TBL 2>>
+ <PUT ,MICROWAVE-TBL 2 <GET ,MICROWAVE-TBL 1>>
+ <PUT ,MICROWAVE-TBL 1 <GET ,MICROWAVE-TBL 0>>
+ <PUT ,MICROWAVE-TBL 0 ,P-NUMBER>
+ <SETG MICROWAVE-TIMER
+ <+ <GET ,MICROWAVE-TBL 0>
+ <* <GET ,MICROWAVE-TBL 1> 10>
+ <* <GET ,MICROWAVE-TBL 2> 60>
+ <* <GET ,MICROWAVE-TBL 3> 600>>>
+ <TELL-TIMER>)>)
+ (<EQUAL? .ADJ ,W?START>
+ <COND (<QUEUED? I-MICROWAVE>
+ <TELL
+"It's already started." CR>)
+ (<OR <FSET? ,MICROWAVE ,OPENBIT>
+ <ZERO? ,MICROWAVE-TIMER>>
+ <TELL "Nothing happens, as there's ">
+ <COND (<NOT <ZERO? ,MICROWAVE-TIMER>>
+ <TELL
+"a safety interlock engaged when the door is open." CR>)
+ (<ZERO? ,MICROWAVE-TIMER>
+ <TELL
+"no time set on it yet." CR>)>)
+ (ELSE
+ <COND (<ZERO? ,MICROWAVE-TEMP>
+ <SETG MICROWAVE-TEMP 4>)>
+ <CLEAR-MICROWAVE-TBL>
+ <QUEUE I-MICROWAVE -1>
+ <TELL
+"The microwave starts up. The timer begins counting down." CR>)>)
+ (<EQUAL? .ADJ ,W?STOP>
+ <COND (<QUEUED? I-MICROWAVE>
+ <CLEAR-MICROWAVE-TBL>
+ <DEQUEUE I-MICROWAVE>
+ ;<HEAT-CONTENTS ,MICROWAVE>
+ <TELL ,MICROWAVE-STOPS>
+ <TELL-HEAT 0>)
+ (ELSE
+ <ITS-ALREADY-X "off">)>)
+ (<EQUAL? .ADJ ,W?CLEAR>
+ <COND (<QUEUED? I-MICROWAVE>
+ <TELL ,NOTHING-HAPPENS>)
+ (ELSE
+ <CLEAR-MICROWAVE-TBL>
+ <SETG MICROWAVE-TIMER 0>
+ <TELL
+"The timer clears to zero." CR>)>)
+ (<EQUAL? .ADJ ,W?WM ,W?LO ,W?MED ,W?HIGH ,W?HI>
+ <COND (<QUEUED? I-MICROWAVE>
+ <TELL ,NOTHING-HAPPENS>)
+ (<EQUAL? .ADJ ,W?WM> <TELL-HEAT 1>)
+ (<EQUAL? .ADJ ,W?LO> <TELL-HEAT 2>)
+ (<EQUAL? .ADJ ,W?MED> <TELL-HEAT 3>)
+ (ELSE <TELL-HEAT 4>)>)
+ (ELSE
+ <TELL
+"Which button?" CR>)>)>>
+
+<ROUTINE CLEAR-MICROWAVE-TBL ()
+ <PUT ,MICROWAVE-TBL 0 0>
+ <PUT ,MICROWAVE-TBL 1 0>
+ <PUT ,MICROWAVE-TBL 2 0>
+ <PUT ,MICROWAVE-TBL 3 0>>
+
+<GLOBAL HEAT-TABLE
+ <LTABLE SMOOTH-STONE 0 DEAD-RAT 0 HAND 0
+ CHINESE-FOOD 0 COKE 0 SNACK 0>>
+
+<ROUTINE I-COOL ("AUX" (CNT 0) (L <GET ,HEAT-TABLE 0>) OBJ H (Q? <>)
+ MICROWAVE-RUNNING?)
+ <SET MICROWAVE-RUNNING? <QUEUED? I-MICROWAVE>>
+ <REPEAT ()
+ <COND (<G? <SET CNT <+ .CNT 1>> .L>
+ <COND (.Q?
+ <QUEUE I-COOL 2>)>
+ <RETURN>)>
+ <SET OBJ <GET ,HEAT-TABLE .CNT>>
+ <SET CNT <+ .CNT 1>>
+ <COND (<ZERO? <GET ,HEAT-TABLE .CNT>>
+ <SET Q? T>
+ <PUT ,HEAT-TABLE .CNT ,MOVES>)>
+ <COND (<AND <IN? .OBJ ,MICROWAVE>
+ .MICROWAVE-RUNNING?>
+ <SET Q? T>)
+ (<NOT <ZERO? <SET H <GETP .OBJ ,P?HEAT>>>>
+ <COND (<G? <- ,MOVES <GET ,HEAT-TABLE .CNT>> 3>
+ <PUT ,HEAT-TABLE .CNT ,MOVES>
+ <PUTP .OBJ ,P?HEAT <SET H <- .H 1>>>)>
+ <COND (<NOT <ZERO? .H>>
+ <SET Q? T>)>)>>>
+
+<ROUTINE HEAT-CONTENTS (WHAT TIM "AUX" H)
+ <MAP-CONTENTS (M .WHAT)
+ <COND (<GETPT .M ,P?HEAT>
+ <QUEUE I-COOL 2 T>
+ <SET H <+ <GETP .M ,P?HEAT> ,MICROWAVE-TEMP>>
+ <COND (<L? .TIM 0>
+ <SET H
+ <+ .H
+ </ .TIM
+ </ 60 ,MICROWAVE-TEMP>>>>)>
+ <PUTP .M ,P?HEAT .H>
+ <COND (<AND <EQUAL? .M ,HAND>
+ <FSET? .M ,PERSON>>
+ <SETG ANIMATION-COUNT 0>
+ <FCLEAR .M ,PERSON>
+ <COND (<HERE? ,KITCHEN>
+ <TELL CR
+"The hand scrabbles frantically around inside " THE <LOC ,HAND> ", and
+then at last lies still." CR>)>)
+ (<AND <EQUAL? .M ,CHINESE-FOOD>
+ <G? .H 20>>
+ <FSET .M ,RMUNGBIT>)>)
+ (ELSE
+ <HEAT-CONTENTS .M .TIM>)>>>
+
+;<GLOBAL FOOD-SCORE 5>
+
+<ROUTINE I-MICROWAVE ()
+ <SETG MICROWAVE-TIMER <- ,MICROWAVE-TIMER 60>>
+ <HEAT-CONTENTS ,MICROWAVE ,MICROWAVE-TIMER>
+ <COND (<L=? ,MICROWAVE-TIMER 0>
+ <SETG MICROWAVE-TIMER 0>
+ <DEQUEUE I-MICROWAVE>)>
+ <COND (<HERE? ,KITCHEN>
+ <CRLF>
+ <COND (<ZERO? ,MICROWAVE-TIMER>
+ <TELL ,MICROWAVE-STOPS>)>
+ <TELL-TIMER>)>>
+
+<GLOBAL MICROWAVE-STOPS "The microwave stops. ">
+
+<ROUTINE TELL-TIMER ()
+ <TELL
+"The timer display now reads " N </ ,MICROWAVE-TIMER 60> ":">
+ <COND (<L? <MOD ,MICROWAVE-TIMER 60> 10>
+ <TELL "0">)>
+ <TELL N <MOD ,MICROWAVE-TIMER 60> ,PERIOD>>
+
+<ROUTINE TELL-HEAT (N)
+ <SETG MICROWAVE-TEMP .N>
+ <TELL
+"The bottom of the display now reads \"" <GET ,MICROWAVE-TEMPS .N> ".\"" CR>>
+
+<OBJECT KITCHEN-COUNTER
+ (IN KITCHEN)
+ (DESC "kitchen counter")
+ (SYNONYM COUNTER)
+ (ADJECTIVE KITCHEN)
+ (FLAGS NDESCBIT OPENBIT CONTBIT SEARCHBIT SURFACEBIT)
+ (CAPACITY 200)>
+
+<OBJECT REFRIGERATOR
+ (IN KITCHEN)
+ (DESC "refrigerator")
+ (SYNONYM REFRIGERATOR FRIDGE SIGN)
+ (ADJECTIVE REFRIGERATOR FRIDGE)
+ (FLAGS NDESCBIT SEARCHBIT CONTBIT OPENABLE READBIT)
+ (CAPACITY 200)
+ (ACTION REFRIGERATOR-F)>
+
+<ROUTINE REFRIGERATOR-F ()
+ <COND (<VERB? EXAMINE READ>
+ <COND (<EQUAL? <GET ,P-NAMW 0> ,W?SIGN>
+ <TELL "\"Everything in this fridge must have a
+name and date on it!\" (The sign has neither.)" CR>)
+ (ELSE
+ <TELL
+"This is a medium-sized refrigerator whose door is ">
+ <COND (<FSET? ,PRSO ,OPENBIT>
+ <TELL "open">)
+ (ELSE <TELL "closed">)>
+ <TELL ". There is a sign on the front." CR>)>)
+ (<VERB? LOOK-INSIDE>
+ <COND (<FSET? ,REFRIGERATOR ,OPENBIT>
+ <TELL
+"The interior of the refrigerator is appalling. There are soggy
+lunch bags, ancient sandwiches and other less identifiable items">
+ <COND (<FIRST? ,REFRIGERATOR>
+ <TELL
+". More appetizingly, you see ">
+ <DESCRIBE-REST ,REFRIGERATOR>)>
+ <TELL ,PERIOD>)
+ (ELSE
+ <TELL
+,YOU-HAVE-TO "open it to look in it." CR>)>)
+ (<VERB? UNPLUG>
+ <CANT-GET-TO-PLUG>)>>
+
+<ROUTINE CANT-GET-TO-PLUG ()
+ <TELL ,YOU-CANT "get to the plug." CR>>
+
+<ROOM KITCHEN
+ (IN ROOMS)
+ (DESC "Kitchen")
+ (LDESC
+"This is a filthy kitchen. The exit is to the east. On the wall near a
+counter are a refrigerator and a microwave.")
+ (EAST TO CS-2ND)
+ (FLAGS RLANDBIT ONBIT)
+ ;(ACTION KITCHEN-F)>
+
+;<ROUTINE KITCHEN-F (RARG)
+ <COND (<RARG? LOOK>
+ <TELL
+ CR>)>>
diff --git a/interrupts.zil b/interrupts.zil
new file mode 100644
index 0000000..657dcfd
--- /dev/null
+++ b/interrupts.zil
@@ -0,0 +1,27 @@
+"INTERRUPTS for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+;"GENERICS"
+
+<GLOBAL LOAD-MAX 150>
+<GLOBAL LOAD-ALLOWED 150>
+
+<GLOBAL AWAKE -1>
+
+<ROUTINE I-TIRED ("AUX" (FORG <>))
+ <QUEUE I-TIRED 25>
+ <COND (<G? ,LOAD-ALLOWED 10>
+ <SETG LOAD-ALLOWED <- ,LOAD-ALLOWED 10>>)>
+ <COND (<G? ,FUMBLE-NUMBER 1>
+ <SETG FUMBLE-NUMBER <- ,FUMBLE-NUMBER 1>>)>
+ <SETG AWAKE <+ ,AWAKE 1>>
+ <CRLF>
+ <COND (<G? ,AWAKE 8>
+ <TELL
+"You are so exhausted you can't stay awake any longer." CR>
+ <CRLF>
+ <V-SLEEP T>
+ <RFATAL>)
+ (T
+ <TELL "You are " <GET ,TIRED-TELL ,AWAKE> ,PERIOD>)>>
diff --git a/misc.zil b/misc.zil
new file mode 100644
index 0000000..e104f36
--- /dev/null
+++ b/misc.zil
@@ -0,0 +1,917 @@
+"MISC for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+<DEFINE DEBUG-CODE ('X "OPTIONAL" ('Y T))
+ <COND (,ZDEBUGGING? .X)(ELSE .Y)>>
+
+;"tell macro and friends"
+
+<TELL-TOKENS (CRLF CR) <CRLF>
+ (NUM N) * <PRINTN .X>
+ (CHAR CHR C) * <PRINTC .X>
+ S *:STRING <PRINT .X>
+ D ,PRSO <DPRINT-PRSO>
+ D ,PRSI <DPRINT-PRSI>
+ D * <DPRINT .X>
+ CD ,PRSO <CDPRINT-PRSO>
+ CD ,PRSI <CDPRINT-PRSI>
+ CD * <CDPRINT .X>
+ THE ,PRSO <THE-PRINT-PRSO>
+ THE ,PRSI <THE-PRINT-PRSI>
+ THE * <THE-PRINT .X>
+ CTHE ,PRSO <CTHE-PRINT-PRSO>
+ CTHE ,PRSI <CTHE-PRINT-PRSI>
+ CTHE * <CTHE-PRINT .X>
+ (A AN) ,PRSO <PRINTA-PRSO>
+ (A AN) ,PRSI <PRINTA-PRSI>
+ (A AN) * <PRINTA .X>>
+
+<ROUTINE CTHE-PRINT-PRSO ()
+ <THE-PRINT ,PRSO T>>
+
+<ROUTINE CTHE-PRINT-PRSI ()
+ <THE-PRINT ,PRSI T>>
+
+<ROUTINE CTHE-PRINT (O)
+ <THE-PRINT .O T>>
+
+<ROUTINE THE-PRINT-PRSO ()
+ <THE-PRINT ,PRSO>>
+
+<ROUTINE THE-PRINT-PRSI ()
+ <THE-PRINT ,PRSI>>
+
+<ROUTINE THE-PRINT (O "OPTIONAL" (CAP? <>))
+ <DPRINT .O .CAP? <NOT <FSET? .O ,NOTHEBIT>>>>
+
+<ROUTINE PRINTA-PRSO ()
+ <PRINTA ,PRSO>>
+
+<ROUTINE PRINTA-PRSI ()
+ <PRINTA ,PRSI>>
+
+<ROUTINE PRINTA (O)
+ <COND (<FSET? .O ,THE> <PRINTI "the ">)
+ (<NOT <FSET? .O ,NOABIT>>
+ <COND (<FSET? .O ,AN> <PRINTI "an ">)
+ (ELSE <PRINTI "a ">)>)>
+ <IPRINT .O>>
+
+;<ROUTINE CDPRINT-PRSO ()
+ <DPRINT ,PRSO T>>
+
+;<ROUTINE CDPRINT-PRSI ()
+ <DPRINT ,PRSI T>>
+
+;<ROUTINE CDPRINT (O)
+ <DPRINT .O T>>
+
+<ROUTINE DPRINT (O "OPTIONAL" (CAP? <>) (THE? <>) "AUX" S)
+ <COND (<OR .THE? <FSET? .O ,THE>>
+ <COND (.CAP? <PRINTI "The ">)
+ (T <PRINTI "the ">)>)>
+ <IPRINT .O>>
+
+<ROUTINE IPRINT (O)
+ <COND (<AND <EQUAL? .O ,PSEUDO-OBJECT>
+ <NOT ,P-MERGED>
+ <EQUAL? .O ,PRSO ,PRSI>>
+ <THING-PRINT ,PSEUDO-PRSO ;"<EQUAL? .O ,PRSO>">)
+ (<EQUAL? .O ,INTNAME>
+ <PRINTB ,P-NAME>)
+ (ELSE
+ <PRINTD .O>)>>
+
+<COND (<GASSIGNED? ZILCH>
+<DEFINE PE (F I)
+ <COND (<TYPE? .I LIST>
+ <FORM .F !.I>)
+ (ELSE
+ <FORM .F .I>)>>
+
+<DEFMAC P? ('V "OPT" ('O '*) ('I '*) ('W '*) "AUX" (L ()))
+ <COND (<N==? .I '*>
+ <SET L (<PE PRSI? .I> !.L)>)>
+ <COND (<N==? .O '*>
+ <SET L (<PE PRSO? .O> !.L)>)>
+ <COND (<N==? .V '*>
+ <SET L (<PE VERB? .V> !.L)>)>
+ <COND (<N==? .W '*>
+ <SET L (<PE WINNER? .W> !.L)>)>
+ <COND (<EMPTY? <REST .L>>
+ <1 .L>)
+ (ELSE <FORM AND !.L>)>>
+
+<DEFMAC VERB? ("ARGS" ATMS)
+ <MULTIFROB ',PRSA .ATMS>>
+
+<DEFMAC CONTEXT? ("ARGS" ATMS)
+ <MULTIFROB '.RARG .ATMS>>
+
+<SETG RARG? ,CONTEXT?>
+
+<DEFMAC WINNER? ("ARGS" ATMS)
+ <MULTIFROB ',WINNER .ATMS>>
+
+<DEFMAC PRSO? ("ARGS" ATMS)
+ <MULTIFROB ',PRSO .ATMS>>
+
+<DEFMAC PRSI? ("ARGS" ATMS)
+ <MULTIFROB ',PRSI .ATMS>>
+
+<DEFMAC HERE? ("ARGS" ATMS)
+ <MULTIFROB ',HERE .ATMS>>
+
+<SETG ROOM? ,HERE?>
+
+<DEFINE MULTIFROB (X ATMS "AUX" (OO (OR)) (O .OO) (L ()) ATM SP)
+ <REPEAT ()
+ <COND (<EMPTY? .ATMS>
+ <RETURN!- <COND (<LENGTH? .OO 1> <ERROR .X>)
+ (<LENGTH? .OO 2> <NTH .OO 2>)
+ (ELSE <CHTYPE .OO FORM>)>>)>
+ <REST
+ <PUTREST
+ .O
+ <SET O
+ (<REPEAT
+ ((LL <FORM EQUAL? .X>)
+ (L <REST .LL>))
+ <COND (<OR <EMPTY? .ATMS>
+ <==? <LENGTH <REST .LL 2>> 3>>
+ <RETURN!- .LL>)>
+ <SET ATM <NTH .ATMS 1>>
+ <PUTREST
+ .L
+ <SET L
+ (<COND
+ (<TYPE? .ATM ATOM>
+ <SET SP <SPNAME .ATM>>
+ <MAKE-GVAL
+ <COND (<==? .X ',PRSA>
+ <PARSE <STRING "V?" .SP>>)
+ (<==? .X '.RARG>
+ <COND (<AND <G? <LENGTH .SP> 2>
+ <==? <1 .SP> !\M>
+ <==? <2 .SP> !\->>
+ .ATM)
+ (ELSE
+ <PARSE
+ <STRING "M-" .SP>>)>)
+ (ELSE .ATM)>>)
+ (ELSE .ATM)>)>>
+ <SET ATMS <REST .ATMS>>>)>>>>>)
+(ELSE
+ <DEFINE P? (V "OPT" (O '*) (I '*) (W '*) "AUX" (L <>))
+ <AND <OR <==? .W '*> <WINNER? .W>>
+ <OR <==? .V '*> <VERB? .V>>
+ <OR <==? .O '*> <PRSO? .O>>
+ <OR <==? .I '*> <PRSI? .I>>>>
+
+ <DEFINE VERB? ("TUPLE" ATMS)
+ <MAPF <>
+ <FUNCTION (A "AUX" ATM)
+ <COND (<TYPE? .A ATOM>
+ <COND (<SET ATM
+ <LOOKUP <STRING "V?" <SPNAME .A>>
+ <MOBLIST INITIAL>>>
+ <COND (<EQUAL? ,PRSA ,.ATM>
+ <MAPLEAVE T>)>)
+ (ELSE
+ <ERROR NOT-A-VERB? .A>)>)
+ (<EQUAL? ,PRSA .A>
+ <MAPLEAVE T>)>>
+ .ATMS>>
+ <DEFINE CONTEXT? ("TUPLE" ATMS)
+ <MAPF <>
+ <FUNCTION (A "AUX" ATM)
+ <COND (<TYPE? .A ATOM>
+ <COND (<AND <G? <LENGTH <SET ATM <SPNAME .A>>> 2>
+ <==? <1 .ATM> !\M>
+ <==? <2 .ATM> !\->>
+ <COND (<EQUAL? .RARG ,.ATM>
+ <MAPLEAVE T>)>)
+ (<SET ATM
+ <LOOKUP <STRING "M-" <SPNAME .A>>
+ <MOBLIST INITIAL>>>
+ <COND (<EQUAL? .RARG ,.ATM>
+ <MAPLEAVE T>)>)
+ (ELSE
+ <ERROR NOT-A-CONTEXT? .A>)>)
+ (<EQUAL? .RARG .A>
+ <MAPLEAVE T>)>>
+ .ATMS>>
+ <SETG RARG? ,CONTEXT?>
+ <DEFINE WINNER? ("TUPLE" ATMS)
+ <MULTIFROB ,WINNER .ATMS>>
+ <DEFINE PRSO? ("TUPLE" ATMS)
+ <MULTIFROB ,PRSO .ATMS>>
+ <DEFINE PRSI? ("TUPLE" ATMS)
+ <MULTIFROB ,PRSI .ATMS>>
+ <DEFINE HERE? ("TUPLE" ATMS)
+ <MULTIFROB HERE .ATMS>>
+ <SETG ROOM? ,HERE?>
+ <DEFINE MULTIFROB (X ATMS)
+ <MAPF <>
+ <FUNCTION (A)
+ <COND (<TYPE? .A ATOM> <SET A ,.A>)>
+ <COND (<EQUAL? .X .A>
+ <MAPLEAVE T>)>>
+ .ATMS>>)>
+
+<COND (<GASSIGNED? ZILCH>
+<DEFMAC BSET ('OBJ "ARGS" BITS)
+ <MULTIBITS FSET .OBJ .BITS>>
+
+<DEFMAC BCLEAR ('OBJ "ARGS" BITS)
+ <MULTIBITS FCLEAR .OBJ .BITS>>
+
+<DEFMAC BSET? ('OBJ "ARGS" BITS)
+ <MULTIBITS FSET? .OBJ .BITS>>
+
+<DEFINE MULTIBITS (X OBJ ATMS
+ "AUX" (OT <COND (<==? .X FSET?> <FORM OR>)
+ (ELSE <FORM PROG ()>)>)
+ (OO <COND (<LENGTH? .OT 1> .OT)
+ (ELSE <REST .OT>)>)
+ (O .OO)
+ ATM)
+ <REPEAT ()
+ <COND (<EMPTY? .ATMS>
+ <RETURN!- .OT>)>
+ <SET ATM <NTH .ATMS 1>>
+ <SET ATMS <REST .ATMS>>
+ <PUTREST .O
+ <SET O
+ (<FORM .X
+ .OBJ
+ <COND (<TYPE? .ATM FORM> .ATM)
+ (ELSE <MAKE-GVAL .ATM>)>>)>>>>)
+(ELSE
+<DEFINE BSET (OBJ "TUPLE" BITS)
+ <MULTIBITS ,FSET .OBJ .BITS>>
+
+<DEFINE BCLEAR (OBJ "TUPLE" BITS)
+ <MULTIBITS ,FCLEAR .OBJ .BITS>>
+
+<DEFINE BSET? (OBJ "TUPLE" BITS)
+ <MAPF <>
+ <FUNCTION (A)
+ <COND (<FSET? .OBJ ,.A> <MAPLEAVE T>)>>
+ .BITS>>
+
+<DEFINE MULTIBITS (X OBJ ATMS)
+ <MAPF <>
+ <FUNCTION (A)
+ <APPLY!- .X .OBJ ,.A>>
+ .ATMS>>)>
+
+<DEFMAC RFATAL ()
+ '<RETURN ,M-FATAL>>
+
+<COND (<GASSIGNED? ZILCH>
+ <DEFMAC PROB ('BASE?)
+ <FORM NOT <FORM L? .BASE? '<RANDOM 100>>>>)
+ (ELSE
+ <DEFINE PROB (BASE?)
+ <NOT <L? .BASE? <RANDOM 100>>>>)>
+
+<ROUTINE PICK-ONE (FROB
+ "AUX" (L <GET .FROB 0>) (CNT <GET .FROB 1>) RND MSG RFROB)
+ <SET L <- .L 1>>
+ <SET FROB <REST .FROB 2>>
+ <SET RFROB <REST .FROB <* .CNT 2>>>
+ <SET RND <RANDOM <- .L .CNT>>>
+ <SET MSG <GET .RFROB .RND>>
+ <PUT .RFROB .RND <GET .RFROB 1>>
+ <PUT .RFROB 1 .MSG>
+ <SET CNT <+ .CNT 1>>
+ <COND (<==? .CNT .L> <SET CNT 0>)>
+ <PUT .FROB 0 .CNT>
+ .MSG>
+
+<ROUTINE RANDOM-ELEMENT (FROB)
+ <GET .FROB <RANDOM <GET .FROB 0>>>>
+
+
+
+;"former MAIN.ZIL stuff"
+
+<GLOBAL P-WON <>>
+
+<CONSTANT M-FATAL 2>
+
+<CONSTANT M-BEG 1>
+<CONSTANT M-END 2>
+<CONSTANT M-ENTER 3>
+<CONSTANT M-LEAVE 4>
+<CONSTANT M-LOOK 5>
+<CONSTANT M-FLASH 6>
+<CONSTANT M-OBJDESC 7>
+<CONSTANT M-CONTAINER 8>
+
+<ROUTINE GO ()
+ <PUT-GLOBAL ,TOMB 0 0>
+ <PUT-GLOBAL ,TOMB 1 0>
+ ;"put interrupts on clock chain"
+ <SETG CLOCK-HAND <REST ,C-TABLE ,C-TABLELEN>>
+ <QUEUE I-URCHIN 10>
+ <QUEUE I-TIRED 200>
+ ;"set up and go"
+ <SETG P-HIM-OBJECT ,HACKER>
+ <SETG P-IT-OBJECT ,PC>
+ <SETG WINNER ,PLAYER>
+ <SETG HERE ,TERMINAL-ROOM>
+ <SETG LIT <LIT? ,HERE>>
+ <USL>
+ <TELL
+"You've waited until the last minute again. This time it's the end of
+the term, so all the TechNet terminals in the dorm are occupied.
+So, off you go to the old Comp Center. Too bad it's the worst storm of
+the winter (Murphy's Law, right?), and you practically froze to death
+slogging over here from the dorm. Not to mention jumping at every
+shadow, what with all the recent disappearances. Time to find a free
+machine, get to work, and write that twenty page paper." CR CR>
+ <V-VERSION>
+ <CRLF>
+ <V-LOOK>
+ <MAIN-LOOP>>
+
+<ROUTINE MAIN-LOOP ("AUX" TRASH)
+ <REPEAT ()
+ <SET TRASH <MAIN-LOOP-1>>>>
+
+<GLOBAL WAS-IT? <>>
+<GLOBAL WAS-HIM? <>>
+
+<GLOBAL PERFORM-DEPTH 0> ;"number recursive calls to perform"
+
+<ROUTINE MAIN-LOOP-1 ("AUX" ICNT OCNT NUM (CNT 0) (OBJ <>) TBL
+ (V <>) (PTBL T) OBJ1 TMP ONUM)
+ <COND (<SETG P-WON <PARSER>>
+ <SET ICNT <GET ,P-PRSI ,P-MATCHLEN>>
+ <SET OCNT <GET ,P-PRSO ,P-MATCHLEN>>
+ <SETG WAS-IT? <OBJECT-SUBSTITUTE ,IT ,P-IT-OBJECT>>
+ <SETG WAS-HIM? <OBJECT-SUBSTITUTE ,HIM ,P-HIM-OBJECT>>
+ <SET ONUM <BAND <GETB ,P-SYNTAX ,P-SBITS> ,P-SONUMS>>
+ <SET NUM
+ <COND (<OR <ZERO? .OCNT>
+ <AND <ZERO? .ICNT>
+ <EQUAL? .ONUM 2>>>
+ 0)
+ (<G? .OCNT 1>
+ <SET TBL ,P-PRSO>
+ <COND (<ZERO? .ICNT> <SET OBJ <>>)
+ (T <SET OBJ <GET ,P-PRSI 1>>)>
+ .OCNT)
+ (<G? .ICNT 1>
+ <SET PTBL <>>
+ <SET TBL ,P-PRSI>
+ <SET OBJ <GET ,P-PRSO 1>>
+ .ICNT)
+ (T 1)>>
+ <COND (<AND <NOT .OBJ> <1? .ICNT>>
+ <SET OBJ <GET ,P-PRSI 1>>)>
+ <SETG PERFORM-DEPTH 0>
+ <COND (<EQUAL? ,PRSA ,V?WALK> <SET V <PERFORM-PRSA ,PRSO>>)
+ (<ZERO? .NUM>
+ <COND (<ZERO? .ONUM>
+ <SET V <PERFORM-PRSA>>
+ <SETG PRSO <>>)
+ (<NOT ,LIT>
+ <TELL ,TOO-DARK>
+ <END-QUOTE>)
+ (T
+ <TELL "There isn't anything to ">
+ <SET TMP <GET ,P-ITBL ,P-VERBN>>
+ <COND (<VERB? TELL>
+ <TELL "talk to">)
+ (<OR ,P-OFLAG ,P-MERGED>
+ <PRINTB <GET .TMP 0>>)
+ (T
+ <WORD-PRINT <GETB .TMP 2>
+ <GETB .TMP 3>>)>
+ <TELL "!" CR>
+ <SET V <>>
+ <END-QUOTE>)>)
+ (T
+ <SETG P-NOT-HERE 0>
+ <SETG P-MULT <>>
+ <COND (<G? .NUM 1> <SETG P-MULT 1>)>
+ <SET TMP <>>
+ <SET CNT 0>
+ <REPEAT ()
+ <COND (<G? <SET CNT <+ .CNT 1>> .NUM>
+ <COND (<G? ,P-NOT-HERE 0>
+ <TELL "The ">
+ <COND (<NOT <EQUAL? ,P-NOT-HERE .NUM>>
+ <TELL "other ">)>
+ <TELL "object">
+ <COND (<NOT <EQUAL? ,P-NOT-HERE 1>>
+ <TELL "s">)>
+ <TELL " that you mentioned ">
+ <COND (<NOT <EQUAL? ,P-NOT-HERE 1>>
+ <TELL "are">)
+ (T <TELL "is">)>
+ <TELL "n't here." CR>)
+ (<NOT .TMP>
+ <TELL ,REFERRING CR>)>
+ <RETURN>)
+
+(T ;"REFORMATTED AREA"
+ <COND (.PTBL <SET OBJ1 <GET ,P-PRSO .CNT>>)
+ (T <SET OBJ1 <GET ,P-PRSI .CNT>>)>
+ <SETG PRSO <COND (.PTBL .OBJ1) (T .OBJ)>>
+ <SETG PRSI <COND (.PTBL .OBJ) (T .OBJ1)>>
+ <COND (<OR <G? .NUM 1>
+ <EQUAL? <GET <GET ,P-ITBL ,P-NC1> 0> ,W?ALL>>
+ <COND (<MULTIPLE-EXCEPTION? .OBJ1> <AGAIN>)
+ (<VERB? COMPARE-MANY>)
+ (T
+ <COND (<EQUAL? .OBJ1 ,IT>
+ <TELL D ,P-IT-OBJECT>)
+ (ELSE
+ <TELL D .OBJ1>)>
+ <TELL ": ">)>)>
+ <SET TMP T>
+ <SETG PSEUDO-PRSO <COND (<PRSO? ,PSEUDO-OBJECT>)>>
+ <SET V <PERFORM-PRSA ,PRSO ,PRSI>>
+ <COND (<EQUAL? .V ,M-FATAL> <RETURN>)>
+ <COND (,P-MULT <SETG P-MULT <+ ,P-MULT 1>>)>) ;"END REFORMATTING"
+
+ >>)>
+ <COND (<NOT <EQUAL? .V ,M-FATAL>>
+ <COND (<GAME-VERB?> T)
+ (<LOC ,WINNER>
+ <SET V
+ %<DEBUG-CODE
+ <D-APPLY "End"
+ <GETP <LOC ,WINNER> ,P?ACTION>
+ ,M-END>
+ <APPLY <GETP <LOC ,WINNER> ,P?ACTION>
+ ,M-END>>>)>)>
+ <COND (<EQUAL? .V ,M-FATAL>
+ <SETG P-CONT <>>)>)
+ (T
+ <SETG P-CONT <>>)>
+ <COND (,P-WON
+ %<DEBUG-CODE
+ <COND (<VERB? $DEBUG>
+ <AGAIN>)>>
+ <COND (<GAME-VERB?> T)
+ (T
+ <SET V <CLOCKER>>)>
+ <SETG PRSA <>>
+ <SETG PRSO <>>
+ <SETG PRSI <>>)>>
+
+<ROUTINE OBJECT-SUBSTITUTE (OBJ VAR "AUX" (TMP <>) (CNT 0) ICNT OCNT)
+ <COND (<AND .VAR <ACCESSIBLE? .VAR>>
+ <SET ICNT <GET ,P-PRSI ,P-MATCHLEN>>
+ <SET OCNT <GET ,P-PRSO ,P-MATCHLEN>>
+ <REPEAT ()
+ <COND (<G? <SET CNT <+ .CNT 1>> .ICNT>
+ <RETURN>)
+ (T
+ <COND (<EQUAL? <GET ,P-PRSI .CNT> .OBJ>
+ <PUT ,P-PRSI .CNT .VAR>
+ <SET TMP T>
+ <RETURN>)>)>>
+ <SET CNT 0>
+ <REPEAT ()
+ <COND (<G? <SET CNT <+ .CNT 1>> .OCNT>
+ <RETURN>)
+ (T
+ <COND (<EQUAL? <GET ,P-PRSO .CNT> .OBJ>
+ <PUT ,P-PRSO .CNT .VAR>
+ <SET TMP T>
+ <RETURN>)>)>>
+ .TMP)>>
+
+<GLOBAL PSEUDO-PRSO <>> ;"T IF ORIGINAL PRSO WAS PSEUDO-OBJECT"
+
+<ROUTINE GAME-VERB? ()
+ <COND (<AND <VERB? TELL> ,P-CONT> <RTRUE>)
+ (<AND <VERB? HELP>
+ <NOT ,PRSO>
+ <NOT <IN? ,PC ,HERE>>>
+ <RTRUE>)
+ (<VERB? QUIT VERSION BRIEF SUPER-BRIEF VERBOSE
+ $VERIFY RESTART SAVE RESTORE SCRIPT UNSCRIPT
+ $RANDOM $COMMAND $RECORD $UNRECORD SCORE
+ TIME>
+ <RTRUE>)>>
+
+"MULTIPLE-EXCEPTION? -- return true if an object found by all should not
+be included when the crunch comes."
+
+<ROUTINE MULTIPLE-EXCEPTION? (OBJ1 "AUX" (L <LOC .OBJ1>))
+ <COND (<EQUAL? .OBJ1 ,NOT-HERE-OBJECT>
+ <SETG P-NOT-HERE <+ ,P-NOT-HERE 1>>
+ <RTRUE>)
+ (<AND <VERB? TAKE>
+ ,PRSI
+ <NOT <IN? ,PRSO ,PRSI>>>
+ ;"TAKE X FROM Y and x not in y"
+ <RTRUE>)
+ (<NOT <ACCESSIBLE? .OBJ1>>
+ ;"can't get at object"
+ <RTRUE>)
+ (<EQUAL? ,P-GETFLAGS ,P-ALL>
+ ;"cases for ALL"
+ <COND (<AND ,PRSI
+ <PRSO? ,PRSI>>
+ ;"VERB ALL and prso = prsi"
+ <RTRUE>)
+ (<AND <VERB? TAKE> <NOT ,PRSI>>
+ <COND (<OR <AND <NOT <EQUAL? .L ,WINNER ,HERE ,PRSI>>
+ <NOT <EQUAL? .L <LOC ,WINNER>>>
+ <NOT <FSET? .L ,SURFACEBIT>>
+ <NOT <FSET? .L ,SEARCHBIT>>>
+ <AND <NOT <FSET? .OBJ1 ,TAKEBIT>>
+ <NOT <FSET? .OBJ1 ,TRYTAKEBIT>>>>
+ ;"TAKE ALL and object not accessible or takeable"
+ <RTRUE>)
+ (<OR <FSET? .L ,PERSON>
+ <FSET? <LOC .L> ,PERSON>>
+ ;"TAKE ALL held by a person (use TAKE ALL FROM)"
+ <RTRUE>)
+ (<HELD? ,PRSO>
+ ;"TAKE ALL and one object has others in it"
+ <RTRUE>)
+ (<AND <PRSO? DOME-LADDER>
+ <OR ,LADDER-TOP? ,LADDER-BOTTOM?>>
+ ;"TAKE ALL and ladder set up"
+ <RTRUE>)
+ (<AND <PRSO? CHAIN CHAIN-1 CHAIN-2>
+ <OR ,CHAIN-HOOKED? ,CHAIN-LOOPED?>
+ <NOT <EQUAL? .L
+ ,ELEVATOR-PIT ,CS-BASEMENT>>>
+ ;"TAKE ALL and chain looped or hooked"
+ <RTRUE>)
+ (<AND <PRSO? PADLOCK>
+ ,PADLOCK-ON?>
+ ;"TAKE ALL and padlock locked"
+ <RTRUE>)>)
+ (<VERB? DROP GIVE>
+ <COND (<NOT <IN? .OBJ1 ,WINNER>>
+ ;"GIVE/DROP ALL and object not held"
+ <RTRUE>)
+ (<FSET? .OBJ1 ,WEARBIT>
+ ;"GIVE/DROP ALL and object worn"
+ <RTRUE>)>)
+ (<AND <VERB? PUT>
+ <NOT <IN? ,PRSO ,WINNER>>
+ <HELD? ,PRSO ,PRSI>>
+ ;"PUT ALL IN X and object already in x"
+ <RTRUE>)>)>>
+
+;<ROUTINE SAVE-INPUT (TBL "AUX" (OFFS 0) CNT TMP)
+ <SET CNT <+ <GETB ,P-LEXV <SET TMP <* 4 ,P-INPUT-WORDS>>>
+ <GETB ,P-LEXV <+ .TMP 1>>>>
+ <COND (<EQUAL? .CNT 0> ;"failed"
+ <RFALSE>)>
+ <SET CNT <- .CNT 1>>
+ <REPEAT ()
+ <COND (<EQUAL? .OFFS .CNT>
+ <PUTB .TBL .OFFS 0>
+ <RETURN>)
+ (T
+ <PUTB .TBL .OFFS <GETB ,P-INBUF <+ .OFFS 1>>>)>
+ <SET OFFS <+ .OFFS 1>>>
+ <RTRUE>>
+
+;<ROUTINE RESTORE-INPUT (TBL "AUX" CHR)
+ <REPEAT ()
+ <COND (<EQUAL? <SET CHR <GETB .TBL 0>> 0>
+ <RETURN>)
+ (T
+ <PRINTC .CHR>
+ <SET TBL <REST .TBL>>)>>>
+
+<GLOBAL P-MULT <>>
+
+<GLOBAL P-NOT-HERE 0>
+
+
+<GLOBAL WHAT-DO-YOU-WANT-TO "What do you want to ">
+
+<ROUTINE FAKE-ORPHAN ("AUX" TMP)
+ <ORPHAN ,P-SYNTAX <>>
+ <TELL ,WHAT-DO-YOU-WANT-TO>
+ <SET TMP <GET ,P-OTBL ,P-VERBN>>
+ <COND (<EQUAL? .TMP 0>
+ <TELL "tell">)
+ (<ZERO? <GETB ,P-VTBL 2>>
+ <PRINTB <GET .TMP 0>>)
+ (T
+ <WORD-PRINT <GETB .TMP 2> <GETB .TMP 3>>
+ <PUTB ,P-VTBL 2 0>)>
+ <SETG P-OFLAG T>
+ <SETG P-WON <>>
+ <PREP-PRINT
+ <GETB ,P-SYNTAX ,P-SPREP1>>
+ <TELL "?" CR>>
+
+<ROUTINE PERFORM (A "OPTIONAL" (O <>) (I <>) "AUX" (V <>) OA OO OI CNT)
+ <SETG PERFORM-DEPTH <+ ,PERFORM-DEPTH 1>>
+ %<DEBUG-CODE
+ <COND (,ZDEBUG
+ <TELL "[Perform: ">
+ %<COND (<GASSIGNED? ZILCH> '<TELL N .A>)
+ (T '<PRINT <SPNAME <NTH ,ACTIONS <+ <* .A 2> 1>>>>)>
+ <COND (.O
+ <COND (<AND <EQUAL? .A ,V?WALK>
+ ,P-WALK-DIR>
+ <TELL "/" N .O>)
+ (ELSE
+ <TELL "/" D .O>)>)>
+ <COND (.I <TELL "/" D .I>)>
+ <TELL "]" CR>)>>
+ <SET OA ,PRSA>
+ <SET OO ,PRSO>
+ <SET OI ,PRSI>
+ <SETG PRSA .A>
+ <COND (<EQUAL? ,IT .I .O>
+ <COND (<NOT .I>
+ <FAKE-ORPHAN>)
+ (T
+ <TELL ,REFERRING CR>)>
+ <RFATAL>)>
+ <COND (<AND .I
+ <NOT <VERB? WALK>>
+ <NOT <EQUAL? .I ,NOT-HERE-OBJECT>>>
+ <THIS-IS-IT .I>)>
+ <COND (<AND .O
+ <NOT <VERB? WALK>>
+ <NOT <EQUAL? .O ,NOT-HERE-OBJECT>>>
+ <THIS-IS-IT .O>)>
+ <SETG PRSO .O>
+ <SETG PRSI .I>
+ <COND (<AND <NOT <EQUAL? .A ,V?WALK>>
+ <EQUAL? ,NOT-HERE-OBJECT ,PRSO ,PRSI>
+ <SET V
+ %<DEBUG-CODE
+ <D-APPLY "Not Here" ,NOT-HERE-OBJECT-F>
+ <APPLY ,NOT-HERE-OBJECT-F>>>>
+ ;<SETG P-WON <>>)
+ (T
+ <SET O ,PRSO>
+ <SET I ,PRSI>
+ <COND (<AND <NOT <VERB? TELL-ABOUT SGIVE SSHOW SRUB SPUT-ON>>
+ <SET V
+ %<DEBUG-CODE
+ <DD-APPLY "Actor" ,WINNER
+ <GETP ,WINNER ,P?ACTION>>
+ <APPLY <GETP ,WINNER ,P?ACTION>>>>>)
+ (<AND <LOC ,WINNER>
+ <NOT <EQUAL? <LOC ,WINNER> ,HERE>>
+ <SET V
+ %<DEBUG-CODE
+ <D-APPLY "Begin"
+ <GETP <LOC ,WINNER> ,P?ACTION>
+ ,M-BEG>
+ <APPLY <GETP <LOC ,WINNER> ,P?ACTION>
+ ,M-BEG>>>>)
+ (<SET V
+ %<DEBUG-CODE
+ <D-APPLY "Begin"
+ <GETP ,HERE ,P?ACTION>
+ ,M-BEG>
+ <APPLY <GETP ,HERE ,P?ACTION>
+ ,M-BEG>>>)
+ (<SET V
+ %<DEBUG-CODE
+ <D-APPLY "Preaction"
+ <GET ,PREACTIONS .A>>
+ <APPLY <GET ,PREACTIONS .A>>>>)
+ (<AND .I
+ <SET V
+ %<DEBUG-CODE
+ <D-APPLY "PRSI" <GETP .I ,P?ACTION>>
+ <APPLY <GETP .I ,P?ACTION>>>>>)
+ (<AND .O
+ <NOT <EQUAL? .A ,V?WALK>>
+ <LOC .O>
+ <GETP <LOC .O> ,P?CONTFCN>
+ <SET V
+ %<DEBUG-CODE
+ <D-APPLY "Container"
+ <GETP <LOC .O> ,P?CONTFCN>
+ ,M-CONTAINER>
+ <APPLY <GETP <LOC .O> ,P?CONTFCN>
+ ,M-CONTAINER>>>>)
+ (<AND .O
+ <NOT <EQUAL? .A ,V?WALK>>
+ <SET V
+ %<DEBUG-CODE
+ <D-APPLY "PRSO"
+ <GETP .O ,P?ACTION>>
+ <APPLY <GETP .O ,P?ACTION>>>>>)
+ (<SET V
+ %<DEBUG-CODE
+ <D-APPLY <>
+ <GET ,ACTIONS .A>>
+ <APPLY <GET ,ACTIONS .A>>>>)>)>
+ <SETG PRSA .OA>
+ <SETG PRSO .OO>
+ <SETG PRSI .OI>
+ .V>
+
+%<COND (,ZDEBUGGING?
+ <COND (<GASSIGNED? ZILCH>
+ <ROUTINE II-APPLY (STR FCN)
+ <COND (,ZDEBUG
+ <TELL "[I- " N <* .FCN 2> " ">)>
+ <D-APPLY .STR .FCN>>)
+ (ELSE
+ <ROUTINE II-APPLY (STR FCN)
+ <D-APPLY <COND (<TYPE? .FCN ATOM> <SPNAME .FCN>)
+ (ELSE .STR)>
+ .FCN>>)>)>
+
+%<DEBUG-CODE
+ <ROUTINE DD-APPLY (STR OBJ FCN)
+ <COND (,ZDEBUG <TELL "[" D .OBJ "=]">)>
+ <D-APPLY .STR .FCN>>>
+
+%<DEBUG-CODE
+ <ROUTINE D-APPLY (STR FCN "OPTIONAL" (FOO <>) "AUX" RES)
+ <COND (<NOT .FCN> <>)
+ (T
+ <COND (,ZDEBUG
+ <COND (<NOT .STR>
+ <TELL "[Action:]" CR>)
+ (T <TELL "[" .STR ": ">)>)>
+ <SET RES
+ <COND (.FOO <APPLY .FCN .FOO>)
+ (T <APPLY .FCN>)>>
+ %<DEBUG-CODE
+ <COND (<AND ,ZDEBUG .STR>
+ <COND (<EQUAL? .RES ,M-FATAL>
+ <TELL "Fatal]" CR>)
+ (<NOT .RES>
+ <TELL "Not handled]" CR>)
+ (T <TELL "Handled]" CR>)>)>>
+ .RES)>>>
+
+;"former CLOCK.ZIL stuff"
+
+<GLOBAL CLOCK-WAIT <>>
+
+<GLOBAL C-TABLE <ITABLE 13 <> <>>>
+
+<CONSTANT C-INTLEN 4> ;"length of an interrupt entry in bytes"
+<CONSTANT C-RTN 0> ;"word offset of routine name"
+<CONSTANT C-TICK 1> ;"word offset of count"
+
+<CONSTANT C-TABLELEN 52> ;"length of interrupt table in bytes"
+<GLOBAL C-INTS 52> ;"start of queued interrupts in bytes"
+%<DEBUG-CODE <GLOBAL C-MAXINTS 52>>
+
+<ROUTINE DEQUEUE (RTN "AUX" TIM)
+ <COND (<SET RTN <QUEUED? .RTN>>
+ <SET TIM <GET .RTN ,C-TICK>>
+ <PUT .RTN ,C-RTN 0>
+ .TIM)>>
+
+<ROUTINE QUEUED? (RTN "AUX" C E)
+ <SET E <REST ,C-TABLE ,C-TABLELEN>>
+ <SET C <REST ,C-TABLE ,C-INTS>>
+ <REPEAT ()
+ <COND (<EQUAL? .C .E> <RFALSE>)
+ (<EQUAL? <GET .C ,C-RTN> .RTN>
+ <COND (<ZERO? <GET .C ,C-TICK>>
+ <RFALSE>)
+ (T <RETURN .C>)>)>
+ <SET C <REST .C ,C-INTLEN>>>>
+
+"this version of QUEUE automatically enables as well"
+
+"QUEUE routine when fresh?:t means only queue if not currently queued"
+
+<ROUTINE QUEUE (RTN TICK "OPT" (I? <>) "AUX" C E (INT <>))
+ <SET E <REST ,C-TABLE ,C-TABLELEN>>
+ <SET C <REST ,C-TABLE ,C-INTS>>
+ <REPEAT ()
+ <COND (<EQUAL? .C .E>
+ <COND (.INT
+ <SET C .INT>)
+ (ELSE
+ %<DEBUG-CODE
+ <COND (<L? ,C-INTS ,C-INTLEN>
+ <TELL
+ "[**Too many interrupts!**]" CR>)>>
+ <SETG C-INTS <- ,C-INTS ,C-INTLEN>>
+ %<DEBUG-CODE
+ <COND (<L? ,C-INTS ,C-MAXINTS>
+ <SETG C-MAXINTS ,C-INTS>)>>
+ <SET INT <REST ,C-TABLE ,C-INTS>>)>
+ <PUT .INT ,C-RTN .RTN>
+ <RETURN>)
+ (<EQUAL? <GET .C ,C-RTN> .RTN>
+ <COND (.I? <RFALSE>)
+ (ELSE
+ <SET INT .C>
+ <RETURN>)>)
+ (<ZERO? <GET .C ,C-RTN>>
+ <SET INT .C>)>
+ <SET C <REST .C ,C-INTLEN>>>
+ <COND (%<COND (<GASSIGNED? ZILCH>
+ '<G? .INT ,CLOCK-HAND>)
+ (ELSE
+ '<L=? <LENGTH .INT> <LENGTH ,CLOCK-HAND>>)>
+ <SET TICK <- <+ .TICK 3>>>)>
+ <PUT .INT ,C-TICK .TICK>
+ .INT>
+
+<GLOBAL CLOCK-HAND <>>
+
+<ROUTINE CLOCKER ("AUX" E TICK RTN (FLG <>) (Q? <>) OWINNER)
+ <COND (,CLOCK-WAIT <SETG CLOCK-WAIT <>> <RFALSE>)>
+ <SETG CLOCK-HAND <REST ,C-TABLE ,C-INTS>>
+ <SET E <REST ,C-TABLE ,C-TABLELEN>>
+ <SET OWINNER ,WINNER>
+ <SETG WINNER ,PLAYER>
+ <REPEAT ()
+ <COND (<EQUAL? ,CLOCK-HAND .E>
+ <SETG CLOCK-HAND .E>
+ <SETG MOVES <+ ,MOVES 1>>
+ <SETG WINNER .OWINNER>
+ <RETURN .FLG>)
+ (<NOT <ZERO? <GET ,CLOCK-HAND ,C-RTN>>>
+ <SET TICK <GET ,CLOCK-HAND ,C-TICK>>
+ <COND (<L? .TICK -1>
+ <PUT ,CLOCK-HAND ,C-TICK <- <- .TICK> 3>>
+ <SET Q? ,CLOCK-HAND>)
+ (<NOT <ZERO? .TICK>>
+ <COND (<G? .TICK 0>
+ <SET TICK <- .TICK 1>>
+ <PUT ,CLOCK-HAND ,C-TICK .TICK>)>
+ <COND (<NOT <ZERO? .TICK>>
+ <SET Q? ,CLOCK-HAND>)>
+ <COND (<NOT <G? .TICK 0>>
+ <SET RTN
+ %<COND (<GASSIGNED? ZILCH>
+ '<GET ,CLOCK-HAND ,C-RTN>)
+ (ELSE
+ '<NTH ,CLOCK-HAND
+ <+ <* ,C-RTN 2>
+ 1>>)>>
+ <COND (<ZERO? .TICK>
+ <PUT ,CLOCK-HAND ,C-RTN 0>)>
+ <COND (%<COND
+ (,ZDEBUGGING?
+ '<II-APPLY "Int" .RTN>)
+ (ELSE
+ '<APPLY .RTN>)>
+ <SET FLG T>)>
+ <COND (<AND <NOT .Q?>
+ <NOT
+ <ZERO?
+ <GET ,CLOCK-HAND
+ ,C-RTN>>>>
+ <SET Q? T>)>)>)>)>
+ <SETG CLOCK-HAND <REST ,CLOCK-HAND ,C-INTLEN>>
+ <COND (<NOT .Q?>
+ <SETG C-INTS <+ ,C-INTS ,C-INTLEN>>)>>>
+
+<DEFINE PSEUDO ("TUPLE" V)
+ <MAPF ,PLTABLE
+ <FUNCTION (OBJ)
+ <COND (<N==? <LENGTH .OBJ> 3>
+ <ERROR BAD-THING .OBJ>)>
+ <MAPRET <COND (<NTH .OBJ 1>
+ <VOC <SPNAME <NTH .OBJ 1>> ADJECTIVE>)>
+ <COND (<NTH .OBJ 2>
+ <VOC <SPNAME <NTH .OBJ 2>> NOUN>)>
+ ;<3 .OBJ>>>
+ .V>>
+
+<ROUTINE PERFORM-PRSA ("OPT" (O <>) (I <>))
+ <PERFORM ,PRSA .O .I>>
+
+<ROUTINE NEW-VERB (V)
+ <PERFORM .V ,PRSO ,PRSI>>
+
+<ROUTINE SWAP-VERB (V)
+ <PERFORM .V ,PRSI ,PRSO>>
+
+<ROUTINE NEW-PRSO (O)
+ <PERFORM-PRSA .O ,PRSI>>
+
+<ROUTINE NEW-PRSI (I)
+ <PERFORM-PRSA ,PRSO .I>>
+
+<ROUTINE NEW-WINNER-PRSO (A "OPT" (O <>) (I <>) "AUX" OW)
+ <SET OW ,WINNER>
+ <SETG WINNER ,PRSO>
+ <PERFORM .A .O .I>
+ <SETG WINNER .OW>>
+
+<ROUTINE REDIRECT (FROM TO "AUX" O I)
+ <SET O <COND (<PRSO? .FROM> .TO) (ELSE ,PRSO)>>
+ <SET I <COND (<PRSI? .FROM> .TO) (ELSE ,PRSI)>>
+ <PERFORM-PRSA .O .I>
+ <RTRUE>>
diff --git a/parser.zil b/parser.zil
new file mode 100644
index 0000000..a023215
--- /dev/null
+++ b/parser.zil
@@ -0,0 +1,1793 @@
+"PARSER for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+"Parser global variable convention: All parser globals will begin
+with 'P-'. Local variables are not restricted in any way."
+
+<SETG SIBREAKS ".,\"">
+
+<GLOBAL WINNER <>> ;"agent of the action"
+<GLOBAL PRSA <>> ;"the verb"
+<GLOBAL PRSO <>> ;"the first object"
+<GLOBAL PRSI <>> ;"the second object"
+
+"useful globals"
+
+<GLOBAL P-IT-OBJECT <>>
+
+<GLOBAL P-HIM-OBJECT <>>
+
+<GLOBAL LAST-PSEUDO-LOC <>>
+
+<GLOBAL P-ACT <>> ;"gets action associated with the verb"
+
+<GLOBAL P-NAME <>>
+
+<GLOBAL P-OFLAG <>> ;"T if last input was an orphan"
+
+<GLOBAL P-MERGED <>> ;"T if this input was merged with an orphan"
+
+<GLOBAL P-ACLAUSE <>>
+
+<GLOBAL P-NCN 0> ;"how many noun clauses we've seen"
+
+<GLOBAL QUOTE-FLAG <>> ;"T if we're in quoted text (or winner,verb)"
+
+<GLOBAL P-END-ON-PREP <>> ;"T if the sentence ended on a prep."
+
+<GLOBAL P-AND <>> ;"T if seen an AND in a noun clause"
+
+<GLOBAL P-ONEOBJ <>>
+
+
+
+"tables and globals for looking at the input"
+
+<GLOBAL P-CONT <>> ;"offset of more to parse, <> if done"
+<GLOBAL P-LEN 0> ;"saves number of words left to be examined"
+
+<CONSTANT P-LEXWORDS 1> ;"Byte offset to # of entries in LEXV"
+<CONSTANT P-LEXSTART 1> ;"Word offset to start of LEXV entries"
+<CONSTANT P-LEXELEN 2> ;"Number of words per LEXV entry"
+<CONSTANT P-WORDLEN 4> ;"number of bytes per LEXV entry"
+
+<GLOBAL P-LEXV
+ <ITABLE 59 (LEXV) 0 #BYTE 0 #BYTE 0>>
+<GLOBAL AGAIN-LEXV
+ <ITABLE 59 (LEXV) 0 #BYTE 0 #BYTE 0>>
+<GLOBAL RESERVE-LEXV
+ <ITABLE 59 (LEXV) 0 #BYTE 0 #BYTE 0>>
+<GLOBAL RESERVE-PTR <>>
+
+<GLOBAL P-INBUF
+ <ITABLE 120 (BYTE LENGTH) 0>> ;"INBUF - Input buffer for READ"
+<GLOBAL OOPS-INBUF
+ <ITABLE 120 (BYTE LENGTH) 0>>
+
+"table and offsets for oops info"
+
+<GLOBAL OOPS-TABLE <TABLE <> <> <> <>>>
+<CONSTANT O-PTR 0> ;"word pointer to unknown token in P-LEXV"
+<CONSTANT O-START 1> ;"word pointer to sentence start in P-LEXV"
+<CONSTANT O-LENGTH 2> ;"byte length of unparsed tokens in P-LEXV"
+<CONSTANT O-END 3> ;"byte pointer to first free byte in OOPS-INBUF"
+
+"offsets in words"
+
+<CONSTANT P-PSOFF 4> ;"Offset to parts of speech byte"
+<CONSTANT P-P1OFF 5> ;"Offset to first part of speech"
+
+<CONSTANT P-P1BITS 3> ;"First part of speech bit mask in PSOFF byte"
+
+"p-itbl -- state of the parse is stored here"
+
+<GLOBAL P-ITBL <TABLE 0 0 0 0 0 0 0 0 0 0>>
+<GLOBAL P-VTBL <TABLE 0 #BYTE 0 #BYTE 0>>
+
+"p-otbl -- just like p-itbl, for saving orphaned parses"
+
+<GLOBAL P-OTBL <TABLE 0 0 0 0 0 0 0 0 0 0>>
+<GLOBAL P-OVTBL <TABLE 0 #BYTE 0 #BYTE 0>>
+
+"offsets in p-itbl and p-otbl"
+
+<CONSTANT P-ITBLLEN 9> ;"length of p-itbl in words"
+<CONSTANT P-VERB 0> ;"the action (act?foo)"
+<CONSTANT P-VERBN 1> ;"lexv entries for it"
+<CONSTANT P-PREP1 2> ;"first noun clause preposition"
+<CONSTANT P-PREP1N 3> ;"word for it"
+<CONSTANT P-PREP2 4> ;"second noun clause preposition"
+<CONSTANT P-PREP2N 5> ;"word for it"
+<CONSTANT P-NC1 6> ;"start of first noun clause"
+<CONSTANT P-NC1L 7> ;"end of first noun clause"
+<CONSTANT P-NC2 8> ;"start of second noun clause"
+<CONSTANT P-NC2L 9> ;"end of second noun clause"
+
+
+
+"PARSER -- Grovel down the input finding the verb, prepositions, and
+noun clauses. If the input is <direction> or <walk> <direction>, fall
+out immediately setting PRSA to ,V?WALK and PRSO to <direction>.
+Otherwise, perform all required orphaning, syntax checking, and noun
+clause lookup."
+
+<ROUTINE PARSER ("AUX" (PTR ,P-LEXSTART) WRD (VAL 0) (VERB <>) (OF-FLAG <>)
+ OWINNER OMERGED LEN (DIR <>) (NW 0) (LW 0) (CNT -1))
+ <REPEAT ()
+ <COND (<G? <SET CNT <+ .CNT 1>> ,P-ITBLLEN> <RETURN>)
+ (T
+ <COND (<NOT ,P-OFLAG>
+ <PUT ,P-OTBL .CNT <GET ,P-ITBL .CNT>>)>
+ <PUT ,P-ITBL .CNT 0>)>>
+ <SET OWINNER ,WINNER>
+ <SET OMERGED ,P-MERGED>
+ <SETG P-ADVERB <>>
+ <SETG P-MERGED <>>
+ <SETG P-END-ON-PREP <>>
+ <PUT ,P-PRSO ,P-MATCHLEN 0>
+ <PUT ,P-PRSI ,P-MATCHLEN 0>
+ <PUT ,P-BUTS ,P-MATCHLEN 0>
+ <COND (<AND <NOT ,QUOTE-FLAG> <N==? ,WINNER ,PLAYER>>
+ <SETG WINNER ,PLAYER>
+ <COND (<NOT <FSET? <LOC ,WINNER> ,VEHBIT>>
+ <SETG HERE <LOC ,WINNER>>)>
+ <SETG LIT <LIT? ,HERE>>)>
+ <COND (,RESERVE-PTR
+ <SET PTR ,RESERVE-PTR>
+ <STUFF ,RESERVE-LEXV ,P-LEXV>
+ <COND (<AND ,VERBOSITY <EQUAL? ,PLAYER ,WINNER>>
+ <CRLF>)>
+ <SETG RESERVE-PTR <>>
+ <SETG P-CONT <>>)
+ (,P-CONT
+ <SET PTR ,P-CONT>
+ <COND (<AND ,VERBOSITY <EQUAL? ,PLAYER ,WINNER>>
+ <CRLF>)>
+ <SETG P-CONT <>>)
+ (T
+ <SETG WINNER ,PLAYER>
+ <SETG QUOTE-FLAG <>>
+ <COND (<NOT <FSET? <LOC ,WINNER> ,VEHBIT>>
+ <SETG HERE <LOC ,WINNER>>)>
+ <SETG LIT <LIT? ,HERE>>
+ <COND (,VERBOSITY <CRLF>)>
+ <TELL ">">
+ <READ ,P-INBUF ,P-LEXV>)>
+ <SETG P-LEN <GETB ,P-LEXV ,P-LEXWORDS>>
+ <COND (<ZERO? ,P-LEN>
+ <BEG-PARDON>
+ <RFALSE>)>
+ <COND (<EQUAL? <SET WRD <GET ,P-LEXV .PTR>> ,W?OOPS ,W?O>
+ <COND (<EQUAL? <GET ,P-LEXV <+ .PTR ,P-LEXELEN>>
+ ,W?PERIOD ,W?COMMA>
+ <SET PTR <+ .PTR ,P-LEXELEN>>
+ <SETG P-LEN <- ,P-LEN 1>>)>
+ <COND (<NOT <G? ,P-LEN 1>>
+ <TELL "I can't help your clumsiness." CR>
+ <RFALSE>)
+ (<GET ,OOPS-TABLE ,O-PTR>
+ <COND (<AND <G? ,P-LEN 2>
+ <EQUAL? <GET ,P-LEXV <+ .PTR ,P-LEXELEN>>
+ ,W?QUOTE>>
+ <TELL
+"Sorry, you can't correct mistakes in quoted text." CR>
+ <RFALSE>)
+ (<G? ,P-LEN 2>
+ <TELL
+"Warning: only the first word after OOPS is used." CR>)>
+ <PUT ,AGAIN-LEXV <GET ,OOPS-TABLE ,O-PTR>
+ <GET ,P-LEXV <+ .PTR ,P-LEXELEN>>>
+ <SETG WINNER .OWINNER> ;"maybe fix oops vs. chars.?"
+ <INBUF-ADD <GETB ,P-LEXV <+ <* .PTR ,P-LEXELEN> 6>>
+ <GETB ,P-LEXV <+ <* .PTR ,P-LEXELEN> 7>>
+ <+ <* <GET ,OOPS-TABLE ,O-PTR> ,P-LEXELEN> 3>>
+ <STUFF ,AGAIN-LEXV ,P-LEXV>
+ <SETG P-LEN <GETB ,P-LEXV ,P-LEXWORDS>>
+ <SET PTR <GET ,OOPS-TABLE ,O-START>>
+ <INBUF-STUFF ,OOPS-INBUF ,P-INBUF>)
+ (T
+ <PUT ,OOPS-TABLE ,O-END <>>
+ <TELL "There was no word to replace!" CR>
+ <RFALSE>)>)
+ (T
+ <COND (<NOT <EQUAL? .WRD ,W?AGAIN ,W?G>>
+ <SETG P-NUMBER 0>)>
+ <PUT ,OOPS-TABLE ,O-END <>>)>
+ <COND (<EQUAL? <GET ,P-LEXV .PTR> ,W?AGAIN ,W?G>
+ <COND (<ZERO? <GETB ,OOPS-INBUF 1>>
+ <BEG-PARDON>
+ <RFALSE>)
+ (,P-OFLAG
+ <TELL "It's difficult to repeat fragments." CR>
+ <RFALSE>)
+ (<NOT ,P-WON>
+ <TELL "That would just repeat a mistake." CR>
+ <RFALSE>)
+ (<G? ,P-LEN 1>
+ <COND (<OR <EQUAL? <GET ,P-LEXV <+ .PTR ,P-LEXELEN>>
+ ,W?PERIOD ,W?COMMA ,W?THEN>
+ <EQUAL? <GET ,P-LEXV <+ .PTR ,P-LEXELEN>>
+ ,W?AND>>
+ <SET PTR <+ .PTR <* 2 ,P-LEXELEN>>>
+ <PUTB ,P-LEXV ,P-LEXWORDS
+ <- <GETB ,P-LEXV ,P-LEXWORDS> 2>>)
+ (T
+ <TELL "I couldn't understand that sentence." CR>
+ <RFALSE>)>)
+ (T
+ <SET PTR <+ .PTR ,P-LEXELEN>>
+ <PUTB ,P-LEXV ,P-LEXWORDS
+ <- <GETB ,P-LEXV ,P-LEXWORDS> 1>>)>
+ <COND (<G? <GETB ,P-LEXV ,P-LEXWORDS> 0>
+ <STUFF ,P-LEXV ,RESERVE-LEXV>
+ <SETG RESERVE-PTR .PTR>)
+ (T
+ <SETG RESERVE-PTR <>>)>
+ ;<SETG P-LEN <GETB ,AGAIN-LEXV ,P-LEXWORDS>>
+ <SETG WINNER .OWINNER>
+ <SETG P-MERGED .OMERGED>
+ <INBUF-STUFF ,OOPS-INBUF ,P-INBUF>
+ <STUFF ,AGAIN-LEXV ,P-LEXV>
+ <SET CNT -1>
+ <SET DIR ,AGAIN-DIR>
+ <REPEAT ()
+ <COND (<IGRTR? CNT ,P-ITBLLEN> <RETURN>)
+ (T <PUT ,P-ITBL .CNT <GET ,P-OTBL .CNT>>)>>)
+ (T
+ <STUFF ,P-LEXV ,AGAIN-LEXV>
+ <INBUF-STUFF ,P-INBUF ,OOPS-INBUF>
+ <PUT ,OOPS-TABLE ,O-START .PTR>
+ <PUT ,OOPS-TABLE ,O-LENGTH <* 4 ,P-LEN>>
+ <SET LEN
+ <* 2 <+ .PTR <* ,P-LEXELEN <GETB ,P-LEXV ,P-LEXWORDS>>>>>
+ <PUT ,OOPS-TABLE ,O-END <+ <GETB ,P-LEXV <- .LEN 1>>
+ <GETB ,P-LEXV <- .LEN 2>>>>
+ <SETG RESERVE-PTR <>>
+ <SET LEN ,P-LEN>
+ ;<SETG P-DIR <>>
+ <SETG P-NCN 0>
+ <SETG P-GETFLAGS 0>
+ <REPEAT ()
+ <COND (<L? <SETG P-LEN <- ,P-LEN 1>> 0>
+ <SETG QUOTE-FLAG <>>
+ <RETURN>)
+ (<SET WRD <KNOWN-WORD? .PTR .VERB>>
+ <COND (<ZERO? ,P-LEN> <SET NW 0>)
+ (T <SET NW <GET ,P-LEXV <+ .PTR ,P-LEXELEN>>>)>
+ <COND (<AND <EQUAL? .WRD ,W?TO>
+ <EQUAL? .VERB ,ACT?TELL ,ACT?ASK>
+ ;"next clause added 8/20/84 by JW to
+ enable TELL MY NAME TO BEAST"
+ <NOT <ZERO?
+ <WT? .NW ,PS?VERB ,P1?VERB>>>>
+ <PUT ,P-ITBL ,P-VERB ,ACT?TELL>
+ <SET WRD ,W?QUOTE>)
+ (<AND <EQUAL? .WRD ,W?THEN>
+ <G? ,P-LEN 0>
+ <NOT .VERB>
+ <NOT ,QUOTE-FLAG>>
+ <COND (<EQUAL? .LW 0 ,W?PERIOD>
+ <SET WRD ,W?THE>)
+ (ELSE
+ <PUT ,P-ITBL ,P-VERB ,ACT?TELL>
+ <PUT ,P-ITBL ,P-VERBN 0>
+ <SET WRD ,W?QUOTE>)>)>
+ <COND (<EQUAL? .WRD ,W?THEN ,W?PERIOD ,W?QUOTE>
+ <COND (<EQUAL? .WRD ,W?QUOTE>
+ <COND ;"Following clause added for
+ WRITE 'FOO' ON CUBE"
+ (<AND <EQUAL? <GET ,P-LEXV .PTR>
+ ,W?QUOTE>
+ <OR <NOT <EQUAL?
+ .VERB
+ ,ACT?TELL
+ ,ACT?SAY>>
+ <NOT <EQUAL? ,WINNER
+ ,PLAYER>>>>
+ <YOU-CANT-X-THAT "use quotes like">
+ <RFALSE>)
+ (,QUOTE-FLAG
+ <SETG QUOTE-FLAG <>>)
+ (T <SETG QUOTE-FLAG T>)>)>
+ <OR <ZERO? ,P-LEN>
+ <SETG P-CONT <+ .PTR ,P-LEXELEN>>>
+ <PUTB ,P-LEXV ,P-LEXWORDS ,P-LEN>
+ <RETURN>)>
+ <COND (<AND ,P-OFLAG
+ <ZERO? .VERB>
+ <EQUAL? .WRD ,W?UP ,W?DOWN>
+ <EQUAL? <GET ,P-OTBL ,P-VERB>
+ ,ACT?PUSH>
+ <EQUAL? <GET <GET ,P-OTBL ,P-NC1> 0>
+ ,W?CALL ,W?BUTTON ,W?ARROW>>
+ <COND (<EQUAL? .WRD ,W?UP>
+ <SET WRD ,W?UP-ARROW>)
+ (<EQUAL? .WRD ,W?DOWN>
+ <SET WRD ,W?DOWN-ARROW>)>
+ <CHANGE-LEXV .PTR .WRD>)>
+ <COND (<AND <NOT <ZERO? <SET VAL
+ <WT? .WRD
+ ,PS?DIRECTION
+ ,P1?DIRECTION>>>>
+ <EQUAL? .VERB <> ,ACT?WALK ;,ACT?FLY>
+ <OR <EQUAL? .LEN 1>
+ <AND <EQUAL? .LEN 2>
+ <EQUAL? .VERB ,ACT?WALK ;,ACT?FLY>>
+ <AND <EQUAL? .NW
+ ,W?THEN
+ ,W?PERIOD
+ ,W?QUOTE>
+ <NOT <L? .LEN 2>>>
+ <AND ,QUOTE-FLAG
+ <EQUAL? .LEN 2>
+ <EQUAL? .NW ,W?QUOTE>>
+ <AND <G? .LEN 2>
+ <EQUAL? .NW ,W?COMMA ,W?AND>>>>
+ <SET DIR .VAL>
+ <COND (<EQUAL? .NW ,W?COMMA ,W?AND>
+ <CHANGE-LEXV <+ .PTR ,P-LEXELEN>
+ ,W?THEN>)>
+ <COND (<NOT <G? .LEN 2>>
+ <SETG QUOTE-FLAG <>>
+ <RETURN>)>)
+ (<AND <NOT <ZERO?
+ <SET VAL <WT? .WRD
+ ,PS?VERB ,P1?VERB>>>>
+ <NOT .VERB>>
+ <SET VERB .VAL>
+ <PUT ,P-ITBL ,P-VERB .VAL>
+ <PUT ,P-ITBL ,P-VERBN ,P-VTBL>
+ <PUT ,P-VTBL 0 .WRD>
+ <PUTB ,P-VTBL 2 <GETB ,P-LEXV
+ <SET CNT
+ <+ <* .PTR 2> 2>>>>
+ <PUTB ,P-VTBL 3 <GETB ,P-LEXV <+ .CNT 1>>>)
+ (<OR <NOT <ZERO? <SET VAL <WT? .WRD ,PS?PREPOSITION 0>>>>
+ <EQUAL? .WRD ,W?ALL ,W?ONE ,W?BOTH>
+ <NOT <ZERO? <WT? .WRD ,PS?ADJECTIVE>>>
+ <NOT <ZERO? <WT? .WRD ,PS?OBJECT>>>>
+ <COND (<AND <G? ,P-LEN 1>
+ <EQUAL? .NW ,W?OF>
+ <ZERO? .VAL>
+ <NOT <EQUAL? .WRD
+ ,W?ALL ,W?ONE ,W?A>>
+ <NOT <EQUAL? .WRD
+ ,W?BOTH>>>
+ <SET OF-FLAG T>)
+ (<AND <NOT <ZERO? .VAL>>
+ <OR <ZERO? ,P-LEN>
+ <EQUAL? .NW ,W?THEN ,W?PERIOD>>>
+ <SETG P-END-ON-PREP T>
+ <COND (<L? ,P-NCN 2>
+ <PUT ,P-ITBL ,P-PREP1 .VAL>
+ <PUT ,P-ITBL ,P-PREP1N .WRD>)>)
+ (<EQUAL? ,P-NCN 2>
+ <TELL
+"There were too many nouns in that sentence." CR>
+ <RFALSE>)
+ (T
+ <COND (<AND <NOT <ZERO? .VAL>>
+ <EQUAL? .WRD
+ ,W?UP ,W?DOWN ,W?U
+ ,W?D>
+ <EQUAL? .NW
+ ,W?BUTTON ,W?ARROW>>
+ <SET VAL <>>)>
+ <SETG P-NCN <+ ,P-NCN 1>>
+ <SETG P-ACT .VERB>
+ <OR <SET PTR <CLAUSE .PTR .VAL .WRD>>
+ <RFALSE>>
+ <COND (<L? .PTR 0>
+ <SETG QUOTE-FLAG <>>
+ <RETURN>)>)>)
+ (<EQUAL? .WRD ,W?OF>
+ <COND (<OR <NOT .OF-FLAG>
+ <EQUAL? .NW ,W?PERIOD ,W?THEN>>
+ <CANT-USE .PTR>
+ <RFALSE>)
+ (T
+ <SET OF-FLAG <>>)>)
+ (<NOT <ZERO? <WT? .WRD ,PS?BUZZ-WORD>>>)
+ (<AND <EQUAL? .VERB ,ACT?TELL>
+ <NOT <ZERO? <WT? .WRD ,PS?VERB ,P1?VERB>>>
+ ;"Next expr added to fix FORD, TELL ME WHY"
+ ;"NOT taken out of said expr to fix fix"
+ <EQUAL? ,WINNER ,PLAYER>>
+ <TELL
+"Please consult your manual for the correct way to talk to characters." CR>
+ <RFALSE>)
+ (T
+ <CANT-USE .PTR>
+ <RFALSE>)>)
+ (T
+ <UNKNOWN-WORD .PTR>
+ <RFALSE>)>
+ <SET LW .WRD>
+ <SET PTR <+ .PTR ,P-LEXELEN>>>)>
+ <PUT ,OOPS-TABLE ,O-PTR <>>
+ <COND (.DIR
+ <SETG PRSA ,V?WALK>
+ <SETG PRSO .DIR>
+ <SETG P-OFLAG <>>
+ <SETG P-WALK-DIR .DIR>
+ <SETG AGAIN-DIR .DIR>)
+ (ELSE
+ <COND (,P-OFLAG <ORPHAN-MERGE>)>
+ <SETG P-WALK-DIR <>>
+ <SETG AGAIN-DIR <>>
+ <COND (<AND <SYNTAX-CHECK>
+ <SNARF-OBJECTS>
+ <MANY-CHECK>
+ <TAKE-CHECK>>
+ T)>)>>
+
+<ROUTINE BEG-PARDON ()
+ <TELL "I beg your pardon?" CR>>
+
+<ROUTINE KNOWN-WORD? (PTR "OPTIONAL" (VERB <>) "AUX" (WRD <>) (NWRD <>))
+ <COND (<SET WRD <GET ,P-LEXV .PTR>>
+ <COND ;(<EQUAL? .WRD ,W?XYZZY ,W?PLUGH>
+ <SETG P-NAME .WRD>
+ <SET NWRD ,W?INTNAME>)
+ (<EQUAL? .WRD ,W?EVERYTHING ,W?BOTH>
+ <SET NWRD ,W?ALL>)
+ (<EQUAL? .WRD ,W?A>
+ <SET NWRD ,W?ONE>)>)
+ (<OR <SET WRD <INPUT-EQUAL? .PTR ,LOGIN-ID ,W?XYZZY>>
+ <SET WRD <INPUT-EQUAL? .PTR ,PASSWORD-STRING ,W?PLUGH>>>
+ <SETG P-NAME .WRD>
+ <SET NWRD ,W?INTNAME>)
+ (<SET NWRD <NUMBER? .PTR>>)
+ (<EQUAL? .VERB ,ACT?TYPE ,ACT?LOGIN ,ACT?PASSWORD>
+ <SETG P-NAME .WRD>
+ <SET NWRD ,W?INTNAME>)>
+ <COND (.NWRD
+ <CHANGE-LEXV .PTR .NWRD>
+ <SET WRD .NWRD>)>
+ .WRD>
+
+<ROUTINE INPUT-EQUAL? (PTR TBL WRD "AUX" LEX LPTR (CNT 0) CMAX)
+ <SET LEX <REST ,P-LEXV <* .PTR 2>>>
+ <SET CMAX <GETB .TBL 0>>
+ <COND (<EQUAL? .CMAX <GETB .LEX 2>>
+ <SET LPTR <GETB .LEX 3>>
+ <REPEAT ()
+ <COND (<IGRTR? CNT .CMAX> <RETURN .WRD>)
+ (<EQUAL? <GETB ,P-INBUF .LPTR>
+ <GETB .TBL .CNT>>
+ <SET LPTR <+ .LPTR 1>>)
+ (ELSE <RFALSE>)>>)>>
+
+<CONSTANT LOGIN-ID <TABLE (PURE LENGTH STRING) "872325412">>
+<CONSTANT PASSWORD-STRING <TABLE (PURE LENGTH STRING) "uhlersoth">>
+
+<ROUTINE CHANGE-LEXV (PTR WRD)
+ <PUT ,P-LEXV .PTR .WRD>
+ <PUT ,AGAIN-LEXV .PTR .WRD>>
+
+<GLOBAL P-WALK-DIR <>>
+<GLOBAL AGAIN-DIR <>>
+
+"For AGAIN purposes, put contents of one LEXV table into another."
+
+<ROUTINE STUFF (SRC DEST "OPTIONAL" (MAX 29) "AUX" (PTR ,P-LEXSTART) (CTR 1)
+ BPTR)
+ <PUTB .DEST 0 <GETB .SRC 0>>
+ <PUTB .DEST 1 <GETB .SRC 1>>
+ <REPEAT ()
+ <PUT .DEST .PTR <GET .SRC .PTR>>
+ <SET BPTR <+ <* .PTR 2> 2>>
+ <PUTB .DEST .BPTR <GETB .SRC .BPTR>>
+ <SET BPTR <+ <* .PTR 2> 3>>
+ <PUTB .DEST .BPTR <GETB .SRC .BPTR>>
+ <SET PTR <+ .PTR ,P-LEXELEN>>
+ <COND (<IGRTR? CTR .MAX>
+ <RETURN>)>>>
+
+"Put contents of one INBUF into another"
+<ROUTINE INBUF-STUFF (SRC DEST "AUX" CNT)
+ <SET CNT <- <GETB .SRC 0> 1>>
+ <REPEAT ()
+ <PUTB .DEST .CNT <GETB .SRC .CNT>>
+ <COND (<DLESS? CNT 0> <RETURN>)>>>
+
+"Put the word in the positions specified from P-INBUF to the end of
+OOPS-INBUF, leaving the appropriate pointers in AGAIN-LEXV"
+
+<ROUTINE INBUF-ADD (LEN BEG SLOT "AUX" DBEG (CTR 0) TMP)
+ <COND (<SET TMP <GET ,OOPS-TABLE ,O-END>>
+ <SET DBEG .TMP>)
+ (T
+ <SET DBEG <+ <GETB ,AGAIN-LEXV
+ <SET TMP <GET ,OOPS-TABLE ,O-LENGTH>>>
+ <GETB ,AGAIN-LEXV <+ .TMP 1>>>>)>
+ <PUT ,OOPS-TABLE ,O-END <+ .DBEG .LEN>>
+ <REPEAT ()
+ <PUTB ,OOPS-INBUF
+ <+ .DBEG .CTR>
+ <GETB ,P-INBUF <+ .BEG .CTR>>>
+ <SET CTR <+ .CTR 1>>
+ <COND (<EQUAL? .CTR .LEN> <RETURN>)>>
+ <PUTB ,AGAIN-LEXV .SLOT .DBEG>
+ <PUTB ,AGAIN-LEXV <- .SLOT 1> .LEN>>
+
+"Check whether word pointed at by PTR is the correct part of speech.
+ The second argument is the part of speech (,PS?<part of speech>). The
+ 3rd argument (,P1?<part of speech>), if given, causes the value
+ for that part of speech to be returned."
+
+<ROUTINE WT? (PTR BIT "OPTIONAL" (B1 5) "AUX" (OFFS ,P-P1OFF) TYP)
+ <COND (<BTST <SET TYP <GETB .PTR ,P-PSOFF>> .BIT>
+ <COND (<G? .B1 4> <RTRUE>)
+ (<EQUAL? .BIT ,PS?OBJECT> 1)
+ (T
+ <SET TYP <BAND .TYP ,P-P1BITS>>
+ <COND (<NOT <EQUAL? .TYP .B1>> <SET OFFS <+ .OFFS 1>>)>
+ <GETB .PTR .OFFS>)>)
+ (<EQUAL? .BIT ,PS?ADJECTIVE>
+ <COND (<EQUAL? .PTR ,W?UP ,W?U>
+ <WT? ,W?UP-ARROW ,PS?ADJECTIVE .B1>)
+ (<EQUAL? .PTR ,W?DOWN ,W?D>
+ <WT? ,W?DOWN-ARROW ,PS?ADJECTIVE .B1>)
+ (ELSE <RFALSE>)>)>>
+
+"Scan through a noun clause, leave a pointer to its starting location"
+
+<ROUTINE CLAUSE (PTR VAL WRD "AUX" OFF NUM (ANDFLG <>) (1ST? T) NW (LW 0))
+ <SET OFF <* <- ,P-NCN 1> 2>>
+ <COND (<NOT <EQUAL? .VAL 0>>
+ <PUT ,P-ITBL <SET NUM <+ ,P-PREP1 .OFF>> .VAL>
+ <PUT ,P-ITBL <+ .NUM 1> .WRD>
+ <SET PTR <+ .PTR ,P-LEXELEN>>)
+ (T <SETG P-LEN <+ ,P-LEN 1>>)>
+ <COND (<ZERO? ,P-LEN> <SETG P-NCN <- ,P-NCN 1>> <RETURN -1>)>
+ <PUT ,P-ITBL <SET NUM <+ ,P-NC1 .OFF>> <REST ,P-LEXV <* .PTR 2>>>
+ <COND (<EQUAL? <GET ,P-LEXV .PTR> ,W?THE ,W?A ,W?AN>
+ <PUT ,P-ITBL .NUM <REST <GET ,P-ITBL .NUM> 4>>)>
+ <REPEAT ()
+ <COND (<L? <SETG P-LEN <- ,P-LEN 1>> 0>
+ <PUT ,P-ITBL <+ .NUM 1> <REST ,P-LEXV <* .PTR 2>>>
+ <RETURN -1>)>
+ <COND (<SET WRD <KNOWN-WORD? .PTR>>
+ <COND (<ZERO? ,P-LEN> <SET NW 0>)
+ (T <SET NW <GET ,P-LEXV <+ .PTR ,P-LEXELEN>>>)>
+ <COND (<AND <EQUAL? .WRD ,W?QUOTE>
+ <NOT <EQUAL? ,P-ACT ,ACT?TELL ,ACT?SAY>>>
+ <COND ;(<QUOTED-PHRASE .PTR ,P-ACT>
+ <SET PTR <+ .PTR ,P-LEXELEN>>
+ <AGAIN>)
+ (ELSE <RFALSE>)>)
+ (<EQUAL? .WRD ,W?AND ,W?COMMA>
+ <SET ANDFLG .WRD>)
+ (<EQUAL? .WRD ,W?ALL ,W?ONE ,W?BOTH>
+ <COND (<EQUAL? .NW ,W?OF>
+ <SETG P-LEN <- ,P-LEN 1>>
+ <SET PTR <+ .PTR ,P-LEXELEN>>)>)
+ (<OR <EQUAL? .WRD ,W?THEN ,W?PERIOD>
+ <AND <NOT <ZERO? <WT? .WRD ,PS?PREPOSITION>>>
+ <GET ,P-ITBL ,P-VERB>
+ ;"ADDED 4/27 FOR TURTLE,UP"
+ <NOT .1ST?>>>
+ <SETG P-LEN <+ ,P-LEN 1>>
+ <PUT ,P-ITBL
+ <+ .NUM 1>
+ <REST ,P-LEXV <* .PTR 2>>>
+ <RETURN <- .PTR ,P-LEXELEN>>)
+ ;"This next clause was 2 clauses further down"
+ ;"This attempts to fix EDDIE, TURN ON COMPUTER"
+ (<AND <EQUAL? .ANDFLG ,W?COMMA>
+ <EQUAL? <GET ,P-ITBL ,P-VERB> 0>>
+ <SET PTR <- .PTR 4>>
+ <CHANGE-LEXV <+ .PTR 2> ,W?THEN>
+ <SETG P-LEN <+ ,P-LEN 2>>)
+ (<NOT <ZERO? <WT? .WRD ,PS?OBJECT>>>
+ <COND ;"First clause added 1/10/84 to fix
+ 'verb AT synonym OF synonym' bug"
+ (<AND <G? ,P-LEN 0>
+ <EQUAL? .NW ,W?OF>
+ <NOT <EQUAL? .WRD ,W?ALL ,W?ONE>>>
+ T)
+ ;"next clause makes 'give troll red book'
+ have only one noun clause. careful!"
+ (<AND <NOT <ZERO? <WT? .WRD
+ ,PS?ADJECTIVE
+ ,P1?ADJECTIVE>>>
+ <NOT <EQUAL? .NW 0>>
+ <OR <WT? .NW ,PS?OBJECT>
+ <WT? .NW ,PS?ADJECTIVE>>>)
+ (<AND <NOT .ANDFLG>
+ <NOT <EQUAL? .NW ,W?BUT ,W?EXCEPT>>
+ <NOT <EQUAL? .NW ,W?AND ,W?COMMA>>>
+ <PUT ,P-ITBL
+ <+ .NUM 1>
+ <REST ,P-LEXV <* <+ .PTR 2> 2>>>
+ <RETURN .PTR>)
+ (T <SET ANDFLG <>>)>)
+ ;"next clause replaced by following on from games
+ with characters"
+ ;(<AND <OR ,P-MERGED
+ ,P-OFLAG
+ <NOT <EQUAL? <GET ,P-ITBL ,P-VERB> 0>>>
+ <OR <WT? .WRD ,PS?ADJECTIVE>
+ <WT? .WRD ,PS?BUZZ-WORD>>>)
+ (<OR <NOT <ZERO? <WT? .WRD ,PS?ADJECTIVE>>>
+ <NOT <ZERO? <WT? .WRD ,PS?BUZZ-WORD>>>>)
+ (<NOT <ZERO? <WT? .WRD ,PS?PREPOSITION>>> T)
+ (T
+ <CANT-USE .PTR>
+ <RFALSE>)>)
+ (T <UNKNOWN-WORD .PTR> <RFALSE>)>
+ <SET LW .WRD>
+ <SET 1ST? <>>
+ <SET PTR <+ .PTR ,P-LEXELEN>>>>
+
+<ROUTINE NUMBER? (PTR "AUX" CNT BPTR CHR (SUM 0))
+ <SETG P-TIME? <>>
+ <SETG P-MINUTES 0>
+ <SET CNT <GETB <REST ,P-LEXV <* .PTR 2>> 2>>
+ <SET BPTR <GETB <REST ,P-LEXV <* .PTR 2>> 3>>
+ <REPEAT ()
+ <COND (<L? <SET CNT <- .CNT 1>> 0> <RETURN>)
+ (T
+ <SET CHR <GETB ,P-INBUF .BPTR>>
+ <COND (<EQUAL? .CHR %<ASCII !\:>>
+ <SETG P-TIME? T>
+ <SETG P-MINUTES <* .SUM 60>>
+ <SET SUM 0>)
+ (<AND <L? .CHR 58> <G? .CHR 47>>
+ <COND (<G? .SUM 6553>
+ <SET SUM 10000>
+ <RETURN>)>
+ <SET SUM <+ <* .SUM 10> <- .CHR 48>>>)
+ (T <RFALSE>)>
+ <SET BPTR <+ .BPTR 1>>)>>
+ <SETG P-NUMBER .SUM>
+ <COND (,P-TIME?
+ <SETG P-NUMBER <+ ,P-MINUTES ,P-NUMBER>>)>
+ ,W?INTNUM>
+
+<GLOBAL P-TIME? <>> ;"t if reading a time"
+<GLOBAL P-MINUTES 0> ;"number to left of : in a time"
+<GLOBAL P-NUMBER 0> ;"actual number found (NUMBER? substitutes INTNUM)"
+
+
+
+<ROUTINE ORPHAN-MERGE ("AUX" (CNT -1) TEMP VERB BEG END
+ (ADJ <>) (ADJB <>) (VRB <>) (NOUN <>) ADJE WRD)
+ <SETG P-OFLAG <>>
+ <COND (<SET WRD <GET <GET ,P-ITBL ,P-VERBN> 0>>
+ <COND (<EQUAL? <WT? .WRD ,PS?VERB ,P1?VERB>
+ <GET ,P-OTBL ,P-VERB>>
+ <SET VRB T>)>
+ <COND (<WT? .WRD ,PS?ADJECTIVE>
+ <SET ADJ T>)>
+ <COND (<WT? .WRD ,PS?OBJECT>
+ <SET NOUN T>)>)>
+ <COND (<AND <NOT .VRB> ;"convert apparent verb into noun clause"
+ <NOT .ADJ>
+ <WT? .WRD ,PS?OBJECT ,P1?OBJECT>
+ <EQUAL? ,P-NCN 0>>
+ <PUT ,P-ITBL ,P-VERB 0>
+ <PUT ,P-ITBL ,P-VERBN 0>
+ <PUT ,P-ITBL ,P-NC1 <REST ,P-LEXV 2>>
+ <PUT ,P-ITBL ,P-NC1L <REST ,P-LEXV 6>>
+ <SETG P-NCN 1>)>
+ <COND (<AND <NOT <ZERO? <SET VERB <GET ,P-ITBL ,P-VERB>>>>
+ <NOT .ADJ>
+ <NOT .VRB>
+ <NOT <EQUAL? .VERB <GET ,P-OTBL ,P-VERB>>>>
+ <RFALSE>)
+ (<EQUAL? ,P-NCN 2> <RFALSE>)
+ (<EQUAL? <GET ,P-OTBL ,P-NC1> 1>
+ <COND (<EQUAL? <GET ,P-ITBL ,P-PREP1>
+ 0
+ <GET ,P-OTBL ,P-PREP1>>
+ <COND (.ADJ
+ <PUT ,P-ITBL ,P-NC1 <REST ,P-LEXV 2>>
+ <COND (<ZERO? <GET ,P-ITBL ,P-NC1L>>
+ <PUT ,P-ITBL ,P-NC1L <REST ,P-LEXV 6>>)>
+ <COND (<ZERO? ,P-NCN> <SETG P-NCN 1>)>)>
+ <PUT ,P-OTBL ,P-NC1 <GET ,P-ITBL ,P-NC1>>
+ <PUT ,P-OTBL ,P-NC1L <GET ,P-ITBL ,P-NC1L>>)
+ (T <RFALSE>)>)
+ (<EQUAL? <GET ,P-OTBL ,P-NC2> 1>
+ <COND (<EQUAL? <GET ,P-ITBL ,P-PREP1>
+ <>
+ <GET ,P-OTBL ,P-PREP2>>
+ <COND (<OR .ADJ
+ <AND <ZERO? ,P-NCN> .NOUN>>
+ <PUT ,P-ITBL ,P-NC1 <REST ,P-LEXV 2>>
+ <COND (<ZERO? <GET ,P-ITBL ,P-NC1L>>
+ <PUT ,P-ITBL ,P-NC1L <REST ,P-LEXV 6>>)>)>
+ <PUT ,P-OTBL ,P-NC2 <GET ,P-ITBL ,P-NC1>>
+ <PUT ,P-OTBL ,P-NC2L <GET ,P-ITBL ,P-NC1L>>
+ <SETG P-NCN 2>)
+ (T <RFALSE>)>)
+ (,P-ACLAUSE
+ <COND (<AND <NOT <EQUAL? ,P-NCN 1>> <NOT .ADJ>>
+ <SETG P-ACLAUSE <>>
+ <RFALSE>)
+ (T
+ <SET BEG <GET ,P-ITBL ,P-NC1>>
+ <COND (.ADJ
+ <SET BEG <REST ,P-LEXV 2>>
+ <PUT ,P-ITBL ,P-NC1 .BEG>
+ <SET ADJ <>>)>
+ <SET END <GET ,P-ITBL ,P-NC1L>>
+ <REPEAT ()
+ <COND (<EQUAL? .BEG .END>
+ <COND (.ADJB <CLAUSE-WIN .ADJB .ADJE> <RETURN>)
+ (T
+ <SETG P-ACLAUSE <>>
+ <RFALSE>)>)>
+ <SET WRD <GET .BEG 0>>
+ <COND (<OR <EQUAL? .WRD ,W?ALL ,W?ONE>
+ <BTST <GETB .WRD ,P-PSOFF> ,PS?ADJECTIVE>>
+ <COND (<NOT .ADJB> <SET ADJB .BEG>)>
+ <SET ADJE <REST .BEG ,P-WORDLEN>>)
+ (<AND <BTST <GETB .WRD ,P-PSOFF> ,PS?OBJECT>
+ <EQUAL? <+ .BEG ,P-WORDLEN> .END>>
+ <COND (<AND ,P-ANAM
+ <NOT <EQUAL? .WRD ,P-ANAM>>>
+ <SETG P-ANAM <>>
+ <SET ADJB <GET ,P-ITBL ,P-NC1>>
+ <SET ADJE .END>)>)>
+ <SET BEG <REST .BEG ,P-WORDLEN>>
+ <COND (<EQUAL? .END 0>
+ <SET END .BEG>
+ <SETG P-NCN 1>
+ <PUT ,P-ITBL ,P-NC1 <BACK .BEG 4>>
+ <PUT ,P-ITBL ,P-NC1L .BEG>)>>)>)>
+ <PUT ,P-VTBL 0 <GET ,P-OVTBL 0>>
+ <PUTB ,P-VTBL 2 <GETB ,P-OVTBL 2>>
+ <PUTB ,P-VTBL 3 <GETB ,P-OVTBL 3>>
+ <PUT ,P-OTBL ,P-VERBN ,P-VTBL>
+ <PUTB ,P-VTBL 2 0>
+ ;<AND <NOT <EQUAL? <GET ,P-OTBL ,P-NC2> 0>> <SETG P-NCN 2>>
+ <REPEAT ()
+ <COND (<G? <SET CNT <+ .CNT 1>> ,P-ITBLLEN>
+ <SETG P-MERGED T>
+ <RTRUE>)
+ (T <PUT ,P-ITBL .CNT <GET ,P-OTBL .CNT>>)>>
+ T>
+
+<ROUTINE CLAUSE-WIN ("OPT" (ADJB <>) (ADJE <>))
+ <COND (.ADJB
+ <PUT ,P-ITBL ,P-VERB <GET ,P-OTBL ,P-VERB>>)>
+ <PUT ,P-CCTBL ,CC-BEG ,P-ACLAUSE>
+ <PUT ,P-CCTBL ,CC-END <+ ,P-ACLAUSE 1>>
+ <PUT ,P-CCTBL ,CC-IBEG .ADJB>
+ <PUT ,P-CCTBL ,CC-IEND .ADJE>
+ <COND (<EQUAL? ,P-ACLAUSE ,P-NC1>
+ <PUT ,P-CCTBL ,CC-CLAUSE ,P-OCL1>)
+ (ELSE
+ <PUT ,P-CCTBL ,CC-CLAUSE ,P-OCL2>)>
+ <CLAUSE-COPY ,P-OTBL ,P-OTBL>
+ <AND <NOT <EQUAL? <GET ,P-OTBL ,P-NC2> 0>> <SETG P-NCN 2>>
+ <SETG P-ACLAUSE <>>
+ <RTRUE>>
+
+"Print undefined word in input.
+ PTR points to the unknown word in P-LEXV"
+
+<ROUTINE WORD-PRINT (CNT BUF)
+ <REPEAT ()
+ <COND (<DLESS? CNT 0> <RETURN>)
+ (ELSE
+ <PRINTC <GETB ,P-INBUF .BUF>>
+ <SET BUF <+ .BUF 1>>)>>>
+
+<ROUTINE UNKNOWN-WORD (PTR "AUX" BUF)
+ <PUT ,OOPS-TABLE ,O-PTR .PTR>
+ <TELL "I don't know the word \"">
+ <WORD-PRINT <GETB <REST ,P-LEXV <SET BUF <* .PTR 2>>> 2>
+ <GETB <REST ,P-LEXV .BUF> 3>>
+ <TELL ".\"" CR>
+ <SETG QUOTE-FLAG <>>
+ <SETG P-OFLAG <>>>
+
+<ROUTINE CANT-USE (PTR "AUX" BUF)
+ <TELL "You used the word \"">
+ <WORD-PRINT <GETB <REST ,P-LEXV <SET BUF <* .PTR 2>>> 2>
+ <GETB <REST ,P-LEXV .BUF> 3>>
+ <TELL "\" in a way that I don't understand." CR>
+ <SETG QUOTE-FLAG <>>
+ <SETG P-OFLAG <>>>
+
+" Perform syntax matching operations, using P-ITBL as the source of
+ the verb and adjectives for this input. Returns false if no
+ syntax matches, and does it's own orphaning. If return is true,
+ the syntax is saved in P-SYNTAX."
+
+<GLOBAL P-SYNTAX 0> ;"where the actual syntax found is saved"
+<GLOBAL P-SLOCBITS 0> ;"location bits (where to look)"
+
+"definition of a syntax"
+
+<CONSTANT P-SYNLEN 8> ;"length in bytes"
+<CONSTANT P-SBITS 0>
+<CONSTANT P-SPREP1 1>
+<CONSTANT P-SPREP2 2>
+<CONSTANT P-SFWIM1 3>
+<CONSTANT P-SFWIM2 4>
+<CONSTANT P-SLOC1 5>
+<CONSTANT P-SLOC2 6>
+<CONSTANT P-SACTION 7>
+<CONSTANT P-SONUMS 3>
+
+<ROUTINE SYNTAX-CHECK
+ ("AUX" SYN LEN NUM OBJ (DRIVE1 <>) (DRIVE2 <>) PREP VERB TMP)
+ <COND (<ZERO? <SET VERB <GET ,P-ITBL ,P-VERB>>>
+ <TELL "There was no verb in that sentence!" CR>
+ <RFALSE>)>
+ <SET SYN <GET ,VERBS <- 255 .VERB>>>
+ <SET LEN <GETB .SYN 0>>
+ <SET SYN <REST .SYN>>
+ <REPEAT ()
+ <SET NUM <BAND <GETB .SYN ,P-SBITS> ,P-SONUMS>>
+ <COND (<G? ,P-NCN .NUM> T)
+ (<AND <NOT <L? .NUM 1>>
+ <ZERO? ,P-NCN>
+ <OR <ZERO? <SET PREP <GET ,P-ITBL ,P-PREP1>>>
+ <EQUAL? .PREP <GETB .SYN ,P-SPREP1>>>>
+ <SET DRIVE1 .SYN>)
+ (<EQUAL? <GETB .SYN ,P-SPREP1> <GET ,P-ITBL ,P-PREP1>>
+ <COND (<AND <EQUAL? .NUM 2> <EQUAL? ,P-NCN 1>>
+ <SET DRIVE2 .SYN>)
+ (<EQUAL? <GETB .SYN ,P-SPREP2>
+ <GET ,P-ITBL ,P-PREP2>>
+ <SYNTAX-FOUND .SYN>
+ <RTRUE>)>)>
+ <COND (<DLESS? LEN 1>
+ <COND (<OR .DRIVE1 .DRIVE2> <RETURN>)
+ (T
+ <TELL ,NOT-RECOGNIZED CR>
+ <RFALSE>)>)
+ (T <SET SYN <REST .SYN ,P-SYNLEN>>)>>
+ <COND (<AND .DRIVE1
+ <SET OBJ
+ <GWIM <GETB .DRIVE1 ,P-SFWIM1>
+ <GETB .DRIVE1 ,P-SLOC1>
+ <GETB .DRIVE1 ,P-SPREP1>>>>
+ <PUT ,P-PRSO ,P-MATCHLEN 1>
+ <PUT ,P-PRSO 1 .OBJ>
+ <SYNTAX-FOUND .DRIVE1>)
+ (<AND .DRIVE2
+ <SET OBJ
+ <GWIM <GETB .DRIVE2 ,P-SFWIM2>
+ <GETB .DRIVE2 ,P-SLOC2>
+ <GETB .DRIVE2 ,P-SPREP2>>>>
+ <PUT ,P-PRSI ,P-MATCHLEN 1>
+ <PUT ,P-PRSI 1 .OBJ>
+ <SYNTAX-FOUND .DRIVE2>)
+ (<EQUAL? .VERB ,ACT?FIND ;,ACT?WHAT>
+ <TELL "I can't answer that question." CR>
+ <RFALSE>)
+ (<NOT <EQUAL? ,WINNER ,PLAYER>>
+ <TELL
+"I don't understand. What are you referring to?" CR>
+ <RFALSE>)
+ (T
+ <ORPHAN .DRIVE1 .DRIVE2>
+ <TELL ,WHAT-DO-YOU-WANT-TO>
+ <SET TMP <GET ,P-OTBL ,P-VERBN>>
+ <COND (<EQUAL? .TMP 0>
+ <TELL "tell">)
+ (<ZERO? <GETB ,P-VTBL 2>>
+ <PRINTB <GET .TMP 0>>)
+ (T
+ <WORD-PRINT <GETB .TMP 2> <GETB .TMP 3>>
+ <PUTB ,P-VTBL 2 0>)>
+ <COND (.DRIVE2
+ <TELL " ">
+ <THING-PRINT T T>)>
+ <SETG P-OFLAG T>
+ <PREP-PRINT <COND (.DRIVE1 <GETB .DRIVE1 ,P-SPREP1>)
+ (T <GETB .DRIVE2 ,P-SPREP2>)>>
+ <TELL "?" CR>
+ <RFALSE>)>>
+
+<GLOBAL NOT-RECOGNIZED "That sentence isn't one I recognize.">
+
+
+<ROUTINE ORPHAN (D1 D2 "AUX" (CNT -1))
+ <COND (<NOT ,P-MERGED>
+ <PUT ,P-OCL1 ,P-MATCHLEN 0>
+ <PUT ,P-OCL2 ,P-MATCHLEN 0>)>
+ <PUT ,P-OVTBL 0 <GET ,P-VTBL 0>>
+ <PUTB ,P-OVTBL 2 <GETB ,P-VTBL 2>>
+ <PUTB ,P-OVTBL 3 <GETB ,P-VTBL 3>>
+ <REPEAT ()
+ <COND (<IGRTR? CNT ,P-ITBLLEN> <RETURN>)
+ (T <PUT ,P-OTBL .CNT <GET ,P-ITBL .CNT>>)>>
+ <COND (<EQUAL? ,P-NCN 2>
+ <PUT ,P-CCTBL ,CC-BEG ,P-NC2>
+ <PUT ,P-CCTBL ,CC-END ,P-NC2L>
+ <PUT ,P-CCTBL ,CC-CLAUSE ,P-OCL2>
+ <PUT ,P-CCTBL ,CC-IBEG <>>
+ <PUT ,P-CCTBL ,CC-IEND <>>
+ <CLAUSE-COPY ,P-ITBL ,P-OTBL>)>
+ <COND (<NOT <L? ,P-NCN 1>>
+ <PUT ,P-CCTBL ,CC-BEG ,P-NC1>
+ <PUT ,P-CCTBL ,CC-END ,P-NC1L>
+ <PUT ,P-CCTBL ,CC-CLAUSE ,P-OCL1>
+ <PUT ,P-CCTBL ,CC-IBEG <>>
+ <PUT ,P-CCTBL ,CC-IEND <>>
+ <CLAUSE-COPY ,P-ITBL ,P-OTBL>)>
+ <COND (.D1
+ <PUT ,P-OTBL ,P-PREP1 <GETB .D1 ,P-SPREP1>>
+ <PUT ,P-OTBL ,P-NC1 1>)
+ (.D2
+ <PUT ,P-OTBL ,P-PREP2 <GETB .D2 ,P-SPREP2>>
+ <PUT ,P-OTBL ,P-NC2 1>)>>
+
+;<ROUTINE ORPHAN-VERB (WRD ACT)
+ <PUT ,P-VTBL 0 .WRD>
+ <PUT ,P-OTBL ,P-VERB .ACT>
+ <PUT ,P-OTBL ,P-VERBN ,P-VTBL>
+ <PUT ,P-OTBL ,P-PREP1 0>
+ <PUT ,P-OTBL ,P-PREP1N 0>
+ <PUT ,P-OTBL ,P-PREP2 0>
+ <PUT ,P-OTBL 5 0>
+ <PUT ,P-OTBL ,P-NC1 1>
+ <PUT ,P-OTBL ,P-NC1L 0>
+ <PUT ,P-OTBL ,P-NC2 0>
+ <PUT ,P-OTBL ,P-NC2L 0>
+ <SETG P-OFLAG T>>
+
+<ROUTINE THING-PRINT (PRSO? "OPTIONAL" (THE? <>) "AUX" BEG END)
+ <COND (.PRSO?
+ <SET BEG <GET ,P-ITBL ,P-NC1>>
+ <SET END <GET ,P-ITBL ,P-NC1L>>)
+ (ELSE
+ <SET BEG <GET ,P-ITBL ,P-NC2>>
+ <SET END <GET ,P-ITBL ,P-NC2L>>)>
+ <BUFFER-PRINT .BEG .END .THE?>>
+
+<ROUTINE BUFFER-PRINT (BEG END CP "AUX" (NOSP T) WRD (1ST? T) (PN <>) (Q? <>))
+ <REPEAT ()
+ <COND (<EQUAL? .BEG .END> <RETURN>)
+ (T
+ <SET WRD <GET .BEG 0>>
+ <COND (<EQUAL? .WRD ,W?COMMA>
+ <TELL ", ">)
+ (.NOSP <SET NOSP <>>)
+ (ELSE <TELL " ">)>
+ <COND (<EQUAL? .WRD ,W?PERIOD ,W?COMMA>
+ <SET NOSP T>)
+ (<EQUAL? .WRD ,W?ME>
+ <PRINTD ,ME>
+ <SET PN T>)
+ (<EQUAL? .WRD ,W?INTNUM>
+ <PRINTN ,P-NUMBER>
+ <SET PN T>)
+ (T
+ <COND (<AND .1ST? <NOT .PN> .CP>
+ <TELL "the ">)>
+ <COND (<OR ,P-OFLAG ,P-MERGED>
+ <PRINTB .WRD>)
+ (<AND <EQUAL? .WRD ,W?IT>
+ <ACCESSIBLE? ,P-IT-OBJECT>>
+ <PRINTD ,P-IT-OBJECT>)
+ (<AND <EQUAL? .WRD ,W?HIM>
+ <ACCESSIBLE? ,P-HIM-OBJECT>>
+ <PRINTD ,P-HIM-OBJECT>)
+ (T
+ <WORD-PRINT <GETB .BEG 2>
+ <GETB .BEG 3>>)>
+ <SET 1ST? <>>)>)>
+ <SET BEG <REST .BEG ,P-WORDLEN>>>>
+
+;<ROUTINE PRINTW (WRD "AUX" TBL)
+ <COND (<SET TBL <ZMEMQ .WRD ,LONG-WORD-TABLE>>
+ <TELL <GET .TBL 1>>)
+ (ELSE <PRINTB .WRD>)>>
+
+;<ROUTINE CAPITALIZE (PTR)
+ <COND (<OR ,P-OFLAG ,P-MERGED>
+ <PRINTW <GET .PTR 0>>)
+ (T
+ <PRINTC <- <GETB ,P-INBUF <GETB .PTR 3>> 32>>
+ <WORD-PRINT <- <GETB .PTR 2> 1> <+ <GETB .PTR 3> 1>>)>>
+
+<ROUTINE PREP-PRINT (PREP "AUX" WRD)
+ <COND (<NOT <ZERO? .PREP>>
+ <TELL " ">
+ <COND (<EQUAL? .PREP ,PR?THROUGH>
+ <TELL "through">)
+ (T
+ <SET WRD <PREP-TO-WORD .PREP>>
+ <PRINTB .WRD>)>)>>
+
+
+"CLAUSE-COPY"
+
+<GLOBAL P-CCTBL <TABLE 0 0 0 0 0>>
+
+;"pointers used by CLAUSE-COPY (source/destination beginning/end pointers)"
+<CONSTANT CC-BEG 0> ;"slot in source to start from"
+<CONSTANT CC-END 1> ;"slot in source to end at"
+<CONSTANT CC-CLAUSE 2> ;"which orphan table to use"
+<CONSTANT CC-IBEG 3> ;"insertion beginning (from lexv)"
+<CONSTANT CC-IEND 4> ;"insertion ending"
+
+"do something about duplicate words in clause?"
+
+<ROUTINE CLAUSE-COPY (SRC DEST
+ "AUX" (IBEG <>) IEND OCL BEG END BB EE OBEG CNT B E)
+ <SET BB <GET ,P-CCTBL ,CC-BEG>>
+ <SET EE <GET ,P-CCTBL ,CC-END>>
+ <SET OCL <GET ,P-CCTBL ,CC-CLAUSE>>
+ <SET IBEG <GET ,P-CCTBL ,CC-IBEG>>
+ <SET IEND <GET ,P-CCTBL ,CC-IEND>>
+ <SET BEG <GET .SRC .BB>>
+ <SET END <GET .SRC .EE>>
+ <SET OBEG <GET .OCL ,P-MATCHLEN>>
+ <REPEAT ()
+ <COND (<EQUAL? .BEG .END>
+ <COND (<AND .IBEG <NOT ,P-ANAM>>
+ <CLAUSE-SUBSTRUC .IBEG .IEND>)>
+ <RETURN>)>
+ <COND (<AND .IBEG
+ <EQUAL? ,P-ANAM <GET .BEG 0>>>
+ <CLAUSE-SUBSTRUC .IBEG .IEND>)>
+ <CLAUSE-ADD <GET .BEG 0>>
+ <SET BEG <REST .BEG ,P-WORDLEN>>>
+ <COND (<AND <G? .OBEG 0>
+ <G? <SET CNT <- <GET .OCL ,P-MATCHLEN> .OBEG>> 0>>
+ <PUT .OCL ,P-MATCHLEN 0>
+ <SET OBEG <+ .OBEG 1>>
+ <REPEAT ()
+ <CLAUSE-ADD <GET .OCL .OBEG> T>
+ <COND (<ZERO? <SET CNT <- .CNT 2>>>
+ <RETURN>)>
+ <SET OBEG <+ .OBEG 2>>>
+ <SET OBEG 0>)>
+ <PUT .DEST
+ .BB
+ <REST .OCL <+ <* .OBEG ,P-LEXELEN> 2>>>
+ <PUT .DEST
+ .EE
+ <REST .OCL
+ <+ <* <GET .OCL ,P-MATCHLEN> ,P-LEXELEN> 2>>>>
+
+<ROUTINE CLAUSE-SUBSTRUC (B E)
+ <REPEAT ()
+ <COND (<EQUAL? .B .E> <RETURN>)>
+ <CLAUSE-ADD <GET .B 0>>
+ <SET B <REST .B ,P-WORDLEN>>>>
+
+<ROUTINE CLAUSE-ADD (WRD "OPT" (CHECK? <>) "AUX" OCL PTR)
+ <SET OCL <GET ,P-CCTBL ,CC-CLAUSE>>
+ <SET PTR <GET .OCL ,P-MATCHLEN>>
+ <COND (<AND .CHECK? <NOT <ZERO? .PTR>> <ZMEMQ .WRD .OCL>>
+ <RFALSE>)
+ (ELSE
+ <SET PTR <+ .PTR 2>>
+ <PUT .OCL <- .PTR 1> .WRD>
+ <PUT .OCL .PTR 0>
+ <PUT .OCL ,P-MATCHLEN .PTR>)>>
+
+
+
+<ROUTINE PREP-TO-WORD (PREP "AUX" (CNT 2) SIZE)
+ <SET SIZE <GET ,PREPOSITIONS 0>>
+ <REPEAT ()
+ <COND (<DLESS? SIZE 0> <RFALSE>)
+ (<EQUAL? <GET ,PREPOSITIONS .CNT> .PREP>
+ <RETURN <GET ,PREPOSITIONS <- .CNT 1>>>)
+ (ELSE
+ <SET CNT <+ .CNT 2>>)>>>
+
+<ROUTINE SYNTAX-FOUND (SYN)
+ <SETG P-SYNTAX .SYN>
+ <SETG PRSA <GETB .SYN ,P-SACTION>>>
+
+<GLOBAL P-GWIMBIT 0>
+
+<ROUTINE GWIM (GBIT LBIT PREP "AUX" OBJ)
+ <COND (<EQUAL? .GBIT ,RLANDBIT>
+ <RETURN ,ROOMS>)>
+ <SETG P-GWIMBIT .GBIT>
+ <SETG P-SLOCBITS .LBIT>
+ <PUT ,P-MERGE ,P-MATCHLEN 0>
+ <COND (<GET-OBJECT ,P-MERGE <>>
+ <SETG P-GWIMBIT 0>
+ <COND (<EQUAL? <GET ,P-MERGE ,P-MATCHLEN> 1>
+ <SET OBJ <GET ,P-MERGE 1>>
+ <TELL "(">
+ <COND (<AND <NOT <ZERO? .PREP>>
+ <NOT ,P-END-ON-PREP>>
+ <PRINTB <SET PREP <PREP-TO-WORD .PREP>>>
+ <COND (<EQUAL? .PREP ,W?OUT>
+ <TELL " of">)>
+ <TELL " ">
+ <COND (<EQUAL? .OBJ ,HANDS>
+ <TELL D .OBJ>)
+ (ELSE
+ <TELL THE .OBJ>)>
+ <TELL ")" CR>)
+ (ELSE
+ <TELL D .OBJ ")" CR>)>
+ .OBJ)>)
+ (T <SETG P-GWIMBIT 0> <RFALSE>)>>
+
+<ROUTINE SNARF-OBJECTS ("AUX" OPTR IPTR L)
+ <PUT ,P-BUTS ,P-MATCHLEN 0>
+ <COND (<NOT <EQUAL? <SET IPTR <GET ,P-ITBL ,P-NC2>> 0>>
+ <SETG P-SLOCBITS <GETB ,P-SYNTAX ,P-SLOC2>>
+ <OR <SNARFEM .IPTR <GET ,P-ITBL ,P-NC2L> ,P-PRSI> <RFALSE>>)>
+ <COND (<NOT <EQUAL? <SET OPTR <GET ,P-ITBL ,P-NC1>> 0>>
+ <SETG P-SLOCBITS <GETB ,P-SYNTAX ,P-SLOC1>>
+ <OR <SNARFEM .OPTR <GET ,P-ITBL ,P-NC1L> ,P-PRSO> <RFALSE>>)>
+ <COND (<NOT <ZERO? <GET ,P-BUTS ,P-MATCHLEN>>>
+ <SET L <GET ,P-PRSO ,P-MATCHLEN>>
+ <COND (.OPTR <SETG P-PRSO <BUT-MERGE ,P-PRSO>>)>
+ <COND (<AND .IPTR
+ <OR <NOT .OPTR>
+ <EQUAL? .L <GET ,P-PRSO ,P-MATCHLEN>>>>
+ <SETG P-PRSI <BUT-MERGE ,P-PRSI>>)>)>
+ <RTRUE>>
+
+%<DEBUG-CODE
+ <ROUTINE TELL-LIST (TBL NUM "AUX" (CNT 1))
+ <COND (<ZERO? .NUM> <TELL "<>">)
+ (ELSE
+ <REPEAT ()
+ <PRINTD <GET .TBL .CNT>>
+ <SET CNT <+ .CNT 1>>
+ <COND (<G? .CNT .NUM> <RETURN>)>
+ <PRINTI ", ">>)>>>
+
+
+<ROUTINE BUT-MERGE (TBL "AUX" LEN BUTLEN (CNT 1) (MATCHES 0) OBJ NTBL)
+ <SET LEN <GET .TBL ,P-MATCHLEN>>
+ <PUT ,P-MERGE ,P-MATCHLEN 0>
+ <REPEAT ()
+ <COND (<DLESS? LEN 0> <RETURN>)
+ (<ZMEMQ <SET OBJ <GET .TBL .CNT>> ,P-BUTS>)
+ (T
+ <PUT ,P-MERGE <+ .MATCHES 1> .OBJ>
+ <SET MATCHES <+ .MATCHES 1>>)>
+ <SET CNT <+ .CNT 1>>>
+ <PUT ,P-MERGE ,P-MATCHLEN .MATCHES>
+ <SET NTBL ,P-MERGE>
+ <SETG P-MERGE .TBL>
+ .NTBL>
+
+"ADJ/NOUN COMBINATION"
+
+<GLOBAL P-NAM <>>
+<GLOBAL P-ADJT <ITABLE 5 0>>
+<GLOBAL P-ADJNT <ITABLE 5 0>>
+
+"AMBIGUOUS ADJ/NOUN COMBINATION"
+
+<GLOBAL P-ANAM <>>
+;<GLOBAL P-AADJNT <ITABLE 5 0>>
+
+"PSEUDO-OBJECT ADJ-NOUN COMBINATION"
+
+<GLOBAL P-PNAM <>>
+;<GLOBAL P-PADJNT <ITABLE 5 0>>
+
+<GLOBAL P-ADVERB <>>
+
+<GLOBAL P-PRSO <ITABLE 80 <>>>
+
+<GLOBAL P-PRSI <ITABLE 80 <>>>
+
+<GLOBAL P-BUTS <ITABLE 80 <>>>
+
+<GLOBAL P-MERGE <ITABLE 80 <>>>
+
+<GLOBAL P-OCL1 <ITABLE NONE 40>>
+<GLOBAL P-OCL2 <ITABLE NONE 40>>
+
+<GLOBAL P-MATCHLEN 0>
+
+<GLOBAL P-GETFLAGS 0>
+
+<CONSTANT P-ALL 1>
+
+<CONSTANT P-ONE 2>
+
+<CONSTANT P-INHIBIT 4>
+
+
+<ROUTINE SNARFEM (PTR EPTR TBL "AUX" (BUT <>) LEN WV WRD NW (WAS-ALL <>))
+ <SETG P-AND <>>
+ <COND (<EQUAL? ,P-GETFLAGS ,P-ALL>
+ <SET WAS-ALL T>)>
+ <SETG P-GETFLAGS 0>
+ <PUT .TBL ,P-MATCHLEN 0>
+ <SET WRD <GET .PTR 0>>
+ <REPEAT ()
+ <COND (<EQUAL? .PTR .EPTR>
+ <SET WV <GET-OBJECT <OR .BUT .TBL>>>
+ <COND (.WAS-ALL <SETG P-GETFLAGS ,P-ALL>)>
+ <RETURN .WV>)
+ (T
+ <COND (<==? .EPTR <REST .PTR ,P-WORDLEN>>
+ <SET NW 0>)
+ (T <SET NW <GET .PTR ,P-LEXELEN>>)>
+ <COND (<EQUAL? .WRD ,W?ALL ,W?BOTH>
+ <SETG P-GETFLAGS ,P-ALL>
+ <COND (<EQUAL? .NW ,W?OF>
+ <SET PTR <REST .PTR ,P-WORDLEN>>)>)
+ (<EQUAL? .WRD ,W?BUT ,W?EXCEPT>
+ <OR <GET-OBJECT <OR .BUT .TBL>> <RFALSE>>
+ <SET BUT ,P-BUTS>
+ <PUT .BUT ,P-MATCHLEN 0>)
+ (<EQUAL? .WRD ,W?A ,W?ONE>
+ <COND (<ZERO? <GET ,P-ADJT 0>> ;<NOT ,P-ADJ>
+ <SETG P-GETFLAGS ,P-ONE>
+ <COND (<EQUAL? .NW ,W?OF>
+ <SET PTR <REST .PTR ,P-WORDLEN>>)>)
+ (T
+ <SETG P-NAM ,P-ONEOBJ>
+ <OR <GET-OBJECT <OR .BUT .TBL>> <RFALSE>>
+ <AND <ZERO? .NW> <RTRUE>>)>)
+ (<AND <EQUAL? .WRD ,W?AND ,W?COMMA>
+ <NOT <EQUAL? .NW ,W?AND ,W?COMMA>>>
+ <SETG P-AND T>
+ <OR <GET-OBJECT <OR .BUT .TBL>> <RFALSE>>
+ T)
+ (<NOT <ZERO? <WT? .WRD ,PS?BUZZ-WORD>>>)
+ (<EQUAL? .WRD ,W?AND ,W?COMMA>)
+ (<EQUAL? .WRD ,W?OF>
+ <COND (<ZERO? ,P-GETFLAGS>
+ <SETG P-GETFLAGS ,P-INHIBIT>)>)
+ (<NOT <ZERO?
+ <SET WV
+ <WT? .WRD
+ ,PS?ADJECTIVE ,P1?ADJECTIVE>>>>
+ <NEW-ADJ .WV .WRD>)
+ (<WT? .WRD ,PS?OBJECT ,P1?OBJECT>
+ <SETG P-NAM .WRD>
+ <SETG P-ONEOBJ .WRD>)>)>
+ <COND (<NOT <EQUAL? .PTR .EPTR>>
+ <SET PTR <REST .PTR ,P-WORDLEN>>
+ <SET WRD .NW>)>>>
+
+"add an adjective value and name to the adjective table"
+
+<ROUTINE NEW-ADJ ("OPT" (WV <>) (WRD <>) "AUX" N)
+ <COND (<NOT .WV>
+ <SETG P-NAM <>>
+ <PUT ,P-ADJT 0 0>
+ <PUT ,P-ADJNT 0 0>)
+ (ELSE
+ <SET N <GET ,P-ADJT 0>>
+ <COND (<L? .N 4> <SET N <+ .N 1>>)>
+ <PUT ,P-ADJT 0 .N>
+ <PUT ,P-ADJT .N .WV>
+ <PUT ,P-ADJNT 0 .N>
+ <PUT ,P-ADJNT .N .WRD>)>>
+
+<ROUTINE COPY-ADJ (SRC DST "AUX" N)
+ <SET N <GET .SRC 0>>
+ <REPEAT ()
+ <PUT .DST .N <GET .SRC .N>>
+ <COND (<L? <SET N <- .N 1>> 0>
+ <RTRUE>)>>>
+
+"magic bits for syntaxes"
+
+<CONSTANT SH 128> ;"HELD"
+<CONSTANT SC 64> ;"CARRIED"
+<CONSTANT SIR 32> ;"IN-ROOM"
+<CONSTANT SOG 16> ;"ON-GROUND"
+<CONSTANT STAKE 8> ;"TAKE"
+<CONSTANT SMANY 4> ;"MANY"
+<CONSTANT SHAVE 2> ;"HAVE"
+
+<GLOBAL NOUN-MISSING "There seems to be a noun missing in that sentence.">
+
+<ROUTINE SEARCH-CONTENTS? (OBJ)
+ <COND (<FSET? .OBJ ,INVISIBLE> <RFALSE>)
+ (<AND <FSET? .OBJ ,SEARCHBIT>
+ <OR <FSET? .OBJ ,OPENBIT>
+ <FSET? .OBJ ,TRANSBIT>>>
+ <RTRUE>)
+ (<FSET? .OBJ ,SURFACEBIT>
+ <RTRUE>)>>
+
+<ROUTINE GET-OBJECT (TBL "OPTIONAL" (VRB T)
+ "AUX" GEN BITS LEN XBITS TLEN (GCHECK <>) (OLEN 0) OBJ)
+ <SET XBITS ,P-SLOCBITS>
+ <SET TLEN <GET .TBL ,P-MATCHLEN>>
+ <COND (<BTST ,P-GETFLAGS ,P-INHIBIT> <RTRUE>)>
+ <COND (<AND <NOT ,P-NAM>
+ <NOT <ZERO? <SET LEN <GET ,P-ADJNT 0>>>>>
+ <COND (<NOT <ZERO? <WT? <GET ,P-ADJNT .LEN>
+ ,PS?OBJECT ,P1?OBJECT>>>
+ <SETG P-NAM <GET ,P-ADJNT <GET ,P-ADJNT 0>>>
+ <PUT ,P-ADJT 0 <- .LEN 1>>
+ <PUT ,P-ADJNT 0 <- .LEN 1>>)
+ (<AND <EQUAL? .LEN 1>
+ <SET BITS
+ <WT? <GET ,P-ADJNT 1>
+ ,PS?DIRECTION
+ ,P1?DIRECTION>>>
+ <PUT ,P-ADJT 0 0>
+ <PUT ,P-ADJNT 0 0>
+ <PUT .TBL ,P-MATCHLEN 1>
+ <PUT .TBL 1 ,INTDIR>
+ <SETG P-DIRECTION .BITS>
+ <RTRUE>)>)>
+ <COND (<AND <NOT ,P-NAM>
+ <ZERO? <GET ,P-ADJT 0>>
+ <NOT <EQUAL? ,P-GETFLAGS ,P-ALL>>
+ <ZERO? ,P-GWIMBIT>>
+ <COND (.VRB
+ <TELL ,NOUN-MISSING CR>)>
+ <RFALSE>)>
+ <COND (<OR <NOT <EQUAL? ,P-GETFLAGS ,P-ALL>> <ZERO? ,P-SLOCBITS>>
+ <SETG P-SLOCBITS -1>)>
+ <SETG P-TABLE .TBL>
+ <PROG ()
+ <COND (.GCHECK <GLOBAL-CHECK .TBL>)
+ (T
+ <COND (,LIT
+ <DO-SL ,HERE ,SOG ,SIR>
+ <COND (<AND <FSET? <LOC ,PLAYER> ,VEHBIT>
+ <NOT <SEARCH-CONTENTS?
+ <LOC ,PLAYER>>>>
+ <DO-SL <LOC ,PLAYER> ,SOG ,SIR>)>)>
+ <DO-SL ,PLAYER ,SH ,SC>)>
+ <SET LEN <- <GET .TBL ,P-MATCHLEN> .TLEN>>
+ <COND (<BTST ,P-GETFLAGS ,P-ALL> ;<AND * <NOT <EQUAL? .LEN 0>>>)
+ (<AND <BTST ,P-GETFLAGS ,P-ONE>
+ <NOT <ZERO? .LEN>>>
+ <COND (<NOT <EQUAL? .LEN 1>>
+ <PUT .TBL 1 <GET .TBL <RANDOM .LEN>>>
+ <TELL "(How about " THE <GET .TBL 1> "?)" CR>)>
+ <PUT .TBL ,P-MATCHLEN 1>)
+ (<OR <G? .LEN 1>
+ <AND <ZERO? .LEN> <NOT <EQUAL? ,P-SLOCBITS -1>>>>
+ <COND (<EQUAL? ,P-SLOCBITS -1>
+ <SETG P-SLOCBITS .XBITS>
+ <SET OLEN .LEN>
+ <PUT .TBL
+ ,P-MATCHLEN
+ <- <GET .TBL ,P-MATCHLEN> .LEN>>
+ <AGAIN>)
+ (T
+ <COND (<ZERO? .LEN> <SET LEN .OLEN>)>
+ <COND (<AND <G? .LEN 1>
+ <SET GEN <GENERIC? .TBL .LEN>>>
+ <PUT .TBL
+ ,P-MATCHLEN
+ <SET LEN <+ .TLEN 1>>>
+ <PUT .TBL .LEN .GEN>
+ <SETUP-XADJ>
+ <RTRUE>)
+ (<AND .VRB ;".VRB added 8/14/84 by JW"
+ <NOT <EQUAL? ,WINNER ,PLAYER>>>
+ <WHICH-PRINT .TLEN .LEN .TBL>)
+ (<AND .VRB
+ <OR ,P-NAM
+ <NOT <ZERO? <GET ,P-ADJT 0>>>>>
+ <WHICH-PRINT .TLEN .LEN .TBL>
+ <SETG P-ACLAUSE
+ <COND (<EQUAL? .TBL ,P-PRSO> ,P-NC1)
+ (T ,P-NC2)>>
+ ;<COPY-ADJ ,P-ADJNT ,P-AADJNT>
+ ;<SETG P-AADJ ,P-ADJ>
+ <SETG P-ANAM ,P-NAM>
+ <ORPHAN <> <>>
+ <SETG P-OFLAG T>)
+ (.VRB
+ <TELL ,NOUN-MISSING CR>)>
+ <NEW-ADJ>
+ <RFALSE>)>)>
+ <COND (<AND <ZERO? .LEN> .GCHECK>
+ <COND (.VRB
+ <SETG P-SLOCBITS .XBITS>
+ <COND (<OR ,LIT
+ <AND <EQUAL? .TBL ,P-PRSO>
+ <VERB? TELL WHERE WHAT WHO
+ FOLLOW WAIT-FOR>>
+ <AND <EQUAL? .TBL ,P-PRSI>
+ <VERB? ASK-ABOUT ASK-FOR
+ TELL-ABOUT>>>
+ ;"Changed 6/10/83 - MARC"
+ <OBJ-FOUND ,NOT-HERE-OBJECT .TBL>
+ <SETUP-XADJ>
+ <RTRUE>)
+ (T
+ <TELL ,TOO-DARK>)>)>
+ <NEW-ADJ>
+ <RFALSE>)
+ (<ZERO? .LEN> <SET GCHECK T> <AGAIN>)>
+ <SETG P-SLOCBITS .XBITS>
+ <NEW-ADJ>
+ <RTRUE>>>
+
+<ROUTINE SETUP-XADJ ()
+ <SETG P-XNAM ,P-NAM>
+ <COPY-ADJ ,P-ADJT ,P-XADJT>
+ <COPY-ADJ ,P-ADJNT ,P-XADJNT>
+ <NEW-ADJ>>
+
+<ROUTINE MOBY-FIND (TBL "AUX" FOO LEN GEN)
+ <SETG P-MOBY-FLAG T>
+ <SETG P-SLOCBITS -1>
+ <SETG P-TABLE .TBL>
+ <SETG P-NAM ,P-XNAM>
+ <COPY-ADJ ,P-XADJT ,P-ADJT> ;<SETG P-ADJ ,P-XADJ>
+ <PUT .TBL ,P-MATCHLEN 0>
+ <SET FOO <FIRST? ,ROOMS>>
+ <REPEAT ()
+ <COND (<NOT .FOO> <RETURN>)
+ (T
+ <SEARCH-LIST .FOO .TBL ,P-SRCALL>
+ <SET FOO <NEXT? .FOO>>)>>
+ <DO-SL ,LOCAL-GLOBALS 1 1>
+ <SEARCH-LIST ,ROOMS .TBL ,P-SRCTOP>
+ <COND (<EQUAL? <SET LEN <GET .TBL ,P-MATCHLEN>> 1>
+ <SETG P-MOBY-FOUND <GET .TBL 1>>)
+ (<AND <G? .LEN 1>
+ <SET GEN <GENERIC? .TBL .LEN>>>
+ <SET LEN 1>
+ <SETG P-MOBY-FOUND .GEN>)>
+ <SETG P-MOBY-FLAG <>>
+ <NEW-ADJ>
+ .LEN>
+
+<GLOBAL P-MOBY-FOUND <>>
+<GLOBAL P-MOBY-FLAG <>>
+
+<GLOBAL P-XNAM <>>
+<GLOBAL P-XADJT <ITABLE 5 0>>
+<GLOBAL P-XADJNT <ITABLE 5 0>>
+
+<ROUTINE GENERIC? (TBL LEN "AUX" (GEN <>) G (N 0))
+ <COND (<G? .LEN 1>
+ <REPEAT ()
+ <COND (<G? <SET N <+ .N 1>> .LEN>
+ <RETURN <APPLY .GEN>>)
+ (ELSE
+ <SET G <GETP <GET .TBL .N> ,P?GENERIC>>
+ <COND (<NOT .GEN> <SET GEN .G>)
+ (<NOT <EQUAL? .GEN .G>>
+ <RFALSE>)>)>>)>>
+
+<ROUTINE WHICH-PRINT (TLEN LEN TBL "AUX" OBJ RLEN)
+ <COND (<ZERO? .LEN>
+ <TELL ,REFERRING CR>
+ <RTRUE>)>
+ <SET RLEN .LEN>
+ <COND (<NOT <==? ,WINNER ,PLAYER>>
+ <TELL "\"I don't understand if you mean ">)
+ (T
+ <TELL "Which ">
+ <COND (<OR ,P-OFLAG ,P-MERGED ,P-AND>
+ <COND (<PRINT-ADJT ,P-ADJNT>
+ <COND (,P-NAM <TELL " "> <PRINTB ,P-NAM>)>)
+ (,P-NAM <PRINTB ,P-NAM>)
+ (ELSE <PRINTB ,W?ONE>)>)
+ (ELSE
+ <THING-PRINT <EQUAL? .TBL ,P-PRSO>>)>
+ <TELL " do you mean, ">)>
+ <REPEAT ()
+ <SET TLEN <+ .TLEN 1>>
+ <SET OBJ <GET .TBL .TLEN>>
+ <COND (<EQUAL? .OBJ ,FLOOR-BUTTON>
+ <TELL "the 1 button, the 2 button, the 3 button">)
+ (ELSE
+ <TELL THE .OBJ>)>
+ <COND (<EQUAL? .LEN 2>
+ <COND (<NOT <EQUAL? .RLEN 2>>
+ <TELL ",">)>
+ <TELL " or ">)
+ (<G? .LEN 2>
+ <TELL ", ">)>
+ <COND (<L? <SET LEN <- .LEN 1>> 1>
+ <RETURN>)>>
+ <COND (<NOT <==? ,WINNER ,PLAYER>>
+ <TELL ".\"" CR>)
+ (T
+ <TELL "?" CR>)>>
+
+<ROUTINE PRINT-ADJT (TBL "AUX" N (CNT 0))
+ <COND (<NOT <ZERO? <SET N <GET .TBL 0>>>>
+ <REPEAT ()
+ <PRINTB <GET .TBL .N>>
+ <COND (<ZERO? <SET N <- .N 1>>>
+ <RTRUE>)>
+ <TELL " ">>)>>
+
+
+
+<ROUTINE GLOBAL-CHECK (TBL "AUX" LEN RMG RMGL (CNT 0) OBJ OBITS FOO NOBJ)
+ <SET LEN <GET .TBL ,P-MATCHLEN>>
+ <SET OBITS ,P-SLOCBITS>
+ <COND (<SET RMG <GETPT ,HERE ,P?GLOBAL>>
+ <SET RMGL <- <PTSIZE .RMG> 1>>
+ <REPEAT ()
+ <COND (<SET OBJ <GETB .RMG .CNT>>
+ <COND (<THIS-IT? .OBJ .TBL>
+ <OBJ-FOUND .OBJ .TBL>)>
+ <COND (<AND <SEARCH-CONTENTS? .OBJ>
+ <SET NOBJ <FIRST? .OBJ>>>
+ <SEARCH-LIST .OBJ .TBL ,P-SRCALL>)>)>
+ <COND (<IGRTR? CNT .RMGL> <RETURN>)>>)>
+ <COND (<SET RMG <GETP ,HERE ,P?THINGS>>
+ <SET RMGL <GET .RMG 0>>
+ <SET CNT 0>
+ <REPEAT ()
+ <COND (<AND <EQUAL? ,P-NAM <GET .RMG <+ .CNT 2>>>
+ <OR <ZERO? <GET ,P-ADJT 0>>
+ <ZMEMQ <GET .RMG <+ .CNT 1>>
+ ,P-ADJNT>
+ ;<EQUAL? ,P-ADJN
+ <GET .RMG <+ .CNT 2>>>>>
+ <SETG P-PNAM ,P-NAM>
+ ;<COND (<NOT <ZERO? <GET ,P-ADJT 0>>>
+ <COPY-ADJ ,P-ADJNT ,P-PADJNT>
+ ;<SETG P-PADJNT ,P-ADJNT>)
+ (ELSE
+ <PUT ,P-PADJNT 0 0>
+ ;<SETG P-PADJN <>>)>
+ <SETG LAST-PSEUDO-LOC ,HERE>
+ <PUTP ,PSEUDO-OBJECT
+ ,P?ACTION
+ ,RANDOM-PSEUDO ;<GET .RMG <+ .CNT 2>>>
+ <SET FOO
+ <BACK <GETPT ,PSEUDO-OBJECT ,P?ACTION> 5>>
+ <PUT .FOO 0 <GET ,P-NAM 0>>
+ <PUT .FOO 1 <GET ,P-NAM 1>>
+ <OBJ-FOUND ,PSEUDO-OBJECT .TBL>
+ <RETURN>)>
+ <SET CNT <+ .CNT 2>>
+ <COND (<NOT <L? .CNT .RMGL>> <RETURN>)>>)>
+ <COND (<EQUAL? <GET .TBL ,P-MATCHLEN> .LEN>
+ <SETG P-SLOCBITS -1>
+ <SETG P-TABLE .TBL>
+ <DO-SL ,GLOBAL-OBJECTS 1 1>
+ <SETG P-SLOCBITS .OBITS>
+ ;<COND (<AND <ZERO? <GET .TBL ,P-MATCHLEN>>
+ <EQUAL? ,PRSA ,V?LOOK-INSIDE ,V?SEARCH ,V?EXAMINE>>
+ <DO-SL ,ROOMS 1 1>)>)>>
+
+<GLOBAL P-TABLE <>> ;"DO-SL outputs stuff to this table"
+
+<CONSTANT P-SRCBOT 2>
+<CONSTANT P-SRCALL 1>
+<CONSTANT P-SRCTOP 0>
+
+<ROUTINE DO-SL (OBJ BIT1 BIT2 "AUX" BTS)
+ <COND (<BTST ,P-SLOCBITS <+ .BIT1 .BIT2>>
+ <SEARCH-LIST .OBJ ,P-TABLE ,P-SRCALL>)
+ (T
+ <COND (<BTST ,P-SLOCBITS .BIT1>
+ <SEARCH-LIST .OBJ ,P-TABLE ,P-SRCTOP>)
+ (<BTST ,P-SLOCBITS .BIT2>
+ <SEARCH-LIST .OBJ ,P-TABLE ,P-SRCBOT>)
+ (T <RTRUE>)>)>>
+
+<ROUTINE SEARCH-LIST (OBJ TBL LVL "AUX" ROBJ)
+ <COND (<SET OBJ <FIRST? .OBJ>>
+ <REPEAT ()
+ <COND (<AND <NOT <EQUAL? .LVL ,P-SRCBOT>>
+ <GETPT .OBJ ,P?SYNONYM>
+ <THIS-IT? .OBJ .TBL>>
+ <OBJ-FOUND .OBJ .TBL>)>
+ <COND (<EQUAL? .OBJ ,ELEVATOR-DOOR>
+ <SET ROBJ <DOOR-AT-ELEVATOR>>)
+ (ELSE
+ <SET ROBJ .OBJ>)>
+ <COND (<AND <FIRST? .ROBJ>
+ <SEARCH-CONTENTS? .ROBJ>
+ <OR <NOT <EQUAL? .LVL ,P-SRCTOP>>
+ ,P-MOBY-FLAG>>
+ <SEARCH-LIST
+ .ROBJ
+ .TBL
+ <COND (<OR ,P-MOBY-FLAG
+ <FSET? .ROBJ ,SURFACEBIT>
+ <FSET? .ROBJ ,SEARCHBIT>>
+ ,P-SRCALL)
+ (T ,P-SRCTOP)>>)>
+ <COND (<NOT <SET OBJ <NEXT? .OBJ>>>
+ <RETURN>)>>)>>
+
+<GLOBAL P-NAMW <TABLE 0 0>> ;"table of actual noun used by player"
+<GLOBAL P-ADJW <TABLE 0 0>> ;"table of actual adj used by player"
+
+<ROUTINE OBJ-FOUND (OBJ TBL "AUX" PTR)
+ <COND (<EQUAL? .TBL ,P-PRSO>
+ <PUT ,P-NAMW 0 ,P-NAM>
+ <PUT ,P-ADJW 0 <GET ,P-ADJNT 1>>)
+ (<EQUAL? .TBL ,P-PRSI>
+ <PUT ,P-NAMW 1 ,P-NAM>
+ <PUT ,P-ADJW 1 <GET ,P-ADJNT 1>>)>
+ <SET PTR <GET .TBL ,P-MATCHLEN>>
+ <PUT .TBL <+ .PTR 1> .OBJ>
+ <PUT .TBL ,P-MATCHLEN <+ .PTR 1>>>
+
+<ROUTINE TAKE-CHECK ()
+ <AND <ITAKE-CHECK ,P-PRSO <GETB ,P-SYNTAX ,P-SLOC1>>
+ <ITAKE-CHECK ,P-PRSI <GETB ,P-SYNTAX ,P-SLOC2>>>>
+
+<ROUTINE ITAKE-CHECK (TBL IBITS "AUX" PTR OBJ TAKEN)
+ <COND (<AND <SET PTR <GET .TBL ,P-MATCHLEN>>
+ <OR <BTST .IBITS ,SHAVE>
+ <BTST .IBITS ,STAKE>>>
+ <REPEAT ()
+ <COND (<L? <SET PTR <- .PTR 1>> 0>
+ <RETURN>)
+ (T
+ <SET OBJ <GET .TBL <+ .PTR 1>>>
+ <COND (<EQUAL? .OBJ ,IT>
+ <COND (<NOT ,P-IT-OBJECT>
+ <TELL ,REFERRING CR>)
+ (<NOT <ACCESSIBLE? ,P-IT-OBJECT>>
+ <TELL
+"I don't see " THE ,P-IT-OBJECT " here." CR>
+ <RFALSE>)
+ (T
+ <SET OBJ ,P-IT-OBJECT>)>)
+ (<EQUAL? .OBJ ,HIM>
+ <COND (<NOT ,P-HIM-OBJECT>
+ <TELL ,REFERRING CR>)
+ (<NOT <ACCESSIBLE? ,P-HIM-OBJECT>>
+ <TELL
+"I don't see " THE ,P-HIM-OBJECT " here." CR>
+ <RFALSE>)
+ (T
+ <SET OBJ ,P-HIM-OBJECT>)>)>
+ <COND (<OR <HELD? .OBJ ,WINNER>
+ <INTRINSIC? .OBJ>
+ <IN? ,WINNER .OBJ>>
+ T)
+ (T
+ <SETG PRSO .OBJ>
+ <SET TAKEN T>
+ <COND (<FSET? .OBJ ,TRYTAKEBIT>
+ <SET TAKEN <>>)
+ (<NOT <EQUAL? ,WINNER ,PLAYER>>)
+ (<AND <BTST .IBITS ,STAKE>
+ <EQUAL? <ITAKE <>> T>>)
+ (T
+ <SET TAKEN <>>)>
+ <COND (<AND <NOT .TAKEN> <BTST .IBITS ,SHAVE>>
+ <COND (<L? 1 <GET .TBL ,P-MATCHLEN>>
+ <TELL
+,YOU-ARENT "holding all those things!" CR>
+ <RFALSE>)
+ (<EQUAL? .OBJ ,NOT-HERE-OBJECT>
+ <TELL ,YOU-CANT-SEE "that here!" CR>
+ <RFALSE>)
+ (<EQUAL? ,WINNER ,PLAYER>
+ <TELL ,YOU-ARENT>)
+ (T
+ <TELL S "It doesn't look like ">
+ <TELL THE ,WINNER " is ">)>
+ <TELL "holding ">
+ <COND (<EQUAL? .OBJ ,PSEUDO-OBJECT>
+ <TELL "that">)
+ (ELSE
+ <TELL THE .OBJ>)>
+ <THIS-IS-IT .OBJ>
+ <TELL ,PERIOD>
+ <RFALSE>)
+ (<AND .TAKEN
+ <EQUAL? ,WINNER ,PLAYER>
+ <NOT <PRSO? ,INTNUM>>>
+ <TAKING-FIRST .OBJ>)>)>)>>)
+ (T)>>
+
+<ROUTINE TAKING-FIRST (OBJ)
+ <TELL
+"(Taking " THE .OBJ " first)" CR>>
+
+<ROUTINE MANY-CHECK ("AUX" (LOSS <>) TMP)
+ <COND (<AND <G? <GET ,P-PRSO ,P-MATCHLEN> 1>
+ <NOT <BTST <GETB ,P-SYNTAX ,P-SLOC1> ,SMANY>>>
+ <SET LOSS 1>)
+ (<AND <G? <GET ,P-PRSI ,P-MATCHLEN> 1>
+ <NOT <BTST <GETB ,P-SYNTAX ,P-SLOC2> ,SMANY>>>
+ <SET LOSS 2>)>
+ <COND (.LOSS
+ <TELL ,YOU-CANT "use multiple ">
+ <COND (<EQUAL? .LOSS 2>
+ <TELL "in">)>
+ <TELL "direct objects with \"">
+ <SET TMP <GET ,P-ITBL ,P-VERBN>>
+ <COND (<ZERO? .TMP>
+ <TELL "tell">)
+ (<OR ,P-OFLAG ,P-MERGED>
+ <PRINTB <GET .TMP 0>>)
+ (T
+ <WORD-PRINT <GETB .TMP 2> <GETB .TMP 3>>)>
+ <TELL "\"." CR>
+ <RFALSE>)
+ (T)>>
+
+<ROUTINE ZMEMQ (ITM TBL "OPTIONAL" (SIZE -1) "AUX" (CNT 1))
+ <COND (<NOT .TBL> <RFALSE>)>
+ <COND (<NOT <L? .SIZE 0>> <SET CNT 0>)
+ (ELSE <SET SIZE <GET .TBL 0>>)>
+ <REPEAT ()
+ <COND (<EQUAL? .ITM <GET .TBL .CNT>>
+ <RETURN <REST .TBL <* .CNT 2>>>)
+ (<IGRTR? CNT .SIZE> <RFALSE>)>>>
+
+<ROUTINE ZMEMQB (ITM TBL SIZE "AUX" (CNT 0))
+ <REPEAT ()
+ <COND (<EQUAL? .ITM <GETB .TBL .CNT>>
+ <RTRUE>)
+ (<IGRTR? CNT .SIZE>
+ <RFALSE>)>>>
+
+<ROUTINE LIT? (RM "OPTIONAL" (RMBIT T) "AUX" OHERE (LIT <>))
+ <SETG P-GWIMBIT ,ONBIT>
+ <SET OHERE ,HERE>
+ <SETG HERE .RM>
+ <COND (<AND .RMBIT
+ <FSET? .RM ,ONBIT>>
+ <SET LIT ,HERE>)
+ (<AND <HERE? ,ELEVATOR-PIT>
+ <OR <FSET? ,ELEVATOR-DOOR-B ,OPENBIT>
+ <FSET? ,ELEVATOR-DOOR-1 ,OPENBIT>>>
+ <SET LIT ,CS-BASEMENT>)
+ (<AND <HERE? ,UNDER-ALCHEMY-LAB>
+ <FSET? ,ALCHEMY-TRAP-DOOR ,OPENBIT>
+ <FSET? ,ALCHEMY-LAB ,ONBIT>>
+ <SET LIT ,ALCHEMY-LAB>)
+ (<AND <FSET? ,WINNER ,ONBIT>
+ <HELD? ,WINNER .RM>>
+ <SET LIT ,WINNER>)
+ (T
+ <PUT ,P-MERGE ,P-MATCHLEN 0>
+ <SETG P-TABLE ,P-MERGE>
+ <SETG P-SLOCBITS -1>
+ <COND (<EQUAL? .OHERE .RM>
+ <DO-SL ,WINNER 1 1>
+ <COND (<AND <NOT <EQUAL? ,WINNER ,PLAYER>>
+ <IN? ,PLAYER .RM>>
+ <DO-SL ,PLAYER 1 1>)>)>
+ <COND (<AND <FSET? <LOC ,WINNER> ,VEHBIT>
+ <NOT <FSET? <LOC ,WINNER> ,OPENBIT>>>
+ <DO-SL <LOC ,WINNER> 1 1>)>
+ <DO-SL .RM 1 1>
+ <COND (<G? <GET ,P-TABLE ,P-MATCHLEN> 0>
+ <SET LIT <GET ,P-TABLE 1>>)>)>
+ <SETG HERE .OHERE>
+ <SETG P-GWIMBIT 0>
+ .LIT>
+
+;"former CRUFTY.ZIL routine"
+
+<ROUTINE THIS-IT? (OBJ TBL "AUX" SYNS ACNT)
+ <COND (<FSET? .OBJ ,INVISIBLE> <RFALSE>)
+ (<AND ,P-NAM
+ <NOT <ZMEMQ ,P-NAM
+ <SET SYNS <GETPT .OBJ ,P?SYNONYM>>
+ <- </ <PTSIZE .SYNS> 2> 1>>>>
+ <RFALSE>)
+ (<AND <NOT <ZERO? <SET ACNT <GET ,P-ADJT 0>>>>
+ <NOT <SET SYNS <GETPT .OBJ ,P?ADJECTIVE>>>>
+ <RFALSE>)
+ (ELSE
+ <COND (<NOT <ZERO? .ACNT>>
+ <REPEAT ()
+ <COND (<NOT <ZMEMQB <GET ,P-ADJT .ACNT>
+ .SYNS
+ <- <PTSIZE .SYNS> 1>>>
+ <RFALSE>)>
+ <COND (<ZERO? <SET ACNT <- .ACNT 1>>>
+ <RETURN>)>>)>
+ <COND (<AND <NOT <ZERO? ,P-GWIMBIT>>
+ <NOT <FSET? .OBJ ,P-GWIMBIT>>>
+ <RFALSE>)>)>
+ <RTRUE>>
+
+<ROUTINE END-QUOTE ()
+ <SETG QUOTE-FLAG <>>
+ <SETG P-CONT <>>
+ <RFATAL>>
diff --git a/pc.zil b/pc.zil
new file mode 100644
index 0000000..cc39f56
--- /dev/null
+++ b/pc.zil
@@ -0,0 +1,529 @@
+"PC for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+<OBJECT ASSIGNMENT
+ (IN PLAYER)
+ (DESC "assignment")
+ (SYNONYM ASSIGNMENT)
+ (FLAGS AN READBIT TAKEBIT)
+ (SIZE 1)
+ (ACTION ASSIGNMENT-F)>
+
+<ROUTINE ASSIGNMENT-F ()
+ <COND (<VERB? EXAMINE READ>
+ <TELL
+"Laser printed on creamy bond paper, the assignment is due tomorrow.
+It's from your freshman course in \"The Classics in the Modern Idiom,\"
+better known as \"21.014.\" It reads, in part: \"Twenty pages on modern
+analogues of Xenophon's 'Anabasis.'\" You're not sure whether this refers
+to the movie \"The Warriors\" or \"Alien,\" but this is the last
+assignment you need to complete in this course this term. You wonder,
+yet again, why a technical school requires you to endure this sort of
+stuff." CR>)>>
+
+<OBJECT CHAIR
+ (IN TERMINAL-ROOM)
+ (FDESC
+"Nearby is one of those ugly molded plastic chairs.")
+ (DESC "chair")
+ (SYNONYM CHAIR)
+ (ADJECTIVE MOLDED PLASTIC UGLY)
+ (FLAGS TAKEBIT VEHBIT SEARCHBIT CONTBIT OPENBIT FURNITURE SURFACEBIT)
+ (SIZE 100)
+ (ACTION CHAIR-F)>
+
+<ROUTINE CHAIR-F ("OPT" (RARG <>))
+ <COND (<RARG? BEG>
+ <COND (<QUEUED? I-COMPULSION> <RFALSE>)
+ (<VERB? WALK>
+ <MOVE ,WINNER <LOC ,CHAIR>>
+ <TELL "First, you arise from the chair." CR>)
+ (<P? SIT CHAIR>
+ <TELL ,YOU-ARE ,PERIOD>)
+ (<P? (STAND DISEMBARK) CHAIR>
+ <MOVE ,WINNER <LOC ,CHAIR>>
+ <TELL "You get out of the chair." CR>)>)
+ (<RARG? <>>
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a molded plastic chair, a cheap knock-off of a designer
+chair, and even more uncomfortable." CR>)
+ (<AND <VERB? TAKE>
+ <IN? ,HACKER ,CHAIR>>
+ <TELL "It's in use." CR>)
+ (<VERB? SIT BOARD>
+ <COND (<IN? ,HACKER ,CHAIR>
+ <TELL
+"The hacker is already using it." CR>
+ <RTRUE>)
+ (ELSE
+ <COND (<HELD? ,CHAIR>
+ <MOVE ,CHAIR <LOC ,WINNER>>)>
+ <MOVE ,WINNER ,CHAIR>
+ <TELL
+,YOU-ARE-NOW "sitting in the chair." CR>)>)>)>>
+
+<OBJECT OUTLET
+ (IN LOCAL-GLOBALS)
+ (DESC "outlet")
+ (SYNONYM OUTLET SOCKET)
+ (ADJECTIVE ELECTRIC WALL)
+ (FLAGS NDESCBIT AN)>
+
+<GLOBAL PC-UNPLUGGED? <>>
+
+<OBJECT HELP-KEY
+ (IN PC)
+ (DESC "HELP key")
+ (SYNONYM HELP KEY)
+ (ADJECTIVE HELP)
+ (FLAGS NDESCBIT READBIT)
+ (ACTION HELP-KEY-F)
+ (TEXT "It says \"HELP\" in reassuring blue letters.")>
+
+<ROUTINE HELP-KEY-F ()
+ <COND (<MOUSE-VERB?>
+ <COND (<NOT <FSET? ,PC ,POWERBIT>>
+ <TELL
+"Well," ,LC-NOTHING-HAPPENS " Perhaps you should turn on the computer?" CR>
+ <RTRUE>)>
+ <TELL
+"You push the friendly-looking HELP key. A spritely little box appears
+on the screen, which reads: \"">
+ <COND (<NOT ,LOGGED-IN?>
+ <TELL "You should ">
+ <COND (<NOT ,USERNAME?>
+ <TELL
+"\"LOGIN your-user-id\" and then ">)>
+ <TELL
+"\"PASSWORD your-password\".">)
+ (<IN? ,MORE-BOX ,PC>
+ <TELL "Please">
+ <COND (<NOT ,READ-PAGE?>
+ <TELL
+" read the page on the screen and then">)>
+ <TELL " click the MORE box.">)
+ (<IN? ,YAK-WINDOW ,PC>
+ <TELL
+"Please click the box representing the file you wish to edit or view.
+I notice that one file is marked as urgent, so you should probably click
+its box.">)
+ (<IN? ,MENU-BOX ,PC>
+ <TELL
+"You should click the menu box, as you previously set it up as an urgent
+task.">)
+ (ELSE
+ <TELL
+"I can't help you at this point.">)>
+ <TELL "\"" CR>)>>
+
+<OBJECT MOUSE
+ (IN PC)
+ (DESC "mouse")
+ (SYNONYM MOUSE)
+ (FLAGS NDESCBIT)
+ (ACTION MOUSE-F)>
+
+<ROUTINE MOUSE-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a plastic pointing device." CR>)
+ (<VERB? TAKE>
+ <TELL
+"It's attached to the computer." CR>)
+ (<VERB? MOVE>
+ <TELL
+"It rolls smoothly." CR>)
+ (<AND <MOUSE-VERB?>
+ <PRSO? MOUSE>>
+ <COND (,PRSI
+ <PERFORM ,V?CLICK ,PRSI>
+ <RTRUE>)
+ (ELSE
+ <TELL
+,YOU-HAVE-TO "click something with the mouse." CR>)>)
+ (<AND <MOUSE-VERB?>
+ <PRSI? MOUSE>>
+ <PERFORM ,V?CLICK ,PRSO>
+ <RTRUE>)>>
+
+<OBJECT PC
+ (IN TERMINAL-ROOM)
+ (DESC "pc")
+ (FDESC
+"A really whiz-bang pc is right inside the door.")
+ (SYNONYM PC COMPUTER SCREEN TERMINAL)
+ (ADJECTIVE PERSONAL MY MONITOR)
+ (FLAGS TAKEBIT TRYTAKEBIT OPENBIT CONTBIT SEARCHBIT SURFACEBIT)
+ (SIZE 30)
+ (ACTION PC-F)>
+
+<GLOBAL COMPUTER-POWERS "The computer powers ">
+
+<ROUTINE PC-F ("AUX" TMP)
+ <COND (<VERB? EXAMINE>
+ <COND (<EQUAL? <GET ,P-NAMW 0> ,W?SCREEN>
+ <NEW-VERB ,V?READ>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"This is a beyond-state-of-the-art personal computer. It has a
+1024 by 1024 pixel color monitor, a mouse, an attached hard disk,
+and a local area network connection. Fortunately, one of its features
+is a prominent HELP key.">
+ <COND (<NOT <FSET? ,PC ,POWERBIT>>
+ <TELL S " It is currently ""turned off.">)
+ (<FIRST? ,PC>
+ <TELL
+" On the screen you see " A <FIRST? ,PC> ".">)>
+ <CRLF>)>)
+ (<AND <VERB? LISTEN>
+ <FSET? ,PC ,POWERBIT>>
+ <TELL "It hums contentedly." CR>)
+ (<VERB? TAKE>
+ <COND (<QUEUED? I-HACKER-HELPS>
+ <NEW-VERB ,V?UNPLUG>
+ <RTRUE>)
+ (<EQUAL? <ITAKE> T>
+ <TELL
+"You take it">
+ <COND (<NOT ,PC-UNPLUGGED?>
+ <TELL ", ">
+ <COND (<FSET? ,PC ,POWERBIT>
+ <INIT-PC>
+ <TELL
+"turning it off and ">)>
+ <SETG PC-UNPLUGGED? T>
+ <TELL
+"unplugging it first">)>
+ <TELL ,PERIOD>)
+ (ELSE <RTRUE>)>)
+ (<P? (PUT PUT-ON) * PC>
+ <NO-GOOD-SURFACE>)
+ (<VERB? READ>
+ <COND (<AND <QUEUED? I-HACKER-HELPS>
+ <L? ,HACKER-HELP 3>>
+ <TELL
+S "There's nothing ""recognizable on the screen." CR>
+ <RTRUE>)>
+ <SET TMP
+ <COND (<IN? ,ODD-PAPER ,PC> ,ODD-PAPER)
+ ;(<IN? ,REAL-PAPER ,PC> ,REAL-PAPER)
+ (<IN? ,MENU-BOX ,PC> ,MENU-BOX)
+ (<IN? ,MORE-BOX ,PC> ,MORE-BOX)
+ (<IN? ,YAK-WINDOW ,PC> ,YAK-WINDOW)>>
+ <COND (.TMP
+ <NEW-PRSO .TMP>
+ <RTRUE>)
+ (ELSE
+ <TELL
+S "There's nothing ""to read on the screen now." CR>)>)
+ (<VERB? LAMP-ON>
+ <COND (,PC-UNPLUGGED?
+ <TELL
+"It's unplugged. You should plug it in first." CR>)
+ (<NOT <FSET? ,PC ,POWERBIT>>
+ <FSET ,PC ,POWERBIT>
+ <TELL
+,COMPUTER-POWERS "up, goes through a remarkably fast self-check,
+and greets you, requesting " ,LOGIN-PLEASE " The only sound you hear is
+a very low hum." CR>)
+ (ELSE
+ <TELL
+"It's on. Maybe you didn't notice." CR>)>)
+ (<VERB? PLUG-IN>
+ <COND (,PC-UNPLUGGED?
+ <SETG PC-UNPLUGGED? <>>
+ <TELL
+"You plug in the computer." CR>)
+ (ELSE <TELL ,IT-ALREADY-IS>)>)
+ (<VERB? UNPLUG>
+ <COND (,PC-UNPLUGGED?
+ <TELL ,IT-ALREADY-IS>
+ <RTRUE>)
+ (<QUEUED? I-HACKER-HELPS>
+ <TELL S
+"The hacker stops you. \"You'll mung the bits, chomper!\"|">)
+ (ELSE
+ <INIT-PC>
+ <SETG PC-UNPLUGGED? T>
+ <TELL
+"Okay, it's unplugged now." CR>)>)
+ (<VERB? LAMP-OFF>
+ <COND (<QUEUED? I-HACKER-HELPS>
+ <TELL S
+"The hacker stops you. \"You'll mung the bits, chomper!\"|">)
+ (<FSET? ,PC ,POWERBIT>
+ <INIT-PC>
+ <COMPUTER-POWERS-OFF>)
+ (ELSE
+ <ITS-ALREADY-X "off">)>)
+ (<VERB? READ>
+ <COND (<IN? ,ODD-PAPER ,PC>
+ <NEW-PRSO ,ODD-PAPER>
+ <RTRUE>)>)
+ (<AND <VERB? SIT-AT>
+ <IN? ,CHAIR ,HERE>>
+ <PERFORM ,V?SIT ,CHAIR>
+ <RTRUE>)>>
+
+<ROUTINE COMPUTER-POWERS-OFF ()
+ <FCLEAR ,PRSO ,POWERBIT>
+ <TELL
+,COMPUTER-POWERS "off. It no longer makes a sound." CR>>
+
+<ROUTINE INIT-PC ()
+ <FCLEAR ,PC ,POWERBIT>
+ <SETG LOGGED-IN? <>>
+ <SETG USERNAME? <>>
+ <REMOVE ,MENU-BOX>
+ <REMOVE ,MORE-BOX>
+ <MOVE ,YAK-WINDOW ,GLOBAL-OBJECTS>
+ <COND (<NOT <IN? ,ODD-PAPER ,GLOBAL-OBJECTS>>
+ <REMOVE ,ODD-PAPER>)>>
+
+<OBJECT INTNAME
+ (IN GLOBAL-OBJECTS)
+ (SYNONYM INTNAME)
+ (FLAGS NDESCBIT)>
+
+<SYNTAX LOGIN OBJECT = V-LOGIN>
+<SYNTAX LOGIN ON OBJECT = V-LOGIN>
+<SYNTAX LOGIN AS OBJECT = V-LOGIN>
+<SYNTAX PASSWORD OBJECT = V-PASSWORD>
+
+<GLOBAL LOGGED-IN? <>>
+<GLOBAL USERNAME? <>>
+
+<ROUTINE CANT-USE-COMPUTER? ("AUX" (COMP <>))
+ <COND (<ACCESSIBLE? ,PC> <SET COMP ,PC>)
+ (<ACCESSIBLE? ,LOVECRAFT> <SET COMP ,LOVECRAFT>)
+ (ELSE
+ <TELL "Login on what?" CR>
+ <RTRUE>)>
+ <COND (<POWER-ON-FIRST? .COMP> <RTRUE>)
+ (<EQUAL? .COMP ,LOVECRAFT>
+ <TELL S "\"Unable to boot because: No disk inserted. Please
+insert a dismountable disk.\"" CR>
+ <RTRUE>)>>
+
+<ROUTINE V-LOGIN ()
+ <COND (<CANT-USE-COMPUTER?> <RTRUE>)
+ (<AND <PRSO? ,INTNAME>
+ <EQUAL? ,P-NAME ,W?XYZZY>>
+ <SETG USERNAME? ,W?XYZZY>)
+ (ELSE
+ <SETG USERNAME? T>)>
+ <TELL
+,COMPUTER-RESPONDS "PASSWORD PLEASE:\"" CR>>
+
+<GLOBAL COMPUTER-RESPONDS "The computer responds \"">
+
+<ROUTINE POWER-ON-FIRST? (COMP)
+ <COND (<NOT <FSET? .COMP ,POWERBIT>>
+ <TELL
+"It would help if you turned on the computer first." CR>
+ <RTRUE>)>>
+
+<ROUTINE V-PASSWORD ()
+ <COND (<CANT-USE-COMPUTER?> <RTRUE>)
+ (<AND <PRSO? ,INTNAME>
+ <EQUAL? ,P-NAME ,W?PLUGH>
+ <EQUAL? ,USERNAME? ,W?XYZZY>>
+ <SETG LOGGED-IN? T>
+ <MOVE ,MENU-BOX ,PC>
+ <TELL
+,COMPUTER-RESPONDS "Good evening. You're here awfully late.\" It
+displays a list of pending tasks, one of which is in blinking
+red letters, with large arrows pointing to it. The task reads \"Classics
+Paper,\" some particularly ominous words next to it say \"DUE
+TOMORROW!\" and more reassuringly, a menu box next to that
+reads " <GETP ,MENU-BOX ,P?TEXT> CR>)
+ (ELSE
+ <SETG USERNAME? <>>
+ <SETG LOGGED-IN? <>>
+ <TELL
+,COMPUTER-RESPONDS "INVALID LOGIN\" and then " ,LOGIN-PLEASE CR>)>>
+
+<GLOBAL LOGIN-PLEASE "\"LOGIN PLEASE:\".">
+
+<OBJECT MENU-BOX
+ (DESC "menu box")
+ (SYNONYM BOX PAPER LIST)
+ (ADJECTIVE EDIT MENU CLASSIC RED)
+ (FLAGS NDESCBIT READBIT)
+ (ACTION MENU-BOX-F)
+ (TEXT
+"\"Edit Classics Paper.\"")>
+
+<ROUTINE MOUSE-VERB? ()
+ <VERB? PUSH RUB CLICK POINT EDIT ATTACK>>
+
+<ROUTINE MENU-BOX-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"The most immediate thing you see is the red menu box that refers to
+an urgent task." CR>)
+ (<MOUSE-VERB?>
+ <REMOVE ,MENU-BOX>
+ <MOVE ,YAK-WINDOW ,PC>
+ <TELL
+"The menu box is replaced by the YAK text editor and menu boxes
+listing the titles of your files. The one for your paper is highlighted in a
+rather urgent-looking shade of red." CR>)>>
+
+<OBJECT YAK-WINDOW
+ (IN LOCAL-GLOBALS)
+ (DESC "YAK editor")
+ (SYNONYM WINDOW PAPER BOX)
+ (ADJECTIVE MENU YAK EDITOR FORMATTER CLASSIC RED URGENT)
+ (FLAGS NDESCBIT READBIT)
+ (GENERIC GENERIC-PAPER-F)
+ (ACTION YAK-WINDOW-F)
+ (TEXT
+"\"YAK 5.3\"")>
+
+<ROUTINE GENERIC-PAPER-F ()
+ <COND (<IN? ,YAK-WINDOW ,PC> ,YAK-WINDOW)
+ (ELSE ,ODD-PAPER)>>
+
+<ROUTINE YAK-WINDOW-F ()
+ <COND (<IN? ,YAK-WINDOW ,GLOBAL-OBJECTS>
+ <COND (<NOT <ABSTRACT-VERB?>>
+ <YOU-SEE-NO ,YAK-WINDOW>)>)
+ (<VERB? EXAMINE READ>
+ <COND (<EQUAL? <GET ,P-NAMW 0> ,W?BOX ,W?SCREEN>
+ <TELL
+"There's one for your paper." CR>)
+ (ELSE
+ <TELL
+,YOU-HAVE-TO "touch the box for it first." CR>)>)
+ (<MOUSE-VERB?>
+ <MOVE ,YAK-WINDOW ,GLOBAL-OBJECTS>
+ <MOVE ,MORE-BOX ,PC>
+ <SETG READ-PAGE? <>>
+ <TELL
+"You click the box for your paper, and">
+ <COND (<NOT <FSET? ,ODD-PAPER ,TOUCHBIT>>
+ <MOVE ,ODD-PAPER ,PC>
+ <TELL
+" the box grows reassuringly until
+it fills most of the screen. Unfortunately, the text that fills it
+bears no resemblance to your paper. The title is the same, but after
+that, there is something different, very different." CR>)
+ (ELSE
+ <TELL
+,LC-NOTHING-HAPPENS " \"Your paper is lost!\" reminds the hacker." CR>)>)>>
+
+<OBJECT MORE-BOX
+ (DESC "more box")
+ (SYNONYM BOX)
+ (ADJECTIVE MORE)
+ (FLAGS READBIT NDESCBIT)
+ (ACTION MORE-BOX-F)>
+
+<ROUTINE MORE-BOX-F ()
+ <COND (<VERB? READ>
+ <TELL "It says \"MORE\" in a subdued typeface." CR>)
+ (<MOUSE-VERB?>
+ <COND (<NOT ,READ-PAGE?>
+ <TELL
+"You haven't read the page yet. You probably shouldn't touch the MORE
+box until then." CR>)
+ (ELSE
+ <TELL
+"You touch the MORE box, and a new page appears." CR>)>)>>
+
+<OBJECT ODD-PAPER
+ (DESC "classics paper")
+ (SYNONYM PAPER TEXT PAGE)
+ (ADJECTIVE MY STRANGE ODD CLASSIC)
+ (FLAGS READBIT NDESCBIT)
+ (GENERIC GENERIC-PAPER-F)
+ (ACTION ODD-PAPER-F)>
+
+<GLOBAL ALREADY-DISPLAYED
+"It's already displayed. It hasn't changed, either.|">
+
+<ROUTINE ODD-PAPER-F ()
+ <COND (<IN? ,ODD-PAPER ,GLOBAL-OBJECTS>
+ <COND (<NOT <ABSTRACT-VERB?>>
+ <TELL "It's been lost!" CR>)>)
+ (<MOUSE-VERB?>
+ <TELL ,ALREADY-DISPLAYED>)
+ (<VERB? READ EXAMINE>
+ <SETG READ-PAGE? T>
+ <COND (<QUEUE I-COMPULSION 2 T>
+ <SETG COMPCNT 1>
+ <TELL <GET ,COMPDESCS ,COMPCNT> CR CR
+"As you look at it more closely, you
+find it hard to focus on the screen, but impossible to look away. Your
+finger strays toward the \"MORE\" box..." CR>)
+ (ELSE
+ <TELL
+"You click the \"MORE\" box and read what appears." CR>)>)>>
+
+<GLOBAL READ-PAGE? <>>
+
+<GLOBAL COMPCNT 0>
+
+<ROUTINE I-COMPULSION ()
+ <FSET ,ODD-PAPER ,TOUCHBIT>
+ <COND (<G? <SETG COMPCNT <+ ,COMPCNT 1>> <GET ,COMPDESCS 0>>
+ <TELL CR "You faint, and when you awaken..." CR CR>
+ <DEQUEUE I-COMPULSION>
+ <REMOVE ,MORE-BOX>
+ <MOVE ,MENU-BOX ,PC>
+ <COND (<NOT <IN? ,PLAYER ,HERE>>
+ <MOVE ,PLAYER ,HERE>)>
+ <ROB ,PLAYER ,FROB>
+ <GOTO ,YUGGOTH>)
+ (ELSE
+ <QUEUE I-COMPULSION 1>
+ <SETG READ-PAGE? T>
+ <TELL CR <GET ,COMPDESCS ,COMPCNT> CR>)>>
+
+<GLOBAL COMPDESCS <LTABLE (PURE)
+"The paper appears to be a facsimile overlaid with occasional typescript.
+The text is mostly in a sort of \"Olde English\" you've never seen before.
+What you read is a combination of incomprehensible gibberish, latinate
+pseudowords, debased Hebrew and Arabic scripts, and an occasional
+disquieting phrase in English."
+
+"The second page is much like the first, but around the edges, not when
+you look at it straight, it's almost readable. There is something about
+a \"summoning,\" or a \"visitor.\""
+
+"The third page is in the same script as the first, but laid out
+like a poem. There are woodcut illustrations
+which are queasily disturbing.|
+|
+There is a translation, or notes for one, typed
+between the lines of the poem:|
+|
+\"He returns, he is called back (?)|
+The loyal ones (acolytes?) make a sacrifice|
+Those who survive will meet him (be absorbed? eaten?)|
+They will live, yet die|
+Forever will be (is?) nothing to them (to him?)|
+|
+\"His place (lair? burrow?) must be prepared|
+His food (offerings?) must be prepared|
+Call him forth (invite him?) with great power|
+Only an acceptable (tasteful?) sacrifice will call him forth|
+He will be grateful (satiated?)\"|
+|
+The rest is even more fragmentary."
+
+"The fourth page is a
+photograph. You try to recoil from the screen, but cannot. Fascinated
+and repelled at the same time, you wonder: is that a mouth, and what
+is in it?">>
+
+<OBJECT PROGRAM
+ (IN LOCAL-GLOBALS)
+ (DESC "program")
+ (SYNONYM PROGRAM BUG PROBLEM)
+ (ADJECTIVE ASSEMBLY)
+ (FLAGS NDESCBIT)>
diff --git a/record.zil b/record.zil
new file mode 100644
index 0000000..e676596
--- /dev/null
+++ b/record.zil
@@ -0,0 +1,30 @@
+"RECORD for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+<SYNTAX \#RANDOM OBJECT = V-$RANDOM>
+<SYNTAX \#COMMAND = V-$COMMAND>
+<SYNTAX \#RECORD = V-$RECORD>
+<SYNTAX \#UNRECORD = V-$UNRECORD>
+
+<ROUTINE V-$COMMAND ()
+ <DIRIN 1>
+ <RTRUE>>
+
+<ROUTINE V-$RANDOM ()
+ <COND (<NOT <PRSO? ,INTNUM>>
+ <TELL "Illegal call to #RANDOM." CR>)
+ (T
+ <RANDOM <- 0 ,P-NUMBER>>
+ <RTRUE>)>>
+
+<CONSTANT D-RECORD-ON 4>
+<CONSTANT D-RECORD-OFF -4>
+
+<ROUTINE V-$RECORD ()
+ <DIROUT ,D-RECORD-ON> ;"all READS and INPUTS get sent to command file"
+ <RTRUE>>
+
+<ROUTINE V-$UNRECORD ()
+ <DIROUT ,D-RECORD-OFF>
+ <RTRUE>>
diff --git a/syntax.zil b/syntax.zil
new file mode 100644
index 0000000..5a787a7
--- /dev/null
+++ b/syntax.zil
@@ -0,0 +1,737 @@
+"SYNTAX for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+<BUZZ XYZZY PLUGH> ;"username/password"
+
+<BUZZ A AN THE IS ARE AM AND OF THEN ALL ONE BUT EXCEPT \. \, \"
+ ;PLEASE ;HERE ;SOME G AGAIN OOPS O>
+
+<PREP-SYNONYM WITH USING>
+<PREP-SYNONYM THROUGH THRU>
+<PREP-SYNONYM ON ONTO>
+<PREP-SYNONYM IN INSIDE INTO>
+<PREP-SYNONYM UNDER BELOW BENEATH UNDERNEATH>
+<PREP-SYNONYM AROUND ALONG>
+
+<SYNONYM ALL BOTH EVERYTHING>
+
+\
+
+;"game commands"
+
+<SYNTAX VERBOSE = V-VERBOSE>
+
+<SYNTAX BRIEF = V-BRIEF>
+
+<SYNTAX SUPER = V-SUPER-BRIEF>
+<VERB-SYNONYM SUPER SUPERBRIEF>
+
+<SYNTAX DIAGNOSE = V-DIAGNOSE>
+
+<SYNTAX I = V-INVENTORY>
+<VERB-SYNONYM I INVENTORY>
+
+<SYNTAX QUIT = V-QUIT>
+<VERB-SYNONYM QUIT Q>
+
+<SYNTAX RESTAR = V-RESTART>
+
+<SYNTAX RESTOR = V-RESTORE>
+
+<SYNTAX SAVE = V-SAVE>
+
+<SYNTAX SCORE = V-SCORE>
+
+<SYNTAX SCRIPT = V-SCRIPT>
+
+<SYNTAX UNSCRIPT = V-UNSCRIPT>
+
+<SYNTAX VERSION = V-VERSION>
+
+<SYNTAX $VERIFY = V-$VERIFY>
+<SYNTAX $VERIFY OBJECT = V-$VERIFY>
+
+\
+
+;"subtitle real verbs"
+
+<SYNTAX ANSWER = V-ANSWER>
+<SYNTAX ANSWER OBJECT = V-REPLY>
+<VERB-SYNONYM ANSWER REPLY RESPOND>
+
+<SYNTAX APPLY OBJECT (HELD MANY HAVE) TO OBJECT = V-PUT PRE-PUT>
+
+<SYNTAX ASK FOR OBJECT = V-ASK-FOR PRE-ASK-FOR>
+<SYNTAX ASK OBJECT (FIND PERSON) FOR OBJECT = V-ASK-FOR PRE-ASK-FOR>
+<SYNTAX ASK ABOUT OBJECT = V-ASK-ABOUT PRE-ASK-ABOUT>
+<SYNTAX ASK OBJECT (FIND PERSON) ABOUT OBJECT = V-ASK-ABOUT PRE-ASK-ABOUT>
+<VERB-SYNONYM ASK QUIZ>
+
+<SYNTAX ATTACK OBJECT (FIND PERSON) (ON-GROUND IN-ROOM) = V-ATTACK>
+<SYNTAX ATTACK OBJECT (FIND PERSON) (ON-GROUND IN-ROOM)
+ WITH OBJECT (FIND WEAPONBIT) (HELD CARRIED HAVE) = V-ATTACK>
+<VERB-SYNONYM ATTACK FIGHT HIT STRIKE>
+
+<SYNTAX BITE OBJECT = V-BITE>
+
+;<SYNTAX BLOW UP OBJECT = V-INFLATE>
+<SYNTAX BLOW OUT OBJECT = V-LAMP-OFF>
+
+<SYNTAX BOARD OBJECT (FIND VEHBIT) (ON-GROUND IN-ROOM) = V-BOARD PRE-BOARD>
+<VERB-SYNONYM BOARD RIDE>
+
+<SYNTAX BURN OBJECT (HELD CARRIED ON-GROUND IN-ROOM)
+ WITH OBJECT (HELD CARRIED ON-GROUND IN-ROOM HAVE) = V-BURN>
+<SYNTAX BURN DOWN OBJECT (HELD CARRIED ON-GROUND IN-ROOM)
+ WITH OBJECT (HELD CARRIED ON-GROUND IN-ROOM HAVE) = V-BURN>
+<VERB-SYNONYM BURN IGNITE>
+
+<SYNTAX CLIMB OBJECT (ON-GROUND IN-ROOM) = V-CLIMB-FOO>
+<SYNTAX CLIMB ON OBJECT (FIND VEHBIT) (ON-GROUND IN-ROOM) = V-CLIMB-ON>
+<SYNTAX CLIMB UP OBJECT (FIND RLANDBIT) (ON-GROUND IN-ROOM) = V-CLIMB-UP>
+<SYNTAX CLIMB DOWN OBJECT (FIND RLANDBIT) (ON-GROUND IN-ROOM) = V-CLIMB-DOWN>
+<SYNTAX CLIMB OVER OBJECT (ON-GROUND IN-ROOM) = V-CLIMB-OVER>
+<SYNTAX CLIMB IN OBJECT (FIND VEHBIT) (ON-GROUND IN-ROOM) = V-BOARD PRE-BOARD>
+<SYNTAX CLIMB OFF OBJECT (FIND RLANDBIT) (ON-GROUND IN-ROOM) = V-DISEMBARK>
+<SYNTAX CLIMB OUT OBJECT (FIND RLANDBIT) (ON-GROUND IN-ROOM) = V-DISEMBARK>
+<VERB-SYNONYM CLIMB SCALE>
+
+<SYNTAX COVER OBJECT WITH OBJECT (ON-GROUND IN-ROOM) = V-SPUT-ON PRE-SPUT-ON>
+
+<SYNTAX DESCEN OBJECT (ON-GROUND IN-ROOM) = V-CLIMB-DOWN>
+
+<SYNTAX LIE DOWN OBJECT (FIND RLANDBIT) = V-SLEEP>
+<SYNTAX LIE ON OBJECT (FIND VEHBIT) = V-BOARD>
+;<VERB-SYNONYM LIE>
+
+<SYNTAX CLOSE OBJECT (FIND CONTBIT) (HELD CARRIED ON-GROUND IN-ROOM)
+ = V-CLOSE>
+<SYNTAX CLOSE OBJECT (FIND CONTBIT) (HELD CARRIED ON-GROUND IN-ROOM)
+ WITH OBJECT (FIND WEAPONBIT) = V-CLOSE>
+<VERB-SYNONYM CLOSE SHUT>
+
+<SYNTAX COMPARE OBJECT (MANY) = V-COMPARE-MANY>
+<SYNTAX COMPARE OBJECT TO OBJECT = V-COMPARE>
+<SYNTAX COMPARE OBJECT WITH OBJECT = V-COMPARE>
+
+<SYNTAX COUNT OBJECT = V-WASTE-OF-TIME <> COUNT>
+<SYNTAX COUNT OBJECT IN OBJECT = V-WASTE-OF-TIME <> COUNT>
+;<VERB-SYNONYM COUNT>
+
+<SYNTAX CROSS OBJECT = V-CROSS>
+;<VERB-SYNONYM CROSS TRAVERSE>
+
+<SYNTAX CUT OBJECT
+ WITH OBJECT (FIND WEAPONBIT) (CARRIED HELD HAVE) = V-CUT>
+<SYNTAX CUT THROUGH OBJECT
+ WITH OBJECT (FIND WEAPONBIT) (CARRIED HELD HAVE) = V-CUT>
+<VERB-SYNONYM CUT CHOP SLICE SLASH ;SEVER SPLIT ;DIVIDE PRUNE>
+
+<SYNTAX SHIT = V-CURSE>
+;<SYNTAX SHIT OBJECT = V-CURSE>
+;<SYNTAX SHIT OFF OBJECT (FIND RLANDBIT) = V-CURSE>
+<VERB-SYNONYM SHIT DAMN FUCK>
+
+<SYNTAX CRACK OBJECT (ON-GROUND IN-ROOM) = V-MUNG>
+<SYNTAX CRACK OBJECT (ON-GROUND IN-ROOM HELD CARRIED)
+ WITH OBJECT (HELD CARRIED TAKE HAVE) = V-MUNG>
+<SYNTAX CRACK DOWN OBJECT (ON-GROUND IN-ROOM HELD CARRIED)
+ WITH OBJECT (HELD CARRIED TAKE HAVE) = V-MUNG>
+<VERB-SYNONYM CRACK DESTROY BREAK SMASH WRECK SCRATCH ;SCUFF SCRAPE>
+
+<SYNTAX DIG IN OBJECT = V-WASTE-OF-TIME <> DIG>
+<SYNTAX DIG WITH OBJECT = V-WASTE-OF-TIME <> DIG>
+<SYNTAX DIG THROUGH OBJECT = V-WASTE-OF-TIME <> DIG>
+<SYNTAX DIG OBJECT (ON-GROUND IN-ROOM)
+ WITH OBJECT (FIND TOOLBIT) (HELD CARRIED HAVE)
+ = V-WASTE-OF-TIME <> DIG>
+<SYNTAX DIG IN OBJECT (ON-GROUND IN-ROOM)
+ WITH OBJECT (FIND TOOLBIT) (HELD CARRIED HAVE)
+ = V-WASTE-OF-TIME <> DIG>
+;<VERB-SYNONYM DIG EXCAVATE>
+
+<SYNTAX DISEMBARK = V-DISEMBARK>
+<SYNTAX DISEMBARK OBJECT (ON-GROUND IN-ROOM) = V-DISEMBARK>
+;<VERB-SYNONYM DISEMBARK DEBARK DISMOUNT>
+
+<SYNTAX DRINK OBJECT (HELD CARRIED ON-GROUND IN-ROOM) = V-DRINK>
+<SYNTAX DRINK FROM OBJECT (HELD CARRIED) = V-DRINK-FROM>
+<VERB-SYNONYM DRINK SIP SWALLOW>
+
+<SYNTAX DROP OBJECT ;(FIND RLANDBIT) (HELD MANY HAVE) = V-DROP PRE-DROP>
+<SYNTAX DROP OBJECT (HELD MANY HAVE) DOWN OBJECT = V-PUT PRE-PUT>
+<SYNTAX DROP OBJECT (HELD MANY HAVE) IN OBJECT = V-PUT PRE-PUT>
+<SYNTAX DROP OBJECT (HELD MANY HAVE) ON OBJECT = V-PUT PRE-PUT>
+<SYNTAX DROP FROM OBJECT = V-DROP PRE-DROP>
+<VERB-SYNONYM DROP DUMP>
+
+<SYNTAX RELEASE OBJECT = V-RELEASE>
+
+<SYNTAX EAT OBJECT (HELD CARRIED ON-GROUND IN-ROOM MANY) = V-EAT>
+<VERB-SYNONYM EAT CONSUME ;TASTE ;INGEST GOBBLE>
+
+<SYNTAX TASTE OBJECT (HELD CARRIED ON-GROUND IN-ROOM MANY) = V-TASTE>
+<VERB-SYNONYM TASTE SAMPLE>
+
+<SYNTAX ENTER = V-ENTER>
+<SYNTAX ENTER OBJECT = V-THROUGH>
+
+<SYNTAX EXIT = V-EXIT>
+<SYNTAX EXIT OBJECT = V-EXIT>
+<VERB-SYNONYM EXIT DEPART WITHDRAW>
+
+<SYNTAX EXAMINE OBJECT (HELD CARRIED ON-GROUND IN-ROOM)
+ = V-EXAMINE PRE-EXAMINE>
+<SYNTAX EXAMINE IN OBJECT (HELD CARRIED IN-ROOM ON-GROUND)
+ = V-LOOK-INSIDE>
+<SYNTAX EXAMINE ON OBJECT (HELD CARRIED IN-ROOM ON-GROUND)
+ = V-LOOK-INSIDE>
+<SYNTAX EXAMINE FOR OBJECT = V-FIND>
+<VERB-SYNONYM EXAMINE X ;INSPECT DESCRIBE CHECK ;OBSERVE WATCH>
+
+;<SYNTAX EXORCISE OBJECT = V-EXORCISE>
+;<SYNTAX EXORCISE OUT OBJECT (FIND PERSON) = V-EXORCISE>
+;<SYNTAX EXORCISE AWAY OBJECT (FIND PERSON) = V-EXORCISE>
+;<VERB-SYNONYM EXORCISE BANISH DRIVE>
+
+<SYNTAX EXTINGUISH OBJECT
+ (MANY HELD CARRIED ON-GROUND IN-ROOM TAKE HAVE) = V-LAMP-OFF>
+;<VERB-SYNONYM EXTINGUISH DOUSE>
+
+<SYNTAX FILL OBJECT (FIND CONTBIT) (HELD TAKE HAVE) = V-FILL>
+<SYNTAX FILL OBJECT (FIND CONTBIT) (HELD TAKE HAVE)
+ WITH OBJECT = V-FILL>
+<SYNTAX FILL OBJECT (FIND CONTBIT) (HELD TAKE HAVE)
+ AT OBJECT = V-FILL>
+
+<SYNTAX FIND OBJECT = V-FIND>
+;<VERB-SYNONYM FIND SEEK SEE>
+
+;<SYNTAX FLY = V-FLY>
+;<SYNTAX FLY OBJECT = V-FLY>
+;<SYNONYM FLY LAUNCH>
+
+<SYNTAX FOLLOW = V-FOLLOW>
+<SYNTAX FOLLOW OBJECT = V-FOLLOW>
+<VERB-SYNONYM FOLLOW ;PURSUE CHASE>
+
+;<SYNTAX FORGET OBJECT = V-FORGET>
+;<VERB-SYNONYM FORGET UNLEARN ;UNMEMORIZE>
+
+<SYNTAX GIVE OBJECT (MANY HELD CARRIED HAVE)
+ TO OBJECT (FIND PERSON) (ON-GROUND) = V-GIVE PRE-GIVE>
+<SYNTAX GIVE OBJECT (FIND PERSON) (ON-GROUND) OBJECT (MANY HELD CARRIED HAVE)
+ = V-SGIVE PRE-SGIVE>
+<SYNTAX GIVE OBJECT (FIND PERSON) (ON-GROUND)
+ WITH OBJECT (MANY HELD CARRIED HAVE)
+ = V-SGIVE PRE-SGIVE>
+<SYNTAX GIVE OBJECT (HELD CARRIED HAVE) FOR OBJECT = V-TRADE>
+<VERB-SYNONYM GIVE OFFER FEED ;PRESENT>
+
+<SYNTAX HELLO = V-HELLO>
+<SYNTAX HELLO OBJECT = V-HELLO>
+<VERB-SYNONYM HELLO HI GREETINGS>
+
+<SYNTAX HELP = V-HELP>
+<SYNTAX HELP OBJECT = V-HELP>
+<VERB-SYNONYM HELP HINT ;HINTS>
+
+<SYNTAX HIDE = V-HIDE>
+<SYNTAX HIDE OBJECT (HELD HAVE) = V-HIDE>
+<SYNTAX HIDE UNDER OBJECT = V-HIDE>
+<SYNTAX HIDE BEHIND OBJECT = V-HIDE>
+<SYNTAX HIDE OBJECT (HELD HAVE) FROM OBJECT = V-HIDE>
+<SYNTAX HIDE IN OBJECT = V-BOARD>
+<SYNTAX HIDE FROM OBJECT = V-HIDE-FROM>
+<VERB-SYNONYM HIDE CONCEAL ;STASH>
+
+;<SYNTAX INFLAT OBJECT = V-INFLATE>
+
+<SYNTAX JUMP = V-LEAP>
+<SYNTAX JUMP OVER OBJECT = V-LEAP>
+<SYNTAX JUMP ACROSS OBJECT = V-LEAP>
+<SYNTAX JUMP IN OBJECT = V-LEAP>
+<SYNTAX JUMP FROM OBJECT = V-LEAP>
+<SYNTAX JUMP DOWN OBJECT (FIND RLANDBIT) = V-LEAP>
+<SYNTAX JUMP OFF OBJECT = V-LEAP>
+<SYNTAX JUMP ON OBJECT = V-CLIMB-ON>
+<SYNTAX JUMP TO OBJECT = V-CLIMB-ON>
+<VERB-SYNONYM JUMP LEAP DIVE>
+
+<SYNTAX KICK OBJECT = V-KICK PRE-OPEN>
+
+<SYNTAX KILL OBJECT (FIND PERSON) (ON-GROUND IN-ROOM) = V-KILL>
+<SYNTAX KILL OBJECT (FIND PERSON) (ON-GROUND IN-ROOM)
+ WITH OBJECT (FIND WEAPONBIT) (HELD CARRIED HAVE) = V-KILL>
+<VERB-SYNONYM KILL MURDER SLAY STAB>
+
+<SYNTAX KISS OBJECT (FIND PERSON) (ON-GROUND IN-ROOM) = V-KISS>
+
+<SYNTAX KNOCK AT OBJECT = V-KNOCK>
+<SYNTAX KNOCK ON OBJECT = V-KNOCK>
+<SYNTAX KNOCK DOWN OBJECT (FIND PERSON) (ON-GROUND IN-ROOM) = V-ATTACK>
+<VERB-SYNONYM KNOCK RAP>
+
+;<SYNTAX LAND = V-LAND>
+
+<SYNTAX LEAN ON OBJECT (HELD HAVE) = V-LEAN-ON>
+<SYNTAX LEAN OBJECT ON OBJECT = V-RAISE>
+<SYNTAX LEAN OBJECT AGAINST OBJECT = V-RAISE>
+
+<SYNTAX LEAVE = V-LEAVE>
+<SYNTAX LEAVE OBJECT = V-DROP PRE-DROP>
+
+<SYNTAX LISTEN = V-LISTEN>
+<SYNTAX LISTEN TO OBJECT = V-LISTEN>
+<SYNTAX LISTEN FOR OBJECT = V-LISTEN>
+
+<SYNTAX LOCK OBJECT (ON-GROUND IN-ROOM) WITH OBJECT
+ (HELD CARRIED HAVE) = V-LOCK>
+<SYNTAX LOCK OBJECT (ON-GROUND IN-ROOM) TO OBJECT = V-LOCK>
+
+<SYNTAX LOOK = V-LOOK>
+<SYNTAX LOOK AROUND OBJECT (FIND RLANDBIT) = V-LOOK>
+<SYNTAX LOOK DOWN OBJECT (FIND RLANDBIT) = V-LOOK-DOWN>
+<SYNTAX LOOK AT OBJECT (HELD CARRIED ON-GROUND IN-ROOM)
+ = V-EXAMINE PRE-EXAMINE>
+<SYNTAX LOOK THROUGH OBJECT = V-LOOK-INSIDE>
+<SYNTAX LOOK UNDER OBJECT = V-LOOK-UNDER>
+<SYNTAX LOOK BEHIND OBJECT = V-LOOK-BEHIND>
+<SYNTAX LOOK ON OBJECT (HELD CARRIED ON-GROUND IN-ROOM)
+ = V-LOOK-INSIDE>
+<SYNTAX LOOK IN OBJECT (HELD CARRIED ON-GROUND IN-ROOM) = V-LOOK-INSIDE>
+<SYNTAX LOOK AT OBJECT (HELD CARRIED ON-GROUND IN-ROOM TAKE) THROUGH OBJECT
+ = V-READ PRE-READ>
+<SYNTAX LOOK UP OBJECT (FIND RLANDBIT) = V-LOOK-UP>
+<SYNTAX LOOK UP OBJECT IN OBJECT = V-WHAT>
+<SYNTAX LOOK FOR OBJECT = V-FIND>
+<SYNTAX LOOK OBJECT = V-CHASTISE>
+<VERB-SYNONYM LOOK L STARE GAZE>
+
+<SYNTAX LOWER OBJECT = V-LOWER>
+<SYNTAX LOWER OBJECT IN OBJECT = V-LOWER-INTO>
+<SYNTAX LOWER OBJECT DOWN OBJECT = V-LOWER-INTO>
+
+<SYNTAX MELT OBJECT WITH OBJECT (HELD CARRIED ON-GROUND IN-ROOM) = V-MELT>
+<VERB-SYNONYM MELT THAW>
+
+<SYNTAX MOVE = V-WALK-AROUND>
+<SYNTAX MOVE OBJECT (ON-GROUND IN-ROOM) = V-MOVE>
+<SYNTAX MOVE OBJECT (ON-GROUND IN-ROOM)
+ WITH OBJECT = V-PRY PRE-PRY>
+<SYNTAX MOVE OBJECT (ON-GROUND IN-ROOM)
+ TO OBJECT = V-PUSH-TO>
+<SYNTAX MOVE OBJECT (ON-GROUND IN-ROOM)
+ ON OBJECT = V-PUSH-TO>
+<SYNTAX ROLL UP OBJECT (ON-GROUND IN-ROOM) = V-MOVE>
+<VERB-SYNONYM MOVE SHIFT CLEAR>
+
+;<SYNTAX PAY OBJECT (MANY HELD HAVE) = V-PAY>
+;<SYNTAX PAY OBJECT (FIND PERSON) WITH OBJECT (MANY HELD HAVE) = V-PAY>
+;<SYNTAX PAY OBJECT (MANY HELD HAVE) TO OBJECT (FIND PERSON) = V-SPAY>
+;<SYNTAX PAY OBJECT (FIND PERSON) OBJECT (MANY HELD HAVE) = V-PAY>
+
+;<SYNTAX PLAY OBJECT = V-PLAY>
+
+<SYNTAX PRAY = V-PRAY>
+
+<SYNTAX PULL OBJECT (ON-GROUND IN-ROOM) = V-MOVE>
+<SYNTAX PULL ON OBJECT (ON-GROUND IN-ROOM) = V-MOVE>
+<SYNTAX PULL DOWN OBJECT = V-LOWER>
+<VERB-SYNONYM PULL TUG DRAG>
+
+<SYNTAX OPEN OBJECT (FIND DOORBIT) (HELD CARRIED ON-GROUND IN-ROOM)
+ = V-OPEN PRE-OPEN>
+<SYNTAX OPEN UP OBJECT (FIND DOORBIT) (HELD CARRIED ON-GROUND IN-ROOM)
+ = V-OPEN PRE-OPEN>
+<SYNTAX OPEN OBJECT (FIND DOORBIT) (HELD CARRIED ON-GROUND IN-ROOM)
+ WITH OBJECT (FIND TOOLBIT) (ON-GROUND IN-ROOM HELD CARRIED)
+ = V-OPEN PRE-OPEN>
+;<VERB-SYNONYM OPEN UNZIP>
+
+<SYNTAX PICK OBJECT = V-PICK>
+<SYNTAX PICK OBJECT WITH OBJECT = V-PICK>
+<SYNTAX PICK UP OBJECT (FIND TAKEBIT) (ON-GROUND MANY) = V-TAKE PRE-TAKE>
+
+<SYNTAX PLUG OBJECT WITH OBJECT = V-PLUG>
+<SYNTAX PLUG IN OBJECT = V-PLUG-IN>
+<SYNTAX PLUG OBJECT IN OBJECT = V-PLUG>
+<VERB-SYNONYM PLUG ;CLOG ;BLOCK SCREW>
+
+<SYNTAX UNPLUG OBJECT = V-UNPLUG>
+<SYNTAX UNPLUG OBJECT FROM OBJECT = V-UNTIE>
+<SYNTAX UNPLUG OBJECT WITH OBJECT = V-PRY PRE-PRY>
+<VERB-SYNONYM UNPLUG UNSCREW>
+
+<SYNTAX REPAIR OBJECT = V-REPAIR>
+<SYNTAX REPAIR OBJECT WITH OBJECT = V-REPAIR>
+<VERB-SYNONYM REPAIR PATCH FIX>
+
+<SYNTAX POINT AT OBJECT = V-POINT>
+<SYNTAX POINT TO OBJECT = V-POINT>
+<VERB-SYNONYM POINT GESTURE>
+
+;<SYNTAX POKE OBJECT (FIND PERSON) (ON-GROUND IN-ROOM)
+ WITH OBJECT (FIND WEAPONBIT) (HELD CARRIED TAKE HAVE) = V-MUNG>
+;<VERB-SYNONYM POKE JAB BLIND>
+
+<SYNTAX POUR OBJECT (HELD CARRIED) = V-POUR PRE-POUR>
+<SYNTAX POUR OBJECT (HELD CARRIED) IN OBJECT = V-PUT>
+<SYNTAX POUR OBJECT (HELD CARRIED) ON OBJECT = V-POUR PRE-POUR>
+<SYNTAX POUR OBJECT (HELD CARRIED) OVER OBJECT = V-POUR PRE-POUR>
+<SYNTAX POUR OBJECT (HELD CARRIED) THROUGH OBJECT = V-POUR PRE-POUR>
+<SYNTAX POUR OBJECT (HELD CARRIED) FROM OBJECT = V-POUR-FROM>
+<VERB-SYNONYM POUR EMPTY SPILL>
+
+;<SYNTAX PUMP UP OBJECT = V-PUMP>
+;<SYNTAX PUMP UP OBJECT WITH OBJECT = V-PUMP>
+
+<SYNTAX PUSH OBJECT (IN-ROOM ON-GROUND) = V-PUSH>
+<SYNTAX PUSH ON OBJECT (IN-ROOM ON-GROUND) = V-PUSH>
+<SYNTAX PUSH OBJECT (IN-ROOM ON-GROUND) OBJECT = V-PUSH-TO>
+<SYNTAX PUSH OBJECT (IN-ROOM ON-GROUND) TO OBJECT = V-PUSH-TO>
+<SYNTAX PUSH OBJECT (IN-ROOM ON-GROUND) ON OBJECT = V-PUSH-TO>
+<SYNTAX PUSH OBJECT UNDER OBJECT = V-PUT-UNDER>
+<SYNTAX PUSH DOWN OBJECT (FIND RLANDBIT) = V-PUSH-DOWN>
+<SYNTAX PUSH UP OBJECT (FIND RLANDBIT) = V-PUSH-UP>
+<VERB-SYNONYM PUSH PRESS SHOVE>
+
+<SYNTAX PUT OBJECT (HELD MANY HAVE) IN OBJECT = V-PUT PRE-PUT>
+<SYNTAX PUT OBJECT (HELD MANY HAVE) DOWN OBJECT = V-PUT PRE-PUT>
+<SYNTAX PUT OBJECT (HELD MANY HAVE) ON OBJECT = V-PUT-ON PRE-PUT>
+<SYNTAX PUT OBJECT (HELD MANY HAVE) OVER OBJECT = V-PUT-ON PRE-PUT>
+<SYNTAX PUT OBJECT (HELD MANY HAVE) ACROSS OBJECT = V-PUT-ON PRE-PUT>
+<SYNTAX PUT DOWN OBJECT (HELD MANY) = V-DROP PRE-DROP>
+<SYNTAX PUT OBJECT (HELD MANY HAVE) UNDER OBJECT = V-PUT-UNDER>
+<SYNTAX PUT ON OBJECT (HELD CARRIED ON-GROUND IN-ROOM HAVE TAKE MANY) = V-WEAR>
+<SYNTAX PUT OBJECT (HELD MANY HAVE) BEHIND OBJECT = V-PUT-BEHIND>
+<SYNTAX PUT OBJECT (HELD HAVE) BETWEEN OBJECT = V-PUT-BETWEEN>
+<SYNTAX PUT OBJECT (HELD HAVE) AROUND OBJECT = V-TIE>
+<SYNTAX PUT UP OBJECT = V-RAISE>
+<VERB-SYNONYM PUT ;STUFF INSERT PLACE LAY ;FIT>
+
+<SYNTAX RAISE OBJECT = V-RAISE>
+<SYNTAX RAISE UP OBJECT = V-RAISE>
+<SYNTAX RAISE OBJECT WITH OBJECT = V-PRY PRE-PRY>
+<SYNTAX RAISE UP OBJECT WITH OBJECT = V-PRY PRE-PRY>
+<VERB-SYNONYM RAISE LIFT ERECT>
+
+<SYNTAX REACH IN OBJECT (ON-GROUND IN-ROOM) = V-REACH-IN>
+<SYNTAX REACH IN OBJECT (ON-GROUND IN-ROOM)
+ WITH OBJECT (HELD CARRIED HAVE) = V-REACH-IN>
+<SYNTAX REACH UNDER OBJECT (ON-GROUND IN-ROOM) = V-SEARCH>
+
+<SYNTAX READ OBJECT (FIND READBIT) (HELD CARRIED ON-GROUND IN-ROOM)
+ = V-READ PRE-READ>
+;<SYNTAX READ OBJECT (FIND READBIT) (HELD CARRIED ON-GROUND IN-ROOM)
+ THROUGH OBJECT = V-READ PRE-READ>
+<SYNTAX READ OBJECT (FIND READBIT) (HELD CARRIED ON-GROUND IN-ROOM)
+ TO OBJECT (FIND PERSON) = V-SHOW>
+<SYNTAX READ ABOUT OBJECT = V-WHAT>
+;<SYNTAX READ ABOUT OBJECT IN OBJECT = V-WHAT>
+;<VERB-SYNONYM READ>
+
+<SYNTAX REMOVE OBJECT = V-TAKE-OFF>
+<SYNTAX REMOVE OBJECT WITH OBJECT = V-PRY PRE-PRY>
+<SYNTAX REMOVE OBJECT FROM OBJECT = V-TAKE PRE-TAKE>
+<VERB-SYNONYM REMOVE SHED>
+
+<SYNTAX SAY TO OBJECT (FIND PERSON) (IN-ROOM) = V-TELL>
+<SYNTAX SAY = V-SAY>
+<SYNTAX SAY OBJECT = V-SAY>
+<VERB-SYNONYM SAY TALK CALL>
+
+<SYNTAX SEARCH OBJECT = V-SEARCH>
+<SYNTAX SEARCH IN OBJECT = V-SEARCH>
+<SYNTAX SEARCH FOR OBJECT = V-FIND>
+<VERB-SYNONYM SEARCH RUMMAGE ;FRISK>
+
+;<SYNTAX SEND FOR OBJECT = V-SEND>
+
+<SYNTAX SHAKE OBJECT = V-SHAKE>
+<SYNTAX SHAKE OBJECT AT OBJECT = V-WAVE-AT>
+<VERB-SYNONYM SHAKE ;JOSTLE RATTLE>
+
+<SYNTAX SHARPEN OBJECT WITH OBJECT = V-SHARPEN>
+<SYNTAX SHARPEN OBJECT ON OBJECT = V-SHARPEN>
+<VERB-SYNONYM SHARPEN HONE>
+
+<SYNTAX SHOOT OBJECT = V-SHOOT>
+;<VERB-SYNONYM SHOOT FIRE>
+
+<SYNTAX SHOW OBJECT TO OBJECT (FIND PERSON) = V-SHOW>
+<SYNTAX SHOW OBJECT (FIND PERSON) OBJECT = V-SSHOW PRE-SSHOW>
+
+<SYNTAX SIT ON OBJECT (FIND VEHBIT) (ON-GROUND IN-ROOM) = V-SIT>
+<SYNTAX SIT DOWN OBJECT (FIND RLANDBIT) (ON-GROUND IN-ROOM) = V-SIT>
+<SYNTAX SIT IN OBJECT (FIND VEHBIT) (ON-GROUND IN-ROOM) = V-BOARD PRE-BOARD>
+<SYNTAX SIT AT OBJECT = V-SIT <> SIT-AT>
+<VERB-SYNONYM SIT REST ;MEDITATE>
+
+<SYNTAX SKIP = V-SKIP>
+<VERB-SYNONYM SKIP HOP ;CAVORT ;GAMBOL>
+
+<SYNTAX SLEEP = V-SLEEP>
+<SYNTAX SLEEP IN OBJECT (IN-ROOM ON-GROUND) = V-BOARD>
+<SYNTAX SLEEP ON OBJECT (IN-ROOM ON-GROUND) = V-BOARD>
+<VERB-SYNONYM SLEEP NAP ;SNOOZE>
+
+<SYNTAX SLIDE OBJECT = V-MOVE>
+<SYNTAX SLIDE ON OBJECT = V-BOARD>
+<SYNTAX SLIDE OBJECT UNDER OBJECT = V-PUT-UNDER>
+
+<SYNTAX SMELL = V-SMELL>
+<SYNTAX SMELL OBJECT = V-SMELL>
+<VERB-SYNONYM SMELL SNIFF>
+
+;<SYNTAX SPIN OBJECT = V-SPIN>
+;<VERB-SYNONYM SPIN WHIRL ROTATE>
+
+<SYNTAX STAND = V-STAND>
+<SYNTAX STAND UP OBJECT (FIND RLANDBIT) = V-STAND>
+<SYNTAX STAND IN OBJECT = V-BOARD>
+<SYNTAX STAND ON OBJECT = V-WASTE-OF-TIME <> STAND-ON>
+<SYNTAX STAND OBJECT AGAINST OBJECT = V-RAISE>
+<VERB-SYNONYM STAND RISE>
+
+<SYNTAX START OBJECT = V-LAMP-ON>
+<SYNTAX START UP OBJECT = V-LAMP-ON>
+
+<SYNTAX SWIM = V-SWIM>
+<SYNTAX SWIM IN OBJECT = V-SWIM>
+<VERB-SYNONYM SWIM WADE>
+
+<SYNTAX SWING OBJECT (FIND WEAPONBIT) (HELD CARRIED HAVE) = V-SWING>
+<SYNTAX SWING OBJECT (FIND WEAPONBIT) (HELD CARRIED HAVE)
+ AT OBJECT (FIND PERSON) (ON-GROUND IN-ROOM) = V-SWING>
+<VERB-SYNONYM SWING THRUST>
+
+<SYNTAX TAKE OBJECT (FIND TAKEBIT) (ON-GROUND IN-ROOM MANY) = V-TAKE PRE-TAKE>
+<SYNTAX TAKE IN OBJECT (FIND VEHBIT) (ON-GROUND IN-ROOM) = V-BOARD PRE-BOARD>
+<SYNTAX TAKE OUT OBJECT (FIND RLANDBIT) (ON-GROUND) = V-DISEMBARK>
+<SYNTAX TAKE ON OBJECT (FIND VEHBIT) (ON-GROUND IN-ROOM) = V-CLIMB-ON>
+<SYNTAX TAKE UP OBJECT (FIND RLANDBIT) = V-STAND>
+<SYNTAX TAKE OBJECT (FIND TAKEBIT) (CARRIED IN-ROOM MANY)
+ OUT OBJECT = V-TAKE PRE-TAKE>
+<SYNTAX TAKE OBJECT (FIND TAKEBIT) (CARRIED IN-ROOM MANY)
+ OFF OBJECT = V-TAKE PRE-TAKE>
+<SYNTAX TAKE OBJECT (FIND TAKEBIT) (IN-ROOM CARRIED MANY)
+ FROM OBJECT = V-TAKE PRE-TAKE>
+<SYNTAX TAKE OBJECT (FIND TAKEBIT) (IN-ROOM CARRIED MANY)
+ IN OBJECT = V-TAKE PRE-TAKE>
+<SYNTAX TAKE OFF OBJECT = V-TAKE-OFF>
+<SYNTAX TAKE DOWN OBJECT = V-LOWER>
+<SYNTAX TAKE OBJECT (FIND TAKEBIT) (IN-ROOM CARRIED MANY)
+ WITH OBJECT = V-PRY PRE-PRY>
+<VERB-SYNONYM TAKE GRAB CATCH GET HOLD CARRY SNATCH>
+
+<SYNTAX TELL OBJECT (FIND PERSON) (HELD CARRIED IN-ROOM) = V-TELL>
+<SYNTAX TELL OBJECT ABOUT OBJECT = V-TELL-ABOUT PRE-TELL-ABOUT>
+<SYNTAX TELL OBJECT OBJECT = V-REPLY>
+<SYNTAX TELL ABOUT OBJECT = V-TELL-ME-ABOUT>
+
+<SYNTAX THANK OBJECT = V-THANK>
+<SYNTAX THANK = V-THANK>
+<VERB-SYNONYM THANK THANKS>
+
+<SYNTAX THROW OBJECT (HELD CARRIED HAVE) = V-THROW>
+<SYNTAX THROW OBJECT (HELD CARRIED HAVE)
+ AT OBJECT (ON-GROUND IN-ROOM) = V-THROW>
+<SYNTAX THROW OBJECT (HELD CARRIED HAVE)
+ TO OBJECT (ON-GROUND IN-ROOM) = V-THROW>
+<SYNTAX THROW OBJECT (HELD CARRIED HAVE) OFF OBJECT = V-THROW-OFF>
+<SYNTAX THROW OBJECT (HELD CARRIED HAVE) OVER OBJECT = V-THROW-OFF>
+<SYNTAX THROW OBJECT (HELD CARRIED HAVE)
+ THROUGH OBJECT (ON-GROUND IN-ROOM) = V-THROW>
+<SYNTAX THROW OBJECT (HELD MANY HAVE) DOWN OBJECT = V-THROW>
+<SYNTAX THROW OBJECT (HELD MANY HAVE) IN OBJECT = V-THROW>
+<SYNTAX THROW OBJECT (HELD MANY HAVE) ON OBJECT = V-THROW>
+<SYNTAX THROW AWAY OBJECT (HELD MANY HAVE) = V-DROP PRE-DROP>
+<SYNTAX THROW OBJECT (HELD MANY HAVE)
+ AWAY OBJECT (FIND RLANDBIT) = V-DROP PRE-DROP>
+<VERB-SYNONYM THROW HURL TOSS PITCH>
+
+<SYNTAX TIE OBJECT TO OBJECT = V-TIE>
+<SYNTAX TIE OBJECT AROUND OBJECT = V-TIE>
+<SYNTAX TIE OBJECT ON OBJECT = V-TIE>
+<SYNTAX TIE UP OBJECT (FIND PERSON) (ON-GROUND IN-ROOM) WITH OBJECT
+ (FIND TOOLBIT) (ON-GROUND IN-ROOM HELD CARRIED HAVE) = V-TIE-UP>
+<VERB-SYNONYM TIE LOOP WRAP FASTEN ATTACH HOOK CONNECT>
+
+<SYNTAX TIME = V-TIME>
+<VERB-SYNONYM TIME T>
+
+<SYNTAX TORTUR OBJECT = V-TORTURE>
+
+<SYNTAX TOUCH OBJECT = V-RUB>
+<SYNTAX TOUCH OBJECT WITH OBJECT = V-RUB>
+<SYNTAX TOUCH OBJECT TO OBJECT = V-SRUB PRE-SRUB>
+<VERB-SYNONYM TOUCH FEEL PAT PET RUB SQUEEZE>
+
+<SYNTAX TURN OBJECT TO OBJECT = V-TURN>
+<SYNTAX TURN OBJECT = V-TURN>
+<SYNTAX TURN OBJECT WITH OBJECT (FIND TOOLBIT) (HAVE) = V-TURN>
+<SYNTAX TURN ON OBJECT (HELD CARRIED ON-GROUND IN-ROOM) = V-LAMP-ON>
+<SYNTAX TURN OFF OBJECT (HELD CARRIED ON-GROUND IN-ROOM TAKE) = V-LAMP-OFF>
+<SYNTAX TURN OVER OBJECT = V-TURN-OVER>
+<SYNTAX TURN AROUND OBJECT (FIND RLANDBIT) = V-TURN-AROUND>
+<SYNTAX TURN UP OBJECT = V-LAMP-ON>
+<VERB-SYNONYM TURN FLIP POWER SET>
+
+<SYNTAX STOP OBJECT = V-STOP>
+
+<SYNTAX LIGHT OBJECT (FIND LIGHTBIT) = V-LAMP-ON>
+<SYNTAX LIGHT UP OBJECT (FIND LIGHTBIT) = V-LAMP-ON>
+
+<SYNTAX UNLOCK OBJECT (ON-GROUND IN-ROOM)
+ WITH OBJECT (HELD CARRIED HAVE) = V-UNLOCK>
+
+<SYNTAX UNTIE OBJECT (ON-GROUND IN-ROOM HELD CARRIED) = V-UNTIE>
+<SYNTAX UNTIE OBJECT (ON-GROUND IN-ROOM HELD CARRIED) FROM OBJECT = V-UNTIE>
+<VERB-SYNONYM UNTIE UNWRAP FREE UNFASTEN UNATTACH UNHOOK DISCONNECT DETACH>
+
+<SYNTAX WAIT = V-WAIT>
+<SYNTAX WAIT OBJECT = V-WAIT>
+<SYNTAX WAIT FOR OBJECT = V-WAIT-FOR>
+<VERB-SYNONYM WAIT Z>
+
+<SYNTAX SCARE OBJECT (FIND PERSON) (ON-GROUND IN-ROOM) = V-SCARE>
+<SYNTAX SCARE OBJECT (FIND PERSON) (ON-GROUND IN-ROOM) WITH OBJECT = V-SCARE>
+<VERB-SYNONYM SCARE SURPRISE STARTLE CURDLE>
+
+<SYNTAX WAKE OBJECT (FIND RLANDBIT) = V-WAKE>
+<SYNTAX WAKE UP OBJECT (FIND RLANDBIT) = V-WAKE>
+<VERB-SYNONYM WAKE AWAKE ;ROUSE>
+
+<SYNTAX WALK = V-WALK-AROUND>
+<SYNTAX WALK OBJECT = V-WALK>
+<SYNTAX WALK IN OBJECT (FIND RLANDBIT) = V-THROUGH>
+<SYNTAX WALK ON OBJECT = V-STEP-ON>
+<SYNTAX WALK OVER OBJECT = V-LEAP>
+<SYNTAX WALK THROUGH OBJECT = V-THROUGH>
+<SYNTAX WALK AROUND OBJECT = V-WALK-AROUND>
+<SYNTAX WALK UP OBJECT (ON-GROUND IN-ROOM) = V-CLIMB-UP>
+<SYNTAX WALK DOWN OBJECT (ON-GROUND IN-ROOM) = V-CLIMB-DOWN>
+<SYNTAX WALK TO OBJECT = V-WALK-TO>
+<SYNTAX WALK UNDER OBJECT = V-WALK-UNDER>
+<SYNTAX WALK AWAY OBJECT (FIND RLANDBIT) = V-LEAVE>
+<SYNTAX WALK OBJECT ON OBJECT = V-DRIVE-ON>
+<SYNTAX WALK OBJECT OVER OBJECT = V-DRIVE-ON>
+<SYNTAX WALK OBJECT OBJECT = V-DRIVE-TO>
+<VERB-SYNONYM WALK GO RUN PROCEED STEP DRIVE STEER>
+
+<SYNTAX APPROACH OBJECT = V-WALK-TO>
+
+<SYNTAX WAVE OBJECT (HELD CARRIED) = V-WAVE>
+<SYNTAX WAVE AT OBJECT = V-WAVE-AT>
+<SYNTAX WAVE TO OBJECT = V-WAVE-AT>
+<SYNTAX YELL AT OBJECT = V-WAVE-AT>
+<SYNTAX WAVE OBJECT (HELD CARRIED) AT OBJECT = V-WAVE>
+<VERB-SYNONYM WAVE ;MOTION BECKON>
+
+<SYNTAX WEAR OBJECT (HELD CARRIED ON-GROUND IN-ROOM HAVE TAKE MANY) = V-WEAR>
+
+<SYNTAX WHAT OBJECT = V-WHAT>
+<SYNTAX WHAT ABOUT OBJECT = V-WHAT>
+;<VERB-SYNONYM WHAT WHATS>
+
+<SYNTAX WHERE = V-WHERE>
+<SYNTAX WHERE OBJECT = V-WHERE>
+;<VERB-SYNONYM WHERE WHERES>
+
+<SYNTAX WHO = V-WHO>
+<SYNTAX WHO OBJECT = V-WHO>
+;<VERB-SYNONYM WHO WHOS>
+
+<SYNTAX YAWN = V-YAWN>
+
+<SYNTAX YELL = V-YELL>
+<VERB-SYNONYM YELL SCREAM SHOUT>
+
+\^L
+
+;"magic spell syntaxes"
+
+;<SYNTAX LABEL OBJECT (HELD CARRIED) = V-SWRITE PRE-SWRITE>
+;<SYNTAX LABEL OBJECT (HELD CARRIED) WITH OBJECT = V-SWRITE PRE-SWRITE>
+
+;<SYNTAX WRITE OBJECT = V-WRITE PRE-WRITE>
+;<SYNTAX WRITE OBJECT ON OBJECT (HELD CARRIED) = V-WRITE PRE-WRITE>
+;<SYNTAX WRITE OBJECT IN OBJECT (HELD CARRIED) = V-WRITE PRE-WRITE>
+;<SYNTAX WRITE ON OBJECT (HELD CARRIED) = V-WRITE-ON PRE-WRITE-ON>
+;<SYNTAX WRITE IN OBJECT (HELD CARRIED) = V-WRITE-ON PRE-WRITE-ON>
+;<SYNTAX WRITE ON OBJECT (HELD CARRIED)
+ WITH OBJECT (FIND TOOLBIT) = V-WRITE-ON PRE-WRITE-ON>
+;<SYNTAX WRITE IN OBJECT (HELD CARRIED)
+ WITH OBJECT (FIND TOOLBIT) = V-WRITE-ON PRE-WRITE-ON>
+;<VERB-SYNONYM WRITE PRINT INSCRIBE SCRIBE>
+
+<SYNTAX PRY OBJECT WITH OBJECT = V-PRY PRE-PRY>
+<SYNTAX PRY OUT OBJECT WITH OBJECT = V-PRY PRE-PRY>
+<SYNONYM PRY LEVER>
+
+<SYNTAX BURY OBJECT = V-BURY>
+<SYNTAX BURY OBJECT IN OBJECT = V-BURY>
+
+<SYNTAX YES = V-YES>
+<VERB-SYNONYM YES Y OKAY>
+<SYNTAX NO = V-NO>
+<VERB-SYNONYM NO NOPE>
+
+<SYNTAX BUY OBJECT FROM OBJECT (FIND PERSON) = V-BUY>
+<SYNTAX BUY OBJECT WITH OBJECT = V-BUY>
+<VERB-SYNONYM BUY PURCHASE>
+
+<SYNTAX SELL OBJECT TO OBJECT (FIND PERSON) = V-SELL>
+<SYNTAX SELL OBJECT OBJECT = V-SSELL PRE-SSELL>
+
+<SYNTAX TRADE OBJECT (HELD CARRIED HAVE) WITH OBJECT (FIND PERSON) = V-TRADE>
+<SYNTAX TRADE OBJECT (HELD CARRIED HAVE) FOR OBJECT = V-TRADE>
+<SYNTAX TRADE OBJECT (HELD CARRIED HAVE) = V-TRADE>
+
+<SYNTAX ERASE OBJECT = V-ERASE>
+
+<SYNTAX ADMIRE OBJECT (FIND PERSON) = V-ADMIRE>
+<VERB-SYNONYM ADMIRE COMPLIMENT>
+
+;<SYNTAX COPY OBJECT (FIND READBIT)
+ WITH OBJECT (FIND TOOLBIT) = V-COPY>
+;<SYNTAX COPY OBJECT (FIND READBIT)
+ ON OBJECT = V-COPY>
+;<SYNTAX COPY OBJECT (FIND READBIT)
+ TO OBJECT = V-COPY>
+;<SYNTAX COPY OBJECT (FIND READBIT) = V-COPY>
+
+<SYNTAX BARGAIN WITH OBJECT (FIND PERSON) = V-BARGAIN>
+;<VERB-SYNONYM BARGAIN HAGGLE>
+
+<SYNTAX EDIT OBJECT = V-EDIT>
+<SYNTAX CLICK OBJECT = V-CLICK>
+<SYNTAX CLICK OBJECT WITH OBJECT = V-CLICK>
+<SYNTAX CLICK ON OBJECT = V-CLICK>
+<SYNTAX CLICK ON OBJECT WITH OBJECT = V-CLICK>
+<VERB-SYNONYM CLICK SELECT CHOOSE>
+
+<SYNTAX LET GO OBJECT (FIND RLANDBIT) = V-DROP PRE-DROP>
+<SYNTAX HANG FROM OBJECT = V-BOARD PRE-BOARD>
+<SYNTAX HANG OBJECT ON OBJECT = V-PUT-ON>
+<SYNTAX HANG OBJECT FROM OBJECT = V-PUT-ON>
+
+<SYNTAX TYPE OBJECT = V-TYPE>
+<SYNTAX TYPE LOGIN OBJECT = V-LOGIN>
+<SYNTAX TYPE PASSWORD OBJECT = V-PASSWORD>
+<VERB-SYNONYM TYPE INPUT>
+
+<SYNTAX WEDGE OBJECT WITH OBJECT = V-WEDGE>
+<SYNTAX WEDGE OBJECT IN OBJECT = V-SWEDGE PRE-SWEDGE>
+<SYNTAX WEDGE OBJECT BETWEEN OBJECT = V-SWEDGE PRE-SWEDGE>
+<VERB-SYNONYM WEDGE PROP>
+
+<SYNTAX DIE = V-DIE>
+
+<SYNTAX HACK = V-HACK>
+<SYNTAX HACK OBJECT = V-HACK>
+
+<SYNTAX COOK OBJECT = V-COOK>
+<VERB-SYNONYM COOK WARM HEAT>
diff --git a/verbs.zil b/verbs.zil
new file mode 100644
index 0000000..bd88d90
--- /dev/null
+++ b/verbs.zil
@@ -0,0 +1,2216 @@
+"VERBS for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+;"stuff to try to save space"
+
+<GLOBAL PERIOD ".|">
+<GLOBAL REFERRING "I don't see what you're referring to.">
+<GLOBAL I-DONT-THINK-THAT "I don't think that ">
+<GLOBAL IT-ALREADY-IS "It already is.|">
+;<GLOBAL DOESNT-FIT "It doesn't fit.|">
+<GLOBAL IT-LOOKS-LIKE "It looks like ">
+<GLOBAL IT-SEEMS-TO-BE "It seems to be ">
+<GLOBAL IT-IS-ALREADY "It's already ">
+<GLOBAL ITS-NOT-TIED "It's not tied to anything.|">
+<GLOBAL TOO-DARK "It's too dark to see!|">
+;<GLOBAL LOOK-AROUND-YOU "Look around you.|">
+<GLOBAL NOTHING-HAPPENS "Nothing happens.|">
+<GLOBAL TAKEN "Taken.|">
+<GLOBAL GOOD-TRICK "That would be a good trick.|">
+<GLOBAL WASTE-OF-TIME "That would be a waste of time.|">
+<GLOBAL THERE-IS-NOTHING "There is nothing ">
+<GLOBAL NO-ROOM "There's no room.">
+<GLOBAL THERES-NOTHING-TO "There's nothing to ">
+<GLOBAL ALREADY-IN-IT "You're already in it.">
+<GLOBAL YOURE-IN-IT "You're in it!|">
+<GLOBAL YOUVE-ALREADY "You've already ">
+<GLOBAL YOU-ARE "You already are">
+<GLOBAL YOU-HAVE "You already have ">
+<GLOBAL YOU-ARE-NOW "You are now ">
+<GLOBAL YOU-ARENT "You aren't ">
+<GLOBAL YOU-CANT "You can't ">
+<GLOBAL YOU-CANT-SEE "You can't see ">
+<GLOBAL YOU-FIND-NOTHING "You find nothing">
+<GLOBAL YOU-HAVE-TO "You'll have to ">
+
+;<ROUTINE DONT-HAVE-THAT ()
+ <TELL ,YOU-DONT-HAVE "that" ,PERIOD>>
+
+<ROUTINE TO-A-PRSO? ()
+ <HOW-DO-YOU> <A-PRSO?>>
+
+<ROUTINE CANT-GO ()
+ <TELL ,YOU-CANT "go that way." CR>>
+
+<ROUTINE NOT-HOLDING (OBJ)
+ <THIS-IS-IT .OBJ>
+ <TELL ,YOU-ARENT "holding " THE .OBJ ,PERIOD>>
+
+<ROUTINE ITS-EMPTY ()
+ <TELL CTHE ,PRSO " is empty" ,PERIOD>>
+
+<ROUTINE ITS-ALREADY-X (X)
+ <TELL ,IT-IS-ALREADY .X ,PERIOD>>
+
+<ROUTINE ALREADY-OPEN ()
+ <ITS-ALREADY-X "open">>
+
+<ROUTINE ALREADY-CLOSED ()
+ <ITS-ALREADY-X "closed">>
+
+<ROUTINE WITH-PRSI? ()
+ <TELL "With "><A-PRSI?>>
+
+<ROUTINE TELL-OPEN-CLOSED ("OPTIONAL" (OBJ <>))
+ <COND (.OBJ <TELL CTHE .OBJ>)
+ (ELSE
+ <SET OBJ ,PRSO>
+ <TELL THE ,PRSO>)>
+ <IS-ARE .OBJ>
+ <TELL " ">
+ <OPEN-CLOSED .OBJ>>
+
+<ROUTINE OPEN-CLOSED (OBJ)
+ <COND (<FSET? .OBJ ,OPENBIT>
+ <TELL "open">)
+ (ELSE
+ <TELL "closed">)>
+ <TELL ,PERIOD>>
+
+<ROUTINE THE-PRSO () <TELL THE ,PRSO ,PERIOD>>
+
+<ROUTINE A-PRSO () <TELL A ,PRSO ,PERIOD>>
+
+<ROUTINE A-PRSO? () <TELL A ,PRSO "?" CR>>
+
+<ROUTINE THE-PRSI () <TELL THE ,PRSI ,PERIOD>>
+
+;<ROUTINE A-PRSI () <TELL A ,PRSI ,PERIOD>>
+
+<ROUTINE A-PRSI? () <TELL A ,PRSI "?" CR>>
+
+<ROUTINE YOU-CANT-X-THAT (STR)
+ <TELL ,YOU-CANT .STR " that!" CR>>
+
+<ROUTINE YOU-CANT-X-PRSO (STR)
+ <TELL ,YOU-CANT .STR " ">
+ <COND (,PRSO <TELL THE ,PRSO>)
+ (ELSE <TELL "that">)>
+ <TELL ,PERIOD>>
+
+;<ROUTINE YOU-CANT-X-PRSI (STR)
+ <TELL ,YOU-CANT .STR " ">
+ <COND (,PRSI <TELL THE ,PRSI>)
+ (ELSE <TELL "that">)>
+ <TELL ,PERIOD>>
+
+<ROUTINE UNINTERESTED (OBJ)
+ <COND (<EQUAL? .OBJ ,ME>
+ <TELL-YUKS>)
+ (ELSE
+ <TELL CTHE .OBJ>
+ <IS-ARE .OBJ>
+ <TELL " uninterested." CR>)>>
+
+<ROUTINE IS-ARE (OBJ)
+ <COND (<PLURAL? .OBJ> <TELL " are">)
+ (ELSE <TELL " is">)>>
+
+<ROUTINE PLURAL? (OBJ)
+ <EQUAL? .OBJ ,RATS ,STUDENTS ,ELEVATOR-DOOR
+ ,ELEVATOR-DOOR-B ,ELEVATOR-DOOR-1 ,ELEVATOR-DOOR-2
+ ,ELEVATOR-DOOR-3 ,STEAM-PIPES ,GLOBAL-URCHINS
+ ,STUDENTS ,URCHINS>>
+
+<ROUTINE CANT-REACH-THAT ()
+ <YOU-CANT-X-THAT "reach">>
+
+;"end of space saving stuff"
+
+;"subtitle game commands"
+
+<GLOBAL VERBOSITY 1>
+
+<GLOBAL DESCRIPTIONS " descriptions">
+
+<ROUTINE V-VERBOSE ()
+ <SETG VERBOSITY 2>
+ <TELL "Verbose" ,DESCRIPTIONS ,PERIOD CR>
+ <V-LOOK>>
+
+<ROUTINE V-BRIEF ()
+ <SETG VERBOSITY 1>
+ <TELL "Brief" ,DESCRIPTIONS ,PERIOD>>
+
+<ROUTINE V-SUPER-BRIEF ()
+ <SETG VERBOSITY <>>
+ <TELL "Super-brief" ,DESCRIPTIONS ,PERIOD>>
+
+<ROUTINE V-DIAGNOSE ()
+ <TELL "You are ">
+ <COND (<L? ,AWAKE 0>
+ <TELL "wide awake">)
+ (T
+ <TELL <GET ,TIRED-TELL ,AWAKE>>)>
+ <TELL ", and are in ">
+ <COND (<G? ,FREEZE-COUNT 2>
+ <COND (<G? ,FREEZE-COUNT 3>
+ <TELL "imminent ">)>
+ <TELL "danger of freezing to death">)
+ (ELSE
+ <TELL "good health">
+ <COND (<NOT <ZERO? ,FREEZE-COUNT>>
+ <TELL " but getting cold">)>)>
+ <TELL ,PERIOD>>
+
+<GLOBAL TIRED-TELL
+ <PTABLE
+ "beginning to tire"
+ "feeling tired"
+ "getting more and more tired"
+ "worn out"
+ "dead tired"
+ "so tired you can barely concentrate"
+ "moving on your last reserves of strength"
+ "practically asleep"
+ "barely able to keep your eyes open"
+ "about to keel over from exhaustion">>
+
+<ROUTINE V-INVENTORY ()
+ <SETG D-BIT <- ,WEARBIT>>
+ <COND (<NOT <DESCRIBE-CONTENTS ,WINNER
+ <>
+ <+ ,D-ALL? ,D-PARA?>>>
+ <TELL "You are empty-handed.">)>
+ <SETG D-BIT ,WEARBIT>
+ <DESCRIBE-CONTENTS ,WINNER
+ <>
+ <+ ,D-ALL? ,D-PARA?>>
+ <SETG D-BIT <>>
+ <CRLF>>
+
+<ROUTINE V-QUIT ("OPTIONAL" (ASK? T) "AUX" SCOR)
+ %<DEBUG-CODE <TELL-C-INTS>>
+ <V-SCORE>
+ <COND (<OR <AND .ASK?
+ <TELL
+S "Do you wish to ""leave the game">
+ <YES?>>
+ <NOT .ASK?>>
+ <QUIT>)
+ (T
+ <TELL ,OKAY>)>>
+
+<ROUTINE V-RESTART ()
+ %<DEBUG-CODE <TELL-C-INTS>>
+ <V-SCORE T>
+ <TELL S "Do you wish to ""restart">
+ <COND (<YES?>
+ <TELL "Restarting." CR>
+ <RESTART>
+ <TELL ,FAILED>)>>
+
+<GLOBAL OKAY "Okay.|">
+
+<GLOBAL FAILED "Failed.|">
+
+<ROUTINE FINISH ()
+ <USL>
+ <CRLF>
+ %<DEBUG-CODE <TELL-C-INTS>>
+ <V-SCORE>
+ <CRLF>
+ <TELL
+"Would you like to restart the game from the beginning, restore a saved
+game position, or end this session of the game?" CR>
+ <REPEAT ()
+ <TELL
+"(Type RESTART, RESTORE, or QUIT):|
+>">
+ <READ ,P-INBUF ,P-LEXV>
+ <COND (<EQUAL? <GET ,P-LEXV 1> ,W?RESTAR>
+ <RESTART>
+ <TELL ,FAILED>)
+ (<EQUAL? <GET ,P-LEXV 1> ,W?RESTOR>
+ <COND (<RESTORE>
+ <TELL ,OKAY>)
+ (T
+ <TELL ,FAILED>)>)
+ (<EQUAL? <GET ,P-LEXV 1> ,W?QUIT ,W?Q>
+ <QUIT>)>>>
+
+<ROUTINE YES? ()
+ <PRINTI "?|
+(Y is affirmative): >">
+ <READ ,P-INBUF ,P-LEXV>
+ <COND (<EQUAL? <GET ,P-LEXV 1> ,W?YES ,W?Y>
+ <RTRUE>)
+ (T
+ <RFALSE>)>>
+
+<ROUTINE V-RESTORE ()
+ <COND (<RESTORE> <RTRUE>)
+ (T
+ <TELL ,FAILED>)>>
+
+<ROUTINE V-SAVE ("AUX" X)
+ <PUTB ,OOPS-INBUF 1 0>
+ <SET X <SAVE>>
+ <COND (<ZERO? .X>
+ <TELL ,FAILED>)
+ (ELSE
+ <TELL ,OKAY>)>>
+
+<ROUTINE V-SCORE ("OPTIONAL" (ASK? T))
+ <TELL
+"Your score is " N ,SCORE " of a possible 100, in " N ,MOVES " move">
+ <COND (<NOT <1? ,MOVES>> <TELL "s">)>
+ <TELL ". Graded on the curve, you are in the class of "
+ <GET ,RANKINGS </ ,SCORE 10>>>
+ <TELL ,PERIOD>
+ ,SCORE>
+
+<GLOBAL RANKINGS
+ <PTABLE
+ "Freshman" ;"0"
+ "Sophomore" ;"10"
+ "Junior" ;"20"
+ "Senior" ;"30"
+ "Graduate Student" ;"40"
+ "Post-doc Student" ;"50"
+ "Assistant Professor" ;"60"
+ "Professor" ;"70"
+ "Department Head" ;"80"
+ "Dean of Engineering" ;"90"
+ "President of the Institute" ;"100">>
+
+<ROUTINE V-SCRIPT ()
+ <PUT 0 8 <BOR <GET 0 8> 1>>
+ <TELL
+"Start of a transcript of " ,LURKING-HORROR ,PERIOD>
+ <V-VERSION>>
+
+<ROUTINE V-UNSCRIPT ()
+ <TELL "End of transcript" ,PERIOD>
+ <PUT 0 8 <BAND <GET 0 8> -2>>
+ <RTRUE>>
+
+<GLOBAL LURKING-HORROR "THE LURKING HORROR">
+
+<ROUTINE V-VERSION ()
+ <TELL
+,LURKING-HORROR "|
+An Interactive Horror|
+Copyright (c) 1987 by Infocom, Inc. All rights reserved.|"
+,LURKING-HORROR " is a trademark of Infocom, Inc.|
+Release ">
+ <PRINTN <BAND <GET 0 1> *3777*>>
+ <TELL " / Serial number ">
+ <DO (CNT 18 23)
+ <PRINTC <GETB 0 .CNT>>>
+ <CRLF>>
+
+<ROUTINE V-$VERIFY ()
+ <COND (<AND <PRSO? ,INTNUM>
+ <EQUAL? ,P-NUMBER 1066>>
+ <TELL N ,SERIAL CR>)
+ (,PRSO
+ <TELL ,NOT-RECOGNIZED CR>)
+ (ELSE
+ <TELL "Verifying..." CR>
+ <COND (<VERIFY> <TELL "The disk is correct." CR>)
+ (T <TELL CR "** Disk Failure **" CR>)>)>>
+^\L
+
+;"subtitle real verbs"
+
+<ROUTINE V-WAKE ()
+ <COND (<PRSO? ,ROOMS>
+ <NEW-PRSO ,ME>
+ <RTRUE>)
+ (T
+ <TELL
+,I-DONT-THINK-THAT THE ,PRSO " is sleeping." CR>)>>
+
+<ROUTINE V-ANSWER ()
+ <TELL "Nobody is awaiting your answer." CR>
+ <END-QUOTE>>
+
+"V-ASK-ABOUT -- transform into PRSO, TELL ME ABOUT PRSI"
+
+<ROUTINE PRE-ASK-ABOUT ("AUX" P)
+ <COND (<AND <NOT ,PRSI>
+ <SET P <FIND-IN ,HERE ,PERSON>>>
+ <PERFORM-PRSA .P ,PRSO>
+ <RTRUE>)>>
+
+<ROUTINE V-ASK-ABOUT ()
+ <COND (<PRSO? ,ME>
+ <NEW-VERB ,V?TELL>
+ <RTRUE>)
+ (<FSET? ,PRSO ,PERSON>
+ <NEW-WINNER-PRSO ,V?TELL-ME-ABOUT ,PRSI>
+ <RTRUE>)
+ (T
+ <NEW-VERB ,V?TELL>
+ <RTRUE>)>>
+
+<ROUTINE FIND-IN (WHERE WHAT "AUX" W)
+ <MAP-CONTENTS (W .WHERE)
+ (END <RFALSE>)
+ <COND (<AND <FSET? .W .WHAT> <VISIBLE? .W>>
+ <RETURN .W>)>>>
+
+"V-ASK-FOR -- transform into PRSO, GIVE PRSI TO ME"
+
+<ROUTINE PRE-ASK-FOR ()
+ <PRE-ASK-ABOUT>>
+
+<ROUTINE V-ASK-FOR ()
+ <COND (<PRSO? ,ME>
+ <PERFORM ,V?TAKE ,PRSI>
+ <RTRUE>)
+ (<FSET? ,PRSO ,PERSON>
+ <NEW-WINNER-PRSO ,V?GIVE ,PRSI ,ME>
+ <RTRUE>)
+ (T
+ <TELL
+"It's unlikely that " THE ,PRSO " will oblige." CR>)>>
+
+<ROUTINE V-ATTACK ()
+ <IKILL "attack">>
+
+<ROUTINE V-BITE ()
+ <HACK-HACK "Biting">>
+
+<ROUTINE PRE-BOARD ("AUX" AV)
+ <SET AV <LOC ,WINNER>>
+ <COND (<FSET? ,PRSO ,VEHBIT>
+ <COND (<EQUAL? .AV ,PRSO>
+ <TELL ,YOU-ARE ,PERIOD>)
+ (<AND <FSET? .AV ,VEHBIT>
+ <HELD? ,PRSO .AV>>
+ <TELL ,YOU-HAVE-TO "leave " THE .AV " first" ,PERIOD>)
+ (T
+ <RFALSE>)>)
+ (T
+ <TELL ,YOU-CANT "get into " THE ,PRSO "!" CR>)>
+ <RFATAL>>
+
+<ROUTINE YOU-ARE-IN (AV)
+ <TELL ,YOU-ARE
+ <COND (<FSET? .AV ,SURFACEBIT> " on ")
+ (ELSE " in ")>
+ THE .AV "!" CR>>
+
+<ROUTINE V-BOARD ("AUX" AV)
+ <TELL ,YOU-ARE-NOW "in ">
+ <THE-PRSO>
+ <MOVE ,WINNER ,PRSO>
+ %<DEBUG-CODE <D-APPLY "Get in" <GETP ,PRSO ,P?ACTION> ,M-ENTER>
+ <APPLY <GETP ,PRSO ,P?ACTION> ,M-ENTER>>
+ <RTRUE>>
+
+<ROUTINE V-BURN ()
+ <COND (<NOT ,PRSI>
+ <TELL "Your blazing gaze is insufficient." CR>)
+ (T
+ <WITH-PRSI?>)>>
+
+<ROUTINE V-CHASTISE ()
+ <TELL
+"Use prepositions instead: LOOK AT the object, LOOK INSIDE it,
+LOOK UNDER it, etc." CR>>
+
+<ROUTINE V-CLIMB-DOWN ()
+ <COND (<PRSO? ,ROOMS>
+ <DO-WALK ,P?DOWN>)
+ (T
+ <TELL ,WASTE-OF-TIME>)>>
+
+<ROUTINE V-CLIMB-FOO ()
+ <COND (<PRSO? ,ROOMS>
+ <DO-WALK ,P?UP>)
+ (T
+ <TELL ,WASTE-OF-TIME>)>>
+
+<ROUTINE V-CLIMB-ON ()
+ <COND (<AND <FSET? ,PRSO ,VEHBIT>
+ <FSET? ,PRSO ,SURFACEBIT>>
+ <NEW-VERB ,V?BOARD>
+ <RTRUE>)
+ (T
+ <TELL ,YOU-CANT "climb onto "><A-PRSO>)>>
+
+<ROUTINE V-CLIMB-OVER ()
+ <YOU-CANT-X-THAT "do">>
+
+<ROUTINE V-CLIMB-UP ()
+ <COND (<PRSO? ,ROOMS>
+ <DO-WALK ,P?UP>)
+ (T
+ <TELL ,WASTE-OF-TIME>)>>
+
+<ROUTINE V-CLOSE ()
+ <COND (<AND <NOT <FSET? ,PRSO ,OPENBIT>>
+ <FSET? ,PRSO ,OPENABLE>>
+ <TELL CTHE ,PRSO " is already closed." CR>)
+ (<OR <FSET? ,PRSO ,SURFACEBIT>
+ <AND <NOT <FSET? ,PRSO ,CONTBIT>>
+ <NOT <FSET? ,PRSO ,DOORBIT>>>>
+ <TELL "There's no way to close "><THE-PRSO>)
+ (<FSET? ,PRSO ,PERSON>
+ <TELL "Huh?" CR>)
+ (<NOT <EQUAL? <GETP ,PRSO ,P?CAPACITY> 0>>
+ <COND (<FSET? ,PRSO ,OPENBIT>
+ <FCLEAR ,PRSO ,OPENBIT>
+ <TELL "Closed">
+ <IN-DARK?>)
+ (T
+ <ALREADY-CLOSED>)>)
+ (<FSET? ,PRSO ,DOORBIT>
+ <CLOSE-A-DOOR>)
+ (T
+ <YOU-CANT-X-THAT "close">)>>
+
+<ROUTINE CLOSE-A-DOOR ()
+ <COND (<FSET? ,PRSO ,OPENBIT>
+ <OKAY-THE-PRSO-IS-NOW "closed">
+ <FCLEAR ,PRSO ,OPENBIT>)
+ (T
+ <ALREADY-CLOSED>)>>
+
+<ROUTINE IN-DARK? ("OPT" (DIE? <>) "AUX" OLIT)
+ <SET OLIT ,LIT>
+ <SETG LIT <LIT? ,HERE>>
+ <COND (<AND .OLIT <NOT ,LIT>>
+ <TELL
+", leaving you in the dark." CR>
+ <COND (.DIE?
+ <CRLF>
+ <TELL "Not alone, however. ">
+ <JIGS-UP ;"this string is a duplicate of one in GOTO"
+"One should never assume the dark is safe.
+Something just grabbed you from behind and dragged you
+off to its lair.">)
+ (ELSE <RTRUE>)>)
+ (ELSE <TELL ,PERIOD>)>>
+
+<ROUTINE OKAY-THE-PRSO-IS-NOW (STR)
+ <TELL "Okay, " THE ,PRSO " is now " .STR ,PERIOD>>
+
+<ROUTINE V-COMPARE-MANY ()
+ <COND (<EQUAL? <GET ,P-PRSO 0> 2>
+ <SETG P-MULT <>>
+ <PERFORM ,V?COMPARE <GET ,P-PRSO 1> <GET ,P-PRSO 2>>
+ <RFATAL>)
+ (ELSE
+ <TELL "You can only compare two things." CR>)>>
+
+<ROUTINE V-WASTE-OF-TIME ()
+ <TELL ,WASTE-OF-TIME>>
+
+<ROUTINE V-COMPARE ()
+ <COND (<AND <PRSO? RAT-SYMBOL STONE-SYMBOL CARVING-SYMBOL TATTOO CARTON>
+ <PRSI? RAT-SYMBOL STONE-SYMBOL CARVING-SYMBOL TATTOO CARTON>>
+ <TELL
+"Allowing for the different media in which the symbols are executed,
+they are identical." CR>)
+ (ELSE
+ <TELL ,WASTE-OF-TIME>)>>
+
+;<ROUTINE V-COUNT ()
+ <TELL ,WASTE-OF-TIME>>
+
+<ROUTINE V-CROSS ()
+ <YOU-CANT-X-THAT "cross">>
+
+<ROUTINE V-CURSE ()
+ <TELL
+"Language like that was until recently grounds for probation!" CR>>
+
+<ROUTINE V-CUT ()
+ <COND (<FSET? ,PRSO ,PERSON>
+ <NEW-VERB ,V?KILL>
+ <RTRUE>)
+ (<OR <NOT ,PRSI> <NOT <FSET? ,PRSI ,WEAPONBIT>>>
+ <COND (<OR <NOT ,PRSI> <INTRINSIC? ,PRSI>>
+ <TELL "Your body">)
+ (ELSE
+ <TELL CTHE ,PRSI>)>
+ <TELL
+" has an inadequate \"cutting edge.\"" CR>)
+ (T
+ <TO-A-PRSO?>)>>
+
+;<ROUTINE V-DIG ()
+ <TELL ,WASTE-OF-TIME>>
+
+<ROUTINE V-DISEMBARK ("AUX" AV)
+ <SET AV <LOC ,WINNER>>
+ <COND (<OR <NOT ,PRSO>
+ <PRSO? ,ROOMS>>
+ <COND (<AND .AV <FSET? .AV ,VEHBIT>>
+ <NEW-PRSO .AV>
+ <RTRUE>)
+ ;(<FSET? ,HERE ,RWATERBIT>
+ <DO-WALK ,P?UP>)
+ (ELSE
+ <TELL ,YOU-ARENT "in anything." CR>)>)
+ (<AND .AV
+ <FSET? .AV ,VEHBIT>>
+ <COND (<AND <NOT <EQUAL? .AV ,PRSO>>
+ <NOT <HELD? .AV ,PRSO>>>
+ <YOU-ARE-IN .AV>
+ <RFATAL>)
+ (T
+ <MOVE ,WINNER <LOC ,PRSO>> ;"for vehicle in vehicle"
+ <TELL ,YOU-ARE-NOW "on your feet." CR>)>)
+ (<LOC ,PRSO>
+ <NEW-VERB ,V?TAKE>
+ <RTRUE>)
+ (ELSE
+ <TELL "It's not in anything." CR>)>>
+
+<ROUTINE V-DRINK ("AUX" S)
+ <YOU-CANT-X-THAT "drink">>
+
+<ROUTINE V-DRINK-FROM ("AUX" X)
+ <COND ;(<PRSO? ,WATER>
+ <PERFORM ,V?DRINK ,PRSO>
+ <RTRUE>)
+ (T
+ <TO-A-PRSO?>)>>
+
+<ROUTINE PRE-DROP ()
+ <COND (<OR <AND <PRSO? ,ROOMS ,CABLE>
+ ,ON-CABLE?>
+ <PRSO? <LOC ,WINNER>>>
+ <NEW-VERB ,V?DISEMBARK>
+ <RTRUE>)>>
+
+<ROUTINE V-DROP ()
+ <COND (<PRSO? ,ROOMS>
+ <TELL ,YOU-ARENT "hanging from anything." CR>)
+ (<IDROP>
+ <TELL "Dropped." CR>)
+ (ELSE <RTRUE>)>>
+
+<ROUTINE V-EAT ("AUX" H)
+ <COND (<AND <GETPT ,PRSO ,P?HEAT>
+ <FSET? ,PRSO ,FOODBIT>>
+ <TELL "It tastes " <HEAT ,PRSO> ,PERIOD>)
+ (ELSE
+ <TELL
+"The food here is terrible, but this is ridiculous!" CR>)>>
+
+<ROUTINE V-ENTER ("AUX" VEHICLE)
+ <COND (<IN? ,PENTAGRAM ,HERE>
+ <PERFORM ,V?BOARD ,PENTAGRAM>
+ <RTRUE>)
+ (<GETPT ,HERE ,P?IN>
+ <DO-WALK ,P?IN>)
+ (ELSE
+ <V-WALK-AROUND>)>>
+
+<ROUTINE PRE-EXAMINE ()
+ <COND (<NOT ,LIT>
+ <TELL ,TOO-DARK>)
+ (<FSET? ,PRSO ,SLIMEBIT>
+ <TELL "First, it's covered with slime. ">
+ <RFALSE>)>>
+
+<ROUTINE V-EXAMINE ("AUX" H)
+ <COND (<AND <FSET? ,PRSO ,READBIT>
+ <GETP ,PRSO ,P?TEXT>>
+ <NEW-VERB ,V?READ>
+ <RTRUE>)
+ (<FSET? ,PRSO ,DOORBIT>
+ <V-LOOK-INSIDE>)
+ (<FSET? ,PRSO ,CONTBIT>
+ <COND (<FSET? ,PRSO ,OPENBIT>
+ <V-LOOK-INSIDE>)
+ (T
+ <TELL S "It's closed.|">)>)
+ (<GETPT ,PRSO ,P?HEAT>
+ <TELL "It looks " <HEAT ,PRSO> ,PERIOD>)
+ (T
+ <PRSO-NOTHING-SPECIAL>)>>
+
+<ROUTINE PRSO-NOTHING-SPECIAL ()
+ <TELL S "You see nothing special about ">
+ <THE-PRSO>>
+
+<ROUTINE V-EXIT ()
+ <COND (<AND ,PRSO <FSET? ,PRSO ,VEHBIT>>
+ <NEW-VERB ,V?DISEMBARK>
+ <RTRUE>)
+ (<GETPT ,HERE ,P?OUT>
+ <DO-WALK ,P?OUT>)
+ (ELSE
+ <V-WALK-AROUND>)>>
+
+<ROUTINE V-FILL ()
+ <COND (<NOT ,PRSI>
+ <TELL
+,THERES-NOTHING-TO "fill it with" ,PERIOD>)
+ (T
+ <TELL-YUKS>)>>
+
+<ROUTINE V-FIND ("OPT" (WHERE <>) "AUX" L)
+ <COND (<INTRINSIC? ,PRSO>
+ <TELL
+"Nearby, I'm sure">)
+ (<IN? ,PRSO ,PLAYER>
+ <TELL "You have it">)
+ (<OR <IN? ,PRSO ,HERE>
+ <PRSO? ,PSEUDO-OBJECT>>
+ <TELL "Right in front of you">)
+ (<OR <IN? ,PRSO ,LOCAL-GLOBALS>
+ <IN? ,PRSO ,GLOBAL-OBJECTS>>
+ <TELL "It could be lurking right behind you">)
+ (ELSE
+ <SET L <LOC ,PRSO>>
+ <COND (<AND <EQUAL? .L ,URCHIN>
+ <VISIBLE? .L>>
+ <TELL "Maybe an urchin ripped it off">)
+ (<AND <FSET? .L ,PERSON>
+ <VISIBLE? .L>>
+ <TELL "I think " THE .L " has it">)
+ (<ACCESSIBLE? ,PRSO>
+ <TELL "It's in " THE .L>)
+ (.WHERE
+ <TELL "Beats me">)
+ (T
+ <TELL ,YOU-HAVE-TO "do that yourself">)>)>
+ <TELL ,PERIOD>>
+
+<ROUTINE V-FOLLOW ()
+ <COND (<AND ,PRSO <IN? ,PRSO ,HERE>>
+ <TELL CTHE ,PRSO " is right here!" CR>)
+ (T
+ <TELL ,WASTE-OF-TIME>)>>
+
+<ROUTINE PRE-GIVE ()
+ <COND (<AND <WINNER? ,PLAYER>
+ <NOT <HELD? ,PRSO>>
+ <TELL
+,YOU-HAVE-TO "get it first." CR>)>>
+
+<ROUTINE V-GIVE ()
+ <COND (<NOT <FSET? ,PRSI ,PERSON>>
+ <TELL ,YOU-CANT "give " A ,PRSO " to " A ,PRSI "!" CR>)
+ (T
+ <UNINTERESTED ,PRSI>)>>
+
+<ROUTINE V-HELLO ("AUX" OWINNER)
+ <COND (,PRSO
+ <COND (<FSET? ,PRSO ,PERSON>
+ <NEW-WINNER-PRSO ,PRSA>
+ <RTRUE>)
+ (T
+ <TELL
+"Serious college students never say \"Hello\" to "><A-PRSO>)>)
+ (T
+ <TELL "Cheery, aren't you?" CR>)>>
+
+<ROUTINE V-HELP ()
+ <COND (,PRSO
+ <TELL
+CTHE ,PRSO S " doesn't appear to ""want help." CR>)
+ (<IN? ,PC ,HERE>
+ <PERFORM ,V?PUSH ,HELP-KEY>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"If you're really stuck, you can order maps and InvisiClues Hint
+Booklets using the order form that came in your package." CR>)>>
+
+<ROUTINE V-HIDE ()
+ <COND (<NOT ,PRSO>
+ <TELL "There's no place to hide here." CR>
+ <RFATAL>)
+ (<AND ,PRSI <FSET? ,PRSI ,PERSON>>
+ <UNINTERESTED ,PRSI>)
+ (<NOT ,PRSI>
+ <TELL ,WASTE-OF-TIME> ;"useless")>>
+
+<ROUTINE V-HIDE-FROM ()
+ <TELL ,YOU-HAVE-TO "decide where." CR>>
+
+<ROUTINE V-KICK ()
+ <HACK-HACK "Kicking">>
+
+<ROUTINE V-KILL ()
+ <IKILL "kill">>
+
+<ROUTINE IKILL (STR)
+ <COND (<NOT ,PRSO>
+ <TELL ,THERES-NOTHING-TO .STR " here." CR>)>
+ <COND (<FSET? ,PRSO ,DOORBIT>
+ <TELL
+"Pounding on a door is of little use." CR>)
+ (<NOT <FSET? ,PRSO ,PERSON>>
+ <TO-A-PRSO?>)
+ (<OR <PRSI? <> ,HANDS>
+ <NOT <FSET? ,PRSI ,WEAPONBIT>>>
+ <TELL
+"Trying to " .STR " " THE ,PRSO " with ">
+ <COND (<NOT <PRSI? <> ,HANDS>>
+ <TELL A ,PRSI>)
+ (ELSE <TELL "your bare hands">)>
+ <TELL " is suicidal." CR>)
+ (<NOT <IN? ,PRSI ,WINNER>>
+ <NOT-HOLDING ,PRSI>)
+ (T
+ <NOT-TRAINED>)>>
+
+<ROUTINE NOT-TRAINED ()
+ <TELL
+"You miss. (Now you know why few technical schools make it to the
+Rose Bowl.)" CR>>
+
+<ROUTINE V-KNOCK ()
+ <COND (<FSET? ,PRSO ,DOORBIT>
+ <TELL "Nobody's home." CR>)
+ (T
+ <TELL "Why knock on "> <A-PRSO?>)>>
+
+<ROUTINE V-KISS ()
+ <COND (<FSET? ,PRSO ,PERSON>
+ <UNINTERESTED ,PRSO>)
+ (ELSE <TELL-YUKS>)>>
+
+<ROUTINE V-LAMP-OFF ()
+ <TO-A-PRSO?> ;"flashlight is only light source">
+
+<ROUTINE V-LAMP-ON ()
+ <TO-A-PRSO?>>
+
+<ROUTINE V-LEAN-ON ()
+ <TELL "Tired?" CR>>
+
+<ROUTINE V-LEAP ()
+ <COND (<AND ,PRSO <IN? ,PRSO ,HERE>>
+ <V-SKIP>)
+ (<HERE? CS-ROOF ON-DOME>
+ <JIGS-UP
+"It was a long way down. It was quick, though.">)
+ (T
+ <TELL ,GOOD-TRICK>)>>
+
+<ROUTINE V-LEAVE ()
+ <DO-WALK ,P?OUT>>
+
+<ROUTINE V-LISTEN ()
+ <COND (<HERE? ,YUGGOTH ,BOWL-ROOM ,PLATFORM-ROOM>
+ <TELL
+"The sounds here are harsh and discordant." CR>)
+ (<HERE? ,CAVE-ALTAR ,CAVE-ROOM>
+ <I-PANEL-NOISES T>)
+ (<AND ,PRSO <NOT <PRSO? ,NOISE>>>
+ <TELL
+"At the moment, " THE ,PRSO " is as quiet as a graveyard." CR>)
+ (<AND <IN-TUNNEL? ,RATS>
+ <IN-TUNNEL? ,WINNER>>
+ <TELL ,RATS-CHITTERING>)
+ (<PROB 90>
+ <TELL
+"You hear nothing unsettling." CR>)
+ (ELSE
+ <TELL
+"You hear a very odd noise, sort of like breathing." CR>)>>
+
+<ROUTINE V-LOCK ()
+ <TELL CTHE ,PRSO " doesn't have a lock." CR>>
+
+<ROUTINE V-FIRST-LOOK ()
+ <COND (<DESCRIBE-ROOM <G? ,VERBOSITY 1>>
+ <COND (,VERBOSITY <DESCRIBE-OBJECTS>)>)>>
+
+<ROUTINE V-LOOK ()
+ <COND (<DESCRIBE-ROOM T>
+ <DESCRIBE-OBJECTS>)>>
+
+<ROUTINE V-LOOK-BEHIND ()
+ <COND (<AND <NOT <FSET? ,PRSO ,OPENBIT>>
+ <NOT <FSET? ,PRSO ,SURFACEBIT>>
+ <OR <FSET? ,PRSO ,CONTBIT>
+ <FSET? ,PRSO ,DOORBIT>>>
+ <INSPECTION-REVEALS ,PRSO>)
+ (ELSE
+ <TELL ,THERE-IS-NOTHING "behind "><THE-PRSO>)>>
+
+<ROUTINE V-LOOK-DOWN ()
+ <COND (<NOT ,LIT>
+ <TELL ,TOO-DARK>)
+ (<PRSO? <> ,ROOMS ,GLOBAL-HOLE>
+ <COND (<GLOBAL-IN? ,GLOBAL-HOLE ,HERE>
+ <PERFORM ,V?LOOK-INSIDE ,GLOBAL-HOLE>)
+ (ELSE
+ <PERFORM ,V?EXAMINE ,GROUND>)>
+ <RTRUE>)
+ (ELSE
+ <PRSO-NOTHING-SPECIAL>)>>
+
+<ROUTINE WHAT-CONTENTS ()
+ <COND (<NOT <DESCRIBE-CONTENTS ,PRSO>>
+ <TELL "nothing">
+ <COND (<IN? ,PLAYER ,PRSO>
+ <TELL " (other than you)">)>)>
+ <TELL ,PERIOD>>
+
+<ROUTINE V-LOOK-INSIDE ()
+ <COND (<FSET? ,PRSO ,PERSON>
+ <PRSO-NOTHING-SPECIAL>)
+ (<FSET? ,PRSO ,SURFACEBIT>
+ <TELL "On " THE ,PRSO " is ">
+ <WHAT-CONTENTS>)
+ (<FSET? ,PRSO ,DOORBIT>
+ <THIS-IS-IT ,PRSO>
+ <TELL "All you can tell is that ">
+ <TELL-OPEN-CLOSED>)
+ (<FSET? ,PRSO ,CONTBIT>
+ <COND (<PRSO? <LOC ,WINNER>>
+ <MOVE ,PLAYER ,ROOMS>
+ <TELL "Aside from you, there's ">
+ <WHAT-CONTENTS>
+ <MOVE ,PLAYER ,PRSO>)
+ (<SEE-INSIDE? ,PRSO>
+ <TELL CTHE ,PRSO " contains ">
+ <WHAT-CONTENTS>)
+ (<AND <NOT <FSET? ,PRSO ,OPENBIT>>
+ <FIRST? ,PRSO>>
+ <NEW-VERB ,V?OPEN>
+ <RTRUE>)
+ (T
+ <THIS-IS-IT ,PRSO>
+ <TELL "It seems ">
+ <TELL-OPEN-CLOSED>)>)
+ (T
+ <YOU-CANT-X-PRSO "look inside">)>>
+
+<ROUTINE V-LOOK-UNDER ()
+ <COND (<HELD? ,PRSO>
+ <TELL "You're already holding it!" CR>)
+ (T
+ <TELL ,THERE-IS-NOTHING "there." CR>)>>
+
+<ROUTINE V-LOWER ()
+ <HACK-HACK "Lowering">>
+
+<ROUTINE V-LOWER-INTO ()
+ <V-LOWER>>
+
+<ROUTINE V-MELT ()
+ <WITH-PRSI?>>
+
+<ROUTINE V-MOVE ()
+ <COND (<HELD? ,PRSO>
+ <TELL
+"You're holding it. Are you planning to juggle it?" CR>)
+ (<AND <FSET? ,PRSO ,TAKEBIT>
+ <NOT <FSET? ,PRSO ,PERSON>>>
+ <V-TURN-OVER>)
+ (T
+ <YOU-CANT-X-PRSO "move">)>>
+
+<ROUTINE HOSTILE-VERB? ()
+ <VERB? ATTACK BITE CUT KICK KILL MUNG RUB PUSH MOVE THROW>>
+
+"verbs which don't require object to exist/be nearby"
+
+<ROUTINE ABSTRACT-VERB? ()
+ <VERB? ASK-ABOUT ASK-FOR FIND
+ TELL-ME-ABOUT TELL-ABOUT WHAT WHERE>>
+
+"verbs with no object or which don't require touching their object."
+
+<ROUTINE PASSIVE-VERB? ()
+ <OR <ABSTRACT-VERB?>
+ <VERB? COMPARE COUNT CURSE DIE DISEMBARK
+ EXAMINE HELLO LISTEN LOOK-BEHIND LOOK-DOWN
+ LOOK-INSIDE LOOK-UNDER POINT READ REPLY
+ SAY SCARE SHOW TELL THANK
+ WAIT WAIT-FOR WALK WAVE-AT YAWN
+ YELL>>>
+
+<ROUTINE V-MUNG ()
+ <HACK-HACK "Trying to break">>
+
+<ROUTINE PRE-OPEN ()
+ <COND (<AND <IN? ,PRSO ,MICROWAVE>
+ <NOT <FSET? ,MICROWAVE ,OPENBIT>>>
+ <YOU-CANT-X-THAT "get to">)
+ (<OR <FSET? ,PRSO ,PERSON>
+ <PRSO? ,DEAD-RAT ,HAND>>
+ <TELL "What a grisly idea." CR>)
+ (<AND ,PRSI
+ <NOT <PRSI? ,FORKLIFT>>
+ <NOT <HELD? ,PRSI>>>
+ <NOT-HOLDING ,PRSI>)>>
+
+<ROUTINE V-OPEN ("AUX" F STR)
+ <COND (<AND <FSET? ,PRSO ,OPENBIT>
+ <FSET? ,PRSO ,OPENABLE>>
+ <TELL CTHE ,PRSO " is already open." CR>)
+ (<OR <AND <NOT <FSET? ,PRSO ,CONTBIT>>
+ <NOT <FSET? ,PRSO ,DOORBIT>>>
+ <FSET? ,PRSO ,SURFACEBIT>>
+ <TO-A-PRSO?>)
+ (<NOT <EQUAL? <GETP ,PRSO ,P?CAPACITY> 0>>
+ <COND (<NOT <FSET? ,PRSO ,OPENBIT>>
+ <FSET ,PRSO ,OPENBIT>
+ <FSET ,PRSO ,TOUCHBIT>
+ <COND (<OR <NOT <FIRST? ,PRSO>>
+ <FSET? ,PRSO ,TRANSBIT>>
+ <TELL "Opened." CR>)
+ (<AND <SET F <FIRST? ,PRSO>>
+ <NOT <NEXT? .F>>
+ <SET STR <GETP .F ,P?FDESC>>>
+ <OKAY-THE-PRSO-IS-NOW "open">
+ <TELL .STR CR>)
+ (T
+ <TELL "Opening ">
+ <TELL THE ,PRSO " reveals ">
+ <WHAT-CONTENTS>)>)>)
+ (T ;"door"
+ <COND (<FSET? ,PRSO ,OPENBIT>
+ <ALREADY-OPEN>)
+ (<FSET? ,PRSO ,LOCKED>
+ <TELL "It's locked." CR>)
+ (T
+ <FSET ,PRSO ,OPENBIT>
+ <OKAY-THE-PRSO-IS-NOW "open">)>)>>
+
+;<ROUTINE V-PAY ()
+ <COND (<NOT ,PRSI>
+ <TELL "Pay with what?" CR>
+ <RTRUE>)
+ (T
+ <WITH-PRSI?>)>>
+
+<ROUTINE V-PICK ()
+ <YOU-CANT-X-THAT "pick">>
+
+;<ROUTINE V-PLAY ()
+ <TELL "How peculiar!" CR>>
+
+<ROUTINE V-PLUG ()
+ <V-TURN> ;"no effect">
+
+<ROUTINE V-POINT ()
+ <TELL "It may be dangerous to point." CR>>
+
+<ROUTINE V-POUR-FROM ()
+ <COND (<IN? ,PRSO ,PRSI>
+ <PERFORM ,V?POUR ,PRSO>
+ <RTRUE>)
+ (ELSE
+ <TELL "It's not in that!" CR>)>>
+
+<ROUTINE PRE-POUR ()
+ <COND (<EQUAL? ,PRSO ,PRSI>
+ <TELL-YUKS>)>>
+
+<ROUTINE V-POUR ()
+ <COND (<AND <FSET? ,PRSO ,CONTBIT>
+ <HELD? ,PRSO>>
+ <EMPTY-ALL ,PRSO ,PRSI>)
+ (ELSE
+ <YOU-CANT-X-THAT "pour">)>>
+
+<ROUTINE EMPTY-ALL (FROM TO "AUX" F N R (1ST? <>))
+ <MAP-CONTENTS (F N .FROM)
+ <COND (<FSET? .F ,TAKEBIT>
+ <SET 1ST? T>
+ <TELL D .F ": ">
+ <SET R
+ <COND (.TO
+ <PERFORM ,V?PUT .F .TO>)
+ (ELSE
+ <PERFORM ,V?DROP .F>)>>
+ <COND (<EQUAL? .R ,M-FATAL> <RTRUE>)>)>>
+ <COND (<NOT .1ST?> <TELL CTHE .FROM " is empty." CR>)>
+ <RTRUE>>
+
+;<ROUTINE V-PUMP ()
+ <TELL "It's not clear how." CR>>
+
+<ROUTINE V-PUSH ()
+ <HACK-HACK "Pushing">>
+
+<ROUTINE V-PUSH-TO ()
+ <YOU-CANT-X-THAT "push things to">>
+
+<ROUTINE PRE-PUT ("AUX" (L <LOC ,PRSO>))
+ <COND (<OR <IN? ,PRSO ,GLOBAL-OBJECTS>
+ <NOT <FSET? ,PRSO ,TAKEBIT>>>
+ <TELL "Nice try." CR>)
+ (<AND <VERB? PUT>
+ <FSET? ,PRSO ,WEAPONBIT>
+ <FSET? ,PRSI ,PERSON>>
+ <SWAP-VERB ,V?ATTACK>
+ <RTRUE>)
+ (<IN? ,PRSO ,PRSI>
+ <TAKE-OUT-FIRST ,PRSO ,PRSI>)
+ (<IN? ,PRSI ,PRSO>
+ <TAKE-OUT-FIRST ,PRSI ,PRSO>)
+ (<FSET? .L ,PERSON> <RFALSE>)
+ (<AND <FSET? .L ,CONTBIT>
+ <NOT <FSET? .L ,OPENBIT>>>
+ <TAKE-OUT-FIRST ,PRSO .L>)
+ (<PRSO? ,ELIXIR ,FLOOR-WAX ,NITROGEN>
+ <NEW-VERB ,V?POUR>
+ <RTRUE>)>>
+
+<ROUTINE TAKE-OUT-FIRST (OBJ CONT)
+ <TELL
+"You should take " THE .OBJ " ">
+ <COND (<EQUAL? .CONT ,HAND>
+ <TELL "off">)
+ (ELSE <TELL "out">)>
+ <TELL " " THE .CONT " first." CR>>
+
+<ROUTINE V-PUT ("AUX" W)
+ <COND (<AND <NOT <FSET? ,PRSI ,OPENBIT>>
+ <NOT <FSET? ,PRSI ,DOORBIT>>
+ <NOT <FSET? ,PRSI ,CONTBIT>>
+ <NOT <FSET? ,PRSI ,SURFACEBIT>>
+ <NOT <FSET? ,PRSI ,VEHBIT>>>
+ <YOU-CANT-X-THAT "do">
+ <RTRUE>)
+ (<EQUAL? ,PRSI ,POOL>
+ <PERFORM ,V?DROP ,PRSO>
+ <RTRUE>)
+ (<AND <NOT <FSET? ,PRSI ,OPENBIT>>
+ <NOT <FSET? ,PRSI ,SURFACEBIT>>>
+ <INSPECTION-REVEALS ,PRSI>)
+ (<PRSI? ,PRSO>
+ <TO-A-PRSO?>)
+ (<IN? ,PRSO ,PRSI>
+ <TELL "I think ">
+ <TELL THE ,PRSO " is already in ">
+ <THE-PRSI>)
+ (<AND <FSET? <SET W <LOC ,PRSI>> ,PERSON>
+ <NOT <EQUAL? .W ,WINNER>>>
+ <TELL
+"Don't you think you should ask " THE .W " first?" CR>)
+ (<OR <AND <PRSO? ,AXE ,BOLT-CUTTER ,CROWBAR>
+ <PRSI? ,MICROWAVE>>
+ <PRSO-TOO-BIG?>>
+ <TELL ,NO-ROOM CR>)
+ (<AND <NOT <HELD? ,PRSO>>
+ <NOT <EQUAL? <ITAKE> T>>>
+ <RTRUE>)
+ (T
+ <FCLEAR ,PRSO ,WEARBIT>
+ <MOVE ,PRSO ,PRSI>
+ <COND (<PRSI? ,FLASK>
+ <FCLEAR ,PRSO ,SLIMEBIT>)>
+ <FSET ,PRSO ,TOUCHBIT>
+ <TELL "Done." CR>)>>
+
+<ROUTINE PRSO-TOO-BIG? ()
+ <COND (<G? <- <+ <WEIGHT ,PRSI> <WEIGHT ,PRSO>>
+ <GETP ,PRSI ,P?SIZE>>
+ <GETP ,PRSI ,P?CAPACITY>>
+ <RTRUE>)
+ (ELSE <RFALSE>)>>
+
+<ROUTINE INSPECTION-REVEALS (OBJ)
+ <THIS-IS-IT .OBJ>
+ <TELL "Inspection reveals that " THE .OBJ " isn't open." CR>>
+
+<ROUTINE V-PUT-BEHIND ()
+ <TELL ,YOU-CANT "be sure what's lurking there." CR>>
+
+<ROUTINE V-PUT-ON ()
+ <COND (<PRSI? ,ME>
+ <PERFORM ,V?WEAR ,PRSO>
+ <RTRUE>)
+ (<PRSI? ,GROUND>
+ <PERFORM ,V?DROP ,PRSO>
+ <RTRUE>)
+ (<FSET? ,PRSI ,SURFACEBIT>
+ <V-PUT>)
+ (T
+ <NO-GOOD-SURFACE>)>>
+
+<ROUTINE NO-GOOD-SURFACE ()
+ <TELL "There's no good surface on ">
+ <THE-PRSI>>
+
+<ROUTINE V-PUT-UNDER ()
+ <YOU-CANT-X-THAT "put anything under">>
+
+<ROUTINE V-RAISE ()
+ <HACK-HACK "Lifting">>
+
+<ROUTINE V-REACH-IN ("AUX" OBJ)
+ <COND (<OR <NOT <FSET? ,PRSO ,CONTBIT>>
+ <FSET? ,PRSO ,PERSON>>
+ <TO-A-PRSO?>)
+ (<NOT <FSET? ,PRSO ,OPENBIT>>
+ <TELL "It's not open." CR>)
+ (<OR <NOT <SET OBJ <FIRST? ,PRSO>>>
+ <FSET? .OBJ ,INVISIBLE>
+ <NOT <FSET? .OBJ ,TAKEBIT>>>
+ <ITS-EMPTY>)
+ (T
+ <TELL
+S "You feel something " "in " THE ,PRSO "!" CR>
+ <RTRUE>)>>
+
+<ROUTINE PRE-READ ()
+ <COND (<NOT ,LIT>
+ <TELL ,YOU-CANT "read in the dark." CR>)
+ (<AND ,PRSI <NOT <FSET? ,PRSI ,TRANSBIT>>>
+ <HOW-DO-YOU> <A-PRSI?>)>>
+
+<ROUTINE HOW-DO-YOU ()
+ <TELL "How do you do that with ">>
+
+<ROUTINE V-READ ()
+ <COND (<AND <FSET? ,PRSO ,READBIT>
+ <GETP ,PRSO ,P?TEXT>>
+ <TELL <GETP ,PRSO ,P?TEXT> CR>)
+ (T
+ <TO-A-PRSO?>)>>
+
+<ROUTINE V-REPLY ()
+ <TELL "You are ignored." CR>
+ <END-QUOTE>>
+
+<ROUTINE PRE-SRUB ()
+ <SWAP-VERB ,V?RUB>
+ <RTRUE>>
+
+<ROUTINE V-SRUB ()
+ <RTRUE>>
+
+<ROUTINE V-RUB ("AUX" H)
+ <COND (<GETPT ,PRSO ,P?HEAT>
+ <TELL "It's " <HEAT ,PRSO> ,PERIOD>)
+ (<PRSO? ,AIR>
+ <TELL "It's ">
+ <COND (<FSET? ,HERE ,OUTSIDE>
+ <TELL "cold." CR>)
+ (ELSE
+ <TELL "warm." CR>)>)
+ (ELSE
+ <HACK-HACK "Fiddling with">)>>
+
+<ROUTINE V-SAY ("AUX" V)
+ <COND (<SET V <FIND-IN ,HERE ,PERSON>>
+ <TELL "You must address " THE .V " directly." CR>
+ <END-QUOTE>)
+ (<EQUAL? <GET ,P-LEXV ,P-CONT> ,W?HELLO>
+ <SETG QUOTE-FLAG <>>
+ <RTRUE>)
+ (T
+ <PERFORM ,V?TELL ,ME>
+ <END-QUOTE>)>>
+
+<ROUTINE V-SEARCH ()
+ <COND (<FSET? ,PRSO ,PERSON>
+ <TELL
+CTHE ,PRSO " refuses." CR>)
+ (ELSE
+ <TELL ,THERE-IS-NOTHING "there" ,PERIOD>)>>
+
+;<ROUTINE V-SEND ()
+ <COND (<FSET? ,PRSO ,PERSON>
+ <TELL "Why would you send for ">
+ <A-PRSO?>)
+ (T
+ <TELL-YUKS>)>>
+
+<ROUTINE PRE-SGIVE ()
+ <SWAP-VERB ,V?GIVE>
+ <RTRUE>>
+
+<ROUTINE V-SGIVE ()
+ <RTRUE>>
+
+<ROUTINE V-SHAKE ("AUX" X)
+ <COND (<FSET? ,PRSO ,PERSON>
+ <TELL "Be real." CR>)
+ ;(<NOT <FSET? ,PRSO ,TAKEBIT>>
+ <TELL ,YOU-CANT "take it; thus, you can't shake it!" CR>)
+ (T
+ <TELL "There's no point in shaking that." CR>)>>
+
+<ROUTINE V-SHARPEN ()
+ <TELL "You'll never sharpen anything with that!" CR>>
+
+<ROUTINE V-SHOOT ()
+ <TELL
+"This explains why you aren't in ROTC." CR>>
+
+<ROUTINE V-SHOW ()
+ <COND (<FSET? ,PRSI ,PERSON>
+ <UNINTERESTED ,PRSI>)
+ (ELSE <TELL-YUKS>)>>
+
+<ROUTINE V-SIT ()
+ <COND (<AND <P? SIT ROOMS>
+ <IN? ,CHAIR ,HERE>>
+ <NEW-PRSO ,CHAIR>
+ <RTRUE>)
+ (ELSE
+ <TELL ,WASTE-OF-TIME>)>>
+
+<ROUTINE V-SKIP ()
+ <TELL "Not as fun as skipping class." CR>>
+
+<ROUTINE V-SLEEP ("OPTIONAL" (FORCE? <>))
+ <COND (<AND <NOT .FORCE?> <EQUAL? ,AWAKE -1>>
+ <TELL
+"You try to sleep, but you can't relax." CR>)
+ (<QUEUED? I-FREEZE-TO-DEATH>
+ <TELL
+"You would freeze to death before you woke." CR>)
+ (T
+ <TELL
+"You've been up for a long time, and it was turning into an
+all-nighter. You can use the rest. You
+stretch out as best you can. You toss and turn fitfully,
+sleeping only in snatches." CR CR "You dream of " <RANDOM-ELEMENT ,DREAMS>
+ CR CR>
+ <JIGS-UP
+"Your dream ends, and another begins. Something clawed and fanged grabs
+you, and you try to wake, but you already are!">
+ <RFATAL>)>>
+
+<GLOBAL DREAMS
+ <LTABLE (PURE)
+"being late for class. First you can't find the classroom,
+and when you finally find it you realize they're giving an exam."
+
+"standing on the roof of the Brown Building, looking down at the ground.
+You lose your balance..."
+
+"a dark curtain, blown gently in a breeze you don't feel. You try to
+rip it aside, but you can't, because you know what's behind it."
+
+"being pursued. You trip, slip, fall, and can't
+make headway. It's not coming very fast, but you can't get away.">>
+
+<ROUTINE LIKE-A-PRSO (V)
+ <TELL "It " .V " just like " A ,PRSO "." CR>>
+
+<ROUTINE V-SMELL ()
+ <COND (,PRSO
+ <LIKE-A-PRSO "smells">)
+ (<FSET? <LOC ,WINNER> ,VEHBIT>
+ <PERFORM-PRSA <LOC ,WINNER>>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"There's no noticeable smell here." CR>)>>
+
+;<ROUTINE V-SPAY ()
+ <SWAP-VERB ,V?PAY>
+ <RTRUE>>
+
+;<ROUTINE V-SPIN ()
+ <YOU-CANT-X-THAT "spin">>
+
+<ROUTINE PRE-SSHOW ()
+ <SWAP-VERB ,V?SHOW>
+ <RTRUE>>
+
+<ROUTINE V-SSHOW ()
+ <RTRUE>>
+
+<ROUTINE V-STAND ()
+ <COND (<PRSO? <> ,ROOMS>
+ <COND (<FSET? <LOC ,WINNER> ,VEHBIT>
+ <PERFORM ,V?DISEMBARK <LOC ,WINNER>>
+ <RTRUE>)
+ (T
+ <TELL ,YOU-ARE " standing." CR>)>)
+ (ELSE
+ <HACK-HACK "Holding up">)>>
+
+;<ROUTINE V-STAND-ON ()
+ <TELL ,WASTE-OF-TIME>>
+
+<ROUTINE V-SWING ()
+ <COND (<NOT ,PRSI>
+ <TELL "Whoosh!" CR>)
+ (T
+ <SWAP-VERB ,V?ATTACK>
+ <RTRUE>)>>
+
+<ROUTINE V-SWIM ()
+ <TELL-YUKS>>
+
+<ROUTINE PRE-TAKE ()
+ <COND (<IN? ,PRSO ,WINNER>
+ <TELL ,YOU-HAVE "it." CR>)
+ (<AND <NOT <FSET? <LOC ,WINNER> ,VEHBIT>>
+ <FSET? <LOC ,PRSO> ,CONTBIT>
+ <NOT <FSET? <LOC ,PRSO> ,OPENBIT>>
+ <NOT <PRSO? ,REPEATER-COVER ,PADLOCK>>>
+ <CANT-REACH-THAT>
+ <RTRUE>)
+ (,PRSI
+ <COND (<PRSI? ,WALL-SOCKET ,ROD ,HOOK> <RFALSE>)
+ (<PRSO? ,ME>
+ <PERFORM ,V?DROP ,PRSI>
+ <RTRUE>)
+ (<AND <NOT <PRSI? <LOC ,PRSO>>>
+ <OR <AND <PRSI? ,HOOK>
+ <NOT <EQUAL? ,PRSO ,CHAIN-HOOKED?>>>
+ <AND <PRSI? ,ROD>
+ <NOT <EQUAL? ,PRSO ,CHAIN-LOOPED?>>>>>
+ <TELL "But ">
+ <TELL THE ,PRSO " isn't in ">
+ <THE-PRSI>)
+ (T
+ <SETG PRSI <>>
+ <RFALSE>)>)
+ (<PRSO? <LOC ,WINNER>>
+ <TELL "You are ">
+ <COND (<FSET? ,PRSO ,PERSON> <TELL "being carried by">)
+ (<FSET? ,PRSO ,SURFACEBIT> <TELL "on">)
+ (ELSE <TELL "in">)>
+ <TELL " it!" CR>)>>
+
+"return true if prso or prsi is inaccessible from vehicle and verb requires
+access to it. e.g.,
+ >EXAMINE obj-outside-vehicle => rfalse
+ >TAKE obj-outside-vehicle => rtrue"
+
+<ROUTINE NOT-REACHABLE? ()
+ <COND (<PASSIVE-VERB?> <RFALSE>)>
+ <COND (<NOT-IN-VEHICLE? ,PRSO> <RETURN ,PRSO>)
+ (<NOT-IN-VEHICLE? ,PRSI> <RETURN ,PRSI>)>>
+
+<ROUTINE CANT-REACH-FROM-VEHICLE (O)
+ <TELL
+,YOU-CANT "reach " THE .O " from within " THE <LOC ,WINNER> "." CR>>
+
+<ROUTINE NOT-IN-VEHICLE? (PP "AUX" (V <LOC ,WINNER>))
+ <COND (<OR <NOT .PP>
+ <EQUAL? .PP .V ,ROOMS>
+ <INTRINSIC? .PP>
+ <HELD? .PP>
+ <EQUAL? <META-LOC .PP> .V>>
+ <RFALSE>)
+ (ELSE <RTRUE>)>>
+
+<ROUTINE V-TAKE ()
+ <COND (<EQUAL? <ITAKE> T>
+ <TELL ,TAKEN>)>>
+
+<ROUTINE V-TAKE-OFF ()
+ <COND (<FSET? ,PRSO ,VEHBIT>
+ <NEW-VERB ,V?DISEMBARK>
+ <RTRUE>)
+ (<FSET? ,PRSO ,WEARBIT>
+ <FCLEAR ,PRSO ,WEARBIT>
+ <TELL
+"You're no longer wearing " THE ,PRSO ,PERIOD>)
+ (ELSE
+ <NEW-VERB ,V?TAKE>
+ <RTRUE>)>>
+
+<ROUTINE V-TELL ()
+ <COND (<FSET? ,PRSO ,PERSON>
+ <COND (,P-CONT
+ <SETG WINNER ,PRSO>
+ ;<COND (<IN? <LOC ,WINNER> ,ROOMS>
+ <SETG HERE <LOC ,WINNER>>)>)
+ (T
+ <TELL
+"Hmmm ... " THE ,PRSO " waits for you to say something." CR>)>
+ <RTRUE>)
+ (T
+ <YOU-CANT-X-PRSO "talk to">
+ <END-QUOTE>)>>
+
+<ROUTINE V-THANK ()
+ <COND (<NOT ,PRSO>
+ <TELL "You're welcome, I guess." CR>)
+ (<FSET? ,PRSO ,PERSON>
+ <UNINTERESTED ,PRSO>)
+ (T
+ <TO-A-PRSO?>)>>
+
+<ROUTINE V-THROUGH ("AUX" M)
+ <COND (<PRSO? ,ROOMS>
+ <DO-WALK ,P?IN>)
+ (<PRSO? ,INTNAME>
+ <NEW-VERB ,V?TYPE>
+ <RTRUE>)
+ (<FSET? ,PRSO ,VEHBIT>
+ <NEW-VERB ,V?BOARD>
+ <RTRUE>)
+ (<AND <FSET? ,PRSO ,DOORBIT>
+ <FSET? ,PRSO ,OPENBIT>>
+ <DO-WALK ,P?IN>)
+ (<NOT <FSET? ,PRSO ,TAKEBIT>>
+ <TELL
+"You hit your head against " THE ,PRSO " as you attempt this feat." CR>)
+ (<IN? ,PRSO ,WINNER>
+ <TELL "That would involve quite a contortion!" CR>)
+ (T
+ <TELL-YUKS>)>>
+
+<ROUTINE V-THROW ()
+ <COND (<AND ,PRSI
+ <FSET? ,PRSI ,PERSON>>
+ <COND (<IN? ,PRSO ,WINNER>
+ <COND (<IDROP>
+ <NOT-TRAINED>)>)
+ (ELSE
+ <SWAP-VERB ,V?ATTACK>
+ <RTRUE>)>)
+ (<AND ,PRSI
+ <NOT <PRSI? PSEUDO-OBJECT>>
+ <FSET? ,PRSO ,WEAPONBIT>>
+ <SWAP-VERB ,V?ATTACK>
+ <RTRUE>)
+ (<AND ,PRSI
+ <NOT <FSET? ,PRSI ,DOORBIT>>
+ <FSET? ,PRSI ,CONTBIT>
+ <GETP ,PRSI ,P?CAPACITY>>
+ <NEW-VERB ,V?PUT>
+ <RTRUE>)
+ (<IDROP>
+ <TELL "Thrown." CR>)>>
+
+<ROUTINE V-THROW-OFF ()
+ <YOU-CANT-X-THAT "throw anything off">>
+
+<ROUTINE V-TIE ()
+ <TO-A-PRSO?>>
+
+<ROUTINE V-TIE-UP ()
+ <TO-A-PRSO?>>
+
+<ROUTINE V-TIME ("AUX" X)
+ <TELL "It seems like three o'clock in the morning." CR>>
+
+<ROUTINE V-TORTURE ()
+ <TELL "An appalling idea!" CR>>
+
+<ROUTINE V-TURN () ;"used by others"
+ <TELL "This has no effect." CR>>
+
+<ROUTINE V-TURN-OVER ()
+ <TELL "Moving " THE ,PRSO " reveals nothing." CR>>
+
+<ROUTINE V-TURN-AROUND ()
+ <COND (<PRSO? ,ROOMS>
+ <PERFORM ,V?LOOK-BEHIND ,ME>
+ <RTRUE>)
+ (<FSET? ,PRSO ,PERSON>
+ <TELL
+"I wouldn't do that, " THE ,PRSO " might get dizzy." CR>)
+ (<NOT <FSET? ,PRSO ,TAKEBIT>>
+ <TELL
+,YOU-CANT "turn " THE ,PRSO " around." CR>)
+ (ELSE
+ <TELL
+"Turning " THE ,PRSO " around gives you a new perspective on it, but
+reveals no new information." CR>)>>
+
+<ROUTINE V-UNLOCK ()
+ <COND (<AND <FSET? ,PRSO ,DOORBIT>
+ <PRSI? ,MASTER-KEY>>
+ <TELL
+"The key fits perfectly in the lock, but the lock doesn't turn.
+The master key doesn't work on this lock." CR>)
+ (ELSE
+ <V-LOCK>)>>
+
+<ROUTINE V-UNTIE ()
+ <TO-A-PRSO?>>
+
+<ROUTINE V-WALK ("AUX" PT PTS STR OBJ RM)
+ <COND (<NOT ,P-WALK-DIR>
+ <NEW-VERB ,V?WALK-TO>
+ <RTRUE>)
+ (<SET PT <GETPT ,HERE ,PRSO>>
+ <SET PTS <PTSIZE .PT>>
+ <COND (<EQUAL? .PTS ,NEXIT>
+ <TELL <GET .PT ,NEXITSTR> CR>
+ <RFATAL>)
+ (<EQUAL? .PTS ,UEXIT>
+ <SET RM <GETB .PT ,REXIT>>)
+ (<EQUAL? .PTS ,FEXIT>
+ <COND (<NOT <SET RM <APPLY <GET .PT ,FEXITFCN>>>>
+ <RFATAL>)>)
+ (<EQUAL? .PTS ,CEXIT>
+ <COND (<VALUE <GETB .PT ,CEXITFLAG>>
+ <SET RM <GETB .PT ,REXIT>>)
+ (<SET STR <GET .PT ,CEXITSTR>>
+ <TELL .STR CR>
+ <RFATAL>)
+ (T
+ <CANT-GO>
+ <RFATAL>)>)
+ (<EQUAL? .PTS ,DEXIT>
+ <SET OBJ <GETB .PT ,DEXITOBJ>>
+ <COND (<FSET? .OBJ ,OPENBIT>
+ <SET RM <GETB .PT ,REXIT>>)
+ (<SET STR <GET .PT ,DEXITSTR>>
+ <TELL .STR CR>
+ <THIS-IS-IT .OBJ>
+ <RFATAL>)
+ (T
+ <TELL-OPEN-CLOSED .OBJ>
+ <THIS-IS-IT .OBJ>
+ <RFATAL>)>)>
+ <COND (<IN? ,FLOOR-WAX ,HERE>
+ <TELL
+"You slip and slide on the wax. It's like walking on wet ice. You can
+barely keep upright, but ">
+ <COND (<AND ,CORD-SEVERED?
+ <IN? ,MAINTENANCE-MAN ,HERE>
+ <FSET? ,MAINTENANCE-MAN ,PERSON>>
+ <TELL
+"it's worse for the maintenance man. His gait
+is so jerky that each time he takes a step he
+falls! His persistence is impressive, but you slip (literally)
+by before he can grab you.">)
+ (ELSE
+ <TELL
+"you manage to lose your balance in just the
+right way to keep going.">)>
+ <TELL CR CR>)
+ (,ON-CABLE?
+ <COND (<NOT <PRSO? ,P?DOWN>>
+ <TELL
+"You go hand-over-hand along the cable.">
+ <COND (<NOT <GLOBAL-IN? ,CABLE .RM>>
+ <SETG ON-CABLE? <>>
+ <TELL
+" You reach the end, drop, and continue on.">)>
+ <COND (,RATS-HERE
+ <MOVE ,RATS ,HERE>
+ <TELL " The rats follow, red eyes
+staring upward. Some of the bolder ones leap at your feet, and one hits
+with a thump.">)>
+ <TELL CR CR>)>)>
+ <GOTO .RM>)
+ (T
+ <CANT-GO>
+ <RFATAL>)>>
+
+<ROUTINE V-WALK-AROUND ()
+ <TELL "Please use compass directions instead." CR>>
+
+<ROUTINE V-WALK-TO ()
+ <COND (<AND ,PRSO
+ <OR <IN? ,PRSO ,HERE>
+ <GLOBAL-IN? ,PRSO ,HERE>>>
+ <TELL "It's here!" CR>)
+ (T
+ <V-WALK-AROUND>)>>
+
+<ROUTINE V-WAIT ("AUX" (NUM 3))
+ <COND (<PRSO? ,INTNUM>
+ <COND (<G? ,P-NUMBER 100>
+ <TELL "Too long!" CR>)
+ (T
+ <SET NUM ,P-NUMBER>)>)>
+ <TELL "Time passes..." CR>
+ <REPEAT ()
+ <COND (<L? <SET NUM <- .NUM 1>> 0>
+ <RETURN>)
+ (<CLOCKER>
+ <RETURN>)>>
+ <SETG CLOCK-WAIT T>>
+
+<ROUTINE V-WAIT-FOR ()
+ <COND (<PRSO? INTNUM>
+ <NEW-VERB ,V?WAIT>
+ <RTRUE>)
+ (<EQUAL? <LOC ,PRSO> ,HERE ,WINNER>
+ <TELL "It's already here!" CR>)
+ (T
+ <TELL "You may well wait quite a while." CR>)>>
+
+<ROUTINE V-WAVE ()
+ <HACK-HACK "Waving">>
+
+<ROUTINE V-WAVE-AT ()
+ <TELL
+CTHE ,PRSO>
+ <IS-ARE ,PRSO>
+ <TELL "n't likely to respond." CR>>
+
+<ROUTINE V-WEAR ()
+ <COND (<FSET? ,PRSO ,WEARBIT>
+ <TELL ,YOU-ARE ,PERIOD>)
+ (ELSE
+ <YOU-CANT-X-PRSO "wear">)>>
+
+<ROUTINE V-WHAT ()
+ <TELL "An excellent question." CR>>
+
+<ROUTINE V-WHERE ()
+ <COND (<NOT ,PRSO>
+ <COND (,P-IT-OBJECT
+ <NEW-PRSO ,P-IT-OBJECT>
+ <RTRUE>)
+ (ELSE
+ <TELL "Why?" CR>)>)
+ (ELSE
+ <V-FIND T>)>>
+
+<ROUTINE V-WHO ()
+ <COND (<NOT ,PRSO> <V-WHAT>)
+ (<FSET? ,PRSO ,PERSON>
+ <NEW-VERB ,V?WHAT>
+ <RTRUE>)
+ (T
+ <TELL "That's not a person!" CR>)>>
+
+<ROUTINE V-YAWN ()
+ <V-LEAN-ON>>
+
+<ROUTINE V-YELL ()
+ <TELL "The scream echoes back to you, subtly changed." CR>>
+
+;"subtitle object manipulation"
+
+<CONSTANT FUMBLE-MAX 9>
+
+<GLOBAL FUMBLE-NUMBER 9>
+
+<ROUTINE ITAKE ("OPTIONAL" (VB T) "AUX" CNT OBJ)
+ <COND (<NOT <FSET? ,PRSO ,TAKEBIT>>
+ <COND (.VB
+ <TELL-YUKS>)>
+ <RFALSE>)
+ (<IN? ,PRSO ,WINNER>
+ <TELL ,YOU-HAVE "it" ,PERIOD>
+ <RFALSE>)
+ (<AND <PRSO? ,CHAIN-1 ,CHAIN-2>
+ <HELD? ,CHAIN>>
+ <REMOVE ,PRSO>
+ <RTRUE>)
+ (<AND <NOT <IN? <LOC ,PRSO> ,WINNER>>
+ <G? <+ <WEIGHT ,PRSO> <WEIGHT ,WINNER>> ,LOAD-ALLOWED>>
+ <COND (.VB
+ <COND (<FIRST? ,PLAYER>
+ <TELL "Your load is too heavy">)
+ (T
+ <TELL "It's a little too heavy">)>
+ <COND (<L? ,LOAD-ALLOWED ,LOAD-MAX>
+ <TELL
+", especially in light of your exhaustion.">)
+ (T
+ <TELL ".">)>
+ <CRLF>)>
+ <RFATAL>)
+ (<G? <SET CNT <CCOUNT ,WINNER>> ,FUMBLE-NUMBER>
+ <COND (.VB
+ <TELL
+"You're holding too many things and can't quite get them all arranged
+to take it as well." CR>)>
+ <RFATAL>)
+ (T
+ <COND (<FSET? ,PRSO ,SLIMEBIT>
+ <QUEUE I-SLIME-OBJECT 1>)>
+ <SCORE-OBJECT>
+ <MOVE ,PRSO ,WINNER>
+ <FCLEAR ,PRSO ,WEARBIT>
+ <FCLEAR ,PRSO ,NDESCBIT>
+ <RTRUE>)>>
+
+<ROUTINE SCORE-OBJECT ("OPTIONAL" (OBJ <>))
+ <COND (<NOT .OBJ>
+ <SET OBJ ,PRSO>
+ <COND (<FSET? .OBJ ,TOUCHBIT> <RTRUE>)>)>
+ <COND (<GETPT .OBJ ,P?VALUE>
+ <SETG SCORE <+ ,SCORE <GETP .OBJ ,P?VALUE>>>
+ <PUTP .OBJ ,P?VALUE 0>)>
+ <FSET .OBJ ,TOUCHBIT>>
+
+<ROUTINE IDROP ()
+ <COND (<NOT <HELD? ,PRSO>>
+ <TELL ,YOU-ARENT "carrying ">
+ <THE-PRSO>
+ <RFALSE>)
+ (<AND <NOT <IN? ,PRSO ,WINNER>>
+ <NOT <FSET? <LOC ,PRSO> ,OPENBIT>>>
+ <THIS-IS-IT ,PRSO>
+ <TELL-OPEN-CLOSED <LOC ,PRSO>>
+ <RFALSE>)
+ (T
+ <FCLEAR ,PRSO ,WEARBIT>
+ <MOVE ,PRSO <LOC ,WINNER>>
+ <RTRUE>)>>
+
+<ROUTINE CCOUNT (OBJ "AUX" (CNT 0) X)
+ <MAP-CONTENTS (X .OBJ)
+ (END <RETURN .CNT>)
+ <COND (<AND <EQUAL? .X ,HAND>
+ <FSET? ,HAND ,PERSON>>)
+ (<FSET? .X ,WEARBIT>)
+ (ELSE
+ <SET CNT <+ .CNT 1>>)>>>
+
+;"WEIGHT: Gets sum of SIZEs of supplied object, recursing to nth level."
+
+<ROUTINE WEIGHT (OBJ "AUX" CONT (WT 0))
+ <COND (<AND <EQUAL? .OBJ ,HAND>
+ <FSET? ,HAND ,PERSON>>
+ T)
+ (<NOT <FSET? .OBJ ,WEARBIT>>
+ <MAP-CONTENTS (CONT .OBJ)
+ <SET WT <+ .WT <WEIGHT .CONT>>>>
+ <+ .WT <GETP .OBJ ,P?SIZE>>)>>
+
+^\L
+
+;"subtitle movement"
+
+<CONSTANT REXIT 0>
+<CONSTANT UEXIT 1>
+<CONSTANT NEXIT 2>
+<CONSTANT FEXIT 3>
+<CONSTANT CEXIT 4>
+<CONSTANT DEXIT 5>
+
+<CONSTANT NEXITSTR 0>
+<CONSTANT FEXITFCN 0>
+<CONSTANT CEXITFLAG 1>
+<CONSTANT CEXITSTR 1>
+<CONSTANT DEXITOBJ 1>
+<CONSTANT DEXITSTR 1>
+
+;<ROUTINE LKP (ITM TBL "AUX" (CNT 0) (LEN <GET .TBL 0>))
+ <REPEAT ()
+ <COND (<G? <SET CNT <+ .CNT 1>> .LEN>
+ <RFALSE>)
+ (<EQUAL? <GET .TBL .CNT> .ITM>
+ <COND (<EQUAL? .CNT .LEN> <RFALSE>)
+ (T
+ <RETURN <GET .TBL <+ .CNT 1>>>)>)>>>
+
+<GLOBAL OHERE <>>
+
+<ROUTINE GOTO (RM "OPTIONAL" (V? T) "AUX" OLIT)
+ <SETG OHERE .RM>
+ %<DEBUG-CODE <D-APPLY "Leave" <GETP ,HERE ,P?ACTION> ,M-LEAVE>
+ <APPLY <GETP ,HERE ,P?ACTION> ,M-LEAVE>>
+ <SETG OHERE ,HERE>
+ <SET OLIT ,LIT>
+ <COND (<NOT <IN? <LOC ,WINNER> ,ROOMS>>
+ <MOVE <LOC ,WINNER> .RM>)
+ (ELSE
+ <MOVE ,WINNER .RM>)>
+ <SETG HERE .RM>
+ <SETG LIT <LIT? ,HERE>>
+ <COND (<AND <NOT .OLIT>
+ <NOT ,LIT>
+ <PROB 80>>
+ <JIGS-UP ;"this string is a duplicate of one in FLASHLIGHT-F"
+"One should never assume the dark is safe.
+Something just grabbed you from behind and dragged you
+off to its lair.">
+ <RTRUE>)>
+ %<DEBUG-CODE <D-APPLY "Enter" <GETP ,HERE ,P?ACTION> ,M-ENTER>
+ <APPLY <GETP ,HERE ,P?ACTION> ,M-ENTER>>
+ <COND (<NOT <EQUAL? ,HERE .RM>>
+ <RTRUE>)
+ (.V?
+ <V-FIRST-LOOK>)>
+ <COND (,LIT <SCORE-OBJECT .RM>)>
+ <RTRUE>>
+
+\
+
+;"subtitle death and stuff"
+
+<ROUTINE JIGS-UP ("OPTIONAL" (DESC <>) (FROB? <>))
+ <SETG WINNER ,PLAYER>
+ <COND (.DESC <TELL .DESC>)>
+ <TELL "|
+| **** You have ">
+ <COND (.FROB? <TELL "changed">)
+ (ELSE <TELL "died">)>
+ <TELL " ****|
+|">
+ <COND (.FROB?
+ <TELL
+"Sometimes, during your future existence, you remember your old life.
+At these times, you wish you had died instead." CR>)
+ (ELSE
+ <TELL
+"At first, you think \"Maybe it was all just a bad dream,\" but no such
+luck. It appears to be for real. That's too bad, although
+something gnawing on your " <RANDOM-ELEMENT ,PARTS> " thinks it's pretty
+wonderful, or at least fairly tasty." CR>)>
+ <FINISH>>
+
+<GLOBAL PARTS <LTABLE (PURE) "fingertips" "toes" "nose" "ears" "tongue">>
+
+<ROUTINE ROB (FROM TO "OPTIONAL" (IGNORE <>)
+ "AUX" (F <FIRST? .FROM>) N (1ST? <>))
+ <REPEAT ()
+ <COND (.F
+ <SET N <NEXT? .F>>
+ <COND (<AND <EQUAL? .TO ,URCHIN>
+ <EQUAL? .F ,VAT ,HAND ,CHAIN ,FLOOR-WAX
+ ,DOME-LADDER ,MANHOLE-COVER
+ ,PLASTIC-CONTAINER ,CHAIR ,PC
+ ,LOVECRAFT>>
+ T)
+ (<AND <FSET? .F ,TAKEBIT>
+ <FSET? .F ,TOUCHBIT>
+ <NOT <EQUAL? .F .IGNORE>>>
+ <SET 1ST? T>
+ <COND (.TO <MOVE .F .TO>)
+ (ELSE <REMOVE .F>)>)>
+ <SET F .N>)
+ (T
+ <RETURN>)>>
+ .1ST?>
+
+^\L
+
+;"subtitle useful utility routines"
+
+<ROUTINE THIS-IS-IT (OBJ)
+ <COND (<NOT <EQUAL? .OBJ ,IT ,HIM>>
+ <COND (<EQUAL? .OBJ ,HACKER ,MAINTENANCE-MAN ,PROFESSOR
+ ,URCHIN>
+ <COND (<NOT ,WAS-HIM?>
+ <SETG P-HIM-OBJECT .OBJ>)>)
+ (<NOT ,WAS-IT?>
+ <SETG P-IT-OBJECT .OBJ>)>)>>
+
+<ROUTINE INTRINSIC? (OBJ)
+ <EQUAL? .OBJ ,ME ,HANDS ,HEAD ,EYES ,FEET>>
+
+<ROUTINE ACCESSIBLE? (OBJ "AUX" (L <LOC .OBJ>)) ;"can player TOUCH object?"
+ ;"revised 5/2/84 by SEM and SWG"
+ <COND (<FSET? .OBJ ,INVISIBLE>
+ <RFALSE>)
+ (<EQUAL? .OBJ ,PSEUDO-OBJECT>
+ <COND (<EQUAL? ,LAST-PSEUDO-LOC ,HERE>
+ <RTRUE>)
+ (T
+ <RFALSE>)>)
+ (<NOT .L>
+ <RFALSE>)
+ (<EQUAL? .L ,GLOBAL-OBJECTS>
+ <RTRUE>)
+ (<AND <EQUAL? .L ,LOCAL-GLOBALS>
+ <GLOBAL-IN? .OBJ ,HERE>>
+ <RTRUE>)
+ (<NOT <EQUAL? <META-LOC .OBJ> ,HERE <LOC ,WINNER>>>
+ <RFALSE>)
+ (<EQUAL? .L ,WINNER ,HERE <LOC ,WINNER>>
+ <RTRUE>)
+ (<AND <FSET? .L ,OPENBIT>
+ <ACCESSIBLE? .L>>
+ <RTRUE>)
+ (T
+ <RFALSE>)>>
+
+<ROUTINE VISIBLE? (OBJ "AUX" (L <LOC .OBJ>)) ;"can player SEE object"
+ ;"revised 5/2/84 by SEM and SWG"
+ <COND (<ACCESSIBLE? .OBJ>
+ <RTRUE>)
+ (<AND <SEE-INSIDE? .L>
+ <VISIBLE? .L>>
+ <RTRUE>)(T
+ <RFALSE>)>>
+
+<ROUTINE META-LOC (OBJ)
+ <REPEAT ()
+ <COND (<NOT .OBJ>
+ <RFALSE>)
+ (<IN? .OBJ ,GLOBAL-OBJECTS>
+ <RETURN ,GLOBAL-OBJECTS>)>
+ <COND (<IN? .OBJ ,ROOMS>
+ <RETURN .OBJ>)
+ (T
+ <SET OBJ <LOC .OBJ>>)>>>
+
+<ROUTINE HELD? (OBJ "OPTIONAL" (WHO <>))
+ ;"is object carried, or in something carried, by player?"
+ <COND (<NOT .WHO> <SET WHO ,PLAYER>)>
+ <COND (<NOT .OBJ>
+ <RFALSE>)
+ (<IN? .OBJ .WHO>
+ <RTRUE>)
+ (<IN? .OBJ ,ROOMS>
+ <RFALSE>)
+ (<IN? .OBJ ,GLOBAL-OBJECTS>
+ <RFALSE>)
+ (T
+ <HELD? <LOC .OBJ> .WHO>)>>
+
+<ROUTINE SEE-INSIDE? (OBJ)
+ <AND .OBJ
+ <NOT <FSET? .OBJ ,INVISIBLE>>
+ <OR <FSET? .OBJ ,TRANSBIT>
+ <FSET? .OBJ ,OPENBIT>>>>
+
+<ROUTINE GLOBAL-IN? (OBJ1 OBJ2 "AUX" TEE)
+ <COND (<AND .OBJ2
+ <SET TEE <GETPT .OBJ2 ,P?GLOBAL>>>
+ <ZMEMQB .OBJ1 .TEE <- <PTSIZE .TEE> 1>>)>>
+
+<ROUTINE DO-WALK (DIR)
+ <SETG P-WALK-DIR .DIR>
+ <PERFORM ,V?WALK .DIR>>
+
+;<ROUTINE SOAK-STUFF (OBJ "OPTIONAL" (RECURSE? T)
+ "AUX" (F <FIRST? .OBJ>) (1ST? T))
+ <REPEAT ()
+ <COND (<NOT .F> <RETURN <NOT .1ST?>>)
+ (<SOAK-OBJ? .F>
+ <SET 1ST? <>>)
+ (<AND <NOT .RECURSE?>
+ <EQUAL? .F ,PLAYER>>
+ T)
+ (<AND <FSET? .F ,CONTBIT>
+ <FSET? .F ,OPENBIT>
+ <FIRST? .F>>
+ <COND (<SOAK-STUFF .F>
+ <SET 1ST? <>>)>)>
+ <SET F <NEXT? .F>>>>
+
+;<ROUTINE SOAK-OBJ? (F)
+ <COND (<FSET? .F ,RMUNGBIT> <RFALSE>)>>
+
+<ROUTINE HACK-HACK (STR)
+ <TELL .STR " " THE ,PRSO " has no effect." CR>>
+
+<ROUTINE TELL-YUKS ()
+ <TELL <PICK-ONE ,YUKS> CR>>
+
+<CONSTANT YUKS
+ <LTABLE 0
+ "Not likely!"
+ "That would never work!"
+ "You can't be serious."
+ "You won't get a passing grade for that idea!">>
+
+<ROUTINE PRE-PRY ()
+ <COND (<AND ,PRSI
+ <NOT <INTRINSIC? ,PRSI>>
+ <NOT <HELD? ,PRSI>>
+ <NOT <IN? ,WINNER ,PRSI>>
+ <NOT <FSET? ,PRSI ,VEHBIT>>>
+ <NOT-HOLDING ,PRSI>)>>
+
+<ROUTINE V-PRY ()
+ <V-TURN>>
+
+<ROUTINE V-BURY ()
+ <TELL
+"You can never tell what will happen to something you bury." CR>>
+
+<ROUTINE V-YES ()
+ <TELL "That was a rhetorical question." CR>>
+
+<ROUTINE V-NO ()
+ <V-YES>>
+
+<ROUTINE V-BUY ()
+ <UNINTERESTED ,PRSI>>
+
+<ROUTINE PRE-SSELL ()
+ <SWAP-VERB ,V?SELL>
+ <RTRUE>>
+
+<ROUTINE V-SSELL () <RTRUE>>
+
+<ROUTINE V-SELL ()
+ <UNINTERESTED ,PRSI>>
+
+<ROUTINE PRE-TELL-ABOUT ()
+ <COND (<PRSO? ,ME>
+ <PERFORM ,V?TELL-ME-ABOUT ,PRSI>
+ <RTRUE>)>>
+
+<ROUTINE V-TELL-ABOUT ()
+ <COND (<HELD? ,PRSI>
+ <SWAP-VERB ,V?SHOW>
+ <RTRUE>)
+ (<ACCESSIBLE? ,PRSI>
+ <NEW-VERB ,V?ASK-ABOUT>
+ <RTRUE>)
+ (ELSE
+ <UNINTERESTED ,PRSO>)>>
+
+<ROUTINE V-TELL-ME-ABOUT ()
+ <COND (<WINNER? ,PLAYER>
+ <MENTAL-COLLAPSE>)
+ (ELSE
+ <UNINTERESTED ,WINNER>)>>
+
+<ROUTINE V-TRADE ()
+ <COND (<AND ,PRSI <FSET? ,PRSI ,PERSON>>
+ <UNINTERESTED ,PRSI>)
+ (<AND <WINNER? ,PLAYER>
+ ,PRSI
+ <NOT <FSET? ,PRSO ,PERSON>>>
+ <COND (<IN? ,HACKER ,HERE>
+ <SETG WINNER ,HACKER>
+ <NEW-VERB ,PRSA>
+ <SETG WINNER ,PLAYER>
+ <RTRUE>)
+ (ELSE
+ <TELL
+"No one here is interested in trading." CR>)>)
+ (ELSE
+ <V-BARGAIN>)>>
+
+<ROUTINE V-ERASE ()
+ <TELL-YUKS>>
+
+<ROUTINE V-ADMIRE ()
+ <TELL "Your taste is unusual." CR>>
+
+<ROUTINE V-BARGAIN ()
+ <TELL "What are you, an M.B.A. student?" CR>>
+
+<ROUTINE V-REPAIR ()
+ <COND (<FSET? ,PRSO ,RMUNGBIT>
+ <TELL "You don't know how." CR>)
+ (ELSE
+ <TELL CTHE ,PRSO " isn't broken." CR>)>>
+
+<ROUTINE V-LOOK-UP ()
+ <COND (<PRSO? ,ROOMS>
+ <TELL "Don't get a sore neck." CR>)
+ (ELSE
+ <NEW-VERB ,V?WHAT>
+ <RTRUE>)>>
+
+<ROUTINE V-PLUG-IN ()
+ <YOU-CANT-X-THAT "plug in">>
+
+<ROUTINE V-UNPLUG ()
+ <YOU-CANT-X-THAT "unplug">>
+
+<ROUTINE V-EDIT ()
+ <YOU-CANT-X-THAT "edit">>
+
+<ROUTINE V-CLICK ()
+ <TELL ,NOTHING-HAPPENS>>
+
+<ROUTINE V-WALK-UNDER ()
+ <TELL "Only a snake could get under " A ,PRSO "!" CR>>
+
+<ROUTINE V-SCARE ()
+ <TELL "I don't think you scared " THE ,PRSO " very much." CR>>
+
+<ROUTINE V-TYPE ()
+ <COND (<CANT-USE-COMPUTER?> <RTRUE>)
+ (<NOT ,USERNAME?>
+ <NEW-VERB ,V?LOGIN>
+ <RTRUE>)
+ (<NOT ,LOGGED-IN?>
+ <NEW-VERB ,V?PASSWORD>
+ <RTRUE>)
+ (ELSE
+ <TELL "Nothing interesting happens, ">
+ <COND (<FSET? ,PC ,POWERBIT>
+ <TELL
+"except that a yellow smiling face appears
+in a small box next to the legend \"Sorry, Syntax Error. Hope you have a
+nice day anyway.\"" CR>)
+ (ELSE
+ <TELL
+"as the computer is powered off." CR>)>)>>
+
+<ROUTINE V-WEDGE ()
+ <TELL ,YOU-CANT "wedge open " A ,PRSO " with " A ,PRSI ,PERIOD>>
+
+<ROUTINE PRE-SWEDGE ()
+ <SWAP-VERB ,V?WEDGE>
+ <RTRUE>>
+
+<ROUTINE V-SWEDGE ()
+ <RTRUE>>
+
+<ROUTINE V-PUT-BETWEEN ()
+ <TELL ,YOU-CANT "put " A ,PRSO " between " A ,PRSI ,PERIOD>>
+
+<ROUTINE V-TASTE ()
+ <TELL "It tastes exactly as you'd expect " A ,PRSO " to taste,
+only worse." CR>>
+
+<ROUTINE V-DIE ()
+ <PERFORM ,V?KILL ,ME>
+ <RTRUE>>
+
+<ROUTINE V-HACK ()
+ <TELL
+"Your use of such jargon is unconvincing." CR>>
+
+<ROUTINE V-COOK ()
+ <TELL
+"Most people cook things in ovens." CR>>
+
+<ROUTINE V-DRIVE-ON ()
+ <COND (<FSET? ,PRSI ,PERSON>
+ <TELL CTHE ,PRSI " moves out of the way." CR>)
+ (ELSE
+ <TELL ,GOOD-TRICK>)>>
+
+<ROUTINE V-DRIVE-TO ()
+ <COND (<AND <IN? ,WINNER ,PRSO>
+ <PRSI? INTDIR>>
+ <DO-WALK ,P-DIRECTION>)
+ (ELSE
+ <TELL ,GOOD-TRICK>)>>
+
+<ROUTINE V-STEP-ON ()
+ <COND (<FSET? ,PRSO ,VEHBIT>
+ <NEW-VERB ,V?BOARD>
+ <RTRUE>)
+ (ELSE
+ <TELL ,WASTE-OF-TIME>)>>
+
+<ROUTINE V-STOP ()
+ <TELL ,NOTHING-HAPPENS>>
+
+<ROUTINE V-RELEASE ()
+ <NEW-VERB ,V?DROP>
+ <RTRUE>>
+
+<ROUTINE V-PUSH-DOWN ()
+ <COND (<AND <PRSO? ,ROOMS>
+ <GLOBAL-IN? ,DOWN-BUTTON ,HERE>>
+ <PERFORM ,V?PUSH ,DOWN-BUTTON>
+ <RTRUE>)
+ (ELSE
+ <NO-BUTTON ,DOWN-BUTTON>)>>
+
+<ROUTINE NO-BUTTON (OBJ)
+ <TELL "There's no " D .OBJ " here." CR>>
+
+<ROUTINE V-PUSH-UP ()
+ <COND (<AND <PRSO? ,ROOMS>
+ <GLOBAL-IN? ,UP-BUTTON ,HERE>>
+ <PERFORM ,V?PUSH ,UP-BUTTON>
+ <RTRUE>)
+ (ELSE
+ <NO-BUTTON ,UP-BUTTON>)>>
+
+<ROUTINE V-PRAY ()
+ <TELL "You get an empty feeling." CR>>
+
+<ROUTINE PRE-SPUT-ON ()
+ <SWAP-VERB ,V?PUT-ON>
+ <RTRUE>>
+
+<ROUTINE V-SPUT-ON ()
+ <RTRUE>>
diff --git a/yuggoth.zil b/yuggoth.zil
new file mode 100644
index 0000000..793e95b
--- /dev/null
+++ b/yuggoth.zil
@@ -0,0 +1,302 @@
+"YUGGOTH for
+ The Lurking Horror
+ (c) Copyright 1986 Infocom, Inc. All Rights Reserved."
+
+<ROUTINE I-YUGGOTH ()
+ <COND (<HERE? ,YUGGOTH>
+ <TELL CR
+"From below, a low noise begins, and slowly builds. You feel yourself drawn
+downward by the noise." CR CR>
+ <GOTO ,BOWL-ROOM>
+ <RFATAL>)
+ (<HERE? ,BOWL-ROOM>
+ <TELL CR
+"The crowd around you begins to sway and groan. They are expecting
+something. You are drawn forward by the noise." CR CR>
+ <GOTO ,PLATFORM-ROOM>
+ <RFATAL>)>>
+
+<ROOM YUGGOTH
+ (IN ROOMS)
+ (DESC "Place")
+ (LDESC
+"This is a place. Things move about on a broken, rocky surface.
+Harsh sounds split the air. Something sticky grabs at your feet.
+There is no color, everything is drained of brightness, dull and
+lifeless. A path descends into a shallow bowl of black basalt.")
+ (DOWN TO BOWL-ROOM)
+ (FLAGS ONBIT)
+ (ACTION RANDOM-YUGGOTH-F)>
+
+<ROUTINE RANDOM-YUGGOTH-F (RARG)
+ <COND (<RARG? ENTER>
+ <QUEUE I-YUGGOTH 2>)>>
+
+<ROOM BOWL-ROOM
+ (IN ROOMS)
+ (DESC "Basalt Bowl")
+ (LDESC
+"You are at the bottom of a deeply cut, smooth basalt bowl. Dimly seen
+shapes crowd you on all sides. Ahead, in the focus of the movement, is
+a rock platform.")
+ (UP TO YUGGOTH)
+ (IN TO PLATFORM-ROOM)
+ (DOWN TO PLATFORM-ROOM)
+ (GLOBAL PLATFORM)
+ (FLAGS ONBIT)
+ (ACTION RANDOM-YUGGOTH-F)>
+
+<ROOM PLATFORM-ROOM
+ (IN ROOMS)
+ (DESC "At Platform")
+ (LDESC
+"You stand before a low rock platform, more like an afterthought of
+piled rocks or a glacial moraine than a work of artifice. You are
+pushed against the pile by the crowd around you.")
+ (FLAGS ONBIT)
+ (GLOBAL PLATFORM)
+ (ACTION PLATFORM-ROOM-F)>
+
+<ROUTINE PLATFORM-ROOM-F (RARG)
+ <COND ;(<RARG? LOOK>
+ <TELL
+ CR>)
+ (<RARG? BEG>
+ <COND (<VERB? WALK>
+ <COND (<EQUAL? ,P-WALK-DIR ,P?UP>
+ <TELL
+"You are prevented, as the crowd holds you back." CR>)
+ (ELSE
+ <TELL
+"The crowding is such that you can barely move, much less walk." CR>)>)
+ (<P? LISTEN (<> NOISE)>
+ <TELL
+"It sounds like supplication." CR>)
+ (<AND <P? SMELL <>>
+ <IN? ,LURKER ,HERE>>
+ <NEW-PRSO ,LURKER>
+ <RTRUE>)
+ (<OR <P? (DROP PUT THROW) SMOOTH-STONE>
+ <P? ATTACK * SMOOTH-STONE>>
+ <TELL
+"You can't. You go through the motions, but the stone doesn't leave your
+hand." CR>)>)>>
+
+<OBJECT PLATFORM
+ (IN LOCAL-GLOBALS)
+ (DESC "platform")
+ (SYNONYM PLATFORM ROCKS PILE)
+ (ADJECTIVE BASALT)
+ (FLAGS NDESCBIT VEHBIT SURFACEBIT)
+ (ACTION PLATFORM-F)>
+
+<ROUTINE PLATFORM-F ()
+ <COND (<VERB? WALK-TO THROUGH BOARD>
+ <COND (<HERE? ,BOWL-ROOM>
+ <DO-WALK ,P?IN>)
+ (ELSE
+ <DO-WALK ,P?UP>)>)
+ (<VERB? EXAMINE LOOK-UNDER LOOK-BEHIND>
+ <TELL
+"The platform is made of the same rocks as the surrounding terrain.
+In fact, you can't tell whether it is natural or constructed." CR>)>>
+
+<OBJECT SMOOTH-STONE
+ (IN PLATFORM-ROOM)
+ (DESC "smooth stone")
+ (SYNONYM STONE)
+ (ADJECTIVE SMOOTH SHINY SMALL)
+ (FLAGS TAKEBIT SEARCHBIT OPENBIT CONTBIT WEAPONBIT)
+ (VALUE 5)
+ (DESCFCN SMOOTH-STONE-DESC)
+ (ACTION SMOOTH-STONE-F)>
+
+<ROUTINE SMOOTH-STONE-DESC (RARG OBJ)
+ <COND (<RARG? OBJDESC?>
+ <COND (<NOT <FSET? ,SMOOTH-STONE ,TOUCHBIT>>
+ <RTRUE>)>)
+ (<NOT <FSET? ,SMOOTH-STONE ,TOUCHBIT>>
+ <COND (<HERE? ,INNER-LAIR>
+ <TELL
+"The stone sits on a hummock of mud. From here it appears to have a crack
+in it.">)
+ (ELSE
+ <TELL
+"One small stone stands out in the pile, smooth, shiny, and glowing with a blazing
+light.">)>)>>
+
+<ROUTINE SMOOTH-STONE-F ()
+ <COND (<VERB? EXAMINE>
+ <TELL
+"It's a ">
+ <COND (<AND <HERE? ,INNER-LAIR>
+ <NOT <FSET? ,SMOOTH-STONE ,TOUCHBIT>>>
+ <TELL "cracked">)
+ (ELSE
+ <TELL "smooth, shiny">)>
+ <TELL " piece of what might be obsidian. Scratched on it
+is a symbol." CR>)
+ (<AND <VERB? TAKE>
+ <IN? ,PRSO ,HERE>>
+ <COND (<HERE? ,PLATFORM-ROOM>
+ <QUEUE I-COOL 20 T>
+ <QUEUE I-LURKER-APPEARS -1>
+ <RFALSE>)
+ (<AND <HERE? ,BROWN-ROOF ,INSIDE-DOME>
+ <IN? ,FLIER ,HERE>>
+ <TELL
+"The noisome creature jabs at you with its razor beak, but appears
+unwilling to approach the stone." CR>)
+ (<AND <HERE? ,INNER-LAIR>
+ <NOT <FSET? ,SMOOTH-STONE ,TOUCHBIT>>>
+ <TELL
+"You pick up the stone. It has a long jagged crack that almost breaks
+it in half. As you pick it up, you feel it bump to one side. Then, as
+you are holding it in your hand, something pushes its way out through
+the crack, breaking the stone into two pieces. Something small, pale,
+and damp blinks its watery eyes at you. It hisses, gaining strength,
+and spreads membranous wings. It takes to the air, at first clumsily, then
+with increased assurance, and disappears into the gloom. One eerie
+cry drifts back to where you stand." CR CR>
+ <TELL
+"Something rises out of the mud, slowly straightening.
+The hacker, mud-covered and weak, staggers
+to his feet. \"Can I have my key back?\" he asks." CR>
+ <FINISH>)>)
+ (<VERB? DROP>
+ <COND (<IN? ,FLIER ,HERE>
+ <MOVE ,SMOOTH-STONE ,HERE>
+ <TELL
+"The shape becomes agitated, screeching and cawing as it approaches the
+stone." CR>)>)
+ (<AND <VERB? KICK MOVE RUB>
+ <NOT <HELD? ,PRSO>>
+ <IN? ,FLIER ,HERE>>
+ <TELL
+,YOU-CANT "get close enough." CR>)
+ (<P? RUB SMOOTH-STONE>
+ <TELL
+"The stone is smooth and ">
+ <COND (<NOT <ZERO? ,END-CNT>> <TELL "warm">)
+ (ELSE <TELL "cool">)>
+ <TELL "." CR>)
+ (<P? ATTACK * SMOOTH-STONE>
+ <COND (<PRSO? ,FLIER-SHAPE>
+ <MOVE ,SMOOTH-STONE ,HERE>
+ <TELL
+"The stone crashes against the wall of the dome. The shape
+screams, a hissing fit of anger and frustration." CR>)
+ (<PRSO? ,FLIER>
+ <TELL
+"The stone hits the dark beast, and appears to go completely through
+it as though the creature was made of air. ">
+ <COND (<HERE? ,INSIDE-DOME>
+ <MOVE ,SMOOTH-STONE ,HERE>
+ <MOVE ,FLIER ,BROWN-ROOF>
+ <QUEUE I-FLIER 3> ;"time to get outside"
+ <TELL
+"The stone tumbles onto the floor. The creature, hissing vilely,
+retreats." CR>)
+ (<HERE? ,BROWN-ROOF>
+ <OBJ-OFF-ROOF ,SMOOTH-STONE>)>)>)
+ (<VERB? OPEN>
+ <TELL-YUKS>)>>
+
+<ROUTINE OBJ-OFF-ROOF (OBJ)
+ <MOVE .OBJ ,COURTYARD>
+ <TELL
+CTHE .OBJ " disappears over the south edge of the building">
+ <COND (<IN? ,FLIER ,HERE>
+ <TELL ", and the creature ">
+ <COND (<EQUAL? .OBJ ,SMOOTH-STONE>
+ <SCORE-OBJECT ,FLIER>
+ <MOVE ,FLIER ,GLOBAL-OBJECTS>
+ <TELL
+"follows it, screaming frustration into the storm." CR>)
+ (ELSE
+ <TELL
+"watches it fall with cunning attention." CR>)>)
+ (ELSE <TELL "." CR>)>>
+
+<OBJECT STONE-SYMBOL
+ (IN SMOOTH-STONE)
+ (DESC "carved symbol")
+ (SYNONYM SYMBOL)
+ (ADJECTIVE STONE SCRATCH CARVED STRANGE INCOMPREHENSIBLE)
+ (FLAGS NDESCBIT)
+ (SIZE 0)
+ (GENERIC GENERIC-SYMBOL-F)
+ (ACTION STONE-SYMBOL-F)>
+
+<ROUTINE STONE-SYMBOL-F ()
+ <COND (<VERB? EXAMINE READ>
+ <TELL
+,SYMBOL-APPEARS "carved into the " 'SMOOTH-STONE ", perhaps with a claw. ">
+ <TELL-SYMBOL ,SMOOTH-STONE>
+ <CRLF>)
+ (<VERB? RUB>
+ <TELL
+"The symbol is rough." CR>)>>
+
+<GLOBAL YUGGOTH-COUNT 0>
+
+<ROUTINE I-LURKER-APPEARS ()
+ <CRLF>
+ <COND (<EQUAL? <SETG YUGGOTH-COUNT <+ ,YUGGOTH-COUNT 1>> 1>
+ <MOVE ,LURKER ,HERE>
+ <TELL
+"Suddenly, the dimness becomes darkness, and the crowd around you explodes
+with excitement. You are jostled and shoved from all sides. A low keening
+begins, building into a deafening, almost mechanical chant. The darkness
+before you compacts and deepens." CR>)
+ (<EQUAL? ,YUGGOTH-COUNT 2>
+ <TELL
+"The darkness before you, now visible, is a creature. It towers over the
+now-silent crowd. The thing jerks this way and that, spraying a foul
+ichor. Its palps twitch expectantly, then pound impatiently against the
+rock. You can feel the " 'SMOOTH-STONE " vibrating in your hand." CR>)
+ (<EQUAL? ,YUGGOTH-COUNT 3>
+ <TELL
+"The thing now turns, sensing the presence of the stone. It quests almost
+blindly for it, then those surrounding you thrust you forward. The thing
+stoops, its mandibles grasping you. You are lifted towards its gaping
+maw. The stench and the sounds issuing from it are overwhelming, and
+you fall unconscious." CR CR>
+ <DEQUEUE I-LURKER-APPEARS>
+ <COND (<IN? ,CHAIR ,TERMINAL-ROOM>
+ <MOVE ,CHAIR ,HERE>
+ <MOVE ,PLAYER ,CHAIR>)>
+ <MOVE ,ODD-PAPER ,GLOBAL-OBJECTS>
+ <GOTO ,TERMINAL-ROOM>
+ <ROB ,FROB ,PLAYER>
+ <RTRUE>)>>
+
+<OBJECT LURKER
+ (DESC "thing")
+ (SYNONYM CREATURE THING DARKNESS DARK)
+ (ADJECTIVE VISIBLE)
+ (FLAGS NDESCBIT PERSON)
+ (GENERIC GENERIC-CREATURE-F)
+ (ACTION LURKER-F)>
+
+<ROUTINE GENERIC-CREATURE-F ()
+ ,LURKER>
+
+<ROUTINE LURKER-F ()
+ <COND (<WINNER? ,LURKER>
+ <TELL
+,NO-RESPONSE " You are not even sure that you produced any sound
+when you spoke." CR>
+ <END-QUOTE>)
+ (<VERB? EXAMINE>
+ <COND (<G? ,YUGGOTH-COUNT 1>
+ <TELL
+"It is large, smooth and yet scaly. It has too many limbs,
+and they are not in the right places. To look at it gives you a
+headache." CR>)
+ (ELSE
+ <TELL
+"You see a visible darkness, in a shape not easily grasped." CR>)>)
+ (<VERB? SMELL>
+ <TELL
+"The thing gives off a charnel stench." CR>)>>