home *** CD-ROM | disk | FTP | other *** search
/ 3D Games (Spidla) / 3dhry2.iso / InterBingo 1.0 / InterBingoSetup.exe / BingoInstaller.swf / scripts / DefineSprite_3 / frame_1 / DoAction.as
Encoding:
Text File  |  2002-07-25  |  824 b   |  45 lines

  1. function StartTracking()
  2. {
  3.    Tracking = true;
  4.    UpdateProgress();
  5.    Progress = 0;
  6.    KBS = "12.5 KBS";
  7.    ETA = "5 minutes";
  8.    Component = "Casino Core";
  9. }
  10. function StopTracking()
  11. {
  12.    Tracking = false;
  13.    stop();
  14. }
  15. function UpdateProgress()
  16. {
  17.    Progress++;
  18.    trace("Updating:" + Progress);
  19.    if(100 < Progress)
  20.    {
  21.       Tracking = false;
  22.       call("_root.FINISH");
  23.       stop();
  24.    }
  25.    else
  26.    {
  27.       KBS = random(100) + 10 + " KBS";
  28.       ETA = 100 - Progress + " seconds";
  29.       _root.ProgressBar.Status = "Downloading...";
  30.       _root.ProgressBar.Progress = Progress;
  31.       _root.ProgressBar.KBS = KBS;
  32.       _root.ProgressBar.ETA = ETA;
  33.       _root.ProgressBar.Component = Component;
  34.       play();
  35.    }
  36. }
  37. if(Tracking)
  38. {
  39.    UpdateProgress();
  40. }
  41. else
  42. {
  43.    stop();
  44. }
  45.