Scripts/Commands: .learn adjustments

Port From (https://github.com/TrinityCore/TrinityCore/commit/2319a99d875cd17a1c26ccc756bae73e2faef327)
This commit is contained in:
hondacrx
2022-06-09 20:48:29 -04:00
parent 35569af2e8
commit 2dcbe3e840
4 changed files with 160 additions and 156 deletions
@@ -2047,15 +2047,6 @@ namespace Game.Entities
SendPacket(new SendUnlearnSpells());
}
public void LearnSpellHighestRank(uint spellid)
{
LearnSpell(spellid, false);
uint next = Global.SpellMgr.GetNextSpellInChain(spellid);
if (next != 0)
LearnSpellHighestRank(next);
}
public void LearnSpell(uint spellId, bool dependent, uint fromSkill = 0, bool suppressMessaging = false)
{
PlayerSpell spell = m_spells.LookupByKey(spellId);