TweenLite AS3 在 x 轴问题上移动
我正在尝试使用 TweenLite AS3 创建一个简单的动画效果,有一个影片剪辑(“selectedFrame”),每隔几秒在舞台上的 x 轴上移动一次。其他 TweenLite 效果(使用“alpha”函数)工作正常,但由于某种原因我无法让这个简单的转变工作。 这是我尝试移动 MC 的代码块:
TweenLite.to(selectedFrame, 1, {x:501.6});
TweenLite.to(selectedFrame, 1, {x:536.8, delay:3, overwrite:1}); TweenLite.to(selectedFrame, 1, {x:572.1, 延迟:6, 覆盖:1}); TweenLite.to(selectedFrame, 1, {x:607.5, 延迟:9, 覆盖:1}); TweenLite.to(selectedFrame, 1, {x:501.6, 延迟:12, 覆盖:1});
(这一切都位于一个基于另一个影片剪辑连续循环的函数内,否则工作正常)
非常感谢任何和所有帮助。
I'm trying to create a simple animation effect with TweenLite AS3, having a movieclip ("selectedFrame"), shift on the x-axis on the stage every few seconds. Other TweenLite effects (using the 'alpha' function) are working fine, but for some reason I can't get this simple shift to work.
Here is the block of code I'm trying to move the MC with:
TweenLite.to(selectedFrame, 1, {x:501.6});
TweenLite.to(selectedFrame, 1, {x:536.8, delay:3, overwrite:1});
TweenLite.to(selectedFrame, 1, {x:572.1, delay:6, overwrite:1});
TweenLite.to(selectedFrame, 1, {x:607.5, delay:9, overwrite:1});
TweenLite.to(selectedFrame, 1, {x:501.6, delay:12, overwrite:1});
(this is all located within a function that continuously loops based on another movieclip, and otherwise is working fine)
Any and all help is greatly appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
尝试添加缓动:
Try adding the easing: