0 Replies Latest reply: May 20, 2010 5:39 PM by Kim Isola RSS

    FAQ: How do I loop an animation or action sequence?

    Kim Isola Employee Hosts
      The proper way of looping an Action Sequence in a Catalyst project is to open it in Flash Builder and add a couple lines of ActionScript code. Many people don't want to make the jump over to Builder though, so here is a quick and dirty way of looping an Action Sequence in Catalyst.

      1. Generate a simple, short video clip to use as a timer
      2. Bring it into Catalyst, and place it on the ArtBoard
      3. Set it to Loop in the Properties Inspector. Also set it to Auto Play if you wish for your ActionSequence to begin at application start.
      4. Click your video, and add an "On Play Complete" Action Sequence
      5. Add the effect(s) you want to your action sequence
      6. Hide the video by resizing it and setting its opacity to zero.

       

      If you are courageous enough to experiment with Builder, then you can do the following.
      1. Save your project out to an fxp
      2. Import the fxp into Builder
      3. In the main.mxml file, locate the action sequence you wish to repeat (it will look something like <s:Parallel id="Sequence1"> .... </s:Parallel>)
      4. Add "effectEnd="SequenceX.play()" to the Parallel tag, where X is the number. The new code will look like
        <s:Parallel id="Sequence1" effectEnd="Sequence1.play()"> ... </s:Parallel>

      You may, alternatively, want to check out something like FlashUtils.Timer.

      Answered by: Bear Travis. See entire discussion.

      More help: