Sunday, June 28, 2009

Flash SWFs Slide Show in AS 3.0


Playing above is a set of “Car Driving” Animations that my students made.

Unfortunately there is sometimes a glitch when the slide show plays through the first time. As you may see above, it sometimes plays "one and a bit" of the movie, then does a wobbly jump to the next movie. This glitch does not occur when the Flash slide show is ran locally on a stand alone computer, and it stops occurring when the slides go through for their second and third times etc.

The first time through, this Blog page has to download the movies from the internet, and this probably causes the delay glitch. However, second time through, the browser is probably getting the images from the temp files on the user's hard drive, and so faster load speed, and no delay glitches.
(If I ever find out how to remove the glitch, I will go back and modify this blog page. Maybe I don't have my Browser buffering set up properly ?).

The main reason I needed to make a slide show was to be able to present some student work at an open day and/or school assembly. And running stand alone on my laptop, it works just fine with never a jumpy glitch. :)

In fact, I had been wondering for quite a while how to make a set of individual Flash SWF files into an automated slideshow.

The answer to these ponderings was found at the “Flash and Math” website, in their “External Clips in Flash CS3” tutorial. This tutorial goes through step-by-step, how to create a FLA project that uses Action Script 3.0 code that runs several SWF files one after each other.

The resulting SWF provides a looping slide show of our SWF files.

The component SWF files that are in the Slide Show, need to be ActionScript 3.0 SWF files that play in a continuous loop, and do not themselves contain any Actionscript.

The tutorial for making the Slide Show is in two parts, at these Web addresses:

http://www.flashandmath.com/intermediate/externalclips/ext_clip1.html

http://www.flashandmath.com/intermediate/externalclips/ext_clip2.html

(There are also some further Parts 3 and 4 tutorials, but these are on how to control FLV video files using Actionscript, and not about SWF files.)

The Parts 1 and 2 web pages also have downloadable finished “FLA” files.

So if you just need to animate some SWF files, (and don’t have time to learn the ActionScript code), then download their finished FLA file, and rename your SWF files to clip0.swf, clip1.swf, and clip2.swf. Then make sure these files are located in the same directory as the downloaded FLA file.

The “Car Driving” animations that the students made, were developed by following an excellent set of instructions by Denise Etheridge, located at:
http://www.baycongroup.com/flash/01_flash_5_tutorial.htm

The PDF document below, gives full instructions and details about setting up a Flash Slide Show of SWF files. It also includes how to put the end product onto the web in a blog page.




If you would like to have your own copy of this PDF, then simply click the save disk icon button on the PDF viewer, and you should be able to save it to your own hard disk.

Alternatively, you can view or save the PDF by clicking the link below:
(Click the Browser's Back Button to return to this Blog).



Enjoy,
Passy