Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...

TimelineMax

.startTime()

.startTime( value:Number ) : *

Gets or sets the time at which the animation begins on its parent timeline (after any delay that was defined).

Parameters

value: Number

(default = NaN) — Omitting the parameter returns the current value (getter), whereas defining the parameter sets the value (setter) and returns the instance itself for easier chaining.

Returns : *

Omitting the parameter returns the current value (getter), whereas defining the parameter sets the value (setter) and returns the instance itself for easier chaining.

Details

Gets or sets the time at which the animation begins on its parent timeline (after any delay that was defined). For example, if a tween starts at exactly 3 seconds into the timeline on which it is placed, the tween's startTime would be 3.

The startTime may be automatically adjusted to make the timing appear seamless if the parent timeline's smoothChildTiming property is trueand a timing-dependent change is made on-the-fly, like reverse() is called or timeScale() is changed, etc. See the documentation for thesmoothChildTiming property of timelines for more details.

This method serves as both a getter and setter. Omitting the parameter returns the current value (getter), whereas defining the parameter sets the value (setter) and returns the instance itself for easier chaining.

var start = myAnimation.startTime(); //gets current start time
myAnimation.startTime(2); //sets the start time
Copyright 2017, GreenSock. All rights reserved. This work is subject to theterms of useor for Club GreenSock members, the software agreement that was issued with the membership.
×