or u can use another Tween Class ( mx.effects.Tween) .

example :

import mx.effects.Tween;
import mx.transitions.easing. *;

var q:MovieClip = this.createEmptyMovieClip( "quad_mc" ,
this.getNextHighestDepth() );

q.beginFill( 0x000000, 100 );
q.lineTo( 100 , 0 );
q.lineTo( 100 , 100 );
q.lineTo( 0 , 100 );
q.lineTo( 0 , 0 );
q.endFill();

function onTweenEnd (values:Array)
{
   this.onTweenUpdate (values);
}
function onTweenUpdate (values:Array)
{
   q._x = values [0];
   q._xscale = q._yscale = values [1];
   //here u can put any properties
}

var tw : Tween = new Tween (this, [0, 0], [250, 100], 1000);
// here u can use any equation function like Back, Elastic, Strong ...
tw.easingEquation = Strong.easeInOut;

MauricioMassaia

On 12/22/06, Dave Mennenoh <[EMAIL PROTECTED]> wrote:

You can do it with a Delegate:

import mx.transitions.Tween;
import mx.transitions.easing.*;
import mx.utils.Delegate;

class tweeny extends MovieClip {
private var theClass;

function test() {
  theClass = this;
}

function onLoad() {
  this["mc"].onRelease = function():Void  {
  var p:Tween = new Tween(_parent["mc2"],, "_y",Regular.easeOut, 0, 50,
10,
false);
  var ch = function(){
   trace(this);
  }
  p.onMotionChanged = Delegate.create(theClass, ch);
};
};
}




Dave -
Head Developer
www.blurredistinction.com
Adobe Community Expert
http://www.adobe.com/communities/experts/

_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to