DEV Community

Cover image for Going Rogue
daveclarke
daveclarke

Posted on • Edited on

Going Rogue

Once upon a time I was at University doing a maths and computer science degree (and presumably provided subject matter for the BOFH but that's a different story). The University had a shiny DEC VAX 11/780 running VMS. The computer lab was an underground bunker with a bunch of physical terminals. Second year students were allowed a key to access it after hours. Yes a physical key. What did comp-sci students do after hours back in 1984? We played Rogue on a VAX 11/780.

While Rogue was not the first dungeon-crawling game with procedural generation features, it introduced the subgenre of roguelike RPG procedurally generated dungeon crawlers with Dungeons-and-Dragons-like items (armor, weapons, potions, and magic scrolls) that also had permadeath (permanent death) and an overhead graphical view — albeit via ASCII drawings, as opposed to text descriptions in natural language such as can be seen in Adventure/Colossal Cave and the original Zork games.

A couple of years ago I was feeling a little nostalgic so I googled to see whether Rogue was still available. I started out looking for a Mac port but the only ones I could find were pre-osx. I did however find a linux port download at Rogue Central. Having downloaded the source to my mac I was then faced with the question of how to run it. Docker to the rescue. Fast forward and while I really like Docker, the most recent Docker Desktop for Mac update hosed all my containers and images. So here is the trivial process to at least get my Rogue container back.

I subsequently discovered the Docker gcc image now throws an error when compiling the original source (and a bunch of warnings). Not to worry, I loaded the source into github, removed the offending line of code, and added a script, docker_run to create and run the container.

The first step is to clone or download the source.

$ mkdir -p ~/Projects/linuxrogue-0.3.7-roguecentral
$ cd !$
$ git clone https://github.com/daveclarke/linuxrogue.git .
Enter fullscreen mode Exit fullscreen mode

If you're already running Linux or have a Linux distro running under WSL you can just run make and generate a working executable. Otherwise this needs to be run in a Linux container using the appropriately named image gcc. Either run the docker_run script or type the following in to the shell:

$ docker run \
  --name gcc \
  -v ~/Projects/linuxrogue-0.3.7-roguecentral:/src \
  -it \
  gcc /bin/bash 
Enter fullscreen mode Exit fullscreen mode

The script creates a new container called gcc and drops you into a bash shell in the container. Building the source is easy:

# cd /src/linuxrogue-0.3.7
# make
# ./rogue
Enter fullscreen mode Exit fullscreen mode

For subsequent access if the gcc container is already running, access the container via:

$ docker exec -it gcc /bin/bash
# cd /src/linuxrogue-0.3.7
# ./rogue
Enter fullscreen mode Exit fullscreen mode

Press the ? key for a synopsis of the commands. Game on like it's 1984!

Top comments (0)