Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

Scratch damage is a game mechanic whereby any successful attack always does some minimal amount of damage. This is often used in subtractive combat systems, where the defense is subtracted directly from the damage done by an attacker. Therefore, the target will always take some minimal damage.

The downside of such a system, for me at least, is that it's a hack. It takes a simple formula like Damage = Attack - Defense and turns it into a (slightly) more complex one: Damage = max(Attack - Defense, 1).

I also feel that it detracts from a player's skill in developing their character/etc. No matter how many defense bonuses they get, every attack will do some small damage. So why get your defense so high, if it won't mean anything?

Furthermore, this now encourages the use of larger numbers for Hp and damage, so that the scratch damage is truly negligable. After all, if the minimum damage is 1, and you only have 10 Hp, that's still 10% of your health. Even with 20 Hp, that's 5%. And I would rather avoid using larger numbers like that unless it's absolutely necessary.

However, there is one very important upside of scratch damage: it solves the deadlock problem.

Deadlock happens when neither side is able to do damage to the other. If you invest all of your resources into defense, and few into attack, then your character may not take damage, but they won't be able to deal very much either. Thus, you could come upon an encounter where neither side will be able to inflict damage, so battle continues forever. This is especially if you don't have random mechanics like critical hits (which I also hate).

At least with scratch damage, someone will eventually win. It may only be the one with the most Hp or highest number of attacks, but the battle will end.

So I like having a combat system where there will always be an outcome. But I don't like having scratch damage. What are my alternatives?

Alternatives that don't involve rolling random numbers; I want combat to be 100% deterministic. If the same battle is fought, the exact same outcome must happen.

If you want specifics on the gameplay, think in terms of turn-based combat, where battle can be automated (you design your forces, then pit them against others).

share|improve this question
7  
Could you do a deteriorating armor system (per encounter) to solve the deadlock problem? –  Tetrad May 4 '13 at 14:32
4  
+1 Well posed question. –  Byte56 May 4 '13 at 14:54
1  
I'd suggest you take a look at "Design Patterns of Successful Role-Playing Games": rpg-design-patterns.speedykitty.com/doku.php/start –  sarahm May 4 '13 at 15:59
3  
Devil's Advocate position: instead of forcing players to play your safe way, why not let them decide if they want to use stupid builds that can deadlock? –  Patrick Hughes May 4 '13 at 22:09
3  
@PatrickHughes: Because I believe that it's bad game design to allow the player to put themselves into a bad position without proper forewarning. And even with forewarning, they must be able to get out of it once they see that it's happening. If their character design choices can't be taken back, then they need to know up front that they aren't permanently screwing themselves over by making choices that seemed like a good idea at the time. –  Nicol Bolas May 5 '13 at 9:35

12 Answers 12

You could implement a fatigue/stamina system. As more and more attacks are done the player becomes increasingly fatigued meaning they are unable to maintain such a good defense (that shield arm suddenly starts feeling really heavy after swinging the sword 50 times) as fatigue increases, defense falls. This means a player who has developed a good character won't take damage in quick encounters but longer drawn out combat will result in increasing damage preventing a deadlock.

share|improve this answer

