Browse Source

Take hero-stats into account for attacking hero-defended entities

Instead of using just the strength of the raw army, the hero-stats are now taking into account for the generation of the danger-map.
Xilmi 1 năm trước cách đây
mục cha
commit
e2e3f9e638
1 tập tin đã thay đổi với 1 bổ sung0 xóa
  1. 1 0
      AI/Nullkiller/Engine/FuzzyHelper.cpp

+ 1 - 0
AI/Nullkiller/Engine/FuzzyHelper.cpp

@@ -71,6 +71,7 @@ ui64 FuzzyHelper::evaluateDanger(const int3 & tile, const CGHeroInstance * visit
 			{
 				objectDanger += evaluateDanger(hero->visitedTown.get());
 			}
+			objectDanger *= ai->heroManager->getFightingStrengthCached(hero);
 		}
 
 		if(objectDanger)