웹디자인 강의
Flash 하이얀 눈송이를 웹에 날려 볼까요?
2003.12.24 01:55
복사용 액션
1. 무비클립 액션
onClipEvent (enterFrame) {
this._x += Math.random ()*(this._xscale)/10 ;
this._y += Math.random ()*(this._xscale)/10 ;
if ( this._x > 500 ) {
this._x =0;
}
if ( this._y > 400 ) {
this._y =0;
}
}
2. 프레임 액션
for (i=1; i<100; i++) {
fiocco.duplicateMovieClip("fiocco"+i, i);
eval("fiocco"+i)._x = Math.random()*500;
eval("fiocco"+i)._y = Math.random()*400;
eval("fiocco"+i)._xscale = Math.random()*70+30;
eval("fiocco"+i)._yscale = eval("fiocco"+i)._xscale;
eval("fiocco"+i)._alpha = eval("fiocco"+i)._xscale+20;
}
stop ();