November 17, 2004

Writing Fable, part two

by Noah Wardrip-Fruin · , 12:05 am

In my previous post on writing Fable I outlined some of the work that the Lionhead writers (lead by James Leach) undertook while crafting the game’s story and the lines delivered by the more than 200 speaking characters in that story. But the story is only part of Fable. There’s also a sizable virtual world — and it not only provides a setting for the story, and a sandbox to play in when not concentrating on the story, but also another means of controlling some of the characters in the story. This means that the two types of writing that are discussed in these posts can both provide lines for the same speaker, and that in some cases the logic of the story and the logic of the world are connected via characters, widening the possibilities of Fable. More on this below.

First, however, let’s take a look at the writing of Fable‘s world.

The world

Albion, the world of Fable, contains villages populated by seventeen types of non-player characters (NPCs). As a hero takes actions in the world (whether story-related or not) NPC attitudes toward the hero change. Again, the result isn’t just communicated through graphics and AI — it also takes place on a linguistic level, and this (along with the size of the story) is what required the game to include more than 150,000 words of dialogue. (For reference, a two-hour, two-act play might run about 1/7 that length.) NPCs don’t just speak with the hero. They also make comments to one another (often about the hero, within earshot) and to themselves (just audibly).

In order to be able to respond appropriately to the hero, each NPC must have “in her/his head” a representation of what they know of the hero — measured in terms of alignment (morality) and renown (fame and power). An NPC might respond with fear to a hero with an evil alignment and high renown, but react with disdain and mockery to a hero that is equally evil but of low renown. A simplified way of representing this might look like the following, with attitude toward the player as a dot that moves as the NPC’s knowledge of the hero’s alignment and renown shifts.

EVIL   GOOD R
E
N
O
W
N
  Fear Awe Worship  
  Respect  
  Disdain   Friendly  
  None  
 

Each NPC might talk with the player for any number of reasons — what you look like, what you’ve just done, the fact that you’ve just talked to the NPC, etc. Over 100 of these were enumerated by the Fable team, including:

Being greeted
Being greeted again
Being followed
Wearing odd clothes
Carrying odd objects
Seeing an assault
Seeing a theft
Being assaulted
Seeing an assault
Being given a gift
Seeing a trespass
Being apologised to
Being insulted
Seeing murder
Seeing decapitation
Being courted
Seeing vandalism
Seeing kindness
Receiving kindness
Being cheated on (in marriage)

These reasons for speaking are then cross-referenced with the NPC’s internal representation of their attitude toward the player. The NPC then says something appropriate for this combination. For example:

TEXT_AI_DEED_REACT_CRIME_TRESPASS_NONE You’re trespassing.
TEXT_AI_DEED_REACT_CRIME_TRESPASS_RESPECT What brings you here?
TEXT_AI_DEED_REACT_CRIME_TRESPASS_AWE Your Lordship?
TEXT_AI_DEED_REACT_CRIME_TRESPASS_DISDAIN You shouldn’t be here!
TEXT_AI_DEED_REACT_CRIME_TRESPASS_FEAR Er, can I help you?
TEXT_AI_DEED_REACT_CRIME_TRESPASS_FRIENDLY Here, didnít you know this is a private place?
TEXT_AI_DEED_REACT_CRIME_TRESPASS_WORSHIP May I humbly ask what brings you here?
TEXT_AI_DEED_REACT_CRIME_TRESPASS_RIDICULOUS What do you want, fool?
TEXT_AI_DEED_REACT_CRIME_TRESPASS_OFFENSIVE Hey. You’re trespassing!
TEXT_AI_DEED_REACT_CRIME_TRESPASS_AGREEABLE You! Hello there!
TEXT_AI_DEED_REACT_CRIME_TRESPASS_UGLY You aren’t supposed to be here, you horror.
TEXT_AI_DEED_REACT_CRIME_TRESPASS_ATTRACTED Oh hel-lo there.
TEXT_AI_DEED_REACT_CRIME_TRESPASS_LOVE Wonderful to see you!

