0 Replies Latest reply on Nov 24, 2006 1:47 AM by Newsgroup_User

    any netstream gurus?

    Level 7
      Any help is greatly appreciated.


      this is what my site does. Using netstream a I am loading external flvs into
      my flash movie. Loading is working fine. I've used a tutorial meant for
      loading one movie at runtime and have been modifying it while trying to
      learn. What is NOT working....

      There is a buffering clip that runs when a flv is loaded. I can only get it
      to work for the first movie that loads since this was the way it was written
      for the tutorial. Once it dissappears after the first movie is playing it
      doesn't return and show buffering for the others, which I need it to do.

      The buffering clip needs to be invisible until the first button is pressed
      to load the movie. Tried setting its visibilty to "false" to start.

      Cant seem to get the movie to unload and clear the stage once it is done
      playing. Tried ns.close();

      and Last,,,what is the easiest way to trigger an event on the main timeline
      from the flv timeline? I need to have a new menu appear at the end of the
      flv's. Is there a end stream command or something?

      Thanks so much obviously this is new to me. Below is the code I am tyring to
      work with.

      URL is www.amazingwebs.com/flinch/flinchfinal.html under construction.

      stop();

      //SET UP CONNECTION

      var nc:NetConnection = new NetConnection();
      nc.connect (null);

      var ns:NetStream = new NetStream(nc);
      theVideo.attachVideo(ns);

      //BUFFERING

      ns.setBufferTime(15);

      //SHOW BUFFERING IMAGE

      this.bufferclip._visible = false; //trying to have

      ns.onStatus =function(info) {
      if(info.code == "NetStream.Buffer.Full") {
      bufferclip._visible = false;
      }
      if(info.code == "NetStream.Buffer.Empty") {
      bufferclip._visible = true;
      }


      }


      //assign buttons
      //BASE JUMP BUTTONS

      this.baseJump_btn.onPress = function () {
      ns.play(" http://amazingwebs.com/flinch/manofyear.flv");
      }
      this.baseJump_btn.onRollOver = function () {
      _root.spotSelections.baseJump.baseJumpRollover.gotoAndStop("over");

      }
      this.baseJump_btn.onRollOut = function () {
      _root.spotSelections.baseJump.baseJumpRollover.gotoAndStop("on");
      }

      //TRAIN BUTTONS

      this.train_btn.onPress = function () {
      ns.play(" http://amazingwebs.com/flinch/For Love of Country.flv");
      }

      this.train_btn.onRollOver = function () {
      _root.spotSelections.train.baseJumpRollover.gotoAndStop("over");
      }

      this.train_btn.onRollOut = function () {
      _root.spotSelections.train.baseJumpRollover.gotoAndStop("on");
      }

      //WATERFALL BUTTON

      this.waterfall_btn.onPress = function () {
      ns.play(" http://amazingwebs.com/flinch/bk.flv");
      }

      this.waterfall_btn.onRollOver = function () {
      _root.spotSelections.waterfall.baseJumpRollover.gotoAndStop("over");
      }

      this.waterfall_btn.onRollOut = function () {
      _root.spotSelections.waterfall.baseJumpRollover.gotoAndStop("on");
      }

      // MOVIE CONTROL BUTTONS

      this.controller.controllerButtons.rewindButton.onRelease = function() {
      ns.seek(0);
      }
      this.controller.controllerButtons.playButton.onRelease = function(){
      ns.pause();
      }
      this.controller.controllerButtons.pauseButton.onRelease = function(){
      ns.pause();
      }

      //additional code is working

      thanks so much