5 Replies Latest reply on Sep 16, 2009 12:32 PM by kglad

    random text scrolling mask

    vanroojdotcom

      Does anyone have a tutorial or an example to point me to?

       

      It's a flash banner with a simple image, and then I want an xml of quotes that get pulled into the banner a mask scrolls in and then when it scrolls out, the words have changed to another random quote?

       

      When I mean scroll I mean the quote remains in place but a mask appears (from right to left) that covers the words, once the 'mask has got to the left side of the quote all the letters are gone - the mask the reverses (right to left) to reveal a new quote.

       

      Like the home page flash the Adobe website.

       

      Hope there's a tutorial somewhere it's just I don't know the relevant application phrase to search -

       

      "Random Quotes from XML mask swap in Flash" isn't getting the right results!

       

      Many thanks

      Vanroo

        • 1. Re: random text scrolling mask
          kglad Adobe Community Professional & MVP

          search for a tutorial on using the Tween class or one of the other tween classes freely available (like TweenLite).  once you know how to use one of the tween classes to animate your mask you can use an onComplete or onTweenFinished  function to display your various quotes.

          1 person found this helpful
          • 2. Re: random text scrolling mask
            vanroojdotcom Level 1

            Thanks for the reply. I would normally create tweens using the timeline. So you are saying:

             

            Forget about the timeline

             

            1) First learn how to block out the text using a tween mask - controlled by Actionscript

             

            2) Then learn how to pull in a quote (from an xml document) using onComplete or onTweenFinished  ie: "onComplete load new quote randomly"

             

            3) Set the mask to loop so that it continually masks and retrieves a new quote

             

             

            Is this near to the solution?

             

            Do you have any links that may help me?

             

             

            Many thanks

            Vanrooj

            • 3. Re: random text scrolling mask
              kglad Adobe Community Professional & MVP

              forget about the timeline.  that will be much too cumbersome.

               

              1.  learn how to tween a movieclip's width and/or height. 

               

              2.  learn how to load and parse an xml file if that's where you will store the quotes to be used by your flash.  store the quotes in an array

               

              3. select and display a random array element each time your mask tween completes unmasking the previous quote.

               

              if you know nothing about flash actionsript tweens i'd recommend using tweenlite (or any number of 3rd party tweening classes).  they're just about all easier to use and have more features than the flash Tween class.

              • 4. Re: random text scrolling mask
                vanroojdotcom Level 1

                Thanks for the help

                 

                I'll check out your advice.

                 

                 

                Many thanks

                Vanrooj

                • 5. Re: random text scrolling mask
                  kglad Adobe Community Professional & MVP

                  you're welcome.