There are 17 different NPC groups, and James tells me that they all have different voices and wordings. NPC groups include males, females, guards, bandits, children, etc. Together with the many reasons for speaking and the many possible knowledge states about the player, this created the need for 14,000 lines of NPC dialogue for the world. And within this huge number of lines were nearly-impossible writing tasks, such as creating 200 different ways of saying hello that expressed different character types and degrees of awe. So here the team took advantage of the fact that they were using skilled voice actors. As James wrote to me:

In the end we actually explained to each voice actor how the tag indicates the attitude and let them ad lib whatever they wanted. This resulted in some extremely natural (not to say comic) lines, but we had to go through afterwards and transcribe each and every one for the localisation teams. And there were 60,000 words to check, some of which were drunken mumbles or, frankly, just noises!

This vast amount of amusing material creates, in some sense, another game within the game. As happens in many writing-rich environments (such as IF) players spend time exploring different interaction paths with the game and the NPCs in order to find different amusing dialogue. However, Fable is constructed in such a way that this sort of probing tends to annoy NPCs. As probing continues, an NPC’s attitude can move, for example, from Friendly to Disdain — changing the tenor of the lines delivered. Luckily, these derisive statements can be some of the more amusing.

It’s also possible to interact with NPCs in Fable non-verbally, and this is where much discussion of NPC interaction in the game has focused. For example, one can give gifts, pose, flirt, and woo. One can even marry NPCs — though what might seem a huge life event doesn’t have that many in-game consequences.

Fable: Don't tell me you forgot to get her one? Well I'm not bailing you out this time, son.

Fable: My advice to you, don't get tied down to one woman.

NPCs: in the story and in the world

Now, finally, to what may be the most interesting thing about the writing of Fable — the connections between the story writing and the writing for the world simulation. The main site of this is in characters who are part of the story. A number of these characters had their story dialogue recorded by a voice actor who also recorded dialogue for a class of NPCs. These story characters are classified as belonging to the appropriate NPC groups, and their story functions may also be represented by the world simulation in alternate ways. This allows Fable to seamlessly switch the characters between “story” and “world” control. As James puts it, “This has never before been implemented in a game and hugely adds to the richness.”

For example, a bridge may have a keeper who is part of the story — and as part of this tries to send the player on a quest before allowing use of the bridge. If the player steps out of what is covered by the story dialogue for the bridge keeper (say, by threatening him) the keeper will fall into his NPC dialogue. And if the player decides to kill the keeper instead of going on the quest, and succeeds, it doesn’t “screw up” the story. The player can then just use the bridge whenever it is desired. Of course, if anyone sees this, other NPCs may begin to trust the hero less and fear him more, which is appropriate. After all, it’s one of Fable‘s design goals for the game and story to be shaped by the moral choices of players.

This is the subversion of hoop-jumping that I mentioned in my previous post (and for which I took some flack). I think it’s an interesting design goal, even if I didn’t make it at all clear when I characterized it as “situating the story in a simulated world.” It’s not greater simulation, but a different use of simulation. To summarize with another quote from James:

Not only does this subvert the ponderous quest-after-quest nature of many RPGs but it gives the player the sense of power, freedom and lack of accountability which, as a Hero, the game is about. Of course, it’s not a violent short-cut to winning. There is always a bigger gatekeeper…

It strikes me (especially in light of our recent discussion of the fact that bigger isn’t better) that games could also benefit from an inversion of this. Rather than giving particular characters in the story the ability to also fall back on the behavior of a class of NPC, any member of certain NPC classes could be used to fulfill certain functions in a story/mission (by being “taken over” by the story logic). So when it’s time for the function to take place it’s not a matter of somehow getting the player and the appropriate character together, across however much game distance, but just of getting the player together with some member of one of the appropriate NPC classes (for which the necessary story dialogue has been recorded). Or a matter of choosing the best NPC to use for the function, if several are immediately available. Actually, given how not-radical this idea is (and how not-technically-difficult), I imagine it’s been done. I might be forgetting something obvious. Can people point me at examples?

Final thoughts

While this kind of process writeup could be done for any number of games (I’m sure you’re all dying to hear about how this year’s Madden was penned) I think Fable is a particularly interesting example because Lionhead clearly takes writing seriously and is trying to think about how to better employ what writers know in their development processes. After all, how many other major commercial games released this year had the writing of a short story as one of the early steps in its creation? Who else is employing enough writing and acting talent to send players on a search for verbal easter eggs located via NPC interaction (rather than on a search for mini-games, or whatever)? A game like Fable helps us imagine an alternate game industry, in which writers are first-class citizens.

