public sealed class GoapTargetSensorsWhere each of a domain's actions happens, and where the agent asking is.
Remarks
doc 37 § D12: an action declares a target key and a sensor resolves it — "the nearest pear", not "pear number four". That is what keeps the graph a function of the action set rather than of the world's contents.
⚠ Where the agent is comes through a delegate, and that is the layering. A position lives in Vixen.Engine, which this assembly may not reference — doc 37's whole argument for putting the planners in Core/. A game or Vixen.Ai.Nodes hands one over; a game with no transforms at all hands over nothing, every distance reads as zero, and the search plans by action cost alone, which is a perfectly good way to plan.
Fields and properties (2)
public GoapTargetSensors.PositionLookup? AgentPositionHow to find where the agent is, or null for the origin.
public int CountHow many sensors it holds.
Methods (5)
public GoapTargetSensors Add(Symbol key, IGoapTargetSensor sensor)Registers a sensor.
public GoapTargetSensors Add(Symbol key, GoapTargetLookup sensor)Registers a sensor written as a lambda.
public GoapTargetSensors Add(Symbol key, ITargetSensor sensor)Registers one of doc 37 § D13's target sensors under a GOAP target key.
public bool TryResolve(Symbol key, in AgentContext context, out Vector3 position, out Entity target)Finds where an action would happen.
public Vector3 Where(in AgentContext context)Where the agent is.
Used by (5)
- AiSystemVixen.Ai
- GoapPlanQueueVixen.Ai
- GoapPlannerVixen.Ai
- GoapSnapshotVixen.Ai
- GoapWiringVixen.Ai.Nodes