A Flash Developer Resource Site














Internet Commerce

Partners & Affiliates














Developer Channel

internet.com


Featured Flash FLA
Gallery Downloads 11336 Flash Movies | 2 New Flash Movies Added
What's New | Top 100

Featured FLA

» Author: Surjit Dhami
» Title: Book
» Description: Book
» More by Surjit Dhami


Random FLAs | Add Flash Movie
Featured Flash Site
Gallery Downloads 5848 Flash Sites | 0 New Flash Links
What's New | Top 100 Flash Site

Featured Site

» Posted in the Flash Kit Links section
» Title: All-American Rejects
» Description: Get to know this great band by exploring their "practice room".


Random Links | Add your own Flash Related Links
Flash Tutorials 1277 Tutorials 7 New Tutorials Added!
What's New | Top100

» Create xml slideshow with free template
» How to Insert a Multilingual Subtitle Into Your Flash Video Studio
» How to Create Cool Halloween Slideshow
» Debugging flash using the Firebug console
» Create Flash Slideshow on Blogger
» FLASH TRICKS IN WEB ADVERTISING: FLASH BANNERS
» HTML Photo Gallery Tutorial
» Create your first flash site – PART 1
» How to Make a Flash Photo Gallery
» Unknown Tag: Title10
Random Tutorial | Add Site

Webmaster (IL)
Next Step Systems
US-IL-Chicago

Justtechjobs.com Post A Job | Post A Resume


Tutorials Home What's New Top Rated Submit myTutes Random!

Search Tutorials


Tutorials Tutorials » Utilities

Categories Buffer Bar and Preloader
Author: Gavin Powell | Website: http://www.cs.cf.ac.uk/user/G.R.Powell/ |

 
Page 7
«prev 1 2 3 4 5 6 7 8 next»

Preloader - Loading

Now we need to work out which frame we need to check is loaded using the needle position, start and end point of the movie and the amount the user wants to buffer. Easy! :-)

In the expression box put Int(start_frame+((buffer_length/100)*((end_frame-start_frame) / needle_points)*position)) The position is the needle position on the dial and will range from 0-8.

Note: You must convert the answer to an integer using Int() as flash won't convert it itself when checking if that frame is loaded, i.e. it cacn't check if frame 112.34 is loaded.

Then choose Set Variable from the menu and position as the variable and position+1 as the value, make sure that it is an expression not a String literal. Then choose Go To from the drop down menu and choose expression and enter GetProperty ( "", _currentframe )+2 and check the Go To and Play box.

Now you could have entered numbers instead of using these variables but what if you want to add a couple of frames somewhere in the preloader for some reason you would have to alter all these values, so using these variables is more dynamic. Also some people put the preloader in a different scene whereas I just plonk it before the rest of the movie so the start point of my movie can change as well. These can become even more dynamic when you write one frame action which can then recalled by other frames. This saves on your writing actions again and again and keeps file sizes down.

Anyway back to it. In the next keyframe Make a frame action of Go To and Play(GetProperty ("",_currentframe)-1). Now highlight these two keyframes and copy frames from the edit menu. Then Paste Frames for the next 16 frames so that they co-incide with the needle pointer positions. The first frame action checks if the relevant frame is loaded if it is it increments the position variable and the movie progresses two frames to the next If Frame is Loaded. If it is not then it progresses to the next frame which then returns to the previous frame. This is just a little loop that continues until the required frame is loaded, it needs to loop so that the load status is constantly checked.

Hint:- When writing anything but the simplest of action scripts use the script editor as it will check for syntax errors, if there are errors they won't show at runtime.

«prev 1 2 3 4 5 6 7 8 next»

» Level Intermediate

Added: : 2000-10-04
Rating: 5.76 Votes: 183
Hits: 9209
» Author
No information about the author has been provided
» Download
Download the files used in this tutorial.
Download (98 kb)
Get conversion and unzipping tools for PC and Mac here!

» Forums
More help? Search our boards for quick answers!

Please rate this tutorial, 10 is the top rating, you can also click the comments link to read/write a review.
10 9 8 7 6 5 4 3 2 1
Read or Post Comments
 
   
 

internet.commediabistro.comJusttechjobs.comGraphics.com

Search:

WebMediaBrands Corporate Info

Legal Notices, Licensing, Reprints, Permissions, Privacy Policy.
Advertise | Newsletters | Shopping | E-mail Offers | Freelance Jobs