[Rogue][Talent] Improved sap
https://www.getmangos.eu/issue.php?issueid=283
This commit is contained in:
parent
4ed15a6670
commit
e18cdf6f96
@ -2569,6 +2569,10 @@ void Spell::prepare(SpellCastTargets const* targets, Aura* triggeredByAura)
|
||||
// skip triggered spell (item equip spell casting and other not explicit character casts/item uses)
|
||||
if (!m_IsTriggeredSpell && isSpellBreakStealth(m_spellInfo))
|
||||
{
|
||||
// Sap - don't exit Stealth yet to prevent getting in combat and making Sap impossible to cast
|
||||
// Removing Stealth depends on talent later
|
||||
// Pick Pocket - don't exit Stealth at all
|
||||
if (!(m_spellInfo->SpellFamilyName == SPELLFAMILY_ROGUE && (m_spellInfo->SpellFamilyFlags & UI64LIT(0x00000080) || m_spellInfo->SpellFamilyFlags & 2147483648)))
|
||||
m_caster->RemoveSpellsCausingAura(SPELL_AURA_MOD_STEALTH);
|
||||
m_caster->RemoveSpellsCausingAura(SPELL_AURA_FEIGN_DEATH);
|
||||
}
|
||||
@ -2713,6 +2717,12 @@ void Spell::cast(bool skipCheck)
|
||||
{ AddPrecastSpell(25771); } // Forbearance
|
||||
break;
|
||||
}
|
||||
case SPELLFAMILY_ROGUE:
|
||||
{
|
||||
// exit stealth on sap when improved sap is not skilled
|
||||
if (m_spellInfo->SpellFamilyFlags & UI64LIT(0x00000080) && m_caster->GetTypeId() == TYPEID_PLAYER && (!m_caster->GetAura(14076, SpellEffectIndex(0)) && !m_caster->GetAura(14094, SpellEffectIndex(0)) && !m_caster->GetAura(14095, SpellEffectIndex(0))))
|
||||
m_caster->RemoveSpellsCausingAura(SPELL_AURA_MOD_STEALTH);
|
||||
}
|
||||
case SPELLFAMILY_WARRIOR:
|
||||
break;
|
||||
case SPELLFAMILY_PRIEST:
|
||||
|
@ -310,7 +310,14 @@ bool Unit::IsTriggeredAtSpellProcEvent(Unit* pVictim, SpellAuraHolder* holder, S
|
||||
modOwner->ApplySpellMod(spellProto->Id, SPELLMOD_CHANCE_OF_SUCCESS, chance);
|
||||
}
|
||||
|
||||
return roll_chance_f(chance);
|
||||
if (!roll_chance_f(chance))
|
||||
{
|
||||
// Break stealth on sap if improved sap doesnt proc
|
||||
if ((procSpell && procSpell->SpellIconID == 249 && procSpell->SpellVisual == 257) && (spellProto->SpellFamilyName == SPELLFAMILY_ROGUE && spellProto->SpellIconID == 249 && spellProto->SpellVisual == 0))
|
||||
RemoveSpellsCausingAura(SPELL_AURA_MOD_STEALTH);
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
SpellAuraProcResult Unit::HandleHasteAuraProc(Unit* pVictim, uint32 damage, Aura* triggeredByAura, SpellEntry const* /*procSpell*/, uint32 /*procFlag*/, uint32 /*procEx*/, uint32 cooldown)
|
||||
|
Loading…
x
Reference in New Issue
Block a user