Skip to main content

AgentCrawlSettings

A class in Root.Township, Alta.Intelligence.

Action settings for a creature crawling over surfaces for a random duration (ActiveCrawl). Sits under an action set on the creature prefab.

Constructors​

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

Fields​

8 private and internal fields
MemberWhat it is
private float colliderRadiusBacking field for ColliderRadius: radius used for crawl surface and obstacle checks.
private LayerMask collisionCheckBacking field for CollisionCheck: layers that block the crawl.
private int raycastEveryXFramesBacking field for RaycastEveryXFrames: how many frames between surface raycasts.
private ActionComponentSet recoverFromFallingBacking field for RecoverFromFalling: action set used when the crawler loses the surface.
private float uprightRotationSpeedBacking field for UprightRotationSpeed.
private float walkingSpeedBacking field for WalkingSpeed.
private LayerMask walkOnBacking field for WalkOn: layers the agent can crawl on.
private float walkRotationSpeedBacking field for WalkRotationSpeed.

Properties​

MemberWhat it is
float ColliderRadius { get; }Radius used for the surface and collision checks around the body.
LayerMask CollisionCheck { get; }Layers that block the crawl.
int RaycastEveryXFrames { get; }How many frames between the forward surface raycasts.
ActionComponentSet RecoverFromFalling { get; }Action set switched to when the creature loses the surface, if set.
float UprightRotationSpeed { get; }How fast it turns to match the surface.
float WalkingSpeed { get; }Crawl speed in metres per second.
LayerMask WalkOn { get; }Layers it can crawl on.
float WalkRotationSpeed { get; }How fast it turns while walking.

Methods​

MemberWhat it is
protected override IAction GetAction()Creates the ActiveCrawl action without a target.