flash点滴

上一篇 / 下一篇  2008-05-13 15:48:31 / 个人分类:Flash设计

做水泡效果

for(i=0);i<40;i++){    //控制水泡的数量

duplicateMovieClip("shui","shui"+i,i);  //复制水珠

temp=eval("shui"+i)

with(temp){           //设置属性

_x=random(400)    //坐标

_y=random(150)+300

_xscale=_yscale=random(40)+20    //缩放

_alpha=random(40)+60     //透明度

}

shui._visible=false    //设置原来的mc不显示

}

//以上是复制一定数量的水泡,设置它们位于场景底部的一定的位置

选择shui影片剪辑,打开“动作”面板,添加AS动作语句:

onClipEvent(load){

speed=random(5)+3

}

onClipEvent(enterFrame){

this._y-=speed

this._x+=random(3)-random(3)

if(this._y<-10{

this._y=random(310)-10

}


TAG:

 

评分:0

我来说两句

显示全部

:loveliness: :handshake :victory: :funk: :time: :kiss: :call: :hug: :lol :'( :Q :L ;P :$ :P :o :@ :D :( :)

我的栏目

日历

« 2008-07-07  
  12345
6789101112
13141516171819
20212223242526
2728293031  

数据统计

  • 访问量: 1526
  • 日志数: 6
  • 图片数: 6
  • 建立时间: 2008-05-09
  • 更新时间: 2008-06-04

RSS订阅

Open Toolbar