CombatDamage

From Super Snail Wiki
Jump to navigation Jump to search

Combat Damage

The purpose of this page is to provide more details about how damage is actually calculated when it comes to combat. The data on this page is not 100% accurate, but provides a good foundation for a more in-depth understanding of how combat damage is calculated.

📝 Note: Some of the statements on this page are opinionated, but considered to be generally true (such as stat priority). They may not be true for all situations.



What is not taken into account in the calculations on this page?

Some combat bonuses that come from Gear, Avatar Score bonuses, relics, etc. These are typically buffs that apply only in specific scenarios, such as in Explorations, only in the First round, etc.

Examples of buffs missing from calculations on this page:

  1. Combat Damage for battles in the Fissure will not take into account the bonuses given by the Home Facilities Avatar Buff.
  2. If you have Golden Drazgul Fang, calculations below do not account for the bonus CRIT DMG in Round 1 given by this gear.

Combat Stats

The main combat stats are your HARD stats (HP, ATK, RUSH, and DEF) as well as your ELMT Stats (ELMT DMG and ELMT RES).

> RES = Resistance
> DMG = Damage
Note: For elements (ex: Fire DMG) it is a stat that you accumulate; however when referred to as DMG, ATK DMG, RUSH DMG, CRIT DMG or Total DMG it refers to a value calculated from your stats.
Ranked Combat Stats
Priority Combat Stat What it does
1 Fire DMG
Water DMG
Earth DMG
Wind DMG
Poison DMG
Contributes to Total DMG for both regular and RUSH attacks.

FREQUENTLY ASKED QUESTION
Question: Why is ELMT DMG considered the "best" stat?
Answer: ELMT DMG applies to standard attacks and RUSH attacks. The final damage also scales with the ATK or RUSH stat. In non-PvP battles, opponenets do not have ELMT RES.



2 ATK Primary contributor to Total DMG in your first attack. It is always useful and generally your main source of damage.
3 DEF Primary stat for decreasing DMG taken from enemy attacks.

FREQUENTLY ASKED QUESTION
Question: Why is DEF better than HP?
Answer: 1 DEF will save you 1 HP for each round you are alive. So if you last the full 20 rounds in a battle, each point of DEF is worth 20 HP. Also



