diff --git a/lib/entities/hero/CHeroClass.cpp b/lib/entities/hero/CHeroClass.cpp index 4a8d6d308..80e06cabf 100644 --- a/lib/entities/hero/CHeroClass.cpp +++ b/lib/entities/hero/CHeroClass.cpp @@ -30,7 +30,10 @@ SecondarySkill CHeroClass::chooseSecSkill(const std::set & possi { skills.push_back(possible); if (secSkillProbability.count(possible) != 0) - weights.push_back(secSkillProbability.at(possible)); + { + int weight = secSkillProbability.at(possible); + weights.push_back(std::max(1, weight)); + } else weights.push_back(1); // H3 behavior - banned skills have minimal (1) chance to be picked }