--Reducing your Flash file size--

-------Reducing File Size in your Flash Movie/Game-------

1-If it’s possible animate through actionscript

Unless you’re going for your own unique style of frame-by-frame animating its not necessary to use tweening
You could use a motion tween moving an image across the screen and rotating it, the filesize for mine resulted in 18.6kb
Or you could animate the image using actionscript with a code something like like this

onClipEvent (enterFrame) {

The filesize for this resulted in 18.3kb which isn’t actually a great drop but it helps alot when you use it in a large movie

2-Dynamically loading images/text

A useful function of the more recent Flash versions is the ability to dynamically loading images and text this saves filesize but can be quite difficult to use. I’ve never actually used this before so here is a tutorial I found

Taken from http://www.flashcircle.com

  1. Start a new movie – mine had dimensions of 350x350 pixels.

  2. Open the components panel by hitting ctrl+f7.

  3. Drag 3 instances of the PushButton component on the stage, and select the first PushButton component in Frame 1.

  4. The component’s parameters are displayed in the Property inspector.

  5. Type “hen” into the Property inspector Instance Name text box.

  6. Type “call_Img” for the Click Handler name.

  7. Type “Show Hen” for the Label name. Similarly, for other buttons, type:

ButtonName, LabelName, ClickHandlerName

(a). hen , Show Hen , call_Img

(b). cheetah , Show Cheetah , call_Img

©. hen , Show Hen , call_Img

  1. Select Frame1. Press F9 (Windows) to open the actions box.

  2. Insert the action:

filejpg = function(picName)


//set the position of picHolder movie clip to center of stage

picHolder._x = 80

picHolder._y = 10

//Load the pictures



function call_Img(name)


//Give correct path here

if(name == hen){filejpg(“hen.jpg”;}

if(name == cheetah){filejpg(“cheetah.jpg”;}

if(name == tiger){filejpg(“tiger.jpg”;}


//create a empty movie clip for holding the Jpg pics

createEmptyMovieClip(“picHolder”, 1);

That’s all it takes! Before you test the movie, ensure that the pictures are in the same folder as the movie.

3-The “Call” action

A simple action which will repeat actions you have on one frame and uses it on another.

Call ([“Frame Label”])

You must label the frame first and the frame must be loaded otherwise the call action will be ignored

4-Turn all items which are to be reused into symbols

This way the computer only needs to load it once and not on every frame that the item appears

Of course if your movie still runs very slowly then you can always just set the quality to low or reduce the quality of the sound