Damage Calculation

Been a while now. Work was a bit much these weeks…

Well, let’s go step by step. I still don’t have it all figured out, but progress is progress (isn’t there a meme for that?) :slight_smile:

First, let’s take a look at the minion damage:
I got more data with Noor and finally got Freya.

Attacker minion damage
Here’s the attacker minion’s damage without any buffs, only elemental bonus and crit:
grafik

I got some data on the tiebreaker damage bonus (up to 220%DMG at turn 42). The data doesn’t fit well, if I simply add the damage bonus to the elemental bonus and crit, but it does so relatively well, if I add it multiplicatively.
grafik
I re-checked these low points twice now. They are outliers, but they are correct, with the 220%damage bonus.

I just realized that I haven’t gotten much data for Freya’s minion attack buff:
grafik
There seems to be an upward bent starting at an attack/defense ratio of around 1.5

The druid minions continue to fit very well with 15% attack.
grafik
Here’s how they would like with 14% attack grafik
and with 16% attack
grafik

=> druid minions get 15% attack, just like they get 15% HP

Now, the defense debuffs push the curve even further, but they do not fit as perfectly as the other points and I haven’t found out why.
Here’s the curve with only a defense debuff or only an elemental defense debuff:
grafik
and with the data on combined defense debuffs:
grafik
This doesn’t look right. The points with both defense debuffs are shifted to higher ratios.
They align much better, if I reduce the elemental defense debuff to 65% for only these points with both debuffs:
grafik

The linear trend curve is then approx. 74.5 x attack/defense ratio
grafik

Defender minion damage
For the defender minions the situation looks similar, although I have much less data for them.

unbuffed minion damage
grafik

now adding Freya’s attack buff
grafik

druid minion with 15% attack
grafik

a few defense buffs of +30% (from my Kiril)
grafik

Now, as we already know, the defender gets some bonus and does more damage.
grafik

how much?
Applying 20% attack bonus for the defender leads to this
grafik

When playing around with the attack bonus and the damage bonus for the defender I get the best fit with something like 30% damage bonus for the defender:
grafik

If we can keep a linear formula, the above results would suggest the damage formula for minion damage to be roughly:
minion damage = 74.5 x attack / defense x damage modifier

  • attack = caster‘s ATK x caster‘s troop ATK bonus x caster‘s minion ATK % x (1 + minion ATK buff)
  • defense = target‘s DEF x target‘s troop DEF bonus x (1+ DEF buff/debuff) x (1+elemental DEF buff/debuff x elemental defense debuff limiter)
  • damage_ modifier = (1+ elemental bonus + critical bonus) x (1 + tie breaker %) x (1 + defender bonus)
  • elemental defense debuff limiter = 0.65, if both defense debuffs apply, otherwise it’s 1
  • defender bonus = 30%
9 Likes

Let’s continue with tile damage.

On one hand, because I have the most data on tile damage. On the other hand, because the complete set of tile damage, slash damage, specials and enemy specials was a mess and so I separated each data set to see what’s going on. (this was the right choice as they have different curves and formulas, but are still similar)
It adds to the confusion that here and there a strange data point appears, that survives quality checks. Well, I’m including those in my diagrams anyway. It’s the overall picture that is important for understanding how things work.

Here is the pure tile damage with only elemental bonus and crit bonus:
grafik

If I add the corresponding curve for the current damage formula:
grafik
Range of 0-5:
grafik
looks good in the range of 0-4.

Combos are added to the damage modifier just like the elemental bonus and crits:
grafik
damage modifier = elemental bonus + crit + combo

As is already known, the attack buffs and debuffs are multiplied with the corresponding attack values
grafik
total attack = hero1 attack stat x (1 + troop attack bonus) x (1 + attack buff/debuff) + hero2 attack stat x …

Wu (and Ranvir for sure as well) gets added as additional damage (NOT attack!)
This is my Wu data when his buff is not applied anywhere yet:
grafik
This shows Wu’s buff applied as an additional attack buff
grafik
and this is his buff when applied as damage multiplier:
grafik
Wu’s buff applying to damage explains why it works with normal attack buffs/debuffs without overwriting.

It also explains why Wu is so effective with tile damage, especially against titans.

There is also Tarlak and Miki that are superior to Wu (due to his misses). As we know, they work with attack buffs/debuffs but they do not work with Wu.
Since I don’t own Tarlak or Miki, I have very little tile damage data on them - only the few data points from an alliance member that tested for me the combined buffs of Tarlak+Wu and Miki+Wu.

Here is how this combination looks like, if I use Miki and Tarlak as a normal attack buff and Wu as damage buff:
grafik

According to their card description they stack with similar effects to a maximum of 160% (Tarlak) and 170% (Miki), respectively. If I apply their buffs as damage buffs and use limits to the damage buff, I get the following:
grafik
This looks good and much better than applying Miki and Tarlak as normal attack buffs.
=> I would say, that Miki and Tarlak are most probably damage buffers (just like Wu)

This would also suggest that it makes absolutely no sense to use Wu with Miki or Tarlak as you end up with the miss chance and a damage buff that is lower than Wu’s buff.

Now, I would like to add the data for the defense buffs/debuffs, but the data is inconsistent so far. There seems to be some kind of limiter at work sometimes and I haven’t figured out when exactly. In any case, my data suggests that this limiter is in the range of 75%-100%, but may apply for both, normal defense debuffs and elemental debuffs. I will collect more data and see, if I can make any sense out of it.

5 Likes

Next stop: special attacks

As is already known, the attack power for the damage calculation is applied as
hero’s attack x (1 + troop attack bonus) x special power
Without taking the troop into consideration a maxed Bane has an attack power of
1407 = 469 ATK x 300%

Here is the pure special damage.
grafik
The curve looks very similar to the one for the tile damage.

Minor damage is calculated as -50%damage
grafik

The attack buff came as a surprise.
Here’s the curve for attack buffs (not debuffs) applied multiplicatively:
hero’s attack x troop attack bonus x (1 + attack buff) x special power
grafik
The data points are too far to the right, the attack power is calculated too high.

Now, if the attack buff is simply added to the special power, things look better:
hero’s attack x troop attack bonus x (attack buff + special power)
grafik

The other surprise here was the attack debuff. Here are my data points for those cases:
grafik

And when I switch those points for attack debuffs back to the initial application (multiplicatively):
grafik
Looks a lot better!
=> That means that attack buffs and attack debuffs are applied differently in the special damage formula, and the attack debuff is much more effective.

Now, Wu also was a surprise. If I apply his buff as a damage boost like for the tiles:
grafik

If I apply Wu’s buff multiplicatively as an attack boost:
grafik

But when I add his buff to the special power like an attack buff:
grafik
Not perfect, but looks good enough for me.

=> This would explain why Wu is so effective for tile damage but not as helpful for specials
=> Weak specials should get the most out of Wu’s buff

The relation between the tile damage curve and the special damage curve is also interesting. Initially the special curve is lower than the tile curve:
grafik

When I try to align the two curves, I get a seemingly very good fit when I apply a damage reduction for the special damage curve and reduce it to 85%:
grafik
Same curve with tile data on top
grafik
=> that would mean that the same formula applies for tile damage and special damage, but the buffs and debuffs are applied differently and special damage is reduced to approx. 85%

3 Likes

Correct, this is proving previous hyphotesis. Thanks for the analysis.

1 Like

Here’s something for the special attacks and the defense debuffs:

First, the data without adjustments (defense debuffs apply with 100%) for defense debuff, elemental defense debuff and both defense buffs:
grafik
looks like the defense is reduced too much.

grafik
looks like the defense is reduced too much, again.

grafik
Defense is reduced way too much here.

By playing around with limiters on the defense debuffs, I get very good results with approx. 85% for the defense debuff, approx. 85% for the elemental defense debuff, and, in case of both defense buffs applying, 75% for the elemental defense debuff:
grafik

grafik

grafik

Whatever the actual limiters are, imho they shouldn’t be too far off from these values.

Another interesting topic is hidden bonuses. As a 5* Zocc has found his way into some of the raid defense teams and therefore allows to check, if hitting your own team members produces different damage.
grafik
I can play around with attack and/or defense bonuses for the attacker, but only +10%attack would look reasonable enough to make a (weak) case.
grafik
Well, so far I haven’t seen anybody arguing in this direction, so
=> I don’t see any bonuses (or debuffs) for the attacker

2 Likes

Could you test something for me ? I actually interest in damage calculation but I can’t test it because my alliance member don’t want to do it.

The first thing I want to test is tile damage in normal condition without buff, debuff, cascade bonus, and elemental effect against fixed defense target.

  • Use target with 800 total defense (can be other number)
  • Use attack hero with (lowest attack you can make)…,500,600,700,…(highest attack you can make).
  • About 10 data per attack value.
  • Graph will be attack (x-axis) vs damage (y-axis)

What exactly are you looking for?

Two possible situations come to mind for fixing the defender’s defense:
(1) fighting the bosses of a common mission, like those from 8-7 (assuming that their defense doesn’t really change from battle to battle)
(2) fighting an alliance member

Only for situation 2 the exact defense of the defender is known, but you only get 5 attacks per day.

The possible attack values will be in the range of approx 181 to 1100. For a defense of 800 this will then mean an attack/defense ratio range of 0,225-1,375, unless you include colour stacking.

Work will start for me on Monday again, and I expect that I’ll have little time to work on my data collection, so maybe your point can be answered with my already existing data?

