videoLinks
June 24th, 2007 . by polyGeek![]() |
Watch a video tutorial on creating links to other videos in you video interface. |
videoLinks allow you to create links to other videos in your video interface.
Creating a videoLink is similar to creating the videoWindow. Somewhere inside your videoLink MovieClip there needs to be a dynamic TextField with a text value that is the path to the video you would like to play when the user clicks on the MovieClip.
If you have more than one videoLink you must differentiate their instance names by appending an index number to the end of the instance name.
Example, if you have 3 videoLink MovieClips then you could give them instance names of videoLink1, videoLink2, videoLink3. However, the index numbers do not need to be sequential, just make sure they are unique or you will get an error when publishing the FLA: 256 levels of recursion exceeded.
You can also create next and prev (previous) buttons for the user to navigate through the videoLinks. The order of navigation is based on the index number appended to the videoLink MovieClips.
The videoLinks also support states for the currently playing video. To enable states create a keyframe inside your videoLink MovieClip with a frame label of nowPlaying. When the user clicks that MovieClip the nowPlaying state will be displayed. Otherwise it will display frame 1. The next/prev MovieClips are also integrated with the videoLink states.
If the video that plays at startup is also one of the videoLink MovieClips then it will automatically display that MovieClip in the nowPlaying state. Otherwise all of the videoLinks will display frame 1. In that case if the user clicks on either the next or prev button the videoLink with the lowest index number will always be selected first.

