From ccd73918aed62456af4cf900c59b2d8108a24d81 Mon Sep 17 00:00:00 2001 From: Kitzunu <24550914+Kitzunu@users.noreply.github.com> Date: Sun, 27 Jun 2021 17:46:13 +0200 Subject: [PATCH] fix(Core/Player): Learn runeforging & lockpicking skills (#6612) * cherry-pick commit (https://github.com/TrinityCore/TrinityCore/commit/b1ac631f68d122558c25c4da7eedef75b4c2b7b6) Co-authored-by: r00ty-tc <173349+r00ty-tc@users.noreply.github.com> --- src/server/game/Entities/Player/Player.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index 4c688169f..169fe3ebf 100644 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -4108,7 +4108,9 @@ bool Player::_addSpell(uint32 spellId, uint8 addSpecMask, bool temporary, bool l continue; } - if (_spell_idx->second->AcquireMethod == SKILL_LINE_ABILITY_LEARNED_ON_SKILL_LEARN && !HasSkill(pSkill->id)) + // @todo confirm if rogues start wth lockpicking skill at level 1 but only recieve the spell to use it at level 16 + // Added for runeforging, it is confirmed via sniff that this happens when death knights learn the spell, not on character creation. + if ((_spell_idx->second->AcquireMethod == SKILL_LINE_ABILITY_LEARNED_ON_SKILL_LEARN && !HasSkill(pSkill->id)) || ((pSkill->id == SKILL_LOCKPICKING || pSkill->id == SKILL_RUNEFORGING) && _spell_idx->second->TrivialSkillLineRankHigh == 0)) { LearnDefaultSkill(pSkill->id, 0); }