Core/Spells: CastSpell Cleanup

Port From (https://github.com/TrinityCore/TrinityCore/commit/)
This commit is contained in:
hondacrx
2021-04-18 18:42:11 -04:00
parent b1ea7212f3
commit d0faa12ef6
45 changed files with 775 additions and 632 deletions
+5 -6
View File
@@ -1412,13 +1412,12 @@ namespace Game.Entities
if (auraId == 0)
return;
CastSpellExtraArgs args = new CastSpellExtraArgs(TriggerCastFlags.FullMask);
if (auraId == 35696) // Demonic Knowledge
{
int basePoints = MathFunctions.CalculatePct(aura.GetDamage(), GetStat(Stats.Stamina) + GetStat(Stats.Intellect));
CastCustomSpell(this, auraId, basePoints, 0, 0, true);
}
else
CastSpell(this, auraId, true);
args.SpellValueOverrides.Add(SpellValueMod.BasePoint0, MathFunctions.CalculatePct(aura.GetDamage(), GetStat(Stats.Stamina) + GetStat(Stats.Intellect)));
CastSpell(this, auraId, args);
}
bool IsPetAura(Aura aura)