.recent( ) : Animation
var tl = new TimelineLite();
tl.to('.green', 99, {x:100, repeat:5})
.to('.grey', 1, {y:200}, 0.5)
.to('.orange', 1, {scaleX:2}, tl.recent().endTime() + 3);//此recent()得到的是最新添加的第二个动画
.box {
width:50px;
height:50px;
position:relative;
border-radius:6px;
margin-top:4px;
}
.green{
background-color:#6fb936;
}
.orange {
background-color:#f38630;
}
.grey {
background-color:#989898;
}
var tl = new TimelineLite();
tl.to('.green', 9, {x:100, repeat:5})
.to('.grey', 1, {x:200}, 0.5)
.to('.orange', 1, {x:400}, tl.recent().endTime() + 3);//tl.recent()得到的是最新添加的第二个动画
转载原创文章请注明:文章转载自:TweenMax中文网 [https://www.tweenmax.com.cn]
本文地址:https://www.tweenmax.com.cn/api/timelinemax/recent()