Preload Question [renamed]
Whats the action script, if I just want a borring loading were when its done it will play a frame. like when loaded gotoandplay(2);.
KirupaForum > Flash > Flash 8 (and earlier) > Flash MX 2004
Posted on: 06-06-2005, 10:58 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Preload Madness - Preload Movies Clip In A Movie?
hey people... a brought up this subject here a while back but it didn't really go anywhere... now that this sections seems to be a bit more lively perhaps some of you flashers can help me out... I am going to break this down very simple... I haven’t even storyboarded this so this is an extremely rough draft of the idea
I am building a photo gallery
this gallery has eight images which range from 30k-75k (roughly) so I don't want the user to wait for a full load of 240k-600k
I want to first load the thumbnails for the images... and then begin to preload the first image directly after that... then display it
and then from that point when the user clicks a thumbnail the corresponding full image will preload and then display
basicially this is about preloading a movieclip in a movie... I jsut can't wrap my head this... so I will ask for help before I get too deep.... any input on the basics of this idea would be appreciated
thanx!
Selectively Preload, Preload Rest While Playing
Hello,
I have updated a pre-bought flash template for a photographer. Long story short, the file is now 4M's -mostly from images- and he wants it to load faster. Right now it is all in one swf, no load movies. So the large jpg's are embedded. (I could make them all movies and load them as needed, but am trying to avoid that.)
I would like to know if it is possible to selectively preload. For instance load everything except the large images mc. This way the movie would play its long intro and the viewer would have to go to the thumbnail gallery before getting to the large images gallery. Meanwhile the large images mc could load in the background?
Any thoughts?
The site is here:
www.crphotography.com
Any help is greatly appreciated.
Preload, Finish Preload Anim, And Then Play
Hello!
I have a preloader with a mc that plays while it loads. I want the movie to preload the whole show, then finish playing the section of animation that it is in, and then play the main movie.
For example:
A ball goes from the right corner to the left (section 1) and then reverses back to the right (section 2). While the show loads the ball just goes back and forth. But once loaded, I want the ball mc to finish going to either corner and then _root.gotoAndPlay(5);
I am thinking of something like this (try not to giggle at me):
if (loaded == total) {
_root.ball_mc.gotoAndPlay(until the next frame label);
then
_root.gotoAndPlay(5);
}
This is my preloader code which works great but cuts of my ball mc abruptly:
onClipEvent (load) {
total = _root.getBytesTotal();
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded();
percent = int(loaded/total*100);
text = percent+"%";
gotoAndStop(percent);
if (loaded == total) {
_root.gotoAndPlay(5);
}
}
Thanks so much!
Preload Code Help - Holding Content During Preload
First off, the current code works fine in terms of function but I want to see if someone has a code fix for me. When the preloader starts, I want the current image to "hold" inplace instead of being unloaded from the "container" MC. I want the bar to load, covering up the current image and then when the preload is complete, load the next image in and display it. Does anyone have an idea on how I might rearrange or change the code? I know I have seen this same technique on several web pages, I just havn't been able to figure out how to execute it.
click on btn1 or btn2 to load an image.
Here's the current SWF
http://josephryannasipak.com/test.html
Here's the code:
stop();
bar._visible = false;
my_mc = new MovieClipLoader();
preload = new Object();
my_mc.addListener(preload);
preload.onLoadStart = function(targetMC) {
trace("started loading "+targetMC);
container._visible = false;
bar._visible = true;
}
preload.onLoadProgress = function(targetMC, lBytes, tBytes) {
bar._width = (lBytes/tBytes)*550;
pText.text = "% "+Math.round((lBytes/tBytes)*100);
};
preload.onLoadComplete = function(targetMC) {
container._visible = true;
bar._visible = false;
trace(targetMC+" finished");
};
my_mc.loadClip("sunset.jpg", "container");
btn1.onPress = function () {
my_mc.loadClip("bluest.jpg", "container");
}
btn2.onPress = function () {
my_mc.loadClip("church.jpg", "container");
}
and the FLA file:
http://josephryannasipak.com/test.fla
Preload Scene DOESN'T PRELOAD
ok, so i have this file, full of images, it's huge. i have a preload scene, the actionscript is as follows:
setProperty ("loadBar", _xscale, "((_root.getBytesLoaded() /_root.getBytesTotal() )*100)");
ifFrameLoaded ("Scene 1", "End") {
gotoAndPlay ("Scene 1", "Start");
}
so basically, it SHOULD increase the width of the preload bar as the movies progressively loads, and it SHOULN'T start playing the main scene(Scene1)until the whole scene is finished loading.
It doesn't do this!
i haven't done much actionscripting b4, so any help would be appreciated.
you can see the extremely CRAP movie at: http://www.angelfire.com/ca/adamstuff/paragon3.html
Loading Two Swf's Next To Each Other [renamed]
ok wow!! i need HELP big time with some stuff! first of all..im trying to load an .swf movie (or file which ever it is) into my main movie...well the way im doing that is by clicking a button and then the movie loads...then im wanting to be able to click another button and load a different movie BUTTTT when i do this right now the second button's movie loads right over the first buttons movie!! what do i do?!?
also im wanting to make a text scroller with JUST the slider. how can i go about this?
p.s.
would appreciate just verbal help b/c i would like to try to do this without using someone elses stuff ...if thats ok...?!
If/else Problems [renamed]
lo all. im having trouble with a menu im workin on.
ages ago i learned how to use if statments to control a menu system like this one, but i've lost all my source files and cant remember much of the script, i remember settin variables on the buttons then usin if/else/else if actions to target frames (if button pressed = button 1 goto and play etc...) if you got 5 mins to look at the fla you shud see what im trying to do...basic i know...im just a noob. also i think i learned it in v5, the actions may have changed in v6 /v7. if anybody gets what i mean from this (vague) post and knows of any nice tutes please please let me know!
any help greatly appreciated!!
kev.
p.s. im usin v6
How Is This Menu Done? [renamed]
If you go to the www.panasonic.co.uk, you will see this amazing menu if you click "in the home & on the move". Can someone tell me how this is done please
best regards
Cd Rom Issues [renamed]
Help!!, I'm not very good at scripting, and I have been trying all day to find the answer to this simple operation, so this is like a last hope. I am developing a cdrom, and I have a main page with 8 buttons, which I want the user to click where they want to go and navigate back to and from this page. Is it better to make each of the 8 sections on new scenes, or would a separate movie for each be better. I feel that a separate movie would be better as the file size is quite large on some of the sections, but i'm not sure and could really use some advice. If I do make separate movies, then please what is the script for the buttons to navigate to the movies (i guess i would be loading .swfs'). I really need some help with this please.
Help With Sound (renamed)
I tried performing this tutorial:
Creating a Volume Control Slider http://www.kirupa.com/developer/mx/volume_slider.htm
I added my song to the library and exported the file to my desktop. The swf file plays perfectly on my desktop...the slider, stop and play button all work. The problem arises when i upload to website. It appears on the site but it doesnt play. It only says that it is downloading song and just stays like that for a considerable amount of time. I cant understand why it works on the desktop and not on the website. I think it is a quick fix... can someone can just tell me what i am doing wrong?
How To Color A Mc [renamed]
Hi Guys,
I wonder if you can help me out on this....
I want to create a color palette one side and on the other has like a white board so when a user select a color from the palette that color will appears on the white board.... How can you do that? Can you supply me a sample?
Thank you.
Bobby
Published Swf Is Way Too Big [renamed]
I need help publishing a .fla file.
any help is appreciated.
I've been toying some time now with Flash MX and websites, but never reach the point where I need to publish the .fla properly onto the net. I've reached that point now.
My problem is getting the final movie to work probaly in the browser. The final .swf movie is 2,81mb, because it contain a lot of pictures. Is that too much? When the .html and .swf is uploaded to ftp, the screen goes black in the browser, like the background color of the site, and it seems like taking forever to load the site and in the end nothing shows.
So what is the proper way to publish to fix this?
*** Renamed *** Masking Help
Is there no way I can do this with multiple MCs, each one moving around independently, but masked by the same lens MC?
Loading Two Swf's Next To Each Other [renamed]
ok wow!! i need HELP big time with some stuff! first of all..im trying to load an .swf movie (or file which ever it is) into my main movie...well the way im doing that is by clicking a button and then the movie loads...then im wanting to be able to click another button and load a different movie BUTTTT when i do this right now the second button's movie loads right over the first buttons movie!! what do i do?!?
also im wanting to make a text scroller with JUST the slider. how can i go about this?
p.s.
would appreciate just verbal help b/c i would like to try to do this without using someone elses stuff ...if thats ok...?!
If/else Problems [renamed]
lo all. im having trouble with a menu im workin on.
ages ago i learned how to use if statments to control a menu system like this one, but i've lost all my source files and cant remember much of the script, i remember settin variables on the buttons then usin if/else/else if actions to target frames (if button pressed = button 1 goto and play etc...) if you got 5 mins to look at the fla you shud see what im trying to do...basic i know...im just a noob. also i think i learned it in v5, the actions may have changed in v6 /v7. if anybody gets what i mean from this (vague) post and knows of any nice tutes please please let me know!
any help greatly appreciated!!
kev.
p.s. im usin v6
How Is This Menu Done? [renamed]
If you go to the www.panasonic.co.uk, you will see this amazing menu if you click "in the home & on the move". Can someone tell me how this is done please
best regards
Save As .txt? [renamed]
i'm developing an application,, of course using flash mx 2004..---interactive program.....
i wonder what else the script that i can use instead of SharedObject and fscommand(exec) to save the user's input into a file such as txt file. please...~~~
Cd Rom Issues [renamed]
Help!!, I'm not very good at scripting, and I have been trying all day to find the answer to this simple operation, so this is like a last hope. I am developing a cdrom, and I have a main page with 8 buttons, which I want the user to click where they want to go and navigate back to and from this page. Is it better to make each of the 8 sections on new scenes, or would a separate movie for each be better. I feel that a separate movie would be better as the file size is quite large on some of the sections, but i'm not sure and could really use some advice. If I do make separate movies, then please what is the script for the buttons to navigate to the movies (i guess i would be loading .swfs'). I really need some help with this please.
Movement With Acceleration [renamed]
Heyo!
Ok, i have this kinda difficult question (i think it is..) :
Let's say i have a button, and a movie, when i click on the button, i want the movie to move to another position with an accelerating effect ! How would i achieve this?
For the putton i have this code:
on (release){
instanceNameOfMovie._y = a value;
}
How can i modify it so that it will move to that value smoothly? i mean with an accelerating effect...
LoadMovie And _root PLEASE HELP [renamed]
I'm so freakin' frustrated!!!!
OK!!! i have an external movie clip that i want to load to a main clip.
This external clip have something to do with its root
So my question is:
1) How do u tell the _root in the external MC to point to its real root? (I've search the forum and tried to change _root to _parent but it doesnt work)
2) If changing to _parent doesnt work, does this means that there is something wrong with the empty MC container that i use?
I know there are some pro in this forum so PLEASE HELP ME!!!!!!!!!
Preloader Problems [renamed]
OK - i'm having major preloader problems with Flash MX 2004 Pro...
Here's a link to a website i'm trying to put together for a friend:
http://www.kraitt.com/hypertouch/index.htm
After entering, you will immediately notice the following:
I cannot get a preloader to work for the infinite menu that loads when you click on "gallery 1" (i've tried every tutorial and every type of preloader you can imagine and nothing works). At the moment it simply has no preloader - can anyone show me one that will work?
When the infinite menu is loaded, you will also notice that the preloader for each thumbnail also doesn't work. When you click on any of the thumbnails, the loading bar appears complete immediately, and sits there until the image is loaded.
The main menu button (gallery 1) basically loads the infinite menu, which is an external swf, and the infinite menu itself loads all the main images which are also external swf's.
Can anyone please help me.... ???
Flip Movieclips...? [renamed]
I have (most likely) a very easy question. How do you get a movie clip to flip vertically/horizontally when a key is pressed. I know how to rotate, but I need to get the clip to flip to make it look more realistic. PLEASE HELP!
Cursor Question [renamed]
Since im new with Flash and im at the begining i had a question to do.How do i have to do some effects to the cursor for my webpage or to the buttons.
Please some help
LoadMovie + Paths [renamed]
i am trying to load a movie into an empty movieclip (instance name container).
loadMovie("music_bar.swf", "container");
but when my main movie is playing, the music_bar.swf shows up but doesn't play... what am i doing wrong? it just appears but the buttons in the movie doesn't do anything
How To Adjust Framerate?[renamed]
I just got Flash yesterday and am making a few cheap cartoons, however they run very quickly and I was wondering how you could lower the framerate or whatever in order to view them properly. Thanks.
Logo Question [renamed]
Hai guys, I'm kinda new with flash and was wondering if any of you guys could help me out with the effect seen for example on this page. The logo and the links do blink for a while. I don't know how this effect is called and would appreciate if one of you can help with a tutorial or point me out where I can find a good tutorial of this effect.
Thank you very much and sorry if this question is stupid or has already been asked.
B-P
External Swf's Not Working [renamed]
Ok This a bit hard to explain but here i go... I am doing a web site where i load external swf's. http://kirupa.com/developer/mx2004/transitions.htm
Now i have a button where i load a photo page where i amn using the tutorial making a photo galerry However I have multiple galerrys and i ran into the prob of loading a external swf with a button inside that external swf to go to a certain gallery.
If that doesn't makes sense just help with this lol. I then decided to have under that photo button a drop down menu where there are supposed to be 4 more buttons that when you click on them they load the exteral swf according to the gallery. However the code used in the loading of external swf is not working on the drop down buttons.
Does neone have any suggestions???
LoadMovie Question [renamed]
sorry guys i need to post here because of faster traffic... urgent..
i just loaded a movie in the main movie.. how do i stop it from looping?
Font Not Showing Up [renamed]
hello
I am new to this forum and to flash in general... my question is probably really dumb but i cannot figure it out ...
I tried to follow the animated button tutorial and it is all ok
until i decided to modify it a bit and add some text and a mask to it ...
for some reason when i preview (ctrl-enter) the movie the mask hides the text but reveals the button ...
I hava no clue why it behaves this way ..
<here> is the souce file
could someone take a look .. thank you
Font Problems [renamed]
Hey guys ive been working on this project for about a week. Its my mini-blog for a website. Ive been having some serious problems with text illedgibility (bla bad spelling). And i need someone to please take a look at my .fla and fix my font errors.
http://www.guidone.com/matt/myspace/main.html
^this is how much help i need
ive been following that tutorial but i need someone else to help me now because i can't figure out a way to fix them.
Ill give u the link to the .fla after someone trustful chooses to aid me.
How To Add Text To The Tranistion Tut [renamed]
Hi,
I'm new around here and hoping someone might be able to help me with their actionscript knowledge.
I'm doing a project that involves loading external images and needs corresponding test to go with each pic. I'm basing the project off of the tutorial found here to load in the movies separately: http://www.kirupa.com/developer/mx/p...transition.htm
What I need to do is find a way to have text for each photo transition in/out, separately from the photos. This way the text will transition while the pic loads separately. If anyone can let me know what I would need to alter from the files from the above tutorial, it would be greatly appreciated. Thanks so much!
Masking Question [renamed]
How do create these effects, as lines running or something - http://www.vampirebloodlines.com/entrance.html
How does it called and how to do that effect?
Animated Preloader, How Is It Done? [renamed]
need a good answer or better yet an fla for MX. Basically if you go to any of these sites:
especially this one:
http://www.unfortunateeventsmovie.com/intro.html
(animated RASTER preloader)
http://troymovie.warnerbros.com/
(raster image in preloader)
http://avp-movie.com/
(large raster images in background)
and finally sincity movie website has a preloader between scenes that's a raster gun and animated.
HOW do all these preloaders show up 1%-100% ??? when I put just a raster image in the background my preloader shows up at 40%+, and NO I don't have any linkage or music/mp3 streaming and I even do it in a separate scene that will go to next scene when preloader is done.
would be great if someone could post a similar preloader to the unfortunateevents website - at least a raster that's animated and shows the preloader going from 1-100..
Rollover Question [renamed]
i'm still pretty new to flash so i'm not sure how to do a rollover/mouse thing that i want to do.
i basically just need to know how to make something follow the mouse as you roll over it. i have a timeline and i want there to be a bar that "slides" as you move the mouse over the timeline. i guess pretty much like a scrollbar. then i want to be able to click on whatever year the bar is stopped on (which will then take me to a movie clip describing that year).
if there's an easy to follow tutorial for this out there, let me know! otherwise, pleeeaaasse help!
thanks!!!
emily
How To Store X/y Values [renamed]
I am making a game for my final in my comp sci. class. I need an action script of some sort that can help me wiht my problem. In my game i am going to have the player "take pictures". I will have a mask to cover the background and a "lens hole" in the middle that follows the cursor. When they click it, it makes the noise that a camera makes when it takes a picture. Is there a script that records the shot that was taken in the "lens hole" and shows them in a list after a certain amount of shots have been taken?? I really need this quick! thanks for the help.
Another Snow Problem [renamed]
How to make it stop 'snowin' on frame 2 or shtop the the loading ends?? i tried putting stop(); blank keyframe but it still keep on last till my last keyframe
action script for layer
for (k=0; k<200; k++) {
duplicateMovieClip(this.snow, "snow"+k, k);
}
action script for snow
onClipEvent (load) {
//specifies the size of the movie stage
movieWidth = 800;
movieHeight = 600;
//variables that will modify the falling snow
i = 1+Math.random()*2;
k = -Math.PI+Math.random()*Math.PI;
//giving each snowflake unique characteristics
this._xscale = this._yscale=50+Math.random()*100;k<50
this._alpha = 75+Math.random()*100;
this._x = -10+Math.random()*movieWidth;
this._y = -10+Math.random()*movieHeight;
}
onClipEvent (enterFrame) {
//putting it all together
rad += (k/180)*Math.PI;
this._x -= Math.cos(rad);
this._y += i;
if (this._y>=movieHeight) {
this._y = -5;
}
if ((this._x>=movieWidth) || (this._x<=0)) {
this._x = -10+Math.random()*movieWidth;
this._y = -5;
}
}
Keycode Question [renamed]
hey can anyone tell me whats wrong with this code??
else if (Key.isDown(Key.RIGHT)) && (Key.isDown(Key.UP)) {
_root.Character.gotoAndStop(4);}
Can You Customize The ComboBox? [renamed]
Is there really no one who knows if there is possible to customize a combobox to look like this? (where it says select)
http://www.kirupa.com/forum/showthread.php?t=99342
LoadMovie Question [renamed]
I am trying to get the actual SWFs for the (home bio news multimedia etc. ) You know loading the SWFs into a blank movie clip
This is my actions for the buttons
on (release) {
_root.contents.loadMovie("home.swf";
}
movie clip instance is "contents"
http://www.kaewun.com/k1.html
http://www.kaewun.com/fla/main.fla.zip <<source file
I change the ("home.swf" to whatever the page is. I'm thinking its the _root. I'm doing wrong I don't know. If any one kan help I appreciate it.
The mp3 player is from http://www.jeroenwijering.com/?item=Flash+MP3+Player really kool.
LoadMovie Question [renamed]
I'm very new to Flash, but I've managed to do okay with it (for a school project).
Basically, I have a 'home' page, with buttons to 4 other pages (and on each of those pages are buttons to the other 3 plus the home button). What action script is required for this? loadMovie?
I have tried using loadmovie, but it doesn't seem to work quite well. For example, when I play the home page swf, and click on one of the buttons, it goes fine. But if I click on another button on the new page, the home page flashes very quickly before it reaches the new page and it continues to do this when I continue to click on buttons to go to the various pages. Does this have to do with levels? I have them all on the same level, I don't know if that is right.
I also have an 'intro page' which comes before the main page and you just click a button to get to the main page. It does the same thing (flashing briefly) if preview it first.
Quickest and easiest solutions are best (as I have to hand this in tomorrow, haha) Thanks!
How To Create A Glass Look [renamed]
i want to create this http://www.jerzees.com/jz_2005/index_flash.html the animated buttons..i want them to move like that..
...plz help me or point me into a very good tutorial..
i'm a newbie.
write soon,
Xtina
Transition Question [renamed]
Hey guys, im making a flash website and I almost got it done.
http://www.wiking-clan.nl/peter/flash/site1.html
http://www.wiking-clan.nl/peter/flash/site1.fla
If you watch the site and click on a button in the menu you see a movieclip wit a orange shape slide in the screen right? Well I need to know how can I make the movieclip slide back when a other button is pressed and then load that other movieclip?
Cause now the movieclips just stay there.
I hope you understand me.
I realy dont know how to do this
GotoAndPlay Issues [renamed]
Okay, this is a reasonably basic sort of problem I think, one I could solve myself if I had the time which I don't. Umm, I'm trying to figure out you trigger animations by links ect. Is that what GoToandPlay is used for? I've never actually figured out what you use gotoandplay for and have constructed reasonable flash sites without the need for it but now I've come to this hurdle.
So basically what I mean is, the user clicks on a button and an animation pops up somewhere. I don't know how to do that...
and also, is there such thing as 'unloading' a movie clip? I mean, I know how to load in a movie clip to the stage, but how about code that can 'unload' the clip when a button is pressed or something, along with an animation of the movie clip closing.
If someone can help me with these problems I would appreciate it greatly.
Thanks,
Sam Norriss
Popup Problems [renamed]
I've fixed my site up with a centered pop-up, but it doesn't work in Explorer and looks even worse in firefox.
I DON'T KNOW WHAT'S WRONG. I checked everything, and it all looks good. SOMEBODY?!?
http://users.pandora.be/willem.photography/index.fla
www.wdotp.com
Email Form? [renamed]
Can somebody give me a flash file with a .php file that works as a mail form? I'm sorry to ask of this and not knowing how but I really need it for website.
Email Form Help [renamed]
Had a customer purchase a template, customized it to suite their needs only thing was it has a built in email part to the flash which came with no php script ....and for the life of me I cannot get it to work properly, http://www.tyronechablis.com is the site, if you go to the contacts page you will see the form I am referring to. If any one here who knows the php and action scripting well, please give this a look see. I cannot get it to send mail, clear button works fine, send button just does absolutely nothing, sits there and looks pretty lol.....I have tried 4 different action scripts with this thing and am at my wits end. Thanks in advance.
*Edit* I have tried the tutorial seen here on this site which is what brought me to the forums.
WC
|