public readonly record struct QueryBindingWhere a query run gets its origin, and where its answer goes.
Remarks
⚠ Two result keys, not one. A query over entities answers with an entity and a query over a grid answers with a position, and a node that wrote only the position would have thrown away the whole point of the first — while one that wrote only the entity would have nothing to say about the second. Both are written when both are known; the entity key is cleared when the winning point came from no entity, because a stale entity is worse than none.
⚠ The optional keys are BlackboardKey? and not BlackboardKey, because default(BlackboardKey) is key zero and not an invalid one. A binding that left the entity key unset would silently name the first key on the board — which in this node's case meant clearing the very key it had just written. Perception's bindings are nullable for the same reason and it cost a failing test to find there too.
Fields and properties (4)
public EnvironmentQuery QueryThe query to run.
public BlackboardKey? ContextA key naming what the query is about, or invalid for none.
public BlackboardKey? ResultA Vector3 key the best point is written to.
public BlackboardKey? ResultEntityAn Entity key the best point's entity is written to, or invalid.
Methods (1)
public QueryBinding(EnvironmentQuery Query, BlackboardKey? Context = null, BlackboardKey? Result = null, BlackboardKey? ResultEntity = null)Where a query run gets its origin, and where its answer goes.
Used by (5)
- QueryNodesVixen.Ai.Nodes
- QueryRunnerVixen.Ai.Nodes
- RunQueryNodeTestsVixen.Ai.Nodes.Tests
- RunQueryServiceVixen.Ai.Nodes
- RunQueryTaskVixen.Ai.Nodes