Grassy Knoll: The Director’s Cut

(It was either that or Grassy Knoll: Reloaded which seemed a bit much)

OK so I don’t know how it’s been so long since the last post I made on this but I have finally translated Grassy Knoll to a modern interactive fiction format. I’ll explain below but for now you can play it here:

Just click inside the box above and you can start typing and play the game.

I went with Inform 6 like I had mentioned previously and it’s been an interesting experience. The source code can be found here and you can download the compiled game here. Or you can just play it in the box above.

 

 

So, low key one of my favorite things I got Christmas before last was a hardcover copy of The Inform Designer’s Manual, fourth edition

I had mentioned that Inform was made by an academic in the 90’s named Graham Nelson. He made several versions of the language, up through Inform 6, and then an Inform 7 which completely redid the language in a “natural language” syntax, which for the purposes of this exercise I decided to skip and keep with the more traditional syntax of Inform 6. Both are still maintained, though Inform 6 is mostly just bug fixes now (and I think the natural language version is up to v10 by now).

Anyway the other thing he did which was pretty common and traditional at the time was he made a book about the programming language. So much in the same way Bjarne Stroustrup made C++ and wrote and published The C++ Programming Language, Graham Nelson made Inform and published The Inform Designer’s Manual, which much like the title suggests, is part programming language description, part manual on how to craft adventure games, and part history of interactive fiction.

It was also, for quite some time, a book you could only get in printed form. Like, you couldn’t browse it on the web, you couldn’t buy a digital version (the first version in 1994 predated many things we take for granted, like eBooks as a concept so selling a PDF was out of the question probably), you had to buy a dead tree version in a world where Amazon didn’t exist yet. And this pattern continued through the final revision, the fourth edition (commonly referred to as DM4) in May of 2001.

Today when you make a new programming language the trend is to make the information about it available as widely and freely as possible, especially if it’s the case that you are trying to be competitive and woo people away from existing, established languages. And Inform 7 follows this trend, but Inform 6 was for years tied to the old paradigm of keeping the documentation on the language (or most of it anyway) tucked away in a book. After about five years (around the time Inform 7 came about) they released DM4 online for free in both web and PDF forms, with the PDF being of the variety where it’s the same dimensions as the book.

Something I’m unclear on in hindsight is, if I was so interested in this why didn’t I buy a copy of the book in the years when it was only in printed form? I don’t really have an answer for that other than being cheap and also that circa 2001 corresponds to the era in which I was right out of college, married, and in my first job which as you might expect from right out of most college gigs, didn’t really pay that well.

But then in 2023 when going down the rabbit hole for the IF stuff I saw a reference on Wikipedia to the ISBN number which led to Amazon which led it to me putting it on my wishlist and then promptly forgetting about it yet again, until someone got it off my list for Christmas. It seems like it’s brand new off the press, which it might be, but the information inside claims that it was printed circa 2001 so either this has been sitting on some shelf in a warehouse for decades, or the print information is inaccurate and it’s a recent production. Amazon does have some number of products – including books and audio CDs – that are printed “on demand” so you can always buy a copy because it doesn’t exist until you order it and some robot prints the book or burns the disc. You can usually tell by the lack of publisher or record label info – but this book has a publisher and nothing on it that indicates an automated process (a copy of Game Engine Black Book: DOOM that I got literally had the date it was ordered as part of the printed book) so I think this is a preprinted copy, just not sure how old it is.

Anyway, in that previous post I mentioned that I was wanting to translate the game to something more modern. I was sort of torn between Inform and TWINE. I was considering TWINE both because it’s literally more modern (it was started in 2009) but also because I had a book on it that I found at Half Price Books.

But what I really thought was – I don’t just want something more modern, I want something that’s more road tested and portable. There’s that modern AGT interpreter, Magx, which can run the game (sans graphics) as-is but it doesn’t run everywhere (though mostly because no one’s bothered, it looks to be pretty portable C code). I could probably make it work in TWINE, but TWINE only runs in web browsers as I follow it, or in some sort of Electron-like arrangement. But the Z-Machine runs everywhere. On Windows, on the iPhone, on a Raspberry Pi, in a web browser,  on a Commodore 64 (size/version permitting), everywhere. Inform in particular had come full circle when, in the run-up to the graphic adventure game sequel Zork: Grand Inquisitor, Activision enlisted Marc Blank and Michael Berlyn to make Zork: The Undiscovered Underground, a text adventure prequel, for which they used Inform.

