Appendix B: Example ZurkParser Syntactic Analysis

Note that some of the strings in this analysis have been wrapped for readability. In the actual ZurkParser output, they MUST NOT be wrapped.

Description: "A comfy-looking couch, with a few cookie crumbs on it."
Object declaration: sofa
Description: "An ornate, Victorian, gilt-framed looking-glass. There's
something not quite right about this one though.  If only you could
put your finger on it..."
Object declaration: lookingGlass
Description: "A large, blue door, with a shiny brass doorknob."
Variable declaration: open(2)
Object declaration: door
Description: "A beautiful red rose.  With big thorns."
Object declaration: rose
Description: "A small, cozy room with a fireplace.  There's a blue
door on the Northern wall.  Beside the door is a window, through which
you can see the garden."
Object reference: sofa
Object reference: lookingGlass
Description: "A long-handled knife with a wickedly sharp blade.
There's blood on the blade, and a bloody fingerprint on the hilt.  It
looks like your fingerprint.  I wonder how that got there?"
Variable declaration: sharpness(2)
Variable declaration: broken(2)
Object declaration: knife
Object reference: door
Absolute var reference: door.open
Absolute var reference: Player.location
Room reference: garden
Absolute var reference: door.open
print: "The door swings closed behind you."
Absolute var reference: door.open
print: "You bump your nose on the door. Maybe if you opened it first?"
error: "Error in the game engine or description file"
cond(3)
Move declaration: north
Room declaration: study
Description: "A lovely garden filled with lillies, snapdragons, roses,
petunias, and poison ivy.  There is a door here to the South.  Through
the window beside the door, you can see the study."
Object reference: rose
Object reference: door
Absolute var reference: door.open
Absolute var reference: Player.location
Room reference: study
print: "The door remains open behind you."
Absolute var reference: door.open
Absolute var reference: rose.location
print: "Your fairy godmother appears and grants your every wish.  Game
over.  You win. Congratulations."
print: "You bump your nose on the door.  Ow!"
cond(3)
Move declaration: south
Room declaration: garden
Absolute var reference: Player.location
Absolute var reference: Player.location
Numeric arg reference: $1.open
Numeric arg reference: $1.open
print: "The door glides open on well-oiled hinges."
print: "Hey.  It looks like the door is ALREADY open.  Imagine that!"
cond(2)
Action declaration: open(1)
Absolute var reference: Player.location
Numeric arg reference: $1.location
print: "Sorry.  You're not anywhere near that"
Numeric arg reference: $1.Motility
Numeric arg reference: $1.location
print: "Ok.  You got it."
print: "Sorry.  You can't pick it up."
cond(3)
Action declaration: get(1)
Numeric arg reference: $1.location
print: "You can't drop that because you don't have it.  Duh."
Numeric arg reference: $1.location
Absolute var reference: Player.location
print: "[thud]  It hits the floor."
cond(2)
Action declaration: drop(1)
print: "What?  Leaving so early?  Fine.  Just reject me, then."
cond(1)
Action declaration: quit(0)



Terran Lane 2005-02-28