Frame 1
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;
var pv;
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);
}
pv = ((fv == 5) ? (getVersion()) : (System.capabilities.version));
u = (((((((((((("http://" + mbc) + "/my/core.swf?mv=8&fv=") + fv) + "&v=") + escape(pv)) + "&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__("db8c6284", this, 10301, true);
soundBTN.onPress = function () {
soundBTN.play();
};
var fireMinionShooting_sound = new Sound();
fireMinionShooting_sound.attachSound("fireMinionShooting");
sound = start(0, 1);
sound = setVolume(100);
var greenMinionAtomicBomb_sound = new Sound();
greenMinionAtomicBomb_sound.attachSound("greenMinionAtomicBomb");
sound = start(0, 1);
sound = setVolume(100);
var buttonNoises_sound = new Sound();
buttonNoises_sound.attachSound("buttonNoises");
sound = start(0, 1);
sound = setVolume(100);
var brownMinionClubbing_sound = new Sound();
brownMinionClubbing_sound.attachSound("brownMinionClubbing");
sound = start(0, 1);
sound = setVolume(100);
var greenMinionSlash_sound = new Sound();
greenMinionSlash_sound.attachSound("greenMinionSlash");
sound = start(0, 1);
sound = setVolume(100);
var greenMinionSpinSlash_sound = new Sound();
greenMinionSpinSlash_sound.attachSound("greenMinionSpinSlash");
sound = start(0, 1);
sound = setVolume(100);
var blueMinionSplash_sound = new Sound();
blueMinionSplash_sound.attachSound("blueMinionSplash");
sound = start(0, 1);
sound = setVolume(100);
var minionBand_sound = new Sound();
minionBand_sound.attachSound("minionBand");
sound = start(0, 100);
sound = setVolume(100);
var bell_sound = new Sound();
bell_sound.attachSound("bell");
sound = start(0, 1);
sound = setVolume(100);
stop();
Frame 2
stop();
_root.hasGameStarted = false;
Instance of Symbol 186 MovieClip "grass" in Frame 2
/* no clip actions */
Instance of Symbol 189 MovieClip "deselect" in Frame 2
on (press) {
_root.selectedTower = "";
_root.ranger._x = 3000;
_root.ranger._width = 10;
_root.ranger._height = 10;
_root.UpgradeTowerInfo._visible = false;
_root.icon2Blocker._visible = true;
_root.icon3Blocker._visible = true;
_root.icon5Blocker._visible = true;
_root.icon6Blocker._visible = true;
_root.icon8Blocker._visible = true;
_root.icon9Blocker._visible = true;
_root.icon11Blocker._visible = true;
_root.icon12Blocker._visible = true;
_root.icon2upper._visible = false;
_root.icon3upper._visible = false;
_root.icon5upper._visible = false;
_root.icon6upper._visible = false;
_root.icon8upper._visible = false;
_root.icon9upper._visible = false;
_root.icon11upper._visible = false;
_root.icon12upper._visible = false;
_root.sellButton._visible = false;
_parent.info_message._visible = false;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
Instance of Symbol 212 MovieClip "InfoBar" in Frame 2
/* no clip actions */
Instance of Symbol 215 MovieClip "marker" in Frame 2
onClipEvent (load) {
active = 0;
}
onClipEvent (enterFrame) {
if (active == 1) {
_x = ((int((_root._xmouse - 10) / 20) * 20) + 20);
_y = ((int((_root._ymouse - 10) / 20) * 20) + 20);
hitTestOnGrassMovieClip = _root.grass.hitTest(_x, _y, 1);
if (hitTestOnGrassMovieClip) {
gotoAndStop (1);
_root.ranger.gotoAndStop(1);
} else {
gotoAndStop (2);
_root.ranger.gotoAndStop(2);
}
_root.ranger._x = _x;
_root.ranger._y = _y;
_root.ranger._width = _root["tower_" + tower].range * 2;
_root.ranger._height = _root["tower_" + tower].range * 2;
}
}
on (press) {
hitTestOnGrassMovieClip = _root.grass.hitTest(_x, _y, 1);
hitTestOnDeSelectMovieClip = _root.deselect.hitTest(_x, _y, 1);
if (hitTestOnGrassMovieClip || (hitTestOnDeSelectMovieClip)) {
if (hitTestOnGrassMovieClip && (!_root.hasGameFinished)) {
_root.towerCount++;
_root["tower_" + tower].duplicateMovieClip("t" + _root.towerCount, 500 + _root.towerCount);
a = _root["t" + _root.towerCount];
a._x = _x;
a._y = _y;
a.active = 1;
a.cost = cost;
_root.money = _root.money - cost;
_root.updateInfoBar();
if (!_root.hasGameStarted) {
_root.newLevel();
_root.hasGameStarted = true;
_root.instructions._visible = false;
}
}
active = 0;
_x = 1000;
_root.selectedTower = "";
_root.ranger._x = 1000;
_root.ranger._width = 10;
_root.ranger._height = 10;
}
}
Instance of Symbol 222 MovieClip "info_message" in Frame 2
onClipEvent (load) {
_visible = false;
}
Instance of Symbol 232 MovieClip in Frame 2
on (press) {
if (_root.money >= 24) {
_root.marker.active = 1;
_root.marker.tower = "cannon";
_root.marker.cost = 24;
}
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.UpgradeTowerInfo._visible = false;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = _root.tower_cannon.title;
_parent.info_message.desc.text = _root.tower_cannon.desc;
_parent.info_message.costMoney.text = _root.tower_cannon.costMoney;
_parent.info_message.attackType.text = _root.tower_cannon.attackType;
_parent.info_message.type.text = _root.tower_cannon.type;
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 235 MovieClip in Frame 2
on (press) {
if (_root.money >= 40) {
_root.marker.active = 1;
_root.marker.tower = "fire";
_root.marker.cost = 49;
}
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.UpgradeTowerInfo._visible = false;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = "Red Minion Ember";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $40";
_parent.info_message.attackType.text = "Burns a single villager at a time";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 238 MovieClip in Frame 2
on (press) {
if (_root.money >= 50) {
_root.marker.active = 1;
_root.marker.tower = "water";
_root.marker.cost = 50;
}
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.UpgradeTowerInfo._visible = false;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = "Blue Minion Water Puddle";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $50";
_parent.info_message.attackType.text = "Slows down villagers ";
_parent.info_message.type.text = "Damage: Low";
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 241 MovieClip in Frame 2
on (press) {
if (_root.money >= 60) {
_root.marker.active = 1;
_root.marker.tower = "poison";
_root.marker.cost = 60;
}
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.UpgradeTowerInfo._visible = false;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = "Green Minion Claw Slash";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $60";
_parent.info_message.attackType.text = "Attacks villager twice ";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 243 MovieClip in Frame 2
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = "Brown Minion w/ Sword";
_parent.info_message.desc.text = "Speed: Medium";
_parent.info_message.costMoney.text = "Cost: $240";
_parent.info_message.attackType.text = "Hits a single villager at a time";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 245 MovieClip in Frame 2
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = "Brown Minion w/ Mace";
_parent.info_message.desc.text = "Speed: Medium";
_parent.info_message.costMoney.text = "Cost: $600";
_parent.info_message.attackType.text = "Hits multiple villagers at a time";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 248 MovieClip in Frame 2
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = "Red Minion Fireball Blast";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $250";
_parent.info_message.attackType.text = "Damage over time to multiple villagers";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 253 MovieClip in Frame 2
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = "Red Minion Firewall";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $1500";
_parent.info_message.attackType.text = "Damage over time to multiple villagers";
_parent.info_message.type.text = "Damage: Strong";
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 256 MovieClip in Frame 2
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = "Blue Minion Poison Splash";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $300";
_parent.info_message.attackType.text = "Slows down a group of villagers";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 259 MovieClip in Frame 2
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = "Blue Minion Ice Blast";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $750";
_parent.info_message.attackType.text = "Slows down large group of villagers. One time use. Minion lost after attack";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 262 MovieClip in Frame 2
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = "Green Minion Spin Splash";
_parent.info_message.desc.text = "Speed: Medium";
_parent.info_message.costMoney.text = "Cost: $320";
_parent.info_message.attackType.text = "Affects multiple villagers inside range";
_parent.info_message.type.text = "Damage: Strong";
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 265 MovieClip in Frame 2
on (rollOver) {
_root.sellButton._visible = false;
_parent.info_message.title.text = "Green Minion Atomic Bomb";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $4000";
_parent.info_message.attackType.text = "Wipes out majority of villagers. One time use";
_parent.info_message.type.text = "Damage: Strong";
_parent.info_message._visible = true;
}
on (rollOut) {
_parent.info_message._visible = false;
}
Instance of Symbol 266 MovieClip "infoIcon1" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 267 MovieClip "infoIcon4" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 268 MovieClip "infoIcon7" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 269 MovieClip "infoIcon10" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 229 MovieClip "infoIcon2" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 231 MovieClip "infoIcon3" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 270 MovieClip "infoIcon5" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 271 MovieClip "infoIcon6" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 272 MovieClip "infoIcon8" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 273 MovieClip "infoIcon9" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 274 MovieClip "infoIcon11" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 275 MovieClip "infoIcon12" in Frame 2
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 287 MovieClip "UpgradeTowerInfo" in Frame 2
onClipEvent (load) {
_visible = false;
swapDepths(100000);
}
Instance of Symbol 307 MovieClip "timeline" in Frame 2
onClipEvent (load) {
clearInterval(_root.levelInterval);
_root.levelInterval = setInterval(_root, "executeCallback", 600);
}
on (press) {
if (!_root.hasGameStarted) {
return(undefined);
}
if ((_root.wave >= 0) && ((_root.wave - 1) <= (_root.waves.length - 1))) {
_root.score = _root.score + (_root.wave * (_root.maxCount - _root.count));
_root.money = _root.money + int(_root.money * 0.03);
_root.count = 1;
_root.newLevel();
}
}
onClipEvent (enterFrame) {
}
Frame 12
onEnterFrame = function () {
_root.rules.swapDepths(100001);
_root.InfoBar.swapDepths(100000);
if (_root.InfoBar.hitTest(_root.endScreen)) {
_root.InfoBar.removeMovieClip();
} else {
_root.InfoBar._visible = true;
}
if ((_root.selectedTower.hitTest(_root.ranger) && (_root.money >= 240)) && (_root.selectedTower.damage == 10)) {
_root.icon2Blocker._visible = false;
_root.icon2upper._visible = true;
_root.icon3Blocker._visible = true;
_root.icon3upper._visible = false;
_root.icon5Blocker._visible = true;
_root.icon6Blocker._visible = true;
_root.icon8Blocker._visible = true;
_root.icon9Blocker._visible = true;
_root.icon11Blocker._visible = true;
_root.icon12Blocker._visible = true;
_root.icon5upper._visible = false;
_root.icon6upper._visible = false;
_root.icon8upper._visible = false;
_root.icon9upper._visible = false;
_root.icon11upper._visible = false;
_root.icon12upper._visible = false;
}
if ((_root.selectedTower.hitTest(_root.ranger) && (_root.money >= 600)) && (_root.selectedTower.damage == 20)) {
_root.icon2Blocker._visible = true;
_root.icon2upper._visible = false;
_root.icon3Blocker._visible = false;
_root.icon3upper._visible = true;
_root.icon5Blocker._visible = true;
_root.icon6Blocker._visible = true;
_root.icon8Blocker._visible = true;
_root.icon9Blocker._visible = true;
_root.icon11Blocker._visible = true;
_root.icon12Blocker._visible = true;
_root.icon5upper._visible = false;
_root.icon6upper._visible = false;
_root.icon8upper._visible = false;
_root.icon9upper._visible = false;
_root.icon11upper._visible = false;
_root.icon12upper._visible = false;
}
if ((_root.selectedTower.hitTest(_root.ranger) && (_root.money >= 250)) && (_root.selectedTower.damage == 15)) {
_root.icon5Blocker._visible = false;
_root.icon5upper._visible = true;
_root.icon6Blocker._visible = true;
_root.icon6upper._visible = false;
_root.icon2Blocker._visible = true;
_root.icon3Blocker._visible = true;
_root.icon8Blocker._visible = true;
_root.icon9Blocker._visible = true;
_root.icon2upper._visible = false;
_root.icon3upper._visible = false;
_root.icon8upper._visible = false;
_root.icon9upper._visible = false;
}
if ((_root.selectedTower.hitTest(_root.ranger) && (_root.money >= 1500)) && (_root.selectedTower.damage == 30)) {
_root.icon5Blocker._visible = true;
_root.icon5upper._visible = false;
_root.icon6Blocker._visible = false;
_root.icon6upper._visible = true;
_root.icon2Blocker._visible = true;
_root.icon3Blocker._visible = true;
_root.icon8Blocker._visible = true;
_root.icon9Blocker._visible = true;
_root.icon2upper._visible = false;
_root.icon3upper._visible = false;
_root.icon8upper._visible = false;
_root.icon9upper._visible = false;
}
if ((_root.selectedTower.hitTest(_root.ranger) && (_root.money >= 300)) && (_root.selectedTower.damage == 5)) {
_root.icon8Blocker._visible = false;
_root.icon8upper._visible = true;
_root.icon9Blocker._visible = true;
_root.icon9upper._visible = false;
_root.icon2Blocker._visible = true;
_root.icon3Blocker._visible = true;
_root.icon5Blocker._visible = true;
_root.icon6Blocker._visible = true;
_root.icon2upper._visible = false;
_root.icon3upper._visible = false;
_root.icon5upper._visible = false;
_root.icon6upper._visible = false;
}
if ((_root.selectedTower.hitTest(_root.ranger) && (_root.money >= 750)) && (_root.selectedTower.damage == 25)) {
_root.icon8Blocker._visible = true;
_root.icon8upper._visible = false;
_root.icon9Blocker._visible = false;
_root.icon9upper._visible = true;
_root.icon2Blocker._visible = true;
_root.icon3Blocker._visible = true;
_root.icon5Blocker._visible = true;
_root.icon6Blocker._visible = true;
_root.icon11Blocker._visible = true;
_root.icon12Blocker._visible = true;
_root.icon2upper._visible = false;
_root.icon3upper._visible = false;
_root.icon5upper._visible = false;
_root.icon6upper._visible = false;
_root.icon11upper._visible = false;
_root.icon12upper._visible = false;
}
if ((_root.selectedTower.hitTest(_root.ranger) && (_root.money >= 320)) && (_root.selectedTower.damage == 18)) {
_root.icon11Blocker._visible = false;
_root.icon11upper._visible = true;
_root.icon12Blocker._visible = true;
_root.icon12upper._visible = false;
_root.icon2Blocker._visible = true;
_root.icon3Blocker._visible = true;
_root.icon5Blocker._visible = true;
_root.icon6Blocker._visible = true;
_root.icon8Blocker._visible = true;
_root.icon9Blocker._visible = true;
_root.icon2upper._visible = false;
_root.icon3upper._visible = false;
_root.icon5upper._visible = false;
_root.icon6upper._visible = false;
_root.icon8upper._visible = false;
_root.icon9upper._visible = false;
}
if ((_root.selectedTower.hitTest(_root.ranger) && (_root.money >= 4000)) && (_root.selectedTower.damage == 38)) {
_root.icon11Blocker._visible = true;
_root.icon11upper._visible = false;
_root.icon12Blocker._visible = false;
_root.icon12upper._visible = true;
_root.icon2Blocker._visible = true;
_root.icon3Blocker._visible = true;
_root.icon5Blocker._visible = true;
_root.icon6Blocker._visible = true;
_root.icon8Blocker._visible = true;
_root.icon9Blocker._visible = true;
_root.icon2upper._visible = false;
_root.icon3upper._visible = false;
_root.icon5upper._visible = false;
_root.icon6upper._visible = false;
_root.icon8upper._visible = false;
_root.icon9upper._visible = false;
}
if (_root.wave >= 25) {
clearInterval(_root["spawnInterval" + level]);
clearInterval(_root.spawnInterval0);
clearInterval(_root.spawnInterval1);
clearInterval(_root.spawnInterval2);
clearInterval(_root.spawnInterval3);
clearInterval(_root.spawnInterval4);
clearInterval(_root.spawnInterval5);
clearInterval(_root.spawnInterval6);
clearInterval(_root.spawnInterval7);
clearInterval(_root.spawnInterval8);
clearInterval(_root.spawnInterval9);
clearInterval(_root.spawnInterval10);
}
if (_root.wave >= 35) {
clearInterval(_root.spawnInterval11);
clearInterval(_root.spawnInterval12);
clearInterval(_root.spawnInterval13);
clearInterval(_root.spawnInterval14);
clearInterval(_root.spawnInterval15);
clearInterval(_root.spawnInterval16);
clearInterval(_root.spawnInterval17);
clearInterval(_root.spawnInterval18);
clearInterval(_root.spawnInterval19);
clearInterval(_root.spawnInterval20);
}
if (_root.wave >= 45) {
clearInterval(_root.spawnInterval21);
clearInterval(_root.spawnInterval22);
clearInterval(_root.spawnInterval23);
clearInterval(_root.spawnInterval24);
clearInterval(_root.spawnInterval25);
clearInterval(_root.spawnInterval26);
clearInterval(_root.spawnInterval27);
clearInterval(_root.spawnInterval28);
clearInterval(_root.spawnInterval29);
clearInterval(_root.spawnInterval30);
}
if (_root.wave >= 55) {
clearInterval(_root.spawnInterval31);
clearInterval(_root.spawnInterval32);
clearInterval(_root.spawnInterval33);
clearInterval(_root.spawnInterval34);
clearInterval(_root.spawnInterval35);
clearInterval(_root.spawnInterval36);
clearInterval(_root.spawnInterval37);
clearInterval(_root.spawnInterval38);
clearInterval(_root.spawnInterval39);
clearInterval(_root.spawnInterval40);
}
if (_root.wave >= 65) {
clearInterval(_root.spawnInterval41);
clearInterval(_root.spawnInterval42);
clearInterval(_root.spawnInterval43);
clearInterval(_root.spawnInterval44);
clearInterval(_root.spawnInterval45);
clearInterval(_root.spawnInterval46);
clearInterval(_root.spawnInterval47);
clearInterval(_root.spawnInterval48);
clearInterval(_root.spawnInterval49);
clearInterval(_root.spawnInterval50);
}
if (_root.wave >= 75) {
clearInterval(_root.spawnInterval51);
clearInterval(_root.spawnInterval52);
clearInterval(_root.spawnInterval53);
clearInterval(_root.spawnInterval54);
clearInterval(_root.spawnInterval55);
clearInterval(_root.spawnInterval56);
clearInterval(_root.spawnInterval57);
clearInterval(_root.spawnInterval58);
clearInterval(_root.spawnInterval59);
clearInterval(_root.spawnInterval60);
}
if (_root.wave >= 85) {
clearInterval(_root.spawnInterval61);
clearInterval(_root.spawnInterval62);
clearInterval(_root.spawnInterval63);
clearInterval(_root.spawnInterval64);
clearInterval(_root.spawnInterval65);
clearInterval(_root.spawnInterval66);
clearInterval(_root.spawnInterval67);
clearInterval(_root.spawnInterval68);
clearInterval(_root.spawnInterval69);
clearInterval(_root.spawnInterval70);
}
if (_root.wave >= 95) {
clearInterval(_root.spawnInterval71);
clearInterval(_root.spawnInterval72);
clearInterval(_root.spawnInterval73);
clearInterval(_root.spawnInterval74);
clearInterval(_root.spawnInterval75);
clearInterval(_root.spawnInterval76);
clearInterval(_root.spawnInterval77);
clearInterval(_root.spawnInterval78);
clearInterval(_root.spawnInterval79);
clearInterval(_root.spawnInterval80);
}
};
minionBand_sound.start(0, 99);
soundBTN.onPress = function () {
soundBTN.play();
};
function executeCallback() {
if (_root.hasGameStarted) {
if (_root.count >= _root.maxCount) {
_root.newLevel();
_root.count = 1;
}
if ((_root.wave - 1) < (_root.waves.length - 1)) {
_root.count++;
} else if (_root.currentNumberofCreeps <= 0) {
_root.hasGameStarted = false;
}
} else {
var _local2 = 1;
while (_local2 <= _root.towerCount) {
b = _root["t" + _local2];
if (("" + b) != "undefined") {
Explosion("projectile_fire", b._x, b._y);
b.removeMovieClip();
}
_local2++;
}
}
}
function towerInfo(tower) {
_root.selectedTower = tower;
_root.ranger._x = tower._x;
_root.ranger._y = tower._y;
_root.ranger._width = tower.range * 2;
_root.ranger._height = tower.range * 2;
_root.UpgradeTowerInfo._visible = true;
if (tower.upgrades.length >= tower.level) {
_root.UpgradeTowerInfo.UpgradeInfoText.text = tower.upgrades[tower.level - 1][0];
_root.UpgradeTowerInfo.TowerInfoText.text = (((((((("Damage: " + tower.damage) + "\rRange: ") + tower.range) + "\rSplash: ") + (tower.splash ? "Yes" : "No")) + "\rSlow: ") + (tower.slow ? "Yes" : "No")) + "\rPoison: ") + (tower.poison ? "Yes" : "No");
_root.UpgradeTowerInfo.UpgradeButton.UpgradeButtonText.text = ("Upgrade [$" + tower.upgrades[tower.level - 1][1]) + "]";
_root.UpgradeTowerInfo.UpgradeButton._visible = true;
} else {
_root.UpgradeTowerInfo.f.text = "";
_root.UpgradeTowerInfo.UpgradeButton._visible = false;
_root.UpgradeTowerInfo.h.text = "";
}
}
function newLevel() {
_root.wave++;
updateInfoBar();
if ((_root.wave - 1) < (_root.waves.length - 1)) {
_root.inGameMessage(("<b>Lvl: " + _root.wave) + "</b>");
_root["spawnInterval" + _root.wave] = setInterval(_root, "spawn", _root.waves[_root.wave - 1][3], _root.wave, "creep1", _root.waves[_root.wave - 1][2], _root.waves[_root.wave - 1][1], _root.waves[_root.wave - 1][4]);
_root["creepEventInterval" + _root.wave] = setInterval(_root, "creepEvent", 500);
_root["spawned" + _root.wave] = _root.waves[_root.wave - 1][0];
}
updateScore();
}
function creepEvent() {
i = 0;
while (i <= _root.creepArray.length) {
if (("" + _root.creepArray[i]) != "") {
if (_root.creepArray[i].poison > 0) {
_root.creepArray[i].health = _root.creepArray[i].health - ((_root.creepArray[i].poison * _root.creepArray[i].health) * 0.001);
_root.creepArray[i].poison--;
}
}
i++;
}
}
function spawn(level, creep, speed, health, money) {
if (_root["spawned" + level] == 0) {
clearInterval(_root["spawnInterval" + level]);
} else {
_root["spawned" + level]--;
_root.creepCount++;
_root.currentNumberofCreeps++;
_root[creep].duplicateMovieClip("c" + _root.creepCount, 1000 + _root.creepCount);
c = _root["c" + _root.creepCount];
_root.creepArray[_root.creepArray.length] = c;
c.creep.gotoAndStop(level);
c._x = wp1._x;
c._y = wp1._y;
c.speed = speed;
c.maxspeed = speed;
c.targ = 2;
c.rnd = random(10);
c.health = health;
c.maxHealth = health;
c.isDead = 0;
c.money = money;
c.onEnterFrame = function () {
if (this.health <= 0) {
_root.kill(this);
}
if (this.speed < this.maxspeed) {
this.speed = this.speed + 0.1;
}
this.targX = (_root["wp" + this.targ]._x - 5) + this.rnd;
this.targY = (_root["wp" + this.targ]._y - 5) + this.rnd;
this.dir = (Math.atan2(this.targY - this._y, this.targX - this._x) * 180) / 3.141593;
if ((this.creep._rotation + 10) < this.r) {
this.creep._rotation = this.creep._rotation + 10;
} else if ((this.creep._rotation - 10) > this.r) {
this.creep._rotation = this.creep._rotation - 10;
} else {
this.creep._rotation = r;
}
this.rads = (this.dir * 3.141593) * 0.005;
this._x = this._x + (Math.cos(this.rads) * this.speed);
this._y = this._y + (Math.sin(this.rads) * this.speed);
d = Math.sqrt(Math.pow(this._x - this.targX, 2) + Math.pow(this._y - this.targY, 2));
if (d < 5) {
this.targ++;
if (this.targ > 160) {
_root.leak(this);
_root.updateInfoBar();
}
}
this.health_bar.health._width = (30 / this.maxHealth) * this.health;
this.health_bar._visible = true;
};
}
}
function Explosion(type, x, y) {
i = 1;
while (i <= 10) {
_root.explosionCount++;
duplicateMovieClip (_root[type + "_explosion"], "explosion" + _root.explosionCount, 4900 + _root.explosionCount);
a = _root["explosion" + _root.explosionCount];
a._x = x;
a._y = y;
a.rads = random(360);
a.speed = (5 + random(20)) * 0.2;
a._rotation = a.rads;
a.onEnterFrame = function () {
this._x = this._x + (Math.cos(this.rads) * this.speed);
this._y = this._y + (Math.sin(this.rads) * this.speed);
this._alpha = this._alpha - 5;
if (this.speed > 0.5) {
this.speed = this.speed - 0.5;
}
if (this._alpha <= 0) {
this.removeMovieClip();
}
};
i++;
}
if (_root.explosionCount > 100) {
_root.explosionCount = 0;
}
}
function fire(from, to, speed, acc, maxspeed, projectile, damage, splash, slow, poison) {
_root.particleCount++;
_root[projectile].duplicateMovieClip("p" + _root.particleCount, 2000 + _root.particleCount);
r = _root["p" + _root.particleCount];
dir = (Math.atan2(from._y - to._y, from._x - to._x) * 180) / 3.141593;
rads = (dir * 3.141593) / 180;
r._x = from._x;
r._y = from._y;
r._x = r._x - (Math.cos(rads) * (from._width * 0.5));
r._y = r._y - (Math.sin(rads) * (from._height * 0.5));
r.targ = to;
if (("" + to) == "") {
r.removeMovieClip();
}
r.speed = speed;
r.acc = acc;
r.maxspeed = maxspeed;
r.projectile = projectile;
r.damage = damage;
r.splash = splash;
r.slow = slow;
r.poison = poison;
r.onEnterFrame = function () {
if (("" + this.targ) != "") {
this.targX = this.targ._x;
this.targY = this.targ._y;
} else if (("" + this.targX) == "undefined") {
this.removeMovieClip();
}
this.dir = (Math.atan2(this.targY - this._y, this.targX - this._x) * 180) / 3.141593;
this._rotation = this.dir + 90;
this.rads = (this.dir * 3.141593) / 180;
this._x = this._x + (Math.cos(this.rads) * this.speed);
this._y = this._y + (Math.sin(this.rads) * this.speed);
if (this.speed < this.maxspeed) {
this.speed = this.speed + this.acc;
}
d = Math.sqrt(Math.pow(this._x - this.targX, 2) + Math.pow(this._y - this.targY, 2));
if (d < 10) {
Explosion(projectile, this._x, this._y);
if (this.slow > 0) {
this.targ.speed = (this.targ.maxspeed * 0.01) * (50 - this.slow);
}
if (this.poison > 0) {
this.targ.poison = this.poison;
}
if (this.splash > 0) {
i = 0;
while (i <= _root.creepArray.length) {
if ((("" + _root.creepArray[i]) != "") && (_root.creepArray[i] != this.targ)) {
d = Math.sqrt(Math.pow(this._x - _root.creepArray[i]._x, 2) + Math.pow(this._y - _root.creepArray[i]._y, 2));
if (d < this.splash) {
_root.creepArray[i].health = _root.creepArray[i].health - (this.damage * (1 - (d / this.splash)));
if (this.slow > 0) {
_root.creepArray[i].speed = (_root.creepArray[i].maxspeed * 0.01) * (100 - this.slow);
}
if (this.poison > 0) {
_root.creepArray[i].poison = int(this.poison * (d / this.splash));
}
}
}
i++;
}
}
this.targ.health = this.targ.health - this.damage;
if (targ.health <= 0) {
targ.isDead = 1;
}
this.removeMovieClip();
}
if (_root.particleCount > 50) {
_root.particleCount = 0;
}
};
}
function kill(creep) {
_root.kills++;
if (_root.kills >= _root.waves[_root.wave - 1][0]) {
}
creep.onEnterFrame = function () {
_root.currentNumberOfCreeps--;
_root.money = _root.money + creep.money;
updateScore();
updateInfoBar();
this.removeMovieClip();
};
}
function escaped() {
_root.InfoBar.HealthAmount++;
_root.bell_sound.start();
if (_root.kills >= _root.waves[_root.wave - 1][0]) {
}
creep.onEnterFrame = function () {
_root.currentNumberOfCreeps--;
this.removeMovieClip();
};
}
function leak(creep) {
_root.creepLeaks++;
_root.bell_sound.start();
if (!_root.hasGameFinished) {
creep.removeMovieClip();
} else {
creep.removeMovieClip();
}
_root.health--;
_root.InfoBar.healthIcon.healthCycle.gotoAndPlay("healthHit");
if (_root.health <= 0) {
_root.health = 0;
_root.hasGameStarted = false;
if (!_root.hasGameFinished) {
_root.gotoAndStop("gameOver");
}
_root.hasGameFinished = true;
creep.removeMovieClip();
c.removeMovieClip();
creep.onEnterFrame = function () {
_root.currentNumberOfCreeps--;
_root.money = _root.money + creep.money;
updateScore();
updateInfoBar();
this.removeMovieClip();
};
}
}
function updateScore() {
var _local3 = _root.money;
var _local2 = 1;
while (_local2 <= _root.towerCount) {
b = _root["t" + _local2];
if (("" + b) != "undefined") {
_local3 = _local3 + b.cost;
}
_local2++;
}
_root.score = _root.score + _local3;
}
function upgrade() {
a = _root.selectedTower;
b = a.level - 1;
if (int(a.upgrades[b][1]) <= _root.money) {
a.damage = int(a.upgrades[b][2]);
a.range = a.upgrades[b][3];
a.rate = a.upgrades[b][4];
a.splash = a.upgrades[b][5];
a.slow = a.upgrades[b][6];
a.cost = a.cost + int(a.upgrades[b][1]);
a.level++;
_root.towerInfo(_root.selectedTower);
_root.money = _root.money - int(a.upgrades[b][1]);
updateInfoBar();
}
updateScore();
}
function updateInfoBar() {
_root.InfoBar.moneyAmount.text = _root.money;
_root.InfoBar.ScoreAmount.text = _root.score;
_root.InfoBar.HealthAmount.text = _root.health;
}
function inGameMessage(n) {
_root.ingame_message.htmlText = (n + "<br>") + _root.ingame_message.htmlText;
_root.ingame_message.vPosition = _root.ingame_message.maxVPosition;
}
stop();
_root.waves = [[7, 140, 1.2, 3600, 15], [8, 200, 1.4, 4200, 15], [25, 160, 1, 10800, 10], [6, 200, 2.8, 3600, 10], [5, 320, 3.6, 6200, 20], [6, 450, 2.4, 3600, 25], [25, 250, 2.8, 6600, 10], [5, 220, 1.4, 3600, 10], [6, 400, 4.2, 7200, 25], [5, 450, 3.5, 5200, 40], [7, 680, 2.8, 3600, 30], [1, 1800, 1.9, 7200, 800], [6, 280, 2.8, 6200, 15], [7, 240, 1.9, 4600, 20], [5, 420, 4.6, 6200, 50], [8, 740, 2.6, 4200, 30], [6, 320, 2.9, 6500, 20], [5, 280, 1.8, 3600, 15], [6, 460, 4.8, 6100, 50], [5, 480, 3.7, 5000, 50], [8, 880, 2.4, 4100, 40], [1, 3500, 1.9, 3600, 900], [7, 380, 2.4, 5000, 30], [4, 300, 1.8, 4600, 20], [5, 490, 4.6, 7200, 35], [1, 8000, 1.3, 3600, 2000], [4, 430, 2.4, 4800, 35], [7, 280, 2.1, 4900, 20], [8, 900, 2.5, 4500, 40], [6, 700, 4.8, 7100, 40], [5, 430, 2.4, 4800, 35], [6, 280, 2.2, 3900, 30], [8, 950, 2.4, 4600, 50], [5, 9000, 3.7, 5200, 50], [2, 8000, 1.9, 5600, 800], [4, 290, 2.1, 4900, 20], [4, 430, 2.3, 5100, 35], [7, 1500, 4.9, 3600, 45], [8, 1100, 3.9, 4000, 55], [5, 500, 4.9, 5200, 50], [4, 450, 2.5, 4900, 35], [5, 300, 2.3, 4500, 25], [1, 42000, 1.9, 3600, 1500], [6, 430, 2.7, 6000, 20], [7, 300, 1.9, 4200, 20], [5, 2000, 4.9, 4400, 20], [8, 1500, 4.2, 4200, 30], [6, 430, 2.9, 5500, 20], [5, 300, 1.8, 4200, 15], [7, 2300, 4.8, 5800, 30], [5, 520, 3.7, 5400, 45], [6, 2900, 2.5, 3900, 35], [2, 60000, 1.9, 10800, 550], [7, 480, 2.4, 5500, 30], [4, 300, 1.8, 4600, 20], [7, 640, 4.6, 6800, 35], [4, 999999, 1.9, 5500, 1000], [4, 430, 2.4, 4800, 35], [7, 280, 2.1, 4900, 20], [8, 900, 2.5, 4500, 40], [6, 920, 4.8, 7100, 40], [5, 430, 2.4, 4800, 35], [6, 280, 2.2, 3900, 30], [8, 1000, 2.4, 4600, 50], [5, 590, 3.7, 5200, 50], [2, 82000, 2.9, 6000, 550], [2, 8200, 2.9, 6000, 550]];
_root.wave = 0;
_root.hasGameStarted = false;
_root.hasGameFinished = false;
_root.towerCount = 0;
_root.selectedTower = "";
_root.currentNumberofCreeps = 0;
_root.creepCount = 0;
_root.creepArray = [];
_root.creepLeaks = 0;
_root.explosionCount = 0;
_root.particleCount = 0;
_root.kills = 0;
_root.money = 150;
_root.count = 1;
_root.maxCount = 40;
_root.updateDuration = 2;
_root.health = 5;
_root.score = 0;
sellButton.onPress = function () {
_root.money = _root.money + Math.abs(_root.selectedTower.cost * 0.5);
_root.selectedTower.removeMovieClip();
sellButton._visible = false;
updateInfoBar();
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
};
Instance of Symbol 345 MovieClip "tower_fire" in Frame 12
onClipEvent (load) {
title = "Fire Tower [Cost: $40]";
desc = "Fast attack speed with moderate damage and low range, but can cause splash damage to nearby enemies";
type = "Ground + Splash";
_root.sellButton.sellButtonText.text = "Sell for $20";
cost = 40;
range = 90;
rate = 30;
lastFire = rate;
lastChecked = rate;
creep = "";
target = 0;
damage = 15;
splash = 0;
slow = 0;
poison = 3;
level = 1;
upgrades = [["Damage: 11\rRange: 80\rSplash:Yes\rSlow:No\rPoison:No\r", 250, 30, 120, 20, 50, 0, 6], ["Damage: 20\rRange: 80\rSplash:Yes\rSlow:No\rPoison:No\r", 1500, 75, 130, 20, 60, 0, 8], ["Damage: 35\rRange: 80\rSplash:Yes\rSlow:No\rPoison:No\r", 9999999, 35, 80, 2, 60, 0, 0], ["Damage: 60\rRange: 80\rSplash:Yes\rSlow:Yes\rPoison:No\r", 99999998, 60, 80, 2, 60, 20, 3]];
}
on (press) {
_root.towerInfo(this);
_root.sellButton._visible = true;
if (this.cost == 40) {
_root.sellButton.sellButtonText.text = "Sell for $20";
_parent.info_message.title.text = "Red Minion Ember";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $40";
_parent.info_message.attackType.text = "Burns a single villager at a time";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = true;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
if (this.cost == 250) {
_root.sellButton.sellButtonText.text = "Sell for $125";
_parent.info_message.title.text = "Red Minion Fireball Blast";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $250";
_parent.info_message.attackType.text = "Damage over time to multiple villagers";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = true;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
if (this.cost == 1500) {
_root.sellButton.sellButtonText.text = "Sell for $750";
_parent.info_message.title.text = "Red Minion Firewall";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $1500";
_parent.info_message.attackType.text = "Damage over time to multiple villagers";
_parent.info_message.type.text = "Damage: Strong";
_parent.info_message._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = true;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
}
onClipEvent (enterFrame) {
if ((active == 1) && (_root.creepArray.length > 0)) {
lastChecked++;
if (this.damage == 15) {
cost = 40;
redWeaponLevel1 = false;
}
if (this.damage == 30) {
cost = 250;
this.gotoAndStop("redWeaponUpgrade02");
}
if (this.damage == 75) {
cost = 1500;
this.gotoAndStop("redWeaponUpgrade03");
}
if (lastChecked >= rate) {
lastChecked = 0;
if (target == 0) {
i = 0;
while (i <= _root.creepArray.length) {
d = Math.sqrt(Math.pow(this._x - _root.creepArray[i]._x, 2) + Math.pow(this._y - _root.creepArray[i]._y, 2));
if (d < range) {
target = 1;
creep = _root.creepArray[i];
break;
}
i++;
}
} else if (("" + creep) == "") {
target = 0;
} else {
d = Math.sqrt(Math.pow(this._x - creep._x, 2) + Math.pow(this._y - creep._y, 2));
if (d > range) {
lastChecked = 999;
target = 0;
} else {
_rotation = ((Math.atan2(creep._y - this._y, creep._x - this._x) * 180) / 3.141593);
if (this.damage == 15) {
_root.fire(this, creep, 10, 1, 10, "projectile_fire", damage, splash, slow, poison);
this.redMinionAttackOne.gotoAndPlay("Attack");
creep.fire.gotoAndPlay(2);
}
if (this.damage == 30) {
_root.fire(this, creep, 10, 1, 10, "projectile_fire", damage, splash, slow, poison);
this.redMinionAttackTwo.gotoAndPlay("Attack");
creep.fire.gotoAndPlay(2);
}
if (this.damage == 75) {
_root.fire(this, creep, 10, 1, 10, "projectile_fire", damage, splash, slow, poison);
this.redMinionAttackThree.gotoAndPlay("Attack");
creep.fire.gotoAndPlay(2);
}
}
}
}
}
}
Instance of Symbol 395 MovieClip "tower_water" in Frame 12
onClipEvent (load) {
title = "WaterTower [Cost: $30]";
desc = "Fast attack speed with low damage and low range, but can cause nearby enemies to slow and can be upgraded to do splash damage";
type = "Ground + Splash + Slow";
_root.sellButton.sellButtonText.text = "Sell for $25";
cost = 50;
range = 80;
rate = 40;
lastFire = rate;
lastChecked = rate;
creep = "";
target = 0;
damage = 5;
splash = 70;
slow = 50;
poison = 0;
level = 1;
upgrades = [["Damage: 5\rRange: 80\rSplash:Yes\rSlow:Yes\rPoison:No\r", 300, 25, 100, 45, 90, 60, 20], ["Damage: 10\rRange: 80\rSplash:Yes\rSlow:Yes\rPoison:No\r", 750, 35, 150, 35, 120, 70, 20], ["Damage: 16\rRange: 80\rSplash:Yes\rSlow:Yes\rPoison:No\r", 900999090, 16, 80, 2, 30, 65, 0], ["Damage: 25\rRange: 80\rSplash:Yes\rSlow:Yes\rPoison:No\r", 990909090, 25, 80, 2, 40, 70, 0]];
}
on (press) {
_root.towerInfo(this);
_root.sellButton._visible = true;
if (this.cost == 50) {
_root.sellButton.sellButtonText.text = "Sell for $25";
_parent.info_message.title.text = "Blue Minion Water Puddle";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $50";
_parent.info_message.attackType.text = "Slows down villagers ";
_parent.info_message.type.text = "Damage: Low";
_parent.info_message._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = true;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
if (this.cost == 300) {
_root.sellButton.sellButtonText.text = "Sell for $150";
_parent.info_message.title.text = "Blue Minion Poison Splash";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $300";
_parent.info_message.attackType.text = "Slows down a group of villagers";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = true;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
if (this.cost == 750) {
_root.sellButton.sellButtonText.text = "Sell for $325";
_parent.info_message.title.text = "Blue Minion Ice Blast";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $750";
_parent.info_message.attackType.text = "Slows down large group of villagers. One time use";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = true;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
}
onClipEvent (enterFrame) {
if ((active == 1) && (_root.creepArray.length > 0)) {
lastChecked++;
if (this.damage == 5) {
cost = 50;
blueWeaponLevel1 = false;
}
if (this.damage == 25) {
cost = 300;
this.gotoAndStop("blueWeaponUpgrade02");
}
if (this.damage == 35) {
cost = 750;
this.gotoAndStop("blueWeaponUpgrade03");
}
if (lastChecked >= rate) {
lastChecked = 0;
if (target == 0) {
i = 0;
while (i <= _root.creepArray.length) {
d = Math.sqrt(Math.pow(this._x - _root.creepArray[i]._x, 2) + Math.pow(this._y - _root.creepArray[i]._y, 2));
if (d < range) {
target = 1;
creep = _root.creepArray[i];
break;
}
i++;
}
} else if (("" + creep) == "") {
target = 0;
} else {
d = Math.sqrt(Math.pow(this._x - creep._x, 2) + Math.pow(this._y - creep._y, 2));
if (d > range) {
lastChecked = 999;
target = 0;
} else {
_rotation = ((Math.atan2(creep._y - this._y, creep._x - this._x) * 180) / 3.141593);
if (this.damage == 5) {
_rotation = ((Math.atan2(creep._y - this._y, creep._x - this._x) * 180) / 3.141593);
_root.fire(this, creep, 10, 1, 10, "projectile_water", damage, splash, slow);
this.blueMinionAttackOne.gotoAndPlay("Attack");
}
if (this.damage == 25) {
_rotation = ((Math.atan2(creep._y - this._y, creep._x - this._x) * 180) / 3.141593);
_root.fire(this, creep, 10, 1, 10, "projectile_water", damage, splash, slow);
this.blueMinionAttackTwo.gotoAndPlay("Attack");
}
if (this.damage == 35) {
_root.fire(this, creep, 10, 1, 10, "projectile_water", damage, splash, slow);
this._rotation = -90;
this._xscale = -90;
this._yscale = -90;
this.blueMinionAttackThree.play();
}
}
}
}
}
}
Instance of Symbol 428 MovieClip "tower_poison" in Frame 12
onClipEvent (load) {
title = "Poison Tower [Cost: $25]";
desc = "Fast attack speed with medium damage and low range, but can cause residual poison damage";
type = "Ground + Poison";
_root.sellButton.sellButtonText.text = "Sell for $30";
cost = 60;
range = 70;
rate = 20;
lastFire = rate;
lastChecked = rate;
creep = "";
target = 0;
damage = 18;
splash = 0;
slow = 0;
poison = 3;
level = 1;
upgrades = [["Damage: 2\rRange: 80\rSplash:No\rSlow:No\rPoison:Yes\r", 320, 38, 75, 20, 0, 0, 5], ["Damage: 3\rRange: 80\rSplash:No\rSlow:No\rPoison:Yes\r", 4000, 40000, 500, 60, 800, 0, 0], ["Damage: 4\rRange: 80\rSplash:No\rSlow:No\rPoison:Yes\r", 50060, 4, 80, 8, 0, 9], ["Damage: 5\rRange: 80\rSplash:Yes\rSlow:No\rPoison:Yes\r", 689898, 5, 80, 8, 0, 11]];
}
on (press) {
_root.towerInfo(this);
_root.sellButton._visible = true;
if (this.cost == 60) {
_root.sellButton.sellButtonText.text = "Sell for $30";
_parent.info_message.title.text = "Green Minion Claw Slash";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $60";
_parent.info_message.attackType.text = "Attacks villager twice ";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = true;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
if (this.cost == 320) {
_root.sellButton.sellButtonText.text = "Sell for $160";
_parent.info_message.title.text = "Green Minion Spin Splash";
_parent.info_message.desc.text = "Speed: Medium";
_parent.info_message.costMoney.text = "Cost: $320";
_parent.info_message.attackType.text = "Affects multiple villagers inside range";
_parent.info_message.type.text = "Damage: Strong";
_parent.info_message._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon11._visible = true;
_root.infoIcon12._visible = false;
}
if (this.cost == 4000) {
_root.sellButton.sellButtonText.text = "Sell for $2000";
_parent.info_message.title.text = "Green Minion Atomic Bomb";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $4000";
_parent.info_message.attackType.text = "Wipes out majority of villagers. One time use";
_parent.info_message.type.text = "Damage: Strong";
_parent.info_message._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon11._visible = false;
_root.infoIcon12._visible = true;
}
}
onClipEvent (enterFrame) {
if ((active == 1) && (_root.creepArray.length > 0)) {
lastChecked++;
if (this.damage == 18) {
redWeaponLevel1 = false;
cost = 60;
}
if (this.damage == 38) {
this.gotoAndStop("greenWeaponUpgrade02");
cost = 320;
}
if (this.damage == 40000) {
cost = 4000;
this.gotoAndStop("greenWeaponUpgrade03");
}
if (lastChecked >= rate) {
lastChecked = 0;
if (target == 0) {
i = 0;
while (i <= _root.creepArray.length) {
d = Math.sqrt(Math.pow(this._x - _root.creepArray[i]._x, 2) + Math.pow(this._y - _root.creepArray[i]._y, 2));
if (d < range) {
target = 1;
creep = _root.creepArray[i];
break;
}
i++;
}
} else if (("" + creep) == "") {
target = 0;
} else {
d = Math.sqrt(Math.pow(this._x - creep._x, 2) + Math.pow(this._y - creep._y, 2));
if (d > range) {
lastChecked = 999;
target = 0;
} else {
if (this.damage == 18) {
_rotation = ((Math.atan2(creep._y - this._y, creep._x - this._x) * 180) / 3.141593);
_root.fire(this, creep, 10, 1, 10, "projectile_poison", damage, splash, slow, poison);
this.greenMinionAttackOne.gotoAndPlay("Attack");
}
if (this.damage == 38) {
_rotation = ((Math.atan2(creep._y - this._y, creep._x - this._x) * 180) / 3.141593);
_root.fire(this, creep, 10, 1, 10, "projectile_poison", damage, splash, slow, poison);
this.greenMinionAttackTwo.gotoAndPlay("Attack");
}
if (this.damage == 40000) {
this._rotation = -90;
this._xscale = -90;
this._yscale = -90;
this._x = 240;
this._y = 200;
_root.fire(this, creep, 10, 1, 10, "projectile_poison", damage, splash, slow, poison);
this.greenMinionAttackThree.gotoAndPlay("Attack");
}
}
}
}
}
}
Instance of Symbol 452 MovieClip "tower_cannon" in Frame 12
onClipEvent (load) {
title = "Brown Minion w/ Club";
desc = "Speed: Medium";
costMoney = "Cost: $24";
attackType = "Hits a single villager at a time";
type = "Damage: Low";
_root.sellButton.sellButtonText.text = "Sell for $12";
cost = 24;
range = 70;
rate = 12;
lastFire = rate;
lastChecked = rate;
creep = "";
target = 0;
damage = 10;
splash = 0;
slow = 0;
poison = 0;
level = 1;
upgrades = [["Damage: 40\rRange: 120\rSplash:No\rSlow:No\rPoison:No\r", 240, 20, 70, 8, 0, 0, 0], ["Damage: 75\rRange: 120\rSplash:No\rSlow:No\rPoison:No\r", 600, 60, 70, 10, 90, 0, 0], ["Damage: 150\rRange: 120\rSplash:No\rSlow:No\rPoison:No\r", 9999000, 150, 120, 5, 0, 0, 0], ["Damage: 250\rRange: 120\rSplash:Yes\rSlow:No\rPoison:No\r", 989990, 250, 120, 5, 40, 0, 0]];
}
on (press) {
_root.towerInfo(this);
_root.sellButton._visible = true;
if (this.cost == 24) {
_root.sellButton.sellButtonText.text = "Sell for $12";
_parent.info_message.title.text = _root.tower_cannon.title;
_parent.info_message.desc.text = _root.tower_cannon.desc;
_parent.info_message.costMoney.text = _root.tower_cannon.costMoney;
_parent.info_message.attackType.text = _root.tower_cannon.attackType;
_parent.info_message.type.text = _root.tower_cannon.type;
_parent.info_message._visible = true;
_root.infoIcon1._visible = true;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
if (this.cost == 240) {
_root.sellButton.sellButtonText.text = "Sell for $120";
_parent.info_message.title.text = "Brown Minion w/ Sword";
_parent.info_message.desc.text = "Speed: Medium";
_parent.info_message.costMoney.text = "Cost: $240";
_parent.info_message.attackType.text = "Hits a single villager at a time";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = true;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
if (this.cost == 600) {
_root.sellButton.sellButtonText.text = "Sell for $300";
_parent.info_message.title.text = "Brown Minion w/ Mace";
_parent.info_message.desc.text = "Speed: Medium";
_parent.info_message.costMoney.text = "Cost: $600";
_parent.info_message.attackType.text = "Hits multiple villagers at a time";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = true;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
}
onClipEvent (enterFrame) {
if ((active == 1) && (_root.creepArray.length > 0)) {
lastChecked++;
if (this.damage == 10) {
cost = 24;
brownWeaponLevel1 = false;
brownWeaponLevel2 = true;
brownWeaponLevel3 = true;
}
if (this.damage == 20) {
cost = 240;
this.gotoAndStop("brownWeaponUpgrade02");
brownWeaponLevel1 = true;
brownWeaponLevel2 = false;
brownWeaponLevel3 = true;
}
if (this.damage == 60) {
this.gotoAndStop("brownWeaponUpgrade03");
cost = 600;
brownWeaponLevel1 = true;
brownWeaponLevel2 = true;
brownWeaponLevel3 = false;
}
if (lastChecked >= rate) {
lastChecked = 0;
if (target == 0) {
i = 0;
while (i <= _root.creepArray.length) {
d = Math.sqrt(Math.pow(this._x - _root.creepArray[i]._x, 2) + Math.pow(this._y - _root.creepArray[i]._y, 2));
if (d < range) {
target = 1;
creep = _root.creepArray[i];
break;
}
i++;
}
} else if (("" + creep) == "") {
target = 0;
} else {
d = Math.sqrt(Math.pow(this._x - creep._x, 2) + Math.pow(this._y - creep._y, 2));
if (d > range) {
lastChecked = 999;
target = 0;
} else {
_rotation = ((Math.atan2(creep._y - this._y, creep._x - this._x) * 180) / 3.141593);
if (this.damage == 10) {
_root.fire(this, creep, 10, 1, 10, "projectile_cannonball", damage, splash, slow);
this.brownMinionAttackOne.gotoAndPlay("Attack");
}
if (this.damage == 20) {
_root.fire(this, creep, 10, 1, 10, "projectile_cannonball", damage, splash, slow);
this.brownMinionAttackTwo.gotoAndPlay("Attack");
}
if (this.damage == 60) {
_root.fire(this, creep, 10, 1, 10, "projectile_cannonball", damage, splash, slow);
this.brownMinionAttackThree.gotoAndPlay("Attack");
}
}
}
}
}
}
Instance of Symbol 227 MovieClip "icon1Blocker" in Frame 12
onClipEvent (load) {
this.useHandCursor = false;
}
onClipEvent (enterFrame) {
if (_root.money < 24) {
this._visible = true;
} else {
this._visible = false;
}
}
Instance of Symbol 456 MovieClip "icon7Blocker" in Frame 12
onClipEvent (load) {
this.useHandCursor = false;
}
onClipEvent (enterFrame) {
if (_root.money < 50) {
this._visible = true;
} else {
this._visible = false;
}
}
Instance of Symbol 457 MovieClip "icon4Blocker" in Frame 12
onClipEvent (load) {
this.useHandCursor = false;
}
onClipEvent (enterFrame) {
if (_root.money < 49) {
this._visible = true;
} else {
this._visible = false;
}
}
Instance of Symbol 458 MovieClip "icon10Blocker" in Frame 12
onClipEvent (load) {
this.useHandCursor = false;
}
onClipEvent (enterFrame) {
if (_root.money < 60) {
this._visible = true;
} else {
this._visible = false;
}
}
Instance of Symbol 227 MovieClip "icon2upper" in Frame 12
onClipEvent (load) {
this._visible = false;
}
on (rollOver) {
_parent.info_message.title.text = "Brown Minion w/ Sword";
_parent.info_message.desc.text = "Speed: Medium";
_parent.info_message.costMoney.text = "Cost: $240";
_parent.info_message.attackType.text = "Hits a single villager at a time";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
}
on (press) {
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.upgrade();
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = true;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
this._visible = false;
_root.icon2Blocker._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
Instance of Symbol 227 MovieClip "icon3upper" in Frame 12
onClipEvent (load) {
this._visible = false;
}
on (press) {
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.upgrade();
this._visible = false;
_root.icon3Blocker._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = true;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
on (rollOver) {
_parent.info_message.title.text = "Brown Minion w/ Mace";
_parent.info_message.desc.text = "Speed: Medium";
_parent.info_message.costMoney.text = "Cost: $600";
_parent.info_message.attackType.text = "Hits multiple villagers at a time";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
}
Instance of Symbol 227 MovieClip "icon5upper" in Frame 12
onClipEvent (load) {
this._visible = false;
}
on (rollOver) {
_parent.info_message.title.text = "Red Minion Fireball Blast";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $250";
_parent.info_message.attackType.text = "Damage over time to multiple villagers";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
}
on (press) {
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.upgrade();
this._visible = false;
_root.icon5Blocker._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = true;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
Instance of Symbol 227 MovieClip "icon6upper" in Frame 12
onClipEvent (load) {
this._visible = false;
}
on (press) {
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.upgrade();
_root.icon6Blocker._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = true;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
on (rollOver) {
_parent.info_message.title.text = "Red Minion Firewall";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $1500";
_parent.info_message.attackType.text = "Damage over time to multiple villagers";
_parent.info_message.type.text = "Damage: Strong";
_parent.info_message._visible = true;
}
on (rollOut) {
}
Instance of Symbol 227 MovieClip "icon9upper" in Frame 12
onClipEvent (load) {
this._visible = false;
}
on (press) {
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.upgrade();
this._visible = false;
_root.icon9Blocker._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = true;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
on (rollOver) {
_parent.info_message.title.text = "Blue Minion Ice Blast";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $750";
_parent.info_message.attackType.text = "Slows down large group of villagers. One time use. Minion lost after attack";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
}
Instance of Symbol 227 MovieClip "icon11upper" in Frame 12
onClipEvent (load) {
this._visible = false;
}
on (rollOver) {
_parent.info_message.title.text = "Green Minion Spin Splash";
_parent.info_message.desc.text = "Speed: Medium";
_parent.info_message.costMoney.text = "Cost: $320";
_parent.info_message.attackType.text = "Affects multiple villagers inside range";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
}
on (press) {
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.upgrade();
this._visible = false;
_root.icon11Blocker._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = true;
}
Instance of Symbol 227 MovieClip "icon12upper" in Frame 12
onClipEvent (load) {
this._visible = false;
}
on (press) {
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.upgrade();
this._visible = false;
_root.icon12Blocker._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = false;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = true;
_root.infoIcon11._visible = false;
}
on (rollOver) {
_parent.info_message.title.text = "Green Minion Atomic Bomb";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $4000";
_parent.info_message.attackType.text = "Wipes out majority of villagers. One time use";
_parent.info_message.type.text = "Damage: Strong";
_parent.info_message._visible = true;
}
on (rollOut) {
}
Instance of Symbol 227 MovieClip "icon8upper" in Frame 12
onClipEvent (load) {
this._visible = false;
}
on (rollOver) {
_parent.info_message.title.text = "Blue Minion Poison Splash";
_parent.info_message.desc.text = "Speed: Slow";
_parent.info_message.costMoney.text = "Cost: $300";
_parent.info_message.attackType.text = "Slows down a group of villagers";
_parent.info_message.type.text = "Damage: Medium";
_parent.info_message._visible = true;
}
on (rollOut) {
}
on (press) {
_root.sellButton._visible = false;
_parent.info_message._visible = true;
_root.upgrade();
this._visible = false;
_root.icon8Blocker._visible = true;
_root.infoIcon1._visible = false;
_root.infoIcon2._visible = false;
_root.infoIcon3._visible = false;
_root.infoIcon4._visible = false;
_root.infoIcon5._visible = false;
_root.infoIcon6._visible = false;
_root.infoIcon7._visible = false;
_root.infoIcon8._visible = true;
_root.infoIcon9._visible = false;
_root.infoIcon10._visible = false;
_root.infoIcon12._visible = false;
_root.infoIcon11._visible = false;
}
Instance of Symbol 227 MovieClip "icon11Blocker" in Frame 12
/* no clip actions */
Instance of Symbol 227 MovieClip "icon6Blocker" in Frame 12
/* no clip actions */
Instance of Symbol 227 MovieClip "icon9Blocker" in Frame 12
/* no clip actions */
Instance of Symbol 227 MovieClip "icon12Blocker" in Frame 12
/* no clip actions */
Instance of Symbol 460 MovieClip "sellButton" in Frame 12
onClipEvent (load) {
this._visible = false;
}
Instance of Symbol 466 MovieClip "rules" in Frame 12
onClipEvent (load) {
this._visible = false;
}
Frame 13
gotoAndStop ("end");
Frame 22
stop();
minionBand_sound.stop();
_root.waves[_root.wave - 1][3];
_root.wave;
_root.waves[_root.wave - 1][2];
_root.waves[_root.wave - 1][1];
clearInterval(_root[_root.waves[_root.wave - 1][4]]);
clearInterval(_root["spawnInterval" + level]);
clearInterval(_root.spawnInterval0);
clearInterval(_root.spawnInterval1);
clearInterval(_root.spawnInterval2);
clearInterval(_root.spawnInterval3);
clearInterval(_root.spawnInterval4);
clearInterval(_root.spawnInterval5);
clearInterval(_root.spawnInterval6);
clearInterval(_root.spawnInterval7);
clearInterval(_root.spawnInterval8);
clearInterval(_root.spawnInterval9);
clearInterval(_root.spawnInterval10);
clearInterval(_root.spawnInterval11);
clearInterval(_root.spawnInterval12);
clearInterval(_root.spawnInterval13);
clearInterval(_root.spawnInterval14);
clearInterval(_root.spawnInterval15);
clearInterval(_root.spawnInterval16);
clearInterval(_root.spawnInterval17);
clearInterval(_root.spawnInterval18);
clearInterval(_root.spawnInterval19);
clearInterval(_root.spawnInterval20);
clearInterval(_root.spawnInterval21);
clearInterval(_root.spawnInterval22);
clearInterval(_root.spawnInterval23);
clearInterval(_root.spawnInterval24);
clearInterval(_root.spawnInterval25);
clearInterval(_root.spawnInterval26);
clearInterval(_root.spawnInterval27);
clearInterval(_root.spawnInterval28);
clearInterval(_root.spawnInterval29);
clearInterval(_root.spawnInterval30);
clearInterval(_root.spawnInterval31);
clearInterval(_root.spawnInterval32);
clearInterval(_root.spawnInterval33);
clearInterval(_root.spawnInterval34);
clearInterval(_root.spawnInterval35);
clearInterval(_root.spawnInterval36);
clearInterval(_root.spawnInterval37);
clearInterval(_root.spawnInterval38);
clearInterval(_root.spawnInterval39);
clearInterval(_root.spawnInterval40);
clearInterval(_root.spawnInterval41);
clearInterval(_root.spawnInterval42);
clearInterval(_root.spawnInterval43);
clearInterval(_root.spawnInterval44);
clearInterval(_root.spawnInterval45);
clearInterval(_root.spawnInterval46);
clearInterval(_root.spawnInterval47);
clearInterval(_root.spawnInterval48);
clearInterval(_root.spawnInterval49);
clearInterval(_root.spawnInterval50);
clearInterval(_root.spawnInterval51);
clearInterval(_root.spawnInterval52);
clearInterval(_root.spawnInterval53);
clearInterval(_root.spawnInterval54);
clearInterval(_root.spawnInterval55);
clearInterval(_root.spawnInterval56);
clearInterval(_root.spawnInterval57);
clearInterval(_root.spawnInterval58);
clearInterval(_root.spawnInterval59);
clearInterval(_root.spawnInterval60);
clearInterval(_root.spawnInterval61);
clearInterval(_root.spawnInterval62);
clearInterval(_root.spawnInterval63);
clearInterval(_root.spawnInterval64);
clearInterval(_root.spawnInterval65);
clearInterval(_root.spawnInterval66);
clearInterval(_root.spawnInterval67);
clearInterval(_root.spawnInterval68);
clearInterval(_root.spawnInterval69);
clearInterval(_root.spawnInterval70);
clearInterval(_root.spawnInterval71);
clearInterval(_root.spawnInterval72);
clearInterval(_root.spawnInterval73);
clearInterval(_root.spawnInterval74);
clearInterval(_root.spawnInterval75);
clearInterval(_root.spawnInterval76);
clearInterval(_root.spawnInterval77);
clearInterval(_root.spawnInterval78);
clearInterval(_root.spawnInterval79);
clearInterval(_root.spawnInterval80);
clearInterval(_root.spawnInterval81);
clearInterval(_root.spawnInterval82);
clearInterval(_root.spawnInterval83);
clearInterval(_root.spawnInterval84);
clearInterval(_root.spawnInterval85);
clearInterval(_root.spawnInterval86);
clearInterval(_root.spawnInterval87);
clearInterval(_root.spawnInterval88);
clearInterval(_root.spawnInterval89);
clearInterval(_root.spawnInterval90);
clearInterval(_root.spawnInterval91);
clearInterval(_root.spawnInterval92);
clearInterval(_root.spawnInterval93);
clearInterval(_root.spawnInterval94);
clearInterval(_root.spawnInterval95);
clearInterval(_root.spawnInterval96);
clearInterval(_root.spawnInterval97);
clearInterval(_root.spawnInterval98);
clearInterval(_root.spawnInterval99);
clearInterval(_root.spawnInterval100);
clearInterval(_root.spawnInterval101);
clearInterval(_root.spawnInterval102);
clearInterval(_root.spawnInterval103);
clearInterval(_root.spawnInterval104);
clearInterval(_root.spawnInterval105);
clearInterval(_root.spawnInterval106);
clearInterval(_root.spawnInterval107);
clearInterval(_root.spawnInterval108);
clearInterval(_root.spawnInterval109);
clearInterval(_root.spawnInterval110);
clearInterval(_root.spawnInterval111);
clearInterval(_root.spawnInterval112);
clearInterval(_root.spawnInterval113);
clearInterval(_root.spawnInterval114);
clearInterval(_root.spawnInterval115);
clearInterval(_root.spawnInterval116);
clearInterval(_root.spawnInterval117);
clearInterval(_root.spawnInterval118);
clearInterval(_root.spawnInterval119);
clearInterval(_root.spawnInterval120);
clearInterval(_root.spawnInterval121);
clearInterval(_root.spawnInterval122);
clearInterval(_root.spawnInterval123);
clearInterval(_root.spawnInterval124);
clearInterval(_root.spawnInterval125);
clearInterval(_root.spawnInterval126);
clearInterval(_root.spawnInterval127);
clearInterval(_root.spawnInterval128);
clearInterval(_root.spawnInterval129);
clearInterval(_root.spawnInterval130);
clearInterval(_root.spawnInterval131);
clearInterval(_root.spawnInterval132);
clearInterval(_root.spawnInterval133);
clearInterval(_root.spawnInterval134);
clearInterval(_root.spawnInterval135);
clearInterval(_root.spawnInterval136);
clearInterval(_root.spawnInterval137);
clearInterval(_root.spawnInterval138);
clearInterval(_root.spawnInterval139);
clearInterval(_root.spawnInterval140);
clearInterval(_root.spawnInterval141);
clearInterval(_root.spawnInterval142);
clearInterval(_root.spawnInterval143);
clearInterval(_root.spawnInterval144);
clearInterval(_root.spawnInterval145);
clearInterval(_root.spawnInterval146);
clearInterval(_root.spawnInterval147);
clearInterval(_root.spawnInterval148);
clearInterval(_root.spawnInterval149);
clearInterval(_root.spawnInterval150);
clearInterval(_root.spawnInterval151);
clearInterval(_root.spawnInterval152);
clearInterval(_root.spawnInterval153);
clearInterval(_root.spawnInterval154);
clearInterval(_root.spawnInterval155);
clearInterval(_root.spawnInterval156);
clearInterval(_root.spawnInterval157);
clearInterval(_root.spawnInterval158);
clearInterval(_root.spawnInterval159);
clearInterval(_root.spawnInterval160);
clearInterval(_root.spawnInterval161);
clearInterval(_root.spawnInterval162);
clearInterval(_root.spawnInterval163);
clearInterval(_root.spawnInterval164);
clearInterval(_root.spawnInterval165);
clearInterval(_root.spawnInterval166);
clearInterval(_root.spawnInterval167);
clearInterval(_root.spawnInterval168);
clearInterval(_root.spawnInterval169);
clearInterval(_root.spawnInterval170);
clearInterval(_root.spawnInterval171);
clearInterval(_root.spawnInterval172);
clearInterval(_root.spawnInterval173);
clearInterval(_root.spawnInterval174);
clearInterval(_root.spawnInterval175);
clearInterval(_root.spawnInterval176);
clearInterval(_root.spawnInterval177);
clearInterval(_root.spawnInterval178);
clearInterval(_root.spawnInterval179);
clearInterval(_root.spawnInterval180);
clearInterval(_root.spawnInterval181);
clearInterval(_root.spawnInterval182);
clearInterval(_root.spawnInterval183);
clearInterval(_root.spawnInterval184);
clearInterval(_root.spawnInterval185);
clearInterval(_root.spawnInterval186);
clearInterval(_root.spawnInterval187);
clearInterval(_root.spawnInterval188);
clearInterval(_root.spawnInterval189);
clearInterval(_root.spawnInterval190);
clearInterval(_root.spawnInterval191);
clearInterval(_root.spawnInterval192);
clearInterval(_root.spawnInterval193);
clearInterval(_root.spawnInterval194);
clearInterval(_root.spawnInterval195);
clearInterval(_root.spawnInterval196);
clearInterval(_root.spawnInterval197);
clearInterval(_root.spawnInterval198);
clearInterval(_root.spawnInterval199);
clearInterval(_root.spawnInterval200);
removeMovieClip("creep1");
Symbol 15 MovieClip [puddle] Frame 1
stop();
Symbol 17 MovieClip Frame 1
stop();
Symbol 85 MovieClip Frame 1
stop();
Symbol 94 MovieClip Frame 1
stop();
Symbol 94 MovieClip Frame 78
stop();
Instance of Symbol 17 MovieClip in Symbol 95 MovieClip [Creep1] Frame 1
onClipEvent (enterFrame) {
if (this.hitTest(_root.flip01)) {
_parent._xscale = -90;
}
if (this.hitTest(_root.flip02)) {
_parent._xscale = 90;
}
if (this.hitTest(_root.flip03)) {
_parent._xscale = -90;
}
if (this.hitTest(_root.flip04)) {
_parent._xscale = 90;
}
if (this.hitTest(_root.ender)) {
_root.health--;
_root.escaped();
bell_sound.start();
}
if (this.hitTest(_root.endScreen)) {
_parent.removeMovieClip();
}
}
Symbol 152 MovieClip Frame 1
stop();
soundON = true;
_root.fireMinionShooting_sound.setVolume(100);
_root.greenMinionAtomicBomb_sound.setVolume(100);
_root.buttonNoises_sound.setVolume(100);
_root.brownMinionClubbing_sound.setVolume(100);
_root.greenMinionSlash.setVolume(100);
_root.blueMinionSplash.setVolume(100);
_root.greenMinionSpinSlash.setVolume(0);
Symbol 152 MovieClip Frame 2
stop();
soundON = false;
if (soundON) {
_root.fireMinionShooting_sound.setVolume(100);
_root.greenMinionAtomicBomb_sound.setVolume(100);
_root.buttonNoises_sound.setVolume(100);
_root.brownMinionClubbing_sound.setVolume(100);
_root.greenMinionSlash.setVolume(100);
_root.greenMinionSpinSlash.setVolume(1000);
_root.blueMinionSplash.setVolume(100);
_root.greenMinionSpinSlash.setVolume(100);
_root.minionBand_sound.setVolume(100);
_root.bell_sound.setVolume(100);
} else {
_root.fireMinionShooting_sound.setVolume(0);
_root.greenMinionAtomicBomb_sound.setVolume(0);
_root.buttonNoises_sound.setVolume(0);
_root.brownMinionClubbing_sound.setVolume(0);
_root.greenMinionSlash.setVolume(0);
_root.greenMinionSpinSlash.setVolume(0);
_root.blueMinionSplash.setVolume(0);
_root.minionBand_sound.setVolume(0);
_root.bell_sound.setVolume(0);
}
Symbol 155 Button
on (press) {
gotoAndPlay ("seeRules");
_root.buttonNoises_sound.start();
}
Symbol 156 Button
on (press) {
gotoAndPlay ("seeRules");
_root.buttonNoises_sound.start();
}
Symbol 157 Button
on (release) {
getURL ("http://www.overlordgame.com", "blank");
}
on (press) {
_root.buttonNoises_sound.start();
}
Symbol 191 MovieClip Frame 2
stop();
Symbol 206 MovieClip Frame 1
stop();
Symbol 232 MovieClip Frame 1
stop();
Symbol 232 MovieClip Frame 2
stop();
Symbol 232 MovieClip Frame 3
stop();
Symbol 278 MovieClip Frame 1
stop();
Instance of Symbol 285 MovieClip "UpgradeButton" in Symbol 287 MovieClip Frame 1
on (press) {
_root.upgrade();
}
Symbol 289 Button
on (release) {
getURL ("http://www.overlordgame.com", "blank");
}
Symbol 298 Button
on (release) {
_root.gotoAndPlay("startGame");
}
on (press) {
_root.buttonNoises_sound.start();
}
Instance of Symbol 305 MovieClip "tl" in Symbol 307 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = ((190 + (_root.wave * 100)) + (_root.count * (100 / _root.maxCount)));
}
Symbol 325 MovieClip Frame 1
stop();
Symbol 325 MovieClip Frame 7
_root.fireMinionShooting_sound.start();
Symbol 333 MovieClip Frame 1
stop();
Symbol 333 MovieClip Frame 6
_root.fireMinionShooting_sound.start();
Symbol 344 MovieClip Frame 1
stop();
Symbol 344 MovieClip Frame 6
_root.fireMinionShooting_sound.start();
Symbol 345 MovieClip Frame 1
stop();
Instance of Symbol 17 MovieClip in Symbol 345 MovieClip Frame 1
onClipEvent (enterFrame) {
if (this.hitTest(_root.endScreen)) {
_parent.removeMovieClip();
}
}
Symbol 345 MovieClip Frame 2
stop();
Symbol 345 MovieClip Frame 3
stop();
Symbol 352 MovieClip Frame 1
stop();
Symbol 352 MovieClip Frame 11
_root.blueMinionSplash_sound.start();
Symbol 352 MovieClip Frame 19
Symbol 369 MovieClip Frame 1
stop();
Symbol 369 MovieClip Frame 9
_root.blueMinionSplash_sound.start();
Symbol 394 MovieClip Frame 1
stop();
Symbol 394 MovieClip Frame 20
_root.fireMinionShooting_sound.start();
Instance of Symbol 17 MovieClip in Symbol 394 MovieClip Frame 51
onClipEvent (load) {
_parent._parent.removeMovieClip();
}
Symbol 395 MovieClip Frame 1
stop();
Instance of Symbol 17 MovieClip in Symbol 395 MovieClip Frame 1
onClipEvent (enterFrame) {
if (this.hitTest(_root.endScreen)) {
_parent.removeMovieClip();
}
}
Symbol 395 MovieClip Frame 2
stop();
Symbol 395 MovieClip Frame 3
stop();
Symbol 408 MovieClip Frame 1
stop();
Symbol 408 MovieClip Frame 12
_root.greenMinionSlash_sound.start();
Symbol 417 MovieClip Frame 1
stop();
Symbol 417 MovieClip Frame 12
_root.greenMinionSpinSlash_sound.start();
Symbol 427 MovieClip Frame 1
stop();
Symbol 427 MovieClip Frame 14
_root.greenMinionAtomicBomb_sound.start();
Symbol 427 MovieClip Frame 46
Instance of Symbol 17 MovieClip in Symbol 427 MovieClip Frame 46
onClipEvent (load) {
_parent._parent.removeMovieClip();
}
Symbol 428 MovieClip Frame 1
stop();
Instance of Symbol 17 MovieClip in Symbol 428 MovieClip Frame 1
onClipEvent (enterFrame) {
if (this.hitTest(_root.endScreen)) {
_parent.removeMovieClip();
}
}
Symbol 428 MovieClip Frame 2
stop();
Symbol 428 MovieClip Frame 3
stop();
Symbol 437 MovieClip Frame 1
stop();
Symbol 437 MovieClip Frame 17
_root.brownMinionClubbing_sound.start();
Symbol 444 MovieClip Frame 1
stop();
Symbol 444 MovieClip Frame 13
_root.greenMinionSlash_sound.start();
Symbol 451 MovieClip Frame 1
stop();
Symbol 451 MovieClip Frame 5
_root.brownMinionClubbing_sound.start();
Symbol 452 MovieClip Frame 1
stop();
Instance of Symbol 17 MovieClip in Symbol 452 MovieClip Frame 1
onClipEvent (enterFrame) {
if (this.hitTest(_root.endScreen)) {
_parent.removeMovieClip();
}
}
Symbol 452 MovieClip Frame 2
stop();
Symbol 452 MovieClip Frame 3
stop();
Symbol 455 MovieClip Frame 1
stop();
Symbol 461 Button
on (press) {
gotoAndPlay ("end");
}
Symbol 462 Button
on (press) {
_root.rules._visible = true;
}
Symbol 463 Button
on (release) {
getURL ("http://www.overlordgame.com", "blank");
}
on (press) {
_root.buttonNoises_sound.start();
}
Symbol 465 Button
on (release) {
this._visible = false;
}
on (press) {
_root.buttonNoises_sound.start();
}
Symbol 475 Button
on (release) {
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;
var pv;
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);
}
pv = ((fv == 5) ? (getVersion()) : (System.capabilities.version));
u = (((((((((((("http://" + mbc) + "/my/core.swf?mv=8&fv=") + fv) + "&v=") + escape(pv)) + "&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);
}
_root.gotoAndPlay("startGame");
__com_mochibot__("a127c31c", this, 10301, true);
}
on (press) {
_root.buttonNoises_sound.start();
}
Symbol 477 Button
on (release) {
getURL ("http://www.overlordgame.com", "blank");
}
on (press) {
_root.buttonNoises_sound.start();
}