Showing posts with label fighting. Show all posts
Showing posts with label fighting. Show all posts

Friday, December 07, 2012

Fight

I had a bit of a chat and a bit of an essay and thought about it, and I realized something:

Nobody likes playing the support characters.

Nobody picks endurance if they have a choice. Speed, range, stealth - anything but a tank! Similarly, nobody wants to play a healer. I mean, sure, if the party needs one, you'll take it for the team's sake. But nobody goes "wooo! Stand around and get hit!"

Both tanks and healers are support roles. In oldschool games, tanks were combined with offensive capabilities that made them acceptable ("warrior"), but that's steadily been eclipsed by the concepts of strikers and glass cannons. The classic D&D "cleric" was a combination of both support roles - boring healing combined with boring damage-sponging.

If we dissect party combat roles, we can see that most party combat games have a few specific tactical concerns.

1) Dealing damage. Often, there are multiple types of damage, or damage of varying focus. So you can have a lot of different "damage-focused" classes that are all unique.

2) Tactical manipulation. The most obvious is the tank, who draws the enemy fire, since he's so much better able to survive it. However, there are plenty of others, such as the rogue that gets free movement, or the skirmisher who gets a second attack if his first kills an enemy, or even just someone who can dominate turn order.

3) Statistical manipulation. The obvious example is a healer. However, boosts and hexes of all kinds apply - berserkers, mage armor spells, leadership bonuses... these are most common in MMORPGs, but have migrated into all sorts of other games.

My hypothesis is that tanks and healers are not boring because of their role: they are boring because they are a boring version of that role.

In most games, the classes are split into a few simple categories. Tank, striker, support. A lot of effort is put into making tank and support interesting to play, but there's an easy way around that issue: don't have them. Come up with new roles. Roles that are all interesting right from the start.

So, fun challenge: can we create a tabletop RPG where the character classes don't specialize in any of those three groups? Where all the classes have all three kinds of utility? But, of course, all the classes still have to feel different and interesting and mesh well in combat.

I think one key would be in allowing the players to migrate between tactical roles on the fly. So Anna and Barry might be dealing damage, while Jacob and Kelvin are doing tactical manipulation. Of course, these aren't the same at all: Anna is burning stats to deal out massive damage to one target, while Barry is providing baseline disruptive damage against the mooks. Jacob is drawing enemy fire while Kelvin is popping the initiative stack so that the enemies can't get their team attacks working.

And they all have the same base amount of HP and armor.

Hmmmm.

Wednesday, October 04, 2006

A Balanced Fairy Tale

Gather around and I shall tell you a (very long) story of a fantastic contest, a festival of carnage which brought warriors from every corner of the globe. Yes, a good, old-fashioned, world-wide beat-down.

Wait, you've heard this story before? What's that? Mortal Kombat? Dead or Alive? Soul Calibre? Darkstalkers? Virtua Fighter? King of Fighters? Street Fighter? Fighter Fighter?

Some of the most observant of you have probably noticed that certain fighters fit certain players better than others. Other of you have probably noticed that some people consider some fighters cheesy. Others might have noticed that certain warriors tend to beat specific other warriors, but lose to still other warriors. "Is this balance?" you cry, "Nobody gets to play Vega, he's too freakin' cheap!" But the other day, it was Chun Li we banned...

I have cracked the secrets. Yes, indeed, like Indiana Jones I have braved the wilderness, searching for the holy grail of Game Balance, until now done mostly by the Deep Magic known as "Guess and Test".

The First Secret of Fighter Game Balance is Spherical Coordinates.

Nearly every move in nearly every fighting game is character-centric. The moves issue from the character, center around the character, and affect specific distances from the character.

It's a mistake to think of an attack as having a given range. Instead, it occupies specific layers of the sphere.

For ease of not-letting-our-brains-ooze-out-our-ears, spheres come in five onion-like layers: immediate, short, medium, long, and extended ranges. What these ranges actually are depends on the game - a game like Dead or Alive, with no weapons or energy attacks, "extended" is about five feet. A game like Darkstalkers, extended range is "as far as the screen can possibly stretch". Games might have fewer ranges, if you really feel like it.

Few attacks only affect one range. Most attacks will "cut through" several ranges on their path to the enemy's face. For example, thrusting a spear pokes a small hole through medium, long, and extended ranges.

What percentage of the effective surface of the sphere an attack covers is also critical. A spear thrust takes up only a tiny portion of the layers it penetrates. A swing will carve a huge horizontal line through the sphere. A vertical slice may carve a line just as large, but it cuts through less effective surface, since surface above head height is rarely used in today's 3-D fighter games (except for juggling purposes).

Now, looking at the mathematics of it, a spear thrust covers only a teeeeeeeeny tiny little bit of space - say, 1/30th that of a swing. But it's not 1/30th as effective. That really screwed me up for a long time. How do you account for it?

