Frame 1
cash = 500;
stop();
debt = 0;
Frame 5
j = false;
if (cash < 0) {
gotoAndPlay (16);
}
if (cash > 0) {
if (debt > 0) {
dc = dc + 1;
if (dc > 4) {
cash = cash - debt;
debt = 0;
dc = 0;
}
}
}
stop();
if (cash <= 0) {
gotoAndPlay (15);
}
if (cash > 0) {
worm1s = random(4) + 5;
if (worm1s < 6) {
chance1 = "very bad";
double1 = 4;
}
if ((worm1s > 5) and (worm1s < 7)) {
b = random(2);
worm1s = worm1s + b;
chance1 = "bad";
double1 = 3;
}
if ((worm1s > 6) and (worm1s < 8)) {
chance1 = "good";
double1 = 2;
}
if (worm1s > 7) {
b = random(2);
worm1s = worm1s - b;
chance1 = "very good";
double1 = 1.25;
}
worm2s = random(4) + 5;
if (worm2s < 6) {
chance2 = "very bad";
double2 = 4;
}
if ((worm2s > 5) and (worm2s < 7)) {
b = random(2);
worm2s = worm2s + b;
chance2 = "bad";
double2 = 3;
}
if ((worm2s > 6) and (worm2s < 8)) {
chance2 = "good";
double2 = 2;
}
if (worm2s > 7) {
b = random(2);
worm2s = worm2s - b;
chance2 = "very good";
double2 = 1.25;
}
worm3s = random(4) + 5;
if (worm3s < 6) {
chance3 = "very bad";
double3 = 4;
}
if ((worm3s > 5) and (worm3s < 7)) {
b = random(2);
worm3s = worm3s + b;
chance3 = "bad";
double3 = 3;
}
if ((worm3s > 6) and (worm3s < 8)) {
chance3 = "good";
double3 = 2;
}
if (worm3s > 7) {
b = random(2);
worm1s = worm1s - b;
chance3 = "very good";
double3 = 1.25;
}
worm4s = random(4) + 5;
if (worm4s < 6) {
chance4 = "very bad";
double4 = 4;
}
if ((worm4s > 5) and (worm4s < 7)) {
b = random(2);
worm4s = worm4s + b;
chance4 = "bad";
double4 = 3;
}
if ((worm4s > 6) and (worm4s < 8)) {
chance4 = "good";
double4 = 2;
}
if (worm4s > 7) {
b = random(2);
worm1s = worm1s - b;
chance4 = "very good";
double4 = 1.25;
}
}
s = 0;
Frame 6
stop();
Frame 7
if (s < 2) {
worm1.onEnterFrame = function () {
with (worm1) {
i = random(4) - 2;
_x = _x + (random(worm1s) + i);
if (worm1.hittest(fend)) {
wwiner = 1;
s = 2;
}
}
};
}
worm2.onEnterFrame = function () {
with (worm2) {
i = random(4) - 2;
_x = _x + (random(worm2s) + i);
if (worm2.hittest(fend)) {
wwiner = 2;
s = 2;
}
}
};
worm3.onEnterFrame = function () {
with (worm3) {
i = random(4) - 2;
_x = _x + (random(worm3s) + i);
if (worm3.hittest(fend)) {
wwiner = 3;
s = 2;
}
}
};
worm4.onEnterFrame = function () {
with (worm4) {
i = random(4) - 2;
_x = _x + (random(worm4s) + i);
if (worm4.hittest(fend)) {
wwiner = 4;
s = 2;
}
}
};
if (s >= 2) {
if (wwiner == wbet) {
gotoAndPlay (9);
}
if (wwiner != wbet) {
gotoAndPlay (10);
}
}
Frame 8
gotoAndPlay (7);
Frame 9
stop();
wincash = bet * double;
cash = cash + wincash;
Frame 10
if (j) {
if (random(2) < 1) {
gotoAndPlay (9);
}
}
stop();
Frame 11
stop();
Frame 12
stop();
Frame 13
stop();
Frame 14
stop();
Frame 15
stop();
Symbol 4 Button
on (release) {
getURL ("http://www.synergyforums.com/forum/arcade_image.php", "_blank");
}
Symbol 8 Button
on (release) {
gotoAndPlay (5);
}
Symbol 12 MovieClip Frame 1
if (this.sessionstarted != 1) {
this.arcade = new LoadVars();
this.sessionvars = new LoadVars();
this.arcade.gamename = "wormrace";
this.arcade.sessdo = "sessionstart";
this.arcade.sendAndLoad("arcade.php", sessionvars, "POST");
if (this.sessionvars.sessiontype != 2) {
_root.is_a_challenge = 0;
} else {
_root.is_a_challenge = 1;
}
this.sessionstarted = 1;
}
if (_root.gameover == 1) {
if ((this.askpermission != 1) && (this.sessionvars.connStatus == 1)) {
this.prequestvars = new LoadVars();
this.pranswer = new LoadVars();
this.prequestvars.gametime = this.sessionvars.gametime;
this.prequestvars.fakekey = this.sessionvars.initbar;
_root.score = int(Number(_root.cash));
if (_root.score != 0) {
this.prequestvars.score = _root.score;
} else {
this.prequestvars.score = -1;
}
this.prequestvars.id = this.sessionvars.lastid;
this.prequestvars.sessdo = "permrequest";
this.prequestvars.note = (this.prequestvars.id * this.prequestvars.score) * this.prequestvars.fakekey;
this.prequestvars.sendAndLoad("./arcade.php", this.pranswer, "POST");
this.askpermission = 1;
}
if ((this.pranswer.validate == 1) && (this.finalsent != 1)) {
this.burnscore = new LoadVars();
this.burnscore.microone = this.pranswer.microone;
this.burnscore.gametime = this.prequestvars.gametime;
this.burnscore.id = this.prequestvars.id;
if (_root.score == 0) {
this.burnscore.noscore = 1;
}
this.burnscore.sessdo = "burn";
this.burnscore.send("./arcade.php", "_self", "POST");
this.finalsent = 1;
}
}
Symbol 14 Button
on (release) {
getURL ("http://www.synergyforums.com/forum/arcade_image.php", "_blank");
}
Symbol 20 Button
on (release) {
gotoAndPlay (5);
}
Symbol 24 Button
on (release) {
getURL ("http://www.synergyforums.com/forum/arcade_image.php", "_blank");
}
Symbol 26 Button
on (release) {
wbet = 1;
double = double1;
gotoAndPlay (6);
}
Symbol 30 Button
on (release) {
wbet = 2;
double = double2;
gotoAndPlay (6);
}
Symbol 33 Button
on (release) {
gotoAndPlay (5);
}
Symbol 34 Button
on (release) {
wbet = 3;
double = double3;
gotoAndPlay (6);
}
Symbol 38 Button
on (release) {
wbet = 4;
double = double4;
gotoAndPlay (6);
}
Symbol 46 Button
on (release) {
if ((cash - 50) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 50) >= 0) {
cash = cash - 50;
bet = 50;
}
gotoAndPlay (7);
}
Symbol 50 Button
on (release) {
wbet = 1;
double = double1;
gotoAndPlay (6);
}
Symbol 51 Button
on (release) {
if ((cash - 100) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 100) >= 0) {
cash = cash - 100;
bet = 100;
}
gotoAndPlay (7);
}
Symbol 54 Button
on (release) {
wbet = 2;
double = double2;
gotoAndPlay (6);
}
Symbol 55 Button
on (release) {
if ((cash - 200) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 200) >= 0) {
cash = cash - 200;
bet = 200;
}
gotoAndPlay (7);
}
Symbol 58 Button
on (release) {
gotoAndPlay (12);
}
Symbol 61 Button
on (release) {
wbet = 3;
double = double3;
gotoAndPlay (6);
}
Symbol 62 Button
on (release) {
if (debt < 1) {
gotoAndPlay (14);
}
}
Symbol 66 Button
on (release) {
wbet = 4;
double = double4;
gotoAndPlay (6);
}
Symbol 69 Button
on (release) {
if ((cash - 25) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 25) >= 0) {
cash = cash - 25;
bet = 25;
}
gotoAndPlay (7);
}
Symbol 75 Button
on (release) {
if ((cash - 50) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 50) >= 0) {
cash = cash - 50;
bet = 50;
}
gotoAndPlay (7);
}
Symbol 81 Button
on (release) {
if ((cash - 100) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 100) >= 0) {
cash = cash - 100;
bet = 100;
}
gotoAndPlay (7);
}
Symbol 90 Button
on (release) {
if ((cash - 200) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 200) >= 0) {
cash = cash - 200;
bet = 200;
}
gotoAndPlay (7);
}
Symbol 93 Button
on (release) {
gotoAndPlay (12);
}
Symbol 94 Button
on (release) {
if (debt < 1) {
gotoAndPlay (14);
}
}
Symbol 95 Button
on (release) {
if ((cash - 25) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 25) >= 0) {
cash = cash - 25;
bet = 25;
}
gotoAndPlay (7);
}
Symbol 102 Button
on (release) {
_root.gameover = 1;
}
Symbol 107 Button
on (release) {
gotoAndPlay (5);
}
Symbol 112 Button
on (release) {
_root.gameover = 1;
}
Symbol 114 Button
on (release) {
_root.gameover = 1;
}
Symbol 116 Button
on (release) {
if ((cash - 50) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 50) >= 0) {
cash = cash - 50;
bet = 50;
}
gotoAndPlay (7);
}
Symbol 117 Button
on (release) {
if ((cash - 100) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 100) >= 0) {
cash = cash - 100;
bet = 100;
}
gotoAndPlay (7);
}
Symbol 118 Button
on (release) {
if ((cash - 200) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 200) >= 0) {
cash = cash - 200;
bet = 200;
}
gotoAndPlay (7);
}
Symbol 119 Button
on (release) {
_root.gameover = 1;
}
Symbol 122 Button
on (release) {
if ((cash - 25) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 25) >= 0) {
cash = cash - 25;
bet = 25;
}
gotoAndPlay (7);
}
Symbol 130 Button
on (release) {
if ((cash - 50) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 50) >= 0) {
cash = cash - 50;
bet = 50;
}
gotoAndPlay (7);
}
Symbol 131 Button
on (release) {
if (cash > 150) {
cash = cash - 150;
if (wbet < 2) {
worm1s = worm1s + 1;
}
if ((wbet > 1) and (wbet < 3)) {
worm2s = worm2s + 1;
}
if ((wbet > 2) and (wbet < 4)) {
worm3s = worm3s + 1;
}
if (wbet > 3) {
worm4s = worm4s + 1;
}
gotoAndPlay (11);
}
}
Symbol 136 Button
on (release) {
if ((cash - 100) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 100) >= 0) {
cash = cash - 100;
bet = 100;
}
gotoAndPlay (7);
}
Symbol 138 Button
on (release) {
if ((cash - 200) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 200) >= 0) {
cash = cash - 200;
bet = 200;
}
gotoAndPlay (7);
}
Symbol 139 Button
on (release) {
if (cash > 350) {
cash = cash - 350;
J = true;
gotoAndPlay (11);
}
}
Symbol 144 Button
on (release) {
if (cash > 100) {
cash = cash - 100;
gotoAndPlay (13);
}
}
Symbol 149 Button
on (release) {
if ((cash - 25) < 0) {
bet = cash;
cash = 0;
}
if ((cash - 25) >= 0) {
cash = cash - 25;
bet = 25;
}
gotoAndPlay (7);
}
Symbol 150 Button
on (release) {
gotoAndPlay (6);
}
Symbol 155 Button
on (release) {
if (cash > 150) {
cash = cash - 150;
if (wbet < 2) {
worm1s = worm1s + 1;
}
if ((wbet > 1) and (wbet < 3)) {
worm2s = worm2s + 1;
}
if ((wbet > 2) and (wbet < 4)) {
worm3s = worm3s + 1;
}
if (wbet > 3) {
worm4s = worm4s + 1;
}
gotoAndPlay (11);
}
}
Symbol 157 Button
on (release) {
worm1s = worm1s - 1;
gotoAndPlay (11);
}
Symbol 159 Button
on (release) {
worm2s = worm2s - 1;
gotoAndPlay (11);
}
Symbol 160 Button
on (release) {
if (cash > 350) {
cash = cash - 350;
J = true;
gotoAndPlay (11);
}
}
Symbol 161 Button
on (release) {
worm3s = worm3s - 1;
gotoAndPlay (11);
}
Symbol 164 Button
on (release) {
worm4s = worm4s - 1;
gotoAndPlay (11);
}
Symbol 166 Button
on (release) {
if (cash > 100) {
cash = cash - 100;
gotoAndPlay (13);
}
}
Symbol 167 Button
on (release) {
gotoAndPlay (6);
}
Symbol 173 Button
on (release) {
worm1s = worm1s - 1;
gotoAndPlay (11);
}
Symbol 176 Button
on (release) {
worm2s = worm2s - 1;
gotoAndPlay (11);
}
Symbol 177 Button
on (release) {
gotoAndPlay (6);
}
Symbol 178 Button
on (release) {
worm3s = worm3s - 1;
gotoAndPlay (11);
}
Symbol 179 Button
on (release) {
debt = 150;
cash = cash + 100;
gotoAndPlay (11);
}
Symbol 183 Button
on (release) {
worm4s = worm4s - 1;
gotoAndPlay (11);
}
Symbol 184 Button
on (release) {
debt = 450;
cash = cash + 250;
gotoAndPlay (11);
}
Symbol 187 Button
on (release) {
debt = 1000;
cash = cash + 500;
gotoAndPlay (11);
}
Symbol 192 Button
on (release) {
gotoAndPlay (1);
}
Symbol 199 Button
on (release) {
gotoAndPlay (6);
}
Symbol 200 Button
on (release) {
debt = 150;
cash = cash + 100;
gotoAndPlay (11);
}
Symbol 201 Button
on (release) {
debt = 450;
cash = cash + 250;
gotoAndPlay (11);
}
Symbol 202 Button
on (release) {
debt = 1000;
cash = cash + 500;
gotoAndPlay (11);
}