4 RUSH Primary contributor to Total DMG in your second attack per round (assuming you spotted the enemy's weakness).

FREQUENTLY ASKED QUESTION
Question: Why is RUSH not as good as DEF?
Answer: If you haven't spotted the enemy's weakness this stat does not contribute anything to the battle.
Also, the Total RUSH DMG done in a single round of combat is almost always primarily comes from ELMT DMG, not RUSH DMG.



5 HP Increases total Hit Points.
6 Fire RES
Water RES
Earth RES
Wind RES
Poison RES
Reduces the amount of elemental DMG taken when an enemy attacks you.

FREQUENTLY ASKED QUESTION
Question: Why is ELMT RES the "worst" stat?
Answer: Enemies in explorations, fissure, mirages, mailbox, etc do not have any Elemental Damage stats. Meaning this stat is really only useful in PvP battles.



ATK Damage (First Attack)

ATK Damage is done every round, regardless of if you spot an enemy's weakness. The actual DMG done in the attack is based a combination of ATK DMG and ELMT DMG. Your ATK stat will scale the amount of ELMT DMG you do during your first attack.

The high level formula for your first round of attack is:

TOTAL DMG = ATK DMG + CRIT DMG + ELMT DMG

For a detailed breakdown of how to calculate TOTAL DMG, see Total ATK or RUSH DMG Calculation

RUSH Damage (Second Attack)

Fun Fact:
The translation of "rush" from the original Chinese game text would be better translated as "pursuit" in english (according to google translate). This is why a "rush" attack is actually the second attack and not an attack that happens before the main attack as you might assume from the name.

Presumably it was translated as "rush" instead of "pursuit" to make the stats acronym "HARD" more memorable -- but this is pure conjecture.

Note: The majority of the TOTAL DMG in the second attack typically comes from ELMT DMG. This is because your RUSH stat is generally significantly less than your ATK stat, but the the enemy's DEF stat applies to RUSH as well.

RUSH Damage is only done if you spot an enemy's weakness. The actual DMG done in the attack is based a combination of RUSH DMG and ELMT DMG. Your RUSH stat will scale the amount of ELMT DMG you do during your second attack.

The high level formula for your second attack in a single round is:

TOTAL DMG = RUSH DMG + CRIT DMG + ELMT DMG

For a detailed breakdown of how to calculate TOTAL DMG, see Total ATK or RUSH DMG Calculation

Elemental Damage

Credit for all Elemental Damage calculations goes to the article Strategy: Use mathematics to teach you how to deal with elemental damage [1] by Li Ruosheng [2]

For most player in mid to late game, 1 point of ELMT DMG can be assumed to be equivalent to about 7 ATK. Because ELMT DMG is also calculated for RUSH attacks, each point is more useful than ATK. For Non-PvP battles, opponents also DO NOT have any ELMT RES.

Elemental Damage scales with either the attacker's ATK stat or RUSH stat depending on if the calculation is for a regular attack or a rush attack. As your ATK and/or RUSH stats grow, the amount of additional damage done for each ELMT DMG point increases at a slower and slower rate (logarithmic scale). At approximately 80,000 ATK or RUSH each point of ELMT DMG equates to about 7 DMG (not accounting for resistances). Each ELMT DMG point equates to about 8 DMG once your ATK or RUSH reach between 390,000 and 400,000. (See the table below for a breakdown of how ELMT DMG scales)

For a detailed breakdown of how to calculate TOTAL DMG, see Elemental Damage Calculation
For a quick-reference table to see how ELMT DMG scales at a glance, see Elemental DMG Scaling Reference Table

Appendix

Glossary

Sometimes it can get confusing when you read a statement about a stat such as ELMT DMG. Is this the final damage after scaling? Is this the sum of the raw elemental DMG stats?

To clear this confusion (at least for this page), here is the glossary for the values used on this page:

Caption text
STAT / Calculation Formula / Calculation Description
ELMT DMG Fire DMG + Water DMG + Earth DMG + Wind DMG + Poison DMG The sum of all the RAW Element DMG stats.
Total ELMT DMG ELMT DMG * Math.log(<atkOrRush>) / Math.log(5) The scaled final number for Elemental DMG for an attack.

Formulas / Calculations

Total ATK or RUSH DMG Calculation

The same general formula is used for RUSH, just switch out values such as attacker.ATK for attacker.RUSH, and the formula is the same.

// Note: Round number in this formula is 1 based, meaning it goes from 1-20 (not 0-19 as programmers may assume)
function calculateAttackDamage(attacker: Combatant, defender: Combatant, roundNumber: number, crit: boolean) {

  const attackerAdjustedATK = (
    attacker.ATK 
    + attacker.combatbuff.beforeCombat.ATK 
    + (roundNumber * attacker.buffEachRound.ATK)
  );

  const defenderAdjustedDEF = (defender.DEF * (1 - attacker.effectsTowardsEnemy.ignoreDEF))

  // Note: The minimum value for rawAtkDmg is 5% of adjusted ATK 

  const rawAtkDmg = Math.max(
    attackerAdjustedATK - defenderAdjustedDEF,
    attackerAdjustedATK * 0.05
  );

  // Note: Negative Element Resistances are not allowed.

  const elementalDmg = calculateElementalDamage(attacker, defender, rawAtkDmg)
  
  let dmgMultiplier = 1 + attacker.effectsTowardsEnemy.DMG

  if (roundNumber === 1) {
    dmgMultiplier = dmgMultiplier + attacker.buffEachRound.roundOneDMG
  }

  const critMultiplier = (0.5 + attacker.enhanceSelf.critDMG) * (1 - defender.enhanceSelf.critDmgReduc)

  let critDmg = 0
  
  if (crit) {
    critDmg = rawAtkDmg * critMultiplier
  }
  
  return (rawAtkDmg * dmgMultiplier + elementalDamage) * (1 - defender.enhanceSelf.dmgReduc) + critDmg
}

Elemental Damage Calculation

This is pseudo-code for elemental damage calculation:

function calculateElementalDamage(attacker: Combatant, defender: Combatant, atkOrRush: number) {

  // Note: Negative Element Resistances are not allowed, so default to 0
  // if the attacker has higher ignore RES than the defender's RES.
  
  const fireDmg = attacker.elmtDMG.fire - Math.max(
    defender.elmtRES.fire - attacker.effectsTowardsEnemy.ignoreElmtRES.fire,
    0
  );

  const earthDmg = attacker.elmtDMG.earth - Math.max(
    defender.elmtRES.earth - attacker.effectsTowardsEnemy.ignoreElmtRES.earth,
    0
  );

  const waterDmg = attacker.elmtDMG.water - Math.max(
    defender.elmtRES.water - attacker.effectsTowardsEnemy.ignoreElmtRES.water,
    0
  );

  const windDmg = attacker.elmtDMG.earth - Math.max(
    defender.elmtRES.wind - attacker.effectsTowardsEnemy.ignoreElmtRES.wind,
    0
  );

  const poisonDmg = attacker.elmtDMG.earth - Math.max(
    defender.elmtRES.poison - attacker.effectsTowardsEnemy.ignoreElmtRES.poison,
    0
  );

  const elemDmg = fireDmg + waterDmg + earthDmg + windDmg + poisonDmg;

  return elemDmg * Math.log(atkOrRush) / Math.log(5);
}

Elemental DMG Scaling Reference Table

How do I read this table?

Example:
Assume you are trying to estimate the total elemental damage you will do if you have 101,000 ATK, and 2,500 total ELMT DMG (Fire DMG + Water DMG + Earth DMG + Wind DMG + Poison DMG) for your first attack (not the RUSH attack).

  1. Lookup the ATK value in the table closest to your ATK
    1. In this case, you would go to the row for 100,000 ATK or RUSH
  2. Multiply your total ELMT DMG (2,500) by the value in the second column (7.153) to get your estimate for Total ELMT DMG in your first attack:
    1. Total ELMT DMG = 2500 * 7.152 = 17,880
ELMT DMG Scaling Reference Table
(Not taking into account ELMT RES)
ATK or RUSH DMG from
One ELMT DMG point
DMG from
One Thousand ELMT DMG points
0 0 00
10,000 5.723 5,722.706
20,000 6.153 6,153.383
30,000 6.405 6,405.312
40,000 6.584 6,584.059
50,000 6.723 6,722.706
60,000 6.836 6,835.989
70,000 6.932 6,931.768
80,000 7.015 7,014.736
90,000 7.088 7,087.919
100,000 7.153 7,153.383
110,000 7.213 7,212.602
120,000 7.267 7,266.666
130,000 7.316 7,316.399
140,000 7.362 7,362.445
150,000 7.405 7,405.312
160,000 7.445 7,445.412
170,000 7.483 7,483.081
180,000 7.519 7,518.595
190,000 7.552 7,552.189
200,000 7.584 7,584.059
210,000 7.614 7,614.374
220,000 7.643 7,643.279
230,000 7.671 7,670.898
240,000 7.697 7,697.342
250,000 7.723 7,722.706
260,000 7.747 7,747.075
270,000 7.771 7,770.525
280,000 7.793 7,793.121
290,000 7.815 7,814.925
300,000 7.836 7,835.989
310,000 7.856 7,856.362
320,000 7.876 7,876.089
330,000 7.895 7,895.209
340,000 7.914 7,913.757
350,000 7.932 7,931.768
360,000 7.949 7,949.272
370,000 7.966 7,966.296
380,000 7.983 7,982.866
390,000 7.999 7,999.005
400,000 8.015 8,014.736
410,000 8.03 8,030.078
420,000 8.045 8,045.051
430,000 8.06 8,059.671
440,000 8.074 8,073.955
450,000 8.088 8,087.919
460,000 8.102 8,101.575
470,000 8.115 8,114.937
480,000 8.128 8,128.019
490,000 8.141 8,140.83
500,000 8.153 8,153.383
510,000 8.166 8,165.687
520,000 8.178 8,177.752
530,000 8.19 8,189.587
540,000 8.201 8,201.201
550,000 8.213 8,212.602
560,000 8.224 8,223.798
570,000 8.235 8,234.795
580,000 8.246 8,245.601
590,000 8.256 8,256.223
600,000 8.267 8,266.666
610,000 8.277 8,276.936
620,000 8.287 8,287.039
630,000 8.297 8,296.981
640,000 8.307 8,306.766
650,000 8.316 8,316.399
660,000 8.326 8,325.885
670,000 8.335 8,335.229
680,000 8.344 8,344.434
690,000 8.354 8,353.505
700,000 8.362 8,362.445
710,000 8.371 8,371.258
720,000 8.38 8,379.948
730,000 8.389 8,388.519
740,000 8.397 8,396.972
750,000 8.405 8,405.312
760,000 8.414 8,413.542
770,000 8.422 8,421.664
780,000 8.43 8,429.682
790,000 8.438 8,437.597
800,000 8.445 8,445.412
810,000 8.453 8,453.131
820,000 8.461 8,460.755
830,000 8.468 8,468.286
840,000 8.476 8,475.727
850,000 8.483 8,483.081
860,000 8.49 8,490.348
870,000 8.498 8,497.531
880,000 8.505 8,504.632
890,000 8.512 8,511.653
900,000 8.519 8,518.595
910,000 8.525 8,525.461
920,000 8.532 8,532.251
930,000 8.539 8,538.969
940,000 8.546 8,545.614
950,000 8.552 8,552.189
960,000 8.559 8,558.695
970,000 8.565 8,565.134
980,000 8.572 8,571.507
990,000 8.578 8,577.815
1,000,000 8.584 8,584.059

Content References