Results 1 to 4 of 4

Thread: Need Advice In Making This File More AS

  1. #1
    Join Date
    Apr 2006
    Posts
    584
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Need Advice In Making This File More AS

    If anyone would mind taking the time to take a look at my file, I have got the AS working pretty nicely although have still needed to make my timeline quite long, if anyone can look and let me know what else I could control with AS would be greatly appreciated!

  2. #2
    Join Date
    Apr 2007
    Location
    Phoenix, AZ
    Posts
    64
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    This seems like a pretty vague question-- there are a LOT of thing you can do, it just depends on what you're trying to accomplish.

  3. #3
    Join Date
    Mar 2007
    Location
    Currently: New York/Philadelphia
    Posts
    2,735
    Thanks
    3
    Thanked 519 Times in 507 Posts

    Default

    Quote Originally Posted by tomyknoker View Post
    If anyone would mind taking the time to take a look at my file, I have got the AS working pretty nicely although have still needed to make my timeline quite long, if anyone can look and let me know what else I could control with AS would be greatly appreciated!
    You can take away the thing that is making your timelong so long -- the motion tweens.

    You can use the Tween and easing classes to accomplish the same thing.

    First, convert your "bg" graphic into a movieclip (instance name bg) and use the following actionscript to move it:

    Code:
    import mx.transitions.Tween; 
    import mx.transitions.easing.*;
    
    new Tween (bg, "_x", Regular.easeOut, bg._x, bg._x + 20, 2, true)
    This will explain everything reasonably well: http://www.kirupa.com/developer/actionscript/tween.htm

    Post back here if you have any questions.

  4. #4
    Join Date
    Apr 2007
    Location
    Phoenix, AZ
    Posts
    64
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    You want to make sure to look at the info on the onMotionFinished event associated with the Tween class (in the same kirupa.com page above). That can really help when you have things happening in sequence.

    Code:
    var bgTween:Tween = new Tween (bg, "_x", Regular.easeOut, bg._x, bg._x + 20, 2, true)
    
    bgTween.onMotionFinished = function(){
         // add items here to execute after tween is finished
    }

Bookmarks

Posting Permissions

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