So Inform won out, both because of its longevity but also that it’s been proven to work. Plus, I had this cool book on it. Apparently on these topics I’m a sucker for a cool book.

I made a second version of the “gknoll.agt” source code file, “gknoll_scratch.agt”, with the idea being that as I implemented parts of the game successfully in Inform, I would delete them from the scratch AGT file. Once the scratch file was empty I was done. This actually mostly worked.

I went through and implemented all the locations in the game, with directions and connections between them to match their AGT equivalents. At this point I could actually compile and run the game and move from place to place, there just wasn’t anything to do. Still, I thought this was pretty neat. Right away though it was noticeable that not every location in the game can be found by going north, south, whatever – some locations were only accessible if you did certain things that I hadn’t implemented yet. There was no way to get to Oak Cliff where Oswald shoots Tippit, or the hospital where they’re trying to save JFK’s life.

Next up was trying to implement a time of day concept. This proved challenging and I’m still not sure if I did it “right” but I did it in a version that works. Basically I’m doing a blunt calculation per-turn and incrementing the minutes until it hits 60 then resetting them to zero and incrementing the hour, rolling over for noon turning into 1 pm. Since the events of the game start at noon and don’t go past like 2:30 pm, I didn’t have to worry about AM/PM. Like I said last time, I think AGT just had this time of day concept built in (and there were a few Infocom games that did something similar) and seeing that in place may have given me the original idea behind the game anyway, but Inform didn’t have anything intrinsic for this because it’s designed to be a flexible system.

Next I implemented the basics of the characters in the game, some of which are based on real people (like Zapruder) and others are fictitious (like your old high school crush you’re ostensibly meeting up with when you happen to be near one of the biggest events in American history). Something I noticed at one point though is that there’s this location in the game called “Backstage” where a number of characters, including the crush, are initially stationed. At first I thought maybe there was like a theater or something in the School Book Depository (real or invented by me as a teenager) and perhaps these characters were, I dunno, actors in a local theater troupe. I actually played through the game to this point looking to see how I could stumble into the Backstage area and had no luck. Only then did I realize in looking at the code that there’s no way to get to the Backstage area. I was truly confused, and then I had the literal head smacking moment: Backstage is a dummy area where I’m “storing” certain characters. The whole gimmick of the game is that characters are in the places they need to be at the times they need to be there in order to simulate the events of the day, but if you don’t need them there at all times you don’t want their initial area to be those locations, but I guess AGT required them to be *somewhere* so I just made a “Backstage” area. I’m actually not completely sure what Inform requires in this regard, I just mimicked what I did in AGT.

Then there was the Coke machine. OK, so this paragraph and the next are a spoiler so either play through the game a bit or skip it if you don’t want something spoiled. So, there’s three things in the game in which you can interact using money – a Coke machine, a food dispenser (one of those things with sandwiches), and a bus that can take you to Oak Cliff for the Tippit portion of the day’s events. The Coke machine is based off of something mentioned in the movie JFK – that at one point someone mentioned seeing Oswald in the lunchroom buying a Coke from a vending machine (with the implication being that this would be an irrational thing for someone who is either about to kill or just did kill the President to do). I’m not sure if the food dispenser also existed or if that’s just something I made up. And I think maybe a bus was mentioned in JFK but either way it’s a plot device to get you elsewhere in the game. The trick is your character for some reason has no money however there is a location in the game where you can get a quarter. You can either get a Coke from the machine, or a sandwich from the food dispenser, or you can ride the bus. The Coke serves no purpose, but the sandwich makes you sick and kills you (I don’t think it’s been laced with poison so much as you just ate a really old sandwich).

