Mailbag: Teaching Spatial Storytelling

A Twitter follower asked me for resources to teach students to pair space and story in a meaningful way, and they were already familiar with my article Plot-Shaped Level Design.

Screen Shot 2017-04-21 at 1.36.22 PMTo state what will be extremely obvious to some of my readers, but probably new to others: this is classic craft territory for parser IF, where maps are generally developed in tandem with plot and puzzles.

The primacy of the map, in this tradition, is why Inform had a map index much earlier in its development than it had a scene index: charting the space, together with its doors and access points, was understood as more critical (and also easier to do programmatically) than diagramming a CYOA-style node structure.

Classic text adventures rarely experimented with treating space as continuous rather than room-based, even though the possibility of doing so cropped up in discussion at least as early as 1991, with another discussion in 1996. Some of that may have had to do with technical challenges, genre convention, and the relative difficulty of expressing quantitative information in prose. But I suspect another major factor was simply that the room-based approach to map design offered a lot of leverage in controlling which parts of the story the player saw at a time. Games such as Ether that allow for very free movement through a highly connected volume have to rely on alternative methods to control narrative presentation, or else have story content that can safely be encountered in any order.

In classic parser IF design, the companion of the map was the puzzle dependency chart. Puzzle dependency charts showed which barriers had to be crossed before which others; maps represented how this manifested in physical space.

In most parser IF, not all of the map is available at once, and the player has to solve puzzles to open particular areas, whether by unlocking a door, getting past a guard, throwing light on a dark room, etc.: many of the classic IF puzzles reward the player with access to new spaces, though there are many different ways of setting up the challenge initially.

That progression of spatial access was typically what let the author control the difficulty curve (only give the players puzzles that they’ve proven they’re ready for) and the plot reveals (put the more important clues deeper in the map). Often, reaching a particular location, or reaching it under particular circumstances, or interacting with an object there, would serve to trigger dramatic scenes marking a major advancement in the story.

Then there’s the question of pacing and content density. How much story material belongs in each room? How much real space does a given room represent, and how does that connect with narrative presentation? Adam Cadre’s review of Lost New York gets into detail about some of these topics, and the problem of representational space vs. literally simulating a large area.

So with all that background explanation, here are a few other resources beside the links already given, but if anyone reading wants to recommend others, please feel free to comment as well. Continue reading

Small Plotting Trick for Choice-of Work

Choice of Games pieces also very often involve multiple romantic or career options; and in my WIP, I found that there was kind of a risk of making all the romances be variants of “…and then you ride into the sunset with person X.” From a storytelling point of view, though, I don’t find that very satisfying, because it makes those characters interchangeable and makes it harder for them to have distinctive arcs in the body of the text.

Recently I tried an exercise that helped with this. It is really pretty trivial but I shared it with a few people who found it useful, so now I will share it more widely. The exercise:

Continue reading

Small-Scale Structures in CYOA

Over the last few years the IF community has become more systematic about how we talk about structure in branching choice-based narrative. Sam Kabo Ashwell’s Standard Patterns in Choice-based Games is a go-to article defining some useful terms; it pairs well with Choice of Games’ article on how to use stats to create long-term consequence without combinatorial explosion, and Jon Ingold’s talk on inkle processes at GDC 2015.

A lot of that conversation revolves around the shape of the whole plot, or at least whole chapters, though; so I wanted here to talk briefly about some structures that I find really useful at the smaller scale.

screen-shot-2016-11-05-at-10-19-11-amConfirmation-required Choice. One of the things Jon talks about sometimes is the use of text to let the player opt in to doing something profoundly stupid, through a series of escalating choices. Are you sure you want to do this? It looks like the monster is getting angrier. Are you still sure you want to attack? Yes? You notice that the monster’s bite is poisonous. Are you going to attack now?

Once the player has opted in multiple times, it’s really on their own head if they wind up in a situation with a combat roll that wipes them out. This expands what would otherwise be a binary decision into an experience with more tension; it also tends to work well in cases where there’s one dangerous-but-interesting option and one safe-but-bland option.

