troubleshooting Question

FLV Pre-loader

Avatar of walker6o9
walker6o9 asked on
Adobe Flash
1 Comment1 Solution1013 ViewsLast Modified:
Here's the loading code from a flash video player I wrote a while back--I was wondering if there is an easy way to either add a pre-loader, or add something that checks to see if it has loaded or its progress loading.

Here's how I call it:

moviePlayer = attachMovie("moviePlayer", "moviePlayer", 9000)
                  moviePlayer._x = -3
                  moviePlayer._alpha = 0
                  //myMovie._alpha = 0
                  pathFinalNum = int(pathNum) + 1
                  //moviePlayer.contentPath = myMovie.folderPath+"/fullMovies/"+pathFinalNum+".flv"
                  myPath = myMovie.folderPath+"/fullMovies/"+pathFinalNum+".mov"
                  moviePlayer.path = myPath
                  moviePlayer.returnButton._alpha = 0

And then inside moviePlayer I have an FLVPlayer called video and this code:

var my_nc:NetConnection = new NetConnection();
my_nc.connect(null);
var my_ns:NetStream = new NetStream(my_nc);
video.play(path);
this.createEmptyMovieClip("flv_mc", this.getNextHighestDepth());
flv_mc.attachAudio(my_ns);
var audio_sound:Sound = new Sound(flv_mc);

ASKER CERTIFIED SOLUTION
Join our community to see this answer!
Unlock 1 Answer and 1 Comment.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 1 Comment.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros