1 Reply Latest reply on Aug 11, 2006 4:09 PM by kglad

    help with this code... preloader ... again...

    julieta
      Sorry to bother you again with this... i am new to flash and this is kind of overwhelming sometimes...
      I'm using loadMovieNum to load a swf movie as kglad suggested, and it works, but when I try to make the preloader I get stuck. I use _level1.getBytesTotal and _level1.getBytesLoaded but I get "undfefined"... I check them with _level0 and they give me numbers... could someone please check my code? I would be really greatful.

      my loadermovie has 3 frames.
      on frame 1 I have:

      loadMovieNum("cielospreloadtest.swf",1);
      gotoAndPlay(2);

      on frame 2 I have:
      stop();
      var amount:Number;
      amount=_level1.getBytesLoaded() / _level1.getBytesTotal() * 100; //(these do not work);tried everythng in the first
      //frame and didn't work either.
      loader._xscale=amount;
      textamount.text=Math.round(amount) + "%"
      if (amount==100) {
      this.gotoAndPlay(3);
      }else{
      gotoAndPlay(2);
      };
      on frame 3 i have
      stop();