home *** CD-ROM | disk | FTP | other *** search
/ 600 Games / 600games.iso / Nave / dragonforce.swf / scripts / DefineSprite_44_transition / frame_24 / DoAction.as
Encoding:
Text File  |  2006-06-13  |  8.3 KB  |  324 lines

  1. if(_root.fade == "out")
  2. {
  3.    _root[_root.currentloop].stop();
  4. }
  5. if(_root.startgame == true)
  6. {
  7.    _root.maindisplay.gotoAndStop("blank");
  8.    _root.clean();
  9.    _root.depth = 2;
  10.    _root.init();
  11.    _root.status._visible = true;
  12.    if(_root.levelnumber == 1)
  13.    {
  14.       _root.ship.shiptype.gotoAndStop("nolaser");
  15.       _root.havelaser = false;
  16.       _root.status.mask.laser._xscale = 0;
  17.       _root.protectorlevel = 0;
  18.       _root.weaponnumber = 1;
  19.       _root.passtext1 = "neeL";
  20.       _root.display.gotoAndPlay("mission");
  21.    }
  22.    else if(_root.levelnumber == 2)
  23.    {
  24.       _root.protectorlevel = 0;
  25.       _root.havelaser = true;
  26.       _root.ship.shiptype.gotoAndStop("yeslaser");
  27.       if(_root.weaponnumber > 2)
  28.       {
  29.          _root.weaponnumber = 1;
  30.       }
  31.       _root.passtext1 = "eGdl";
  32.       _root.display.gotoAndPlay("mission");
  33.    }
  34.    else if(_root.levelnumber == 3)
  35.    {
  36.       if(_root.difficulty == "easy")
  37.       {
  38.          _root.protectorlevel = 2;
  39.          _root.ship.protector.gotoAndStop("protector");
  40.       }
  41.       else if(_root.difficulty == "expert")
  42.       {
  43.          _root.protectorlevel = 1;
  44.          _root.ship.protector.gotoAndStop("protector");
  45.       }
  46.       _root.havelaser = true;
  47.       _root.ship.shiptype.gotoAndStop("yeslaser");
  48.       if(_root.weaponnumber > 3)
  49.       {
  50.          _root.weaponnumber = 1;
  51.       }
  52.       _root.passtext1 = "top8";
  53.       _root.display.gotoAndPlay("mission");
  54.    }
  55.    else if(_root.levelnumber == 4)
  56.    {
  57.       _root.display.gotoAndPlay("fmission");
  58.       _root.havelaser = true;
  59.       _root.ship.shiptype.gotoAndStop("yeslaser");
  60.       _root.passtext1 = "lylS";
  61.       _root.assignx = 900;
  62.       _root.assigny = 100;
  63.       _root.missilepowerupfunction();
  64.       _root.assignx = 900;
  65.       _root.assigny = 200;
  66.       _root.weaponpowerupfunction();
  67.       _root.assignx = 900;
  68.       _root.assigny = 300;
  69.       _root.missilepowerupfunction();
  70.       _root.assignx = 900;
  71.       _root.assigny = 400;
  72.       _root.protectorpowerupfunction();
  73.    }
  74.    if(_root.mode == "survival")
  75.    {
  76.       _root.shipshield = 1;
  77.       _root.assignx = 710;
  78.       _root.assigny = 250;
  79.       _root.weaponpowerupfunction();
  80.       _root.havelaser = false;
  81.       _root.ship.shiptype.gotoAndStop("nolaser");
  82.       _root.status.mask.laser._xscale = 0;
  83.       _root.status.score = int(_root.totalscore2);
  84.    }
  85.    else if(_root.mode == "mission")
  86.    {
  87.       if(_root.difficulty == "easy")
  88.       {
  89.          _root.shipshield = 50;
  90.       }
  91.       else if(_root.difficulty == "expert")
  92.       {
  93.          if(_root.shipshield > 45)
  94.          {
  95.             _root.shipshield = 50;
  96.          }
  97.          else
  98.          {
  99.             _root.shipshield += 5;
  100.          }
  101.       }
  102.       _root.status.score = int(_root.totalscore);
  103.    }
  104.    _root.status.mask.shield._xscale = 100 * (_root.shipshield / _root.shipshieldtotal);
  105.    if(_root.difficulty == "easy")
  106.    {
  107.       _root.enemiesrequired = 10;
  108.    }
  109.    else if(_root.difficulty == "expert")
  110.    {
  111.       _root.enemiesrequired = 13;
  112.    }
  113.    _quality = "low";
  114.    _root.bluedepth = 10010;
  115.    _root.ship._x = 100;
  116.    _root.ship._y = 200;
  117.    _root.whichmissileframe = "level" + _root.mhlevel;
  118.    _root.status.mask.missile.gotoAndStop(_root.whichmissileframe);
  119.    _root.status.bomb.gotoAndStop(_root.numberofbombs + 1);
  120.    _root.enemyticker = -25;
  121.    _root.firetimer = 0;
  122.    _root.sgreenfunction = false;
  123.    _root.sgreentimer = 0;
  124.    _root.bosskilled = false;
  125.    _root.gamestart = true;
  126.    _root.gametimer = true;
  127.    _root.timing = true;
  128.    _root.time = 0;
  129.    _root.boss = false;
  130.    _root.bosscoming = 0;
  131.    _root.bossready = false;
  132.    _root.targetenemy = 0;
  133.    _root.maindisplay.gotoAndStop("blank");
  134.    _root.pausedisplay._visible = false;
  135.    _root.bg.gotoAndStop("level" + _root.levelnumber);
  136.    _root.currentscore = _root.totalscore;
  137.    if(_root.globalmusiccontrol == "play")
  138.    {
  139.       _root.musicplaying = true;
  140.       _root.fade = "in";
  141.       _root.loopvolume = 100;
  142.       if(_root.mode == "mission")
  143.       {
  144.          _root.currentloop = "loop" + _root.levelnumber;
  145.          _root[_root.currentloop].start(0,20);
  146.          _root[_root.currentloop].setVolume(100);
  147.          _root.status.mask.box._x = 212.3;
  148.       }
  149.       else if(_root.mode == "survival")
  150.       {
  151.          _root.currentloop = "survivalloop";
  152.          _root[_root.currentloop].start(0,9999999);
  153.          _root[_root.currentloop].setVolume(300);
  154.       }
  155.       _root.status.mask.box._x = 212.3;
  156.    }
  157.    else
  158.    {
  159.       _root.status.mask.box._x = 245;
  160.    }
  161.    _root.status._visible = true;
  162.    _root.transform = true;
  163.    _root.startgame = false;
  164.    if(_root.numberofbombs == 0)
  165.    {
  166.       _root.passtext2 = "16Eg";
  167.    }
  168.    else if(_root.numberofbombs == 1)
  169.    {
  170.       _root.passtext2 = "Gecl";
  171.    }
  172.    else if(_root.numberofbombs == 2)
  173.    {
  174.       _root.passtext2 = "bvWi";
  175.    }
  176.    else if(_root.numberofbombs == 3)
  177.    {
  178.       _root.passtext2 = "Sidk";
  179.    }
  180.    else if(_root.numberofbombs == 4)
  181.    {
  182.       _root.passtext2 = "57Fd";
  183.    }
  184.    else if(_root.numberofbombs == 5)
  185.    {
  186.       _root.passtext2 = "Wwpa";
  187.    }
  188.    else if(_root.numberofbombs == 6)
  189.    {
  190.       _root.passtext2 = "3dEp";
  191.    }
  192.    else if(_root.numberofbombs == 7)
  193.    {
  194.       _root.passtext2 = "rtms";
  195.    }
  196.    else if(_root.numberofbombs == 8)
  197.    {
  198.       _root.passtext2 = "RFdY";
  199.    }
  200.    else if(_root.numberofbombs == 9)
  201.    {
  202.       _root.passtext2 = "DFSc";
  203.    }
  204.    else if(_root.numberofbombs == 10)
  205.    {
  206.       _root.passtext2 = "qwt7";
  207.    }
  208.    else if(_root.numberofbombs == 11)
  209.    {
  210.       _root.passtext2 = "mzx6";
  211.    }
  212.    else if(_root.numberofbombs == 12)
  213.    {
  214.       _root.passtext2 = "ukdf";
  215.    }
  216.    else if(_root.numberofbombs == 13)
  217.    {
  218.       _root.passtext2 = "Elmb";
  219.    }
  220.    else if(_root.numberofbombs == 14)
  221.    {
  222.       _root.passtext2 = "1l1l";
  223.    }
  224.    else if(_root.numberofbombs == 15)
  225.    {
  226.       _root.passtext2 = "ghtc";
  227.    }
  228.    if(_root.mhlevel == 0)
  229.    {
  230.       _root.passtext3 = "addd";
  231.    }
  232.    else if(_root.mhlevel == 1)
  233.    {
  234.       _root.passtext3 = "ALfj";
  235.    }
  236.    else if(_root.mhlevel == 2)
  237.    {
  238.       _root.passtext3 = "ruGk";
  239.    }
  240.    else if(_root.mhlevel == 3)
  241.    {
  242.       _root.passtext3 = "ryNh";
  243.    }
  244.    else if(_root.mhlevel == 4)
  245.    {
  246.       _root.passtext3 = "6kjs";
  247.    }
  248.    else if(_root.mhlevel == 5)
  249.    {
  250.       _root.passtext3 = "142H";
  251.    }
  252.    if(_root.weaponnumber == 1)
  253.    {
  254.       _root.passtext4 = "h8vb";
  255.    }
  256.    else if(_root.weaponnumber == 2)
  257.    {
  258.       _root.passtext4 = "eaaP";
  259.    }
  260.    else if(_root.weaponnumber == 3)
  261.    {
  262.       _root.passtext4 = "rty4";
  263.    }
  264.    else if(_root.weaponnumber == 4)
  265.    {
  266.       _root.passtext4 = "7gf7";
  267.    }
  268.    if(_root.weapontype == "red")
  269.    {
  270.       _root.passtext5 = "alsk";
  271.    }
  272.    else if(_root.weapontype == "blue")
  273.    {
  274.       _root.passtext5 = "KAKA";
  275.    }
  276.    else if(_root.weapontype == "green")
  277.    {
  278.       _root.passtext5 = "99Kl";
  279.    }
  280. }
  281. if(_root.abortmission == true)
  282. {
  283.    _root[_root.currentloop].stop();
  284.    _root.pausedisplay.gotoAndStop("pause");
  285.    _root.pausedisplay._visible = false;
  286.    _root.paused = false;
  287.    _quality = "high";
  288.    _root.levelnumber = 1;
  289.    _root.reset = true;
  290.    _root.controls._visible = false;
  291.    _root.gamestart = false;
  292.    _root.abortmission = false;
  293.    _root.maindisplay.gotoAndStop("title");
  294.    _root.clean();
  295.    _root.gamestart = false;
  296.    _root.youaredead = false;
  297.    _root.time = 0;
  298.    _root.bombsound = false;
  299.    _root.havelaser = false;
  300.    _root.mhshotting = false;
  301.    _root.sgreenfunction = false;
  302.    _root.sgreentimer = 0;
  303.    _root.autorotate = false;
  304.    _root.protectorlevel = 0;
  305.    _root.hitshipcounter = 0;
  306.    _root.shipshieldtotal = _root.shipshield = 50;
  307.    _root.status.mask.shield._xscale = 100 * (_root.shipshield / _root.shipshieldtotal);
  308.    _root.gametimer = false;
  309.    _root.numberofbombs = 3;
  310.    _root.targetenemy = 0;
  311.    _root.mhlevel = 0;
  312.    _root.whichmissileframe = "level" + _root.mhlevel;
  313.    _root.status.mask.missile.gotoAndStop(_root.whichmissileframe);
  314.    _root.protectorlevel = 0;
  315.    _root.weapontype = "red";
  316.    _root.weaponnumber = 1;
  317.    _root.boss3x = 600;
  318.    _root.boss3y = 100;
  319.    _root.boss3s = 5;
  320.    _root.boss3turndelay = 5;
  321.    _root.boss3totalhealth = _root.boss3health = 299 * _root.health;
  322.    _root.maindisplay.givepass.gotoAndStop("blank");
  323. }
  324.