The result can be expected to be similar to my tile curve above. I can limit my tile data on those points that have no buffs and debuffs, no crit, no elemental bonus:
grafik

grafik

grafik
The two outliers at the beginning of the curve survive a quality check, but feel free to ignore them.

The curve has 3 parts. first a straight line until approx. 0.85, then a “s” shaped part, until approx. 5, and then a straight line again

1 Like

Next: enemy specials

The curve for the enemy specials looks different. Here are the pure enemy specials without buffs:
grafik
At approx 7 something happens.

Minor damage (= -50% damage) and elemental extra damage:
grafik

For the attack buffs and debuffs the situation is the same as for the specials. The attack buff is added to the special power, while the attack debuff is applied multiplicatively, and therefore is more effective:
grafik

Unfortunately, I have just 2 data points for Wu since nearly nobody uses Wu in the defense.
grafik
Nevertheless, the two points fit in very well when I add Wu’s buff to the special power, like for the specials.

When we compare the enemy special damage with tile damage
grafik

grafik
the enemy special clearly gets a considerable damage boost.

I get a very good fit, if I apply a damage boost of 1.2 until approx. an attack/defense ratio of 7:
grafik
here with tiles on top
grafik
but beyond 7 the damage boost is obviously smaller
grafik
so I apply 1.1 for this range and get a good fit:
grafik
and with tiles on top
grafik

This suggests that
=> enemy specials get a damage boost of approx. 1.2 for the important range of attack/defense ratios of approx. 0-7
=> enemy specials get a damage boost of approx. 1.1 for an attack/defense ratio of approx. 7 and higher
=> when compared to specials, which get a damage reduction to approx. 85%, the damage of enemy specials is approx. 40% (= 1.2/0.85) higher in the important attack/defense range of 0-7
=> even in the attack/defense range of >7 the damage of enemy specials is approx. 30% (= 1.1/0.85) higher than the damage from attacker specials

Now, I wonder, if there will be a future hero that steals the hidden enemy buffs :thinking: :sweat_smile:

1 Like

I am looking for the more accurate formula for any damage calculation. From my 3 years experience, I never see any damage that have more than ±5% range. The damage is very stable. But I can be wrong, so I want to see how it is by using only some specific attack value.

The reason why I want attack (x-axis) vs damage (y-axis) graph is because I think it is easy for other people to understand. If you find the new better formula, maybe you can post it as new topic.

Thank you for your graph, I think it can answer about 80% of my question. I don’t what is the formula of your adjust damage ? Can you fit lower limit, upper limit, average of each linear ?

Well, I can accumulate some additional data for a single target to confirm. I just cannot guarantee how fast I’ll be with it as it takes time and is tedious to do correctly (and work is a bit stressful these days).

The damage adjustment is simply the correction for any damage modifiers to kind of “normalize” the data, make it comparable. The basis is indeed pure neutral tile damage (from all 3 tiles) without buffs, debuffs, crit, elemental bonuses, etc.
When such factors get removed correctly the corresponding curve will match the pure neutral curve perfectly.

So far we know that the damage formula uses (1) the ratio of attack to defense, (2) throws it into a function to calculate a corresponding damage value,and (3) then applies damage modifiers.
This is the state of knowledge, at least since the first post of this thread.

Initially,
a) the function is assumed to be exponential with 1.35 as the exponent for the attack/defense ratio
b) the damage formula is assumed to be the same for each attack type (tile, slash, special, enemy special)
c) the defender is assumed to get a +20% bonus on attack and defense

I’ve collected and analysed some data and found it confusing as it didn’t fit that well with all of these assumptions. Only after collecting more data and analysing the data on each attack type separately I could make more sense out of it.

Assumption a) is clearly wrong, but it is a function that you can easily work with and it seems to do well in the range of 0-4. I’ve suggested a combination of a straight line and a Gompertz function before in this thread. Post309
Assumption b) is clearly wrong, though it looks like you can align the curves by correctly applying the buffs, debuffs and damage modifiers.
Assumption c) might be wrong. The analysis of the specials and enemy specials suggests that the defender doesn’t get such bonuses. Instead, the defender gets a considerable damage increase

The general formula starts as
damage = function_to_be_found (total_attack / defense) x damage_modifier

for tile damage the damage modifier is
damage_modifier = 100/3 x (1 + colour_bonus + critical_hit_bonus + tile_combo) x (1 + Wu) x tiebreaker_bonus

My suggested function is something like this:
function_to_be_found = 350 x exp( -9 x exp( -1 x ADR)) + 80 x ADR

ADR = attack/defense ratio

And when the first part is multiplied with 0.6 or 1.4 the boundaries look suitable
function_to_be_found = 0.6 x 350 x exp( -9 x exp( -1 x ADR)) + 80 x ADR
function_to_be_found = 1.4 x 350 x exp( -9 x exp( -1 x ADR)) + 80 x ADR

