Frame 1
_global.particles = true;
Frame 2
_global.difficulty = 3;
_global.message = "";
music.stop();
clix = new Sound();
clix.attachSound("clicj");
music = new Sound();
music.attachSound("music");
_root.music.start();
music.onSoundComplete = function () {
_root.music.start();
};
stop();
Instance of Symbol 86 MovieClip in Frame 2
onClipEvent (load) {
}
onClipEvent (enterFrame) {
txt = "Easy";
if (_global.difficulty == 2) {
this.gotoAndStop(4);
} else {
this.gotoAndStop(1);
}
}
on (press) {
_root.clix.start();
_global.difficulty = 2;
}
on (rollOver) {
_global.message = "Scores will not be submitted to high scores";
}
on (rollOut) {
_global.message = "";
}
on (releaseOutside) {
_global.message = "";
}
Instance of Symbol 86 MovieClip in Frame 2
onClipEvent (load) {
}
onClipEvent (enterFrame) {
txt = "Medium";
if (_global.difficulty == 3) {
this.gotoAndStop(4);
} else {
this.gotoAndStop(1);
}
}
on (press) {
_root.clix.start();
_global.difficulty = 3;
}
Instance of Symbol 86 MovieClip in Frame 2
onClipEvent (load) {
}
onClipEvent (enterFrame) {
txt = "Insane";
if (_global.difficulty == 4) {
this.gotoAndStop(4);
} else {
this.gotoAndStop(1);
}
}
on (press) {
_root.clix.start();
_global.difficulty = 4;
}
Instance of Symbol 86 MovieClip in Frame 2
onClipEvent (load) {
}
onClipEvent (enterFrame) {
txt = "OMG WTF!?";
if (_global.difficulty == 10) {
this.gotoAndStop(4);
} else {
this.gotoAndStop(1);
}
}
on (press) {
_global.message = "OMG LOL!";
_root.clix.start();
_global.difficulty = 10;
}
Instance of Symbol 86 MovieClip in Frame 2
onClipEvent (load) {
}
onClipEvent (enterFrame) {
txt = "Tutorial";
}
on (press) {
_root.gotoAndStop(5);
}
Instance of Symbol 96 MovieClip in Frame 2
onClipEvent (load) {
}
onClipEvent (enterFrame) {
txt = "Low Quality";
if (_root._quality == "LOW") {
this.gotoAndStop(4);
} else {
this.gotoAndStop(1);
}
}
on (press) {
_root.clix.start();
_root._quality = "LOW";
}
Instance of Symbol 96 MovieClip in Frame 2
onClipEvent (load) {
}
onClipEvent (enterFrame) {
txt = "Medium Quality";
if (_root._quality == "MEDIUM") {
this.gotoAndStop(4);
} else {
this.gotoAndStop(1);
}
}
on (press) {
_root.clix.start();
_root._quality = "MEDIUM";
}
Instance of Symbol 96 MovieClip in Frame 2
onClipEvent (load) {
}
onClipEvent (enterFrame) {
txt = "High Quality";
if (_root._quality == "HIGH") {
this.gotoAndStop(4);
} else {
this.gotoAndStop(1);
}
}
on (press) {
_root.clix.start();
_root._quality = "HIGH";
}
Instance of Symbol 96 MovieClip in Frame 2
onClipEvent (load) {
}
onClipEvent (enterFrame) {
txt = "Particles";
if (_global.particles) {
this.gotoAndStop(4);
} else {
this.gotoAndStop(1);
}
}
on (press) {
_root.clix.start();
if (_global.particles) {
_global.particles = false;
} else {
_global.particles = true;
}
}
on (rollOver) {
_global.message = "Toggle particles that slow down the game";
}
on (rollOut) {
_global.message = "";
}
on (releaseOutside) {
_global.message = "";
}
Instance of Symbol 96 MovieClip in Frame 2
onClipEvent (load) {
}
onClipEvent (enterFrame) {
txt = "Feedback";
}
on (press) {
_root.clix.start();
_root.feedBackMenu._x = 275;
}
Instance of Symbol 98 MovieClip in Frame 2
onClipEvent (enterFrame) {
mess = _global.message;
}
Instance of Symbol 100 MovieClip in Frame 2
onClipEvent (enterFrame) {
_global.player = txt;
}
Frame 3
function shoot(t, x, y, r, n, sf, ad) {
c = 0;
while (c < n) {
if (t == 0) {
_root.bulls.hand.duplicateMovieClip("object", _global.depth);
}
if (t == 1) {
_root.bulls.rock.duplicateMovieClip("object", _global.depth);
}
if (t == 2) {
_root.bulls.arrow.duplicateMovieClip("object", _global.depth);
}
if (t == 3) {
_root.bulls.fireArrow.duplicateMovieClip("object", _global.depth);
}
if (t == 4) {
_root.bulls.cannon.duplicateMovieClip("object", _global.depth);
}
if (t == 5) {
_root.bulls.bull.duplicateMovieClip("object", _global.depth);
}
if (t == 6) {
_root.bulls.rocket.duplicateMovieClip("object", _global.depth);
}
if (t == 7) {
_root.bulls.spear.duplicateMovieClip("object", _global.depth);
}
if (t == 8) {
_root.bulls.ember.duplicateMovieClip("object", _global.depth);
}
if (t == 10) {
_root.bulls.laser.duplicateMovieClip("object", _global.depth);
}
_global.depth = _global.depth + 1;
_root.bulls.object._x = x;
_root.bulls.object._y = y;
_root.bulls.object.sf = sf;
_root.bulls.object.ad = ad;
_root.bulls.object._rotation = r;
_root.bulls.object._name = "bull" + random(349564);
c++;
}
}
function bear(t, x, y) {
_root.enemies.enemy.duplicateMovieClip("object", _global.depth);
_global.depth = _global.depth + 1;
_root.enemies.object._x = x;
_root.enemies.object._y = y;
_root.enemies.object.type = t;
_root.enemies.object._name = "gyfvu" + random(349564);
}
function build(t, x, y) {
_root.buildings.building.duplicateMovieClip("object", _global.depth);
_global.depth = _global.depth + 1;
_root.buildings.object._x = x;
_root.buildings.object._y = y;
_root.buildings.object.type = t;
_root.buildings.object._name = "gyfvu" + random(349564);
}
function blackSmith(x, y, r) {
_root.bs.range.duplicateMovieClip("object", _global.depth);
_global.depth = _global.depth + 1;
_root.bs.object._x = x;
_root.bs.object._y = y;
_root.bs.object._width = r * 2;
_root.bs.object._height = r * 2;
_root.bs.object._name = "gyfvu" + random(349564);
}
function part(t, x, y, n) {
if (_global.particles) {
c = 0;
while (c < n) {
if (t == "dirt") {
_root.parts.dirt.duplicateMovieClip("object", _global.depth);
}
if (t == "blood") {
_root.parts.blood.duplicateMovieClip("object", _global.depth);
}
if (t == "spark") {
_root.parts.spark.duplicateMovieClip("object", _global.depth);
}
if (t == "fire") {
_root.parts.fire.duplicateMovieClip("object", _global.depth);
}
if (t == "explosion") {
_root.parts.explosion.duplicateMovieClip("object", _global.depth);
}
_global.depth = _global.depth + 1;
_root.parts.object._x = x;
_root.parts.object._y = y;
_root.parts.object._name = "object" + random(349564);
c++;
}
}
}
stop();
_global.eTech = 0;
_global.eNum = 0;
_global.bNum = 0;
_global.wave = 1;
_global.waveTime = 50;
_global.depth = 0;
_global.population = 100;
_global.coin = 150;
_global.secMenu = 1;
_global.tech = 1;
_global.day = 1;
_global.birthRate = 10;
_global.message = "";
_global.vSelected = "";
_global.eStats = new Array();
_global.bStats = new Array();
_global.bProps = new Array();
_global.bProps[0] = ["Base", 1000, 1, 50, 30, 0];
_global.bProps[1] = ["Rock Tower", 100, 1, 75, 30, 60];
_global.bProps[2] = ["Arrow Tower", 100, 2, 150, 30, 110];
_global.bProps[3] = ["Wall", 50, 0, 0, 0, 10];
_global.bProps[4] = ["Lit Arrow Tower", 100, 3, 150, 60, 130];
_global.bProps[5] = ["Spear Tower", 100, 7, 75, 45, 90];
_global.bProps[6] = ["Cannon Tower", 100, 4, 150, 70, 150];
_global.bProps[7] = ["Gun Tower", 100, 5, 150, 30, 160];
_global.bProps[8] = ["Machine Gun Tower", 100, 5, 150, 10, 180];
_global.bProps[9] = ["Rocket Tower", 100, 6, 150, 40, 220];
_global.bProps[10] = ["Fire Tower", 100, 8, 75, 5, 250];
_global.bProps[11] = ["OMG WTF!?", 1000, 10, 500, 10, 0];
_global.bProps[20] = ["Farm", 100, 0, 0, 0, 50];
_global.bProps[21] = ["Blacksmith", 100, 0, 75, 0, 75];
_global.eProps = new Array();
_global.eProps[0] = ["Warrior", 30, 0, 20, 30, 2];
_global.eProps[1] = ["Slinger", 20, 1, 50, 60, 2.3];
_global.eProps[2] = ["Spearman", 40, 7, 75, 90, 2];
_global.eProps[3] = ["Horseman", 50, 7, 75, 90, 4];
_global.eProps[4] = ["Archer", 40, 2, 100, 90, 2.3];
_global.eProps[5] = ["Grenadier", 60, 4, 75, 120, 1.7];
_global.eProps[6] = ["Gunner", 80, 5, 100, 30, 2.3];
_global.eProps[7] = ["Jeep", 120, 5, 100, 30, 5];
_global.eProps[8] = ["Machine Gunner", 90, 5, 75, 10, 1.7];
_global.eProps[9] = ["Armored Car", 140, 5, 100, 15, 5];
_global.eProps[10] = ["Rocketeer", 100, 5, 90, 90, 1.7];
_global.eProps[11] = ["Tank", 250, 6, 90, 90, 3];
_global.eProps[12] = ["Trooper", 200, 10, 90, 90, 1.7];
_global.eProps[99] = ["LOL OMG ROFL", 1500, 10, 100, 30, 5];
poof = new Sound();
poof.attachSound("poof");
bow = new Sound();
bow.attachSound("bow");
stone = new Sound();
stone.attachSound("stone");
die = new Sound();
die.attachSound("die");
flesh = new Sound();
flesh.attachSound("flesh");
laser = new Sound();
laser.attachSound("laser");
cannon = new Sound();
cannon.attachSound("cannon");
explode = new Sound();
explode.attachSound("explode");
gunShot = new Sound();
gunShot.attachSound("gunShot");
wood = new Sound();
wood.attachSound("wood");
Instance of Symbol 116 MovieClip in Frame 3
onClipEvent (enterFrame) {
yo = _global.castleHealth;
}
Instance of Symbol 116 MovieClip in Frame 3
onClipEvent (enterFrame) {
yo = _global.waveTime;
}
Instance of Symbol 290 MovieClip "Tower" in Frame 3
onClipEvent (enterFrame) {
txt = _name;
}
on (press) {
_root.build(21, _x, _y);
}
Instance of Symbol 290 MovieClip "Arrow_Tower" in Frame 3
onClipEvent (enterFrame) {
txt = _name;
}
on (press) {
_root.build(2, _x, _y);
}
Instance of Symbol 290 MovieClip "Wall" in Frame 3
onClipEvent (enterFrame) {
txt = _name;
}
on (press) {
_root.build(6, _x, _y);
}
Instance of Symbol 290 MovieClip "Wall" in Frame 3
onClipEvent (enterFrame) {
txt = _name;
}
on (press) {
_root.build(4, _x, _y);
}
Instance of Symbol 291 MovieClip "bs" in Frame 3
onClipEvent (load) {
_visible = false;
}
Instance of Symbol 334 MovieClip "menu" in Frame 3
onClipEvent (enterFrame) {
da = _global.day;
pop = _global.population;
gold = _global.coin;
heal = _global.castleHealth;
br = _global.birthRate;
_global.income = _global.population / 2;
inc = _global.income;
if (_global.castleHealth < 1) {
_root.gotoAndStop(4);
}
_global.eTech = Math.floor(_global.day / 3);
}
Instance of Symbol 355 MovieClip in Frame 3
onClipEvent (enterFrame) {
da = "Day " + _global.day;
if (_global.eNum > 1) {
if (_root._ymouse > 360) {
if (_y > 400) {
_y = (_y - 10);
}
} else if (_y < 430) {
_y = (_y + 10);
}
} else if (_y < 430) {
_y = (_y + 10);
}
}
Instance of Symbol 358 MovieClip in Frame 3
onClipEvent (enterFrame) {
txtAttack = _global.sAttack;
txtName = _global.sName;
if (_global.sAd) {
this.pic.ring._visible = true;
} else {
this.pic.ring._visible = false;
}
this.pic.gotoAndStop(_global.sType + 1);
if (!(_global.vSelected === "")) {
if (_y < 10) {
_y = (_y + 10);
}
} else if (_y > -40) {
_y = (_y - 40);
}
}
Frame 6
function __rankz_send__(par1, par2, par3, par4, par4n, par4nb) {
if (_global.difficulty > 2) {
par227 = new LoadVars();
par228 = new LoadVars();
par227.flashkey = par2;
par227.SU0249 = par1;
par227.bmFtZTE = ab3.rankz.Armor_Bot_30_En_AS1.Encode(par3);
par227.c2NvcmUx = ab3.rankz.Armor_Bot_30_En_AS1.Encode(par4 + "j%e%a%n%s");
par227.c2NvcmUy = ab3.rankz.Armor_Bot_30_En_AS1.Encode(par4n + "j%e%a%n%s");
par227.c2NvcmUz = ab3.rankz.Armor_Bot_30_En_AS1.Encode(par4nb + "j%e%a%n%s");
par227.flashkey = par227.flashkey.split("=").join("");
par227.SU0249 = par227.SU0249.split("=").join("");
par228.onLoad = function (success) {
if (success) {
if (par228.place == 0) {
hstatus.text = "Sorry, you are not yet worthy of the high score table.";
} else {
hstatus.text = ("Highscore posted! You got #" + par228.place) + " place!";
}
} else {
trace(par228.loaded);
}
};
par227.sendAndLoad("http://rankz.armorbot.com/submit/", par228, "POST");
} else {
hstatus.text = "You must play on medium, hard, or OMG WTF!? difficulties to attain a high score.";
}
}
stop();
bXlnYW1lX25hbWVfdmFyaWFibGU = _global.player;
bXlnYW1lX3Njb3JlX3ZhcmlhYmxl = _global.day;
bXlnYW1lX3Njb3JlX3ZhcmlhYmx2 = _global.population;
bXlnYW1lX3Njb3JlX3ZhcmlhYmx3 = _global.coin;
__rankz_send__("Mjc2M2olZSVhJW4lcw==", "VGVSdVBKb0Q=", bXlnYW1lX25hbWVfdmFyaWFibGU, bXlnYW1lX3Njb3JlX3ZhcmlhYmxl, bXlnYW1lX3Njb3JlX3ZhcmlhYmx2, bXlnYW1lX3Njb3JlX3ZhcmlhYmx3);
Symbol 43 MovieClip Frame 20
stop();
Symbol 46 MovieClip Frame 15
stop();
Symbol 48 MovieClip Frame 11
stop();
Symbol 49 MovieClip Frame 25
stop();
Symbol 56 MovieClip Frame 16
stop();
Symbol 58 MovieClip Frame 15
stop();
Symbol 59 Button
on (release) {
_root.play();
}
Symbol 60 MovieClip Frame 1
_root.stop();
this.stop();
Instance of Symbol 15 MovieClip in Symbol 60 MovieClip Frame 1
onClipEvent (load) {
var totalBytes = _root.getBytesTotal();
}
onClipEvent (enterFrame) {
var currentBytes = _root.getBytesLoaded();
var ratio = (currentBytes / totalBytes);
_xscale = (100 * ratio);
if (ratio == 1) {
_parent.gotoAndStop(2);
}
}
Symbol 408 MovieClip [__Packages.ab3.rankz.Armor_Bot_30_En_AS1] Frame 0
class ab3.rankz.Armor_Bot_30_En_AS1 extends Object
{
static var _CharsReverseLookup;
var _Armor_Bot_30_En_AS1Str, _Armor_Bot_30_En_AS1Count;
function Armor_Bot_30_En_AS1 () {
super();
}
static function Encode(str) {
var _local1 = new ab3.rankz.Armor_Bot_30_En_AS1();
return(_local1.encodeArmor_Bot_30_En_AS1(str));
}
static function Decode(str) {
var _local1 = new ab3.rankz.Armor_Bot_30_En_AS1();
return(_local1.decodeArmor_Bot_30_En_AS1(str));
}
static function StringReplaceAll(source, find, replacement) {
return(source.split(find).join(replacement));
}
static function InitReverseChars() {
_CharsReverseLookup = new Array();
var _local1 = 0;
while (_local1 < _Chars.length) {
_CharsReverseLookup[_Chars[_local1]] = _local1;
_local1++;
}
return(true);
}
static function UrlDecode(str) {
str = StringReplaceAll(str, "\\", " ");
str = unescape(str);
return(str);
}
static function UrlEncode(str) {
str = escape(str);
str = StringReplaceAll(str, "\\", "%2B");
str = StringReplaceAll(str, "%20", "+");
return(str);
}
function setArmor_Bot_30_En_AS1Str(str) {
_Armor_Bot_30_En_AS1Str = str;
_Armor_Bot_30_En_AS1Count = 0;
}
function readArmor_Bot_30_En_AS1() {
if (!_Armor_Bot_30_En_AS1Str) {
return(_EndOfInput);
}
if (_Armor_Bot_30_En_AS1Count >= _Armor_Bot_30_En_AS1Str.length) {
return(_EndOfInput);
}
var _local2 = _Armor_Bot_30_En_AS1Str.charCodeAt(_Armor_Bot_30_En_AS1Count) & 255;
_Armor_Bot_30_En_AS1Count++;
return(_local2);
}
function encodeArmor_Bot_30_En_AS1(str) {
setArmor_Bot_30_En_AS1Str(str);
var _local3 = "";
var _local2 = new Array(3);
var _local5 = 0;
var _local4 = false;
while ((!_local4) && (((_local2[0] = readArmor_Bot_30_En_AS1())) != _EndOfInput)) {
_local2[1] = readArmor_Bot_30_En_AS1();
_local2[2] = readArmor_Bot_30_En_AS1();
_local3 = _local3 + _Chars[_local2[0] >> 2];
if (_local2[1] != _EndOfInput) {
_local3 = _local3 + _Chars[((_local2[0] << 4) & 48) | (_local2[1] >> 4)];
if (_local2[2] != _EndOfInput) {
_local3 = _local3 + _Chars[((_local2[1] << 2) & 60) | (_local2[2] >> 6)];
_local3 = _local3 + _Chars[_local2[2] & 63];
} else {
_local3 = _local3 + _Chars[(_local2[1] << 2) & 60];
_local3 = _local3 + "=";
_local4 = true;
}
} else {
_local3 = _local3 + _Chars[(_local2[0] << 4) & 48];
_local3 = _local3 + "=";
_local3 = _local3 + "=";
_local4 = true;
}
_local5 = _local5 + 4;
if (_local5 >= 76) {
_local3 = _local3 + newline;
_local5 = 0;
}
}
return(_local3);
}
function readReverseArmor_Bot_30_En_AS1() {
if (!_Armor_Bot_30_En_AS1Str) {
return(_EndOfInput);
}
while (true) {
if (_Armor_Bot_30_En_AS1Count >= _Armor_Bot_30_En_AS1Str.length) {
return(_EndOfInput);
}
var _local2 = _Armor_Bot_30_En_AS1Str.charAt(_Armor_Bot_30_En_AS1Count);
_Armor_Bot_30_En_AS1Count++;
if (_CharsReverseLookup[_local2]) {
return(_CharsReverseLookup[_local2]);
}
if (_local2 == "A") {
return(0);
}
}
}
function ntos(n) {
var _local1 = n.toString(16);
if (_local1.length == 1) {
_local1 = "0" + _local1;
}
_local1 = "%" + _local1;
return(unescape(_local1));
}
function decodeArmor_Bot_30_En_AS1(str) {
setArmor_Bot_30_En_AS1Str(str);
var _local3 = "";
var _local2 = new Array(4);
var _local4 = false;
while (((!_local4) && (((_local2[0] = readReverseArmor_Bot_30_En_AS1())) != _EndOfInput)) && (((_local2[1] = readReverseArmor_Bot_30_En_AS1())) != _EndOfInput)) {
_local2[2] = readReverseArmor_Bot_30_En_AS1();
_local2[3] = readReverseArmor_Bot_30_En_AS1();
_local3 = _local3 + ntos(((_local2[0] << 2) & 255) | (_local2[1] >> 4));
if (_local2[2] != _EndOfInput) {
_local3 = _local3 + ntos(((_local2[1] << 4) & 255) | (_local2[2] >> 2));
if (_local2[3] != _EndOfInput) {
_local3 = _local3 + ntos(((_local2[2] << 6) & 255) | _local2[3]);
} else {
_local4 = true;
}
} else {
_local4 = true;
}
}
return(_local3);
}
function toHex(n) {
var _local4 = "";
var _local3 = true;
var _local1 = 32;
while (_local1 > 0) {
_local1 = _local1 - 4;
var _local2 = (n >> _local1) & 15;
if ((!_local3) || (_local2 != 0)) {
_local3 = false;
_local4 = _local4 + _Digits[_local2];
}
}
return(((_local4 == "") ? "0" : (_local4)));
}
function pad(str, len, pad) {
var _local2 = str;
var _local1 = str.length;
while (_local1 < len) {
_local2 = pad + _local2;
_local1++;
}
return(_local2);
}
function encodeHex(str) {
var _local4 = "";
var _local2 = 0;
while (_local2 < str.length) {
_local4 = _local4 + pad(toHex(str.charCodeAt(_local2) & 255), 2, "0");
_local2++;
}
return(_local4);
}
function decodeHex(str) {
var _local5 = "";
var _local3 = "";
var _local2 = 0;
while (_local2 < str.length) {
_local3 = _local3 + str.charAt(_local2);
if (_local3.length == 2) {
_local5 = _local5 + ntos(parseInt("0x" + _local3));
_local3 = "";
}
_local2++;
}
return(_local5);
}
static var _EndOfInput = -1;
static var _Chars = new Array("A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "+", "/");
static var _CharsReverseLookupInited = InitReverseChars();
static var _Digits = new Array("0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "a", "b", "c", "d", "e", "f");
}
Symbol 76 Button
on (press) {
_root.clix.start();
_root.gotoAndStop(3);
}
Symbol 86 MovieClip Frame 1
stop();
Symbol 96 MovieClip Frame 1
stop();
Symbol 110 Button
on (press) {
_root.feedBackMenu._x = -275;
}
Symbol 136 MovieClip Frame 1
stop();
Symbol 142 MovieClip Frame 1
stop();
Symbol 145 MovieClip Frame 1
stop();
Symbol 150 MovieClip Frame 1
stop();
Symbol 156 MovieClip Frame 1
stop();
Symbol 161 MovieClip Frame 1
stop();
Symbol 163 MovieClip Frame 1
stop();
Symbol 169 MovieClip Frame 1
stop();
Instance of Symbol 175 MovieClip "building" in Symbol 176 MovieClip Frame 1
onClipEvent (load) {
action = "drag";
this.gotoAndStop(type + 1);
tmr = 1;
_alpha = 100;
vName = _global.bProps[type][0];
health = _global.bProps[type][1];
attack = _global.bProps[type][2];
vRange = _global.bProps[type][3];
recoil = _global.bProps[type][4];
this.ring._visible = false;
this.onMouseDown = function () {
vMouse = true;
};
this.base.onPress = function () {
vPress = true;
};
}
onClipEvent (enterFrame) {
if (type == 0) {
_global.castleX = _x;
_global.castleY = _y;
_name = "castle";
}
if (_name == "building") {
action = "preserve";
_x = 700;
}
if (action == "drag") {
_root.popUp.gotoAndStop(2);
_root.menu._x = -550;
_root.range._visible = true;
_root.range._x = _x;
_root.range._y = _y;
_root.range._width = vRange * 2;
_root.range._height = vRange * 2;
_x = _root._xmouse;
_y = _root._ymouse;
block = false;
if (_root.buildings.hitTest((_x + (_width / 2)) + 0.1, (_y - (_height / 2)) + 0.1, true) || (_root.buildings.hitTest((_x + (_width / 2)) + 0.1, (_y + (_height / 2)) + 0.1, true))) {
block = true;
}
if (_root.buildings.hitTest((_x - (_width / 2)) - 0.1, (_y - (_height / 2)) + 0.1, true) || (_root.buildings.hitTest((_x - (_width / 2)) - 0.1, (_y + (_height / 2)) + 0.1, true))) {
block = true;
}
c = 0;
while (c < _global.bStats.length) {
if (this.hitTest(_global.bStats[c][0], _global.bStats[c][1], true)) {
block = true;
}
c++;
}
if (this.base.hitTest(_root.road) || (block)) {
_alpha = 25;
thought = "unable";
} else {
_alpha = 75;
thought = "able";
}
if (vMouse && (thought == "able")) {
_root.menu._x = 112.5;
num = _global.bNum;
_root.popUp.gotoAndStop(1);
_global.bStats[num] = [_x, _y, type];
_global.bNum = _global.bNum + 1;
_root.range._x = -200;
action = "placed";
if (vName == "Farm") {
_global.birthRate = _global.birthRate + 10;
}
thought = "defend";
if (vName == "Blacksmith") {
_root.blackSmith(_x, _y, vRange);
}
}
if (Key.isDown(27)) {
_root.popUp.gotoAndStop(1);
_root.menu._x = 112.5;
_global.coin = _global.coin + _global.bProps[type][5];
_root.range._x = -200;
this.removeMovieClip();
}
}
if (action == "wait") {
_alpha = 50;
if (vPress) {
action = "drag";
}
}
if (action == "placed") {
_alpha = 100;
if (vPress) {
_global.vSelected = _name;
}
if (_global.vSelected == _name) {
if (Key.isDown(83)) {
_global.coin = _global.coin + (_global.bProps[type][5] / 2);
_root.popUp.gotoAndStop(1);
_root.range._x = -200;
_global.vSelected = "";
this.removeMovieClip();
}
_root.popUp.gotoAndStop(3);
_global.sName = vName;
_global.sAttack = attack;
_global.sType = type;
_global.sAd = ad;
_root.range._visible = true;
_root.range._x = _x;
_root.range._y = _y;
_root.range._width = vRange * 2;
_root.range._height = vRange * 2;
if (vMouse && (!vPress)) {
_root.popUp.gotoAndStop(1);
_root.range._visible = false;
_global.vSelected = "";
}
} else {
this.range._visible = false;
}
if (thought == "defend") {
if (_root.bs.hitTest(_x, _y, true)) {
ad = 10;
this.ring._visible = true;
} else {
ad = 0;
this.ring._visible = false;
}
see = false;
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
dist = Math.sqrt(((_x - x) * (_x - x)) + ((_y - y) * (_y - y)));
if (dist < vRange) {
this.turret._rotation = (Math.atan2(y - _y, x - _x) * 57.2957795130823) + 90;
see = true;
}
c++;
}
if (see && (recoil > 0)) {
tmr = tmr - 1;
if (tmr < 1) {
this.turret.play();
_root.shoot(attack, _x, _y, this.turret._rotation, 1, "human", ad);
tmr = recoil;
}
}
}
}
vMouse = false;
vPress = false;
}
Instance of Symbol 175 MovieClip in Symbol 176 MovieClip Frame 1
onClipEvent (load) {
action = "placed";
thought = "defend";
type = 0;
this.gotoAndStop(type + 1);
tmr = 1;
_alpha = 100;
vName = _global.bProps[type][0];
health = _global.bProps[type][1];
attack = _global.bProps[type][2];
vRange = _global.bProps[type][3];
recoil = _global.bProps[type][4];
_global.castleHealth = health;
this.onMouseDown = function () {
vMouse = true;
};
this.base.onPress = function () {
vPress = true;
};
}
onClipEvent (enterFrame) {
if (type == 0) {
_global.castleX = _x;
_global.castleY = _y;
_name = "castle";
}
if (_name == "building") {
action = "preserve";
_x = 700;
}
if (action == "drag") {
_root.menu._x = -550;
_root.range._visible = true;
_root.range._x = _x;
_root.range._y = _y;
_root.range._width = vRange * 2;
_root.range._height = vRange * 2;
_x = _root._xmouse;
_y = _root._ymouse;
block = false;
if (_root.buildings.hitTest((_x + (_width / 2)) + 0.1, (_y - (_height / 2)) + 0.1, true) || (_root.buildings.hitTest((_x + (_width / 2)) + 0.1, (_y + (_height / 2)) + 0.1, true))) {
block = true;
}
if (_root.buildings.hitTest((_x - (_width / 2)) - 0.1, (_y - (_height / 2)) + 0.1, true) || (_root.buildings.hitTest((_x - (_width / 2)) - 0.1, (_y + (_height / 2)) + 0.1, true))) {
block = true;
}
c = 0;
while (c < _global.bStats.length) {
if (this.hitTest(_global.bStats[c][0], _global.bStats[c][1], true)) {
block = true;
}
c++;
}
if (this.base.hitTest(_root.road) || (block)) {
_alpha = 25;
thought = "unable";
} else {
_alpha = 75;
thought = "able";
}
if (vMouse && (thought == "able")) {
_root.menu._x = 112.5;
num = _global.bNum;
_global.bStats[num] = [_x, _y, type];
_global.bNum = _global.bNum + 1;
action = "placed";
if (vName == "Farm") {
_global.birthRate = _global.birthRate + 10;
}
thought = "defend";
}
}
if (action == "wait") {
_alpha = 50;
if (vPress) {
action = "drag";
}
}
if (action == "placed") {
_alpha = 100;
if (vPress) {
_global.vSelected = _name;
}
if (_global.vSelected == _name) {
_root.range._visible = true;
_root.range._x = _x;
_root.range._y = _y;
_root.range._width = vRange * 2;
_root.range._height = vRange * 2;
if (vMouse && (!vPress)) {
_root.range._visible = false;
_global.vSelected = "";
}
} else {
this.range._visible = false;
}
if (thought == "defend") {
see = false;
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
dist = Math.sqrt(((_x - x) * (_x - x)) + ((_y - y) * (_y - y)));
if (dist < vRange) {
this.turret._rotation = (Math.atan2(y - _y, x - _x) * 57.2957795130823) + 90;
see = true;
}
c++;
}
if (see) {
tmr = tmr - 1;
if (tmr < 1) {
this.turret.play();
_root.shoot(attack, _x, _y, this.turret._rotation, 1, "human", 0);
tmr = recoil;
}
}
}
}
vMouse = false;
vPress = false;
}
Symbol 184 MovieClip Frame 1
stop();
Symbol 185 MovieClip Frame 1
stop();
Symbol 188 MovieClip Frame 1
stop();
Symbol 189 MovieClip Frame 1
stop();
Symbol 192 MovieClip Frame 1
stop();
Symbol 193 MovieClip Frame 1
stop();
Symbol 198 MovieClip Frame 1
stop();
Symbol 199 MovieClip Frame 1
stop();
Symbol 216 MovieClip Frame 1
stop();
Symbol 217 MovieClip Frame 1
stop();
Symbol 224 MovieClip Frame 1
stop();
Symbol 225 MovieClip Frame 1
stop();
Symbol 231 MovieClip Frame 1
stop();
Symbol 232 MovieClip Frame 1
stop();
Symbol 239 MovieClip Frame 1
stop();
Symbol 240 MovieClip Frame 1
stop();
Symbol 246 MovieClip Frame 1
stop();
Symbol 247 MovieClip Frame 1
stop();
Instance of Symbol 248 MovieClip "enemy" in Symbol 251 MovieClip Frame 1
onClipEvent (load) {
action = "attack";
tmr = 1;
thought = "move";
vName = _global.eProps[type][0];
health = _global.eProps[type][1];
attack = _global.eProps[type][2];
vRange = _global.eProps[type][3];
recoil = _global.eProps[type][4];
speed = _global.eProps[type][5];
num = _global.eNum;
_global.eNum = _global.eNum + 1;
_global.eStats[num] = [_x, _y, health];
this.gotoAndStop(type + 1);
}
onClipEvent (enterFrame) {
if (_name == enemy) {
thought = "preserve";
}
if (action == "attack") {
if (thought == "move") {
this.av.gotoAndStop(1);
_rotation = ((Math.atan2(_global.castleY - _y, _global.castleX - _x) * 57.2957795130823) + 90);
ySpeed = Math.cos((Math.PI/180) * _rotation) * speed;
xSpeed = Math.sin((Math.PI/180) * _rotation) * speed;
t = 1;
while (_root.buildings.hitTest(_x + xSpeed, _y - ySpeed, true)) {
if (_y > _root.road._y) {
_rotation = (_rotation - 1);
} else {
_rotation = (_rotation + 1);
}
t = t + 1;
if (t > 180) {
break;
}
ySpeed = Math.cos((Math.PI/180) * _rotation) * speed;
xSpeed = Math.sin((Math.PI/180) * _rotation) * speed;
}
_x = (_x + xSpeed);
_y = (_y - ySpeed);
dist = Math.sqrt(((_global.castleX - _x) * (_global.castleX - _x)) + ((_global.castleY - _y) * (_global.castleY - _y)));
if (dist < (vRange + 15)) {
thought = "attack";
}
}
if (thought == "attack") {
this.av.gotoAndStop(2);
tmr = tmr - 1;
if (tmr < 1) {
tmr = recoil;
this.av.attack.play();
_root.shoot(attack, _x, _y, _rotation, 1, "computer");
}
}
if (ailment == "on fire") {
health = health - 0.5;
_root.part("fire", _x, _y, 1);
}
if (_global.eStats[num][3] == -1) {
ailment = "on fire";
_global.eStats[num][3] = 10;
}
if (_global.eStats[num][3] == -2) {
ailment = "on fire";
_global.eStats[num][3] = 1;
}
if (_global.eStats[num][3] > 0) {
_root.part("blood", _x, _y, 10);
health = health - _global.eStats[num][3];
_global.eStats[num][3] = 0;
}
if (health < 1) {
action = "dead";
_root.die.start();
_root.part("blood", _x, _y, 30);
_x = -500;
_global.eStats[num] = [_x, _y, health];
_global.eNum = _global.eNum - 1;
if (_global.eNum == 1) {
_global.day = _global.day + 1;
_root.menu._x = 112.5;
_global.secMenu = 1;
_global.population = _global.population + _global.birthRate;
_global.coin = _global.coin + _global.income;
}
this.removeMovieClip();
}
_global.eStats[num] = [_x, _y, health];
}
}
Instance of Symbol 250 MovieClip in Symbol 251 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.waveTime < 1) {
c = 0;
while (c < ((_global.wave * _global.difficulty) + 1)) {
_x = (random(550) - 550);
_y = random(400);
_root.bear(random(_global.eTech + 1), _x, _y);
_global.waveTime = 1;
c++;
}
_global.wave = _global.wave + 1;
}
}
Instance of Symbol 253 MovieClip "arrow" in Symbol 273 MovieClip Frame 1
onClipEvent (load) {
wid = _width;
hei = _height;
alive = true;
tmr = 10;
ySpeed = Math.cos((Math.PI/180) * _rotation) * 19;
xSpeed = Math.sin((Math.PI/180) * _rotation) * 19;
_root.bow.start();
}
onClipEvent (enterFrame) {
_x = (_x + xSpeed);
_y = (_y - ySpeed);
tmr = tmr - 1;
ySpeed = ySpeed * 0.9;
xSpeed = xSpeed * 0.9;
if (sf == "human") {
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
if ((this.hitTest(x, y, true) || (this.hitTest(x + (xSpeed / 2), y + (ySpeed / 2), true))) || (this.hitTest(x + (xSpeed / 4), y + (ySpeed / 4), true))) {
_root.flesh.start();
_global.eStats[c][3] = 14 + ad;
this.removeMovieClip();
}
c++;
}
} else if (this.hitTest(_root.buildings.castle)) {
_global.castleHealth = _global.castleHealth - 14;
_root.stone.start();
_root.part("spark", _x, _y, 10);
this.removeMovieClip();
}
if ((tmr < 1) && (alive)) {
_root.poof.start();
_root.part("dirt", _x, _y, 10);
this.removeMovieClip();
alive = false;
}
}
Instance of Symbol 255 MovieClip "bull" in Symbol 273 MovieClip Frame 1
onClipEvent (load) {
wid = _width;
hei = _height;
alive = true;
tmr = 15;
ySpeed = Math.cos((Math.PI/180) * _rotation) * 19;
xSpeed = Math.sin((Math.PI/180) * _rotation) * 19;
_root.gunShot.start();
}
onClipEvent (enterFrame) {
_x = (_x + xSpeed);
_y = (_y - ySpeed);
tmr = tmr - 1;
ySpeed = ySpeed * 0.99;
xSpeed = xSpeed * 0.99;
if (sf == "human") {
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
if ((this.hitTest(x, y, true) || (this.hitTest(x + (xSpeed / 2), y + (ySpeed / 2), true))) || (this.hitTest(x + (xSpeed / 4), y + (ySpeed / 4), true))) {
_root.flesh.start();
_global.eStats[c][3] = 25 + ad;
this.removeMovieClip();
}
c++;
}
} else if (this.hitTest(_root.buildings.castle)) {
_global.castleHealth = _global.castleHealth - 20;
_root.stone.start();
_root.part("spark", _x, _y, 10);
this.removeMovieClip();
}
if ((tmr < 1) && (alive)) {
_root.poof.start();
_root.part("dirt", _x, _y, 10);
this.removeMovieClip();
alive = false;
}
}
Instance of Symbol 257 MovieClip "spear" in Symbol 273 MovieClip Frame 1
onClipEvent (load) {
wid = _width;
hei = _height;
alive = true;
tmr = 10;
ySpeed = Math.cos((Math.PI/180) * _rotation) * 12;
xSpeed = Math.sin((Math.PI/180) * _rotation) * 12;
}
onClipEvent (enterFrame) {
_x = (_x + xSpeed);
_y = (_y - ySpeed);
tmr = tmr - 1;
ySpeed = ySpeed * 0.9;
xSpeed = xSpeed * 0.9;
if (sf == "human") {
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
if ((this.hitTest(x, y, true) || (this.hitTest(x + (xSpeed / 2), y + (ySpeed / 2), true))) || (this.hitTest(x + (xSpeed / 4), y + (ySpeed / 4), true))) {
_root.flesh.start();
_global.eStats[c][3] = 15 + ad;
this.removeMovieClip();
}
c++;
}
} else if (this.hitTest(_root.buildings.castle)) {
_global.castleHealth = _global.castleHealth - 15;
_root.stone.start();
_root.part("spark", _x, _y, 10);
this.removeMovieClip();
}
if ((tmr < 1) && (alive)) {
_root.poof.start();
_root.part("dirt", _x, _y, 10);
this.removeMovieClip();
alive = false;
}
}
Instance of Symbol 259 MovieClip "rock" in Symbol 273 MovieClip Frame 1
onClipEvent (load) {
wid = _width;
hei = _height;
alive = true;
z = 1;
zSpeed = 2;
ySpeed = Math.cos((Math.PI/180) * _rotation) * 10;
xSpeed = Math.sin((Math.PI/180) * _rotation) * 10;
_root.wood.start();
}
onClipEvent (enterFrame) {
_x = (_x + xSpeed);
_y = (_y - ySpeed);
_rotation = (_rotation + random(70));
z = z + zSpeed;
zSpeed = zSpeed - 0.2;
ySpeed = ySpeed * 0.9;
xSpeed = xSpeed * 0.9;
if (sf == "human") {
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
if (this.hitTest(x, y, true)) {
_root.flesh.start();
_global.eStats[c][3] = 10 + ad;
this.removeMovieClip();
}
c++;
}
} else if (this.hitTest(_root.buildings.castle)) {
_global.castleHealth = _global.castleHealth - 10;
_root.stone.start();
_root.part("spark", _x, _y, 10);
this.removeMovieClip();
}
if ((z < -5) && (alive)) {
_root.poof.start();
_root.part("dirt", _x, _y, 10);
this.removeMovieClip();
alive = false;
}
}
Instance of Symbol 259 MovieClip "hand" in Symbol 273 MovieClip Frame 1
onClipEvent (load) {
wid = _width;
_visible = false;
hei = _height;
alive = true;
tmr = 3;
ySpeed = Math.cos((Math.PI/180) * _rotation) * 10;
xSpeed = Math.sin((Math.PI/180) * _rotation) * 10;
}
onClipEvent (enterFrame) {
_x = (_x + xSpeed);
_y = (_y - ySpeed);
_rotation = (_rotation + random(50));
tmr = tmr - 1;
ySpeed = ySpeed * 0.9;
xSpeed = xSpeed * 0.9;
if (sf == "human") {
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
if (this.hitTest(x, y, true)) {
_root.flesh.start();
_global.eStats[c][3] = 10;
this.removeMovieClip();
}
c++;
}
} else if (this.hitTest(_root.buildings.castle)) {
_global.castleHealth = _global.castleHealth - 10;
_root.stone.start();
_root.part("spark", _x, _y, 10);
this.removeMovieClip();
}
if ((tmr < 1) && (alive)) {
_root.part("dirt", _x, _y, 10);
this.removeMovieClip();
alive = false;
}
}
Instance of Symbol 261 MovieClip "laser" in Symbol 273 MovieClip Frame 1
onClipEvent (load) {
wid = _width;
hei = _height;
alive = true;
tmr = 100;
ySpeed = Math.cos((Math.PI/180) * _rotation) * 19;
xSpeed = Math.sin((Math.PI/180) * _rotation) * 19;
_root.laser.start();
}
onClipEvent (enterFrame) {
_x = (_x + xSpeed);
_y = (_y - ySpeed);
tmr = tmr - 1;
if (sf == "human") {
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
if ((this.hitTest(x, y, true) || (this.hitTest(x + (xSpeed / 2), y + (ySpeed / 2), true))) || (this.hitTest(x + (xSpeed / 4), y + (ySpeed / 4), true))) {
_root.flesh.start();
_global.eStats[c][3] = 35 + ad;
this.removeMovieClip();
}
c++;
}
} else if (this.hitTest(_root.buildings.castle)) {
_global.castleHealth = _global.castleHealth - 35;
_root.stone.start();
this.removeMovieClip();
}
if ((tmr < 1) && (alive)) {
_root.poof.start();
_root.part("dirt", _x, _y, 10);
this.removeMovieClip();
alive = false;
}
}
Instance of Symbol 263 MovieClip "cannon" in Symbol 273 MovieClip Frame 1
onClipEvent (load) {
wid = _width;
hei = _height;
alive = true;
tmr = 20;
ySpeed = Math.cos((Math.PI/180) * _rotation) * 19;
xSpeed = Math.sin((Math.PI/180) * _rotation) * 19;
_root.cannon.start();
}
onClipEvent (enterFrame) {
_x = (_x + xSpeed);
_y = (_y - ySpeed);
tmr = tmr - 1;
ySpeed = ySpeed * 0.9;
xSpeed = xSpeed * 0.9;
_rotation = (_rotation + random(50));
if (sf == "human") {
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
if ((this.hitTest(x, y, true) || (this.hitTest(x + (xSpeed / 2), y + (ySpeed / 2), true))) || (this.hitTest(x + (xSpeed / 4), y + (ySpeed / 4), true))) {
_root.flesh.start();
_root.explode.start();
_root.part("explosion", _x, _y, 10);
_global.eStats[c][3] = 30 + ad;
this.removeMovieClip();
}
c++;
}
} else if (this.hitTest(_root.buildings.castle)) {
_global.castleHealth = _global.castleHealth - 30;
_root.stone.start();
_root.explode.start();
_root.part("explosion", _x, _y, 10);
this.removeMovieClip();
}
if ((tmr < 1) && (alive)) {
_root.explode.start();
_root.part("explosion", _x, _y, 10);
this.removeMovieClip();
alive = false;
}
}
Instance of Symbol 265 MovieClip "rocket" in Symbol 273 MovieClip Frame 1
onClipEvent (load) {
wid = _width;
hei = _height;
alive = true;
tmr = 15;
ySpeed = Math.cos((Math.PI/180) * _rotation) * 19;
xSpeed = Math.sin((Math.PI/180) * _rotation) * 19;
_root.cannon.start();
}
onClipEvent (enterFrame) {
_x = (_x + xSpeed);
_y = (_y - ySpeed);
tmr = tmr - 1;
ySpeed = ySpeed * 0.99;
xSpeed = xSpeed * 0.99;
if (sf == "human") {
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
if ((this.hitTest(x, y, true) || (this.hitTest(x + (xSpeed / 2), y + (ySpeed / 2), true))) || (this.hitTest(x + (xSpeed / 4), y + (ySpeed / 4), true))) {
_root.flesh.start();
_root.explode.start();
_root.part("explosion", _x, _y, 10);
_global.eStats[c][3] = 45 + ad;
this.removeMovieClip();
}
c++;
}
} else if (this.hitTest(_root.buildings.castle)) {
_global.castleHealth = _global.castleHealth - 45;
_root.stone.start();
_root.explode.start();
_root.part("explosion", _x, _y, 10);
this.removeMovieClip();
}
if ((tmr < 1) && (alive)) {
_root.explode.start();
_root.part("explosion", _x, _y, 10);
this.removeMovieClip();
alive = false;
}
}
Instance of Symbol 253 MovieClip "fireArrow" in Symbol 273 MovieClip Frame 1
onClipEvent (load) {
wid = _width;
hei = _height;
alive = true;
tmr = 10;
ySpeed = Math.cos((Math.PI/180) * _rotation) * 19;
xSpeed = Math.sin((Math.PI/180) * _rotation) * 19;
_root.bow.start();
}
onClipEvent (enterFrame) {
_x = (_x + xSpeed);
_y = (_y - ySpeed);
tmr = tmr - 1;
ySpeed = ySpeed * 0.9;
xSpeed = xSpeed * 0.9;
if (!(_name === "fireArrow")) {
_root.part("fire", _x, _y, 1);
}
if (sf == "human") {
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
if ((this.hitTest(x, y, true) || (this.hitTest(x + (xSpeed / 2), y + (ySpeed / 2), true))) || (this.hitTest(x + (xSpeed / 4), y + (ySpeed / 4), true))) {
_root.flesh.start();
_global.eStats[c][3] = -1;
this.removeMovieClip();
}
c++;
}
} else if (this.hitTest(_root.buildings.castle)) {
_global.castleHealth = _global.castleHealth - 20;
_root.stone.start();
_root.part("spark", _x, _y, 10);
this.removeMovieClip();
}
if ((tmr < 1) && (alive)) {
_root.poof.start();
_root.part("dirt", _x, _y, 10);
this.removeMovieClip();
alive = false;
}
}
Instance of Symbol 272 MovieClip "ember" in Symbol 273 MovieClip Frame 1
onClipEvent (load) {
wid = _width;
hei = _height;
alive = true;
tmr = 10;
_rotation = (_rotation + (random(10) - 5));
ySpeed = Math.cos((Math.PI/180) * _rotation) * 19;
xSpeed = Math.sin((Math.PI/180) * _rotation) * 19;
}
onClipEvent (enterFrame) {
_x = (_x + xSpeed);
_y = (_y - ySpeed);
tmr = tmr - 1;
ySpeed = ySpeed * 0.9;
xSpeed = xSpeed * 0.9;
if (!(_name === "fireArrow")) {
_root.part("fire", _x, _y, 1);
}
if (sf == "human") {
c = 0;
while (c < _global.eStats.length) {
x = _global.eStats[c][0];
y = _global.eStats[c][1];
if ((this.hitTest(x, y, true) || (this.hitTest(x + (xSpeed / 2), y + (ySpeed / 2), true))) || (this.hitTest(x + (xSpeed / 4), y + (ySpeed / 4), true))) {
_global.eStats[c][3] = -2;
}
c++;
}
} else if (this.hitTest(_root.buildings.castle)) {
_global.castleHealth = _global.castleHealth - 1;
this.removeMovieClip();
}
if ((tmr < 1) && (alive)) {
this.removeMovieClip();
alive = false;
}
}
Instance of Symbol 277 MovieClip "spark" in Symbol 285 MovieClip Frame 1
onClipEvent (load) {
xSpeed = random(10) - 5;
ySpeed = random(10) - 5;
tmr = 50;
this.gotoAndStop(random(5) + 1);
}
onClipEvent (enterFrame) {
x = _x + _root.world._x;
y = _y + _root.world._y;
if (_root.buildings.hitTest(x, y, true)) {
this.removeMovieClip();
}
_y = (_y - ySpeed);
_x = (_x + xSpeed);
xSpeed = xSpeed * 0.7;
ySpeed = ySpeed * 0.7;
tmr = tmr - 3;
_alpha = (tmr / 2);
if (tmr < 1) {
this.removeMovieClip();
}
}
Instance of Symbol 281 MovieClip "dirt" in Symbol 285 MovieClip Frame 1
onClipEvent (load) {
xSpeed = random(10) - 5;
ySpeed = random(10) - 5;
tmr = 50;
this.gotoAndStop(random(5) + 1);
}
onClipEvent (enterFrame) {
x = _x + _root.world._x;
y = _y + _root.world._y;
if (_root.buildings.hitTest(x, y, true)) {
this.removeMovieClip();
}
_y = (_y - ySpeed);
_x = (_x + xSpeed);
xSpeed = xSpeed * 0.7;
ySpeed = ySpeed * 0.7;
tmr = tmr - 3;
_alpha = (tmr / 2);
if (tmr < 1) {
this.removeMovieClip();
}
}
Instance of Symbol 284 MovieClip "blood" in Symbol 285 MovieClip Frame 1
onClipEvent (load) {
xSpeed = random(10) - 5;
ySpeed = random(10) - 5;
tmr = 50;
this.gotoAndStop(random(5) + 1);
}
onClipEvent (enterFrame) {
x = _x + _root.world._x;
y = _y + _root.world._y;
if (_root.buildings.hitTest(x, y, true)) {
this.removeMovieClip();
}
_y = (_y - ySpeed);
_x = (_x + xSpeed);
xSpeed = xSpeed * 0.7;
ySpeed = ySpeed * 0.7;
tmr = tmr - 3;
_alpha = (tmr / 2);
if (tmr < 1) {
this.removeMovieClip();
}
}
Instance of Symbol 272 MovieClip "explosion" in Symbol 285 MovieClip Frame 1
onClipEvent (load) {
xSpeed = random(15) - 7;
ySpeed = random(15) - 7;
tmr = 100;
this.gotoAndStop(random(5) + 1);
}
onClipEvent (enterFrame) {
x = _x + _root.world._x;
y = _y + _root.world._y;
if (_root.buildings.hitTest(x, y, true)) {
this.removeMovieClip();
}
_y = (_y - ySpeed);
_x = (_x + xSpeed);
xSpeed = xSpeed * 0.7;
ySpeed = ySpeed * 0.7;
tmr = tmr - 3;
_alpha = (tmr / 2);
if (tmr < 1) {
this.removeMovieClip();
}
}
Instance of Symbol 272 MovieClip "fire" in Symbol 285 MovieClip Frame 1
onClipEvent (load) {
xSpeed = random(10) - 5;
ySpeed = random(10) - 5;
tmr = 100;
this.gotoAndStop(random(5) + 1);
}
onClipEvent (enterFrame) {
x = _x + _root.world._x;
y = _y + _root.world._y;
if (_root.buildings.hitTest(x, y, true)) {
this.removeMovieClip();
}
_y = (_y - ySpeed);
_x = (_x + xSpeed);
xSpeed = xSpeed * 0.7;
ySpeed = ySpeed * 0.7;
tmr = tmr - 3;
_alpha = (tmr / 2);
if (tmr < 1) {
this.removeMovieClip();
}
}
Symbol 290 MovieClip Frame 1
stop();
Symbol 295 MovieClip Frame 1
_global.message = "";
Instance of Symbol 98 MovieClip in Symbol 295 MovieClip Frame 1
onClipEvent (enterFrame) {
mess = _global.message;
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 2
onClipEvent (load) {
me = 0;
}
onClipEvent (enterFrame) {
txt = "Close";
if (_global.tech > me) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
if (_global.tech > me) {
this.gotoAndStop(2);
}
}
on (rollOut) {
if (_global.tech > me) {
this.gotoAndStop(1);
}
}
on (press) {
_global.secMenu = 1;
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 2
onClipEvent (load) {
me = 1;
cost = 90;
}
onClipEvent (enterFrame) {
txt = ("Spear Tower (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Range = 75 Attack = 15 ";
if (_global.tech > me) {
this.gotoAndStop(2);
} else {
_global.message = "Not Researched";
}
if (_global.coin >= cost) {
this.gotoAndStop(2);
} else {
_global.message = "Not Enough Money";
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
_global.message = "";
}
on (press) {
if ((_global.coin >= cost) && (_global.tech > me)) {
_root.build(5, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 2
onClipEvent (load) {
me = 0;
cost = 60;
}
onClipEvent (enterFrame) {
txt = ("Rock Tower (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Range = 75 Attack = 10 ";
if (_global.tech > me) {
this.gotoAndStop(2);
} else {
_global.message = "Not Researched";
}
if (_global.coin >= cost) {
this.gotoAndStop(2);
} else {
_global.message = "Not Enough Money";
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if ((_global.coin >= cost) && (_global.tech > me)) {
_root.build(1, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 2
onClipEvent (load) {
me = 2;
cost = 110;
}
onClipEvent (enterFrame) {
txt = ("Arrow Tower (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Range = 150 Attack = 15 ";
if (_global.tech > me) {
this.gotoAndStop(2);
} else {
_global.message = "Not Researched";
}
if (_global.coin >= cost) {
this.gotoAndStop(2);
} else {
_global.message = "Not Enough Money";
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
_global.message = "";
}
on (press) {
if ((_global.coin >= cost) && (_global.tech > me)) {
_root.build(2, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 2
onClipEvent (load) {
me = 3;
cost = 130;
}
onClipEvent (enterFrame) {
txt = ("Lit Arrow Tower (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Range = 75 Attack = 15(+Fire) ";
if (_global.tech > me) {
this.gotoAndStop(2);
} else {
_global.message = "Not Researched";
}
if (_global.coin >= cost) {
this.gotoAndStop(2);
} else {
_global.message = "Not Enough Money";
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
_global.message = "";
}
on (press) {
if ((_global.coin >= cost) && (_global.tech > me)) {
_root.build(4, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 2
onClipEvent (load) {
me = 4;
cost = 150;
}
onClipEvent (enterFrame) {
txt = ("Cannon Tower (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Range = 150 Attack = 40 ";
if (_global.tech > me) {
this.gotoAndStop(2);
} else {
_global.message = "Not Researched";
}
if (_global.coin >= cost) {
this.gotoAndStop(2);
} else {
_global.message = "Not Enough Money";
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
_global.message = "";
}
on (press) {
if ((_global.coin >= cost) && (_global.tech > me)) {
_root.build(6, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 2
onClipEvent (load) {
me = 4;
cost = 160;
}
onClipEvent (enterFrame) {
txt = ("Gun Tower (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Range = 150 Attack = 25 ";
if (_global.tech > me) {
this.gotoAndStop(2);
} else {
_global.message = "Not Researched";
}
if (_global.coin >= cost) {
this.gotoAndStop(2);
} else {
_global.message = "Not Enough Money";
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
_global.message = "";
}
on (press) {
if ((_global.coin >= cost) && (_global.tech > me)) {
_root.build(7, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 2
onClipEvent (load) {
me = 5;
cost = 180;
}
onClipEvent (enterFrame) {
txt = ("Machine Gun Tower (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Range = 150 Attack = 25 ";
if (_global.tech > me) {
this.gotoAndStop(2);
} else {
_global.message = "Not Researched";
}
if (_global.coin >= cost) {
this.gotoAndStop(2);
} else {
_global.message = "Not Enough Money";
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
_global.message = "";
}
on (press) {
if ((_global.coin >= cost) && (_global.tech > me)) {
_root.build(8, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 2
onClipEvent (load) {
me = 6;
cost = 220;
}
onClipEvent (enterFrame) {
txt = ("Rocket Tower (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Range = 150 Attack = 45 ";
if (_global.tech > me) {
this.gotoAndStop(2);
} else {
_global.message = "Not Researched";
}
if (_global.coin >= cost) {
this.gotoAndStop(2);
} else {
_global.message = "Not Enough Money";
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
_global.message = "";
}
on (press) {
if ((_global.coin >= cost) && (_global.tech > me)) {
_root.build(9, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 2
onClipEvent (load) {
me = 7;
cost = 250;
}
onClipEvent (enterFrame) {
txt = ("Fire Tower (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Range = 75 Attack = (fire) ";
if (_global.tech > me) {
this.gotoAndStop(2);
} else {
_global.message = "Not Researched";
}
if (_global.coin >= cost) {
this.gotoAndStop(2);
} else {
_global.message = "Not Enough Money";
}
}
on (rollOut) {
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
_global.message = "";
}
on (press) {
if ((_global.coin >= cost) && (_global.tech > me)) {
_root.build(10, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 3
onClipEvent (load) {
me = 0;
cost = 10;
}
onClipEvent (enterFrame) {
txt = ("Wall (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Umm its a wall..";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if (_global.coin >= cost) {
_root.build(3, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 3
onClipEvent (load) {
me = 0;
}
onClipEvent (enterFrame) {
txt = "Close";
if (_global.tech > me) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
if (_global.tech > me) {
this.gotoAndStop(2);
}
}
on (rollOut) {
if (_global.tech > me) {
this.gotoAndStop(1);
}
}
on (press) {
_global.secMenu = 1;
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 3
onClipEvent (load) {
me = 0;
cost = 50;
}
onClipEvent (enterFrame) {
txt = ("Farm (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Raises birth rate.";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if (_global.coin >= cost) {
_root.build(20, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 3
onClipEvent (load) {
me = 0;
cost = 75;
}
onClipEvent (enterFrame) {
txt = ("Blacksmith (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
_global.message = "Increases the attack of nearby towers";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if (_global.coin >= cost) {
_root.build(21, _x, _y);
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 4
onClipEvent (load) {
me = 0;
cost = 30;
}
onClipEvent (enterFrame) {
txt = ("+100 (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if (_global.coin >= cost) {
_global.castleHealth = _global.castleHealth + 100;
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 4
onClipEvent (load) {
me = 0;
cost = 50;
}
onClipEvent (enterFrame) {
txt = ("+200 (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if (_global.coin >= cost) {
_global.castleHealth = _global.castleHealth + 200;
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 4
onClipEvent (load) {
me = 0;
cost = 100;
}
onClipEvent (enterFrame) {
txt = ("+500 (" + cost) + ")";
if ((_global.tech > me) && (_global.coin >= cost)) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
if ((_global.tech > me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if (_global.coin >= cost) {
_global.castleHealth = _global.castleHealth + 500;
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 5
onClipEvent (load) {
me = 0;
}
onClipEvent (enterFrame) {
txt = "Close";
if (_global.tech > me) {
} else {
this.gotoAndStop(3);
}
}
on (rollOver) {
if (_global.tech > me) {
this.gotoAndStop(2);
}
}
on (rollOut) {
if (_global.tech > me) {
this.gotoAndStop(1);
}
}
on (press) {
_global.secMenu = 1;
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 5
onClipEvent (load) {
me = 3;
cost = 125;
}
onClipEvent (enterFrame) {
txt = ("Chemistry (" + cost) + ")";
if (_global.tech == me) {
if (_global.coin >= cost) {
} else {
this.gotoAndStop(3);
}
} else if (_global.tech < me) {
this.gotoAndStop(3);
} else {
this.gotoAndStop(4);
}
}
on (rollOver) {
_global.message = "Allows lit arrow towers to be built";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if ((_global.coin >= cost) && (_global.tech == me)) {
did = true;
_global.tech = _global.tech + 1;
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 5
onClipEvent (load) {
me = 1;
cost = 50;
}
onClipEvent (enterFrame) {
txt = ("Tool Making (" + cost) + ")";
if (_global.tech == me) {
if (_global.coin >= cost) {
} else {
this.gotoAndStop(3);
}
} else if (_global.tech < me) {
this.gotoAndStop(3);
} else {
this.gotoAndStop(4);
}
}
on (rollOver) {
_global.message = "Allows spear towers to be built";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
_global.message = "";
}
on (press) {
if ((_global.coin >= cost) && (_global.tech == me)) {
did = true;
_global.tech = _global.tech + 1;
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 5
onClipEvent (load) {
me = 2;
cost = 75;
}
onClipEvent (enterFrame) {
txt = ("Archery (" + cost) + ")";
if (_global.tech == me) {
if (_global.coin >= cost) {
} else {
this.gotoAndStop(3);
}
} else if (_global.tech < me) {
this.gotoAndStop(3);
} else {
this.gotoAndStop(4);
}
}
on (rollOver) {
_global.message = "Allows arrow towers to be built";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if ((_global.coin >= cost) && (_global.tech == me)) {
did = true;
_global.tech = _global.tech + 1;
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 5
onClipEvent (load) {
me = 4;
cost = 175;
}
onClipEvent (enterFrame) {
txt = ("Gunpowder (" + cost) + ")";
if (_global.tech == me) {
if (_global.coin >= cost) {
} else {
this.gotoAndStop(3);
}
} else if (_global.tech < me) {
this.gotoAndStop(3);
} else {
this.gotoAndStop(4);
}
}
on (rollOver) {
_global.message = "Allows Cannon towers and Gun towers to be built";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if ((_global.coin >= cost) && (_global.tech == me)) {
did = true;
_global.tech = _global.tech + 1;
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 5
onClipEvent (load) {
me = 5;
cost = 200;
}
onClipEvent (enterFrame) {
txt = ("Machinery (" + cost) + ")";
if (_global.tech == me) {
if (_global.coin >= cost) {
} else {
this.gotoAndStop(3);
}
} else if (_global.tech < me) {
this.gotoAndStop(3);
} else {
this.gotoAndStop(4);
}
}
on (rollOver) {
_global.message = "Allows Machine Gun towers to be built";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if ((_global.coin >= cost) && (_global.tech == me)) {
did = true;
_global.tech = _global.tech + 1;
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 5
onClipEvent (load) {
me = 6;
cost = 250;
}
onClipEvent (enterFrame) {
txt = ("Rocketry (" + cost) + ")";
if (_global.tech == me) {
if (_global.coin >= cost) {
} else {
this.gotoAndStop(3);
}
} else if (_global.tech < me) {
this.gotoAndStop(3);
} else {
this.gotoAndStop(4);
}
}
on (rollOver) {
_global.message = "Allows Rocket Towers to be built";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if ((_global.coin >= cost) && (_global.tech == me)) {
did = true;
_global.tech = _global.tech + 1;
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 5
onClipEvent (load) {
me = 7;
cost = 300;
}
onClipEvent (enterFrame) {
txt = ("Advanced Chemistry (" + cost) + ")";
if (_global.tech == me) {
if (_global.coin >= cost) {
} else {
this.gotoAndStop(3);
}
} else if (_global.tech < me) {
this.gotoAndStop(3);
} else {
this.gotoAndStop(4);
}
}
on (rollOver) {
_global.message = "Allows Fire Towers to be built";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if ((_global.coin >= cost) && (_global.tech == me)) {
did = true;
_global.tech = _global.tech + 1;
_global.coin = _global.coin - cost;
}
}
Instance of Symbol 86 MovieClip in Symbol 295 MovieClip Frame 5
onClipEvent (load) {
me = 8;
cost = 2500;
}
onClipEvent (enterFrame) {
txt = ("Nuclear Energy (" + cost) + ")";
if (_global.tech == me) {
if (_global.coin >= cost) {
} else {
this.gotoAndStop(3);
}
} else if (_global.tech < me) {
this.gotoAndStop(3);
} else {
this.gotoAndStop(4);
}
}
on (rollOver) {
_global.message = "Wins the game";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(2);
}
}
on (rollOut) {
_global.message = "";
if ((_global.tech == me) && (_global.coin >= cost)) {
this.gotoAndStop(1);
}
}
on (press) {
if ((_global.coin >= cost) && (_global.tech == me)) {
_root.music.stop();
_root.gotoAndStop(6);
did = true;
_global.tech = _global.tech + 1;
_global.coin = _global.coin - cost;
}
}
Symbol 303 Button
on (press) {
if (_global.bNum > 0) {
_global.waveTime = 0;
_root.menu._x = -550;
} else {
_root.popUp.gotoAndStop(4);
}
}
Symbol 308 Button
on (press) {
_global.secMenu = 2;
}
Symbol 313 Button
on (press) {
_global.secMenu = 3;
}
Symbol 318 Button
on (press) {
_global.secMenu = 4;
}
Symbol 333 Button
on (press) {
_global.secMenu = 5;
}
Instance of Symbol 295 MovieClip in Symbol 334 MovieClip Frame 1
onClipEvent (enterFrame) {
this.gotoAndStop(_global.secMenu);
if (_global.secMenu > 1) {
if (_x < 98) {
_x = (_x + 10);
}
} else if (_x > -92) {
_x = (_x - 10);
}
}
Symbol 339 Button
on (press) {
_root._quality = "LOW";
}
Symbol 341 Button
on (press) {
_root._quality = "MEDIUM";
}
Symbol 343 Button
on (press) {
_root._quality = "MEDIUM";
}
Symbol 347 MovieClip Frame 1
stop();
Symbol 350 Button
on (press) {
_root.gotoAndStop(4);
}
Instance of Symbol 347 MovieClip in Symbol 355 MovieClip Frame 1
onClipEvent (load) {
}
onClipEvent (enterFrame) {
if (_global.particles) {
this.gotoAndStop(1);
} else {
this.gotoAndStop(2);
}
}
on (press) {
_root.clix.start();
if (_global.particles) {
_global.particles = false;
} else {
_global.particles = true;
}
}
Instance of Symbol 353 MovieClip in Symbol 355 MovieClip Frame 1
onClipEvent (enterFrame) {
_width = (0.15 * _global.castleHealth);
}
Symbol 365 Button
on (press) {
_global.waveTime = 0;
_root.menu._x = -550;
_root.popUp.gotoAndStop(1);
}
Symbol 368 Button
on (press) {
_root.popUp.gotoAndStop(1);
_global.secMenu = 2;
}
Symbol 369 MovieClip Frame 1
stop();
Symbol 377 Button
on (press) {
_root.clix.start();
_root.gotoAndStop(2);
}
Symbol 382 Button
on (press) {
_root.tut.play();
}
Symbol 402 MovieClip Frame 1
stop();
Symbol 402 MovieClip Frame 2
stop();
Symbol 402 MovieClip Frame 3
stop();
Symbol 402 MovieClip Frame 4
stop();
Symbol 402 MovieClip Frame 5
stop();
Symbol 402 MovieClip Frame 6
stop();
Instance of Symbol 347 MovieClip in Symbol 402 MovieClip Frame 6
onClipEvent (load) {
}
onClipEvent (enterFrame) {
if (_global.particles) {
this.gotoAndStop(1);
} else {
this.gotoAndStop(2);
}
}
on (press) {
_root.clix.start();
if (_global.particles) {
_global.particles = false;
} else {
_global.particles = true;
}
}
Instance of Symbol 353 MovieClip in Symbol 402 MovieClip Frame 6
onClipEvent (enterFrame) {
_width = (0.15 * _global.castleHealth);
}
Symbol 402 MovieClip Frame 7
stop();