Core/Creatures: Move creature difficulty specific data from creature_template table to creature_template_difficulty (#28931)

This commit is contained in:
Meji
2023-05-29 00:01:23 +02:00
committed by GitHub
parent 526b16fea4
commit 06d0b16f15
30 changed files with 95916 additions and 549 deletions
+1 -1
View File
@@ -1034,7 +1034,7 @@ void Creature::CalculateMinMaxDamage(WeaponAttackType attType, bool normalized,
float basePct = GetPctModifierValue(unitMod, BASE_PCT) * attackSpeedMulti;
float totalValue = GetFlatModifierValue(unitMod, TOTAL_VALUE);
float totalPct = addTotalPct ? GetPctModifierValue(unitMod, TOTAL_PCT) : 1.0f;
float dmgMultiplier = GetCreatureTemplate()->ModDamage; // = ModDamage * _GetDamageMod(rank);
float dmgMultiplier = GetCreatureDifficulty()->DamageModifier; // = DamageModifier * _GetDamageMod(rank);
minDamage = ((weaponMinDamage + baseValue) * dmgMultiplier * basePct + totalValue) * totalPct;
maxDamage = ((weaponMaxDamage + baseValue) * dmgMultiplier * basePct + totalValue) * totalPct;