Frame 1
NewgroundsAPI.connectMovie(5506);
_global.unlocked = true;
myMenu = new ContextMenu();
myMenu.hideBuiltInItems();
menu = myMenu;
TextField.prototype.sTF = function (TFParameters, msg) {
var _local3 = new TextFormat();
for (paras in TFParameters) {
_local3[paras] = TFParameters[paras];
if (msg) {
trace((((((("from:" + paras) + ":") + TFParameters[paras]) + ", to:") + paras) + ":") + _local3[paras]);
}
}
this.setTextFormat(_local3);
};
stop();
(Stage.align = "C");
(Stage.scaleMode = "noScale");
Frame 2
if (unlocked) {
stop();
clear();
for (all in this) {
this[all].removeMovieClip();
delete this[all];
}
if (!weps) {
_global.weps = {laser:false, flame:false, spread:false};
}
if (!god) {
_global.god = false;
}
if (!grnLnd) {
_global.grnLnd = false;
}
var so = SharedObject.getLocal("so");
if (!isNaN(so.data.masterV)) {
_global.masterV = so.data.masterV;
} else {
_global.masterV = 0.5;
}
if (!isNaN(so.data.musicV)) {
_global.musicV = so.data.musicV;
} else {
_global.musicV = 0.5;
}
if (so.data._quality) {
_quality = so.data._quality;
} else {
_quality = "high";
}
if (so.data.bgOn) {
bgOn = so.data.bgOn;
} else {
bgOn = "ON";
}
if (!so.data.cheats) {
so.data.cheats = [];
}
cheats = ["[greenland - More trees in the background]", "\n[mr shotgun - Special ammo is always shotgun]", "\n[burningman - Special ammo is always fuel]", "\n[shoopdawhoop - Special ammo is always laser]", "\n[almighty - Invulnerability, flying ability,\nability to spawn corpses on mouse click]"];
bg_trees = 5;
} else {
gotoAndStop (1);
}
myMenu = new ContextMenu();
myMenu.hideBuiltInItems();
menu = myMenu;
createEmptyMovieClip("vBar", 0);
(vBar.hit = 100);
(vBar.w = 20);
(vBar.h = 10);
(vBar.y = ((-masterV) + 1) * vBar.hit);
(vBar._x = 712);
(vBar._y = 200);
(vBar.snd = new Sound(vBar));
vBar.snd.attachSound("volTest");
vBar.createTextField("txt", 0, 0, 100, 0, 20);
(vBar.txt.selectable = false);
vBar.onEnterFrame = function () {
if (!console._visible) {
if (Key.isDown(77)) {
if (!mPress) {
if (tmpV) {
(_global.masterV = tmpV);
delete tmpV;
} else {
(tmpV = masterV);
(_global.masterV = 0);
}
this.y = ((-masterV) + 1) * this.hit;
}
mPress = true;
} else {
delete mPress;
}
if (Key.isDown(81)) {
if (!qPress) {
switch (_quality.toLowerCase()) {
case "low" :
_quality = ((aa.q.text = "MEDIUM"));
so.data._quality = (aa.q.text = "MEDIUM");
break;
case "medium" :
_quality = ((aa.q.text = "HIGH"));
so.data._quality = (aa.q.text = "HIGH");
break;
case "high" :
_quality = ((aa.q.text = "LOW"));
so.data._quality = (aa.q.text = "LOW");
}
aa.q.sTF({bold:true, align:"center", font:"courier new", size:18});
}
qPress = true;
} else {
delete qPress;
}
}
if (gover) {
this._visible = false;
} else {
this._visible = true;
}
if (((this._xmouse > (-this.w)) && (this._xmouse < this.w)) && ((this._ymouse > (this.y - this.w)) && (this._ymouse < (this.y + this.w)))) {
this.clr = 13421772 /* 0xCCCCCC */;
} else if (!this.dy) {
this.clr = 5592405 /* 0x555555 */;
}
if (this.dy) {
this.y = this.y + ((this._ymouse + this.dy) - this.y);
}
if (this.y < 0) {
this.y = 0;
}
if (this.y > this.hit) {
this.y = this.hit;
}
_global.masterV = ((-this.y) + 100) / this.hit;
this.clear();
this.lineStyle(1, 0);
this.moveTo(0, 0);
this.lineTo(0, this.hit);
this.moveTo(-this.w, this.y - this.h);
this.beginFill(this.clr);
this.lineTo(-this.w, this.y + this.h);
this.lineTo(this.w, this.y - this.h);
this.lineTo(this.w, this.y + this.h);
this.endFill();
this.txt.text = ("Master Volume: " + (masterV * 100)) + "%";
this.txt.sTF({font:"courier new"});
(this.txt._width = this.txt.textWidth + 4);
(this.txt._x = (-this.txt._width) * 0.5);
this.snd.setVolume(masterV * 100);
};
vBar.onMouseDown = function () {
if (((this._xmouse > (-this.w)) && (this._xmouse < this.w)) && ((this._ymouse > (this.y - this.w)) && (this._ymouse < (this.y + this.w)))) {
this.snd.start(0, 99);
this.dy = this.y - this._ymouse;
}
};
vBar.onMouseUp = function () {
this.snd.stop();
so.data.masterV = masterV;
delete this.dy;
};
createEmptyMovieClip("mBar", 1);
(mBar.hit = 100);
(mBar.w = 20);
(mBar.h = 10);
(mBar.y = ((-musicV) + 1) * mBar.hit);
(mBar._x = 88);
(mBar._y = 200);
(mBar.snd = new Sound(mBar));
mBar.snd.attachSound("volTest");
mBar.createTextField("txt", 0, 0, 100, 0, 20);
(mBar.txt.selectable = false);
mBar.onEnterFrame = function () {
if (gover) {
this._visible = false;
} else {
this._visible = true;
}
if (((this._xmouse > (-this.w)) && (this._xmouse < this.w)) && ((this._ymouse > (this.y - this.w)) && (this._ymouse < (this.y + this.w)))) {
this.clr = 13421772 /* 0xCCCCCC */;
} else if (!this.dy) {
this.clr = 5592405 /* 0x555555 */;
}
if (this.dy) {
this.y = this.y + ((this._ymouse + this.dy) - this.y);
}
if (this.y < 0) {
this.y = 0;
}
if (this.y > this.hit) {
this.y = this.hit;
}
_global.musicV = ((-this.y) + 100) / this.hit;
this.clear();
this.lineStyle(1, 0);
this.moveTo(0, 0);
this.lineTo(0, this.hit);
this.moveTo(-this.w, this.y - this.h);
this.beginFill(this.clr);
this.lineTo(-this.w, this.y + this.h);
this.lineTo(this.w, this.y - this.h);
this.lineTo(this.w, this.y + this.h);
this.endFill();
this.txt.text = ("Music Volume: " + (musicV * 100)) + "%";
this.txt.sTF({font:"courier new"});
(this.txt._width = this.txt.textWidth + 4);
(this.txt._x = (-this.txt._width) * 0.5);
this.snd.setVolume((musicV * masterV) * 100);
};
mBar.onMouseDown = function () {
if (((this._xmouse > (-this.w)) && (this._xmouse < this.w)) && ((this._ymouse > (this.y - this.w)) && (this._ymouse < (this.y + this.w)))) {
this.snd.start(0, 99);
this.dy = this.y - this._ymouse;
}
};
mBar.onMouseUp = function () {
this.snd.stop();
so.data.musicV = musicV;
delete this.dy;
};
createEmptyMovieClip("aa", 2);
(aa._x = 640);
(aa._y = 120);
aa.createTextField("ttl", 0, 0, 0, 0, 0);
(aa.ttl.selectable = false);
(aa.ttl.text = "Anti-Aliasing");
(aa.ttl.border = true);
aa.ttl.sTF({align:"center", font:"courier new", size:18});
(aa.ttl._width = aa.ttl.textWidth + 4);
(aa.ttl._height = aa.ttl.textHeight + 4);
aa.createTextField("q", 1, 0, aa.ttl._height, aa.ttl._width, 20);
(aa.q.selectable = false);
(aa.q.text = _quality.toUpperCase());
aa.q.sTF({align:"center", font:"courier new", size:18});
aa.onEnterFrame = function () {
if (gover) {
this._visible = false;
} else {
this._visible = true;
}
if (this.hitTest(_root._xmouse, _root._ymouse)) {
aa.ttl.sTF({bold:true, align:"center", font:"courier new", size:18});
aa.q.sTF({bold:true, align:"center", font:"courier new", size:18});
} else {
aa.ttl.sTF({bold:false, align:"center", font:"courier new", size:18});
aa.q.sTF({bold:false, align:"center", font:"courier new", size:18});
}
};
aa.onMouseDown = function () {
if (this.hitTest(_root._xmouse, _root._ymouse)) {
switch (_quality.toLowerCase()) {
case "low" :
_quality = ((aa.q.text = "MEDIUM"));
so.data._quality = (aa.q.text = "MEDIUM");
break;
case "medium" :
_quality = ((aa.q.text = "HIGH"));
so.data._quality = (aa.q.text = "HIGH");
break;
case "high" :
_quality = ((aa.q.text = "LOW"));
so.data._quality = (aa.q.text = "LOW");
}
aa.q.sTF({bold:true, align:"center", font:"courier new", size:18});
}
};
createEmptyMovieClip("bs", 3);
(bs._x = 656);
(bs._y = 60);
bs.createTextField("ttl", 0, 0, 0, 0, 0);
(bs.ttl.selectable = false);
(bs.ttl.text = "Background");
(bs.ttl.border = true);
bs.ttl.sTF({align:"center", font:"courier new", size:18});
(bs.ttl._width = bs.ttl.textWidth + 4);
(bs.ttl._height = bs.ttl.textHeight + 4);
bs.createTextField("q", 1, 0, bs.ttl._height, bs.ttl._width, 20);
(bs.q.selectable = false);
(bs.q.text = bgOn);
bs.q.sTF({align:"center", font:"courier new", size:18});
bs.onEnterFrame = function () {
if (gover) {
this._visible = false;
} else {
this._visible = true;
}
if (this.hitTest(_root._xmouse, _root._ymouse)) {
bs.ttl.sTF({bold:true, align:"center", font:"courier new", size:18});
bs.q.sTF({bold:true, align:"center", font:"courier new", size:18});
} else {
bs.ttl.sTF({bold:false, align:"center", font:"courier new", size:18});
bs.q.sTF({bold:false, align:"center", font:"courier new", size:18});
}
};
bs.onMouseDown = function () {
if (this.hitTest(_root._xmouse, _root._ymouse)) {
switch (bgOn) {
case "OFF" :
so.data.bgOn = (bgOn = (bs.q.text = "ON"));
break;
case "ON" :
so.data.bgOn = (bgOn = (bs.q.text = "OFF"));
}
bs.q.sTF({bold:true, align:"center", font:"courier new", size:18});
}
};
createEmptyMovieClip("hs_btn", 4);
hs_btn.createTextField("ttl", 0, 0, 0, 0, 0);
(hs_btn.ttl.selectable = false);
(hs_btn.ttl.text = "Highscores");
(hs_btn.ttl.border = true);
hs_btn.ttl.sTF({align:"center", font:"courier new", size:18});
(hs_btn.ttl._width = hs_btn.ttl.textWidth + 4);
(hs_btn.ttl._height = hs_btn.ttl.textHeight + 4);
(hs_btn._x = 36);
(hs_btn._y = 60);
hs_btn.onEnterFrame = function () {
if (Key.isDown(27)) {
gover.removeMovieClip();
}
if (gover) {
this._visible = false;
} else {
this._visible = true;
}
if (this.hitTest(_root._xmouse, _root._ymouse)) {
hs_btn.ttl.sTF({bold:true, align:"center", font:"courier new", size:18});
} else {
hs_btn.ttl.sTF({bold:false, align:"center", font:"courier new", size:18});
}
};
hs_btn.onMouseDown = function () {
if (this.hitTest(_root._xmouse, _root._ymouse)) {
attachMovie("gameOver", "gover", 123, {_x:400, _y:300, highscore:true});
}
};
createEmptyMovieClip("cl", 5);
cl.createTextField("ttl", 0, 0, 0, 0, 0);
(cl.ttl.selectable = false);
(cl.ttl.text = "Cheats");
(cl.ttl.border = true);
cl.ttl.sTF({align:"center", font:"courier new", size:18});
(cl.ttl._width = cl.ttl.textWidth + 4);
(cl.ttl._height = cl.ttl.textHeight + 4);
(cl._x = 56);
(cl._y = 100);
cl.onEnterFrame = function () {
if (gover) {
this._visible = false;
} else {
this._visible = true;
}
if (Key.isDown(27)) {
this.list.removeMovieClip();
}
if (this.hitTest(_root._xmouse, _root._ymouse)) {
cl.ttl.sTF({bold:true, align:"center", font:"courier new", size:18});
} else {
cl.ttl.sTF({bold:false, align:"center", font:"courier new", size:18});
}
};
cl.onMouseDown = function () {
if (!console._visible) {
if (this.list) {
this.list.removeMovieClip();
} else if (this.hitTest(_root._xmouse, _root._ymouse)) {
cl.cheats = so.data.cheats;
if (!cl.cheats.length) {
cl.cheats = "Make a deadpile high enough to achieve cheats.";
}
this.createEmptyMovieClip("list", 1);
this.list.createTextField("txt", 0, cl._width + 5, 0, 0, 0);
(cl.list.txt.selectable = galse);
(cl.list.txt.background = (cl.list.txt.border = (cl.list.txt.multiline = true)));
cl.list.txt.text = cl.cheats + "\nIn the main menu, press ~ for the console.";
cl.list.txt.sTF({font:"courier new", size:18});
(cl.list.txt._width = cl.list.txt.textWidth + 4);
(cl.list.txt._height = cl.list.txt.textHeight + 4);
}
}
};
createEmptyMovieClip("console", 10);
(console._x = 300);
(console._y = 300);
(console._visible = false);
console.createTextField("ttl", 0, 0, 0, 200, 20);
(console.ttl.selectable = false);
(console.ttl.background = (console.ttl.border = true));
(console.ttl.text = "COMMAND CONSOL");
console.ttl.sTF({align:"center", size:16, font:"courier new"});
console.createTextField("cmd", 1, 0, 20, 200, 20);
(console.cmd.type = "input");
(console.cmd.background = (console.cmd.border = true));
console.cmd.sTF({align:"center", bold:true, font:"courier new", color:10066329});
console.cmd.selectable = false;
console.onEnterFrame = function () {
if (this._visible) {
if (Selection.getFocus() != "_level0.console.cmd") {
Selection.setFocus(this.cmd);
}
console.cmd.sTF({align:"center", bold:true, font:"courier new", color:0});
}
};
console.onKeyDown = function () {
if (Key.getCode() == 192) {
if (!this._visible) {
this._visible = true;
cl.list.removeMovieClip();
return(undefined);
}
if (this._visible) {
this._visible = false;
return(undefined);
}
}
if (Key.getCode() == 13) {
if (this.cmd.text.toLowerCase() == "almighty") {
if (god) {
_global.god = false;
this.cmd.text = "Cheat Deactivated: god";
} else {
_global.god = true;
this.cmd.text = "Cheat Activated: god";
}
Selection.setFocus(this.cmd);
return(undefined);
}
if (this.cmd.text.toLowerCase() == "shoopdawhoop") {
if (weps.laser) {
weps.laser = false;
this.cmd.text = "Cheat Deactivated: laser";
} else {
weps.flame = (weps.spread = false);
weps.laser = true;
this.cmd.text = "Cheat Activated: laser";
}
Selection.setFocus(this.cmd);
return(undefined);
}
if (this.cmd.text.toLowerCase() == "mr shotgun") {
if (weps.spread) {
weps.spread = false;
this.cmd.text = "Cheat Deactivated: spread";
} else {
weps.flame = (weps.laser = false);
weps.spread = true;
this.cmd.text = "Cheat Activated: spread";
}
Selection.setFocus(this.cmd);
return(undefined);
}
if (this.cmd.text.toLowerCase() == "burningman") {
if (weps.flame) {
weps.flame = false;
this.cmd.text = "Cheat Deactivated: flame";
} else {
weps.laser = (weps.spread = false);
weps.flame = true;
this.cmd.text = "Cheat Activated: flame";
}
Selection.setFocus(this.cmd);
return(undefined);
}
if (this.cmd.text.toLowerCase() == "greenland") {
if (grnLnd) {
_global.grnLnd = false;
this.cmd.text = "Cheat Deactivated: greenland";
} else {
_global.grnLnd = true;
so.data.bgOn = (bs.q.text = (bgOn = "ON"));
this.cmd.text = "Cheat Activated: greenland";
}
Selection.setFocus(this.cmd);
return(undefined);
}
if (this.cmd.text.toLowerCase() == "clear all data") {
so.clear();
this.cmd.text = "Cleared.";
Selection.setFocus(this.cmd);
return(undefined);
}
(this.cmd.text = "No such command.");
Selection.setFocus(this.cmd);
}
};
Key.addListener(console);
enterPress = true;
Instance of Symbol 282 MovieClip "start_btn" in Frame 2
onClipEvent (load) {
ss = 10;
(ns = 100);
(os = 170);
(ps = 60);
cs = ns;
}
onClipEvent (enterFrame) {
if (_visible) {
if (_root.gover) {
this.gotoAndStop(2);
_width = 800;
_height = 600;
} else {
this.gotoAndStop(1);
if (!Key.isDown(13)) {
delete _root.enterPress;
}
if ((hitTest(_root._xmouse, _root._ymouse) && (!_root.howtoscore.hitTest(_root._xmouse, _root._ymouse))) && (!_root.console._visible)) {
cs = os;
} else {
cs = ns;
}
_yscale = (_yscale + ss);
_yscale + ss;
_xscale = _yscale;
_yscale;
ss = ss + ((cs - _yscale) * 0.1);
ss = ss * 0.85;
if ((mD || (Key.isDown(13) && (!_root.enterPress))) && (!_root.console._visible)) {
_root.vBar.removeMovieClip();
(_root.console._visible = true);
_root.console.removeMovieClip();
_root.aa.removeMovieClip();
_root.bs.removeMovieClip();
_root.hs_btn.removeMovieClip();
_root.cl.removeMovieClip();
_root.play();
}
}
}
}
onClipEvent (mouseDown) {
if ((hitTest(_root._xmouse, _root._ymouse) && (!_root.howtoscore.hitTest(_root._xmouse, _root._ymouse))) && (_currentframe == 1)) {
mD = true;
}
}
Frame 3
if (unlocked) {
_global.Vect = new Object();
Vect.getD = function (getD_x, getD_y) {
return(Math.sqrt((getD_x * getD_x) + (getD_y * getD_y)));
};
Vect.dtv = function (dtv_deg, dtv_len) {
if (isNaN(dtv_deg)) {
return(("Error: Given degree: " + dtv_deg) + ".");
}
var _local4 = Math.cos((dtv_deg * Math.PI) / 180);
var _local3 = Math.sin((dtv_deg * Math.PI) / 180);
if (dtv_len) {
return({x:_local4 * dtv_len, y:_local3 * dtv_len});
}
return({x:_local4, y:_local3});
};
Vect.vtd = function (vtd_vec) {
if (isNaN(vtd_vec.x) || (isNaN(vtd_vec.y))) {
return(((("Error: Given x: " + vtd_vec.x) + ". Given y: ") + vtd_vec.y) + ".");
}
return((Math.atan2(vtd_vec.y, vtd_vec.x) * 180) / Math.PI);
};
Vect.rv = function (rv_vec, rv_deg) {
var err = "rv:";
if (isNaN(rv_vec.x) || (isNaN(rv_vec.y))) {
err = err + (((("\nError: Given x: " + rv_vec.x) + ". Given y: ") + rv_vec.y) + ".");
}
if (isNaN(rv_deg)) {
err = err + (("\nError: Given degree: " + rv_deg) + ".");
}
if (err != "rv:") {
return(err);
}
with (Vect) {
var rvD = getD(rv_vec.x, rv_vec.y);
var rvDeg = vtd(rv_vec);
var retVec = dtv(rvDeg + rv_deg, rvD);
return(retVec);
}
};
_global.abs1 = function (abs1Val) {
if (!isNaN(Number(abs1Val))) {
return(abs1Val / Math.abs(abs1Val));
}
trace(("abs1 Error: Given value (" + abs1Val) + ") is NaN.");
return(0);
};
_global.splitColor = function (sC) {
if (sC.toString(16).length > 6) {
_32 = true;
}
if (_32) {
var _local3 = (sC & 4278190080) >> 24;
var _local4 = (sC & 16711680) >> 16;
var _local5 = (sC & 65280) >> 8;
var _local2 = sC & 255;
return({a:_local3, r:_local4, g:_local5, b:_local2});
}
var _local4 = (sC & 16711680) >> 16;
var _local5 = (sC & 65280) >> 8;
var _local2 = sC & 255;
return({r:_local4, g:_local5, b:_local2});
};
_global.timerFromSeconds = function (sec) {
var _local2 = 0;
var _local1 = 0;
secNum = 0;
while (secNum <= sec) {
_local1++;
if (_local1 == 60) {
_local2++;
_local1 = 0;
}
secNum++;
}
if (_local1.toString().length == 1) {
_local1 = "0" + _local1;
}
return((_local2 + ":") + _local1);
};
} else {
gotoAndStop (1);
}
_global.gravity = 0.5;
_global.ground = 580;
clear();
if (bgOn == "OFF") {
lineStyle(2, 0);
moveTo(-10, ground);
beginFill(10066329);
lineTo(810, ground);
lineTo(810, 610);
lineTo(-10, 610);
endFill();
}
MovieClip.prototype.loadPlayer = function (plr) {
this.xx = (this.yy = (this.rr = 0));
this.maxXS = 5;
if (plr) {
return(undefined);
}
this.maxXS = 3;
this.jumpTimer = 50 + random(120);
this._y = ground;
if (random(2)) {
(this._x = -10);
(this._y = heightmeter.left);
} else {
(this._x = 810);
(this._y = heightmeter.right);
}
};
MovieClip.prototype.uncontrollable = function () {
this.hit.setVolume(50 * masterV);
this.snd.setVolume(50 * masterV);
this.yy = this.yy + gravity;
(this._x = this._x + this.xx);
(this._y = this._y + this.yy);
(this._rotation = this._rotation + this.rr);
this.rr = this.rr * 0.9;
if ((this._y + this.addH) >= ground) {
(this._y = ground - this.addH);
(this.yy = 0);
this.f = true;
} else {
delete this.f;
}
if ((this._name != "player") || (!Key.isDown(40))) {
if ((this.health > 0) || (Math.round(frmCnt / 4) != (frmCnt / 4))) {
var _local2 = bgBMD.getPixel32(this._x, this._y + this.addH);
if (_local2 != 0) {
this.g = true;
} else {
delete this.g;
}
} else {
delete this.g;
}
} else {
delete this.g;
}
if (this.g) {
if (this._name == "player") {
(this._y = this._y - this.yy);
(this.yy = 0);
}
}
if (this.health < 0) {
this.health = 0;
}
if (this.health > 0) {
if (((!this.goLeft) && (!this.goRight)) && (this.f || (this.g))) {
this.xx = this.xx * 0.7;
}
if (this.g || (this.f)) {
this.rr = this.rr - (this._rotation * 0.05);
this._rotation = this._rotation - (this._rotation * 0.1);
}
} else {
delete this.goRight;
delete this.goLeft;
if (this._currentframe == 1) {
this.gotoAndStop("dead");
}
if (this.f || (this.g)) {
this.rr = this.rr + this.xx;
this.xx = this.xx * 0.9;
if (this._rotation == 0) {
this._rotation = -abs1(this._xscale);
}
if ((Math.abs(this._rotation) < 90) || ((!this.f) && (!this.g))) {
this.rr = this.rr + this._rotation;
} else {
this.rr = 0;
this._rotation = 90 * abs1(this._rotation);
}
this.addH = 5;
}
}
if (((!this.goRight) && (this.goLeft)) && (this.xx > (-this.maxXS))) {
this._xscale = -100;
this.xx = this.xx - 1;
}
if (((!this.goLeft) && (this.goRight)) && (this.xx < this.maxXS)) {
this._xscale = 100;
this.xx = this.xx + 1;
}
};
ctrls = {jump:68, jump2:32, jump3:38, shoot:83, shoot2:17, spec:65, spec2:16, spec3:9};
MovieClip.prototype.controllable = function () {
if (this.g || (god)) {
if ((Key.isDown(ctrls.jump) || (Key.isDown(ctrls.jump2))) || (Key.isDown(ctrls.jump3))) {
if (god) {
this.yy = -10;
}
this._y = this._y - 8;
}
}
if (((Key.isDown(ctrls.jump) || (Key.isDown(ctrls.jump2))) || (Key.isDown(ctrls.jump3))) && (this.f || (this.g))) {
this.yy = this.yy - 10;
}
if (Key.isDown(37) && (!this.gun.onEnterFrame)) {
this.goLeft = true;
} else {
delete this.goLeft;
}
if (Key.isDown(39) && (!this.gun.onEnterFrame)) {
this.goRight = true;
} else {
delete this.goRight;
}
if (this._x < -10) {
delete this.goLeft;
this.goRight = true;
}
if (this._x > 810) {
delete this.goRight;
this.goLeft = true;
}
if (Key.isDown(ctrls.shoot) || (Key.isDown(ctrls.shoot2))) {
if (!sPress) {
if (HUD.sAmmo <= 0) {
delete shootS;
} else if (HUD.ammo <= 0) {
shootS = true;
}
}
if (shootS) {
shootSpecial(HUD.sType);
} else if ((HUD.ammo > 0) && (this.gun._currentframe == 1)) {
shoot();
}
sPress = true;
} else {
delete sPress;
}
if ((Key.isDown(ctrls.spec) || (Key.isDown(ctrls.spec2))) || (Key.isDown(ctrls.spec3))) {
if (!switchDown) {
switchDown = true;
switch (shootS) {
case undefined :
shootS = true;
break;
case true :
delete shootS;
}
}
} else {
delete switchDown;
}
};
MovieClip.prototype.AI = function () {
if (this.health > 0) {
if (this._x < 10) {
if (this._y > heightmeter.left) {
(this._y = heightmeter.left);
(this.yy = 0);
}
}
if (this._x > 790) {
if (this._y > heightmeter.right) {
(this._y = heightmeter.right);
(this.yy = 0);
}
}
if (this.g || (this.f)) {
if (((player._y < (this._y + 20)) || (player.health <= 0)) || (this.lit)) {
this.yy = 0;
}
if (((player._y < this._y) || (player.health <= 0)) || (this.lit)) {
this._y--;
}
}
if ((player.health > 0) || ((!this.goRight) && (!this.goLeft))) {
if (this.lit) {
if (this._x < 10) {
delete this.goLeft;
this.goRight = true;
}
if (this._x > 790) {
delete this.goRight;
this.goLeft = true;
}
if (!this.turnCnt) {
this.turnCnt = 20 + random(20);
if (random(2) && (this.g || (this.f))) {
this.yy = this.yy - 7;
delete this.g;
delete this.f;
} else if (this.goLeft) {
this.goRight = true;
delete this.goLeft;
} else if (this.goRight) {
this.goLeft = true;
delete this.goRight;
}
}
this.turnCnt--;
this.health = this.health - 0.05;
nmN = 0;
while (nmN <= 20) {
var _local3 = _root["nme" + nmN];
if (this.hitTest(_local3)) {
_local3.lit = true;
}
nmN++;
}
} else {
if ((this._x > (player._x + 100)) || ((this._x > player._x) && (this.airAhead))) {
this.goLeft = true;
delete this.goRight;
}
if ((this._x < (player._x - 100)) || ((this._x < player._x) && (this.airAhead))) {
this.goRight = true;
delete this.goLeft;
}
if (((player._y < this._y) && (this.health > 0)) && (Math.round(frmCnt / 4) != (frmCnt / 4))) {
var _local4 = bgBMD.getPixel32(this._x + (abs1(this._xscale) * 20), this._y + this.addH);
if (_local4 == 0) {
this.airAhead = true;
} else {
delete this.airAhead;
}
} else {
delete this.airAhead;
}
if ((!this.goRight) && (!this.goLeft)) {
if (random(2)) {
this.goLeft = true;
delete this.goRight;
} else {
this.goRight = true;
delete this.goLeft;
}
}
}
}
if ((this._x < -30) || ((this._x > 830) && (player.health <= 0))) {
this.removeMovieClip();
}
if ((this.jumpTimer <= 0) && (this.f || (this.g))) {
this.yy = this.yy - 7;
this.jumpTimer = 50 + random(120);
}
this.jumpTimer--;
if ((((player.health > 0) && (Math.abs(player._x - this._x) < 10)) && (Math.abs(player._y - this._y) < 10)) && (Math.abs(this._rotation) < 20)) {
player.health = player.health - 2;
if (!player.hitTmr) {
player.hit.start(0, 1);
player.hit.attachSound(player.hitSnd[random(player.hitSnd.length)]);
}
player.hitTmr = 10;
}
} else {
if (this.g) {
if (this.yy > 0) {
this.yy = 0;
}
this._y--;
}
delete this.jumpTimer;
delete this.goLeft;
delete this.goRight;
if (this.g) {
this._y = this._y + 0.2;
}
if (((((this.g || (this.f)) && (Math.abs(this.xx) < 0.1)) && (Math.abs(this.yy) < 0.1)) && (Math.abs(this._rotation) < 110)) && (Math.abs(this._rotation) > 70)) {
if (this.snd.position == this.snd.duration) {
for (all in _root) {
if (_root[all] != this) {
_root[all]._visible = false;
}
}
this.fire._visible = false;
kills++;
if ((this._y - 6) < heightmeter.top) {
heightmeter.top = this._y - 6;
}
if ((this._x < 20) && (this._y < heightmeter.left)) {
heightmeter.left = this._y;
}
if ((this._x > 780) && (this._y < heightmeter.right)) {
heightmeter.right = this._y;
}
bgBMD.draw(_root);
this.removeMovieClip();
for (all in _root) {
if ((bgOn == "ON") || (all != "backG")) {
_root[all]._visible = true;
}
}
}
}
}
};
addEnemy = function (mp) {
nmeCnt++;
var _local4 = attachMovie("nme", "nme" + nmeCnt, nmeCnt);
_local4.loadPlayer();
_local4.health = 10;
_local4.createEmptyMovieClip("h", 0);
(_local4.h._y = -35);
_local4.h.onEnterFrame = function () {
if (!gamePause) {
sN = 0;
while (sN <= 199) {
var _local3 = _root["sht" + sN];
if (this._parent.ghost.hitTest(_local3) && (_local3._currentframe == 1)) {
this._parent.health = this._parent.health - (_local3.hurt + random(_local3.rand));
(this._parent.xx = this._parent.xx + (_local3.xx * 0.2));
(this._parent.rr = this._parent.rr + (_local3.xx * 0.5));
_local3.play();
}
if (this._parent.health <= 0) {
this._parent.snd.start(0, 1);
this.removeMovieClip();
}
sN++;
}
}
};
if (mp) {
(_local4._x = _xmouse);
(_local4._y = _ymouse);
_local4.health = -1;
}
};
shoot = function () {
shtCnt++;
var _local2 = attachMovie("sht", "sht" + shtCnt, 100 + shtCnt, {hurt:1, rand:3});
player.gun.play();
_local2._x = player._x + (player._xscale * 0.3);
_local2._y = player._y + 3;
_local2.xx = player._xscale * 0.1;
_local2.onEnterFrame = function () {
if (!gamePause) {
if ((this._x < -10) || (this._x > 810)) {
this.removeMovieClip();
}
this._x = this._x + this.xx;
this._width = Math.abs(this.xx) * 2;
}
};
HUD.ammo--;
};
shootSpecial = function (shootType) {
if ((shootType == "flame") && (Math.abs(frmCnt / 5) == (frmCnt / 5))) {
HUD.sAmmo--;
shtCnt++;
var _local9 = attachMovie("flame", "flm_" + shtCnt, 100 + shtCnt, {_x:player._x + (player._xscale * 0.2), _y:player._y + 3, xx:((player._xscale * 0.1) + ((-10 + random(20)) * 0.1)) + player.xx, yy:player.yy * 0.1});
_local9.onEnterFrame = function () {
if (!gamePause) {
this.runSnd();
this.yy = this.yy - (gravity * 0.1);
this.xx = this.xx * 0.94;
this._rotation = this._rotation + (random(Math.abs(this.xx) * 4) * abs1(this.xx));
(this._x = this._x + this.xx);
(this._y = this._y + this.yy);
nmeN = 0;
while (nmeN <= 20) {
var _local3 = _root["nme" + nmeN];
if (this.hitTest(_local3)) {
_local3.health = _local3.health - 0.05;
if (_local3.coal._alpha < 100) {
_local3.coal._alpha++;
}
_local3.lit = true;
}
nmeN++;
}
this.play();
} else {
this.stop();
}
};
}
if (((shootType == "spread") && (!sPress)) && (player.gun._currentframe == 1)) {
HUD.sAmmo--;
player.gun.gotoAndPlay("spread");
shtN = 0;
while (shtN < 5) {
shtCnt++;
var _local5 = attachMovie("sht", "sht" + shtCnt, 100 + shtCnt, {hurt:3, rand:5, _x:player._x + (player._xscale * 0.2), _y:player._y + 3, hits:0, xx:(player._xscale * 0.2) + ((-10 + random(20)) * 0.2), yy:(player.yy * 0.1) + ((-10 + random(20)) * 0.5)});
_local5.onEnterFrame = function () {
if (!gamePause) {
this.yy = this.yy + (gravity * 0.8);
(this._x = this._x + this.xx);
(this._y = this._y + this.yy);
if (this._y > ground) {
this.xx = this.xx * 0.8;
(this._y = ground);
(this.yy = this.yy * -0.9);
this.hits++;
}
this.clear();
this.lineStyle(2, 16750848);
this.lineTo(-this.xx, -this.yy);
if ((((this._x < -10) || (this._x > 810)) || (Math.abs(this.xx) < 1)) || (this.hits >= 5)) {
this.removeMovieClip();
}
}
};
shtN++;
}
}
if (((!sPress) && (shootType == "laser")) && (player.gun._currentframe == 1)) {
HUD.sAmmo--;
player.xx = player.xx - (abs1(player._xscale) * 14);
player.gun.gotoAndPlay("laser");
player.gun.onEnterFrame = function () {
if (!gamePause) {
lsrN = 0;
while (lsrN <= 20) {
var _local3 = _root["nme" + lsrN];
if (this.hitTest(_local3)) {
(_local3.lit = true);
(_local3.fire.clr = new Color(_local3.fire));
_local3.fire.clr.setRGB(13387007);
(_local3.coal.clr = new Color(_local3.coal));
_local3.coal.clr.setRGB(52479);
_local3.health = _local3.health - 20;
(_local3.xx = (player._x - _local3._x) * 0.2);
(_local3.rr = _local3.rr - (abs1(player._xscale) * 2));
_local3.yy--;
}
lsrN++;
}
if ((special.typ == "laser") && (this.hitTest(special))) {
(special.xx = (player._x - special._x) * 0.2);
(special.rr = special.rr - (abs1(player._xscale) * 2));
special.yy--;
special.timer++;
}
if (this.hitTest(pack)) {
(pack.xx = (player._x - pack._x) * 0.2);
(pack.rr = pack.rr - (abs1(player._xscale) * 2));
pack.yy--;
pack.timer++;
}
player.xx = player.xx + (abs1(player._xscale) * 0.5);
}
};
}
};
kills = (frmCnt = (shtCnt = (nmeTmr = (nmeCnt = 0))));
maxNme = 10;
packTimer = 288 + random(288);
specialTimer = 300 + random(200);
shootingNmes = 10;
gamePause = false;
onMouseDown = function () {
if (god) {
addEnemy(true);
HUD.ammo = HUD.ammo + 10;
if (!HUD.sAmmo) {
HUD.sType = "laser";
}
HUD.sAmmo = HUD.sAmmo + 10;
}
};
createEmptyMovieClip("bg", -2);
bgBMD = new flash.display.BitmapData(800, 590, true, 0);
bg.attachBitmap(bgBMD, 0);
attachMovie("nme", "player", -1, {_x:400, _y:300});
player.loadPlayer(1);
attachMovie("HUD", "HUD", 400);
pauseGame = function () {
switch (gamePause) {
case false :
gamePause = true;
return;
case true :
gamePause = false;
}
};
qBox = function () {
var _local1 = HUD.createEmptyMovieClip("qb", 130);
(_local1._x = 400);
(_local1._y = 240);
_local1.createTextField("ttl", 0, 0, 0, 0, 0);
(_local1.ttl.text = "Are you sure you want\nto exit current game?");
_local1.ttl.sTF({font:"courier new", size:20, align:"center"});
(_local1.ttl._width = _local1.ttl.textWidth + 4);
(_local1.ttl._height = _local1.ttl.textHeight + 4);
_local1.ttl._x = (-_local1.ttl._width) * 0.5;
_local1.attachMovie("button", "y", 1, {text:"Yes (Spacebar)", _x:-100, _y:70, _xscale:80, _yscale:60});
_local1.y.onRelease = function () {
HUD.music.stop();
gotoAndStop (2);
};
_local1.attachMovie("button", "n", 2, {text:"No (Escape)", _x:100, _y:70, _xscale:80, _yscale:60});
_local1.n.onRelease = function () {
if (!HUD.qb.gP) {
pauseGame();
}
HUD.qb.removeMovieClip();
};
_local1.onKeyDown = function () {
if (Key.getCode() == 32) {
HUD.music.stop();
gotoAndStop (2);
}
};
Key.addListener(_local1);
_local1.lineStyle(1, 0);
_local1.beginFill(14540253);
_local1.moveTo(-180, -10);
_local1.lineTo(180, -10);
_local1.lineTo(180, 100);
_local1.lineTo(-180, 100);
_local1.endFill();
if (gamePause) {
_local1.gP = true;
} else {
pauseGame();
}
};
onEnterFrame = function () {
if (Key.isDown(77)) {
if (!mPress) {
if (tmpV) {
(_global.masterV = tmpV);
delete tmpV;
} else {
(tmpV = masterV);
(_global.masterV = 0);
}
}
mPress = true;
} else {
delete mPress;
}
if (Key.isDown(81)) {
if (!qPress) {
switch (_quality.toLowerCase()) {
case "low" :
_quality = "MEDIUM";
so.data._quality = "MEDIUM";
break;
case "medium" :
_quality = "HIGH";
so.data._quality = "HIGH";
break;
case "high" :
_quality = "LOW";
so.data._quality = "LOW";
}
}
qPress = true;
} else {
delete qPress;
}
if (!gover) {
if (god) {
player.health = 100;
}
if (Key.isDown(13)) {
if (!HUD.qb) {
if ((frmCnt > 30) && (!pausePress)) {
pauseGame();
pausePress = true;
}
}
} else {
delete pausePress;
}
if (Key.isDown(27)) {
if (!escPress) {
if (!HUD.qb) {
qBox();
} else {
if (!HUD.qb.gP) {
pauseGame();
}
HUD.qb.removeMovieClip();
}
}
escPress = true;
} else {
delete escPress;
}
}
if (!gamePause) {
frmCnt++;
if (frmCnt > 2880) {
shootingNmes = 6;
}
if (frmCnt > 5760) {
shootingNmes = 4;
}
if (frmCnt > 8640) {
shootingNmes = 3;
}
if (frmCnt > 12960) {
shootingNmes = 2;
}
if (frmCnt > 19200) {
shootingNmes = 1;
}
if (nmeCnt >= 20) {
nmeCnt = 0;
}
if (shtCnt > 199) {
shtCnt = 0;
}
if (countNme < maxNme) {
if (nmeTmr == 0) {
addEnemy();
nmeTmr = 10 + random(50);
}
nmeTmr--;
}
player.uncontrollable();
if (player.health > 0) {
player.controllable();
if (player.hitTmr > 0) {
player.hitTmr--;
}
if (player.gun._currentframe != 1) {
player.gun.play();
}
} else {
if (!deathTime) {
deathTime = frmCnt;
}
if (deathTime == (frmCnt - 48)) {
attachMovie("gameOver", "gover", HUD.getDepth() + 1, {_x:400, _y:300});
}
}
countNme = 0;
ai = 1;
while (ai <= 20) {
if (_root["nme" + ai]) {
countNme++;
_root["nme" + ai].uncontrollable();
_root["nme" + ai].AI();
}
ai++;
}
packTimer--;
if (packTimer <= 0) {
packTimer = 288 + random(288);
attachMovie("pack", "pack", 399, {_x:50 + random(700), _y:-20, xx:0, yy:0, rr:0, timer:300});
if (HUD.ammo < 10) {
pack.gotoAndStop(2);
} else {
pack.gotoAndStop(1 + random(2));
}
pack.phys = function () {
this.yy = this.yy + gravity;
(this._x = this._x + this.xx);
(this._y = this._y + this.yy);
(this._rotation = this._rotation + this.rr);
if (bgBMD.getPixel32(this._x, this._y) != 0) {
this.g = true;
} else {
delete this.g;
}
if (this.g) {
this.xx = (this.rr = (this._rotation = 0));
if (this.yy > 0) {
this.yy = this.yy * -0.1;
this._y--;
}
}
if (this._y > ground) {
this.xx = (this.rr = (this._rotation = 0));
this.yy = this.yy * -0.3;
this._y = ground;
}
};
}
specialTimer--;
if (specialTimer <= 0) {
specialTimer = 480 + random(384);
attachMovie("special", "special", 398, {_x:50 + random(700), _y:-20, xx:0, yy:0, rr:0, timer:400, addH:10});
special.phys = function () {
this.yy = this.yy + gravity;
(this._x = this._x + this.xx);
(this._y = this._y + this.yy);
(this._rotation = this._rotation + this.rr);
if (bgBMD.getPixel32(this._x, this._y + this.addH) != 0) {
this.g = true;
} else {
delete this.g;
}
if (this.g) {
this.xx = (this.rr = (this._rotation = 0));
if (this.yy > 0) {
this.yy = this.yy * -0.1;
this._y--;
}
}
if ((this._y + this.addH) > ground) {
this.xx = (this.rr = (this._rotation = 0));
this.yy = this.yy * -0.3;
this._y = ground - this.addH;
}
};
}
HUD._y = -_y;
} else {
player.gun.stop();
}
};
stop();
Instance of Symbol 293 MovieClip "heightmeter" in Frame 3
onClipEvent (load) {
g = new flash.filters.GlowFilter(16777215, 100, 3, 3, 10, 1);
filters = [g];
top = (left = (right = _y));
createTextField("txt", 0, 6, -20, 10, 20);
(txt.selectable = false);
}
onClipEvent (enterFrame) {
_y = (_y + ((top - _y) * 0.1));
hit = Math.round((((-top) + 580) * 0.042) * 10) / 10;
txt.text = ("Highest point: " + hit) + " meters.";
txt.sTF({font:"courier new", bold:true});
(txt._width = txt.textWidth + 4);
}
Frame 4
gotoAndStop (3);
Symbol 20 MovieClip [ind] Frame 1
stop();
snd = new Sound(this);
snd.attachSound("newcheat");
snd.setVolume(100 * masterV);
snd.start(0, 1);
Symbol 20 MovieClip [ind] Frame 20
this.removeMovieClip();
Symbol 37 MovieClip Frame 40
stop();
Symbol 51 Button
on (press) {
tellTarget (_root) {
nextFrame();
};
}
Symbol 52 Button
on (press) {
gotoAndStop ("end");
_root.play();
}
Instance of Symbol 27 MovieClip in Symbol 53 MovieClip Frame 1
onClipEvent (load) {
_root.stop();
PercentLoaded = int((_root.getBytesLoaded() / _root.getBytesTotal()) * 100);
if (PercentLoaded != 100) {
_parent.gotoAndStop(PercentLoaded);
} else {
_parent.gotoAndStop("lastframe");
}
}
onClipEvent (enterFrame) {
PercentLoaded = int((_root.getBytesLoaded() / _root.getBytesTotal()) * 100);
if (PercentLoaded != 100) {
_parent.gotoAndStop(PercentLoaded);
} else {
_parent.gotoAndPlay("loaded");
}
}
Symbol 53 MovieClip Frame 101
play();
Symbol 53 MovieClip Frame 165
stop();
Symbol 59 Button
on (release) {
NewgroundsAPI.loadNewgrounds();
}
Symbol 65 Button
on (release) {
NewgroundsAPI.loadNewgrounds();
}
Symbol 67 MovieClip Frame 1
function startAd(ngad_url) {
trace("opening " + ngad_url);
System.security.allowDomain("70.87.128.99");
System.security.allowInsecureDomain("70.87.128.99");
System.security.allowDomain("ads.shizmoo.com");
System.security.allowInsecureDomain("ads.shizmoo.com");
System.security.allowDomain("www.cpmstar.com");
System.security.allowInsecureDomain("www.cpmstar.com");
System.security.allowDomain("server.cpmstar.com");
System.security.allowInsecureDomain("server.cpmstar.com");
var ngads_redirect = new XML();
ngads_redirect.ignoreWhite = true;
ngads_redirect.onLoad = function (success) {
trace("[NEWGROUNDS FLASH ADS] :: You may get a 'Security Sandbox Violation' ... this is normal, do not freak out!");
if (success) {
ng_ad.loadMovie(ngads_redirect.toString(), "GET");
}
};
ngads_redirect.load(ngad_url);
}
if (NewgroundsAPI.getAdURL()) {
startAd(NewgroundsAPI.getAdURL());
}
NewgroundsAPI.onAdsApproved = function (ad_url) {
startAd(ad_url);
};
stop();
Symbol 294 MovieClip [__Packages.NewgroundsAPI] Frame 0
class NewgroundsAPI
{
static var tracker_id, host, version, debug, error_format, header_format, normal_format, link_format;
function NewgroundsAPI () {
}
static function connectMovie(id) {
if (!id) {
SendError("Missing required 'id' parameter in NewgroundsAPI.connectMovie(id:Number)");
} else if (!tracker_id) {
SendMessage("Connecting to API gateway...");
tracker_id = id;
host = _url.split("/")[2].toLowerCase();
if (host.length < 1) {
host = "localhost";
}
var _local2 = new Object();
SendEvent(MOVIE_VIEWS);
}
}
static function setMovieVersion(movie_version) {
if (!movie_version) {
SendError("Missing required 'version' in NewgroundsAPI.setMovieVersion(version:String)");
} else {
version = movie_version;
}
}
static function debugMode() {
debug = true;
}
static function addCustomEvent(stat_id, stat_name) {
if (!stat_id) {
SendError("Missing required 'id' parameter in NewgroundsAPI.AddCustomEvent(id:Number, event_name:String)");
} else if (!stat_name) {
SendError("Missing required 'event_name' parameter in NewgroundsAPI.AddCustomEvent(id:Number, event_name:String)");
} else {
custom_events[stat_name] = CUSTOM_STATS + stat_id;
SendMessage("Created custom event: " + stat_name);
}
}
static function addCustomLink(stat_id, stat_name) {
if (!stat_id) {
SendError("Missing required 'id' parameter in NewgroundsAPI.AddCustomLink(id:Number, link_name:String)");
} else if (!stat_name) {
SendError("Missing required 'link_name' parameter in NewgroundsAPI.AddCustomLink(id:Number, link_name:String)");
} else {
custom_links[stat_name] = CUSTOM_STATS + stat_id;
SendMessage((("Created custom link " + stat_id) + ": ") + stat_name);
}
}
static function loadMySite() {
SendLink(AUTHOR_SITE);
}
static function loadNewgrounds(special) {
if (special) {
var _local1 = {page:special};
}
SendLink(NEWGROUNDS, _local1);
}
static function logCustomEvent(event_name) {
if (!event_name) {
SendError("Missing required 'event_name' parameter in NewgroundsAPI.logCustomEvent(event_name:String)");
} else if (!custom_events[event_name]) {
SendError("Attempted to log undefined custom event: " + event_name);
} else {
SendEvent(custom_events[event_name]);
}
}
static function loadCustomLink(link_name) {
if (!link_name) {
SendError("Missing required 'link_name' parameter in NewgroundsAPI.loadCustomLink(link_name:String)");
} else if (!custom_links[link_name]) {
SendError("Attempted to open undefined custom link: " + link_name);
} else {
SendLink(custom_links[link_name]);
}
}
static function getAdURL() {
return(movie_options.ad_url);
}
static function getMovieURL() {
if (movie_options.movie_url) {
return(movie_options.movie_url);
}
return("Newgrounds.com");
}
static function getNewVersionURL() {
return((((((GATEWAY_URL + "?&id=") + tracker_id) + "&host=") + escape(host)) + "&stat=") + NEW_VERSION);
}
static function SendEvent(id) {
SendStat(id, false);
}
static function SendLink(id, extra) {
SendStat(id, true, extra);
}
static function ReadGatewayData(params) {
for (var _local2 in params) {
params[_local2] = unescape(params[_local2]);
movie_options[_local2] = params[_local2];
}
if (params.settings_loaded) {
SendMessage("You have successfully connected to the Newgrounds API gateway!");
SendMessage(("Movie Identified as '" + movie_options.movie_name) + "'");
if (movie_options.message) {
SendMessage(movie_options.message);
}
if (movie_options.ad_url) {
SendMessage("Your movie has been approved to run Flash Ads");
onAdsApproved(movie_options.ad_url);
}
if (movie_options.movie_version and (movie_options.movie_version.toString() != version.toString())) {
SendMessage("WARNING: The movie version configured in your API settings does not match this movie's version!");
onNewVersionAvailable(movie_options.movie_version, getMovieURL(), getNewVersionURL());
}
if (movie_options.deny_host) {
SendMessage("You have blocked 'localHost' in your API settings.");
SendMessage("If you wish to test your movie you will need to remove this block.");
onDenyHost(host, getMovieURL(), getNewVersionURL());
}
if (movie_options.request_portal_url == 1) {
var _local4 = (((GATEWAY_URL + "?&id=") + tracker_id) + "&portal_url=") + escape(_url);
var _local3 = new XML();
_local3.ignoreWhite = true;
_local3.load(_local4);
}
} else if (!movie_options.settings_loaded) {
SendError("Could not establish connection to the API gateway.");
}
}
static function SendStat(stat_id, open_in_browser, extra) {
if (!tracker_id) {
SendError("API calls cannot be made without a valid movie id.");
SendError("Did you remember to add the \"NewgroundsAPI.connectMovie()\" code?");
} else {
var _local7 = (((((GATEWAY_URL + "?&id=") + tracker_id) + "&host=") + escape(host)) + "&stat=") + stat_id;
for (var _local9 in extra) {
_local7 = _local7 + ((("&" + escape(_local9)) + "=") + escape(extra[_local9]));
}
trace(_local7);
if (debug) {
_local7 = _local7 + "&debug=1";
}
if (open_in_browser) {
getURL (_local7, "_blank");
} else {
var _local10 = new XML();
_local10.ignoreWhite = true;
_local10.onLoad = function (success) {
var _local6 = new Object();
var _local3 = 0;
while (_local3 < this.firstChild.childNodes.length) {
var _local4 = this.firstChild.childNodes[_local3];
var _local5 = _local4.nodeName;
var _local2 = _local4.attributes.value;
if (_local2 == Number(_local2)) {
_local2 = Number(_local2);
}
_local6[_local5] = _local2;
_local3++;
}
NewgroundsAPI.ReadGatewayData(_local6);
};
_local10.load(_local7);
}
}
}
static function SendError(msg) {
trace("[NEWGROUNDS API ERROR] :: " + msg);
}
static function SendMessage(msg) {
trace("[NEWGROUNDS API] :: " + msg);
}
static function InitTextFormats() {
if (!error_format) {
error_format = new TextFormat();
error_format.font = "Arial Black";
error_format.size = 48;
error_format.color = 16711680 /* 0xFF0000 */;
}
if (!header_format) {
header_format = new TextFormat();
header_format.font = "Arial Black";
header_format.size = 24;
header_format.color = 16777215 /* 0xFFFFFF */;
}
if (!normal_format) {
normal_format = new TextFormat();
normal_format.font = "Arial";
normal_format.bold = true;
normal_format.size = 12;
normal_format.color = 16777215 /* 0xFFFFFF */;
}
if (!link_format) {
link_format = new TextFormat();
link_format.color = 16776960 /* 0xFFFF00 */;
link_format.underline = true;
}
}
static function onNewVersionAvailable(version, movie_url, redirect_url) {
InitTextFormats();
var _local2 = new Object();
_local2.x = Stage.width / 2;
_local2.y = Stage.height / 2;
_root.createEmptyMovieClip("NGAPI_new_version_overlay", _root.getNextHighestDepth());
_root.NGAPI_new_version_overlay.lineStyle(1, 0, 100);
_root.NGAPI_new_version_overlay.beginFill(0, 70);
_root.NGAPI_new_version_overlay.moveTo(-10, -10);
_root.NGAPI_new_version_overlay.lineTo(-10, 1000);
_root.NGAPI_new_version_overlay.lineTo(1000, 1000);
_root.NGAPI_new_version_overlay.lineTo(1000, -10);
_root.NGAPI_new_version_overlay.lineTo(-10, -10);
_root.NGAPI_new_version_overlay.endFill();
_root.NGAPI_new_version_overlay.lineStyle(10, 0, 100);
_root.NGAPI_new_version_overlay.beginFill(51);
_root.NGAPI_new_version_overlay.moveTo(_local2.x - 240, _local2.y - 120);
_root.NGAPI_new_version_overlay.lineTo(_local2.x + 240, _local2.y - 120);
_root.NGAPI_new_version_overlay.lineTo(_local2.x + 240, _local2.y + 80);
_root.NGAPI_new_version_overlay.lineTo(_local2.x - 240, _local2.y + 80);
_root.NGAPI_new_version_overlay.lineTo(_local2.x - 240, _local2.y - 120);
_root.NGAPI_new_version_overlay.endFill();
_root.NGAPI_new_version_overlay.createEmptyMovieClip("exit", 1000);
_root.NGAPI_new_version_overlay.exit.lineStyle(2, 39423, 100);
_root.NGAPI_new_version_overlay.exit.beginFill(0, 50);
_root.NGAPI_new_version_overlay.exit.moveTo(_local2.x + 210, _local2.y - 110);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 230, _local2.y - 110);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 230, _local2.y - 90);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 210, _local2.y - 90);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 210, _local2.y - 110);
_root.NGAPI_new_version_overlay.exit.endFill();
_root.NGAPI_new_version_overlay.exit.moveTo(_local2.x + 214, _local2.y - 106);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 226, _local2.y - 94);
_root.NGAPI_new_version_overlay.exit.moveTo(_local2.x + 226, _local2.y - 106);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 214, _local2.y - 94);
_root.NGAPI_new_version_overlay.exit.onMouseUp = function () {
if (_root.NGAPI_new_version_overlay.exit.hitTest(_root._xmouse, _root._ymouse)) {
_root.NGAPI_new_version_overlay.removeMovieClip();
}
};
var _local3 = (("Version " + version) + " is now available at:") + newline;
var _local5 = _local3.length;
_local3 = _local3 + movie_url;
var _local4 = _local3.length;
_root.NGAPI_new_version_overlay.createTextField("mouseblocker", 99, -10, -10, 1000, 1000);
_root.NGAPI_new_version_overlay.createTextField("newversion", 100, _local2.x - 210, _local2.y - 90, 400, 80);
_root.NGAPI_new_version_overlay.newversion.text = "New Version Available!";
_root.NGAPI_new_version_overlay.newversion.setTextFormat(header_format);
_root.NGAPI_new_version_overlay.createTextField("message", 101, (Stage.width - 400) / 2, Stage.height / 2, 400, 40);
_root.NGAPI_new_version_overlay.message.text = _local3;
_root.NGAPI_new_version_overlay.message.multiline = true;
_root.NGAPI_new_version_overlay.message.wordWrap = true;
_root.NGAPI_new_version_overlay.message.html = true;
_root.NGAPI_new_version_overlay.message.setTextFormat(normal_format);
link_format.url = redirect_url;
_root.NGAPI_new_version_overlay.message.setTextFormat(_local5, _local4, link_format);
}
static function onDenyHost(hostname, movie_url, redirect_url) {
InitTextFormats();
_root.createEmptyMovieClip("NGAPI_deny_host_overlay", _root.getNextHighestDepth());
_root.NGAPI_deny_host_overlay.lineStyle(20, 0, 100);
_root.NGAPI_deny_host_overlay.beginFill(6684672);
_root.NGAPI_deny_host_overlay.moveTo(0, 0);
_root.NGAPI_deny_host_overlay.lineTo(Stage.width, 0);
_root.NGAPI_deny_host_overlay.lineTo(Stage.width, Stage.height);
_root.NGAPI_deny_host_overlay.lineTo(0, Stage.height);
_root.NGAPI_deny_host_overlay.lineTo(0, 0);
_root.NGAPI_deny_host_overlay.endFill();
var _local2 = ("This movie has not been approved for use on " + hostname) + ".";
_local2 = _local2 + "\r\rFor an aproved copy, please visit:\r";
var _local4 = _local2.length;
_local2 = _local2 + movie_url;
var _local3 = _local2.length;
_root.NGAPI_deny_host_overlay.createTextField("mousekill", 100, 0, 0, Stage.width, Stage.height);
_root.NGAPI_deny_host_overlay.createTextField("error", 101, (Stage.width - 400) / 2, (Stage.height / 2) - 100, 400, 200);
_root.NGAPI_deny_host_overlay.error.text = "ERROR!";
_root.NGAPI_deny_host_overlay.error.setTextFormat(error_format);
_root.NGAPI_deny_host_overlay.createTextField("message", 102, (Stage.width - 400) / 2, Stage.height / 2, 400, 200);
_root.NGAPI_deny_host_overlay.message.text = _local2;
_root.NGAPI_deny_host_overlay.message.multiline = true;
_root.NGAPI_deny_host_overlay.message.wordWrap = true;
_root.NGAPI_deny_host_overlay.message.html = true;
_root.NGAPI_deny_host_overlay.message.setTextFormat(normal_format);
link_format.url = redirect_url;
_root.NGAPI_deny_host_overlay.message.setTextFormat(_local4, _local3, link_format);
}
static function isInstalled() {
return(true);
}
static function onAdsApproved(ad_url) {
}
static var movie_options = new Object();
static var custom_events = new Object();
static var custom_links = new Object();
static var MOVIE_VIEWS = 1;
static var AUTHOR_SITE = 2;
static var NEWGROUNDS = 3;
static var NEW_VERSION = 4;
static var CUSTOM_STATS = 50;
static var GATEWAY_URL = "http://www.ngads.com/gateway.php";
}
Symbol 75 MovieClip Frame 1
(h = _y);
_y = 610;
gtH = 610;
onEnterFrame = function () {
if (this.hitTest(_root._xmouse, _root._ymouse)) {
gtH = h;
} else {
gtH = 610;
}
_y = (_y + ((gtH - _y) * 0.1));
};
Symbol 113 MovieClip [flame] Frame 1
snd = new Sound(this);
snd.attachSound("flame_s");
snd.setVolume(0);
snd.start(random(10) * 0.1, 10);
runSnd = function () {
if (snd.getVolume() < (300 * masterV)) {
snd.setVolume(snd.getVolume() + (50 * masterV));
}
if (Key.isDown(27)) {
snd.stop();
delete snd;
}
};
Symbol 113 MovieClip [flame] Frame 16
runSnd = function () {
if (snd.getVolume() > 0) {
snd.setVolume(snd.getVolume() * 0.7);
}
if (Key.isDown(27)) {
snd.stop();
delete snd;
}
};
Symbol 113 MovieClip [flame] Frame 31
snd.stop();
delete snd;
this.removeMovieClip();
Symbol 130 MovieClip [gameOver] Frame 1
if (highscore) {
gotoAndStop (2);
} else {
stop();
pHit = _root.heightmeter.hit;
if (Math.round(_root.deathTime / 48) > 60) {
myTime = timerFromSeconds(Math.floor(_root.deathTime / 48) - 1);
} else {
myTime = Math.round(_root.deathTime / 48) + " seconds";
}
myTime2 = Math.round(_root.deathTime / 48);
statsTxt.text = ((((((("Kills: " + _root.kills) + ".\n\n") + "Time survived: ") + myTime) + ".\n\n") + "Deadpile height: ") + pHit) + " meters.";
pScore = Math.round((pHit * 100) + ((pHit / myTime2) * 100));
fsTxt.text = "Final Score: " + pScore;
delete _root.HUD.onEnterFrame;
_root.HUD.hs._alpha = 0;
if (((god || (weps.laser)) || (weps.flame)) || (weps.spread)) {
nameTF.border = (nameTF.background = (nameTF.selectable = false));
nameTF.type = "dynamic";
nameTF.text = "";
fsTxt.text = "No score. You used cheats.";
btn.text = "High Scores";
btn.onPress = function () {
play();
};
newCheat.text = "";
} else {
if (!_root.gotCheats) {
newCheat.text = "";
}
btn.text = "Submit Score";
btn.onPress = function () {
pName = nameTF.text;
play();
};
Selection.setFocus(nameTF);
}
}
Instance of Symbol 118 MovieClip [button] "btn2" in Symbol 130 MovieClip [gameOver] Frame 1
onClipEvent (load) {
text = "Back to Menu";
}
on (press) {
_root.HUD.music.stop();
_root.gotoAndStop(2);
_parent.removeMovieClip();
}
Symbol 130 MovieClip [gameOver] Frame 2
stop();
refreshTable = function (addScore) {
if (_root.so.data.pList) {
var _local2 = _root.so.data.pList;
} else {
var _local2 = [];
i = 0;
while (i < 10) {
_local2[i] = {name:"- - -", score:0};
i++;
}
_root.so.data.pList = _local2;
}
_local2.sortOn("score", 18);
if (addScore) {
i = 9;
while (i >= 0) {
if (pScore > _local2[i].score) {
_local2.splice(i + 1, 0, {name:pName, score:pScore});
pScore = 0;
break;
}
i--;
}
}
_local2.sortOn("score", 18);
hsName.text = (hsHeight.text = "");
i = 0;
while (i < 10) {
hsName.text = hsName.text + (_local2[i].name + newline);
hsHeight.text = hsHeight.text + (_local2[i].score + newline);
i++;
}
};
refreshTable(pName && (pScore));
Instance of Symbol 118 MovieClip [button] "btn" in Symbol 130 MovieClip [gameOver] Frame 2
onClipEvent (load) {
text = "Back to Menu";
}
on (press) {
_root.HUD.music.stop();
_root.gotoAndStop(2);
_parent.removeMovieClip();
}
Symbol 156 MovieClip [HUD] Frame 1
sAmmo = 0;
ammo = 120;
addAlpha = 0;
hs._alpha = 0;
if (!_root.so.data.cheats) {
_root.so.data.cheats = [];
}
onEnterFrame = function () {
if (!_root.gamePause) {
myTime = timerFromSeconds(Math.floor(_root.frmCnt / 48) - 1);
if (ammo > 400) {
ammo = 400;
}
if ((sType == "flame") && (sAmmo > 400)) {
sAmmo = 400;
}
if ((sType == "spread") && (sAmmo > 40)) {
sAmmo = 40;
}
if (_root.player.health > 100) {
_root.player.health = 100;
}
addAlpha = (40 - _root.player.health) * 2;
if (addAlpha < 0) {
addAlpha = 0;
}
gth = _root.player.health;
hb._width = hb._width + ((gth - hb._width) * 0.2);
hs._alpha = ((-(gth - hb._width)) * 10) + addAlpha;
if (sType && (sAmmo <= 0)) {
delete sType;
}
if (((((_root.frmCnt > 100) && (!god)) && (!weps.laser)) && (!weps.flame)) && (!weps.spread)) {
var _local3 = _root.so.data.cheats.length;
var _local2 = _root.heightmeter.hit;
if ((_local2 >= 5) && (_root.so.data.cheats.length < 1)) {
_root.so.data.cheats[0] = _root.cheats[0];
_root.gotCheats = true;
indicateC();
}
if ((_local2 > 10) && (_root.so.data.cheats.length < 2)) {
_root.so.data.cheats[1] = _root.cheats[1];
_root.gotCheats = true;
indicateC();
}
if ((_local2 > 15) && (_root.so.data.cheats.length < 3)) {
_root.so.data.cheats[2] = _root.cheats[2];
_root.gotCheats = true;
indicateC();
}
if ((_local2 > 20) && (_root.so.data.cheats.length < 4)) {
_root.so.data.cheats[3] = _root.cheats[3];
_root.gotCheats = true;
indicateC();
}
if ((_local2 > 22) && (_root.so.data.cheats.length < 5)) {
_root.so.data.cheats[4] = _root.cheats[4];
_root.gotCheats = true;
indicateC();
}
}
if (!mPlaying) {
pauseMusic(false);
}
if (_root.deathTime) {
music.setVolume(music.getVolume() * 0.99);
} else {
music.setVolume((musicV * masterV) * 100);
}
} else if (mPlaying) {
pauseMusic(true);
}
};
ca = [];
if (god) {
ca[ca.length] = " God";
}
if (grnLnd) {
ca[ca.length] = " Greenland";
}
if (weps.laser) {
ca[ca.length] = " All special ammo is laser";
}
if (weps.spread) {
ca[ca.length] = " All special ammo is shotgun";
}
if (weps.flame) {
ca[ca.length] = " All special ammo is flame";
}
if (ca.length) {
cht.text = "Activated Cheats:\n" + ca;
} else {
cht.text = "";
}
indG1 = new flash.filters.GlowFilter(16777215, 100, 10, 10, 5, 1);
indicateC = function () {
attachMovie("ind", "ind", 157);
(ind._x = 400);
(ind._y = 270);
ind.filters = [indG1];
(ind.ss = 10);
(ind.gtS = 180);
(ind.frmCnt = 0);
ind.onEnterFrame = function () {
this.snd.setVolume(100 * masterV);
this.ss = this.ss + ((this.gtS - this._xscale) * 0.1);
this.ss = this.ss * 0.9;
(this._xscale = this._xscale + this.ss);
(this._yscale = this._xscale);
this.frmCnt++;
if (this.frmCnt > 72) {
this.play();
}
};
};
music = new Sound(this);
music.attachSound("GameMusic");
music.onSoundComplete = function () {
this.start(0, 1);
};
lastPos = 0;
pauseMusic = function (flag) {
switch (flag) {
case false :
music.start(lastPos, 1);
mPlaying = true;
lastPos = 0;
break;
case true :
lastPos = music.position * 0.001;
music.stop();
mPlaying = false;
}
};
Instance of Symbol 132 MovieClip in Symbol 156 MovieClip [HUD] Frame 1
onClipEvent (enterFrame) {
if (!_root.shootS) {
_visible = true;
} else {
_visible = false;
}
}
Instance of Symbol 132 MovieClip in Symbol 156 MovieClip [HUD] Frame 1
onClipEvent (load) {
_visible = false;
}
onClipEvent (enterFrame) {
if (_root.shootS) {
_visible = true;
} else {
_visible = false;
}
}
Instance of Symbol 141 MovieClip in Symbol 156 MovieClip [HUD] Frame 1
onClipEvent (load) {
g = new flash.filters.GlowFilter(16777215, 100, 10, 10, 2.1, 2);
}
onClipEvent (enterFrame) {
if (_parent.sAmmo) {
gotoAndStop(_parent.sType);
filters = [g];
} else {
gotoAndStop (1);
filters = [];
}
}
Symbol 163 MovieClip [pack] Frame 1
snd = new Sound(this);
snd.attachSound("health_s");
snd.setVolume(200 * masterV);
onEnterFrame = function () {
if (!_root.gamePause) {
snd.setVolume(200 * masterV);
if ((_root.player.hitTest(this) && (_root.player.health > 0)) && (Math.abs(_root.player._x - _x) < 20)) {
(_root.player.health = _root.player.health + 10);
snd.start(0, 1);
delete onEnterFrame;
gotoAndPlay ("h");
}
phys();
timer--;
if (timer == 0) {
this.removeMovieClip();
}
}
};
Symbol 163 MovieClip [pack] Frame 2
snd = new Sound(this);
snd.attachSound("ammo_s");
snd.setVolume(200 * masterV);
onEnterFrame = function () {
if (!_root.gamePause) {
snd.setVolume(200 * masterV);
if ((_root.player.hitTest(this) && (_root.player.health > 0)) && (Math.abs(_root.player._x - _x) < 20)) {
(_root.HUD.ammo = _root.HUD.ammo + 120);
snd.start(0, 1);
delete onEnterFrame;
gotoAndPlay ("a");
}
phys();
timer--;
if (timer == 0) {
this.removeMovieClip();
}
}
};
Symbol 163 MovieClip [pack] Frame 3
_rotation = 0;
Symbol 163 MovieClip [pack] Frame 35
this.removeMovieClip();
Symbol 163 MovieClip [pack] Frame 36
_rotation = 0;
Symbol 163 MovieClip [pack] Frame 70
this.removeMovieClip();
Symbol 170 MovieClip Frame 1
stop();
rr = 0;
Symbol 170 MovieClip Frame 2
shootTimer = 24 + random(96);
onEnterFrame = function () {
if (!_root.gamePause) {
if (_root.player.health > 0) {
if (!_parent._parent.lit) {
_rotation = (Vect.vtd({x:(_root.player._x - _parent._parent._x) * abs1(_parent._parent._xscale), y:_root.player._y - _parent._parent._y}) - 90);
}
if (shootTimer <= 0) {
shoot();
shootTimer = 24 + random(96);
}
shootTimer--;
}
}
};
shoot = function () {
_root.shtCnt++;
var _local4 = Vect.dtv((_rotation + 90) - _parent._parent._rotation, 25);
pointerX = ((_parent._parent._x + _parent._x) + _x) + (_local4.x * abs1(_parent._parent._xscale));
pointerY = ((_parent._parent._y + _parent._y) + _y) + _local4.y;
var _local5 = _root.attachMovie("sht", "psht" + _root.shtCnt, 100 + _root.shtCnt, {_x:pointerX, _y:pointerY, xx:_local4.x * abs1(_parent._parent._xscale), yy:_local4.y, _xscale:120, _yscale:120});
_local5.onEnterFrame = function () {
if (!gamePause) {
this.clear();
this.lineStyle(2, 16750848);
this.lineTo(-this.xx, -this.yy);
if (_root.player.hitTest(this._x, this._y)) {
_root.player.health = _root.player.health - 5;
this.removeMovieClip();
}
if ((((this._x < -10) || (this._x > 810)) || (this._y < -10)) || (this._y > 610)) {
this.removeMovieClip();
}
(this._x = this._x + this.xx);
(this._y = this._y + this.yy);
}
};
play();
};
Symbol 170 MovieClip Frame 6
gotoAndStop (2);
Symbol 176 MovieClip Frame 1
stop();
onEnterFrame = function () {
if (_root.shootS) {
gotoAndStop(_root.HUD.sType);
} else {
gotoAndStop (1);
}
};
Symbol 205 MovieClip Frame 1
stop();
shootSnd = ["shoot_1", "shoot_2", "shoot_3", "shoot_4", "shoot_5", "shoot_6", "shoot_7", "shoot_8", "shoot_9"];
snd = new Sound(this);
snd.attachSound(shootSnd[random(shootSnd.length)]);
snd.setVolume(100 * masterV);
shootSnd2 = ["spread_0", "spread_1", "spread_2"];
snd2 = new Sound(this);
snd2.attachSound(shootSnd2[random(shootSnd2.length)]);
snd2.setVolume(300 * masterV);
snd3 = new Sound(this);
snd3.attachSound("laser_s");
snd3.setVolume(200 * masterV);
Symbol 205 MovieClip Frame 2
snd.start(0, 1);
Symbol 205 MovieClip Frame 5
gotoAndStop (1);
Symbol 205 MovieClip Frame 6
snd2.start(0, 1);
Symbol 205 MovieClip Frame 13
gotoAndStop (1);
Symbol 205 MovieClip Frame 14
gotoAndStop (1);
Symbol 205 MovieClip Frame 15
g1 = new flash.filters.GlowFilter(12255440, 100, 40, 40, 1, 1);
g2 = new flash.filters.GlowFilter(16777215, 100, 16, 16, 2, 1, true);
filters = [g2, g1];
snd3.start(0, 1);
Symbol 205 MovieClip Frame 51
delete onEnterFrame;
filters = [];
Symbol 205 MovieClip Frame 58
gotoAndStop (1);
Instance of Symbol 205 MovieClip "gun" in Symbol 207 MovieClip Frame 1
onClipEvent (load) {
if (_parent._parent._name != "player") {
this.swapDepths(100);
this.removeMovieClip();
}
}
Instance of Symbol 170 MovieClip "h1" in Symbol 207 MovieClip Frame 1
onClipEvent (load) {
if ((_parent._parent._name != "player") && (!random(_root.shootingNmes))) {
gotoAndStop (2);
}
}
Symbol 207 MovieClip Frame 30
gotoAndPlay ("run");
Symbol 209 MovieClip Frame 1
_alpha = 0;
onEnterFrame = function () {
if (_parent.lit && (_alpha < 100)) {
_alpha = (_alpha+1);
}
};
Symbol 219 MovieClip Frame 1
_visible = false;
onEnterFrame = function () {
if (_root.gamePause) {
stop();
} else {
play();
if (_parent.lit) {
_visible = true;
(_parent.ani.h1.rr = _parent.ani.h1.rr + ((random(20) - 10) * 0.1));
(_parent.ani.h1._rotation = _parent.ani.h1._rotation + _parent.ani.h1.rr);
(_parent.ani.h2.rr = _parent.ani.h2.rr + ((random(20) - 10) * 0.1));
(_parent.ani.h2._rotation = _parent.ani.h2._rotation + _parent.ani.h2.rr);
} else {
_visible = false;
}
}
};
Symbol 219 MovieClip Frame 19
gotoAndPlay (1);
Symbol 226 MovieClip [nme] Frame 1
stop();
gun = ani.gun;
addH = 25;
if (!health) {
health = 100;
hitTmr = 0;
hitSnd = ["hit_1", "hit_2", "hit_3"];
hit = new Sound(this);
hit.setVolume(50 * masterV);
} else {
dieSnd = ["die_1", "die_2", "die_3", "die_4", "die_5", "die_6", "die_7", "die_8", "die_9", "die_10", "die_11", "die_12"];
snd = new Sound(this);
snd.attachSound(dieSnd[random(dieSnd.length)]);
snd.setVolume(50 * masterV);
}
Instance of Symbol 207 MovieClip "ani" in Symbol 226 MovieClip [nme] Frame 1
onClipEvent (enterFrame) {
if (Math.abs(_parent.xx) > 1) {
if (_root.gamePause) {
this.stop();
} else {
this.play();
}
} else {
this.gotoAndStop(1);
}
gun.snd.setVolume(100 * masterV);
gun.snd2.setVolume(300 * masterV);
gun.snd3.setVolume(200 * masterV);
}
Symbol 226 MovieClip [nme] Frame 2
l1.onEnterFrame = function () {
if (abs1(_rotation) == abs1(_xscale)) {
delete l1.onEnterFrame;
nextFrame();
}
if (abs1(_rotation) == (-abs1(_xscale))) {
delete l1.onEnterFrame;
}
};
Symbol 231 MovieClip [sht] Frame 1
stop();
Symbol 231 MovieClip [sht] Frame 2
onEnterFrame = function () {
if (_root.gamePause) {
stop();
} else {
play();
_x = (_x + xx);
_yscale = 100;
_xscale = 100;
_rotation = (random(360) - 180);
}
};
Symbol 231 MovieClip [sht] Frame 8
this.removeMovieClip();
Symbol 241 MovieClip [special] Frame 1
g1 = new flash.filters.GlowFilter(65280, 100, 40, 40, 1, 2);
filters = [g1];
xx = (rr = 0);
snd = new Sound(this);
snd.attachSound("ammo_s");
snd.setVolume(200 * masterV);
onEnterFrame = function () {
if (!_root.gamePause) {
snd.setVolume(200 * masterV);
if ((_root.player.hitTest(this) && (_root.player.health > 0)) && (Math.abs(_root.player._x - _x) < 20)) {
if (_root.HUD.sType != typ) {
(_root.HUD.sAmmo = 0);
(_root.HUD.sType = typ);
}
(_root.HUD.sAmmo = _root.HUD.sAmmo + ammo);
snd.start(0, 1);
delete onEnterFrame;
play();
}
phys();
timer--;
if (timer == 0) {
this.removeMovieClip();
}
}
};
typA = ["flame", "flame", "flame", "spread", "spread", "spread", "laser"];
typ = typA[random(typA.length)];
if (weps.laser) {
typ = "laser";
}
if (weps.flame) {
typ = "flame";
}
if (weps.spread) {
typ = "spread";
}
gotoAndStop(typ);
Symbol 241 MovieClip [special] Frame 2
ammo = 180;
(g1.color = 16755200);
(filters = [g1]);
Symbol 241 MovieClip [special] Frame 21
removeMovieClip(this);
Symbol 241 MovieClip [special] Frame 22
ammo = 18;
(g1.color = 12163176);
(filters = [g1]);
Symbol 241 MovieClip [special] Frame 41
removeMovieClip(this);
Symbol 241 MovieClip [special] Frame 42
ammo = 4;
(g1.color = 16711935);
(filters = [g1]);
Symbol 241 MovieClip [special] Frame 62
removeMovieClip(this);
Symbol 282 MovieClip Frame 1
stop();
Symbol 288 MovieClip Frame 1
onEnterFrame = function () {
if (_root.gover) {
_visible = false;
} else {
_visible = true;
}
if (open) {
if (_currentframe < _totalframes) {
nextFrame();
}
} else if (_currentframe > 1) {
prevFrame();
}
};
onRollOver = function () {
open = true;
};
onRollOut = function () {
delete open;
};
onDragOut = function () {
delete open;
};
Symbol 291 MovieClip Frame 1
gotoAndPlay (2);
Symbol 291 MovieClip Frame 2
if (_root.bgOn == "ON") {
bmd = new flash.display.BitmapData(800, 580, true, 0);
attachBitmap(bmd, 0);
if (grnLnd) {
i = 0;
while (i < (_root.bg_trees * 14)) {
attachMovie("bg_tree", "tree", 1, {_x:random(800), _y:580 + random(20), _xscale:80 + random(40), _yscale:70 + random(60)});
bmd.draw(this);
i++;
}
tree.removeMovieClip();
} else {
i = 0;
while (i < _root.bg_trees) {
attachMovie("bg_tree", "tree", 1, {_x:random(20) * 40, _y:580});
bmd.draw(this);
i++;
}
tree.removeMovieClip();
i = 0;
while (i < _root.bg_trees) {
attachMovie("bg_item", "item", 1, {_x:random(20) * 40, _y:580});
item.gotoAndStop(random(item._totalframes) + 1);
bmd.draw(this);
i++;
}
item.removeMovieClip();
}
} else {
_visible = false;
}
Symbol 291 MovieClip Frame 3
stop();