Doloro GDK 22 .1.0 Beta
by Tauri Interactive
Doloro.AI.Core.Memory Class Reference

Detailed Description

The class that add an ability to AI to member the references and values. Required to orientation in the world space.

Inheritance diagram for Doloro.AI.Core.Memory:
Collaboration diagram for Doloro.AI.Core.Memory:

Public Member Functions

bool Write (object sender, ref AI.Variable variable, bool typeCheck=false)
 Write variable to variable list by name used as source. If variable already existCheck and has the save type, just rewrite the value. In other case return the false and spawn the warning. More...
 
AI.Variable Read (string key)
 Returns the variable from list by the name as the source. More...
 
bool Remove (PipelineItem sender, string key)
 Removes variable from AI's entity memory More...
 
bool Exists (string key)
 Checks existing of the variable with the key in memory. More...
 
bool CheckTypeEqual (string key, System.Type type)
 Returns true if type of variable equal requested More...
 
IEnumerator< AI.VariableGetEnumerator ()
 

Public Attributes

Brain ai
 Reference to owner of memory.
 

Package Attributes

Dictionary< string, AI.Variablevariables = new Dictionary<string, AI.Variable>()
 Dictionary of variables.
 

Member Function Documentation

◆ CheckTypeEqual()

bool Doloro.AI.Core.Memory.CheckTypeEqual ( string  key,
System.Type  type 
)

Returns true if type of variable equal requested

Parameters
keyVariable key.
typeVariable type.
Returns
Exceptions
KeyNotFoundExceptionNot registered variable key.

◆ Exists()

bool Doloro.AI.Core.Memory.Exists ( string  key)

Checks existing of the variable with the key in memory.

Parameters
keyKey to search.
Returns
Result of search.

◆ Read()

AI.Variable Doloro.AI.Core.Memory.Read ( string  key)

Returns the variable from list by the name as the source.

Parameters
keyVariable's key.
Returns
Variable reference. Null if not found

◆ Remove()

bool Doloro.AI.Core.Memory.Remove ( PipelineItem  sender,
string  key 
)

Removes variable from AI's entity memory

Parameters
senderEncounter source.
keyVariable to remove.
Returns
Result of removing.
Todo:
Implement sender using

◆ Write()

bool Doloro.AI.Core.Memory.Write ( object  sender,
ref AI.Variable  variable,
bool  typeCheck = false 
)

Write variable to variable list by name used as source. If variable already existCheck and has the save type, just rewrite the value. In other case return the false and spawn the warning.

Todo:
sender not integrated withing the core yet.
Parameters
senderObject that initiated the variable set. Using in tracking systems.
variableNew variable
typeCheckIf true then forces check of the variable type and allows override of an exist value only with a value of the same type.
Returns
Is the value has been applied to memory.
Todo:
Implement sender using

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