So I went and looked at the source code and went through the process of implementing the Coke machine in Inform and spent an absolutely nutty amount of time figuring out how to do it. Inform has the concept of containers and things that can hold other things, and buttons on things that do things, this is all absolutely possible in Inform. The trick is implementing it in such a way that’s believable. I could implement the Coke machine as a container that had a Coke in it and you could insert the quarter to get the Coke, but I didn’t want you to be able to then take the quarter out of the Coke machine because that’s not how vending machines work. I implemented the Coke bottle such that it was drinkable and then implemented an empty Coke bottle to switch it out with. Finally I had it working like I figured it should given the source code so I played the Inform version alongside the AGT version emulated in DOSBox and discovered… the Coke machine in the game doesn’t work like that at all. You just insert the quarter and it just says you got a Coke and drank it the end. This is when I realized I was trying too hard to solve a problem that didn’t exist – AGT, while it has some intrinsic things that Inform doesn’t easily have out of the box, is still not that complicated. I’m not sure to what extent I misunderstood the AGT source and to what extent it just didn’t work like I expected.

By now several months had passed and I was working on this when I had time or when I thought about it, but really it shouldn’t have taken this long. Since the original post I made on this was on 11/22/2023, the 60th anniversary of the assassination, my original thought was to make the follow up post with the Inform version of the game on 11/22/2024, one year later, but I missed that deadline. As the months creeped by I thought maybe it was going to be on 11/22/2025, but then it hit me – the opening page of that design document said the AGT version of the game was going to be released on July 4, 1995 (which, again, I was a high school student with zero resources, I had no plan or clue or concept whatsoever – not even the Internet really – so no ability to execute on this), it would be somewhat cool to release it on July 4, 2025, thirty years to the day. So that’s my goal.

Only missed it by a few years. Bonus cringe points for the scratching out of “fiction”

There’s a blogger I follow, The Digital Antiquarian, and they write about old stuff, usually gaming related, and he does a lot of writing about interactive fiction, in particular Infocom. He did an article in 2016 on AGT and it had one particularly interesting detail – most people who used AGT did so in isolation, not participating in any sort of larger IF community. This is both because of the logistics of the era (the World Wide Web wasn’t a thing yet and things like AOL charged by the hour) and also just the nature of the product, especially since come 1992 they just gave it away for free. In addition, a number of folks had played IF in the past, hadn’t touched it in a while, and then when they got a hold of the tools they tried to make something that could imitate Infocom’s work. Not necessarily successfully, but attempting to do so. I know in particular when I saw AGT could display some graphics I thought that perhaps the later Infocom games did the same (they didn’t, not really, though there were some graphic flourishes on the last few games).

I did have a point about halfway or so into reimplementing the game where I kinda had the sinking suspicion that, as neat as this journey has been, the game itself just isn’t very good. Like I had no delusions that I was unearthing some sort of unseen masterpiece, but outside of the neato factor, there wasn’t much there there, especially considering the number of useless locations in the game. However, as I got to where I was implementing the last of the locations in the scratch AGT file I started to realize that there were purposes to a number of those locations. Not lofty purposes of course but outside of a few connecting, transition locations, pretty much everything in the game served some sort of goal. That tied back into the article I linked to before where a lot of folks, apparently, used AGT for what I used it for, everyone’s “first text adventure”, their first and for many (myself included) only foray into game design. There’s bound to be one or more people working professionally in game design today that cut their teeth on AGT or some similar system and it was their gateway drug.

Because it kinda occurs to me – the neat thing about working with text adventures is that, if you have the right framework going, you can actually make them quite intricate and complicated and as detailed as you want, and not have any care or concern about some of the trickier aspects, namely graphics. In going through DM4 I realize that Inform goes all kinds of places, there’s chapters in there on containers, doors, switchable objects, putting things on top of other things, characters and dialogue, consumable objects, etc. Interestingly, and owing likely to the fact that it was created by people less constrained by technology and the need to ship software to stay afloat, Inform is actually considerably more complicated than ZIL, the programming language that Infocom used to write the text adventures they sought to emulate in the first place.

