瀏覽代碼

CGHeroInstance::recreateSecondarySkillsBonuses() restores bonuses for all levels

Henning Koehler 8 年之前
父節點
當前提交
3fe9bc34b8
共有 1 個文件被更改,包括 2 次插入1 次删除
  1. 2 1
      lib/mapObjects/CGHeroInstance.cpp

+ 2 - 1
lib/mapObjects/CGHeroInstance.cpp

@@ -761,7 +761,8 @@ void CGHeroInstance::recreateSecondarySkillsBonuses()
 		removeBonus(bonus);
 
 	for(auto skill_info : secSkills)
-		updateSkill(SecondarySkill(skill_info.first), skill_info.second);
+		for(int level = 1; level <= skill_info.second; level++)
+			updateSkill(SecondarySkill(skill_info.first), level);
 }
 
 void CGHeroInstance::updateSkill(SecondarySkill which, int val)