Search code examples
flashactionscript-3flash-cs5tween

Flash dynamic transitions


Just wanted to know what the best way of transitioning between pages in flash. Basically i have 5 pages, each of them have an intro animation (slide in, slide out). I know how to make them transition IN but say they click on some random page out of the 5 how do i transition out of the current page then somehow tell it to go to the one the user selected?

This is timeline based.

Any help appreciated, thank you.


Solution

  • You will need to have a clickedPage variable which is set when the user clicks on a specific page.

    Then you'll have a currentPage variable, if the clickedPage value is different from the currentPage go to the currentPage animation out frame.

    At the end of the animation , update the currentPage value with the clickedPage value and start the animation in