How to enhance with stats: count how long the player sticks to the risky path before giving up (if they give up). Use this later as a metric of their commitment to the dangerous cause, and/or their recklessness.

screen-shot-2016-11-05-at-10-59-04-amTrack Switching Choice. A variant on the Confirmation-required choice is one where the player is allowed to change their mind in either direction for several beats. Later beats might introduce some potential drawbacks and warnings about whatever track the player is currently pursuing. Like the confirmation-required choice, this is a way to give some extra weight to a decision and emulate a situation where the protagonist might be genuinely conflicted about what to do next.

How to enhance with stats: track how often the player chose the outcome they ultimately landed on, vs. another option. Use this later as a metric of their commitment to a cause, or their willingness to change their mind about things.

Scored Choice. In the track switching choice, we hold the player to their final selection, whatever that might be. With the same basic structure, we could also score how many times the player chose one way vs. the other, and then use their top score to determine the outcome. The track switching choice often works well when there’s a single tough decision in the story; the scored choice is a good fit for a montage of related choices. For instance, if the player is choosing between a career-enhancing move or staying with a romantic partner, we might have a series of small decisions that test their commitment to one option or the other. (This strategy pretty much requires stats.)

Continue reading

Visualizing Procgen Text, Part Two

In a previous post (now several months ago — sorry!) I wrote about visualization strategies for looking at procedurally generated text from The Mary Jane of Tomorrow and determining whether the procedural generation was being used to best effect.

There, I proposed looking at salience (how many aspects of the world model are reflected by this text?), variety (how many options are there to fill this particular slot?) and distribution of varying sections (which parts of a sentence are being looked up elsewhere?)

It’s probably worth having a look back at that post for context if you’re interested in this one, because there’s quite a lot of explanation there which I won’t try to duplicate here. But I’ve taken many of the examples from that post and run them through a Processing script that does the following things:

Underline text that has been expanded from a grammar token.

Underlining is not the prettiest thing, but the intent here is to expose the template-screen-shot-2016-09-11-at-4-45-52-pmstructure of the text. The phrase “diced spam pie” is the result of expanding four layers of grammar tokens; in the last iteration, the Diced Spam is generated by one token that generates meat types, and the Pie by another token that generates types of dish.

This method also draws attention to cases where the chunks of composition are too large or are inconsistent in size, as in the case of the generated limericks for this game:

screen-shot-2016-09-11-at-4-45-28-pm

Though various factors (limerick topic, chosen rhyme scheme) have to be considered in selecting each line, the lines themselves don’t have room for a great deal of variation, and are likely to seem conspicuously same-y after a fairly short period of time. The first line of text locks in the choice of surrounding rhyme, which is part of why the later lines have to operate within a much smaller possibility space.

screen-shot-2016-09-11-at-4-45-36-pmIncrease the font size of text if it is more salient. Here the words “canard” and “braised” appear only because we’re matching a number of different tags in the world model: the character is able to cook, and she’s acquainted with French. By contrast, the phrase “this week” is randomized and does not depend on any world model features in order to appear, so even though there are some variants that could have been slotted in, the particular choice of text is not especially a better fit than another other piece of text.

This particular example came out pretty ugly and looks like bad web-ad text even if you don’t read the actual content. I think that’s not coincidental.

screen-shot-2016-09-11-at-4-45-59-pmColor the font to reflect how much variation was possible. Specifically, what this does is increase the red component of a piece of text to maximum; then the green component; and then the blue component. The input is the log of the number of possible variant texts that were available to be slotted into that position.

This was the trickiest rule to get to where I wanted it. I wanted to suggest that both very high-variance and very low-variance phrases were less juicy than phrases with a moderate number of plausible substitutions. That meant picking a scheme in which low-variance phrases would be very dark red or black; the desirable medium-variance phrases are brighter red or orange; and high-variance phrases turn grey or white.

Here “wordless” and “lusty” are adjectives chosen randomly from a huge adjective list, with no tags connecting them to the model world. As a result, even though there are a lot of possibilities, they’re likely not to resonate much with the reader; they’ll feel obviously just random after a little while. (In the same way, in the Braised Butterflied Canard example above, the word “seraphic” is highly randomized.)