And it’s clear from the example of Fable that working in this way is, in some senses, more difficult. It might be a thankless job to do the stereotypical game writing task — writing dialogue for characters defined by someone else, who are doing actions determined by someone else, in a level designed by someone else. But it’s an easier task than participating in the rounds of design, compromise, and revision that James Leach and his team went through when working more equally with game designers, AI developers, and others on the Fable team. Yet James’s is the kind of challenge to which I hope more writers will have the opportunity to rise.

In the meantime, game industry writers will keep doing the best they can — and perhaps, like Rob Swigart (who commented on the first post in this series), find outlets for innovative writing in other areas of the computational media field.

Fable: There's nothing left for you in Oakvale. And if you'd stayed, you'd be as dead as the rest of them.

14 Responses to “Writing Fable, part two”


  1. andrew Says:

    Noah, thanks for this extensive two-part writeup, it’s great to be able to better understand the details of how Fable was built. A few comments and questions:

    On the one hand, for the “world” dialog, it basically seems like they came up with a certain number of NPC types, a certain number of NPC states, and a certain number of conversational discourse acts / contexts, and then wrote out all the combinations of those, or had their voice actors improvise them. That seems sort of simple. On the other hand, without AI to help generate those dialogs, i.e., rules that use different sentence types and word choices depending on an NPCs attitude, etc., and then voice synthesis to speak the generated dialog — the latter being the bigger technical problem, actually — there’s little way around this brute-force approach.

    What happens when a player repeats a discourse act (e.g., greet, insult, etc.) for a given NPC type/attitude combination? For example, if you “wear odd clothes” in front of an NPC twice in quick succession, do you hear the same dialog again? Some discourse acts, e.g. “insult”, I assume could change the NPC’s attitude towards you, so when repeated, could result in different NPC dialog being spoken.

    How is what you’re calling “subversion of hoop jumping” much different than multiple solutions to a game obstacle? I.e., a player can talk their way past the bridge keeper, or kill him, or marry him, etc. Perhaps it’s not that common for narrative games to offer multiple solutions to obstacles, and it’s true that implementing it requires the designers and writers to robustly handle more narrative permutations, and it’s a great design goal, but it’s not a particularly new idea. I haven’t played the Deus Ex games, but I remember reading that multiple solutions was a big feature there. I’m sure many text-based IF’s offer multiple solutions to certain obstacles. … Anyhow, perhaps what’s most impressive about this to you in Fable is that the dialog stays coherent and robust when pursuing these different solutions to obstacles?

    I’m glad to hear that Fable allows NPCs to mix together their “story” dialog and their “world” dialog. However I cringe in the first place when I hear there’s such a dichotomy between the “story” and “world”. But, from the way you’ve described it, they seem at least weakly integrated, which is good. Based on your experience so far playing Fable, do you think players who were unaware of the implementation would notice the seams between “story” and “world”?

    (I note that “story” and “world” dialog is a bit analagous to the “beats” and “global mix-ins” structure we built when writing Facade. Both Fable “story” dialog and Facade beats are designed to progress the drama — they are the heart of the story. Facade‘s global mix-ins are a broad, general set of additional dialog, like Fable‘s “world” dialog, but in addition to just providing a range of coverage, global mix-ins also progress the overall drama towards a crisis and climax. More on this in an upcoming paper that gives more detail on how Facade‘s conversational behaviors are implemented.)

    I also slightly cringe at the idea that one of the fun things to do is to hunt for verbal easter eggs. Not to discourage players from wanting to hear lots of the good writing — I’m all for that — but ideally it’s integrated as part of the game itself. For example, if the narrative were designed to be played over and over (which Fable is not, correct?), it would give you the chance to hear alternate dialog, without requiring you to artificially hunt for it. I think I’ve had an allergic reaction to that kind of activity ever since those multimedia-ish pieces of the 1990’s that require you to click everywhere on the screen to try to find all the objects that will react. I’m glad to hear Fable‘s AI discourages this by making some/most of your verbal interactions actually count towards something, effectively preventing players from just screwing around with NPCs with no consequences; that wouldn’t be very believable behavior.

    Finally, Noah, I think you’re right on when asking for game designs that are dynamic enough to “plug in” most/any characters in a large world into the template of the grander narrative. You’re wanting the system to be more generative, which I strongly feel is the right design goal. Someone in the previous discussion about GTA:SA wondered if that would deflate any motivation to explore the world; if you can have your narrative with only the characters and objects in your immediate vicinity, because the system can dynamically work with them in that way, then why explore at all? My guess is, I doubt it would come to that; even with a dynamic system like we’re talking about, there will be other reasons to explore.

  2. noah Says:

    Andrew, thanks for your detailed comments! I’ve got a slightly-narrow time window this morning, but I will try to respond in more detail later this week. For now, some quick thoughts:

    – Yes, without voice synthesis that’s acceptable we can’t get much beyond choosing between a (hopefully large) number of pre-recorded lines. Of course, you and Michael are getting a bit beyond this with Facade by cutting-and-splicing the pre-recorded lines. I really look forward to your forthcoming paper on Facade’s conversational behaviors.

    – As for multiple solutions, you’re right that everything I’ve written here should be read in context. The context is my interest in the fact that it’s implemented on the level of language and character. It’s the fact that a bridge keeper, faced with something that’s not part of the scripted story, has something to fall back on besides “I don’t understand that” or Simlish or whatever. It’s the fact that the mini-quest for crossing the bridge is “part of the story” but implemented in a way that’s connected to the keeper’s presence in the virtual world (connected to character, rather than “story part x can be completed one of these ways”).

    – I completely agree with your analysis of the GTA:SA discussion we’ve been having in “bigger isn’t better” — the pleasure would come in combining exploration and fictional development. And there are certainly things it would only make sense to have happen, say, outside of town. But I wonder if we should even have to traverse all the space to get outside of town, then. People have complained a lot about the “fences” in Fable that keep them from arbitrarily moving around the virtual world. I understand this, but I don’t know if long sections of travel without meaningful events should actually be a design goal. I mean, I think California’s beautiful, but I’m glad Dustin Hoffman doesn’t have to drive up and down it multiple times, in full detail, when The Graduate plays. It’s even okay with me that he crosses the Bay Bridge in the wrong direction. Not that I want to subvert all exploration, but I might like to be able to say, in one of these world games “use a couple long shots to establish that I’m traveling from where I am now to [particular place I've already been] and get it done in 10 seconds unless something important happens on the way.”

  3. noah Says:

    Andrew, a few more thoughts in response to your questions around What happens when a player repeats a discourse act (e.g., greet, insult, etc.) for a given NPC type/attitude combination? I haven’t been able to experiment with this as much as I’d like (I don’t have an Xbox, so I’ve been playing Fable at Josh Carroll’s apartment — he’s one of the Screen collaborators) but I think this is actually one of the weaker parts of the game. It seems that the approach is to, as I discussed earlier when talking about the BASIC-style line numbers, choose from one of the appropriate possibilities at random. This is fine, but then the game doesn’t seem to keep track of which lines have already been said. So repetition starts happening pretty quickly. It’s the same in the story-driven dialogue. People say the same things to you that they said a minute ago. To me this seems like the game AI treating dialogue as the same as animation. But they’re not the same. It might be acceptable to say: “We have three animations for this combination of circumstances (e.g., greeting someone the character is afraid of) and we choose one of them at random when the time comes.” But it is unacceptable to say the same thing for dialogue. Repetitive dialogue gets hard to swallow much faster.

    The repetition is particularly bothersome because Fable is clearly doing so much keeping track of the world, and using it to shape other choices of language. More than once I’ve had the experience of the person I was interacting with doing an unacceptable repetition while, simultaneously, I could hear people in the background saying things that did a pretty good job of reflecting the ways my actions had changed the world, my reputation in the world, etc.

  4. Phantsy Says:

    I’d have to dissagree, i think P.M and his team both at LH and at BBB done an amazing job at making the world feel live and inhabited by ‘almost’ real people.

  5. BRENNON Says:

    pleeze make A fable two, fable one was the best game EVER …..SO PLEEZE!!!!!!!!!!!!!!!!!!!

  6. JoL Says:

    If there is to be a Fable 2… Make it great, like startin off by recruitin people to join an army of good or eveil you can decide… Like another thing make more options availible not that many were availible in the first one and please make this one longer as well… Make more choices and lead an army or become one and fight alone against evil or form an army of evil or stand alone and take on the good you kno something like that would be awesome… Ohh yea the tatoos were a great idea too in the first i loved it… If you do make this sequel then make more designs for the shoulders arms face etc… I think once you put together something like this you’ll have gamers reaching for it on the shelves, becuz it would be one hell of a game to play….

  7. Peter Says:

    This game is fantastic, I enjoyed it very much.
    I spend my night looking for similar games now…
    Cheers

  8. Eder Pastrana Says:

    I wrote a paragraph but i accidently went back like two pages and deleated it with tab. In my last paragraph i wrote that first of all with all my gaming experience and knowledge i swear to you creators of fable that fable is the best game i have ever played. I have palyed a couple of regular xbox tittles and after i finished them in like a week i got bored of them right away. on around christmas i got fable…i played till today since like 12/25/05 to today 2/4/06. I can tell you with every gaming experience that i have ever had, fable is the best game i ever play, i have many reasons, first of all i have never got bored of it i have 7 different files…..finished…i dont have all the stuff but in my newr files i try to fix mistakes i did in others like…spend extra money, waste experience and other things.I HAVE NEVER PLAYED A GAME LIKE THIS BEFOR, I swear to you awesome creators, I HAVE NEVER PLAYED A GAME AS AWESOME AS FABLE! I can honestly tell you i was so happy when i saw in internetthat iu awesome creators were making a fable 2 coming out in spring (around my birthday march)sbut then i saw it was only for the xbox 360..Guys i cant aford xbox 360. First of all i have those tipe of parents that say”Why do yuou want another game system ,you already have 1″ or “we are not wasting money on more crap” I want to play fable 2, i want to buy it and love it and play it forever! Please if theres any way please i beg u with all my heart make it for regular xbox. Please do us “strict parents people with xbox” a huge favor, make it for regular xbox too please!!Im a true fan of fable i swear to u please make it for xbox regular!Ill even show u some pretty cool drawings of characters i made up trying to make my own story. Please fable makers i ask u a huge favor, please make it for regular xbox too!I even contacted g4tv.com adum and morgan and asked them to contact the fable creators and tell them to make it for xbox. Please im begging you guys I NEED THIS GAME ,WEE all regular xbox people need it for xbox please do us that favor i really have a passion for fable.Give me an adress to send u the pictures i have and ill show u im really a big fan that needs to play every fable game! PLEASE have mercy.I waatched a review on how some people made Phsyconauts and how the creators were really tired but i no u can do it for xbox too! please read this and consider it please were begging u!With all your respect i ask you to make it on regular xbox with all the options and features as the 360. Please make it come true…

    With all due respect

    Eder

    P.s.:please give me a dirrection to send u guys those pictures and some a my art.LONG LIVE THE FABLE!!!

  9. Katherine Spence Says:

    I loved this game. It was really fun. The only part that I didn’t like was the fact that Maze died. That made me really sad. He was my favorite character. But the rest of the game was top notch.

  10. JB Bone Says:

    I loved the first Fable!!! Now how about Fable two!!!!!!

  11. Oudeis Says:

    It is here. It is called Oblivion. It is much better.

  12. jdog Says:

    hi I have a question? I heard Fable 2 was online I was curious if you can kill opposing players like in other rpg’s.

  13. nichole nordquist Says:

    i loved youer game but you need to put some more in to it i mean like when some one has sex you can see them and ther needs to be more clowes and mord disishons and if you are planing on macking another game try to put it on xbox to becase i realy liked your game and i look forword to play ing it agin but i only have an xbox and playstashon2 so can ya… peace out nicky

  14. Soullezz Says:

    i really loved fable: the lost chapters. but i was wondering if they would make nr.2 so that you will be able to play it on pc instead of only X-box…

Powered by WordPress