1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-06-17 00:07:41 +02:00

vcmi: remove SHval (replace by simple val)

This commit is contained in:
Konstantin
2023-04-27 00:16:05 +03:00
parent af25ad0866
commit 1f54a1474c
6 changed files with 5 additions and 8 deletions

View File

@ -82,9 +82,6 @@ std::string CBonusTypeHandler::bonusToString(const std::shared_ptr<Bonus> & bonu
if (text.find("${subtype.spell}") != std::string::npos)
boost::algorithm::replace_all(text, "${subtype.spell}", SpellID(bonus->subtype).toSpell()->getNameTranslated());
if (text.find("${SHval}") != std::string::npos) //regeneration case
boost::algorithm::replace_all(text, "${SHval}", std::to_string(std::min(static_cast<si32>(bearer->MaxHealth()),bearer->valOfBonuses(Selector::typeSubtype(bonus->type, bonus->subtype)))));
return text;
}