I am trying to build a loader movie for another large application director movie ("'ea300.dcr") on the web. I have this code on an early frame of the loader
gNetID = 0
netDone(gNetID) = 0
on exitFrame me
gNetID = gotoNetMovie("http://www.myclient.com/client_proposals/ClientAnim/Data/ea300.dcr")
go to "audio2"
----on the following frame I have-----
on beginsprite me
sprite(89).width = 1
on exitFrame me
myaudio = getStreamStatus(gNetID)
sprite(84).member.text = String(getStreamStatus(gNetID))
if myaudio.bytesTotal > 0 then
zoo = float(myaudio.bytesSoFar)
set the floatprecision to 2
sprite(16).width = integer(143 * (zoo / zoo2))
sprite(26).member.text = string(( zoo / zoo2 * 100))
sprite(18).member.text = "Loading Audio"
if netdone(gNetID) = False then
go the frame
go to "audio3"
----and on a consecutive frame
if netError(gNetID) <> "OK" then
go to "start"
The problem is with gotoNetMovie it is hanging at "connecting" and | cannot download the movie. If I change gotoNetMovie to preloadNetThing the file downloads but I do not know how to play it. I called
play movie("ea300.dcr") and get an error saying I have to stop the current movie to play a new one
gotoNetMovie("http://www.myclient.com/client_proposals/ClientAnim/Data/ea300.dcr") --- nothing changes
gotoNetMovie("ea300.dcr") -- again nothing
Has anyone had similiar problems and resolved them. I am confused as to why the preloadnetthing() can find the file and download it and gotonetmovie() cannot. If I can download the movie with preloadnetthing() then how can I force it to play from cache.
Any ideas will sincerely welcome.
If I can download the movie with preloadnetthing() then how can I force it to play from cache.
This is exactly the approach you should take. Use preloadNetThing() to download your target movie into the browser's/Shockwave's cache then use gotoNetMovie() when it's available. If you provide the same URL for the gotoNetMovie as you used to preloadNetThing then Shockwave is smart enough to use the cached version.