Gamasutra - Finding Agility in the Random

by Magerette, 2007-11-30 17:44:56

Gamasutra has an article up based on a discussion from the 2007 Montreal Games Summit with Flagship Studios(Hellgate:London) director of technology Tyler Thompson, dealing with how to physically provide randomization in games:

Over 10 years ago, Thompson worked with Blizzard North on random level generation, skills, combat, pathing and monster AI in Diablo, and was the project lead for Diablo 2: Lord of Destruction. Using Flagship's Hellgate: London as a case-in-point, Thompson's talk covered the design and programming challenges of using random levels, items, and monsters.

"All RPGs are a little random," Thompson began, explaining, "You can’t imagine a bunch of guys getting together to play D&D without using dice." As almost every RPG uses some basics, such as random damage ranges on items/spells/skills, or random selection of item drops, it's worth asking -- why do players like it?

"First, it kind of fits into a gambling mentality," said Thompson. "Random combat is similar to craps or roulette, where you take your chance and see what happens. Randomness can create excitement -- a weak character could randomly manage to beat a much stronger character, and vice versa."

The downside? Said Thompson, "Too much randomness can be frustrating - if even the lowliest zombie could kill a level 50 character with a critical hit, that’s not fun."...

...Asked Thompson, "If there are all these reasons why randomness is good, why don’t we see it everywhere?" For one thing, he continued, randomness removes an element of control from the designers.

"You’re not scripting the whole level – the whole experience," he explained. "It requires a different strategy for game development, and therefore people think that it is too hard – but it certainly isn’t easy."

Thompson's next topic -- pulled from a hat -- was game grammar. Meaning what? "A set of symbols that are governed by a set of rules," explained Thompson. "And you can apply those rules, one at a time, in any order, for any number of iterations."

He described how developers can use a “grammar” to make a level. Starting with a template – for example, an entrance room, a hallway, and an end room, the next step is to invent some rules. For example, one could extend the hallway, or replace the end room with a treasure room, or change the hallway into a crossroads. Simply applying the rules one at a time, in any order, for any number of iterations, creates a level.

Moreover, continued Thompson, "There are a couple of things you can do to make the algorithm and the method better." One way is to use sets of rules to perform different tasks: One set creates the ‘flow,' one set adds required rooms, and another set replaces generic rooms with specific rooms.

Advised Thompson, "Make it all data-driven so that artists can create templates, rules and replacements. This is how we did it in Hellgate.”

About random monsters:

"The monsters we use in Hellgate and Diablo are random in a lot of ways. They’re random in placement, selection, and in their properties.”

As to monster placement, Thompson said, "It’s a challenging thing to you [as a developer], as you’re saying you’re not going to place your monsters in cupboards or do other interesting things with them – you’re saying that you trust randomness to create enough interesting situations for the players, which we think they do."

He continued, "If you know where they can stand, you know where they can spawn, but don’t simply sprinkle them. Have settings for density, clustering of similar monsters, and a maximum number.Allow specific monsters to be placed when necessary, because designers will want some of that control.”

When it comes to selecting monsters, Thompson advised, “Create some meaning between groups of monsters and the levels that they go in." As an example, he continued, "We put the imps and the imp shaman in the same level as the zombies, as the imp shaman works as a good boss, the imps work as a good middle-level enemy and the zombie a good low-level enemy. You should have the flexibility to decide which levels monsters appear in."