Options
All
  • Public
  • Public/Protected
  • All
Menu

A behavior that when attached to a mesh will follow a camera

since

5.0.0

Hierarchy

  • FollowBehavior

Implements

Index

Constructors

Properties

attachedNode: Nullable<TransformNode>

Attached node of this behavior

defaultDistance: number

Default distance from eye to attached node, i.e. the sphere radius

fixedVerticalOffset: number

Fixed vertical position offset distance.

ignoreAngleClamp: boolean

Option to ignore angle clamping

ignoreCameraPitchAndRoll: boolean

If the behavior should ignore the pitch and roll of the camera.

ignoreDistanceClamp: boolean

Option to ignore distance clamping

interpolatePose: boolean

Set to false if the node should strictly follow the camera without any interpolation time

lerpTime: number

Rate of interpolation of position and rotation of the attached node. Higher values will give a slower interpolation.

maxViewHorizontalDegrees: number

The horizontal angle from the camera forward axis to the owner will not exceed this value

maxViewVerticalDegrees: number

The vertical angle from the camera forward axis to the owner will not exceed this value

maximumDistance: number

Max distance from eye to attached node, i.e. the sphere radius

minimumDistance: number

Min distance from eye to attached node, i.e. the sphere radius

orientToCameraDeadzoneDegrees: number

The attached node will not reorient until the angle between its forward vector and the vector to the camera is greater than this value

pitchOffset: number

Pitch offset from camera (relative to Max Distance) Is only effective if ignoreCameraPitchAndRoll is set to true.

useFixedVerticalOffset: boolean

Ignore vertical movement and lock the Y position of the object.

verticalMaxDistance: number

Max vertical distance between the attachedNode and camera

Accessors

  • The camera that should be followed by this behavior

    Returns Nullable<Camera>

  • The camera that should be followed by this behavior

    Parameters

    Returns void

  • get name(): string
  • The name of the behavior

    Returns string

Methods

  • Attaches the follow behavior

    Parameters

    • ownerNode: TransformNode

      The mesh that will be following once attached

    • Optional followedCamera: Camera

      The camera that should be followed by the node

    Returns void

  • detach(): void
  • Detaches the behavior from the mesh

    Returns void

  • init(): void
  • Initializes the behavior

    Returns void

  • recenter(): void
  • Recenters the attached node in front of the camera on the next update

    Returns void

Legend

  • Constructor
  • Property
  • Method
  • Accessor
  • Property
  • Method
  • Inherited constructor
  • Static method

Settings

Theme