• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL

Lesson 11. Assembling the Complete Project

Lesson 11. Assembling the Complete Project

In the previous two lessons, you built most of the functionality for both upper.fla and lower.fla. However, a number of loose ends remain. For example, at the moment the two files are disconnected: The down button (in Upper Hell) and the up button (in Lower Hell) don't do anything. Also, the Reset button in Lower Hell doesn't do anything. A smaller issue—but you'll fix it anyway—is that the four monsters snap back into a position a few pixels off where they started.

When testing SWFs from within Flash, you can view information about how the movie will download over different Internet connection speeds, from modems to T1 connections. At the same time, you can test your preloaders.

The final issue that needs to be addressed requires a bit of a background. Both movies lack preloaders. A preloader is a feature that adds a screen up front that informs the user that the movie is loading. This serves two purposes. First, the user isn't faced with a blank screen for several seconds (or in extreme cases, minutes) while the movie downloads, wondering whether the site is broken or if the browser crashed. Second, Flash is a streaming medium, which means that Flash tries to start playing frames before they are all done downloading, which could break certain functionality. A preloader prevents the main movie from showing until all the frames have downloaded.

Along the way, you will be introduced to a few new concepts and techniques. You will learn about initializing movies, which simply means setting the initial state of the movie, including the default values of all variables. In addition, you will learn about functions. Functions are blocks of code that you create, group as a block, and name. You can use one of these custom functions just as you use a built-in action.


In this lesson, you will:

  • Connect the two movies using the loadMovieNum() action

  • Create a script that initializes many of the values used in the movie, to give it a starting state

  • Create and use a custom function

  • Build a preloader for each of the movies


This lesson takes approximately 1½ hours to complete.


Starting Files:



Completed Files:





Not a subscriber?

Start A Free Trial

  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint