Explorar el Código

Remove(reduce durations) of bonuses for tavern heroes

Evgeniy Meshcheryakov hace 2 años
padre
commit
47f5dd14fa
Se han modificado 1 ficheros con 4 adiciones y 0 borrados
  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;