fix(Core/Spells): Fixed displaying "That Glyph is already inscribed in your spellbook" when activating the same glyph in different spec. (#7162)
Fixed #6342 Co-authored-by: Stefano Borzì <stefanoborzi32@gmail.com>
This commit is contained in:
@@ -14138,10 +14138,21 @@ void Player::ActivateSpec(uint8 spec)
|
|||||||
|
|
||||||
// xinef: apply glyphs from second spec
|
// xinef: apply glyphs from second spec
|
||||||
if (GetActiveSpec() != oldSpec)
|
if (GetActiveSpec() != oldSpec)
|
||||||
|
{
|
||||||
for (uint8 slot = 0; slot < MAX_GLYPH_SLOT_INDEX; ++slot)
|
for (uint8 slot = 0; slot < MAX_GLYPH_SLOT_INDEX; ++slot)
|
||||||
if (uint32 glyphId = m_Glyphs[GetActiveSpec()][slot])
|
{
|
||||||
|
uint32 glyphId = m_Glyphs[GetActiveSpec()][slot];
|
||||||
|
if (glyphId)
|
||||||
|
{
|
||||||
if (GlyphPropertiesEntry const* glyphEntry = sGlyphPropertiesStore.LookupEntry(glyphId))
|
if (GlyphPropertiesEntry const* glyphEntry = sGlyphPropertiesStore.LookupEntry(glyphId))
|
||||||
|
{
|
||||||
CastSpell(this, glyphEntry->SpellId, TriggerCastFlags(TRIGGERED_FULL_MASK & ~(TRIGGERED_IGNORE_SHAPESHIFT | TRIGGERED_IGNORE_CASTER_AURASTATE)));
|
CastSpell(this, glyphEntry->SpellId, TriggerCastFlags(TRIGGERED_FULL_MASK & ~(TRIGGERED_IGNORE_SHAPESHIFT | TRIGGERED_IGNORE_CASTER_AURASTATE)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
SetGlyph(slot, glyphId, true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
m_usedTalentCount = spentTalents;
|
m_usedTalentCount = spentTalents;
|
||||||
InitTalentForLevel();
|
InitTalentForLevel();
|
||||||
|
|||||||
Reference in New Issue
Block a user