Motion
Get Motion

ReferenceScripting APIDragComponentconstructor

DragComponent.constructor

constructor

Makes a mote draggable with the pointer.

Nameconstructor
Kindconstructor of DragComponent
Called asnew DragComponent(…)
Since0.3

Syntax

new DragComponent(    name: string,    mote: Mote,    options?: { axis?: "x" | "y" }): DragComponent

Parameters

NameTypeDescription
namestringIts name on the mote.
moteMoteThe mote to drag.
options{ axis?: "x" | "y" }Optional. Axis: "x" or "y" to drag along one way alone.

See also

Mote