mirror of
https://github.com/mangosfour/server.git
synced 2025-12-15 19:37:02 +00:00
[10248] Implement applying proper penalty spell when making use of talent 46917.
This commit is contained in:
parent
5efb7410f2
commit
33e7d46519
4 changed files with 32 additions and 5 deletions
|
|
@ -7825,10 +7825,18 @@ void Spell::EffectActivateRune(SpellEffectIndex eff_idx)
|
|||
}
|
||||
}
|
||||
|
||||
void Spell::EffectTitanGrip(SpellEffectIndex /*eff_idx*/)
|
||||
void Spell::EffectTitanGrip(SpellEffectIndex eff_idx)
|
||||
{
|
||||
// Make sure "Titan's Grip" (49152) penalty spell does not silently change
|
||||
if (m_spellInfo->EffectMiscValue[eff_idx] != 49152)
|
||||
sLog.outError("Spell::EffectTitanGrip: Spell %u has unexpected EffectMiscValue '%u'", m_spellInfo->Id, m_spellInfo->EffectMiscValue[eff_idx]);
|
||||
if (unitTarget && unitTarget->GetTypeId() == TYPEID_PLAYER)
|
||||
((Player*)unitTarget)->SetCanTitanGrip(true);
|
||||
{
|
||||
Player *plr = (Player*)m_caster;
|
||||
plr->SetCanTitanGrip(true);
|
||||
if (plr->HasTwoHandWeaponInOneHand() && !plr->HasAura(49152))
|
||||
plr->CastSpell(plr, 49152, true);
|
||||
}
|
||||
}
|
||||
|
||||
void Spell::EffectRenamePet(SpellEffectIndex /*eff_idx*/)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue