Author |
Message |
cluelessfurball
Expert Cumsniffer
Posts: 4786 |
Joined: Mon Oct 27, 2008 8:08 am |
Cash on hand: 75,561.50
Location: Elsewhere |
Group: Oldies |
Country: |
|
Re: OC Friday
no
_________________ "Freedom is the right to tell people what they do not want to hear." -George Orwell
|
Sat Jul 02, 2011 10:14 pm |
|
|
cluelessfurball
Expert Cumsniffer
Posts: 4786 |
Joined: Mon Oct 27, 2008 8:08 am |
Cash on hand: 75,561.50
Location: Elsewhere |
Group: Oldies |
Country: |
|
Re: OC Friday
I didnt intentionally spam no spam! It was a accident! I thought it was still in spam!!!!!!
_________________ "Freedom is the right to tell people what they do not want to hear." -George Orwell
|
Sat Jul 02, 2011 10:24 pm |
|
|
Jewsus
Level 35
Posts: 8888 |
Joined: Fri Feb 18, 2011 3:52 pm |
Cash on hand: 1,745,184.60
Bank: 55,666.50
Group: Registered users |
|
Re: OC Friday
YomToxic wrote: Oh, I gave them 1 minute bans for that. Don't you worry your tuna-brains off that.
Now hurry up and delete your spammy posts. :'( YomToxic wrote: Phoenix Wright game rule#5: The real criminal always blames someone else.
Hello, CF. Stop spamming in general no spam. nice move please try and answer the following: Jewsus wrote: (in the second frame) Okay so this sits on a blank frame 2 until loaded (as it should) - Spoiler: show
- ifFrameLoaded (_root, 6) {
gotoAndPlay(3); } However this sits on frame 1 even after loaded. (ifframeloaded does not support else for some reason) - Spoiler: show
- ifFrameLoaded (_root, 6) {
gotoAndPlay(3); } gotoAndPlay(1);
now, Flash must read code differently then I think it should. I would assume that if the last frame were loaded it would play frame 3 and ignore any additional code, however it obviously reads and follows the last bit of code. My question is why/how does Flash read this way? Maybe it only loops once and doesn't automatically go to frame 2 after the initial looping? (can't add gotoAndPlay(2) to first frame or an infinite loop.) The following code in frame 2 does not work either - Spoiler: show
- if (_root.percentLoaded == 100)
{gotoAndPlay(3);} //to comment. else {gotoAndPlay(1);}
Do I need to define "percentLoaded" in some way? The following code works. The preloader (frame 1) doesn't show up for a bit, but I assume that's because it is loading? Please let me know if this is hte case. Also, my "movie" of the ball bouncing does not work. - Spoiler: show
- if (_root.bytesLoaded == _root.getBytesTotal())
{gotoAndPlay(3);} //to comment. else {gotoAndPlay(1);} http://www.2shared.com/file/lqiihkUH/preloadervars.html <--new .fla download.
|
Sun Jul 03, 2011 12:07 pm |
|
|
cluelessfurball
Expert Cumsniffer
Posts: 4786 |
Joined: Mon Oct 27, 2008 8:08 am |
Cash on hand: 75,561.50
Location: Elsewhere |
Group: Oldies |
Country: |
|
Re: OC Friday
_________________ "Freedom is the right to tell people what they do not want to hear." -George Orwell
|
Sun Jul 03, 2011 1:37 pm |
|
|
Jewsus
Level 35
Posts: 8888 |
Joined: Fri Feb 18, 2011 3:52 pm |
Cash on hand: 1,745,184.60
Bank: 55,666.50
Group: Registered users |
|
Re: OC Friday
lol, does it come in high def? jk lol. Too bad it's hard to read. Good attempt. lol click the albert johnson vid. I AM A SUPER STAR WITH A BIG BIG HOUSE AND BIG BIG CAR!
|
Sun Jul 03, 2011 2:18 pm |
|
|
cluelessfurball
Expert Cumsniffer
Posts: 4786 |
Joined: Mon Oct 27, 2008 8:08 am |
Cash on hand: 75,561.50
Location: Elsewhere |
Group: Oldies |
Country: |
|
Re: OC Friday
Yeah I saw that one last week.
_________________ "Freedom is the right to tell people what they do not want to hear." -George Orwell
|
Sun Jul 03, 2011 2:20 pm |
|
|
Pantsman
Level 39
Posts: 21063 |
Joined: Sat Feb 14, 2009 11:44 pm |
Cash on hand: 2,187.55
Bank: 5,250.50
Group: Sysop |
|
Re: OC Friday
Sorry I'm kind of slow at replying. Feelin' kinda sick. Anyway, I took a look at the FLA and found your problem. if (_root.bytesLoaded == _root.getBytesTotal ()) {gotoAndPlay(3);} //to comment. else {gotoAndPlay(1);} Yeah. This is how it shouldve been. if (_root.bytesLoaded == _root.getBytesTotal) { play; } else { gotoAndPlay(1); } But it's a little cramped for the preloader if you ask me. You'll need to learn about scenes. Make two scenes. 1) Preloader. 2) Flash. On the first scene, On Frame 1, loadedbytes=getBytesLoaded(); totalbytes=getBytesTotal(); Frame 2, your code should go if (loadedbytes == totalbytes) { gotoAndStop(3); nextScene(); } else { gotoAndPlay(1); } Frame 3 is blank. On Scene 2... PUT YOUR ARTS IN THERE! This way, you can make changes to your preloader without having to deal with changing the whole flash. Lemme know if you need further help.
_________________
Yeap.
_________________
1 pcs.
|
4 pcs.
|
|
Sun Jul 03, 2011 9:25 pm |
|
|
Jewsus
Level 35
Posts: 8888 |
Joined: Fri Feb 18, 2011 3:52 pm |
Cash on hand: 1,745,184.60
Bank: 55,666.50
Group: Registered users |
|
Re: OC Friday
yes sir. I knew of other ways to do it, but was trying to do it the way described in your tutorial. Anyway I will work on this more and get back to you.
|
Sun Jul 03, 2011 10:33 pm |
|
|
Pantsman
Level 39
Posts: 21063 |
Joined: Sat Feb 14, 2009 11:44 pm |
Cash on hand: 2,187.55
Bank: 5,250.50
Group: Sysop |
|
Re: OC Friday
Lol you had extra brackets. NO WONDER IT DIDN'T WORK.
_________________
Yeap.
_________________
1 pcs.
|
4 pcs.
|
|
Sun Jul 03, 2011 10:47 pm |
|
|
Jewsus
Level 35
Posts: 8888 |
Joined: Fri Feb 18, 2011 3:52 pm |
Cash on hand: 1,745,184.60
Bank: 55,666.50
Group: Registered users |
|
Re: OC Friday
why in the following do you have "gotoAndStop(3);"?
Frame 2, your code should go
if (loadedbytes == totalbytes) { gotoAndStop(3);
nextScene(); } else { gotoAndPlay(1); }
Also, i needed the () after .getBytesTotal.
Why doesn't the ball in the first frame bounce? it is a movie.
why are you sick all the time? take care of yourself man. we need you XD.
|
Sun Jul 03, 2011 10:54 pm |
|
|
Pantsman
Level 39
Posts: 21063 |
Joined: Sat Feb 14, 2009 11:44 pm |
Cash on hand: 2,187.55
Bank: 5,250.50
Group: Sysop |
|
Re: OC Friday
It's to force the script to break out of the loop. After that, it shifts to the next scene.
And the ball aint bouncing because the script goes to frame 2, and back to 1, reloading it. You need to have that ball on a different layer and on frames, not keyframes. Let em demonstrate.
_________________
Yeap.
_________________
1 pcs.
|
4 pcs.
|
|
Sun Jul 03, 2011 11:00 pm |
|
|
Jewsus
Level 35
Posts: 8888 |
Joined: Fri Feb 18, 2011 3:52 pm |
Cash on hand: 1,745,184.60
Bank: 55,666.50
Group: Registered users |
|
Re: OC Friday
so the command "nextScene();" isn't enough by itself to break the loop? or is the code
"nextScene(); } else { gotoAndPlay(1); }"
in frame 3 for some reason?
|
Sun Jul 03, 2011 11:03 pm |
|
|
Pantsman
Level 39
Posts: 21063 |
Joined: Sat Feb 14, 2009 11:44 pm |
Cash on hand: 2,187.55
Bank: 5,250.50
Group: Sysop |
|
Re: OC Friday
http://www.filedropper.com/preloadervarsdoneI repaired your preloader. This goes in Frame 1 loadedbytes=getBytesLoaded(); totalbytes=getBytesTotal(); This goes in Frame 2. if (loadedbytes == totalbytes) { gotoAndStop(3); nextScene(); } else { gotoAndPlay(1); } Frame 3 is blank. ABSOLUTELY BLANK. (except for a black box?)
_________________
Yeap.
_________________
1 pcs.
|
4 pcs.
|
|
Sun Jul 03, 2011 11:08 pm |
|
|
Jewsus
Level 35
Posts: 8888 |
Joined: Fri Feb 18, 2011 3:52 pm |
Cash on hand: 1,745,184.60
Bank: 55,666.50
Group: Registered users |
|
Re: OC Friday
Wow you are a troll lol. took me a second to figure out scenes. Thanks for the help.
btw frame 2 i changed it to this
if (loadedbytes == totalbytes) { nextScene(); } else { gotoAndPlay(1); }
and it still works fine. Do you need to stop the first scene from looping for some reason? or won't it stop looping due to the call to "nextScene();"?
|
Sun Jul 03, 2011 11:19 pm |
|
|
Pantsman
Level 39
Posts: 21063 |
Joined: Sat Feb 14, 2009 11:44 pm |
Cash on hand: 2,187.55
Bank: 5,250.50
Group: Sysop |
|
Re: OC Friday
nextScene();
Takes you to a new 'scene', and executes the first page of code on it.
To organize a document thematically, you can use scenes. For example, you might use separate scenes for an introduction, a loading message, and credits. Though using scenes has some disadvantages, there are some situations in which few of these disadvantages apply, such as when you create lengthy animations. When you use scenes, you avoid having to manage a large number of FLA files because each scene is contained within a single FLA file.
Using scenes is similar to using several FLA files together to create a larger presentation. Each scene has a Timeline. Frames in the document are numbered consecutively through the scenes. For example, if a document contains two scenes with ten frames each, the frames in Scene 2 are numbered 11–20. The scenes in the document play back in the order they are listed in the Scene panel. When the playhead reaches the final frame of a scene, the playhead progresses to the next scene. Disadvantages of scenes
When you publish a SWF file, the Timeline of each scene combines into a single Timeline in the SWF file. After the SWF file compiles, it behaves as if you created the FLA file using one scene. Because of this behavior, scenes have some disadvantages:
Controlling scene playback
To stop or pause a document after each scene, or to let users navigate the document in a nonlinear fashion, you use ActionScript. For more information see, ActionScript.
Display the Scene panel Select Window > Other Panels > Scene.
Add a scene Select Insert > Scene, or click the Add Scene button in the Scene panel.
Delete a scene Click the Delete Scene button in the Scene panel.
Change the name of a scene Double-click the scene name in the Scene panel and enter the new name.
Duplicate a scene Click the Duplicate Scene button in the Scene panel.
Change the order of a scene in the document Drag the scene name to a different location in the Scene panel.
View a particular scene Select View > Go To, and then select the name of the scene from the submenu.
Any questions?
_________________
Yeap.
_________________
1 pcs.
|
4 pcs.
|
|
Sun Jul 03, 2011 11:51 pm |
|
|
|