
Код:
MovieClip.prototype.minimize = function(x, y, xscale, yscale, speed){
this.x = x
this.y = y
this.speed = speed
this.xscale = xscale
this.yscale = yscale
this.onEnterFrame = function(){
this._x += (this.x - this._x)/this.speed
///то же самое для всего остального
if(здесь пишем условие - например, все параметры пришли куда надо){
delete this.onEnterFrame
}
}
}