This seems like a very open-ended question. Solutions (that aren't already mentioned) to prevent deadlocks:

  • Allow for deadlocks as a viable end result. This is the least expected or typical solution. In an RTS game, for example, this might be an uneasy cease-fire, or tense but low-key conflict in a violent balance.
  • A time limitation with ties allowable
  • A time limitation wherein the first hit/score/point after the limit wins (sudden death/overtime)
  • Random dangers in the system (a la bombs in Super Smash Bros). This changes the focus of the situation from offense to defense.
  • Any external factor to imbalance the system (e.g. a third agent with high damage and low armor, an agreement by both sides to "duel" without all that armor)
  • Defense as a % reduced (probably the simplest solution, as long as the defense is capped)
  • Skills or tactics which alter the dynamics of gameplay (choices that don't result in damage, such as a Cloak/Invisibility skill)
  • Means of doing much higher damage (classic critical hits, stealth bonuses, height bonuses, terrain bonuses, an ability that turns random portions of ground into lava)
  • Means of damaging or lowering armor, or causing a damage directly targetted to high-defense characters (skill that inverses armor in the calculation, so agents with lower defense receive less damage)
  • Limited use items or skills (e.g. bombs, powerful but draining abilities). Only useful if there are long-term goals beyond the deadlock with which to balance limited use
  • End combat artificially (classic "Flee" option)
share|improve this answer

As variant, you may add wound accumulation. Surely, giant copper axe will not penetrate heavy steel armour, but it will do some blunt damage, and may event break bones. Same true for bullets and vests.

Everytime character being hit, convert part of piercing and slashing damage into blunt damage, and accumulate it. After certain threshold (that depends on endurance), accumulated damage will interfere with combat skills. Some options here:

  • Armor will be less efficient, when taking hits in same body parts.

  • Significant wounds: periodical damage, weakness due to pain.

  • Severe wounds: short-term loss of consciousness (rendering him very vulnerable).

  • Extreme wounds: permanent stat loss (if character will manage to survive).

Related: Damage mechanics in Dwarf Fortress

share|improve this answer
2  
I was going to suggest giving every weapon bludgeoning damage that cannot be blocked by armor. Swords and daggers would have small bludgeoning capacity, but axes and maces would be very effective. –  Boreal May 5 '13 at 21:01

Implement different types of damage, with armors that only protect against some types of damage. For example, kinetic damage, acid damage, fire damage, etc. No armor should protect against each type of damage.

Users could layer their armors to protect against all damage types, but they couldn't protect against all damage types at the same time. This implements some strategy into battles as well, where players have to switch damage types to get through the various layers of armor.

share|improve this answer

You could just not have a defence stat and just give bigger enemies bigger hp. I know you want to avoid gigantic numbers, but if you want a deterministic, turn based game where attacks aren't based on the players input directly (there is no chance of human error messing the attack up) the defence stat seems a little pointless as well.

If you are worried about the presentation aspect you could break HP down into Hearts or Health pips EG 100 hp = 1 heart. Hearts start to go black as a character loses HP, then disappear entirely. That way it's easier for the player to understand than 129301239103123hp, but you don't have to worry about balancing some magic equation.

If you are worried about realism, you could always have it animated to look like the attack's target successfully blocks or is only lightly scratched until the killing blow.

share|improve this answer
1  
"if you want a deterministic, turn based game where attacks aren't based on the players input directly [...] the defence stat seems a little pointless as well." Defense is not based on the concept of "chance-to-miss". It's more like damage reduction in D&D, not THAC0 (or whatever they're calling it these days). Defense means that a 40 damage attack can be reduced to 10 damage if you have 30 defense. I don't see how that can ever be "pointless. –  Nicol Bolas May 4 '13 at 15:39
    
I know the math is a little different, but really there isn't a huge amount of difference in terms of game-play between just giving a character a proportionate amount of health instead and having damage be reduced by a certain amount. Not if there must always be some way of dealing damage to a target. EDIT: That's assuming there aren't any special attacks that ignore defence, or other gameplay modifiers. –  Lewis Wakeford May 4 '13 at 15:44
    
Having a subtractive defense stat gives you something more than just Hp (in addition to all of the things you except, like special attacks or modifiers). It creates stratification between damage-over-time users and high-damage users. A character that attacks multiple times but with lower damage will run afoul of a high defense character, while a slower, high-damage character will be doing more damage-over-time. Mere hit-points will not create this stratification. –  Nicol Bolas May 4 '13 at 15:52

Add a wear-down mechanic for defense. Make every attack slightly reduced the defense of the target.

Eventually even a weak attack will wear down the targets defense enough to inflict actual damage.

share|improve this answer

If you are OK with stepping out from the world of integers and willing to spice up subtraction system, you can use damage reduction algorithm from Warlords Battlecry III:

damage = attack

while DR > 0:
    usedDR = DR
    if DR > damage
        usedDR = damage
    damage = damage - usedDR * 0.5
    DR = (DR - usedDR) / 2

HP = HP - damage

This is the function that behaves very similar to the above pseudocode:

damage(attack, DR) = attack * 2 ^ -(DR/attack)

When DR is smaller than attack (incoming damage), it behaves like attack - k*DR where k is 0.693 (ln(2) to be exact). When DR is close to or bigger then incoming damage than the damage is halved DR/attack many. For example for DR = 30 and attack = 10, damage would be 1.25 (attack halved 3 times).

It may look like more complicated and harder for human to evaluate but it is hack free and changes in both parameters are relevant. If attacker gains bonus attack power or defender gains or looses DR by even small amounts, the resulting damage will change.

share|improve this answer

Use floats.

Even if you present integer HP to the player, use float for hp and float for damage.

I am using fractional armor classes now, where armor of 1.0 is invincible and armor of 0.0 means "takes full damage". Damage is reduced as:

float hpReduction = hp - dmg*(1.f - armor) ;

This formula has the effect of allowing "double damage" by setting armor to -1.

I have classified damage into categories as well, see Starcraft's concussive/explosive damage types, or Eve's damage type system for an example.

So now, a little imp scratching at your .99 class armor will eventually Cherry Tap you to death, but the attacks will appear to do no damage to the player (he will remain at 1 hp as he goes from 1.15 hp to 1.1499 hp the next attack..)

share|improve this answer

A skill graph could put some damage-dealing skills as prerequisites for higher-level defensive skills to reduce a player's ability to make highly asymmetrical builds.

Critical hits can get some damage through as long as one's defense is not absurdly high. If you make them periodic rather than random, you still have deterministic combat.

After a number of failed hits, you might automatically reduce attack speed in favor of higher hit chance and damage. Your super-fast scratch character was doing ten attacks per second; now, after fifteen attacks doing no damage, it gets three attacks per second at +50% to hit and +200% damage. This is similar to critical hits, but it's faster for this sort of situation.

You could use percentage based damage reduction from armor, but to make it more interesting than another way to buff your maximum HP, you could have the reduction percentage be greater for weaker hits. For instance, 90% reduction for 1-20hp of damage, 60% for 20-30, and 30% for everything else.

Finally, don't worry about large numbers. They give you a much finer degree of control than small ones. Having a level 1 character start off with 100 hit points means you can have something that kills them off in seven hits but not five. It means you can have poison damage and other damage over time effects that aren't outrageously devastating (as well as some that are, if you like). If you don't like displaying large numbers, find a way not to display them.

share|improve this answer

You say you want there to always be a resolution, but does that have to be a victory?

Consider the approach used by Dominions--on turn 50 the attacker automatically routs. On turn 75 the defender automatically routs. (A rout doesn't automatically work--some units are immune to routing and even if an immobile unit routs it can't actually leave.) On turn 100 everything left is killed.

While I disagree with the exact way it functions (there are situations where it simply takes too long to kill the other side) the basic idea remains valid.

What I would suggest:

Look at some measure of the power of each side. (Hit points are an obvious starting point but be careful, Dominions has a problem in this regard where hit points "loss" that isn't meaningful is being counted--shapechanging, summons etc. resulting in armies routing due to casualties when they didn't even take any.) Keep track of the minimum value reached and note how many turns it has been since a new minimum has been set. If it goes too long without a new minimum being set you have a deadlock of some kind and the attacker should retreat.

share|improve this answer

Lots of 3D fighting games avoid scratch damage. Examples are Tekken and Soul Calibur 2. They avoid this by making it difficult to have a perfect defense. Some attacks are simply too fast to react to. I think it's a pretty good solution.

share|improve this answer

I think reducing the effectiveness of Defense is not a good option. Depowering a player leads to a bad game experience. Why not go the other way around?

Why not powering up the Attack as time goes by. This makes scratch damage increase with time, reducing the incentive of blocking. In mid-late game, a character can kill another while wailing on him while he's defending.

Some pnp rpgs implement a "tension mechanism". Each turn tension increases by one. All the rolls have the added modifier of the tension value, pushing the battle towards an end.

Another idea, coming from Fighting games, is an attack that goes through defense. I don't know if your game is turn based or real-time, but this attack could also open the opponent to a combo or disable him or some of his abilities temporarily.

I believe the trick is not to undepower defense. Make other options just as good as defense, or reduce the times where defense is a good option.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.