A Flash Developer Resource Site

Results 1 to 10 of 10

Thread: Pre-load external swf files in V2

Hybrid View

  1. #1
    Junior Member
    Join Date
    Jan 2004
    Location
    Rome
    Posts
    11

    Pre-load external swf files in V2

    Hi! I've a specific trouble. I've created a Swish SWF, which loads (load movie action) an external one, made in Flash (see my other post"Trouble importing Flash swf in Swish 2.0").

    The problem is that when I play the load movie action, flash movie, has to load itself, so that it appears very late in the main Swish animation.

    Can somebody help me? Is it possible to "preload" a movie that will be loaded in a Swish swf?

    Thank U in advance, Cristian
    (Pubbliman)

    Last edited by Pubbliman; 01-28-2004 at 06:46 AM.

  2. #2
    Senior Member Dead Rabbit's Avatar
    Join Date
    Oct 2002
    Location
    Back in Tampa FLA again - and happy!
    Posts
    2,403
    Sort of. Here's one method:

    Create a sprite offstage somewhere, or place it behind something on your main movie. Use Tell Target to load teh .swf into the Sprite. This will force it to download to the user's drive, so when it's seen later, it will already be there.
    While changing my profile, I accidentally clicked the link that said
    "Add 'Dead Rabbit' to your Ignore List"
    so now I can't talk to myself anymore...

    The Repository -:- The Forum

  3. #3
    Junior Member
    Join Date
    Jan 2004
    Location
    Rome
    Posts
    11
    I was thinking as the same. I think it should work quite fine.
    Thank you very much.

    Bye, Cristian
    (Pubbliman).

  4. #4
    Member
    Join Date
    Sep 2003
    Posts
    79

    pre-load content

    Originally posted by Dead Rabbit
    Sort of. Here's one method:

    Create a sprite offstage somewhere, or place it behind something on your main movie. Use Tell Target to load teh .swf into the Sprite. This will force it to download to the user's drive, so when it's seen later, it will already be there.
    Hello !!

    tried this function ie.

    onFrame (1) {
    tellTarget (rr1.swf) {
    }
    }

    and it dosn´t speed up the loading time on the web?
    would be grateful for help
    cheers in advance

    geoff

  5. #5
    Senior Member Dead Rabbit's Avatar
    Join Date
    Oct 2002
    Location
    Back in Tampa FLA again - and happy!
    Posts
    2,403
    This won't make the .swf load any faster, it just makes it load sooner. This method works best when loading an external that will be used later in the movie somewhere.

    There is no real method to make the bytes move any faster over the internet.

    Hope this helps somewhat...
    While changing my profile, I accidentally clicked the link that said
    "Add 'Dead Rabbit' to your Ignore List"
    so now I can't talk to myself anymore...

    The Repository -:- The Forum

  6. #6
    Senior Member
    Join Date
    Jan 2003
    Location
    United States
    Posts
    892
    Hi Brad,

    I know this is off topic, but it's good to see you back.
    Welcome Back.

    I thought you went off into married bliss to never return again

    Blessings

    jwr
    When all is said and done -- "You MUST be Born Again!" John 3:3

  7. #7
    Member
    Join Date
    Sep 2003
    Posts
    79

    reply preloader

    Hi Brad!

    Thanks for your comments about data loading.

    I´ll try and explain a little better: :-)

    I thought by giving a command to preload data, say on a index page that by the time the viewer goes/clicks to the desired page the data i.e. in this case a sound example would have been loaded in the background so that the viewer just clicks on the play sound button and the sound plays - instead of the case now (with above script) the sound loads again compleatly from 0 - taking time!!.

    I hope you can get my drift :-) and thanks for your attention!

    geoff

  8. #8
    Senior Member Dead Rabbit's Avatar
    Join Date
    Oct 2002
    Location
    Back in Tampa FLA again - and happy!
    Posts
    2,403

    Re: pre-load content


    onFrame (1) {
    tellTarget (rr1.swf) {
    }
    }
    Should generate an error(?)

    This script is talking to a target that doesn't yet exist, and then doesn't tell it to do anything.

    something like:
    Code:
    onFrame (1) {
        loadersprite.loadMovie("rr1.swf");
    }
    would tell a sprite (named "loadersprite" in this example) to load the external movie. Just be sure the sprite exists, and that it is out of site.

    Hope this helps!
    While changing my profile, I accidentally clicked the link that said
    "Add 'Dead Rabbit' to your Ignore List"
    so now I can't talk to myself anymore...

    The Repository -:- The Forum

  9. #9
    Member
    Join Date
    Sep 2003
    Posts
    79

    reply preload

    Thanks Brad!

    I did what you said and the sound file "rr1.swf" plays
    automatically. Which should not happen, until the viewer
    press´s a button whereby the sound /if I understand right
    has been preloaded enabling the viewer lesser waiting time
    instead of on pressing button (load movie.rr1.swf)

    This szenario might be a bit different being a swf (sound file)
    that can not be hidden.

    I don´t know if you can follow this expanation. Sending a file
    would be a little difficult but possible if you advise.

    Thanks again, in advance

    geoff

  10. #10
    Member
    Join Date
    Sep 2003
    Posts
    79
    Hi!

    I hope the accompanying file will help a little.

    As of present the sound 1 loads on activating red
    awestruck. This script can be found under sprite
    _1 _1 actions.

    Now would it be possible to preload this sound file
    rr1.swf before the viewer press the button awestruck
    so that the viewer then can promptly hear the sound
    without having to wait for the movie then to load
    as currently under www.rhythmresearch.de the case is.

    If so, what command and where would you advise placing it.
    Thanks in advance - much appriciated !!

    geoff
    Attached Files Attached Files

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