1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-08-15 20:03:15 +02:00

Remove(reduce durations) of bonuses for tavern heroes

This commit is contained in:
Evgeniy Meshcheryakov
2023-09-06 09:12:23 +03:00
parent ecf9b1aa2f
commit 47f5dd14fa

View File

@@ -117,6 +117,10 @@ void TavernHeroesPool::onNewDay()
if(!hero.second)
continue;
hero.second->removeBonusesRecursive(Bonus::OneDay);
hero.second->reduceBonusDurations(Bonus::NDays);
hero.second->reduceBonusDurations(Bonus::OneWeek);
// do not access heroes who are not present in tavern of any players
if (vstd::contains(unusedHeroes, hero.first))
continue;