1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-29 23:07:48 +02:00

Updaters replace bonuses during inheritance

This commit is contained in:
Henning Koehler
2017-09-16 12:26:48 +12:00
parent ad5a9f7205
commit 00f51e0f98
3 changed files with 28 additions and 40 deletions

View File

@@ -524,7 +524,6 @@ void CGHeroInstance::initObj(CRandomGenerator & rand)
//initialize bonuses
recreateSecondarySkillsBonuses();
updateBonuses();
mana = manaLimit(); //after all bonuses are taken into account, make sure this line is the last one
type->name = name;
@@ -1255,8 +1254,8 @@ void CGHeroInstance::levelUp(std::vector<SecondarySkill> skills)
}
}
//specialty and other bonuses that scale with level
updateBonuses();
//update specialty and other bonuses that scale with level
treeHasChanged();
}
void CGHeroInstance::levelUpAutomatically(CRandomGenerator & rand)