Finally, here’s the visualization result I got for the piece of generated text I liked best in that initial analysis:

screen-shot-2016-09-11-at-4-45-44-pm

We see that this text is more uniform in size and color than most of the others, that the whole thing has a fair degree of salience, and that special substitution words occur about as often as stressed words might in a poem.

*screen-shot-2016-09-11-at-5-25-03-pm

There’s another evaluative criterion we don’t get from this strategy, namely the ability to visualize the whole expansion space implicit in a single grammar token.

Continue reading

Visualizing Procgen Text

Lately I’ve been aggressively telling everyone I know to do more visualization of the systems they’re building, and thinking about what that might mean for the procedural text experiments I’ve been up to.

If you’ve played with The Mary Jane of Tomorrow, you’ve probably noticed that some of the poems it generates show a lot more variation and richness than others. That’s easy to observe, but can we quantify it? Can we draw observations about what level of complexity is the most satisfying, and identify portions of the game where more or less complexity would improve the experience? If we’re procedural text artists, how do we decide where to direct our attention?

One of the fun/horrifying things about this particular medium is that it pretty much never feels like you’re done: it would always be possible to add more corpora and more variant templates. Both Mary Jane and Annals of the Parrigues came to an end because I needed to move on to other work, not because I couldn’t think of anything further to add. But one thing I might want from a procgen text tool is help discerning where the biggest blank spots are currently.

The first step towards visualization is of course figuring out what aspects of the system you might want to look at, and in fact I often find “how would I draw a picture of this?” to be a good way of making myself think about the salient qualities of a particular system. Here are the things I decided I wanted to know about the text in Mary Jane:

Size of component phrases: how long is the smallest atom of text in a given composition? When you see something in the text, was that produced by a human or is it the juxtaposition of several pieces selected algorithmically? This is very varied in Mary Jane, with some poems or conversation options picking entire sentences, and other selections being just a word or two long. (Parrigues goes even further and composites town names from constituent syllables, but Mary Jane isn’t going that far.)

Number of alternatives: if a phrase was picked from a list, how many other options were there? Number of options is going to determine how unique a particular element is in your experience of the text.

Salience of selected phrase: why did we pick this piece? How many pieces of information about the world model did it have to match in order to be selected? (And to combine those two points, if we picked a highly salient phrase, how many other options were there of equal salience?)

Continue reading

Writing Interactive Fiction With Twine (Melissa Ford)

WritingInteractiveFictionA curious and fascinating thing about Melissa Ford’s Writing Interactive Fiction with Twine is how it combines hypertext craft advice and Twine syntax tutorials with design expectations largely derived from parser-based interactive fiction.

This is a 400 page book about Twine fiction whose index lists Anna Anthropy once (in a passage discussing how she did geographical description in one of her games) and Porpentine never — though it does refer, without attribution, to the tiny Twine jam Porpentine ran. Steve Meretzky and Brian Moriarty appear, but not Michael Lutz or Tom McHenry or A. DeNiro or Caelyn Sandel or Dietrich Squinkifer, nor Michael Joyce or Shelley Jackson or other luminaries from the literary hypertext tradition either. The book has early and prominent chapters about how to design puzzles, inventory, and a room layout; fonts, text transitions, and CSS effects come quite a bit later, despite being much more common than inventory systems in practice. The section on genres starts with a helpful definition of the word “genre,” then runs through bite-sized descriptions of some common fiction genres — rather than, say, trying to describe the range of genres represented in current Twine fiction. The section on story structure explains terms such as “climax” and “exposition” from scratch, assuming essentially no writing-workshop-style experience from the reader.

This writing style, along with the tendency to draw examples from Narnia and Harry Potter, suggests that the author intends the book to be accessible to younger users as well as adults. It would probably be a bit over the head of most young children, but I could picture a motivated tween handling it just fine. Possibly that accounts for a decision not to explore much of the most innovative content for which Twine has been used. If you’ve read Videogames for Humans, almost none of what you saw there is replicated or even mentioned in this book.

Continue reading