mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-06 09:09:40 +02:00
Nullkiller: small optimization of AIPathfinder for big maps
This commit is contained in:
committed by
Andrii Danylchenko
parent
07b6b0605c
commit
5bfe71c8f3
@@ -640,13 +640,6 @@ EvaluationContext PriorityEvaluator::buildEvaluationContext(Goals::TSubgoal goal
|
||||
return context;
|
||||
}
|
||||
|
||||
/// distance
|
||||
/// nearest hero?
|
||||
/// gold income
|
||||
/// army income
|
||||
/// hero strength - hero skills
|
||||
/// danger
|
||||
/// importance
|
||||
float PriorityEvaluator::evaluate(Goals::TSubgoal task)
|
||||
{
|
||||
auto evaluationContext = buildEvaluationContext(task);
|
||||
@@ -677,7 +670,7 @@ float PriorityEvaluator::evaluate(Goals::TSubgoal task)
|
||||
fearVariable->setValue(evaluationContext.enemyHeroDangerRatio);
|
||||
|
||||
engine->process();
|
||||
//engine.process(VISIT_TILE); //TODO: Process only Visit_Tile
|
||||
|
||||
result = value->getValue();
|
||||
}
|
||||
catch(fl::Exception & fe)
|
||||
|
||||
Reference in New Issue
Block a user