mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-16 07:30:42 +01:00
@@ -3807,7 +3807,8 @@ bool Player::AddSpell(uint32 spellId, bool active, bool learning, bool dependent
|
||||
if (!pSkill)
|
||||
continue;
|
||||
|
||||
if (_spell_idx->second->AutolearnType == SKILL_LINE_ABILITY_LEARNED_ON_SKILL_LEARN && !HasSkill(pSkill->id))
|
||||
///@todo: confirm if rogues start with lockpicking skill at level 1 but only receive the spell to use it at level 16
|
||||
if ((_spell_idx->second->AutolearnType == SKILL_LINE_ABILITY_LEARNED_ON_SKILL_LEARN && !HasSkill(pSkill->id)) || (pSkill->id == SKILL_LOCKPICKING && _spell_idx->second->max_value == 0))
|
||||
LearnDefaultSkill(pSkill->id, 0);
|
||||
|
||||
if (pSkill->id == SKILL_MOUNTS && !Has310Flyer(false))
|
||||
@@ -23146,6 +23147,8 @@ void Player::LearnDefaultSkill(uint32 skillId, uint16 rank)
|
||||
skillValue = std::min(std::max<uint16>({ 1, uint16((getLevel() - 1) * 5) }), maxValue);
|
||||
else if (skillId == SKILL_FIST_WEAPONS)
|
||||
skillValue = std::max<uint16>(1, GetSkillValue(SKILL_UNARMED));
|
||||
else if (skillId == SKILL_LOCKPICKING)
|
||||
skillValue = std::max<uint16>(1, GetSkillValue(SKILL_LOCKPICKING));
|
||||
|
||||
SetSkill(skillId, 0, skillValue, maxValue);
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user