Core/Auras: Rename two more aura types
Port From (https://github.com/TrinityCore/TrinityCore/commit/94397ac56cf2db87c14ed39917f6de54e6ce48fb)
This commit is contained in:
@@ -164,7 +164,7 @@ namespace Framework.Constants
|
|||||||
ModRangedHaste = 140,
|
ModRangedHaste = 140,
|
||||||
Unk141 = 141, // Old ModRangedAmmoHaste, Unused Now
|
Unk141 = 141, // Old ModRangedAmmoHaste, Unused Now
|
||||||
ModBaseResistancePct = 142,
|
ModBaseResistancePct = 142,
|
||||||
ModRecoveryRate = 143, // NYI
|
ModRecoveryRateBySpellLabel = 143, // NYI
|
||||||
SafeFall = 144,
|
SafeFall = 144,
|
||||||
ModPetTalentPoints = 145,
|
ModPetTalentPoints = 145,
|
||||||
AllowTamePetType = 146,
|
AllowTamePetType = 146,
|
||||||
@@ -307,7 +307,7 @@ namespace Framework.Constants
|
|||||||
ModHealingReceived = 283, // Possibly Only For Some Spell Family Class Spells
|
ModHealingReceived = 283, // Possibly Only For Some Spell Family Class Spells
|
||||||
Linked = 284,
|
Linked = 284,
|
||||||
Linked2 = 285,
|
Linked2 = 285,
|
||||||
AbilityPeriodicCrit = 286,
|
ModRecoveryRate = 286,
|
||||||
DeflectSpells = 287,
|
DeflectSpells = 287,
|
||||||
IgnoreHitDirection = 288,
|
IgnoreHitDirection = 288,
|
||||||
PreventDurabilityLoss = 289,
|
PreventDurabilityLoss = 289,
|
||||||
|
|||||||
@@ -540,13 +540,6 @@ namespace Game.Spells
|
|||||||
GetBase().CallScriptEffectUpdatePeriodicHandlers(this);
|
GetBase().CallScriptEffectUpdatePeriodicHandlers(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool CanPeriodicTickCrit(Unit caster)
|
|
||||||
{
|
|
||||||
Cypher.Assert(caster);
|
|
||||||
|
|
||||||
return caster.HasAuraTypeWithAffectMask(AuraType.AbilityPeriodicCrit, m_spellInfo);
|
|
||||||
}
|
|
||||||
|
|
||||||
public bool IsAffectingSpell(SpellInfo spell)
|
public bool IsAffectingSpell(SpellInfo spell)
|
||||||
{
|
{
|
||||||
if (spell == null)
|
if (spell == null)
|
||||||
@@ -5461,10 +5454,7 @@ namespace Game.Spells
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool crit = false;
|
bool crit = RandomHelper.randChance(isAreaAura ? caster.GetUnitSpellCriticalChance(target, m_spellInfo, m_spellInfo.GetSchoolMask()) : m_critChance);
|
||||||
if (CanPeriodicTickCrit(caster))
|
|
||||||
crit = RandomHelper.randChance(isAreaAura ? caster.GetUnitSpellCriticalChance(target, m_spellInfo, m_spellInfo.GetSchoolMask()) : m_critChance);
|
|
||||||
|
|
||||||
if (crit)
|
if (crit)
|
||||||
damage = caster.SpellCriticalDamageBonus(m_spellInfo, damage, target);
|
damage = caster.SpellCriticalDamageBonus(m_spellInfo, damage, target);
|
||||||
|
|
||||||
@@ -5551,10 +5541,7 @@ namespace Game.Spells
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool crit = false;
|
bool crit = RandomHelper.randChance(isAreaAura ? caster.GetUnitSpellCriticalChance(target, m_spellInfo, m_spellInfo.GetSchoolMask()) : m_critChance);
|
||||||
if (CanPeriodicTickCrit(caster))
|
|
||||||
crit = RandomHelper.randChance(isAreaAura ? caster.GetUnitSpellCriticalChance(target, m_spellInfo, m_spellInfo.GetSchoolMask()) : m_critChance);
|
|
||||||
|
|
||||||
if (crit)
|
if (crit)
|
||||||
damage = caster.SpellCriticalDamageBonus(m_spellInfo, damage, target);
|
damage = caster.SpellCriticalDamageBonus(m_spellInfo, damage, target);
|
||||||
|
|
||||||
@@ -5694,10 +5681,7 @@ namespace Game.Spells
|
|||||||
damage = (int)target.SpellHealingBonusTaken(caster, GetSpellInfo(), (uint)damage, DamageEffectType.DOT, GetSpellEffectInfo(), GetBase().GetStackAmount());
|
damage = (int)target.SpellHealingBonusTaken(caster, GetSpellInfo(), (uint)damage, DamageEffectType.DOT, GetSpellEffectInfo(), GetBase().GetStackAmount());
|
||||||
}
|
}
|
||||||
|
|
||||||
bool crit = false;
|
bool crit = RandomHelper.randChance(isAreaAura ? caster.GetUnitSpellCriticalChance(target, m_spellInfo, m_spellInfo.GetSchoolMask()) : m_critChance);
|
||||||
if (CanPeriodicTickCrit(caster))
|
|
||||||
crit = RandomHelper.randChance(isAreaAura ? caster.GetUnitSpellCriticalChance(target, m_spellInfo, m_spellInfo.GetSchoolMask()) : m_critChance);
|
|
||||||
|
|
||||||
if (crit)
|
if (crit)
|
||||||
damage = caster.SpellCriticalHealingBonus(m_spellInfo, damage, target);
|
damage = caster.SpellCriticalHealingBonus(m_spellInfo, damage, target);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user