[In this reprinted #altdevblogaday opinion piece, Microsoft game designer Daniel Achterman continues his series on system design's best practices with several examples from Dungeon Siege 2's development.] My previous articles were about system design at a conceptual level, focusing on goals and best practices for system designers. This article gives an example of how to put those principles into practice. To demonstrate, I'll walk through the character stat systems for one of the games I did system design for: Dungeon Siege 2. I'll describe how its systems work, why we set things up the way we did, and how we did the math to translate our goals into content. I've posted the part of our system spreadsheets where we tracked and compared these values. As you read, follow along with the numbers here: Dungeon Siege 2 System Spreadsheet. Dungeon Siege 2 Character Statistic Progressions As an RPG, characters in Dungeon Siege 2 increase in power as they level up. Their stats increase, they get more health, and they get better weapons and armor. In order to make content that is appropriately challenging for characters throughout the game, we needed to be able to predict how strong characters would be at each level. We decided that characters' attributes and the base statistics of their weapons and armor would form their "base power level", so we started by defining those values and progressions. This base power level would later be increased by additional factors like skills, powers, and random loot modifiers to give their total overall power. All of these formulas have "Level" as a parameter. In the case of characters, this is their character level. In the case of items, it's the level we expect characters to be when they are using the item. Item level restricts when the random treasure generator can drop it. Damage Per Second We had a couple simple goals for base character damage per second:
The base damage per second formula should be the same for all classes. Dungeon Siege 2's classes have different strengths and weaknesses, but they all start with the same DPS. This changes as players start specializing their roles by spending skill points, but it's nice to have one base formula for everyone.
The base damage per second formula should be stupidly simple. It appears in countless other tuning calculations, like monster health and item bonus values, so it should be an easy formula to work with.
To keep the DPS formula simple, we made it increase linearly with level, the simplest kind of progression rate. It's just this:
Base Damage Per Second = 8 + 2 * Level
You can see it is identical for all classes in rows 6, 16, and 27 of the spreadsheet. The "8" term represents how much damage a character does at the start of the game. The "2" term represents the rate his base DPS changes with each level. To find a weapon or spell's damage, we multiplied the expected base damage per second from the spreadsheet by the weapon's time between attacks to get its damage per attack. For melee and ranged weapons, we then subtracted the expected damage bonus characters would get from statistics like Strength or Dexterity. Here's an example of a level 10 two handed sword that swings once every 1.5 seconds:
Level 10 Sword Damage = Base DPS at Level 10 * Time per Swing – Strength Bonus Level 10 Sword Damage = (8 + 2 * 10) * 1.5 – (0.2 * (10 + 3 * 10)) Level 10 Sword Damage = 34
So, a level 10 fighter wielding a sword that deals 34 damage per swing will deal the desired base DPS. Here's a visual of how much of a fighter's damage comes from his weapon vs. his strength at different weapon speeds:
If I had to do it again, I'd make the formula coefficients higher. Sometimes at low levels a player got a weapon or piece of armor that was one or two points better than his previous item, which just didn't feel very good. There was nothing to stop us from making all the numbers in the game bigger, so we should have done it to make those early upgrades feel more exciting. Fighter Armor The armor value progression is related to the game's damage calculation formula. There are a million different damage formulas in different games. Sometimes they're so complicated no one understands how they work. Dungeon Siege 2's is pretty simple by industry standards:
No tags.