mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-23 13:46:24 +00:00
fix(Core/Player): Use SkillLineAbility.dbc to determine player initia… (#6015)
* fix(Core/Player): Use SkillLineAbility.dbc to determine player initial spells - skill assignment done in a new table `playercreateinfo_skills` * Cherry-pick2a3546ca36* Cherry-Pickd28b66bca8* Cherry-Pick193408f335- Closes https://github.com/azerothcore/azerothcore-wotlk/issues/1659 - Closes https://github.com/azerothcore/azerothcore-wotlk/issues/6036 - Closes https://github.com/chromiecraft/chromiecraft/issues/693 Co-Authored-By: Shauren shauren.trinity@gmail.com Co-Authored-By: Rothend 67004168+Rothend@users.noreply.github.com Co-Authored-By: claudiodfc claudio.daniel.f.c@gmail.com
This commit is contained in:
@@ -40,7 +40,7 @@ bool IsPartOfSkillLine(uint32 skillId, uint32 spellId)
|
||||
{
|
||||
SkillLineAbilityMapBounds skillBounds = sSpellMgr->GetSkillLineAbilityMapBounds(spellId);
|
||||
for (SkillLineAbilityMap::const_iterator itr = skillBounds.first; itr != skillBounds.second; ++itr)
|
||||
if (itr->second->skillId == skillId)
|
||||
if (itr->second->SkillLine == skillId)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
@@ -2031,7 +2031,7 @@ void SpellMgr::LoadSkillLineAbilityMap()
|
||||
if (!SkillInfo)
|
||||
continue;
|
||||
|
||||
mSkillLineAbilityMap.insert(SkillLineAbilityMap::value_type(SkillInfo->spellId, SkillInfo));
|
||||
mSkillLineAbilityMap.insert(SkillLineAbilityMap::value_type(SkillInfo->Spell, SkillInfo));
|
||||
++count;
|
||||
}
|
||||
|
||||
@@ -2270,13 +2270,13 @@ void SpellMgr::LoadPetLevelupSpellMap()
|
||||
// (!creatureFamily->skillLine[1] || skillLine->skillId != creatureFamily->skillLine[1]))
|
||||
// continue;
|
||||
|
||||
if (skillLine->skillId != creatureFamily->skillLine[j])
|
||||
if (skillLine->SkillLine != creatureFamily->skillLine[j])
|
||||
continue;
|
||||
|
||||
if (skillLine->learnOnGetSkill != ABILITY_LEARNED_ON_GET_RACE_OR_CLASS_SKILL)
|
||||
if (skillLine->AcquireMethod != SKILL_LINE_ABILITY_LEARNED_ON_SKILL_LEARN)
|
||||
continue;
|
||||
|
||||
SpellInfo const* spell = GetSpellInfo(skillLine->spellId);
|
||||
SpellInfo const* spell = GetSpellInfo(skillLine->Spell);
|
||||
if (!spell) // not exist or triggered or talent
|
||||
continue;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user