I’ve asked this before, but it wasn’t the way i wanted it to.
How do you create a preload bar, showing the percentage? Just the number without any % sign after the number.
I want the number to scroll simultaneously at the bottom with the bar.
Jenniferlopez.com has this type of preload. Thanks.
system
August 4, 2003, 5:11am
2
Well there are a lot of tutorials on preloaders, but using this one:
http://www.kirupa.com/developer/mx/percentagepreloader.htm
just change this line:
this.loadText = Math.round(getPercent*100)+"%";
to:
this.loadText = Math.round(getPercent*100)+"%
And that gives you just the number…
And to make it move with the bar, you can make the dynamic textbox into a movieclip, and link their x coordinates…
system
August 4, 2003, 6:07am
3
Hey thanks a lot, but I dont’ know how to link the text. I can’t do any actionscript. could you help me out?
system
August 4, 2003, 7:52am
4
hmm, i’ll havta think about that since i’m not too sure. But try this:
[AS]
this.onEnterFrame = function() {
this._x += this.loadBar._width
}
[/AS]
It might work, most likely not since nothing ever does until i actually try it :P, and i can’t really be stuffed to try it at the moment, so just post the fla after you’ve tried it and i’ll work from there
oh yea, in the last post, i just noticed both the lines i gave you were the same. You’re suppose to change the line to:
[AS]
this.loadText = Math.round(getPercent*100)
[/AS]
system
August 4, 2003, 7:57am
5
Hmm ok thinking about the first code i gave you again, its definately not going to work :-\
EDIT:
maybe try:
this._x += getpercent*100
that might work but maybe not either :-\
system
August 4, 2003, 8:00am
6
Try this instead:
[AS]this.onEnterFrame = function() {
this._x = this.loadBar._x + widthofloadbar;
}
[/AS]
This should work if the registration point is on the left. If it’s in the middle, add “/2” at the end of widthofloadbar and if the registration point is at the right, delete “+ widthofloadbar”.
Untested though …
system
August 4, 2003, 8:02am
7
oh yeah, yea i think that would work
system
August 4, 2003, 2:48pm
8
Am I suppose to make the dynamic text into a movie clip?
Then apply this action to the first perload frame, but to the same layer as the loadText?
system
August 4, 2003, 3:07pm
9
Yes to all your questions doesn’t havta be on same layer though, better to put all your actions on a layer called “AS” or “Code” or somethin…
system
August 4, 2003, 3:21pm
10
That doesn’t work, it blanks out my preload bar.
system
August 4, 2003, 3:29pm
12
You got Icq or MSN? Or any IM?
system
August 4, 2003, 3:32pm
13
Doesn’t it work on here? tried zippin it?
system
August 4, 2003, 3:34pm
14
Don’t want to give it out, that’s all.
system
August 4, 2003, 3:35pm
15
Cut out some stuff and resave it, i just can’t be bothered to start everythin from scratch to test the code
system
August 4, 2003, 3:40pm
16
Actually, here you go… never mind.
system
August 4, 2003, 3:47pm
17
.rar?? how do i open this type of file?!
system
August 4, 2003, 3:50pm
18
Okay… still old school I see.
system
August 4, 2003, 4:04pm
19
eh? old school? i guess :-\
Heres your thing, very nice begining part (but looks a bit like the old 2Advanced :-)…
system
August 4, 2003, 4:10pm
20
Thanks a lot, it worked!
Now, that’s solved.
Yah, I’m starting a new one. I hate when I do that. I spent two weeks on that, and I start a new one.