Z3 – The Zork CPU
opencores.org
opencores.org
I've considered trying to do a hardware implementation, but concluded it is beyond my skill. Some things like user input can be complicated. It is the interpreter's job to split the input on a program-defined set of delimiters, look up each token in a dictionary provided by the program, and copy a variable number of specified values it finds base on that info into other locations. That's really complicated for a single instruction, and makes it pretty apparent to me that their target from the beginning was interpreters, not any kind of special hardware.
Nevertheless, its an awesome project, and a really fun thought experiment. I'd love to see a physical version of something like this from 74xx chips.
You could start by making a CPU that traps to the OS for every single instruction (except for some minimal core), and then incrementally implement hardware versions to speed up execution.
FYI: Allen Garvin has a set of tools to generate annotated disassemblies of many of Infocom's games -- not just Zork I:
¹ https://github.com/Drakulix/zwreec ² http://en.wikipedia.org/wiki/Twine_(software)
It'd also be interesting to see similar "release notes" for proprietary game VMs, like the runtimes of Game Maker Studio or RPG Maker—though these would probably have to be the result of reverse-engineering + wild-ass guessing.
[1] http://inform-fiction.org/zmachine/standards/z1point1/index....
[2] http://inform-fiction.org/zmachine/standards/z1point1/appd.h...
That's an awfully notable omission.
Really cool project, still.