1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-16 16:10:58 +00:00

fix skill window update

invoke winMgr->updateSkillArea() in mechanicsmanagerimp.cpp after looping
over ESM::Skill::SkillEnum if any updates have occurred.
This commit is contained in:
Mitchell Schwitzer 2017-03-12 15:18:02 -07:00
parent 809f5cd01b
commit 465b7361e1

View File

@ -338,16 +338,19 @@ namespace MWMechanics
}
}
bool updateSkills = false;
//Loop over ESM::Skill::SkillEnum
for(int i = 0; i < ESM::Skill::Length; ++i)
{
if(stats.getSkill(i) != mWatchedSkills[i] || mWatchedStatsEmpty)
{
updateSkills = true;
mWatchedSkills[i] = stats.getSkill(i);
winMgr->setValue((ESM::Skill::SkillEnum)i, stats.getSkill(i));
}
}
if (updateSkills) { winMgr->updateSkillArea(); }
winMgr->setValue("level", stats.getLevel());
mWatchedStatsEmpty = false;