TargetConstraint

CopyLocationConstraint

A constraint which makes the constrained object inherit the target's position.

To influence some object, push a CopyLocationConstraint instance into the Object3D.constraints array.

Constructor

CopyLocationConstraint(target : Object3D)

target — constraint's target object.

Properties

See the base TargetConstraint class for common properties.

.influence : Float

The percentage of influence the constraint has on the object. Default is 1.0 (100%).

.invertX : Boolean

Inverts the X axis. Default is false.

.invertY : Boolean

Inverts the Y axis. Default is false.

.invertZ : Boolean

Inverts the Z axis. Default is false.

.isCopyLocationConstraint : Boolean

Read-only flag to check if a given object is of type CopyLocationConstraint.

.type : String

The constraint's type. Equals to "CopyLocationConstraint".

.useOffset : Boolean

When enabled, allows the owner to be translated, relative to its target’s position. Default is false.

.useX : Boolean

Constraint affects the X axis. Default is true.

.useY : Boolean

Constraint affects the Y axis. Default is true.

.useZ : Boolean

Constraint affects the Z axis. Default is true.

Methods

See the base TargetConstraint class for common methods.

Puzzles

You can use the copy transform puzzle to apply CopyLocationConstraint in a visual manner.

Source

For more info on how to obtain the source code of this module see this page.