preloaded

This is a discussion on "preloaded" within the Flash & Multimedia Forum section. This forum, and the thread "preloaded are both part of the Design Your Website category.


 Subscribe in a reader

Go Back   Webforumz.com > Main Forums > Design Your Website > Flash & Multimedia Forum

Notices




Closed Thread
 
LinkBack Thread Tools
  #1  
Old May 15th, 2004, 13:08
benbacardi's Avatar
Highly Reputable Member
Join Date: Feb 2004
Location: United Kingdom
Age: 20
Posts: 611
Thanks: 0
Thanked 0 Times in 0 Posts
preloaded

how can i make an flash preloader? i've tried many different sites but none of them work

help me please! thanx
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!

  #2  
Old May 15th, 2004, 13:34
Highly Reputable Member
Join Date: Aug 2003
Location: Australia
Posts: 662
Thanks: 0
Thanked 0 Times in 0 Posts
www.haeglodesigns.com/load.fla Just download that and you can see how it's done. This is yet another wonderful thing that I made that sirkent Fixed.. lol. All you do is add another scene for your content after this one, and make sure the scene names in the gotoAndPlay are the same.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #3  
Old May 15th, 2004, 13:47
benbacardi's Avatar
Highly Reputable Member
Join Date: Feb 2004
Location: United Kingdom
Age: 20
Posts: 611
Thanks: 0
Thanked 0 Times in 0 Posts
do you know how to make a preloader like the one that weebl-stuff uses, eg www.badgerbadgerbadger.com? or any of the sites at www.weebl.jolt.co.uk
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #4  
Old May 15th, 2004, 15:29
Most Reputable Member
Join Date: Jul 2003
Posts: 1,856
Thanks: 0
Thanked 0 Times in 0 Posts
Just made one [:P]

http://www.digital-end.com/webforumz...ng_loader.html

The FLA is here:

http://www.digital-end.com/webforumz...ing_loader.fla

It's a little slower than the one on weebls-stuff and obviously it isn't actually loading anything, but you get the idea. You should easily be able to tie a percentage into it, so it responds to the loading of a file and maybe multiply it by something to make it go faster.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #5  
Old May 15th, 2004, 17:58
benbacardi's Avatar
Highly Reputable Member
Join Date: Feb 2004
Location: United Kingdom
Age: 20
Posts: 611
Thanks: 0
Thanked 0 Times in 0 Posts
thanks sirkent where do all u guys get your talents from?!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #6  
Old May 15th, 2004, 18:04
benbacardi's Avatar
Highly Reputable Member
Join Date: Feb 2004
Location: United Kingdom
Age: 20
Posts: 611
Thanks: 0
Thanked 0 Times in 0 Posts
what do the two different boxes tell you?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #7  
Old May 15th, 2004, 18:28
benbacardi's Avatar
Highly Reputable Member
Join Date: Feb 2004
Location: United Kingdom
Age: 20
Posts: 611
Thanks: 0
Thanked 0 Times in 0 Posts
can you please help me again? i've made this.. (sorry sirkent didnt understand yours made my own) but can you tell me why it gets to 100% and then waits? heres the html file http://myweb.tiscali.co.uk/cardy/test.html and the .swf file http://myweb.tiscali.co.uk/cardy/test.swf and the fla file so you can have a look at what i've done... http://myweb.tiscali.co.uk/cardy/test.fla
thanks
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #8  
Old May 15th, 2004, 18:55
Highly Reputable Member
Join Date: Aug 2003
Location: Australia
Posts: 662
Thanks: 0
Thanked 0 Times in 0 Posts
well, my flash file doesn't recognize your .fla... nor does it recognize karl's, but by looking at your .swf it appears as if your loader actually isn't loading anything at all... I have opera and even after it finishes with the loading menu it is actually still loading. If you increase your FPS, then you should be good. I can't get into what karl made (since the file format is unrecognized on my pc...) but You should only have to make the Spnner a movie clip and put that movie clip in the file itself. Then delete the numbers and the text, and use the bar. Hope this makes since.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #9  
Old May 15th, 2004, 19:38
benbacardi's Avatar
Highly Reputable Member
Join Date: Feb 2004
Location: United Kingdom
Age: 20
Posts: 611
Thanks: 0
Thanked 0 Times in 0 Posts
sorry i dont understand... i am VERY new this is my first EVER flash movie. the loading menu uses ifFrameLoaded() to move from the 10% frame to the 20% etc... so the last one says if the last frame has loaded, play the movie, but it doesnt do it like that... and i dont understand why? and what did you mean about "increase your FPS, then you should be good" ? sorry!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #10  
Old May 15th, 2004, 20:13
Highly Reputable Member
Join Date: Aug 2003
Location: Australia
Posts: 662
Thanks: 0
Thanked 0 Times in 0 Posts
haha, it's doing what i thought it was doing.. your "preloader" is nothing more than an animation itself. It is designed so that it does load while its animating, but it isn't actually loading. FPS is Frames per second. By Default its stored at 12 FPS.

