Frame 2
var kdash;
var kjump;
var kattack;
var kup;
var kdown;
var kleft;
var kright;
kdash = 65;
kjump = 83;
kattack = 68;
kup = 38;
kdown = 40;
kleft = 37;
kright = 39;
if (_totalframes > _framesloaded) {
gotoAndPlay (1);
}
Frame 3
var xz;
var pd;
var ps;
var pe;
var px;
var py;
var pl;
var pi;
var charge;
var ptime;
var pwall;
var pw;
var pf;
var sx;
var sy;
var psn;
pst = new Array(3);
psd = new Array(3);
psx = new Array(3);
psy = new Array(3);
psf = new Array(3);
bt = new Array(10);
bd = new Array(10);
bs = new Array(10);
bj = new Array(10);
bx = new Array(10);
by = new Array(10);
bl = new Array(10);
btime = new Array(10);
bf = new Array(10);
var bsn;
bst = new Array(6);
bsd = new Array(6);
bsx = new Array(6);
bsy = new Array(6);
bsf = new Array(6);
blt = new Array(15);
blx = new Array(15);
bly = new Array(15);
blsx = new Array(15);
blsy = new Array(15);
var lives;
var timer;
var cframe;
var pace;
var camx;
var camy;
var h1;
var h2;
var h3;
var h4;
boom1 = new Sound(this);
boom1.attachSound("6_boom1.au");
boom2 = new Sound(this);
boom2.attachSound("6_boom2.au");
boom3 = new Sound(this);
boom3.attachSound("6_boom3.au");
bossdeath = new Sound(this);
bossdeath.attachSound("6_bossdeath.wav");
buster = new Sound(this);
buster.attachSound("6_buster.au");
electric = new Sound(this);
electric.attachSound("6_electricity.wav");
herodeath = new Sound(this);
herodeath.attachSound("6_herodeath.wav");
jump = new Sound(this);
jump.attachSound("6_jump.au");
laser = new Sound(this);
laser.attachSound("6_laser.wav");
melee = new Sound(this);
melee.attachSound("6_melee.au");
metal = new Sound(this);
metal.attachSound("6_metalcrunch.wav");
multibeep = new Sound(this);
multibeep.attachSound("6_multiplebeep.au");
rocket = new Sound(this);
rocket.attachSound("6_rocket.au");
shothit = new Sound(this);
shothit.attachSound("6_shothit.au");
stopAllSounds();
Frame 4
stopAllSounds();
gotoAndPlay (360);
Frame 10
xz = 0;
lives = 3;
pl = 50;
px = 20;
py = -40;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
charge = 0;
cframe = 11;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 1;
blx[1] = 400;
bly[1] = -20;
blsx[1] = 400;
blsy[1] = 20;
blt[2] = 1;
blx[2] = 650;
bly[2] = -190;
blsx[2] = 150;
blsy[2] = 150;
blt[3] = 1;
blx[3] = 200;
bly[3] = -330;
blsx[3] = 200;
blsy[3] = 170;
blt[4] = 1;
blx[4] = 600;
bly[4] = -470;
blsx[4] = 220;
blsy[4] = 30;
Frame 11
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 16) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
if (px > 790) {
gotoAndPlay (15);
}
if (py < -470) {
py = -470;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 12
gotoAndPlay (11);
Frame 20
px = 20;
py = -40;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 21;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 6;
bl[1] = 5;
bx[1] = 230;
by[1] = -170;
bt[2] = 4;
bl[2] = 4;
bx[2] = 390;
by[2] = -100;
bt[3] = 6;
bl[3] = 5;
bx[3] = 530;
by[3] = -330;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 2;
blx[1] = 650;
bly[1] = -390;
blsx[1] = 10;
blsy[1] = 110;
blt[2] = 4;
blx[2] = 290;
bly[2] = -70;
blsx[2] = 90;
blsy[2] = 30;
blt[3] = 1;
blx[3] = 400;
bly[3] = -20;
blsx[3] = 400;
blsy[3] = 20;
blt[4] = 1;
blx[4] = 440;
bly[4] = -70;
blsx[4] = 60;
blsy[4] = 30;
blt[5] = 1;
blx[5] = 650;
bly[5] = -140;
blsx[5] = 150;
blsy[5] = 100;
blt[6] = 1;
blx[6] = 300;
bly[6] = -310;
blsx[6] = 100;
blsy[6] = 110;
blt[7] = 1;
blx[7] = 100;
bly[7] = -320;
blsx[7] = 100;
blsy[7] = 180;
blt[8] = 1;
blx[8] = 750;
bly[8] = -370;
blsx[8] = 50;
blsy[8] = 130;
blt[9] = 1;
blx[9] = 400;
bly[9] = -460;
blsx[9] = 200;
blsy[9] = 40;
Frame 21
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 10) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 2) {
if (((((px + 6) > (blx[h1] - blsx[h1])) and ((px - 6) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (Key.isDown(kdown) and (ptime < 1)) {
px = blx[h1];
py = py + 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) > (bly[h1] + blsy[h1])) {
pd = pd - 8;
pj = 2;
}
}
if (Key.isDown(kup) and (ptime < 1)) {
px = blx[h1];
py = py - 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) < (bly[h1] - blsy[h1])) {
py = py + 4;
ps = 1;
}
}
}
}
if (blt[h1] == 4) {
h3 = (blx[h1] - px) / 3;
if (((((px + 2) > (blx[h1] + blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 4) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 4) {
if (bd[h2] == 0) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 10;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 11;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 12;
}
bx[h2] = bx[h2] + 4;
h3 = random(50);
if ((h3 < 4) and ((px + 30) < bx[h2])) {
bd[h2] = 1;
}
}
if (bd[h2] == 1) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 80;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 81;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 82;
}
bx[h2] = bx[h2] - 4;
h3 = random(50);
if ((h3 < 4) and ((px - 30) > bx[h2])) {
bd[h2] = 0;
}
}
}
if (bt[h2] == 6) {
if (bd[h2] == 0) {
if ((pace > 0) and (pace < 6)) {
bf[h2] = 15;
}
if ((pace > 5) and (pace < 12)) {
bf[h2] = 16;
}
if ((pace > 11) and (pace < 17)) {
bf[h2] = 17;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - 2;
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + 2;
}
if (py < by[h2]) {
by[h2] = by[h2] - 2;
}
if (py > by[h2]) {
by[h2] = by[h2] + 2;
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bl[h2] = 1;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 4) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 10) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
if (blt[h1] == 4) {
h3 = (blx[h1] - bx[h2]) / 3;
if (((((bx[h2] + 2) > (blx[h1] + blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 26) < (bly[h1] + blsy[h1]))) and ((by[h2] + 5) >= (bly[h1] + h3))) {
h4 = 1;
by[h2] = bly[h1] + h3;
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (py < -465) {
gotoAndPlay (25);
}
if (py < -470) {
py = -470;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 22
gotoAndPlay (21);
Frame 30
px = 210;
py = -40;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 31;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 2;
bl[1] = 3;
bx[1] = 370;
by[1] = -40;
bt[2] = 6;
bl[2] = 5;
bx[2] = 470;
by[2] = -390;
bt[3] = 6;
bl[3] = 5;
bx[3] = 610;
by[3] = -390;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 2;
blx[1] = 150;
bly[1] = -70;
blsx[1] = 10;
blsy[1] = 90;
blt[2] = 1;
blx[2] = 500;
bly[2] = -20;
blsx[2] = 300;
blsy[2] = 20;
blt[3] = 1;
blx[3] = 570;
bly[3] = -180;
blsx[3] = 70;
blsy[3] = 140;
blt[4] = 1;
blx[4] = 50;
bly[4] = -250;
blsx[4] = 50;
blsy[4] = 250;
blt[5] = 1;
blx[5] = 250;
bly[5] = -320;
blsx[5] = 150;
blsy[5] = 180;
blt[6] = 1;
blx[6] = 750;
bly[6] = -320;
blsx[6] = 50;
blsy[6] = 180;
blt[7] = 1;
blx[7] = 550;
bly[7] = -460;
blsx[7] = 150;
blsy[7] = 40;
Frame 31
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 8) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 2) {
if (((((px + 6) > (blx[h1] - blsx[h1])) and ((px - 6) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (Key.isDown(kdown) and (ptime < 1)) {
px = blx[h1];
py = py + 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) > (bly[h1] + blsy[h1])) {
pd = pd - 8;
pj = 2;
}
}
if (Key.isDown(kup) and (ptime < 1)) {
px = blx[h1];
py = py - 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) < (bly[h1] - blsy[h1])) {
py = py + 4;
ps = 1;
}
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 4) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 2) {
if (bd[h2] == 0) {
if ((pace > 0) and (pace < 5)) {
bf[h2] = 4;
}
if ((pace > 4) and (pace < 9)) {
bf[h2] = 5;
}
if ((pace > 8) and (pace < 13)) {
bf[h2] = 6;
}
if ((pace > 12) and (pace < 17)) {
bf[h2] = 7;
}
bx[h2] = bx[h2] + 2;
h3 = random(50);
if ((h3 < 4) and (px < bx[h2])) {
bd[h2] = 1;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bst[bsn] = 2;
bsd[bsn] = 0;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 10;
bsy[bsn] = by[h2] - 12;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 1) {
if ((pace > 0) and (pace < 5)) {
bf[h2] = 74;
}
if ((pace > 4) and (pace < 9)) {
bf[h2] = 75;
}
if ((pace > 8) and (pace < 13)) {
bf[h2] = 76;
}
if ((pace > 12) and (pace < 17)) {
bf[h2] = 77;
}
bx[h2] = bx[h2] - 2;
h3 = random(50);
if ((h3 < 4) and (px > bx[h2])) {
bd[h2] = 0;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bst[bsn] = 2;
bsd[bsn] = 1;
bsf[bsn] = 4;
bsx[bsn] = bx[h2] - 10;
bsy[bsn] = by[h2] - 12;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 6) {
if (bd[h2] == 0) {
if ((pace > 0) and (pace < 6)) {
bf[h2] = 15;
}
if ((pace > 5) and (pace < 12)) {
bf[h2] = 16;
}
if ((pace > 11) and (pace < 17)) {
bf[h2] = 17;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - 2;
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + 2;
}
if (py < by[h2]) {
by[h2] = by[h2] - 2;
}
if (py > by[h2]) {
by[h2] = by[h2] + 2;
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 4) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 8) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (px > 790) {
gotoAndPlay (35);
}
if (py < -480) {
py = -480;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -410) {
camy = -410;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 32
gotoAndPlay (31);
Frame 40
px = 20;
py = -40;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 41;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
bt[1] = 6;
bl[1] = 5;
bx[1] = 230;
by[1] = -130;
bt[2] = 6;
bl[2] = 5;
bx[2] = 370;
by[2] = -190;
bt[3] = 7;
bl[3] = 3;
bx[3] = 730;
by[3] = -40;
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 1;
blx[1] = 100;
bly[1] = -20;
blsx[1] = 100;
blsy[1] = 20;
blt[2] = 1;
blx[2] = 670;
bly[2] = -20;
blsx[2] = 130;
blsy[2] = 20;
blt[3] = 1;
blx[3] = 440;
bly[3] = -70;
blsx[3] = 40;
blsy[3] = 70;
blt[4] = 1;
blx[4] = 300;
bly[4] = -100;
blsx[4] = 20;
blsy[4] = 20;
blt[5] = 1;
blx[5] = 610;
bly[5] = -180;
blsx[5] = 50;
blsy[5] = 60;
blt[6] = 1;
blx[6] = 50;
bly[6] = -190;
blsx[6] = 50;
blsy[6] = 50;
blt[7] = 1;
blx[7] = 400;
bly[7] = -370;
blsx[7] = 400;
blsy[7] = 130;
Frame 41
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 8) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 4) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 6) {
if (bd[h2] == 0) {
if ((pace > 0) and (pace < 6)) {
bf[h2] = 15;
}
if ((pace > 5) and (pace < 12)) {
bf[h2] = 16;
}
if ((pace > 11) and (pace < 17)) {
bf[h2] = 17;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - 2;
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + 2;
}
if (py < by[h2]) {
by[h2] = by[h2] - 2;
}
if (py > by[h2]) {
by[h2] = by[h2] + 2;
}
}
}
if (bt[h2] == 7) {
if (bd[h2] == 0) {
bf[h2] = 18;
if (px < bx[h2]) {
bd[h2] = 1;
}
if (btime[h2] < 1) {
bd[h2] = 2;
btime[h2] = 9;
}
}
if (bd[h2] == 1) {
bf[h2] = 88;
if (px > bx[h2]) {
bd[h2] = 0;
}
if (btime[h2] < 1) {
bd[h2] = 3;
btime[h2] = 9;
}
}
if (bd[h2] == 2) {
bf[h2] = 19;
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bd[h2] = 0;
bst[bsn] = 2;
bsd[bsn] = 0;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 10;
bsy[bsn] = by[h2] - 14;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 3) {
bf[h2] = 89;
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bd[h2] = 1;
bst[bsn] = 2;
bsd[bsn] = 1;
bsf[bsn] = 4;
bsx[bsn] = bx[h2] - 10;
bsy[bsn] = by[h2] - 14;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bl[h2] = 1;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 4) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 8) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (px > 790) {
gotoAndPlay (45);
}
if (py < -480) {
py = -480;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -410) {
camy = -410;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 42
gotoAndPlay (41);
Frame 50
px = 20;
py = -300;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 51;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 4;
bl[1] = 4;
bx[1] = 130;
by[1] = -300;
bt[2] = 3;
bl[2] = 3;
bx[2] = 230;
by[2] = -370;
bt[3] = 4;
bl[3] = 4;
bx[3] = 270;
by[3] = -280;
bt[4] = 3;
bl[4] = 3;
bx[4] = 470;
by[4] = -280;
bt[5] = 2;
bl[5] = 3;
bx[5] = 550;
by[5] = -220;
bt[6] = 3;
bl[6] = 5;
bx[6] = 710;
by[6] = -280;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 2;
blx[1] = 670;
bly[1] = -130;
blsx[1] = 10;
blsy[1] = 130;
blt[2] = 5;
blx[2] = 320;
bly[2] = -260;
blsx[2] = 120;
blsy[2] = 40;
blt[3] = 1;
blx[3] = 100;
bly[3] = -150;
blsx[3] = 100;
blsy[3] = 150;
blt[4] = 1;
blx[4] = 320;
bly[4] = -110;
blsx[4] = 120;
blsy[4] = 110;
blt[5] = 1;
blx[5] = 540;
bly[5] = -110;
blsx[5] = 100;
blsy[5] = 110;
Frame 51
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 6) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 2) {
if (((((px + 6) > (blx[h1] - blsx[h1])) and ((px - 6) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (Key.isDown(kdown) and (ptime < 1)) {
px = blx[h1];
py = py + 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) > (bly[h1] + blsy[h1])) {
pd = pd - 8;
pj = 2;
}
}
if (Key.isDown(kup) and (ptime < 1)) {
px = blx[h1];
py = py - 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) < (bly[h1] - blsy[h1])) {
py = py + 4;
ps = 1;
}
}
}
}
if (blt[h1] == 5) {
h3 = (px - blx[h1]) / 3;
if (((((px - 2) < (blx[h1] - blsx[h1])) and ((px + 10) > (blx[h1] - blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 7) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 2) {
if (bd[h2] == 0) {
if ((pace > 0) and (pace < 5)) {
bf[h2] = 4;
}
if ((pace > 4) and (pace < 9)) {
bf[h2] = 5;
}
if ((pace > 8) and (pace < 13)) {
bf[h2] = 6;
}
if ((pace > 12) and (pace < 17)) {
bf[h2] = 7;
}
bx[h2] = bx[h2] + 2;
h3 = random(50);
if ((h3 < 4) and (px < bx[h2])) {
bd[h2] = 1;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bst[bsn] = 2;
bsd[bsn] = 0;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 10;
bsy[bsn] = by[h2] - 12;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 1) {
if ((pace > 0) and (pace < 5)) {
bf[h2] = 74;
}
if ((pace > 4) and (pace < 9)) {
bf[h2] = 75;
}
if ((pace > 8) and (pace < 13)) {
bf[h2] = 76;
}
if ((pace > 12) and (pace < 17)) {
bf[h2] = 77;
}
bx[h2] = bx[h2] - 2;
h3 = random(50);
if ((h3 < 4) and (px > bx[h2])) {
bd[h2] = 0;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bst[bsn] = 2;
bsd[bsn] = 1;
bsf[bsn] = 4;
bsx[bsn] = bx[h2] - 10;
bsy[bsn] = by[h2] - 12;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 3) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 8;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 9;
}
bx[h2] = bx[h2] + 1;
if ((px - 40) < bx[h2]) {
bx[h2] = bx[h2] - 3;
}
if (px < bx[h2]) {
bd[h2] = 1;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 5;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 1) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 78;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 79;
}
bx[h2] = bx[h2] - 1;
if ((px + 40) > bx[h2]) {
bx[h2] = bx[h2] + 3;
}
if (px > bx[h2]) {
bd[h2] = 0;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 7;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] - 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 4) {
if (bd[h2] == 0) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 10;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 11;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 12;
}
bx[h2] = bx[h2] + 4;
h3 = random(50);
if ((h3 < 4) and ((px + 30) < bx[h2])) {
bd[h2] = 1;
}
}
if (bd[h2] == 1) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 80;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 81;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 82;
}
bx[h2] = bx[h2] - 4;
h3 = random(50);
if ((h3 < 4) and ((px - 30) > bx[h2])) {
bd[h2] = 0;
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 7) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 6) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
if (blt[h1] == 5) {
h3 = (bx[h2] - blx[h1]) / 3;
if (((((bx[h2] - 2) < (blx[h1] - blsx[h1])) and ((bx[h2] + 10) > (blx[h1] - blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 26) < (bly[h1] + blsy[h1]))) and ((by[h2] + 5) >= (bly[h1] + h3))) {
h4 = 1;
by[h2] = bly[h1] + h3;
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (py > -10) {
gotoAndPlay (55);
}
if (py < -480) {
py = -480;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -410) {
camy = -410;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 52
gotoAndPlay (51);
Frame 60
px = 70;
py = -480;
pd = 14;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 61;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 7;
bl[1] = 3;
bx[1] = 190;
by[1] = -220;
bt[2] = 3;
bl[2] = 3;
bx[2] = 430;
by[2] = -280;
bt[3] = 4;
bl[3] = 3;
bx[3] = 470;
by[3] = -40;
bt[4] = 3;
bl[4] = 3;
bx[4] = 510;
by[4] = -100;
bt[5] = 3;
bl[5] = 3;
bx[5] = 650;
by[5] = -100;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 2;
blx[1] = 70;
bly[1] = -400;
blsx[1] = 10;
blsy[1] = 100;
blt[2] = 1;
blx[2] = 580;
bly[2] = -20;
blsx[2] = 220;
blsy[2] = 20;
blt[3] = 1;
blx[3] = 200;
bly[3] = -110;
blsx[3] = 160;
blsy[3] = 110;
blt[4] = 1;
blx[4] = 480;
bly[4] = -240;
blsx[4] = 40;
blsy[4] = 60;
blt[5] = 1;
blx[5] = 20;
bly[5] = -250;
blsx[5] = 20;
blsy[5] = 250;
blt[6] = 1;
blx[6] = 500;
bly[6] = -400;
blsx[6] = 300;
blsy[6] = 100;
Frame 61
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 7) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 2) {
if (((((px + 6) > (blx[h1] - blsx[h1])) and ((px - 6) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (Key.isDown(kdown) and (ptime < 1)) {
px = blx[h1];
py = py + 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) > (bly[h1] + blsy[h1])) {
pd = pd - 8;
pj = 2;
}
}
if (Key.isDown(kup) and (ptime < 1)) {
px = blx[h1];
py = py - 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) < (bly[h1] - blsy[h1])) {
py = py + 4;
ps = 1;
}
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 6) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 3) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 8;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 9;
}
bx[h2] = bx[h2] + 1;
if ((px - 40) < bx[h2]) {
bx[h2] = bx[h2] - 3;
}
if (px < bx[h2]) {
bd[h2] = 1;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 5;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 1) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 78;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 79;
}
bx[h2] = bx[h2] - 1;
if ((px + 40) > bx[h2]) {
bx[h2] = bx[h2] + 3;
}
if (px > bx[h2]) {
bd[h2] = 0;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 7;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] - 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 4) {
if (bd[h2] == 0) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 10;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 11;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 12;
}
bx[h2] = bx[h2] + 4;
h3 = random(50);
if ((h3 < 4) and ((px + 30) < bx[h2])) {
bd[h2] = 1;
}
}
if (bd[h2] == 1) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 80;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 81;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 82;
}
bx[h2] = bx[h2] - 4;
h3 = random(50);
if ((h3 < 4) and ((px - 30) > bx[h2])) {
bd[h2] = 0;
}
}
}
if (bt[h2] == 7) {
if (bd[h2] == 0) {
bf[h2] = 18;
if (px < bx[h2]) {
bd[h2] = 1;
}
if (btime[h2] < 1) {
bd[h2] = 2;
btime[h2] = 9;
}
}
if (bd[h2] == 1) {
bf[h2] = 88;
if (px > bx[h2]) {
bd[h2] = 0;
}
if (btime[h2] < 1) {
bd[h2] = 3;
btime[h2] = 9;
}
}
if (bd[h2] == 2) {
bf[h2] = 19;
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bd[h2] = 0;
bst[bsn] = 2;
bsd[bsn] = 0;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 10;
bsy[bsn] = by[h2] - 14;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 3) {
bf[h2] = 89;
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bd[h2] = 1;
bst[bsn] = 2;
bsd[bsn] = 1;
bsf[bsn] = 4;
bsx[bsn] = bx[h2] - 10;
bsy[bsn] = by[h2] - 14;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 6) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 7) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (px > 790) {
gotoAndPlay (65);
}
if (py < -470) {
py = -470;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 62
gotoAndPlay (61);
Frame 70
px = 20;
py = -40;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 71;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 10;
blx[1] = 540;
bly[1] = -360;
blsx[1] = 20;
blsy[1] = 20;
blt[2] = 1;
blx[2] = 100;
bly[2] = -20;
blsx[2] = 100;
blsy[2] = 20;
blt[3] = 1;
blx[3] = 260;
bly[3] = -100;
blsx[3] = 20;
blsy[3] = 20;
blt[4] = 1;
blx[4] = 180;
bly[4] = -180;
blsx[4] = 20;
blsy[4] = 20;
blt[5] = 1;
blx[5] = 260;
bly[5] = -200;
blsx[5] = 20;
blsy[5] = 20;
blt[6] = 1;
blx[6] = 360;
bly[6] = -240;
blsx[6] = 20;
blsy[6] = 20;
blt[7] = 1;
blx[7] = 460;
bly[7] = -330;
blsx[7] = 20;
blsy[7] = 30;
blt[8] = 1;
blx[8] = 590;
bly[8] = -360;
blsx[8] = 20;
blsy[8] = 20;
blt[9] = 1;
blx[9] = 740;
bly[9] = -360;
blsx[9] = 60;
blsy[9] = 40;
Frame 71
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 10) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 30) {
if (bly[h1] < 200) {
bly[h1] = bly[h1] + 15;
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if ((blt[h1] > 10) and (blt[h1] < 30)) {
blt[h1] = blt[h1] + 1;
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 10) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
blt[h1] = 11;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
if (px > 790) {
gotoAndPlay (75);
}
if (py < -480) {
py = -480;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
block1._x = 100 + (blx[1] - camx);
block1._y = 100 + (bly[1] - camy);
Frame 72
gotoAndPlay (71);
Frame 80
px = 15;
py = -40;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 81;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 4;
bl[1] = 3;
bx[1] = 210;
by[1] = -80;
bt[2] = 6;
bl[2] = 5;
bx[2] = 290;
by[2] = -170;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 2;
blx[1] = 530;
bly[1] = -400;
blsx[1] = 10;
blsy[1] = 140;
blt[2] = 2;
blx[2] = 570;
bly[2] = -250;
blsx[2] = 10;
blsy[2] = 90;
blt[3] = 2;
blx[3] = 530;
bly[3] = -140;
blsx[3] = 10;
blsy[3] = 100;
blt[4] = 4;
blx[4] = 140;
bly[4] = -60;
blsx[4] = 60;
blsy[4] = 20;
blt[5] = 5;
blx[5] = 420;
bly[5] = -60;
blsx[5] = 60;
blsy[5] = 20;
blt[6] = 1;
blx[6] = 100;
bly[6] = -20;
blsx[6] = 100;
blsy[6] = 20;
blt[7] = 1;
blx[7] = 420;
bly[7] = -20;
blsx[7] = 60;
blsy[7] = 20;
blt[8] = 1;
blx[8] = 280;
bly[8] = -40;
blsx[8] = 80;
blsy[8] = 40;
Frame 81
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 9) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 2) {
if (((((px + 6) > (blx[h1] - blsx[h1])) and ((px - 6) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (Key.isDown(kdown) and (ptime < 1)) {
px = blx[h1];
py = py + 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) > (bly[h1] + blsy[h1])) {
pd = pd - 8;
pj = 2;
}
}
if (Key.isDown(kup) and (ptime < 1)) {
px = blx[h1];
py = py - 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) < (bly[h1] - blsy[h1])) {
py = py + 4;
ps = 1;
}
}
}
}
if (blt[h1] == 4) {
h3 = (blx[h1] - px) / 3;
if (((((px + 2) > (blx[h1] + blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 5) {
h3 = (px - blx[h1]) / 3;
if (((((px - 2) < (blx[h1] - blsx[h1])) and ((px + 10) > (blx[h1] - blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 3) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 4) {
if (bd[h2] == 0) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 10;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 11;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 12;
}
bx[h2] = bx[h2] + 4;
h3 = random(50);
if ((h3 < 4) and ((px + 30) < bx[h2])) {
bd[h2] = 1;
}
}
if (bd[h2] == 1) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 80;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 81;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 82;
}
bx[h2] = bx[h2] - 4;
h3 = random(50);
if ((h3 < 4) and ((px - 30) > bx[h2])) {
bd[h2] = 0;
}
}
}
if (bt[h2] == 6) {
if (bd[h2] == 0) {
if ((pace > 0) and (pace < 6)) {
bf[h2] = 15;
}
if ((pace > 5) and (pace < 12)) {
bf[h2] = 16;
}
if ((pace > 11) and (pace < 17)) {
bf[h2] = 17;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - 2;
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + 2;
}
if (py < by[h2]) {
by[h2] = by[h2] - 2;
}
if (py > by[h2]) {
by[h2] = by[h2] + 2;
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bl[h2] = 1;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 3) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 9) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
if (blt[h1] == 4) {
h3 = (blx[h1] - bx[h2]) / 3;
if (((((bx[h2] + 2) > (blx[h1] + blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 26) < (bly[h1] + blsy[h1]))) and ((by[h2] + 5) >= (bly[h1] + h3))) {
h4 = 1;
by[h2] = bly[h1] + h3;
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
}
if (blt[h1] == 5) {
h3 = (bx[h2] - blx[h1]) / 3;
if (((((bx[h2] - 2) < (blx[h1] - blsx[h1])) and ((bx[h2] + 10) > (blx[h1] - blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 26) < (bly[h1] + blsy[h1]))) and ((by[h2] + 5) >= (bly[h1] + h3))) {
h4 = 1;
by[h2] = bly[h1] + h3;
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (py < -475) {
gotoAndPlay (85);
}
if (py < -480) {
py = -480;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 82
gotoAndPlay (81);
Frame 90
px = 50;
py = -30;
pd = 14;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 91;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 2;
bl[1] = 4;
bx[1] = 250;
by[1] = -40;
bt[2] = 3;
bl[2] = 3;
bx[2] = 330;
by[2] = -100;
bt[3] = 4;
bl[3] = 3;
bx[3] = 370;
by[3] = -40;
bt[4] = 2;
bl[4] = 4;
bx[4] = 550;
by[4] = -40;
bt[5] = 4;
bl[5] = 3;
bx[5] = 570;
by[5] = -40;
bt[6] = 3;
bl[6] = 3;
bx[6] = 570;
by[6] = -100;
bt[7] = 3;
bl[7] = 3;
bx[7] = 610;
by[7] = -80;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 2;
blx[1] = 50;
bly[1] = -50;
blsx[1] = 10;
blsy[1] = 50;
blt[2] = 1;
blx[2] = 450;
bly[2] = -20;
blsx[2] = 350;
blsy[2] = 20;
blt[3] = 1;
blx[3] = 400;
bly[3] = -320;
blsx[3] = 400;
blsy[3] = 180;
Frame 91
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 4) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 2) {
if (((((px + 6) > (blx[h1] - blsx[h1])) and ((px - 6) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (Key.isDown(kdown) and (ptime < 1)) {
px = blx[h1];
py = py + 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) > (bly[h1] + blsy[h1])) {
pd = pd - 8;
pj = 2;
}
}
if (Key.isDown(kup) and (ptime < 1)) {
px = blx[h1];
py = py - 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) < (bly[h1] - blsy[h1])) {
py = py + 4;
ps = 1;
}
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 8) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 2) {
if (bd[h2] == 0) {
if ((pace > 0) and (pace < 5)) {
bf[h2] = 4;
}
if ((pace > 4) and (pace < 9)) {
bf[h2] = 5;
}
if ((pace > 8) and (pace < 13)) {
bf[h2] = 6;
}
if ((pace > 12) and (pace < 17)) {
bf[h2] = 7;
}
bx[h2] = bx[h2] + 2;
h3 = random(50);
if ((h3 < 4) and (px < bx[h2])) {
bd[h2] = 1;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bst[bsn] = 2;
bsd[bsn] = 0;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 10;
bsy[bsn] = by[h2] - 12;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 1) {
if ((pace > 0) and (pace < 5)) {
bf[h2] = 74;
}
if ((pace > 4) and (pace < 9)) {
bf[h2] = 75;
}
if ((pace > 8) and (pace < 13)) {
bf[h2] = 76;
}
if ((pace > 12) and (pace < 17)) {
bf[h2] = 77;
}
bx[h2] = bx[h2] - 2;
h3 = random(50);
if ((h3 < 4) and (px > bx[h2])) {
bd[h2] = 0;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bst[bsn] = 2;
bsd[bsn] = 1;
bsf[bsn] = 4;
bsx[bsn] = bx[h2] - 10;
bsy[bsn] = by[h2] - 12;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 3) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 8;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 9;
}
bx[h2] = bx[h2] + 1;
if ((px - 40) < bx[h2]) {
bx[h2] = bx[h2] - 3;
}
if (px < bx[h2]) {
bd[h2] = 1;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 5;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 1) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 78;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 79;
}
bx[h2] = bx[h2] - 1;
if ((px + 40) > bx[h2]) {
bx[h2] = bx[h2] + 3;
}
if (px > bx[h2]) {
bd[h2] = 0;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 7;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] - 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 4) {
if (bd[h2] == 0) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 10;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 11;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 12;
}
bx[h2] = bx[h2] + 4;
h3 = random(50);
if ((h3 < 4) and ((px + 30) < bx[h2])) {
bd[h2] = 1;
}
}
if (bd[h2] == 1) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 80;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 81;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 82;
}
bx[h2] = bx[h2] - 4;
h3 = random(50);
if ((h3 < 4) and ((px - 30) > bx[h2])) {
bd[h2] = 0;
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 8) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 4) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (px > 790) {
gotoAndPlay (95);
}
if (py < -480) {
py = -480;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -80) {
camy = -80;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 92
gotoAndPlay (91);
Frame 100
px = 20;
py = -200;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 101;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 4;
bl[1] = 3;
bx[1] = 120;
by[1] = -220;
bt[2] = 5;
bl[2] = 3;
bx[2] = 210;
by[2] = -320;
bt[3] = 4;
bl[3] = 3;
bx[3] = 240;
by[3] = -260;
bt[4] = 1;
bl[4] = 3;
bx[4] = 370;
by[4] = -280;
bt[5] = 1;
bl[5] = 3;
bx[5] = 520;
by[5] = -240;
bt[6] = 5;
bl[6] = 3;
bx[6] = 590;
by[6] = -340;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 4;
blx[1] = 180;
bly[1] = -240;
blsx[1] = 120;
blsy[1] = 40;
blt[2] = 5;
blx[2] = 440;
bly[2] = -260;
blsx[2] = 60;
blsy[2] = 20;
blt[3] = 4;
blx[3] = 630;
bly[3] = -270;
blsx[3] = 90;
blsy[3] = 30;
blt[4] = 1;
blx[4] = 400;
bly[4] = -100;
blsx[4] = 400;
blsy[4] = 100;
blt[5] = 1;
blx[5] = 590;
bly[5] = -220;
blsx[5] = 210;
blsy[5] = 20;
blt[6] = 1;
blx[6] = 340;
bly[6] = -240;
blsx[6] = 40;
blsy[6] = 40;
blt[7] = 1;
blx[7] = 760;
bly[7] = -270;
blsx[7] = 40;
blsy[7] = 30;
blt[8] = 1;
blx[8] = 400;
bly[8] = -440;
blsx[8] = 400;
blsy[8] = 60;
Frame 101
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 16) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 2) {
if (((((px + 6) > (blx[h1] - blsx[h1])) and ((px - 6) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (Key.isDown(40) and (ptime < 1)) {
px = blx[h1];
py = py + 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) > (bly[h1] + blsy[h1])) {
pd = pd - 8;
pj = 2;
}
}
if (Key.isDown(38) and (ptime < 1)) {
px = blx[h1];
py = py - 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) < (bly[h1] - blsy[h1])) {
py = py + 4;
ps = 1;
}
}
}
}
if (blt[h1] == 3) {
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
pl = pl - 2;
}
}
if (blt[h1] == 4) {
h3 = (blx[h1] - px) / 3;
if (((((px + 2) > (blx[h1] + blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 5) {
h3 = (px - blx[h1]) / 3;
if (((((px - 2) < (blx[h1] - blsx[h1])) and ((px + 10) > (blx[h1] - blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 6) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((timer > 0) and (timer < 61)) {
px = px + 2;
}
if ((timer > 60) and (timer < 121)) {
px = px - 2;
}
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
if ((timer > 0) and (timer < 61)) {
blx[h1] = blx[h1] + 2;
}
if ((timer > 60) and (timer < 121)) {
blx[h1] = blx[h1] - 2;
}
}
if (blt[h1] == 7) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((timer > 0) and (timer < 61)) {
px = px - 2;
}
if ((timer > 60) and (timer < 121)) {
px = px + 2;
}
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
if ((timer > 0) and (timer < 61)) {
blx[h1] = blx[h1] - 2;
}
if ((timer > 60) and (timer < 121)) {
blx[h1] = blx[h1] + 2;
}
}
if (blt[h1] == 30) {
if (bly[h1] < 200) {
bly[h1] = bly[h1] + 15;
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if ((blt[h1] > 10) and (blt[h1] < 30)) {
blt[h1] = blt[h1] + 1;
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 10) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
blt[h1] = 11;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 7) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 1) {
if (bd[h2] == 0) {
bf[h2] = 2;
if (btime[h2] < 1) {
jump.start();
bd[h2] = 1;
btime[h2] = 20 + random(20);
bj[h2] = -10;
bs[h2] = (px - bx[h2]) / 20;
}
}
if (bd[h2] == 1) {
bf[h2] = 3;
by[h2] = by[h2] + bj[h2];
bx[h2] = bx[h2] + bs[h2];
if (bj[h2] < 0) {
bj[h2] = bj[h2] + 1;
}
}
}
if (bt[h2] == 4) {
if (bd[h2] == 0) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 10;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 11;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 12;
}
bx[h2] = bx[h2] + 4;
h3 = random(50);
if ((h3 < 4) and ((px + 30) < bx[h2])) {
bd[h2] = 1;
}
}
if (bd[h2] == 1) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 80;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 81;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 82;
}
bx[h2] = bx[h2] - 4;
h3 = random(50);
if ((h3 < 4) and ((px - 30) > bx[h2])) {
bd[h2] = 0;
}
}
}
if (bt[h2] == 5) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 13;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 14;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - random(4);
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + random(4);
}
by[h2] = by[h2] + random(3);
if ((py - 35) < by[h2]) {
by[h2] = (by[h2] - 1) - random(3);
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(20);
bst[bsn] = 3;
bsd[bsn] = 3;
bsf[bsn] = 5;
bsx[bsn] = bx[h2];
bsy[bsn] = by[h2] - 10;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 7) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 9) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
if (blt[h1] == 4) {
h3 = (blx[h1] - bx[h2]) / 3;
if (((((bx[h2] + 2) > (blx[h1] + blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 26) < (bly[h1] + blsy[h1]))) and ((by[h2] + 5) >= (bly[h1] + h3))) {
h4 = 1;
by[h2] = bly[h1] + h3;
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
}
if (blt[h1] == 5) {
h3 = (bx[h2] - blx[h1]) / 3;
if (((((bx[h2] - 2) < (blx[h1] - blsx[h1])) and ((bx[h2] + 10) > (blx[h1] - blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 26) < (bly[h1] + blsy[h1]))) and ((by[h2] + 5) >= (bly[h1] + h3))) {
h4 = 1;
by[h2] = bly[h1] + h3;
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (px > 790) {
gotoAndPlay (410);
}
if (py < -480) {
py = -480;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -410) {
camy = -410;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 102
gotoAndPlay (101);
Frame 110
px = 50;
py = -40;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 111;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 25;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 90;
bs[1] = 0;
bl[1] = 150;
bx[1] = 150;
by[1] = -40;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 1;
blx[1] = 175;
bly[1] = -20;
blsx[1] = 175;
blsy[1] = 20;
blt[2] = 1;
blx[2] = 10;
bly[2] = -105;
blsx[2] = 20;
blsy[2] = 65;
blt[3] = 1;
blx[3] = 280;
bly[3] = -105;
blsx[3] = 20;
blsy[3] = 65;
Frame 111
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 4) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 2) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 300)) and (bx[h2] < (camx + 300))) and (by[h2] > (camy - 250))) and (by[h2] < (camy + 120))) {
if (bt[h2] == 90) {
if (bd[h2] == 0) {
bf[h2] = 2;
if (px < bx[h2]) {
bd[h2] = 1;
}
if (btime[h2] < 1) {
h3 = random(10);
if (h3 < 4) {
bd[h2] = 10;
bs[h2] = 0;
btime[h2] = 16 + random(10);
}
if ((h3 > 3) and (h3 < 8)) {
bd[h2] = 2;
btime[h2] = 8 + random(24);
}
if (h3 > 7) {
bd[h2] = 4;
bd[3] = (px - bx[h2]) / 20;
bj[h2] = -7 - random(5);
btime[h2] = 12 + random(24);
}
}
}
if (bd[h2] == 1) {
bf[h2] = 72;
if (px >= bx[h2]) {
bd[h2] = 0;
}
if (btime[h2] < 1) {
h3 = random(10);
if (h3 < 4) {
bd[h2] = 11;
bs[h2] = 0;
btime[h2] = 16 + random(10);
}
if ((h3 < 3) and (h3 < 8)) {
bd[h2] = 3;
btime[h2] = 8 + random(24);
}
if (h3 > 7) {
bd[h2] = 5;
bd[3] = (px - bx[h2]) / 20;
bj[h2] = -7 - random(5);
btime[h2] = 12 + random(24);
}
}
}
if (bd[h2] == 4) {
if (bj[h2] <= 0) {
bf[h2] = 11;
}
if (bj[h2] > 0) {
bf[h2] = 12;
}
bx[h2] = bx[h2] + bd[3];
by[h2] = by[h2] + bj[h2];
if (bj[h2] < 8) {
bj[h2] = bj[h2] + 1;
}
}
if (bd[h2] == 5) {
if (bj[h2] <= 0) {
bf[h2] = 81;
}
if (bj[h2] > 0) {
bf[h2] = 82;
}
bx[h2] = bx[h2] + bd[3];
by[h2] = by[h2] + bj[h2];
if (bj[h2] < 8) {
bj[h2] = bj[h2] + 1;
}
}
if (bd[h2] == 2) {
if ((pace > 0) and (pace < 3)) {
bf[h2] = 3;
}
if ((pace > 2) and (pace < 5)) {
bf[h2] = 4;
}
if ((pace > 4) and (pace < 7)) {
bf[h2] = 5;
}
if ((pace > 6) and (pace < 9)) {
bf[h2] = 6;
}
if ((pace > 8) and (pace < 11)) {
bf[h2] = 7;
}
if ((pace > 10) and (pace < 13)) {
bf[h2] = 8;
}
if ((pace > 12) and (pace < 15)) {
bf[h2] = 9;
}
if ((pace > 14) and (pace < 17)) {
bf[h2] = 10;
}
bx[h2] = bx[h2] + 3;
if (btime[h2] < 1) {
bd[h2] = 0;
btime[h2] = 10 * random(2);
}
}
if (bd[h2] == 3) {
if ((pace > 0) and (pace < 3)) {
bf[h2] = 73;
}
if ((pace > 2) and (pace < 5)) {
bf[h2] = 74;
}
if ((pace > 4) and (pace < 7)) {
bf[h2] = 75;
}
if ((pace > 6) and (pace < 9)) {
bf[h2] = 76;
}
if ((pace > 8) and (pace < 11)) {
bf[h2] = 77;
}
if ((pace > 10) and (pace < 13)) {
bf[h2] = 78;
}
if ((pace > 12) and (pace < 15)) {
bf[h2] = 79;
}
if ((pace > 14) and (pace < 17)) {
bf[h2] = 80;
}
bx[h2] = bx[h2] - 3;
if (btime[h2] < 1) {
bd[h2] = 1;
btime[h2] = 10 * random(2);
}
}
if (bd[h2] == 10) {
bf[h2] = 13;
if ((((btime[h2] == 6) or (btime[h2] == 12)) or (btime[h2] == 18)) or (btime[h2] == 24)) {
if (bst[bsn] == 0) {
boom2.start();
bst[bsn] = 2;
bsd[bsn] = 2;
bsf[bsn] = 6;
bsx[bsn] = bx[h2] - 12;
bsy[bsn] = by[h2] - 15;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
if (btime[h2] < 1) {
bd[h2] = 0;
btime[h2] = 9;
}
}
}
if (bd[h2] == 11) {
bf[h2] = 83;
if ((((btime[h2] == 6) or (btime[h2] == 12)) or (btime[h2] == 18)) or (btime[h2] == 24)) {
if (bst[bsn] == 0) {
boom2.start();
bst[bsn] = 2;
bsd[bsn] = 3;
bsf[bsn] = 6;
bsx[bsn] = bx[h2] + 12;
bsy[bsn] = by[h2] - 15;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (((bd[h2] > 0) and (bd[h2] < 10)) and (bs[h2] > 0)) {
bf[h2] = bf[h2] + 13;
}
h3 = random(100);
if (((((bd[h2] > 0) and (bd[h2] < 10)) and (bst[bsn] == 0)) and (bs[h2] == 0)) and (h3 < 3)) {
laser.start();
bs[h2] = 4;
bst[bsn] = 1;
bsy[bsn] = by[h2] - 15;
if (((bd[h2] == 0) or (bd[h2] == 2)) or (bd[h2] == 4)) {
bsd[bsn] = 0;
bsf[bsn] = 2;
bsx[bsn] = bx[h2] + 12;
}
if (((bd[h2] == 1) or (bd[h2] == 3)) or (bd[h2] == 5)) {
bsd[bsn] = 1;
bsf[bsn] = 2;
bsx[bsn] = bx[h2] - 12;
}
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
if (bs[h2] > 0) {
bs[h2] = bs[h2] - 1;
}
if (btime[h2] < 1) {
bd[h2] = 1;
btime[h2] = 9;
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 5) < (bx[h2] + 12)) and ((psx[h1] + 5) > (bx[h2] - 12))) and ((psy[h1] - 5) < (by[h2] - 2))) and ((psy[h1] + 5) > (by[h2] - 24))) {
bl[h2] = bl[h2] - 4;
shothit.start();
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 13) < (bx[h2] + 12)) and ((psx[h1] + 13) > (bx[h2] - 12))) and ((psy[h1] - 13) < (by[h2] - 2))) and ((psy[h1] + 13) > (by[h2] - 24))) {
boom1.start();
bl[h2] = bl[h2] - 6;
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge < 4)) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 36) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 36) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 36) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 36) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 1;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
gotoAndPlay (420);
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
bossdeath.start();
boom2.start();
bt[h2] = 100;
btime[h2] = 16;
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 6;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 6;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 6;
bsx[h1] = bsx[h1] + h1;
if (bsy[h1] < -100) {
bsd[h1] = 4;
}
}
if (bsd[h1] == 4) {
bsy[h1] = bsy[h1] - 4;
bsx[h1] = bsx[h1] + h1;
if (bsy[h1] < -130) {
bsd[h1] = 6;
}
}
if (bsd[h1] == 6) {
bsy[h1] = bsy[h1] + 4;
bsx[h1] = bsx[h1] + h1;
if (bsy[h1] > -100) {
bsd[h1] = 8;
}
}
if (bsd[h1] == 8) {
bsy[h1] = bsy[h1] + 6;
bsx[h1] = bsx[h1] + h1;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] - 6;
bsx[h1] = bsx[h1] - h1;
if (bsy[h1] < -100) {
bsd[h1] = 5;
}
}
if (bsd[h1] == 5) {
bsy[h1] = bsy[h1] - 4;
bsx[h1] = bsx[h1] - h1;
if (bsy[h1] < -130) {
bsd[h1] = 7;
}
}
if (bsd[h1] == 7) {
bsy[h1] = bsy[h1] + 4;
bsx[h1] = bsx[h1] - h1;
if (bsy[h1] > -100) {
bsd[h1] = 9;
}
}
if (bsd[h1] == 9) {
bsy[h1] = bsy[h1] + 6;
bsx[h1] = bsx[h1] - h1;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
if (bsd[h1] == 0) {
bsf[h1] = 2;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 5;
}
}
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if ((bst[h1] > 1) and (bst[h1] < 4)) {
if ((bsd[h1] == 2) or (bsd[h1] == 3)) {
bsf[h1] = 6;
}
if ((bsd[h1] == 4) or (bsd[h1] == 5)) {
bsf[h1] = 7;
}
if ((bsd[h1] == 6) or (bsd[h1] == 7)) {
bsf[h1] = 8;
}
if ((bsd[h1] == 8) or (bsd[h1] == 9)) {
bsf[h1] = 9;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 7) > (py - 26))) and ((bsy[h1] - 7) < (py - 2))) and (i < 1)) {
boom2.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 11) {
if ((bt[h2] > 0) and (bl[h2] > 0)) {
if (bt[h2] == 90) {
h4 = 0;
h1 = 1;
while (h1 < 16) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 90) and ((bd[h2] == 4) or (bd[h2] == 5))) {
bd[h2] = bd[h2] - 4;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and ((bd[h2] < 4) or (bd[h2] > 5))) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (py < -140) {
py = -140;
}
if (py > 50) {
py = 50;
}
if (px < 10) {
px = 10;
}
if (px > 290) {
px = 290;
}
timer = ((bl[1] / 150) * 100) - 1;
if (timer > 100) {
timer = 100;
if (bd[1] == 100) {
timer = 0;
}
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 200) {
camx = 200;
}
camy = -60;
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 112
gotoAndPlay (111);
Frame 120
xz = 1;
lives = 3;
pl = 50;
px = 20;
py = -40;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 121;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 4;
blx[1] = 320;
bly[1] = -80;
blsx[1] = 120;
blsy[1] = 40;
blt[2] = 5;
blx[2] = 300;
bly[2] = -240;
blsx[2] = 60;
blsy[2] = 20;
blt[3] = 1;
blx[3] = 400;
bly[3] = -20;
blsx[3] = 400;
blsy[3] = 20;
blt[4] = 1;
blx[4] = 620;
bly[4] = -170;
blsx[4] = 180;
blsy[4] = 130;
blt[5] = 1;
blx[5] = 280;
bly[5] = -200;
blsx[5] = 80;
blsy[5] = 20;
blt[6] = 1;
blx[6] = 220;
bly[6] = -280;
blsx[6] = 20;
blsy[6] = 60;
blt[7] = 1;
blx[7] = 580;
bly[7] = -320;
blsx[7] = 220;
blsy[7] = 20;
Frame 121
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 8) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 4) {
h3 = (blx[h1] - px) / 3;
if (((((px + 2) > (blx[h1] + blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 5) {
h3 = (px - blx[h1]) / 3;
if (((((px - 2) < (blx[h1] - blsx[h1])) and ((px + 10) > (blx[h1] - blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
if (px > 790) {
gotoAndPlay (125);
}
if (py < -480) {
py = -480;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -410) {
camy = -410;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 122
gotoAndPlay (121);
Frame 130
px = 20;
py = -360;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 131;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 5;
bl[1] = 3;
bx[1] = 185;
by[1] = -270;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 1;
blx[1] = 270;
bly[1] = -160;
blsx[1] = 30;
blsy[1] = 20;
blt[2] = 1;
blx[2] = 90;
bly[2] = -180;
blsx[2] = 90;
blsy[2] = 180;
blt[3] = 1;
blx[3] = 550;
bly[3] = -250;
blsx[3] = 250;
blsy[3] = 250;
blt[4] = 1;
blx[4] = 210;
bly[4] = -340;
blsx[4] = 30;
blsy[4] = 20;
Frame 131
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 5) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 2) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 5) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 13;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 14;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - random(4);
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + random(4);
}
by[h2] = by[h2] + random(3);
if ((py - 35) < by[h2]) {
by[h2] = (by[h2] - 1) - random(3);
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(20);
bst[bsn] = 3;
bsd[bsn] = 3;
bsf[bsn] = 5;
bsx[bsn] = bx[h2];
bsy[bsn] = by[h2] - 10;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 2) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 5) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (py > -10) {
gotoAndPlay (135);
}
if (py < -470) {
py = -470;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 132
gotoAndPlay (131);
Frame 140
px = 400;
py = -470;
pd = 6;
ps = 1;
pj = 2;
ptime = 0;
pf = 2;
cframe = 141;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 6;
bl[1] = 5;
bx[1] = 390;
by[1] = -350;
bt[2] = 5;
bl[2] = 3;
bx[2] = 410;
by[2] = -350;
bt[3] = 1;
bl[3] = 3;
bx[3] = 370;
by[3] = -160;
bt[4] = 1;
bl[4] = 3;
bx[4] = 410;
by[4] = -40;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 1;
blx[1] = 360;
bly[1] = -20;
blsx[1] = 60;
blsy[1] = 20;
blt[2] = 1;
blx[2] = 430;
bly[2] = -140;
blsx[2] = 70;
blsy[2] = 20;
blt[3] = 1;
blx[3] = 150;
bly[3] = -250;
blsx[3] = 150;
blsy[3] = 250;
blt[4] = 1;
blx[4] = 650;
bly[4] = -250;
blsx[4] = 150;
blsy[4] = 250;
blt[5] = 1;
blx[5] = 340;
bly[5] = -260;
blsx[5] = 40;
blsy[5] = 20;
blt[6] = 1;
blx[6] = 460;
bly[6] = -260;
blsx[6] = 40;
blsy[6] = 20;
blt[7] = 1;
blx[7] = 400;
bly[7] = -400;
blsx[7] = 40;
blsy[7] = 20;
Frame 141
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 8) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 5) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 1) {
if (bd[h2] == 0) {
bf[h2] = 2;
if (btime[h2] < 1) {
jump.start();
bd[h2] = 1;
btime[h2] = 20 + random(20);
bj[h2] = -10;
bs[h2] = (px - bx[h2]) / 20;
}
}
if (bd[h2] == 1) {
bf[h2] = 3;
by[h2] = by[h2] + bj[h2];
bx[h2] = bx[h2] + bs[h2];
if (bj[h2] < 0) {
bj[h2] = bj[h2] + 1;
}
}
}
if (bt[h2] == 5) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 13;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 14;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - random(4);
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + random(4);
}
by[h2] = by[h2] + random(3);
if ((py - 35) < by[h2]) {
by[h2] = (by[h2] - 1) - random(3);
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(20);
bst[bsn] = 3;
bsd[bsn] = 3;
bsf[bsn] = 5;
bsx[bsn] = bx[h2];
bsy[bsn] = by[h2] - 10;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 6) {
if (bd[h2] == 0) {
if ((pace > 0) and (pace < 6)) {
bf[h2] = 15;
}
if ((pace > 5) and (pace < 12)) {
bf[h2] = 16;
}
if ((pace > 11) and (pace < 17)) {
bf[h2] = 17;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - 2;
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + 2;
}
if (py < by[h2]) {
by[h2] = by[h2] - 2;
}
if (py > by[h2]) {
by[h2] = by[h2] + 2;
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bl[h2] = 1;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 5) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 9) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (py > -10) {
gotoAndPlay (145);
}
if (py < -470) {
py = -470;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
Frame 142
gotoAndPlay (141);
Frame 150
px = 80;
py = -470;
pd = 6;
ps = 1;
pj = 2;
ptime = 0;
pf = 2;
cframe = 151;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 1;
bl[1] = 3;
bx[1] = 310;
by[1] = -360;
bt[2] = 4;
bl[2] = 3;
bx[2] = 350;
by[2] = -360;
bt[3] = 3;
bl[3] = 3;
bx[3] = 430;
by[3] = -400;
bt[4] = 1;
bl[4] = 3;
bx[4] = 440;
by[4] = -340;
bt[5] = 5;
bl[5] = 3;
bx[5] = 210;
by[5] = -240;
bt[6] = 4;
bl[6] = 3;
bx[6] = 330;
by[6] = -40;
bt[7] = 5;
bl[7] = 3;
bx[7] = 590;
by[7] = -80;
bt[8] = 4;
bl[8] = 3;
bx[8] = 590;
by[8] = -40;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 3;
blx[1] = 290;
bly[1] = -170;
blsx[1] = 50;
blsy[1] = 10;
blt[2] = 3;
blx[2] = 80;
bly[2] = -60;
blsx[2] = 20;
blsy[2] = 20;
blt[3] = 5;
blx[3] = 470;
bly[3] = -330;
blsx[3] = 90;
blsy[3] = 30;
blt[4] = 1;
blx[4] = 430;
bly[4] = -20;
blsx[4] = 370;
blsy[4] = 20;
blt[5] = 1;
blx[5] = 490;
bly[5] = -140;
blsx[5] = 310;
blsy[5] = 20;
blt[6] = 1;
blx[6] = 30;
bly[6] = -250;
blsx[6] = 30;
blsy[6] = 250;
blt[7] = 1;
blx[7] = 470;
bly[7] = -270;
blsx[7] = 90;
blsy[7] = 30;
blt[8] = 1;
blx[8] = 220;
bly[8] = -320;
blsx[8] = 160;
blsy[8] = 40;
blt[9] = 1;
blx[9] = 710;
bly[9] = -330;
blsx[9] = 90;
blsy[9] = 170;
Frame 151
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 10) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 3) {
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
pl = pl - 2;
}
}
if (blt[h1] == 5) {
h3 = (px - blx[h1]) / 3;
if (((((px - 2) < (blx[h1] - blsx[h1])) and ((px + 10) > (blx[h1] - blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 9) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 1) {
if (bd[h2] == 0) {
bf[h2] = 2;
if (btime[h2] < 1) {
jump.start();
bd[h2] = 1;
btime[h2] = 20 + random(20);
bj[h2] = -10;
bs[h2] = (px - bx[h2]) / 20;
}
}
if (bd[h2] == 1) {
bf[h2] = 3;
by[h2] = by[h2] + bj[h2];
bx[h2] = bx[h2] + bs[h2];
if (bj[h2] < 0) {
bj[h2] = bj[h2] + 1;
}
}
}
if (bt[h2] == 3) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 8;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 9;
}
bx[h2] = bx[h2] + 1;
if ((px - 40) < bx[h2]) {
bx[h2] = bx[h2] - 3;
}
if (px < bx[h2]) {
bd[h2] = 1;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 5;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 1) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 78;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 79;
}
bx[h2] = bx[h2] - 1;
if ((px + 40) > bx[h2]) {
bx[h2] = bx[h2] + 3;
}
if (px > bx[h2]) {
bd[h2] = 0;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 7;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] - 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 4) {
if (bd[h2] == 0) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 10;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 11;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 12;
}
bx[h2] = bx[h2] + 4;
h3 = random(50);
if ((h3 < 4) and ((px + 30) < bx[h2])) {
bd[h2] = 1;
}
}
if (bd[h2] == 1) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 80;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 81;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 82;
}
bx[h2] = bx[h2] - 4;
h3 = random(50);
if ((h3 < 4) and ((px - 30) > bx[h2])) {
bd[h2] = 0;
}
}
}
if (bt[h2] == 5) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 13;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 14;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - random(4);
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + random(4);
}
by[h2] = by[h2] + random(3);
if ((py - 35) < by[h2]) {
by[h2] = (by[h2] - 1) - random(3);
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(20);
bst[bsn] = 3;
bsd[bsn] = 3;
bsf[bsn] = 5;
bsx[bsn] = bx[h2];
bsy[bsn] = by[h2] - 10;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 9) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 10) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
if (blt[h1] == 5) {
h3 = (bx[h2] - blx[h1]) / 3;
if (((((bx[h2] - 2) < (blx[h1] - blsx[h1])) and ((bx[h2] + 10) > (blx[h1] - blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 26) < (bly[h1] + blsy[h1]))) and ((by[h2] + 5) >= (bly[h1] + h3))) {
h4 = 1;
by[h2] = bly[h1] + h3;
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (px > 790) {
gotoAndPlay (155);
}
if (py < -470) {
py = -470;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 152
gotoAndPlay (151);
Frame 160
px = 10;
py = -40;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 161;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 3;
bl[1] = 3;
bx[1] = 310;
by[1] = -250;
bt[2] = 3;
bl[2] = 3;
bx[2] = 450;
by[2] = -320;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 3;
blx[1] = 140;
bly[1] = -50;
blsx[1] = 40;
blsy[1] = 10;
blt[2] = 3;
blx[2] = 640;
bly[2] = -300;
blsx[2] = 20;
blsy[2] = 20;
blt[3] = 10;
blx[3] = 300;
bly[3] = -60;
blsx[3] = 40;
blsy[3] = 20;
blt[4] = 10;
blx[4] = 500;
bly[4] = -140;
blsx[4] = 40;
blsy[4] = 20;
blt[5] = 1;
blx[5] = 100;
bly[5] = -20;
blsx[5] = 100;
blsy[5] = 20;
blt[6] = 1;
blx[6] = 400;
bly[6] = -140;
blsx[6] = 20;
blsy[6] = 140;
blt[7] = 1;
blx[7] = 500;
bly[7] = -360;
blsx[7] = 20;
blsy[7] = 140;
blt[8] = 1;
blx[8] = 690;
bly[8] = -140;
blsx[8] = 110;
blsy[8] = 140;
Frame 161
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 9) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 3) {
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
pl = pl - 2;
}
}
if (blt[h1] == 30) {
if (bly[h1] < 200) {
bly[h1] = bly[h1] + 15;
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if ((blt[h1] > 10) and (blt[h1] < 30)) {
blt[h1] = blt[h1] + 1;
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 10) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
blt[h1] = 11;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 3) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 3) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 8;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 9;
}
bx[h2] = bx[h2] + 1;
if ((px - 40) < bx[h2]) {
bx[h2] = bx[h2] - 3;
}
if (px < bx[h2]) {
bd[h2] = 1;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 5;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 1) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 78;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 79;
}
bx[h2] = bx[h2] - 1;
if ((px + 40) > bx[h2]) {
bx[h2] = bx[h2] + 3;
}
if (px > bx[h2]) {
bd[h2] = 0;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 7;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] - 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 3) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 9) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (px > 790) {
gotoAndPlay (165);
}
if (py < -470) {
py = -470;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
block1._x = 100 + (blx[3] - camx);
block1._y = 100 + (bly[3] - camy);
block2._x = 100 + (blx[4] - camx);
block2._y = 100 + (bly[4] - camy);
Frame 162
gotoAndPlay (161);
Frame 170
px = 10;
py = -300;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 171;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 5;
bl[1] = 3;
bx[1] = 150;
by[1] = -360;
bt[2] = 5;
bl[2] = 3;
bx[2] = 330;
by[2] = -360;
bt[3] = 7;
bl[3] = 3;
bx[3] = 470;
by[3] = -300;
bt[4] = 7;
bl[4] = 3;
bx[4] = 610;
by[4] = -300;
bt[5] = 2;
bl[5] = 4;
bx[5] = 710;
by[5] = -300;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 3;
blx[1] = 320;
bly[1] = -240;
blsx[1] = 220;
blsy[1] = 20;
blt[2] = 6;
blx[2] = 160;
bly[2] = -280;
blsx[2] = 20;
blsy[2] = 20;
blt[3] = 7;
blx[3] = 480;
bly[3] = -280;
blsx[3] = 20;
blsy[3] = 20;
blt[4] = 1;
blx[4] = 50;
bly[4] = -250;
blsx[4] = 50;
blsy[4] = 50;
blt[5] = 1;
blx[5] = 320;
bly[5] = -200;
blsx[5] = 220;
blsy[5] = 20;
blt[6] = 1;
blx[6] = 670;
bly[6] = -250;
blsx[6] = 130;
blsy[6] = 50;
blt[7] = 1;
blx[7] = 560;
bly[7] = -440;
blsx[7] = 20;
blsy[7] = 60;
Frame 171
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 8) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 3) {
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
pl = pl - 2;
}
}
if (blt[h1] == 6) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((timer > 0) and (timer < 61)) {
px = px + 2;
}
if ((timer > 60) and (timer < 121)) {
px = px - 2;
}
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
if ((timer > 0) and (timer < 61)) {
blx[h1] = blx[h1] + 2;
}
if ((timer > 60) and (timer < 121)) {
blx[h1] = blx[h1] - 2;
}
}
if (blt[h1] == 7) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((timer > 0) and (timer < 61)) {
px = px - 2;
}
if ((timer > 60) and (timer < 121)) {
px = px + 2;
}
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
if ((timer > 0) and (timer < 61)) {
blx[h1] = blx[h1] - 2;
}
if ((timer > 60) and (timer < 121)) {
blx[h1] = blx[h1] + 2;
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 6) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 2) {
if (bd[h2] == 0) {
if ((pace > 0) and (pace < 5)) {
bf[h2] = 4;
}
if ((pace > 4) and (pace < 9)) {
bf[h2] = 5;
}
if ((pace > 8) and (pace < 13)) {
bf[h2] = 6;
}
if ((pace > 12) and (pace < 17)) {
bf[h2] = 7;
}
bx[h2] = bx[h2] + 2;
h3 = random(50);
if ((h3 < 4) and (px < bx[h2])) {
bd[h2] = 1;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bst[bsn] = 2;
bsd[bsn] = 0;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 10;
bsy[bsn] = by[h2] - 12;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 1) {
if ((pace > 0) and (pace < 5)) {
bf[h2] = 74;
}
if ((pace > 4) and (pace < 9)) {
bf[h2] = 75;
}
if ((pace > 8) and (pace < 13)) {
bf[h2] = 76;
}
if ((pace > 12) and (pace < 17)) {
bf[h2] = 77;
}
bx[h2] = bx[h2] - 2;
h3 = random(50);
if ((h3 < 4) and (px > bx[h2])) {
bd[h2] = 0;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bst[bsn] = 2;
bsd[bsn] = 1;
bsf[bsn] = 4;
bsx[bsn] = bx[h2] - 10;
bsy[bsn] = by[h2] - 12;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 5) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 13;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 14;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - random(4);
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + random(4);
}
by[h2] = by[h2] + random(3);
if ((py - 35) < by[h2]) {
by[h2] = (by[h2] - 1) - random(3);
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(20);
bst[bsn] = 3;
bsd[bsn] = 3;
bsf[bsn] = 5;
bsx[bsn] = bx[h2];
bsy[bsn] = by[h2] - 10;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 7) {
if (bd[h2] == 0) {
bf[h2] = 18;
if (px < bx[h2]) {
bd[h2] = 1;
}
if (btime[h2] < 1) {
bd[h2] = 2;
btime[h2] = 9;
}
}
if (bd[h2] == 1) {
bf[h2] = 88;
if (px > bx[h2]) {
bd[h2] = 0;
}
if (btime[h2] < 1) {
bd[h2] = 3;
btime[h2] = 9;
}
}
if (bd[h2] == 2) {
bf[h2] = 19;
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bd[h2] = 0;
bst[bsn] = 2;
bsd[bsn] = 0;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 10;
bsy[bsn] = by[h2] - 14;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 3) {
bf[h2] = 89;
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bd[h2] = 1;
bst[bsn] = 2;
bsd[bsn] = 1;
bsf[bsn] = 4;
bsx[bsn] = bx[h2] - 10;
bsy[bsn] = by[h2] - 14;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 6) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 8) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
if (blt[h1] == 6) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((timer > 0) and (timer < 61)) {
bx[h2] = bx[h2] + 2;
}
if ((timer > 60) and (timer < 121)) {
bx[h2] = bx[h2] - 2;
}
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
if (blt[h1] == 7) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
if ((timer > 0) and (timer < 61)) {
bx[h2] = bx[h2] - 2;
}
if ((timer > 60) and (timer < 121)) {
bx[h2] = bx[h2] + 2;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (px > 790) {
gotoAndPlay (175);
}
if (py < -470) {
py = -470;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
block1._x = 100 + (blx[2] - camx);
block1._y = 100 + (bly[2] - camy);
block2._x = 100 + (blx[3] - camx);
block2._y = 100 + (bly[3] - camy);
Frame 172
gotoAndPlay (171);
Frame 180
px = 10;
py = -60;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 181;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 1;
bl[1] = 3;
bx[1] = 190;
by[1] = -120;
bt[2] = 1;
bl[2] = 3;
bx[2] = 250;
by[2] = -120;
bt[3] = 1;
bl[3] = 3;
bx[3] = 310;
by[3] = -60;
bt[4] = 1;
bl[4] = 3;
bx[4] = 370;
by[4] = -100;
bt[5] = 1;
bl[5] = 3;
bx[5] = 510;
by[5] = -160;
bt[6] = 4;
bl[6] = 3;
bx[6] = 570;
by[6] = -60;
bt[7] = 4;
bl[7] = 3;
bx[7] = 750;
by[7] = -60;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 3;
blx[1] = 120;
bly[1] = -70;
blsx[1] = 20;
blsy[1] = 10;
blt[2] = 3;
blx[2] = 460;
bly[2] = -80;
blsx[2] = 20;
blsy[2] = 20;
blt[3] = 1;
blx[3] = 400;
bly[3] = -30;
blsx[3] = 400;
blsy[3] = 30;
blt[4] = 1;
blx[4] = 200;
bly[4] = -90;
blsx[4] = 60;
blsy[4] = 30;
blt[5] = 1;
blx[5] = 360;
bly[5] = -80;
blsx[5] = 20;
blsy[5] = 20;
blt[6] = 1;
blx[6] = 500;
bly[6] = -110;
blsx[6] = 20;
blsy[6] = 50;
blt[7] = 1;
blx[7] = 530;
bly[7] = -370;
blsx[7] = 90;
blsy[7] = 130;
blt[8] = 1;
blx[8] = 750;
bly[8] = -280;
blsx[8] = 50;
blsy[8] = 220;
Frame 181
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 9) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 3) {
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
pl = pl - 2;
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 8) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 1) {
if (bd[h2] == 0) {
bf[h2] = 2;
if (btime[h2] < 1) {
jump.start();
bd[h2] = 1;
btime[h2] = 20 + random(20);
bj[h2] = -10;
bs[h2] = (px - bx[h2]) / 20;
}
}
if (bd[h2] == 1) {
bf[h2] = 3;
by[h2] = by[h2] + bj[h2];
bx[h2] = bx[h2] + bs[h2];
if (bj[h2] < 0) {
bj[h2] = bj[h2] + 1;
}
}
}
if (bt[h2] == 4) {
if (bd[h2] == 0) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 10;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 11;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 12;
}
bx[h2] = bx[h2] + 4;
h3 = random(50);
if ((h3 < 4) and ((px + 30) < bx[h2])) {
bd[h2] = 1;
}
}
if (bd[h2] == 1) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 80;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 81;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 82;
}
bx[h2] = bx[h2] - 4;
h3 = random(50);
if ((h3 < 4) and ((px - 30) > bx[h2])) {
bd[h2] = 0;
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 8) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 9) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (py < -460) {
gotoAndPlay (185);
}
if (py < -470) {
py = -470;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
Frame 182
gotoAndPlay (181);
Frame 190
px = 420;
py = -40;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 191;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 5;
bl[1] = 3;
bx[1] = 370;
by[1] = -300;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 1;
blx[1] = 420;
bly[1] = -20;
blsx[1] = 20;
blsy[1] = 20;
blt[2] = 1;
blx[2] = 180;
bly[2] = -100;
blsx[2] = 180;
blsy[2] = 100;
blt[3] = 1;
blx[3] = 620;
bly[3] = -100;
blsx[3] = 180;
blsy[3] = 100;
blt[4] = 1;
blx[4] = 170;
bly[4] = -350;
blsx[4] = 170;
blsy[4] = 150;
blt[5] = 1;
blx[5] = 630;
bly[5] = -350;
blsx[5] = 170;
blsy[5] = 150;
Frame 191
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 6) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 2) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 5) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 13;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 14;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - random(4);
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + random(4);
}
by[h2] = by[h2] + random(3);
if ((py - 35) < by[h2]) {
by[h2] = (by[h2] - 1) - random(3);
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(20);
bst[bsn] = 3;
bsd[bsn] = 3;
bsf[bsn] = 5;
bsx[bsn] = bx[h2];
bsy[bsn] = by[h2] - 10;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 2) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 6) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (py < -460) {
gotoAndPlay (195);
}
if (py < -470) {
py = -470;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
Frame 192
gotoAndPlay (191);
Frame 200
px = 680;
py = -100;
pd = 1;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 201;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 2;
bl[1] = 3;
bx[1] = 30;
by[1] = -80;
bt[2] = 2;
bl[2] = 3;
bx[2] = 240;
by[2] = -140;
bt[3] = 2;
bl[3] = 3;
bx[3] = 310;
by[3] = -160;
bt[4] = 2;
bl[4] = 3;
bx[4] = 410;
by[4] = -140;
bt[5] = 3;
bl[5] = 3;
bx[5] = 250;
by[5] = -220;
bt[6] = 5;
bl[6] = 3;
bx[6] = 250;
by[6] = -200;
bt[7] = 6;
bl[7] = 3;
bx[7] = 270;
by[7] = -220;
bt[8] = 3;
bl[8] = 3;
bx[8] = 430;
by[8] = -200;
bt[9] = 5;
bl[9] = 3;
bx[9] = 450;
by[9] = -200;
bt[10] = 6;
bl[10] = 3;
bx[10] = 470;
by[10] = -200;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 4;
blx[1] = 180;
bly[1] = -120;
blsx[1] = 120;
blsy[1] = 40;
blt[2] = 5;
blx[2] = 480;
bly[2] = -120;
blsx[2] = 120;
blsy[2] = 40;
blt[3] = 1;
blx[3] = 350;
bly[3] = -40;
blsx[3] = 350;
blsy[3] = 40;
blt[4] = 1;
blx[4] = 330;
bly[4] = -120;
blsx[4] = 30;
blsy[4] = 40;
Frame 201
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 5) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 4) {
h3 = (blx[h1] - px) / 3;
if (((((px + 2) > (blx[h1] + blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 5) {
h3 = (px - blx[h1]) / 3;
if (((((px - 2) < (blx[h1] - blsx[h1])) and ((px + 10) > (blx[h1] - blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 11) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 125)) and (bx[h2] < (camx + 125))) and (by[h2] > (camy - 125))) and (by[h2] < (camy + 75))) {
if (bt[h2] == 110) {
if ((((((pace == 0) or (pace == 3)) or (pace == 4)) or (pace == 7)) or (pace == 10)) or (pace == 13)) {
bf[h2] = 220;
}
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
bf[h2] = 221;
}
if ((((((pace == 2) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
bf[h2] = 222;
}
}
if (bt[h2] == 2) {
if (bd[h2] == 0) {
if ((pace > 0) and (pace < 5)) {
bf[h2] = 4;
}
if ((pace > 4) and (pace < 9)) {
bf[h2] = 5;
}
if ((pace > 8) and (pace < 13)) {
bf[h2] = 6;
}
if ((pace > 12) and (pace < 17)) {
bf[h2] = 7;
}
bx[h2] = bx[h2] + 2;
h3 = random(50);
if ((h3 < 4) and (px < bx[h2])) {
bd[h2] = 1;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bst[bsn] = 2;
bsd[bsn] = 0;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 10;
bsy[bsn] = by[h2] - 12;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 1) {
if ((pace > 0) and (pace < 5)) {
bf[h2] = 74;
}
if ((pace > 4) and (pace < 9)) {
bf[h2] = 75;
}
if ((pace > 8) and (pace < 13)) {
bf[h2] = 76;
}
if ((pace > 12) and (pace < 17)) {
bf[h2] = 77;
}
bx[h2] = bx[h2] - 2;
h3 = random(50);
if ((h3 < 4) and (px > bx[h2])) {
bd[h2] = 0;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(15);
bst[bsn] = 2;
bsd[bsn] = 1;
bsf[bsn] = 4;
bsx[bsn] = bx[h2] - 10;
bsy[bsn] = by[h2] - 12;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 3) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 8;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 9;
}
bx[h2] = bx[h2] + 1;
if ((px - 40) < bx[h2]) {
bx[h2] = bx[h2] - 3;
}
if (px < bx[h2]) {
bd[h2] = 1;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 5;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] + 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
if (bd[h2] == 1) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 78;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 79;
}
bx[h2] = bx[h2] - 1;
if ((px + 40) > bx[h2]) {
bx[h2] = bx[h2] + 3;
}
if (px > bx[h2]) {
bd[h2] = 0;
}
by[h2] = by[h2] + 2;
if ((py - 30) < by[h2]) {
by[h2] = by[h2] - 4;
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 16 + random(15);
bst[bsn] = 1;
bsd[bsn] = 7;
bsf[bsn] = 3;
bsx[bsn] = bx[h2] - 2;
bsy[bsn] = by[h2] - 6;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 5) {
if (bd[h2] == 0) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bf[h2] = 13;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bf[h2] = 14;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - random(4);
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + random(4);
}
by[h2] = by[h2] + random(3);
if ((py - 35) < by[h2]) {
by[h2] = (by[h2] - 1) - random(3);
}
if (btime[h2] < 1) {
if (bst[bsn] == 0) {
laser.start();
btime[h2] = 20 + random(20);
bst[bsn] = 3;
bsd[bsn] = 3;
bsf[bsn] = 5;
bsx[bsn] = bx[h2];
bsy[bsn] = by[h2] - 10;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
}
}
if (bt[h2] == 6) {
if (bd[h2] == 0) {
if ((pace > 0) and (pace < 6)) {
bf[h2] = 15;
}
if ((pace > 5) and (pace < 12)) {
bf[h2] = 16;
}
if ((pace > 11) and (pace < 17)) {
bf[h2] = 17;
}
if (px < bx[h2]) {
bx[h2] = bx[h2] - 2;
}
if (px > bx[h2]) {
bx[h2] = bx[h2] + 2;
}
if (py < by[h2]) {
by[h2] = by[h2] - 2;
}
if (py > by[h2]) {
by[h2] = by[h2] + 2;
}
}
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 2;
}
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 4) < (bx[h2] + 12)) and ((psx[h1] + 4) > (bx[h2] - 12))) and ((psy[h1] - 4) < (by[h2] - 2))) and ((psy[h1] + 4) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 4;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 10) < (bx[h2] + 12)) and ((psx[h1] + 10) > (bx[h2] - 12))) and ((psy[h1] - 10) < (by[h2] - 2))) and ((psy[h1] + 10) > (by[h2] - 24))) {
shothit.start();
bl[h2] = bl[h2] - 6;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
metalcrunch.start();
bl[h2] = bl[h2] + 5;
}
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 32) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 32) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 2;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 215 - btime[h2];
if (btime[h2] < 1) {
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if (bt[h2] == 110) {
if (((((px - 10) < (bx[h2] + 6)) and ((px + 10) > (bx[h2] - 6))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
multibeep.start();
bt[h2] = 0;
bf[h2] = 1;
bl[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
if (pl < 50) {
pl = pl + 1;
}
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
h3 = random(6);
if (h3 < 3) {
boom1.start();
}
if ((h3 > 2) and (h3 < 5)) {
boom2.start();
}
if (h3 > 4) {
boom3.start();
}
h3 = random(12);
bt[h2] = 100;
btime[h2] = 16;
if (h3 < 2) {
bt[h2] = 110;
}
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if (bsd[h1] == 0) {
bsx[h1] = bsx[h1] + 8;
}
if (bsd[h1] == 1) {
bsx[h1] = bsx[h1] - 8;
}
if (bsd[h1] == 2) {
bsy[h1] = bsy[h1] - 8;
}
if (bsd[h1] == 3) {
bsy[h1] = bsy[h1] + 8;
}
if (bsd[h1] == 4) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 5) {
bsx[h1] = bsx[h1] + 6;
bsy[h1] = bsy[h1] + 6;
}
if (bsd[h1] == 6) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] - 6;
}
if (bsd[h1] == 7) {
bsx[h1] = bsx[h1] - 6;
bsy[h1] = bsy[h1] + 6;
}
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
bsf[h1] = 2;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (bsd[h1] == 0) {
bsf[h1] = 3;
}
if (bsd[h1] == 1) {
bsf[h1] = 4;
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 4;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 3) {
bsf[h1] = 5;
if ((((((bsx[h1] + 3) > (px - 12)) and ((bsx[h1] - 3) < (px + 12))) and ((bsy[h1] + 2) > (py - 26))) and ((bsy[h1] - 2) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 11) {
if ((bt[h2] > 0) and ((bl[h2] > 0) or (bt[h2] == 110))) {
if (((((bt[h2] == 1) or (bt[h2] == 2)) or (bt[h2] == 4)) or (bt[h2] == 7)) or (bt[h2] == 110)) {
h4 = 0;
h1 = 1;
while (h1 < 5) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
if (blt[h1] == 4) {
h3 = (blx[h1] - bx[h2]) / 3;
if (((((bx[h2] + 2) > (blx[h1] + blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 26) < (bly[h1] + blsy[h1]))) and ((by[h2] + 5) >= (bly[h1] + h3))) {
h4 = 1;
by[h2] = bly[h1] + h3;
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
}
if (blt[h1] == 5) {
h3 = (bx[h2] - blx[h1]) / 3;
if (((((bx[h2] - 2) < (blx[h1] - blsx[h1])) and ((bx[h2] + 10) > (blx[h1] - blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 26) < (bly[h1] + blsy[h1]))) and ((by[h2] + 5) >= (bly[h1] + h3))) {
h4 = 1;
by[h2] = bly[h1] + h3;
if ((bt[h2] == 1) and (bd[h2] == 1)) {
bd[h2] = 0;
}
}
}
h1++;
}
if ((h4 == 0) and (bj[h2] > -1)) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
if (px < 20) {
gotoAndPlay (205);
}
if (py < -480) {
py = -480;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -410) {
camy = -410;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
Frame 202
gotoAndPlay (201);
Frame 210
px = 780;
py = -100;
pd = 1;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 211;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 10;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 10;
blx[1] = 360;
bly[1] = -260;
blsx[1] = 40;
blsy[1] = 20;
blt[2] = 10;
blx[2] = 120;
bly[2] = -140;
blsx[2] = 40;
blsy[2] = 20;
blt[3] = 7;
blx[3] = 540;
bly[3] = -60;
blsx[3] = 20;
blsy[3] = 20;
blt[4] = 6;
blx[4] = 340;
bly[4] = -100;
blsx[4] = 20;
blsy[4] = 20;
blt[5] = 7;
blx[5] = 300;
bly[5] = -140;
blsx[5] = 20;
blsy[5] = 20;
blt[6] = 6;
blx[6] = 180;
bly[6] = -260;
blsx[6] = 20;
blsy[6] = 20;
blt[7] = 6;
blx[7] = 420;
bly[7] = -300;
blsx[7] = 20;
blsy[7] = 20;
blt[8] = 1;
blx[8] = 700;
bly[8] = -40;
blsx[8] = 100;
blsy[8] = 40;
blt[9] = 1;
blx[9] = 60;
bly[9] = -220;
blsx[9] = 20;
blsy[9] = 60;
blt[10] = 1;
blx[10] = 700;
bly[10] = -280;
blsx[10] = 100;
blsy[10] = 40;
blt[11] = 1;
blx[11] = 760;
bly[11] = -410;
blsx[11] = 40;
blsy[11] = 90;
blt[12] = 2;
blx[12] = 690;
bly[12] = -460;
blsx[12] = 10;
blsy[12] = 80;
Frame 211
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 13) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 2) {
if (((((px + 6) > (blx[h1] - blsx[h1])) and ((px - 6) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (Key.isDown(kdown) and (ptime < 1)) {
px = blx[h1];
py = py + 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) > (bly[h1] + blsy[h1])) {
pd = pd - 8;
pj = 2;
}
}
if (Key.isDown(kup) and (ptime < 1)) {
px = blx[h1];
py = py - 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) < (bly[h1] - blsy[h1])) {
py = py + 4;
ps = 1;
}
}
}
}
if (blt[h1] == 6) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((timer > 0) and (timer < 61)) {
px = px + 2;
}
if ((timer > 60) and (timer < 121)) {
px = px - 2;
}
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
if ((timer > 0) and (timer < 61)) {
blx[h1] = blx[h1] + 2;
}
if ((timer > 60) and (timer < 121)) {
blx[h1] = blx[h1] - 2;
}
}
if (blt[h1] == 7) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((timer > 0) and (timer < 61)) {
px = px - 2;
}
if ((timer > 60) and (timer < 121)) {
px = px + 2;
}
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
if ((timer > 0) and (timer < 61)) {
blx[h1] = blx[h1] - 2;
}
if ((timer > 60) and (timer < 121)) {
blx[h1] = blx[h1] + 2;
}
}
if (blt[h1] == 50) {
if (bly[h1] < 200) {
bly[h1] = bly[h1] + 15;
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if ((blt[h1] > 10) and (blt[h1] < 50)) {
blt[h1] = blt[h1] + 1;
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 10) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
blt[h1] = 11;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
if (py < -460) {
gotoAndPlay (215);
}
if (py < -470) {
py = -470;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 795) {
px = 795;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = px;
if (camx < 100) {
camx = 100;
}
if (camx > 700) {
camx = 700;
}
camy = py;
if (camy < -400) {
camy = -400;
}
if (camy > -50) {
camy = -50;
}
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
stage2._x = 300 - (camx / 2);
stage2._y = -37 - (camy / 2);
block1._x = 100 + (blx[3] - camx);
block1._y = 100 + (bly[3] - camy);
block2._x = 100 + (blx[4] - camx);
block2._y = 100 + (bly[4] - camy);
block3._x = 100 + (blx[5] - camx);
block3._y = 100 + (bly[5] - camy);
block4._x = 100 + (blx[6] - camx);
block4._y = 100 + (bly[6] - camy);
block5._x = 100 + (blx[7] - camx);
block5._y = 100 + (bly[7] - camy);
block6._x = 100 + (blx[1] - camx);
block6._y = 100 + (bly[1] - camy);
block7._x = 100 + (blx[2] - camx);
block7._y = 100 + (bly[2] - camy);
Frame 212
gotoAndPlay (211);
Frame 220
px = 100;
py = -150;
pd = 0;
ps = 1;
pj = 0;
ptime = 0;
pf = 2;
cframe = 221;
psn = 1;
h1 = 1;
while (h1 < 4) {
pst[h1] = 0;
psd[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
psf[h1] = 13;
h1++;
}
timer = 1;
pace = 1;
h1 = 1;
while (h1 < 11) {
bt[h1] = 0;
btime[h1] = 25;
bd[h1] = 0;
bj[h1] = 0;
bs[h1] = 0;
bl[h1] = 0;
bx[h1] = -1000;
by[h1] = -1000;
bf[h1] = 1;
h1++;
}
bt[1] = 90;
bs[1] = 0;
bl[1] = 150;
bx[1] = 170;
by[1] = -40;
bsn = 1;
h1 = 1;
while (h1 < 7) {
bst[h1] = 0;
bsd[h1] = 0;
bsx[h1] = -2000;
bsy[h1] = -2000;
bsf[h1] = 7;
h1++;
}
h1 = 1;
while (h1 < 16) {
blt[h1] = 1;
blx[h1] = -2000;
bly[h1] = -2000;
blsx[h1] = 0;
blsy[h1] = 0;
h1++;
}
blt[1] = 1;
blx[1] = 175;
bly[1] = -20;
blsx[1] = 175;
blsy[1] = 20;
blt[2] = 1;
blx[2] = 10;
bly[2] = -105;
blsx[2] = 20;
blsy[2] = 65;
Frame 221
bl1._width = blsx[1] * 2;
bl1._height = blsy[1] * 2;
bl1._x = 100 + (blx[1] - camx);
bl1._y = 100 + (bly[1] - camy);
bl2._width = blsx[2] * 2;
bl2._height = blsy[2] * 2;
bl2._x = 100 + (blx[2] - camx);
bl2._y = 100 + (bly[2] - camy);
bl3._width = blsx[3] * 2;
bl3._height = blsy[3] * 2;
bl3._x = 100 + (blx[3] - camx);
bl3._y = 100 + (bly[3] - camy);
bl4._width = blsx[4] * 2;
bl4._height = blsy[4] * 2;
bl4._x = 100 + (blx[4] - camx);
bl4._y = 100 + (bly[4] - camy);
bl5._width = blsx[5] * 2;
bl5._height = blsy[5] * 2;
bl5._x = 100 + (blx[5] - camx);
bl5._y = 100 + (bly[5] - camy);
bl6._width = blsx[6] * 2;
bl6._height = blsy[6] * 2;
bl6._x = 100 + (blx[6] - camx);
bl6._y = 100 + (bly[6] - camy);
bl7._width = blsx[7] * 2;
bl7._height = blsy[7] * 2;
bl7._x = 100 + (blx[7] - camx);
bl7._y = 100 + (bly[7] - camy);
bl8._width = blsx[8] * 2;
bl8._height = blsy[8] * 2;
bl8._x = 100 + (blx[8] - camx);
bl8._y = 100 + (bly[8] - camy);
bl9._width = blsx[9] * 2;
bl9._height = blsy[9] * 2;
bl9._x = 100 + (blx[9] - camx);
bl9._y = 100 + (bly[9] - camy);
bl10._width = blsx[10] * 2;
bl10._height = blsy[10] * 2;
bl10._x = 100 + (blx[10] - camx);
bl10._y = 100 + (bly[10] - camy);
bl11._width = blsx[11] * 2;
bl11._height = blsy[11] * 2;
bl11._x = 100 + (blx[11] - camx);
bl11._y = 100 + (bly[11] - camy);
bl12._width = blsx[12] * 2;
bl12._height = blsy[12] * 2;
bl12._x = 100 + (blx[12] - camx);
bl12._y = 100 + (bly[12] - camy);
bl13._width = blsx[13] * 2;
bl13._height = blsy[13] * 2;
bl13._x = 100 + (blx[13] - camx);
bl13._y = 100 + (bly[13] - camy);
bl14._width = blsx[14] * 2;
bl14._height = blsy[14] * 2;
bl14._x = 100 + (blx[14] - camx);
bl14._y = 100 + (bly[14] - camy);
bl15._width = blsx[15] * 2;
bl15._height = blsy[15] * 2;
bl15._x = 100 + (blx[15] - camx);
bl15._y = 100 + (bly[15] - camy);
bl1.gotoAndStop(blt[1]);
bl2.gotoAndStop(blt[2]);
bl3.gotoAndStop(blt[3]);
bl4.gotoAndStop(blt[4]);
bl5.gotoAndStop(blt[5]);
bl6.gotoAndStop(blt[6]);
bl7.gotoAndStop(blt[7]);
bl8.gotoAndStop(blt[8]);
bl9.gotoAndStop(blt[9]);
bl10.gotoAndStop(blt[10]);
bl11.gotoAndStop(blt[11]);
bl12.gotoAndStop(blt[12]);
bl13.gotoAndStop(blt[13]);
bl14.gotoAndStop(blt[14]);
bl15.gotoAndStop(blt[15]);
if (Key.isDown(45)) {
xz = 0;
}
if (Key.isDown(36)) {
xz = 1;
}
if (Key.isDown(33)) {
xz = 2;
}
if (pd == 0) {
pf = 2 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 324 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 174 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 185 - charge;
}
if (charge > 11) {
pf = 196 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 8;
pj = -10;
}
}
if (pd == 1) {
pf = 72 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 394 - charge;
}
}
if ((xz == 1) and (charge > 0)) {
if ((charge > 0) and (charge < 7)) {
pf = 244 - charge;
}
if ((charge > 6) and (charge < 12)) {
pf = 255 - charge;
}
if (charge > 11) {
pf = 266 - charge;
}
if ((Key.isDown(kattack) and (ptime == 0)) and (charge < 4)) {
ptime = 2;
charge = 12;
}
if (((Key.isDown(kattack) and (ptime < 2)) and (charge > 6)) and (charge < 10)) {
electric.start();
ptime = 2;
charge = 17;
}
}
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
if (Key.isDown(kjump) and Key.isDown(kdash)) {
pd = 9;
pj = -10;
}
}
if (pd == 2) {
if ((pace > 0) and (pace < 3)) {
pf = 3 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 4 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 5 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 6 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 7 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 8 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 9 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 10 + (150 * xz);
}
px = px + 4;
if ((xz == 2) and (charge > 0)) {
pf = 324 - charge;
px = px - 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 174 - charge;
px = px - 4;
}
pd = 0;
if (Key.isDown(kright)) {
pd = 2;
}
if (Key.isDown(kleft)) {
pd = 1;
}
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 6;
pj = -10;
}
}
if (pd == 3) {
if ((pace > 0) and (pace < 3)) {
pf = 73 + (150 * xz);
}
if ((pace > 2) and (pace < 5)) {
pf = 74 + (150 * xz);
}
if ((pace > 4) and (pace < 7)) {
pf = 75 + (150 * xz);
}
if ((pace > 6) and (pace < 9)) {
pf = 76 + (150 * xz);
}
if ((pace > 8) and (pace < 11)) {
pf = 77 + (150 * xz);
}
if ((pace > 10) and (pace < 13)) {
pf = 78 + (150 * xz);
}
if ((pace > 12) and (pace < 15)) {
pf = 79 + (150 * xz);
}
if ((pace > 14) and (pace < 17)) {
pf = 80 + (150 * xz);
}
px = px - 4;
if ((xz == 2) and (charge > 0)) {
pf = 394 - charge;
px = px + 4;
}
if ((xz == 1) and (charge > 0)) {
pf = 244 - charge;
px = px + 4;
}
pd = 1;
if (Key.isDown(kright)) {
pd = 0;
}
if (Key.isDown(kleft)) {
pd = 3;
}
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 7;
pj = -10;
}
}
if (pd == 4) {
pf = 13 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 340 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 190 - charge;
}
px = px + 7;
pd = 0;
if (Key.isDown(kdash)) {
pd = 4;
}
if (Key.isDown(kjump)) {
pd = 8;
pj = -10;
}
}
if (pd == 5) {
pf = 83 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 410 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 260 - charge;
}
px = px - 7;
pd = 1;
if (Key.isDown(kdash)) {
pd = 5;
}
if (Key.isDown(kjump)) {
pd = 9;
pj = -10;
}
}
if (pd == 6) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
}
if (Key.isDown(kleft)) {
px = px - 5;
pd = 7;
}
}
if (pd == 7) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 4;
pd = 6;
}
if (Key.isDown(kleft)) {
px = px - 5;
}
}
if (pd == 8) {
if (pj <= 0) {
pf = 11 + (150 * xz);
}
if (pj > 0) {
pf = 12 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 346 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 196 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
}
if (Key.isDown(kleft)) {
px = px - 7;
pd = 9;
}
}
if (pd == 9) {
if (pj <= 0) {
pf = 81 + (150 * xz);
}
if (pj > 0) {
pf = 82 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 416 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 266 - charge;
}
if (Key.isDown(kright)) {
px = px + 7;
pd = 8;
}
if (Key.isDown(kleft)) {
px = px - 7;
}
}
if (pd == 10) {
pf = 16 + (150 * xz);
px = px + 4;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 6;
pj = 2;
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
}
}
if (pd == 11) {
pf = 86 + (150 * xz);
px = px - 5;
py = py - 4;
ps = ps + 1;
if (ps > 2) {
pd = 7;
pj = 2;
if (Key.isDown(kleft) and key.isdown(kjump)) {
pd = 7;
pj = -8;
}
if ((Key.isDown(kleft) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 9;
pj = -8;
}
if (Key.isDown(kright) and key.isdown(kjump)) {
pd = 6;
pj = -8;
}
if ((Key.isDown(kright) and key.isdown(kjump)) and key.isdown(kdash)) {
pd = 8;
pj = -8;
}
}
}
if (pd == 12) {
pf = 17 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 352 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 202 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 6;
pj = 2;
}
if (pwall == 1) {
pd = 12;
pj = 0;
}
if (Key.isDown(kright)) {
pd = 6;
pj = 2;
px = px + 4;
}
if (Key.isDown(kjump)) {
pd = 10;
px = px + 4;
ps = 1;
}
}
if (pd == 13) {
pf = 87 + (150 * xz);
if ((xz == 2) and (charge > 0)) {
pf = 422 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 272 - charge;
}
py = py + 2;
if (pwall == 0) {
pd = 7;
pj = 2;
}
if (pwall == 1) {
pd = 13;
pj = 0;
}
if (Key.isDown(kleft)) {
pd = 7;
pj = 2;
px = px - 5;
}
if (Key.isDown(kjump)) {
pd = 11;
px = px - 5;
ps = 1;
}
}
if (pd == 14) {
if ((ps == 1) or (ps == 2)) {
pf = 14 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 15 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 358 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 208 - charge;
}
if (Key.isDown(kleft)) {
pd = 15;
}
if (Key.isDown(kjump)) {
pd = 6;
px = px + 12;
pj = 2;
}
}
if (pd == 15) {
if ((ps == 1) or (ps == 2)) {
pf = 84 + (150 * xz);
}
if ((ps == 3) or (ps == 4)) {
pf = 85 + (150 * xz);
}
if ((xz == 2) and (charge > 0)) {
pf = 428 - charge;
}
if ((xz == 1) and (charge > 0)) {
pf = 278 - charge;
}
if (Key.isDown(kright)) {
pd = 14;
}
if (Key.isDown(kjump)) {
pd = 7;
px = px - 12;
pj = 2;
}
}
if ((pd > 5) and (pd < 10)) {
py = py + pj;
pj = pj + 4;
if (pj > 12) {
pj = 12;
}
if (Key.isDown(kjump)) {
pj = pj - 3;
}
}
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (psd[h1] == 0) {
psx[h1] = psx[h1] + 10;
}
if (psd[h1] == 1) {
psx[h1] = psx[h1] - 10;
}
if ((psx[h1] > (camx + 125)) or (psx[h1] < (camx - 125))) {
pst[h1] = 0;
psf[h1] = 13;
psx[h1] = -2000;
psy[h1] = -2000;
}
if (pst[h1] == 1) {
psf[h1] = 2;
}
if (pst[h1] == 2) {
if (psd[h1] == 0) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 3;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 4;
}
}
if (psd[h1] == 1) {
if ((((((((pace == 1) or (pace == 2)) or (pace == 5)) or (pace == 6)) or (pace == 9)) or (pace == 10)) or (pace == 13)) or (pace == 14)) {
psf[h1] = 8;
}
if ((((((((pace == 3) or (pace == 4)) or (pace == 7)) or (pace == 8)) or (pace == 11)) or (pace == 12)) or (pace == 15)) or (pace == 16)) {
psf[h1] = 9;
}
}
}
if (pst[h1] == 3) {
if (psd[h1] == 0) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 5;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 5;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 7;
}
}
if (psd[h1] == 1) {
if (((((pace == 1) or (pace == 5)) or (pace == 8)) or (pace == 11)) or (pace == 14)) {
psf[h1] = 10;
}
if ((((((pace == 2) or (pace == 3)) or (pace == 6)) or (pace == 9)) or (pace == 12)) or (pace == 15)) {
psf[h1] = 11;
}
if (((((pace == 4) or (pace == 7)) or (pace == 8)) or (pace == 13)) or (pace == 16)) {
psf[h1] = 12;
}
}
}
}
h1++;
}
if (xz == 0) {
if (Key.isDown(kattack)) {
ptime = 2;
charge = charge + 1;
}
if (ptime > 0) {
pf = pf + 16;
if ((ptime == 1) and (pst[psn] == 0)) {
buster.start();
if (charge < 15) {
pst[psn] = 1;
}
if ((charge > 14) and (charge < 40)) {
pst[psn] = 2;
}
if (charge > 39) {
pst[psn] = 3;
}
charge = 0;
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 11)) or (pd == 12)) or (pd == 14)) {
psd[psn] = 0;
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 10)) or (pd == 13)) or (pd == 15)) {
psd[psn] = 1;
}
if ((pd == 0) or (pd == 2)) {
psx[psn] = px + 13;
psy[psn] = py - 14;
}
if ((pd == 1) or (pd == 3)) {
psx[psn] = px - 13;
psy[psn] = py - 14;
}
if (pd == 4) {
psx[psn] = px + 15;
psy[psn] = py - 10;
}
if (pd == 5) {
psx[psn] = px - 15;
psy[psn] = py - 10;
}
if ((pd == 6) or (pd == 8)) {
psx[psn] = px + 14;
psy[psn] = py - 17;
}
if ((pd == 7) or (pd == 9)) {
psx[psn] = px - 14;
psy[psn] = py - 17;
}
if (pd == 10) {
psx[psn] = px - 13;
psy[psn] = py - 16;
}
if (pd == 11) {
psx[psn] = px + 13;
psy[psn] = py - 16;
}
if ((pd == 12) or (pd == 14)) {
psx[psn] = px + 13;
psy[psn] = py - 20;
}
if ((pd == 13) or (pd == 15)) {
psx[psn] = px - 13;
psy[psn] = py - 20;
}
psn = psn + 1;
if (psn > 3) {
psn = 1;
}
}
}
}
if (xz == 1) {
if (charge > 0) {
charge = charge - 1;
}
if ((charge == 7) or (charge == 12)) {
charge = 0;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if (xz == 2) {
if (charge > 0) {
charge = charge - 1;
}
if (Key.isDown(kattack)) {
if ((ptime == 0) and (charge == 0)) {
charge = 6;
electric.start();
}
ptime = 2;
}
}
if ((pl < 1) or (py > 40)) {
if (lives < 1) {
gotoAndPlay (304);
}
if (lives > 0) {
lives = lives - 1;
pl = 50;
charge = 0;
gotoAndPlay (230);
}
}
h4 = 0;
pwall = 0;
h1 = 1;
while (h1 < 16) {
if (blt[h1] == 1) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 2) {
if (((((px + 6) > (blx[h1] - blsx[h1])) and ((px - 6) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (Key.isDown(40) and (ptime < 1)) {
px = blx[h1];
py = py + 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) > (bly[h1] + blsy[h1])) {
pd = pd - 8;
pj = 2;
}
}
if (Key.isDown(38) and (ptime < 1)) {
px = blx[h1];
py = py - 4;
if ((pd == 14) or (pd == 15)) {
ps = ps + 1;
if (ps > 4) {
ps = 1;
}
}
if ((pd < 14) or (pd > 15)) {
px = blx[h1];
ps = 1;
if (((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) {
pd = 14;
}
if (((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) {
pd = 15;
}
}
if ((py - 26) < (bly[h1] - blsy[h1])) {
py = py + 4;
ps = 1;
}
}
}
}
if (blt[h1] == 3) {
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
pl = pl - 2;
}
}
if (blt[h1] == 4) {
h3 = (blx[h1] - px) / 3;
if (((((px + 2) > (blx[h1] + blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 5) {
h3 = (px - blx[h1]) / 3;
if (((((px - 2) < (blx[h1] - blsx[h1])) and ((px + 10) > (blx[h1] - blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 26) < (bly[h1] + blsy[h1]))) and ((py + 5) >= (bly[h1] + h3))) {
h4 = 1;
py = bly[h1] + h3;
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 6) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((timer > 0) and (timer < 61)) {
px = px + 2;
}
if ((timer > 60) and (timer < 121)) {
px = px - 2;
}
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
if ((timer > 0) and (timer < 61)) {
blx[h1] = blx[h1] + 2;
}
if ((timer > 60) and (timer < 121)) {
blx[h1] = blx[h1] - 2;
}
}
if (blt[h1] == 7) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((timer > 0) and (timer < 61)) {
px = px - 2;
}
if ((timer > 60) and (timer < 121)) {
px = px + 2;
}
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
if ((timer > 0) and (timer < 61)) {
blx[h1] = blx[h1] - 2;
}
if ((timer > 60) and (timer < 121)) {
blx[h1] = blx[h1] + 2;
}
}
if (blt[h1] == 30) {
if (bly[h1] < 200) {
bly[h1] = bly[h1] + 15;
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if ((blt[h1] > 10) and (blt[h1] < 30)) {
blt[h1] = blt[h1] + 1;
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
if (blt[h1] == 10) {
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((py - 6) > ((bly[h1] + blsy[h1]) + 6))) {
py = (bly[h1] + blsy[h1]) + 35;
pj = 0;
}
if (((((px + 10) > (blx[h1] - blsx[h1])) and ((px - 10) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 30) < (bly[h1] + blsy[h1]))) {
if (px > blx[h1]) {
px = (blx[h1] + blsx[h1]) + 10;
}
if (px < blx[h1]) {
px = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((px + 11) > (blx[h1] - blsx[h1])) and ((px - 11) < (blx[h1] + blsx[h1]))) and ((py - 16) > (bly[h1] - blsy[h1]))) and ((py - 20) < (bly[h1] + blsy[h1]))) {
pwall = 1;
if ((((((pd == 6) or (pd == 7)) or (pd == 8)) or (pd == 9)) or (pd == 12)) or (pd == 13)) {
if ((px > blx[h1]) and Key.isDown(kleft)) {
pd = 12;
}
if ((px < blx[h1]) and Key.isDown(kright)) {
pd = 13;
}
}
}
if (((((px + 8) > (blx[h1] - blsx[h1])) and ((px - 8) < (blx[h1] + blsx[h1]))) and ((py - 22) < (bly[h1] - blsy[h1]))) and ((py + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
blt[h1] = 11;
py = bly[h1] - blsy[h1];
if ((pd == 6) or (pd == 7)) {
pd = pd - 6;
}
if ((pd == 8) or (pd == 9)) {
pd = pd - 8;
}
if ((pd == 12) or (pd == 13)) {
pd = pd - 12;
}
}
}
h1++;
}
if (((h4 == 0) and (pwall == 0)) and ((pd < 14) or (pd > 15))) {
if ((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 14)) {
pd = 6;
pj = 2;
}
if ((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 15)) {
pd = 7;
pj = 2;
}
}
h2 = 1;
while (h2 < 2) {
if (bt[h2] > 0) {
if ((((bx[h2] > (camx - 250)) and (bx[h2] < (camx + 250))) and (by[h2] > (camy - 250))) and (by[h2] < (camy + 250))) {
if (bt[h2] == 90) {
if (bd[h2] == 0) {
bf[h2] = 2;
if (btime[h2] < 1) {
h3 = random(30);
if (h3 < 4) {
bd[h2] = 1;
}
if ((h3 > 3) and (h3 < 7)) {
if (py <= -80) {
bd[h2] = 4;
}
if (py > -80) {
bd[h2] = 3;
}
btime[h2] = 24;
}
if ((h3 > 6) and (h3 < 10)) {
bd[h2] = 5;
btime[h2] = 10 + random(13);
}
}
}
if (bd[h2] == 1) {
if ((pace > 0) and (pace < 5)) {
bf[h2] = 3;
}
if ((pace > 4) and (pace < 9)) {
bf[h2] = 4;
}
if ((pace > 8) and (pace < 13)) {
bf[h2] = 5;
}
if ((pace > 12) and (pace < 17)) {
bf[h2] = 6;
}
bx[h2] = (bx[h2] - 4) - random(2);
if (bx[h2] < 55) {
bd[h2] = 2;
bj[h2] = -8;
}
}
if (bd[h2] == 2) {
bf[h2] = 7;
bx[h2] = bx[h2] + 7;
by[h2] = by[h2] + bj[h2];
if (bj[h2] < 4) {
bj[h2] = bj[h2] + 1;
}
}
if (bd[h2] == 5) {
bf[h2] = 10;
if ((((btime[h2] == 5) or (btime[h2] == 10)) or (btime[h2] == 15)) or (btime[h2] == 20)) {
if (bst[bsn] == 0) {
rocket.start();
bst[bsn] = 2;
bsd[bsn] = (py + 70) / 10;
bsf[bsn] = 4;
bsx[bsn] = bx[h2] - 15;
bsy[bsn] = by[h2] - 34;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
if (btime[h2] < 1) {
bd[h2] = 0;
btime[h2] = 10 + random(10);
}
}
if (bd[h2] == 4) {
bf[h2] = 9;
if ((((btime[h2] == 6) or (btime[h2] == 12)) or (btime[h2] == 18)) or (btime[h2] == 24)) {
if (bst[bsn] == 0) {
shothit.start();
bst[bsn] = 1;
bsd[bsn] = 1;
bsf[bsn] = 2;
bsx[bsn] = bx[h2] - 5;
bsy[bsn] = by[h2] - 38;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
if (btime[h2] < 1) {
bd[h2] = 0;
btime[h2] = 10 + random(10);
}
}
if (bd[h2] == 3) {
bf[h2] = 8;
if ((((btime[h2] == 6) or (btime[h2] == 12)) or (btime[h2] == 18)) or (btime[h2] == 24)) {
if (bst[bsn] == 0) {
shothit.start();
bst[bsn] = 1;
bsd[bsn] = 0;
bsf[bsn] = 2;
bsx[bsn] = bx[h2] - 20;
bsy[bsn] = by[h2] - 25;
bsn = bsn + 1;
if (bsn > 6) {
bsn = 1;
}
}
}
if (btime[h2] < 1) {
bd[h2] = 0;
btime[h2] = 10 + random(10);
}
}
}
if (((btime[h2] < 1) and (bd > 2)) and (bd < 6)) {
bd[h2] = 0;
btime[h2] = 10 + random(10);
}
if ((xz == 0) and (bl[h2] > 0)) {
h1 = 1;
while (h1 < 4) {
if (pst[h1] > 0) {
if (pst[h1] == 1) {
if (((((psx[h1] - 3) < (bx[h2] + 12)) and ((psx[h1] + 3) > (bx[h2] - 12))) and ((psy[h1] - 3) < (by[h2] - 2))) and ((psy[h1] + 3) > (by[h2] - 35))) {
shothit.start();
bl[h2] = bl[h2] - 2;
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 2) {
if (((((psx[h1] - 5) < (bx[h2] + 12)) and ((psx[h1] + 5) > (bx[h2] - 12))) and ((psy[h1] - 5) < (by[h2] - 2))) and ((psy[h1] + 5) > (by[h2] - 35))) {
shothit.start();
bl[h2] = bl[h2] - 4;
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
if (pst[h1] == 3) {
if (((((psx[h1] - 13) < (bx[h2] + 12)) and ((psx[h1] + 13) > (bx[h2] - 12))) and ((psy[h1] - 13) < (by[h2] - 2))) and ((psy[h1] + 13) > (by[h2] - 35))) {
boom1.start();
bl[h2] = bl[h2] - 6;
if (bl[h2] > 0) {
pst[h1] = 0;
psx[h1] = -2000;
psy[h1] = -2000;
}
}
}
h1++;
}
}
if (((xz == 2) and (charge > 0)) and (charge < 4)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 38) > (bx[h2] - 12)) and ((px - 8) < (bx[h2] + 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 38) < (bx[h2] + 12)) and ((px + 8) > (bx[h2] - 12))) and (py > (by[h2] - 28))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 2;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 2;
}
}
}
}
if ((xz == 1) and (charge > 0)) {
if ((((((((pd == 0) or (pd == 2)) or (pd == 4)) or (pd == 6)) or (pd == 8)) or (pd == 10)) or (pd == 12)) or (pd == 14)) {
if ((((((px + 36) > (bx[h2] - 25)) and ((px - 8) < (bx[h2] + 25))) and (py > (by[h2] - 35))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
if ((((((((pd == 1) or (pd == 3)) or (pd == 5)) or (pd == 7)) or (pd == 9)) or (pd == 11)) or (pd == 13)) or (pd == 15)) {
if ((((((px - 36) < (bx[h2] + 25)) and ((px + 8) > (bx[h2] - 25))) and (py > (by[h2] - 35))) and ((py - 26) < (by[h2] + 2))) and (bl[h2] > 0)) {
bl[h2] = bl[h2] - 1;
if ((bt[h2] == 7) and ((bd[h2] == 0) or (bd[h2] == 1))) {
bl[h2] = bl[h2] + 1;
}
}
}
}
if (((bl[h2] > 0) and (bt[h2] > 0)) and (i < 1)) {
if (((((px - 10) < (bx[h2] + 12)) and ((px + 10) > (bx[h2] - 12))) and (py > (by[h2] - 25))) and ((py - 24) < by[h2])) {
melee.start();
pl = pl - 8;
i = 12;
}
}
if (btime[h2] > 0) {
btime[h2] = btime[h2] - 1;
}
if (bt[h2] == 100) {
bf[h2] = 257 - btime[h2];
if (btime[h2] < 1) {
gotoAndPlay (450);
bt[h2] = 0;
bf[h2] = 1;
bx[h2] = -1000;
by[h2] = -1000;
}
}
if ((bl[h2] < 1) and (bt[h2] < 100)) {
bossdeath.start();
boom3.start();
bt[h2] = 100;
btime[h2] = 58;
}
}
}
h2++;
}
h1 = 1;
while (h1 < 7) {
if (bst[h1] > 0) {
if ((((bsx[h1] > (camx + 125)) or (bsx[h1] < (camx - 125))) or (bsy[h1] > (camy + 70))) or (bsy[h1] < (camy - 125))) {
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
if (bst[h1] == 1) {
if (bsd[h1] == 0) {
bsf[h1] = 2;
bsx[h1] = bsx[h1] - 7;
if (((h1 == 1) or (h1 == 3)) or (h1 == 5)) {
bsy[h1] = bsy[h1] - 1;
}
if (((h1 == 2) or (h1 == 4)) or (h1 == 6)) {
bsy[h1] = bsy[h1] + 1;
}
}
if (bsd[h1] == 1) {
bsf[h1] = 3;
bsx[h1] = bsx[h1] - 5;
bsy[h1] = bsy[h1] - 4;
if (((h1 == 1) or (h1 == 3)) or (h1 == 5)) {
bsx[h1] = bsx[h1] - 2;
}
if (((h1 == 2) or (h1 == 4)) or (h1 == 6)) {
bsy[h1] = bsy[h1] - 1;
}
}
if ((((((bsx[h1] + 5) > (px - 12)) and ((bsx[h1] - 5) < (px + 12))) and ((bsy[h1] + 3) > (py - 26))) and ((bsy[h1] - 3) < (py - 2))) and (i < 1)) {
melee.start();
i = 12;
pl = pl - 2;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
if (bst[h1] == 2) {
if (((pace > 0) and (pace < 5)) or ((pace > 8) and (pace < 13))) {
bsf[h1] = 4;
}
if (((pace > 4) and (pace < 9)) or ((pace > 12) and (pace < 17))) {
bsf[h1] = 5;
}
bsx[h1] = bsx[h1] - 8;
bsy[h1] = bsy[h1] + bsd[h1];
if ((((((bsx[h1] + 6) > (px - 12)) and ((bsx[h1] - 6) < (px + 12))) and ((bsy[h1] + 4) > (py - 26))) and ((bsy[h1] - 4) < (py - 2))) and (i < 1)) {
boom2.start();
i = 12;
pl = pl - 3;
bst[h1] = 0;
bsf[h1] = 13;
bsx[h1] = -2000;
bsy[h1] = -2000;
}
}
}
h1++;
}
h2 = 1;
while (h2 < 11) {
if ((bt[h2] > 0) and (bl[h2] > 0)) {
if (bt[h2] == 90) {
h4 = 0;
h1 = 1;
while (h1 < 16) {
if (blt[h1] == 1) {
if (((((bx[h2] + 10) > (blx[h1] - blsx[h1])) and ((bx[h2] - 10) < (blx[h1] + blsx[h1]))) and ((by[h2] - 16) > (bly[h1] - blsy[h1]))) and ((by[h2] - 30) < (bly[h1] + blsy[h1]))) {
if (bx[h2] > blx[h1]) {
bx[h2] = (blx[h1] + blsx[h1]) + 10;
}
if (bx[h2] < blx[h1]) {
bx[h2] = (blx[h1] - blsx[h1]) - 10;
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 22) < (bly[h1] - blsy[h1]))) and ((by[h2] + 2) >= (bly[h1] - blsy[h1]))) {
h4 = 1;
by[h2] = bly[h1] - blsy[h1];
if ((bt[h2] == 90) and (bd[h2] == 2)) {
bd[h2] = 0;
metal.start();
btime[h2] = 50 + random(10);
}
}
if (((((bx[h2] + 8) > (blx[h1] - blsx[h1])) and ((bx[h2] - 8) < (blx[h1] + blsx[h1]))) and ((by[h2] - 28) <= ((bly[h1] + blsy[h1]) + 6))) and ((by[h2] - 6) > ((bly[h1] + blsy[h1]) + 6))) {
by[h2] = (bly[h1] + blsy[h1]) + 35;
bj[h2] = 0;
}
}
h1++;
}
if ((h4 == 0) and ((bd[h2] < 2) or (bd[h2] > 2))) {
by[h2] = by[h2] + 10;
}
}
}
h2++;
}
timer = ((bl[1] / 150) * 100) - 1;
if (timer > 100) {
timer = 100;
if (bd[1] == 100) {
timer = 0;
}
}
if (py < -135) {
py = -135;
}
if (py > 50) {
py = 50;
}
if (px < 5) {
px = 5;
}
if (px > 190) {
px = 190;
}
pace = pace + 1;
if (pace > 16) {
pace = 1;
}
if (i > 0) {
i = i - 1;
}
if (ptime > 0) {
ptime = ptime - 1;
}
timer = timer + 1;
if (timer > 120) {
timer = 1;
}
camx = 100;
camy = -50;
if ((((pace == 1) or (pace == 5)) or (pace == 9)) or (pace == 13)) {
sx = -100;
sy = 100;
if (((pd > 3) and (pd < 6)) or ((pd > 7) and (pd < 10))) {
sx = px;
sy = py;
}
}
if ((charge < 15) or (xz == 1)) {
bustercharge._x = -500;
bustercharge._y = -500;
bustercharge._alpha = 0;
}
if (xz == 0) {
if ((charge > 14) and (charge < 40)) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 40;
}
if (charge > 39) {
bustercharge._x = 100 + (px - camx);
bustercharge._y = 100 + (py - camy);
bustercharge._alpha = 100;
}
}
if (i == 0) {
pc._alpha = 100;
}
if (i > 0) {
pc._alpha = 70;
}
pc._x = 100 + (px - camx);
pc._y = 100 + (py - camy);
pc.gotoAndStop(pf);
shadow._x = 100 + (sx - camx);
shadow._y = 100 + (sy - camy);
shadow.gotoAndStop(pf);
pname.gotoAndStop(xz + 1);
plb.gotoAndStop(pl);
bg1._x = 100 + (bx[1] - camx);
bg1._y = 100 + (by[1] - camy);
bg1.gotoAndStop(bf[1]);
bg2._x = 100 + (bx[2] - camx);
bg2._y = 100 + (by[2] - camy);
bg2.gotoAndStop(bf[2]);
bg3._x = 100 + (bx[3] - camx);
bg3._y = 100 + (by[3] - camy);
bg3.gotoAndStop(bf[3]);
bg4._x = 100 + (bx[4] - camx);
bg4._y = 100 + (by[4] - camy);
bg4.gotoAndStop(bf[4]);
bg5._x = 100 + (bx[5] - camx);
bg5._y = 100 + (by[5] - camy);
bg5.gotoAndStop(bf[5]);
bg6._x = 100 + (bx[6] - camx);
bg6._y = 100 + (by[6] - camy);
bg6.gotoAndStop(bf[6]);
bg7._x = 100 + (bx[7] - camx);
bg7._y = 100 + (by[7] - camy);
bg7.gotoAndStop(bf[7]);
bg8._x = 100 + (bx[8] - camx);
bg8._y = 100 + (by[8] - camy);
bg8.gotoAndStop(bf[8]);
bg9._x = 100 + (bx[9] - camx);
bg9._y = 100 + (by[9] - camy);
bg9.gotoAndStop(bf[9]);
bg10._x = 100 + (bx[10] - camx);
bg10._y = 100 + (by[10] - camy);
bg10.gotoAndStop(bf[10]);
pb1._x = 100 + (psx[1] - camx);
pb1._y = 100 + (psy[1] - camy);
pb1.gotoAndStop(psf[1]);
pb2._x = 100 + (psx[2] - camx);
pb2._y = 100 + (psy[2] - camy);
pb2.gotoAndStop(psf[2]);
pb3._x = 100 + (psx[3] - camx);
pb3._y = 100 + (psy[3] - camy);
pb3.gotoAndStop(psf[3]);
bs1._x = 100 + (bsx[1] - camx);
bs1._y = 100 + (bsy[1] - camy);
bs1.gotoAndStop(bsf[1]);
bs2._x = 100 + (bsx[2] - camx);
bs2._y = 100 + (bsy[2] - camy);
bs2.gotoAndStop(bsf[2]);
bs3._x = 100 + (bsx[3] - camx);
bs3._y = 100 + (bsy[3] - camy);
bs3.gotoAndStop(bsf[3]);
bs4._x = 100 + (bsx[4] - camx);
bs4._y = 100 + (bsy[4] - camy);
bs4.gotoAndStop(bsf[4]);
bs5._x = 100 + (bsx[5] - camx);
bs5._y = 100 + (bsy[5] - camy);
bs5.gotoAndStop(bsf[5]);
bs6._x = 100 + (bsx[6] - camx);
bs6._y = 100 + (bsy[6] - camy);
bs6.gotoAndStop(bsf[6]);
stage._x = 500 - camx;
stage._y = -150 - camy;
Frame 222
gotoAndPlay (221);
Frame 230
hero.gotoAndStop(xz + 1);
herodeath.start();
Frame 272
hero.gotoAndStop(xz + 4);
Frame 299
gotoAndPlay(cframe - 1);
Frame 304
herodeath.start();
Frame 355
stopAllSounds();
gotoAndPlay (3);
Frame 360
h1 = 1;
Frame 361
if ((((((((((((h1 == 27) or (h1 == 45)) or (h1 == 63)) or (h1 == 81)) or (h1 == 99)) or (h1 == 117)) or (h1 == 135)) or (h1 == 153)) or (h1 == 171)) or (h1 == 189)) or (h1 == 207)) or (h1 == 225)) {
shothit.start();
}
st1._x = st1._x - 10;
if (st1._x < -50) {
st1._x = 220 + random(20);
st1._y = 20 + random(160);
}
st2._x = st2._x - 10;
if (st2._x < -50) {
st2._x = 220 + random(20);
st2._y = 20 + random(160);
}
st3._x = st3._x - 10;
if (st3._x < -50) {
st3._x = 220 + random(20);
st3._y = 20 + random(160);
}
st4._x = st4._x - 10;
if (st4._x < -50) {
st4._x = 220 + random(20);
st4._y = 20 + random(160);
}
st5._x = st5._x - 15;
if (st5._x < -70) {
st5._x = 230 + random(20);
st5._y = 20 + random(160);
}
st6._x = st6._x - 15;
if (st6._x < -70) {
st6._x = 230 + random(20);
st6._y = 20 + random(160);
}
st7._x = st7._x - 15;
if (st7._x < -70) {
st7._x = 230 + random(20);
st7._y = 20 + random(160);
}
st8._x = st8._x - 20;
if (st8._x < -80) {
st8._x = 240 + random(20);
st8._y = 20 + random(160);
}
st9._x = st9._x - 20;
if (st9._x < -80) {
st9._x = 240 + random(20);
st9._y = 20 + random(160);
}
Frame 362
h1 = h1 + 1;
if (h1 < 246) {
gotoAndPlay (361);
}
Frame 363
st1._x = st1._x - 10;
if (st1._x < -50) {
st1._x = 220 + random(20);
st1._y = 20 + random(160);
}
st2._x = st2._x - 10;
if (st2._x < -50) {
st2._x = 220 + random(20);
st2._y = 20 + random(160);
}
st3._x = st3._x - 10;
if (st3._x < -50) {
st3._x = 220 + random(20);
st3._y = 20 + random(160);
}
st4._x = st4._x - 10;
if (st4._x < -50) {
st4._x = 220 + random(20);
st4._y = 20 + random(160);
}
st5._x = st5._x - 15;
if (st5._x < -70) {
st5._x = 230 + random(20);
st5._y = 20 + random(160);
}
st6._x = st6._x - 15;
if (st6._x < -70) {
st6._x = 230 + random(20);
st6._y = 20 + random(160);
}
st7._x = st7._x - 15;
if (st7._x < -70) {
st7._x = 230 + random(20);
st7._y = 20 + random(160);
}
st8._x = st8._x - 20;
if (st8._x < -80) {
st8._x = 240 + random(20);
st8._y = 20 + random(160);
}
st9._x = st9._x - 20;
if (st9._x < -80) {
st9._x = 240 + random(20);
st9._y = 20 + random(160);
}
Frame 364
gotoAndPlay (363);
Frame 371
gotoAndPlay (370);
Frame 373
gotoAndPlay (372);
Frame 375
gotoAndPlay (374);
Frame 377
gotoAndPlay (376);
Frame 379
gotoAndPlay (378);
Frame 381
gotoAndPlay (380);
Frame 383
gotoAndPlay (382);
Frame 385
gotoAndPlay (384);
Frame 387
gotoAndPlay (386);
Frame 389
gotoAndPlay (388);
Frame 391
gotoAndPlay (390);
Frame 393
gotoAndPlay (392);
Frame 395
gotoAndPlay (394);
Frame 397
gotoAndPlay (396);
Frame 399
gotoAndPlay (398);
Frame 401
gotoAndPlay (400);
Frame 403
gotoAndPlay (402);
Frame 411
gotoAndPlay (410);
Frame 413
gotoAndPlay (412);
Frame 415
gotoAndPlay (414);
Frame 421
gotoAndPlay (420);
Frame 423
gotoAndPlay (422);
Frame 425
gotoAndPlay (424);
Frame 427
gotoAndPlay (426);
Frame 429
gotoAndPlay (428);
Frame 431
gotoAndPlay (430);
Frame 433
gotoAndPlay (432);
Frame 435
gotoAndPlay (434);
Frame 437
gotoAndPlay (436);
Frame 451
gotoAndPlay (450);
Frame 453
gotoAndPlay (452);
Frame 455
gotoAndPlay (454);
Frame 457
gotoAndPlay (456);
Frame 459
gotoAndPlay (458);
Frame 461
gotoAndPlay (460);
Frame 463
gotoAndPlay (462);
Frame 465
gotoAndPlay (464);
Frame 467
gotoAndPlay (466);
Frame 469
gotoAndPlay (468);
Frame 471
gotoAndPlay (470);
Frame 473
gotoAndPlay (472);
Frame 475
gotoAndPlay (474);
Frame 477
gotoAndPlay (476);
Frame 479
gotoAndPlay (478);
Frame 481
gotoAndPlay (480);
Frame 483
gotoAndPlay (482);
Frame 485
gotoAndPlay (484);
Frame 487
gotoAndPlay (486);
Frame 489
gotoAndPlay (488);
Frame 491
gotoAndPlay (490);
Frame 493
gotoAndPlay (492);
Frame 495
gotoAndPlay (494);
Frame 497
gotoAndPlay (496);
Frame 499
gotoAndPlay (498);
Frame 501
gotoAndPlay (500);
Frame 503
gotoAndPlay (502);
Frame 505
gotoAndPlay (504);
Frame 507
gotoAndPlay (506);
Frame 509
gotoAndPlay (508);
Frame 515
kattack = Key.getCode();
Frame 516
gotoAndPlay (515);
Frame 517
kjump = Key.getCode();
Frame 518
gotoAndPlay (517);
Frame 519
kdash = Key.getCode();
Frame 520
gotoAndPlay (519);
Frame 521
kup = Key.getCode();
Frame 522
gotoAndPlay (521);
Frame 523
kdown = Key.getCode();
Frame 524
gotoAndPlay (523);
Frame 525
kright = Key.getCode();
Frame 526
gotoAndPlay (525);
Frame 527
kleft = Key.getCode();
Frame 528
gotoAndPlay (527);
Symbol 961 Button
on (release) {
boom2.start();
gotoAndPlay (370);
}
Symbol 965 Button
on (release) {
boom2.start();
getURL ("http://www.maelstormm.com/Games/MegamanXNext/mmxninstructions.htm", "_blank");
}
Symbol 969 Button
on (release) {
boom2.start();
getURL ("http://www.maelstormm.com/Games/MegamanXNext/mmxninformation.htm", "_blank");
}
Symbol 973 Button
on (release) {
boom2.start();
getURL ("http://www.maelstormm.com/Games/MegamanXNext/mmxnlinks.htm", "_blank");
}
Symbol 977 Button
on (release) {
boom2.start();
gotoAndPlay (515);
}
Symbol 984 Button
on (release) {
gotoAndPlay (372);
}
Symbol 986 Button
on (release) {
gotoAndPlay (374);
}
Symbol 988 Button
on (release) {
gotoAndPlay (376);
}
Symbol 990 Button
on (release) {
gotoAndPlay (378);
}
Symbol 992 Button
on (release) {
gotoAndPlay (380);
}
Symbol 994 Button
on (release) {
gotoAndPlay (382);
}
Symbol 999 Button
on (release) {
gotoAndPlay (384);
}
Symbol 1002 Button
on (release) {
gotoAndPlay (386);
}
Symbol 1006 Button
on (release) {
gotoAndPlay (388);
}
Symbol 1008 Button
on (release) {
gotoAndPlay (390);
}
Symbol 1013 Button
on (release) {
gotoAndPlay (392);
}
Symbol 1015 Button
on (release) {
gotoAndPlay (394);
}
Symbol 1017 Button
on (release) {
gotoAndPlay (396);
}
Symbol 1020 Button
on (release) {
gotoAndPlay (398);
}
Symbol 1022 Button
on (release) {
gotoAndPlay (400);
}
Symbol 1024 Button
on (release) {
gotoAndPlay (402);
}
Symbol 1026 Button
on (release) {
gotoAndPlay (5);
}
Symbol 1030 Button
on (release) {
gotoAndPlay (412);
}
Symbol 1033 Button
on (release) {
gotoAndPlay (414);
}
Symbol 1035 Button
on (release) {
gotoAndPlay (105);
}
Symbol 1039 Button
on (release) {
gotoAndPlay (422);
}
Symbol 1041 Button
on (release) {
gotoAndPlay (424);
}
Symbol 1043 Button
on (release) {
gotoAndPlay (426);
}
Symbol 1046 Button
on (release) {
gotoAndPlay (428);
}
Symbol 1048 Button
on (release) {
gotoAndPlay (430);
}
Symbol 1051 Button
on (release) {
gotoAndPlay (432);
}
Symbol 1053 Button
on (release) {
gotoAndPlay (434);
}
Symbol 1056 Button
on (release) {
gotoAndPlay (436);
}
Symbol 1058 Button
on (release) {
gotoAndPlay (115);
}
Symbol 1063 Button
on (release) {
gotoAndPlay (452);
}
Symbol 1065 Button
on (release) {
gotoAndPlay (454);
}
Symbol 1067 Button
on (release) {
gotoAndPlay (456);
}
Symbol 1072 Button
on (release) {
gotoAndPlay (458);
}
Symbol 1075 Button
on (release) {
gotoAndPlay (460);
}
Symbol 1077 Button
on (release) {
gotoAndPlay (462);
}
Symbol 1079 Button
on (release) {
gotoAndPlay (464);
}
Symbol 1081 Button
on (release) {
gotoAndPlay (466);
}
Symbol 1083 Button
on (release) {
gotoAndPlay (468);
}
Symbol 1085 Button
on (release) {
gotoAndPlay (470);
}
Symbol 1087 Button
on (release) {
gotoAndPlay (472);
}
Symbol 1089 Button
on (release) {
gotoAndPlay (474);
}
Symbol 1091 Button
on (release) {
gotoAndPlay (476);
}
Symbol 1095 Button
on (release) {
gotoAndPlay (478);
}
Symbol 1097 Button
on (release) {
gotoAndPlay (480);
}
Symbol 1101 Button
on (release) {
gotoAndPlay (482);
}
Symbol 1104 Button
on (release) {
gotoAndPlay (484);
}
Symbol 1106 Button
on (release) {
gotoAndPlay (486);
}
Symbol 1108 Button
on (release) {
gotoAndPlay (488);
}
Symbol 1113 Button
on (release) {
gotoAndPlay (490);
}
Symbol 1116 Button
on (release) {
gotoAndPlay (492);
}
Symbol 1118 Button
on (release) {
gotoAndPlay (494);
}
Symbol 1120 Button
on (release) {
gotoAndPlay (496);
}
Symbol 1122 Button
on (release) {
gotoAndPlay (498);
}
Symbol 1124 Button
on (release) {
gotoAndPlay (500);
}
Symbol 1126 Button
on (release) {
gotoAndPlay (502);
}
Symbol 1128 Button
on (release) {
gotoAndPlay (504);
}
Symbol 1130 Button
on (release) {
gotoAndPlay (506);
}
Symbol 1132 Button
on (release) {
gotoAndPlay (508);
}
Symbol 1134 Button
on (release) {
gotoAndPlay (3);
}
Symbol 1136 Button
on (release) {
gotoAndPlay (517);
}
Symbol 1138 Button
on (release) {
gotoAndPlay (519);
}
Symbol 1140 Button
on (release) {
gotoAndPlay (521);
}
Symbol 1142 Button
on (release) {
gotoAndPlay (523);
}
Symbol 1144 Button
on (release) {
gotoAndPlay (525);
}
Symbol 1146 Button
on (release) {
gotoAndPlay (527);
}
Symbol 1148 Button
on (release) {
gotoAndPlay (363);
}