Would anyone here be interested in a ZMachine port into Assembly language? I have a ZMachine written in C (multipplatform source code) that covers up to version 8 of Infocom. I have no idea how long it would take, there's a lot going on. I also have the ZMachine specifications but don't know what to make of it (from scratch)...


Let me know,
Thanks...

For those who don't know what a ZMachine is, it's the game engine that Infocom used to drive the Zork series text advanture games and a few others, like MoonMist and Hitchhickers Guide to the Galazy... to name a few..
Posted on 2002-05-22 18:22:33 by _Shawn
apart from the fun value of doing the port, wouldn't it be rather useless?
I doubt there's any speed problems on any hardware that runs
today :), and the C code (if properly written) would have the
advantage of running on multiple platforms...
Posted on 2002-05-22 18:28:53 by f0dder
Fodder you may be right, but isn't the *fun* aspect the most important part...

:) :) :)

Sliver
Posted on 2002-05-23 00:23:18 by Sliver
I am interested only in the logic system.
I always assumed that those early text adventures were simple hardcoded logic. If the puzzle is somehow encoded, then I am more than interested as I am in the process of coding a hybrid game engine (portal-restricted dx object engine) and it could save me some pain in terms of hardcoded puzzle logic.
If it is simply hardcoded logic in itself, then this probably isn't a suitable forum for your topic.
Posted on 2002-05-23 02:29:10 by Homer
Uhm,

maybe this is a stupid question (Yeah I know, there are no stupid questions except for the ones not asked :P ), but what the heck (excuse this expression, in Germany it is used as (Was zum Geier!)) is a ZMachine?

Does it have anything to do with emulation? Or what is it??

Could anyone explain that briefly to me? (I am too lazy too google it :P )

Greets YaWNS aka Stefan K.
Posted on 2002-05-25 10:20:05 by YaWNS
Yes that was a totally stupid question, as the answer was given immediately in the postscript of the thread starter.
I guess there really are both stupid questions AND stupid people!

(anyone for Tea and/or No Tea?)
Posted on 2002-05-25 10:42:25 by Homer
EvilHomer: please keep it friendly here, I'm sure Stefan just overlooked the description in the first post, there's no need to call people stupid.

Thomas
Posted on 2002-05-25 10:50:41 by Thomas
You're right, Thomas.
One cranky old bastard from Australia is plenty :tongue:
Posted on 2002-05-25 11:33:23 by Homer
Hey guys,

too keep things clear, I am neither stupid nor did I overlook this part.

I assume he just changed the text later on.
Before you say "NO! There is no changement text..." I have seen it before on other threads which have been changed afterwards without this notification text :)

Thanks Thomas for supporting it.
@ Evil2k: I'd like some :)

Greets YaWNS aka Stefan K.
Posted on 2002-05-25 12:17:55 by YaWNS
I didn't modify the thread in anyway. The original post is what you read now. To make things clear, The ZMachine, as they called it, because the original Zork games used what they called "Z-Code", is really a byte-code interpreter of some sort, that read z-files. These z-files were programmed using z-code (looks like assembly language) and contained the logic of the game. The ZMachine itself, however, had very special facilities for controlling logic such as "PICK UP HAMMER" "USE HAMMER ON NAIL" or "KILL TROLL WITH AXE" and so on. It also had facilities controlling the flow of the game, for example, "NORTH" "UP" "WALK UNDER BRIDGE" woud actually take you to wherever that (path) led to (in the game).

As well, if you "DROP HAMMER" and travel around, and then come back, the hammer presumably would still be there unless there is another character in the game that may have taken it after you left. The ZMachine managed all this.

The logic of the puzzles, however, were not hardcoded in the ZMachine. It was just a virtual machine with special features making it specific for text adventure games. The logic of puzzles was programmed in Z-Code in the z-file (or the game itself).

Infocom and others released many games for this virtual machine. The ZM was created due to memory contraints on earlier PC's, memory contraints that don't exist today. But, because of it's special abilities for logic and so on, it makes it useful for text-based games even today, tho you don't see many of them anymore, if any.

It would be a good exercise to create one of these things in assembly and run an actual Zork game or some other. There are also z-compilers that convert the z-code into bytecode. One would have to be created, but the virtual machine is very simple, not like a Java machine in anyway. Keep in mind, this ZMachine spec was written before Windows and probly DOS 5 existed, and was primarily for non-PC mainframe kind of computers, though original ports were in Fortran I believe in early 70's. But was constantly revised until version 8 of the z-spec, in 1988 I think

Thanks,
Shawn
Posted on 2002-05-25 16:00:18 by _Shawn
Let me start by saying that I think the days of text-adventures and MUDS are long gone. We are experiencing the Quickening.
I would not be interested in performing a strict port of the puzzle-logic engine (state engine) which is the ZMachine.
I WOULD be interested in studying it's design and using it as the basis for game logic control in a modern 3d application.
It is easy enough for anyone to devise a basic storyline for a game. But if that storyline contains a branch, it becomes more difficult to implement. And if it contains a MULTITUDE of them, it becomes a real brain-fart, excuse my Australian.
The ZMachine was a wonderful state manager and could handle with ease the many multiple dependencies of a rich storyline.
It deserves to be resurrected, I agree, but not in it's original form, I feel there is no demand for pure text applications, in fact we are becoming an iconified society which worships the image and denigrates the written word.
Posted on 2002-05-29 00:36:10 by Homer