Skip to content

Commit

Permalink
[10908] Imporve detection need use reagents by triggered spell.
Browse files Browse the repository at this point in the history
Now regagent used if main spell (if infor about provided to triggered cast)
not have regent data.

This fix reagetn use for spell 43723. But maybe need another fixes for proper animation.
  • Loading branch information
VladimirMangos committed Dec 22, 2010
1 parent 46108e9 commit 4e5a9be
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
5 changes: 5 additions & 0 deletions src/game/Spell.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5811,6 +5811,11 @@ bool Spell::IgnoreItemRequirements() const
if (targetItem->GetOwnerGuid() != m_caster->GetObjectGuid())
return false;

/// Some triggered spells have same reagents that have master spell
/// expected in test: master spell have reagents in first slot then triggered don't must use own
if (m_triggeredBySpellInfo && !m_triggeredBySpellInfo->Reagent[0])
return false;

return true;
}

Expand Down
4 changes: 1 addition & 3 deletions src/game/SpellEffects.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1220,16 +1220,14 @@ void Spell::EffectDummy(SpellEffectIndex eff_idx)
return;
}
// Demon Broiled Surprise
/* FIX ME: Required for correct work implementing implicit target 7 (in pair (22,7))
case 43723:
{
if (m_caster->GetTypeId() != TYPEID_PLAYER)
return;

((Player*)m_caster)->CastSpell(unitTarget, 43753, true);
((Player*)m_caster)->CastSpell(unitTarget, 43753, true, m_CastItem, NULL, m_originalCasterGUID, m_spellInfo);
return;
}
*/
case 43882: // Scourging Crystal Controller Dummy
{
if (!unitTarget || unitTarget->GetTypeId() != TYPEID_UNIT)
Expand Down
2 changes: 1 addition & 1 deletion src/shared/revision_nr.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "10907"
#define REVISION_NR "10908"
#endif // __REVISION_NR_H__

0 comments on commit 4e5a9be

Please sign in to comment.