Frame 1
function __com_mochibot__(swfid, mc, lv) {
var x;
var g;
var s;
var fv;
var sb;
var u;
var res;
var mb;
var mbc;
mb = "__mochibot__";
mbc = "mochibot.com";
g = (_global ? (_global) : (_level0._root));
if (g[mb + swfid]) {
return(g[mb + swfid]);
}
s = System.security;
x = mc._root.getSWFVersion;
fv = (x ? (mc.getSWFVersion()) : ((_global ? 6 : 5)));
if (!s) {
s = {};
}
sb = s.sandboxType;
if (sb == "localWithFile") {
return(null);
}
x = s.allowDomain;
if (x) {
s.allowDomain(mbc);
}
x = s.allowInsecureDomain;
if (x) {
s.allowInsecureDomain(mbc);
}
u = ((((((((((("http://" + mbc) + "/my/core.swf?mv=5&fv=") + fv) + "&v=") + escape(getVersion())) + "&swfid=") + escape(swfid)) + "&l=") + lv) + "&f=") + mc) + (sb ? ("&sb=" + sb) : "");
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);
}
Stage.showMenu = false;
__com_mochibot__("59b76fba", this, 10301);
function getName(keyCode) {
if (keyCode == 16) {
keyName = "SHIFT";
} else if (keyCode == 37) {
keyName = "LEFT";
} else if (keyCode == 38) {
keyName = "UP";
} else if (keyCode == 39) {
keyName = "RIGHT";
} else if (keyCode == 40) {
keyName = "DOWN";
} else if (keyCode == 13) {
keyName = "ENTER";
} else if (keyCode == 32) {
keyName = "SPACE";
} else if (keyCode == 33) {
keyName = "PAGEUP";
} else if (keyCode == 34) {
keyName = "PAGEDN";
} else if (keyCode == 35) {
keyName = "END";
} else if (keyCode == 36) {
keyName = "HOME";
} else if (keyCode == 45) {
keyName = "INSERT";
} else if (keyCode == 46) {
keyName = "DELETE";
} else if (keyCode == 8) {
keyName = "BACKSPC";
} else if (keyCode == 17) {
keyName = "CTRL";
} else {
keyName = String.fromCharCode(keyCode);
}
return(keyName);
}
boundingBoxColors = [65280, 65280, 65280, 65280, 65280, 65280];
insertCharacterName = "[ ]";
if (keys == undefined) {
keys = [68, 65, 87, 82, 32, 80, 13, 69, 81, 83, 32];
}
if (_root.CHEATS == undefined) {
_root.CHEATS = [["ownitup", "Unlimited Health", false], ["rockedinface", "Unlimited Ammo", false], ["firepower", "All Weapons", false], ["runforrestrun", "Speed", false], ["pwnagesince1337", "Double Damage", false], ["savemejebus", "Low Friction", false]];
_root.motionTrail = false;
}
if (RES == undefined) {
RES = 1;
}
_root.GUISPACE = " ";
mapSize = 40960;
if (DIFFICULTY == undefined) {
DIFFICULTY = "EASY";
_quality = "LOW";
}
if (blur == undefined) {
blur = true;
blurRate = 0.5;
blurVar = 1;
shellblur = true;
}
if (VOLUME_SFX == undefined) {
VOLUME_SFX = 100;
VOLUME_MUSIC = 100;
REAL_VOLUME_SFX = 100;
}
showAreas = false;
showBoundingBoxes = false;
sOffx = 0;
sOffy = 50;
sW = 500;
sH = 600;
if (FPSStability == undefined) {
FPSStability = true;
}
if (blood == undefined) {
blood = "ON";
}
if (mouseTargeting == undefined) {
mouseTargeting = true;
}
Frame 5
stop();
Instance of Symbol 1632 MovieClip "musicPath" in Frame 5
onClipEvent (load) {
newMusic = function (newSong) {
sd = newSong;
music.stop();
this.stopAllSounds();
music = new Sound(this);
music.attachSound(sd);
music.start(0, 999);
music.setVolume(_root.VOLUME_MUSIC);
_root.CURRENTMUSIC = sd;
};
stopAllSounds();
_root.stopAllSounds();
newMusic("audio.TheScheme.mp3");
}
Instance of Symbol 1684 MovieClip "menubox" in Frame 5
onClipEvent (load) {
_root.MENU = true;
swapDepths(300);
}
Frame 6
kRi = keys[0];
kLe = keys[1];
kUp = keys[2];
kDn = keys[9];
kDetonate = keys[3];
kKick = keys[4];
kPause = keys[5];
kQuit = keys[6];
kSwDn = keys[8];
kSwUp = keys[7];
function loadMap(num) {
oX = [];
oY = [];
oTiles = [];
oW = [];
oH = [];
oT = [];
oN = [];
if (VISIBLE == undefined) {
VISIBLE = [];
}
if (BLOCKS == undefined) {
BLOCKS = [];
}
if (BLOCKS_ALL == undefined) {
BLOCKS_ALL = [];
}
map.mapType = num;
_root.trainingText = "";
}
function soundfx(x, name) {
soundeffect = _root.createEmptyMovieClip("soundEffect" + NU_SFX, 9008397 + NU_SFX);
var _local3 = new Sound(soundeffect);
this.pan = (x - _root.iF._x) / 2.5;
if (this.pan > 100) {
volu = this.pan - 100;
this.pan = 100;
} else if (this.pan < -100) {
volu = Math.abs(-100 - this.pan);
this.pan = -100;
} else {
volu = 0;
}
if (volu > _root.VOLUME_SFX) {
volu = _root.VOLUME_SFX;
} else if (volu < (-_root.VOLUME_SFX)) {
volu = -_root.VOLUME_SFX;
}
volu = volu * (Math.abs(_root.VOLUME_SFX) / 100);
_local3.attachSound(name);
_local3.start(0, 0);
_local3.setPan(this.pan);
_local3.setVolume(_root.VOLUME_SFX - volu);
if (NU_SFX < 50) {
NU_SFX++;
} else {
NU_SFX = 0;
}
}
function crObjMC(n) {
var _local5 = scr.createEmptyMovieClip(n, n);
_local5._x = oX[n];
_local5._y = oY[n];
var _local4 = oTiles[n];
var _local3 = _local4.length / 3;
_local5.t = _local4;
_local5.i = _local3;
while (_local3--) {
tellTarget (_local5.attachMovie(_local4[_local3 * 3], _local3, _local3)) {
_x = _local4[(_local3 * 3) + 1];
_y = _local4[(_local3 * 3) + 2];
};
}
if ((oT[n] == "block") || (oT[n] == "barrel")) {
BLOCKS.push(_local5);
}
nOfVisObj++;
VISIBLE.push(n);
tellTarget (_local5) {
eL = _x;
eR = _x + _width;
eT = _y;
eB = _y + _height;
};
_local5.PLACE = n;
pL = _root.player;
_local5.num = oN[n];
if (((oT[n] == "platform") || (oT[n] == "block")) || (oT[n] == "barrel")) {
_local5.onEnterFrame = function () {
if (oT[this._name] == "platform") {
if ((_root.KILLS >= this.num) || (this.num == undefined)) {
this.RUN = true;
} else {
this.RUN = false;
}
} else if (this.num >= 0) {
this.RUN = true;
} else {
this.RUN = false;
reda(BLOCKS, this);
reda(BLOCKS_ALL, this.PLACE);
if (oT[this._name] == "block") {
_root.soundfx(this._x, "audio.blockBreak0.wav");
omg = 0;
while (omg < 10) {
block = _root.attachMovie("mc.barrelDebris" + random(3), "blockParticle" + ((this.PLACE * 10) + omg), 497345 + ((this.PLACE * 10) + omg));
block.vx = (random(31) - 15) / 10;
block.vy = -5 - (random(20) / 10);
block._x = this._x + (this._width / 2);
block._y = this._y + (this._height / 2);
block.s = (5 + random(5)) / 10;
block._xscale = block._xscale * block.s;
block._yscale = block._yscale * block.s;
block.rot = -20 + random(40);
block.onEnterFrame = function () {
if (_root.paused != true) {
this.vy = this.vy + 0.35;
this._x = this._x + this.vx;
this._y = this._y + this.vy;
this._rotation = this._rotation + this.rot;
if (this._alpha > 0) {
this._alpha = this._alpha - 2;
} else {
removeMovieClip(this);
}
}
};
omg++;
}
} else {
_root.soundfx(this._x, ("audio.explode" + random(3)) + ".wav");
block = _root.attachMovie("mc.barrelExplosion", "blockParticle" + ((this.PLACE * 10) + 1), 497345 + ((this.PLACE * 10) + 1));
block._x = this._x + (this._width / 2);
block._y = this._y + (this._height / 2);
block.s = (110 - random(21)) / 100;
block._xscale = block._xscale * block.s;
block._yscale = block._yscale * block.s;
if (random(2) == 0) {
block._xscale = block._xscale * -1;
}
}
_root.BLOCKS_DESTROYED++;
this.removeMovieClip(this);
}
if (this.RUN) {
if (((pL._x + pL.vx) >= this.eL) && ((pL._x + pL.vx) <= this.eR)) {
if ((((pL._y + pL.vy) + pL.eS_y) >= this.eT) && (pL._y < this.eT)) {
pL._y = this.eT - pL.eS_y;
_root.pW._y = _root.pW._y + pL.vy;
pL.vy = 0;
pL.onGround = true;
pL.onGroundTimer = 0;
pL._rotation = 0;
_root.pS._rotation = 0;
} else if ((((pL._y + pL.vy) - pL.eS_y) <= this.eB) && (pL._y > this.eB)) {
pL._y = this.eB + pL.eS_y;
pL.vy = 0;
}
}
if (((pL._y + pL.vy) >= this.eT) && ((pL._y + pL.vy) <= this.eB)) {
if ((((pL._x + pL.vx) + pL.eS_x) >= this.eL) && (pL._x < this.eL)) {
pL._x = this.eL - pL.eS_x;
pL.vx = 0;
} else if ((((pL._x + pL.vx) - pL.eS_x) <= this.eR) && (pL._x > this.eR)) {
pL._x = this.eR + pL.eS_x;
pL.vx = 0;
}
}
}
};
} else if ((oT[n] == "30_60_90Triangle_R") || (oT[n] == "30_60_90Triangle_L")) {
_local5.onEnterFrame = function () {
if (_root.paused != true) {
this.old_vx = pL.vx;
this.old_vy = pL.vy;
if (oT[this._name] == "30_60_90Triangle_R") {
if (this.hitTest(pL.eR, pL.eB, true)) {
pL.vy = (-pL.vx) / 2;
_root.pS._rotation = -25;
pL._rotation = -25;
}
if (((pL._y + pL.vy) >= this.eT) && ((pL._y + pL.vy) <= this.eB)) {
if ((((pL._x + pL.vx) - pL.eS_x) <= this.eR) && (pL._x > this.eR)) {
pL._x = this.eR + pL.eS_x;
pL.vx = 0;
}
}
} else {
if (this.hitTest(pL.eL, pL.eB, true)) {
pL.vy = pL.vx / 2;
_root.pS._rotation = 25;
pL._rotation = 25;
}
if (((pL._y + pL.vy) >= this.eT) && ((pL._y + pL.vy) <= this.eB)) {
if ((((pL._x + pL.vx) + pL.eS_x) >= this.eL) && (pL._x < this.eL)) {
pL._x = this.eL - pL.eS_x;
pL.vx = 0;
}
}
}
if (this.hitTest(pL.eR, pL.eB, true) || (this.hitTest(pL.eL, pL.eB, true))) {
while (this.hitTest(pL.eR, pL._y + 33, true) || (this.hitTest(pL.eL, pL._y + 33, true))) {
pL._y = pL._y - _root.GRAVITY;
}
if ((_root.paused != true) && (_root.inTurret == false)) {
pL.onGround = true;
pL.onGroundTimer = 0;
pL._y = pL._y - _root.GRAVITY;
pL.onSlope = pL.onSlope + 4.5;
if (pL.onSlope > 5) {
pL.onSlope = 5;
}
}
} else if (pL.onSlope == 0) {
_root.pS._rotation = 0;
pL._rotation = 0;
}
if (Math.abs(pL.vy) < 0.2) {
pL.vy = 0;
}
if (Math.abs(pL.vx) < 0.2) {
pL.vx = 0;
}
}
};
} else if (oT[n] == "booster") {
_local5.onEnterFrame = function () {
if ((_root.KILLS >= this.num) || (this.num == undefined)) {
this._visible = true;
if (((pL._x + pL.vx) >= this.eL) && ((pL._x + pL.vx) <= this.eR)) {
if ((((pL._y + pL.vy) + pL.eS_y) >= this.eT) && (pL._y < this.eT)) {
pL._y = this.eT - pL.eS_y;
pL.vy = -30;
pL.yBlur = 30;
pW.yBlur = 30;
}
}
} else {
this._visible = false;
}
};
} else if (oT[n] == "boosterRight") {
_local5.onEnterFrame = function () {
if ((_root.KILLS >= this.num) || (this.num == undefined)) {
this._visible = true;
if (((pL._x + pL.vx) >= this.eL) && ((pL._x + pL.vx) <= this.eR)) {
if ((((pL._y + pL.vy) + pL.eS_y) >= this.eT) && (pL._y < this.eT)) {
pL._y = this.eT - pL.eS_y;
pL.vy = -30;
pL.vx = 20;
pL.yBlur = 30;
pW.yBlur = 30;
}
}
} else {
this._visible = false;
}
};
}
}
function dr() {
var _local4 = int(xPos);
var _local3 = int(yPos);
var _local2 = int(_local4 / sW);
var _local1 = int(_local3 / sH);
if ((_local2 == oldax) && (_local1 == olday)) {
for (var _local11 in scr) {
if (!oV[_local11]) {
if ((oT[_local11] == "block") || (oT[_local11] == "barrel")) {
reda(BLOCKS, scr[_local11]);
}
removeMovieClip(scr[_local11]);
nOfVisObj--;
tr = 0;
while (tr < VISIBLE.length) {
if (_local11 == VISIBLE[tr]) {
b = tr;
while (b < VISIBLE.length) {
VISIBLE[b] = VISIBLE[b + 1];
b++;
}
break;
}
tr++;
}
VISIBLE.pop();
break;
}
}
} else {
oldax = _local2;
olday = _local1;
ar = [];
for (var _local11 in a[_local2][_local1]) {
ar[_local11] = true;
}
for (var _local11 in a[_local2 + 1][_local1]) {
ar[_local11] = true;
}
for (var _local11 in a[_local2][_local1 + 1]) {
ar[_local11] = true;
}
for (var _local11 in a[_local2 + 1][_local1 + 1]) {
ar[_local11] = true;
}
}
scr._x = sOffx - _local4;
scr._y = sOffy - _local3;
var _local8 = oX;
var _local6 = oY;
var _local7 = oX_oW;
var _local5 = oY_oH;
var _local10 = _local4 + sW;
var _local9 = _local3 + sH;
oV = [];
for (var _local11 in ar) {
if (_local7[_local11] > _local4) {
if (_local8[_local11] < _local10) {
if (_local5[_local11] > _local3) {
if (_local6[_local11] < _local9) {
if (oW[_local11] != undefined) {
oV[_local11] = true;
if (!scr[_local11]) {
if (!(((oT[_local11] == "block") || (oT[_local11] == "barrel")) && (oN[_local11] <= 0))) {
crObjMC(_local11);
}
}
} else {
oV[_local11] = false;
}
}
}
}
}
}
}
function mapInit() {
iF = attachMovie("mc.iF", "iF", 1000000);
if (MAPNUMBER == 2) {
iF._x = 250;
iF._y = -400;
} else {
iF._x = 250;
iF._x = 534;
}
iFr = attachMovie("mc.iF_resolutionScreen", "iFr", 1000001);
iFr._x = iF._x;
iFr._y = iF._y;
noo = oX.length;
oldax = null;
olday = null;
xPos = -10;
yPos = -10;
vx = 0;
vy = 0;
ticks = 0;
oX_oW = [];
oY_oH = [];
if (nOfVisObj == undefined) {
nOfVisObj = 0;
} else {
nOfVisObj = nOfVisObj;
}
var _local1 = 0;
while (_local1 < noo) {
oX_oW[_local1] = oX[_local1] + oW[_local1];
oY_oH[_local1] = oY[_local1] + oH[_local1];
_local1++;
}
registerObjectsToAreas();
areaLineHMC._x = sOffx;
areaLineHMC._width = sW;
areaLineVMC._y = sOffy;
areaLineVMC._height = sH;
removeMovieClip("loadScreen");
startEngine();
}
function clearAll() {
a = 0;
while (a < 100) {
removeMovieClip(_root["g" + a]);
removeMovieClip(_root["gH" + a]);
removeMovieClip(_root["z" + a]);
removeMovieClip(_root["zH" + a]);
removeMovieClip(_root["f" + a]);
removeMovieClip(_root["fH" + a]);
removeMovieClip(_root["kn" + a]);
removeMovieClip(_root["knH" + a]);
removeMovieClip(_root["pu" + a]);
removeMovieClip(_root["ln" + a]);
removeMovieClip(_root["sh" + a]);
removeMovieClip(_root["playerTrail" + a]);
removeMovieClip(_root["pWTrail" + a]);
a++;
}
a = 0;
while (a < 20) {
removeMovieClip(_root["generateWeapon" + a]);
removeMovieClip(_root["cannonBall" + a]);
removeMovieClip(_root["explosion" + a]);
a++;
}
a = 0;
while (a < 500) {
removeMovieClip(_root["nadeTrail" + a]);
removeMovieClip(_root["b" + a]);
removeMovieClip(_root["explosionStinger" + (896732 + a)]);
removeMovieClip(_root["explosionStinger" + (543937 + a)]);
removeMovieClip(_root["explosionStinger" + (898432 + a)]);
removeMovieClip(_root["soundEffect" + a]);
removeMovieClip(_root["gB" + a]);
removeMovieClip(_root["frag" + a]);
a++;
}
a = 0;
while (a < 10000) {
removeMovieClip(_root["blockParticle" + a]);
a++;
}
for (var _local2 in scr) {
removeMovieClip(scr[_local2]);
}
for (var _local2 in ar) {
removeMovieClip(ar[_local2]);
}
ar = [];
scr.Clear();
ar.Clear();
MENU = true;
_root.VISIBLE = [];
_root.grunts = [];
_root.zombies = [];
_root.frogs = [];
_root.knights = [];
MINES = [];
BLOCKS = [];
BLOCKS_ALL = [];
BLOCKS_DESTROYED = 0;
removeMovieClip(turret0);
removeMovieClip(gBoss);
removeMovieClip(rBoss);
removeMovieClip(rBossT);
removeMovieClip(rBossS);
iF.resetStage();
removeMovieClip(iF);
removeMovieClip(iFr);
removeMovieClip(player);
removeMovieClip(chubbs);
updateNL();
if (NL) {
removeMovieClip(pW);
}
}
function reset() {
clearAll();
wS = _root.attachMovie("mc.loadScreen", "loadScreen", 1);
wS._x = 250;
wS._y = 250;
T = getTimer();
if (MAPNUMBER == OLDMAPNUMBER) {
poop = 0;
while (poop < LEVELAMMO.length) {
_root["AMMO_" + weapons[poop]] = LEVELAMMO[poop];
poop++;
}
}
LEVELAMMO = [AMMO_usp, AMMO_mac10, AMMO_mp5, AMMO_assaultRifle, AMMO_machineGun, AMMO_m4, AMMO_shotGun, AMMO_flakCannon, AMMO_sniperRifle, AMMO_stinger, AMMO_nade, AMMO_mine];
gotoAndPlay ("Start");
}
function quit() {
clearAll();
gotoAndStop ("Menu");
}
function selectWI(num) {
_root.iF.weaponName = ("<b>weapon type:</b>" + _root.GUISPACE) + getWeaponName(weapons[num]);
if (num < 2) {
similars = [0, 1];
} else if (num < 6) {
similars = [2, 3, 4, 5];
} else if (num < 8) {
similars = [6, 7];
} else if (num < 12) {
similars = [8, 9, 10, 11];
}
wt = 0;
while (wt < weapons.length) {
_root.iF["wi_" + wt]._visible = false;
_root.iF["wi_" + wt]._alpha = 0;
wt++;
}
_root.iF["wi_" + num]._visible = true;
_root.iF["wi_" + num].timer = 100;
for (simNum in similars) {
if (_root["AMMO_" + weapons[similars[simNum]]] > 0) {
_root.iF["wi_" + similars[simNum]]._visible = true;
_root.iF["wi_" + similars[simNum]]._alpha = 100;
_root.iF["wi_" + similars[simNum]].timer = 100;
} else {
_root.iF["wi_" + similars[simNum]]._visible = true;
_root.iF["wi_" + similars[simNum]]._alpha = 50;
_root.iF["wi_" + similars[simNum]].timer = 100;
}
}
updateONS();
}
function tickMain() {
if ((Key.isDown(kDetonate) && (splodeInterval == undefined)) && (_root.MINES.length > 0)) {
_root.soundfx(iF._x, "audio.mineBeep.wav");
splode = function () {
am = 0;
while (am < MINES.length) {
if (MINES[am].detonate != undefined) {
MINES[am].detonate();
reda(MINES, MINES[am]);
}
am++;
}
clearInterval(splodeInterval);
splodeInterval = undefined;
};
splodeInterval = setInterval(splode, 35);
}
if (paused != true) {
if (Key.isDown(kQuit)) {
quit();
}
if (MODE_BERSERK > 0) {
iF.berserkScreen._visible = true;
iF.berserkScreen._alpha = 100;
iF.cS_x = iF.cS_x + (random(10) - 5);
iF.cS_y = iF.cS_y + (random(10) - 5);
var _local2 = new flash.filters.BlurFilter(10, 0, 3);
MODE_BERSERK--;
} else {
iF.berserkScreen._visible = false;
}
xPos = _root.iF._x - ((_root.iF._width / 1.1) / 2);
yPos = _root.iF._y - ((_root.iF._height / 1.1) / 2);
sOffx = iF._x - ((iF._width / 1.1) / 2);
sOffy = iF._y - ((iF._height / 1.1) / 2);
dr();
ticks++;
if ((_root.rBoss.dying != true) && (_root.gBoss.dying != true)) {
if (pW.type != "turret") {
if (Key.isDown(kSwUp)) {
if (kSwUp_isDown == false) {
w = 0;
while (w < (weapons.length + 1)) {
if (wpNum < (weapons.length - 1)) {
wpNum = int(wpNum) + 1;
} else {
wpNum = 0;
}
if (_root["AMMO_" + weapons[wpNum]] > 0) {
pW.init(player, weapons[wpNum], false);
selectWI(wpNum);
break;
}
w++;
}
}
kSwUp_isDown = true;
} else {
kSwUp_isDown = false;
}
if (Key.isDown(kSwDn)) {
if (kSwDn_isDown == false) {
w = 0;
while (w < (weapons.length + 1)) {
if (wpNum > 0) {
wpNum = wpNum - 1;
} else {
wpNum = weapons.length - 1;
}
if (_root["AMMO_" + weapons[wpNum]] > 0) {
pW.init(player, weapons[wpNum], false);
selectWI(wpNum);
break;
}
w++;
}
}
kSwDn_isDown = true;
} else {
kSwDn_isDown = false;
}
}
}
iF.pausedScreen._visible = false;
iF.pausedScreen.gotoAndStop(1);
} else if (iF.pausedScreen._visible != true) {
if (((_root.map.TTM.targetTimer == 0) || (_root.map.TTM.targetTimer == 101)) || (_root.map.TTM.targetTimer == undefined)) {
if ((_root.player.health > 0) && (_root.player._y < 1000)) {
if (!(((_root.gBoss.targeted == false) && (_root.gBoss.hostile == true)) && (_root.gBoss.targetTimer <= 100))) {
if (!(((_root.rBoss.targeted == false) && (_root.rBoss.hostile == true)) && (_root.rBoss.targetTimer <= 100))) {
iF.pausedScreen._visible = true;
iF.pausedScreen.play();
}
}
}
}
}
}
function oncePerSecond() {
if (paused != true) {
FPS = ticks - oldticks;
if (FPS > 30) {
FPS = 30;
}
fpsText = (("<b>fps:</b>" + _root.GUISPACE) + FPS) + " / 30";
oldticks = ticks;
}
}
function registerObjectsToAreas() {
if (!((sW > 0) && (sH > 0))) {
trace("registerObjectsToAreas() failed:");
trace("Screen dimensions (sW, sH) not defined!");
return(undefined);
}
a = [];
var _local6 = Math.max;
var _local3 = 0;
while (_local3 < noo) {
var _local8 = _local6(int(oX[_local3] / sW), 0);
var _local5 = _local6(int(oY[_local3] / sH), 0);
var _local7 = _local6(int(oX_oW[_local3] / sW), 0);
var _local4 = _local6(int(oY_oH[_local3] / sH), 0);
var _local1 = _local8;
while (_local1 <= _local7) {
var _local2 = _local5;
while (_local2 <= _local4) {
if (a[_local1] == undefined) {
a[_local1] = [];
}
if (a[_local1][_local2] == undefined) {
a[_local1][_local2] = [];
}
a[_local1][_local2][_local3] = true;
_local2++;
}
_local1++;
}
_local3++;
}
}
function startEngine() {
iF.trgt = _root.player;
iF.fadeScreen._alpha = 100;
iF.fadeScreen.fade = "out";
_root.iF.weaponName = ("<b>weapon type:</b>" + _root.GUISPACE) + getWeaponName(weapons[num]);
weapons = ["usp", "mac10", "mp5", "assaultRifle", "machineGun", "m4", "shotGun", "flakCannon", "sniperRifle", "stinger", "nade", "mine"];
wpNum = 0;
var _local4 = false;
var _local3 = false;
this.onEnterFrame = tickMain;
if (oncePerSecondInterval == undefined) {
oncePerSecondInterval = setInterval(oncePerSecond, 1000);
}
}
wS = attachMovie("mc.loadScreen", "loadScreen", 1);
wS._x = 250;
wS._y = 250;
Array.prototype.Clear = function () {
this.length = 0;
var _local2;
for (_local2 in this) {
delete this[_local2];
}
};
makeBlood = function (x, y, rot, id, bc) {
RAND = random(3);
bloodType = "blood_" + RAND;
bs = attachMovie(bloodType, ("bs" + bc) + (id * 10), (58000 + bc) + (id * 10));
if (this.RAND == 0) {
bs._yscale = 40;
if (random(2) == 0) {
bs._xscale = 40;
} else {
bs._xscale = -40;
}
} else {
bs._rotation = rot;
bs._xscale = -50;
if ((Math.abs(bs._rotation) > 90) && (Math.abs(bs._rotation) < 270)) {
bs._yscale = -50;
} else {
bs._yscale = 50;
}
}
bs._x = x;
bs._y = y;
return(bs);
};
checkForBlocks = function (object, damg, plc, sf) {
numb = 0;
while (numb < _root.BLOCKS_ALL.length) {
CCB = _root.BLOCKS_ALL[numb];
if (sf != undefined) {
ob = object._parent;
} else {
ob = object;
ob.WID = 0;
}
if (Math.abs((oY[CCB] + (oH[CCB] / 2)) - ob._y) < 50) {
if (ob._x > _root.oX[CCB]) {
PTA = ob._x - ob.WID;
PTB = _root.oX[CCB] + _root.oW[CCB];
} else {
PTB = ob._x + ob.WID;
PTA = _root.oX[CCB];
}
if ((PTA - PTB) < 5) {
cudam = damg;
_root.oN[CCB] = _root.oN[CCB] - cudam;
DEFINE = false;
asdfg = 0;
while (asdfg < _root.BLOCKS.length) {
if (_root.BLOCKS[asdfg].PLACE == CCB) {
_root.BLOCKS[asdfg].num = _root.BLOCKS[asdfg].num - cudam;
DEFINE = true;
break;
}
asdfg++;
}
if (_root.oN[CCB] <= 0) {
if (!DEFINE) {
reda(_root.BLOCKS_ALL, CCB);
_root.BLOCKS_DESTROYED++;
_root.soundfx(_root.oX[CCB], "audio.blockBreak0.wav");
}
}
_root.soundfx(plc, sf);
if (sf == undefined) {
removeMovieClip(ob);
}
break;
}
}
numb++;
}
};
NU_SFX = 0;
ALL_SFX = 0;
reda = function (array, ob) {
asdf = 0;
while (asdf < array.length) {
if (ob == array[asdf]) {
hjkl = asdf;
while (hjkl < array.length) {
array[hjkl] = array[hjkl + 1];
hjkl++;
}
break;
}
asdf++;
}
array.pop();
};
function generate16x128Object(x, y) {
oX.push(x);
oY.push(y);
oTiles.push([4, 16, 64, 4, 16, 128]);
oW.push(16);
oH.push(128);
oT.push("platform");
oN.push(0);
}
function generate48x32Object(x, y) {
oX.push(x);
oY.push(y);
oTiles.push([1, 16, 16, 1, 32, 16, 1, 16, 32, 1, 32, 32, 1, 48, 16, 1, 48, 32]);
oW.push(48);
oH.push(32);
oT.push("platform");
oN.push(num);
}
function generate128x64Object(x, y) {
oX.push(x);
oY.push(y);
oTiles.push([5, 64, 64, 5, 128, 64]);
oW.push(128);
oH.push(64);
oT.push("platform");
oN.push(num);
}
function generate128x16Object(x, y, num) {
oX.push(x);
oY.push(y);
oTiles.push([3, 64, 16, 3, 128, 16]);
oW.push(128);
oH.push(16);
oT.push("platform");
oN.push(num);
}
function generate64x64Object(x, y) {
oX.push(x);
oY.push(y);
oTiles.push([2, 32, 32, 2, 32, 64, 2, 64, 32, 2, 64, 64]);
oW.push(64);
oH.push(64);
oT.push("platform");
oN.push(num);
}
function generate128x128Object(x, y) {
oX.push(x);
oY.push(y);
oTiles.push([5, 64, 64, 5, 64, 128, 5, 128, 64, 5, 128, 128]);
oW.push(128);
oH.push(128);
oT.push("platform");
oN.push(num);
}
function generate32x32Object(x, y) {
oX.push(x);
oY.push(y);
oTiles.push([2, 32, 32]);
oW.push(32);
oH.push(32);
oT.push("target");
oN.push(num);
}
function generateBlock(x, y) {
BLOCKS_ALL.push(oN.length);
oX.push(x);
oY.push(y);
oTiles.push([14, 50, 50]);
oW.push(50);
oH.push(50);
oT.push("block");
oN.push(100);
}
function generateBarrel(x, y) {
BLOCKS_ALL.push(oN.length);
oX.push(x);
oY.push(y);
oTiles.push([15 + random(2), 25, 50]);
oW.push(25);
oH.push(50);
oT.push("barrel");
oN.push(50);
}
function generate30_60_90Triangle(x, y, d) {
oX.push(x);
oY.push(y);
oW.push(400);
oH.push(200);
if (d == "r") {
oTiles.push([6, 400, 200]);
oT.push("30_60_90Triangle_R");
}
if (d == "l") {
oTiles.push([7, 400, 200]);
oT.push("30_60_90Triangle_L");
}
oN.push(num);
}
function generateBush(x, y) {
oX.push(x);
oY.push(y);
oTiles.push([10, 111, 64]);
oW.push(111);
oH.push(64);
oT.push("static");
oN.push(num);
}
function generateTree(x, y) {
oX.push(x);
oY.push(y);
oTiles.push([9, 103, 172]);
oW.push(103);
oH.push(172);
oT.push("static");
oN.push(num);
}
function generateBrush1(x, y) {
oX.push(x);
oY.push(y);
oTiles.push([11, 52, 89]);
oW.push(52);
oH.push(89);
oT.push("static");
oN.push(num);
}
function generateBoosterObject(x, y, num) {
oX.push(x);
oY.push(y);
oTiles.push([12, 48, 16]);
oW.push(48);
oH.push(16);
oT.push("booster");
oN.push(num);
}
function generateBoosterRightObject(x, y, num) {
oX.push(x);
oY.push(y);
oTiles.push([13, 48, 16]);
oW.push(48);
oH.push(16);
oT.push("boosterRight");
oN.push(num);
}
function makeChubbs(x, y, health) {
chbs = attachMovie("mc.chubbs", "chubbs", 137000);
chbs._x = x;
chbs._y = y;
chbs.health = health;
chbs.damage = 15;
chbs.attackSpace = 140;
chbs.xMin = xMin;
chbs.xMax = xMax;
chbs.tDirection = 0;
chbs.facing = "right";
chbs.WID = chbs._width / 2;
chbs.attackTimer = 0;
chbs.healthTimer = 0;
chbs.laughTimer = 0;
chbs.blCount = 0;
chbs.bridge = 0;
chbs.SIZE = 1;
chbs.eL = chbs._x - chbs.WID;
chbs.eR = chbs._x + chbs.WID;
chbs.eT = chbs._y - (chbs._height / 2);
chbs.eB = chbs._y + (chbs._height / 2);
chbs.onEnterFrame = function () {
if (paused != true) {
if (_root.blur == true) {
if (Math.abs(_root.iF.cS_y) > Math.abs(_root.iF.cS_x)) {
this.bx = Math.abs(_root.iF.cS_y) / _root.blurRate;
} else {
this.bx = Math.abs(_root.iF.cS_x) / _root.blurRate;
}
if ((_root.iF.cS_y != 0) || (_root.iF.cS_x != 0)) {
this.bx = this.bx + ((random(5) - 2) * _root.blurVar);
}
var _local3 = new flash.filters.BlurFilter(this.bx, 0, 1);
this.filters = [_local3];
} else {
this.filters = [];
}
pL = _root.player;
if (this.dying != true) {
if (((((this._x < (_root.iF._x + 300)) && (this._x > (_root.iF._x - 300))) && (this._y < (_root.iF._y + 250))) && (this._y > (_root.iF._y - 250))) || (this.attacked == true)) {
if (this.attackTimer == 0) {
if ((_root.KILLS < 6) || (this.bridge == 2)) {
if (pL._x > this._x) {
this.facing = "right";
} else {
this.facing = "left";
}
} else {
this.facing = "left";
}
}
}
if ((_root.player._y - 100) < this._y) {
if (this.laughTimer == 0) {
if ((this.attackTimer == 0) && (random(40) == 0)) {
this.attack = true;
this.attackTimer = 75;
} else {
this.attack = false;
}
}
} else {
this.attack = false;
}
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
this.reduceTimers();
}
if (this.facing == "right") {
this._xscale = -100;
} else {
this._xscale = 100;
}
if (this.laughTimer == 0) {
if (this.attackTimer > 0) {
if (_root.KILLS < 6) {
this.gotoAndStop("Attack");
} else {
if (this.fireTimer == undefined) {
this.fireTimer = 25;
}
if (this.fireTimer > 0) {
this.fireTimer--;
} else {
this.gotoAndStop("Attack");
}
}
} else {
this.gotoAndStop("Idle");
}
} else {
this.gotoAndStop("Laugh");
}
if (this.fireTimer != undefined) {
if (this.fireTimer > 0) {
this.fireTimer--;
}
}
}
};
chbs.reduceTimers = function () {
if (this.attackTimer > 0) {
this.attackTimer--;
}
if (this.healthTimer > 0) {
this.healthTimer--;
}
if (this.laughTimer > 0) {
this.laughTimer--;
}
};
chbs.fire = function (x, y, distance) {
if (_root.KILLS < 6) {
b = attachMovie("mc.cannonBall", "cannonBall" + this.bCount, 138000 + this.bCount);
b.vy = -Math.abs(distance / 80);
b.force = distance / ((((-b.vy) * 37) / 5) + 10);
} else {
b = attachMovie("mc.cannonBall", "cannonBall" + this.bCount, 138000 + this.bCount);
if (this.bridge == 0) {
b.vy = -8;
b.force = -450 / ((((-b.vy) * 37) / 5) + 10);
this.bridge = 1;
} else if (this.bridge == 1) {
b.vy = -12.8;
b.force = -800 / ((((-b.vy) * 37) / 5) + 10);
this.bridge = 2;
} else {
b = attachMovie("mc.cannonBall", "cannonBall" + this.bCount, 138000 + this.bCount);
b.vy = -Math.abs(distance / 80);
b.force = distance / ((((-b.vy) * 37) / 5) + 10);
}
}
b.id = this.bCount;
if (this.facing == "right") {
b._x = x + 16;
} else {
b._x = x - 16;
}
b._y = y;
b.onEnterFrame = function () {
if (_root.paused != true) {
this.vy = this.vy + 0.5;
this._x = this._x + (this.force * 2);
this._y = this._y + (this.vy * 2);
if (this._y > (_root.chubbs._y + 38.5)) {
_root.chubbs.makeExplosion(this.id, this._x, this._y);
removeMovieClip(this);
}
}
};
if (this.bCount < 5) {
this.bCount++;
} else {
this.bCount = 0;
}
};
chbs.makeExplosion = function (id, x, y) {
ex = attachMovie("mc.explosion", "explosion" + id, 139000 + id);
ex._x = x;
ex._y = this._y + 32.5;
if ((Math.abs(ex._x - _root.player._x) < 100) && (Math.abs(ex._y - _root.player._y) < 60)) {
_root.player.takeDamage(200 / Math.abs(ex._x - _root.player._x));
}
if (random(2) == 0) {
ex._xscale = -100;
}
_root.iF.cS_x = _root.iF.cS_x + (random(20) - 10);
_root.iF.cS_y = _root.iF.cS_y + (random(20) - 10);
};
chbs.hit = function (x, y, damage, rot) {
if (this.laughTimer == 0) {
this.laughTimer = 50;
ct = attachMovie("mc.chubbsText", "chubbsText", 139100);
ct._x = this._x;
ct._y = this._y - 70;
}
};
}
function makeKnight(id, x, y, health, xMin, xMax) {
kn = attachMovie("mc.knight", "kn" + id, 900 + id);
kn.id = id;
_root.knights.push(kn);
_root.nK++;
knH = attachMovie("mc.healthBar", "knH" + id, 9500 + id);
knH._xscale = 75;
knH._alpha = 0;
knH.trgt = kn;
knH.onEnterFrame = function () {
this._x = this.trgt._x;
this._y = (this.trgt._y - 50) - 35.7;
};
kn.SIZE = (((health / 100) * 0.5) + 1) - 0.5;
kn._xscale = 100 * kn.SIZE;
kn._yscale = 100 * kn.SIZE;
kn._x = x;
kn._y = (y + 35.7) + (35.7 * (kn.SIZE / 100));
kn.ohealth = health;
kn.health = health;
kn.damage = 15 * kn.SIZE;
kn.attackSpace = 50 * kn.SIZE;
kn.WID = 23 * kn.SIZE;
kn.xMin = xMin;
kn.xMax = xMax;
kn.eL = kn._x - kn.WID;
kn.eR = kn._x + kn.WID;
kn.eT = kn._y - kn._height;
kn.eB = kn._y;
kn.RM = false;
kn.ohealth = health;
kn.health = health;
kn.damage = 7;
kn.attackSpace = 80;
kn.vis = true;
kn.facing = "right";
kn.attackTimer = 0;
kn.healthTimer = 0;
kn.onEnterFrame = function () {
if (paused != true) {
if (_root.blur == true) {
if (Math.abs(_root.iF.cS_y) > Math.abs(_root.iF.cS_x)) {
this.bx = Math.abs(_root.iF.cS_y) / _root.blurRate;
} else {
this.bx = Math.abs(_root.iF.cS_x) / _root.blurRate;
}
if ((_root.iF.cS_y != 0) || (_root.iF.cS_x != 0)) {
this.bx = this.bx + ((random(5) - 2) * _root.blurVar);
}
var _local3 = new flash.filters.BlurFilter(this.bx, 0, 1);
this.filters = [_local3];
} else {
this.filters = [];
}
pL = _root.player;
if (this.dying != true) {
if (((((this._x < (_root.iF._x + 300)) && (this._x > (_root.iF._x - 300))) && (this._y < (_root.iF._y + 250))) && (this._y > (_root.iF._y - 250))) || (this.attacked == true)) {
if (pL._x > this._x) {
this.facing = "right";
if ((((pL._x - this._x) > 75) && ((pL._x - this._x) < 200)) || (this.attacked == true)) {
this.walk = true;
}
} else {
this.facing = "left";
if ((((this._x - pL._x) > 75) && ((this._x - pL._x) < 200)) || (this.attacked == true)) {
this.walk = true;
}
}
} else {
this.walk = false;
}
if (Math.abs(this._x - pL._x) < 5) {
this.walk = false;
}
if (Math.abs(pL._y - this._y) < this.attackSpace) {
if (Math.abs(pL._x - this._x) < this.attackSpace) {
this.attack = true;
this.attackTimer = 75;
} else {
this.attack = false;
}
} else {
this.attack = false;
}
if ((this.walk == true) && (this.attackTimer == 0)) {
if (this.facing == "right") {
this._x = this._x + (6 * this.SIZE);
} else {
this._x = this._x - (6 * this.SIZE);
}
if (this._x < this.xMin) {
this._x = this.xMin;
}
if (this._x > this.xMax) {
this._x = this.xMax;
}
numb = 0;
while (numb < _root.BLOCKS_ALL.length) {
this.CB = _root.BLOCKS_ALL[numb];
if (Math.abs((oY[this.CB] + (oH[this.CB] / 2)) - this._y) < 50) {
if (this._x > oX[this.CB]) {
this.THISPOINT = this._x - this.WID;
this.BLOCKPOINT = _root.oX[this.CB] + _root.oW[this.CB];
} else {
this.BLOCKPOINT = this._x + this.WID;
this.THISPOINT = _root.oX[this.CB];
}
if ((this.THISPOINT - this.BLOCKPOINT) < 0) {
if (this._x > oX[this.CB]) {
this._x = (oX[this.CB] + oW[this.CB]) + this.WID;
} else {
this._x = oX[this.CB] - this.WID;
}
this.attack = true;
this.attackTimer = 75;
break;
}
}
numb++;
}
this.eL = this._x - this.WID;
this.eR = this._x + this.WID;
this.eT = this._y - this._height;
this.eB = this._y;
}
if (this.hitTest(_root.iF)) {
if (!this.vis) {
this._visible = true;
_root.knights.push(this);
this.vis = true;
}
} else if (this.vis) {
this._visible = false;
reda(_root.knights, this);
this.vis = false;
}
this.reduceTimers();
}
if (this.facing == "right") {
this._xscale = -100 * this.SIZE;
} else {
this._xscale = 100 * this.SIZE;
}
if (this.dying == true) {
this.gotoAndStop("Death");
} else if (this.attackTimer > 0) {
this.gotoAndStop("Slash");
} else if (this.walk == true) {
this.gotoAndStop("Run");
} else {
this.gotoAndStop("Idle");
}
if (this.health <= 0) {
this.dying = true;
}
if (this.dead == true) {
if (this._alpha > 0) {
this._alpha = this._alpha - 10;
} else {
_root.nK--;
_root.KILLS++;
this.stopAllSounds();
removeMovieClip(this);
}
}
}
};
kn.reduceTimers = function () {
if (this.attackTimer > 0) {
this.attackTimer--;
}
if (this.healthTimer > 0) {
this.healthTimer--;
}
};
kn.hit = function (x, y, damage, rot) {
this.healthTimer = 50;
this.health = this.health - damage;
if (this.health > 0) {
if (random(4) == 0) {
_root.soundfx(this._x, ("audio.flesh" + random(11)) + ".wav");
} else {
_root.soundfx(this._x, ("audio.damage" + random(8)) + ".wav");
}
} else if (!this.RM) {
reda(_root.knights, this);
this.RM = true;
}
if ((((DIFFICULTY == "EASY") && (MAPNUMBER != "Survival")) && (MAPNUMBER != "SurvivalZombie")) && (MAPNUMBER != "SurvivalKnight")) {
if (_root.player.leechTimer > 0) {
_root.player.health = _root.player.health + (damage / 5);
} else {
_root.player.health = _root.player.health + (damage / 15);
}
} else if (_root.player.leechTimer > 0) {
_root.player.health = _root.player.health + (damage / 15);
}
this.attacked = true;
this.blood(x, y, rot);
};
kn.blood = function (x, y, rot) {
if (_root.blood == "ON") {
bs = _root.makeBlood(x, y, rot, this.id, this.blCount);
if (this.blCount < 10) {
this.blCount++;
} else {
this.blCount = 0;
}
}
};
}
function makeGrunt(id, x, y, health, xMin, xMax) {
g = attachMovie("mc.grunt", "g" + id, 8000 + id);
g.id = id;
_root.grunts.push(g);
_root.nG++;
gH = attachMovie("mc.healthBar", "gH" + id, 8500 + id);
gH._alpha = 0;
gH._xscale = 75;
gH.trgt = g;
gH.onEnterFrame = function () {
this._x = this.trgt._x;
this._y = (this.trgt._y - 50) - 35.7;
};
g.SIZE = (((health / 100) * 0.5) + 1) - 0.5;
g._xscale = 100 * g.SIZE;
g._yscale = 100 * g.SIZE;
g._x = x;
g._y = (y + 35.7) + (35.7 * (g.SIZE / 100));
g.ohealth = health;
g.health = health;
g.damage = 15 * g.SIZE;
g.attackSpace = 50 * g.SIZE;
g.attackType = "standing";
g.deathNumber = random(2) + 1;
g.xMin = xMin;
g.xMax = xMax;
g.vis = true;
g.WID = 11;
g.eL = g._x - g.WID;
g.eR = g._x + g.WID;
g.eT = g._y - g._height;
g.eB = g._y;
g.RM = false;
g.tDirection = 0;
g.facing = "right";
g.attackTimer = 0;
g.healthTimer = 0;
g.bCount = 0;
g.blCount = 0;
g.nCount = 0;
g.onEnterFrame = function () {
if (paused != true) {
if (_root.blur == true) {
if (Math.abs(_root.iF.cS_y) > Math.abs(_root.iF.cS_x)) {
this.bx = Math.abs(_root.iF.cS_y) / _root.blurRate;
} else {
this.bx = Math.abs(_root.iF.cS_x) / _root.blurRate;
}
if ((_root.iF.cS_y != 0) || (_root.iF.cS_x != 0)) {
this.bx = this.bx + ((random(5) - 2) * _root.blurVar);
}
var _local3 = new flash.filters.BlurFilter(this.bx, 0, 1);
this.filters = [_local3];
} else {
this.filters = [];
}
pL = _root.player;
if (this.dying != true) {
if (((((this._x < (_root.iF._x + 300)) && (this._x > (_root.iF._x - 300))) && (this._y < (_root.iF._y + 250))) && (this._y > (_root.iF._y - 250))) || (this.attacked == true)) {
if (pL._x > this._x) {
this.facing = "right";
if ((((pL._x - this._x) > 150) && ((pL._x - this._x) < 300)) || (this.attacked == true)) {
this.walk = true;
}
} else {
this.facing = "left";
if ((((this._x - pL._x) > 150) && ((this._x - pL._x) < 300)) || (this.attacked == true)) {
this.walk = true;
}
}
} else {
this.walk = false;
}
if (((this.facing == "right") && ((pL._x - this._x) < 150)) || ((this.facing == "left") && ((this._x - pL._x) < 150))) {
this.walk = false;
}
if ((Math.abs(pL._x - this._x) < 70) && (_root.MAPNUMBER != "NadeDodger")) {
if (Math.abs(pL._y - this._y) < 70) {
this.attack == true;
this.attackTimer = 25;
this.attackType = "melee";
}
} else if ((random(60) == 0) && (this.attackTimer == 0)) {
this.decision = undefined;
this.attack = true;
this.attackTimer = 50;
if ((random(5) == 0) || (_root.MAPNUMBER == "NadeDodger")) {
this.attackType = "throwing";
} else if ((_root.player.onGround == true) && (Key.isDown(kDn))) {
this.attackType = "crouching";
} else {
this.attackType = "standing";
}
}
if ((this.walk == true) && (this.attackTimer == 0)) {
if (this.facing == "right") {
this._x = this._x + (4.5 * this.SIZE);
} else {
this._x = this._x - (4.5 * this.SIZE);
}
this.OUT = false;
if (this._x < this.xMin) {
this._x = this.xMin;
this.OUT = true;
}
if (this._x > this.xMax) {
this._x = this.xMax;
this.OUT = true;
}
if (this.OUT) {
this.attack = true;
this.attackTimer = 50;
this.attackType = "throwing";
}
numb = 0;
while (numb < _root.BLOCKS_ALL.length) {
this.CB = _root.BLOCKS_ALL[numb];
if (Math.abs((oY[this.CB] + (oH[this.CB] / 2)) - this._y) < 50) {
if (this._x > oX[this.CB]) {
this.THISPOINT = this._x - this.WID;
this.BLOCKPOINT = _root.oX[this.CB] + _root.oW[this.CB];
} else {
this.BLOCKPOINT = this._x + this.WID;
this.THISPOINT = _root.oX[this.CB];
}
if ((this.THISPOINT - this.BLOCKPOINT) < 0) {
if (this._x > oX[this.CB]) {
this._x = (oX[this.CB] + oW[this.CB]) + this.WID;
} else {
this._x = oX[this.CB] - this.WID;
}
this.attack = true;
this.attackTimer = 75;
this.attackType = "melee";
break;
}
}
numb++;
}
this.eL = this._x - this.WID;
this.eR = this._x + this.WID;
this.eT = this._y - this._height;
this.eB = this._y;
}
if (this.hitTest(_root.iF)) {
if (!this.vis) {
this._visible = true;
_root.grunts.push(this);
this.vis = true;
}
} else if (this.vis) {
this._visible = false;
reda(_root.grunts, this);
this.vis = false;
}
this.reduceTimers();
}
if (this.facing == "right") {
this._xscale = -100 * this.SIZE;
} else {
this._xscale = 100 * this.SIZE;
}
if (this.dying == true) {
this.gotoAndStop("Death" + this.deathNumber);
} else if (this.attackTimer > 0) {
if (this.attackType == "melee") {
this.gotoAndStop("Melee");
} else if (this.attackType == "crouching") {
this.gotoAndStop("Fire_Crouch");
} else if (this.attackType == "standing") {
this.gotoAndStop("Fire");
} else {
if (this.decision == undefined) {
if (random(2) == 0) {
this.decision = "ThrowFrag";
} else {
this.decision = "ThrowFlashBang";
}
}
this.gotoAndStop(this.decision);
}
} else if (this.walk == true) {
this.gotoAndStop("Walk");
} else {
this.gotoAndStop("Idle");
}
if (this.health <= 0) {
this.dying = true;
}
if (this.dead == true) {
if (this._alpha > 0) {
this._alpha = this._alpha - 10;
} else {
_root.nG--;
_root.KILLS++;
this.stopAllSounds();
removeMovieClip(this);
}
}
}
};
g.fire = function () {
_root.soundfx(this._x, "audio.gruntFire.wav");
b = attachMovie("mc.bullet", "gB" + ((this.id * 10) + this.bCount), 8750 + ((this.id * 10) + this.bCount));
if (this.attackType == "standing") {
b._y = (this._y - 20) - 35.7;
} else {
b._y = (this._y + 5) - 35.7;
}
if (this.facing == "right") {
b._x = this._x + 80;
} else {
b._x = this._x - 80;
}
b.dir = this.facing;
b.gotoAndStop("grunt");
b.onEnterFrame = function () {
if (_root.paused != true) {
if (this.dir == "right") {
this.vx = 25;
this._rotation = 0;
} else {
this.vx = -25;
this._rotation = 180;
}
this._x = this._x + this.vx;
checkForBlocks(this, 4 + random(3), this._x, undefined);
if (this.hitTest(_root.player)) {
_root.player.takeDamage(4 + random(3));
if (this.dir == "right") {
this._x = this._x + 30;
this._rotation = 0;
} else {
this._x = this._x - 30;
this._rotation = 180;
}
removeMovieClip(this);
}
if ((((this._x > (_root.iF._x + 500)) || (this._x < (_root.iF._x - 500))) || (this._y > (_root.iF._y + 250))) || (this._y < (_root.iF._y - 250))) {
removeMovieClip(this);
}
}
};
mf = attachMovie("mc.muzzleFlash" + random(6), ("muzzleFlash" + (this.id * 20)) + this.bCount, (96000 + (this.id * 20)) + this.bCount);
mf._y = b._y;
if (this.facing == "right") {
mf._rotation = 0;
mf._x = b._x - 55;
} else {
mf._rotation = 180;
mf._x = b._x + 55;
}
mf.onEnterFrame = function () {
if (_root.paused != true) {
if (this._alpha > 0) {
this._alpha = this._alpha - 20;
} else {
removeMovieClip(this);
}
}
};
if (this.bCount > 10) {
this.bCount = 0;
} else {
this.bCount++;
}
};
g.reduceTimers = function () {
if (this.attackTimer > 0) {
this.attackTimer--;
}
if (this.healthTimer > 0) {
this.healthTimer--;
}
};
g.throwNade = function (typea) {
nd = _root.attachMovie(typea, "frag" + ((this.id * 10) + this.nCount), 784643 + ((this.id * 10) + this.nCount));
if (this.facing == "right") {
nd._x = this._x + 5;
nd.rot = 10;
} else {
nd._x = this._x - 5;
nd.rot = -10;
}
nd._y = (this._y - 10) - 35.7;
nd.distance = (_root.player._x - this._x) * 0.7;
nd.vy = -Math.abs(nd.distance / 80);
nd.force = nd.distance / ((((-nd.vy) * 37) / 5) + 10);
nd.timer = 50;
nd.id = this.id;
nd._xscale = 75;
nd._yscale = 75;
nd.splode = function (string) {
if (string == "FRAG") {
exp = _root.attachMovie("mc.explosionMine", "explosionStinger" + (898432 + this.id), 898432 + this.id);
exp._x = this._x;
exp._y = this._y;
if (this._rotation == -90) {
exp._rotation = this._rotation + 90;
} else {
exp._rotation = -25 + random(51);
}
exp.TARG = 0;
if (random(2) == 0) {
exp._xscale = -100;
}
exp._xscale = exp._xscale * ((90 + random(21)) / 100);
exp._yscale = exp._yscale * ((90 + random(21)) / 100);
_root.soundfx(this._x, ("audio.explode" + random(3)) + ".wav");
} else {
_root.iF.blind((Math.abs(this._x - _root.player._x) + Math.abs(this._y - _root.player._y)) / 2);
_root.soundfx(this._x, ("audio.flashbang" + random(2)) + ".wav");
}
};
nd.onEnterFrame = function () {
if (_root.paused != true) {
this.play();
this.vy = this.vy + 0.5;
this._x = this._x + (this.force * 2);
this._y = this._y + (this.vy * 2);
this._rotation = this._rotation + this.rot;
for (var _local3 in _root.VISIBLE) {
nu = _root.VISIBLE[_local3];
obnu = _root.scr[nu];
if ((_root.oT[nu] == "platform") || (_root.oT[nu] == "block")) {
if (obnu.hitTest(this._x, this._y, true)) {
if (_root.oW[nu] == 128) {
if (_root.player._y < obnu._y) {
this._y = obnu._y;
this.vy = this.vy * -0.5;
this.force = this.force * 0.5;
this.rot = this.rot * -0.5;
}
} else if (this.force > 0) {
this._x = obnu._x;
this.force = this.force * -0.5;
this.vy = this.vy * 0.5;
this.rot = this.rot * -0.5;
} else {
this._x = obnu._x + obnu._width;
this.force = this.force * -0.5;
this.vy = this.vy * 0.5;
this.rot = this.rot * -0.5;
}
}
}
}
if (this.timer > 0) {
this.timer--;
} else if (this.timer == 0) {
this.timer--;
trace("");
trace(this);
_root.removeMovieClip(this);
this.removeMovieClip(this);
trace(this);
}
} else {
this.stop();
}
};
if (this.nCount > 10) {
this.nCount = 0;
} else {
this.nCount++;
}
};
g.hit = function (x, y, damage, rot) {
this.healthTimer = 50;
this.health = this.health - damage;
if (this.health > 0) {
_root.soundfx(this._x, ("audio.damage" + random(8)) + ".wav");
if (random(4) == 0) {
_root.soundfx(this._x, ("audio.flesh" + random(11)) + ".wav");
}
} else if (!this.RM) {
reda(_root.grunts, this);
this.RM = true;
}
if ((((DIFFICULTY == "EASY") && (MAPNUMBER != "Survival")) && (MAPNUMBER != "SurvivalZombie")) && (MAPNUMBER != "SurvivalKnight")) {
if (_root.player.leechTimer > 0) {
_root.player.health = _root.player.health + (damage / 5);
} else {
_root.player.health = _root.player.health + (damage / 15);
}
} else if (_root.player.leechTimer > 0) {
_root.player.health = _root.player.health + (damage / 15);
}
this.attacked = true;
this.blood(x, y, rot);
};
g.blood = function (x, y, rot) {
if (_root.blood == "ON") {
bs = _root.makeBlood(x, y, rot, this.id, this.blCount);
if (this.blCount < 10) {
this.blCount++;
} else {
this.blCount = 0;
}
}
};
}
function makeFrog(id, x, y, health, xMin, xMax) {
f = attachMovie("mc.frog", "f" + id, 12000 + id);
f.id = id;
_root.frogs.push(f);
_root.nF++;
fH = attachMovie("mc.healthBar", "fH" + id, 12500 + id);
fH._xscale = 75;
fH._alpha = 0;
fH.trgt = f;
fH.onEnterFrame = function () {
this._x = this.trgt._x;
this._y = (this.trgt._y - 50) - 16.7;
};
f.SIZE = (((health / 100) * 0.5) + 1) - 0.5;
f._xscale = 100 * f.SIZE;
f._yscale = 100 * f.SIZE;
f._x = x;
f._y = (y + 16.7) + (16.7 * (f.SIZE / 100));
f.ohealth = health;
f.health = health;
f.damage = 15 * f.SIZE;
f.attackSpace = 175 * f.SIZE;
f.xMin = xMin;
f.xMax = xMax;
f.vis = true;
f.WID = f._width / 2;
f.tDirection = 0;
f.facing = "right";
f.attackTimer = 0;
f.healthTimer = 0;
f.blCount = 0;
f.sound = 0;
f.eL = f._x - f.WID;
f.eR = f._x + f.WID;
f.eT = f._y - f._height;
f.eB = f._y;
f.RM = false;
f.onEnterFrame = function () {
if (paused != true) {
if (_root.blur == true) {
if (Math.abs(_root.iF.cS_y) > Math.abs(_root.iF.cS_x)) {
this.bx = Math.abs(_root.iF.cS_y) / _root.blurRate;
} else {
this.bx = Math.abs(_root.iF.cS_x) / _root.blurRate;
}
if ((_root.iF.cS_y != 0) || (_root.iF.cS_x != 0)) {
this.bx = this.bx + ((random(5) - 2) * _root.blurVar);
}
var _local3 = new flash.filters.BlurFilter(this.bx, 0, 1);
this.filters = [_local3];
} else {
this.filters = [];
}
if (this.sound > 0) {
this.sound--;
}
pL = _root.player;
this.RS = 30 + random(40);
if (this.dying != true) {
if (((((this._x < (_root.iF._x + 300)) && (this._x > (_root.iF._x - 300))) && (this._y < (_root.iF._y + 250))) && (this._y > (_root.iF._y - 250))) || (this.attacked == true)) {
if (this.attackTimer == 0) {
if (pL._x > this._x) {
if (Math.abs(pL._x - this._x) > (this.attackSpace - this.RS)) {
this.facing = "right";
} else {
this.facing = "left";
}
if ((((pL._x - this._x) > this.attackSpace) && ((pL._x - this._x) < 300)) || (this.attacked == true)) {
this.walk = true;
}
} else {
if (Math.abs(pL._x - this._x) > (this.attackSpace - this.RS)) {
this.facing = "left";
} else {
this.facing = "right";
}
if ((((this._x - pL._x) > this.attackSpace) && ((this._x - pL._x) < 300)) || (this.attacked == true)) {
this.walk = true;
}
}
}
} else {
this.walk = false;
}
if ((pL._y - 100) < this._y) {
if ((Math.abs(pL._x - this._x) < this.attackSpace) && (Math.abs(pL._x - this._x) > (this.attackSpace - this.RS))) {
this.attack = true;
this.attackTimer = 75;
} else {
this.attack = false;
}
} else {
this.attack = false;
}
if (this.walk == true) {
if (this.facing == "right") {
this._x = this._x + (6 * this.SIZE);
} else {
this._x = this._x - (6 * this.SIZE);
}
if (this._x < this.xMin) {
this._x = this.xMin;
}
if (this._x > this.xMax) {
this._x = this.xMax;
}
numb = 0;
while (numb < _root.BLOCKS_ALL.length) {
this.CB = _root.BLOCKS_ALL[numb];
if (Math.abs((oY[this.CB] + (oH[this.CB] / 2)) - this._y) < 50) {
if (this._x > oX[this.CB]) {
this.THISPOINT = this._x - this.WID;
this.BLOCKPOINT = _root.oX[this.CB] + _root.oW[this.CB];
} else {
this.BLOCKPOINT = this._x + this.WID;
this.THISPOINT = _root.oX[this.CB];
}
if ((this.THISPOINT - this.BLOCKPOINT) < 0) {
if (this._x > oX[this.CB]) {
this._x = (oX[this.CB] + oW[this.CB]) + this.WID;
} else {
this._x = oX[this.CB] - this.WID;
}
this.attack = true;
this.attackTimer = 75;
break;
}
}
numb++;
}
this.eL = this._x - this.WID;
this.eR = this._x + this.WID;
this.eT = this._y - this._height;
this.eB = this._y;
}
if (this.hitTest(_root.iF)) {
if (!this.vis) {
this._visible = true;
_root.frogs.push(this);
this.vis = true;
}
} else if (this.vis) {
this._visible = false;
reda(_root.frogs, this);
this.vis = false;
}
this.reduceTimers();
}
if (this.facing == "right") {
this._xscale = -100 * this.SIZE;
} else {
this._xscale = 100 * this.SIZE;
}
if (this.dying == true) {
this.gotoAndStop("Death");
} else if (this.attackTimer > 0) {
this.gotoAndStop("Attack");
} else if (this.walk == true) {
this.gotoAndStop("Walk");
} else {
this.gotoAndStop("Idle");
}
if (this.health <= 0) {
this.dying = true;
}
if (this.dead == true) {
if (this._alpha > 0) {
this._alpha = this._alpha - 10;
} else {
_root.nF--;
_root.KILLS++;
this.stopAllSounds();
removeMovieClip(this);
}
}
}
};
f.reduceTimers = function () {
if (this.attackTimer > 0) {
this.attackTimer--;
}
if (this.healthTimer > 0) {
this.healthTimer--;
}
};
f.hit = function (x, y, damage, rot) {
this.healthTimer = 50;
this.health = this.health - (damage / 2);
if (this.health > 0) {
_root.soundfx(this._x, ("audio.damage" + random(8)) + ".wav");
if (this.sound == 0) {
_root.soundfx(this._x, ("audio.zombieDeath" + random(2)) + ".wav");
}
} else if (!this.RM) {
reda(_root.frogs, this);
this.RM = true;
}
if ((((DIFFICULTY == "EASY") && (MAPNUMBER != "Survival")) && (MAPNUMBER != "SurvivalZombie")) && (MAPNUMBER != "SurvivalKnight")) {
if (_root.player.leechTimer > 0) {
_root.player.health = _root.player.health + (damage / 5);
} else {
_root.player.health = _root.player.health + (damage / 15);
}
} else if (_root.player.leechTimer > 0) {
_root.player.health = _root.player.health + (damage / 15);
}
this.attacked = true;
this.blood(x, y, rot);
};
f.blood = function (x, y, rot) {
if (_root.blood == "ON") {
bs = _root.makeBlood(x, y, rot, this.id, this.blCount);
var _local3 = new Color(bs);
_local3.setRGB(2169905);
if (this.blCount < 10) {
this.blCount++;
} else {
this.blCount = 0;
}
}
};
}
function makeZombie(id, x, y, health, xMin, xMax) {
z = attachMovie("mc.zombie", "z" + id, 6000 + id);
z.id = id;
_root.zombies.push(z);
_root.nZ++;
zH = attachMovie("mc.healthBar", "zH" + id, 6500 + id);
zH._xscale = 75;
zH._alpha = 0;
zH.trgt = z;
zH.onEnterFrame = function () {
this._x = this.trgt._x;
this._y = (this.trgt._y - 50) - 35.7;
};
z.SIZE = (((health / 100) * 0.5) + 1) - 0.5;
z._xscale = 100 * z.SIZE;
z._yscale = 100 * z.SIZE;
z._x = x;
z._y = (y + 35.7) + (35.7 * (z.SIZE / 100));
z.ohealth = health;
z.health = health;
z.damage = 15 * z.SIZE;
z.attackSpace = 50 * z.SIZE;
z.xMin = xMin;
z.xMax = xMax;
z.vis = true;
z.WID = z._width / 2;
z.eL = z._x - z.WID;
z.eR = z._x + z.WID;
z.eT = z._y - z._height;
z.eB = z._y;
z.RM = false;
z.tDirection = 0;
z.facing = "right";
z.attackTimer = 0;
z.healthTimer = 0;
z.blCount = 0;
z.sound = 0;
z.onEnterFrame = function () {
if (paused != true) {
if (_root.blur == true) {
if (Math.abs(_root.iF.cS_y) > Math.abs(_root.iF.cS_x)) {
this.bx = Math.abs(_root.iF.cS_y) / _root.blurRate;
} else {
this.bx = Math.abs(_root.iF.cS_x) / _root.blurRate;
}
if ((_root.iF.cS_y != 0) || (_root.iF.cS_x != 0)) {
this.bx = this.bx + ((random(5) - 2) * _root.blurVar);
}
var _local3 = new flash.filters.BlurFilter(this.bx, 0, 1);
this.filters = [_local3];
} else {
this.filters = [];
}
if (this.sound > 0) {
this.sound--;
}
pL = _root.player;
if (this.dying != true) {
if (((((this._x < (_root.iF._x + 300)) && (this._x > (_root.iF._x - 300))) && (this._y < (_root.iF._y + 250))) && (this._y > (_root.iF._y - 250))) || (this.attacked == true)) {
if (pL._x > this._x) {
if (this.tDirection == 20) {
if (this.attackTimer == 0) {
this.facing = "right";
}
if (((pL._x - this._x) > this.attackSpace) || (this.attacked == true)) {
this.walk = true;
}
} else if (this.tDirection < 20) {
this.tDirection++;
}
} else if (this.tDirection == -20) {
if (this.attackTimer == 0) {
this.facing = "left";
}
if (((this._x - pL._x) > this.attackSpace) || (this.attacked == true)) {
this.walk = true;
}
} else if (this.tDirection > -20) {
this.tDirection--;
}
} else {
this.walk = false;
}
if (Math.abs(pL._y - this._y) < this.attackSpace) {
if (Math.abs(pL._x - this._x) < this.attackSpace) {
this.attack = true;
this.attackTimer = 75;
} else {
this.attack = false;
}
} else {
this.attack = false;
}
if ((this.walk == true) && (this.attackTimer == 0)) {
if (this.facing == "right") {
this._x = this._x + (0.75 * this.SIZE);
} else {
this._x = this._x - (0.75 * this.SIZE);
}
if (this._x < this.xMin) {
this._x = this.xMin;
}
if (this._x > this.xMax) {
this._x = this.xMax;
}
numb = 0;
while (numb < _root.BLOCKS_ALL.length) {
this.CB = _root.BLOCKS_ALL[numb];
if (Math.abs((oY[this.CB] + (oH[this.CB] / 2)) - this._y) < 50) {
if (this._x > oX[this.CB]) {
this.THISPOINT = this._x - this.WID;
this.BLOCKPOINT = _root.oX[this.CB] + _root.oW[this.CB];
} else {
this.BLOCKPOINT = this._x + this.WID;
this.THISPOINT = _root.oX[this.CB];
}
if ((this.THISPOINT - this.BLOCKPOINT) < 0) {
if (this._x > oX[this.CB]) {
this._x = (oX[this.CB] + oW[this.CB]) + this.WID;
} else {
this._x = oX[this.CB] - this.WID;
}
this.attack = true;
this.attackTimer = 75;
break;
}
}
numb++;
}
this.eL = this._x - this.WID;
this.eR = this._x + this.WID;
this.eT = this._y - this._height;
this.eB = this._y;
}
if (this.hitTest(_root.iF)) {
if (!this.vis) {
this._visible = true;
_root.zombies.push(this);
this.vis = true;
}
} else if (this.vis) {
this._visible = false;
reda(_root.zombies, this);
this.vis = false;
}
this.reduceTimers();
}
if (_root.MAPNUMBER == 3) {
this.ccolor = new Color(this);
this.cur = random(16777215);
this.ccolor.setRGB(this.cur);
}
if (this.facing == "right") {
this._xscale = -100 * this.SIZE;
} else {
this._xscale = 100 * this.SIZE;
}
if ((random(300) == 0) && (this.dying != true)) {
if (random(2) == 0) {
_root.soundfx(this._x, ("audio.attack_single" + random(3)) + ".wav");
} else {
_root.soundfx(this._x, ("audio.attack_double" + random(3)) + ".wav");
}
}
if (this.dying == true) {
this.gotoAndStop("Death");
} else if (this.attackTimer > 0) {
this.gotoAndStop("Attack");
} else if (this.walk == true) {
this.gotoAndStop("Walk");
} else {
this.gotoAndStop("Idle");
}
if (this.health <= 0) {
this.dying = true;
}
if (this.dead == true) {
if (this._alpha > 0) {
this._alpha = this._alpha - 10;
} else {
_root.nZ--;
_root.KILLS++;
this.stopAllSounds();
removeMovieClip(this);
}
}
}
};
z.reduceTimers = function () {
if (this.attackTimer > 0) {
this.attackTimer--;
}
if (this.healthTimer > 0) {
this.healthTimer--;
}
};
z.hit = function (x, y, damage, rot) {
this.healthTimer = 50;
this.health = this.health - (damage / 2);
if (this.health > 0) {
_root.soundfx(this._x, ("audio.damage" + random(8)) + ".wav");
if (this.sound == 0) {
_root.soundfx(this._x, ("audio.zombieDeath" + random(2)) + ".wav");
}
} else if (!this.RM) {
reda(_root.zombies, this);
this.RM = true;
}
if ((((DIFFICULTY == "EASY") && (MAPNUMBER != "Survival")) && (MAPNUMBER != "SurvivalZombie")) && (MAPNUMBER != "SurvivalKnight")) {
if (_root.player.leechTimer > 0) {
_root.player.health = _root.player.health + (damage / 5);
} else {
_root.player.health = _root.player.health + (damage / 15);
}
} else if (_root.player.leechTimer > 0) {
_root.player.health = _root.player.health + (damage / 15);
}
this.attacked = true;
this.blood(x, y, rot);
};
z.blood = function (x, y, rot) {
if (_root.blood == "ON") {
bs = _root.makeBlood(x, y, rot, this.id, this.blCount);
if (this.ccolor == undefined) {
var _local3 = new Color(bs);
_local3.setRGB(3055150);
} else {
var _local3 = new Color(bs);
_local3.setRGB(this.cur);
}
if (this.blCount < 10) {
this.blCount++;
} else {
this.blCount = 0;
}
}
};
}
function loadRocketBoss(xMin, xMax) {
rBoss = attachMovie("mc.rocketBoss", "rBoss", 700001);
rBossT = attachMovie("mc.rocketBossTop", "rBossTop", 700000);
rBossS = attachMovie("mc.rocketBossSupport", "rBossSupport", 699999);
rBossH = attachMovie("mc.healthBar", "rBossH", 700004);
rBossH._xscale = 150;
rBossH._alpha = 0;
rBossH.trgt = _root.rBoss;
rBossH.onEnterFrame = function () {
this._x = _root.rBoss._x;
this._y = _root.rBoss._y - 60;
};
rBoss._x = 800;
rBoss._y = 590;
rBoss.vx = 0;
rBoss.health = 1;
rBoss.damage = 10;
rBoss.xMin = xMin + 50;
rBoss.xMax = xMax - 50;
rBoss.targeted = false;
rBoss.targetTimer = 0;
rBoss.attackSpace = 50;
rBoss.RS = 40;
rBoss.WID = rBoss._width / 2;
rBoss.dt = 10;
rBoss.penis = 100;
rBoss.attackSpace = 25;
rBoss.attackTimer = 0;
rBoss.healthTimer = 0;
rBoss.colorTimer = 0;
rBoss.waitTimer = 0;
rBoss.runTo = 0;
rBossS.WID = rBossS._width / 2;
rBossT.WID = rBossT._width / 2;
rBoss.SIZE = 1;
rBossT.SIZE = 1;
rBossS.SIZE = 1;
rBossT.xs = 100;
rBossT.rCount = 0;
rBossT.at = 0;
rBossT.deploy = false;
rBossT.rot = 0;
rBossT.raise = false;
rBossT.raiseTimer = 0;
rBossT.pod = 0;
rBossT.onEnterFrame = function () {
if (paused != true) {
this.able = true;
if (this.deploy == false) {
this.px = pL._x;
this.py = pL._y;
if (this.py > this._y) {
this.py = this._y;
}
this.anx = this.px - this._x;
this.any = this.py - this._y;
this.ma = Math.atan(this.any / this.anx) * 57.2957795130823;
if (this.anx < 0) {
this.ma = this.ma + 180;
}
if ((this.anx >= 0) && (this.any < 0)) {
this.ma = this.ma + 360;
}
if (Math.abs(_root.player._x - this._x) > 380) {
}
this._rotation = this.ma;
} else if (Math.abs(90 - this.rot) > 0.1) {
this.rot = this.rot + ((90 - this.rot) * 0.15);
if (this.xs == 100) {
this._rotation = 180 + (180 - this.rot);
} else {
this._rotation = 0 + (-this.rot);
}
} else {
this.raise = true;
}
if (this.able == true) {
if (((this.at % 200) == 0) && (this.at > 1)) {
this.deploy = true;
this.rot = this._rotation;
if ((this.rot != 0) || (this.rot != 180)) {
this.rot = Math.abs(this.rot);
}
} else if ((((((this.at % 10) == 0) && (this.at > 1)) && (this.deploy == false)) || ((this.deploy == true) && (this.raiseTimer == 20))) || ((this.deploy == true) && (this.raiseTimer == 95))) {
if ((this.raiseTimer == 20) || (this.raiseTimer == 95)) {
this.nuTi = 10;
if (this.raiseTimer == 20) {
this.downX = this._x;
}
} else {
this.nuTi = 1;
}
this.nu = 0;
while (this.nu < this.nuTi) {
rock = attachMovie("mc.bullet", "rBossRocket" + this.rCount, 176340 + this.rCount);
if (((this.nu % 2) == 0) && (this.raiseTimer != 95)) {
_root.soundfx(this._x, "audio.stinger.wav");
}
if (this.raiseTimer == 95) {
rock.xper = 0;
rock.yper = 1;
} else {
rock.xper = Math.cos((this._rotation / 180) * Math.PI);
rock.yper = Math.sin((this._rotation / 180) * Math.PI);
}
if (this.nuTi == 10) {
if (this.raiseTimer == 20) {
rock._x = ((rBossTop._x + (rock.xper * 20)) - 20) + ((this.nu + 1) * 4);
} else if (this.raiseTimer == 95) {
rock._x = ((this.downX + (rock.xper * 20)) - 300) + ((this.nu + 1) * 60);
}
} else {
rock._x = rBossTop._x + (rock.xper * 20);
rock._x = rock._x - (rock.yper * 20);
rock._x = rock._x + ((rock.yper * this.pod) * 13.3);
}
if (this.raiseTimer == 95) {
rock._y = rBossTop._y - 399;
} else {
rock._y = rBossTop._y + (rock.yper * 20);
if (this.raiseTimer != 20) {
rock._y = rock._y - (rock.xper * 20);
rock._y = rock._y + ((rock.xper * this.pod) * 13.3);
}
}
if (this.pod < 3) {
this.pod++;
} else {
this.pod = 0;
}
rock.vx = rock.xper * 15;
rock.vy = rock.yper * 15;
rock.gotoAndStop("stinger");
if (this.raiseTimer == 95) {
rock._rotation = 270;
} else {
rock._rotation = this._rotation;
}
rock.sCount = 0;
rock.rCount = this.rCount;
rock.onEnterFrame = function () {
if (paused != true) {
if (pL.hitTest(this)) {
_root.player.takeDamage(10 + random(3));
exp = attachMovie("mc.explosionStinger", "explosionStinger543937" + this.rCount, 543937 + this.rCount);
exp._x = this._x;
exp._y = this._y;
exp._rotation = this._rotation;
_root.soundfx(this._x, ("audio.explode" + random(3)) + ".wav");
removeMovieClip(this);
}
if ((((this._x > (_root.iF._x + 800)) || (this._x < (_root.iF._x - 800))) || (this._y > (_root.iF._y + 400))) || (this._y < (rBossT._y - 450))) {
removeMovieClip(this);
}
this._x = this._x + this.vx;
this._y = this._y + this.vy;
smoke = attachMovie("mc.smokeParticle", ("smokeParticle" + (this.rCount * 60)) + this.sCount, (358600 + (this.rCount * 60)) + this.sCount);
smoke._x = this._x + (random(6) - 3);
smoke._y = this._y + (random(6) - 3);
smoke._xscale = 70;
smoke._yscale = 70;
smoke.vy = 0;
if (this.sCount < 30) {
this.sCount++;
} else {
this.sCount = 0;
}
}
};
if (this.rCount > 20) {
this.rCount = 0;
} else {
this.rCount++;
}
this.nu++;
}
}
}
if (this.raiseTimer == 0) {
this.at++;
}
if (_root.blur == true) {
if (Math.abs(_root.iF.cS_y) > Math.abs(_root.iF.cS_x)) {
this.bx = Math.abs(_root.iF.cS_y) / _root.blurRate;
} else {
this.bx = Math.abs(_root.iF.cS_x) / _root.blurRate;
}
if ((_root.iF.cS_y != 0) || (_root.iF.cS_x != 0)) {
this.bx = this.bx + ((random(5) - 2) * _root.blurVar);
}
var _local3 = new flash.filters.BlurFilter(this.bx, 0, 1);
this.filters = [_local3];
} else {
this.filters = [];
}
}
};
rBoss.onEnterFrame = function () {
if ((this.targeted == false) && (this.hostile == true)) {
if ((this.targetTimer > 33) && (this.targetTimer < 100)) {
_root.rBossH._alpha = 100;
this.health = this.health + ((100 - this.health) * 0.1);
}
if (this.targetTimer < 100) {
this.targetTimer++;
_root.paused = true;
} else if (this.targetTimer == 100) {
this.targetTimer++;
_root.paused = false;
}
if (this.targetTimer < 75) {
_root.iF.trgt = this;
} else {
_root.iF.trgt = _root.player;
}
if (this.targetTimer == 13) {
bossScr = attachMovie("mc.bossScreen", "bossScr", 120000);
bossScr._alpha = 0;
bossScr.alphaTimer = 0;
bossScr.fade = "in";
bossScr._x = this._x;
bossScr._y = this._y - 80;
bossScr.onEnterFrame = function () {
if ((this._alpha < 100) && (this.fade == "in")) {
this._alpha = this._alpha + 10;
}
if (this.alphaTimer == 100) {
this.fade = "out";
}
if (this.fade == "out") {
if (this._alpha > 0) {
this._alpha = this._alpha - 10;
} else {
_root.KILLS++;
removeMovieClip(this);
}
}
if (this._alpha >= 100) {
this.alphaTimer = this.alphaTimer + 4;
}
};
}
}
if (this.dying == true) {
_root.iF.trgt = this;
if ((Math.abs(iF._x - this._x) < 2) && (Math.abs(iF._y - this._y) < 2)) {
} else {
_root.paused = false;
}
}
if (paused != true) {
if (_root.blur == true) {
if (Math.abs(_root.iF.cS_y) > Math.abs(_root.iF.cS_x)) {
this.bx = Math.abs(_root.iF.cS_y) / _root.blurRate;
} else {
this.bx = Math.abs(_root.iF.cS_x) / _root.blurRate;
}
if ((_root.iF.cS_y != 0) || (_root.iF.cS_x != 0)) {
this.bx = this.bx + ((random(5) - 2) * _root.blurVar);
}
var _local3 = new flash.filters.BlurFilter(this.bx, 0, 1);
this.filters = [_local3];
} else {
this.filters = [];
}
pL = _root.player;
if (this.dying != true) {
if (((((this._x < (_root.iF._x + 500)) && (this._x > (_root.iF._x - 500))) && (this._y < (_root.iF._y + 250))) && (this._y > (_root.iF._y - 250))) || (this.hostile == true)) {
this.hostile = true;
if (this.attackTimer == 0) {
if (pL._x > this._x) {
if (Math.abs(pL._x - this._x) > (this.attackSpace - this.RS)) {
this.facing = "right";
} else {
this.facing = "left";
}
if ((((pL._x - this._x) > this.attackSpace) && ((pL._x - this._x) < 300)) || (this.hostile == true)) {
this.walk = true;
}
} else {
if (Math.abs(pL._x - this._x) > (this.attackSpace - this.RS)) {
this.facing = "left";
} else {
this.facing = "right";
}
if ((((this._x - pL._x) > this.attackSpace) && ((this._x - pL._x) < 300)) || (this.hostile == true)) {
this.walk = true;
}
}
}
} else {
this.walk = false;
}
if ((pL._y - 100) < this._y) {
if ((Math.abs(pL._x - this._x) < this.attackSpace) && (Math.abs(pL._x - this._x) > (this.attackSpace - this.RS))) {
this.attack = true;
this.attackTimer = 10;
} else {
this.attack = false;
}
} else {
this.attack = false;
}
if (this.walk == true) {
if (this.facing == "right") {
this._x = this._x + 2;
} else {
this._x = this._x - 2;
}
if (this._x < this.xMin) {
this._x = this.xMin;
}
if (this._x > this.xMax) {
this._x = this.xMax;
}
rBossT._x = this._x + (5 * (rBossT.xs / 100));
rBossS._x = rBossT._x;
rBossS._y = this._y - 35;
if (rBossT.deploy == false) {
rBossT._y = this._y - 35;
} else if (rBossT.raise == true) {
if (Math.abs((this._y - 60) - rBossT._y) > 0.1) {
rBossT._y = rBossT._y + (((this._y - 60) - rBossT._y) * 0.15);
} else {
rBossT.raiseTimer++;
if (rBossT.raiseTimer > 60) {
}
}
}
this.eL = this._x - this.WID;
this.eR = this._x + this.WID;
this.eT = this._y - (this._height / 2);
this.eB = this._y + (this._height / 2);
rBossT.eL = rBossT._x - rBossT.WID;
rBossT.eR = rBossT._x + rBossT.WID;
rBossT.eT = rBossT._y - (rBossT._height / 2);
rBossT.eB = rBossT._y + (rBossT._height / 2);
rBossS.eL = rBossS._x - rBossS.WID;
rBossS.eR = rBossS._x + rBossS.WID;
rBossS.eT = rBossS._y - (rBossS._height / 2);
rBossS.eB = rBossS._y + (rBossS._height / 2);
if (rBossT.raiseTimer >= 100) {
rBossT.deploy = false;
rBossT.raise = false;
rBossT.raiseTimer = 0;
}
}
this.reduceTimers();
}
if (this.facing == "right") {
this._xscale = -100;
rBossTop.xs = -100;
} else {
this._xscale = 100;
rBossTop.xs = 100;
}
if (this.dying == true) {
this.gotoAndStop("Death");
} else if (this.attackTimer > 0) {
} else if (this.walk == true) {
this.gotoAndStop("Walk");
} else {
this.gotoAndStop("Idle");
}
if (this.dead == true) {
if (this.penis > 0) {
this.penis = this.penis - 5;
} else {
_root.iF.fadeScreen.fade = "inslow";
if (_root.iF.fadeScreen._alpha >= 100) {
_root.clearAll();
_root.gotoAndStop("Credits");
removeMovieClip(this);
}
}
}
if (this.health <= 0) {
this.dying = true;
removeMovieClip(rBossS);
removeMovieClip(rBossT);
if (this.dt > 0) {
this.dt = this.dt - 1;
_root.soundfx(this._x, ("audio.explode" + random(3)) + ".wav");
if (this.dt == 9) {
bn = "mc.barrelExplosion";
bls = 3;
agfx = 0;
agfy = -150;
ro = 0;
} else {
bn = "mc.explosionMine";
block.s = (110 - random(21)) / 100;
agfx = random(40) - 20;
agfy = random(40) - 70;
ro = random(40) - 20;
}
block = _root.attachMovie(bn, "BOSSEX" + this.dt, 344345 + this.dt);
block._x = this._x + agfx;
block._y = this._y + agfy;
block._rotation = 0 + ro;
block._xscale = block._xscale * bls;
block._yscale = block._yscale * bls;
if (random(2) == 0) {
block._xscale = block._xscale * -1;
}
} else {
this.dead = true;
}
}
}
};
rBoss.reduceTimers = function () {
if (this.colorTimer > 0) {
this.colorTimer--;
}
if (this.attackTimer > 0) {
this.attackTimer--;
}
if (this.waitTimer > 0) {
this.waitTimer = this.waitTimer - 12;
if (this.waitTimer < 0) {
this.waitTimer = 0;
}
}
};
rBoss.hit = function (x, y, damage, rot) {
if (this.targetTimer > 0) {
this.healthTimer = 100;
this.health = this.health - (damage / 40);
this.attacked = true;
}
};
}
function loadGrassBoss(xMin, xMax) {
gBoss = attachMovie("mc.grassBoss", "gBoss", 40000);
gBossH = attachMovie("mc.healthBar", "gBossH", 40001);
gBossH._xscale = 150;
gBossH._alpha = 0;
gBossH.trgt = _root.gBoss;
gBossH.onEnterFrame = function () {
this._x = _root.gBoss._x;
this._y = _root.gBoss._y - 60;
};
gBoss._x = -200;
gBoss._y = -82;
gBoss.vx = 0;
gBoss.health = 1;
gBoss.damage = 10;
gBoss.xMin = xMin + 50;
gBoss.xMax = xMax - 50;
gBoss.targeted = false;
gBoss.targetTimer = 0;
gBoss.WID = 25;
gBoss.SIZE = 1;
gBoss.attackSpace = 75;
gBoss.attackTimer = 0;
gBoss.healthTimer = 0;
gBoss.colorTimer = 0;
gBoss.waitTimer = 0;
gBoss.runTo = 0;
gBoss.eL = gBoss._x - gBoss.WID;
gBoss.eR = gBoss._x + gBoss.WID;
gBoss.eT = gBoss._y - (gBoss._height / 2);
gBoss.eB = gBoss._y + (gBoss._height / 2);
gBoss.onEnterFrame = function () {
if ((this.targeted == false) && (this.hostile == true)) {
if ((this.targetTimer > 33) && (this.targetTimer < 100)) {
_root.gBossH._alpha = 100;
this.health = this.health + ((100 - this.health) * 0.1);
}
if (this.targetTimer < 100) {
this.targetTimer++;
_root.paused = true;
} else if (this.targetTimer == 100) {
this.targetTimer++;
_root.paused = false;
}
if (this.targetTimer < 75) {
_root.iF.trgt = this;
} else {
_root.iF.trgt = _root.player;
}
if (this.targetTimer == 13) {
bossScr = attachMovie("mc.bossScreen", "bossScr", 120000);
bossScr._alpha = 0;
bossScr.alphaTimer = 0;
bossScr.fade = "in";
bossScr._x = this._x;
bossScr._y = this._y - 80;
bossScr.onEnterFrame = function () {
if ((this._alpha < 100) && (this.fade == "in")) {
this._alpha = this._alpha + 10;
}
if (this.alphaTimer == 100) {
this.fade = "out";
}
if (this.fade == "out") {
if (this._alpha > 0) {
this._alpha = this._alpha - 10;
} else {
_root.KILLS++;
removeMovieClip(this);
}
}
if (this._alpha >= 100) {
this.alphaTimer = this.alphaTimer + 4;
}
};
}
}
if (this.dying == true) {
_root.iF.trgt = this;
if ((Math.abs(iF._x - this._x) < 2) && (Math.abs(iF._y - this._y) < 2)) {
} else {
_root.paused = false;
}
}
if (paused != true) {
if (_root.blur == true) {
if (Math.abs(_root.iF.cS_y) > Math.abs(_root.iF.cS_x)) {
this.bx = Math.abs(_root.iF.cS_y) / _root.blurRate;
} else {
this.bx = Math.abs(_root.iF.cS_x) / _root.blurRate;
}
if ((_root.iF.cS_y != 0) || (_root.iF.cS_x != 0)) {
this.bx = this.bx + ((random(5) - 2) * _root.blurVar);
}
var _local3 = new flash.filters.BlurFilter(this.bx, 0, 1);
this.filters = [_local3];
} else {
this.filters = [];
}
pL = _root.player;
if (this.dying != true) {
if (((((this._x < (_root.iF._x + 500)) && (this._x > (_root.iF._x - 500))) && (this._y < (_root.iF._y + 250))) && (this._y > (_root.iF._y - 250))) || (this.hostile == true)) {
this.hostile = true;
if (this.waitTimer == 0) {
if (pL._x > this._x) {
this.facing = "right";
if ((pL._x - this._x) > 75) {
this.walk = true;
this.runTo = (this._x + 500) + (pL._x - this._x);
this.waitTimer = 500 + (pL._x - this._x);
}
} else {
this.facing = "left";
if ((this._x - pL._x) > 75) {
this.walk = true;
this.runTo = (this._x - 500) - (this._x - pL._x);
this.waitTimer = (this._x - pL._x) + 500;
}
}
}
this.eL = this._x - this.WID;
this.eR = this._x + this.WID;
this.eT = this._y - (this._height / 2);
this.eB = this._y + (this._height / 2);
} else {
this.walk = false;
}
if (Math.abs(pL._y - this._y) < this.attackSpace) {
if (Math.abs(pL._x - this._x) < this.attackSpace) {
this.attack = true;
this.attackTimer = 75;
} else {
this.attack = false;
}
} else {
this.attack = false;
}
if ((this.walk == true) && (this.attackTimer == 0)) {
this._x = this._x + ((this.runTo - this._x) / 25);
if (this._x < this.xMin) {
this._x = this.xMin;
}
if (this._x > this.xMax) {
this._x = this.xMax;
}
}
this.reduceTimers();
if ((this.colorTimer % 2) != 0) {
var _local4 = new Color("gBoss");
_local4.setRGB(16711680);
} else {
var _local4 = new Color("gBoss");
_local4.setRGB(8092514);
}
}
if (this.facing == "right") {
this._xscale = -100;
} else {
this._xscale = 100;
}
if (this.dying == true) {
this.gotoAndStop("Death");
} else if (this.attackTimer > 0) {
this.gotoAndStop("Attack");
} else if (this.walk == true) {
this.gotoAndStop("Walk");
} else {
this.gotoAndStop("Idle");
}
if (this.dead == true) {
if (this._alpha > 0) {
this._alpha = this._alpha - 5;
} else {
_root.iF.fadeScreen.fade = "in";
if (_root.iF.fadeScreen._alpha >= 100) {
_root.MAPNUMBER = 2;
_root.reset();
removeMovieClip(this);
}
}
}
if (this.health <= 0) {
this.dying = true;
var _local4 = new Color("gBoss");
_local4.setRGB(8092514);
}
}
};
gBoss.reduceTimers = function () {
if (this.colorTimer > 0) {
this.colorTimer--;
}
if (this.attackTimer > 0) {
this.attackTimer--;
}
if (this.waitTimer > 0) {
this.waitTimer = this.waitTimer - 12;
if (this.waitTimer < 0) {
this.waitTimer = 0;
}
}
};
gBoss.hit = function (x, y, damage, rot) {
if (this.targetTimer > 0) {
this.healthTimer = 100;
this.health = this.health - (damage / 20);
if ((((DIFFICULTY == "EASY") && (MAPNUMBER != "Survival")) && (MAPNUMBER != "SurvivalZombie")) && (MAPNUMBER != "SurvivalKnight")) {
if (_root.player.leechTimer > 0) {
_root.player.health = _root.player.health + (damage / 5);
} else {
_root.player.health = _root.player.health + (damage / 15);
}
} else if (_root.player.leechTimer > 0) {
_root.player.health = _root.player.health + (damage / 15);
}
this.attacked = true;
if (this.health > 0) {
this.colorTimer = 10;
}
}
};
}
makePowerup = function (id, x, y, type) {
pw = attachMovie("mc.powerup" + type, "powerup" + id, 157000 + id);
pw.type = type;
pw._x = x;
pw._y = y;
pw.id = id;
pw.fade = "in";
pw._xscale = 75;
pw._yscale = 75;
pw.gotoAndStop(pW.type);
pw.onEnterFrame = function () {
this.gotoAndStop(this.type);
if (paused != true) {
if (this.type == undefined) {
this.type = "shotGun";
}
if (this.fade == "in") {
if (this._xscale < 99) {
this._xscale = this._xscale + ((100 - this._xscale) * 0.15);
this._yscale = this._yscale + ((100 - this._yscale) * 0.15);
} else {
this.fade = "out";
}
} else if (this._xscale > 51) {
this._xscale = this._xscale - ((this._xscale - 50) * 0.15);
this._yscale = this._yscale - ((this._yscale - 50) * 0.15);
} else {
this.fade = "in";
}
if (this.hitTest(_root.player)) {
if (this.type == "Leech") {
_root.player.leechTimer = 500;
}
_root.iF.bonusScreen.text = "[ LEECH POWERUP ]";
_root.iF.bonusScreen.timer = 100;
removeMovieClip(this);
}
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
}
};
};
function makeTurret(id, x, y) {
turret = attachMovie("mc.turret", "turret" + id, 212000 + id);
turret.id = id;
turret.rtap = 0;
turret.ltap = 0;
turret.rdn = false;
turret.ldn = false;
turret.fireTimer = 0;
turret._x = x;
turret._y = y;
turret.fire = function (power, rot) {
if (this.fireTimer == 0) {
this.fireTimer = 30;
b1 = attachMovie("mc.bullet", "turretB1", 11000);
b1._x = pT._x + (Math.cos((rot / 180) * Math.PI) * pW.LN);
b1._y = pT._y + (Math.sin((rot / 180) * Math.PI) * pW.LN);
b1._x = b1._x - (Math.sin((rot / 180) * Math.PI) * _root.player.ofst);
b1._y = b1._y + (Math.cos((rot / 180) * Math.PI) * _root.player.ofst);
b1._visible = false;
b2 = attachMovie("mc.bullet", "turretB2", 11001);
b2._x = b1._x + (Math.cos((rot / 180) * Math.PI) * 500);
b2._y = b1._y + (Math.sin((rot / 180) * Math.PI) * 500);
b2._visible = false;
laser = attachMovie("mc.turretLaser", "turretLaser", 11002);
laser._x = (turretB1._x + turretB2._x) / 2;
laser._y = (turretB1._y + turretB2._y) / 2;
laser._yscale = 50 + power;
laser._xscale = 150;
laser._rotation = rot;
laser.damage = (50 + power) / 2.5;
laser.doDamage = function () {
num = 0;
while (num < _root.zombies.length) {
if (_root.zombies[num].hitTest(this)) {
_root.zombies[num].hit(_root.zombies[num]._x, _root.zombies[num]._y - (_root.zombies[num]._height / 2), this.damage, random(361));
}
num++;
}
num = 0;
while (num < _root.frogs.length) {
if (_root.frogs[num].hitTest(this)) {
_root.frogs[num].hit(_root.frogs[num]._x, _root.frogs[num]._y, this.damage, random(361));
}
num++;
}
num = 0;
while (num < _root.grunts.length) {
if (_root.grunts[num].hitTest(this)) {
_root.grunts[num].hit(_root.grunts[num]._x, _root.grunts[num]._y, this.damage, random(361));
}
num++;
}
num = 0;
while (num < _root.knights.length) {
if (_root.knights[num].hitTest(this)) {
_root.knights[num].hit(_root.knights[num]._x, _root.knights[num]._y - (_root.knights[num]._height / 2), this.damage, random(361));
}
num++;
}
};
clearInterval(laser.interval);
laser.interval = setInterval(laser, "doDamage", 40);
_root.iF.cS_x = Math.cos((turretLaser._rotation / 180) * Math.PI) * power;
_root.iF.cS_y = Math.sin((turretLaser._rotation / 180) * Math.PI) * power;
var _local5 = new Sound(this);
_local5.attachSound("audio.turret.wav");
_local5.start(0, 0);
_local5.setVolume(_root.VOLUME_SFX - ((100 - power) / 5));
n = 0;
while (n < (5 + (power / 5))) {
turretBall = attachMovie("mc.turretBall" + (random(2) + 1), "turretBall" + n, 11003 + n);
turretBall._x = _root.pT._x + (Math.cos((rot / 180) * Math.PI) * (70 + random(100)));
turretBall._y = _root.pT._y + (Math.sin((rot / 180) * Math.PI) * (70 + random(100)));
turretBall._x = turretBall._x + (random(15) - 7);
turretBall._y = turretBall._y + (random(15) - 7);
turretBall.dist = Math.sqrt(((turretBall._x - _root.pT._x) * (turretBall._x - _root.pT._x)) + ((turretBall._y - _root.pT._y) * (turretBall._y - _root.pT._y)));
turretBall._xscale = 200 - turretBall.dist;
turretBall._yscale = 200 - turretBall.dist;
n++;
}
}
};
turret.onEnterFrame = function () {
if (paused != true) {
pL = _root.player;
if (this.hitTest(pL)) {
if (Key.isDown(_root.kLe)) {
if (this.ldn == false) {
if (this.ltap > 0) {
if (_root.inTurret == true) {
_root.inTurret = false;
_root.player._x = _root.player._x - 50;
pW.init("player", this.wpType, false);
this.wpType = undefined;
} else if (this._x < pL._x) {
_root.inTurret = true;
}
} else {
this.ltap = 20;
}
}
this.ldn = true;
} else {
this.ldn = false;
}
if (Key.isDown(_root.kRi)) {
if (this.rdn == false) {
if (this.rtap > 0) {
if (inTurret == true) {
inTurret = false;
_root.player._x = _root.player._x + 50;
pW.init("player", this.wpType, false);
this.wpType = undefined;
} else if (this._x > pL._x) {
_root.inTurret = true;
}
} else {
this.rtap = 20;
}
}
this.rdn = true;
} else {
this.rdn = false;
}
}
if (this.rtap > 0) {
this.rtap--;
}
if (this.ltap > 0) {
this.ltap--;
}
if (this.fireTimer > 0) {
this.fireTimer--;
}
if (_root.inTurret == false) {
this.gotoAndStop("Inactive");
}
if (_root.inTurret == true) {
if (this.wpType == undefined) {
this.wpType = _root.pW.type;
this.gotoAndStop("Active");
pL._x = this._x + 7.4;
pL._y = this._y - 88;
pW.init("player", "turret", true);
}
}
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
}
};
}
function makeShell(id, x, y, rot) {
sh = attachMovie("mc.shell", "sh" + id, 200000 + id);
sh.rot = rot;
tellTarget (sh) {
_x = x;
_y = y;
bx = 0;
by = 0;
_xscale = 26;
_yscale = 32;
_rotation = rot;
angle = ((_rotation - 90) / 180) * 3.14;
if (random(2) == 0) {
vx = (20 * Math.cos(angle)) + random(10);
} else {
vx = (20 * Math.cos(angle)) - random(10);
}
if (random(2) == 0) {
vy = (9 * Math.sin(angle)) + random(4);
} else {
vy = (9 * Math.sin(angle)) - random(4);
}
if (_root.pT._xmouse < 0) {
vy = vy * -1;
vx = vx * -1;
}
vx = vx + _root.player.vx;
vy = vy + _root.player.vy;
if (random(2) == 0) {
rotate = random(60);
} else {
rotate = -random(60);
}
pwt = _root.pW.type;
if ((pwt == "usp") || (pwt == "mac10")) {
gotoAndStop ("Pistol");
} else if ((pwt == "shotGun") || (pwt == "flakCannon")) {
gotoAndStop ("Shotgun");
} else {
gotoAndStop ("Rifle");
}
grv = _root.GRAVITY;
};
sh.onEnterFrame = function () {
if (paused != true) {
tellTarget (this) {
_x = (_x + (vx / 2.5));
_y = (_y + ((vy * 2) / 2.5));
vy = vy + grv;
_rotation = (_rotation + rotate);
};
if (_root.shellblur == true) {
this.bx = Math.abs(this.vx - _root.iF.nx) / 8;
this.by = Math.abs(this.vy - _root.iF.ny);
var _local3 = new flash.filters.BlurFilter(this.bx, this.by, 1);
this.filters = [_local3];
}
if (this._alpha > 0) {
this._alpha = this._alpha - 4;
} else {
this.removeMovieClip(this);
}
}
};
}
makePowerup = function (id, x, y, type) {
pwu = attachMovie("mc.pu", "pu" + id, 709782 + id);
pwu.type = type;
pwu._x = x;
pwu._y = y;
pwu.id = id;
pwu.fade = "in";
pwu.gotoAndStop(type);
pwu.onEnterFrame = function () {
this.gotoAndStop(this.type);
if (paused != true) {
if (this.fade == "in") {
if (this._xscale < 124) {
this._xscale = this._xscale + ((125 - this._xscale) * 0.15);
this._yscale = this._yscale + ((125 - this._yscale) * 0.15);
} else {
this.fade = "out";
}
} else if (this._xscale > 76) {
this._xscale = this._xscale - ((this._xscale - 75) * 0.15);
this._yscale = this._yscale - ((this._yscale - 75) * 0.15);
} else {
this.fade = "in";
}
if (this.hitTest(_root.player)) {
if (this.type == "health") {
_root.player.health = 100;
} else if (this.type == "shield") {
_root.player.invincibilityTimer = 300;
} else if (this.type == "berserk") {
MODE_BERSERK = 300;
}
removeMovieClip(this);
}
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
}
};
};
makeWeapon = function (id, x, y, type) {
wpn = attachMovie("mc.generateWeapon", "generateWeapon" + id, 20000 + id);
wpn.type = type;
wpn._x = x;
wpn._y = y;
wpn.id = id;
wpn.fade = "in";
wpn.gotoAndStop(wpn.type);
wpn.onEnterFrame = function () {
this.gotoAndStop(this.type);
if (paused != true) {
if (this.type == undefined) {
this.type = "shotGun";
}
if (this.fade == "in") {
if (this._xscale < 124) {
this._xscale = this._xscale + ((125 - this._xscale) * 0.15);
this._yscale = this._yscale + ((125 - this._yscale) * 0.15);
} else {
this.fade = "out";
}
} else if (this._xscale > 76) {
this._xscale = this._xscale - ((this._xscale - 75) * 0.15);
this._yscale = this._yscale - ((this._yscale - 75) * 0.15);
} else {
this.fade = "in";
}
if (this.hitTest(_root.player)) {
if (this.type != pW.type) {
makePlayerWeapon("player", this.type, true);
} else {
_root["AMMO_" + this.type] = _root["STARTAMMO_" + this.type];
}
for (var _local3 in weapons) {
if (weapons[_local3] == this.type) {
wpNum = _local3;
_root.selectWI(_local3);
break;
}
}
removeMovieClip(this);
}
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
}
};
};
function makePlayerWeapon(tr, ty, am) {
pW = attachMovie("mc.weapon", "pW", 300000);
pW.init = function (trgt, type, ammo) {
pW.trgt = trgt;
pW.type = type;
pW.ammo = ammo;
pW._x = _root.pT._x;
pW._y = _root.pT._y;
if (pW.type == "machineGun") {
pW.ROF = 3;
pW.aC = 4;
pW.sP = 15;
pW.wS = 4;
pW.gS = 5;
pW.depth = 7;
pW.damage = 8;
pW.LN = 46.2;
} else if (pW.type == "m4") {
pW.ROF = 2;
pW.aC = 4;
pW.sP = 15;
pW.wS = 4;
pW.gS = 5;
pW.depth = 12;
pW.damage = 7;
pW.LN = 54.3;
} else if (pW.type == "sniperRifle") {
pW.ROF = 25;
pW.aC = 0;
pW.sP = 15;
pW.wS = 10;
pW.gS = 20;
pW.depth = 1;
pW.damage = 50;
pW.LN = 64.3;
} else if (pW.type == "shotGun") {
pW.ROF = 20;
pW.aC = 0;
pW.sP = 15;
pW.wS = 10;
pW.gS = 20;
pW.depth = 10;
pW.damage = 7;
pW.LN = 43;
} else if (pW.type == "flakCannon") {
pW.ROF = 30;
pW.aC = 30;
pW.sP = 20;
pW.wS = 14;
pW.gS = 20;
pW.depth = 20;
pW.damage = 5;
pW.LN = 42.8;
} else if (pW.type == "assaultRifle") {
pW.ROF = 3;
pW.aC = 2;
pW.sP = 15;
pW.wS = 4;
pW.gS = 7;
pW.depth = 8;
pW.damage = 5;
pW.LN = 45.5;
} else if (pW.type == "usp") {
pW.ROF = 6;
pW.aC = 5;
pW.sP = 15;
pW.wS = 2;
pW.gS = 10;
pW.depth = 8;
pW.damage = 5;
pW.LN = 36.2;
} else if (pW.type == "mp5") {
pW.ROF = 3;
pW.aC = 2;
pW.sP = 15;
pW.wS = 4;
pW.gS = 5;
pW.depth = 6;
pW.damage = 5;
pW.LN = 34.6;
} else if (pW.type == "mac10") {
pW.ROF = 2;
pW.aC = 6;
pW.sP = 15;
pW.wS = 3;
pW.gS = 2;
pW.depth = 8;
pW.damage = 4;
pW.LN = 38;
} else if (pW.type == "stinger") {
pW.ROF = 40;
pW.aC = 0;
pW.sP = 10;
pW.wS = 20;
pW.gS = 15;
pW.depth = 8;
pW.damage = 0;
pW.LN = 32;
} else if (pW.type == "nade") {
pW.ROF = 30;
pW.aC = 0;
pW.sP = 10;
pW.wS = 5;
pW.gS = 20;
pW.depth = 8;
pW.damage = 0;
pW.LN = 44;
} else if (pW.type == "mine") {
pW.ROF = 30;
pW.aC = 0;
pW.sP = 15;
pW.wS = 2;
pW.gS = 0;
pW.depth = 8;
pW.damage = 0;
pW.LN = 40;
} else if (pW.type == "turret") {
pW.ROF = 8;
pW.aC = 0;
pW.sP = 15;
pW.wS = 2;
pW.gS = 0;
pW.depth = 8;
pW.damage = 50;
pW.LN = 5;
}
if (CHEATS[4][2] != false) {
pW.damage = pW.damage * 2;
}
pW.LN = pW.LN + 5;
pW.yBlur = 0;
if (pW.ammo == true) {
_root["AMMO_" + pW.type] = _root["STARTAMMO_" + pW.type];
pW.aM = _root["AMMO_" + pW.type];
}
_root.iF.weaponName = ("<b>weapon type:</b>" + _root.GUISPACE) + getWeaponName(pW.type);
pW.gotoAndStop(pW.type);
pW.onEnterFrame = function () {
if (_root.paused != true) {
if ((_root.blur == true) && (this.type != "turret")) {
if (Math.abs(this.yBlur) > 0) {
this.yBlur = this.yBlur * 0.78;
}
if (Math.abs(_root.iF.cS_y) > Math.abs(_root.iF.cS_x)) {
this.bx = Math.abs(_root.iF.cS_y) / _root.blurRate;
} else {
this.bx = Math.abs(_root.iF.cS_x) / _root.blurRate;
}
if ((_root.iF.cS_y != 0) || (_root.iF.cS_x != 0)) {
this.bx = this.bx + ((random(5) - 2) * _root.blurVar);
}
var _local3 = new flash.filters.BlurFilter(this.bx, this.yBlur, 1);
this.filters = [_local3];
} else {
this.filters = [];
}
}
};
};
pW.init(tr, ty, am);
}
function makePlayer(x, y, HEALTH, LIVES) {
player = attachMovie("mc.player", "player", 299999);
player.onGround = false;
player.onGroundTimer = 0;
player.onSide = false;
player.onSlope = 0;
player.draw = false;
player.crouching = false;
player.upIsDown = false;
player.dIsDown = false;
player.shooting = false;
player.punch = false;
player.kickRunTimer = 0;
player.kickTimer = 0;
player.sT = 0;
if (CHEATS[4][2] != false) {
player.damage = 60;
} else {
player.damage = 30;
}
player.turretCharge = 0;
player.bCount = 0;
player.sCount = 0;
player.blCount = 0;
player.trCount = 0;
player.CURF = 0;
player.rcl = 0;
player.ofst = 0;
player.xM = 0;
player.yM = 0;
player.rL = 0;
player.leechTimer = 0;
player.invincibilityTimer = 100;
player.triRot = 0;
player.facing = 1;
player.x = x;
player.y = y;
player._x = player.x;
player._y = player.y;
player.ox = player._x;
player.oy = player._y;
player.yBlur = 0;
player.health = HEALTH;
player.LIVES = LIVES;
if (CHEATS[3][2] != false) {
player.INC_VX = 4;
player.MAX_VX = 20;
} else {
player.INC_VX = 2;
player.MAX_VX = 10;
}
if (CHEATS[5][2] != false) {
player.INC_VX = player.INC_VX / 5;
}
player.vx = 1;
player.vy = 0;
if (_root.MAPNUMBER == 1) {
player.checkBoss = function (ob) {
if (ob.checkForHit(_root.gBoss)) {
adf = 0;
while (adf < 10) {
if (_root.gBoss.hitTest(ob._x, ob._y, true)) {
ob.createBossRicochetSparks();
ob.hit = true;
if (ob.type != "mine") {
_root.gBoss.hit(ob._x, ob._y, ob.damage, ob._rotation);
}
ob.drawLine(true, _root.gBoss);
break;
}
ob._x = ob._x + (ob.spx / 10);
ob._y = ob._y + (ob.spy / 10);
adf++;
}
}
};
} else if (_root.MAPNUMBER == 2) {
player.checkBoss = function (ob) {
if (ob.checkForHit(_root.chubbs)) {
adf = 0;
while (adf < 4) {
ob._x = ob._x + (ob.spx / 5);
ob._y = ob._y + (ob.spy / 5);
if (_root.chubbs.hitTest(ob._x, ob._y, true)) {
ob.createBossRicochetSparks();
ob.hit = true;
if (ob.type != "mine") {
_root.chubbs.hit(ob._x, ob._y, ob.damage, ob._rotation);
}
ob.drawLine(true, _root.chubbs);
break;
}
adf++;
}
}
};
} else if (_root.MAPNUMBER == 5) {
player.checkBoss = function (ob) {
ob.createBossRicochetSparks = function () {
if (((ob.type != "stinger") && (ob.type != "flakCannon")) && (ob.type != "nade")) {
debr = attachMovie("mc.sparks" + random(2), "sparks" + ob.bCount, 679300 + ob.bCount);
debr._x = ob._x;
debr._y = ob._y;
if (random(2) == 0) {
debr._yscale = -100;
}
debr._xscale = debr._xscale + (random(21) - 10);
debr._yscale = debr._yscale + (random(21) - 10);
debr._rotation = ob._rotation;
}
};
if (ob.checkForHit(_root.rBossS)) {
adf = 0;
while (adf < 4) {
if (_root.rBossS.hitTest(ob._x, ob._y, true)) {
ob.createBossRicochetSparks();
ob.hit = true;
if (_root.rBossT.deploy == true) {
if (ob.type != "mine") {
_root.rBoss.hit(ob._x, ob._y, ob.damage * 2, ob._rotation);
}
}
ob.drawLine(true, _root.rBossS);
break;
}
ob._x = ob._x + (ob.spx / 20);
ob._y = ob._y + (ob.spy / 20);
adf++;
}
}
if (ob.checkForHit(_root.rBossT)) {
adf = 0;
while (adf < 6) {
ob._x = ob._x + (ob.spx / 10);
ob._y = ob._y + (ob.spy / 10);
if (_root.rBossT.hitTest(ob._x, ob._y, true)) {
ob.createBossRicochetSparks();
ob.drawLine(true, _root.rBossT);
ob.hit = true;
break;
}
adf++;
}
}
if (ob.checkForHit(_root.rBoss)) {
adf = 0;
while (adf < 6) {
ob._x = ob._x + (ob.spx / 10);
ob._y = ob._y + (ob.spy / 10);
if (_root.rBoss.hitTest(ob._x, ob._y, true)) {
ob.createBossRicochetSparks();
ob.drawLine(true, _root.rBoss);
ob.hit = true;
break;
}
adf++;
}
}
};
}
player.checkExplosion = function (ob, range, dmg) {
if (CHEATS[4][2] != false) {
ob.dmg = dmg * 2;
ob.range = range * 2;
} else {
ob.dmg = dmg;
ob.range = range;
}
tellTarget (ob) {
enemies = [_root.zombies, _root.grunts, _root.knights, _root.frogs];
abc = 0;
while (abc < enemies.length) {
n = 0;
while (n < enemies[abc].length) {
arr = enemies[abc][n];
if (((enemies[abc] == _root.zombies) || (enemies[abc] == _root.knights)) || (enemies[abc] == _root.grunts)) {
yp = arr._y - (35 * arr.SIZE);
} else {
yp = arr._y - (17 * arr.SIZE);
}
if ((Math.abs(arr._x - _x) < range) && (Math.abs(yp - _y) < (range / 2))) {
arr.hit(_x, _y, dmg - (((Math.abs(arr._x - _x) + Math.abs(yp - _y)) / 2) * 1), random(360));
nm = 0;
while (nm < 4) {
arr.blood((arr._x - (nm * 5)) + random(10), (arr._y - (nm * 5)) + random(10), random(360));
nm++;
}
}
n++;
}
abc++;
}
if ((Math.abs(_root.gBoss._x - _x) < range) && (Math.abs(_root.gBoss._y - _y) < range)) {
_root.gBoss.hit(_x, _y, dmg - (Math.abs(_root.gBoss._x - _x) * 2), random(360));
}
if ((Math.abs(_root.chubbs._x - _x) < range) && (Math.abs(_root.chubbs._y - _y) < range)) {
_root.chubbs.hit(_x, _y, dmg - (Math.abs(_root.chubbs._x - _x) * 2), random(360));
}
if (_root.rBossT.deploy == true) {
if ((Math.abs(_root.rBossS._x - _x) < range) && (Math.abs(_root.rBossS._y - _y) < range)) {
_root.rBoss.hit(_x, _y, dmg, random(360));
}
}
n = 0;
while (n < _root.BLOCKS.length) {
if ((Math.abs((_root.BLOCKS[n]._x + (_root.BLOCKS[n]._width / 2)) - _x) < range) && (Math.abs((_root.BLOCKS[n]._y + (_root.BLOCKS[n]._height / 2)) - _y) < range)) {
bldam = dmg - ((Math.abs((_root.BLOCKS[n]._x + (_root.BLOCKS[n]._width / 2)) - _x) + Math.abs((_root.BLOCKS[n]._y + (_root.BLOCKS[n]._height / 2)) - _y)) / 2);
_root.BLOCKS[n].num = _root.BLOCKS[n].num - bldam;
_root.oN[_root.BLOCKS[n].PLACE] = _root.oN[_root.BLOCKS[n].PLACE] - bldam;
}
n++;
}
};
};
player.onEnterFrame = function () {
if (paused != true) {
if (this.invincibilityTimer > 0) {
if ((this.invincibilityTimer % 10) == 0) {
this._alpha = 50;
_root.pW._alpha = 50;
_root.pS._alpha = 25;
} else if ((this.invincibilityTimer % 5) == 0) {
this._alpha = 100;
_root.pW._alpha = 100;
_root.pS._alpha = 50;
}
} else {
this._alpha = 100;
_root.pW._alpha = 100;
_root.pS._alpha = 50;
}
if (_root.blur == true) {
if (Math.abs(this.yBlur) > 0) {
this.yBlur = this.yBlur * 0.78;
}
if (Math.abs(_root.iF.cS_y) > Math.abs(_root.iF.cS_x)) {
this.bx = Math.abs(_root.iF.cS_y) / _root.blurRate;
} else {
this.bx = Math.abs(_root.iF.cS_x) / _root.blurRate;
}
if ((_root.iF.cS_y != 0) || (_root.iF.cS_x != 0)) {
this.bx = this.bx + ((random(5) - 2) * _root.blurVar);
}
var _local3 = new flash.filters.BlurFilter(this.bx, this.yBlur, 1);
this.filters = [_local3];
} else {
this.filters = [];
}
if (pW.type != "turret") {
if (this.onSlope > 0) {
this.onSlope--;
} else {
this._rotation = 0;
if (this.onGround == true) {
_root.pS._rotation = 0;
}
}
if (Key.isDown(kDn) && (this.onGround == true)) {
}
this.vy = this.vy + _root.GRAVITY;
if (this.onGround == true) {
if ((((!Key.isDown(kLe)) && (!Key.isDown(kRi))) || (Key.isDown(kLe) && (Key.isDown(kRi)))) || (Key.isDown(kDn))) {
this.vx = this.vx * FRICTION;
}
}
this.checkInput();
if (this.facing == 0) {
this._xscale = -100;
} else {
this._xscale = 100;
}
this._x = this._x + this.vx;
this._y = this._y + this.vy;
this.checkBoundaryCollision();
this.triangulate();
this.reduceTimers();
if (this.kickTimer > 0) {
pW._x = pT._x - this.vx;
pW._y = pT._y;
}
if ((((((this.onGround == true) && ((this.onSlope % 2) != 1.5)) && (this.crouching == false)) && (_root.pW.type != "turret")) && ((!Key.isDown(kLe)) && (!Key.isDown(kRi)))) || (Key.isDown(kLe) && (Key.isDown(kRi)))) {
pW._x = pW._x + this.vx;
pW._y = pT._y;
} else {
pW._x = pT._x;
pW._y = pT._y;
}
if (((this.crouching == true) && (Key.isDown(kLe))) && (Key.isDown(kRi))) {
pW._y = pW._y - 1;
}
this.runShooting();
this._visible = true;
} else {
if (pW.type != "turret") {
pW.init("turret", this._name, true);
}
this.triangulate();
this.reduceTimers();
pW._x = pT._x;
pW._y = pT._y;
this.runShooting();
this._visible = false;
}
} else {
this.filters = [];
}
if (((this._y > 1500) && (_root.gBoss.dying != true)) && (_root.rBoss.dying != true)) {
_root.paused = true;
_root.iF.fadeScreen.fade = "in";
if (_root.iF.fadeScreen._alpha >= 100) {
}
}
if (this.health < 0) {
this.health = 0;
}
if (this.health > 100) {
this.health = 100;
}
iF.playerHealth = Math.round(this.health) + " %";
if ((((this.health <= 0) && (_root.gBoss.dying != true)) && (_root.rBoss.dying != true)) && (!((_root.MAPNUMBER == 3) && (_root.KILLS >= 22)))) {
_root.paused = true;
_root.iF.fadeScreen.fade = "in";
if (_root.iF.fadeScreen._alpha >= 100) {
}
}
if ((_root.MAPNUMBER == 2) && (_root.KILLS == 12)) {
_root.iF.fadeScreen.fade = "in";
if (_root.iF.fadeScreen._alpha >= 100) {
_root.MAPNUMBER = 3;
_root.reset();
}
}
};
player.takeDamage = function (dmg) {
if ((this.invincibilityTimer == 0) && (CHEATS[0][2] != true)) {
this.health = this.health - dmg;
if (dmg > iF.damageScreen._alpha) {
iF.damageScreen._alpha = dmg;
}
}
};
player.triangulate = function () {
if (paused != true) {
pT = createEmptyMovieClip("pT", 5005);
pT._y = player._y - 22;
if ((player.facing == 1) && (pW.type != "turret")) {
pT._x = player._x - 2;
} else {
pT._x = player._x + 2;
}
if (((this.crouching == true) && (_root.pW.type != "turret")) && (this.kickTimer == 0)) {
pT._y = pT._y + 32;
if (((_root.player._rotation == 25) && (_root.player.facing == 1)) || ((_root.player._rotation == -25) && (_root.player.facing == 0))) {
if (_root.player._rotation == 25) {
pT._x = pT._x - 5.5;
} else {
pT._x = pT._x + 5.5;
}
pT._y = pT._y - 1;
}
if (((_root.player._rotation == -25) && (_root.player.facing == 1)) || ((_root.player._rotation == 25) && (_root.player.facing == 0))) {
if (_root.player._rotation == 25) {
pT._x = pT._x - 5.5;
} else {
pT._x = pT._x + 5.5;
}
pT._y = pT._y - 1;
}
} else {
pT._y = pT._y + 1;
if (_root.player._rotation == 25) {
pT._x = pT._x + 10;
}
if (_root.player._rotation == -25) {
pT._x = pT._x - 10;
}
}
this.xM = this.xM - ((this.xM - pT._xmouse) * 0.3);
this.yM = this.yM + ((pT._ymouse - this.yM) * 0.3);
this.an = Math.atan(((-this.yM) + this.ofst) / this.xM) / 0.0174444444444444;
if (this.xM < 0) {
this.an = this.an + 180;
}
if ((this.xM >= 0) && (this.yM < 0)) {
this.an = this.an + 360;
}
if (pT._xmouse > 0) {
pW._yscale = 100;
this.an = this.an + this.rcl;
if (pW.type != "turret") {
this.ofst = -3;
} else {
this.ofst = -7;
}
} else {
pW._yscale = -100;
this.an = this.an - this.rcl;
if (pW.type != "turret") {
this.ofst = 3;
} else {
this.ofst = 7;
}
}
this.ang = (-this.an) + 360;
this.yPt = this._ymouse;
pW._rotation = -Math.round(this.an);
onMouseDown = function () {
player.shooting = true;
};
onMouseUp = function () {
if (pW.type == "turret") {
turret0.fire(player.turretCharge, pW._rotation);
}
player.shooting = false;
player.turretCharge = 0;
};
}
};
player.checkInput = function () {
if ((!Key.isDown(kDn)) && (this.kickTimer == 0)) {
if (Key.isDown(kLe) && (!Key.isDown(kRi))) {
if (this.vx > (-this.MAX_VX)) {
this.vx = this.vx - this.INC_VX;
}
this.facing = 0;
} else if (Key.isDown(kRi) && (!Key.isDown(kLe))) {
if (this.vx < this.MAX_VX) {
this.vx = this.vx + this.INC_VX;
}
this.facing = 1;
}
if (Key.isDown(kKick) && (this.kickRunTimer == 0)) {
this.kickTimer = 18;
this.kickRunTimer = 24;
}
}
if ((this.onGroundTimer < 6) && (this.kickTimer == 0)) {
if (Key.isDown(kUp)) {
this.vy = -15;
this.onGroundTimer++;
this.onSlope = 0;
} else if (this.onGround == false) {
this.onGroundTimer = 6;
}
}
if (this.onGround == true) {
if (this.kickTimer == 0) {
if (!Key.isDown(_root.kDn)) {
if (Key.isDown(_root.kLe) && (!Key.isDown(_root.kRi))) {
this.anim = "Run";
} else if (Key.isDown(_root.kRi) && (!Key.isDown(_root.kLe))) {
this.anim = "Run";
} else {
this.anim = "Idle";
}
} else {
this.anim = "Crouch";
}
} else {
this.anim = "Kick";
}
} else if (this.kickTimer == 0) {
if (this.vy < -2) {
this.anim = "Up";
} else {
this.anim = "Fall";
}
} else {
this.anim = "Kick";
}
this.gotoAndStop(this.anim);
_root.pS._x = this._x;
if (_root.motionTrail) {
this.tra = _root.attachMovie("mc.player", "playerTrail" + this.trCount, 295999 + this.trCount);
this.tra._x = this._x + this.vx;
this.tra._y = this._y + this.vy;
this.tra._xscale = this._xscale;
this.tra._yscale = this._yscale;
this.tra._alpha = 50;
this.tra._visible = false;
this.tra.gotoAndStop(this.anim);
this.traw = _root.attachMovie("mc.weapon", "pWTrail" + this.trCount, 296999 + this.trCount);
this.traw._x = _root.pW._x + this.vx;
this.traw._y = _root.pW._y + this.vy;
this.traw._yscale = _root.pW._yscale;
this.traw._alpha = 50;
this.traw._visible = false;
this.traw._rotation = _root.pW._rotation;
this.traw.gotoAndStop(_root.pW.type);
this.traw.onEnterFrame = function () {
if (this._alpha < 60) {
this._visible = true;
}
this._alpha = this._alpha - 10;
};
this.tra.onEnterFrame = function () {
if (this._alpha < 60) {
this._visible = true;
}
this._alpha = this._alpha - 10;
};
if (this.trCount < 5) {
this.trCount++;
} else {
this.trCount = 0;
}
}
};
player.reduceTimers = function () {
if (this.kickTimer > 0) {
this.kickTimer--;
}
if (this.kickRunTimer > 0) {
this.kickRunTimer--;
}
if (this.leechTimer > 0) {
this.leechTimer--;
}
if (this.invincibilityTimer > 0) {
this.invincibilityTimer--;
}
if (this.sT != 0) {
this.sT--;
}
if (this.rL != 0) {
this.rL--;
iF.aM_Text = ("<b>ammunition:</b>" + _root.GUISPACE) + "reloading";
} else if ((pW.type != "usp") && (pW.type != "turret")) {
iF.aM_Text = ((("<b>ammunition:</b>" + _root.GUISPACE) + _root["AMMO_" + pW.type]) + " / ") + _root["STARTAMMO_" + pW.type];
} else {
iF.aM_Text = ("<b>ammunition:</b>" + _root.GUISPACE) + "unlimited";
}
if (this.rcl > 0) {
this.rcl = this.rcl * 0.81;
}
};
player.checkBoundaryCollision = function () {
tellTarget (this) {
eS_x = 18;
eS_y = 35;
eL = _x - eS_x;
eR = _x + eS_x;
eT = _y - eS_y;
eB = _y + eS_y;
if ((vy > _root.GRAVITY) || (vy < (-_root.GRAVITY))) {
if (onSlope <= 0) {
onGround = false;
}
}
if ((_y + eS_y) > (_root.mS + 16)) {
_y = ((_root.mS + 16) - eS_y);
vy = 0;
onGround = true;
}
};
};
player.runShooting = function () {
if (this.shooting == true) {
if (pW.type == "turret") {
if (this.turretCharge < 100) {
this.turretCharge = this.turretCharge + 5;
}
this.tShake = this.turretCharge / 15;
_root.iF.cS_x = _root.iF.cS_x + (random(this.tShake) - (this.tShake / 2));
_root.iF.cS_y = _root.iF.cS_y + (random(this.tShake) - (this.tShake / 2));
}
if ((((this.sT == 0) && (_root["AMMO_" + pW.type] > 0)) && (this.rL == 0)) && (pW.type != "turret")) {
this.draw = true;
if (_root.SHELLSON) {
rotatT = pW._rotation;
makeShell(this.sCount, pT._x + (Math.cos((rotatT / 180) * 3.14) * _root.toShell), pT._y + (Math.sin(((rotatT + this.ofst) / 180) * 3.14) * _root.toShell), rotatT);
if (this.sCount < 20) {
this.sCount++;
} else {
this.sCount = 0;
}
}
var _local4 = new Sound(this);
_local4.attachSound(("audio." + pW.type) + ".wav");
_local4.start(0, 0);
_local4.setVolume(_root.VOLUME_SFX);
n = 0;
while (n < _root.nB) {
b = attachMovie("mc.bullet", "b" + this.bCount, 10000 + this.bCount);
b.ofst = this.ofst;
b.n = n;
tellTarget (b) {
type = _root.pW.type;
rotat = _root.pW._rotation;
pW_rotx = Math.cos((rotat / 180) * 3.14);
pW_roty = Math.sin((rotat / 180) * 3.14);
_x = ((_root.pT._x + (pW_rotx * _root.TOTAL_LN)) - (pW_roty * ofst));
_y = ((_root.pT._y + (pW_roty * _root.TOTAL_LN)) + (pW_rotx * ofst));
start_x = _x;
start_y = _y;
if (type == "shotGun") {
_rotation = (((rotat - 10) + (n * 5)) + (random(3) - 1));
} else if (type == "flakCannon") {
_rotation = (((rotat - 20) + (n * 4)) + (random(5) - 2));
vy = 0;
} else {
_rotation = ((rotat + random((_root.pW.aC * 2) + 1)) - _root.pW.aC);
}
b_rotx = Math.cos((_rotation / 180) * 3.14);
b_roty = Math.sin((_rotation / 180) * 3.14);
};
_root.iF.cS_x = b.b_rotx * TOTAL_WS;
_root.iF.cS_y = b.b_roty * TOTAL_WS;
b.bCount = this.bCount;
if (this.bCount < 10) {
this.bCount++;
} else {
this.bCount = 0;
}
tellTarget (b) {
if (_root.BULLETSON) {
sP = 50;
rays = 100;
_visible = false;
inc = 8;
drawLine = function (remove) {
_root.player.end_x = this._x;
_root.player.end_y = this._y;
ln = _root.createEmptyMovieClip("ln" + this.bCount, 60000 + this.bCount);
ln.moveTo(this.start_x, this.start_y);
ln.lineStyle(2, 16777215, 100);
ln.lineTo(this._x, this._y);
ln.onEnterFrame = function () {
if (_root.paused != true) {
if (this._alpha > 0) {
this._alpha = this._alpha - 50;
} else {
removeMovieClip(this);
}
}
};
if (remove == true) {
removeMovieClip(this);
}
};
checkForHit = function (arr) {
if (((this._x + this.spx) >= arr.eL) && ((this._x + this.spx) <= arr.eR)) {
if (((this._y + this.spy) >= arr.eT) && (this._y < arr.eT)) {
this._y = arr.eT;
this._x = this._x + (this.spx / 2);
this.HITT = true;
} else if (((this._y + this.spy) <= arr.eB) && (this._y > arr.eB)) {
this._y = arr.eB;
this._x = this._x + (this.spx / 2);
this.HITT = true;
}
}
if (((this._y + this.spy) >= arr.eT) && ((this._y + this.spy) <= arr.eB)) {
if (((this._x + this.spx) >= arr.eL) && (this._x < arr.eL)) {
this._x = arr.eL;
this._y = this._y + (this.spy / 2);
this.HITT = true;
} else if (((this._x + this.spx) <= arr.eR) && (this._x > arr.eR)) {
this._x = arr.eR;
this._y = this._y + (this.spy / 2);
this.HITT = true;
}
}
return(this.HITT);
};
} else {
inc = 1;
checkForHit = function (arr) {
return(arr.hitTest(this));
};
if (type == "flakCannon") {
sP = (_root.pW.sP - 7.5) + random(16);
_visible = true;
spin = random(41) - 20;
rays = 1;
if (random(2) == 0) {
gotoAndStop ("flakCannon1");
_xscale = (35 + random(65));
_yscale = (35 + random(65));
} else {
gotoAndStop ("flakCannon2");
_xscale = (70 + random(30));
_yscale = (70 + random(30));
}
} else if (type == "mine") {
sP = 8;
_visible = true;
rays = 2;
sP = 7;
vy = 0;
bounce = 0.5;
spin = 0;
_xscale = 50;
_yscale = 50;
_rotation = (_rotation + 180);
detonate = function () {
exp = _root.attachMovie("mc.explosionMine", "explosionStinger896732" + this.bCount, 874582 + this.bCount);
exp._x = this._x;
exp._y = this._y;
if (this._rotation == -90) {
exp._rotation = this._rotation + 90;
} else {
exp._rotation = -25 + random(51);
}
if (random(2) == 0) {
exp._xscale = -100;
}
exp._xscale = exp._xscale * ((90 + random(21)) / 100);
exp._yscale = exp._yscale * ((90 + random(21)) / 100);
_root.soundfx(this._x, ("audio.explode" + random(3)) + ".wav");
removeMovieClip(this);
};
} else if (type == "nade") {
_visible = true;
rays = 2;
sP = 8;
vy = 0;
bounce = 0.5;
lifeTimer = 50;
spin = 0;
createMotionTrail = function () {
this.vy = this.vy + 0.1;
this._y = this._y + this.vy;
this._rotation = this._rotation + (this.spin / 2);
};
drawLine = function (remove) {
if (remove == true) {
exp = _root.attachMovie("mc.explosionNade", "explosionNade896732" + this.bCount, 896732 + this.bCount);
exp._x = this._x;
exp._y = this._y;
exp._rotation = this._rotation;
_root.soundfx(this._x, ("audio.explode" + random(3)) + ".wav");
removeMovieClip(this);
}
};
} else if (type == "stinger") {
_visible = true;
rays = 8;
smokeCount = 0;
sP = 8;
createSmoke = function () {
smoke = _root.attachMovie("mc.smokeParticle", ("smokeParticle" + (this.bCount * 30)) + this.smokeCount, (387900 + (this.bCount * 30)) + this.smokeCount);
smoke._x = this._x + (random(6) - 3);
smoke._y = this._y + (random(6) - 3);
smoke._xscale = 70;
smoke._yscale = 70;
smoke.vy = 0;
if (this.smokeCount < 120) {
this.smokeCount++;
} else {
this.smokeCount = 0;
}
};
drawLine = function (remove) {
if (remove == true) {
exp = _root.attachMovie("mc.explosionStinger", "explosionStinger896732" + this.bCount, 896732 + this.bCount);
exp._x = this._x;
exp._y = this._y;
exp._rotation = this._rotation;
_root.soundfx(this._x, ("audio.explode" + random(3)) + ".wav");
removeMovieClip(this);
}
};
}
}
if (type != "flakCannon") {
gotoAndStop(type);
}
if (type != "mine") {
damage = _root.pW.damage * 3;
} else {
damage = 0;
}
rot = _rotation;
hit = false;
de = false;
spx = b_rotx * sP;
spy = b_roty * sP;
insx = spx / (sP / inc);
insy = spy / (sP / inc);
dead = false;
};
b.checkBoss = function () {
_root.player.checkBoss(this);
};
if (b.type == "mine") {
_root.MINES.push(b);
}
b.onEnterFrame = function () {
if ((paused != true) && (this.type != "turret")) {
if ((this.type == "flakCannon") || (this.type == "mine")) {
tellTarget (this) {
if (de != true) {
vy = vy + 0.25;
_y = (_y + vy);
_rotation = (_rotation + spin);
}
};
}
if (this.type == "nade") {
if (this.lifeTimer > 0) {
this.lifeTimer--;
} else {
this._rotation = 90;
this.drawLine(true);
}
}
if (!this.de) {
m = 0;
while (m < this.rays) {
this.enemies = [_root.zombies, _root.grunts, _root.knights, _root.frogs];
abc = 0;
while (abc < this.enemies.length) {
num = 0;
while (num < this.enemies[abc].length) {
this.arr = this.enemies[abc][num];
this.HITT = this.checkForHit(this.arr);
if (this.HITT) {
this.arrs = this.arr.SIZE;
if (this.type == "flakCannon") {
this.dmga = this.damage / this.arrs;
} else {
this.dmga = this.damage;
}
this.msx = this.insx * this.arrs;
this.msy = this.insy * this.arrs;
if (this.type != "mine") {
adf = 0;
while (adf < 5) {
this._x = this._x + this.msx;
this._y = this._y + this.msy;
if (this.arr.hitTest(this._x, this._y, true)) {
this.hit = true;
this.arr.hit(this._x, this._y, this.dmga, this._rotation);
this.drawLine(true, this.arr);
break;
}
adf++;
}
}
}
num++;
}
abc++;
}
this.checkBoss();
for (var _local3 in _root.BLOCKS) {
obnu = _root.BLOCKS[_local3];
if (this.checkForHit(obnu)) {
if (Math.abs(_root.player._y - obnu._y) > Math.abs(_root.player._x - obnu._x)) {
if (_root.player._y < obnu._y) {
this._rotation = 90;
this._y = obnu._y;
if (this.type == "nade") {
this.spy = this.spy * -0.5;
this.vy = this.vy * -0.5;
this.spx = this.spx * 0.9;
} else if (this.type == "mine") {
this.spy = 0;
this.vy = 0;
this.spx = 0;
this._rotation = 270;
}
} else {
this._rotation = 270;
this._y = obnu._y + obnu._height;
if (this.type == "nade") {
this.spy = this.spy * -0.5;
this.vy = this.vy * -0.5;
this.spx = this.spx * 0.9;
} else if (this.type == "mine") {
this.spy = 0;
this.vy = 0;
this.spx = 0;
this._rotation = 90;
}
}
} else if (_root.player._x < obnu._x) {
this._rotation = 0;
this._x = obnu._x;
if (this.type == "nade") {
this.spy = this.spy * 0.9;
this.spx = this.spx * -0.5;
} else if (this.type == "mine") {
this.spy = 0;
this.vy = 0;
this.spx = 0;
this._rotation = 180;
}
} else {
this._rotation = 180;
this._x = obnu._x + obnu._width;
if (this.type == "nade") {
this.spy = this.spy * 0.9;
this.spx = this.spx * -0.5;
} else if (this.type == "mine") {
this.spy = 0;
this.vy = 0;
this.spx = 0;
this._rotation = 0;
}
}
_root._rotation = 0;
_root.oN[obnu.PLACE] = _root.oN[obnu.PLACE] - this.damage;
obnu.num = obnu.num - this.damage;
if (this.type == "mine") {
this.de = true;
}
if ((this.type != "nade") && (this.type != "mine")) {
this.drawLine(true);
}
}
}
if (this.type != "flakCannon") {
for (var _local3 in _root.VISIBLE) {
nu = _root.VISIBLE[_local3];
obnu = _root.scr[nu];
if (((_root.oT[nu] == "platform") || (_root.oT[nu] == "static")) && ((_root.oW[nu] == 128) || (_root.oW[nu] == 16))) {
if (this.checkForHit(obnu)) {
if (_root.oW[nu] == 128) {
if (_root.player._y < obnu._y) {
this._rotation = 90;
this._y = obnu._y;
if ((((this.type != "stinger") && (this.type != "flakCannon")) && (this.type != "nade")) && (this.type != "mine")) {
if (_root.GRASS) {
if ((_root.MAPNUMBER == 4) || (_root.MAPNUMBER == "Survival")) {
this.gtip = "mc.debrisGrass2";
} else {
this.gtip = "mc.debrisGrass1";
}
debr = _root.attachMovie(this.gtip, "debrisGrass" + this.bCount, 679300 + this.bCount);
debr._rotation = this._rotation - 90;
if (random(2) == 0) {
debr._xscale = -100;
}
} else {
debr = _root.attachMovie("mc.sparks" + random(2), "sparks" + this.bCount, 679300 + this.bCount);
debr._rotation = this._rotation + 180;
if (random(2) == 0) {
debr._yscale = -100;
}
}
debr._x = this._x;
debr._y = this._y;
debr._xscale = debr._xscale + (random(21) - 10);
debr._yscale = debr._yscale + (random(21) - 10);
} else if (this.type == "nade") {
this.spin = (random(41) - 20) * (this.spy / 8);
if (this.spx > 0) {
this._rotation = 0;
} else {
this._rotation = 180;
}
} else if (this.type == "mine") {
this.de = true;
this.vy = 0;
this.spy = 0;
this._rotation = 270;
this._x = this._x + this.spx;
this.spx = 0;
}
} else {
this._rotation = 270;
this._y = obnu._y + obnu._height;
if (this.type == "nade") {
this._y = this._y + 5;
}
if (this.type == "mine") {
this.de = true;
this.vy = 0;
this.spy = 0;
this._x = this._x + this.spx;
this.spx = 0;
this._rotation = 90;
}
}
this.spy = this.spy * -0.5;
this.spx = this.spx * 0.9;
this.vy = this.vy * -0.5;
} else if (_root.oW[nu] == 16) {
if (_root.player._x < obnu._x) {
this._rotation = 0;
this._x = obnu._x;
if (this.type == "mine") {
this.de = true;
this.vy = 0;
this.spy = 0;
this.spx = 0;
this._rotation = 180;
}
} else {
this._rotation = 180;
this._x = obnu._x + obnu._width;
if (this.type == "mine") {
this.de = true;
this.vy = 0;
this.spy = 0;
this.spx = 0;
this._rotation = 0;
}
}
this.spx = this.spx * -0.5;
}
if ((this.type != "nade") && (this.type != "mine")) {
this.drawLine(true);
}
}
} else if (obnu.hitTest(this._x, this._y, true)) {
if (_root.oT[nu] != "static") {
if (_root.oT[nu] == "target") {
_root.oW[nu] = undefined;
this.hit = true;
this.drawLine(true);
} else {
this.hit = true;
if ((this.type != "nade") && (this.type != "mine")) {
this.drawLine(true);
}
}
}
}
}
}
_root._rotation = 0;
if (this.hit == false) {
this.drawLine(false);
}
_root._rotation = 0;
this._x = this._x + this.spx;
this._y = this._y + this.spy;
this.createSmoke();
this.createMotionTrail();
if ((((this._x > (_root.iF._x + 260)) || (this._x < (_root.iF._x - 260))) || (this._y > (_root.iF._y + 210))) || (this._y < (_root.iF._y - 210))) {
if (((this.type != "stinger") && (this.type != "nade")) && (this.type != "mine")) {
this.drawLine(true);
}
if ((this.type != "mine") && (this.type != "nade")) {
this.removeMovieClip(this);
}
}
m++;
}
}
}
};
n++;
}
if ((((pW.type != "flakCannon") && (pW.type != "mine")) && (pW.type != "stinger")) && (pW.type != "nade")) {
mf = attachMovie("mc.muzzleFlash" + random(6), "muzzleFlash" + this.bCount, 94000 + this.bCount);
tellTarget (mf) {
_x = _root.b._x;
_y = _root.b._y;
_rotation = _root.b._rotation;
onEnterFrame = function () {
if (_root.paused != true) {
if (this._alpha > 0) {
this._alpha = this._alpha - 40;
} else {
removeMovieClip(this);
}
}
};
};
}
this.rcl = pW.gS;
if (MODE_BERSERK > 0) {
this.sT = Math.floor(pW.ROF / 1.5);
} else {
this.sT = pW.ROF;
}
if (CHEATS[1][2] != true) {
_root["AMMO_" + pW.type]--;
}
}
}
};
}
realHitTest = function (o, p) {
};
function getWeaponName(nm) {
if (nm == "usp") {
NAME = "USP";
} else if (nm == "assaultRifle") {
NAME = "G36k";
} else if (nm == "shotGun") {
NAME = "Spaz 12";
} else if (nm == "m4") {
NAME = "M16 A2";
} else if (nm == "machineGun") {
NAME = "L85";
} else if (nm == "flakCannon") {
NAME = "Flak Cannon";
} else if (nm == "sniperRifle") {
NAME = "Sniper Rifle";
} else if (nm == "mac10") {
NAME = "MAC 10";
} else if (nm == "mp5") {
NAME = "MP5k";
} else if (nm == "stinger") {
NAME = "Stinger";
} else if (nm == "nade") {
NAME = "Nade Launcher";
} else if (nm == "mine") {
NAME = "Mine Layer";
} else if (nm == "turret") {
NAME = "Laser Turret";
}
if (NAME == undefined) {
NAME == "USP";
}
return(NAME);
}
function loadGame() {
_root.MENU = false;
clearInterval(_root.rb);
_root.clearInterval(_root.rb);
clearInterval(_root.mSinterval);
_root.clearInterval(_root.mSinterval);
CLEAR = createEmptyMovieClip("Clear", 300);
ad = 0;
while (ad < 200) {
removeMovieClip(_root["box" + ad]);
ad++;
}
paused = false;
MODE_BERSERK = 0;
MINES = [];
BULLETSON = true;
SHELLSON = true;
updateNL = function () {
if ((((((((MAPNUMBER == 1) || (MAPNUMBER == "Training")) || (MAPNUMBER == "Survival")) || (MAPNUMBER == "SurvivalZombie")) || (MAPNUMBER == "SurvivalKnight")) || (MAPNUMBER == "Destruction")) || (MAPNUMBER == "DestructionSD")) || (MAPNUMBER == "NadeDodger")) {
NL = true;
} else {
NL = false;
}
};
updateNL();
STARTAMMO_machineGun = 120;
STARTAMMO_m4 = 160;
STARTAMMO_sniperRifle = 30;
STARTAMMO_shotGun = 30;
STARTAMMO_flakCannon = 20;
STARTAMMO_assaultRifle = 80;
STARTAMMO_mp5 = 100;
STARTAMMO_mac10 = 110;
STARTAMMO_stinger = 10;
STARTAMMO_nade = 10;
STARTAMMO_mine = 8;
STARTAMMO_usp = 999999 /* 0x0F423F */;
STARTAMMO_turret = 999999 /* 0x0F423F */;
if (NL) {
AMMO_machineGun = 0;
AMMO_m4 = 0;
AMMO_sniperRifle = 0;
AMMO_shotGun = 0;
AMMO_flakCannon = 0;
AMMO_assaultRifle = 0;
AMMO_mp5 = 0;
AMMO_mac10 = 0;
AMMO_usp = 0;
AMMO_stinger = 0;
AMMO_nade = 0;
AMMO_mine = 0;
AMMO_turret = 999999 /* 0x0F423F */;
LEVELAMMO = [AMMO_usp, AMMO_mac10, AMMO_mp5, AMMO_assaultRifle, AMMO_machineGun, AMMO_m4, AMMO_shotGun, AMMO_flakCannon, AMMO_sniperRifle, AMMO_stinger, AMMO_nade, AMMO_mine];
}
BLOCKS_DESTROYED = 0;
var _local4 = false;
var _local3 = false;
GRAVITY = 1;
DRAG = 0.99;
BOUNCE = 0.5;
if (CHEATS[5][2] != false) {
FRICTION = 0.98;
} else {
FRICTION = 0.8;
}
KILLS = 0;
nZ = 0;
nG = 0;
nF = 0;
nK = 0;
LIVES = 1;
HEALTH = 100;
inTurret = false;
nadeTrails = 0;
Object.registerClass("mc.shadow", shadow);
if (MAPNUMBER == 2) {
start_x = -500;
start_y = -500;
} else if (((MAPNUMBER == "Destruction") || (MAPNUMBER == "DestructionSD")) || (MAPNUMBER == "Survival")) {
start_x = 675;
start_y = 534;
} else if (_root.MAPNUMBER == 5) {
start_x = 450;
start_y = 0;
} else {
start_x = 150;
start_y = 534;
}
makePlayer(start_x, start_y, HEALTH, LIVES);
if (MAPNUMBER == "Secret") {
makePlayerWeapon("player", "nade", true);
_root.AMMO_nade = 1;
_root.AMMO_usp = 0;
} else if (NL) {
makePlayerWeapon("player", "usp", true);
} else if (MAPNUMBER == OLDMAPNUMBER) {
pW.type = LEVELWEAPON;
pW.gotoAndStop(LEVELWEAPON);
pW.init(player, LEVELWEAPON, false);
}
if (pW.type == "turret") {
pW.type = "usp";
pW.gotoAndStop(pW.type);
}
_root.iF.weaponName = ("<b>weapon type:</b>" + _root.GUISPACE) + getWeaponName(_root.pW.type);
LEVELWEAPON = _root.pW.type;
OLDMAPNUMBER = MAPNUMBER;
pS = attachMovie("mc.shadow", "pS", 5001);
pS.init(player);
if ((((CHEATS[2][2] != false) || (MAPNUMBER == "Destruction")) || (MAPNUMBER == "DestructionSD")) || (MAPNUMBER == "Survival")) {
this.nweapons = ["machineGun", "mac10", "mp5", "assaultRifle", "shotGun", "m4", "sniperRifle", "flakCannon", "stinger", "nade", "mine"];
this.we = 0;
while (this.we < this.nweapons.length) {
_root.makeWeapon(9 + this.we, _root.player._x, _root.player._y, this.nweapons[this.we]);
this.we++;
}
}
if (MAPNUMBER == "NadeDodger") {
makePlayerWeapon("player", "usp", false);
AMMO_usp = 0;
}
updateONS = function () {
if ((((pW.type != "stinger") && (pW.type != "flakCannon")) && (pW.type != "nade")) && (pW.type != "mine")) {
SHELLSON = true;
BULLETSON = true;
} else {
SHELLSON = false;
BULLETSON = false;
}
if (pW.type == "shotGun") {
_root.nB = 5;
} else if (pW.type == "flakCannon") {
_root.nB = 10;
} else {
_root.nB = 1;
}
if ((pW.type == "usp") || (pW.type == "mac10")) {
_root.toShell = 27;
} else if (pW.type == "mp5") {
_root.toShell = 21;
} else {
_root.toShell = 18;
}
TOTAL_LN = pW.LN;
TOTAL_WS = pW.wS;
};
updateONS();
MN = _root.MAPNUMBER;
if (((((MN == 1) || (MN == "Survival")) || (MN == "Destruction")) || (MN == "DestructionSD")) || (MN == 4)) {
GRASS = true;
} else {
GRASS = false;
}
}
Frame 7
T = getTimer();
loadMap(MAPNUMBER);
stopAllSounds();
Frame 8
mapInit();
stop();
if (T == undefined) {
gT = getTimer();
} else {
gT = getTimer() - T;
}
iF.loadTime = (((("<b>load time:</b>" + _root.GUISPACE) + Math.floor(gT / 1000)) + ".") + (gT - (Math.floor(gT / 1000) * 1000))) + " sec.";
shadow.prototype = new MovieClip();
shadow = function () {
};
shadow.prototype.init = function (trgt) {
this.trgt = trgt;
this.x = this.trgt._x;
this.y = -10000;
this._x = this.x;
this._y = this.y;
this.yB = -10000;
this.onEnterFrame = this.tick;
this._xscale = 150;
this._yscale = 150;
this._alpha = 50;
};
shadow.prototype.tick = function () {
if (paused != true) {
this._x = this.trgt._x;
this.yB = 100000 /* 0x0186A0 */;
for (var _local3 in VISIBLE) {
n = _root.VISIBLE[_local3];
if ((oX[n] < this.trgt._x) && ((oX[n] + oW[n]) > this.trgt._x)) {
if (oT[n] == "30_60_90Triangle_R") {
this.pX = ((oY[n] + (0.5 * (scr[n]._x - this._x))) + oH[n]) - 5;
if ((this.pX < this.yB) && (this.pX > (this.trgt._y - this.trgt.eS_y))) {
this.yB = ((oY[n] + (0.5 * (scr[n]._x - this._x))) + oH[n]) - 5;
this._rotation = -25;
}
}
if (oT[n] == "30_60_90Triangle_L") {
this.pX = (oY[n] + (0.5 * (this._x - scr[n]._x))) - 5;
if ((this.pX < this.yB) && (this.pX > (this.trgt._y - this.trgt.eS_y))) {
this.yB = this.pX;
this._rotation = 25;
}
}
if (oT[n] == "platform") {
if (_root.KILLS >= oN[n]) {
if ((oY[n] < this.yB) && (oY[n] > (this.trgt._y - this.trgt.eS_y))) {
this.yB = oY[n];
this._rotation = 0;
}
}
}
}
}
this._y = this.yB;
}
};
loadGame();
Instance of Symbol 1632 MovieClip "musicPath" in Frame 8
onClipEvent (load) {
newMusic = function (newSong) {
sd = newSong;
music.stop();
this.stopAllSounds();
music = new Sound(this);
music.attachSound(sd);
music.start(0, 999);
music.setVolume(_root.VOLUME_MUSIC);
_root.CURRENTMUSIC = sd;
};
if (_root.MAPNUMBER == 1) {
sd = "audio.LightsAndSounds.wav";
} else if (_root.MAPNUMBER == 2) {
sd = "audio.unfinishedBusiness.wav";
} else if (_root.MAPNUMBER == 3) {
sd = "audio.MysticCaveZone.wav";
} else if (_root.MAPNUMBER == 4) {
sd = "audio.FlyingBatteryZone.wav";
} else if (_root.MAPNUMBER == 5) {
sd = "audio.MelodicSolace.wav";
} else if ((_root.MAPNUMBER / _root.MAPNUMBER) != 1) {
ra = random(4);
if (ra == 0) {
sd = "audio.FlyingBatteryZone.wav";
} else if (ra == 1) {
sd = "audio.MelodicSolace.wav";
} else if (ra == 2) {
sd = "audio.MysticCaveZone.wav";
} else {
sd = "audio.LightsAndSounds.wav";
}
} else {
sd = "audio.LightsAndSounds.wav";
}
newMusic(sd);
}
Frame 9
rolling = false;
timer = 100;
this.onEnterFrame = function () {
if (rolling) {
CREDITS._y = CREDITS._y - 1;
if (_root.CREDITS._y < 0) {
_root.quit();
}
if (btn_mainMenu._alpha < 100) {
btn_mainMenu._alpha = btn_mainMenu._alpha + 5;
}
} else if (timer > 0) {
if (ba._alpha > 0) {
ba._alpha = ba._alpha - 5;
} else if (bb._alpha > 0) {
bb._alpha = bb._alpha - 5;
} else {
timer--;
}
} else if ((ba._alpha < 100) && (bb._alpha < 100)) {
ba._alpha = ba._alpha + 5;
bb._alpha = bb._alpha + 5;
} else {
rolling = true;
}
};
Symbol 8 Button
on (press) {
_root.reset();
}
Symbol 10 Button
on (press) {
_root.quit();
}
Symbol 12 Button
on (press) {
getURL ("http://www.stickpage.com/", "_blank");
}
Symbol 13 MovieClip Frame 1
function noobSFX(name) {
soundeffect = _root.createEmptyMovieClip("menusfx", 30405521);
var _local2 = new Sound(soundeffect);
_local2.attachSound(name);
_local2.start(0, 0);
_local2.setPan(0);
_local2.setVolume(_root.VOLUME_SFX);
}
function loadButtons() {
n = 0;
while (n < buttons.length) {
buttons[n].bl = 0;
buttons[n].w = buttons[n]._width;
buttons[n].h = buttons[n]._height;
buttons[n].x = buttons[n]._x;
buttons[n].y = buttons[n]._y;
buttons[n].a = 80;
buttons[n].blurTimer = n * 10;
buttons[n].onRollOver = function () {
if (this.sL == false) {
noobSFX("benelli_insertshell.wav");
}
m = 0;
while (m < buttons.length) {
buttons[m].sL = false;
m++;
}
this.sL = true;
};
buttons[n].onPress = function () {
noobSFX("button14.wav");
};
n++;
}
}
function runButtons() {
n = 0;
while (n < buttons.length) {
if (buttons[n].sL == true) {
buttons[n]._width = buttons[n]._width + (((buttons[n].w * 2) - buttons[n]._width) * 0.4);
buttons[n]._height = buttons[n]._height + (((buttons[n].h * 2) - buttons[n]._height) * 0.4);
buttons[n]._x = buttons[n].x;
buttons[n]._y = buttons[n].y;
buttons[n]._alpha = 100;
buttons[n].bl = buttons[n].bl * 0.95;
} else {
buttons[n]._width = buttons[n]._width + ((buttons[n].w - buttons[n]._width) * 0.4);
buttons[n]._height = buttons[n]._height + ((buttons[n].h - buttons[n]._height) * 0.4);
buttons[n]._x = buttons[n].x;
buttons[n]._y = buttons[n].y;
buttons[n]._alpha = buttons[n].a;
buttons[n].bl = buttons[n].bl + ((10 - buttons[n].bl) * 0.05);
}
n++;
}
}
buttons = [btn_returnToMenu, btn_restartLevel, btn_playMoreGames];
btn_restartLevel.sL = true;
loadButtons();
this.onEnterFrame = function () {
if ((_parent.fadeScreen._alpha >= 95) && ((_root.player.health <= 0) || (_root.player._y > 1500))) {
if ((_root.gBoss.dying != true) && (_root.rBoss.dying != true)) {
runButtons();
this._visible = true;
if (this._alpha < 100) {
this._alpha = this._alpha + 4;
}
if (_root.MAPNUMBER == "NadeDodger") {
lasted = ("YOU LASTED " + _parent.countertime) + " SECONDS";
} else {
lasted = "";
}
} else {
this._visible = false;
}
} else {
this._visible = false;
}
};
Symbol 20 Button
on (release) {
changeMusic();
}
Symbol 32 MovieClip Frame 1
this.ratio = _root.VOLUME_SFX;
text = ("sfx volume: " + this.ratio) + " %";
dragger._x = (this.ratio * 0.75) + ((this.ratio / 100) * 5);
VOL.gotoAndStop(Math.round(this.ratio / 25));
dragger.onPress = function () {
this.startDrag(true, 0, 0, line._width, 0);
this.onEnterFrame = function () {
ratio = Math.round((this._x * 100) / line._width);
if (ratio > 100) {
ratio = 100;
}
text = ("sfx volume: " + ratio) + " %";
_root.VOLUME_SFX = ratio;
VOL.gotoAndStop(Math.round(ratio / 25));
};
};
dragger.onRelease = (dragger.onreleaseOutside = stopDrag);
Symbol 34 MovieClip Frame 1
this.ratio = _root.VOLUME_MUSIC;
text = ("music volume: " + this.ratio) + " %";
dragger._x = (this.ratio * 0.75) + ((this.ratio / 100) * 5);
VOL.gotoAndStop(Math.round(this.ratio / 25));
dragger.onPress = function () {
this.startDrag(true, 0, 0, line._width, 0);
this.onEnterFrame = function () {
ratio = Math.round((this._x * 100) / line._width);
if (ratio > 100) {
ratio = 100;
}
text = ("music volume: " + ratio) + " %";
_root.VOLUME_MUSIC = ratio;
VOL.gotoAndStop(Math.round(ratio / 25));
};
};
dragger.onRelease = stopDrag;
this.onEnterFrame = function () {
_root.musicPath.music.setVolume(_root.VOLUME_MUSIC);
};
Symbol 44 Button
on (release) {
updateRES(0.75);
}
Symbol 45 Button
on (release) {
updateRES(1);
}
Symbol 46 Button
on (release) {
if (_root.motionTrail == true) {
_root.motionTrail = false;
motionTrailText = "OFF";
poopy = 0;
while (poopy < 10) {
_root.removeMovieClip(_root["playerTrail" + poopy]);
_root.removeMovieClip(_root["pWTrail" + poopy]);
poopy++;
}
} else {
_root.motionTrail = true;
motionTrailText = "ON";
}
}
Symbol 47 Button
on (release) {
if (_root.FPSStability == true) {
FPSStabilityText = "OFF";
_root.FPSStability = false;
_root.musicStream.stop();
} else {
FPSStabilityText = "ON";
_root.FPSStability = true;
_root.musicStream.play();
}
}
Symbol 48 Button
on (release) {
if (_root.mouseTargeting == true) {
_root.mouseTargeting = false;
mouseTargetingText = "OFF";
} else {
_root.mouseTargeting = true;
mouseTargetingText = "ON";
}
}
Symbol 49 Button
on (release) {
if (_root.blur == true) {
_root.blur = false;
_root.shellblur = true;
blurText = "SHELLS";
} else if (_root.shellblur == true) {
_root.blur = false;
_root.shellblur = false;
blurText = "OFF";
} else {
_root.blur = true;
_root.shellblur = true;
blurText = "ON";
}
}
Symbol 50 Button
on (release) {
if ((_quality == "HIGH") || (_quality == "BEST")) {
_quality = "MEDIUM";
qualityText = "MEDIUM";
} else if (_quality == "MEDIUM") {
_quality = "LOW";
qualityText = "LOW";
} else if (_quality == "LOW") {
_quality = "HIGH";
qualityText = "HIGH";
}
}
Symbol 51 Button
on (press) {
if (keylock != true) {
keylock = true;
id = 6;
k6 = _root.insertCharacterName;
}
}
Symbol 52 Button
on (press) {
if (keylock != true) {
keylock = true;
id = 9;
k9 = _root.insertCharacterName;
}
}
Symbol 53 Button
on (press) {
if (keylock != true) {
keylock = true;
id = 5;
k5 = _root.insertCharacterName;
}
}
Symbol 54 Button
on (press) {
if (keylock != true) {
keylock = true;
id = 4;
k4 = _root.insertCharacterName;
}
}
Symbol 55 Button
on (press) {
if (keylock != true) {
keylock = true;
id = 2;
k2 = _root.insertCharacterName;
}
}
Symbol 56 Button
on (press) {
if (keylock != true) {
keylock = true;
id = 1;
k1 = _root.insertCharacterName;
}
}
Symbol 57 Button
on (press) {
if (keylock != true) {
keylock = true;
id = 0;
k0 = _root.insertCharacterName;
}
}
Symbol 58 Button
on (press) {
if (keylock != true) {
keylock = true;
id = 3;
k3 = _root.insertCharacterName;
}
}
Symbol 61 Button
on (press) {
if (keylock != true) {
keylock = true;
id = 7;
k7 = _root.insertCharacterName;
}
}
Symbol 62 Button
on (press) {
if (keylock != true) {
keylock = true;
id = 8;
k8 = _root.insertCharacterName;
}
}
Symbol 84 MovieClip [mc.configureScreen] Frame 1
qualityText = _quality;
difficultyText = _root.DIFFICULTY;
if (_root.iF != undefined) {
this._xscale = 100 * (1 + (1 - _root.RES));
this._yscale = 100 * (1 + (1 - _root.RES));
}
if (_root.FPSStability == true) {
FPSStabilityText = "ON";
} else {
FPSStabilityText = "OFF";
}
if (_root.mouseTargeting == true) {
mouseTargetingText = "ON";
} else {
mouseTargetingText = "OFF";
}
if (_root.motionTrail == true) {
motionTrailText = "ON";
} else {
motionTrailText = "OFF";
}
if (_root.CURRENTMUSIC != undefined) {
SONG = _root.CURRENTMUSIC;
}
music = ["audio.TheScheme.mp3", "audio.LightsAndSounds.wav", "audio.FlyingBatteryZone.wav", "audio.MysticCaveZone.wav", "audio.MelodicSolace.wav", "audio.UnfinishedBusiness.wav"];
changeMusic = function () {
penor = 0;
while (penor < music.length) {
if (_root.CURRENTMUSIC == music[penor]) {
if (penor != (music.length - 1)) {
newSong = music[penor + 1];
} else if (_root.paused == true) {
newSong = music[1];
} else {
newSong = music[0];
}
break;
}
penor++;
}
if (_root.paused == true) {
_root.musicPath.newMusic(newSong);
SONG = newSong;
}
};
updateRES = function (numb) {
_root.RES = numb;
_root.iF.resizeage(_root.RES);
if (_root.MENU == false) {
this._xscale = 100 * (1 + (1 - _root.RES));
this._yscale = 100 * (1 + (1 - _root.RES));
} else {
this._xscale = 100;
this._yscale = 100;
}
if (_root.RES == 1) {
resolutionText500x400 = "<b>500x400</b>";
resolutionText375x300 = "375x300";
} else {
resolutionText500x400 = "500x400";
resolutionText375x300 = "<b>375x300</b>";
}
};
updateRES(_root.RES);
if (_root.blur == true) {
blurText = "ON";
} else if (_root.shellblur == true) {
blurText = "SHELLS";
} else {
blurText = "OFF";
}
Instance of Symbol 81 MovieClip "configureKeys" in Symbol 84 MovieClip [mc.configureScreen] Frame 1
onClipEvent (load) {
_root.keyTimer = 0;
n = 0;
while (n < 10) {
this["k" + n] = _root.getName(_root.keys[n]);
n++;
}
pIsDown = false;
pdn = false;
}
onClipEvent (enterFrame) {
if (_root.keyTimer > 0) {
_root.keyTimer--;
}
if (!Key.isDown(keyNum)) {
keyNum = 1000;
}
if (keylock == true) {
keyNum = 2;
while (keyNum < 128) {
if (Key.isDown(keyNum)) {
n = 0;
while (n < 10) {
if (this["k" + n] == _root.getName(keyNum)) {
_root.keys[n] = undefined;
this["k" + n] = "none";
}
n++;
}
_root.keys[id] = keyNum;
this["k" + id] = _root.getName(keyNum);
keylock = false;
_root.keyTimer = 1;
_root.kRi = _root.keys[0];
_root.kLe = _root.keys[1];
_root.kUp = _root.keys[2];
_root.kDn = _root.keys[9];
_root.kKick = _root.keys[4];
_root.kPause = _root.keys[5];
_root.kQuit = _root.keys[6];
_root.kSwDn = _root.keys[8];
_root.kSwUp = _root.keys[7];
if (this["k" + id] == _root.keys[5]) {
pIsDown = true;
pdn = true;
}
break;
}
keyNum++;
}
} else if (Key.isDown(_root.kPause) && (!Key.isDown(keyNum))) {
if ((pIsDown == false) && (pdn == false)) {
if ((_root.gBoss.dying != true) && (_root.rBoss.dying != true)) {
if ((_root.player.health > 0) && (_root.player._y < 1000)) {
if (!(((_root.gBoss.targeted == false) && (_root.gBoss.hostile == true)) && (_root.gBoss.targetTimer <= 100))) {
if (!(((_root.rBoss.targeted == false) && (_root.rBoss.hostile == true)) && (_root.rBoss.targetTimer <= 100))) {
if (_root.paused == true) {
_root.paused = false;
} else {
poopy = 0;
while (poopy < 10) {
removeMovieClip(_root["playerTrail" + poopy]);
removeMovieClip(_root["pWTrail" + poopy]);
poopy++;
}
_root.paused = true;
}
}
}
}
}
}
pIsDown = true;
} else {
pIsDown = false;
pdn = false;
}
}
Symbol 86 MovieClip Frame 1
setKeys = function () {
_root.kRi = _root.keys[0];
_root.kLe = _root.keys[1];
_root.kUp = _root.keys[2];
_root.kDn = _root.keys[9];
_root.kKick = _root.keys[4];
_root.kPause = _root.keys[5];
_root.kQuit = _root.keys[6];
_root.kSwDn = _root.keys[8];
_root.kSwUp = _root.keys[7];
};
Symbol 94 MovieClip Frame 1
stop();
this.onEnterFrame = function () {
if (this._parent._name != "iF") {
if (((_parent.trgt != _root.chubbs) && (_parent.trgt != _root.gBoss)) && (_parent.trgt != _root.rBoss)) {
this.hl = (_parent.trgt.health / _parent.trgt.ohealth) * 100;
} else {
this.hl = _parent.trgt.health;
}
} else {
this.hl = _root.player.health;
}
if ((this.hl <= 100) && (this.hl > 40)) {
this.greenBar._alpha = 100 - ((100 - this.hl) * 1.6666667);
this.yellowBar._alpha = 100;
this.redBar._alpha = 0;
}
if ((this.hl <= 40) && (this.hl > 0)) {
this.greenBar._alpha = 0;
this.yellowBar._alpha = 100 - ((40 - this.hl) * 2.5);
this.redBar._alpha = 100;
}
};
Symbol 121 MovieClip Frame 1
stop();
this._visible = false;
this.timer = 0;
this.onEnterFrame = function () {
gotoAndStop(this.type);
if (this.type == _root.pW.type) {
this._xscale = this._xscale + ((80 - this._xscale) * 0.3);
this._yscale = this._yscale + ((80 - this._yscale) * 0.3);
} else {
this._xscale = this._xscale + ((60 - this._xscale) * 0.3);
this._yscale = this._yscale + ((60 - this._yscale) * 0.3);
}
if (this.timer > 0) {
this.timer = this.timer - 2;
if (_root["AMMO_" + this.type] > 0) {
this._alpha = 100;
} else {
this._alpha = 50;
}
} else if (this._alpha > 0) {
if (_root["AMMO_" + this.type] > 0) {
this._alpha = this._alpha - 2;
} else {
this._alpha = this._alpha - 1;
}
} else {
this._visible = false;
}
};
Symbol 124 MovieClip Frame 1
this.text = "";
this.onEnterFrame = function () {
if (this.timer > 0) {
if (this._alpha < 100) {
this._alpha = this._alpha + 5;
}
} else if (this._alpha > 0) {
this._alpha = this._alpha - 5;
}
this.timer--;
};
Symbol 128 Button
on (press) {
getURL ("http://www.stickpage.com/", "_blank");
_root.paused = true;
}
Symbol 136 MovieClip [mc.iF] Frame 1
function camControl() {
this.sx = this._x;
this.sy = this._y;
if (((_root.paused != true) && (_root.mouseTargeting == true)) && (_root.gBoss.dying != true)) {
this.xPt = this._xmouse / 3;
this.yPt = this._ymouse / 3;
if (this.xPt > 84) {
this.xPt = 84;
}
if (this.xPt < -84) {
this.xPt = -84;
}
if (this.yPt > 67) {
this.yPt = 67;
}
if (this.yPt < -67) {
this.yPt = -67;
}
} else {
this.xPt = 0;
this.yPt = 0;
}
this._x = this._x + (((this.trgt._x + this.xPt) - this._x) * 0.15);
this._y = this._y + (((this.trgt._y + this.yPt) - this._y) * 0.15);
if (_root.MAPNUMBER == "NadeDodger") {
if (_root.paused != true) {
if (this.thp) {
this.starttimer = getTimer();
}
this.mytimer = this.mytimer + (getTimer() - this.starttimer);
this.starttimer = getTimer();
this.thp = false;
} else {
if (!this.thp) {
}
this.thp = true;
}
countertime = Math.round(this.mytimer * 1) / 1000;
counter = countertime + " seconds";
} else {
this.mytimer = 0;
counter = "";
}
if ((this.cS_x != 0) || (this.cS_y != 0)) {
this._x = this._x + this.cS_x;
if (Math.abs(this.cS_x) > 0.1) {
this.cS_x = this.cS_x * -0.72;
} else {
this.cS_x = 0;
}
this._y = this._y + this.cS_y;
if (Math.abs(this.cS_y) > 0.1) {
this.cS_y = this.cS_y * -0.72;
} else {
this.cS_y = 0;
}
}
_root.map.stageScreen._x = this._x;
_root.map.stageScreen._y = this._y - 100;
_root.map.backdrop._x = this._x;
_root.map.backdrop._y = this._y;
if (weaponName == undefined) {
weaponName = "USP";
}
parentColor.setTransform(camColor.getTransform());
var _local5 = sX / (this._width / 1.1);
var _local4 = sY / (this._height / 1.1);
_parent._x = cX - (this._x * _local5);
_parent._y = cY - (this._y * _local4);
_parent._xscale = 100 * _local5;
_parent._yscale = 100 * _local4;
this.nx = this._x - this.sx;
this.ny = this._y - this.sy;
_root.iFr._x = this._x;
_root.iFr._y = this._y;
_root.iFr._xscale = this._xscale;
_root.iFr._yscale = this._yscale;
}
function resetStage() {
var _local2 = {ra:100, rb:0, ga:100, gb:0, ba:100, bb:0, aa:100, ab:0};
parentColor.setTransform(_local2);
_parent._xscale = 100;
_parent._yscale = 100;
_parent._x = 0;
_parent._y = 0;
}
function resizeage(numb) {
sX = Stage.width * _root.RES;
sY = Stage.height * _root.RES;
}
this.mytimer = 0;
this.starttimer = getTimer();
this.totalTimer = 0;
this.thp = false;
blind = function (degree) {
if (degree < 250) {
blindScreen.degree = blindScreen.degree + (250 - degree);
}
};
this.trgt = _root.player;
this.blindScreen._alpha = 0;
this.pausedScreen._alpha = 100;
this.pausedScreen._visible = false;
this.berserkScreen._alpha = 75;
this.berserkScreen._visible = false;
var oldMode = Stage.scaleMode;
Stage.scaleMode = "exactFit";
var cX = (Stage.width / 2);
var cY = (Stage.height / 2);
var sX = (Stage.width * _root.RES);
var sY = (Stage.height * _root.RES);
Stage.scaleMode = oldMode;
var camColor = new Color(this);
var parentColor = new Color(_parent);
this.onEnterFrame = camControl;
camControl();
this.onUnload = resetStage;
Instance of Symbol 14 MovieClip "fadeScreen" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (enterFrame) {
if (this.fade == "out") {
if (this._alpha > 0) {
this._alpha = this._alpha - 20;
}
} else if (this.fade == "inslow") {
if (this._alpha < 100) {
this._alpha = this._alpha + 1;
}
} else if (this._alpha < 100) {
this._alpha = this._alpha + 4;
}
}
Instance of Symbol 14 MovieClip "blindScreen" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
this.degree = 0;
}
onClipEvent (enterFrame) {
if (_root.paused != true) {
if (this.degree > 0) {
this.degree = this.degree - 5;
}
if (this.degree > 100) {
this._alpha = 100;
} else {
this._alpha = this.degree;
}
}
}
Instance of Symbol 16 MovieClip "damageScreen" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (enterFrame) {
if (this._alpha > 0.01) {
this._alpha = this._alpha * 0.95;
}
}
Instance of Symbol 94 MovieClip "playerHealthBar" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
this.trgt = _root.player;
}
onClipEvent (enterFrame) {
_xscale = (_root.player.health * 1.5);
if (this._xscale < 0) {
this._xscale = 0;
}
}
Instance of Symbol 121 MovieClip "wi_1" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "mac10";
}
Instance of Symbol 121 MovieClip "wi_0" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "usp";
}
Instance of Symbol 121 MovieClip "wi_5" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "m4";
}
Instance of Symbol 121 MovieClip "wi_4" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "machineGun";
}
Instance of Symbol 121 MovieClip "wi_3" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "assaultRifle";
}
Instance of Symbol 121 MovieClip "wi_2" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "mp5";
}
Instance of Symbol 121 MovieClip "wi_7" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "flakCannon";
}
Instance of Symbol 121 MovieClip "wi_6" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "shotGun";
}
Instance of Symbol 121 MovieClip "wi_11" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "mine";
}
Instance of Symbol 121 MovieClip "wi_10" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "nade";
}
Instance of Symbol 121 MovieClip "wi_9" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "stinger";
}
Instance of Symbol 121 MovieClip "wi_8" in Symbol 136 MovieClip [mc.iF] Frame 1
onClipEvent (load) {
type = "sniperRifle";
}
Symbol 153 MovieClip [mc.bullet] Frame 1
stop();
Symbol 154 MovieClip [mc.generateWeapon] Frame 1
gotoAndStop(_parent.type);
Symbol 158 MovieClip [mc.shell] Frame 1
stop();
Instance of Symbol 94 MovieClip in Symbol 160 MovieClip [mc.healthBar] Frame 1
onClipEvent (enterFrame) {
if (((_parent.trgt != _root.chubbs) && (_parent.trgt != _root.gBoss)) && (_parent.trgt != _root.rBoss)) {
_xscale = ((_parent.trgt.health / _parent.trgt.ohealth) * 100);
} else {
_xscale = _parent.trgt.health;
}
if (_xscale < 0) {
_xscale = 0;
}
if (_parent.trgt.healthTimer > 0) {
if (_parent._alpha < 100) {
_parent._alpha = _parent._alpha + 25;
}
} else if (_parent._alpha > 0) {
_parent._alpha = _parent._alpha - 5;
}
if ((_parent.trgt.health == undefined) || (_parent.trgt.dying == true)) {
removeMovieClip(_parent);
}
}
Symbol 168 MovieClip [1] Frame 1
Symbol 171 MovieClip [mc.loadScreen] Frame 1
stop();
Symbol 171 MovieClip [mc.loadScreen] Frame 2
this.onMouseDown = function () {
_root.startEngine();
this.removeMovieClip();
};
Symbol 202 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 202 MovieClip Frame 29
removeMovieClip(_parent);
Symbol 224 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 224 MovieClip Frame 20
removeMovieClip(_parent);
Symbol 262 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 276 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 298 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 298 MovieClip Frame 4
var sfx = new Sound(this);
sfx.attachSound("audio.swing1.wav");
sfx.start(0, 0);
sfx.setVolume(_root.VOLUME_SFX);
Symbol 298 MovieClip Frame 6
if (this.hitTest(_root.player)) {
_root.player.takeDamage(_parent.damage + random(4));
_root.iF.cS_x = _root.iF.cS_x + (random(15) - 7);
_root.iF.cS_y = _root.iF.cS_y + (random(15) - 7);
var sfx = new Sound(this);
sfx.attachSound("audio.kick1.wav");
sfx.start(0, 0);
sfx.setVolume(_root.VOLUME_SFX);
}
Symbol 298 MovieClip Frame 22
_parent.attackTimer = 0;
Symbol 318 MovieClip Frame 1
function onEnterFrame() {
if ((_root.paused != true) && (_parent.dead != true)) {
play();
} else {
stop();
}
}
Symbol 318 MovieClip Frame 50
_parent.dead = true;
stop();
Symbol 319 MovieClip [mc.grassboss] Frame 1
stop();
Symbol 326 MovieClip Frame 1
_root.stop();
PercentLoaded = (_root.getBytesLoaded() / _root.getBytesTotal()) * 100;
bL = (Math.floor(_root.getBytesLoaded() / 1000000) + ".") + Math.round((_root.getBytesLoaded() - (Math.floor(_root.getBytesLoaded() / 1000000) * 1000000)) / 10000);
bT = (Math.floor(_root.getBytesTotal() / 1000000) + ".") + Math.round((_root.getBytesTotal() - (Math.floor(_root.getBytesTotal() / 1000000) * 1000000)) / 10000);
text = ((((bL + " mB / ") + bT) + " mB - [ ") + Math.round(PercentLoaded)) + "% ] ";
trace(text);
if (PercentLoaded != 100) {
bar._xscale = PercentLoaded;
} else {
bar._xscale = PercentLoaded;
_root.gotoAndStop("AGIntro");
}
Symbol 326 MovieClip Frame 2
gotoAndPlay (1);
Symbol 330 Button
on (release) {
getURL ("http://www.stickpage.com", "_blank");
}
Symbol 337 MovieClip [mc.debrisGrass2] Frame 14
removeMovieClip(this);
Symbol 342 MovieClip [mc.frag] Frame 50
this.splode("FRAG");
removeMovieClip(this);
Symbol 344 MovieClip [mc.flashBang] Frame 50
this.splode("FLASHBANG");
removeMovieClip(this);
Symbol 346 MovieClip Frame 1
_root.generateBarrel(this._x, this._y, 0);
this._visible = false;
Symbol 434 MovieClip [mc.barrelExplosion] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 434 MovieClip [mc.barrelExplosion] Frame 3
this.damage = 150;
_root.iF.cS_x = _root.iF.cS_x + (Math.cos((this._rotation / 180) * Math.PI) * 20);
_root.iF.cS_y = _root.iF.cS_y + (Math.sin((this._rotation / 180) * Math.PI) * 20);
_root.player.checkExplosion(this, 150, this.damage);
Symbol 434 MovieClip [mc.barrelExplosion] Frame 97
removeMovieClip(this);
Symbol 450 MovieClip [blood_2] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 450 MovieClip [blood_2] Frame 28
removeMovieClip(this);
Symbol 479 MovieClip [blood_1] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 479 MovieClip [blood_1] Frame 25
removeMovieClip(this);
Symbol 499 MovieClip [blood_0] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 499 MovieClip [blood_0] Frame 34
removeMovieClip(this);
Symbol 517 MovieClip Frame 1
_root.generateBlock(this._x, this._y, 0);
this._visible = false;
Symbol 587 MovieClip [mc.explosionMine] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
this.damage = 150;
_root.iF.cS_x = _root.iF.cS_x + (Math.cos((this._rotation / 180) * Math.PI) * 20);
_root.iF.cS_y = _root.iF.cS_y + (Math.sin((this._rotation / 180) * Math.PI) * 20);
if (this.TARG == undefined) {
_root.player.checkExplosion(this, 150, this.damage);
} else {
ra = 200;
if ((Math.abs(this._y - _root.player._y) < ra) && (Math.abs(this._x - _root.player._x) < ra)) {
dm = this.damage - ((Math.abs(this._y - _root.player._y) + Math.abs(this._x - _root.player._x)) / 2);
_root.player.takeDamage(dm);
}
}
Symbol 587 MovieClip [mc.explosionMine] Frame 107
removeMovieClip(this);
Symbol 619 MovieClip [mc.pu] Frame 1
gotoAndStop(this.type);
Symbol 636 MovieClip [mc.sparks1] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 636 MovieClip [mc.sparks1] Frame 17
removeMovieClip(this);
Symbol 653 MovieClip [mc.sparks0] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 653 MovieClip [mc.sparks0] Frame 20
removeMovieClip(this);
Symbol 715 MovieClip [mc.explosionNade] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
this.damage = 150;
_root.iF.cS_x = _root.iF.cS_x + (Math.cos((this._rotation / 180) * Math.PI) * 20);
_root.iF.cS_y = _root.iF.cS_y + (Math.sin((this._rotation / 180) * Math.PI) * 20);
_root.player.checkExplosion(this, 150, this.damage);
Symbol 715 MovieClip [mc.explosionNade] Frame 40
removeMovieClip(this);
Symbol 716 MovieClip [mc.nadeTrail] Frame 5
stop();
removeMovieClip(this);
Symbol 717 MovieClip [mc.debrisGrass1] Frame 14
removeMovieClip(this);
Symbol 766 MovieClip [mc.explosionStinger] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
this.damage = 200;
_root.iF.cS_x = _root.iF.cS_x + (Math.cos((this._rotation / 180) * Math.PI) * 15);
_root.iF.cS_y = _root.iF.cS_y + (Math.sin((this._rotation / 180) * Math.PI) * 15);
_root.player.checkExplosion(this, 150, this.damage);
Symbol 766 MovieClip [mc.explosionStinger] Frame 33
removeMovieClip(this);
Symbol 774 MovieClip [mc.smokeParticle] Frame 1
this.onEnterFrame = function () {
if (_root.paused != true) {
play();
this._alpha = this._alpha - 8;
this.vy = this.vy - 0.1;
this._y = this._y + this.vy;
this._xscale = this._xscale + 1.5;
this._yscale = this._yscale + 1.5;
} else {
stop();
}
};
Symbol 774 MovieClip [mc.smokeParticle] Frame 29
removeMovieClip(this);
Symbol 786 MovieClip [mc.backdrop] Frame 1
this.onEnterFrame = function () {
this.gotoAndStop("map" + _root.MAPNUMBER);
};
Symbol 799 MovieClip [mc.chubbsText] Frame 70
removeMovieClip(this);
Symbol 824 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 824 MovieClip Frame 68
removeMovieClip(_parent);
Symbol 837 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 845 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
_parent.fire(_parent._x, _parent._y - 6, _root.player._x - _parent._x);
Symbol 845 MovieClip Frame 20
_parent.attackTimer = 0;
Symbol 851 MovieClip Frame 40
_parent.laughTimer = 0;
Symbol 852 MovieClip [mc.chubbs] Frame 1
stop();
Symbol 855 MovieClip [mc.turretBall2] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 855 MovieClip [mc.turretBall2] Frame 30
removeMovieClip(this);
Symbol 857 MovieClip [mc.turretBall1] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 857 MovieClip [mc.turretBall1] Frame 19
removeMovieClip(this);
Symbol 870 MovieClip [mc.turretLaser] Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 870 MovieClip [mc.turretLaser] Frame 17
removeMovieClip(this);
Symbol 878 MovieClip [mc.turret] Frame 1
stop();
Symbol 912 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 940 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 940 MovieClip Frame 19
gotoAndPlay (1);
Symbol 963 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 963 MovieClip Frame 3
var sfx = new Sound(this);
var pan = ((_parent._x - _root.iF._x) / 2.5);
sfx.attachSound("audio.swing2.wav");
sfx.start(0, 0);
sfx.setPan(pan);
sfx.setVolume(_root.VOLUME_SFX);
Symbol 963 MovieClip Frame 11
var sfx = new Sound(this);
var pan = ((_parent._x - _root.iF._x) / 2.5);
sfx.attachSound("audio.clawMiss2.wav");
sfx.start(0, 0);
sfx.setPan(pan);
sfx.setVolume(_root.VOLUME_SFX);
Symbol 963 MovieClip Frame 15
if (this.hitTest(_root.player)) {
if (((_parent.facing == "right") && (_root.player._x > _parent._x)) || ((_parent.facing == "left") && (_root.player._x < _parent._x))) {
_root.player.takeDamage(_parent.damage + random(3));
var sfx = new Sound(this);
var pan = ((_parent._x - _root.iF._x) / 2.5);
sfx.attachSound(("audio.clawStrike" + random(3)) + ".wav");
sfx.start(0, 0);
sfx.setPan(pan);
sfx.setVolume(_root.VOLUME_SFX);
_root.iF.cS_x = _root.iF.cS_x + (random(11) - 5);
_root.iF.cS_y = _root.iF.cS_y + (random(11) - 5);
}
}
_root.checkForBlocks(this, _parent.damage + random(3), _parent._x, ("audio.clawStrike" + random(3)) + ".wav");
Symbol 963 MovieClip Frame 25
_parent.attackTimer = 0;
Symbol 1003 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
cF++;
if (cF < 42) {
play();
}
} else {
stop();
}
}
cF = 0;
var sfx = new Sound(this);
var pan = ((_parent._x - _root.iF._x) / 2.5);
sfx.attachSound(("audio.zombieDeath" + random(2)) + ".wav");
sfx.start(0, 0);
sfx.setPan(pan);
sfx.setVolume(_root.VOLUME_SFX);
Symbol 1003 MovieClip Frame 42
stop();
_parent.dead = true;
Symbol 1004 MovieClip [mc.frog] Frame 1
stop();
Symbol 1021 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 1034 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 1055 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 1055 MovieClip Frame 8
_root.soundfx(_parent._x, "audio.swing0.wav");
Symbol 1055 MovieClip Frame 10
if (this.hitTest(_root.player)) {
_root.player.takeDamage(_parent.damage + random(4));
_root.soundfx(_parent._x, ("audio.slash" + random(3)) + ".wav");
}
_root.checkForBlocks(this, _parent.damage + random(4), _parent._x, ("audio.slash" + random(3)) + ".wav");
Symbol 1055 MovieClip Frame 19
_parent.attackTimer = 0;
Symbol 1075 MovieClip Frame 1
function onEnterFrame() {
if ((_root.paused != true) && (_parent.dead != true)) {
play();
} else {
stop();
}
}
_root.soundfx(_parent._x, ("audio.death" + random(3)) + ".wav");
Symbol 1075 MovieClip Frame 30
_parent.dead = true;
stop();
Symbol 1076 MovieClip [mc.knight] Frame 1
stop();
Symbol 1077 MovieClip Frame 1
this.onEnterFrame = function () {
if (_root.player.facing == 1) {
_root.pW._x = (this._x + _root.player._x) - 23.8;
} else {
_root.pW._x = ((-this._x) + _root.player._x) + 23.8;
}
_root.pW._y = (this._y + _root.player._y) - 33;
if (_root.player._rotation == 25) {
_root.pW._x = _root.pW._x + 10;
_root.pW._y = _root.pW._y + 1;
}
if (_root.player._rotation == -25) {
_root.pW._x = _root.pW._x - 10;
_root.pW._y = _root.pW._y + 1;
}
};
Symbol 1084 MovieClip Frame 1
function onEnterFrame() {
if (_parent._name == "player") {
_root.player.CURF = this._currentframe;
if (_root.paused != true) {
play();
} else {
stop();
}
} else {
this.frem = _root.player.CURF - ((100 - (_parent._alpha + 50)) / 10);
if (this.frem < 0) {
this.frem = this.frem + 18;
}
gotoAndStop(this.frem);
}
}
Symbol 1096 MovieClip Frame 1
if ((_root.inTurret == false) && (_parent._name == "player")) {
if (((_root.MAPNUMBER != 2) && (_root.MAPNUMBER != 5)) && (_root.MAPNUMBER != "NadeDodger")) {
_root.soundfx(_root.iF._x, ("audio.fs_stone" + (random(4) + 1)) + ".wav");
} else {
_root.soundfx(_root.iF._x, ("audio.fs_metal" + random(3)) + ".wav");
}
}
function onEnterFrame() {
if (_parent._name == "player") {
_root.player.CURF = this._currentframe;
if (_root.paused != true) {
play();
} else {
stop();
}
} else {
this.frem = _root.player.CURF - ((100 - (_parent._alpha + 50)) / 10);
if (this.frem < 0) {
this.frem = this.frem + 14;
}
gotoAndStop(this.frem);
}
}
Symbol 1096 MovieClip Frame 8
if ((_root.inTurret == false) && (_parent._name == "player")) {
if (((_root.MAPNUMBER != 2) && (_root.MAPNUMBER != 5)) && (_root.MAPNUMBER != "NadeDodger")) {
_root.soundfx(_root.iF._x, ("audio.fs_stone" + (random(4) + 1)) + ".wav");
} else {
_root.soundfx(_root.iF._x, ("audio.fs_metal" + random(3)) + ".wav");
}
}
Symbol 1109 MovieClip Frame 1
function onEnterFrame() {
if (_parent._name == "player") {
_root.player.CURF = this._currentframe;
if ((_root.paused != true) && (cF < 10)) {
play();
cF++;
} else {
stop();
}
} else {
if (_root.player.CURF < 10) {
this.frem = _root.player.CURF - ((100 - (_parent._alpha + 50)) / 10);
if (this.frem < 0) {
this.frem = this.frem + 11;
}
} else if (this.frem == undefined) {
this.frem = 11 - ((100 - (_parent._alpha + 50)) / 10);
} else if (this.frem < 10) {
this.frem++;
} else {
this.frem = 10;
}
gotoAndStop(this.frem);
}
}
cF = 0;
Symbol 1109 MovieClip Frame 11
stop();
Symbol 1122 MovieClip Frame 1
function onEnterFrame() {
if (_parent._name == "player") {
_root.player.CURF = this._currentframe;
if ((_root.paused != true) && (cF < 18)) {
play();
cF++;
} else {
stop();
}
} else {
if (_root.player.CURF < 18) {
this.frem = _root.player.CURF - ((100 - (_parent._alpha + 50)) / 10);
if (this.frem < 0) {
this.frem = this.frem + 19;
}
} else if (this.frem == undefined) {
this.frem = 19 - ((100 - (_parent._alpha + 50)) / 10);
} else if (this.frem < 18) {
this.frem++;
} else {
this.frem = 10;
}
gotoAndStop(this.frem);
}
}
cF = 0;
Symbol 1122 MovieClip Frame 2
if (_parent._name == "player") {
var sfx = new Sound(this);
sfx.attachSound("audio.swing1.wav");
sfx.start(0, 0);
sfx.setVolume(_root.VOLUME_SFX);
}
Symbol 1122 MovieClip Frame 4
function makeSoundA() {
if (_parent._name == "player") {
_root.soundfx(_root.iF._x, "audio.kick0.wav");
_root.iF.cS_x = _root.iF.cS_x + (5 + random(5));
}
}
pL = _root.player;
if (_root.MAPNUMBER != "NadeDodger") {
c = 0;
while (c < _root.grunts.length) {
if (_root.grunts[c].hitTest(pL)) {
if (_root.grunts[c].health > 0) {
if (((pL.facing == 1) && (_root.grunts[c]._x > (pL._x + 5))) || ((pL.facing == 0) && (_root.grunts[c]._x < (pL._x - 5)))) {
_root.grunts[c].hit(_root.grunts[c]._x, pL._y, pL.damage, random(361));
makeSoundA();
}
}
}
c++;
}
}
c = 0;
while (c < _root.zombies.length) {
if (_root.zombies[c].hitTest(pL)) {
if (_root.zombies[c].health > 0) {
if (((pL.facing == 1) && (_root.zombies[c]._x > (pL._x + 5))) || ((pL.facing == 0) && (_root.zombies[c]._x < (pL._x - 5)))) {
_root.zombies[c].hit(_root.zombies[c]._x, pL._y, pL.damage, random(361));
makeSoundA();
}
}
}
c++;
}
c = 0;
while (c < _root.frogs.length) {
if (_root.frogs[c].hitTest(pL)) {
if (_root.frogs[c].health > 0) {
if (((pL.facing == 1) && (_root.frogs[c]._x > (pL._x + 5))) || ((pL.facing == 0) && (_root.frogs[c]._x < (pL._x - 5)))) {
_root.frogs[c].hit(_root.frogs[c]._x, pL._y, pL.damage, random(361));
makeSoundA();
}
}
}
c++;
}
c = 0;
while (c < _root.knights.length) {
if (_root.knights[c].hitTest(pL)) {
if (_root.knights[c].health > 0) {
if (((pL.facing == 1) && (_root.knights[c]._x > (pL._x + 5))) || ((pL.facing == 0) && (_root.knights[c]._x < (pL._x - 5)))) {
_root.knights[c].hit(_root.knights[c]._x, pL._y, pL.damage, random(361));
makeSoundA();
}
}
}
c++;
}
if (_root.gBoss.hitTest(pL)) {
if (_root.gBoss.health > 0) {
if (((pL.facing == 1) && (_root.gBoss._x > (pL._x + 5))) || ((pL.facing == 0) && (_root.gBoss._x < (pL._x - 5)))) {
_root.gBoss.hit(_root.gBoss._x, pL._y, pL.damage, random(361));
makeSoundA();
}
}
}
Symbol 1122 MovieClip Frame 12
if (_parent._name == "player") {
var sfx = new Sound(this);
sfx.attachSound("audio.swing1.wav");
sfx.start(0, 0);
sfx.setVolume(_root.VOLUME_SFX);
}
Symbol 1122 MovieClip Frame 14
function makeSoundA() {
if (_parent._name == "player") {
_root.soundfx(_root.iF._x, "audio.kick0.wav");
_root.iF.cS_x = _root.iF.cS_x + (5 + random(5));
}
}
pL = _root.player;
if (_root.MAPNUMBER != "NadeDodger") {
c = 0;
while (c < _root.grunts.length) {
if (_root.grunts[c].hitTest(pL)) {
if (_root.grunts[c].health > 0) {
if (((pL.facing == 1) && (_root.grunts[c]._x > (pL._x + 5))) || ((pL.facing == 0) && (_root.grunts[c]._x < (pL._x - 5)))) {
_root.grunts[c].hit(_root.grunts[c]._x, pL._y, pL.damage, random(361));
makeSoundA();
}
}
}
c++;
}
}
c = 0;
while (c < _root.zombies.length) {
if (_root.zombies[c].hitTest(pL)) {
if (_root.zombies[c].health > 0) {
if (((pL.facing == 1) && (_root.zombies[c]._x > (pL._x + 5))) || ((pL.facing == 0) && (_root.zombies[c]._x < (pL._x - 5)))) {
_root.zombies[c].hit(_root.zombies[c]._x, pL._y, pL.damage, random(361));
makeSoundA();
}
}
}
c++;
}
c = 0;
while (c < _root.frogs.length) {
if (_root.frogs[c].hitTest(pL)) {
if (_root.frogs[c].health > 0) {
if (((pL.facing == 1) && (_root.frogs[c]._x > (pL._x + 5))) || ((pL.facing == 0) && (_root.frogs[c]._x < (pL._x - 5)))) {
_root.frogs[c].hit(_root.frogs[c]._x, pL._y, pL.damage, random(361));
makeSoundA();
}
}
}
c++;
}
c = 0;
while (c < _root.knights.length) {
if (_root.knights[c].hitTest(pL)) {
if (_root.knights[c].health > 0) {
if (((pL.facing == 1) && (_root.knights[c]._x > (pL._x + 5))) || ((pL.facing == 0) && (_root.knights[c]._x < (pL._x - 5)))) {
_root.knights[c].hit(_root.knights[c]._x, pL._y, pL.damage, random(361));
makeSoundA();
}
}
}
c++;
}
if (_root.gBoss.hitTest(pL)) {
if (_root.gBoss.health > 0) {
if (((pL.facing == 1) && (_root.gBoss._x > (pL._x + 5))) || ((pL.facing == 0) && (_root.gBoss._x < (pL._x - 5)))) {
_root.gBoss.hit(_root.gBoss._x, pL._y, pL.damage, random(361));
makeSoundA();
}
}
}
Symbol 1122 MovieClip Frame 19
stop();
Symbol 1122 MovieClip Frame 23
stop();
Symbol 1126 MovieClip [mc.player] Frame 1
if ((_root.player.crouching == true) && (!Key.isDown(_root.kKick))) {
if (_root.pW.type != "turret") {
_root.pT._y = _root.pT._y - 32;
}
if (((_root.player._rotation == 25) && (_root.player.facing == 1)) || ((_root.player._rotation == -25) && (_root.player.facing == 0))) {
if (_root.player._rotation == 25) {
_root.pT._x = _root.pT._x + 11;
} else {
_root.pT._x = _root.pT._x - 22;
}
_root.pT._y = _root.pT._y + 1;
}
if (((_root.player._rotation == -25) && (_root.player.facing == 1)) || ((_root.player._rotation == 25) && (_root.player.facing == 0))) {
if (_root.player._rotation == 25) {
_root.pT._x = _root.pT._x + 22;
} else {
_root.pT._x = _root.pT._x - 11;
}
_root.pT._y = _root.pT._y + 1;
}
}
_root.player.crouching = false;
Symbol 1126 MovieClip [mc.player] Frame 2
if (_root.player.crouching == true) {
_root.pT._y = _root.pT._y - 32;
if (_root.player._rotation == 25) {
_root.pT._x = _root.pT._x + 11;
}
if (_root.player._rotation == -25) {
_root.pT._x = _root.pT._x - 11;
}
_root.pW._x = _root.pT._x;
_root.pW._y = _root.pT._y;
}
_root.player.crouching = false;
Symbol 1126 MovieClip [mc.player] Frame 3
if (_root.player.crouching == true) {
_root.pT._y = _root.pT._y - 32;
if (_root.player._rotation == 25) {
_root.pT._x = _root.pT._x + 11;
}
if (_root.player._rotation == -25) {
_root.pT._x = _root.pT._x - 11;
}
_root.pW._x = _root.pT._x;
_root.pW._y = _root.pT._y;
}
_root.player.crouching = false;
Symbol 1126 MovieClip [mc.player] Frame 4
_root.player.crouching = false;
Symbol 1126 MovieClip [mc.player] Frame 5
_root.player.crouching = true;
if ((_root.pW.type != "turret") && (_root.player.kickTimer == 0)) {
_root.pT._y = _root.pT._y + 32;
if (((_root.player._rotation == 25) && (_root.player.facing == 1)) || ((_root.player._rotation == -25) && (_root.player.facing == 0))) {
if (_root.player._rotation == 25) {
_root.pT._x = _root.pT._x - 11;
} else {
_root.pT._x = _root.pT._x + 11;
}
_root.pT._y = _root.pT._y - 1;
}
if (((_root.player._rotation == -25) && (_root.player.facing == 1)) || ((_root.player._rotation == 25) && (_root.player.facing == 0))) {
if (_root.player._rotation == 25) {
_root.pT._x = _root.pT._x - 11;
} else {
_root.pT._x = _root.pT._x + 11;
}
_root.pT._y = _root.pT._y - 1;
}
_root.pW._x = _root._root.pT._x;
_root.pW._y = _root._root.pT._y;
}
Symbol 1126 MovieClip [mc.player] Frame 6
if (_root.player.crouching == true) {
if (_root.player._rotation == 25) {
_root.pT._x = _root.pT._x + 11;
}
if (_root.player._rotation == -25) {
_root.pT._x = _root.pT._x - 11;
}
_root.pW._x = _root.pT._x;
_root.pW._y = _root.pT._y;
}
_root.player.crouching = false;
Symbol 1141 MovieClip [mc.weapon] Frame 1
Symbol 1174 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 1208 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 1245 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 1245 MovieClip Frame 15
_root.soundfx(_parent._x, "audio.clawMiss2.wav");
Symbol 1245 MovieClip Frame 21
if (this.hitTest(_root.player)) {
if (((_parent.facing == "right") && (_root.player._x > _parent._x)) || ((_parent.facing == "left") && (_root.player._x < _parent._x))) {
_root.player.takeDamage(_parent.damage + random(3));
_root.soundfx(_parent._x, ("audio.clawStrike" + random(3)) + ".wav");
_root.iF.cS_x = _root.iF.cS_x + (random(11) - 5);
_root.iF.cS_y = _root.iF.cS_y + (random(11) - 5);
}
}
_root.checkForBlocks(this, _parent.damage + random(3), _parent._x, ("audio.clawStrike" + random(3)) + ".wav");
Symbol 1245 MovieClip Frame 41
_parent.attackTimer = 0;
Symbol 1280 MovieClip Frame 1
function onEnterFrame() {
if ((_root.paused != true) && (_parent.dead != true)) {
play();
} else {
stop();
}
}
_root.soundfx(_parent._x, ("audio.zombieDeath" + random(2)) + ".wav");
Symbol 1280 MovieClip Frame 40
_parent.dead = true;
stop();
Symbol 1281 MovieClip [mc.zombie] Frame 1
stop();
Symbol 1296 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 1318 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 1348 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
Symbol 1348 MovieClip Frame 7
if (this.hitTest(_root.player)) {
_root.player.takeDamage(_parent.damage + random(3));
var sfx = new Sound(this);
sfx.attachSound("audio.kick1.wav");
sfx.start(0, 0);
sfx.setVolume(_root.VOLUME_SFX);
_root.iF.cS_x = _root.iF.cS_x + (random(11) - 5);
_root.iF.cS_y = _root.iF.cS_y + (random(11) - 5);
}
_root.checkForBlocks(this, _parent.damage + random(3), _parent._x, "audio.kick1.wav");
Symbol 1348 MovieClip Frame 18
_parent.attackTimer = 0;
Symbol 1362 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
_parent.fire();
Symbol 1372 MovieClip Frame 1
function onEnterFrame() {
if (_root.paused != true) {
play();
} else {
stop();
}
}
_parent.fire();
Symbol 1409 MovieClip Frame 1
function onEnterFrame() {
if ((_root.paused != true) && (_parent.dead != true)) {
play();
} else {
stop();
}
}
var sfx = new Sound(this);
var pan = ((_parent._x - _root.iF._x) / 2.5);
sfx.attachSound(("audio.death" + random(3)) + ".wav");
sfx.start(0, 0);
sfx.setPan(pan);
sfx.setVolume(_root.VOLUME_SFX);
Symbol 1409 MovieClip Frame 38
_parent.dead = true;
stop();
Symbol 1446 MovieClip Frame 1
function onEnterFrame() {
if ((_root.paused != true) && (_parent.dead != true)) {
play();
} else {
stop();
}
}
var sfx = new Sound(this);
var pan = ((_parent._x - _root.iF._x) / 2.5);
sfx.attachSound(("audio.death" + random(3)) + ".wav");
sfx.start(0, 0);
sfx.setPan(pan);
sfx.setVolume(_root.VOLUME_SFX);
Symbol 1446 MovieClip Frame 31
_parent.dead = true;
stop();
Symbol 1507 MovieClip Frame 1
function onEnterFrame() {
if ((_root.paused != true) && (_parent.dead != true)) {
play();
} else {
stop();
}
}
Symbol 1507 MovieClip Frame 39
_parent.throwNade("mc.flashBang");
Symbol 1507 MovieClip Frame 81
_parent.attackTimer = 0;
Symbol 1519 MovieClip Frame 1
function onEnterFrame() {
if ((_root.paused != true) && (_parent.dead != true)) {
play();
} else {
stop();
}
}
Symbol 1519 MovieClip Frame 39
_parent.throwNade("mc.frag");
Symbol 1519 MovieClip Frame 81
_parent.attackTimer = 0;
Symbol 1520 MovieClip [mc.grunt] Frame 1
stop();
Symbol 1614 Button
on (release) {
getURL ("http://www.stickpage.com", "_blank");
}
Symbol 1624 MovieClip Frame 1
_root.stop();
Symbol 1624 MovieClip Frame 210
_root.play();
Symbol 1626 Button
on (release) {
getURL ("http://www.fluidanims.com", "_blank");
}
Symbol 1628 MovieClip Frame 1
_root.stop();
Symbol 1628 MovieClip Frame 129
_root.play();
Symbol 1631 Button
on (release) {
getURL ("http://www.stickpage.com/wpnfirestrats.shtml", "_blank");
}
Symbol 1635 Button
on (press) {
_root.MAPNUMBER = "Secret";
_root.gotoAndPlay("Start");
_root.T = _root.getTimer();
clearInterval(rb);
}
Symbol 1637 MovieClip Frame 1
this._visible = false;
Symbol 1639 Button
on (press) {
moveTo(pl0);
}
Symbol 1641 MovieClip Frame 1
function camControl() {
this._y = this._y + ((this.tar - this._y) * 0.1);
_parent.btn_back._x = this._x - 221.1;
_parent.btn_back._y = this._y - 171.4;
parentColor.setTransform(camColor.getTransform());
var _local4 = sX / this._width;
var _local3 = sY / this._height;
_parent._x = cX - (this._x * _local4);
_parent._y = cY - (this._y * _local3);
_parent._xscale = 100 * _local4;
_parent._yscale = 100 * _local3;
if (backfade == "out") {
if (_parent.btn_back._alpha > 0) {
_parent.btn_back._alpha = _parent.btn_back._alpha - 5;
} else {
_parent.btn_back._visible = false;
}
} else {
_parent.btn_back._visible = true;
if (_parent.btn_back._alpha < 100) {
_parent.btn_back._alpha = _parent.btn_back._alpha + 5;
}
}
}
function resetStage() {
var _local2 = {ra:100, rb:0, ga:100, gb:0, ba:100, bb:0, aa:100, ab:0};
parentColor.setTransform(_local2);
_parent._xscale = 100;
_parent._yscale = 100;
_parent._x = 0;
_parent._y = 0;
}
var oldMode = Stage.scaleMode;
Stage.scaleMode = "exactFit";
var cX = (Stage.width / 2);
var cY = (Stage.height / 2);
var sX = Stage.width;
var sY = Stage.height;
Stage.scaleMode = oldMode;
backfade = "out";
var camColor = new Color(this);
var parentColor = new Color(_parent);
this.onEnterFrame = camControl;
camControl();
this.onUnload = resetStage;
Symbol 1643 Button
on (press) {
moveTo(pl4);
}
Symbol 1645 Button
on (press) {
moveTo(pl3);
}
Symbol 1647 Button
on (press) {
moveTo(pl1);
}
Symbol 1649 Button
on (press) {
moveTo(pl2);
}
Symbol 1651 Button
on (press) {
_root.MAPNUMBER = "Training";
_root.gotoAndPlay("Start");
_root.T = getTimer();
clearInterval(rb);
}
Symbol 1653 Button
on (press) {
_root.MAPNUMBER = "NadeDodger";
_root.gotoAndPlay("Start");
_root.T = _root.getTimer();
clearInterval(rb);
}
Symbol 1658 Button
on (press, release, keyPress "<Up>") {
currentScroll = TEXT.scroll;
if (Number(currentScroll) > 1) {
TEXT.scroll = currentScroll - 1;
}
}
Symbol 1659 Button
on (press, release, keyPress "<Down>") {
currentScroll = TEXT.scroll;
if (Number(currentScroll) < Number(TEXT.maxscroll)) {
TEXT.scroll = Number(currentScroll) + 1;
}
}
Symbol 1662 Button
on (press) {
_root.MAPNUMBER = "DestructionSD";
_root.gotoAndPlay("Start");
_root.T = _root.getTimer();
clearInterval(rb);
}
Symbol 1664 Button
on (press) {
_root.MAPNUMBER = "Destruction";
_root.gotoAndPlay("Start");
_root.T = _root.getTimer();
clearInterval(rb);
}
Symbol 1666 Button
on (press) {
_root.MAPNUMBER = "SurvivalKnight";
_root.gotoAndPlay("Start");
_root.T = _root.getTimer();
clearInterval(rb);
}
Symbol 1668 Button
on (press) {
_root.MAPNUMBER = "SurvivalZombie";
_root.gotoAndPlay("Start");
_root.T = _root.getTimer();
clearInterval(rb);
}
Symbol 1670 Button
on (press) {
_root.MAPNUMBER = "Survival";
_root.gotoAndPlay("Start");
_root.T = _root.getTimer();
clearInterval(rb);
}
Symbol 1672 Button
on (press) {
_root.MAPNUMBER = 1;
_root.gotoAndPlay("Start");
_root.T = _root.getTimer();
clearInterval(rb);
}
Symbol 1674 Button
on (press) {
loadCheat(CHEAT);
}
Symbol 1680 Button
on (press) {
removeMovieClip(mS);
gotoAndStop ("Main");
}
Symbol 1684 MovieClip Frame 1
function noobSFX(name) {
soundeffect = _root.createEmptyMovieClip("menusfx", 30405521);
var _local2 = new Sound(soundeffect);
_local2.attachSound(name);
_local2.start(0, 0);
_local2.setPan(0);
_local2.setVolume(_root.VOLUME_SFX);
}
function loadScreen(type) {
mS = attachMovie(("mc." + type) + "Screen", "mS", 1);
mS._x = 0;
mS._y = 0;
mS._alpha = 0;
mS.sbl = 1000;
var _local3 = new flash.filters.BlurFilter(mS.sbl, 0, 1);
mS.filters = [_local3];
mS.run = function () {
var _local3 = new flash.filters.BlurFilter(this.sbl, 0, 1);
this.sbl = this.sbl * 0.8;
if (_root.blur == true) {
this.filters = [_local3];
} else {
this.filters = [];
}
if (this._alpha < 100) {
this._alpha = this._alpha + 5;
}
};
clearInterval(_root.mSinterval);
_root.mSinterval = setInterval(mS, "run", 20);
}
function loadButtons() {
n = 0;
while (n < buttons.length) {
buttons[n].bl = 0;
buttons[n].w = buttons[n]._width;
buttons[n].h = buttons[n]._height;
buttons[n].x = buttons[n]._x;
buttons[n].y = buttons[n]._y;
buttons[n].a = 80;
buttons[n].blurTimer = n * 10;
buttons[n].nr = n;
buttons[n].onRollOver = function () {
if (this.sL == false) {
noobSFX("benelli_insertshell.wav");
info.TEXT = DESC[this.nr];
info.TEXT.scroll = 1;
}
m = 0;
while (m < buttons.length) {
buttons[m].sL = false;
m++;
}
this.sL = true;
};
buttons[n].onPress = function () {
noobSFX("button14.wav");
};
n++;
}
}
function runButtons() {
n = 0;
while (n < buttons.length) {
if (buttons[n].sL == true) {
buttons[n]._width = buttons[n]._width + (((buttons[n].w * 2) - buttons[n]._width) * 0.4);
buttons[n]._height = buttons[n]._height + (((buttons[n].h * 2) - buttons[n]._height) * 0.4);
buttons[n]._x = buttons[n].x;
buttons[n]._y = buttons[n].y;
buttons[n]._alpha = 100;
buttons[n].bl = buttons[n].bl * 0.9;
} else {
buttons[n]._width = buttons[n]._width + ((buttons[n].w - buttons[n]._width) * 0.4);
buttons[n]._height = buttons[n]._height + ((buttons[n].h - buttons[n]._height) * 0.4);
buttons[n]._x = buttons[n].x;
buttons[n]._y = buttons[n].y;
buttons[n]._alpha = buttons[n].a;
buttons[n].bl = buttons[n].bl + ((10 - buttons[n].bl) * 0.1);
}
n++;
}
}
stop();
buttons = [btn_play, btn_cheats, btn_training, btn_configure, btn_credits, btn_playMoreGames];
btn_play.sL = true;
clearInterval(re);
bc = 0;
bl = 100;
moveTo = function (tar) {
resetButtons();
if (tar == pl0) {
camera.backfade = "out";
} else {
camera.backfade = "in";
}
if (tar == pl3) {
buttons = [btn_start, btn_survivalMode, btn_survivalZombieMode, btn_survivalKnightMode, btn_destructionMode, btn_destructionSDMode, btn_nadeDodger];
DESC = ["<b>Adventure Mode</b>\n\n Find your way to the end of each level, destroying anything that gets in your way. Pick up more powerful weapons along the way to help you kill more powerful enemies.\n\n View the training section to make sure you know how to use a Laser Turret before starting. Playing Survival modes may help familiarize you with different enemies and weapons, and might be a good idea to do before playing Adventure Mode.", "<b>Survival Mode</b>\n\n Survive each wave of enemies for as long as you can. Enemies spawn one by one near the right or left edges of the level. Harder enemies start appearing at higher stages.", "<b>Zombie Survival Mode</b>\n\n Similar to regular Survival Mode, except that the only enemies are Zombies. Although they will usually be slower than you, their attack damage can quickly become very high, and are soon capable of killing you in one hit.\n\n Less enemies appear, but the ones that do are more powerful: they do more damage, have more health, are faster, and can attack from a farther range than smaller enemies. Enemies become increasingly powerful based on the stage number.", "<b>Knight Survival Mode</b>\n\n Similar to regular Survival Mode, except that the only enemies are Knights. This mode is more difficult than Zombie Survival Mode, because Knights end up faster than you after a very short period of time.\n\n Less enemies appear, but the ones that do are more powerful: they do more damage, have more health, are faster, and can attack from a farther range than smaller enemies. Enemies become increasingly powerful based on the stage number.", "<b>Destruction Mode</b>\n\n Defend all ten of your blocks against wave after wave of enemies for as long as you can. Use explosives carefully, or you might damage the blocks you're defending.\n\n Enemy spawning for each stage is staggered: not all enemies appear at once. There is a fifty-fifty chance of an enemy spawning on either side of your base, so be careful not to run out to one side too far, or you may not be able to get back to the other side in time to defend the opposite outside block.\n\n You may have to use explosives and sacrifice one of your blocks to take out a large group of enemies.", "<b>Sudden Death Destruction Mode</b>\n\n Similar to regular Destruction Mode, except you only have one block to defend. This means that you'll have less area to move around, but can probably use more explosives in order to defend it. Running away from the block to grab powerups or weapons can be very risky.", "<b>Nade Dodger Mode</b>\n\n You have no weapons, and kicking cannot damage your enemies. The only objective in Nade Dodger Mode is to run around avoiding frag and flashbang grenades for as long as you can. Another Grunt will appear about every five seconds.\n\n Keep moving; Grunts are fairly accurate when throwing their grenades. Try not to jump off the map if you get blinded by a flashbang explosion."];
removeMovieClip(mS);
info.TEXT = "Select a gametype.";
btn_start.sL = true;
loadButtons();
} else if (tar == pl0) {
buttons = [btn_play, btn_cheats, btn_training, btn_configure, btn_credits, btn_playMoreGames];
btn_play.sL = true;
loadButtons();
clearInterval(re);
} else if (tar == pl4) {
buttons = [];
removeMovieClip(mS);
btn_enter.sL = true;
OUTPUT = "";
btn_start.sL = true;
loadButtons();
ed = false;
runEnter = function () {
if (Key.isDown(13)) {
if (ed == false) {
loadCheat(CHEAT);
}
ed = true;
} else {
ed = false;
}
};
clearInterval(re);
re = setInterval(runEnter, 1);
loadCheat = function (ch) {
VALID = false;
for (var _local3 in _root.CHEATS) {
if (ch == _root.CHEATS[_local3][0]) {
VALID = true;
if (_root.CHEATS[_local3][2] == false) {
mes = _root.CHEATS[_local3][1] + " enabled.";
_root.CHEATS[_local3][2] = true;
} else {
mes = _root.CHEATS[_local3][1] + " disabled.";
_root.CHEATS[_local3][2] = false;
}
break;
}
}
if (VALID == false) {
mes = "Invalid cheat code.";
} else {
CHEAT = "";
}
OUTPUT = mes;
};
}
camera.tar = tar._y;
};
loadButtons();
resetButtons = function () {
n = 0;
while (n < buttons.length) {
buttons[n]._width = buttons[n].w;
buttons[n]._height = buttons[n].h;
buttons[n]._x = buttons[n].x;
buttons[n]._y = buttons[n].y;
buttons[n]._alpha = buttons[n].a;
buttons[n].sL = false;
buttons[n].bl = buttons[n].bl + buttons[n].bl;
n++;
}
};
clearInterval(_root.rb);
_root.rb = setInterval(runButtons, 20);
Symbol 1684 MovieClip Frame 2
Symbol 1684 MovieClip Frame 3
Symbol 1684 MovieClip Frame 4
buttons = [btn_start, btn_survivalMode, btn_survivalZombieMode, btn_survivalKnightMode, btn_destructionMode, btn_destructionSDMode, btn_back];
DESC = ["<b>Adventure Mode</b>\n\n Find your way to the end of each level, destroying anything that gets in your way. Pick up more powerful weapons along the way to help you defeat more powerful enemies.\n\n View the training section to make sure you know how to use a Laser Turret before starting. Playing Survival modes may help to familiarize you with different enemies and weapons, and might be a good idea to do before playing Adventure Mode.", "<b>Survival Mode</b>\n\n Survive each wave of enemies for as long as you can. All enemies spawn at the same time at the start of each stage, but you remain invincible for about two seconds afterwards. Harder enemies start appearing at higher stages.", "<b>Zombie Survival Mode</b>\n\n Similar to regular Survival Mode, except that the only enemies are Zombies. Although they will usually be slower than you, their attack damage can quickly become very high, eventually being capable of killing you in one hit.\n\n Less enemies appear, but the ones that do are more powerful: they do more damage, have more health, are faster, and can attack from a farther range than smaller enemies. Enemies become increasingly powerful based on the stage number.", "<b>Knight Survival Mode</b>\n\n Similar to regular Survival Mode, except that the only enemies are Knights. This mode is mroe difficult than Zombie Survival Mode, because Knights end up faster than you after a very short period of time.\n\n Less enemies appear, but the ones that do are more powerful: they do more damage, have more health, are faster, and can attack from a farther range than smaller enemies. Enemies become increasingly powerful based on the stage number.", "<b>Destruction Mode</b>\n\n Defend all ten of your blocks against wave after wave of enemies for as long as you can. Use explosives carefully, or you might damage the blocks you're defending.\n\n Enemy spawning for each stage is staggered: not all enemies appear at once. There is a fifty-fifty chance of an enemy spawning on either side of your base, so be careful not to run out to one side too far, or you may not be able to get back to the other side in time to defend the opposite outside block.\n\n You may have to use explosives and sacrifice one of your blocks to take out a large group of enemies.", "<b>Sudden Death Destruction Mode</b>\n\n Similar to regular Destruction Mode, except you only have one block to defend. This means that you'll have less area to move around, but can probably use more explosives in order to defend it. Running away from the block to grab powerups or weapons can be very risky.", ""];
removeMovieClip(mS);
info.TEXT = "Select a gametype.";
btn_start.sL = true;
loadButtons();
Symbol 1684 MovieClip Frame 5
buttons = [btn_enter, btn_back];
removeMovieClip(mS);
btn_enter.sL = true;
OUTPUT = "";
btn_start.sL = true;
loadButtons();
ed = false;
runEnter = function () {
if (Key.isDown(13)) {
if (ed == false) {
loadCheat(CHEAT);
}
ed = true;
} else {
ed = false;
}
};
clearInterval(re);
re = setInterval(runEnter, 1);
loadCheat = function (ch) {
VALID = false;
for (var _local3 in _root.CHEATS) {
if (ch == _root.CHEATS[_local3][0]) {
VALID = true;
if (_root.CHEATS[_local3][2] == false) {
mes = _root.CHEATS[_local3][1] + " enabled.";
_root.CHEATS[_local3][2] = true;
} else {
mes = _root.CHEATS[_local3][1] + " disabled.";
_root.CHEATS[_local3][2] = false;
}
break;
}
}
if (VALID == false) {
mes = "Invalid cheat code.";
} else {
CHEAT = "";
}
OUTPUT = mes;
};
Symbol 1686 MovieClip Frame 1
_root.generate16x128Object(this._x - 16, this._y);
if (_root.MAPNUMBER != "Training") {
this._visible = false;
}
Symbol 1687 MovieClip Frame 1
_root.generate128x16Object(this._x, this._y, 0);
if (_root.MAPNUMBER != "Training") {
this._visible = false;
}
Symbol 1688 MovieClip Frame 1
_root.generateBoosterObject(this._x, this._y, 0);
this._visible = false;
Symbol 1690 MovieClip Frame 1
_root.generate30_60_90Triangle(this._x, this._y, "l");
if (_root.MAPNUMBER != "Training") {
this._visible = false;
}
Symbol 1692 MovieClip Frame 1
_root.generate30_60_90Triangle(this._x, this._y, "r");
if (_root.MAPNUMBER != "Training") {
this._visible = false;
}
Symbol 1698 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1701 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1705 MovieClip Frame 1
_root.generateBrush1(this._x, this._y);
this._visible = false;
Symbol 1706 MovieClip Frame 1
_root.generateBush(this._x, this._y);
this._visible = false;
Symbol 1707 MovieClip Frame 1
_root.generateTree(this._x, this._y);
this._visible = false;
Symbol 1709 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1714 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1716 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1718 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1720 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1722 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1723 MovieClip Frame 1
this.remove = false;
this._visible = false;
this.eL = this._x;
this.eR = this._x + this._width;
this.eT = this._y;
this.eB = this._y + this._height;
this.WID = this._width / 2;
this.DEL = [];
this.checkCollision = function () {
pL = _root.player;
if (((pL._x + pL.vx) >= this.eL) && ((pL._x + pL.vx) <= this.eR)) {
if ((((pL._y + pL.vy) + pL.eS_y) >= this.eT) && (pL._y < this.eT)) {
pL._y = this.eT - pL.eS_y;
pL.vy = 0;
pL.onGround = true;
pL.onGroundTimer = 0;
pL._rotation = 0;
_root.pS._rotation = 0;
} else if ((((pL._y + pL.vy) - pL.eS_y) <= this.eB) && (pL._y > this.eB)) {
pL._y = this.eB + pL.eS_y;
pL.vy = 0;
}
}
if (((pL._y + pL.vy) >= this.eT) && ((pL._y + pL.vy) <= this.eB)) {
if ((((pL._x + pL.vx) + pL.eS_x) >= this.eL) && (pL._x < this.eL)) {
pL._x = this.eL - pL.eS_x;
pL.vx = 0;
} else if ((((pL._x + pL.vx) - pL.eS_x) <= this.eR) && (pL._x > this.eR)) {
pL._x = this.eR + pL.eS_x;
pL.vx = 0;
}
}
if ((_root.player._y + _root.player.eS_y) < this._y) {
_root.player.pS._y = this._y;
_root.player.pS._x = _root.player._x;
}
};
this.onEnterFrame = function () {
if ((_root.KILLS >= 6) && (_root.chubbs.fireTimer <= 0)) {
a = 0;
while (a < 6) {
if (_root["explosion" + a].hitTest(this)) {
if (this.R == undefined) {
this.R = true;
this.remove = true;
}
}
a++;
}
}
if (this.R) {
if (this._name == "mc1") {
this._x = 722;
_root.player.checkExplosion(this, 212, 1000);
_parent.br1.explode();
} else {
this._x = 1144;
_root.player.checkExplosion(this, 212, 1000);
_parent.br2.explode();
}
this.R = false;
}
if (this.remove == false) {
this.checkCollision();
}
};
Symbol 1725 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1727 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1729 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1732 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1734 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1736 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1738 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1740 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1743 MovieClip Frame 1
this.exploding = false;
this.vx = 0;
this.vy = 0;
this.rot = 0;
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
if (this.exploding == true) {
this.vy = this.vy + 0.25;
if (this._alpha > 0) {
this._alpha = this._alpha - 0.5;
} else {
this._visible = false;
}
}
this._x = this._x + this.vx;
this._y = this._y + this.vy;
this._rotation = this._rotation + this.rot;
};
this.explode = function () {
if (this.exploding == false) {
this.exploding = true;
this.vy = -(5 + random(10));
this.vx = (random(3) - 4) / 2;
if (random(2) == 0) {
this.rot = 5 + random(5);
} else {
this.rot = -5 - random(5);
}
}
};
Symbol 1750 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1752 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1753 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1755 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1757 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1759 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1761 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1770 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1772 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1776 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1779 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1782 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1789 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1792 MovieClip Frame 1
this.onEnterFrame = function () {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
};
Symbol 1793 MovieClip Frame 1
stop();
this.map = "map" + this.mapType;
this.weapons = ["machineGun", "mac10", "mp5", "assaultRifle", "shotGun", "m4", "sniperRifle", "flakCannon", "stinger", "nade", "mine"];
_root.grunts = [];
_root.zombies = [];
_root.frogs = [];
_root.knights = [];
this.gotoAndStop(this.map);
Symbol 1793 MovieClip Frame 2
stop();
_root.makeTurret(0, 1800, 332);
_root.makeWeapon(0, 1150, 266, "mac10");
_root.makeWeapon(1, 1050, 266, "mp5");
_root.makeWeapon(2, 950, 266, "machineGun");
_root.makeWeapon(3, 850, 266, "flakCannon");
_root.makeWeapon(4, 1600, 594, "stinger");
n = 0;
while (n < 6) {
m = 0;
while (m < 3) {
m++;
}
n++;
}
Instance of Symbol 1687 MovieClip in Symbol 1793 MovieClip Frame 2
onClipEvent (load) {
touched = false;
}
onClipEvent (enterFrame) {
if (_root.player.hitTest(this)) {
touched = true;
}
if (((_root.player._y < 312) && (Math.abs(this._x - _root.iF._x) < 200)) && (touched == true)) {
if (_root.inTurret == false) {
_root.trainingText = "[ DOUBLE-TAP LEFT OR RIGHT MOVEMENT KEYS TO ENTER A TURRET ]";
this.turretTimer = 0;
} else {
this.turretTimer++;
if (this.turretTimer > 300) {
_root.trainingText = "[ DOUBLE-TAP LEFT OR RIGHT MOVEMENT KEYS TO EXIT A TURRET ]";
} else {
_root.trainingText = "[ HOLD DOWN YOUR MOUSE TO CHARGE THE TURRET LASER ]";
}
}
}
}
Instance of Symbol 1687 MovieClip in Symbol 1793 MovieClip Frame 2
onClipEvent (enterFrame) {
if (_root.player.hitTest(this)) {
_root.trainingText = ((("[ USE " + _root.getName(_root.kSwUp)) + " AND ") + _root.getName(_root.kSwDn)) + " TO SWTICH WEAPONS ]";
}
}
Instance of Symbol 1687 MovieClip in Symbol 1793 MovieClip Frame 2
onClipEvent (enterFrame) {
if ((_root.player._y > 312) && (Math.abs(this._x - _root.iF._x) < 50)) {
_root.trainingText = "[ WALK UP ANGLED SLOPES ]";
}
}
Instance of Symbol 1687 MovieClip in Symbol 1793 MovieClip Frame 2
onClipEvent (enterFrame) {
if (_root.player.hitTest(this)) {
_root.trainingText = ("[ PRESS " + _root.getName(_root.kQuit)) + " TO RETURN TO THE MAIN MENU ]";
}
}
Instance of Symbol 1687 MovieClip in Symbol 1793 MovieClip Frame 2
onClipEvent (enterFrame) {
if (_root.player.hitTest(this)) {
_root.trainingText = "[ USE BOOSTER OBJECTS ]";
}
}
Instance of Symbol 1687 MovieClip in Symbol 1793 MovieClip Frame 2
onClipEvent (enterFrame) {
if (_root.player.hitTest(this)) {
_root.trainingText = "[ SHOOT TO REMOVE DESTRUCTIBLE OBJECTS ]";
}
}
Instance of Symbol 1687 MovieClip in Symbol 1793 MovieClip Frame 2
onClipEvent (enterFrame) {
if (_root.player.hitTest(this)) {
_root.trainingText = "[ WALK UP ANGLED SLOPES ]";
}
}
Symbol 1793 MovieClip Frame 3
function loadStageScreen(stageNumber) {
stageScreen = attachMovie("mc.stageScreen", "stageScreen", 600000);
stageScreen._alpha = 0;
stageScreen._x = _root.iF._x;
stageScreen._y = _root.iF._y - 100;
stageScreen.timer = 60;
stageScreen.number = stageNumber;
stageScreen.onEnterFrame = function () {
if (_root.paused != true) {
textStuff = new String();
if (stageNumber != "YOU LOSE!!!") {
textStuff = "STAGE " + stageNumber;
} else {
textStuff = stageNumber;
}
this.text = textStuff;
this.timer--;
if (this.timer <= 10) {
this._alpha = this.timer * 5;
if (this._alpha <= 0) {
if (this.text == "YOU LOSE!!!") {
_root.player.health = 0;
removeMovieClip(this);
} else {
removeMovieClip(this);
}
}
} else if (this._alpha < 100) {
this._alpha = this._alpha + 10;
}
}
};
}
stop();
this.powerups = ["health", "berserk", "shield"];
this.weapon = false;
this.cr_weapon = false;
this.powerup = false;
this.cr_powerup = false;
this.numWeapons = 0;
this.numPowerups = 0;
this.stage = 1;
this.stageTimer = 25;
this.nFG = 0;
this.nZM = 0;
this.nGR = 0;
this.nKN = 0;
CREATED = false;
CREATEDTIMER = 0;
loseLoad = false;
this.we = 0;
while (this.we < this.weapons.length) {
_root.makeWeapon(9 + this.we, 180, 558, this.weapons[this.we]);
this.we++;
}
either = function () {
if (random(2) == 0) {
val = 160;
val = val + random(100);
} else {
val = 1185;
val = val - random(100);
}
return(val);
};
this.onEnterFrame = function () {
if (_root.paused != true) {
if (CREATEDTIMER > 0) {
CREATEDTIMER--;
if ((CREATEDTIMER % 50) == 0) {
n = this.stage - ((CREATEDTIMER / 50) + 1);
if (this.stage > 3) {
if (this.stage > 6) {
if (this.stage > 9) {
if (n > 9) {
nGR++;
_root.makeGrunt(nGR, either(), 569, 100, 50, 1250);
}
if (n <= 9) {
this.rand = random(3);
if (this.rand == 0) {
nKN++;
_root.makeKnight(nKN, either(), 570, 100, 50, 1250);
} else if (this.rand == 1) {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
} else {
nFG++;
_root.makeFrog(nFG, either(), 590, 100, 50, 1250);
}
}
} else if (random(4) == 0) {
nFG++;
_root.makeFrog(nFG, either(), 590, 100, 50, 1250);
} else if (random(2) == 0) {
nKN++;
_root.makeKnight(nKN, either(), 570, 100, 50, 1250);
} else {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
}
} else if ((n % 2) != 0) {
nKN++;
_root.makeKnight(nKN, either(), 570, 100, 50, 1250);
} else {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
}
} else {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
}
num = 0;
while (num < _root.zombies.length) {
_root.zombies[num].attacked = true;
num++;
}
num = 0;
while (num < _root.knights.length) {
_root.knights[num].attacked = true;
num++;
}
num = 0;
while (num < _root.frogs.length) {
_root.frogs[num].attacked = true;
num++;
}
num = 0;
while (num < _root.grunts.length) {
_root.grunts[num].attacked = true;
num++;
}
}
} else {
CREATED = true;
}
if (((((_root.nK == 0) && (_root.nZ == 0)) && (_root.nG == 0)) && (_root.nF == 0)) && (CREATED == true)) {
if (this.stageTimer == 0) {
_root.player.invincibilityTimer = _root.player.invincibilityTimer + 50;
_root.grunts = [];
_root.zombies = [];
_root.frogs = [];
_root.knights = [];
this.nFG = -1;
this.nZM = -1;
this.nGR = -1;
this.nKN = -1;
CREATED = false;
CREATEDTIMER = this.stage * 50;
loadStageScreen(this.stage);
this.stage++;
this.stageTimer = 25;
} else {
this.stageTimer--;
}
}
if (((_root.KILLS % 5) == 0) && (_root.KILLS != 0)) {
this.weapon = true;
} else {
this.weapon = false;
this.cr_weapon = false;
}
if ((this.cr_weapon == false) && (this.weapon == true)) {
this.weaponType = random(weapons.length);
_root.makeWeapon(this.numWeapons, 50 + random(1100), 558, this.weapons[this.weaponType]);
this.cr_weapon = true;
if (this.numWeapons < 5) {
this.numWeapons++;
} else {
this.numWeapons = 0;
}
}
if (((_root.KILLS % 7) == 0) && (_root.KILLS != 0)) {
this.powerup = true;
} else {
this.powerup = false;
this.cr_powerup = false;
}
if ((this.cr_powerup == false) && (this.powerup == true)) {
this.powerupType = random(powerups.length);
_root.makePowerup(this.numPowerups, 50 + random(1100), 558, this.powerups[this.powerupType]);
this.cr_powerup = true;
if (this.numPowerups < 5) {
this.numPowerups++;
} else {
this.numPowerups = 0;
}
}
}
};
Symbol 1793 MovieClip Frame 4
function loadStageScreen(stageNumber) {
stageScreen = attachMovie("mc.stageScreen", "stageScreen", 600000);
stageScreen._alpha = 0;
stageScreen._x = _root.iF._x;
stageScreen._y = _root.iF._y - 100;
stageScreen.timer = 60;
stageScreen.number = stageNumber;
stageScreen.onEnterFrame = function () {
if (_root.paused != true) {
textStuff = new String();
if (stageNumber != "YOU LOSE!!!") {
textStuff = "STAGE " + stageNumber;
} else {
textStuff = stageNumber;
}
this.text = textStuff;
this.timer--;
if (this.timer <= 10) {
this._alpha = this.timer * 5;
if (this._alpha <= 0) {
if (this.text == "YOU LOSE!!!") {
_root.player.health = 0;
removeMovieClip(this);
} else {
removeMovieClip(this);
}
}
} else if (this._alpha < 100) {
this._alpha = this._alpha + 10;
}
}
};
}
stop();
this.powerups = ["health", "berserk", "shield"];
this.weapon = false;
this.cr_weapon = false;
this.powerup = false;
this.cr_powerup = false;
this.numWeapons = 0;
this.numPowerups = 0;
this.stage = 1;
this.stageTimer = 25;
this.nFG = 0;
this.nZM = 0;
this.nGR = 0;
this.nKN = 0;
CREATED = false;
CREATEDTIMER = 0;
loseLoad = false;
this.we = 0;
while (this.we < this.weapons.length) {
_root.makeWeapon(9 + this.we, 180, 558, this.weapons[this.we]);
this.we++;
}
either = function () {
if (random(2) == 0) {
val = 160;
val = val + random(100);
} else {
val = 1185;
val = val - random(100);
}
return(val);
};
this.onEnterFrame = function () {
if (_root.paused != true) {
if ((_root.BLOCKS_DESTROYED >= 10) && (_root.BLOCKS_DESTROYED != undefined)) {
if (!loseLoad) {
loadStageScreen("YOU LOSE!!!");
loseLoad = true;
}
}
if (CREATEDTIMER > 0) {
CREATEDTIMER--;
if ((CREATEDTIMER % 50) == 0) {
n = (CREATEDTIMER / 50) + 1;
if (this.stage > 3) {
if (this.stage > 6) {
if (this.stage > 9) {
if (n > 9) {
nGR++;
_root.makeGrunt(nGR, either(), 569, 100, 50, 1250);
}
if (n <= 9) {
this.rand = random(3);
if (this.rand == 0) {
nKN++;
_root.makeKnight(nKN, either(), 570, 100, 50, 1250);
} else if (this.rand == 1) {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
} else {
nFG++;
_root.makeFrog(nFG, either(), 590, 100, 50, 1250);
}
}
} else if (random(5) == 0) {
nFG++;
_root.makeFrog(nFG, either(), 590, 100, 50, 1250);
} else if (random(2) == 0) {
nKN++;
_root.makeKnight(nKN, either(), 570, 100, 50, 1250);
} else {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
}
} else if ((n % 2) != 0) {
nKN++;
_root.makeKnight(nKN, either(), 570, 100, 50, 1250);
} else {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
}
} else {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
}
num = 0;
while (num < _root.zombies.length) {
_root.zombies[num].attacked = true;
num++;
}
num = 0;
while (num < _root.knights.length) {
_root.knights[num].attacked = true;
num++;
}
num = 0;
while (num < _root.frogs.length) {
_root.frogs[num].attacked = true;
num++;
}
num = 0;
while (num < _root.grunts.length) {
_root.grunts[num].attacked = true;
num++;
}
}
} else {
CREATED = true;
}
if (((((_root.nK == 0) && (_root.nZ == 0)) && (_root.nG == 0)) && (_root.nF == 0)) && (CREATED == true)) {
if (this.stageTimer == 0) {
_root.player.invincibilityTimer = _root.player.invincibilityTimer + 50;
_root.grunts = [];
_root.zombies = [];
_root.frogs = [];
_root.knights = [];
this.nFG = -1;
this.nZM = -1;
this.nGR = -1;
this.nKN = -1;
CREATED = false;
CREATEDTIMER = this.stage * 50;
loadStageScreen(this.stage);
this.stage++;
this.stageTimer = 25;
} else {
this.stageTimer--;
}
}
if (((_root.KILLS % 5) == 0) && (_root.KILLS != 0)) {
this.weapon = true;
} else {
this.weapon = false;
this.cr_weapon = false;
}
if ((this.cr_weapon == false) && (this.weapon == true)) {
this.weaponType = random(weapons.length);
_root.makeWeapon(this.numWeapons, 50 + random(1100), 558, this.weapons[this.weaponType]);
this.cr_weapon = true;
if (this.numWeapons < 5) {
this.numWeapons++;
} else {
this.numWeapons = 0;
}
}
if (((_root.KILLS % 7) == 0) && (_root.KILLS != 0)) {
this.powerup = true;
} else {
this.powerup = false;
this.cr_powerup = false;
}
if ((this.cr_powerup == false) && (this.powerup == true)) {
this.powerupType = random(powerups.length);
_root.makePowerup(this.numPowerups, 50 + random(1100), 558, this.powerups[this.powerupType]);
this.cr_powerup = true;
if (this.numPowerups < 5) {
this.numPowerups++;
} else {
this.numPowerups = 0;
}
}
}
};
Symbol 1793 MovieClip Frame 5
function loadStageScreen(stageNumber) {
stageScreen = attachMovie("mc.stageScreen", "stageScreen", 600000);
stageScreen._alpha = 0;
stageScreen._x = _root.iF._x;
stageScreen._y = _root.iF._y - 100;
stageScreen.timer = 60;
stageScreen.number = stageNumber;
stageScreen.onEnterFrame = function () {
if (_root.paused != true) {
textStuff = new String();
if (stageNumber != "YOU LOSE!!!") {
textStuff = "STAGE " + stageNumber;
} else {
textStuff = stageNumber;
}
this.text = textStuff;
this.timer--;
if (this.timer <= 10) {
this._alpha = this.timer * 5;
if (this._alpha <= 0) {
if (this.text == "YOU LOSE!!!") {
_root.player.health = 0;
removeMovieClip(this);
} else {
removeMovieClip(this);
}
}
} else if (this._alpha < 100) {
this._alpha = this._alpha + 10;
}
}
};
}
stop();
this.powerups = ["health", "berserk", "shield"];
this.weapon = false;
this.cr_weapon = false;
this.powerup = false;
this.cr_powerup = false;
this.numWeapons = 0;
this.numPowerups = 0;
this.stage = 1;
this.stageTimer = 25;
this.nFG = 0;
this.nZM = 0;
this.nGR = 0;
this.nKN = 0;
CREATED = false;
CREATEDTIMER = 0;
loseLoad = false;
this.we = 0;
while (this.we < this.weapons.length) {
_root.makeWeapon(9 + this.we, 180, 558, this.weapons[this.we]);
this.we++;
}
either = function () {
if (random(2) == 0) {
val = 160;
val = val + random(100);
} else {
val = 1185;
val = val - random(100);
}
return(val);
};
this.onEnterFrame = function () {
if (_root.paused != true) {
if ((_root.BLOCKS_DESTROYED >= 1) && (_root.BLOCKS_DESTROYED != undefined)) {
if (!loseLoad) {
loadStageScreen("YOU LOSE!!!");
loseLoad = true;
}
}
if (CREATEDTIMER > 0) {
CREATEDTIMER--;
if ((CREATEDTIMER % 50) == 0) {
n = (CREATEDTIMER / 50) + 1;
if (this.stage > 3) {
if (this.stage > 6) {
if (this.stage > 9) {
if (n > 9) {
nGR++;
_root.makeGrunt(nGR, either(), 569, 100, 50, 1250);
}
if (n <= 9) {
this.rand = random(3);
if (this.rand == 0) {
nKN++;
_root.makeKnight(nKN, either(), 570, 100, 50, 1250);
} else if (this.rand == 1) {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
} else {
nFG++;
_root.makeFrog(nFG, either(), 590, 100, 50, 1250);
}
}
} else if (random(5) == 0) {
nFG++;
_root.makeFrog(nFG, either(), 590, 100, 50, 1250);
} else if (random(2) == 0) {
nKN++;
_root.makeKnight(nKN, either(), 570, 100, 50, 1250);
} else {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
}
} else if ((n % 2) != 0) {
nKN++;
_root.makeKnight(nKN, either(), 570, 100, 50, 1250);
} else {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
}
} else {
nZM++;
_root.makeZombie(nZM, either(), 569, 100, 50, 1250);
}
num = 0;
while (num < _root.zombies.length) {
_root.zombies[num].attacked = true;
num++;
}
num = 0;
while (num < _root.knights.length) {
_root.knights[num].attacked = true;
num++;
}
num = 0;
while (num < _root.frogs.length) {
_root.frogs[num].attacked = true;
num++;
}
num = 0;
while (num < _root.grunts.length) {
_root.grunts[num].attacked = true;
num++;
}
}
} else {
CREATED = true;
}
if (((((_root.nK == 0) && (_root.nZ == 0)) && (_root.nG == 0)) && (_root.nF == 0)) && (CREATED == true)) {
if (this.stageTimer == 0) {
_root.player.invincibilityTimer = _root.player.invincibilityTimer + 50;
_root.grunts = [];
_root.zombies = [];
_root.frogs = [];
_root.knights = [];
this.nFG = -1;
this.nZM = -1;
this.nGR = -1;
this.nKN = -1;
CREATED = false;
CREATEDTIMER = this.stage * 50;
loadStageScreen(this.stage);
this.stage++;
this.stageTimer = 25;
} else {
this.stageTimer--;
}
}
if (((_root.KILLS % 5) == 0) && (_root.KILLS != 0)) {
this.weapon = true;
} else {
this.weapon = false;
this.cr_weapon = false;
}
if ((this.cr_weapon == false) && (this.weapon == true)) {
this.weaponType = random(weapons.length);
_root.makeWeapon(this.numWeapons, 50 + random(1100), 558, this.weapons[this.weaponType]);
this.cr_weapon = true;
if (this.numWeapons < 5) {
this.numWeapons++;
} else {
this.numWeapons = 0;
}
}
if (((_root.KILLS % 7) == 0) && (_root.KILLS != 0)) {
this.powerup = true;
} else {
this.powerup = false;
this.cr_powerup = false;
}
if ((this.cr_powerup == false) && (this.powerup == true)) {
this.powerupType = random(powerups.length);
_root.makePowerup(this.numPowerups, 50 + random(1100), 558, this.powerups[this.powerupType]);
this.cr_powerup = true;
if (this.numPowerups < 5) {
this.numPowerups++;
} else {
this.numPowerups = 0;
}
}
}
};
Symbol 1793 MovieClip Frame 6
stop();
_root.makeZombie(0, 500, 569, 100, 16, 1552);
_root.makeZombie(1, 2983, 100, 100, 2342, 3260);
_root.makeZombie(2, 3100, 100, 100, 2342, 3260);
_root.makeGrunt(0, 600, 569, 100, 16, 1552);
_root.makeGrunt(1, 1400, 569, 100, 16, 1552);
_root.makeGrunt(2, 1250, 569, 100, 16, 1552);
_root.makeGrunt(3, 1300, 569, 100, 16, 1552);
_root.loadGrassBoss(-492.4, 772.6);
_root.makeWeapon(0, 800, 569, "assaultRifle");
_root.makeWeapon(2, 1200, -850, "shotGun");
_root.makeWeapon(3, 2500, 80, "sniperRifle");
_root.makeFrog(0, 2000, -400, 100, 1500, 2640);
_root.makeFrog(1, 2100, -400, 100, 1500, 2640);
Instance of Symbol 1702 MovieClip in Symbol 1793 MovieClip Frame 6
onClipEvent (load) {
_root.generateBoosterRightObject(this._x, this._y, 9);
this._visible = false;
}
Instance of Symbol 1703 MovieClip in Symbol 1793 MovieClip Frame 6
onClipEvent (load) {
_root.generateBoosterObject(this._x, this._y, 7);
this._visible = false;
}
Instance of Symbol 1704 MovieClip in Symbol 1793 MovieClip Frame 6
onClipEvent (load) {
this._visible = false;
_root.generate128x16Object(this._x, this._y, 5);
}
Instance of Symbol 1704 MovieClip in Symbol 1793 MovieClip Frame 6
onClipEvent (load) {
this._visible = false;
_root.generate128x16Object(this._x, this._y, 5);
}
Instance of Symbol 1711 MovieClip in Symbol 1793 MovieClip Frame 6
onClipEvent (enterFrame) {
if (this.hitTest(_root.iF)) {
this._visible = true;
} else {
this._visible = false;
}
}
Instance of Symbol 1711 MovieClip in Symbol 1793 MovieClip Frame 6
onClipEvent (load) {
this._alpha = 0;
}
onClipEvent (enterFrame) {
if (this.hitTest(_root.iF)) {
this._visible = true;
if (_root.KILLS >= 5) {
if (this._alpha < 100) {
this._alpha = this._alpha + 10;
}
}
} else {
this._visible = false;
}
}
Symbol 1793 MovieClip Frame 7
stop();
_root.makeChubbs(1530, -362.5, 100);
_root.makeWeapon(0, -425, -370, "mac10");
_root.makeWeapon(8, 0, -370, "m4");
_root.makeWeapon(1, 1500, 212, "mine");
_root.makeGrunt(0, -300, -360, 100, -735, 1965);
_root.makeGrunt(1, -250, -360, 100, -735, 1965);
_root.makeGrunt(2, 300, -360, 100, -735, 1965);
_root.makeGrunt(3, 400, -360, 100, -735, 1965);
_root.makeGrunt(4, 1200, -360, 100, -735, 1965);
_root.makeGrunt(5, 1300, -360, 100, -735, 1965);
made = false;
this.onEnterFrame = function () {
if (!made) {
if (_root.player._y > -230) {
_root.makeGrunt(0, 300, 1090, 100, 0, 950);
_root.makeGrunt(1, 400, 1090, 100, 0, 950);
_root.makeGrunt(2, 450, 1090, 100, 0, 950);
_root.makeGrunt(3, -300, 1034, 100, -1950, -180);
_root.makeGrunt(4, -350, 1034, 100, -1950, -180);
_root.makeGrunt(5, -400, 1034, 100, -1950, -180);
_root.makePowerup(0, 1550, 220, "shield");
_root.makeWeapon(2, 856, 1087, "mp5");
made = true;
}
}
};
Symbol 1793 MovieClip Frame 8
stop();
Symbol 1793 MovieClip Frame 9
function loadStageScreen(stageNumber) {
stageScreen = attachMovie("mc.stageScreen", "stageScreen", 600000);
stageScreen._alpha = 0;
stageScreen._x = _root.iF._x;
stageScreen._y = _root.iF._y - 100;
stageScreen.timer = 60;
stageScreen.number = stageNumber;
this.we = 0;
while (this.we < this.weapons.length) {
_root["AMMO_" + this.weapons[this.we]] = _root["STARTAMMO_" + this.weapons[this.we]];
this.we++;
}
stageScreen.onEnterFrame = function () {
if (_root.paused != true) {
textStuff = new String();
textStuff = "STAGE " + stageNumber;
this.text = textStuff;
this.timer--;
if (this.timer <= 10) {
this._alpha = this.timer * 5;
if (this._alpha <= 0) {
removeMovieClip(this);
}
} else if (this._alpha < 100) {
this._alpha = this._alpha + 10;
}
}
};
}
stop();
this.powerups = ["health", "berserk", "shield"];
this.weapon = false;
this.cr_weapon = false;
this.powerup = false;
this.cr_powerup = false;
this.numWeapons = 0;
this.numPowerups = 0;
this.stage = 1;
this.stageTimer = 25;
this.nFG = 0;
this.nZM = 0;
this.nGR = 0;
this.nKN = 0;
this.throughAllWeapons = 0;
this.we = 0;
while (this.we < this.weapons.length) {
_root.makeWeapon(9 + this.we, 180, 558, this.weapons[this.we]);
this.we++;
}
this.onEnterFrame = function () {
if (_root.paused != true) {
if (_root.nZ == 0) {
if (this.stageTimer == 0) {
_root.player.invincibilityTimer = _root.player.invincibilityTimer + 50;
_root.zombies = [];
this.nZM = -1;
loadStageScreen(this.stage);
n = 0;
while (n < (Math.floor(this.stage / 4) + 1)) {
nZM++;
_root.makeZombie(nZM, 100 + random(1500), 569, (100 + (this.stage * 25)) - ((Math.floor(this.stage / 4) + 1) * 20), 50, 1700);
n++;
}
this.stage++;
this.stageTimer = 25;
} else {
this.stageTimer--;
}
}
if (((_root.KILLS % 7) == 0) && (_root.KILLS != 0)) {
this.powerup = true;
} else {
this.powerup = false;
this.cr_powerup = false;
}
if ((this.cr_powerup == false) && (this.powerup == true)) {
this.powerupType = random(powerups.length);
_root.makePowerup(this.numPowerups, 50 + random(1100), 558, this.powerups[this.powerupType]);
this.cr_powerup = true;
if (this.numPowerups < 5) {
this.numPowerups++;
} else {
this.numPowerups = 0;
}
}
}
};
Symbol 1793 MovieClip Frame 10
function loadStageScreen(stageNumber) {
stageScreen = attachMovie("mc.stageScreen", "stageScreen", 600000);
stageScreen._alpha = 0;
stageScreen._x = _root.iF._x;
stageScreen._y = _root.iF._y - 100;
stageScreen.timer = 60;
stageScreen.number = stageNumber;
this.we = 0;
while (this.we < this.weapons.length) {
_root["AMMO_" + this.weapons[this.we]] = _root["STARTAMMO_" + this.weapons[this.we]];
this.we++;
}
stageScreen.onEnterFrame = function () {
if (_root.paused != true) {
textStuff = new String();
textStuff = "STAGE " + stageNumber;
this.text = textStuff;
this.timer--;
if (this.timer <= 10) {
this._alpha = this.timer * 5;
if (this._alpha <= 0) {
removeMovieClip(this);
}
} else if (this._alpha < 100) {
this._alpha = this._alpha + 10;
}
}
};
}
stop();
this.powerups = ["health", "berserk", "shield"];
this.weapon = false;
this.cr_weapon = false;
this.powerup = false;
this.cr_powerup = false;
this.numWeapons = 0;
this.numPowerups = 0;
this.stage = 1;
this.stageTimer = 25;
this.nFG = 0;
this.nZM = 0;
this.nGR = 0;
this.nKN = 0;
this.throughAllWeapons = 0;
this.we = 0;
while (this.we < this.weapons.length) {
_root.makeWeapon(9 + this.we, 180, 558, this.weapons[this.we]);
this.we++;
}
this.onEnterFrame = function () {
if (_root.paused != true) {
if (_root.nK == 0) {
if (this.stageTimer == 0) {
_root.player.invincibilityTimer = _root.player.invincibilityTimer + 50;
_root.knights = [];
this.nKN = -1;
loadStageScreen(this.stage);
n = 0;
while (n < (Math.floor(this.stage / 4) + 1)) {
nZM++;
_root.makeKnight(nZM, 100 + random(1500), 569, (100 + (this.stage * 25)) - ((Math.floor(this.stage / 4) + 1) * 20), 50, 1700);
n++;
}
this.stage++;
this.stageTimer = 25;
} else {
this.stageTimer--;
}
}
if (((_root.KILLS % 7) == 0) && (_root.KILLS != 0)) {
this.powerup = true;
} else {
this.powerup = false;
this.cr_powerup = false;
}
if ((this.cr_powerup == false) && (this.powerup == true)) {
this.powerupType = random(powerups.length);
_root.makePowerup(this.numPowerups, 50 + random(1100), 558, this.powerups[this.powerupType]);
this.cr_powerup = true;
if (this.numPowerups < 5) {
this.numPowerups++;
} else {
this.numPowerups = 0;
}
}
}
};
Symbol 1793 MovieClip Frame 11
pfs = 0;
while (pfs < 10) {
_root.makeZombie(_root.nZ, 400 + (pfs * 100), 569, 30 + (pfs * 40), 50, 1700);
pfs++;
}
_root.makeWeapon(0, 300, 558, "machineGun");
_root.makeWeapon(1, 400, 558, "stinger");
_root.makeWeapon(2, 1700, 558, "nade");
_root.makePowerup(0, 500, 558, "shield");
ztim = 0;
zombs = 0;
this.onEnterFrame = function () {
if (_root.paused != true) {
if (_root.KILLS >= 22) {
_root.iF.fadeScreen.fade = "in";
if (_root.iF.fadeScreen._alpha >= 100) {
_root.MAPNUMBER = 4;
_root.reset();
}
}
if (_root.KILLS >= 10) {
ztim++;
if (((ztim % 200) == 0) && (ztim != 0)) {
_root.makeZombie(zombs, 493, 569, 50 + ((ztim / 50) * 15), 50, 1700);
zombs++;
_root.makeZombie(zombs, 1293, 569, 50 + ((ztim / 50) * 15), 50, 1700);
zombs++;
num = 0;
while (num < _root.zombies.length) {
_root.zombies[num].attacked = true;
num++;
}
}
}
}
};
Instance of Symbol 1687 MovieClip "TTM" in Symbol 1793 MovieClip Frame 11
onClipEvent (load) {
build = false;
comp = false;
this.targetTimer = 0;
}
onClipEvent (enterFrame) {
if (_root.KILLS == 10) {
if (build == false) {
build = true;
_root.makeTurret(0, 893, 615);
}
}
if ((this.comp == false) && (this.build == true)) {
if (this.targetTimer < 100) {
this.targetTimer++;
_root.paused = true;
} else if (this.targetTimer == 100) {
this.targetTimer++;
_root.paused = false;
}
if (this.targetTimer < 75) {
_root.iF.trgt = _root.turret0;
} else {
_root.iF.trgt = _root.player;
}
}
if (this.targetTimer == 101) {
this.comp = true;
}
}
Symbol 1793 MovieClip Frame 12
function loadStageScreen(stageNumber) {
stageScreen = attachMovie("mc.stageScreen", "stageScreen", 600000);
stageScreen._alpha = 0;
stageScreen._x = _root.iF._x;
stageScreen._y = _root.iF._y - 100;
stageScreen.timer = 60;
stageScreen.number = stageNumber;
stageScreen.onEnterFrame = function () {
if (_root.paused != true) {
textStuff = new String();
textStuff = stageNumber;
this.text = textStuff;
this.timer--;
if (this.timer <= 10) {
this._alpha = this.timer * 5;
if (this._alpha <= 0) {
_root.quit();
}
} else if (this._alpha < 100) {
this._alpha = this._alpha + 10;
}
}
};
}
ld = false;
pfs = 0;
while (pfs < 1) {
_root.makeZombie(pfs, 150, 728, 30, 60, 250);
pfs++;
}
this.onEnterFrame = function () {
if ((_root.nZ == -1) && (!ld)) {
ld = true;
clearInterval(asdfpoop);
loadStageScreen("YOU WIN!!!");
}
};
working = function () {
if (_root.KILLS < 1) {
loadStageScreen("YOU LOSE!!!");
}
clearInterval(asdfpoop);
};
asdfpoop = setInterval(working, 7000);
Instance of Symbol 1704 MovieClip in Symbol 1793 MovieClip Frame 12
onClipEvent (load) {
this._visible = false;
_root.generate128x16Object(this._x, this._y, 5);
}
Instance of Symbol 1704 MovieClip in Symbol 1793 MovieClip Frame 12
onClipEvent (load) {
this._visible = false;
_root.generate128x16Object(this._x, this._y, 5);
}
Symbol 1793 MovieClip Frame 13
_root.loadRocketBoss(50, 1250);
Symbol 1793 MovieClip Frame 14
function loadStageScreen(stageNumber) {
stageScreen = attachMovie("mc.stageScreen", "stageScreen", 600000);
stageScreen._alpha = 0;
stageScreen._x = _root.iF._x;
stageScreen._y = _root.iF._y - 100;
stageScreen.timer = 60;
stageScreen.number = stageNumber;
this.we = 0;
while (this.we < this.weapons.length) {
_root["AMMO_" + this.weapons[this.we]] = 0;
this.we++;
}
stageScreen.onEnterFrame = function () {
if (_root.paused != true) {
textStuff = new String();
textStuff = "STAGE " + stageNumber;
this.text = textStuff;
this.timer--;
if (this.timer <= 10) {
this._alpha = this.timer * 5;
if (this._alpha <= 0) {
removeMovieClip(this);
}
} else if (this._alpha < 100) {
this._alpha = this._alpha + 10;
}
}
};
}
stop();
this.powerups = ["health", "berserk", "shield"];
this.weapon = false;
this.cr_weapon = false;
this.powerup = false;
this.cr_powerup = false;
this.numWeapons = 0;
this.numPowerups = 0;
this.stage = 1;
this.stageTimer = 25;
this.nFG = 0;
this.nZM = 0;
this.nGR = 0;
this.nKN = 0;
this.throughAllWeapons = 0;
this.onEnterFrame = function () {
if (_root.paused != true) {
if (this.stageTimer == 0) {
loadStageScreen(this.stage);
_root.makeGrunt(_root.nG, 160 + random(1350), 569, 100, 150, 1500);
this.stage++;
this.stageTimer = 150;
} else {
this.stageTimer--;
}
}
};
Symbol 1793 MovieClip Frame 15
stop();
_root.makeZombie(0, 500, 570, 100, 100, 1530);
_root.makeZombie(1, 700, 570, 100, 100, 1530);
_root.makeZombie(2, 900, 570, 100, 100, 1530);
_root.makeZombie(3, 1100, 570, 100, 100, 1530);
_root.makeZombie(4, 1300, 570, 100, 100, 1530);
Instance of Symbol 1704 MovieClip in Symbol 1793 MovieClip Frame 15
onClipEvent (load) {
this._visible = false;
_root.generate128x16Object(this._x, this._y, 5);
}
Instance of Symbol 1704 MovieClip in Symbol 1793 MovieClip Frame 15
onClipEvent (load) {
this._visible = false;
_root.generate128x16Object(this._x, this._y, 5);
}
Instance of Symbol 1773 MovieClip in Symbol 1793 MovieClip Frame 15
onClipEvent (load) {
this._alpha = 0;
}
onClipEvent (enterFrame) {
if (this.hitTest(_root.iF)) {
this._visible = true;
if (_root.KILLS >= 5) {
if (this._alpha < 100) {
this._alpha = this._alpha + 10;
}
}
} else {
this._visible = false;
}
}
Instance of Symbol 1704 MovieClip in Symbol 1793 MovieClip Frame 15
onClipEvent (load) {
this._visible = false;
_root.generate128x16Object(this._x, this._y, 5);
}
Instance of Symbol 1704 MovieClip in Symbol 1793 MovieClip Frame 15
onClipEvent (load) {
this._visible = false;
_root.generate128x16Object(this._x, this._y, 5);
}
Instance of Symbol 1773 MovieClip in Symbol 1793 MovieClip Frame 15
onClipEvent (load) {
this._alpha = 0;
this.create = false;
}
onClipEvent (enterFrame) {
if (this.hitTest(_root.iF)) {
this._visible = true;
if (_root.KILLS >= 5) {
if (this._alpha < 100) {
this._alpha = this._alpha + 10;
}
if (this.create == false) {
this.create = true;
_root.makeFrog(0, 350, 880, 100, -50, 1380);
_root.makeFrog(1, 550, 880, 100, -50, 1380);
_root.makeFrog(2, 750, 880, 100, -50, 1380);
_root.makeFrog(3, 950, 880, 100, -50, 1380);
_root.makeFrog(4, 1150, 880, 100, -50, 1380);
}
}
} else {
this._visible = false;
}
}
Instance of Symbol 1704 MovieClip in Symbol 1793 MovieClip Frame 15
onClipEvent (load) {
this._visible = false;
_root.generate128x16Object(this._x, this._y, 5);
}
Instance of Symbol 1704 MovieClip in Symbol 1793 MovieClip Frame 15
onClipEvent (load) {
this._visible = false;
_root.generate128x16Object(this._x, this._y, 5);
}
Instance of Symbol 1773 MovieClip in Symbol 1793 MovieClip Frame 15
onClipEvent (load) {
this._alpha = 0;
}
onClipEvent (enterFrame) {
if (this.hitTest(_root.iF)) {
this._visible = true;
if (_root.KILLS >= 5) {
if (this._alpha < 100) {
this._alpha = this._alpha + 10;
}
}
} else {
this._visible = false;
}
}
Symbol 1793 MovieClip Frame 16
stop();
_root.makeKnight(0, 725, 170, 100, 650, 2900);
_root.makeWeapon(0, 900, 160, "shotGun");
_root.makeKnight(1, 1500, 170, 100, 650, 2900);
_root.makeKnight(2, 1600, 170, 100, 650, 2900);
_root.makeKnight(3, 2000, 170, 100, 650, 2900);
_root.makeKnight(4, 2100, 170, 100, 650, 2900);
_root.makeFrog(0, 2400, 190, 100, 650, 2900);
_root.makeKnight(5, 2450, 170, 100, 650, 2900);
_root.makeFrog(1, 2500, 190, 100, 650, 2900);
_root.makeWeapon(2, 2700, 160, "mp5");
_root.makeWeapon(1, 2800, 160, "nade");
_root.makeWeapon(8, 150, 514, "stinger");
this.onEnterFrame = function () {
if (_root.player._y > 600) {
_root.iF.trgt = undefined;
if (_root.player._y > 1000) {
_root.paused = true;
_root.iF.fadeScreen.fade = "in";
if (_root.iF.fadeScreen._alpha >= 100) {
_root.MAPNUMBER = 5;
_root.reset();
}
}
}
};
Instance of Symbol 517 MovieClip in Symbol 1793 MovieClip Frame 16
onClipEvent (load) {
anus = false;
}
onClipEvent (enterFrame) {
if (((_root.player._x < this._x) && (_root.player._y > 300)) && (anus == false)) {
anus = true;
_root.makeWeapon(3, 1400, 514, "flakCannon");
_root.makeWeapon(4, 1500, 514, "machineGun");
_root.makeWeapon(5, 1600, 514, "m4");
}
}
Instance of Symbol 346 MovieClip in Symbol 1793 MovieClip Frame 16
onClipEvent (load) {
anus = false;
}
onClipEvent (enterFrame) {
if ((_root.player._x > this._x) && (anus == false)) {
anus = true;
_root.makeKnight(_root.nK, 2950, 525, 150, 650, 3000);
_root.makeGrunt(_root.nG, 1900, 525, 100, 650, 3000);
_root.makeGrunt(_root.nG, 1900, 525, 100, 650, 3000);
}
}
Symbol 1794 MovieClip Frame 1
this._visible = false;
if ((_root.FPSStability == false) || (_root.paused == true)) {
stop();
}
Symbol 1794 MovieClip Frame 40
gotoAndPlay (2);
Symbol 1798 Button
on (press) {
_root.quit();
}