Sfoglia il codice sorgente

Remove(reduce durations) of bonuses for tavern heroes

Evgeniy Meshcheryakov 2 anni fa
parent
commit
47f5dd14fa
1 ha cambiato i file con 4 aggiunte e 0 eliminazioni
  1. 4 0
      lib/gameState/TavernHeroesPool.cpp

+ 4 - 0
lib/gameState/TavernHeroesPool.cpp

@@ -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;