[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 528
  • Last Modified:

Flash CS5 - .swf file playing before preloader finishes

Using a preloader, but the audio (FLVPlayback component) starts before preloader finishes.

How do I stop that FLVPlayback component (instance name = aud01) from playing until the entire .swf file is loaded?

Here is my AS3:

import fl.video.MetadataEvent;
aud01.addEventListener(MetadataEvent.CUE_POINT, fl_CuePointHandler);

function fl_CuePointHandler(event:MetadataEvent):void
{
      if (event.info.name=="Cue Point 1")
      {gotoAndStop(5);}
      {trace(event.info.name + ", Time = " + aud01.playheadTime + ", Frame " + (this.currentFrame +1));}
      
      if (event.info.name=="Cue Point 2")
      {gotoAndStop(10);}
      
      if (event.info.name=="Cue Point 3")
      {gotoAndStop(15);}      

}

stop();
0
tlengnick
Asked:
tlengnick
  • 4
1 Solution
 
Jen0910Commented:
Do you have your preloader set to progressive load? If so, it will play before the entire item is loaded.
0
 
tlengnickAuthor Commented:
How do check that? Flash cs5
0
 
tlengnickAuthor Commented:
0
 
tlengnickAuthor Commented:
I figured it out...

In general, I did the following:

() Unchecked "autoplay" in the properties panel of the FLVPlayback file
() Made sure there was no AS3 on frame 1 telling it to play
() In my preloader, in the "load complete" function, I told it to play the video
0
 
tlengnickAuthor Commented:
no comments/help added after one initial inquiry.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now