A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: finishing a loop before changing scene

  1. #1
    Junior Member
    Join Date
    Aug 2000
    Posts
    2
    I have a scene with a looping animation and a button which on press moves on to a new scene. how can I ensure the looping animation finishes its current loop before moving on to the next scene? (and doesn't just jump to the new scene mid loop?)

    any tips appreciated

    thnx

  2. #2
    Senior Member
    Join Date
    Mar 2000
    Posts
    597
    To finish playing a movie after a button has been clicked :

    On the button use the script

    On (Release)
    Set Variable: "/:gotoscene" = true
    End On

    Make sure "true" is an expression. It must not have quotes.

    And in the last frame of the movie clip that you want to finish playing put

    If (/:gotoscene)
    Go to and Play (Scene 2, 1)
    End If

    The Go to and play will only happen if the button has been clicked.

    By the, it's much better to use movie clips in place of scenes. It will give you much more control and eliminate lots of problems in the future.

    Let me know if you need more,

    Rich.


  3. #3
    Junior Member
    Join Date
    Aug 2000
    Posts
    2
    thanks rich,

    worked a treat. have ditched the scenes in favor of movie clips now too.


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