grail (C  1.0.0
A multi-platform, modular, universal engine for embedding advanced AI in games.
Grail.Utility.Evaluator< ContextType > Class Template Reference

Standard evaluator calculating scores based on considerations and curves. More...

Inheritance diagram for Grail.Utility.Evaluator< ContextType >:
Collaboration diagram for Grail.Utility.Evaluator< ContextType >:

Public Member Functions

 Evaluator (WeightEvaluationMethod method)
 
 Evaluator (WeightEvaluationMethod method, IEnumerable<(Consideration< ContextType >, Curve)> curveData)
 
float EvaluateWeight (ContextType context)
 Evaluates weight using provided evaluation method. More...
 
void AddCurve (Consideration< ContextType > consideration, Curve curve)
 

Properties

int Rank [get]
 
WeightEvaluationMethod EvaluationMethod [get]
 
List<(Consideration< ContextType > consideration, Curve curve)> CurveData [get]
 
- Properties inherited from Grail.Utility.IEvaluator< ContextType >
int Rank [get]
 Measure of importance of evaluated object. More...
 

Detailed Description

Standard evaluator calculating scores based on considerations and curves.

Template Parameters
ContextType

Constructor & Destructor Documentation

◆ Evaluator() [1/2]

Grail.Utility.Evaluator< ContextType >.Evaluator ( WeightEvaluationMethod  method)
inline

Parameters
methodscore aggregation method (MAX, MIN, AVERAGE, ADD, MULTIPLY)

◆ Evaluator() [2/2]

Grail.Utility.Evaluator< ContextType >.Evaluator ( WeightEvaluationMethod  method,
IEnumerable<(Consideration< ContextType >, Curve)>  curveData 
)
inline

Parameters
methodscore aggregation method (MAX, MIN, AVERAGE, ADD, MULTIPLY)
curveDatacollection of considerations paired with curves

Member Function Documentation

◆ EvaluateWeight()

float Grail.Utility.Evaluator< ContextType >.EvaluateWeight ( ContextType  context)
inline

Evaluates weight using provided evaluation method.

Parameters
context
Returns
weight - measure of suitability of evaluated object in given Context
Exceptions
ArgumentOutOfRangeException

Implements Grail.Utility.IEvaluator< ContextType >.


The documentation for this class was generated from the following file: