mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 13:37:05 +00:00
Not store dependent spells in character_spell
* Mark spells learned in result character creating, another spell learning, skill grow, quest reward as dependent and not store its in `character_spell`. * Prevent re-learning known spell in expected state * Prevent re-learning low rank spell as active if higher rank known. * New type of non-stacked ranked spells check: skill dependent spell bonuses. * Activate (show propetly and cast if need) lesser spell rank for non-stackable in spellbooks spells at unlearn high rank
This commit is contained in:
parent
4b5aba18f8
commit
bbf8fd0742
10 changed files with 222 additions and 85 deletions
|
|
@ -3848,7 +3848,7 @@ bool ChatHandler::HandleLearnAllCraftsCommand(const char* /*args*/)
|
|||
if(!spellInfo || !SpellMgr::IsSpellValid(spellInfo,m_session->GetPlayer(),false))
|
||||
continue;
|
||||
|
||||
m_session->GetPlayer()->learnSpell(skillLine->spellId);
|
||||
m_session->GetPlayer()->learnSpell(skillLine->spellId,false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -3919,7 +3919,7 @@ bool ChatHandler::HandleLearnAllRecipesCommand(const char* args)
|
|||
continue;
|
||||
|
||||
if( !target->HasSpell(spellInfo->Id) )
|
||||
m_session->GetPlayer()->learnSpell(skillLine->spellId);
|
||||
m_session->GetPlayer()->learnSpell(skillLine->spellId,false);
|
||||
}
|
||||
|
||||
uint16 maxLevel = target->GetPureMaxSkillValue(skillInfo->id);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue