jquery tweenmax时间轴动画

jquery tweenmax时间轴动画
<pre>
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="utf-8" />
<title>{$title}</title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1,user-scalable=no" />
<meta name="format-detection" content="telephone=no" />
<!-- Link Swiper's CSS -->
<include file="commonheader" />
</head>

<body>
<include file="jiazai" />
<include file="commonmokuai" />
<div class="showcontainer" style="display: block;">
<div class="ddd1" style="position: absolute;left:10%;top:20%;">111111111</div>
</div>
<script src="{$yuming}/js/TweenMax.js"></script>
<script src="{$yuming}/js/DrawSVGPlugin.min.js"></script>
<include file="commonfooter" />
<script type="text/javascript">
var times=0;
$(function() {
var tl = new TimelineLite();

var tm = new TimelineMax();
// tm.to($('.ddd1'), 3, {left:300,delay:0,repeat: 1, yoyo: true,repeatDelay: 1,ease: Linear.easeNone});//将一个动画添加到时间轴
// tl.add(tm);//将一个动画添加到时间轴
//
tm.to($('.ddd1'), 3, {left:300,delay:0,repeatDelay: 1,ease: Linear.easeNone});//将一个动画添加到时间轴
tl.add(tm);//将一个动画添加到时间轴
//
tl.pause();

setInterval(function(){
times+=0.1;
tl.progress(times);
},200)

})
</script>
</body>

</html>
</pre>

posted @ 2019-11-12 15:42  newmiracle宇宙  阅读(215)  评论(0编辑  收藏  举报