mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-21 09:44:45 +01:00
Core/Spells: build fixes
This commit is contained in:
@@ -5780,7 +5780,7 @@ SpellCastResult Spell::CheckCasterAuras() const
|
||||
prevented_reason = SPELL_FAILED_SILENCED;
|
||||
else if (unitflag & UNIT_FLAG_PACIFIED && m_spellInfo->PreventionType == SPELL_PREVENTION_TYPE_PACIFY)
|
||||
prevented_reason = SPELL_FAILED_PACIFIED;
|
||||
else if (m_caster->HasFlag(UNIT_FIELD_FLAGS_2, UNIT_FLAG2_NO_ACTIONS) && m_spellInfo->PreventionType & SPELL_PREVENTION_TYPE_NO_ACTIONS)
|
||||
else if (m_caster->HasFlag(UNIT_FIELD_FLAGS_2, UNIT_FLAG2_NO_ACTIONS) && m_spellInfo->PreventionType == SPELL_PREVENTION_TYPE_NO_ACTIONS)
|
||||
prevented_reason = SPELL_FAILED_NO_ACTIONS;
|
||||
|
||||
// Attr must make flag drop spell totally immune from all effects
|
||||
@@ -7502,11 +7502,8 @@ void Spell::TriggerGlobalCooldown()
|
||||
m_spellInfo->HasAttribute(SPELL_ATTR0_ABILITY);
|
||||
|
||||
// Apply haste rating
|
||||
if (gcd > MIN_GCD && ((m_spellInfo->StartRecoveryCategory == 133 && !isMeleeOrRangedSpell) || m_caster->HasAuraTypeWithAffectMask(SPELL_AURA_MOD_GLOBAL_COOLDOWN_BY_HASTE, m_spellInfo)))
|
||||
if (gcd > MIN_GCD && ((m_spellInfo->StartRecoveryCategory == 133 && !isMeleeOrRangedSpell)))
|
||||
gcd = std::min<int32>(std::max<int32>(int32(float(gcd) * m_caster->GetFloatValue(UNIT_MOD_CAST_HASTE)), MIN_GCD), MAX_GCD);
|
||||
|
||||
if (gcd > MIN_GCD && m_caster->HasAuraTypeWithAffectMask(SPELL_AURA_MOD_GLOBAL_COOLDOWN_BY_HASTE_REGEN, m_spellInfo))
|
||||
gcd = std::min<int32>(std::max<int32>(int32(float(gcd) * m_caster->GetFloatValue(UNIT_FIELD_MOD_HASTE_REGEN)), MIN_GCD), MAX_GCD);
|
||||
}
|
||||
|
||||
m_caster->GetSpellHistory()->AddGlobalCooldown(m_spellInfo, gcd);
|
||||
|
||||
Reference in New Issue
Block a user