Procedural Stories in Practice: Torchlight II

At Runic Games, if it isn’t randomized, they don’t even want to hear about it. The office restrooms change sexes several times per day, each employee takes a new desk at random intervals, and the water cooler is just as likely to spit out boiling oil as H2O. It’s the same way my posts bounce between fact and fiction without so much as a kind word of warning. In Torchlight, the team further iterated on the concept of randomized dungeons with great success. Now, with Torchlight II, Runic is experimenting with an idea rarely explored: random bits of story.

You’ll still get the randomized dungeons you love, and, if you’ve followed the game, you may already know you’ll be getting outdoor areas as well which will also be randomly generated. In the early days of procedurally generated dungeons, the engine built the dungeon one tile at a time. These days, designers build large chunks which the engine pieces together to form a cohesive area to explore.

The size of chunks fed into the engine has been growing and this sequel with its outdoor areas brings a significant increase in the number and variety of pieces composing a single area.“…the largest dungeon we had in Torchlight was maybe six or maybe seven chunk types and that was in Palace towards the end of the game and that was a very linear progression but it was still a pretty lengthy one. For the outdoor areas forTorchlight II, I think right now we’re averaging around 14 chunks for one of the bigger outdoor areas,” says Patrick Blank, the game’s lead level designer.

The outdoor areas are a natural evolution from the fully underground questing in the first game. It’s a great change of pace for the player to be able to get out into the open from the cramped catacombs. Runic’s founders made the same jump going from the first Diablo to the second back when they were Blizzard North. However, quest randomization in the Diablo series was… well, it barely existed.

In Torchlight II, you will find random events along with other random quests tied to, what Runic calls “landmark areas.” The random events sound very much like those of Red Dead Redemption. JD Wiker, Torchlight II’s resident wordsmith, told me, “An event quest could basically just be a little piece of art asset that just happens to be sitting there like a burned out wagon or something.” This burned out wagon would then have a task associated with it — perhaps finding the bandits who destroyed the wagon or returning a ring found in the rubble to its rightful owner.

The landmark areas, on the other hand, are larger set pieces. JD’s example is the cemetery. “So, if a zone has a cemetery landmark in it, it’s because there are quests available that are associated with that landmark. If you’re following the story, you should get the associated quest. And, if you’re a thorough player, who takes a lot of side quests, you’ll probably get an unrelated quest or two that goes to the same place.”

NPC motives for assigning a quest also have some variance.  JD provides an example. “(The NPC) will have you go take care of a task that’s going to be the same because that’s the event task, but each time you encounter him, he’ll have different quest text. He may say, ‘Go fetch me the big rubber ball.’ I’m thinking of that because I’m looking at (Runic Minister of Culture, Wonder Russell)’s Dog, Falcor. He may say, ‘Go fetch me Falcor’s big red rubber ball,’ one time because he was playing with Falcor and he needs Falcor to come back. The next time he might say, ‘Go fetch me the big rubber ball because Falcor’s old rubber ball is worn out and I need a new one.’ It’s the same task, it’s just that he’ll have a different text of why he wants you to go on that particular task.”

It’s reminiscent of recent Rockstar games in which the dialog is slightly different on subsequent repeats of the same task. Although, in those cases, the scenario is the same each time. Anyone who has had to repeat missions in GTA 4 can attest this is a welcome addition to that game, and, in a game that begs to be replayed like Torchlight II, the feature will be welcome to players.

Just as dungeons remain constant in a single game, so do quests. It is only in starting a new character that the procedural content generation engine works its magic. JD explains, “…it’s not going to be that you’ll run into this guy and each time you run into him he’ll say, ’Oh, by the way, I need another rubber ball.’ It’s you’re going to run into him, and he’s gonna say, ‘Get me a rubber ball,’ and you’ll go get it and he’ll be done with you. He’ll have nothing else to talk to you about the rest of the time except to say maybe, ‘Hey, thanks again for picking up my red rubber ball,’ but when you play the game again or play with a different character or whatever — if you’re playing multiplayer and someone else approaches him, they might get completely different text when they talk to him.”

These new additions are exciting, but it made me wish there was some way to incorporate some of these ideas into the main story. Wouldn’t it be cool to have a videogame that was tailoring a story to your action just as a GM might in a game of tabltop D&D? When asked about the prospect, JD has some great insight. “I think it’s theoretically possible. I think that it shifts the workload onto the person who’s generating that system you’re describing. Instead of the level designers being able to plug things in where they want them or to set things up so that the random bits mesh together well, you’re putting a lot of this onto the writer so that no matter which direction the characters go or which random event pops in, it will all eventually tie back in again at the end. If that’s what you’re describing, I think it’s still a lot of work; it just shifts who does that work.”

Gaming is in a transitional period in which narrative is taking on a much larger role than it has in the past. That usually comes in the form of crafted stories. In the wake of this change, it’s refreshing to see a developer like Torchlight continue to push in other directions, namely that of procedural content generation, all the while still conveying an overarching story. “There is an overarching storyline and it is not randomized,” says JD. “So, everytime you play, you will be on that main storyline quest if you follow it all the way through, but there will be side quests and quests revolving around landmarks and event quests and quests that involve the lore of the world.” There is an undeniable appeal of a singular story created by a writer, but the real draw of the game is the way it randomizes bits of story. Random elements in games have been around since Rogue hit in the 1980s, but the approach still has merit. With Torchlight II’s refined approach to randomization, everything old is new again.