0 Replies Latest reply on Aug 14, 2006 10:02 PM by dawu

    Video actionscript help

    dawu
      I got this actionscript from this forum and I need help with this.

      I want to have the flv play through then go to a frame on the timeframe. Can someone help me with this?

      var videos:Object = new Object();
      // Set up to 7 video feeds in a single component
      videos.list = new Array();
      videos.list[0] = "/originals/cs/CS_WebPromo.flv";
      videos.list[1] = "/originals/cs/LogoLoop.flv";
      videos.loop = true;
      videos.length = 1;
      videos.loaded = false;
      // Path to FLVPlayback components
      var m = this.myVideo;
      // Set the path of the first video feed
      m.contentPath = videos.list[0];
      // Set a 'ready' event handler to load the videos
      videos.ready = function(evt:Object):Void {
      if (!this.loaded) {
      this.loaded = true;
      for (var n = 1; n<this.list.length; n++) {
      if (videos.list[n].indexOf(".flv") != -1) {
      m.activeVideoPlayerIndex = n;
      m.contentPath = videos.list[n];
      this.length++;
      }
      }
      m.activeVideoPlayerIndex = 0;
      }
      };
      m.addEventListener("ready", videos);
      // Set a 'complete' event handler to load the next video
      videos.complete = function(evt:Object):Void {
      var nextIndex = Number(evt.vp)+1;
      if (nextIndex == this.length) {
      if (this.loop) {
      nextIndex = 1;
      } else {
      return;
      }
      }
      m.activeVideoPlayerIndex = nextIndex;
      m.visibleVideoPlayerIndex = nextIndex;
      m.play();
      };
      m.addEventListener("complete", videos);
      stop();