Core/Spells: Reapply glyph bonuses that depend on stance when you shapeshift into that instance
Closes #1076 and possibly others Signed-off-by: Subv <[email protected]>
This commit is contained in:
@@ -1474,6 +1474,23 @@ void AuraEffect::HandleShapeshiftBoosts(Unit* target, bool apply) const
|
||||
if (spellInfo->Stances & (1<<(GetMiscValue()-1)))
|
||||
target->CastSpell(target, itr->first, true, NULL, this);
|
||||
}
|
||||
|
||||
// Also do it for Glyphs
|
||||
for (uint32 i = 0; i < MAX_GLYPH_SLOT_INDEX; ++i)
|
||||
{
|
||||
if (uint32 glyphId = target->ToPlayer()->GetGlyph(i))
|
||||
{
|
||||
if (GlyphPropertiesEntry const* glyph = sGlyphPropertiesStore.LookupEntry(glyphId))
|
||||
{
|
||||
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(glyph->SpellId);
|
||||
if (!spellInfo || !(spellInfo->Attributes & (SPELL_ATTR0_PASSIVE | SPELL_ATTR0_HIDDEN_CLIENTSIDE)))
|
||||
continue;
|
||||
if (spellInfo->Stances & (1<<(GetMiscValue()-1)))
|
||||
target->CastSpell(target, glyph->SpellId, true, NULL, this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Leader of the Pack
|
||||
if (target->ToPlayer()->HasSpell(17007))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user