Sul frame
supponendo che il mc da spostare sia istanziato mccodice:MovieClip.prototype.tweenTo= function (x,y,steps) { this._xstep=(Number(x)-this._x)/Number(steps); this._ystep=(Number(y)-this._y)/Number(steps); this._steps=steps; this.onEnterFrame=function () { if (this._steps) { this._x+=this._xstep; this._y+=this._ystep; this._steps--; } else { delete this._xstep; delete this._ystep; delete this._steps; delete this.onEnterFrame; } } }
richiami la proto
ovviamente puoi mettere il richiamo o su un frame o associarlo al pulsantecodice:mc.tweenTo(0,400,30);//0=posizione x da raggiungere 400=pos Y, 30 velocità/step

Rispondi quotando