DynamicInstance¶
DynamicInstance is the base class where all objects with a position, rotation and scale derive from.
Abstract Object
This object exists only to serve as a foundation for other objects. It cannot be accessed directly, but its properties are documented below.
Additionally, it cannot be created in the creator menu or with Instance.New()
Inherits Instance
Methods¶
LookAt → void
¶
Parameters: rotation [ Vector3 ]
Rotates the DynamicInstance so that the forward vector looks at the target.
Example
part.LookAt(Vector3.New(12, 34, 56))
Translate → void
¶
Parameters: translation [ Vector3 ]
Moves the transform in the direction and distance of translation.
Example
part.Translate(part.Forward * 5)
Properties¶
Forward : Vector3¶
The forward vector of this DynamicInstance
LocalPosition :
Vector3 = Vector3.New(0, 10, 0)
¶
Specifies the position relative to the parent of an instance.
LocalRotation :
Vector3 = Vector3.New(0, 45, 0)
¶
Specifies the rotation relative to the parent of an instance.
Rotation is in euler angles.
LocalSize :
Vector3 = Vector3.New(1, 1, 1)
¶
The size of the instance relative to its parent.
Position :
Vector3 = Vector3.New(0, 10, 0)
¶
Specifies the position of an instance.
Right : Vector3¶
The right vector of this DynamicInstance
Example
part.Translate(part.Right * 5)
Rotation :
Vector3 = Vector3.New(0, 45, 0)
¶
Specifies the rotation of an instance.
Rotation is in euler angles.
Size :
Vector3 = Vector3.New(5, 10, 4)
¶
Specifies the size of an instance.
Up : Vector3¶
The Y axis of this DynamicInstance