Archive for the ‘castle-fantasy’ Tag

Castle Fantasy (1982)   11 comments

As of 2022, Matthew Stepka is not only on a lecturer at UC Berkeley, but he previously was Vice President of Business Operations & Strategy for Google working on philanthropic efforts and opening new offices in Africa. He has studied both computer engineering and art, has a law degree from UCLA, and was a founder of one of the world’s first cyber-cafes.

A portion of his art from his webpage.

So quite logically, today, we’re going to look at an essentially unfinished game he wrote for Atari 8-bit computers when he was a sophomore in high school.

I was highly tempted to skip it — it only barely counts as an adventure, it uses a quite broken randomization system — but realizing this took so much effort I was invested, and I managed to hack at the BASIC source long enough to at least get a notion of what the author was aiming at.


(Yes, that’s the spelling in the comments. It is done correctly in the PRINT statement giving the title, though.)

I’m not clear how the game escaped into the wild. Mr. Stepka has put two of his later pieces of Atari work on his website (Shark! and OS II: The Sequel) but not this, yet somehow the BASIC source for this game ended up on both Atarimania and as an entry on CASA Solution Archive. I wonder if it would be possible to estimate how many student efforts (finished and unfinished) are lost to time.

The game is undecided as to whether it intends to be an RPG or an adventure and never quite settles on either. The “class” seems to be randomly determined and the idea — assuming the game had been finished — might have been to have a “thief”, “wizard”, “warrior” and so on with different starts. As it is the default is to give a map and a sword.

The map (displayed with the MAP command) shows in ASCII form like the above. It’s interesting for adventure format; I don’t think I’ve ever seen something quite matching. To borrow terminology from The CRPG Addict, the two possible map types (generally) for games on grids are razor walls and worm tunnels. Castle Fantasy, as seen on the map above, uses worm tunnels. We have seen a few adventure games use the razor walls model:

A sample from Deathmaze 5000.

The map in Deathmaze 5000 is still stored on a grid, like a CRPG. However, based on the original Crowther/Woods model, adventure games tend to be something else, and follow the concept of “nodes” from graph theory. We can even trace this back to Caves and Wumpus; Caves in particular felt like a pedagogical exercise in computer science trying to illustrate what a tree structure is like from the inside.

An example from Asia 1400 AD in Time Zone. With a worm tunnel model the entire grid would be stored in memory or on disk somehow, and there would be a “0” or “-1” or the like marking the three empty spaces shown. With the adventure game model, those rooms simply don’t exist in any sense at all.

Where I think the worm tunnel model might have some purpose in adventure games is coherent destructibility. By which, I mean, there have been games (like The Public Caves) that have tried to allow expanding the map, but due to allowing the players to name the directions anything they want — hence not being physical directions really, but nodes of graphs — it’s hard to convey a sense of physical position. (Enchanter did manage to do this with a puzzle, but thinking in terms of edges between rooms rather than the rooms themselves.) Whereas if all walls have a physical relative location to rooms, they can be easier to remove and possibly used that way in puzzles or as a way to work within a adventure-roguelike system with randomization.

This is all theorizing about admittedly a much better game, so let’s get back to Castle Fantasy. The verb list is wildly limited, and is simply composed of:


Yes, XXYZY instead of XYZZY. That helps reveal secret passages in particular locations (which teleport you elsewhere). HOLD shows your inventory. I’m still foggy on what ESP does.

Returning to the game proper, you start in a narrow arrow of “open passages” and “dark forests” blocked by a gate that needs a key, and my first time through there was no key nor a way to get a key. There aren’t any secret passages either (based on my testing XXYZY on every room).

Some poking at the source code reveals that the key is just the variable K, so I tossed a K=1 in on initialization and re-ran the game to explore a little farther…

…only to fall into a pit where there wasn’t any way out, nor any method of avoiding it. I would guess there were ladders or some such planned but never implemented.

Resetting the game “properly” without hacking myself to gain extra items, I tried a different random setup and found no gate blocking my entrance, but I still was stuck later by a gate down one corridor and and a pit down the other.

You start on the left, and the impassible rooms are marked in red.

What the game reminds me most of is Wumpus 2, specifically the String of Beads map. In that particular level, items, enemies, and obstacles are randomly placed (just like Castle Fantasy) but the particular geography means that it is possible to get into an “impossible start” where you are completely blocked off from reaching the Wumpus. At least in that game you only had the one objective and could send arrows sailing over pits; this game has no such consideration.

The only mitigating factor is the odd behavior of QUIT, which you might think starts a new game, but actually just restarts you at the start in the same “world” holding anything you’ve picked up. So you can get out of a pit that way, but it still puts the obstacle there.

Even if there’s some method past the pits (maybe ESP holding a particular item?) sometimes parts of the map are just blocked off at random. That is, there isn’t even an obstacle to get by, it’s just what the map shows to be an open corridor is in fact just a wall.

There are three different enemies: green dragons, dwarves, and “worlocks”. I only ran across dwarves and green dragons. Dwarves I managed to kill where the only choice was whether I wanted to keep fighting.

Any attempts to attack green dragons with my sword failed.

This screenshot is from when I had a torch. It lets you see what is in all adjacent rooms, so you don’t have to wander into a pit to find out it is there.

I made multiple earnest attempts to “play well” — there’s at least a SCORE function going on — and where each time I did a full reset of the game (that involves breaking out and typing RUN in BASIC, remember that QUIT doesn’t actually quit) I had maybe a 60% chance of starting with a completely impossible situation. My “best” run I managed to find a key early and a secret passage shot me off to an area without many obstacles, but the experience really emphasized how much the whole situation was a slot machine rather than something resembling skill.

The concept of milking the Wumpus-model of randomization still I think has some untapped potential and fits cleanly into the adventure-roguelike style I’ve referenced before, but Treasure Hunt back in 1978 managed a much more pleasing and coherent experience, even if it was apt to have impossible situations of its own.

Posted March 28, 2022 by Jason Dyer in Interactive Fiction, Video Games

Tagged with