TweenInfo
Overview
A configuration object that defines the behavior of a tween animation. It is used when TweenService:Create() is called to control detailed behaviors of tween including duration of property change, type of interpolation, and loop settings.
The property values of TweenInfo cannot be modified after creation. If you need a different setting, a new TweenInfo needs to be created.
Constructors
new
Creates a new TweenInfo object including the configuration value needed to execute tween behaviors using passed factors.
The created TweenInfo is used later when tween is configured in TweenService.
Parameters
number InTime
The time in seconds that the tween animation takes to progress from start to finish. The higher the value, the slower the change.
Enum.EasingStyle InEasingStyle
Determines in which curve tween will change over time. With this, you can make it smooth or accentuate a certain motion.
Enum.EasingDirection InEasingDirection
Sets whether acceleration or deceleration is applied at the start or end point of the tween.
number InRepeatCount
The number of loops to play the tween. A value of -1 means an infinite loop.
boolean InReverses
Specifies whether or not to play the tween repeatedly. When enabled, the tween reverses direction after reaching its target value and plays back toward its starting point.
number InDelayTime
The time in seconds to wait before the tween starts. It is useful for sequencing multiple animations.
Return
TweenInfo
The created TweenInfo object.
Code Samples
Properties
Time
number
The time in seconds that the tween animation takes to progress from start to finish.
Code Samples
EasingStyle
EasingStyle
A property that determines the curve shape by which the tween changes over time.
Code Samples
EasingDirection
EasingDirection
A property that determines whether acceleration or deceleration is applied at the start or end point of the tween.
Code Samples
RepeatCount
number
A property that specifies the number of loops to play a tween animation. -1 means an infinite loop.
Code Samples
Reverses
boolean
A property that determines whether to play the tween backward during repetition after reaching its target value.
Code Samples
DelayTime
number
A property that specifies the waiting time before the tween is executed.
Code Samples
Methods
Last updated