PHPackages                             itafroma/zork - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. itafroma/zork

ActiveLibrary

itafroma/zork
=============

Port of MIT's version of Zork from the original MDL source.

12463PHP

Since May 8Pushed 5y ago4 watchersCompare

[ Source](https://github.com/itafroma/zork-php)[ Packagist](https://packagist.org/packages/itafroma/zork)[ RSS](/packages/itafroma-zork/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (2)Used By (0)

Zork
====

[](#zork)

This repository contains an attempt at porting the text-based adventure game [*Zork*](http://en.wikipedia.org/wiki/Zork "Wikipedia article on Zork") from its [original source code](https://github.com/itafroma/zork-mdl "Source code repository for MDL Zork") written in the [MIT Design Language](http://en.wikipedia.org/wiki/MDL_(programming_language) "Wikipedia article on MDL") (MDL) to PHP.

[![Build Status](https://camo.githubusercontent.com/0dea4f28046e2a1a974e85d893af4bc65dbbfa4e6c53370d7dd256468381d852/68747470733a2f2f7472617669732d63692e6f72672f69746166726f6d612f7a6f726b2d7068702e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/itafroma/zork-php)[![Code Coverage](https://camo.githubusercontent.com/632ec04554d1194e4426e9acce8c8664da072dac366fa9a91ad20435d70c205c/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f69746166726f6d612f7a6f726b2d7068702f6261646765732f636f7665726167652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/itafroma/zork-php/?branch=master)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/c22634e0d4e61f545cfd28438e881c929868d42ebb35cf6f2bb64e628b8a88f7/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f69746166726f6d612f7a6f726b2d7068702f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/itafroma/zork-php/?branch=master)

Rationale
---------

[](#rationale)

You might be wondering, "why do this?" [And you may well ask, "Why climb the highest mountain? Why, 35 88 years ago, fly the Atlan—"](http://er.jsc.nasa.gov/seh/ricetalk.htm "Transcript of JFK's Moon Speech at Rice Stadium in 1962") Okay, the real reason is because *Zork* holds a special place in my heart and I wanted to see if it'd be possible to replicate it in its original form—feature for feature, bug for bug—in modern languages.

Caveats
-------

[](#caveats)

The original incarnation of *Zork* was written in the late '70s in a language that has long been obsolete. In order to create a faithful adaptation, the original algorithms, procedures, and program design have been ported without consideration of modern programming principles. Concepts and structures that did not exist in MDL—for example, objects—are not used. This repository should not be considered a paragon of current development practices, but an exploration of a historical moment in game development.

With that in mind, I have made a few conceits:

- Concepts and data structures that existed in MDL but do not exist in certain, more modern languages (e.g. enumerable types in PHP) are replicated as best as possible while still maintaining the spirit of the original code.
- Namespacing of functions (and classes when they are necessary) is used.

Roadmap
-------

[](#roadmap)

You can follow along with development on my blog in a series of posts I'm calling "[Porting Zork](https://marktrapp.com/blog/2015/01/27/porting-zork-part-1/ "Porting Zork — Part 1: Introduction")". This project will follow the [Semantic Versioning](http://semver.org "Semantic Versioning website") standard: the first numbered unstable version, 0.1.0, will contain a running executable (though not a complete game). The 1.0.0 release will be a complete port.

Installation and usage
----------------------

[](#installation-and-usage)

Installation is done using [Composer](https://getcomposer.org "Composer website") via [Packagist](https://packagist.org "Packagist website"):

```
composer create-project itafroma/zork:dev-master
```

At this stage of development, there is no working binary, but you can run tests using [PHPUnit](https://phpunit.de "PHPUnit website"):

```
cd zork
./vendor/bin/phpunit --configuration phpunit.xml.dist
```

Acknowledgments
---------------

[](#acknowledgments)

The original *Zork* was designed and [implemented](http://en.wikipedia.org/wiki/Implementer_(video_games) "Wikipedia article on implmenters") between 1977 and 1979 by [Tim Anderson](http://en.wikipedia.org/wiki/Tim_Anderson_(Zork) "Wikipedia article on Tim Anderson"), [Marc Blank](http://www.infocom-if.org/authors/blank.html "Infocom author page on Marc Blank"), [Bruce Daniels](http://en.wikipedia.org/wiki/Bruce_Daniels "Wikipedia article on Bruce Daniels"), and [Dave Lebling](http://www.infocom-if.org/authors/lebling.html "Infocom author page on Dave Lebling") working out of the MIT Laboratory for Computer Science Dynamic Modeling System ([MIT-DMS](http://pdp-10.trailing-edge.com/mit_emacs_170_teco_1220/01/info/mit-dm.txt.html "Information on MIT-DMS")).

I am using the reference manual *The MDL Programming Language* by S. W. Galley and [Greg Pfister](http://perilsofparallel.blogspot.com "Greg Pfister's blog") to facilitate the porting process.

Copyright and license
---------------------

[](#copyright-and-license)

The original *Zork* source code is copyright © 1978 Massachusetts Institute of Technology. All rights reserved.

Where applicable, the ported source code is copyright © 2015 Mark Trapp. All rights reserved. The ported code is made available under the MIT license. A copy of the license can be found in the `LICENSE` file.

Development disclaimer
----------------------

[](#development-disclaimer)

This a personal project in its early stages of development and planning. It is not ready for collaboration or a guarantee of fitness. It's being made available for transparency (and so I have something to point to when I want to talk about it), but be warned that:

- Support requests via GitHub issues or email will go unanswered and ignored
- Pull requests will be summarily rejected
- Public progress may be minimal to non-existent for long stretches at a time

You're welcome to use what's here under the terms of its license (if one is available) or the principles of fair use (if one is not). If you like the idea/premise behind this project, I would suggest starting over the way you'd want to do it yourself as I am very unlikely to accept future contributions forked off of, or derived from, this project's current stage of development.

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity43

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/277116?v=4)[Mark Trapp](/maintainers/itafroma)[@itafroma](https://github.com/itafroma)

---

Top Contributors

[![itafroma](https://avatars.githubusercontent.com/u/277116?v=4)](https://github.com/itafroma "itafroma (120 commits)")

### Embed Badge

![Health badge](/badges/itafroma-zork/health.svg)

```
[![Health](https://phpackages.com/badges/itafroma-zork/health.svg)](https://phpackages.com/packages/itafroma-zork)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