This then looks as follows:


Great for higher values, not so great for the lower range of 0-1.
Also, much more complicated than the simple exponential function, but maybe a bit better:

As you can see from the formula, the second straight line has an inclination of approx. 80 (boundaries are approx. ±100).
grafik
The inclination of the first straight line is only 75 (boundaries are approx. ±5):
grafik
This messes up my “simple” Gompertz function.

I can make a slightly improved fit with an offset of -5:
formula_to_be_found = 350 x exp( -9 x exp( -0.9 x ADR)) + 80 x ADR -5

So the formula would be:
damage = [350 x exp{ -9 x exp( -1 x ADR)} + 80 x ADR] x damage_modifier

ADR = attack/defense ratio
damage_modifier = 100/3 x (1 + colour_bonus + critical_hit_bonus + tile_combo) x (1 + Wu) x tiebreaker_bonus

A simpler formula would be highly appreciated, though :smiley:

1 Like

I ran 5 raids against an alliance teammate just to see for myself how the damage calc works for tiles on raids. The defense was rainbow 3*s, my defense was mono green and included Tarlak and Almur. I included troop buffs and made sure to monitor for all buffs that would affect the damage calc. The formula I used was as follows:

33*((attack/defense)^1.35)) with the result multiplied by 0.5/1/2 based on tile strength.

I specifically chose to attack a 3* defense with mono attack because tile damage can be calculated for high attack to low defense ratio before any attack or defense specials are applied.

In a critical damage thread, a reference is made that the game selects individual heroes to test for crit damage on each tile. This seems logical, so I wanted to see how each hero’s attack “could” affect the calculated damage, if each tile is assigned to a specific hero. I made a reference table that calculated damage based on the total attack, and also a hero specific weighting based on individual attack divided by the average attack. (for example: Tarlak attack was 1022, average attack for mono green was 912, so 1022/912 ≈ 1.12). I multiplied the final tile damage with the hero specific weighting to give me an expected range of tile damage across all 5 offensive heroes.

I attacked without specials, using Almur’s special, Tarlak’s special, and a combo of both Almur/Tarlak.

My observations:

  • The damage calc held up closely for attack:defense ≈ 6 or less.
  • Weighting each hero’s attack gave a fairly close range to the results, but not good enough to be conclusive.
    -Tarlak’s attack buff did not seem to stack with elemental defense down.
    -Once a hero with elemental defense down dies, the ailment is removed and remaining tiles “hit” with Tarlak’s buff (if applied) or for expected damage if no buff. False damage tiles, and I’ll try to post a screenshot.

My conclusions:

  • A lot of people have put in some really good work on figuring out the damage calc, and we still have more to uncover.
  • Data collection could be a source of error, if heroes die, ailments are removed, but “false” damage tiles are displayed.
  • Feedback is appreciated.

Have you recorded videos of these battles and recorded the data? This would allow you to check the damage situation again whenever you want and to show the data in the form of similar diagrams like the ones in the posts above. I like to check my recorded videos when I encounter some outliers in my data.

To allow you to calculate damage with the hero specific weighting, how did know which hero attacked? Did you give 5 different looking troops to these 5 green heroes and ?

One could argue that all damage modifiers belong to the hitting tile: colour bonus, crit bonus, combo bonus, Wu/Ranvir/Miki/Tarlak, tiebreaker bonus

From my limited data in this regard I would expect Tarlak to provide 100% multiplicatively to the damage modifier, like Wu does with his 185%.

That is also my experience. The target loses all buffs and debuffs after the killing tile, and any further tiles hit only with the buffs/debuffs from the attacker. It is confusing at first, though.

I did record the videos. I did check everything twice, but another look in the morning with fresh eyes may reveal an error.

I don’t know which hero attacked. In a way it gives me reasonability limits to determine if hits are following the damage calc. I did screen shot a 4 tile combo showing the false damage tiles for 340 and 348 (I did see in your post that you’ve seen this also.

Here’s an example of the hero weighted damage for green mono attack (no buffs/no ailments) against defense Hawkmoon.

Hawkmoon - +troop and raid def bonus - 765.
Sum of mono green atk - +troop bonus- 4560 (912 avg).
Average calculated 0.5 tile damage - 184

Reasonable 0.5 tile damage if weighted ( calc damage * 1022/912 Tarlak atk example):
Tarlak - 206
cMel - 189
cKad - 177
Lianna - 181
Almur - 167

In the screenshot above the last two hits (340 & 348) are below low-end Tarlak buffed damage. If Tarlak’s atk buff applied to all heroes, the first two hits (550 & 520) would have been in ballpark 1300 range with elemental def down ailment. I’m still thinking of why Tarlak + Almur don’t appear to work together, yet Tarlak’s buff alone is reasonable.

Cookie Settings