Grail (C#)  1.1.1
A multi-platform, modular, universal engine for embedding advanced AI in games.
Grail.Evolution.EvoScript Class Referenceabstract
Inheritance diagram for Grail.Evolution.EvoScript:
Collaboration diagram for Grail.Evolution.EvoScript:

Public Member Functions

abstract EvoScript UserClone ()
 Make and return a new copy of the type of your derived class from EvoScript - your complete player being optimized. You do not need to set concrete values of EvoParams, because they will be synchronized automatically. More...
 
EvoScript SystemClone ()
 
void CloneEvoParamValuesFromOther (EvoScript other)
 
void Randomize (Random random)
 
List< EvoScriptGetAllRealizations ()
 
ulong GetPossibleRealizationsCount ()
 
List< EvoScriptGetRandomRealizations (Random random, int count)
 
override string ToString ()
 
int CompareTo (EvoScript other)
 
int Compare (EvoScript x, EvoScript y)
 
void ExchangeParams (EvoScript other, int inclusiveFrom, int exclusiveTo)
 
float CalculateSimilarity (EvoScript other)
 
float[] GetNormalizedPositionWeights ()
 

Protected Member Functions

void RegisterParam (EvoParam parameter)
 Params might be stored by normal named members, but in order to evolve them, they need to be registered, i.e. added to a special collection. It is advised to call this function or RegisterParams in the object's constructor. More...
 
void RegisterParams (params EvoParam[] parameters)
 

Properties

List< EvoParamEvoParams = new List<EvoParam>() [get]
 
float Fitness = -1.0f [get, set]
 
- Properties inherited from Grail.Evolution.IFitnessProvider
float Fitness [get, set]
 

Member Function Documentation

◆ RegisterParam()

void Grail.Evolution.EvoScript.RegisterParam ( EvoParam  parameter)
inlineprotected

Params might be stored by normal named members, but in order to evolve them, they need to be registered, i.e. added to a special collection. It is advised to call this function or RegisterParams in the object's constructor.

Parameters
parameterA single parameter to be registered. To register multiple parameters at once, call RegisterParams

◆ UserClone()

abstract EvoScript Grail.Evolution.EvoScript.UserClone ( )
pure virtual

Make and return a new copy of the type of your derived class from EvoScript - your complete player being optimized. You do not need to set concrete values of EvoParams, because they will be synchronized automatically.


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