tweenline_stagger_fromto

Syntax:

tweenline_stagger_fromto(targets_array, duration, from_vars, to_vars, stagger, [position], [wave_amount]);
Argument name Type Description
targets_array Array of instances or objects The target instances to tween
duration real The duration in seconds or frames (for frames based tweens)
from_vars Array The special vars array for the starting values. For more info about the vars array see the Animation documentation.
to_vars Array The special vars array for the ending values. For more info about the vars array see the Animation documentation.
stagger real Amount of time to stagger the start time of each tween.
position string|real The special position parameter. See tweenline_add for more info.
wave_amount integer How many instances will grouped in one "wave"

Returns: (Array of Tweens) Array with the tweens that has been created

Description:

Tweens an array of targets from and to a common set of destination values, but staggers their start times by a specified amount of time, creating an evenly-spaced sequence with a surprisingly small amount of code.

The parameter stagger is the amount of time in seconds (or frames if the timeline is frames-based) to stagger the start time of each tween.

The difference between tweenline_stagger_fromto and tween_stagger_fromto is that the first adds the tweens to the current tweenline that is in edit mode.

For more info about the edit mode, see tweenline_edit

For more info about the optional position parameter, see tweenline_add

For the optional parameter wave_amount, see tween_stagger_to

Returns an array of the indexes of the tweens that has been created