Advertisement
Guest User

Untitled

a guest
Jul 15th, 2017
391
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. //"Horror!" button
  2. on(release){
  3.     poz = 10;
  4. }
  5. //"In the Dark (up)" button
  6. on(release){
  7.     che.gotoAndStop(2);
  8. }
  9. //"Change" button, Couldn't you just do this? `on(release){guh=(guh%5)+1;duoxie.gotoAndStop(guh);}`
  10. on(release){
  11.     if(guh == 5) {
  12.         duoxie.gotoAndStop(1);
  13.         guh = 1;
  14.     } else if(guh == 1) {
  15.         duoxie.gotoAndStop(2);
  16.         guh = 2;
  17.     } else if(guh == 2) {
  18.         duoxie.gotoAndStop(3);
  19.         guh = 3;
  20.     } else if(guh == 3) {
  21.         duoxie.gotoAndStop(4);
  22.         guh = 4;
  23.     } else if(guh == 4) {
  24.         duoxie.gotoAndStop(5);
  25.         guh = 5;
  26.     }
  27. }
  28. //frame 1
  29. getUrl("FSCommand:showmenu", "false");
  30. getUrl("FSCommand:trapallkeys", "true");
  31. //frame 2
  32. if(getBytesLoaded() < getBytesTotal()) {
  33.     gotoAndPlay(1);
  34. }
  35. //frame 3, these abbreviations confuse me.
  36. var huh = 1;
  37. var tuh = 1;
  38. var guh = 1;
  39. gotoAndStop(10);
  40. //frame 4
  41. var pan = 1;
  42. var timery = 0;
  43. var veloy = 0;
  44. var onob = 0;
  45. var namo = 0;
  46. var velox = 0;
  47. var timer = 0;
  48. var poz = 0;
  49. var score = 0;
  50. var b1 = 1;
  51. var b2 = 0;
  52. var fur = 0;
  53. var sooth = -17;
  54. var escore;
  55. var good = 0;
  56. var go = 0;
  57. var tootoo = 0;
  58. var platon = 0;
  59. var jh = 0;
  60. var jt = 0;
  61. if(huh == 1) {
  62.     mhm.gotoAndStop(1);
  63. } else if(huh == 2) {
  64.     mhm.gotoAndStop(9);
  65. } else if(huh == 3) {
  66.     mhm.gotoAndStop(10);
  67. } else if(huh == 4) {
  68.     mhm.gotoAndStop(11);
  69. } else if(huh == 5) {
  70.     mhm.gotoAndStop(12);
  71. }
  72. if(tuh == 1) {
  73.     pla1.gotoAndStop(1);
  74.     pla2.gotoAndStop(1);
  75.     pla3.gotoAndStop(1);
  76.     pla4.gotoAndStop(1);
  77. } else if(tuh == 2) {
  78.     pla1.gotoAndStop(2);
  79.     pla2.gotoAndStop(2);
  80.     pla3.gotoAndStop(2);
  81.     pla4.gotoAndStop(2);
  82. } else if(tuh == 3) {
  83.     pla1.gotoAndStop(3);
  84.     pla2.gotoAndStop(3);
  85.     pla3.gotoAndStop(3);
  86.     pla4.gotoAndStop(3);
  87. } else if(tuh == 4) {
  88.     pla1.gotoAndStop(4);
  89.     pla2.gotoAndStop(4);
  90.     pla3.gotoAndStop(4);
  91.     pla4.gotoAndStop(4);
  92. } else if(tuh == 5) {
  93.     pla1.gotoAndStop(5);
  94.     pla2.gotoAndStop(5);
  95.     pla3.gotoAndStop(5);
  96.     pla4.gotoAndStop(5);
  97. }
  98. //frame 5
  99. fo._x = mhm._x;
  100. if(mhm._y < -30) {
  101.     fo.gotoAndStop(2);
  102.     fo._height = - mhm._y;
  103.     fo._width = (- mhm._y) / 2 + 130;
  104. } else if(mhm._y >= -30) {
  105.     fo.gotoAndStop(1);
  106. }
  107. if(Key.isDown(17)) {
  108.     che.gotoAndStop(3);
  109.     _quality = "LOW";
  110. }
  111. if(Key.isDown(34)) {
  112.     good = 1;
  113. }
  114. che._x = mhm._x;
  115. che._y = mhm._y;
  116. if(Key.isDown(38) && fur == 0) {
  117.     if(che._currentframe == 2) {
  118.         che.gotoAndStop(1);
  119.         _quality = "HIGH";
  120.     } else if(Key.isDown(38)) {
  121.         che.gotoAndStop(2);
  122.         _quality = "MEDIUM";
  123.     }
  124.     fur = 8;
  125. }
  126. if(fur > 0) {
  127.     fur--;
  128. }
  129. escore = score;
  130. if(Key.isDown(36) && poz < 0) {
  131.     poz = 1;
  132.     doy.gotoAndStop(1);
  133. } else if(Key.isDown(45)) {
  134.     poz = -5;
  135.     doy.gotoAndStop(2);
  136. }
  137. if(poz == 0) {
  138.     doy.gotoAndStop(1);
  139. }
  140. if(Key.isDown(33)) {
  141.     sooth = -150;
  142. }
  143. if(mhm._currentframe == 9 || mhm._currentframe == 10 || mhm._currentframe == 11 || mhm._currentframe == 12) {
  144.     mhm.gotoAndStop(mhm._currentframe);
  145. } else if(velox < 0.5 && velox > -0.5) {
  146.     velox = 0;
  147. } else if(veloy != 0 && velox == 0) {
  148.     mhm.gotoAndStop(8);
  149. } else if(veloy != 0 && velox < 0) {
  150.     mhm.gotoAndStop(7);
  151. } else if(veloy != 0 && velox > 0) {
  152.     mhm.gotoAndStop(6);
  153. } else if(velox > 5) {
  154.     mhm.gotoAndStop(2);
  155. } else if(velox < -5) {
  156.     mhm.gotoAndStop(3);
  157. } else if(velox > 1) {
  158.     mhm.gotoAndStop(4);
  159. } else if(velox < -1) {
  160.     mhm.gotoAndStop(5);
  161. } else {
  162.     mhm.gotoAndStop(1);
  163. }
  164. if(onob == 1) {
  165.     if(mhm._y <= pla1._y + 30) {
  166.         platon = plon - 1 + tootoo;
  167.     } else {
  168.         platon = plon - 9 + tootoo;
  169.     }
  170. }
  171. pla1.num = tootoo;
  172. var i = 1;
  173. while(i <= 8) {
  174.     if(mhm._y > _root["pla" + i]._y - 10 && mhm._y < _root["pla" + i]._y + 10 && veloy > 0 && mhm._x > _root["pla" + i]._x - 85 && mhm._x < _root["pla" + i]._x + 85) {
  175.         mhm._y = _root["pla" + i]._y;
  176.         onob = 1;
  177.         veloy = 0;
  178.         plon = i;
  179.     } else if((mhm._x < _root["pla" + i]._x - 85 || mhm._x > _root["pla" + i]._x + 85) && mhm._y > _root["pla" + i]._y - 10 && mhm._y < _root["pla" + i]._y + 10) {
  180.         onob = 0;
  181.     }
  182.     i++;
  183. }
  184. if(bul1._x > 560 && b1 == 1 || bul1._x < -10 && b1 == 0) {
  185.     if(Math.random() > 0.5) {
  186.         bul1._x = Math.random() * 200 + 570;
  187.         bul1._y = Math.random() * 80;
  188.         b1 = 0;
  189.     } else {
  190.         bul1._x = Math.random() * 200 - 220;
  191.         bul1._y = Math.random() * 80;
  192.         b1 = 1;
  193.     }
  194. }
  195. if(onob == 1) {
  196.     velox = velox * 0.83;
  197. } else {
  198.     velox = velox * 0.9;
  199. }
  200. if(bul2._x > 560 && b2 == 1 || bul2._x < -10 && b2 == 0) {
  201.     if(Math.random() > 0.5) {
  202.         bul2._x = Math.random() * 200 + 570;
  203.         bul2._y = Math.random() * 80;
  204.         b2 = 0;
  205.     } else {
  206.         bul2._x = Math.random() * 200 - 200;
  207.         bul2._y = Math.random() * 80;
  208.         b2 = 1;
  209.     }
  210. }
  211. if(b1 == 1 && guh > 1) {
  212.     bul1._x = bul1._x + 10;
  213.     bul1.gotoAndStop(guh);
  214.     bul1._y = bul1._y + pan;
  215. }
  216. if(b1 == 0 && guh > 1) {
  217.     bul1._x = bul1._x - 10;
  218.     bul1.gotoAndStop(guh);
  219.     bul1._y = bul1._y + pan;
  220. }
  221. if(b2 == 1 && guh > 1) {
  222.     bul2._x = bul2._x + 10;
  223.     bul2.gotoAndStop(guh);
  224.     bul2._y = bul2._y + pan;
  225. }
  226. if(b2 == 0 && guh > 1) {
  227.     bul2._x = bul2._x - 10;
  228.     bul2.gotoAndStop(guh);
  229.     bul2._y = bul2._y + pan;
  230. }
  231. if(mhm._currentframe < 9) {
  232.     if(mhm._x > bul1._x - 40 && mhm._x < bul1._x + 40) {
  233.         if(mhm._y > bul1._y && mhm._y < bul1._y + 120) {
  234.             if(b1 == 1) {
  235.                 bul1._x = 560;
  236.                 velox = velox + 10;
  237.             } else if(b1 == 0) {
  238.                 bul1._x = -10;
  239.                 velox = velox + -10;
  240.             }
  241.         }
  242.     } else if(mhm._x > bul2._x - 40 && mhm._x < bul2._x + 40) {
  243.         if(mhm._y > bul2._y && mhm._y < bul2._y + 120) {
  244.             if(b2 == 1) {
  245.                 bul2._x = 560;
  246.                 velox = velox + 10;
  247.             } else if(b2 == 0) {
  248.                 bul2._x = -10;
  249.                 velox = velox + -10;
  250.             }
  251.         }
  252.     }
  253. } else if(mhm._currentframe == 9) {
  254.     if(mhm._x > bul1._x - 40 && mhm._x < bul1._x + 40) {
  255.         if(mhm._y > bul1._y && mhm._y < bul1._y + 50) {
  256.             if(b1 == 1) {
  257.                 bul1._x = 560;
  258.                 velox = velox + 10;
  259.             } else if(b1 == 0) {
  260.                 bul1._x = -10;
  261.                 velox = velox + -10;
  262.             }
  263.         }
  264.     } else if(mhm._x > bul2._x - 40 && mhm._x < bul2._x + 40) {
  265.         if(mhm._y > bul2._y && mhm._y < bul2._y + 50) {
  266.             if(b2 == 1) {
  267.                 bul2._x = 560;
  268.                 velox = velox + 10;
  269.             } else if(b2 == 0) {
  270.                 bul2._x = -10;
  271.                 velox = velox + -10;
  272.             }
  273.         }
  274.     }
  275. } else if(mhm._currentframe == 11) {
  276.     if(mhm._x > bul1._x - 40 && mhm._x < bul1._x + 40) {
  277.         if(mhm._y > bul1._y - 40 && mhm._y < bul1._y + 40) {
  278.             if(b1 == 1) {
  279.                 bul1._x = 560;
  280.                 velox = velox + 10;
  281.             } else if(b1 == 0) {
  282.                 bul1._x = -10;
  283.                 velox = velox + -10;
  284.             }
  285.         }
  286.     } else if(mhm._x > bul2._x - 40 && mhm._x < bul2._x + 40) {
  287.         if(mhm._y > bul2._y - 40 && mhm._y < bul2._y + 40) {
  288.             if(b2 == 1) {
  289.                 bul2._x = 560;
  290.                 velox = velox + 10;
  291.             } else if(b2 == 0) {
  292.                 bul2._x = -10;
  293.                 velox = velox + -10;
  294.             }
  295.         }
  296.     }
  297. }
  298. if(mhm._y <= 200) {
  299.     pan = poz + (200 - mhm._y) / 10;
  300. }
  301. mhm._y = mhm._y + (veloy + pan);
  302. mhm._x = mhm._x + velox;
  303. if(onob == 1) {
  304.     veloy = 0;
  305. }
  306. pla1._y = pla1._y + pan;
  307. pla2._y = pla2._y + pan;
  308. pla3._y = pla3._y + pan;
  309. pla4._y = pla4._y + pan;
  310. pla6._y = pla6._y + pan;
  311. pla7._y = pla7._y + pan;
  312. pla8._y = pla8._y + pan;
  313. pla5._y = pla5._y + pan;
  314. if(sky.covero._y <= 1000) {
  315.     sky.covero._y = sky.covero._y + pan / 2.05;
  316. }
  317. if(mhm._x > 500) {
  318.     velox = - Math.abs(velox);
  319.     mhm._x = 495;
  320. } else if(mhm._x < 50) {
  321.     velox = Math.abs(velox);
  322.     mhm._x = 55;
  323. } else if(onob == 0 && veloy < 16) {
  324.     veloy = veloy + 3;
  325. }
  326. if(onob == 1 && mhm._x - _root["pla" + plon]._x + velox * 50 <= 0 || onob == 0 && mhm._x - _root["pla" + jt]._x >= 0 && (- velox) * 2 < mhm._x - _root["pla" + jt]._x) {
  327.     velox = velox - 3;
  328.     a2.gotoAndPlay(2);
  329. } else if(onob == 1 && mhm._x - _root["pla" + plon]._x + velox * 50 >= 0 || onob == 0 && mhm._x - _root["pla" + jt]._x <= 0 && velox * 2 < _root["pla" + jt]._x - mhm._x) {
  330.     velox = velox + 3;
  331.     a3.gotoAndPlay(2);
  332. }
  333. if(veloy >= 0 && mhm._y > _root["pla" + jt]._y && onob == 0) {
  334.     jt--;
  335. }
  336. if(jt == 0) {
  337.     jt = 8;
  338. }
  339. if((Math.abs(mhm._x - _root["pla" + plon]._x) > 73 - Math.abs(velox) || Math.abs(velox) >= 18 || Math.abs(velox) >= 10 && mhm._y >= 450) && (onob == 1 || good == 1)) {
  340.     if(sooth == -150) {
  341.         veloy = sooth;
  342.     } else {
  343.         veloy = -26 - Math.abs(velox);
  344.         score = score + Math.round((- veloy) / 3);
  345.     }
  346.     a1.gotoAndPlay(2);
  347.     jh = Math.abs(veloy * veloy / 6 + veloy / 2 + 8);
  348.     jt = plon + Math.floor(jh / 75);
  349.     if(jt >= 9) {
  350.         jt = jt - 8;
  351.     }
  352.     onob = 0;
  353. }
  354. disscore = score;
  355. if(Math.floor(tootoo / 40) + 1 <= 10) {
  356.     var i = 0;
  357.     while(i <= 8) {
  358.         if(_root["pla" + i]._y > 550) {
  359.             _root["pla" + i]._y = _root["pla" + i]._y - 600;
  360.             _root["pla" + i]._x = Math.random() * 350 + 100;
  361.             score = score + poz;
  362.             if(i == 1) {
  363.                 tootoo = tootoo + 8;
  364.             }
  365.             _root["pla" + i].goof.gotoAndStop(Math.floor(tootoo / 40) + 1);
  366.         }
  367.         i++;
  368.     }
  369. }
  370. gotoAndPlay(5);
  371. if(mhm._y > 600) {
  372.     gotoAndStop("die");
  373.     play();
  374. }
  375. if(sky._currentframe != Math.floor(tootoo / 40) + 1) {
  376.     sky.gotoAndStop(Math.floor(tootoo / 40) + 1);
  377.     sky.covero._y = -300;
  378. }
  379. //frame 6
  380. gotoAndPlay(5);
  381. if(tootoo == 400) {
  382.     jt = 1;
  383.     poz = 0.5;
  384.     pan = 0.5;
  385. } else {
  386.     timer++;
  387.     if(poz == 10) {
  388.         poz = 10;
  389.     }
  390.     if(timer > 90 && poz < 10) {
  391.         timer = 0;
  392.         if(poz != 10) {
  393.             poz = poz + 0.5;
  394.         }
  395.     }
  396. }
  397. if(veloy == 0 && (mhm._currentframe == 6 || mhm._currentframe == 7)) {
  398.     mhm.gotoAndStop(1);
  399. }
  400. //frame 8
  401. if(timery < 40) {
  402.     timery++;
  403.     gotoAndStop("die");
  404.     play();
  405. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement