dcsimg
A Flash Developer Resource Site

Page 2 of 10 FirstFirst 123456 ... LastLast
Results 21 to 40 of 189

Thread: For everyone with a preloader problem

  1. #21
    if you go first
    Join Date
    Oct 2005
    Location
    Herts, UK
    Posts
    62

    Still need help

    Hey,

    My problem is that I have a .swf file with 1 MB in the first frame - and that a normal preloader doesn't seem to work for this!

    Any suggestions???

    Thanks,
    Chris

    PS -
    Here's an image of the problem:
    http://www.pc16.net/chris/city/problemImage1.jpg
    How can I use this to fix it?
    The movie is about 1 megabyte - and it seems it's all in the first frame! Is this because of my library? Virtually everything is in the library - ie everything is a movieclip and is "exported" under "linkage properties".

    Is this the problem? What can I do?

    The movie is here:
    http://www.pc16.net/chris/city/index2.php?swf=cityjj
    <insert witty signature here>

  2. #22
    if you go first
    Join Date
    Oct 2005
    Location
    Herts, UK
    Posts
    62

    Really need help with this still

    Hey guys,

    I really really really need help with this.

    I have nothing unnecessary in my Library and my first frame is now EMPTY, yet Flash still tells me that my first frame is 899KB!

    I have tried everything I can think of, but preloaders aren't working properly. I have tried them in a separate scene at the beginning, and as separate .swf files. But I can't get it to count the "bytes loaded" for an external clip. I can't find anything helpful in the tutorials for Flash 5.

    Can someone plese help me?

    You can see the problem here:
    http://www.pc16.net/chris/city/problem1.jpg
    Thanks a lot,
    Chris
    <insert witty signature here>

  3. #23
    if you go first
    Join Date
    Oct 2005
    Location
    Herts, UK
    Posts
    62

    Sorted

    Hey,

    I've sorted this now:
    http://www.pc16.net/chris/city/?swf=holder

    I made holder.swf which loaded preloader.swf into level2 then loaded city.swf (my main move, 1MB) into level1.

    I used _level1.getBytesLoaded and _level1.getBytesTotal to get my percentage.

    This is all I had wanted to know - just post this in case someone else finds it helpful. I'm knackered now so I'm finally gonna sleep - woo hoo!!!

    Chris
    ps - one thing I don't understand is that my main movie works fine even though it's now in _level1, but still refers to variables loaded into _level0.
    <insert witty signature here>

  4. #24
    Flasher
    Join Date
    Jun 2005
    Posts
    1,365
    Hi. I'm glad you sorted things out. Thinking about it, that's a completely logical solution, very nice job.

    Good luck,
    Sportzguy933

  5. #25
    Advance Motion Management
    Join Date
    Mar 2006
    Location
    India
    Posts
    84
    Great Thread and wonderful explanation. Too Good


    --
    Vini
    Its in my Blood, B+



  6. #26
    XRave tongxn's Avatar
    Join Date
    Apr 2005
    Location
    Somewhere near Here
    Posts
    870
    Yea, I wonder how can you make complecated preloader? Not that I needed it but -
    When you actually know what "OMG I have so much homework!" means, you won't want to be me.
    Xrave

  7. #27
    Moderator whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,755
    tongxn-
    what kind of preloader?

    also..I knwo this thread is somewhat older..and I did NOT read the entire first post..(just most of it)...and I have to say....some of the things/ways shown to make a preloader are out of date and not good coding practices (like the going to frame 2 with code going back to frame 1)....there is no reason to do that anymore when you onClipEvent (enterFrame) and this.onEnterFrame = function() available to you.

    It also never a good idea to use preloaders IN the external.swf's you are loading..as they will never be accurate and usually cause problems.

    the best practice (IMHO) is to create a "generic" preloader...that can used over and over again...no matter what content is loaded into the "containerClip"

  8. #28
    XRave tongxn's Avatar
    Join Date
    Apr 2005
    Location
    Somewhere near Here
    Posts
    870
    oh I get it is it something like a head preloader? so that you put it into a MC and tell it to load level_whatever? I never know the stuff with levels. could anyone explain it to me?

    Regards,
    I am too basik.#
    Tongxn
    When you actually know what "OMG I have so much homework!" means, you won't want to be me.
    Xrave

  9. #29
    Flasher
    Join Date
    Jun 2005
    Posts
    1,365
    the best practice (IMHO) is to create a "generic" preloader...that can used over and over again...no matter what content is loaded into the "containerClip"
    Yes, I definitely agree with that, I don't have time to change it now, but I definitely will. But the coding practices really don't make a difference. Either way, you're still making a preloader, and I've been making it this way ever since I can remember, and it's definitely not flawed...

    ~Sportzguy933

  10. #30
    Moderator whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,755
    Coding practices DO make a difference...as older ways are abandoned everyday and with each new release. Now Im not sure what way is "definately not flawed"....but if you ARE referring to have the preloader in the external.swf that you are loading that IS a flawed method.. just because it may be working for you...(your lucky).. by design, it shouldnt...and thats why most of the time you see posts like:

    "My preloader starts @ 22%".. or "my preloader doesnt show until the external.swf is at 100%"....etc..etc.

    Wheather you make it re-usable or not..it is better to have your preloader in the MAIN .swf chekcing the content being loaded into whatever _level or movieClip you want.

  11. #31
    XRave tongxn's Avatar
    Join Date
    Apr 2005
    Location
    Somewhere near Here
    Posts
    870
    still, I still don't get no stilling stuff about _levels and everything.
    When you actually know what "OMG I have so much homework!" means, you won't want to be me.
    Xrave

  12. #32
    Flasher
    Join Date
    Jun 2005
    Posts
    1,365
    Quote Originally Posted by whispers
    Coding practices DO make a difference...as older ways are abandoned everyday and with each new release. Now Im not sure what way is "definately not flawed"....but if you ARE referring to have the preloader in the external.swf that you are loading that IS a flawed method.. just because it may be working for you...(your lucky).. by design, it shouldnt...and thats why most of the time you see posts like:

    "My preloader starts @ 22%".. or "my preloader doesnt show until the external.swf is at 100%"....etc..etc.

    Wheather you make it re-usable or not..it is better to have your preloader in the MAIN .swf chekcing the content being loaded into whatever _level or movieClip you want.
    Check out my post... I agreed with you on the "practice" of preloading external scripts...

    ~Sportzguy933

  13. #33
    XRave tongxn's Avatar
    Join Date
    Apr 2005
    Location
    Somewhere near Here
    Posts
    870
    why no one answer me!
    When you actually know what "OMG I have so much homework!" means, you won't want to be me.
    Xrave

  14. #34
    Flasher
    Join Date
    Jun 2005
    Posts
    1,365
    Quote Originally Posted by tongxn
    still, I still don't get no stilling stuff about _levels and everything.
    Because 'no stilling stuff' doesn't make any sense... lol .

    ~Sportzguy933

  15. #35
    XRave tongxn's Avatar
    Join Date
    Apr 2005
    Location
    Somewhere near Here
    Posts
    870
    but no stuff dont make sense, everything doesn't not does.
    When you actually know what "OMG I have so much homework!" means, you won't want to be me.
    Xrave

  16. #36
    Moderator whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,755
    I dont use _levels much (only for music)...

    but _levels are like movieClips.. but they are stacked on top of each other. I do believe they supercede all layers as well.

    anyways... your MAIN.swf is always treated as _level 0 ... so remeber that when loading into levels.

    Also..you woudl not use "loadMovie();"....but you would use loadMoivieNum() as this lets you assign a parameter for the _level.

    play with it... start new .fla and load some random images into _levels

    I prefer loading into target clips (movieClips)

  17. #37

  18. #38
    Advance Motion Management
    Join Date
    Mar 2006
    Location
    India
    Posts
    84
    Hey Wisper,
    I agree with you. If you make it complicated, the more complicated it gets on the server, and it becomes difficult for you to handle it later. Keep it to the basics.
    Last edited by vinitt jaiswal; 03-13-2006 at 04:04 AM.


    --
    Vini
    Its in my Blood, B+



  19. #39
    XRave tongxn's Avatar
    Join Date
    Apr 2005
    Location
    Somewhere near Here
    Posts
    870
    if you get the double negative, you get that sentence.
    When you actually know what "OMG I have so much homework!" means, you won't want to be me.
    Xrave

  20. #40

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center