A Flash Developer Resource Site

Results 1 to 5 of 5

Thread: Question about the Tween Class

  1. #1
    Senior Designer
    Join Date
    Jul 2001
    Location
    Australia
    Posts
    367

    Question about the Tween Class

    Hey just a quick question, I'm utilising the blur filter in the tween class so when you mouse over; the MC will blur horizontally..

    Typically if I were to use the _alpha property for example, I would put the starting point as this._alpha rather than a fixed value.

    How do I go about doing this with blur? I tried this.blurX but doesn't work,

    Cheers!

    PHP Code:
    import mx.transitions.Tween;
    import mx.transitions.easing.*;
    import flash.filters.BlurFilter;


    myMC.onRollOver = function() {
        var 
    myBlur:BlurFilter = new BlurFilter(001);
        var 
    blurTween:Tween = new Tween(myBlur"blurX"Regular.easeInOut0400.3true);

        
    blurTween.onMotionChanged = function() {
            
    myMC.filters = new Array(this.obj);
        };
    }; 

  2. #2
    Senior Member
    Join Date
    Jun 2008
    Posts
    549
    Theres a plugin called tweenlite at: blog.greensock.com/tweenlite/ which is easier to use than the built in tween in Flash.

  3. #3
    Senior Designer
    Join Date
    Jul 2001
    Location
    Australia
    Posts
    367
    Thanks I'll check that out.

    I'm actually building a component which I may sell further down the line, I don't think I could use this commercially. Does anyone know if there is a built in way to check where the current blurX is? (like this.alpha)

  4. #4
    Senior Designer
    Join Date
    Jul 2001
    Location
    Australia
    Posts
    367
    Bump

  5. #5
    Flash/Flex Developer samac1068's Avatar
    Join Date
    Apr 2007
    Location
    Here, no there
    Posts
    1,813
    Not sure, haven't done it before, but the Tween class has a position property that is suppose to tell you info about the current tween.
    Some people are like Slinkies, not really good for anything, but they bring a smile to your face when pushed down the stairs.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center