aqui el codigo que tengo
clip10inicioX = mc1._x;
clip10inicioY = mc1._y;
//
MovieClip.prototype.mover = function(x, y) {
this.velocidad = 2;
this.x = x;
this.y = y;
this.onEnterFrame = function() {
// movimiento con deceleración
// usando la formula:
// objeto.propiedad=(objeto.propiedad+velocidad*objeto.propiedad)/velocidad+1
this._x = (this.x+this.velocidad*this._x)/(this.velocidad+1);
this._y = (this.y+this.velocidad*this._y)/(this.velocidad+1);
// detener onEnterFrame cuando se aproxima a su destino
// esto lo hago calculando la diferencia entre la posición
// destino y la actual.
if (Math.abs(Math.round(this.x)-Math.round(this._x)) == 1) {
this._x = this.x;
this._y = this.y;
delete this.onEnterFrame;
}
};
};
// -- arrastrar
mc1.onPress = function() {
this._alpha = 50;
this.gotoAndStop("arrastrar");
startDrag(this);
};
// -- soltar
mc1.onRelease = mc1.onReleaseOutside=function () {
stopDrag();
this._alpha = 100;
// si mc19 se encuentra sobre el área de mc29 pegar
if (this.hitTest(_root.mc23)) {
this.mover(mc23._x, mc23._y);
this.gotoAndStop("pegar");
_root.mc19.enabled=false;
score+=1;
} else {
this.mover(clip10inicioX, clip10inicioy);
this.gotoAndStop("soltar");
}
};
