Fixed bug with professions in trainer list not being marked as known until trainer list re-opened.

This commit is contained in:
tomrus88 2010-03-27 19:41:15 +03:00
parent 112046718a
commit b99f51a984
13 changed files with 108 additions and 91 deletions

View file

@ -2113,15 +2113,16 @@ void SpellMgr::LoadSpellLearnSkills()
for(int i = 0; i < MAX_EFFECT_INDEX; ++i)
{
if(entry->Effect[i]==SPELL_EFFECT_SKILL)
if(entry->Effect[i] == SPELL_EFFECT_SKILL)
{
SpellLearnSkillNode dbc_node;
dbc_node.skill = entry->EffectMiscValue[i];
dbc_node.step = entry->CalculateSimpleValue(SpellEffectIndex(i));
if ( dbc_node.skill != SKILL_RIDING )
dbc_node.value = 1;
else
dbc_node.value = entry->CalculateSimpleValue(SpellEffectIndex(i))*75;
dbc_node.maxvalue = entry->CalculateSimpleValue(SpellEffectIndex(i))*75;
dbc_node.value = dbc_node.step * 75;
dbc_node.maxvalue = dbc_node.step * 75;
mSpellLearnSkills[spell] = dbc_node;
++dbc_count;