Flash ActionScript制作超酷视觉效果动画-Flash教程
来源:设计前沿收集整理 作者:
更新时间:2008-03-04
点击:
效果演示:
具体代码:
onClipEvent (load) {
x=0 //where the dot is
y=0 //where the dot is
xmove=0 //it's movement
ymove=0 //it's movement
}
onClipEvent (enterFrame) {
xmove = (_root._xmouse-_x-x)/10 //math
ymove = (_root._ymouse-_y-y)/10 //math
x =xmove (_root._xmouse-_x-x)/10 //math
y =ymove (_root._ymouse-_y-y)/10 //math
clear()
lineStyle(1,000000,100)
moveTo(oldx,oldy)
lineTo(x,y)
oldx=x //this is so that in the next frame it knows where the dot was last frame
oldy=y //this is so that in the next frame it knows where the dot was last frame
_rotation-- //This is negative on two of the movieclips (that initially have an opposite rotation to eachother), and positive on the other two.
}
相关Flash教程:
最新评论:
评论加载中....
发表评论:不能超过250字节,请自觉遵守互联网相关政策法规.
- 昵称: 验证:







