Skip to main content

AgentWanderSettings

A class in Root.Township, Alta.Intelligence.

Settings for ActiveWander and ActiveBlockCanceleableWander: walk to a random reachable point near the creature. Server only.

Constructors​

MemberWhat it is
AgentWanderSettings()Unity makes components itself; use AddComponent or spawn a prefab instead of new.

Fields​

3 private and internal fields
MemberWhat it is
private int heuristicMaximumBacking field for HeuristicMaximum (default 20000).
private bool isCancelingOnBlockedIf true, the wander cancels as soon as the walker is blocked.
private bool isUsingTargetBacking field for IsUsingTarget.

Properties​

MemberWhat it is
int HeuristicMaximum { get; }Search length for the pathfinder's constant path, which limits how far away the random point can be.
bool IsUsingTarget { get; }Whether the action is scored and run against a target. With the blockable wander, losing the target cancels it.

Methods​

MemberWhat it is
protected override IAction GetAction()Builds ActiveBlockCanceleableWander if isCancelingOnBlocked is on, otherwise ActiveWander, using a target only if IsUsingTarget.