DrupalZM – Opening the Small Mailbox Reveals…

Even though it seems like I encounter a new set of issues at every step, things are progressing really nicely with the zmachine module. The lexical parser is done, it parses the input buffer and creates the parse table, looking up each word in the game dictionary. I had a few bugs with memory addressing and setting attributes of objects, but those are cleared up now.

I dont have any user interface to put commands into the input buffer yet, but I am able to set a “script” in the program so it will execute commands one by one, as can be seen below. This shows how much progress is done – as can be seen, it recognizes commands properly, but there are still a few bugs (notice how even though I take the leaflet and its in my inventory, its still in the mailbox as well – I’m not updating the objects 100% correctly yet). Also, if you try to move from the first room it crashes, which I think is actually related to the previously mentioned object issue. But anyway – here’s a nice transcript of how much is working so far!

ZORK I: The Great Underground Empire
Copyright (c) 1981, 1982, 1983 Infocom, Inc. All rights reserved.
ZORK is a registered trademark of Infocom, Inc.
Revision 88 / Serial number 840726

West of House
You are standing in an open field west of a white house, with a boarded front door.
There is a small mailbox here.

>open mailbox
Opening the small mailbox reveals a leaflet.

>take leaflet
Taken.

>read it
“WELCOME TO ZORK!

ZORK is a game of adventure, danger, and low cunning. In it you will explore some of the most amazing territory ever seen by mortals. No computer should be without one!”

>look
West of House
You are standing in an open field west of a white house, with a boarded front door.
There is a small mailbox here.
The small mailbox contains:
A leaflet

>i
You are carrying:
A leaflet

>jump
Are you enjoying yourself?

>jump
Wheeeeeeeeee!!!!!

>jump
Very good. Now you can go to the second grade.

>take me
How romantic!

>hello sailor
Nothing happens here.

>look at me
That’s difficult unless your eyes are prehensile.

>quit
Your score is 0 (total of 350 points), in 11 moves.
This gives you the rank of Beginner.
Do you wish to leave the game? (Y is affirmative): >
Ok.

Now to fix things up with the objects!

One Response to DrupalZM – Opening the Small Mailbox Reveals…

  1. Anonymous says:

    then what ?

Leave a Reply to Anonymous Cancel reply

Your email address will not be published.