I tried a couple of methods, but the one that works is to add the size of the opponent to all edges of the effect. It makes sense, when you think about it: in his attempt to dodge, the opponent must heave his fat ass out of the way. The bigger the ass, the more heaving is required.

Therefore, a spear thrust pokes an enemy-sized hole through several layers of sphere while a swing carves an enemy-height hole along the course of the swing. This means that the swing is something like 2-4x as "effective", which is just about right since most thrusts are either faster or cover more layers of sphere.

Already, we can see a few fun things developing.

First, long-range swings are rather evil, since they carve a lot of surface area out of a lot of layers of the sphere. Hence, most long-range swings are quite slow, with an impressive wind-up. There are a few exceptions, such as the knight class in Soul Calibre III, and I generally find those exceptions to be the cheesiest thing since gouda.

Second, when you're fighting tiny characters, horizontal swings should be moderately more effective than thrusts or vertical swings. This is especially true because small characters typically have a much faster foot-speed and better dodge moves. Innnnteresting. This is not true of games where size is virtual and has no actual effect on the collision box, and is obviously slightly different in 2D fighters.

Okay, so rule 1: Spherical coordinates. Rule 2: add enemy size to attack effects.

Rule 3: Optimum range.

Most moves have an optimum range. Some moves are very forgiving, with a range of ranges, but even these moves typically have a range they are "best" at. For example Ken's fireball can theoretically hit at immediate range, but is usually of more use at longer ranges.

Most characters have moves which are geared towards working at a specific range. In some games, like Dead or Alive, this is extremely subtle. In other games, like Soul Calibre, this is extremely pronounced. Most of their moves work most effectively when the enemy occupies a specific layer of our killer onion.

There's two kinds of "focusing" to take in to account. One is how forgiving each individual move is as to range. Some characters, like the barbarian class in Soul Calibre, can happily allow their enemy to occupy any of the three middle ranges because all their attacks hit all three of those ranges. Being low-focus in this way is very beginner-friendly.

The other kind of focus is how many of their moves deal with that range as opposed to other ranges. A barbarian has few immediate or extended attacks, so they are very "focused" in this way. On the other hand, a monk wielding a size-changing staff has moves for every range, usually found when least applicable. Being low-focus in this way can be easy for advanced players, but beginners will frequently suppose that "forward thrust" should be something other than "poke your finger into his belly button, if it happens to not be more than one foot away".

Once a character's optimum range and level of focus is determined, there is the art of staying at optimum range. There are two basic options for this. One is maneuvering. Typically done by smaller characters, they simply dash into their favorite place on the map.

The other is knockback. This is a misleading term, because not all knockback is actually knockback. Some people (Scorpion) have knock-FORWARD. Some people have knock-DOWN. Many people have knock-UP, usually leading to an asinine 75% damage combo.

The most interesting form of knockback is self-knockback. A lot of attacks move the attacker as well, covering distance while attacking. This is a very common method of "knockbacking" into a shorter range.

For most characters, the more they have of one of these methods, the less they have of the other.

Now we're starting to see some intertwined stats. Movement is useful for dodging as well as changing range. So, technically, movement should be nerfed somewhat, so it's not quite as easy to dodge things as it should be. Most games seem to do this.

Most games also take the approach that small characters should be fast, short-range characters. This allows them a strong "hook" to balance the game. Small, long distance chars are irritating, largely because the opposite supposition is that big characters need to be slow and long-range, giving those small guys plenty of time to get out of the way.

There are games which break these conventions. Games where long-range attacks are frequently as fast as short-range attacks. Characters that do this usually feel "cheesy" - think Kilik and, if you've ever played it, the magicians in Valkyrie Profile Fight Tag.

Blllleeeeaaaaahhhh... running low on juice. I'd like to say I'm coming up on the home stretch, but there is really no end to the exposition.

So the last thing I'll talk about is rule four: speed.

How long the enemy has to evade, block, and/or counter an attack is critical. This is primarily affected by how long the pre-attack animation is, and we can also think of the post-attack animation as part of its "speed".

Many attacks have "paths" - classically, attacks simply "popped" in, affecting their effective areas simultaneously. This changed, famously, with Dhalsim. Now there are many games (usually 3D ones) where the attacks have an effective area that changes moment by moment. Obviously, these attacks are "faster" near the beginning of their arc, and "slower" near the end, since they give more time to react.

The other half of this equation is how long the enemy takes to react to your attack. An enemy must see what you're doing. Milliseconds gone, decreases with training. They must recognize what you're doing. This takes less time the more you've fought against a character. Some characters, such as Yoshimitsu and Voldo, specialize in attacks that are hard to predict. Lastly, they must actually block (which takes a certain amount of time) or dodge (ditto).

These four primary rules interact to form a brutal statistical representation of what characters do what. I haven't explained how to actually BALANCE anything yet, and I'm not going to do that today. (And then they ate the minstrel.)

Rule 1: Onion spheres
Rule 2: Add enemy size
Rule 3: Optimum ranges
Rule 4: Speed

Rule five is combos, but I'll just leave it to your imagination.