Flash ActionScript制作超酷視覺效果動畫_Flash教程
推薦:解決Fla文件編譯SWF后體積過大經(jīng)�?吹桨婷嫔嫌腥藛栠@個問題。想起我第一次碰到別人給我的源文件有這種情況時,也是很頭疼,往往這些Fla文件中有著一大批動態(tài)文本框。整理了一下具體的解決
效果演示:
具體代碼:
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 ActionScript制作真實的火焰效果如下:點擊這里下載源文件主要代碼:importflash.display.*;importflash.filters.*;importflash.geom.*;importde.popforge.bitmap.Shape;Shape.s
- 相關(guān)鏈接:
- 教程說明:
Flash教程-Flash ActionScript制作超酷視覺效果動畫
。