Polarith AI
1.8

◆ Query()

void Query ( Vector3  point,
float  range,
IList< string >  environments,
IList< SteeringPercept percepts 
)

Given the point and the range , this method iterates all cells of the grid that may hold relevant SteeringPercept instances.

A percept is considered relevant if it is referenced by one of the given environments and is within the range of the given point . If the percept is relevant, it is written to the percepts list and SteeringPercept.Receive() is called when the percept data was not already received yet.

Parameters
point

A point in world coordinates to query relevant percepts for. This might be an agent position.

Parameters
rangeThe maximum distance a SteeringPercept must have with respect to the given point for being considered as relevant.
environmentsA list containing labels corresponding to environments that should be searched.
perceptsContains the queried percepts after the call of this method.
Exceptions
NullReferenceExceptionIf environments or percepts are null.
Imprint