Public Voice Network
- Decriminalize all drugs 99
- Been asked to do a legal … 44
- Vid of the Day 1506115061
- Pic of the Day 7474674746
- London machete attack 3333
- good music with fake inst… 55
- the gif animation thread 1846518465
- News of the day... 659659
- FMT170513 1515
- Soundcloud 149149
- Adobe CS6 "Creative … 103103
- Best Free VST plugins... 11
- New BOC 2828
- You're at a party and… 6868
- What are you listening to… 55865586
- Femen 2626
- DaftPunk 210210
- Yahoo buying Tumblr 1515
- San Francisco 2222
- Flat Design 160160
- the jif animation thread 1111
- GIF vs JIF 4949
- religion 216216
- Magic Hat vs. West Sixth 88
Preloading external SWF 99 Responses
Last post: 6 years, 12 months ago | Thread started: May 29, 06, 2:38 a.m.
- thismanslife
I'm not a complete Flash novice, I've done this before many times, but not in quite the same way.
My problem is, when I use loadMovie, i'm getting a lag before it appears, even if i've loaded it & shown it already in a previous scene (a preloader scene, which I thought should load, and therefore cache, the external file!)...
I was up all night with this... :(
- May 29, 06, 2:38 a.m. – Permalink
- Fariska
usa a MovieClipLoader
http://livedocs.macromedia.com/f…

- Dog-earMay 29, 06, 2:44 a.m. – Permalink
- thismanslife
I've not seen that before... an alternative to loadMovie... but will it also have a lag?


- Dog-earMay 29, 06, 2:50 a.m. – Permalink
- Fariska
with MCloader you can handle bettere the events:
I.E.
onLoadstart: you can specify actions when loading starts
onLoadProgress: actions during the progress (typically loadbar dimensions)
onLoadComplete: when the movie is loaded but not yest placed in the stage
onLoadIniti: when the movie is loaded AND istantiated: you can do evertything at this point (hide, scale, assign actions and so on)

- Dog-earMay 29, 06, 2:54 a.m. – Permalink
- thismanslife
Ok cool, I'll have a go, thanks! :)


- Dog-earMay 29, 06, 2:58 a.m. – Permalink
- thismanslife
Ok, tried that, still get a lag exactly the same as before
:(


- Dog-earMay 29, 06, 3:26 a.m. – Permalink
- Rickbass
The lag might be because of the server you're on? Loading an external movie clip requires a request to the server and, like any page or image, this can take time.
To speed things up, you might consider starting to pre-load external swfs the moment the main timeline swf is loaded - you'll take a bandwidth hit if you load files that the user never sees, but it should give you the instantaneous feel you seem to be after.


- Dog-earMay 29, 06, 3:32 a.m. – Permalink
- thismanslife
Thanks Rick, yes I realise all that, and I *am* preloading stuff first, it's just that when the same object gets called to load into another container after the preloader, theres a lag before it appears. Preloading doesnt stop that.
I think I need a way of loading items into the library itself, so i'm not "reloading" files in everytime, they perhaps need to be loaded into the library, and thats it, they're in. That'd probably fix it.
That said... I've played with import/export runtime stuff to do exactly that, and there was no lag problem with it, but i was having trouble with my preloader, and strangeness in general... so I gave up. Also doing that didnt allow me to specify with a variable what gets loaded, it's all specified in the library. Not ideal.
Either way i'm struggling :(


- Dog-earMay 29, 06, 3:42 a.m. – Permalink
- thismanslife
tomkat : i dont have that exact setting (MX2004) but I do have "Export frame for classes" which i set to 2, made no difference.


- Dog-earMay 29, 06, 3:45 a.m. – Permalink