I have built something similar to the above, yet it's actually loading.. I can't get it to display only at the 10's but what you can do is replace the movie clip I have on there with one of your own... If you want to add an intro to this after loading, then all you have to do is add extra frames on to the end of it... ok.. it will take a while to download, but that is because I wanted you to see how it will load. But here is the .swf www.haeglodesigns.com/beth/loader.swf and here is the .fla www.haeglodesigns.com/beth/loader.fla . Hope this helps.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #11  
Old May 15th, 2004, 20:16
Highly Reputable Member
Join Date: Aug 2003
Location: Australia
Posts: 662
Thanks: 0
Thanked 0 Times in 0 Posts
ohh.. by the way.. your gonna have to add that code to make the spinner go faster too.. since I can't view your .fla's I couldn't throw it in, and I have to be at work in 10 minutes, so I didn't have time to create it myself. Hopefully you can figure it out, and if not i'll try and do it when I get back tonight.

And unlike the way Sirkent did it, the motion will be coded.

Note to Sirkent: I know you can do better than that... I have seen your skillz.. come on, I know your trying to let me help the guy out, but come on, your the man... Throw us one
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #12  
Old May 15th, 2004, 20:29
benbacardi's Avatar
Highly Reputable Member
Join Date: Feb 2004
Location: United Kingdom
Age: 20
Posts: 611
Thanks: 0
Thanked 0 Times in 0 Posts
thanks Court Jester ... your .swf file "cant be found"
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #13  
Old May 15th, 2004, 20:34
Highly Reputable Member
Join Date: Aug 2003
Location: Australia
Posts: 662
Thanks: 0
Thanked 0 Times in 0 Posts
your welcome man... heh.. my uploader crashed on me.. didn't realize it.. I uploaded it now.. and im off to work.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #14  
Old May 15th, 2004, 23:34
Most Reputable Member
Join Date: Jul 2003
Posts: 1,856
Thanks: 0
Thanked 0 Times in 0 Posts
Ok, the previous link I posted now has a fulling working preloading version of the previous file. It jumps to frame 4 when loading is complete, so as long as you have what you want after frame 4, it'll work fine.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #15  
Old May 16th, 2004, 12:57
benbacardi's Avatar
Highly Reputable Member
Join Date: Feb 2004
Location: United Kingdom
Age: 20
Posts: 611
Thanks: 0
Thanked 0 Times in 0 Posts
thanks guys... Court Jester, where in your .fla file is the text that says "this is my main content" ? i cant find it :S
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #16  
Old May 16th, 2004, 13:32
benbacardi's Avatar
Highly Reputable Member
Join Date: Feb 2004
Location: United Kingdom
Age: 20
Posts: 611
Thanks: 0
Thanked 0 Times in 0 Posts
ok dw found it! how can i delete that scene though? i dont want it there... also, sirkent, i cant work out how you rotated the image at a relative speed to the download... could you help me please?!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #17  
Old May 16th, 2004, 15:32
Most Reputable Member
Join Date: Jul 2003
Posts: 1,856
Thanks: 0
Thanked 0 Times in 0 Posts
I assume you've had a look in the FLA I made available on my webspace.

You'll notice that the image is in fact a movieclip called "myObject" (you can see that in the properties panel).

Frame 1 of the movie contains some setup variables, which you can configure yourself:
Code: Select all
rotation = 0;
multiplier = 5;
"rotation" is the starting rotation point (in degrees).
You'll notice that the movie is set to 30 frames per second and the frames that contain the loader are 2 frames (frames 2 and 3). So the image is updated 15 times a second. "multiplier" is by how much the rotation should increase each timethe script on frame 2 runs (15 times a second).

Next is frame 2
Code: Select all
if (_root.getBytesLoaded() >= _root.getBytesTotal()) {
	gotoAndPlay(4);
}
else {
	percentage = (_root.getBytesLoaded()/_root.getBytesTotal())*100;
	rotation = myObject._rotation + multiplier*percentage;
	myObject._rotation = rotation;
}
The first if statement checks if the number of bytes loaded is more than or equal to (this should be equal to, but in some cases it can be slightly over as the totalbytes can be an estimation) the total number of loaded bytes... so basically it checks if the whole file is downloaded. If it is, then the movie goes to and plays frame 4 and onwards.

If the condition is false, then we're still downloading the file. So we setup our spinning image.
percentage is, obviously, the percentage of the file downloaded, which is used to increase the speed at which the image spins.
As you probably know, in maths the percentage can be worked out by dividing what you have, out of the total and multiplying by 100.

rotation is then worked out. It is worked out as the current rotation of the object (whcih could be anywhere from 0 to 360) + the multiplier times the percentage. So as the percentage increases, so does the speed of the rotating image.

Lastly, the newly worked out rotation is applied to the image.

Frame 3 tells the movie to go back to frame 2, so that it checks over and over again if the movie is fully loaded.

I hope that helps!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #18  
Old May 16th, 2004, 15:58
Highly Reputable Member
Join Date: Aug 2003
Location: Australia
Posts: 662
Thanks: 0
Thanked 0 Times in 0 Posts
I got a question... is rotation just a variable you made.. or is it a constant that actually makes something rotate? Just wondering.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #19  
Old May 16th, 2004, 19:05
benbacardi's Avatar
Highly Reputable Member
Join Date: Feb 2004
Location: United Kingdom
Age: 20
Posts: 611
Thanks: 0
Thanked 0 Times in 0 Posts
thanks Court Jester by the way could i have some feedback on the movie itself, being my first one?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
  #20  
Old May 16th, 2004, 20:21
Most Reputable Member
Join Date: Jul 2003
Posts: 1,856
Thanks: 0
Thanked 0 Times in 0 Posts
rotation is a property of the object... any movieclip has this property.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Closed Thread

Tags
preloaded

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


All times are GMT. The time now is 01:30.