Frame 1
function citem1f() {
getURL ("http://www.rustyarcade.com", "_blank");
}
function citem4f() {
_root.bgmOn = true;
_root.songNum++;
if (_root.songNum > 3) {
_root.songNum = 1;
}
_root.bgm.stop();
_root.bgm.attachSound("bgm" + _root.songNum);
_root.bgm.start(0, 100);
if (_root.songName != undefined) {
_root.songName.swapDepths(_root.getNextHighestDepth());
_root.songName.removeMovieClip();
}
m = _root.attachMovie("songName", "songName", _root.getNextHighestDepth());
m.title = _root.songNames[_root.songNum - 1];
m.onEnterFrame = function () {
this._alpha--;
if (this._alpha <= 0) {
this.swapDepths(_root.getNextHighestDepth());
this.removeMovieClip();
}
};
delete m;
}
function citem5f() {
if (_root.bgmOn) {
_root.bgmOn = false;
_root.bgm.stop();
} else {
_root.bgmOn = true;
_root.bgm.start(0, 100);
}
if (_root.songName != undefined) {
_root.songName.swapDepths(_root.getNextHighestDepth());
_root.songName.removeMovieClip();
}
m = _root.attachMovie("songName", "songName", _root.getNextHighestDepth());
m.title = "Music " + (_root.bgmOn ? "On" : "Off");
m.onEnterFrame = function () {
this._alpha--;
if (this._alpha <= 0) {
this.swapDepths(_root.getNextHighestDepth());
this.removeMovieClip();
}
};
delete m;
}
function citem6f() {
_root.soundOn = !_root.soundOn;
if (_root.songName != undefined) {
_root.songName.swapDepths(_root.getNextHighestDepth());
_root.songName.removeMovieClip();
}
m = _root.attachMovie("songName", "songName", _root.getNextHighestDepth());
m.title = "Sound " + (_root.soundOn ? "On" : "Off");
m.onEnterFrame = function () {
this._alpha--;
if (this._alpha <= 0) {
this.swapDepths(_root.getNextHighestDepth());
this.removeMovieClip();
}
};
delete m;
}
function citem7f() {
_root.effects = !_root.effects;
if (_root.songName != undefined) {
_root.songName.swapDepths(_root.getNextHighestDepth());
_root.songName.removeMovieClip();
}
m = _root.attachMovie("songName", "songName", _root.getNextHighestDepth());
m.title = "Effects " + (_root.effects ? "On" : "Off");
m.onEnterFrame = function () {
this._alpha--;
if (this._alpha <= 0) {
this.swapDepths(_root.getNextHighestDepth());
this.removeMovieClip();
}
};
delete m;
}
stop();
var effects = true;
var songNames = new Array("ParagonX9 - No. 5", "MaestroRage - The Spread of Chaos", "MaestroRage - An Ambitious War");
var bgmOn = true;
var soundOn = true;
var songNum = 1;
var bgm = new Sound(_root);
_root.bgm.attachSound("bgm1");
var gameMenu = new ContextMenu();
_root.gameMenu.builtInItems.zoom = false;
_root.gameMenu.builtInItems.play = false;
_root.gameMenu.builtInItems.loop = false;
_root.gameMenu.builtInItems.rewind = false;
_root.gameMenu.builtInItems.forward_back = false;
var citem1 = new ContextMenuItem("Rustyarcade.com", citem1f);
var citem2 = new ContextMenuItem("Art by Eduardo Mojica", citem1f);
var citem3 = new ContextMenuItem("Code by Matthew Shaile", citem1f);
var citem4 = new ContextMenuItem("Next Song", citem4f);
var citem5 = new ContextMenuItem("Toggle Music", citem5f);
var citem6 = new ContextMenuItem("Toggle SFX", citem6f);
var citem7 = new ContextMenuItem("Toggle Effects", citem7f);
_root.gameMenu.customItems.push(citem1);
_root.gameMenu.customItems.push(citem2);
_root.gameMenu.customItems.push(citem3);
_root.gameMenu.customItems.push(citem4);
_root.gameMenu.customItems.push(citem5);
_root.gameMenu.customItems.push(citem6);
_root.gameMenu.customItems.push(citem7);
_root.gameMenu.customItems[3].separatorBefore = true;
_root.gameMenu.customItems[6].separatorBefore = true;
_root.menu = _root.gameMenu;
Instance of Symbol 263 MovieClip in Frame 1
on (release) {
getURL ("http://www.rustyarcade.com", "_blank");
}
Frame 2
function __com_mochibot__(swfid, mc, lv, trk) {
var x;
var g;
var s;
var fv;
var sb;
var u;
var res;
var mb;
var mbc;
mb = "__mochibot__";
mbc = "mochibot.com";
g = (_global ? (_global) : (_level0._root));
if (g[mb + swfid]) {
return(g[mb + swfid]);
}
s = System.security;
x = mc._root.getSWFVersion;
fv = (x ? (mc.getSWFVersion()) : ((_global ? 6 : 5)));
if (!s) {
s = {};
}
sb = s.sandboxType;
if (sb == "localWithFile") {
return(null);
}
x = s.allowDomain;
if (x) {
s.allowDomain(mbc);
}
x = s.allowInsecureDomain;
if (x) {
s.allowInsecureDomain(mbc);
}
u = (((((((((((("http://" + mbc) + "/my/core.swf?mv=7&fv=") + fv) + "&v=") + escape(getVersion())) + "&swfid=") + escape(swfid)) + "&l=") + lv) + "&f=") + mc) + (sb ? ("&sb=" + sb) : "")) + (trk ? "&t=1" : "");
lv = ((fv > 6) ? (mc.getNextHighestDepth()) : ((g[mb + "level"] ? (g[mb + "level"] + 1) : (lv))));
g[mb + "level"] = lv;
if (fv == 5) {
res = "_level" + lv;
if (!eval (res)) {
loadMovieNum (u, lv);
}
} else {
res = mc.createEmptyMovieClip(mb + swfid, lv);
res.loadMovie(u);
}
return(res);
}
__com_mochibot__("56270851", this, 10301, true);
stop();
if (_root.bgmOn) {
_root.bgm.stop();
_root.bgm.attachSound("menu");
_root.bgm.start(0, 100);
}
Frame 3
stop();
Frame 4
stop();
Instance of Symbol 301 MovieClip in Frame 4
on (press) {
_root.prevFrame();
}
Instance of Symbol 303 MovieClip in Frame 4
on (press) {
_root.gotoAndStop(8);
}
Instance of Symbol 301 MovieClip in Frame 4
on (press) {
_root.nextFrame();
}
Instance of Symbol 354 MovieClip in Frame 8
on (press) {
_root.nextFrame();
}
Frame 9
function e1() {
m = _root.ground.attachMovie("etroop", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxvel = 4;
m.range = 150;
m.rof = 30;
m.damage = 1.5;
m.bulid = "bul1";
m.maxhp = 10;
m.hp = 10;
m.aa = false;
m.adv = 0;
m.evil = true;
m.tnum = 1;
delete m;
}
function e2() {
m = _root.ground.attachMovie("etroop", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxvel = 3;
m.range = 150;
m.rof = 15;
m.damage = 1;
m.bulid = "bul1";
m.maxhp = 10;
m.hp = 10;
m.aa = false;
m.adv = 0;
m.evil = true;
m.tnum = 2;
delete m;
}
function e3() {
m = _root.ground.attachMovie("etroop", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxvel = 4;
m.range = 100;
m.rof = 60;
m.damage = 1;
m.bulid = "bul1";
m.maxhp = 10;
m.hp = 10;
m.aa = false;
m.adv = 0;
m.evil = true;
m.tnum = 3;
delete m;
}
function e4() {
m = _root.ground.attachMovie("etroop", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxvel = 3;
m.range = 250;
m.rof = 45;
m.damage = 4;
m.bulid = "bul2";
m.maxhp = 10;
m.hp = 10;
m.aa = true;
m.adv = 1;
m.evil = true;
m.tnum = 4;
delete m;
}
function e5() {
m = _root.ground.attachMovie("etroop", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxvel = 4;
m.range = 100;
m.rof = 60;
m.damage = 1;
m.bulid = "bul1";
m.maxhp = 10;
m.hp = 10;
m.aa = false;
m.adv = 0;
m.evil = true;
m.tnum = 4;
delete m;
}
function e6() {
m = _root.ground.attachMovie("ejeep", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxacc = 0.4;
m.maxvel = 10;
m.range = 150;
m.rof = 10;
m.damage = 0.5;
m.bulid = "bul1";
m.maxhp = 16;
m.hp = 16;
m.aa = true;
m.adv = 3;
m.evil = true;
delete m;
}
function e7() {
m = _root.ground.attachMovie("elight", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxacc = 0.2;
m.maxvel = 4;
m.range = 200;
m.rof = 45;
m.damage = 10;
m.bulid = "bul2";
m.maxhp = 24;
m.hp = 24;
m.aa = false;
m.adv = 0;
m.evil = true;
delete m;
}
function e8() {
m = _root.ground.attachMovie("emedium", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxacc = 0.1;
m.maxvel = 3;
m.range = 300;
m.rof = 90;
m.damage = 16;
m.bulid = "bul2";
m.maxhp = 32;
m.hp = 32;
m.aa = false;
m.adv = 2;
m.evil = true;
delete m;
}
function e9() {
m = _root.ground.attachMovie("eheavy", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxacc = 0.1;
m.maxvel = 2;
m.range = 400;
m.rof = 140;
m.damage = 50;
m.bulid = "bul2";
m.maxhp = 55;
m.hp = 55;
m.aa = false;
m.adv = 2;
m.evil = true;
delete m;
}
function e10() {
m = _root.ground.attachMovie("erockettank", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxacc = 0.1;
m.maxvel = 3;
m.range = 600;
m.rof = 90;
m.damage = 25;
m.bulid = "bul4";
m.maxhp = 32;
m.hp = 32;
m.aa = true;
m.adv = 1;
m.evil = true;
delete m;
}
function e11() {
m = _root.ground.attachMovie("edemotruck", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxacc = 0.1;
m.maxvel = 4;
m.range = 1;
m.rof = 200;
m.damage = 10;
m.bulid = "bul2";
m.maxhp = 40;
m.hp = 40;
m.aa = true;
m.adv = 2;
m.evil = true;
m.explosive = true;
delete m;
}
function e12() {
m = _root.ground.attachMovie("echopper", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxacc = 0.4;
m.maxvel = 10;
m.range = 350;
m.rof = 10;
m.damage = 0.5;
m.bulid = "bul1";
m.maxhp = 16;
m.hp = 16;
m.aa = true;
m.adv = 3;
m.evil = true;
delete m;
}
function e13() {
m = _root.ground.attachMovie("eplane", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxacc = 0.5;
m.maxvel = 12;
m.range = 300;
m.rof = 60;
m.damage = 5;
m.bulid = "bul4";
m.maxhp = 24;
m.hp = 24;
m.aa = true;
m.adv = 2;
m.evil = true;
delete m;
}
function e14() {
m = _root.ground.attachMovie("ebomber", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:((random(2) == 1) ? (10 + random(200)) : (3000 - random(200))), _y:264});
m.maxacc = 0.1;
m.maxvel = 3;
m.range = 400;
m.rof = 200;
m.damage = 50;
m.bulid = "bul3";
m.maxhp = 40;
m.hp = 40;
m.aa = true;
m.adv = 2;
m.evil = true;
delete m;
}
var lp = 0;
var etimer = 0;
var inittimer = 0;
var level = 1;
var leveld = 1;
var level1 = new Array([1], [1, 1], [1, 1, 1], [2, 1], [2, 2, 1], [2, 2, 2, 1, 1]);
var level2 = new Array([6], [1, 1, 1, 1, 1, 1], [2, 2, 6], [6, 6]);
var level3 = new Array([6], [1, 1, 1, 1, 1, 1], [2, 2, 6], [6, 6]);
var level4 = new Array([1, 1, 2, 2, 4, 4, 4, 2, 1, 1]);
var level5 = new Array([6, 6], [1, 2, 2], [6, 6], [1, 2, 2], [4, 4, 6], [1, 2, 2], [6, 6, 6]);
var level6 = new Array([7], [1, 2, 2], [1, 1, 7, 1, 1], [1, 2, 2], [2, 7, 2], [1, 2, 2], [7, 7]);
var level7 = new Array([7, 7, 7], [1, 2, 2], [7, 2, 2, 2, 2, 2], [1, 2, 2], [2, 2, 2, 2, 2, 2], [1, 2, 2], [7, 7, 7]);
var level8 = new Array([8, 1, 1], [2, 4, 2], [8, 7], [7, 7, 4], [1], [1, 2], [1, 2, 4], [8]);
var level8 = new Array([10, 1, 1], [10, 10, 2], [2, 7], [7, 7, 4], [10], [1, 2], [10, 2, 4], [8]);
var level9 = new Array([10, 1, 1], [8, 10, 2], [2, 7], [7, 8, 4], [10], [1, 2], [10, 2, 4], [8]);
var level10 = new Array([9, 1, 1], [1], [1], [9, 9, 9], [1], [1], [1], [9, 10, 10]);
var level11 = new Array([12, 12], [12, 12, 12], [12, 12, 12, 12]);
var level12 = new Array([12, 13], [12, 13, 12], [12, 13, 13, 12]);
var level13 = new Array([12, 13, 2, 2], [12, 13, 12, 4, 4], [12, 13, 13, 12, 4, 4, 2, 2]);
var level14 = new Array([1, 2, 4, 6, 7, 8, 9, 10, 12, 13], [14, 14]);
var level15 = new Array([1, 1, 1, 1], [2, 2, 2, 2], [4, 4, 4, 4], [6, 6, 6, 6], [7, 7, 7, 7], [8, 8, 8, 8], [9, 9, 9], [10, 10, 10], [12, 12, 12, 12], [13, 13, 13, 13], [14]);
_root.createEmptyMovieClip("Brain", _root.getNextHighestDepth());
_root.Brain.onEnterFrame = function () {
if (_root.inittimer == 1500) {
_root.errors._alpha = 100;
_root.errors.error.text = "Wave " + _root.leveld;
}
if (_root.inittimer > 1500) {
_root.etimer = _root.etimer + _root.level;
} else {
_root.inittimer++;
}
if (_root.etimer >= 700) {
_root.etimer = 0;
i = 0;
while (i < _root["level" + _root.level][_root.lp].length) {
_root["e" + _root["level" + _root.level][_root.lp][i]]();
i++;
}
_root.lp++;
if (_root.lp >= _root["level" + _root.level].length) {
_root.etimer = 0;
_root.lp = 0;
_root.inittimer = 600;
if (_root.level > 14) {
_root.level = 14;
} else {
_root.level++;
}
_root.leveld++;
}
}
};
var score = 0;
var money = 1000;
var hp = 100;
var power = 0;
var troops = 0;
var fpsarr = new Array(30, 30, 30);
var advarr = new Array("none", "flying", "vehicle", "troop");
var nuk = 0;
var m1 = 0;
var m2 = 0;
var m3 = 0;
var m4 = 0;
var m5 = 0;
var barbuilt = 0;
var warbuilt = 0;
var airbuilt = 0;
var labbuilt = 0;
var nucbuilt = 0;
var barbuilding = false;
var warbuilding = false;
var airbuilding = false;
var labbuilding = false;
var nucbuilding = false;
var barNames = new Array("Barracks", "Advanced Barracks");
var warNames = new Array("Tank Factory", "Super Tank Factory", "Ultimate Tank Factory");
var airNames = new Array("Air Base", "Air Fortress");
var labNames = new Array("Research Laboratory");
var nucNames = new Array("Nuclear Plant");
var barPrices = new Array(300, 900);
var warPrices = new Array(1500, 3000, 6000);
var airPrices = new Array(1700, 2800);
var labPrices = new Array(1750, 0);
var nucPrices = new Array(10000, 0);
var barPower = new Array(0, 3, 5);
var warPower = new Array(0, 7, 12, 15);
var airPower = new Array(0, 7, 10);
var labPower = new Array(0, 10);
var nucPower = new Array(0, 20);
var barTimes = new Array(0, 600, 1200);
var warTimes = new Array(0, 900, 1300, 1800);
var airTimes = new Array(0, 1400, 2000);
var labTimes = new Array(0, 2000);
var nucTimes = new Array(0, 5000);
var powers = new Array(8, 20, 45, 70, 100, 100);
var incomes = new Array(0.222222222222222, 0.444444444444444, 0.888888888888889, 1.77777777777778, 2.66666666666667, 3.33333333333333, 4.44444444444444, 4.44444444444444);
var buildspeeds = new Array(1, 2, 4);
var resbuilt = 0;
var combuilt = 0;
var banbuilt = 0;
var powbuilt = 0;
var buildTypes = ["res", "com", "ban", "pow", "bar", "war", "lab", "nuc", "air"];
var resbtime = 0;
var combtime = 0;
var banbtime = 0;
var powbtime = 0;
var resbuilding = false;
var combuilding = false;
var banbuilding = false;
var powbuilding = false;
var resupgrade = 0;
var comupgrade = 0;
var banupgrade = 0;
var powupgrade = 0;
var resNames = new Array("Apartment Block", "Small Community", "Small Town", "Medium Town", "City Block", "Large City", "Major City", "All Upgrades Purchased");
var resDesc = new Array(12000, 25000, 50000, 100000, 200000, 400000, 1000000, "Full");
var resPrices = new Array(0, 400, 800, 1600, 3200, 6400, 8000);
var resPower = new Array(1, 2, 4, 8, 12, 18, 20);
var resTimes = new Array(0, 600, 900, 1200, 2000, 2500, 3000);
var comNames = new Array("Business Center", "Huge Company", "Business Empire", "All Upgrades Purchased");
var comDesc = new Array("Regular Productivity", "Double Regular Productivity", "4x Regular Productivity", "Productivity is optimum");
var comPrices = new Array(0, 400, 1000);
var comPower = new Array(1, 7, 15);
var comTimes = new Array(0, 400, 1000);
var banNames = new Array("Main Bank Office", "Bank Branches", "International Bank", "All Upgrades Purchased");
var banDesc = new Array("Regular Income", "Double City Income", "Triple City Income", "Income is at max");
var banPrices = new Array(0, 8000, 12000);
var banPower = new Array(1, 3, 5);
var banTimes = new Array(0, 3000, 6000);
var powNames = new Array("Power Plant", "Large Power Plant", "High-Tech Power Plant", "Huge Power Factory", "Ultimate Power Factory", "All Upgrades Purchased");
var powDesc = new Array("5% Maximum Power", "Increase to 20% Maximum Power", "Increase to 45% Maximum Power", "Increase to 70% Maximum Power", "Increase to 100% Maximum Power", "Power is at full capacity");
var powPrices = new Array(0, 500, 2500, 4000, 7000);
var powTimes = new Array(0, 1000, 1500, 2500, 4000);
onEnterFrame = function () {
if (_root.m4 > 0) {
_root.nuk = _root.nuk + 0.1;
if (_root.nuk > 100) {
_root.nuk = 100;
}
}
if (_root.hp <= 0) {
_root.play();
}
_root.scored = Math.floor(_root.score);
_root.score = _root.score + 0.1;
fps = (1 / (getTimer() - dt)) * 1000;
dt = getTimer();
fpsarr.push(fps);
avefps = Math.round(((fpsarr[0] + fpsarr[1]) + fpsarr[2]) / 3);
fpsarr.splice(0, 1);
_root.efficency = (Math.round(((avefps / 30) * 100) / 10) * 10) + "%";
_root.money = _root.money + (_root.incomes[_root.resupgrade] * (_root.banupgrade + 1));
_root.power = _root.powers[_root.powupgrade];
_root.cash = "$" + Math.round(_root.money);
_root.usedpower = 0;
i = 0;
while (i < 3) {
_root.usedpower = _root.usedpower + _root[_root.buildTypes[i] + "Power"][_root[_root.buildTypes[i] + "upgrade"]];
i++;
}
i = 4;
while (i < 9) {
_root.usedpower = _root.usedpower + _root[_root.buildTypes[i] + "Power"][_root["m" + (i - 3)]];
i++;
}
_root.energy = (_root.usedpower + "/") + _root.power;
_root.health = _root.hp + "%";
_root.tunits = _root.troops + "/15 units";
i = 0;
while (i < 4) {
if (_root[_root.buildTypes[i] + "building"]) {
_root[_root.buildTypes[i] + "built"] = _root[_root.buildTypes[i] + "built"] + ((100 / _root[_root.buildTypes[i] + "Times"][_root[_root.buildTypes[i] + "upgrade"] + 1]) * _root.buildspeeds[_root.comupgrade]);
}
if (_root[_root.buildTypes[i] + "built"] >= 100) {
_root[_root.buildTypes[i] + "built"] = 0;
_root[_root.buildTypes[i] + "building"] = false;
_root[_root.buildTypes[i] + "upgrade"]++;
}
i++;
}
i = 4;
while (i < 9) {
if (_root[_root.buildTypes[i] + "building"]) {
_root[_root.buildTypes[i] + "built"] = _root[_root.buildTypes[i] + "built"] + ((100 / _root[_root.buildTypes[i] + "Times"][_root["m" + (i - 3)] + 1]) * _root.buildspeeds[_root.comupgrade]);
}
if (_root[_root.buildTypes[i] + "built"] >= 100) {
_root[_root.buildTypes[i] + "built"] = 0;
_root[_root.buildTypes[i] + "building"] = false;
_root["m" + (i - 3)]++;
}
i++;
}
};
function infoBox(v1, v2, v3) {
m = _root.attachMovie("infobox", "infobox", _root.getNextHighestDepth(), {_x:_root._xmouse, _y:_root._ymouse});
m.named.text = v1;
m.cost.text = v2;
m.power.text = v3;
m.onEnterFrame = function () {
this._x = _root._xmouse;
this._y = _root._ymouse;
};
delete m;
}
function removeInfo() {
if (_root.infobox != undefined) {
_root.infobox.swapDepths(_root.getNextHighestDepth());
_root.infobox.removeMovieClip();
}
}
_root.bgm.stop();
if (_root.bgmOn) {
_root.bgm.attachSound("bgm" + _root.songNum);
_root.bgm.start(0, 100);
}
Instance of Symbol 359 MovieClip in Frame 9
onClipEvent (enterFrame) {
if (this.dragging) {
_root.ground._x = this.setX - ((this.setM - _root._xmouse) * 4);
}
if (_root.ground._x > 0) {
_root.ground._x = 0;
}
if (_root.ground._x < (650 - _root.ground._width)) {
_root.ground._x = 650 - _root.ground._width;
}
if (Key.isDown(17)) {
this.useHandCursor = true;
} else {
this.useHandCursor = false;
}
}
on (press) {
if (Key.isDown(17)) {
this.setX = _root.ground._x;
this.setM = _root._xmouse;
this.dragging = true;
}
}
onClipEvent (mouseUp) {
this.dragging = false;
}
Instance of Symbol 530 MovieClip "ground" in Frame 9
onClipEvent (enterFrame) {
this._x = this._x - (Key.isDown(39) * 25);
this._x = this._x + (Key.isDown(37) * 25);
}
Instance of Symbol 715 MovieClip "infoBoxb" in Frame 9
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 717 MovieClip "errors" in Frame 9
onClipEvent (load) {
this._alpha = 0;
}
onClipEvent (enterFrame) {
if (this._alpha > 0) {
this._alpha = this._alpha - 0.5;
}
}
Frame 10
stop();
onEnterFrame = null;
var username = "Player 1";
Frame 11
stop();
onEnterFrame = function () {
i = 1;
while (i < _root.scorearr.length) {
_root["sid" + (i - 1)] = this.scorearr[i];
i++;
}
};
Symbol 23 MovieClip Frame 20
this._parent.swapDepths(this._parent._parent.getNextHighestDepth());
this._parent.removeMovieClip();
Symbol 24 MovieClip [bul4] Frame 1
stop();
Symbol 24 MovieClip [bul4] Frame 2
stop();
Symbol 26 MovieClip [bul3] Frame 1
stop();
Symbol 26 MovieClip [bul3] Frame 2
stop();
Symbol 35 MovieClip [sdexplosion] Frame 1
if (_root.soundOn) {
var son = new Sound(this);
this.son.attachSound("sfx1");
this.son.start(0, 0);
var son2 = new Sound(this);
this.son2.attachSound("sfx3");
this.son2.start(0, 0);
}
Symbol 35 MovieClip [sdexplosion] Frame 71
stop();
this.swapDepths(this._parent.getNextHighestDepth());
this.removeMovieClip();
Instance of Symbol 49 MovieClip in Symbol 50 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 51 MovieClip [erockettank] Frame 1
#initclip 23
Object.registerClass("erockettank", vehicle);
#endinitclip
Instance of Symbol 53 MovieClip in Symbol 54 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 55 MovieClip [rockettank] Frame 1
#initclip 4
Object.registerClass("rockettank", vehicle);
#endinitclip
Instance of Symbol 49 MovieClip in Symbol 63 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 64 MovieClip [edemotruck] Frame 1
#initclip 5
Object.registerClass("edemotruck", vehicle);
#endinitclip
Instance of Symbol 53 MovieClip in Symbol 65 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 66 MovieClip [demotruck] Frame 1
#initclip 6
Object.registerClass("demotruck", vehicle);
#endinitclip
Instance of Symbol 49 MovieClip in Symbol 72 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 74 MovieClip [ebomber] Frame 1
#initclip 7
Object.registerClass("ebomber", flying);
#endinitclip
stop();
Symbol 74 MovieClip [ebomber] Frame 2
stop();
Instance of Symbol 53 MovieClip in Symbol 76 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 78 MovieClip [bomber] Frame 1
#initclip 8
Object.registerClass("bomber", flying);
#endinitclip
stop();
Symbol 78 MovieClip [bomber] Frame 2
stop();
Instance of Symbol 49 MovieClip in Symbol 84 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 86 MovieClip [eplane] Frame 1
#initclip 9
Object.registerClass("eplane", flying);
#endinitclip
stop();
Symbol 86 MovieClip [eplane] Frame 2
stop();
Instance of Symbol 53 MovieClip in Symbol 87 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 88 MovieClip [plane] Frame 1
#initclip 10
Object.registerClass("plane", flying);
#endinitclip
stop();
Symbol 88 MovieClip [plane] Frame 2
stop();
Instance of Symbol 49 MovieClip in Symbol 100 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 102 MovieClip [echopper] Frame 1
#initclip 11
Object.registerClass("echopper", flying);
#endinitclip
stop();
Symbol 102 MovieClip [echopper] Frame 2
stop();
Instance of Symbol 53 MovieClip in Symbol 103 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 104 MovieClip [chopper] Frame 1
#initclip 12
Object.registerClass("chopper", flying);
#endinitclip
stop();
Symbol 104 MovieClip [chopper] Frame 2
stop();
Symbol 110 MovieClip Frame 1
stop();
Symbol 116 MovieClip Frame 1
stop();
Symbol 122 MovieClip Frame 1
stop();
Symbol 122 MovieClip Frame 4
stop();
Symbol 122 MovieClip Frame 5
stop();
Symbol 128 MovieClip Frame 1
stop();
Symbol 134 MovieClip Frame 1
stop();
Instance of Symbol 137 MovieClip in Symbol 138 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 143 MovieClip Frame 5
this._parent.gotoAndStop(1);
Symbol 144 MovieClip Frame 15
if (!this._parent.evil) {
_root.troops--;
_root.score = _root.score - 10;
}
this._parent.swapDepths(this._parent._parent.getNextHighestDepth());
this._parent.removeMovieClip();
Symbol 145 MovieClip Frame 21
if (!this._parent.evil) {
_root.score = _root.score - 10;
_root.troops--;
}
this._parent.swapDepths(this._parent._parent.getNextHighestDepth());
this._parent.removeMovieClip();
Symbol 146 MovieClip Frame 18
if (!this._parent.evil) {
_root.score = _root.score - 10;
_root.troops--;
}
this._parent.swapDepths(this._parent._parent.getNextHighestDepth());
this._parent.removeMovieClip();
Symbol 147 MovieClip [etroop] Frame 1
#initclip 13
Object.registerClass("etroop", troop);
#endinitclip
stop();
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Symbol 147 MovieClip [etroop] Frame 2
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Symbol 147 MovieClip [etroop] Frame 3
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Symbol 147 MovieClip [etroop] Frame 4
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Symbol 147 MovieClip [etroop] Frame 5
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Symbol 147 MovieClip [etroop] Frame 6
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Instance of Symbol 148 MovieClip in Symbol 149 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 150 MovieClip [troop] Frame 1
#initclip 14
Object.registerClass("troop", troop);
#endinitclip
stop();
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Symbol 150 MovieClip [troop] Frame 2
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Symbol 150 MovieClip [troop] Frame 3
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Symbol 150 MovieClip [troop] Frame 4
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Symbol 150 MovieClip [troop] Frame 5
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Symbol 150 MovieClip [troop] Frame 6
for (var d in this.main) {
this.main[d].gotoAndStop(this.tnum);
}
Instance of Symbol 158 MovieClip in Symbol 159 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 161 MovieClip [enemyjeep] Frame 1
#initclip 15
Object.registerClass("enemyjeep", vehicle);
#endinitclip
stop();
Symbol 161 MovieClip [enemyjeep] Frame 2
stop();
Instance of Symbol 53 MovieClip in Symbol 168 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 170 MovieClip [heavy] Frame 1
#initclip 16
Object.registerClass("heavy", vehicle);
#endinitclip
stop();
Symbol 170 MovieClip [heavy] Frame 2
stop();
Instance of Symbol 49 MovieClip in Symbol 176 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 178 MovieClip [emedium] Frame 1
#initclip 17
Object.registerClass("emedium", vehicle);
#endinitclip
stop();
Symbol 178 MovieClip [emedium] Frame 2
stop();
Instance of Symbol 53 MovieClip in Symbol 180 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 182 MovieClip [medium] Frame 1
#initclip 18
Object.registerClass("medium", vehicle);
#endinitclip
stop();
Symbol 182 MovieClip [medium] Frame 2
stop();
Instance of Symbol 49 MovieClip in Symbol 183 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 184 MovieClip [ejeep] Frame 1
#initclip 19
Object.registerClass("ejeep", vehicle);
#endinitclip
stop();
Symbol 184 MovieClip [ejeep] Frame 2
stop();
Instance of Symbol 53 MovieClip in Symbol 185 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 186 MovieClip [jeep] Frame 1
#initclip 20
Object.registerClass("jeep", vehicle);
#endinitclip
stop();
Symbol 186 MovieClip [jeep] Frame 2
stop();
Instance of Symbol 49 MovieClip in Symbol 193 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 195 MovieClip [elight] Frame 1
#initclip 21
Object.registerClass("elight", vehicle);
#endinitclip
stop();
Symbol 195 MovieClip [elight] Frame 2
stop();
Instance of Symbol 53 MovieClip in Symbol 196 MovieClip Frame 1
onClipEvent (enterFrame) {
this._parent._xscale = this._parent._parent._xscale;
this._xscale = (this._parent._parent.hp / this._parent._parent.maxhp) * 100;
}
Symbol 198 MovieClip [light] Frame 1
#initclip 22
Object.registerClass("light", vehicle);
#endinitclip
stop();
Symbol 198 MovieClip [light] Frame 2
stop();
Symbol 217 MovieClip [bul2] Frame 1
stop();
Symbol 217 MovieClip [bul2] Frame 2
stop();
this.swapDepths(this._parent.getNextHighestDepth());
this.removeMovieClip();
Symbol 219 MovieClip [bul1] Frame 1
stop();
Symbol 219 MovieClip [bul1] Frame 2
stop();
this.swapDepths(this._parent.getNextHighestDepth());
this.removeMovieClip();
Symbol 237 Button
on (release) {
getURL ("http://www.rustyarcade.com", "_blank");
}
Symbol 246 MovieClip Frame 1
stop();
Instance of Symbol 246 MovieClip in Symbol 247 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(Math.round((_root.getBytesLoaded() / _root.getBytesTotal()) * 24));
if (((_root.getBytesLoaded() / _root.getBytesTotal()) == 1) && (_root.gook == 255)) {
_root.nextFrame();
}
}
Symbol 263 MovieClip Frame 1
_root.gook = 2;
Symbol 263 MovieClip Frame 112
stop();
_root.gook = 255;
Symbol 753 MovieClip [__Packages.vehicle] Frame 0
class vehicle extends MovieClip
{
var _x, coodx1, w1, coodx2, w2, _parent, _y, _name, swapDepths, removeMovieClip, _currentframe, deadcurve, gotoAndStop, _rotation, _alpha, info, _xscale, ang, gun;
function vehicle () {
super();
}
function onLoad() {
gotox = _x;
if (evil) {
gotox = 1500;
}
active = false;
coodx1 = _x + w1._x;
coodx2 = _x + w2._x;
}
function onEnterFrame() {
if (evil) {
if (targ != "none") {
gotox = _x;
} else {
gotox = 1500;
}
}
if (explosive) {
if (_parent.citye.hitTest(_x, _y, true)) {
hp = 0;
}
}
if (evil) {
coodx1--;
coodx2--;
}
if (hp <= 0) {
if (explosive) {
if (_parent["boom" + _name] == undefined) {
m = _parent.attachMovie("sdexplosion", "boom" + _name, _parent.getNextHighestDepth(), {_x:_x, _y:_y});
m.onEnterFrame = function () {
for (var _local2 in this._parent) {
if (this._parent[_local2].unit) {
this._parent[_local2].hp = this._parent[_local2].hp - 0.7;
}
}
};
delete m;
swapDepths(_parent.getNextHighestDepth());
removeMovieClip();
}
}
if (_currentframe == 1) {
deadcurve = -15;
gotoAndStop(2);
}
if (_root.effects) {
if (deadcurve < 0) {
deadsmoking = true;
for (d in _parent) {
if (d.slice(0, 5) == "smoke") {
if (_parent[d].hitTest(_x + _parent._x, _y + _parent._y)) {
deadsmoking = false;
}
}
}
if (deadsmoking) {
m = _parent.attachMovie("deadsmoke", "smoke" + _parent.getNextHighestDepth(), _parent.getNextHighestDepth(), {_x:_x, _y:_y});
m.onEnterFrame = function () {
this._alpha--;
this._xscale = this._yscale--;
if (this._alpha <= 0) {
this.swapDepths(this._parent.getNextHighestDepth());
this.removeMovieClip();
}
};
delete m;
}
}
}
if (!_parent.dirt.hitTest(_x + _parent._x, (_y + _parent._y) + deadcurve, true)) {
_y = _y + deadcurve;
_rotation = _rotation + 3;
}
if (deadcurve < 0) {
_rotation = _rotation + (deadcurve * 10);
}
deadcurve++;
_alpha--;
if (_alpha <= 0) {
if (!evil) {
_root.troops--;
_root.score = _root.score - 10;
}
swapDepths(_root.getNextHighestDepth());
removeMovieClip();
}
}
if (ovrtarg != "none") {
if ((_parent[ovrtarg].hp <= 0) || (_parent[ovrtarg] == undefined)) {
ovrtarg = "none";
gotox = _x;
} else {
gotox = _parent[ovrtarg]._x;
}
}
if (_currentframe == 1) {
info._visible = active;
if (evil) {
info._visible = true;
if (settarg) {
for (var d in _parent) {
if ((_parent[d].active && (_parent[d].unit)) && (_parent[d].evil != evil)) {
_parent[d].ovrtarg = _name;
}
}
stcon--;
if (stcon <= 0) {
settarg = false;
}
}
}
if (gotox != -100) {
if (_x < gotox) {
_xscale = -100;
acc = maxacc;
} else {
_xscale = 100;
acc = -maxacc;
}
if (Math.abs(gotox - _x) < ((ovrtarg == "none") ? 10 : (range))) {
gotox = -100;
acc = 0;
vel = 0;
}
} else if (Math.abs(coody1 - coody2) > 7) {
if ((coody1 - coody2) > 7) {
acc = -0.005 * (Math.abs(coody1 - coody2) - 7);
} else {
acc = 0.005 * (Math.abs(coody1 - coody2) - 7);
}
} else if (vel < 0.25) {
vel = 0;
} else {
acc = 0;
vel = vel * 0.5;
}
vel = vel - acc;
if (vel > maxvel) {
vel = maxvel;
}
if (vel < (-maxvel)) {
vel = -maxvel;
}
coodx1 = coodx1 - vel;
coodx2 = coodx2 - vel;
var _local3 = 0;
while (_local3 < 20) {
if (!_parent.dirt.hitTest(coodx1 + _parent._x, (coody1 + _parent._y) + 1, true)) {
coody1++;
}
if (!_parent.dirt.hitTest(coodx2 + _parent._x, (coody2 + _parent._y) + 1, true)) {
coody2++;
}
if (_parent.dirt.hitTest(coodx1 + _parent._x, coody1 + _parent._y, true)) {
coody1--;
}
if (_parent.dirt.hitTest(coodx2 + _parent._x, coody2 + _parent._y, true)) {
coody2--;
}
_local3++;
}
ang = Math.atan2(coody1 - coody2, coodx1 - coodx2) + (Math.PI/2);
_rotation = 90 + ((ang * 180) / Math.PI);
_x = (coodx1 - ((coodx2 - coodx1) / 2)) + (Math.cos(ang) * 5);
_y = (coody1 - ((coody2 - coody1) / 2)) + (Math.sin(ang) * 5);
if (gotox != -100) {
var _local5 = 0;
var _local4 = 0;
for (var d in _parent) {
if (_parent[d].gotox == gotox) {
if (d != _name) {
_parent[d].flagged = true;
_local4++;
}
}
}
if (_local4 > 0) {
for (var d in _parent) {
if (_parent[d].flagged) {
_parent[d].gotox = _parent[d].gotox + (-50 + ((100 / _local4) * _local5));
_local5++;
_parent[d].flagged = false;
}
}
}
}
targ = "none";
for (d in _parent) {
if (((_parent[d].evil != evil) && (_parent[d].hp > 0)) && (_parent[d].unit)) {
if ((Math.abs(_x - _parent[d]._x) <= range) && (_parent[d].hp > 0)) {
if (((_parent[d].vtype == "flying") && (aa)) || (_parent[d].vtype != "flying")) {
if (gotox == -100) {
if (_parent[d]._x < _x) {
_xscale = 100;
} else {
_xscale = -100;
}
}
if (((_parent[d]._x - _x) / Math.abs(_parent[d]._x - _x)) != (_xscale / 100)) {
targ = d;
break;
}
targ = "none";
}
}
}
}
if ((ovrtarg != "none") && (Math.abs(_x - _parent[ovrtarg]._x) <= range)) {
targ = ovrtarg;
}
if (explosive) {
targ = "none";
}
rel--;
if ((rel <= 0) && (_parent[targ] != undefined)) {
if (_root.soundOn) {
var _local7 = new Sound(this);
_local7.attachSound("sfx" + bulid);
_local7.start(0, 0);
}
rel = rof;
var m = _parent.attachMovie(bulid, "bul" + _parent.getNextHighestDepth(), _parent.getNextHighestDepth(), {_x:_x, _y:_y + gun._y, par:_name, ang:Math.atan2((_y + gun._y) - (_parent[targ]._y - ((_parent[targ].vtype == "troop") ? (_parent[targ]._height / 2) : 0)), _x - _parent[targ]._x), bulid:bulid, damage:damage, evil:evil, adv:adv, vtype:_parent[targ].vtype, dnum:0});
m._visible = false;
m._rotation = (m.ang * 180) / Math.PI;
m.onEnterFrame = function () {
this.dnum++;
if (this._currentframe == 1) {
this._visible = !this._parent[this.par].hitTest(this._x + this._parent._x, this._y + this._parent._y, true);
if (this._visible) {
if (_root.effects) {
var _local4 = this._parent.attachMovie("s" + this.bulid, "smoke" + this._parent.getNextHighestDepth(), this._parent.getNextHighestDepth(), {_x:this._x, _y:this._y});
_local4.onEnterFrame = function () {
this._xscale = (this._yscale = this._yscale - 5);
this._alpha = this._alpha - 10;
if (this._alpha <= 0) {
this.swapDepths(this._parent.getNextHighestDepth());
this.removeMovieClip();
}
};
}
}
this._x = this._x - (Math.cos(this.ang) * 5);
this._y = this._y - (Math.sin(this.ang) * 5);
if (((this._parent.dirt.hitTest(this._x + this._parent._x, this._y + this._parent._y, 1) || (this._x > (this._parent.dirt._width + 50))) || (this._x < -100)) || (this.dnum > 900)) {
this.gotoAndStop(2);
} else {
for (var _local3 in this._parent) {
if (((this._parent[_local3].evil != this.evil) && (this._parent[_local3].unit)) && (this._parent[_local3].hp > 0)) {
if (this._parent[_local3].hitTest(this._x + this._parent._x, this._y + this._parent._y, 1)) {
if (((this._parent[_local3].vtype == "base") && (this.vtype == "base")) || (this._parent[_local3].vtype != "base")) {
if (this._parent[_local3].vtype == _root.advarr[this.adv]) {
this._parent[_local3].hp = this._parent[_local3].hp - (this.damage * 2);
} else {
this._parent[_local3].hp = this._parent[_local3].hp - this.damage;
}
this.gotoAndStop(2);
break;
}
}
}
}
}
}
};
delete m;
}
}
if (_x < 200) {
gotox = 400;
}
if (_x > (_parent.dirt._width - 200)) {
gotox = _parent.dirt._width - 400;
}
}
function onMouseUp() {
if (_currentframe == 1) {
if (!evil) {
if (!Key.isDown(17)) {
if (active) {
if (_parent.goarrow == undefined) {
_parent.attachMovie("arrow", "goarrow", _parent.getNextHighestDepth(), {_x:_root._xmouse - _parent._x, _y:-100});
_parent.goarrow.onEnterFrame = function () {
while (!this._parent.dirt.hitTest(this._x + this._parent._x, this._y + this._parent._y, 1)) {
this._y++;
}
this._alpha = this._alpha - 10;
if (this._alpha <= 0) {
this.swapDepths(this._parent.getNextHighestDepth());
this.removeMovieClip();
}
};
}
ovrtarg = "none";
gotox = _root._xmouse - _parent._x;
}
}
}
}
}
function onPress() {
if (!evil) {
if (_currentframe == 1) {
if (Key.isDown(17)) {
active = !active;
} else {
for (var _local2 in _parent) {
if (_parent[_local2].active) {
_parent[_local2].active = false;
}
}
active = true;
}
}
} else {
settarg = true;
stcon = 5;
}
}
var maxacc = 0.1;
var maxvel = 3;
var range = 400;
var rof = 60;
var damage = 40;
var bulid = "bul2";
var maxhp = 100;
var hp = 100;
var vtype = "vehicle";
var aa = false;
var adv = 0;
var acc = 0.1;
var vel = 0;
var gotox = _x;
var targ = "none";
var ovrtarg = "none";
var rel = 0;
var explosive = false;
var active = false;
var coody1 = _y;
var coody2 = _y;
var flagged = false;
var deadsmoking = false;
var settarg = false;
var stcon = 0;
var unit = true;
var evil = false;
}
Symbol 754 MovieClip [__Packages.flying] Frame 0
class flying extends MovieClip
{
var _x, _currentframe, deadcurve, gotoAndStop, _parent, _y, _rotation, _alpha, swapDepths, removeMovieClip, info, _name, _xscale, gun;
function flying () {
super();
}
function onLoad() {
gotox = _x;
if (evil) {
gotox = 1500;
}
active = false;
}
function onEnterFrame() {
if (evil) {
if (targ != "none") {
gotox = _x;
} else {
gotox = 1500;
}
}
if (hp <= 0) {
if (_currentframe == 1) {
deadcurve = -5;
gotoAndStop(2);
}
if (_root.effects) {
if (deadcurve < 0) {
deadsmoking = true;
for (d in _parent) {
if (d.slice(0, 5) == "smoke") {
if (_parent[d].hitTest(_x + _parent._x, _y + _parent._y)) {
deadsmoking = false;
}
}
}
if (deadsmoking) {
m = _parent.attachMovie("deadsmoke", "smoke" + _parent.getNextHighestDepth(), _parent.getNextHighestDepth(), {_x:_x, _y:_y});
m.onEnterFrame = function () {
this._alpha--;
this._xscale = this._yscale--;
if (this._alpha <= 0) {
this.swapDepths(this._parent.getNextHighestDepth());
this.removeMovieClip();
}
};
delete m;
}
}
}
if (!_parent.dirt.hitTest(_x + _parent._x, (_y + _parent._y) + deadcurve, true)) {
_y = _y + deadcurve;
_rotation = _rotation + 3;
}
if (deadcurve < 0) {
_rotation = _rotation + (deadcurve * 10);
}
deadcurve++;
_alpha--;
if (_alpha <= 0) {
if (!evil) {
_root.troops--;
_root.score = _root.score - 10;
}
swapDepths(_root.getNextHighestDepth());
removeMovieClip();
}
} else {
_y = _y - mody;
mody = mody - modya;
if ((mody > 0.5) || (mody < -0.5)) {
modya = -modya;
}
}
if (ovrtarg != "none") {
if ((_parent[ovrtarg].hp <= 0) || (_parent[ovrtarg] == undefined)) {
ovrtarg = "none";
gotox = _x;
} else {
gotox = _parent[ovrtarg]._x;
}
}
if (_currentframe == 1) {
info._visible = active;
if (evil) {
info._visible = true;
if (settarg) {
for (var d in _parent) {
if ((_parent[d].active && (_parent[d].unit)) && (_parent[d].evil != evil)) {
_parent[d].ovrtarg = _name;
}
}
stcon--;
if (stcon <= 0) {
settarg = false;
}
}
}
if (gotox != -100) {
if (_x < gotox) {
_xscale = -100;
acc = maxacc;
} else {
_xscale = 100;
acc = -maxacc;
}
if (Math.abs(gotox - _x) < ((ovrtarg == "none") ? 10 : (range))) {
gotox = -100;
acc = 0;
vel = 0;
}
} else if (vel < 0.25) {
vel = 0;
} else {
acc = 0;
vel = vel * 0.5;
}
vel = vel - acc;
if (vel > maxvel) {
vel = maxvel;
}
if (vel < (-maxvel)) {
vel = -maxvel;
}
_x = _x - vel;
if (gotox != -100) {
var _local4 = 0;
var _local3 = 0;
for (var d in _parent) {
if (_parent[d].gotox == gotox) {
if (d != _name) {
_parent[d].flagged = true;
_local3++;
}
}
}
if (_local3 > 0) {
for (var d in _parent) {
if (_parent[d].flagged) {
_parent[d].gotox = _parent[d].gotox + (-50 + ((100 / _local3) * _local4));
_local4++;
_parent[d].flagged = false;
}
}
}
}
targ = "none";
for (d in _parent) {
if (((_parent[d].evil != evil) && (_parent[d].hp > 0)) && (_parent[d].unit)) {
if ((Math.abs(_x - _parent[d]._x) <= range) && (_parent[d].hp > 0)) {
if (gotox == -100) {
if (_parent[d]._x < _x) {
_xscale = 100;
} else {
_xscale = -100;
}
}
if (((_parent[d]._x - _x) / Math.abs(_parent[d]._x - _x)) != (_xscale / 100)) {
targ = d;
break;
}
targ = "none";
}
}
}
if ((ovrtarg != "none") && (Math.abs(_x - _parent[ovrtarg]._x) <= range)) {
targ = ovrtarg;
}
rel--;
if ((rel <= 0) && (_parent[targ] != undefined)) {
if (_root.soundOn) {
var _local6 = new Sound(this);
_local6.attachSound("sfx" + bulid);
_local6.start(0, 0);
}
rel = rof;
var m = _parent.attachMovie(bulid, "bul" + _parent.getNextHighestDepth(), _parent.getNextHighestDepth(), {_x:_x, _y:_y + gun._y, par:_name, ang:Math.atan2((_y + gun._y) - (_parent[targ]._y - ((_parent[targ].vtype == "troop") ? (_parent[targ]._height / 2) : 0)), _x - _parent[targ]._x), bulid:bulid, damage:damage, evil:evil, adv:adv, vtype:_parent[targ].vtype, dnum:0});
m._visible = false;
m._rotation = (m.ang * 180) / Math.PI;
m.onEnterFrame = function () {
this.dnum++;
if (this._currentframe == 1) {
this._visible = !this._parent[this.par].hitTest(this._x + this._parent._x, this._y + this._parent._y, true);
if (this._visible) {
if (_root.effects) {
var _local4 = this._parent.attachMovie("s" + this.bulid, "smoke" + this._parent.getNextHighestDepth(), this._parent.getNextHighestDepth(), {_x:this._x, _y:this._y});
_local4._rotation = this._rotation;
_local4.onEnterFrame = function () {
this._xscale = (this._yscale = this._yscale - 5);
this._alpha = this._alpha - 10;
if (this._alpha <= 0) {
this.swapDepths(this._parent.getNextHighestDepth());
this.removeMovieClip();
}
};
}
}
this._x = this._x - (Math.cos(this.ang) * 5);
this._y = this._y - (Math.sin(this.ang) * 5);
if (((this._parent.dirt.hitTest(this._x + this._parent._x, this._y + this._parent._y, 1) || (this._x > (this._parent.dirt._width + 50))) || (this._x < -100)) || (this.dnum > 900)) {
this.gotoAndStop(2);
} else {
for (var _local3 in this._parent) {
if (((this._parent[_local3].evil != this.evil) && (this._parent[_local3].unit)) && (this._parent[_local3].hp > 0)) {
if (this._parent[_local3].hitTest(this._x + this._parent._x, this._y + this._parent._y, 1)) {
if (((this._parent[_local3].vtype == "base") && (this.vtype == "base")) || (this._parent[_local3].vtype != "base")) {
if (this._parent[_local3].vtype == _root.advarr[this.adv]) {
this._parent[_local3].hp = this._parent[_local3].hp - (this.damage * 2);
} else {
this._parent[_local3].hp = this._parent[_local3].hp - this.damage;
}
this.gotoAndStop(2);
break;
}
}
}
}
}
}
};
delete m;
}
}
if (_x < 200) {
gotox = 400;
}
if (_x > (_parent.dirt._width - 200)) {
gotox = _parent.dirt._width - 400;
}
}
function onMouseUp() {
if (_currentframe == 1) {
if (!evil) {
if (!Key.isDown(17)) {
if (active) {
if (_parent.goarrow == undefined) {
_parent.attachMovie("arrow", "goarrow", _parent.getNextHighestDepth(), {_x:_root._xmouse - _parent._x, _y:-100});
_parent.goarrow.onEnterFrame = function () {
while (!this._parent.dirt.hitTest(this._x + this._parent._x, this._y + this._parent._y, 1)) {
this._y++;
}
this._alpha = this._alpha - 10;
if (this._alpha <= 0) {
this.swapDepths(this._parent.getNextHighestDepth());
this.removeMovieClip();
}
};
}
ovrtarg = "none";
gotox = _root._xmouse - _parent._x;
}
}
}
}
}
function onPress() {
if (!evil) {
if (_currentframe == 1) {
if (Key.isDown(17)) {
active = !active;
} else {
for (var _local2 in _parent) {
if (_parent[_local2].active) {
_parent[_local2].active = false;
}
}
active = true;
}
}
} else {
settarg = true;
stcon = 5;
}
}
var maxacc = 0.1;
var maxvel = 3;
var range = 400;
var rof = 60;
var damage = 40;
var bulid = "bul2";
var maxhp = 100;
var hp = 100;
var vtype = "flying";
var acc = 0.1;
var adv = 0;
var vel = 0;
var gotox = _x;
var targ = "none";
var ovrtarg = "none";
var rel = 0;
var active = false;
var flagged = false;
var mody = 0.5;
var modya = 0.1;
var deadsmoking = false;
var settarg = false;
var stcon = 0;
var unit = true;
var evil = false;
}
Symbol 755 MovieClip [__Packages.troop] Frame 0
class troop extends MovieClip
{
var _x, main, _currentframe, _parent, gotoAndStop, info, _name, _xscale, _y, _height;
function troop () {
super();
}
function onLoad() {
gotox = _x;
if (evil) {
gotox = 1500;
}
active = false;
}
function onEnterFrame() {
if (evil) {
if (targ != "none") {
gotox = _x;
} else {
gotox = 1500;
}
}
if ((gotox == undefined) || (gotox == NaN)) {
gotox = _x;
}
for (var _local7 in main) {
main[_local7].gotoAndStop(tnum);
}
if (_currentframe < 4) {
if (ovrtarg != "none") {
if ((_parent[ovrtarg].hp <= 0) || (_parent[ovrtarg] == undefined)) {
ovrtarg = "none";
gotox = _x;
} else {
gotox = _parent[ovrtarg]._x;
}
}
if (hp <= 0) {
gotoAndStop(4 + random(3));
} else {
info._visible = active;
if (evil) {
info._visible = true;
if (settarg) {
for (var _local7 in _parent) {
if ((_parent[_local7].active && (_parent[_local7].unit)) && (_parent[_local7].evil != evil)) {
_parent[_local7].ovrtarg = _name;
}
}
stcon--;
if (stcon <= 0) {
settarg = false;
}
}
}
if (_currentframe != 3) {
if (gotox == -100) {
gotoAndStop(1);
} else {
gotoAndStop(2);
}
}
if (gotox != -100) {
if (_x < gotox) {
_xscale = -100;
vel = maxvel;
} else {
_xscale = 100;
vel = -maxvel;
}
if (Math.abs(gotox - _x) < ((ovrtarg == "none") ? 10 : (range))) {
gotox = -100;
vel = 0;
}
}
_x = _x + vel;
var _local3 = 0;
while (_local3 < 20) {
if (!_parent.dirt.hitTest(_x + _parent._x, (_y + _parent._y) + 1, true)) {
_y++;
}
if (_parent.dirt.hitTest(_x + _parent._x, _y + _parent._y, true)) {
_y--;
}
_local3++;
}
if (gotox != -100) {
var _local5 = 0;
var _local4 = 0;
for (var _local7 in _parent) {
if (_parent[_local7].gotox == gotox) {
if (_local7 != _name) {
_parent[_local7].flagged = true;
_local4++;
}
}
}
if (_local4 > 0) {
for (var _local7 in _parent) {
if (_parent[_local7].flagged) {
_parent[_local7].gotox = _parent[_local7].gotox + (-50 + ((100 / _local4) * _local5));
_local5++;
_parent[_local7].flagged = false;
}
}
}
}
targ = "none";
for (var _local7 in _parent) {
if (((_parent[_local7].evil != evil) && (_parent[_local7].hp > 0)) && (_parent[_local7].unit)) {
if ((Math.abs(_x - _parent[_local7]._x) <= range) && (_parent[_local7].hp > 0)) {
if (((_parent[_local7].vtype == "flying") && (aa)) || (_parent[_local7].vtype != "flying")) {
if (gotox == -100) {
if (_parent[_local7]._x < _x) {
_xscale = 100;
} else {
_xscale = -100;
}
}
if (((_parent[_local7]._x - _x) / Math.abs(_parent[_local7]._x - _x)) != (_xscale / 100)) {
targ = _local7;
break;
}
targ = "none";
}
}
}
}
if ((ovrtarg != "none") && (Math.abs(_x - _parent[ovrtarg]._x) <= range)) {
targ = ovrtarg;
}
rel--;
if ((tnum == 3) || (tnum == 5)) {
targ = "none";
if (rel <= 0) {
rel = rof;
for (var _local7 in _parent) {
if (((((tnum == 3) && (_parent[_local7].unit)) && (_parent[_local7].evil == evil)) && (_parent[_local7].vtype == "troop")) && (Math.abs(_parent[_local7]._x - _x) < range)) {
if (_parent[_local7].hp < _parent[_local7].maxhp) {
_parent[_local7].hp = _parent[_local7].hp + 5;
}
if (_parent[_local7].hp > _parent[_local7].maxhp) {
_parent[_local7].hp = _parent[_local7].maxhp;
}
}
if (((((tnum == 5) && (_parent[_local7].unit)) && (_parent[_local7].evil == evil)) && (_parent[_local7].vtype == "vehicle")) && (Math.abs(_parent[_local7]._x - _x) < range)) {
if (_parent[_local7].hp < _parent[_local7].maxhp) {
_parent[_local7].hp = _parent[_local7].hp + 5;
}
if (_parent[_local7].hp > _parent[_local7].maxhp) {
_parent[_local7].hp = _parent[_local7].maxhp;
}
}
}
}
}
if ((rel <= 0) && (_parent[targ] != undefined)) {
if (_root.soundOn) {
var _local9 = new Sound(this);
_local9.attachSound("sfx" + bulid);
_local9.start(0, 0);
}
gotoAndStop(3);
rel = rof;
var _local6 = _parent.attachMovie(bulid, "bul" + _parent.getNextHighestDepth(), _parent.getNextHighestDepth(), {_x:_x, _y:_y - (_height / 2), par:_name, ang:Math.atan2((_y - (_height / 2)) - _parent[targ]._y, _x - _parent[targ]._x), bulid:bulid, damage:damage, evil:evil, adv:adv, vtype:_parent[targ].vtype, dnum:0});
_local6._visible = false;
_local6._rotation = (_local6.ang * 180) / Math.PI;
_local6.onEnterFrame = function () {
this.dnum++;
if (this._currentframe == 1) {
this._visible = !this._parent[this.par].hitTest(this._x + this._parent._x, this._y + this._parent._y, true);
if (this._visible) {
if (_root.effects) {
var _local4 = this._parent.attachMovie("s" + this.bulid, "smoke" + this._parent.getNextHighestDepth(), this._parent.getNextHighestDepth(), {_x:this._x, _y:this._y});
_local4.onEnterFrame = function () {
this._xscale = (this._yscale = this._yscale - 5);
this._alpha = this._alpha - 10;
if (this._alpha <= 0) {
this.swapDepths(this._parent.getNextHighestDepth());
this.removeMovieClip();
}
};
}
}
this._x = this._x - (Math.cos(this.ang) * 5);
this._y = this._y - (Math.sin(this.ang) * 5);
if (((this._parent.dirt.hitTest(this._x + this._parent._x, this._y + this._parent._y, 1) || (this._x > (this._parent.dirt._width + 50))) || (this._x < -100)) || (this.dnum > 900)) {
this.gotoAndStop(2);
} else {
for (var _local3 in this._parent) {
if (((this._parent[_local3].evil != this.evil) && this._parent[_local3].unit) && (this._parent[_local3].hp > 0)) {
if (this._parent[_local3].hitTest(this._x + this._parent._x, this._y + this._parent._y, 1)) {
if (((this._parent[_local3].vtype == "base") && (this.vtype == "base")) || (this._parent[_local3].vtype != "base")) {
if (this._parent[_local3].vtype == _root.advarr[this.adv]) {
this._parent[_local3].hp = this._parent[_local3].hp - (this.damage * 2);
} else {
this._parent[_local3].hp = this._parent[_local3].hp - this.damage;
}
this.gotoAndStop(2);
break;
}
}
}
}
}
}
};
}
}
if (_x < 200) {
gotox = 400;
}
if (_x > (_parent.dirt._width - 200)) {
gotox = _parent.dirt._width - 400;
}
}
}
function onMouseUp() {
if (_currentframe < 4) {
if (!evil) {
if (!Key.isDown(17)) {
if (active) {
if (_parent.goarrow == undefined) {
_parent.attachMovie("arrow", "goarrow", _parent.getNextHighestDepth(), {_x:_root._xmouse - _parent._x, _y:-100});
_parent.goarrow.onEnterFrame = function () {
while (!this._parent.dirt.hitTest(this._x + this._parent._x, this._y + this._parent._y, 1)) {
this._y++;
}
this._alpha = this._alpha - 10;
if (this._alpha <= 0) {
this.swapDepths(this._parent.getNextHighestDepth());
this.removeMovieClip();
}
};
}
ovrtarg = "none";
gotox = _root._xmouse - _parent._x;
}
}
}
}
}
function onPress() {
if (!evil) {
if (_currentframe < 4) {
if (Key.isDown(17)) {
active = !active;
} else {
for (var _local2 in _parent) {
if (_parent[_local2].active) {
_parent[_local2].active = false;
}
}
active = true;
}
}
} else {
settarg = true;
stcon = 5;
}
}
var tnum = 1;
var maxvel = 3;
var range = 400;
var rof = 60;
var damage = 40;
var bulid = "bul2";
var maxhp = 100;
var hp = 100;
var vtype = "troop";
var aa = false;
var adv = 0;
var vel = 0;
var gotox = _x;
var targ = "none";
var ovrtarg = "none";
var rel = 0;
var active = false;
var flagged = false;
var settarg = false;
var stcon = 0;
var unit = true;
var evil = false;
}
Symbol 268 Button
on (release) {
_root.gotoAndStop(4);
}
Symbol 272 Button
on (release) {
_root.nextFrame();
}
Instance of Symbol 280 MovieClip in Symbol 291 MovieClip Frame 1
on (release) {
_root.bgmOn = true;
}
Instance of Symbol 282 MovieClip in Symbol 291 MovieClip Frame 1
on (release) {
_root.bgmOn = false;
_root.bgm.stop();
}
Instance of Symbol 280 MovieClip in Symbol 291 MovieClip Frame 1
on (release) {
_root.soundOn = true;
}
Instance of Symbol 282 MovieClip in Symbol 291 MovieClip Frame 1
on (release) {
_root.soundOn = false;
}
Instance of Symbol 284 MovieClip in Symbol 291 MovieClip Frame 1
on (release) {
_root.prevFrame();
}
Instance of Symbol 286 MovieClip in Symbol 291 MovieClip Frame 1
on (release) {
_quality = "LOW";
}
Instance of Symbol 288 MovieClip in Symbol 291 MovieClip Frame 1
on (release) {
_quality = "MEDIUM";
}
Instance of Symbol 290 MovieClip in Symbol 291 MovieClip Frame 1
on (release) {
_quality = "HIGH";
}
Symbol 380 MovieClip Frame 1
stop();
Instance of Symbol 373 MovieClip "desc" in Symbol 380 MovieClip Frame 1
onClipEvent (load) {
this._visible = false;
}
Symbol 380 MovieClip Frame 2
stop();
Instance of Symbol 376 MovieClip "desc" in Symbol 380 MovieClip Frame 2
onClipEvent (load) {
this._visible = false;
}
Symbol 380 MovieClip Frame 3
stop();
Instance of Symbol 379 MovieClip "desc" in Symbol 380 MovieClip Frame 3
onClipEvent (load) {
this._visible = false;
}
Symbol 400 MovieClip Frame 1
stop();
Symbol 416 MovieClip Frame 1
stop();
Symbol 416 MovieClip Frame 2
stop();
Symbol 416 MovieClip Frame 3
stop();
Symbol 416 MovieClip Frame 4
stop();
Symbol 416 MovieClip Frame 5
stop();
Symbol 416 MovieClip Frame 6
stop();
Symbol 416 MovieClip Frame 7
stop();
Symbol 435 MovieClip Frame 1
stop();
Instance of Symbol 422 MovieClip "desc" in Symbol 435 MovieClip Frame 1
onClipEvent (load) {
this._visible = false;
}
Symbol 435 MovieClip Frame 2
stop();
Instance of Symbol 429 MovieClip "desc" in Symbol 435 MovieClip Frame 2
onClipEvent (load) {
this._visible = false;
}
Symbol 435 MovieClip Frame 3
stop();
Instance of Symbol 434 MovieClip "desc" in Symbol 435 MovieClip Frame 3
onClipEvent (load) {
this._visible = false;
}
Symbol 459 MovieClip Frame 1
stop();
Symbol 464 MovieClip Frame 1
stop();
Symbol 464 MovieClip Frame 2
stop();
Symbol 464 MovieClip Frame 3
stop();
Symbol 464 MovieClip Frame 4
stop();
Symbol 465 MovieClip Frame 1
for (d in this) {
this[d].desc._visible = false;
this[d].odepth = this[d].getDepth();
this[d].onRollOver = function () {
for (d in this._parent) {
this._parent[d]._alpha = 20;
}
this._alpha = 100;
this.swapDepths(this._parent.getNextHighestDepth());
this.desc.gotoAndStop(this._currentframe);
this.desc._visible = true;
};
this[d].onRollOut = function () {
for (d in this._parent) {
this._parent[d]._alpha = 100;
}
this.swapDepths(this.odepth);
this.desc._visible = false;
};
}
Instance of Symbol 380 MovieClip in Symbol 465 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(_root.comupgrade + 1);
}
on (press) {
_root.hud.buildMenu.gotoAndStop(7);
}
Instance of Symbol 416 MovieClip in Symbol 465 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(_root.resupgrade + 1);
}
on (press) {
_root.hud.buildMenu.gotoAndStop(4);
}
Instance of Symbol 435 MovieClip in Symbol 465 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(_root.banupgrade + 1);
}
on (press) {
_root.hud.buildMenu.gotoAndStop(8);
}
Instance of Symbol 464 MovieClip in Symbol 465 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(_root.powupgrade + 1);
}
on (press) {
_root.hud.buildMenu.gotoAndStop(6);
}
Symbol 478 MovieClip Frame 1
stop();
Instance of Symbol 473 MovieClip "desc" in Symbol 478 MovieClip Frame 1
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 477 MovieClip "desc" in Symbol 478 MovieClip Frame 2
onClipEvent (load) {
this._visible = false;
}
Symbol 491 MovieClip Frame 1
stop();
Instance of Symbol 482 MovieClip "desc" in Symbol 491 MovieClip Frame 1
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 486 MovieClip "desc" in Symbol 491 MovieClip Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 490 MovieClip "desc" in Symbol 491 MovieClip Frame 3
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 497 MovieClip "desc" in Symbol 498 MovieClip Frame 1
onClipEvent (load) {
this._visible = false;
}
Symbol 519 MovieClip Frame 1
stop();
Instance of Symbol 509 MovieClip "desc" in Symbol 519 MovieClip Frame 1
onClipEvent (load) {
this._visible = false;
}
Symbol 528 MovieClip Frame 1
stop();
Instance of Symbol 523 MovieClip "desc" in Symbol 528 MovieClip Frame 1
onClipEvent (load) {
this._visible = false;
}
Symbol 528 MovieClip Frame 2
stop();
Instance of Symbol 527 MovieClip "desc" in Symbol 528 MovieClip Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 469 MovieClip in Symbol 529 MovieClip Frame 1
on (press) {
_root.hud.buildMenu.gotoAndStop(2);
}
Instance of Symbol 478 MovieClip in Symbol 529 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_root.m1 == 0) {
this._visible = false;
} else {
this._visible = true;
this.gotoAndStop(_root.m1);
}
}
on (press) {
_root.hud.buildMenu.gotoAndStop(12);
}
on (rollOver) {
this.desc._visible = true;
}
on (rollOut) {
this.desc._visible = false;
}
Instance of Symbol 491 MovieClip in Symbol 529 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_root.m2 == 0) {
this._visible = false;
} else {
this._visible = true;
this.gotoAndStop(_root.m2);
}
}
on (press) {
_root.hud.buildMenu.gotoAndStop(13);
}
on (rollOver) {
this.desc._visible = true;
}
on (rollOut) {
this.desc._visible = false;
}
Instance of Symbol 498 MovieClip in Symbol 529 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_root.m3 == 0) {
this._visible = false;
} else {
this._visible = true;
this.gotoAndStop(_root.m3);
}
}
on (press) {
_root.hud.buildMenu.gotoAndStop(14);
}
on (rollOver) {
this.desc._visible = true;
}
on (rollOut) {
this.desc._visible = false;
}
Instance of Symbol 519 MovieClip in Symbol 529 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_root.m4 == 0) {
this._visible = false;
} else {
this._visible = true;
this.gotoAndStop(_root.m4);
}
}
on (press) {
_root.hud.buildMenu.gotoAndStop(16);
}
on (rollOver) {
this.desc._visible = true;
}
on (rollOut) {
this.desc._visible = false;
}
Instance of Symbol 528 MovieClip in Symbol 529 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_root.m5 == 0) {
this._visible = false;
} else {
this._visible = true;
this.gotoAndStop(_root.m5);
}
}
on (press) {
_root.hud.buildMenu.gotoAndStop(15);
}
on (rollOver) {
this.desc._visible = true;
}
on (rollOut) {
this.desc._visible = false;
}
Symbol 530 MovieClip Frame 1
onMouseDown = function () {
this.dragging = true;
this.createEmptyMovieClip("box", this.getNextHighestDepth());
this.sx = _root._xmouse - this._x;
this.sy = _root._ymouse - this._y;
};
onMouseMove = function () {
if (this.dragging) {
this.box.clear();
this.box.lineStyle(1, 16711680, 50);
this.box.moveTo(this.sx, this.sy);
this.box.beginFill(16711680, 50);
this.box.lineTo(this.sx, _root._ymouse - this._y);
this.box.lineTo(_root._xmouse - this._x, _root._ymouse - this._y);
this.box.lineTo(_root._xmouse - this._x, this.sy);
this.box.lineTo(this.sx, this.sy);
this.box.endFill();
}
};
onMouseUp = function () {
if (this.dragging) {
for (var _local3 in this) {
if (this.box.hitTest(this[_local3])) {
this[_local3].active = true;
}
}
this.box.removeMovieClip();
this.box.swapDepths(_root.getNextHighestDepth());
this.dragging = false;
}
};
onEnterFrame = function () {
if (Key.isDown(17)) {
if (this.dragging) {
this.box.removeMovieClip();
this.box.swapDepths(_root.getNextHighestDepth());
this.dragging = false;
}
}
if (Key.isDown(68)) {
for (var _local3 in this) {
this[_local3].active = false;
}
}
};
Instance of Symbol 465 MovieClip in Symbol 530 MovieClip Frame 1
onClipEvent (load) {
this.evil = false;
this.unit = true;
this.vtype = "base";
this.hp = 500;
}
onClipEvent (enterFrame) {
this.alarm = false;
for (d in this._parent) {
if (this._parent[d].evil && (this._parent[d].targ == this._name)) {
this.alarm = true;
break;
}
}
if (((!this.alarming) && (this.alarm)) && (_root.soundOn)) {
var son = new Sound(this);
son.attachSound("alarm");
son.start(0, 1000);
this.alarming = true;
}
if (this.alarming && (!this.alarm)) {
this.son.stop();
this.alarming = false;
}
_root.hp = (this.hp / 500) * 100;
}
Symbol 540 MovieClip Frame 1
stop();
Symbol 541 MovieClip Frame 1
stop();
Symbol 543 MovieClip Frame 1
stop();
Symbol 545 MovieClip Frame 1
stop();
Symbol 547 MovieClip Frame 1
stop();
Symbol 549 MovieClip Frame 1
stop();
Symbol 551 MovieClip Frame 1
stop();
Symbol 553 MovieClip Frame 1
stop();
Symbol 555 MovieClip Frame 1
stop();
Symbol 557 MovieClip Frame 1
stop();
Symbol 559 MovieClip Frame 1
stop();
Symbol 566 MovieClip Frame 1
stop();
Instance of Symbol 540 MovieClip in Symbol 566 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.resbuilt * 0.25));
}
Symbol 566 MovieClip Frame 2
stop();
Symbol 566 MovieClip Frame 3
stop();
Symbol 566 MovieClip Frame 4
stop();
Symbol 566 MovieClip Frame 5
stop();
Symbol 566 MovieClip Frame 6
stop();
Symbol 566 MovieClip Frame 7
stop();
Symbol 571 MovieClip Frame 1
stop();
Instance of Symbol 540 MovieClip in Symbol 571 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.banbuilt * 0.25));
}
Symbol 578 MovieClip Frame 1
stop();
Instance of Symbol 540 MovieClip in Symbol 578 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.powbuilt * 0.25));
}
Symbol 578 MovieClip Frame 2
stop();
Symbol 578 MovieClip Frame 3
stop();
Symbol 578 MovieClip Frame 4
stop();
Symbol 582 MovieClip Frame 1
stop();
Instance of Symbol 540 MovieClip in Symbol 582 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.combuilt * 0.25));
}
Symbol 584 MovieClip Frame 1
stop();
Instance of Symbol 473 MovieClip "desc" in Symbol 584 MovieClip Frame 1
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 540 MovieClip in Symbol 584 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.barbuilt * 0.25));
}
Instance of Symbol 477 MovieClip "desc" in Symbol 584 MovieClip Frame 2
onClipEvent (load) {
this._visible = false;
}
Symbol 585 MovieClip Frame 1
stop();
Instance of Symbol 482 MovieClip "desc" in Symbol 585 MovieClip Frame 1
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 540 MovieClip in Symbol 585 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.warbuilt * 0.25));
}
Instance of Symbol 486 MovieClip "desc" in Symbol 585 MovieClip Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 490 MovieClip "desc" in Symbol 585 MovieClip Frame 3
onClipEvent (load) {
this._visible = false;
}
Symbol 586 MovieClip Frame 1
stop();
Instance of Symbol 540 MovieClip in Symbol 586 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.labbuilt * 0.25));
}
Symbol 587 MovieClip Frame 1
stop();
Instance of Symbol 540 MovieClip in Symbol 587 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.nucbuilt * 0.25));
}
Symbol 589 MovieClip Frame 1
stop();
Instance of Symbol 540 MovieClip in Symbol 589 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.airbuilt * 0.25));
}
Symbol 593 MovieClip Frame 1
stop();
Symbol 593 MovieClip Frame 2
stop();
Symbol 593 MovieClip Frame 3
stop();
Symbol 593 MovieClip Frame 4
stop();
Symbol 593 MovieClip Frame 5
stop();
Symbol 593 MovieClip Frame 6
stop();
Symbol 593 MovieClip Frame 7
stop();
Symbol 601 MovieClip Frame 1
stop();
Symbol 605 MovieClip Frame 1
stop();
Symbol 609 MovieClip Frame 1
stop();
Symbol 611 MovieClip Frame 1
stop();
Symbol 614 MovieClip Frame 1
stop();
Symbol 621 MovieClip Frame 1
stop();
Symbol 621 MovieClip Frame 2
stop();
Symbol 621 MovieClip Frame 3
stop();
Symbol 621 MovieClip Frame 4
stop();
Symbol 628 MovieClip Frame 1
stop();
Symbol 633 MovieClip Frame 1
stop();
Symbol 654 MovieClip Frame 1
stop();
Instance of Symbol 541 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 900;
this.built = 0;
this.cost = 1000;
}
on (rollOver) {
_root.infoBox("Demolition Truck", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if ((_root.m2 > 2) && (_root.m4 > 0)) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "War Factory (Upgrade 2) and Nuclear Facility Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 11;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("demotruck", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:251});
m.active = false;
m.maxacc = 0.1;
m.maxvel = 4;
m.range = 1;
m.rof = 200;
m.damage = 10;
m.bulid = "bul2";
m.maxhp = 40;
m.hp = 40;
m.aa = true;
m.adv = 2;
m.explosive = true;
delete m;
}
}
Instance of Symbol 543 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 300;
this.built = 0;
this.cost = 200;
}
on (rollOver) {
_root.infoBox("Chopper", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if (_root.m5 > 0) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "Air Base Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 11;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("chopper", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:50});
m.maxacc = 0.4;
m.maxvel = 10;
m.range = 350;
m.rof = 10;
m.damage = 0.5;
m.bulid = "bul1";
m.maxhp = 16;
m.hp = 16;
m.adv = 3;
delete m;
}
}
Instance of Symbol 545 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 600;
this.built = 0;
this.cost = 350;
}
on (rollOver) {
_root.infoBox("Fighter Jet", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if (_root.m5 > 1) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "Air Base (Upgrade 1) Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 11;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("plane", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:50});
m.active = false;
m.maxacc = 0.5;
m.maxvel = 12;
m.range = 300;
m.rof = 60;
m.damage = 5;
m.bulid = "bul4";
m.maxhp = 24;
m.hp = 24;
m.adv = 2;
delete m;
}
}
Instance of Symbol 547 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 900;
this.built = 0;
this.cost = 700;
}
on (rollOver) {
_root.infoBox("Bomber", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if ((_root.m5 > 1) && (_root.m5 > 0)) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "Air Base (Upgrade 2) and Nuclear Facility Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 11;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("bomber", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:50});
m.active = false;
m.maxacc = 0.1;
m.maxvel = 3;
m.range = 400;
m.rof = 200;
m.damage = 50;
m.bulid = "bul3";
m.maxhp = 40;
m.hp = 40;
m.aa = true;
m.adv = 2;
delete m;
}
}
Instance of Symbol 549 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 200;
this.built = 0;
this.cost = 70;
}
on (rollOver) {
_root.infoBox("Jeep", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if (_root.m2 > 0) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "War Factory Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 10;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("jeep", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:251});
m.maxacc = 0.4;
m.maxvel = 10;
m.range = 150;
m.rof = 10;
m.damage = 0.5;
m.bulid = "bul1";
m.maxhp = 16;
m.hp = 16;
m.aa = true;
m.adv = 3;
delete m;
}
}
Instance of Symbol 551 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 300;
this.built = 0;
this.cost = 100;
}
on (rollOver) {
_root.infoBox("Light Tank", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if (_root.m2 > 0) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "War Factory Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 10;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("light", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:251});
m.maxacc = 0.2;
m.maxvel = 4;
m.range = 200;
m.rof = 45;
m.damage = 10;
m.bulid = "bul2";
m.maxhp = 24;
m.hp = 24;
m.aa = false;
m.adv = 0;
delete m;
}
}
Instance of Symbol 553 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 400;
this.built = 0;
this.cost = 250;
}
on (rollOver) {
_root.infoBox("Medium Tank", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if (_root.m2 > 1) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "War Factory (Upgrade 1) Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 10;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("medium", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:251});
m.maxacc = 0.1;
m.maxvel = 3;
m.range = 300;
m.rof = 90;
m.damage = 16;
m.bulid = "bul2";
m.maxhp = 32;
m.hp = 32;
m.aa = false;
m.adv = 2;
delete m;
}
}
Instance of Symbol 555 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 600;
this.built = 0;
this.cost = 350;
}
on (rollOver) {
_root.infoBox("Heavy Tank", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if (_root.m2 > 2) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "War Factory (Upgrade 2) Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 10;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("heavy", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:251});
m.maxacc = 0.1;
m.maxvel = 2;
m.range = 400;
m.rof = 140;
m.damage = 50;
m.bulid = "bul2";
m.maxhp = 55;
m.hp = 55;
m.aa = false;
m.adv = 2;
delete m;
}
}
Instance of Symbol 557 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 400;
this.built = 0;
this.cost = 250;
}
on (rollOver) {
_root.infoBox("Rocket Tank", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if ((_root.m2 > 1) && (_root.m3 > 0)) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "War Factory (Upgrade 1) and Laboratory Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 10;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("rockettank", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:251});
m.maxacc = 0.1;
m.maxvel = 3;
m.range = 600;
m.rof = 90;
m.damage = 25;
m.bulid = "bul4";
m.maxhp = 32;
m.hp = 32;
m.aa = true;
m.adv = 1;
delete m;
}
}
Instance of Symbol 559 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 100;
this.built = 0;
this.cost = 25;
this.tnum = 1;
for (d in this.blokey) {
this.blokey[d].gotoAndStop(this.tnum);
}
}
on (rollOver) {
_root.infoBox("Rifleman", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if (_root.m1 > 0) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "Barracks Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 9;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("troop", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:251});
m.maxvel = 4;
m.range = 150;
m.rof = 30;
m.damage = 1.5;
m.bulid = "bul1";
m.maxhp = 10;
m.hp = 10;
m.aa = false;
m.adv = 0;
m.tnum = this.tnum;
delete m;
}
}
Instance of Symbol 559 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 150;
this.built = 0;
this.cost = 30;
this.tnum = 2;
for (d in this.blokey) {
this.blokey[d].gotoAndStop(this.tnum);
}
}
on (rollOver) {
_root.infoBox("Machine-gunner", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if (_root.m1 > 0) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "Barracks Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 9;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("troop", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:251});
m.maxvel = 3;
m.range = 150;
m.rof = 15;
m.damage = 1;
m.bulid = "bul1";
m.maxhp = 10;
m.hp = 10;
m.aa = false;
m.adv = 0;
m.tnum = this.tnum;
delete m;
}
}
Instance of Symbol 559 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 150;
this.built = 0;
this.cost = 50;
this.tnum = 3;
for (d in this.blokey) {
this.blokey[d].gotoAndStop(this.tnum);
}
}
on (rollOver) {
_root.infoBox("Medic", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if (_root.m1 > 1) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "Advanced Barracks Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 9;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("troop", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:251});
m.maxvel = 4;
m.range = 100;
m.rof = 60;
m.damage = 1;
m.bulid = "bul1";
m.maxhp = 10;
m.hp = 10;
m.aa = false;
m.adv = 0;
m.tnum = this.tnum;
delete m;
}
}
Instance of Symbol 559 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 200;
this.built = 0;
this.cost = 40;
this.tnum = 4;
for (d in this.blokey) {
this.blokey[d].gotoAndStop(this.tnum);
}
}
on (rollOver) {
_root.infoBox("Rocket Soldier", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if (_root.m1 > 1) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "Advanced Barracks Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 9;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("troop", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:251});
m.maxvel = 3;
m.range = 250;
m.rof = 45;
m.damage = 4;
m.bulid = "bul2";
m.maxhp = 10;
m.hp = 10;
m.aa = true;
m.adv = 1;
m.tnum = this.tnum;
delete m;
}
}
Instance of Symbol 559 MovieClip in Symbol 654 MovieClip Frame 1
onClipEvent (load) {
this.buildt = 200;
this.built = 0;
this.cost = 50;
this.tnum = 5;
for (d in this.blokey) {
this.blokey[d].gotoAndStop(this.tnum);
}
}
on (rollOver) {
_root.infoBox("Medic", "$" + this.cost, "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
_root.removeInfo();
if ((_root.m1 > 0) && (_root.m2 > 0)) {
if (!this.building) {
if (this.cost > _root.money) {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
} else if (_root.troops < 15) {
_root.troops++;
_root.money = _root.money - this.cost;
this.building = true;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You may only have up to 15 units at once";
}
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "Barracks and War Factory Required";
}
}
onClipEvent (enterFrame) {
this._visible = this._parent._currentframe == 9;
if (this.building) {
this.built = this.built + (100 / this.buildt);
this.bbar.gotoAndStop(1);
this.bbar.gotoAndStop(Math.round((this.built / 100) * 25));
} else {
this.bbar.gotoAndStop(1);
}
if (this.built >= 100) {
_root.errors._alpha = 100;
_root.errors.error.text = "Unit Ready";
this.built = 0;
this.building = false;
m = _root.ground.attachMovie("troop", "unit" + _root.ground.getNextHighestDepth(), _root.ground.getNextHighestDepth(), {_x:1370, _y:251});
m.maxvel = 4;
m.range = 100;
m.rof = 60;
m.damage = 1;
m.bulid = "bul1";
m.maxhp = 10;
m.hp = 10;
m.aa = false;
m.adv = 0;
m.tnum = this.tnum;
delete m;
}
}
Instance of Symbol 566 MovieClip in Symbol 654 MovieClip Frame 1
on (rollOver) {
_root.infoBox("Residential", "", "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
if (!this.masker._visible) {
_root.removeInfo();
this._parent.gotoAndStop(4);
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.resupgrade + 1);
}
this.masker._visible = _root.resupgrade >= (_root.resNames.length - 2);
}
Instance of Symbol 571 MovieClip in Symbol 654 MovieClip Frame 1
on (rollOver) {
_root.infoBox("Bank Offices", "", "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
if (!this.masker._visible) {
_root.removeInfo();
this._parent.gotoAndStop(8);
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.banupgrade + 1);
}
this.masker._visible = _root.banupgrade >= (_root.banNames.length - 2);
}
Instance of Symbol 578 MovieClip in Symbol 654 MovieClip Frame 1
on (rollOver) {
_root.infoBox("Power plant", "", "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
if (!this.masker._visible) {
_root.removeInfo();
this._parent.gotoAndStop(6);
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.powupgrade + 1);
}
this.masker._visible = _root.powupgrade >= (_root.powNames.length - 2);
}
Instance of Symbol 582 MovieClip in Symbol 654 MovieClip Frame 1
on (rollOver) {
_root.infoBox("Commercial", "", "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
if (!this.masker._visible) {
_root.removeInfo();
this._parent.gotoAndStop(7);
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.comupgrade + 1);
}
this.masker._visible = _root.comupgrade >= (_root.comNames.length - 2);
}
Instance of Symbol 584 MovieClip in Symbol 654 MovieClip Frame 2
on (rollOver) {
_root.infoBox("Barracks", "", "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
if (!this.masker._visible) {
_root.removeInfo();
this._parent.gotoAndStop(12);
}
}
onClipEvent (enterFrame) {
this.masker._visible = false;
this.gotoAndStop(_root.m1 + 1);
}
Instance of Symbol 585 MovieClip in Symbol 654 MovieClip Frame 2
on (rollOver) {
_root.infoBox("War Factory", "", "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
if (!this.masker._visible) {
_root.removeInfo();
this._parent.gotoAndStop(13);
}
}
onClipEvent (enterFrame) {
this.masker._visible = false;
this.gotoAndStop(_root.m2 + 1);
}
Instance of Symbol 586 MovieClip in Symbol 654 MovieClip Frame 2
on (rollOver) {
_root.infoBox("War Laboratory", "", "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
if (!this.masker._visible) {
_root.removeInfo();
this._parent.gotoAndStop(14);
}
}
onClipEvent (enterFrame) {
this.masker._visible = false;
this.gotoAndStop(_root.m3 + 1);
}
Instance of Symbol 587 MovieClip in Symbol 654 MovieClip Frame 2
on (rollOver) {
_root.infoBox("Nuclear Facility", "", "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
if (!this.masker._visible) {
_root.removeInfo();
this._parent.gotoAndStop(16);
}
}
onClipEvent (enterFrame) {
this._visible = _root.m3 > 0;
this.masker._visible = false;
this.gotoAndStop(_root.m4 + 1);
}
Instance of Symbol 589 MovieClip in Symbol 654 MovieClip Frame 2
on (rollOver) {
_root.infoBox("Air Base", "", "");
}
on (rollOut) {
_root.removeInfo();
}
on (press) {
if (!this.masker._visible) {
_root.removeInfo();
this._parent.gotoAndStop(15);
}
}
onClipEvent (enterFrame) {
this.masker._visible = false;
this.gotoAndStop(_root.m5 + 1);
}
Instance of Symbol 593 MovieClip in Symbol 654 MovieClip Frame 4
on (press) {
if ((!_root.resbuilding) && (!this.masker._visible)) {
_root.infoBoxb._visible = true;
_root.infoBoxb.named.text = _root.resNames[_root.resupgrade + 1];
_root.infoBoxb.cost.text = "$" + _root.resPrices[_root.resupgrade + 1];
_root.infoBoxb.power.text = _root.resPower[_root.resupgrade + 1];
_root.infoBoxb.body.text = "Building a bigger residential zone increases the ammount of people in your city. The more people you have in your city the greater the income.";
_root.infoBoxb.price = _root.resPrices[_root.resupgrade + 1];
_root.infoBoxb.btype = "res";
_root.infoBoxb.militarybuilding = false;
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.resupgrade + 2);
}
this.masker._visible = _root.resbuilding;
if (_root.resupgrade >= (_root.resNames.length - 2)) {
this.masker._visible = true;
}
this.useHandCursor = !this.masker._visible;
this._parent.txt1.text = _root.resNames[_root.resupgrade + 1];
this._parent.txt2.text = "Max Population: " + _root.resDesc[_root.resupgrade + 1];
}
Instance of Symbol 540 MovieClip "buildres" in Symbol 654 MovieClip Frame 4
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.resbuilt * 0.25));
}
Instance of Symbol 621 MovieClip in Symbol 654 MovieClip Frame 6
on (press) {
if ((!_root.powbuilding) && (!this.masker._visible)) {
_root.infoBoxb._visible = true;
_root.infoBoxb.named.text = _root.powNames[_root.powupgrade + 1];
_root.infoBoxb.cost.text = "$" + _root.powPrices[_root.powupgrade + 1];
_root.infoBoxb.power.text = "N/A";
_root.infoBoxb.body.text = "Building bigger power plants means you will have more power to run your city. If you are using too much power, building will take a lot longer.";
_root.infoBoxb.price = _root.powPrices[_root.powupgrade + 1];
_root.infoBoxb.btype = "pow";
_root.infoBoxb.militarybuilding = false;
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.powupgrade + 2);
}
this.masker._visible = _root.powbuilding;
if (_root.powupgrade >= (_root.powNames.length - 2)) {
this.masker._visible = true;
}
this.useHandCursor = !this.masker._visible;
this._parent.txt1.text = _root.powNames[_root.powupgrade + 1];
this._parent.txt2.text = _root.powDesc[_root.powupgrade + 1];
}
Instance of Symbol 540 MovieClip in Symbol 654 MovieClip Frame 6
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.powbuilt * 0.25));
}
Instance of Symbol 628 MovieClip in Symbol 654 MovieClip Frame 7
on (press) {
if ((!_root.combuilding) && (!this.masker._visible)) {
_root.infoBoxb._visible = true;
_root.infoBoxb.named.text = _root.comNames[_root.comupgrade + 1];
_root.infoBoxb.cost.text = "$" + _root.comPrices[_root.comupgrade + 1];
_root.infoBoxb.power.text = _root.comPower[_root.comupgrade + 1];
_root.infoBoxb.body.text = "Better commercial buildings means better productivity. Higher productivity means building will be much faster.";
_root.infoBoxb.price = _root.comPrices[_root.comupgrade + 1];
_root.infoBoxb.btype = "com";
_root.infoBoxb.militarybuilding = false;
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.comupgrade + 2);
}
this.masker._visible = _root.combuilding;
if (_root.comupgrade >= (_root.comNames.length - 2)) {
this.masker._visible = true;
}
this.useHandCursor = !this.masker._visible;
this._parent.txt1.text = _root.comNames[_root.comupgrade + 1];
this._parent.txt2.text = _root.comDesc[_root.comupgrade + 1];
}
Instance of Symbol 540 MovieClip in Symbol 654 MovieClip Frame 7
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.combuilt * 0.25));
}
Instance of Symbol 633 MovieClip in Symbol 654 MovieClip Frame 8
on (press) {
if ((!_root.banbuilding) && (!this.masker._visible)) {
_root.infoBoxb._visible = true;
_root.infoBoxb.named.text = _root.banNames[_root.banupgrade + 1];
_root.infoBoxb.cost.text = "$" + _root.banPrices[_root.banupgrade + 1];
_root.infoBoxb.power.text = _root.banPower[_root.banupgrade + 1];
_root.infoBoxb.body.text = "Making your banks better will multiply your cities total earnings";
_root.infoBoxb.price = _root.banPrices[_root.banupgrade + 1];
_root.infoBoxb.btype = "ban";
_root.infoBoxb.militarybuilding = false;
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.banupgrade + 2);
}
this.masker._visible = _root.banbuilding;
if (_root.banupgrade >= (_root.banNames.length - 2)) {
this.masker._visible = true;
}
this.useHandCursor = !this.masker._visible;
this._parent.txt1.text = _root.banNames[_root.banupgrade + 1];
this._parent.txt2.text = _root.banDesc[_root.banupgrade + 1];
}
Instance of Symbol 540 MovieClip in Symbol 654 MovieClip Frame 8
onClipEvent (enterFrame) {
this.gotoAndStop(1);
this.gotoAndStop(Math.round(_root.banbuilt * 0.25));
}
Instance of Symbol 637 MovieClip in Symbol 654 MovieClip Frame 9
on (press) {
this._parent.nextFrame();
}
Instance of Symbol 639 MovieClip in Symbol 654 MovieClip Frame 10
on (press) {
this._parent.prevFrame();
}
Instance of Symbol 642 MovieClip in Symbol 654 MovieClip Frame 12
on (press) {
this._parent.gotoAndStop(9);
}
Instance of Symbol 584 MovieClip in Symbol 654 MovieClip Frame 12
on (press) {
if ((!_root.barbuilding) && (!this.masker._visible)) {
_root.infoBoxb._visible = true;
_root.infoBoxb.named.text = _root.barNames[_root.m1];
_root.infoBoxb.cost.text = "$" + _root.barPrices[_root.m1];
_root.infoBoxb.power.text = _root.barPower[_root.m1 + 1];
_root.infoBoxb.body.text = "Your Barracks produced your infantry. Upgrading the barracks will enable you to train better infantry.";
_root.infoBoxb.price = _root.barPrices[_root.m1];
_root.infoBoxb.btype = "bar";
_root.infoBoxb.militarybuilding = true;
_root.infoBoxb.mnum = 1;
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.m1 + 1);
}
this.masker._visible = _root.barbuilding;
if (_root.m1 >= _root.barNames.length) {
this.masker._visible = true;
}
this.useHandCursor = !this.masker._visible;
}
Instance of Symbol 645 MovieClip in Symbol 654 MovieClip Frame 13
on (press) {
this._parent.gotoAndStop(10);
}
Instance of Symbol 585 MovieClip in Symbol 654 MovieClip Frame 13
on (press) {
if ((!_root.warbuilding) && (!this.masker._visible)) {
_root.infoBoxb._visible = true;
_root.infoBoxb.named.text = _root.warNames[_root.m2];
_root.infoBoxb.cost.text = "$" + _root.warPrices[_root.m2];
_root.infoBoxb.power.text = _root.warPower[_root.m2 + 1];
_root.infoBoxb.body.text = "Your tank factory will produce your vehicles. Upgrading the tank factory and building a research center will give you the capability to produce better weapons.";
_root.infoBoxb.price = _root.warPrices[_root.m2];
_root.infoBoxb.btype = "war";
_root.infoBoxb.militarybuilding = true;
_root.infoBoxb.mnum = 2;
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.m2 + 1);
}
this.masker._visible = _root.warbuilding;
if (_root.m2 >= _root.warNames.length) {
this.masker._visible = true;
}
this.useHandCursor = !this.masker._visible;
}
Instance of Symbol 586 MovieClip in Symbol 654 MovieClip Frame 14
on (press) {
if ((!_root.labbuilding) && (!this.masker._visible)) {
_root.infoBoxb._visible = true;
_root.infoBoxb.named.text = _root.labNames[_root.m3];
_root.infoBoxb.cost.text = "$" + _root.labPrices[_root.m3];
_root.infoBoxb.power.text = _root.labPower[_root.m3 + 1];
_root.infoBoxb.body.text = "The research center will give you the technology to produce better units.";
_root.infoBoxb.price = _root.labPrices[_root.m3];
_root.infoBoxb.btype = "lab";
_root.infoBoxb.militarybuilding = true;
_root.infoBoxb.mnum = 3;
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.m3 + 1);
}
this.masker._visible = _root.labbuilding;
if (_root.m3 >= _root.labNames.length) {
this.masker._visible = true;
}
this.useHandCursor = !this.masker._visible;
}
Instance of Symbol 649 MovieClip in Symbol 654 MovieClip Frame 15
on (press) {
this._parent.gotoAndStop(11);
}
Instance of Symbol 589 MovieClip in Symbol 654 MovieClip Frame 15
on (press) {
if ((!_root.airbuilding) && (!this.masker._visible)) {
_root.infoBoxb._visible = true;
_root.infoBoxb.named.text = _root.airNames[_root.m5];
_root.infoBoxb.cost.text = "$" + _root.airPrices[_root.m5];
_root.infoBoxb.power.text = _root.airPower[_root.m5 + 1];
_root.infoBoxb.body.text = "The air base allows you to produce flying units.";
_root.infoBoxb.price = _root.airPrices[_root.m5];
_root.infoBoxb.btype = "air";
_root.infoBoxb.militarybuilding = true;
_root.infoBoxb.mnum = 5;
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.m5 + 1);
}
this.masker._visible = _root.airbuilding;
if (_root.m5 >= _root.airNames.length) {
this.masker._visible = true;
}
this.useHandCursor = !this.masker._visible;
}
Instance of Symbol 587 MovieClip in Symbol 654 MovieClip Frame 16
on (press) {
if ((!_root.nucbuilding) && (!this.masker._visible)) {
_root.infoBoxb._visible = true;
_root.infoBoxb.named.text = _root.nucNames[_root.m4];
_root.infoBoxb.cost.text = "$" + _root.nucPrices[_root.m4];
_root.infoBoxb.power.text = _root.nucPower[_root.m4 + 1];
_root.infoBoxb.body.text = "The nuclear plant allows you to send nuclear warheads! It also allows you to use nuclear technology in some vehicles.";
_root.infoBoxb.price = _root.nucPrices[_root.m4];
_root.infoBoxb.btype = "nuc";
_root.infoBoxb.militarybuilding = true;
_root.infoBoxb.mnum = 4;
}
}
onClipEvent (enterFrame) {
if (!this.masker._visible) {
this.gotoAndStop(_root.m4 + 1);
}
this.masker._visible = _root.nucbuilding;
if (_root.m4 >= _root.nucNames.length) {
this.masker._visible = true;
}
this.useHandCursor = !this.masker._visible;
}
Instance of Symbol 653 MovieClip in Symbol 654 MovieClip Frame 16
onClipEvent (enterFrame) {
this._visible = _root.m4 > 0;
if (this._visible) {
this._parent.nuk.text = ("Nuke: " + _root.nukeready) + "% complete";
} else {
this._parent.nuk.text = "";
}
}
on (press) {
if (_root.nuk >= 100) {
_root.nuk = 0;
if (_root.ground.nukeboom == undefined) {
m = _root.ground.attachMovie("sdexplosion", "nukeboom", _root.ground.getNextHighestDepth(), {_x:1580, _y:255});
m.onEnterFrame = function () {
for (var _local2 in this._parent) {
if (this._parent[_local2].unit) {
this._parent[_local2].hp = this._parent[_local2].hp - 0.7;
}
}
};
delete m;
}
}
}
Symbol 667 MovieClip Frame 1
for (d in this) {
this[d].desc._visible = false;
this[d].odepth = this[d].getDepth();
this[d].onRollOver = function () {
for (d in this._parent) {
this._parent[d]._alpha = 20;
}
this._alpha = 100;
this.swapDepths(this._parent.getNextHighestDepth());
this.desc.gotoAndStop(this._currentframe);
this.desc._visible = true;
};
this[d].onRollOut = function () {
for (d in this._parent) {
this._parent[d]._alpha = 100;
}
this.swapDepths(this.odepth);
this.desc._visible = false;
};
this[d].onPress = function () {
this.play();
};
}
Instance of Symbol 668 MovieClip "ground" in Symbol 669 MovieClip Frame 1
onClipEvent (load) {
var counter = 15;
}
onClipEvent (enterFrame) {
this.counter--;
if (this.counter <= 0) {
this.counter = 15;
for (var d in this) {
if (d.slice(0, 3) == "dot") {
this[d].swapDepths(this.getNextHighestDepth());
this[d].removeMovieClip();
}
}
for (var d in _root.ground) {
if (_root.ground[d].unit) {
switch (_root.ground[d].vtype) {
case "troop" :
m = this.attachMovie("dot1", "dot" + this.getNextHighestDepth(), this.getNextHighestDepth(), {_x:this.dirt._width * (_root.ground[d]._x / _root.ground.dirt._width), _y:this.dirt._height * (_root.ground[d]._y / _root.ground.dirt._height)});
m.gotoAndStop(1 + _root.ground[d].evil);
delete m;
break;
case "vehicle" :
m = this.attachMovie("dot2", "dot" + this.getNextHighestDepth(), this.getNextHighestDepth(), {_x:this.dirt._width * (_root.ground[d]._x / _root.ground.dirt._width), _y:this.dirt._height * (_root.ground[d]._y / _root.ground.dirt._height)});
m.gotoAndStop(1 + _root.ground[d].evil);
delete m;
break;
case "flying" :
m = this.attachMovie("dot3", "dot" + this.getNextHighestDepth(), this.getNextHighestDepth(), {_x:this.dirt._width * (_root.ground[d]._x / _root.ground.dirt._width), _y:this.dirt._height * (_root.ground[d]._y / _root.ground.dirt._height)});
m.gotoAndStop(1 + _root.ground[d].evil);
delete m;
}
}
}
}
}
Instance of Symbol 693 MovieClip in Symbol 694 MovieClip Frame 1
onClipEvent (enterFrame) {
this._xscale = (_root.usedpower / _root.power) * 100;
if (this._xscale > 100) {
this._xscale = 100;
this.play();
} else {
this.gotoAndStop(1);
}
}
Instance of Symbol 696 MovieClip in Symbol 697 MovieClip Frame 1
onClipEvent (enterFrame) {
this._xscale = _root.hp;
}
Instance of Symbol 533 MovieClip in Symbol 698 MovieClip Frame 1
onClipEvent (load) {
this.useHandCursor = false;
}
on (rollOver) {
if (this.hitTest(_root._xmouse, _root._ymouse, false)) {
for (d in _root.ground) {
_root.ground[d].active = false;
}
}
}
Instance of Symbol 657 MovieClip in Symbol 698 MovieClip Frame 1
on (press) {
this._parent.buildMenu.gotoAndStop(1);
}
Instance of Symbol 660 MovieClip in Symbol 698 MovieClip Frame 1
on (press) {
this._parent.buildMenu.gotoAndStop(9);
}
Instance of Symbol 663 MovieClip in Symbol 698 MovieClip Frame 1
on (press) {
this._parent.buildMenu.gotoAndStop(2);
}
Instance of Symbol 669 MovieClip in Symbol 698 MovieClip Frame 1
on (press) {
this.setX = this.ground._x;
this.setM = _root._xmouse;
this.dragging = true;
}
onClipEvent (mouseUp) {
this.dragging = false;
}
onClipEvent (enterFrame) {
if (this.dragging) {
this.ground._x = this.setX - ((this.setM - _root._xmouse) * 2);
}
if (this.ground._x > 0) {
this.ground._x = 0;
}
if (this.ground._x < (139 - this.ground._width)) {
this.ground._x = 139 - this.ground._width;
}
}
Symbol 709 Button
on (press) {
if (_root.money >= this.price) {
if (!this.militarybuilding) {
this.powerok = ((_root.usedpower - _root[this.btype + "Power"][_root[this.btype + "upgrade"]]) + _root[this.btype + "Power"][_root[this.btype + "upgrade"] + 1]) <= _root.power;
} else {
this.powerok = ((_root.usedpower - _root[this.btype + "Power"][_root["m" + this.mnum]]) + _root[this.btype + "Power"][_root["m" + this.mnum] + 1]) <= _root.power;
}
if (this.powerok || (this.btype == "pow")) {
_root[this.btype + "building"] = true;
_root.money = _root.money - this.price;
_root.infoBoxb._visible = false;
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You have insufficent power to run this";
}
} else {
_root.errors._alpha = 100;
_root.errors.error.text = "You do not have enough for this";
}
}
Instance of Symbol 711 MovieClip in Symbol 715 MovieClip Frame 1
on (press) {
this._parent.startDrag();
}
onClipEvent (mouseUp) {
this._parent.stopDrag();
}
Instance of Symbol 714 MovieClip in Symbol 715 MovieClip Frame 1
on (press) {
this._parent._visible = false;
}
Symbol 719 Button
on (release) {
getURL ("http://www.rustyarcade.com", "_blank");
}
Symbol 720 Button
on (release) {
getURL ("http://www.rustyarcade.com", "_blank");
}
Symbol 726 Button
on (release) {
_root.gotoAndStop(1);
}
Symbol 732 Button
on (release) {
var sen = new LoadVars();
var lod = new Object();
sen.username = _root.username;
sen.score = _root.score;
sen.sendAndLoad("http://www.rustyarcade.com/UA/postscore.php", sen, "post");
sen.onLoad = function (success) {
if (success) {
_root.scorearr = this.datas.split("|");
_root.nextFrame();
}
};
}