I used to have a theory (I still kind of do) that, for most commercial video games, there’s this finite amount of “energy” (resources, really) that you can expend on them if you want them to ever ship and make enough money to be profitable, and so you have to allocate your resources accordingly, and this manifests itself frequently in the form of games that will or need to sacrifice one aspect of them in order to focus on others. The area where this most often occurs is graphics, not only because it’s the often the hardest aspect to get right, but also because if your aim is graphics fidelity, the moving target nature of it can work against you. This is why you encounter games that are very graphically pretty but have very little else going for them in the way of gameplay. Obviously you can have both, like with 2016’s DOOM, but you better have a massive amount of money and talent to throw at it like id Software does. Scale back the graphics a bit though, and you can focus on other aspects. A great example of this is Minecraft where the decision was made early on to have the textures be deliberately low texture and every object in the game is a literal rigid cube, which then allowed the designer to focus on the other aspects like crafting and construction and object interaction. Even further down the line you have things like the original version of Dwarf Fortress where the characters are simulated, in-system, down to their literal knuckles but the game had next to zero graphics – everything was ASCII art down to your characters which were “@” symbols.

So then it’s logical that text adventures have the potential to allow you to create complex worlds but not require you to conjure up graphics for them. You can make a game or a system that is very detailed, with very involved puzzles or characters or atmosphere, and not concern yourself with whether or not the visual representation is up to par because there’s not one. A 1995 text adventure called Christminster is said to have, for the time, some of the most developed NPCs ever. The downside being that it can also come down to your skills as a writer – it doesn’t matter how good your puzzles are if no one can figure out what you’re talking about. And that’s not to say text adventures are a perfect medium – the puzzles of Myst rely on their visuals and purposely have no other explanation.

Getting back on track though, there was the matter of finishing porting Grassy Knoll to Inform. Like I said, once the final pieces of this game got implemented I realized that while it wasn’t going to win any awards, this game was a lot more “done” than I remembered. It’s still not a very substantial game, but it’s as competent as it can be given that it’s something written by an inexperienced 17-year-old still in high school. It’s somewhat amusing that both AGT and Inform have these intrinsic systems for saving and loading games, given that at best this game can be experienced in a single sitting – the in-game clock starts at noon and you can’t go past like 2:30pm or so so we’re talking like 150 moves total.

I did have a little bit of an internal struggle when it came to implementing versus revising. When I would come across something like a typo or a misspelling or a logic flaw in the game I had to decide – do I fix it or leave it in, warts and all? Do I want to be a preservationist or go full George Lucas? For that matter, does anyone really even care about preservation of this given that prior to 2023 no one besides me even knew this existed?

I ultimately compromised and for a simple reason – as silly as it sounds, the splash screen of the original game proclaimed that the version on the disk was 95% complete. I could reasonably justify that small changes were the never-finished 5%. So the clunky, cringe-worthy dialogue with your in-game near girlfriend stays, the 90’s era stereotypes about what happens to you when you go to jail gets removed. On a scale of zero to “Han shoots second”, it rates pretty low on the tampering meter.

Of course, in the run-up to making this article and figuring out how to get the game online I kept picking at it and fixing little glitches here and there. A few things the AGT version of the game does are not things I coded, they’re things the system had built in, like the dialogue when your character dies and it asks if you want to be resurrected – I had to emulate that in Inform. There’s no real “win” conditions in the game, other than maybe meeting your girlfriend, but the way the thing is laid out you have to avoid a number of things in order for that to happen. A few things in the game happen by random chance – as in, a random number generator does a 1-100 thing and if it’s above or below X then Y happens – and so a 1:1 play of the AGT alongside the Inform version becomes impossible at some point. And I’m realizing a few things in the game are the sort of thing I thought was incredibly clever when I was in high school but unless you make the same logic leap I did you won’t do the thing necessary to get there, so I may modify some of the text in the game to slip some hints, dunno. I’m torn between wanting to make this a better game and letting the flaws show up.

In the end it winds up being basically what it always was: a short text adventure with a wafer-thin premise, a smattering of locations inspired by 1960’s Downtown Dallas, a handful of obtuse puzzles from an inexperienced teenage game designer, and a time-based adherence to a cherry-picked collection of claims and facts from a movie and a couple of books. All of which was confined to a folder I’ve somehow carried around since the Clinton administration until I decided it was time to unleash it onto the world, or at least the dozen or so people who will ever read this.

Categories: