Frame 142
tellTarget ("bunny") {
gotoAndPlay ("dead");
};
Frame 183
tellTarget ("logo") {
gotoAndPlay (1);
};
tellTarget ("play") {
gotoAndPlay (1);
};
play();
Frame 200
play();
tellTarget ("_root.tank") {
gotoAndPlay ("go");
};
Frame 210
stop();
tellTarget ("tank") {
nextFrame();
};
Frame 275
gotoAndPlay (191);
Frame 278
bombWhistle_1 = new Sound(bonus);
bombWhistle_1.attachSound("bombWhistle");
bombWhistle_2 = new Sound(explosion);
bombWhistle_2.attachSound("bombWhistleC");
turrent_shot = new Sound(player_dead);
turrent_shot.attachSound("shot");
boom = new Sound(rabbit);
boom.attachSound("boom");
function resetGame() {
tank_speed = 2;
i = 0;
xmax = 610;
xmin = 40;
ymax = 440;
ymin = 40;
player_1_lives = 2;
player_2_lives = 2;
player_2_colour = random(4) + 1;
player_1_startx = 100;
player_1_starty = 100;
player_2_startx = 400;
player_2_starty = 300;
duplicateMovieClip ("player_score", "player_1_score", 9800);
duplicateMovieClip ("player_score", "player_2_score", 9801);
with (player_1_score) {
_x = 180;
_y = 497;
score = 0;
name = "tank 01";
}
with (player_2_score) {
_x = 470;
_y = 497;
score = 0;
name = "tank 02";
}
player_hits = 12;
player_1_health = 100;
player_2_health = 100;
health_per = 100 / player_hits;
alive_distance = 25;
duplicateMovieClip ("shot", "shot1", 9900);
duplicateMovieClip ("shot", "shot2", 9901);
shot1.num = 1;
shot2.num = 2;
duplicateMovieClip ("rabbit", "rabbit_1", 9100);
rabbit_1.num = 1;
rabbit_1.othernum = 2;
duplicateMovieClip ("rabbit_comp", "rabbit_2", 9101);
rabbit_2.num = 2;
rabbit_2.othernum = 1;
placeRabbit();
shield_player.gotoAndPlay(2);
rabbit_comp.gotoAndStop(1);
}
function get_pos() {
player_1_pos = rabbit_1.getBounds(_root);
player_2_pos = rabbit_2.getBounds(_root);
}
function removeExpl() {
while (i != 0) {
removeMovieClip("explosion" add i);
i--;
}
}
function removeMc() {
removeExpl();
removeMovieClip("bonus_car");
removeMovieClip("rabbit_1");
removeMovieClip("rabbit_2");
removeMovieClip("shot1");
removeMovieClip("shot2");
removeMovieClip("player_1_score");
removeMovieClip("player_2_score");
removeMovieClip("shield_1");
removeMovieClip("end_title");
gotoAndPlay (183);
}
function randomCar() {
bonus = "yes";
duplicateMovieClip ("bonus", "bonus_car", 9995);
tellTarget ("bonus_car") {
gotoAndPlay (2);
};
}
function hitBonus(num) {
Set(("player_" add num) add "_score.score", eval (("player_" add num) add "_score.score") + 500);
bonus_car.num = num;
tellTarget ("bonus_car") {
gotoAndPlay ("gotit");
};
}
function random_shield() {
shield = "yes";
duplicateMovieClip ("shield", "shield_1", 5000);
with (shield_1) {
_x = random(590) + 30;
_y = random(400) + 30;
}
}
function got_shield(num) {
shield = "no";
removeMovieClip("shield_1");
Set(("player_" add num) add "_health", eval (("player_" add num) add "_health") + (health_per * 3));
if (100 < eval (("player_" add num) add "_health")) {
Set(("player_" add num) add "_health", 100);
}
tellTarget (("_root.rabbit_" add num) add ".health_fade") {
gotoAndPlay (2);
};
}
function explode(num) {
if (num == 1) {
othernum = 2;
} else {
othernum = 1;
}
i = Number(i) + 1;
duplicateMovieClip ("explosion", "explosion" add i, i);
setProperty("explosion" add i, _x , eval (("shot" add num) add "._x"));
setProperty("explosion" add i, _y , eval (("shot" add num) add "._y"));
setProperty("explosion" add i, _rotation , random(360));
eval ("explosion" add i).gotoAndStop(random(4) + 1);
if (eval ("shot" add num).hitTest(("_root.rabbit_" add othernum) add ".turrent")) {
_root.hit(othernum, num, 2);
} else if (eval ("shot" add num).hitTest(("_root.rabbit_" add othernum) add ".hull")) {
_root.hit(othernum, num, 1);
} else if (eval ("explosion" add i).hitTest(("_root.rabbit_" add othernum) add ".hull")) {
_root.hit(othernum, num, 0.5);
} else if (eval ("explosion" add i).hitTest("_root.bonus_car.bonus")) {
hitBonus(num);
}
}
function hit(num, othernum, damage) {
boom.start(0, 1);
Set(("player_" add othernum) add "_score.score", eval (("player_" add othernum) add "_score.score") + int(damage * eval (("shot_" add othernum) add "_distance")));
Set(("player_" add num) add "_health", eval (("player_" add num) add "_health") - (health_per * damage));
if (eval (("player_" add num) add "_health") < 1) {
Set(("player_" add num) add "_health", 100);
tellTarget ((("player_" add num) add "_score") add ".tank_lives") {
gotoAndStop(_currentframe + 1);
};
Set(("player_" add num) add "_lives", eval (("player_" add num) add "_lives") - 1);
if (eval (("player_" add num) add "_lives") < 0) {
gotoAndStop (282);
} else {
tellTarget ("rabbit_" add num) {
gotoAndPlay ("dead");
};
tellTarget ("rabbit_" add othernum) {
gotoAndPlay ("win");
};
duplicateMovieClip ("player_dead", "player_dead_new", 9999);
player_dead_new.num = num;
player_dead_new.gotoAndPlay(2);
}
} else {
tellTarget (("_root.rabbit_" add num) add ".health_fade") {
gotoAndPlay (2);
};
}
}
function removeRabbits() {
removeMovieClip("rabbit_1");
removeMovieClip("rabbit_2");
}
function placeRabbit() {
removeMovieClip("player_dead_new");
with (rabbit_1) {
gotoAndPlay(2);
_x = player_1_startx;
_y = player_1_starty;
hull.gotoAndStop(player_1_colour);
turrent.gun_colour.gotoAndStop(player_1_colour);
turrent.gotoAndPlay(2);
}
with (rabbit_2) {
gotoAndPlay(2);
_x = player_2_startx;
_y = player_2_starty;
hull.gotoAndStop(player_2_colour);
turrent.gun_colour.gotoAndStop(player_2_colour);
turrent.gotoAndPlay(2);
}
}
resetGame();
stop();
Instance of Symbol 194 MovieClip "rabbit" in Frame 278
onClipEvent (load) {
visc = 0.3;
drag = 0;
}
Instance of Symbol 197 MovieClip "rabbit_comp" in Frame 278
onClipEvent (load) {
visc = 0.3;
drag = 0;
}
Instance of Symbol 214 MovieClip "shot" in Frame 278
onClipEvent (load) {
setProperty(this, _visible , false);
alive = 0;
xv = 0;
yv = 0;
}
onClipEvent (enterFrame) {
if (num ne "") {
if (0 < alive) {
alive--;
setProperty(this, _visible , true);
_x = (_x + xv);
_y = (_y + yv);
} else {
gotoAndStop (278);
setProperty(this, _visible , false);
}
}
}
Frame 282
removeRabbits();
duplicateMovieClip ("end", "end_title", 9995);
end._visible = 0;
end_title.final_score = "score: " add player_1_score.score;
if (player_1_lives < 0) {
end_title.outcome = "you lose";
winner_tank.hull.gotoAndStop(_root.player_2_colour);
winner_tank.turrent.gun_colour.gotoAndStop(_root.player_2_colour);
} else {
end_title.outcome = "you win";
winner_tank.hull.gotoAndStop(_root.player_1_colour);
winner_tank.turrent.gun_colour.gotoAndStop(_root.player_1_colour);
}
winner_tank.gotoAndPlay("win");
stop();
Symbol 11 Button
on (release) {
getURL ("http://www.hyro.com", "_blank");
}
Symbol 30 MovieClip Frame 30
stop();
Symbol 30 MovieClip Frame 32
stop();
Symbol 58 Button
on (release) {
_root.player_1_colour = 2;
tellTarget (_root) {
gotoAndPlay ("start");
};
}
Symbol 59 Button
on (release) {
_root.player_1_colour = 4;
tellTarget (_root) {
gotoAndPlay ("start");
};
}
Symbol 60 Button
on (release) {
_root.player_1_colour = 1;
tellTarget (_root) {
gotoAndPlay ("start");
};
}
Symbol 61 Button
on (release) {
_root.player_1_colour = 3;
tellTarget (_root) {
gotoAndPlay ("start");
};
}
Symbol 64 Button
on (release) {
_root.instructions.gotoAndPlay(2);
this.gotoAndStop(1);
_root.gotoAndStop("loop");
}
Symbol 65 MovieClip Frame 1
stop();
Symbol 65 MovieClip Frame 17
stop();
Symbol 92 MovieClip Frame 1
stop();
Symbol 92 MovieClip Frame 16
play();
tellTarget ("_root") {
gotoAndPlay ("boom");
};
Symbol 92 MovieClip Frame 22
gotoAndStop (1);
Symbol 110 MovieClip Frame 1
stop();
Symbol 110 MovieClip Frame 2
play();
Symbol 110 MovieClip Frame 12
stop();
Symbol 120 MovieClip Frame 1
stop();
Symbol 127 MovieClip Frame 1
stop();
Symbol 162 Button
on (release) {
_root.gotoAndPlay("loop");
_root.play.gotoAndPlay(2);
_root.logo.gotoAndPlay(2);
_parent.gotoAndStop(1);
}
Symbol 171 MovieClip Frame 1
stop();
Symbol 171 MovieClip Frame 21
stop();
Symbol 175 MovieClip Frame 1
stop();
Symbol 175 MovieClip Frame 2
txt.info = ("player " add num) add " is dead";
play();
Symbol 175 MovieClip Frame 67
_root.removeExpl();
_root.placeRabbit();
Symbol 177 MovieClip Frame 1
stop();
Symbol 177 MovieClip Frame 2
if (_root.shield ne "yes") {
num = random(400);
if (num == 7) {
_root.random_shield();
}
}
play();
Symbol 177 MovieClip Frame 3
gotoAndPlay (2);
Symbol 181 Button
on (release) {
_root.removeMc();
}
Symbol 185 MovieClip Frame 1
stop();
Symbol 186 MovieClip Frame 1
stop();
Symbol 187 MovieClip Frame 1
function shoot(distance) {
if (eval (("_root.shot" add num) add ".alive") == 0) {
eval ("_root.bombWhistle_" + num).start(0, 1);
_root.turrent_shot.start(0, 1);
tellTarget ("gun_colour.gun") {
gotoAndPlay (2);
};
Set(("_root.shot_" add _parent.num) add "_distance", distance);
with (eval ("_root.shot" add num)) {
gotoAndPlay(2);
xv = 15 * Math.sin((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
yv = -15 * Math.cos((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
alive = distance;
}
setProperty("_root.shot" add num, _x , _parent._x);
setProperty("_root.shot" add num, _y , _parent._y);
}
}
stop();
Symbol 187 MovieClip Frame 2
if (Key.isDown(39)) {
torque = 3;
} else if (Key.isDown(37)) {
torque = -3;
} else {
torque = 0;
}
AngAcceleration = torque - rtorque;
rtorque = 0.4 * AngVelocity;
AngVelocity = AngVelocity + AngAcceleration;
angle = angle + AngVelocity;
if (angle < 0) {
angle = angle + 360;
}
if (360 < angle) {
angle = angle - 360;
}
_rotation = angle;
play();
Symbol 187 MovieClip Frame 3
gotoAndPlay (2);
Symbol 190 MovieClip Frame 1
stop();
Symbol 191 MovieClip Frame 1
stop();
Symbol 191 MovieClip Frame 2
player_health.gotoAndStop(eval (("_root.player_" add _parent.num) add "_colour"));
setProperty("player_health.health_bar", _xscale , eval (("_root.player_" add _parent.num) add "_health"));
Symbol 192 MovieClip Frame 1
function shoot(distance) {
if (eval (("_root.shot" add num) add ".alive") == 0) {
eval ("_root.bombWhistle_" + num).start(0, 1);
_root.turrent_shot.start(0, 1);
tellTarget ("gun_colour.gun") {
gotoAndPlay (2);
};
Set(("_root.shot_" add _parent.num) add "_distance", distance);
with (eval ("_root.shot" add num)) {
gotoAndPlay(2);
xv = 15 * Math.sin((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
yv = -15 * Math.cos((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
alive = distance;
}
setProperty("_root.shot" add num, _x , _parent._x);
setProperty("_root.shot" add num, _y , _parent._y);
}
}
stop();
Symbol 192 MovieClip Frame 2
if (Key.isDown(39)) {
torque = 3;
} else if (Key.isDown(37)) {
torque = -3;
} else {
torque = 0;
}
AngAcceleration = torque - rtorque;
rtorque = 0.4 * AngVelocity;
AngVelocity = AngVelocity + AngAcceleration;
angle = angle + AngVelocity;
if (angle < 0) {
angle = angle + 360;
}
if (360 < angle) {
angle = angle - 360;
}
_rotation = angle;
play();
Symbol 192 MovieClip Frame 3
gotoAndPlay (2);
Symbol 193 MovieClip Frame 1
function shoot(distance) {
if (eval (("_root.shot" add num) add ".alive") == 0) {
eval ("_root.bombWhistle_" + num).start(0, 1);
_root.turrent_shot.start(0, 1);
tellTarget ("gun_colour.gun") {
gotoAndPlay (2);
};
Set(("_root.shot_" add _parent.num) add "_distance", distance);
with (eval ("_root.shot" add num)) {
gotoAndPlay(2);
xv = 15 * Math.sin((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
yv = -15 * Math.cos((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
alive = distance;
}
setProperty("_root.shot" add num, _x , _parent._x);
setProperty("_root.shot" add num, _y , _parent._y);
}
}
stop();
Symbol 193 MovieClip Frame 2
if (Key.isDown(39)) {
torque = 3;
} else if (Key.isDown(37)) {
torque = -3;
} else {
torque = 0;
}
AngAcceleration = torque - rtorque;
rtorque = 0.4 * AngVelocity;
AngVelocity = AngVelocity + AngAcceleration;
angle = angle + AngVelocity;
if (angle < 0) {
angle = angle + 360;
}
if (360 < angle) {
angle = angle - 360;
}
_rotation = angle;
play();
Symbol 193 MovieClip Frame 3
gotoAndPlay (2);
Symbol 194 MovieClip Frame 1
function clearVari() {
v = 0;
drag = 0;
xa = 0;
ya = 0;
xv = 0;
yv = 0;
}
if (num ne "") {
angle = 0;
xv = 0;
x = 0;
y = 0;
yv = 0;
xa = 0;
ya = 0;
v = 0;
hull.gotoAndStop(_root.player_1_colour);
turrent.gun_colour.gotoAndStop(_root.player_1_colour);
}
stop();
Symbol 194 MovieClip Frame 2
_root.get_pos();
if (this.hitTest(_root.shield_1)) {
_root.got_shield(num);
}
ycheck_1 = eval (("_root.player_" add othernum) add "_pos.yMin") - eval (("_root.player_" add num) add "_pos.yMax");
ycheck_2 = eval (("_root.player_" add num) add "_pos.yMin") - eval (("_root.player_" add othernum) add "_pos.yMax");
xcheck_1 = eval (("_root.player_" add num) add "_pos.xMin") - eval (("_root.player_" add othernum) add "_pos.xMax");
xcheck_2 = eval (("_root.player_" add othernum) add "_pos.xMin") - eval (("_root.player_" add num) add "_pos.xMax");
if (Key.isDown(87)) {
force = _root.tank_speed;
} else if (Key.isDown(83)) {
force = -_root.tank_speed;
} else {
force = 0;
}
if (Key.isDown(68)) {
torque = 3.2;
} else if (Key.isDown(65)) {
torque = -3.2;
} else {
torque = 0;
}
angle = angle + torque;
if (angle < 0) {
angle = angle + 360;
}
if (360 < angle) {
angle = angle - 360;
}
v = Math.sqrt((xv * xv) + (yv * yv));
drag = visc * v;
xa = ((drag * xv) * -1) + (force * Math.sin((Math.PI/180) * angle));
ya = ((drag * yv) * -1) - (force * Math.cos((Math.PI/180) * angle));
xv = xv + xa;
yv = yv + ya;
if (yv < 0) {
if (eval (("_root.player_" add othernum) add "_pos.yMax") < eval (("_root.player_" add num) add "_pos.yMin")) {
_y = (_y + yv);
} else if ((xcheck_1 < 0) && (0 < xcheck_2)) {
if (_root.ymin < _y) {
_y = (_y + yv);
}
} else if ((0 < xcheck_1) && (xcheck_2 < 0)) {
if (_root.ymin < _y) {
_y = (_y + yv);
}
} else if ((xcheck_1 < 0) && (xcheck_2 < 0)) {
if (eval (("_root.player_" add num) add "_pos.yMin") < eval (("_root.player_" add othernum) add "_pos.yMin")) {
if (_root.ymin < _y) {
_y = (_y + yv);
}
}
}
} else if (0 < yv) {
if (eval (("_root.player_" add num) add "_pos.yMax") < eval (("_root.player_" add othernum) add "_pos.yMin")) {
_y = (_y + yv);
} else if ((xcheck_1 < 0) && (0 < xcheck_2)) {
if (_y < _root.ymax) {
_y = (_y + yv);
}
} else if ((0 < xcheck_1) && (xcheck_2 < 0)) {
if (_y < _root.ymax) {
_y = (_y + yv);
}
} else if ((xcheck_1 < 0) && (xcheck_2 < 0)) {
if (eval (("_root.player_" add othernum) add "_pos.yMax") < eval (("_root.player_" add num) add "_pos.yMax")) {
if (_y < _root.ymax) {
_y = (_y + yv);
}
}
}
}
if (xv < 0) {
if (eval (("_root.player_" add othernum) add "_pos.xMax") < eval (("_root.player_" add num) add "_pos.xMin")) {
_x = (_x + xv);
} else if ((ycheck_1 < 0) && (0 < ycheck_2)) {
if (_root.xmin < _x) {
_x = (_x + xv);
}
} else if ((0 < ycheck_1) && (ycheck_2 < 0)) {
if (_root.xmin < _x) {
_x = (_x + xv);
}
} else if ((ycheck_1 < 0) && (ycheck_2 < 0)) {
if (eval (("_root.player_" add num) add "_pos.xMin") < eval (("_root.player_" add othernum) add "_pos.xMin")) {
if (_root.xmin < _x) {
_x = (_x + xv);
}
}
}
} else if (0 < xv) {
if (eval (("_root.player_" add num) add "_pos.xMax") < eval (("_root.player_" add othernum) add "_pos.xMin")) {
_x = (_x + xv);
} else if ((ycheck_1 < 0) && (0 < ycheck_2)) {
if (_x < _root.xmax) {
_x = (_x + xv);
}
} else if ((0 < ycheck_1) && (ycheck_2 < 0)) {
if (_x < _root.xmax) {
_x = (_x + xv);
}
} else if ((ycheck_1 < 0) && (ycheck_2 < 0)) {
if (eval (("_root.player_" add othernum) add "_pos.xMax") < eval (("_root.player_" add num) add "_pos.xMax")) {
if (_x < _root.xmax) {
_x = (_x + xv);
}
}
}
}
_rotation = angle;
setProperty("health_fade", _rotation , -angle);
play();
Instance of Symbol 192 MovieClip "turrent" in Symbol 194 MovieClip Frame 2
onClipEvent (load) {
angle = 0;
scale = 8;
xv = 0;
yv = 0;
xa = 0;
ya = 0;
}
onClipEvent (keyUp) {
if (Key.getCode() == 32) {
shoot(scale);
scale = 8;
}
}
onClipEvent (enterFrame) {
if (_parent.num ne "") {
if (Key.isDown(32)) {
num = 1;
if (0 < Number(num)) {
if (Number(scale) >= 40) {
} else {
scale = Number(scale) + Number(num);
}
}
}
}
}
Symbol 194 MovieClip Frame 3
gotoAndPlay (2);
Symbol 194 MovieClip Frame 4
turrent.gotoAndStop(1);
hull.gotoAndStop(_root.player_1_colour);
turrent.gun_colour.gotoAndStop(_root.player_1_colour);
clearVari();
Instance of Symbol 193 MovieClip "turrent" in Symbol 194 MovieClip Frame 4
onClipEvent (load) {
angle = 0;
xv = 0;
x = 0;
y = 0;
yv = 0;
xa = 0;
ya = 0;
v = 0;
scale = 8;
}
onClipEvent (keyUp) {
if (Key.getCode() == 32) {
shoot(scale);
scale = 8;
}
}
onClipEvent (enterFrame) {
if (Key.isDown(32)) {
num = 1;
if (0 < Number(num)) {
if (Number(scale) >= 40) {
num = 0;
} else {
scale = Number(scale) + Number(num);
}
}
}
}
Symbol 194 MovieClip Frame 16
stop();
Symbol 194 MovieClip Frame 27
hull.gotoAndStop(_root.player_1_colour);
turrent.gun_colour.gotoAndStop(_root.player_1_colour);
clearVari();
Symbol 194 MovieClip Frame 38
gotoAndPlay (27);
Symbol 195 MovieClip Frame 1
function shoot(distance) {
if (eval (("_root.shot" add num) add ".alive") == 0) {
_root.turrent_shot.start(0, 1);
eval ("_root.bombWhistle_" + num).start(0, 1);
tellTarget ("gun_colour.gun") {
gotoAndPlay (2);
};
Set(("_root.shot_" add _parent.num) add "_distance", distance);
with (eval ("_root.shot" add num)) {
gotoAndPlay(2);
xv = 15 * Math.sin((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
yv = -15 * Math.cos((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
alive = distance;
}
setProperty("_root.shot" add num, _x , _parent._x);
setProperty("_root.shot" add num, _y , _parent._y);
}
}
stop();
Symbol 195 MovieClip Frame 2
mouse_x = int(_root.rabbit_1._x - _parent._x);
mouse_y = int(_root.rabbit_1._y - _parent._y);
if ((0 < mouse_x) && (0 < mouse_y)) {
quad = 4;
}
if ((mouse_x < 0) && (0 < mouse_y)) {
quad = 1;
}
if ((mouse_x < 0) && (mouse_y < 0)) {
quad = 2;
}
if ((0 < mouse_x) && (mouse_y < 0)) {
quad = 3;
}
abs_x = Math.abs(mouse_x);
abs_y = Math.abs(mouse_y);
tg = abs_y / abs_x;
_root.maths = (Math.atan(tg) * Number(180)) / Math.PI;
if (quad == 1) {
angle = Number(90) - Number(_root.maths);
}
if (quad == 2) {
angle = Number(90) + Number(_root.maths);
}
if (quad == 3) {
angle = Number(270) - Number(_root.maths);
}
if (quad == 4) {
angle = Number(270) + Number(_root.maths);
}
angle = angle - _parent.angle;
angle = angle - 180;
_rotation = angle;
play();
Symbol 195 MovieClip Frame 3
gotoAndPlay (2);
Symbol 196 MovieClip Frame 1
function shoot(distance) {
if (eval (("_root.shot" add num) add ".alive") == 0) {
eval ("_root.bombWhistle_" + num).start(0, 1);
_root.turrent_shot.start(0, 1);
tellTarget ("gun_colour.gun") {
gotoAndPlay (2);
};
Set(("_root.shot_" add _parent.num) add "_distance", distance);
with (eval ("_root.shot" add num)) {
gotoAndPlay(2);
xv = 15 * Math.sin((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
yv = -15 * Math.cos((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
alive = distance;
}
setProperty("_root.shot" add num, _x , _parent._x);
setProperty("_root.shot" add num, _y , _parent._y);
}
}
stop();
Symbol 196 MovieClip Frame 2
if (Key.isDown(39)) {
torque = 3;
} else if (Key.isDown(37)) {
torque = -3;
} else {
torque = 0;
}
AngAcceleration = torque - rtorque;
rtorque = 0.4 * AngVelocity;
AngVelocity = AngVelocity + AngAcceleration;
angle = angle + AngVelocity;
if (angle < 0) {
angle = angle + 360;
}
if (360 < angle) {
angle = angle - 360;
}
_rotation = angle;
play();
Symbol 196 MovieClip Frame 3
gotoAndPlay (2);
Symbol 197 MovieClip Frame 1
function find_ran_angle() {
future_angle = random(360);
if (_root.bonus eq "no") {
var num = random(500);
if (num < 10) {
_root.randomCar();
}
}
}
function clearVari() {
v = 0;
drag = 0;
xa = 0;
ya = 0;
xv = 0;
yv = 0;
}
function reverse() {
force = -force;
var num = random(20);
if (10 < num) {
find_ran_angle();
}
}
function change() {
var num = random(1000);
if (num < 30) {
find_ran_angle();
random_t();
random_f();
}
}
function shoot() {
var num = random(800);
if (num < 30) {
var a = (_root.rabbit_1._x - _x);
var b = (_root.rabbit_1._y - _y);
var c = Math.sqrt((a * a) + (b * b));
if (c < 150) {
turrent.shoot(random(8) + 8);
} else if (c < 300) {
turrent.shoot(random(15) + 8);
} else if (c < 600) {
turrent.shoot(random(20) + 8);
} else {
turrent.shoot(random(35) + 8);
}
}
}
function random_t() {
var num = random(2);
if (num == 1) {
torque = 2;
} else {
torque = -2;
}
}
function random_f() {
var num = random(2);
if (num == 1) {
force = 2;
} else {
force = -2;
}
}
angle = 0;
xv = 0;
x = 0;
y = 0;
yv = 0;
xa = 0;
ya = 0;
v = 0;
find_ran_angle();
random_t();
random_f();
hull.gotoAndStop(eval (("_root.player_" add num) add "_colour"));
turrent.gun_colour.gotoAndStop(eval (("_root.player_" add num) add "_colour"));
stop();
Instance of Symbol 195 MovieClip "turrent" in Symbol 197 MovieClip Frame 1
onClipEvent (load) {
angle = 0;
num = 2;
xv = 0;
yv = 0;
xa = 0;
ya = 0;
scale = 8;
}
Symbol 197 MovieClip Frame 2
change();
shoot();
if (this.hitTest(_root.shield_1)) {
_root.got_shield(num);
}
ycheck_1 = eval (("_root.player_" add othernum) add "_pos.yMin") - eval (("_root.player_" add num) add "_pos.yMax");
ycheck_2 = eval (("_root.player_" add num) add "_pos.yMin") - eval (("_root.player_" add othernum) add "_pos.yMax");
xcheck_1 = eval (("_root.player_" add num) add "_pos.xMin") - eval (("_root.player_" add othernum) add "_pos.xMax");
xcheck_2 = eval (("_root.player_" add othernum) add "_pos.xMin") - eval (("_root.player_" add num) add "_pos.xMax");
if (angle != future_angle) {
if (angle < future_angle) {
if ((future_angle - angle) < 3) {
torque = 0;
}
} else if (future_angle < angle) {
if ((angle - future_angle) < 3) {
torque = 0;
}
}
} else {
torque = 0;
}
angle = angle + torque;
if (angle < 0) {
angle = angle + 360;
}
if (360 < angle) {
angle = angle - 360;
}
v = Math.sqrt((xv * xv) + (yv * yv));
drag = visc * v;
xa = ((drag * xv) * -1) + (force * Math.sin((Math.PI/180) * angle));
ya = ((drag * yv) * -1) - (force * Math.cos((Math.PI/180) * angle));
xv = xv + xa;
yv = yv + ya;
if (yv < 0) {
if (eval (("_root.player_" add othernum) add "_pos.yMax") < eval (("_root.player_" add num) add "_pos.yMin")) {
_y = (_y + yv);
} else if ((xcheck_1 < 0) && (0 < xcheck_2)) {
if (_root.ymin < _y) {
_y = (_y + yv);
} else {
reverse();
}
} else if ((0 < xcheck_1) && (xcheck_2 < 0)) {
if (_root.ymin < _y) {
_y = (_y + yv);
} else {
reverse();
}
} else if ((xcheck_1 < 0) && (xcheck_2 < 0)) {
if (eval (("_root.player_" add num) add "_pos.yMin") < eval (("_root.player_" add othernum) add "_pos.yMin")) {
if (_root.ymin < _y) {
_y = (_y + yv);
} else {
reverse();
}
}
}
} else if (0 < yv) {
if (eval (("_root.player_" add num) add "_pos.yMax") < eval (("_root.player_" add othernum) add "_pos.yMin")) {
_y = (_y + yv);
} else if ((xcheck_1 < 0) && (0 < xcheck_2)) {
if (_y < _root.ymax) {
_y = (_y + yv);
} else {
reverse();
}
} else if ((0 < xcheck_1) && (xcheck_2 < 0)) {
if (_y < _root.ymax) {
_y = (_y + yv);
} else {
reverse();
}
} else if ((xcheck_1 < 0) && (xcheck_2 < 0)) {
if (eval (("_root.player_" add othernum) add "_pos.yMax") < eval (("_root.player_" add num) add "_pos.yMax")) {
if (_y < _root.ymax) {
_y = (_y + yv);
} else {
reverse();
}
}
}
}
if (xv < 0) {
if (eval (("_root.player_" add othernum) add "_pos.xMax") < eval (("_root.player_" add num) add "_pos.xMin")) {
_x = (_x + xv);
} else if ((ycheck_1 < 0) && (0 < ycheck_2)) {
if (_root.xmin < _x) {
_x = (_x + xv);
} else {
reverse();
}
} else if ((0 < ycheck_1) && (ycheck_2 < 0)) {
if (_root.xmin < _x) {
_x = (_x + xv);
} else {
reverse();
}
} else if ((ycheck_1 < 0) && (ycheck_2 < 0)) {
if (eval (("_root.player_" add num) add "_pos.xMin") < eval (("_root.player_" add othernum) add "_pos.xMin")) {
if (_root.xmin < _x) {
_x = (_x + xv);
} else {
reverse();
}
}
}
} else if (0 < xv) {
if (eval (("_root.player_" add num) add "_pos.xMax") < eval (("_root.player_" add othernum) add "_pos.xMin")) {
_x = (_x + xv);
} else if ((ycheck_1 < 0) && (0 < ycheck_2)) {
if (_x < _root.xmax) {
_x = (_x + xv);
} else {
reverse();
}
} else if ((0 < ycheck_1) && (ycheck_2 < 0)) {
if (_x < _root.xmax) {
_x = (_x + xv);
} else {
reverse();
}
} else if ((ycheck_1 < 0) && (ycheck_2 < 0)) {
if (eval (("_root.player_" add othernum) add "_pos.xMax") < eval (("_root.player_" add num) add "_pos.xMax")) {
if (_x < _root.xmax) {
_x = (_x + xv);
} else {
reverse();
}
}
}
}
setProperty("health_fade", _rotation , -angle);
_rotation = angle;
play();
Symbol 197 MovieClip Frame 3
gotoAndPlay (2);
Symbol 197 MovieClip Frame 4
turrent.gotoAndStop(1);
hull.gotoAndStop(eval (("_root.player_" add num) add "_colour"));
turrent.gun_colour.gotoAndStop(eval (("_root.player_" add num) add "_colour"));
clearVari();
Instance of Symbol 196 MovieClip "turrent" in Symbol 197 MovieClip Frame 4
onClipEvent (load) {
angle = 0;
xv = 0;
x = 0;
y = 0;
yv = 0;
xa = 0;
ya = 0;
v = 0;
scale = 8;
}
Symbol 197 MovieClip Frame 16
stop();
Symbol 197 MovieClip Frame 25
hull.gotoAndStop(eval (("_root.player_" add num) add "_colour"));
turrent.gun_colour.gotoAndStop(eval (("_root.player_" add num) add "_colour"));
clearVari();
Instance of Symbol 195 MovieClip "turrent" in Symbol 197 MovieClip Frame 25
onClipEvent (load) {
angle = 0;
num = 2;
xv = 0;
yv = 0;
xa = 0;
ya = 0;
scale = 8;
}
Symbol 197 MovieClip Frame 36
gotoAndPlay (25);
Symbol 213 MovieClip Frame 1
_root.bonus = "no";
stop();
Symbol 213 MovieClip Frame 2
play();
Symbol 213 MovieClip Frame 145
gotoAndPlay (172);
Symbol 213 MovieClip Frame 146
info = ("player " add num) add " score + 500";
play();
Symbol 213 MovieClip Frame 171
gotoAndStop (1);
Symbol 213 MovieClip Frame 172
play();
Symbol 214 MovieClip Frame 1
stop();
Symbol 214 MovieClip Frame 2
if (alive >= (eval (("_root.shot_" add num) add "_distance") / 2)) {
scale = 100 * (eval (("_root.shot_" add num) add "_distance") - alive);
} else if (alive < (eval (("_root.shot_" add num) add "_distance") / 2)) {
scale = 100 * alive;
}
eval ("_root.bombWhistle_" + num).setVolume((scale / 10) - 10);
setProperty(this, _xscale , scale);
setProperty(this, _yscale , scale);
if (1 >= alive) {
eval ("_root.bombWhistle_" + num).stop();
_root.explode(num);
gotoAndStop (1);
}
Symbol 214 MovieClip Frame 3
gotoAndPlay (2);
Symbol 216 MovieClip Frame 5
stop();
Symbol 220 MovieClip Frame 1
stop();
Symbol 227 Button
on (release) {
_root.removeMc();
}
Symbol 230 MovieClip Frame 1
function shoot(distance) {
if (eval (("_root.shot" add num) add ".alive") == 0) {
_root.turrent_shot.start(0, 1);
eval ("_root.bombWhistle_" + num).start(0, 1);
tellTarget ("gun_colour.gun") {
gotoAndPlay (2);
};
Set(("_root.shot_" add _parent.num) add "_distance", distance);
with (eval ("_root.shot" add num)) {
gotoAndPlay(2);
xv = 15 * Math.sin((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
yv = -15 * Math.cos((Math.PI/180) * (this.angle + eval (("_root.rabbit_" add num) add ".angle")));
alive = distance;
}
setProperty("_root.shot" add num, _x , _parent._x);
setProperty("_root.shot" add num, _y , _parent._y);
}
}
stop();
Symbol 230 MovieClip Frame 2
mouse_x = int(_root.rabbit_1._x - _parent._x);
mouse_y = int(_root.rabbit_1._y - _parent._y);
if ((0 < mouse_x) && (0 < mouse_y)) {
quad = 4;
}
if ((mouse_x < 0) && (0 < mouse_y)) {
quad = 1;
}
if ((mouse_x < 0) && (mouse_y < 0)) {
quad = 2;
}
if ((0 < mouse_x) && (mouse_y < 0)) {
quad = 3;
}
abs_x = Math.abs(mouse_x);
abs_y = Math.abs(mouse_y);
tg = abs_y / abs_x;
_root.maths = (Math.atan(tg) * Number(180)) / Math.PI;
if (quad == 1) {
angle = Number(90) - Number(_root.maths);
}
if (quad == 2) {
angle = Number(90) + Number(_root.maths);
}
if (quad == 3) {
angle = Number(270) - Number(_root.maths);
}
if (quad == 4) {
angle = Number(270) + Number(_root.maths);
}
angle = angle - _parent.angle;
angle = angle - 180;
_rotation = angle;
play();
Symbol 230 MovieClip Frame 3
gotoAndPlay (2);
Symbol 231 MovieClip Frame 1
stop();
Symbol 231 MovieClip Frame 4
play();
Symbol 231 MovieClip Frame 15
gotoAndPlay (4);