mirror of
https://github.com/mangosfour/server.git
synced 2025-12-16 04:37:00 +00:00
[8357] Use less hacky Spell::AddTriggeredSpell call for spell 33076 and ranks jump animation cast
This commit is contained in:
parent
d35eecf175
commit
0bbc496192
5 changed files with 8 additions and 13 deletions
|
|
@ -2378,6 +2378,9 @@ void Spell::cast(bool skipCheck)
|
||||||
if (m_spellInfo->Mechanic == MECHANIC_SHIELD &&
|
if (m_spellInfo->Mechanic == MECHANIC_SHIELD &&
|
||||||
(m_spellInfo->SpellFamilyFlags & UI64LIT(0x0000000000000001)))
|
(m_spellInfo->SpellFamilyFlags & UI64LIT(0x0000000000000001)))
|
||||||
AddPrecastSpell(6788); // Weakened Soul
|
AddPrecastSpell(6788); // Weakened Soul
|
||||||
|
// Prayer of Mending (jump animation), we need formal caster instead original for correct animation
|
||||||
|
else if (m_spellInfo->SpellFamilyFlags & UI64LIT(0x0000002000000000))
|
||||||
|
AddTriggeredSpell(41637);
|
||||||
|
|
||||||
switch(m_spellInfo->Id)
|
switch(m_spellInfo->Id)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -2407,15 +2407,7 @@ void Spell::EffectApplyAura(uint32 i)
|
||||||
Aur->SetAuraDuration(duration);
|
Aur->SetAuraDuration(duration);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool added = unitTarget->AddAura(Aur);
|
unitTarget->AddAura(Aur);
|
||||||
|
|
||||||
// Aura not added and deleted in AddAura call;
|
|
||||||
if (!added)
|
|
||||||
return;
|
|
||||||
|
|
||||||
// Prayer of Mending (jump animation), we need formal caster instead original for correct animation
|
|
||||||
if( m_spellInfo->SpellFamilyName == SPELLFAMILY_PRIEST && (m_spellInfo->SpellFamilyFlags & UI64LIT(0x0000002000000000)))
|
|
||||||
m_caster->CastSpell(unitTarget, 41637, true, NULL, Aur, m_originalCasterGUID);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Spell::EffectUnlearnSpecialization( uint32 i )
|
void Spell::EffectUnlearnSpecialization( uint32 i )
|
||||||
|
|
|
||||||
|
|
@ -11037,7 +11037,7 @@ void Unit::ProcDamageAndSpellFor( bool isVictim, Unit * pTarget, uint32 procFlag
|
||||||
sLog.outDebug("ProcDamageAndSpell: casting mending (triggered by %s dummy aura of spell %u)",
|
sLog.outDebug("ProcDamageAndSpell: casting mending (triggered by %s dummy aura of spell %u)",
|
||||||
(isVictim?"a victim's":"an attacker's"),triggeredByAura->GetId());
|
(isVictim?"a victim's":"an attacker's"),triggeredByAura->GetId());
|
||||||
|
|
||||||
HandleMeandingAuraProc(triggeredByAura);
|
HandleMendingAuraProc(triggeredByAura);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SPELL_AURA_PROC_TRIGGER_SPELL_WITH_VALUE:
|
case SPELL_AURA_PROC_TRIGGER_SPELL_WITH_VALUE:
|
||||||
|
|
@ -11817,7 +11817,7 @@ bool Unit::IsTriggeredAtSpellProcEvent(Unit *pVictim, Aura* aura, SpellEntry con
|
||||||
return roll_chance_f(chance);
|
return roll_chance_f(chance);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Unit::HandleMeandingAuraProc( Aura* triggeredByAura )
|
bool Unit::HandleMendingAuraProc( Aura* triggeredByAura )
|
||||||
{
|
{
|
||||||
// aura can be deleted at casts
|
// aura can be deleted at casts
|
||||||
SpellEntry const* spellProto = triggeredByAura->GetSpellProto();
|
SpellEntry const* spellProto = triggeredByAura->GetSpellProto();
|
||||||
|
|
|
||||||
|
|
@ -1551,7 +1551,7 @@ class MANGOS_DLL_SPEC Unit : public WorldObject
|
||||||
bool HandleHasteAuraProc( Unit *pVictim, uint32 damage, Aura* triggredByAura, SpellEntry const *procSpell, uint32 procFlag, uint32 procEx, uint32 cooldown);
|
bool HandleHasteAuraProc( Unit *pVictim, uint32 damage, Aura* triggredByAura, SpellEntry const *procSpell, uint32 procFlag, uint32 procEx, uint32 cooldown);
|
||||||
bool HandleProcTriggerSpell(Unit *pVictim, uint32 damage, Aura* triggredByAura, SpellEntry const *procSpell, uint32 procFlag, uint32 procEx, uint32 cooldown);
|
bool HandleProcTriggerSpell(Unit *pVictim, uint32 damage, Aura* triggredByAura, SpellEntry const *procSpell, uint32 procFlag, uint32 procEx, uint32 cooldown);
|
||||||
bool HandleOverrideClassScriptAuraProc(Unit *pVictim, uint32 damage, Aura* triggredByAura, SpellEntry const *procSpell, uint32 cooldown);
|
bool HandleOverrideClassScriptAuraProc(Unit *pVictim, uint32 damage, Aura* triggredByAura, SpellEntry const *procSpell, uint32 cooldown);
|
||||||
bool HandleMeandingAuraProc(Aura* triggeredByAura);
|
bool HandleMendingAuraProc(Aura* triggeredByAura);
|
||||||
|
|
||||||
uint32 m_state; // Even derived shouldn't modify
|
uint32 m_state; // Even derived shouldn't modify
|
||||||
uint32 m_CombatTimer;
|
uint32 m_CombatTimer;
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __REVISION_NR_H__
|
#ifndef __REVISION_NR_H__
|
||||||
#define __REVISION_NR_H__
|
#define __REVISION_NR_H__
|
||||||
#define REVISION_NR "8356"
|
#define REVISION_NR "8357"
|
||||||
#endif // __REVISION_NR_H__
|
#endif // __REVISION_NR_H__
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue