Like
this
I made one 10X10 pixel bubble attachMovie'd 10 of them & animated them with this,
MovieClip.prototype.air = function(){
this.onEnterFrame = function(){
this._y> -10 ? this._y-=4 : (this._y=85,this._x=random(300));
if(this.L>0){
this._x++;this.C++;this._xscale+=10;this._yscale-=10;
if(this.C>3){
this.L=0;this.C=0;
}
}else{
this._x--;this.C++;this._xscale-=10;this._yscale+=10;
if(this.C>3){
this.L=1;this.C=0;
}
}
}
}
/*------initialize bubbles---------*/
for(i=0;++i<11;){
_root["bb"+i].C = 0;
_root["bb"+i].L = Math.round(Math.random());
_root["bb"+i].air();
}
- MovieClip.prototype.air = function(){
- this.onEnterFrame = function(){
- this._y> -10 ? this._y-=4 : (this._y=85,this._x=random(300));
- if(this.L>0){
- this._x++;this.C++;this._xscale+=10;this._yscale-=10;
- if(this.C>3){
- this.L=0;this.C=0;
- }
- }else{
- this._x--;this.C++;this._xscale-=10;this._yscale+=10;
- if(this.C>3){
- this.L=1;this.C=0;
- }
- }
- }
- }
- /*------initialize bubbles---------*/
- for(i=0;++i<11;){
- _root["bb"+i].C = 0;
- _root["bb"+i].L = Math.round(Math.random());
- _root["bb"+i].air();
- }
You would have to tweek the numbers but the basic formula is there.
Strong with this one, the sudo is.