MCPcopy Index your code
hub / github.com/ajdnik/gozork

github.com/ajdnik/gozork @v1.1.1

Chat with this repo
repository ↗ · DeepWiki ↗ · release v1.1.1 ↗ · + Follow
793 symbols 4,066 edges 71 files 223 documented · 28% updated 2d agov1.1.1 · 2026-04-22★ 43
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

GoZork Logo

A Zork I game ported from ZIL source to Golang.

Go Report

Description

Zork I is a 1980 interactive fiction game written by Marc Blank, Dave Lebling, Bruce Daniels and Tim Anderson and published by Infocom. To learn more about the history of the game feel free to read Zork I: The Great Underground Empire on Medium.

Install

Pre-built binary

Download the latest release for your platform from the releases page:

Platform Archive
Linux amd64 gozork-linux-amd64.tar.gz
Linux arm64 gozork-linux-arm64.tar.gz
macOS amd64 gozork-darwin-amd64.tar.gz
macOS arm64 gozork-darwin-arm64.tar.gz
Windows amd64 gozork-windows-amd64.tar.gz
Windows arm64 gozork-windows-arm64.tar.gz

Verify the checksum against checksums-sha256.txt included in the release.

Linux / macOS:

sha256sum -c checksums-sha256.txt --ignore-missing

macOS (if sha256sum unavailable):

shasum -a 256 -c checksums-sha256.txt --ignore-missing

Windows (PowerShell):

$file = "gozork-windows-amd64.tar.gz"
$expected = (Select-String $file checksums-sha256.txt).Line.Split(" ")[0]
$actual = (Get-FileHash $file -Algorithm SHA256).Hash.ToLower()
if ($actual -eq $expected) { "OK" } else { "MISMATCH" }

Extract and run:

tar -xzf gozork-<os>-<arch>.tar.gz
./gozork

go install

Requires Go 1.25+:

go install github.com/ajdnik/gozork@latest
gozork

Build from source

git clone https://github.com/ajdnik/gozork.git
cd gozork
make run

Usage

$ ./gozork
ZORK I: The Great Underground Empire
Infocom interactive fiction - a fantasy story
Copyright (c) 1981, 1982, 1983, 1984, 1985, 1986 Infocom, Inc. All rights reserved.
ZORK is a registered trademark of Infocom, Inc.
Release 119 / Serial number 880429

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.

>

Contributing

See CONTRIBUTING.md.

Extension points exported contracts — how you extend this code

RNG (Interface)
RNG abstracts random number generation so tests can inject a deterministic source. The single method matches math/rand.R [1 …
engine/state.go
VerbAction (FuncType)
VerbAction is a handler function invoked when a verb is performed.
engine/syntax.go
Action (FuncType)
Action is a handler function attached to a game object, invoked with a context argument.
engine/object.go
FDir (FuncType)
FDir is a function-based room exit that computes the destination dynamically.
engine/object.go
CDir (FuncType)
CDir is a conditional exit check that returns true if passage is allowed.
engine/object.go

Core symbols most depended-on inside this repo

Printf
called by 1054
engine/output.go
SetExit
called by 360
engine/object.go
gD
called by 299
game/zork_data.go
Has
called by 294
engine/object.go
LocSet
called by 180
engine/syntax.go
MoveTo
called by 167
engine/object.go
mp
called by 139
game/combat.go
String
called by 130
engine/object.go

Shape

Function 690
Method 51
Struct 32
TypeAlias 15
FuncType 4
Interface 1

Languages

Go100%

Modules by API surface

game/verbs.go137 symbols
game/actions.go137 symbols
engine/parser.go44 symbols
engine/object.go44 symbols
engine/parser_test.go29 symbols
game/verbs_movement.go26 symbols
game/combat.go24 symbols
game/coverage_consolidated_test.go23 symbols
game/verbs_test.go22 symbols
game/game_test.go22 symbols
game/verbs_meta.go21 symbols
engine/lexer.go21 symbols

For agents

$ claude mcp add gozork \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact