Frame 1
function geturl() {
getURL ("http://www.basinhetveld.com/", _blank);
}
function geturl2() {
getURL ("http://www.newgrounds.com/", _blank);
}
function geturl3() {
getURL ("http://www.newgrounds.com/portal/view/228567", _blank);
}
function none() {
}
function goback() {
stopAllSounds();
for (a in _root) {
eval (_root.a).removeMovieClip("");
}
gotoAndPlay (2);
}
function qualitylow() {
_root._quality = "LOW";
}
function qualitymed() {
_root._quality = "MEDIUM";
}
function qualityhigh() {
_root._quality = "HIGH";
}
function soundup() {
_root.idcontroller_music.music.setVolume(_root.idcontroller_music.music.getVolume() + 10);
}
function sounddown() {
_root.idcontroller_music.music.setVolume(_root.idcontroller_music.music.getVolume() - 10);
}
function resetdata() {
_global.shootrange = 20;
_global.bulletdelay = 6;
_global.rocketdelay = 40;
_global.bombdelay = 60;
_global.adnr = 6;
_global.razorrotor = 0;
_global.maxhealth = 100;
_global.stunting = 0;
_global.clusters = 0;
_global.extralives = 0;
_global.bossnr = 1;
_global.XP = 0;
_global.XPpoints = 1;
_global.XPlevel = 1;
_global.XPneed = 1000;
savedata();
}
function savedata() {
_root.cookie.data.shootrange = _global.shootrange;
_root.cookie.data.bulletdelay = _global.bulletdelay;
_root.cookie.data.rocketdelay = _global.rocketdelay;
_root.cookie.data.bombdelay = _global.bombdelay;
_root.cookie.data.adnr = _global.adnr;
_root.cookie.data.razorrotor = _global.razorrotor;
_root.cookie.data.repair = _global.repair;
_root.cookie.data.maxhealth = _global.maxhealth;
_root.cookie.data.stunting = _global.stunting;
_root.cookie.data.clusters = _global.clusters;
_root.cookie.data.extralives = _global.extralives;
_root.cookie.data.bossnr = _global.bossnr;
_root.cookie.data.XP = _global.XP;
_root.cookie.data.XPpoints = _global.XPpoints;
_root.cookie.data.XPlevel = _global.XPlevel;
_root.cookie.data.XPneed = _global.XPneed;
}
function loaddata() {
_global.shootrange = _root.cookie.data.shootrange;
_global.bulletdelay = _root.cookie.data.bulletdelay;
_global.rocketdelay = _root.cookie.data.rocketdelay;
_global.bombdelay = _root.cookie.data.bombdelay;
_global.adnr = _root.cookie.data.adnr;
_global.razorrotor = _root.cookie.data.razorrotor;
_global.repair = _root.cookie.data.repair;
_global.maxhealth = _root.cookie.data.maxhealth;
_global.stunting = _root.cookie.data.stunting;
_global.clusters = _root.cookie.data.clusters;
_global.extralives = _root.cookie.data.extralives;
_global.bossnr = _root.cookie.data.bossnr;
_global.XP = _root.cookie.data.XP * 0.666666666666667;
_global.XPpoints = _root.cookie.data.XPpoints;
_global.XPlevel = _root.cookie.data.XPlevel;
_global.XPneed = _root.cookie.data.XPneed;
}
MENU = new ContextMenu();
MENU.hideBuiltInItems();
MENU.customItems.push(new ContextMenuItem("My site (dutch)", geturl));
MENU.customItems.push(new ContextMenuItem("Newgrounds", geturl2));
MENU.customItems.push(new ContextMenuItem("Watch Calderbank!", geturl3));
MENU.customItems.push(new ContextMenuItem("Main Menu", goback, true));
MENU.customItems.push(new ContextMenuItem("Set Quality:", none, true));
MENU.customItems.push(new ContextMenuItem("Low", qualitylow));
MENU.customItems.push(new ContextMenuItem("Medium (recommended)", qualitymed));
MENU.customItems.push(new ContextMenuItem("High (+ blurring)", qualityhigh));
MENU.customItems.push(new ContextMenuItem("Music ++", soundup, true));
MENU.customItems.push(new ContextMenuItem("Music --", sounddown));
_root.menu = MENU;
var cookie = SharedObject.getLocal("bv87plane");
if (cookie.data.shootrange == undefined) {
_root.txtmssg = "no data found, savegame created";
resetdata();
} else {
_root.txtmssg = "data found, progress has been loaded";
loaddata();
}
Frame 2
loaded = getBytesLoaded();
total = getBytesTotal();
percentdone = (loaded / total) * 100;
idloadtank._alpha = percentdone;
if (percentdone == 100) {
gotoAndStop (4);
}
Frame 3
gotoAndPlay (2);
Frame 37
for (a in this) {
eval (_root.a).gotoAndStop(1);
}
Frame 40
gotoAndPlay (37);
Frame 44
gotoAndPlay (42);
Frame 48
gotoAndPlay (45);
Frame 55
gotoAndPlay (58);
Frame 57
gotoAndPlay (56);
Frame 58
_root.attachMovie("idcontroller_ground", "idcontroller_ground", 12);
_root.attachMovie("idcontroller_music", "idcontroller_music", 13);
_root.attachMovie("idcontroller_level", "idcontroller_level", 14);
_root.attachMovie("idwantedbar", "idwantedbar", 27);
_root.attachMovie("idhealthbar", "idhealthbar", 39);
_root.attachMovie("idXPscreen", "idXPscreen", 40);
_root.attachMovie("idtextbox", "idtextbox", 45);
adrenalinebar = _root.attachMovie("idadrenaline_meter", "idadrenalinebar", 26);
_root.adrenalinebar._y = 30;
_root.idhealthbar._y = 30;
_root.idwantedbar._y = 30;
_root.idtextbox._y = 90;
_root.idXPscreen._y = 30;
_root.displaytext1 = "";
_root.displaytext2 = "";
_root.roomheight = 380;
h = (_root.roomheight - 16) - (Math.floor(Math.random() * 3) * 16);
_root.idcontroller_ground.startheight = h;
_root.attachMovie("idplayer_plane", "idplane", 100);
_root.idplane._x = 50;
_root.idplane._y = h;
Set("_root.idplane:shoot", 0);
if (_root.MP == 0) {
_root.idplane.pilot2._alpha = 0;
_root.idplane.p2gun._alpha = 0;
}
_root.Fz = 0.8;
_root.Fengine = 0;
_root.Fwings = 0;
_root.hspeed = 2;
_root.vspeed = 0;
_root.rotspeed = 0;
_root.bulletnr = 0;
_root.bulletshoot = 1;
_root.bulletspeed = 25;
_root.rocketnr = 0;
_root.rocket_shoot = 1;
_root.bomb_shoot = 1;
_root.adrenaline = 0;
_root.adrocket = 0;
_root.adbomb = 0;
_root.wantedlevel = 0;
_root.totalenemies = 0;
_root.totalcivs = 0;
_root.totalcivcars = 0;
_root.idplane.myhealth = _global.maxhealth;
_root.idplane.p2gun._rotation = 180;
_root.p2rocketshoot = _global.rocketdelay;
_root.p2bombshoot = _global.bombdelay;
_root.savecountdown = 50;
_global.lives = 10 + _global.extralives;
_root.displaytxt = "Welcome In Happy Cyclopsland!";
_root.sndengine = new Sound("_root.idplane");
_root.sndengine.attachSound("snd_engine");
_root.sndengine.start(0, 9999);
var mouseListener = new Object();
mouseListener.onMouseWheel = function (delta) {
nr = delta / Math.abs(delta);
if (nr == 1) {
_root.idplane.shoot2 = 1;
}
if (nr == -1) {
_root.idplane.shoot3 = 1;
}
};
Mouse.addListener(mouseListener);
getFPS = function () {
if (signal == true) {
time = getTimer();
} else {
tempo = int(1000 / (getTimer() - time));
}
signal = !signal;
return(tempo);
};
numcount = 0;
cumule = 0;
this.createEmptyMovieClip("fps", 41);
fps.onEnterFrame = function () {
numcount++;
currfps = getFPS();
};
var filter = (new flash.filters.BlurFilter(2, 2, 1));
var filterArray = new Array();
filterArray.push(filter);
var filter2 = (new flash.filters.BlurFilter(8, 8, 1));
var filterArray2 = new Array();
filterArray2.push(filter2);
onEnterFrame = function () {
if (Key.isDown(27)) {
stopAllSounds();
for (a in this) {
eval (_root.a).removeMovieClip("");
}
gotoAndPlay (2);
}
};
Frame 68
_root.savecountdown = _root.savecountdown - 1;
if (_root.savecountdown <= 0) {
_root.savecountdown = 50;
_root.savegame();
}
gotoAndPlay (59);
Symbol 12 MovieClip [c_head1] Frame 1
gotoAndStop(Math.floor((Math.random() * 3) + 1));
Symbol 15 MovieClip [c_mouth1] Frame 1
gotoAndStop (1);
onEnterFrame = function () {
if (this._parent.alive == 0) {
gotoAndStop (2);
}
};
Symbol 18 MovieClip [c_eye1] Frame 1
gotoAndStop (1);
onEnterFrame = function () {
if (this._parent.alive == 0) {
gotoAndStop (2);
}
};
Symbol 30 MovieClip [tank_NG] Frame 1
nr = Math.floor(Math.random() * 6) + 1;
arm1.gotoAndStop(nr);
arm2.gotoAndStop(nr);
Symbol 35 MovieClip Frame 1
onEnterFrame = function () {
distmouse = Math.sqrt(Math.pow(_root._xmouse - _x, 2) + Math.pow(_root._ymouse - _y, 2));
this._xscale = (0.01 * _root.percentdone) * distmouse;
this._yscale = (0.01 * _root.percentdone) * distmouse;
_rotation = (Math.atan2(_root._ymouse - _y, _root._xmouse - _x) * 57.2957795130823);
};
Symbol 35 MovieClip Frame 2
gotoAndPlay (1);
Symbol 43 MovieClip Frame 1
onEnterFrame = function () {
this._rotation = (_root.percentdone / 100) * 360;
};
Symbol 43 MovieClip Frame 2
gotoAndPlay (1);
Symbol 53 Button
on (release) {
_root.MP = 1;
gotoAndPlay (37);
}
Symbol 59 Button
on (release) {
_root.resetdata();
_root.txtmssg = "Data reset!";
}
Symbol 65 MovieClip [idcontroller_ground] Frame 1
startheight2 = startheight;
currentfirst = 1;
civmax = 8;
enemynr = 28;
maxenemies = 10;
createtimer = 250;
i = -1;
while (i <= 1) {
i = i + 1;
_root.attachMovie("id_ground2", "groundnr" + (i + 1), i + 1);
Set(("../groundnr" + (i + 1)) + "._x", i * 100);
Set(("../groundnr" + (i + 1)) + "._y", startheight);
}
i = -1;
while (i <= 4) {
i = i + 1;
nr = Math.floor((Math.random() * 3) + 1);
while (((startheight >= (_root.roomheight - 16)) && (nr == 1)) or ((startheight <= (_root.roomheight - 96)) && (nr == 3))) {
nr = Math.floor((Math.random() * 3) + 1);
}
cnc = Math.floor(Math.random() * 5);
if (cnc != 0) {
nr = 2;
}
kindd = "id_ground" + nr;
_root.attachMovie(kindd, "groundnr" + (4 + i), i + 4);
Set(("../groundnr" + (4 + i)) + "._x", 300 + (i * 100));
Set(("../groundnr" + (4 + i)) + "._y", startheight);
if (nr == 1) {
startheight = startheight + 16;
}
if (nr == 3) {
startheight = startheight - 16;
}
call("randomstuff");
}
onEnterFrame = function () {
dif = 0;
if (_root.idplane._x >= 500) {
dif = Math.round(../idplane._x - 500);
}
if (_root.idplane._x <= 300) {
dif = Math.round(../idplane._x - 300);
}
for (a in _root) {
Set(("_root." + a) + "._x", eval (("_root." + a) + "._x") - dif);
}
_root.adrenalinebar._x = 170;
_root.idwantedbar._x = 400;
_root.idtextbox._x = 400;
_root.idhealthbar._x = 70;
_root.idXPscreen._x = 70;
_root.bgtree._x = 0;
_root.bgtree.hhspeed = dif / 20;
if (_root.groundnr1._x < -100) {
call("right");
}
if (_root.groundnr9._x > 800) {
call("left");
}
createtimer = createtimer - 1;
if (createtimer < 1) {
if (Math.floor(Math.random() * 2) == 0) {
side = "left";
} else {
side = "right";
}
createtimer = 25 * ((Math.random() * 5) + 3);
call("randomstuff");
}
};
Symbol 65 MovieClip [idcontroller_ground] Frame 3
gotoAndPlay (2);
Symbol 65 MovieClip [idcontroller_ground] Frame 4
removeMovieClip("_root.groundnr1");
nr = Math.floor((Math.random() * 3) + 1);
while (((startheight >= (_root.roomheight - 16)) && (nr == 1)) or ((startheight <= (_root.roomheight - 54)) && (nr == 3))) {
nr = Math.floor((Math.random() * 3) + 1);
}
cnc = Math.floor(Math.random() * 2);
if (cnc != 0) {
nr = 2;
}
kind1 = "id_ground" + nr;
_root.attachMovie(kind1, "groundnr10", 10);
Set("../groundnr10._x", _root.groundnr9._x + 100);
Set("../groundnr10._y", startheight);
if (nr == 1) {
startheight = startheight + 16;
}
if (nr == 3) {
startheight = startheight - 16;
}
i = 2;
while (i <= 10) {
eval ("_root.groundnr" + i).swapDepths(i - 1);
setProperty("_root.groundnr" + i, _name , "groundnr" + (i - 1));
i = i + 1;
}
side = "right";
call("randomstuff");
Symbol 65 MovieClip [idcontroller_ground] Frame 9
startheight = _root.groundnr9._y;
removeMovieClip("_root.groundnr9");
nr = Math.floor((Math.random() * 3) + 1);
startheight2 = _root.groundnr1._y;
while (((startheight2 >= (_root.roomheight - 16)) && (nr == 3)) or ((startheight2 <= (_root.roomheight - 48)) && (nr == 1))) {
nr = Math.floor((Math.random() * 3) + 1);
}
cnc = Math.floor(Math.random() * 2);
if (cnc != 0) {
nr = 2;
}
kind2 = "id_ground" + nr;
_root.attachMovie(kind2, "groundnr0", 0);
if (nr == 3) {
startheight2 = startheight2 + 16;
}
if (nr == 1) {
startheight2 = startheight2 - 16;
}
Set("../groundnr0._x", _root.groundnr1._x - 100);
Set("../groundnr0._y", startheight2);
i = 9;
while (i >= 0) {
eval ("_root.groundnr" + i).swapDepths(i + 1);
setProperty("_root.groundnr" + i, _name , "groundnr" + (i + 1));
i = i - 1;
}
side = "left";
call("randomstuff");
Symbol 65 MovieClip [idcontroller_ground] Frame 13
cnc = Math.floor(Math.random() * 8);
if ((cnc <= 3) && (_root.totalcivs < 10)) {
nr = 15;
while ((_root.getInstanceAtDepth(nr) != undefined) && (nr < 22)) {
nr = nr + 1;
}
if (_root.getInstanceAtDepth(nr) == undefined) {
_root.attachMovie("idcivilian", "civ" + nr, nr);
if (side == "right") {
Set(("_root.civ" + nr) + "._x", 850);
Set(("_root.civ" + nr) + "._y", startheight);
}
if (side == "left") {
Set(("_root.civ" + nr) + "._x", -50);
Set(("_root.civ" + nr) + "._y", startheight2);
}
if ((side != "left") and (side != "right")) {
Set(("_root.civ" + nr) + "._x", Math.random() * 800);
Set(("_root.civ" + nr) + "._y", startheight);
}
_root.totalcivs = _root.totalcivs + 1;
}
}
if ((cnc == 4) && (_root.totalcivcars < 3)) {
nr = 42;
while ((_root.getInstanceAtDepth(nr) != undefined) && (nr < 44)) {
nr = nr + 1;
}
if (_root.getInstanceAtDepth(nr) == undefined) {
_root.attachMovie("idcivcar", "civcar" + nr, nr);
if (side == "right") {
Set(("_root.civcar" + nr) + "._x", 850);
Set(("_root.civcar" + nr) + "._y", startheight);
}
if (side == "left") {
Set(("_root.civcar" + nr) + "._x", -50);
Set(("_root.civcar" + nr) + "._y", startheight2);
}
if ((side != "left") and (side != "right")) {
Set(("_root.civcar" + nr) + "._x", Math.random() * 800);
Set(("_root.civcar" + nr) + "._y", startheight);
}
_root.totalcivcars = _root.totalcivcars + 1;
}
}
if (_root.wantedlevel < 1000) {
maxenemies = Math.round(_root.wantedlevel / 100);
if ((cnc == 0) && (maxenemies > _root.totalenemies)) {
nr = 28;
while ((_root.getInstanceAtDepth(nr) != undefined) && (nr < 37)) {
nr = nr + 1;
}
cnc = Math.floor(Math.random() * maxenemies) + 1;
if (cnc <= 5) {
_root.attachMovie("idarmyjeep", "enemy" + nr, nr);
_root.totalenemies = _root.totalenemies + 1;
Set(("../enemy" + nr) + "._xscale", -100);
if ((Math.random() * 10) == 0) {
Set(("../enemy" + nr) + "._xscale", 100);
}
}
if (cnc >= 7) {
_root.attachMovie("idtank1", "enemy" + nr, nr);
_root.totalenemies = _root.totalenemies + 1;
}
if (side == "right") {
Set(("../enemy" + nr) + "._x", 900);
Set(("../enemy" + nr) + "._y", startheight);
} else {
Set(("../enemy" + nr) + "._x", -100);
Set(("../enemy" + nr) + "._y", startheight2);
}
}
}
Symbol 184 MovieClip [idexplosion_1] Frame 1
_rotation = (Math.random() * 360);
_xscale = scale;
_yscale = scale;
boomsound = new Sound(this);
nr = Math.floor((Math.random() * 3) + 1);
boomsound.attachSound("snd_boom" + nr);
this.boomsound.setVolume(scale);
boomsound.start();
if (_root._quality == "HIGH") {
this.filters = _root.filterArray;
}
onEnterFrame = function () {
if ((((_x < -50) or (_x > 850)) or (_y < -50)) or (_y > (_root.roomheight + 50))) {
removeMovieClip("");
}
if (this._currentframe < 5) {
i = 15;
while (i <= (14 + _root.totalcivs)) {
if (this.hitTest(eval ("_root.civ" + i))) {
xdif = eval ("_root.civ" + i)._x - this._x;
ydif = eval ("_root.civ" + i)._y - this._y;
eval ("_root.civ" + i).die = 2;
eval ("_root.civ" + i).hspeed = xdif / 5;
eval ("_root.civ" + i).vspeed = ydif / 5;
}
i = i + 1;
}
i = 42;
while (i <= (41 + _root.totalcivcars)) {
if (eval ("_root.civcar" + i).hitTest(_x, _y, false)) {
eval ("_root.civcar" + i).myhealth = eval ("_root.civcar" + i).myhealth - ((scale / 100) * 20);
}
i = i + 1;
}
i = 28;
while (i <= (27 + _root.totalenemies)) {
if (this.hitTest(eval ("_root.enemy" + i))) {
eval ("_root.enemy" + i).myhealth = eval ("_root.enemy" + i).myhealth - ((scale / 100) * 10);
}
i = i + 1;
}
}
};
Symbol 184 MovieClip [idexplosion_1] Frame 60
removeMovieClip("");
Symbol 200 MovieClip [idrotor] Frame 1
if (_global.razorrotor == 1) {
this.localToGlobal((p = {x:this._x, y:this._y}));
i = 15;
while (i <= (14 + _root.totalcivs)) {
if (eval ("_root.civ" + i).hitTest(p.x, p.y, false)) {
eval ("_root.civ" + i).die = 2;
eval ("_root.civ" + i).hspeed = eval ("_root.civ" + i).hspeed + (_root.hspeed / 2);
if (Math.floor(Math.random() * 10) == 0) {
ripsound = new Sound(this);
ripsound.attachSound("idcivrip1");
this.ripsound.setVolume(150);
ripsound.start();
eval ("_root.civ" + i).die = 3;
}
}
i = i + 1;
}
}
Symbol 200 MovieClip [idrotor] Frame 4
gotoAndPlay (1);
Symbol 205 MovieClip [idplayer_plane] Frame 1
p2gun.rotspeed = 0;
crashsnd = 0;
stunttimer = 0;
onEnterFrame = function () {
if (myhealth > 1) {
if ((Key.isDown(87) or Key.isDown(73)) && (_root.Fengine < 1.4)) {
_root.Fengine = _root.Fengine + 0.05;
}
if ((Key.isDown(83) or Key.isDown(75)) && (_root.Fengine > 0)) {
_root.Fengine = _root.Fengine - 0.05;
}
if (Key.isDown(65) or Key.isDown(74)) {
_root.rotspeed = _root.rotspeed - 0.8;
}
if (Key.isDown(68) or Key.isDown(76)) {
_root.rotspeed = _root.rotspeed + 0.8;
}
} else {
myhealth = 1;
_root.Fwings = 0;
_root.Fz = 0.8;
_root.Fengine = 0;
if (crashsnd == 0) {
crashsnd = 1;
crashsound = new Sound(this);
crashsound.attachSound("idplanecrashing");
crashsound.setVolume(150);
crashsound.start();
stunttimer = 5;
}
crashsound.setVolume(crashsound.getVolume() + 5);
if (_root.hspeed > 0) {
if (_rotation > 75) {
_root.rotspeed = _root.rotspeed - 0.2;
}
if (_rotation < 75) {
_root.rotspeed = _root.rotspeed + 0.2;
}
} else if ((_rotation < 165) && (_rotation > 0)) {
_root.rotspeed = _root.rotspeed + 0.2;
} else {
_root.rotspeed = _root.rotspeed - 0.2;
}
}
_root.Fengine = _root.Fengine * 0.98;
if (myhealth < 20) {
call("dying");
}
_root.rotspeed = _root.rotspeed * 0.9;
_rotation = (_rotation + _root.rotspeed);
if (_y < 0) {
_root.vspeed = _root.vspeed + 1;
}
if (myhealth > 1) {
_root.Fwings = ((_root.Fz + 0.05) * Math.abs(_root.hspeed)) * 0.15;
}
_root.hspeed = _root.hspeed + (_root.Fengine * Math.cos(_rotation * (Math.PI/180)));
_root.vspeed = _root.vspeed + (((_root.Fengine * Math.sin(_rotation * (Math.PI/180))) + _root.Fz) - _root.Fwings);
if (myhealth > 1) {
_root.hspeed = _root.hspeed * 0.85;
_root.vspeed = _root.vspeed * 0.85;
} else {
_root.hspeed = _root.hspeed * 0.95;
_root.vspeed = _root.vspeed * 0.95;
}
_x = (_x + _root.hspeed);
_y = (_y + _root.vspeed);
call("collcheck");
onMouseDown = function () {
shoot = 1;
};
onMouseUp = function () {
shoot = 0;
};
if (_root.MP == 0) {
call("1pshoot");
}
if (_root.MP == 1) {
call("2pshoot");
}
if (_root.rocket_shoot >= 1) {
_root.rocket_shoot = _root.rocket_shoot - 1;
}
if (_root.bomb_shoot >= 1) {
_root.bomb_shoot = _root.bomb_shoot - 1;
}
if ((Key.isDown(70) or Key.isDown(80)) && (_root.rocket_shoot == 0)) {
call("rocket1");
}
if ((Key.isDown(71) or Key.isDown(77)) && (_root.bomb_shoot == 0)) {
call("bomb1");
}
if (_global.stunting == 1) {
if (stunttimer >= 1) {
stunttimer = stunttimer - 1;
}
if (stunttimer <= 0) {
if (Key.isDown(81) or Key.isDown(85)) {
_root.rotspeed = _root.rotspeed - 20;
p2gun.rotspeed = p2gun.rotspeed + 50;
stunttimer = 50;
}
if (Key.isDown(69) or Key.isDown(79)) {
_root.rotspeed = _root.rotspeed + 20;
p2gun.rotspeed = p2gun.rotspeed - 50;
stunttimer = 50;
}
}
}
if (_root.adrocket >= 1) {
_root.adrocket = _root.adrocket - 0.25;
if ((Math.round(10 * _root.adrocket) / 10) == Math.round(_root.adrocket)) {
call("rocket1");
}
_root.adrenaline = 0;
}
if (_root.adbomb >= 1) {
_root.adbomb = _root.adbomb - 0.2;
if ((Math.round(10 * _root.adbomb) / 10) == Math.round(_root.adbomb)) {
call("bomb1");
}
_root.adrenaline = 0;
}
_root.sndengine.setVolume((30 + (150 * _root.Fengine)) + ((stunttimer / 50) * 200));
_root.sndengine.onSoundComplete = function () {
_root.sndengine.start();
};
};
Symbol 205 MovieClip [idplayer_plane] Frame 3
gotoAndPlay (2);
Symbol 205 MovieClip [idplayer_plane] Frame 4
snd = new Sound();
nr = Math.floor((Math.random() * 3) + 1);
snd.attachSound("snd_releasebomb" + nr);
snd.start();
_root.rocket_shoot = _global.rocketdelay;
_root.rocketnr = _root.rocketnr + 1;
if (_root.rocketnr >= 50) {
_root.rocketnr = 0;
}
_root.attachMovie("idrocket_1", "rocket" + _root.rocketnr, _root.getNextHighestDepth());
Set(("../rocket" + _root.rocketnr) + ":power", 2);
Set(("../rocket" + _root.rocketnr) + ":rotspeed", (Math.random(1) * 2) - 2);
Set(("../rocket" + _root.rocketnr) + ":hspeed", _root.hspeed + (1 * Math.cos((_rotation + 90) * (Math.PI/180))));
Set(("../rocket" + _root.rocketnr) + ":vspeed", _root.vspeed + (1 * Math.sin((_rotation + 90) * (Math.PI/180))));
Set(("../rocket" + _root.rocketnr) + ":life", 20 + (Math.random(1) * 10));
Set(("../rocket" + _root.rocketnr) + ":delay", Math.floor(30 - (Math.random() * 3)));
setProperty("../rocket" + _root.rocketnr, _rotation , _rotation);
setProperty("../rocket" + _root.rocketnr, _x , this._x + (10 * Math.cos((_rotation + 130) * (Math.PI/180))));
setProperty("../rocket" + _root.rocketnr, _y , this._y + (10 * Math.sin((_rotation + 130) * (Math.PI/180))));
if (_root.adrenaline == 100) {
_root.adrocket = _global.adnr;
_root.adrenaline = 0;
}
Symbol 205 MovieClip [idplayer_plane] Frame 9
_root.bulletshoot = _global.bulletdelay;
_root.bulletnr = _root.bulletnr + 1;
if (_root.bulletnr >= 100) {
_root.bulletnr = 0;
}
_root.attachMovie("idbullet", "bullet" + _root.bulletnr, _root.getNextHighestDepth());
Set(("../bullet" + _root.bulletnr) + ":speed", _root.bulletspeed + (Math.random(1) * 5));
setProperty("../bullet" + _root.bulletnr, _rotation , (mousedirec + (Math.random(1) * 4)) - 2);
setProperty("../bullet" + _root.bulletnr, _x , this._x + (15 * Math.cos(_rotation * (Math.PI/180))));
setProperty("../bullet" + _root.bulletnr, _y , this._y + (15 * Math.sin(_rotation * (Math.PI/180))));
Symbol 205 MovieClip [idplayer_plane] Frame 15
this.localToGlobal((p = {x:p2gun._x, y:p2gun._y}));
_root.bulletshoot = _global.bulletdelay;
_root.bulletnr = _root.bulletnr + 1;
if (_root.bulletnr >= 100) {
_root.bulletnr = 0;
}
_root.attachMovie("idbullet", "bullet" + _root.bulletnr, _root.getNextHighestDepth());
Set(("../bullet" + _root.bulletnr) + ":speed", _root.bulletspeed + (Math.random(1) * 5));
setProperty("../bullet" + _root.bulletnr, _rotation , ((_rotation + this.p2gun._rotation) + (Math.random(1) * 4)) - 2);
if (p2gun._yscale == 100) {
nr = 8;
} else {
nr = -8;
}
setProperty("../bullet" + _root.bulletnr, _x , p.x + (30 * Math.cos(((_rotation + this.p2gun._rotation) + nr) * (Math.PI/180))));
setProperty("../bullet" + _root.bulletnr, _y , p.y + (30 * Math.sin(((_rotation + this.p2gun._rotation) + nr) * (Math.PI/180))));
Symbol 205 MovieClip [idplayer_plane] Frame 20
_root.Fz = 0.8;
this.localToGlobal((p = {x:this.idrwheel._x, y:this.idrwheel._y}));
min = Math.floor(p.x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y + 1, true)) {
if (myhealth == 1) {
call("destroy");
}
_root.Fz = 0;
_rotation = (_rotation - 1);
j = 30;
while (eval ("_root.groundnr" + i).hitTest(p.x, p.y, true) and (j > 0)) {
p.y = p.y - 1;
_y = (_y - 1);
j = j - 1;
}
}
i = i + 1;
}
}
this.localToGlobal((p = {x:this.idlwheel._x, y:this.idlwheel._y}));
min = Math.floor(p.x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y, true)) {
if (myhealth == 1) {
call("destroy");
}
j = 15;
while (eval ("_root.groundnr" + i).hitTest(p.x, p.y, true) and (j > 0)) {
this.localToGlobal((p = {x:this.idlwheel._x, y:this.idlwheel._y}));
_rotation = (_rotation + 0.5);
_root.rotspeed = 0;
j = j - 1;
}
}
i = i + 1;
}
}
for (a in this.hitbox) {
this.hitbox.localToGlobal((p = {x:this.hitbox[a]._x, y:this.hitbox[a]._y}));
min = Math.floor(p.x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y, true)) {
_root.vspeed = (Math.random() * -5) - 5;
call("destroy");
}
i = i + 1;
}
}
}
Symbol 205 MovieClip [idplayer_plane] Frame 24
_root.displaytxt = "You died! Press space for a new plane!";
crashsound.stop();
i = 0;
while (i < 4) {
i = i + 1;
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , (this._x + (Math.random() * 80)) - 40);
setProperty("../explosion_1_" + expdepth, _y , (this._y + (Math.random() * 80)) - 40);
Set(("../explosion_1_" + expdepth) + ":scale", 70 + (Math.random() * 60));
}
_root.sndengine.stop("snd_engine");
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.pilot.head._x, y:this.pilot.head._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_head1", "head", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
eval (("_root.limb" + nr) + ".head").gotoAndStop(this.pilot.head._currentframe);
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.pilot.head._x, y:this.pilot.head._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_eye1", "eye", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
if (Math.floor(Math.random() * 4) == 0) {
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.pilot.head._x, y:this.pilot.head._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_brains1", "brains", 1);
eval ("_root.limb" + nr).brains._xscale = 50;
eval ("_root.limb" + nr).brains._yscale = 50;
Set(("_root.limb" + nr) + "._rotation", _rotation);
}
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.pilot2.head._x, y:this.pilot2.head._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_head1", "head", 1);
eval ("_root.limb" + nr).head._xscale = 50;
eval ("_root.limb" + nr).head._yscale = 50;
Set(("_root.limb" + nr) + "._rotation", _rotation);
eval (("_root.limb" + nr) + ".head").gotoAndStop(this.pilot2.head._currentframe);
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.pilot2.head._x, y:this.pilot2.head._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_eye1", "eye", 1);
eval ("_root.limb" + nr).eye._xscale = 50;
eval ("_root.limb" + nr).eye._yscale = 50;
Set(("_root.limb" + nr) + "._rotation", _rotation);
if (Math.floor(Math.random() * 4) == 0) {
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.pilot2.head._x, y:this.pilot2.head._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_brains1", "brains", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
}
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.planerotor._x, y:this.planerotor._y}));
_root.attachMovie("idjunk", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("idrotor", "rotor", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
Set(("_root.limb" + nr) + ":hspeed", _root.hspeed + (14 * Math.cos(_rotation * (Math.PI/180))));
Set(("_root.limb" + nr) + ":vspeed", _root.vspeed + (14 * Math.sin(_rotation * (Math.PI/180))));
Set(("_root.limb" + nr) + ":rotspeed", 0);
i = 3;
while (i >= 1) {
nr = _root.getNextHighestDepth();
_root.attachMovie("idjunk", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", _x + ((-50 + ((i - 1) * 20)) * Math.cos(_rotation * (Math.PI/180))));
Set(("_root.limb" + nr) + "._y", _y + ((-50 + ((i - 1) * 20)) * Math.sin(_rotation * (Math.PI/180))));
eval ("_root.limb" + nr).attachMovie("idplane_dead", "New", 1);
eval ("_root.limb" + nr).New.gotoAndStop(i);
Set(("_root.limb" + nr) + "._rotation", _rotation);
Set(("_root.limb" + nr) + ":hspeed", (_root.hspeed + (Math.random() * 16)) - 8);
Set(("_root.limb" + nr) + ":vspeed", (_root.vspeed + ((-Math.random()) * 8)) + 2);
Set(("_root.limb" + nr) + ":rotspeed", (Math.random() * 50) - 25);
i = i - 1;
}
nr = _root.getNextHighestDepth();
_root.attachMovie("idgun_dead", "limb" + nr, nr);
this.localToGlobal((p = {x:this.p2gun._x, y:this.p2gun._y}));
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
Set(("_root.limb" + nr) + "._rotation", _rotation + p2gun._rotation);
Set(("_root.limb" + nr) + ":hspeed", ((_root.hspeed / 2) + (Math.random() * 5)) - 2.5);
Set(("_root.limb" + nr) + ":vspeed", ((_root.vspeed / 2) + (Math.random() * 8)) - 12);
Set(("_root.limb" + nr) + ":rotspeed", (Math.random() * 40) - 20);
Set(("_root.limb" + nr) + ":bulletshoot", _root.bulletshoot);
Set(("_root.limb" + nr) + ":shoot", shoot);
removeMovieClip("");
Symbol 205 MovieClip [idplayer_plane] Frame 28
snd = new Sound();
nr = Math.floor((Math.random() * 3) + 1);
snd.attachSound("snd_releasebomb" + nr);
snd.start();
_root.bomb_shoot = _global.bombdelay;
_root.rocketnr = _root.rocketnr + 1;
if (_root.rocketnr >= 50) {
_root.rocketnr = 0;
}
_root.attachMovie("idbomb_1", "rocket" + _root.rocketnr, _root.getNextHighestDepth());
Set(("../rocket" + _root.rocketnr) + ":hspeed", _root.hspeed + (1 * Math.cos((_rotation + 90) * (Math.PI/180))));
Set(("../rocket" + _root.rocketnr) + ":vspeed", _root.vspeed + (1 * Math.sin((_rotation + 90) * (Math.PI/180))));
setProperty("../rocket" + _root.rocketnr, _rotation , _rotation);
setProperty("../rocket" + _root.rocketnr, _x , this._x + (10 * Math.cos((_rotation + 130) * (Math.PI/180))));
setProperty("../rocket" + _root.rocketnr, _y , this._y + (10 * Math.sin((_rotation + 130) * (Math.PI/180))));
if (_root.adrenaline == 100) {
_root.adbomb = _global.adnr;
_root.adrenaline = 0;
}
Symbol 205 MovieClip [idplayer_plane] Frame 33
if (Math.floor(Math.random() * (myhealth + 10)) == 0) {
myhealth = myhealth - 0.5;
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , (this._x + (Math.random() * 30)) - 15);
yplace = (Math.random() * 30) - 15;
setProperty("../explosion_1_" + expdepth, _y , this._y + yplace);
_root.rotspeed = _root.rotspeed + (yplace / 5);
Set(("../explosion_1_" + expdepth) + ":scale", 50 + (Math.random() * 10));
}
Symbol 205 MovieClip [idplayer_plane] Frame 38
mousedirec = Math.atan2(_root._ymouse - _y, _root._xmouse - _x) * 57.2957795130823;
if (_root.bulletshoot >= 1) {
_root.bulletshoot = _root.bulletshoot - 1;
}
if (shoot == 1) {
if ((_root.bulletshoot <= 0) && (((Math.abs(mousedirec - _rotation) < _global.shootrange) or (Math.abs((mousedirec + 360) - _rotation) < _global.shootrange)) or (Math.abs(mousedirec - (_rotation + 360)) < _global.shootrange))) {
call("bullets");
}
}
Symbol 205 MovieClip [idplayer_plane] Frame 44
p2gun.tdirec = Math.atan2(_root._ymouse - (_y - (13 * Math.sin(_rotation * (Math.PI/180)))), _root._xmouse - (_x - (24 * Math.cos(_rotation * (Math.PI/180)))));
if (p2gun.tdirec < 0) {
p2gun.tdirec = p2gun.tdirec + (Math.PI*2);
}
if (p2gun.tdirec > (Math.PI*2)) {
p2gun.tdirec = p2gun.tdirec - (Math.PI*2);
}
p2gun.direc = (_rotation + p2gun._rotation) * (Math.PI/180);
p2gun.reldirec = p2gun.tdirec - p2gun.direc;
if (p2gun.reldirec < 0) {
p2gun.reldirec = p2gun.reldirec + (Math.PI*2);
}
if (p2gun.reldirec > (Math.PI*2)) {
p2gun.reldirec = p2gun.reldirec - (Math.PI*2);
}
turning = 0.5 + (((_global.shootrange - 20) / 40) * 1);
if (p2gun.reldirec > Math.PI) {
p2gun.rotspeed = p2gun.rotspeed - turning;
}
if (p2gun.reldirec < Math.PI) {
p2gun.rotspeed = p2gun.rotspeed + turning;
}
p2gun.rotspeed = p2gun.rotspeed * 0.8;
p2gun._rotation = p2gun._rotation + p2gun.rotspeed;
p2gun._x = -24 + (12 * Math.cos(p2gun._rotation * (Math.PI/180)));
p2gun._y = -13 + (6 * Math.sin(p2gun._rotation * (Math.PI/180)));
if (p2gun._x > -24) {
p2gun._yscale = -100;
} else {
p2gun._yscale = 100;
}
if (_root.bulletshoot >= 1) {
_root.bulletshoot = _root.bulletshoot - 1;
}
if (_root.p2rocketshoot >= 1) {
_root.p2rocketshoot = _root.p2rocketshoot - 1;
}
if (_root.p2bombshoot >= 1) {
_root.p2bombshoot = _root.p2bombshoot - 1;
}
if ((shoot == 1) and (_root.bulletshoot <= 0)) {
call("bullets2");
}
if ((shoot2 == 1) and (_root.p2rocketshoot <= 0)) {
call("2procket");
}
if ((shoot3 == 1) and (_root.p2bombshoot <= 0)) {
call("grenade");
}
shoot2 = 0;
shoot3 = 0;
Symbol 205 MovieClip [idplayer_plane] Frame 51
_root.p2rocketshoot = _global.rocketdelay * 3;
this.localToGlobal((p = {x:p2gun._x, y:p2gun._y}));
snd = new Sound();
nr = Math.floor((Math.random() * 3) + 1);
snd.attachSound("snd_releasebomb" + nr);
snd.start();
_root.rocketnr = _root.rocketnr + 1;
if (_root.rocketnr >= 50) {
_root.rocketnr = 0;
}
rot = p2gun.tdirec * 57.2957795130823;
_root.attachMovie("idrocket_homing", "rocket" + _root.rocketnr, _root.getNextHighestDepth());
Set(("../rocket" + _root.rocketnr) + ":power", 1);
Set(("../rocket" + _root.rocketnr) + ":hspeed", _root.hspeed + (5 * Math.cos(rot * (Math.PI/180))));
Set(("../rocket" + _root.rocketnr) + ":vspeed", _root.vspeed + (5 * Math.sin(rot * (Math.PI/180))));
Set(("../rocket" + _root.rocketnr) + ":life", 60 + (Math.random() * 10));
Set(("../rocket" + _root.rocketnr) + ":delay", Math.floor(30 - (Math.random(1) * 3)));
Set(("../rocket" + _root.rocketnr) + ":rotspeed", (Math.random() * 4) - 2);
setProperty("../rocket" + _root.rocketnr, _rotation , rot);
setProperty("../rocket" + _root.rocketnr, _x , p.x);
setProperty("../rocket" + _root.rocketnr, _y , p.y);
Symbol 205 MovieClip [idplayer_plane] Frame 57
_root.p2bombshoot = _global.bombdelay * 2;
this.localToGlobal((p = {x:p2gun._x, y:p2gun._y}));
snd = new Sound();
nr = Math.floor((Math.random() * 3) + 1);
snd.attachSound("snd_releasebomb" + nr);
snd.start();
_root.rocketnr = _root.rocketnr + 1;
if (_root.rocketnr >= 50) {
_root.rocketnr = 0;
}
rot = p2gun.tdirec * 57.2957795130823;
_root.attachMovie("idgrenade", "rocket" + _root.rocketnr, _root.getNextHighestDepth());
Set(("../rocket" + _root.rocketnr) + ":hspeed", _root.hspeed + (10 * Math.cos(rot * (Math.PI/180))));
Set(("../rocket" + _root.rocketnr) + ":vspeed", _root.vspeed + (10 * Math.sin(rot * (Math.PI/180))));
setProperty("../rocket" + _root.rocketnr, _rotation , rot);
setProperty("../rocket" + _root.rocketnr, _x , p.x);
setProperty("../rocket" + _root.rocketnr, _y , p.y);
Symbol 214 MovieClip [idcivilian] Frame 1
dep = this.getNextHighestDepth();
myarm1 = this.attachMovie("c_arm1", "civarm1" + dep, dep);
dep = this.getNextHighestDepth();
mybody = this.attachMovie("c_body1", "civbody" + dep, dep);
dep = this.getNextHighestDepth();
myarm2 = this.attachMovie("c_arm1", "civarm2" + dep, dep);
nr = 1;
dep = this.getNextHighestDepth();
myhead = this.attachMovie("c_head" + nr, "civhead" + dep, dep);
nr = 1;
dep = this.getNextHighestDepth();
myfeet = this.attachMovie("c_feet" + nr, "civfeet" + dep, dep);
nr = 1;
dep = this.getNextHighestDepth();
myeye = this.attachMovie("c_eye" + nr, "civeye" + dep, dep);
nr = 1;
dep = this.getNextHighestDepth();
mymouth = this.attachMovie("c_mouth" + nr, "civmouth" + dep, dep);
nr = Math.floor(Math.random() * 6) + 1;
mybody.gotoAndStop(nr);
myarm1.gotoAndStop(nr);
myarm2.gotoAndStop(nr);
mybody._y = -20.6 + (mybody._height / 2);
myhead._y = -69.8 + (myhead._height / 2);
myfeet._y = 22.8 + (myfeet._height / 2);
myeye._y = -51 + (myeye._height / 2);
mymouth._y = -40.8 + (mymouth._height / 2);
myarm1._y = -6;
myarm2._y = -6;
t = Math.PI;
t = 0;
_y = (_y - 13);
_xscale = 50;
_yscale = 50;
rotspeed = 0;
alive = 1;
die = 0;
hspeed = Math.round((Math.random() * 4) - 2);
vspeed = 0;
Fz = 0;
if (hspeed > 0) {
_xscale = -50;
}
if (hspeed == 0) {
if (Math.floor(Math.random() * 2) == 0) {
_xscale = -50;
}
}
onEnterFrame = function () {
dep = this.getDepth();
if (dep != 15) {
if (_root.getInstanceAtDepth(dep - 1) == undefined) {
this.swapDepths(dep - 1);
this._name = "civ" + (dep - 1);
}
}
if (die == 1) {
call("die1");
}
if (die == 2) {
call("die2");
}
if (die == 3) {
call("die3");
}
if (alive == 1) {
call("normal");
} else {
call("ragdoll");
}
if (((_y > _root.roomheight) or (_x < -100)) or (_x > 900)) {
call("destroy");
}
};
Symbol 214 MovieClip [idcivilian] Frame 3
gotoAndPlay (2);
Symbol 214 MovieClip [idcivilian] Frame 4
_root.totalcivs = _root.totalcivs - 1;
removeMovieClip("");
Symbol 214 MovieClip [idcivilian] Frame 11
vspeed = vspeed + Fz;
_y = (_y + vspeed);
_x = (_x + hspeed);
t = t + (Math.PI / (32 / hspeed));
if (t >= 6.3) {
t = t - (Math.PI*2);
}
myarm1._rotation = 15 + (70 * Math.sin(t));
myarm2._rotation = 18.1415926535898 + (70 * Math.sin(t));
Fz = 0.4;
this.localToGlobal((p = {x:myfeet._x, y:myfeet._y}));
min = Math.floor(p.x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y - 1, true)) {
Fz = 0;
vspeed = 0;
yy = 0;
while (eval ("_root.groundnr" + i).hitTest(p.x, (p.y - 2) - yy, true)) {
yy = yy + 1;
}
_y = (_y - yy);
}
i = i + 1;
}
}
Symbol 214 MovieClip [idcivilian] Frame 16
hitX = _x;
vspeed = vspeed + Fz;
hspeed = hspeed + (rotspeed / 100);
_y = (_y + vspeed);
_x = (_x + hspeed);
vspeed = vspeed * 0.98;
hspeed = hspeed * 0.98;
rotspeed = rotspeed * 0.95;
_rotation = (_rotation + rotspeed);
hitX = _x;
Fz = 0.3;
for (a in this.hitbox) {
this.hitbox.localToGlobal((p = {x:this.hitbox[a]._x, y:this.hitbox[a]._y}));
min = Math.floor(p.x / 100) + 1;
max = min + 1;
i = min;
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y + 1, true)) {
Fz = 0;
hitX = p.x;
if (Math.abs(vspeed) < 0.1) {
vspeed = 0;
}
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y, true)) {
rotspeed = rotspeed + ((-(1 * (p.x - this._x))) * (Math.abs(vspeed) * 0.15));
vspeed = -0.4 * Math.abs(vspeed);
yy = 0;
while (eval ("_root.groundnr" + i).hitTest(p.x, p.y - 1, true)) {
p.y = p.y - yy;
yy = yy + 1;
}
_y = (_y - yy);
}
}
i = i + 1;
}
}
rotspeed = rotspeed + ((-(hitX - this._x)) * 0.05);
Symbol 214 MovieClip [idcivilian] Frame 23
if (alive == 1) {
_root.adrenaline = _root.adrenaline + ((Math.random() * 2) + 4);
_root.wantedlevel = _root.wantedlevel + 5;
_global.XP = _global.XP + 3;
}
rotspeed = rotspeed + (((Math.random() * 4) - 2) * hspeed);
alive = 0;
die = 0;
Symbol 214 MovieClip [idcivilian] Frame 27
if (alive == 1) {
_root.adrenaline = _root.adrenaline + ((Math.random() * 2) + 4);
_root.wantedlevel = _root.wantedlevel + 5;
_global.XP = _global.XP + 5;
}
if (myhead._currentframe <= 3) {
myhead.gotoAndStop(myhead._currentframe + 3);
}
rotspeed = rotspeed + (Math.random() * hspeed);
alive = 0;
die = 0;
Symbol 214 MovieClip [idcivilian] Frame 31
_root.adrenaline = _root.adrenaline + ((Math.random() * 2) + 6);
_root.wantedlevel = _root.wantedlevel + 5;
_global.XP = _global.XP + 7;
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.myhead._x, y:this.myhead._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_head1", "head", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
eval (("_root.limb" + nr) + ".head").gotoAndStop(myhead._currentframe);
if (myhead._currentframe > 3) {
eval (("_root.limb" + nr) + ".head").gotoAndStop(myhead._currentframe - 3);
}
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.mybody._x, y:this.mybody._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("c_body1", "body", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
eval (("_root.limb" + nr) + ".body").gotoAndStop(mybody._currentframe);
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.myarm1._x, y:this.myarm1._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("c_arm1", "arm", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
eval (("_root.limb" + nr) + ".arm").gotoAndStop(myarm1._currentframe);
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.myarm2._x, y:this.myarm2._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("c_arm1", "arm", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
eval (("_root.limb" + nr) + ".arm").gotoAndStop(myarm2._currentframe);
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.myfeet._x, y:this.myfeet._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("c_feet1", "feet", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.myhead._x, y:this.myhead._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_eye1", "eye", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
if (Math.floor(Math.random() * 4) == 0) {
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.myhead._x, y:this.myhead._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_brains1", "brains", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
}
call("destroy");
Symbol 236 MovieClip [c_feet1] Frame 1
onEnterFrame = function () {
if (this._parent.alive == 1) {
gotoAndPlay(_currentframe + Math.abs(Math.round(_parent.hspeed * 0.32)));
} else {
gotoAndStop (1);
}
};
Symbol 236 MovieClip [c_feet1] Frame 6
if (_parent.hspeed == 0) {
gotoAndPlay (1);
}
Symbol 269 MovieClip [idbloodsmall] Frame 1
scale = ((Math.random() / 5) + 0.3) * 100;
_xscale = scale;
_yscale = scale;
if (hspeed < 0) {
_yscale = (_yscale * -1);
}
this.filters = _root.filterArray;
onEnterFrame = function () {
_x = (_x + (hspeed * 0.8));
};
Symbol 269 MovieClip [idbloodsmall] Frame 16
removeMovieClip("");
Symbol 270 MovieClip [idcontroller_level] Frame 1
if (_root.getInstanceAtDepth(100) == undefined) {
if (Key.isDown(32)) {
if (_global.lives >= 1) {
_root.attachMovie("idplayer_plane", "idplane", 100);
_root.idplane._x = 400;
_root.idplane._y = -20;
_root.idplane._rotation = 90;
_root.idplane.myhealth = _global.maxhealth;
_root.Fengine = 4;
_root.vspeed = 10;
_root.rotspeed = -7;
_root.idplane.p2gun._rotation = 180;
if (_root.MP == 0) {
_root.idplane.pilot2._alpha = 0;
_root.idplane.p2gun._alpha = 0;
}
_root.adrenaline = 0;
_global.XP = _global.XP * 0.666666666666667;
_global.lives = _global.lives - 1;
_root.sndengine = new Sound("_root.idplane");
_root.sndengine.attachSound("snd_engine");
_root.sndengine.start(0, 9999);
} else if (Math.random() < 0.9) {
_root.displaytxt = "No more lives left! Press ESC";
} else {
_root.displaytxt = "INSERT COIN";
}
}
}
onEnterFrame = function () {
if ((_root.adrenaline > 0) && (_root.adrenaline < 100)) {
_root.adrenaline = _root.adrenaline - 0.0333333333333333;
}
if (_root.adrenaline > 100) {
_root.adrenaline = 100;
}
_root.adrenalinebar.idfill._xscale = _root.adrenaline;
_root.adrenalinebar.idfill._yscale = _root.adrenaline;
if ((_root.wantedlevel > 0) && (_root.wantedlevel < 1000)) {
_root.wantedlevel = _root.wantedlevel - 0.0333333333333333;
}
if (_root.wantedlevel > 1000) {
_root.wantedlevel = 1000;
if (_root.totalenemies == 0) {
call("makeboss");
}
}
_root.idwantedbar.idfill._x = -470 + (305 * (_root.wantedlevel / 1000));
_root.idhealthbar.idfill._x = -150.8 + (98.7 * (_root.idplane.myhealth / _global.maxhealth));
if (_root.getInstanceAtDepth(100) == undefined) {
_root.idhealthbar.idfill._x = -175.8;
}
_root.idhealthbar.lives = "x" + _global.lives;
_root.idhealthbar.idxpfill._x = -128.5 + (85.8 * (_global.XP / _global.XPneed));
if (_global.XP > _global.XPneed) {
_global.XP = _global.XP - _global.XPneed;
_global.XPneed = _global.XPneed * 1.2;
_global.XPpoints = _global.XPpoints + 1;
_global.XPlevel = _global.XPlevel + 1;
_root.displaytxt = "Level Up! 1 Xp earned!";
if (((_global.XPlevel == 5) or (_global.XPlevel == 15)) or (_global.XPlevel == 20)) {
_root.displaytxt = ("Level " + _global.XPlevel) + "; reloading has been upgraded!";
_global.bulletdelay = _global.bulletdelay - 1;
_global.rocketdelay = _global.rocketdelay * 0.75;
_global.bombdelay = _global.bombdelay * 0.75;
_global.rocketdelay = Math.round(_global.rocketdelay * 0.75);
_global.bombdelay = Math.round(_global.bombdelay * 0.75);
}
_root.savedata();
}
};
Symbol 270 MovieClip [idcontroller_level] Frame 2
gotoAndPlay (1);
Symbol 270 MovieClip [idcontroller_level] Frame 3
_root.attachMovie("idngtank", "enemy38", 38);
_root.enemy38._x = -230;
_root.enemy38._y = _root.idcontroller_ground.startheight2 - 230;
Set("_root.enemy38:hhspeed", 4);
_root.totalenemies = _root.totalenemies + 1;
Symbol 271 MovieClip [idcontroller_music] Frame 1
music = new Sound(this);
music.setVolume(65);
music.attachSound("Intro.wav");
music.start();
current = 1;
music.onSoundComplete = function () {
music.stop("Intro.wav");
if (current == 1) {
call("stopsnd");
music.attachSound("Refrein.wav");
music.start(0, 0);
current = 2;
}
if (current == 3) {
call("stopsnd");
nr = Math.floor((Math.random() * 2) + 1);
music.attachSound("snd_music" + nr);
music.start(0, 0);
current = 1;
}
if (current == 2) {
current = 3;
}
};
Symbol 271 MovieClip [idcontroller_music] Frame 3
gotoAndPlay (2);
Symbol 271 MovieClip [idcontroller_music] Frame 4
music.stop("Refrein.wav");
music.stop("snd_music1");
music.stop("snd_music2");
Symbol 273 MovieClip [idbomb_1] Frame 1
rotspeed = (Math.random() * 14) - 7;
onEnterFrame = function () {
if ((_rotation < 90) && (_rotation > 0)) {
rotspeed = rotspeed + 0.1;
}
if (_rotation > 90) {
rotspeed = rotspeed - 0.1;
}
rotspeed = rotspeed * 0.95;
_rotation = (_rotation + rotspeed);
vspeed = vspeed + 0.24;
_x = (_x + hspeed);
_y = (_y + vspeed);
hspeed = hspeed * 0.98;
vspeed = vspeed * 0.98;
min = Math.floor(_x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(_x, _y, true)) {
call("destroy");
}
i = i + 1;
}
}
i = 42;
while (i <= (41 + _root.totalcivcars)) {
if (eval ("_root.civcar" + i).hitTest(_x, _y, true)) {
eval ("_root.civcar" + i).myhealth = 0;
mydelta = eval (("_root.civcar" + i) + "._x") - this._x;
eval ("_root.civcar" + i).hspeed = eval ("_root.civcar" + i).hspeed + (mydelta / 2);
Set(("_root.civcar" + i) + ":rotspeed", -0.6 * mydelta);
call("destroy");
}
i = i + 1;
}
i = 15;
while (i <= (14 + _root.totalcivs)) {
if (eval ("_root.civ" + i).hitTest(_x, _y, false)) {
eval ("_root.civ" + i).die = 3;
eval ("_root.civ" + i).hspeed = eval ("_root.civ" + i).hspeed + (hspeed * 4);
call("destroy");
}
i = i + 1;
}
i = 28;
while (i <= (27 + _root.totalenemies)) {
if (eval ("_root.enemy" + i).hitTest(_x, _y, true)) {
eval ("_root.enemy" + i).myhealth = eval ("_root.enemy" + i).myhealth - (150 + (Math.random() * 50));
mydelta = eval (("_root.enemy" + i) + "._x") - this._x;
eval ("_root.enemy" + i).rotspeed = eval ("_root.enemy" + i).rotspeed - (mydelta / 15);
eval ("_root.enemy" + i).hspeed = eval ("_root.enemy" + i).hspeed + (mydelta / 10);
call("destroy");
}
i = i + 1;
}
if ((((_x < -5) or (_x > 805)) or (_y < -5)) or (_y > (_root.roomheight + 5))) {
removeMovieClip("");
}
};
Symbol 273 MovieClip [idbomb_1] Frame 4
gotoAndPlay (2);
Symbol 273 MovieClip [idbomb_1] Frame 5
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , this._x);
setProperty("../explosion_1_" + expdepth, _y , this._y);
Set(("_root.explosion_1_" + expdepth) + ":scale", 90 - (Math.random() * 20));
i = 0;
while (i < _global.clusters) {
nr = _root.getNextHighestDepth();
_root.attachMovie("idbomb_fragment", "new_" + nr, nr);
setProperty("../new_" + nr, _x , this._x);
setProperty("../new_" + nr, _y , this._y - this.vspeed);
Set(("_root.new_" + nr) + ":hspeed", (Math.random() * 16) - 8);
Set(("_root.new_" + nr) + ":vspeed", (Math.random() * -4) - 2);
i = i + 1;
}
removeMovieClip("");
Symbol 275 MovieClip [idbullet] Frame 1
gunsound = new Sound(this);
nr = Math.floor((Math.random() * 2) + 1);
gunsound.attachSound("snd_gunshot" + nr);
this.gunsound.setVolume(75);
gunsound.start();
onEnterFrame = function () {
hspeed = speed * Math.cos(_rotation * (Math.PI/180));
vspeed = speed * Math.sin(_rotation * (Math.PI/180));
_x = (_x + hspeed);
_y = (_y + vspeed);
if ((((_x < -5) or (_x > 805)) or (_y < -5)) or (_y > (_root.roomheight + 5))) {
call("destroy");
}
min = Math.floor(_x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(this._x, this._y, true)) {
call("destroy");
}
i = i + 1;
}
}
i = 42;
while (i <= (41 + _root.totalcivcars)) {
if (eval ("_root.civcar" + i).hitTest(_x, _y, false)) {
eval ("_root.civcar" + i).myhealth = eval ("_root.civcar" + i).myhealth - 10;
mydelta = eval (("_root.civcar" + i) + "._x") - this._x;
eval ("_root.civcar" + i).rotspeed = eval ("_root.civcar" + i).rotspeed - (mydelta / 20);
call("destroy");
}
i = i + 1;
}
i = 15;
while (i <= (14 + _root.totalcivs)) {
if (eval ("_root.civ" + i).hitTest(_x, _y, false)) {
eval ("_root.civ" + i).die = 1;
eval ("_root.civ" + i).hspeed = eval ("_root.civ" + i).hspeed + (hspeed / 6);
nr = eval ("_root.civ" + i).getNextHighestDepth();
eval ("_root.civ" + i).attachMovie("idc_wound", "wound" + nr, nr);
setProperty(eval ((("_root.civ" + i) + ".wound") + nr), _x , (Math.random() * 30) - 15);
setProperty(eval ((("_root.civ" + i) + ".wound") + nr), _y , 1.8 * (this._y - eval ("_root.civ" + i)._y));
nr = _root.getNextHighestDepth();
_root.attachMovie("idbloodsmall", "blood" + nr, nr);
setProperty("_root.blood" + nr, _x , eval ("_root.civ" + i)._x);
setProperty("_root.blood" + nr, _y , this._y);
setProperty("_root.blood" + nr, _rotation , this._rotation);
Set(("_root.blood" + nr) + ":hspeed", this.hspeed / 6);
call("destroy");
}
i = i + 1;
}
i = 28;
while (i <= (27 + _root.totalenemies)) {
if (eval ("_root.enemy" + i).hitTest(_x, _y, true)) {
eval ("_root.enemy" + i).myhealth = eval ("_root.enemy" + i).myhealth - (10 + (Math.random() * 5));
call("destroy");
}
i = i + 1;
}
};
Symbol 275 MovieClip [idbullet] Frame 3
gotoAndPlay (2);
Symbol 275 MovieClip [idbullet] Frame 4
removeMovieClip("");
Symbol 353 MovieClip Frame 1
if (_root._quality == "HIGH") {
this.filters = _root.filterArray;
}
Symbol 353 MovieClip Frame 38
gotoAndPlay (14);
Symbol 354 MovieClip [idrocket_1] Frame 1
onEnterFrame = function () {
delay = delay - 1;
if (delay < 0) {
if (delay == -1) {
snd = new Sound();
idnr = Math.floor((Math.random() * 3) + 1);
snd.attachSound("snd_rocketboost" + idnr);
snd.start();
}
chc = Math.floor(Math.random(1) * 10);
if (chc == 0) {
rotspeed = (Math.random(1) * 7) - 3;
}
_rotation = (_rotation + rotspeed);
hspeed = hspeed + (power * Math.cos(_rotation * (Math.PI/180)));
vspeed = vspeed + (power * Math.sin(_rotation * (Math.PI/180)));
if (life < 0) {
call("destroy");
}
life = life - 1;
}
vspeed = vspeed + 0.05;
_x = (_x + hspeed);
_y = (_y + vspeed);
hspeed = hspeed * 0.98;
vspeed = vspeed * 0.98;
min = Math.floor(_x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(_x, _y, true)) {
call("destroy");
}
i = i + 1;
}
}
i = 42;
while (i <= (41 + _root.totalcivcars)) {
if (eval ("_root.civcar" + i).hitTest(_x, _y, true)) {
eval ("_root.civcar" + i).myhealth = 0;
mydelta = eval (("_root.civcar" + i) + "._x") - this._x;
eval ("_root.civcar" + i).hspeed = eval ("_root.civcar" + i).hspeed + (mydelta / 3);
Set(("_root.civcar" + i) + ":rotspeed", -0.4 * mydelta);
call("destroy");
}
i = i + 1;
}
i = 15;
while (i <= (14 + _root.totalcivs)) {
if (eval ("_root.civ" + i).hitTest(_x, _y, false)) {
eval ("_root.civ" + i).die = 3;
eval ("_root.civ" + i).hspeed = hspeed;
call("destroy");
}
i = i + 1;
}
i = 28;
while (i <= (27 + _root.totalenemies)) {
if (eval ("_root.enemy" + i).hitTest(_x, _y, true)) {
eval ("_root.enemy" + i).myhealth = eval ("_root.enemy" + i).myhealth - (100 + (Math.random() * 50));
mydelta = eval (("_root.enemy" + i) + "._x") - this._x;
eval ("_root.enemy" + i).rotspeed = eval ("_root.enemy" + i).rotspeed - (mydelta / 15);
eval ("_root.enemy" + i).hspeed = eval ("_root.enemy" + i).hspeed + (mydelta / 10);
call("destroy");
}
i = i + 1;
}
};
Symbol 354 MovieClip [idrocket_1] Frame 3
if (delay < 0) {
gotoAndPlay (4);
} else {
gotoAndPlay (2);
}
Symbol 354 MovieClip [idrocket_1] Frame 5
gotoAndPlay (4);
Symbol 354 MovieClip [idrocket_1] Frame 6
snd.stop("snd_rocketboost" + idnr);
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , this._x);
setProperty("../explosion_1_" + expdepth, _y , this._y);
Set(("../explosion_1_" + expdepth) + ":scale", 70 - (Math.random() * 20));
removeMovieClip("");
Symbol 360 MovieClip [idw_loadingbar] Frame 2
if (this.idfill._xscale == 100) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 360 MovieClip [idw_loadingbar] Frame 4
if (this.idfill._xscale == 100) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 404 MovieClip Frame 1
_rotation = 90;
Symbol 405 MovieClip [idadrenaline_meter] Frame 2
if (_root.adrenaline < 100) {
gotoAndPlay (1);
} else {
gotoAndPlay (3);
}
Symbol 405 MovieClip [idadrenaline_meter] Frame 4
if (_root.adrenaline < 100) {
gotoAndPlay (1);
} else {
gotoAndPlay (3);
}
Symbol 408 MovieClip [idlimb] Frame 1
Fz = 0.4;
_xscale = 50;
_yscale = 50;
vspeed = ((-Math.random()) * 5) - 8;
hspeed = (Math.random() * 20) - 10;
rotspeed = (Math.random() * 30) - 15;
life = Math.random(25) + 50;
onEnterFrame = function () {
vspeed = vspeed + Fz;
vspeed = vspeed * 0.99;
hspeed = hspeed * 0.99;
_rotation = (_rotation + rotspeed);
rotspeed = rotspeed * 0.99;
_y = (_y + vspeed);
_x = (_x + hspeed);
if (life <= 25) {
_alpha = ((life / 25) * 100);
}
life = life - 1;
if (life <= 0) {
removeMovieClip("");
}
};
Symbol 408 MovieClip [idlimb] Frame 3
gotoAndPlay (2);
Symbol 416 MovieClip [idjunk] Frame 1
Fz = 0.4;
life = Math.random(25) + 50;
onEnterFrame = function () {
vspeed = vspeed + Fz;
vspeed = vspeed * 0.99;
hspeed = hspeed * 0.99;
_rotation = (_rotation + rotspeed);
rotspeed = rotspeed * 0.99;
_y = (_y + vspeed);
_x = (_x + hspeed);
if (life <= 25) {
_alpha = ((life / 25) * 100);
}
life = life - 1;
if (life <= 0) {
removeMovieClip("");
}
};
Symbol 416 MovieClip [idjunk] Frame 3
gotoAndPlay (2);
Symbol 423 MovieClip [dead_brains1] Frame 1
gotoAndStop(Math.floor((Math.random() * 2) + 1));
Symbol 439 MovieClip [idtank1] Frame 1
idcannon.rotspeed = 0;
rotspeed = 0;
Fz = 0.5;
hspeed = 0;
vspeed = 0;
hitX = 0;
myhealth = 600 + (100 * (_global.bossnr - 1));
maxhealth = myhealth;
bulletspeed = 25;
canshoot = 0;
recoil = 0;
count = 5;
rocketdelay = 125;
keepdistance = 350 - (Math.random() * 300);
idcannon._rotation = Math.atan2(_root.idplane._y - _y, _root.idplane._x - _x) * 57.2957795130823;
onEnterFrame = function () {
dep = this.getDepth();
if (dep != 28) {
if (_root.getInstanceAtDepth(dep - 1) == undefined) {
this.swapDepths(dep - 1);
this._name = "enemy" + (dep - 1);
}
}
if (myhealth <= 0) {
call("die1");
}
if (myhealth < 50) {
call("dying");
}
this.healthbar._xscale = (myhealth / maxhealth) * 100;
if (_root.idplane._x < (_x - keepdistance)) {
hspeed = hspeed - 0.9;
}
if (_root.idplane._x > (_x + keepdistance)) {
hspeed = hspeed + 0.9;
}
call("cannon");
if (canshoot <= 0) {
call("shoot");
} else if (_root.getInstanceAtDepth(100) != undefined) {
canshoot = canshoot - 1;
}
rocketdelay = rocketdelay - 1;
if (rocketdelay <= 0) {
rocketdelay = 250;
call("rocket");
}
call("coll");
hitX = hitX * 0.9;
rotspeed = rotspeed * 0.9;
_rotation = (_rotation + rotspeed);
_rotation = (_rotation - (hitX * 0.008));
hspeed = hspeed * 0.9;
vspeed = vspeed * 0.9;
vspeed = vspeed + Fz;
_x = (_x + hspeed);
_y = (_y + vspeed);
if ((((_x < -105) or (_x > 905)) or (_y < -105)) or (_y > (_root.roomheight + 5))) {
call("destroy");
}
};
Symbol 439 MovieClip [idtank1] Frame 3
gotoAndPlay (2);
Symbol 439 MovieClip [idtank1] Frame 4
if (recoil > 0) {
recoil = recoil - 1;
}
idcannon._x = (-0.5 * recoil) * Math.cos(idcannon._rotation * (Math.PI/180));
idcannon._y = -45 - ((0.5 * recoil) * Math.sin(idcannon._rotation * (Math.PI/180)));
count = count - 1;
if (count <= 0) {
count = 5;
this.localToGlobal((p = {x:this.idcannon._x, y:this.idcannon._y}));
tdirec = Math.atan2(_root.idplane._y - p.y, _root.idplane._x - p.x);
if (tdirec < 0) {
tdirec = tdirec + (Math.PI*2);
}
if (tdirec > (Math.PI*2)) {
tdirec = tdirec - (Math.PI*2);
}
direc = (_rotation + idcannon._rotation) * (Math.PI/180);
reldirec = tdirec - direc;
if (reldirec < 0) {
reldirec = reldirec + (Math.PI*2);
}
if (reldirec > (Math.PI*2)) {
reldirec = reldirec - (Math.PI*2);
}
if (reldirec > Math.PI) {
idcannon.rotspeed = idcannon.rotspeed - 1;
} else {
idcannon.rotspeed = idcannon.rotspeed + 1;
}
}
if (idcannon._rotation >= 90) {
idcannon._rotation = -180;
idcannon.rotspeed = 0;
}
if (idcannon._rotation > 0) {
idcannon._rotation = 0;
idcannon.rotspeed = 0;
}
idcannon.rotspeed = idcannon.rotspeed * 0.95;
idcannon._rotation = idcannon._rotation + idcannon.rotspeed;
Symbol 439 MovieClip [idtank1] Frame 10
_root.totalenemies = _root.totalenemies - 1;
removeMovieClip("");
Symbol 439 MovieClip [idtank1] Frame 17
Fz = 0.5;
for (a in this.hitbox) {
this.localToGlobal((p = {x:this.hitbox[a]._x, y:this.hitbox[a]._y}));
min = Math.floor(p.x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y + 1, true)) {
hitX = hitX + (p.x - _x);
Fz = 0;
vspeed = 0;
if ((_rotation > 90) or (_rotation < -90)) {
call("die1");
}
}
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y, true)) {
yy = 0;
while (eval ("_root.groundnr" + i).hitTest(p.x, p.y + yy, true)) {
yy = yy - 1;
}
_y = (_y + yy);
i = max;
}
i = i + 1;
}
}
}
Symbol 439 MovieClip [idtank1] Frame 22
mysnd = new Sound(this);
nr = Math.floor(Math.random() * 3) + 1;
mysnd.attachSound("snd_tankshot" + nr);
mysnd.start("snd_tankshot" + nr);
mysnd.setVolume(150);
recoil = recoil + 20;
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:this.idcannon._x, y:this.idcannon._y}));
_root.attachMovie("idtankbullet", "bullet" + nr, nr);
Set(("_root.bullet" + nr) + "._x", (p.x + (hspeed * 0.9)) + (35 * Math.cos(idcannon._rotation * (Math.PI/180))));
Set(("_root.bullet" + nr) + "._y", (p.y + (vspeed * 0.9)) + (35 * Math.sin(idcannon._rotation * (Math.PI/180))));
Set(("_root.bullet" + nr) + "._rotation", idcannon._rotation);
canshoot = 30 + (Math.random() * 5);
Symbol 439 MovieClip [idtank1] Frame 27
_root.adrenaline = _root.adrenaline + ((Math.random() * 10) + 20);
_root.wantedlevel = _root.wantedlevel + ((Math.random() * 20) + 40);
_global.XP = _global.XP + 350;
i = 0;
while (i < 4) {
i = i + 1;
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , (this._x + (Math.random() * 80)) - 40);
setProperty("../explosion_1_" + expdepth, _y , (this._y + (Math.random() * 80)) - 40);
Set(("../explosion_1_" + expdepth) + ":scale", 60 + (Math.random() * 70));
}
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", _x);
Set(("_root.limb" + nr) + "._y", _y);
eval ("_root.limb" + nr).attachMovie("dead_head1", "head", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
eval (("_root.limb" + nr) + ".head").gotoAndStop(Math.floor(Math.random() * 3) + 1);
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", _x);
Set(("_root.limb" + nr) + "._y", _y);
eval ("_root.limb" + nr).attachMovie("dead_eye1", "eye", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
if (Math.floor(Math.random() * 4) == 0) {
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", _x);
Set(("_root.limb" + nr) + "._y", _y);
eval ("_root.limb" + nr).attachMovie("dead_brains1", "brains", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
}
i = 6;
while (i >= 1) {
nr = _root.getNextHighestDepth();
_root.attachMovie("idjunk", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", _x + ((-60 + ((i - 1) * 17)) * Math.cos(_rotation * (Math.PI/180))));
Set(("_root.limb" + nr) + "._y", (_y - 20) + ((-60 + ((i - 1) * 17)) * Math.sin(_rotation * (Math.PI/180))));
eval ("_root.limb" + nr).attachMovie("idtank_dead", "New", 1);
eval ("_root.limb" + nr).New.gotoAndStop(i);
Set(("_root.limb" + nr) + "._rotation", _rotation);
Set(("_root.limb" + nr) + ":hspeed", ((hspeed / 2) + (Math.random() * 5)) - 2.5);
Set(("_root.limb" + nr) + ":vspeed", ((vspeed / 2) + (Math.random() * 8)) - 12);
Set(("_root.limb" + nr) + ":rotspeed", (Math.random() * 40) - 20);
i = i - 1;
}
nr = _root.getNextHighestDepth();
_root.attachMovie("idjunk", "limb" + nr, nr);
this.localToGlobal((p = {x:this.idcannon._x, y:this.idcannon._y}));
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("idtank_dead", "New", 1);
eval ("_root.limb" + nr).New.gotoAndStop(7);
Set(("_root.limb" + nr) + "._rotation", idturret._rotation);
Set(("_root.limb" + nr) + ":hspeed", ((hspeed / 2) + (Math.random() * 10)) - 5);
Set(("_root.limb" + nr) + ":vspeed", ((vspeed / 2) + (Math.random() * 10)) - 15);
Set(("_root.limb" + nr) + ":rotspeed", (Math.random() * 50) - 25);
call("destroy");
Symbol 439 MovieClip [idtank1] Frame 31
if (Math.floor(Math.random() * (myhealth + 10)) == 0) {
myhealth = myhealth - 0.5;
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , (this._x + (Math.random() * 50)) - 25);
yplace = (Math.random() * 30) - 15;
setProperty("../explosion_1_" + expdepth, _y , this._y + yplace);
Set(("../explosion_1_" + expdepth) + ":scale", 50 + (Math.random() * 10));
}
Symbol 439 MovieClip [idtank1] Frame 35
this.localToGlobal((p = {x:rocketlauncher._x, y:rocketlauncher._y}));
snd = new Sound();
nr = Math.floor((Math.random() * 3) + 1);
snd.attachSound("snd_releasebomb" + nr);
snd.start();
_root.rocketnr = _root.rocketnr + 1;
if (_root.rocketnr >= 50) {
_root.rocketnr = 0;
}
_root.attachMovie("idrocket_homing2", "rocket" + _root.rocketnr, _root.getNextHighestDepth());
Set(("../rocket" + _root.rocketnr) + ":power", 1);
Set(("../rocket" + _root.rocketnr) + ":hspeed", hspeed);
Set(("../rocket" + _root.rocketnr) + ":vspeed", vspeed - 3);
Set(("../rocket" + _root.rocketnr) + ":life", 60 + (Math.random() * 10));
Set(("../rocket" + _root.rocketnr) + ":delay", 5);
if (_root.idplane._x > _x) {
Set(("../rocket" + _root.rocketnr) + ":rotspeed", 5);
} else {
Set(("../rocket" + _root.rocketnr) + ":rotspeed", -5);
}
setProperty("../rocket" + _root.rocketnr, _rotation , -90);
setProperty("../rocket" + _root.rocketnr, _x , p.x);
setProperty("../rocket" + _root.rocketnr, _y , p.y);
Symbol 441 MovieClip [idtankbullet] Frame 1
onEnterFrame = function () {
if (_root.idplane.hitTest(this._x, this._y, true)) {
_root.idplane.myhealth = _root.idplane.myhealth - (35 + (Math.random() * 10));
_root.rotspeed = _root.rotspeed + ((Math.random() * 10) - 5);
call("destroy");
}
_x = (_x + (40 * Math.cos(_rotation * (Math.PI/180))));
_y = (_y + (40 * Math.sin(_rotation * (Math.PI/180))));
if ((((_x < -5) or (_x > 805)) or (_y < -5)) or (_y > (_root.roomheight + 5))) {
removeMovieClip("");
}
};
Symbol 441 MovieClip [idtankbullet] Frame 3
gotoAndPlay (2);
Symbol 441 MovieClip [idtankbullet] Frame 4
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , this._x);
setProperty("../explosion_1_" + expdepth, _y , this._y);
Set(("../explosion_1_" + expdepth) + ":scale", (40 - (Math.random() * 20)) + 10);
removeMovieClip("");
Symbol 463 Button
on (press) {
if ((_global.XPpoints >= 2) && (_global.razorrotor == 0)) {
_global.XPpoints = _global.XPpoints - 2;
_global.razorrotor = 1;
_root.savedata();
_root.displaytext2 = ("Costs 2 points!\nlevel " + _global.razorrotor) + "/1";
}
}
on (rollOver) {
_root.displayhead = "Razor Rotors";
_root.displaytext1 = "use your rotors to tear civilians apart";
_root.displaytext2 = ("Costs 2 points!\nlevel " + _global.razorrotor) + "/1";
}
on (rollOut) {
_root.displayhead = "";
_root.displaytext1 = "";
_root.displaytext2 = "";
}
Symbol 466 Button
on (press) {
if ((_global.XPpoints >= 1) && (_global.shootrange < 60)) {
_global.XPpoints = _global.XPpoints - 1;
_global.shootrange = _global.shootrange + 10;
_root.savedata();
_root.displaytext2 = ("level " + ((_global.shootrange / 10) - 2)) + "/4";
}
}
on (rollOver) {
_root.displayhead = "Machinegun";
_root.displaytext1 = "Increase your gun's turning speed";
_root.displaytext2 = ("level " + ((_global.shootrange / 10) - 2)) + "/4";
}
on (rollOut) {
_root.displayhead = "";
_root.displaytext1 = "";
_root.displaytext2 = "";
}
Symbol 469 Button
on (rollOver) {
_root.displayhead = "Reload";
_root.displaytext1 = "Reload times upgrade \n automatically at\nlevel 5,15 & 20.";
leveltxt = "0/3";
if (_global.XPlevel >= 5) {
leveltxt = "1/3";
}
if (_global.XPlevel >= 15) {
leveltxt = "2/3";
}
if (_global.XPlevel >= 20) {
leveltxt = "3/3";
}
_root.displaytext2 = "affects bombs, missiles & bullets\nlevel " + leveltxt;
}
on (rollOut) {
_root.displayhead = "";
_root.displaytext1 = "";
_root.displaytext2 = "";
}
Symbol 472 Button
on (press) {
if ((_global.XPpoints >= 1) && (_global.adnr < 16)) {
_global.XPpoints = _global.XPpoints - 1;
_global.adnr = _global.adnr + 2;
_root.savedata();
_root.displaytext2 = ("no of projectiles: " + _global.adnr) + "/16";
}
}
on (rollOver) {
_root.displayhead = "Adrenaline";
_root.displaytext1 = "Get more rockets or bombs (+2) in every adrenaline attack";
_root.displaytext2 = ("no of projectiles: " + _global.adnr) + "/16";
}
on (rollOut) {
_root.displayhead = "";
_root.displaytext1 = "";
_root.displaytext2 = "";
}
Symbol 475 Button
on (press) {
if ((_global.XPpoints >= 2) && (_global.stunting == 0)) {
_global.XPpoints = _global.XPpoints - 2;
_global.stunting = 1;
_root.savedata();
_root.displaytext2 = ("Costs 2 points!\nlevel " + _global.stunting) + "/1";
}
}
on (rollOver) {
_root.displayhead = "Stunting";
_root.displaytext1 = "Use Q & E to make a quick 180 evasion turn";
_root.displaytext2 = ("Costs 2 points!\nlevel " + _global.stunting) + "/1";
}
on (rollOut) {
_root.displayhead = "";
_root.displaytext1 = "";
_root.displaytext2 = "";
}
Symbol 478 Button
on (press) {
if ((_global.XPpoints >= (_global.clusters + 1)) && (_global.clusters < 5)) {
_global.XPpoints = _global.XPpoints - (_global.clusters + 1);
_global.clusters = _global.clusters + 1;
_root.savedata();
_root.displaytext2 = ((("clusters: " + _global.clusters) + "/5\ncosts ") + (_global.clusters + 1)) + " Xp";
}
}
on (rollOver) {
_root.displayhead = "Cluster Bombs";
_root.displaytext1 = "Your Bombs/grenades release clusters upon detonation";
_root.displaytext2 = ((("clusters: " + _global.clusters) + "/5\ncosts ") + (_global.clusters + 1)) + " Xp";
}
on (rollOut) {
_root.displayhead = "";
_root.displaytext1 = "";
_root.displaytext2 = "";
}
Symbol 481 Button
on (press) {
if ((_global.XPpoints >= 3) && (_global.maxhealth < 300)) {
_global.XPpoints = _global.XPpoints - 3;
_global.maxhealth = _global.maxhealth + 100;
_root.savedata();
_root.displaytext2 = ("Costs 3 points! Armor: " + _global.maxhealth) + "/300%";
}
}
on (rollOver) {
_root.displayhead = "Armor";
_root.displaytext1 = "Increase your armor by 100% for a saver flight!";
_root.displaytext2 = ("Costs 3 points! Armor: " + _global.maxhealth) + "/300%";
}
on (rollOut) {
_root.displayhead = "";
_root.displaytext1 = "";
_root.displaytext2 = "";
}
Symbol 484 Button
on (press) {
if ((_global.XPpoints >= 2) && (_global.extralives < 5)) {
_global.XPpoints = _global.XPpoints - 2;
_global.extralives = _global.extralives + 1;
_root.savedata();
_global.lives = _global.lives + 1;
_root.displaytext2 = ("Costs 2 points!\nTotal Planes: " + (10 + _global.extralives)) + "/15";
}
}
on (rollOver) {
_root.displayhead = "Spare Planes";
_root.displaytext1 = "Can't beat the game? Start each level with extra planes!";
_root.displaytext2 = ("Costs 2 points!\nTotal Planes: " + (10 + _global.extralives)) + "/15";
}
on (rollOut) {
_root.displayhead = "";
_root.displaytext1 = "";
_root.displaytext2 = "";
}
Symbol 485 MovieClip Frame 1
vspeed = 0;
onEnterFrame = function () {
if (_y < -110) {
vspeed = 0;
_y = -110;
}
if (_y > 35) {
vspeed = 0;
_y = 35;
}
_y = (_y + vspeed);
};
Symbol 485 MovieClip Frame 3
gotoAndPlay (2);
Symbol 489 MovieClip Frame 1
nr = 1;
Symbol 489 MovieClip Frame 2
if (_global.XPpoints > 0) {
nr = nr + 1;
}
if (nr > 3) {
gotoAndPlay (12);
}
Symbol 489 MovieClip Frame 11
gotoAndPlay (2);
Symbol 489 MovieClip Frame 12
nr = nr + 1;
if (nr > 7) {
nr = 0;
gotoAndPlay (2);
}
Symbol 489 MovieClip Frame 21
gotoAndPlay (12);
Symbol 496 MovieClip [idXPscreen] Frame 1
onEnterFrame = function () {
if (_root.p2weapon == 1) {
p2w = "P2 weapon: M16";
}
if (_root.p2weapon == 2) {
p2w = "P2 weapon: Homing Missiles";
}
if ((hitbox.hitTest(_root._xmouse, _root._ymouse, false) && (idskills.vspeed < 3)) && (idskills._y < 35)) {
idskills.vspeed = idskills.vspeed + 0.2;
}
if ((!this.hitTest(_root._xmouse, _root._ymouse, false)) && (idskills.vspeed > -3)) {
idskills.vspeed = idskills.vspeed - 0.2;
}
points = _global.XPpoints + " Xp";
xp = "XP: " + _global.XP;
xpneed = "/ " + _global.XPneed;
};
Symbol 496 MovieClip [idXPscreen] Frame 3
gotoAndPlay (2);
Symbol 498 MovieClip [idrocket_homing] Frame 1
onEnterFrame = function () {
tdirec = Math.atan2(_root._ymouse - _y, _root._xmouse - _x);
if (tdirec < 0) {
tdirec = tdirec + (Math.PI*2);
}
if (tdirec > (Math.PI*2)) {
tdirec = tdirec - (Math.PI*2);
}
direc = _rotation * (Math.PI/180);
reldirec = tdirec - direc;
if (reldirec < 0) {
reldirec = reldirec + (Math.PI*2);
}
if (reldirec > (Math.PI*2)) {
reldirec = reldirec - (Math.PI*2);
}
delay = delay - 1;
if (delay < 0) {
if (delay == -1) {
snd = new Sound();
idnr = Math.floor((Math.random() * 3) + 1);
snd.attachSound("snd_rocketboost" + idnr);
snd.start();
}
if (reldirec > Math.PI) {
rotspeed = rotspeed - 0.9;
} else {
rotspeed = rotspeed + 0.9;
}
hspeed = hspeed + (power * Math.cos(_rotation * (Math.PI/180)));
vspeed = vspeed + (power * Math.sin(_rotation * (Math.PI/180)));
if (life < 0) {
call("destroy");
}
life = life - 1;
}
vspeed = vspeed + 0.05;
_x = (_x + hspeed);
_y = (_y + vspeed);
hspeed = hspeed * 0.98;
vspeed = vspeed * 0.98;
rotspeed = rotspeed * 0.95;
_rotation = (_rotation + rotspeed);
min = Math.floor(_x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(_x, _y, true)) {
call("destroy");
}
i = i + 1;
}
}
i = 42;
while (i <= (41 + _root.totalcivcars)) {
if (eval ("_root.civcar" + i).hitTest(_x, _y, true)) {
eval ("_root.civcar" + i).myhealth = 0;
mydelta = eval (("_root.civcar" + i) + "._x") - this._x;
eval ("_root.civcar" + i).hspeed = eval ("_root.civcar" + i).hspeed + (mydelta / 3);
Set(("_root.civcar" + i) + ":rotspeed", -0.4 * mydelta);
call("destroy");
}
i = i + 1;
}
i = 15;
while (i <= (14 + _root.totalcivs)) {
if (eval ("_root.civ" + i).hitTest(_x, _y, false)) {
eval ("_root.civ" + i).die = 3;
eval ("_root.civ" + i).hspeed = hspeed;
call("destroy");
}
i = i + 1;
}
i = 28;
while (i <= (27 + _root.totalenemies)) {
if (eval ("_root.enemy" + i).hitTest(_x, _y, true)) {
eval ("_root.enemy" + i).myhealth = eval ("_root.enemy" + i).myhealth - (120 + (Math.random() * 50));
mydelta = eval (("_root.enemy" + i) + "._x") - this._x;
eval ("_root.enemy" + i).rotspeed = eval ("_root.enemy" + i).rotspeed - (mydelta / 15);
eval ("_root.enemy" + i).hspeed = eval ("_root.enemy" + i).hspeed + (mydelta / 10);
call("destroy");
}
i = i + 1;
}
};
Symbol 498 MovieClip [idrocket_homing] Frame 3
if (delay < 0) {
gotoAndPlay (4);
} else {
gotoAndPlay (2);
}
Symbol 498 MovieClip [idrocket_homing] Frame 5
gotoAndPlay (4);
Symbol 498 MovieClip [idrocket_homing] Frame 6
snd.stop("snd_rocketboost" + idnr);
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , this._x);
setProperty("../explosion_1_" + expdepth, _y , this._y);
Set(("../explosion_1_" + expdepth) + ":scale", (60 - (Math.random() * 20)) + 10);
removeMovieClip("");
Symbol 510 MovieClip Frame 1
gotoAndStop(Math.floor((Math.random() * 5) + 2));
Symbol 511 MovieClip [idcivcar_dead] Frame 1
Fz = 0.5;
hitX = 0;
life = 220;
var mycolor = new Color(mybody.masked);
var myColorTransform = new Object();
myColorTransform.ra = 100;
myColorTransform.rb = rb;
myColorTransform.ga = 100;
myColorTransform.gb = gb;
myColorTransform.ba = 100;
myColorTransform.bb = bb;
myColorTransform.aa = 100;
myColorTransform.ab = 100;
mycolor.setTransform(myColorTransform);
mybody.masked.beginFill(mycolor);
mybody.masked.moveTo(-50, -10);
mybody.masked.lineTo(50, -10);
mybody.masked.lineTo(50, 10);
mybody.masked.lineTo(-50, 10);
mybody.masked.lineTo(-50, -10);
mybody.masked.endFill();
onEnterFrame = function () {
life = life - 1;
if (life <= 0) {
removeMovieClip("");
}
call("ragdoll");
hitX = hitX * 0.9;
_rotation = (_rotation - (hitX * 0.012));
rotspeed = rotspeed * 0.95;
_rotation = (_rotation + rotspeed);
hspeed = hspeed * 0.98;
vspeed = vspeed * 0.98;
vspeed = vspeed + Fz;
_x = (_x + hspeed);
_y = (_y + vspeed);
if (life < 50) {
_alpha = ((life / 50) * 100);
}
if (((_y > _root.roomheight) or (_x < -100)) or (_x > 900)) {
removeMovieClip("");
}
call("dying");
};
Symbol 511 MovieClip [idcivcar_dead] Frame 3
gotoAndPlay (2);
Symbol 511 MovieClip [idcivcar_dead] Frame 4
Fz = 0.5;
for (a in this.hitbox) {
this.localToGlobal((p = {x:this.hitbox[a]._x, y:this.hitbox[a]._y}));
min = Math.floor(p.x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y + 1, true)) {
hitX = hitX + (p.x - _x);
Fz = 0;
}
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y, true)) {
yy = 0;
while (eval ("_root.groundnr" + i).hitTest(p.x, p.y + yy, true)) {
yy = yy - 1;
}
_y = (_y + yy);
i = max;
}
i = i + 1;
}
}
}
Symbol 511 MovieClip [idcivcar_dead] Frame 9
if (Math.floor(Math.random() * 50) == 0) {
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , (this._x + (Math.random() * 50)) - 25);
yplace = (Math.random() * 30) - 15;
setProperty("../explosion_1_" + expdepth, _y , this._y + yplace);
Set(("../explosion_1_" + expdepth) + ":scale", 50 + (Math.random() * 10));
}
Symbol 513 MovieClip [idrocket_homing2] Frame 1
onEnterFrame = function () {
if ((((_x < -5) or (_x > 805)) or (_y < -5)) or (_y > (_root.roomheight + 5))) {
removeMovieClip("");
}
tdirec = Math.atan2(_root.idplane._y - _y, _root.idplane._x - _x);
if (tdirec < 0) {
tdirec = tdirec + (Math.PI*2);
}
if (tdirec > (Math.PI*2)) {
tdirec = tdirec - (Math.PI*2);
}
direc = _rotation * (Math.PI/180);
reldirec = tdirec - direc;
if (reldirec < 0) {
reldirec = reldirec + (Math.PI*2);
}
if (reldirec > (Math.PI*2)) {
reldirec = reldirec - (Math.PI*2);
}
delay = delay - 1;
if (delay < 0) {
if (delay == -1) {
snd = new Sound();
idnr = Math.floor((Math.random() * 3) + 1);
snd.attachSound("snd_rocketboost" + idnr);
snd.start();
}
if (reldirec > Math.PI) {
rotspeed = rotspeed - 0.9;
_rotation = (_rotation - 0.5);
}
if (reldirec < Math.PI) {
rotspeed = rotspeed + 0.9;
_rotation = (_rotation - 0.5);
}
hspeed = hspeed + (power * Math.cos(_rotation * (Math.PI/180)));
vspeed = vspeed + (power * Math.sin(_rotation * (Math.PI/180)));
if (life < 0) {
call("destroy");
}
life = life - 1;
}
vspeed = vspeed + 0.05;
_x = (_x + hspeed);
_y = (_y + vspeed);
hspeed = hspeed * 0.98;
vspeed = vspeed * 0.98;
rotspeed = rotspeed * 0.95;
_rotation = (_rotation + rotspeed);
min = Math.floor(_x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(_x, _y, true)) {
call("destroy");
}
i = i + 1;
}
}
if (_root.idplane.hitTest(_x, _y, true)) {
_root.idplane.myhealth = _root.idplane.myhealth - 75;
mydelta = _root.idplane._x - this._x;
_root.idplane.rotspeed = _root.idplane.rotspeed - (mydelta / 10);
_root.hspeed = _root.hspeed + (mydelta / 10);
call("destroy");
}
};
Symbol 513 MovieClip [idrocket_homing2] Frame 3
if (delay < 0) {
gotoAndPlay (4);
} else {
gotoAndPlay (2);
}
Symbol 513 MovieClip [idrocket_homing2] Frame 5
gotoAndPlay (4);
Symbol 513 MovieClip [idrocket_homing2] Frame 6
snd.stop("snd_rocketboost" + idnr);
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , this._x);
setProperty("../explosion_1_" + expdepth, _y , this._y);
Set(("../explosion_1_" + expdepth) + ":scale", 70 - (Math.random() * 10));
removeMovieClip("");
Symbol 515 MovieClip [idbullet2] Frame 1
gunsound = new Sound(this);
nr = Math.floor((Math.random() * 2) + 1);
gunsound.attachSound("snd_gunshot" + nr);
this.gunsound.setVolume(50);
gunsound.start();
onEnterFrame = function () {
hspeed = speed * Math.cos(_rotation * (Math.PI/180));
vspeed = speed * Math.sin(_rotation * (Math.PI/180));
_x = (_x + hspeed);
_y = (_y + vspeed);
if ((((_x < -5) or (_x > 805)) or (_y < -5)) or (_y > (_root.roomheight + 5))) {
call("destroy");
}
min = Math.floor(_x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(this._x, this._y, true)) {
call("destroy");
}
i = i + 1;
}
}
if (_root.idplane.hitTest(_x, _y, true)) {
_root.idplane.myhealth = _root.idplane.myhealth - (2 + (Math.random() * 3));
xdelta = _root.idplane._x - _x;
_root.idplane.rotspeed = _root.idplane.rotspeed + (xdelta / 5);
removeMovieClip("");
}
};
Symbol 515 MovieClip [idbullet2] Frame 3
gotoAndPlay (2);
Symbol 515 MovieClip [idbullet2] Frame 4
removeMovieClip("");
Symbol 522 MovieClip [idarmyjeep] Frame 1
hspeed = Math.round((Math.random() * 12) - 6);
vspeed = 0;
rotspeed = 0;
Fz = 0.5;
hitX = 0;
keepdistance = 420 - (Math.random() * 650);
myhealth = (120 + (Math.random() * 40)) + ((_global.bossnr - 1) * 40);
arm1.gotoAndStop(7);
arm2.gotoAndStop(7);
pilotbody.gotoAndStop(7);
var id;
nr = Math.floor(Math.random() * 10) + 1;
switch (nr) {
case 1 :
id = "idarmy_stationarybazooka";
reloadtime = 75;
break;
default :
id = "idarmy_stationarygun";
reloadtime = 15;
}
this.attachMovie(id, "gun", this.getNextHighestDepth());
this.gun._x = 26;
this.gun._y = -30;
idgun = this.gun;
this.idgun.reloadtime = reloadtime;
if ((_root.wantedlevel >= 600) && (Math.random() > 0.3)) {
armor._alpha = 100;
myhealth = myhealth * 3;
if (Math.random() < 0.2) {
this.gun.reloadtime = this.gun.reloadtime * (1 - (Math.random() / 2));
}
if (Math.random() < 0.3) {
id = "idarmy_stationarybazooka";
this.attachMovie(id, "gun2", this.getNextHighestDepth());
this.gun2._x = -26;
this.gun2._y = -30;
idgun = this.gun2;
this.idgun.reloadtime = reloadtime;
}
}
onEnterFrame = function () {
dep = this.getDepth();
if (dep != 28) {
if (_root.getInstanceAtDepth(dep - 1) == undefined) {
this.swapDepths(dep - 1);
this._name = "enemy" + (dep - 1);
}
}
if (myhealth <= 0) {
call("die1");
}
call("ragdoll");
if ((_root.idplane._x + keepdistance) < _x) {
hspeed = hspeed - 1;
}
if ((_root.idplane._x - keepdistance) > _x) {
hspeed = hspeed + 1;
}
hitX = hitX * 0.9;
rotspeed = rotspeed * 0.9;
_rotation = (_rotation + rotspeed);
_rotation = (_rotation - (hitX * 0.02));
hspeed = hspeed * 0.95;
vspeed = vspeed * 0.9;
vspeed = vspeed + Fz;
_x = (_x + hspeed);
_y = (_y + vspeed);
wheelrot = -Math.abs((hspeed / 62.8318530717959) * 360);
rwheel._rotation = rwheel._rotation + wheelrot;
lwheel._rotation = lwheel._rotation + wheelrot;
if (((_y > _root.roomheight) or (_x < -100)) or (_x > 900)) {
call("destroy");
}
};
Symbol 522 MovieClip [idarmyjeep] Frame 3
gotoAndPlay (2);
Symbol 522 MovieClip [idarmyjeep] Frame 4
Fz = 0.5;
for (a in this.hitbox) {
this.localToGlobal((p = {x:this.hitbox[a]._x, y:this.hitbox[a]._y}));
min = Math.floor(p.x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y + 1, true)) {
hitX = hitX + (p.x - _x);
Fz = 0;
vspeed = 0;
if ((_rotation > 90) or (_rotation < -90)) {
call("die1");
}
}
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y, true)) {
yy = 0;
while (eval ("_root.groundnr" + i).hitTest(p.x, p.y + yy, true)) {
yy = yy - 1;
}
_y = (_y + yy);
i = max;
}
i = i + 1;
}
}
}
Symbol 522 MovieClip [idarmyjeep] Frame 9
_root.totalenemies = _root.totalenemies - 1;
removeMovieClip("");
Symbol 522 MovieClip [idarmyjeep] Frame 14
_root.adrenaline = _root.adrenaline + ((Math.random() * 5) + 15);
_root.wantedlevel = _root.wantedlevel + 20;
_global.XP = _global.XP + 100;
tellTarget (gun) {
call("destroy");
};
if (gun2 != undefined) {
tellTarget (gun2) {
call("destroy");
};
}
i = 3;
while (i >= 1) {
nr = _root.getNextHighestDepth();
_root.attachMovie("idjunk", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", _x + ((-38 + ((i - 1) * 26)) * Math.cos(_rotation * (Math.PI/180))));
Set(("_root.limb" + nr) + "._y", _y + ((-38 + ((i - 1) * 25)) * Math.sin(_rotation * (Math.PI/180))));
eval ("_root.limb" + nr).attachMovie("idarmyjeep_dead", "New", 1);
eval ("_root.limb" + nr).New.gotoAndStop(i);
Set(("_root.limb" + nr) + "._rotation", _rotation);
Set(("_root.limb" + nr) + ":hspeed", ((hspeed / 2) + (Math.random() * 5)) - 2.5);
Set(("_root.limb" + nr) + ":vspeed", ((vspeed / 2) + (Math.random() * 8)) - 12);
Set(("_root.limb" + nr) + ":rotspeed", (Math.random() * 40) - 20);
i = i - 1;
}
this.localToGlobal((p = {x:this.pilot._x, y:this.pilot._y}));
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_head1", "head", 1);
eval (("_root.limb" + nr) + ".head").gotoAndStop(pilot._currentframe);
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_eye1", "eye", 1);
if (Math.floor(Math.random() * 4) == 0) {
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_brains1", "brains", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
}
this.localToGlobal((p = {x:this.rwheel._x, y:this.rwheel._y}));
nr = _root.getNextHighestDepth();
_root.attachMovie("idjunk", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("idarmyjeep_wheel", "New", 1);
Set(("_root.limb" + nr) + ":hspeed", ((hspeed / 2) + (Math.random() * 5)) - 2.5);
Set(("_root.limb" + nr) + ":vspeed", ((vspeed / 2) + (Math.random() * 8)) - 12);
Set(("_root.limb" + nr) + ":rotspeed", (Math.random() * 40) - 20);
this.localToGlobal((p = {x:this.lwheel._x, y:this.lwheel._y}));
nr = _root.getNextHighestDepth();
_root.attachMovie("idjunk", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("idarmyjeep_wheel", "New", 1);
Set(("_root.limb" + nr) + ":hspeed", ((hspeed / 2) + (Math.random() * 5)) - 2.5);
Set(("_root.limb" + nr) + ":vspeed", ((vspeed / 2) + (Math.random() * 8)) - 12);
Set(("_root.limb" + nr) + ":rotspeed", (Math.random() * 40) - 20);
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , (this._x + (Math.random() * 50)) - 25);
setProperty("../explosion_1_" + expdepth, _y , (this._y + (Math.random() * 50)) - 25);
Set(("../explosion_1_" + expdepth) + ":scale", 80 + (Math.random() * 30));
call("destroy");
Symbol 529 MovieClip [idgun_dead] Frame 1
Fz = 0.4;
life = Math.random(25) + 75;
onEnterFrame = function () {
vspeed = vspeed + Fz;
vspeed = vspeed * 0.99;
hspeed = hspeed * 0.99;
_rotation = (_rotation + rotspeed);
rotspeed = rotspeed * 0.99;
_y = (_y + vspeed);
_x = (_x + hspeed);
if (life <= 25) {
_alpha = ((life / 25) * 100);
shoot = 0;
}
life = life - 1;
if (life <= 0) {
removeMovieClip("");
}
bulletshoot = bulletshoot - 1;
if ((shoot == 1) and (bulletshoot <= 0)) {
bulletshoot = _global.bulletdelay;
_root.bulletnr = _root.bulletnr + 1;
if (_root.bulletnr >= 100) {
_root.bulletnr = 0;
}
_root.attachMovie("idbullet", "bullet" + _root.bulletnr, _root.getNextHighestDepth());
Set(("../bullet" + _root.bulletnr) + ":speed", _root.bulletspeed + (Math.random(1) * 5));
setProperty("../bullet" + _root.bulletnr, _rotation , (_rotation + (Math.random(1) * 4)) - 2);
if (_yscale == 100) {
nr = 8;
} else {
nr = -8;
}
setProperty("../bullet" + _root.bulletnr, _x , _x + (30 * Math.cos((_rotation + nr) * (Math.PI/180))));
setProperty("../bullet" + _root.bulletnr, _y , _y + (30 * Math.sin((_rotation + nr) * (Math.PI/180))));
}
};
Symbol 529 MovieClip [idgun_dead] Frame 3
gotoAndPlay (2);
Symbol 532 MovieClip [idarmy_stationarygun] Frame 1
var reloadtime;
arm1.gotoAndStop(7);
arm2.gotoAndStop(7);
body.gotoAndStop(7);
body._xscale = -50;
mygun.rotspeed = 0;
shoot = 25 + (Math.random() * 10);
count = 5;
if (_parent._xscale == -100) {
_xscale = -100;
}
onEnterFrame = function () {
count = count - 1;
if (count <= 0) {
count = 5;
this.localToGlobal((p = {x:mygun._x, y:mygun._y}));
mygun.tdirec = Math.atan2(_root.idplane._y - p.y, _root.idplane._x - p.x);
if (mygun.tdirec < 0) {
mygun.tdirec = mygun.tdirec + (Math.PI*2);
}
if (mygun.tdirec > (Math.PI*2)) {
mygun.tdirec = mygun.tdirec - (Math.PI*2);
}
mygun.direc = (_parent._rotation + mygun._rotation) * (Math.PI/180);
mygun.reldirec = mygun.tdirec - mygun.direc;
if (mygun.reldirec < 0) {
mygun.reldirec = mygun.reldirec + (Math.PI*2);
}
if (mygun.reldirec > (Math.PI*2)) {
mygun.reldirec = mygun.reldirec - (Math.PI*2);
}
turning = 4;
if (mygun.reldirec > Math.PI) {
mygun.rotspeed = mygun.rotspeed - turning;
}
if (mygun.reldirec < Math.PI) {
mygun.rotspeed = mygun.rotspeed + turning;
}
if ((mygun._rotation > 90) or (mygun._rotation < -90)) {
mygun._yscale = 100;
} else {
mygun._yscale = -100;
}
}
mygun.rotspeed = mygun.rotspeed * 0.8;
mygun._rotation = mygun._rotation + mygun.rotspeed;
shoot = shoot - 1;
if (((shoot <= 0) && (_root.idplane != undefined)) && (Math.abs(mygun.reldirec) < 0.1)) {
call("shoot");
}
};
Symbol 532 MovieClip [idarmy_stationarygun] Frame 3
gotoAndPlay (2);
Symbol 532 MovieClip [idarmy_stationarygun] Frame 4
shoot = reloadtime;
this.localToGlobal((p = {x:mygun._x, y:mygun._y}));
_root.bulletnr = _root.bulletnr + 1;
if (_root.bulletnr >= 100) {
_root.bulletnr = 0;
}
_root.attachMovie("idbullet2", "bullet" + _root.bulletnr, _root.getNextHighestDepth());
Set(("_root.bullet" + _root.bulletnr) + ":speed", 25 + (Math.random(1) * 5));
setProperty("_root.bullet" + _root.bulletnr, _rotation , ((_parent._rotation + this.mygun._rotation) + (Math.random(1) * 16)) - 8);
nr = 0;
if (mygun._yscale == 100) {
nr = 2;
} else {
nr = -2;
}
setProperty("_root.bullet" + _root.bulletnr, _x , p.x + (30 * Math.cos(((_parent._rotation + this.mygun._rotation) + nr) * (Math.PI/180))));
setProperty("_root.bullet" + _root.bulletnr, _y , p.y + (30 * Math.sin(((_parent._rotation + this.mygun._rotation) + nr) * (Math.PI/180))));
Symbol 532 MovieClip [idarmy_stationarygun] Frame 9
this.localToGlobal((p = {x:head._x, y:head._y}));
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_head1", "head", 1);
eval (("_root.limb" + nr) + ".head").gotoAndStop(head._currentframe);
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_eye1", "eye", 1);
if (Math.floor(Math.random() * 4) == 0) {
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_brains1", "brains", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
}
nr = _root.getNextHighestDepth();
_root.attachMovie("idgun_dead", "limb" + nr, nr);
this.localToGlobal((p = {x:this.mygun._x, y:this.mygun._y}));
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
Set(("_root.limb" + nr) + "._rotation", _parent._rotation + mygun._rotation);
Set(("_root.limb" + nr) + ":hspeed", ((_parent.hspeed / 2) + (Math.random() * 5)) - 2.5);
Set(("_root.limb" + nr) + ":vspeed", ((_parent.vspeed / 2) + (Math.random() * 8)) - 12);
Set(("_root.limb" + nr) + ":rotspeed", (Math.random() * 40) - 20);
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:body._x, y:body._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("c_body1", "body", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
eval (("_root.limb" + nr) + ".body").gotoAndStop(body._currentframe);
Symbol 534 MovieClip [idgrenade] Frame 1
rotspeed = (Math.random() * 30) - 15;
life = 75;
Fz = 0.4;
onEnterFrame = function () {
life = life - 1;
if (life <= 0) {
call("destroy");
}
rotspeed = rotspeed * 0.95;
_rotation = (_rotation + rotspeed);
vspeed = vspeed + Fz;
_x = (_x + hspeed);
_y = (_y + vspeed);
hspeed = hspeed * 0.98;
vspeed = vspeed * 0.98;
min = Math.floor(_x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(_x, _y, true)) {
while (eval ("_root.groundnr" + i).hitTest(_x, _y, true)) {
_y = (_y - 1);
}
vspeed = vspeed * -0.8;
if (Math.abs(vspeed) < 1) {
Fz = 0;
vspeed = 0;
}
}
i = i + 1;
}
}
i = 42;
while (i <= (41 + _root.totalcivcars)) {
if (eval ("_root.civcar" + i).hitTest(_x, _y, true)) {
eval ("_root.civcar" + i).myhealth = 0;
mydelta = eval (("_root.civcar" + i) + "._x") - this._x;
eval ("_root.civcar" + i).hspeed = eval ("_root.civcar" + i).hspeed + (mydelta / 2);
Set(("_root.civcar" + i) + ":rotspeed", -0.6 * mydelta);
call("destroy");
}
i = i + 1;
}
i = 15;
while (i <= (14 + _root.totalcivs)) {
if (eval ("_root.civ" + i).hitTest(_x, _y, false)) {
eval ("_root.civ" + i).die = 3;
eval ("_root.civ" + i).hspeed = hspeed * 4;
call("destroy");
}
i = i + 1;
}
i = 28;
while (i <= (27 + _root.totalenemies)) {
if (eval ("_root.enemy" + i).hitTest(_x, _y, true)) {
eval ("_root.enemy" + i).myhealth = eval ("_root.enemy" + i).myhealth - (150 + (Math.random() * 50));
mydelta = eval (("_root.enemy" + i) + "._x") - this._x;
eval ("_root.enemy" + i).rotspeed = eval ("_root.enemy" + i).rotspeed - (mydelta / 15);
eval ("_root.enemy" + i).hspeed = eval ("_root.enemy" + i).hspeed + (mydelta / 10);
call("destroy");
}
i = i + 1;
}
if ((((_x < -5) or (_x > 805)) or (_y < -5)) or (_y > (_root.roomheight + 5))) {
removeMovieClip("");
}
};
Symbol 534 MovieClip [idgrenade] Frame 4
gotoAndPlay (2);
Symbol 534 MovieClip [idgrenade] Frame 5
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , this._x);
setProperty("../explosion_1_" + expdepth, _y , this._y);
Set(("_root.explosion_1_" + expdepth) + ":scale", 90 - (Math.random() * 20));
i = 0;
while (i < _global.clusters) {
nr = _root.getNextHighestDepth();
_root.attachMovie("idbomb_fragment", "new_" + nr, nr);
setProperty("../new_" + nr, _x , this._x);
setProperty("../new_" + nr, _y , this._y - this.vspeed);
Set(("_root.new_" + nr) + ":hspeed", (Math.random() * 16) - 8);
Set(("_root.new_" + nr) + ":vspeed", (Math.random() * -4) - 2);
i = i + 1;
}
removeMovieClip("");
Symbol 538 MovieClip [idarmy_stationarybazooka] Frame 1
var reloadtime;
arm1.gotoAndStop(7);
arm2.gotoAndStop(7);
body.gotoAndStop(7);
body._xscale = -50;
mygun.rotspeed = 0;
shoot = 75 + (Math.random() * 50);
if (_parent._xscale == -100) {
_xscale = -100;
}
onEnterFrame = function () {
count = count - 1;
if (count <= 0) {
count = 5;
this.localToGlobal((p = {x:mygun._x, y:mygun._y}));
mygun.tdirec = Math.atan2(_root.idplane._y - p.y, _root.idplane._x - p.x);
if (mygun.tdirec < 0) {
mygun.tdirec = mygun.tdirec + (Math.PI*2);
}
if (mygun.tdirec > (Math.PI*2)) {
mygun.tdirec = mygun.tdirec - (Math.PI*2);
}
mygun.direc = (_parent._rotation + mygun._rotation) * (Math.PI/180);
mygun.reldirec = mygun.tdirec - mygun.direc;
if (mygun.reldirec < 0) {
mygun.reldirec = mygun.reldirec + (Math.PI*2);
}
if (mygun.reldirec > (Math.PI*2)) {
mygun.reldirec = mygun.reldirec - (Math.PI*2);
}
turning = 4;
if (mygun.reldirec > Math.PI) {
mygun.rotspeed = mygun.rotspeed - turning;
}
if (mygun.reldirec < Math.PI) {
mygun.rotspeed = mygun.rotspeed + turning;
}
if ((mygun._rotation > 90) or (mygun._rotation < -90)) {
mygun._yscale = 100;
} else {
mygun._yscale = -100;
}
}
shoot = shoot - 1;
if (((shoot <= 0) && (_root.idplane != undefined)) && (Math.abs(mygun.reldirec) < 0.1)) {
call("shoot");
}
mygun.rotspeed = mygun.rotspeed * 0.8;
mygun._rotation = mygun._rotation + mygun.rotspeed;
};
Symbol 538 MovieClip [idarmy_stationarybazooka] Frame 3
gotoAndPlay (2);
Symbol 538 MovieClip [idarmy_stationarybazooka] Frame 4
shoot = reloadtime + (Math.random() * 25);
this.localToGlobal((p = {x:mygun._x, y:mygun._y}));
snd = new Sound();
nr = Math.floor((Math.random() * 3) + 1);
snd.attachSound("snd_releasebomb" + nr);
snd.start();
_root.rocketnr = _root.rocketnr + 1;
if (_root.rocketnr >= 50) {
_root.rocketnr = 0;
}
_root.attachMovie("idrocket_2", "rocket" + _root.rocketnr, _root.getNextHighestDepth());
Set(("_root.rocket" + _root.rocketnr) + ":power", 2);
Set(("_root.rocket" + _root.rocketnr) + ":rotspeed", (Math.random() * 2) - 2);
Set(("_root.rocket" + _root.rocketnr) + ":hspeed", _parent.hspeed + (3 * Math.cos((_rotation + 90) * (Math.PI/180))));
Set(("_root.rocket" + _root.rocketnr) + ":vspeed", _parent.vspeed + (3 * Math.sin((_rotation + 90) * (Math.PI/180))));
Set(("_root.rocket" + _root.rocketnr) + ":life", 20 + (Math.random() * 10));
Set(("_root.rocket" + _root.rocketnr) + ":delay", 0);
Set(("_root.rocket" + _root.rocketnr) + "._rotation", _parent._rotation + mygun._rotation);
Set(("_root.rocket" + _root.rocketnr) + "._x", p.x + (25 * Math.cos((_parent._rotation + mygun._rotation) * (Math.PI/180))));
Set(("_root.rocket" + _root.rocketnr) + "._y", p.y + (25 * Math.sin((_parent._rotation + mygun._rotation) * (Math.PI/180))));
Symbol 538 MovieClip [idarmy_stationarybazooka] Frame 9
this.localToGlobal((p = {x:head._x, y:head._y}));
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_head1", "head", 1);
eval (("_root.limb" + nr) + ".head").gotoAndStop(head._currentframe);
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_eye1", "eye", 1);
if (Math.floor(Math.random() * 4) == 0) {
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_brains1", "brains", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
}
nr = _root.getNextHighestDepth();
this.localToGlobal((p = {x:body._x, y:body._y}));
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("c_body1", "body", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
eval (("_root.limb" + nr) + ".body").gotoAndStop(body._currentframe);
Symbol 540 MovieClip [idrocket_2] Frame 1
onEnterFrame = function () {
delay = delay - 1;
if (delay < 0) {
if (delay == -1) {
snd = new Sound();
idnr = Math.floor((Math.random() * 3) + 1);
snd.attachSound("snd_rocketboost" + idnr);
snd.start();
}
chc = Math.floor(Math.random(1) * 10);
if (chc == 0) {
rotspeed = (Math.random(1) * 7) - 3;
}
_rotation = (_rotation + rotspeed);
hspeed = hspeed + (power * Math.cos(_rotation * (Math.PI/180)));
vspeed = vspeed + (power * Math.sin(_rotation * (Math.PI/180)));
if (life < 0) {
call("destroy");
}
life = life - 1;
}
vspeed = vspeed + 0.05;
_x = (_x + hspeed);
_y = (_y + vspeed);
hspeed = hspeed * 0.98;
vspeed = vspeed * 0.98;
min = Math.floor(_x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(_x, _y, true)) {
call("destroy");
}
i = i + 1;
}
}
if (_root.idplane.hitTest(_x, _y, true)) {
_root.idplane.myhealth = _root.idplane.myhealth - (50 + (Math.random() * 20));
mydelta = _root.idplane._x - this._x;
_root.idplane.rotspeed = _root.idplane.rotspeed - (mydelta / 10);
_root.hspeed = _root.hspeed + (mydelta / 10);
call("destroy");
}
};
Symbol 540 MovieClip [idrocket_2] Frame 3
if (delay < 0) {
gotoAndPlay (4);
} else {
gotoAndPlay (2);
}
Symbol 540 MovieClip [idrocket_2] Frame 5
gotoAndPlay (4);
Symbol 540 MovieClip [idrocket_2] Frame 6
snd.stop("snd_rocketboost" + idnr);
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , this._x);
setProperty("../explosion_1_" + expdepth, _y , this._y);
Set(("../explosion_1_" + expdepth) + ":scale", 60 - (Math.random() * 10));
removeMovieClip("");
Symbol 547 MovieClip Frame 1
onEnterFrame = function () {
gotoAndPlay((_currentframe + Math.round(_parent.hhspeed / 2)) - 1);
};
Symbol 549 MovieClip Frame 1
onEnterFrame = function () {
gotoAndPlay((_currentframe + Math.round(_parent.hhspeed / 2)) - 1);
};
Symbol 578 MovieClip [idCB_animations] Frame 1
if (this._parent == _root) {
Fz = 0.4;
vspeed = ((-Math.random()) * 2) - 0.5;
hspeed = hspeed + ((Math.random() * 5) + 2);
rotspeed = (Math.random() * 30) - 15;
gotoAndPlay ("die");
onEnterFrame = function () {
vspeed = vspeed + Fz;
vspeed = vspeed * 0.99;
hspeed = hspeed * 0.99;
_rotation = (_rotation + rotspeed);
rotspeed = rotspeed * 0.99;
_y = (_y + vspeed);
_x = (_x + hspeed);
if (((_x < -100) or (_x > 900)) or (_y > (_root.roomheight + 100))) {
removeMovieClip("");
}
};
}
Symbol 578 MovieClip [idCB_animations] Frame 26
cnc = Math.floor(Math.random() * 10) + 1;
switch (cnc) {
case 1 :
case 2 :
case 3 :
gotoAndPlay ("blink");
break;
case 4 :
gotoAndPlay ("facing");
break;
case 5 :
gotoAndPlay ("lookdown");
break;
case 10 :
if (Math.random() > 0.5) {
gotoAndPlay ("talk1");
} else {
gotoAndPlay ("talk2");
}
break;
default :
gotoAndPlay ("normal");
}
Symbol 578 MovieClip [idCB_animations] Frame 31
cnc = Math.floor(Math.random() * 3);
switch (cnc) {
case 1 :
gotoAndPlay ("openright");
break;
case 2 :
gotoAndPlay ("openleft");
break;
default :
gotoAndPlay (28);
}
Symbol 578 MovieClip [idCB_animations] Frame 34
gotoAndPlay ("normal");
Symbol 578 MovieClip [idCB_animations] Frame 50
if (Math.random() < 0.6) {
gotoAndPlay (39);
}
Symbol 578 MovieClip [idCB_animations] Frame 53
gotoAndPlay ("normal");
Symbol 578 MovieClip [idCB_animations] Frame 71
if (Math.random() < 0.3) {
gotoAndPlay ("normal");
} else {
gotoAndPlay ("facing");
}
Symbol 578 MovieClip [idCB_animations] Frame 92
if (Math.random() < 0.4) {
gotoAndPlay (79);
}
Symbol 578 MovieClip [idCB_animations] Frame 99
gotoAndPlay ("normal");
Symbol 578 MovieClip [idCB_animations] Frame 204
gotoAndPlay ("normal");
Symbol 578 MovieClip [idCB_animations] Frame 288
gotoAndPlay ("normal");
Symbol 578 MovieClip [idCB_animations] Frame 395
gotoAndPlay ("normal");
Symbol 578 MovieClip [idCB_animations] Frame 438
stop();
Symbol 587 MovieClip [idFulp_animations] Frame 1
function getnewframe() {
cnc = Math.floor(Math.random() * 20) + 1;
switch (cnc) {
case 9 :
gotoAndPlay ("talk1");
return;
case 10 :
if (Math.random() > 0.5) {
gotoAndPlay ("talk2");
} else {
gotoAndPlay ("talk3");
}
return;
case 11 :
case 12 :
case 13 :
case 14 :
case 15 :
_xscale = 100;
gotoAndPlay ("normal");
return;
case 16 :
_xscale = -100;
gotoAndPlay ("normal");
return;
default :
gotoAndPlay ("normal");
}
}
if (this._parent == _root) {
Fz = 0.4;
vspeed = ((-Math.random()) * 2) - 0.5;
hspeed = hspeed + ((Math.random() * 5) + 2);
rotspeed = (Math.random() * 30) - 15;
gotoAndPlay ("talk1");
onEnterFrame = function () {
vspeed = vspeed + Fz;
vspeed = vspeed * 0.99;
hspeed = hspeed * 0.99;
_rotation = (_rotation + rotspeed);
rotspeed = rotspeed * 0.99;
_y = (_y + vspeed);
_x = (_x + hspeed);
if (((_x < -100) or (_x > 900)) or (_y > (_root.roomheight + 100))) {
removeMovieClip("");
}
};
}
Symbol 587 MovieClip [idFulp_animations] Frame 25
getnewframe();
Symbol 587 MovieClip [idFulp_animations] Frame 66
if (this._parent == _root) {
stop();
} else {
gotoAndPlay ("normal");
}
Symbol 587 MovieClip [idFulp_animations] Frame 134
gotoAndPlay ("normal");
Symbol 590 MovieClip [idboss_sbc] Frame 1
if (this._parent == _root) {
Fz = 0.4;
vspeed = ((-Math.random()) * 2) - 0.5;
hspeed = hspeed + ((Math.random() * 5) + 2);
rotspeed = (Math.random() * 30) - 15;
onEnterFrame = function () {
vspeed = vspeed + Fz;
vspeed = vspeed * 0.99;
hspeed = hspeed * 0.99;
_rotation = (_rotation + rotspeed);
rotspeed = rotspeed * 0.99;
_y = (_y + vspeed);
_x = (_x + hspeed);
if (((_x < -100) or (_x > 900)) or (_y > (_root.roomheight + 100))) {
removeMovieClip("");
}
};
}
Symbol 590 MovieClip [idboss_sbc] Frame 3
gotoAndPlay (2);
Symbol 591 MovieClip Frame 7
if (_currentframe == 1) {
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , (this._x + (Math.random() * 50)) - 25);
setProperty("../explosion_1_" + expdepth, _y , (this._y + (Math.random() * 50)) - 25);
Set(("../explosion_1_" + expdepth) + ":scale", 80 + (Math.random() * 30));
}
if (_currentframe == 2) {
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , (this._x + (Math.random() * 50)) - 25);
setProperty("../explosion_1_" + expdepth, _y , (this._y + (Math.random() * 50)) - 25);
Set(("../explosion_1_" + expdepth) + ":scale", 80 + (Math.random() * 30));
}
if (_currentframe == 3) {
this.localToGlobal((p = {x:this.cb_boss._x + 5.8, y:this.cb_boss._y - 40}));
nr = _root.getNextHighestDepth();
_root.attachMovie("idCB_animations", "new" + nr, nr);
Set(("_root.new" + nr) + "._x", p.x);
Set(("_root.new" + nr) + "._y", p.y);
Set(("_root.new" + nr) + "._width", 35);
Set(("_root.new" + nr) + "._height", 54);
Set(("_root.new" + nr) + "._rotation", _parent._rotation + this.cb_boss._rotation);
Set(("_root.new" + nr) + ":hspeed", _parent.hhspeed);
}
if (_currentframe == 4) {
this.localToGlobal((p = {x:this.fulpboss._x, y:this.fulpboss._y}));
nr = _root.getNextHighestDepth();
_root.attachMovie("idFulp_animations", "new" + nr, nr);
Set(("_root.new" + nr) + "._x", p.x);
Set(("_root.new" + nr) + "._y", p.y);
Set(("_root.new" + nr) + "._rotation", _parent._rotation + this.cb_boss._rotation);
Set(("_root.new" + nr) + ":hspeed", _parent.hhspeed);
}
if (_currentframe == 5) {
this.localToGlobal((p = {x:this.boss_sbc._x, y:this.boss_sbc._y}));
nr = _root.getNextHighestDepth();
_root.attachMovie("idboss_sbc", "new" + nr, nr);
Set(("_root.new" + nr) + "._x", p.x);
Set(("_root.new" + nr) + "._y", p.y);
Set(("_root.new" + nr) + "._rotation", _parent._rotation + this.cb_boss._rotation);
Set(("_root.new" + nr) + ":hspeed", _parent.hhspeed);
Set(("_root.new" + nr) + "._xscale", 69);
Set(("_root.new" + nr) + "._yscale", 81);
}
Symbol 592 MovieClip [idngtank] Frame 1
Fz = 0.5;
vspeed = 0;
hspeed = 0;
hitX = 0;
keepdistance = 250;
goback = 0;
shootdelay = 150;
shoot = 50;
call("getboss");
nr = _root.getNextHighestDepth();
myhealthbar = this.attachMovie("idboss_healthbar", "myhealthbar" + nr, nr);
myhealthbar._y = 60;
onEnterFrame = function () {
dep = this.getDepth();
if (dep != 28) {
if (_root.getInstanceAtDepth(dep - 1) == undefined) {
this.swapDepths(dep - 1);
this._name = "enemy" + (dep - 1);
}
}
if (myhealth <= 0) {
call("destroy");
}
if ((_root.idplane._x + keepdistance) < _x) {
hhspeed = hhspeed - 0.5;
}
if ((_root.idplane._x - keepdistance) > _x) {
hhspeed = hhspeed + 0.5;
}
if (goback == 1) {
if (_x < 50) {
_x = 50;
}
} else {
hhspeed = hhspeed + 1;
if (_x > 50) {
goback = 1;
}
}
call("coll");
call("cannon");
hitX = hitX * 0.8;
_rotation = (_rotation - (hitX * 0.0015));
hhspeed = hhspeed * 0.94;
hspeed = hspeed * 0.9;
vspeed = vspeed * 0.9;
vspeed = vspeed + Fz;
_x = (_x + (hhspeed + (hspeed / 5)));
_y = (_y + vspeed);
myhealthbar._x = 100;
myhealthbar._rotation = -_rotation;
if (_y > _root.roomheight) {
_x = -230;
_y = (_root.idcontroller_ground.startheight2 - 230);
}
};
Symbol 592 MovieClip [idngtank] Frame 3
gotoAndPlay (2);
Symbol 592 MovieClip [idngtank] Frame 4
Fz = 0.5;
for (a in this.hitbox) {
this.localToGlobal((p = {x:this.hitbox[a]._x, y:this.hitbox[a]._y}));
min = Math.floor(p.x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y + 1, true)) {
hitX = hitX + (p.x - _x);
Fz = 0;
vspeed = 0;
}
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y, true)) {
yy = 0;
while (eval ("_root.groundnr" + i).hitTest(p.x, p.y + yy, true)) {
yy = yy - 1;
}
_y = (_y + yy);
i = max;
}
i = i + 1;
}
}
}
i = 42;
while (i <= (41 + _root.totalcivcars)) {
if (this.hitTest(eval ("_root.civcar" + i)._x, eval ("_root.civcar" + i)._y, true)) {
eval ("_root.civcar" + i).myhealth = 0;
mydelta = eval (("_root.civcar" + i) + "._x") - this._x;
eval ("_root.civcar" + i).rotspeed = eval ("_root.civcar" + i).rotspeed - (mydelta / 20);
}
i = i + 1;
}
i = 15;
while (i <= (14 + _root.totalcivs)) {
if (this.hitTest(eval ("_root.civ" + i)._x - 10, eval ("_root.civ" + i)._y - 20, true)) {
eval ("_root.civ" + i).die = 3;
eval ("_root.civ" + i).hspeed = eval ("_root.civ" + i).hspeed + (hspeed / 6);
}
i = i + 1;
}
Symbol 592 MovieClip [idngtank] Frame 9
this.localToGlobal((p = {x:this.myturret._x, y:this.myturret._y}));
tdirec = Math.atan2(_root.idplane._y - p.y, _root.idplane._x - p.x);
if (tdirec < 0) {
tdirec = tdirec + (Math.PI*2);
}
if (tdirec > (Math.PI*2)) {
tdirec = tdirec - (Math.PI*2);
}
direc = (_rotation + myturret._rotation) * (Math.PI/180);
reldirec = tdirec - direc;
if (reldirec < 0) {
reldirec = reldirec + (Math.PI*2);
}
if (reldirec > (Math.PI*2)) {
reldirec = reldirec - (Math.PI*2);
}
if (Math.abs(reldirec) > 0.1) {
if (reldirec > Math.PI) {
myturret._rotation = myturret._rotation - 0.5;
}
if (reldirec < Math.PI) {
myturret._rotation = myturret._rotation + 0.5;
}
}
if (myturret._rotation > 45) {
myturret._rotation = 45;
}
if (myturret._rotation < -65) {
myturret._rotation = -65;
}
if (_root.idplane != undefined) {
shoot = shoot - 1;
}
if ((shoot <= 0) && (_root.idplane._x > (p.x + (155 * Math.cos(direc))))) {
shoot = shootdelay;
myexpl = _root.attachMovie("idexplosion_2", "explup", _root.getNextHighestDepth());
_root.explup._x = p.x + (155 * Math.cos(direc));
_root.explup._y = p.y + (155 * Math.sin(direc));
Set("_root.explup:scale", 200);
_root.explup._rotation = direc * 57.2957795130823;
if (reldirec < 0.15) {
_root.idplane.myhealth = _root.idplane.myhealth - 150;
_root.attachMovie("idexplosion_1", "new", _root.getNextHighestDepth());
_root.new._x = (_root.idplane._x + (Math.random() * 30)) - 15;
_root.new._y = (_root.idplane._y + (Math.random() * 30)) - 15;
Set("_root.new:scale", 150);
}
}
if (myexpl != undefined) {
myexpl._x = p.x + (155 * Math.cos(direc));
myexpl._y = p.y + (155 * Math.sin(direc));
}
if ((_root.idplane._x < p.x) && ((shoot / 15) == Math.round(shoot / 15))) {
call("rocket");
}
Symbol 592 MovieClip [idngtank] Frame 15
_root.totalenemies = _root.totalenemies - 1;
_root.wantedlevel = 0;
_global.XP = _global.XP + (3000 + (_global.bossnr * 500));
_global.bossnr = _global.bossnr + 1;
_global.lives = 10 + _global.extralives;
_root.idplane.myhealth = _global.maxhealth;
_root.attachMovie("idngtank_dead", "deadtank", this.getDepth() + 1);
_root.deadtank._x = _x;
_root.deadtank._y = _y;
_root.deadtank._rotation = _rotation;
Set("_root.deadtank:hhspeed", hhspeed);
Set("_root.deadtank:vspeed", vspeed);
Set("_root.deadtank:hitX", hitX);
_root.deadtank.myturret._rotation = myturret._rotation;
_root.deadtank.lwheel._currentframe = wheel._currentframe;
_root.deadtank.rwheel._currentframe = wheel._currentframe;
if (_global.bossnr == 4) {
_root.deadtank._xscale = _xscale;
_root.deadtank._yscale = _yscale;
}
i = 0;
while (i < 5) {
i = i + 1;
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , (this._x + (Math.random() * 200)) - 100);
setProperty("../explosion_1_" + expdepth, _y , (this._y + (Math.random() * 200)) - 100);
Set(("../explosion_1_" + expdepth) + ":scale", 100 + (Math.random() * 100));
}
tellTarget (gun1) {
call("destroy");
};
tellTarget (gun2) {
call("destroy");
};
tellTarget (myboss) {
call("destroy");
};
removeMovieClip("");
Symbol 592 MovieClip [idngtank] Frame 19
this.localToGlobal((p = {x:rocketlauncher._x, y:rocketlauncher._y}));
snd = new Sound();
nr = Math.floor((Math.random() * 3) + 1);
snd.attachSound("snd_releasebomb" + nr);
snd.start();
_root.rocketnr = _root.rocketnr + 1;
if (_root.rocketnr >= 50) {
_root.rocketnr = 0;
}
_root.attachMovie("idrocket_homing2", "rocket" + _root.rocketnr, _root.getNextHighestDepth());
Set(("../rocket" + _root.rocketnr) + ":power", 1);
Set(("../rocket" + _root.rocketnr) + ":hspeed", hhspeed - 2);
Set(("../rocket" + _root.rocketnr) + ":vspeed", -4);
Set(("../rocket" + _root.rocketnr) + ":life", 60 + (Math.random() * 10));
Set(("../rocket" + _root.rocketnr) + ":delay", 5);
Set(("../rocket" + _root.rocketnr) + ":rotspeed", (Math.random() * 20) - 10);
setProperty("../rocket" + _root.rocketnr, _rotation , -90);
setProperty("../rocket" + _root.rocketnr, _x , p.x);
setProperty("../rocket" + _root.rocketnr, _y , p.y);
Symbol 592 MovieClip [idngtank] Frame 24
idgun1 = this.gun1;
idgun2 = this.gun2;
switch (_global.bossnr) {
case 1 :
maxhealth = 5000;
myhealth = maxhealth;
myname = "General Joy";
idgun1.reloadtime = 65;
idgun2.reloadtime = 13;
_root.displaytxt = "The army has send their very best to get you; General Joy!";
myboss.gotoAndStop(1);
break;
case 2 :
maxhealth = 7500;
myhealth = maxhealth;
myname = "Queen Harry";
idgun1.reloadtime = 55;
idgun2.reloadtime = 11;
_root.displaytxt = "Incoming; Queen Harry!";
shootdelay = 130;
myboss.gotoAndStop(2);
break;
case 3 :
maxhealth = 100;
myhealth = maxhealth;
myname = "StrawberryClock";
idgun1.reloadtime = 200;
idgun2.reloadtime = 50;
_root.displaytxt = "The 'Mighty' Strawberryclock has come!";
shootdelay = 10000;
shoot = 10000;
myboss.gotoAndStop(5);
_xscale = 20;
_yscale = 20;
_y = (_y + 100);
break;
case 4 :
maxhealth = 12500;
myhealth = maxhealth;
myname = "Calderbank";
idgun1.reloadtime = 40;
idgun2.reloadtime = 9;
_root.displaytxt = "Calderbank has come to get you!";
shootdelay = 120;
myboss.gotoAndStop(3);
break;
case 5 :
maxhealth = 17500;
myhealth = maxhealth;
myname = "Tom Fulp";
idgun1.reloadtime = 35;
idgun2.reloadtime = 8;
_root.displaytxt = "Tom Fulp Himself will deal with you!";
shootdelay = 100;
myboss.gotoAndStop(4);
break;
default :
maxhealth = 17500 + (_global.bossnr * 2500);
myhealth = maxhealth;
idgun1.reloadtime = 30;
idgun2.reloadtime = 7;
shootdelay = 100;
if (Math.random() < 0.5) {
myname = "Tom Fulp";
_root.displaytxt = "Tom Fulp Himself will deal with you!";
myboss.gotoAndStop(4);
} else {
myname = "Calderbank";
_root.displaytxt = "Calderbank has come to get you!";
myboss.gotoAndStop(3);
}
}
Symbol 651 MovieClip [idexplosion_2] Frame 1
_xscale = scale;
_yscale = scale;
boomsound = new Sound(this);
nr = Math.floor((Math.random() * 3) + 1);
boomsound.attachSound("idngtankshot" + nr);
this.boomsound.setVolume(150);
boomsound.start();
if (_root._quality == "HIGH") {
this.filters = _root.filterArray2;
}
Symbol 651 MovieClip [idexplosion_2] Frame 30
removeMovieClip("");
Symbol 657 MovieClip [idboss_healthbar] Frame 1
onEnterFrame = function () {
this.fill._x = -124 + (83 * (_parent.myhealth / _parent.maxhealth));
myname = _parent.myname;
};
Symbol 657 MovieClip [idboss_healthbar] Frame 3
gotoAndPlay (2);
Symbol 658 MovieClip [idngtank_dead] Frame 1
Fz = 0.5;
onEnterFrame = function () {
call("coll");
call("cannon");
hitX = hitX * 0.7;
_rotation = (_rotation - (hitX * 0.001));
hhspeed = hhspeed * 0.96;
vspeed = vspeed * 0.9;
vspeed = vspeed + Fz;
_x = (_x + hhspeed);
_y = (_y + vspeed);
if (((_y > _root.roomheight) or (_x < -250)) or (_x > 900)) {
removeMovieClip("");
}
};
Symbol 658 MovieClip [idngtank_dead] Frame 3
gotoAndPlay (2);
Symbol 658 MovieClip [idngtank_dead] Frame 4
Fz = 0.5;
for (a in this.hitbox) {
this.localToGlobal((p = {x:this.hitbox[a]._x, y:this.hitbox[a]._y}));
min = Math.floor(p.x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y + 1, true)) {
hitX = hitX + (p.x - _x);
Fz = 0;
vspeed = 0;
}
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y, true)) {
yy = 0;
while (eval ("_root.groundnr" + i).hitTest(p.x, p.y + yy, true)) {
yy = yy - 1;
}
_y = (_y + yy);
i = max;
}
i = i + 1;
}
}
}
Symbol 658 MovieClip [idngtank_dead] Frame 9
this.localToGlobal((p = {x:this.myturret._x, y:this.myturret._y}));
tdirec = (Math.PI/4);
direc = (_rotation + myturret._rotation) * (Math.PI/180);
reldirec = tdirec - direc;
if (reldirec < 0) {
reldirec = reldirec + (Math.PI*2);
}
if (reldirec > (Math.PI*2)) {
reldirec = reldirec - (Math.PI*2);
}
if (Math.abs(reldirec) > 0.1) {
if (reldirec > Math.PI) {
myturret._rotation = myturret._rotation - 0.5;
}
if (reldirec < Math.PI) {
myturret._rotation = myturret._rotation + 0.5;
}
}
Symbol 664 MovieClip [idtextbox] Frame 1
displaytxt = "";
displaytxt2 = "";
displaytxt3 = "";
timer = 0;
timer2 = 0;
timer3 = 0;
onEnterFrame = function () {
if (displaytxt != _root.displaytxt) {
if (displaytxt2 != "") {
timer3 = timer2;
displaytxt3 = displaytxt2;
}
if (displaytxt != "") {
timer2 = timer;
displaytxt2 = displaytxt;
}
displaytxt = _root.displaytxt;
timer = 200;
}
if (timer >= 1) {
timer = timer - 1;
} else {
_root.displaytxt = "";
displaytxt = "";
}
if (timer2 >= 1) {
timer2 = timer2 - 1;
} else {
displaytxt2 = "";
}
if (timer3 >= 1) {
timer3 = timer3 - 1;
} else {
displaytxt3 = "";
}
};
Symbol 664 MovieClip [idtextbox] Frame 3
gotoAndPlay (2);
Symbol 667 MovieClip [idbg_tree] Frame 1
function getnew() {
_y = (Math.random() * 20);
scale = ((_y / 50) * 90) + 80;
_xscale = scale;
_yscale = scale;
gotoAndStop(Math.floor(Math.random() * 2) + 1);
}
onEnterFrame = function () {
if (_root._quality != "LOW") {
_x = (_x - (_parent.hhspeed * (scale / 100)));
if (_x > (800 + _width)) {
_x = (_x - (-_width));
getnew();
}
if (_x < (-_width)) {
_x = (_x + (800 + _width));
getnew();
}
}
};
getnew();
Symbol 669 MovieClip [idbomb_fragment] Frame 1
rotspeed = (Math.random() * 50) - 25;
onEnterFrame = function () {
rotspeed = rotspeed * 0.95;
_rotation = (_rotation + rotspeed);
vspeed = vspeed + 0.24;
_x = (_x + hspeed);
_y = (_y + vspeed);
min = Math.floor(_x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(_x, _y, true)) {
call("destroy");
}
i = i + 1;
}
}
i = 42;
while (i <= (41 + _root.totalcivcars)) {
if (eval ("_root.civcar" + i).hitTest(_x, _y, true)) {
eval ("_root.civcar" + i).myhealth = eval ("_root.civcar" + i).myhealth - 20;
mydelta = eval (("_root.civcar" + i) + "._x") - this._x;
Set(("_root.civcar" + i) + ":rotspeed", -0.1 * mydelta);
call("destroy");
}
i = i + 1;
}
i = 15;
while (i <= (14 + _root.totalcivs)) {
if (eval ("_root.civ" + i).hitTest(_x, _y, false)) {
eval ("_root.civ" + i).die = 2;
eval ("_root.civ" + i).hspeed = eval ("_root.civ" + i).hspeed + hspeed;
call("destroy");
}
i = i + 1;
}
i = 28;
while (i <= (27 + _root.totalenemies)) {
if (eval ("_root.enemy" + i).hitTest(_x, _y, true)) {
eval ("_root.enemy" + i).myhealth = eval ("_root.enemy" + i).myhealth - (40 + (Math.random() * 20));
mydelta = eval (("_root.enemy" + i) + "._x") - this._x;
eval ("_root.enemy" + i).rotspeed = eval ("_root.enemy" + i).rotspeed - (mydelta / 15);
eval ("_root.enemy" + i).hspeed = eval ("_root.enemy" + i).hspeed + (mydelta / 10);
call("destroy");
}
i = i + 1;
}
if ((((_x < -5) or (_x > 805)) or (_y < -5)) or (_y > (_root.roomheight + 5))) {
removeMovieClip("");
}
};
Symbol 669 MovieClip [idbomb_fragment] Frame 4
gotoAndPlay (2);
Symbol 669 MovieClip [idbomb_fragment] Frame 5
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , this._x);
setProperty("../explosion_1_" + expdepth, _y , this._y);
Set(("_root.explosion_1_" + expdepth) + ":scale", 30 + (Math.random() * 20));
removeMovieClip("");
Symbol 675 MovieClip [idcivcar] Frame 1
wannaspeed = 0;
while (wannaspeed == 0) {
wannaspeed = Math.round((Math.random() * 6) - 3);
}
hspeed = wannaspeed;
vspeed = 0;
rotspeed = 0;
hitX = 0;
if (hspeed > 0) {
_xscale = -100;
}
Fz = 0.4;
myhealth = (Math.random() * 10) + 30;
mycolor = new Color(this.body.masked);
var myColorTransform = new Object();
myColorTransform.ra = 0;
myColorTransform.rb = Math.random() * 255;
myColorTransform.ga = 0;
myColorTransform.gb = Math.random() * 255;
myColorTransform.ba = 0;
myColorTransform.bb = Math.random() * 255;
myColorTransform.aa = 100;
myColorTransform.ab = 0;
mycolor.setTransform(myColorTransform);
this.body.masked.beginFill(mycolor, 100);
this.body.masked.moveTo(-47.3, -8.6);
this.body.masked.lineTo(47.3, -8.6);
this.body.masked.lineTo(47.3, 8.6);
this.body.masked.lineTo(-47.3, 8.6);
this.body.masked.lineTo(-47.3, -8.6);
this.body.masked.endFill();
nr = Math.floor(Math.random() * 6) + 1;
arm1.gotoAndStop(nr);
arm2.gotoAndStop(nr);
onEnterFrame = function () {
dep = this.getDepth();
if (dep != 42) {
if (_root.getInstanceAtDepth(dep - 1) == undefined) {
this.swapDepths(dep - 1);
this._name = "civcar" + (dep - 1);
}
}
if (((_x < -100) or (_x > 900)) or (_y > (_root.roomheight + 100))) {
call("destroy");
}
if (myhealth <= 0) {
call("die1");
}
if (hspeed < wannaspeed) {
hspeed = hspeed + 0.2;
}
if (hspeed > wannaspeed) {
hspeed = hspeed - 0.2;
}
hspeed = hspeed * 0.95;
vspeed = vspeed + Fz;
hitX = hitX * 0.8;
rotspeed = rotspeed * 0.9;
_rotation = (_rotation - ((hitX * 0.012) - rotspeed));
_x = (_x + hspeed);
_y = (_y + vspeed);
wheelrot = -Math.abs((hspeed / 62.8318530717959) * 360);
lwheel._rotation = lwheel._rotation + wheelrot;
rwheel._rotation = rwheel._rotation + wheelrot;
call("coll");
};
Symbol 675 MovieClip [idcivcar] Frame 3
gotoAndPlay (2);
Symbol 675 MovieClip [idcivcar] Frame 4
_root.totalcivcars = _root.totalcivcars - 1;
removeMovieClip("");
Symbol 675 MovieClip [idcivcar] Frame 9
Fz = 0.4;
for (a in this.hitbox) {
this.localToGlobal((p = {x:this.hitbox[a]._x, y:this.hitbox[a]._y}));
min = Math.floor(p.x / 100) + 1;
max = min + 1;
i = min;
if ((i >= 0) or (i <= 9)) {
while (i <= max) {
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y + 1, true)) {
hitX = hitX + (p.x - _x);
Fz = 0;
vspeed = 0;
}
if (eval ("_root.groundnr" + i).hitTest(p.x, p.y, true)) {
yy = 0;
while (eval ("_root.groundnr" + i).hitTest(p.x, p.y + yy, true)) {
yy = yy - 1;
}
_y = (_y + yy);
i = max;
}
i = i + 1;
}
}
}
Symbol 675 MovieClip [idcivcar] Frame 14
_root.adrenaline = _root.adrenaline + ((Math.random() * 4) + 8);
_root.wantedlevel = _root.wantedlevel + 12;
_global.XP = _global.XP + 8;
this.localToGlobal((p = {x:this.rwheel._x, y:this.rwheel._y}));
nr = _root.getNextHighestDepth();
_root.attachMovie("idjunk", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("idcivcar_wheel", "New", 1);
Set(("_root.limb" + nr) + ":hspeed", ((hspeed / 2) + (Math.random() * 5)) - 2.5);
Set(("_root.limb" + nr) + ":vspeed", ((vspeed / 2) + (Math.random() * 8)) - 12);
Set(("_root.limb" + nr) + ":rotspeed", (Math.random() * 40) - 20);
nr = _root.getNextHighestDepth();
_root.attachMovie("idcivcar_dead", "new" + nr, nr);
Set(("_root.new" + nr) + "._x", _x);
Set(("_root.new" + nr) + "._y", _y);
Set(("_root.new" + nr) + "._xscale", _xscale);
Set(("_root.new" + nr) + ":hspeed", (hspeed + (Math.random() * 4)) - 2);
Set(("_root.new" + nr) + ":vspeed", (vspeed + (Math.random() * -10)) - 5);
Set(("_root.new" + nr) + ":rotspeed", (rotspeed + (Math.random() * 16)) - 8);
Set(("_root.new" + nr) + ":rb", myColorTransform.rb);
Set(("_root.new" + nr) + ":gb", myColorTransform.gb);
Set(("_root.new" + nr) + ":bb", myColorTransform.bb);
this.localToGlobal((p = {x:this.pilot._x, y:this.pilot._y}));
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_head1", "head", 1);
eval (("_root.limb" + nr) + ".head").gotoAndStop(pilot._currentframe);
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_eye1", "eye", 1);
if (Math.floor(Math.random() * 4) == 0) {
nr = _root.getNextHighestDepth();
_root.attachMovie("idlimb", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("dead_brains1", "brains", 1);
Set(("_root.limb" + nr) + "._rotation", _rotation);
}
this.localToGlobal((p = {x:this.lwheel._x, y:this.lwheel._y}));
nr = _root.getNextHighestDepth();
_root.attachMovie("idjunk", "limb" + nr, nr);
Set(("_root.limb" + nr) + "._x", p.x);
Set(("_root.limb" + nr) + "._y", p.y);
eval ("_root.limb" + nr).attachMovie("idcivcar_wheel", "New", 1);
Set(("_root.limb" + nr) + ":hspeed", ((hspeed / 2) + (Math.random() * 5)) - 2.5);
Set(("_root.limb" + nr) + ":vspeed", ((vspeed / 2) + (Math.random() * 8)) - 12);
Set(("_root.limb" + nr) + ":rotspeed", (Math.random() * 40) - 20);
expdepth = _root.getNextHighestDepth();
_root.attachMovie("idexplosion_1", "explosion_1_" + expdepth, expdepth);
setProperty("../explosion_1_" + expdepth, _x , (this._x + (Math.random() * 50)) - 25);
setProperty("../explosion_1_" + expdepth, _y , (this._y + (Math.random() * 50)) - 25);
Set(("../explosion_1_" + expdepth) + ":scale", 70 + (Math.random() * 30));
call("destroy");
Symbol 701 MovieClip Frame 1
hhspeed = 0;
Symbol 715 Button
on (release) {
gotoAndPlay (42);
}
Symbol 717 Button
on (release) {
gotoAndPlay (56);
}
Symbol 719 Button
on (release) {
gotoAndPlay (45);
}
Symbol 731 Button
on (release) {
gotoAndPlay (49);
}
Symbol 740 Button
on (release) {
gotoAndPlay (37);
}