Frame 1
function getPage(theUrl, thePageName) {
if (_root.site == "master") {
getURL (((("javascript:void window.open('" + theUrl) + "', '") + thePageName) + "', 'scrollbars=yes,resizable=yes,width=500,height=500');");
} else {
getURL (theUrl, "_blank");
}
}
stop();
theDomain = "http://www.thekungfustatesmen.com/";
folder = "game/";
loadMovie ((theDomain + folder) + "/offsite.swf", _root.offsite);
Instance of Symbol 9 MovieClip in Frame 1
onClipEvent (enterFrame) {
loadPct = _root.getBytesLoaded() / _root.getBytesTotal();
gotoAndStop(int(_totalframes * loadPct));
if (loadPct == 1) {
_root.play();
} else {
_root.stop();
}
}
Instance of Symbol 17 MovieClip in Frame 1
onClipEvent (load) {
this.gotoAndStop(2);
}
Frame 2
stop();
Frame 6
stop();
Instance of Symbol 295 MovieClip in Frame 7
onClipEvent (load) {
this.gotoAndStop(_root.heroName);
}
Frame 47
stop();
Frame 66
stop();
Symbol 9 MovieClip Frame 1
stop();
Symbol 12 Button
on (release) {
stopAllSounds();
gotoAndStop (3);
_root.playSound = 0;
}
Symbol 16 Button
on (release) {
gotoAndStop (2);
_root.playSound = 1;
}
Symbol 17 MovieClip Frame 1
stop();
Symbol 33 MovieClip Frame 1
stop();
Symbol 51 Button
on (release) {
_root.getPage("http://www.killerviral.com/redir.php?urlId=2", "prize");
}
Symbol 53 Button
on (release) {
_root.getPage((_root.theDomain + _root.folder) + "highscores.php", "highscores");
}
Symbol 60 Button
on (release) {
_root.getPage("http://www.killerviral.com/redir.php?urlId=5", "prize");
}
Symbol 65 MovieClip Frame 1
stop();
Symbol 65 MovieClip Frame 6
stop();
Symbol 65 MovieClip Frame 10
stop();
Symbol 65 MovieClip Frame 15
stop();
Symbol 65 MovieClip Frame 19
stop();
Symbol 65 MovieClip Frame 24
stop();
Symbol 65 MovieClip Frame 28
stop();
Symbol 66 Button
on (rollOver) {
mcChoose.gotoAndPlay("chooseTony");
}
on (rollOut) {
mcChoose.gotoAndPlay("chooseTonyBack");
}
on (release) {
_root.heroName = "blair";
_parent.play();
}
Symbol 67 Button
on (rollOver) {
mcChoose.gotoAndPlay("chooseDavid");
}
on (rollOut) {
mcChoose.gotoAndPlay("chooseDavidBack");
}
on (release) {
_root.heroName = "blunkett";
_parent.play();
}
Symbol 68 Button
on (rollOver) {
mcChoose.gotoAndPlay("chooseGordon");
}
on (rollOut) {
mcChoose.gotoAndPlay("chooseGordonBack");
}
on (release) {
_root.heroName = "brown";
_parent.play();
}
Symbol 81 Button
on (release) {
getURL ("http://www.killerviral.com/redir.php?urlId=1", "_blank");
}
Symbol 82 MovieClip Frame 91
stop();
Symbol 92 MovieClip Frame 1
stop();
Symbol 99 MovieClip Frame 1
stop();
Symbol 110 MovieClip Frame 6
stop();
Symbol 111 MovieClip Frame 9
gotoAndPlay (1);
Symbol 119 MovieClip Frame 8
gotoAndPlay (1);
Symbol 124 MovieClip Frame 8
gotoAndPlay (1);
Symbol 129 MovieClip Frame 8
gotoAndPlay (1);
Symbol 135 MovieClip Frame 8
gotoAndPlay (1);
Symbol 141 MovieClip Frame 8
gotoAndPlay (1);
Symbol 146 MovieClip Frame 8
gotoAndPlay (1);
Symbol 151 MovieClip Frame 7
gotoAndPlay (1);
Symbol 159 MovieClip Frame 8
gotoAndPlay (1);
Symbol 162 MovieClip Frame 6
stop();
Symbol 163 MovieClip Frame 10
gotoAndPlay (1);
Symbol 168 MovieClip Frame 8
gotoAndPlay (1);
Symbol 170 MovieClip Frame 1
this._visible = 0;
Symbol 180 MovieClip Frame 39
_parent.resetVars(this);
Symbol 181 MovieClip Frame 1
played = 0;
Symbol 181 MovieClip Frame 9
gotoAndPlay ("waggle");
played++;
if (played == 10) {
_root.gotoAndStop("youwin");
}
Symbol 182 MovieClip Frame 1
stop();
Symbol 182 MovieClip Frame 2
stop();
Symbol 182 MovieClip Frame 3
stop();
Instance of Symbol 111 MovieClip "huntman1" in Symbol 183 MovieClip Frame 1
onClipEvent (load) {
movedir = "l";
speed = 4;
msgType = "hunting";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 119 MovieClip "dog1" in Symbol 183 MovieClip Frame 1
onClipEvent (load) {
movedir = "l";
speed = 6;
msgType = "hunting";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 124 MovieClip "batman1" in Symbol 183 MovieClip Frame 2
onClipEvent (load) {
movedir = "l";
speed = 6;
msgType = "fathers";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 129 MovieClip "spiderman1" in Symbol 183 MovieClip Frame 2
onClipEvent (load) {
movedir = "r";
speed = 4;
msgType = "fathers";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 135 MovieClip "protestman1" in Symbol 183 MovieClip Frame 3
onClipEvent (load) {
movedir = "r";
speed = 4;
msgType = "protest";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 141 MovieClip "protestgirl1" in Symbol 183 MovieClip Frame 3
onClipEvent (load) {
movedir = "r";
speed = 4;
msgType = "protest";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 146 MovieClip "dinnerlady1" in Symbol 183 MovieClip Frame 4
onClipEvent (load) {
movedir = "l";
speed = 4;
msgType = "jamie";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 151 MovieClip "foxy2" in Symbol 183 MovieClip Frame 4
onClipEvent (load) {
movedir = "r";
speed = 2;
msgType = "hunting";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 146 MovieClip "dinnerlady2" in Symbol 183 MovieClip Frame 5
onClipEvent (load) {
movedir = "l";
speed = 4;
msgType = "jamie";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 159 MovieClip "jamie1" in Symbol 183 MovieClip Frame 5
onClipEvent (load) {
movedir = "r";
speed = 2;
msgType = "jamie";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 129 MovieClip "spiderman2" in Symbol 183 MovieClip Frame 6
onClipEvent (load) {
movedir = "l";
speed = 5;
msgType = "fathers";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 124 MovieClip "batman2" in Symbol 183 MovieClip Frame 6
onClipEvent (load) {
movedir = "l";
speed = 6;
msgType = "fathers";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 141 MovieClip "protestgirl2" in Symbol 183 MovieClip Frame 6
onClipEvent (load) {
movedir = "r";
speed = 5;
msgType = "protest";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 111 MovieClip in Symbol 183 MovieClip Frame 7
onClipEvent (load) {
movedir = "l";
speed = 5;
msgType = "hunting";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 119 MovieClip "dog2" in Symbol 183 MovieClip Frame 7
onClipEvent (load) {
movedir = "r";
speed = 7;
msgType = "hunting";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 135 MovieClip "protestman2" in Symbol 183 MovieClip Frame 7
onClipEvent (load) {
movedir = "r";
speed = 6;
msgType = "protest";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 159 MovieClip in Symbol 183 MovieClip Frame 8
onClipEvent (load) {
movedir = "l";
speed = 7;
msgType = "jamie";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 163 MovieClip in Symbol 183 MovieClip Frame 8
onClipEvent (load) {
movedir = "d";
speed = 6;
msgType = "fathers";
offset = 37;
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 168 MovieClip in Symbol 183 MovieClip Frame 8
onClipEvent (load) {
movedir = "u";
speed = 6;
msgType = "fathers";
offset = 37;
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 124 MovieClip in Symbol 183 MovieClip Frame 9
onClipEvent (load) {
movedir = "l";
speed = 4;
msgType = "fathers";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 146 MovieClip in Symbol 183 MovieClip Frame 9
onClipEvent (load) {
movedir = "l";
speed = 8;
msgType = "jamie";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 151 MovieClip "foxy1" in Symbol 183 MovieClip Frame 9
onClipEvent (load) {
movedir = "l";
speed = 8;
msgType = "hunting";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 135 MovieClip in Symbol 183 MovieClip Frame 10
onClipEvent (load) {
movedir = "r";
speed = 6;
msgType = "protest";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 129 MovieClip in Symbol 183 MovieClip Frame 10
onClipEvent (load) {
movedir = "l";
speed = 4;
msgType = "fathers";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 141 MovieClip in Symbol 183 MovieClip Frame 10
onClipEvent (load) {
movedir = "l";
speed = 5;
msgType = "protest";
}
onClipEvent (enterFrame) {
_parent.moveme(this);
}
Instance of Symbol 182 MovieClip in Symbol 183 MovieClip Frame 11
onClipEvent (load) {
function resetVars(t) {
speed = (Math.random() * 5) + 5;
this.stunned = 0;
this.gotoAndStop("walk");
}
movedir = "l";
speed = 5;
msgType = "boris";
bossLives = 5;
}
onClipEvent (enterFrame) {
_parent.bossMove(this);
}
Symbol 194 MovieClip Frame 1
stop();
Symbol 194 MovieClip Frame 22
_parent.attacking = 0;
Symbol 203 MovieClip Frame 11
stop();
Symbol 203 MovieClip Frame 18
stop();
Symbol 204 MovieClip Frame 11
stop();
Symbol 204 MovieClip Frame 18
stop();
Symbol 207 MovieClip Frame 10
_parent._parent.showMsg(_parent);
stop();
Symbol 209 MovieClip Frame 15
_parent.dying = 0;
_parent.dead = 0;
Symbol 210 MovieClip Frame 1
stop();
Symbol 224 MovieClip Frame 1
stop();
Symbol 224 MovieClip Frame 22
_parent.attacking = 0;
Symbol 226 MovieClip Frame 5
stop();
Symbol 226 MovieClip Frame 12
stop();
Symbol 227 MovieClip Frame 10
_parent._parent.showMsg(_parent);
stop();
Symbol 228 MovieClip Frame 15
_parent.dying = 0;
_parent.dead = 0;
Symbol 229 MovieClip Frame 1
stop();
Symbol 238 MovieClip Frame 1
stop();
Symbol 238 MovieClip Frame 22
_parent.attacking = 0;
Symbol 240 MovieClip Frame 5
stop();
Symbol 240 MovieClip Frame 12
stop();
Symbol 241 MovieClip Frame 10
_parent._parent.showMsg(_parent);
stop();
Symbol 242 MovieClip Frame 15
_parent.dying = 0;
_parent.dead = 0;
Symbol 243 MovieClip Frame 1
stop();
Symbol 248 MovieClip Frame 1
stop();
Symbol 248 MovieClip Frame 7
this._visible = 0;
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 1
onClipEvent (load) {
id = 3;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 1
onClipEvent (load) {
id = 2;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 1
onClipEvent (load) {
id = 1;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 2
onClipEvent (load) {
id = 5;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 2
onClipEvent (load) {
id = 4;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 2
onClipEvent (load) {
id = 6;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 3
onClipEvent (load) {
id = 7;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 3
onClipEvent (load) {
id = 8;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 4
onClipEvent (load) {
id = 9;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 4
onClipEvent (load) {
id = 10;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 5
onClipEvent (load) {
id = 11;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 5
onClipEvent (load) {
id = 12;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 6
onClipEvent (load) {
id = 13;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 6
onClipEvent (load) {
id = 14;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 7
onClipEvent (load) {
id = 15;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 7
onClipEvent (load) {
id = 16;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 8
onClipEvent (load) {
id = 18;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 8
onClipEvent (load) {
id = 17;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 9
onClipEvent (load) {
id = 19;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 9
onClipEvent (load) {
id = 21;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 9
onClipEvent (load) {
id = 20;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 10
onClipEvent (load) {
id = 22;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 10
onClipEvent (load) {
id = 27;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 10
onClipEvent (load) {
id = 26;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 10
onClipEvent (load) {
id = 23;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 10
onClipEvent (load) {
id = 24;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 10
onClipEvent (load) {
id = 25;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Instance of Symbol 248 MovieClip in Symbol 249 MovieClip Frame 11
onClipEvent (load) {
id = 28;
if (_parent.itemlist[id] == 0) {
this._visible = 0;
}
}
onClipEvent (enterFrame) {
if (_parent.itemlist[id] != 0) {
_parent.checkitem(this);
}
}
Symbol 251 MovieClip Frame 1
this._visible = 0;
Symbol 265 MovieClip Frame 1
stop();
Symbol 265 MovieClip Frame 2
stop();
Symbol 265 MovieClip Frame 3
stop();
Symbol 283 MovieClip Frame 1
stop();
Symbol 283 MovieClip Frame 2
stop();
Instance of Symbol 265 MovieClip in Symbol 283 MovieClip Frame 2
onClipEvent (load) {
this.gotoAndStop(_root.heroName);
}
Symbol 283 MovieClip Frame 3
stop();
Symbol 283 MovieClip Frame 4
stop();
Symbol 283 MovieClip Frame 5
stop();
Symbol 283 MovieClip Frame 6
stop();
Symbol 283 MovieClip Frame 7
stop();
Symbol 285 MovieClip Frame 1
stop();
Instance of Symbol 283 MovieClip in Symbol 285 MovieClip Frame 7
onClipEvent (load) {
this.gotoAndStop(_parent.msgType);
}
Instance of Symbol 283 MovieClip in Symbol 285 MovieClip Frame 49
onClipEvent (load) {
this.gotoAndStop(_parent.msgType);
}
Symbol 285 MovieClip Frame 54
_parent.onDeath(_parent.hero);
Symbol 294 MovieClip Frame 1
function pcSetVars(t) {
var _local1 = t;
for (var _local2 in pcVars) {
_local1[_local2] = pcVars[_local2];
}
_local1.leftKey = 37;
_local1.rightKey = 39;
_local1.jumpKey = 38;
_local1.attackKey = 32;
}
function resetVars(t) {
var _local1 = t;
_local1.dead = 1;
_local1.attackclip.gotoAndStop(1);
_local1.attacking = 0;
_local1.jumping = 0;
_local1.yVel = 0;
}
function removeHero(t) {
var _local3 = t;
var _local2 = 0;
var _local1 = 1000;
while (_local2 != 1) {
if (!getInstanceAtDepth(1000)) {
_local3.swapDepths(_local1);
_local2 = 1;
_local3.removeMovieClip();
}
_local1++;
}
}
function createHero(t) {
var _local1 = t;
_local1.duplicateMovieClip("hero", _local1.getNextHighestDepth());
_local1._parent.hero.swapDepths(_local1);
moveToStart(_local1._parent.hero);
removeHero(_local1);
}
stop();
scrLeft = scrLeft._x;
scrRight = scrRight._x;
scrBottom = scrBottom._y;
theFloor = theFloor._y;
ceiling = ceiling._y;
grav = 1;
numRooms = 11;
totalitems = 28;
itemlist = new Array();
starttime = getTimer();
bgs = 11;
pcVars = new Object();
pcVars.currRoom = 1;
pcVars.score = 0;
pcVars.issues = 0;
pcVars.lives = 5;
pcVars.dead = 0;
pcVars.speed = 7;
pcVars.yOffset = 28;
pcVars.xOffset = 16;
pcVars.yVel = 0;
pcVars.tVel = 11;
pcVars.jumping = 0;
pcVars.dir = 0;
pcVars.jumpSpeed = 12;
function setroom(room) {
var _local1 = room;
backgrounds.gotoAndStop(_local1);
floors.gotoAndStop(_local1);
enemies.gotoAndStop(_local1);
walls.gotoAndStop(_local1);
pickup.gotoAndStop(_local1);
bgs.gotoAndStop(_local1);
startpoints.gotoAndStop(_local1);
}
function change_room(t) {
var _local1 = t;
if (_local1.dir > 0) {
newXpos = scrLeft + 10;
} else {
newXpos = scrRight - 10;
}
_local1.currRoom = _local1.currRoom + _local1.dir;
setroom(_local1.currRoom);
return(newXpos);
}
function showMsg(t) {
messages.play();
}
function saveScores(t) {
var _local1 = t;
var _local2 = _root;
_local2.lives = _local1.lives;
_local2.score = _local1.score;
_local2.issues = _local1.issues;
}
function pcCode(t) {
var _local1 = t;
if (_local1.dead && (!_local1.dying)) {
_local1.gotoAndStop("death");
_local1.dying = 1;
} else if ((!_local1.dead) && (!_local1.paused)) {
checkKeys(_local1);
var _local3 = _local1._x + (_local1.dir * _local1.speed);
var _local2 = _local1._y + _local1.yVel;
if (_local1.yVel < _local1.tVel) {
_local1.yVel = _local1.yVel + grav;
}
if (_local1.yVel > 0) {
_local2 = checkFloors(_local1, _local2);
}
_local3 = checkWalls(_local1, _local3, _local2);
if (_local1.dir != 0) {
_local1._x = _local3;
_local1._xscale = 100 * _local1.dir;
}
_local1._y = _local2;
if (_local1.attacking) {
_local1.attackclip.play();
} else if ((_local1.dir != 0) && (!_local1.jumping)) {
_local1.gotoAndStop("walk");
} else if (_local1.jumping) {
_local1.gotoAndStop("jump");
} else {
_local1.gotoAndStop("stand");
}
if (_local1._y > (scrBottom + _local1.yOffset)) {
_local1.dead = 1;
messages.msgType = "fallout";
}
}
}
function onDeath(t) {
var _local1 = t;
_local1.lives = _local1.lives - 1;
if (_local1.lives == 0) {
saveScores(_local1);
_parent.gotoAndPlay("gameover");
} else {
if (_local1.currRoom > 1) {
_local1.currRoom = _local1.currRoom - 1;
setroom(_local1.currRoom);
}
moveToStart(_local1);
}
}
function moveToStart(t) {
var _local1 = t;
_local1.gotoAndStop("rebirth");
_local1._x = startpoints.start._x;
_local1._y = startpoints.start._y;
}
function checkWalls(t, newXpos, newYpos) {
var _local1 = newXpos;
var _local2 = t;
var _local3 = newYpos;
if ((_local2.currRoom == 1) && (_local1 <= scrLeft)) {
_local1 = scrLeft;
} else if ((_local2._x <= scrLeft) && (_local2.dir < 0)) {
_local1 = change_room(_local2, _local1);
}
if ((_local2.currRoom == numRooms) && (_local1 >= scrRight)) {
_local1 = scrRight;
} else if ((_local1 >= scrRight) && (_local2.dir > 0)) {
_local1 = change_room(_local2, _local1);
}
if (walls.hitTest(_local1 - _local2.xOffset, _local3 + (_local2.yOffset - 5), true)) {
var i = 0;
while (walls.hitTest(_local1 - _local2.xOffset, _local3 + (_local2.yOffset - 5), true)) {
_local1 = _local1 + 1;
}
}
if (walls.hitTest(_local1 + _local2.xOffset, _local3 + (_local2.yOffset - 5), true)) {
var i = 0;
while (walls.hitTest(_local1 + _local2.xOffset, _local3 + (_local2.yOffset - 5), true)) {
_local1 = _local1 - 1;
}
}
return(_local1);
}
function checkFloors(t, newYpos) {
var _local1 = t;
var _local2 = newYpos;
if (floors.hitTest(_local1._x, _local2 + _local1.yOffset, true)) {
_local2 = _local1._y - _local1.tVel;
var _local3 = 0;
while (!floors.hitTest(_local1._x, _local2 + _local1.yOffset, true)) {
_local2 = _local2 + 1;
}
_local2 = _local2 - 1;
_local1.yVel = 0;
_local1.jumping = 0;
}
return(_local2);
}
function checkKeys(t) {
var _local1 = t;
if (Key.isDown(_local1.rightKey) || (Key.isDown(_local1.leftKey))) {
_local1.dir = Key.isDown(_local1.rightKey) - Key.isDown(_local1.leftKey);
} else {
_local1.dir = 0;
}
if (((!_local1.jumping) && (_local1.yVel == 0)) && (Key.isDown(_local1.jumpKey))) {
_local1.jumping = 1;
_local1.yVel = -_local1.jumpSpeed;
}
if ((!_local1.attacking) && (Key.isDown(_local1.attackKey))) {
_local1.attacking = 1;
}
}
Instance of Symbol 183 MovieClip "enemies" in Symbol 294 MovieClip Frame 1
onClipEvent (load) {
function moveme(t) {
var _local1 = t;
var _local2 = _parent;
if (!_local1.dead) {
if (_local1.hitTest(_local2.hero.attackclip.hitarea)) {
_local1.gotoAndStop("die");
_local1.dead = 1;
_local2.hero.issues = _local2.hero.issues + 1;
} else if (_local1.hitTest(_local2.hero.hitarea)) {
_local2.resetVars(_local2.hero);
_local2.messages.msgType = _local1.msgType;
}
moveCalc(_local1);
} else {
_local1.gotoAndStop("die");
}
}
function bossMove(t) {
var _local1 = t;
var _local2 = _parent;
if ((_local1.bossLives > 0) && (!_local1.stunned)) {
if (_local1.hitTest(_local2.hero.attackclip.hitarea)) {
_local1.gotoAndStop("scratch");
_local1.bossLives = _local1.bossLives - 1;
_local1.speed = 0;
_local1.stunned = 1;
_local2.hero.issues = _local2.hero.issues + 1;
} else if (_local1.hitarea.hitTest(_local2.hero.hitarea)) {
_local2.resetVars(_local2.hero);
_local2.messages.msgType = _local1.msgType;
}
moveCalc(_local1);
} else if (_local1.bossLives < 1) {
_local1.gotoAndStop("die");
_root.bonus = 100;
_local2.saveScores(_local2.hero);
_local2.hero.paused = 1;
} else {
_local1.gotoAndStop("scratch");
}
}
function moveCalc(t) {
var _local1 = t;
var _local2 = _parent;
if (_local1.movedir == "l") {
_local1._x = _local1._x - _local1.speed;
_local1._xscale = 100;
if (_local1._x < (_local2.scrLeft + 20)) {
_local1.movedir = "r";
}
}
if (_local1.movedir == "r") {
_local1._x = _local1._x + _local1.speed;
_local1._xscale = -100;
if (_local1._x > (_local2.scrRight - 20)) {
_local1.movedir = "l";
}
}
if (_local1.movedir == "u") {
_local1._y = _local1._y - _local1.speed;
if ((_local1._y - _local1.offset) < _local2.ceiling) {
_local1.movedir = "d";
}
}
if (_local1.movedir == "d") {
_local1._y = _local1._y + _local1.speed;
if ((_local1._y + _local1.offset) > _local2.theFloor) {
_local1.movedir = "u";
}
}
}
this.stop();
}
Instance of Symbol 210 MovieClip "blunkers" in Symbol 294 MovieClip Frame 1
onClipEvent (load) {
if (_root.heroName != "blunkett") {
_parent.removeHero(this);
} else if (this._name != "hero") {
_parent.createHero(this);
}
id = 1;
_parent.pcSetVars(this);
}
onClipEvent (enterFrame) {
_parent.pcCode(this);
}
Instance of Symbol 229 MovieClip "blair" in Symbol 294 MovieClip Frame 1
onClipEvent (load) {
if (_root.heroName != "blair") {
_parent.removeHero(this);
} else if (this._name != "hero") {
_parent.createHero(this);
}
id = 2;
_parent.pcSetVars(this);
}
onClipEvent (enterFrame) {
_parent.pcCode(this);
}
Instance of Symbol 243 MovieClip "brown" in Symbol 294 MovieClip Frame 1
onClipEvent (load) {
if (_root.heroName != "brown") {
_parent.removeHero(this);
} else if (this._name != "hero") {
_parent.createHero(this);
}
id = 3;
_parent.pcSetVars(this);
}
onClipEvent (enterFrame) {
_parent.pcCode(this);
}
Instance of Symbol 249 MovieClip "pickup" in Symbol 294 MovieClip Frame 1
onClipEvent (load) {
function checkitem(t) {
var _local1 = t;
if (_local1.hitTest(_parent.hero.hitarea)) {
_local1.play();
_parent.hero.score = _parent.hero.score + 1;
itemlist[_local1.id] = 0;
}
}
function checksunny(t) {
var _local1 = _parent;
if (t.hitTest(_local1.hero)) {
if (_local1.hero.score == _local1.totalitems) {
_local1.gotoAndPlay("youwin");
} else {
t.gotoAndStop(2);
}
}
}
itemlist = _parent.itemlist;
this.stop();
}
Instance of Symbol 251 MovieClip "ceiling" in Symbol 294 MovieClip Frame 1
onClipEvent (load) {
this._visible = 0;
}
Instance of Symbol 252 MovieClip "startpoints" in Symbol 294 MovieClip Frame 1
onClipEvent (load) {
this.stop();
}
Instance of Symbol 287 MovieClip in Symbol 294 MovieClip Frame 1
onClipEvent (load) {
text1 = " OF ";
text2 = " PAGES RECOVERED";
currentscore = -1;
}
onClipEvent (enterFrame) {
if (currentscore != _parent.hero.score) {
this.score = ((_parent.hero.score + text1) + _parent.totalitems) + text2;
}
}
Instance of Symbol 289 MovieClip in Symbol 294 MovieClip Frame 1
onClipEvent (load) {
text1 = " SECS";
starttime = _parent.starttime;
}
onClipEvent (enterFrame) {
var currenttime = Math.floor((getTimer() - starttime) / 1000);
if (_root.gameTime != currenttime) {
this.gameTime = currenttime + text1;
_root.gameTime = currenttime;
}
}
Instance of Symbol 291 MovieClip in Symbol 294 MovieClip Frame 1
onClipEvent (load) {
text1 = " SWING SEATS REMAINING";
}
onClipEvent (enterFrame) {
if (currentLives != _parent.hero.lives) {
currentLives = _parent.hero.lives;
this.lives = currentLives + text1;
}
}
Instance of Symbol 293 MovieClip in Symbol 294 MovieClip Frame 1
onClipEvent (load) {
text1 = " ISSUES BURIED";
}
onClipEvent (enterFrame) {
if (currIssues != _parent.hero.issues) {
currIssues = _parent.hero.issues;
this.issues = currIssues + text1;
}
}
Symbol 300 MovieClip Frame 1
stop();
Symbol 300 MovieClip Frame 2
stop();
Symbol 300 MovieClip Frame 3
stop();
Symbol 308 MovieClip Frame 1
function fillVals() {
var _local1 = this;
var _local2 = _root;
_local1.gameTime = _local1.gameTime + _local2.gameTime;
_local1.score = _local1.score + _local2.score;
_local1.issues = _local1.issues + _local2.issues;
if (_local2.bonus) {
_local1.bonus = _local1.bonus + _local2.bonus;
} else {
_local1.bonus = "";
_local2.bonus = 0;
}
_local1.buildScore();
_local1.finalscore = _local1.finalscore + _local2.a;
}
function challenge() {
var _local1 = _root;
buildURL();
_local1.getPage(((_local1.theDomain + _local1.folder) + "challenge.php") + sendVar, "challenge");
}
function enterComp() {
var _local1 = _root;
buildURL();
_local1.getPage(((_local1.theDomain + _local1.folder) + "competition.php") + sendVar, "challenge");
}
function buildScore() {
var _local1 = _root;
var _local2 = ((1 / Math.sqrt(_local1.gameTime)) * _local1.score) * 1000;
_local1.a = (Math.round(_local2) + (_local1.issues * 10)) + _local1.bonus;
_local1.b = Math.floor(Math.pow(Math.log(Math.atan2(19.81, _local1.a)), 8));
}
function buildURL() {
sendVar = base64_encode(((("Teflon" + _root.a) + ",") + _root.b) + "Tony");
sendVar = "?sessId=" + sendVar;
}
function b64arrays() {
b64s = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
b64 = new Array();
f64 = new Array();
i = 0;
while (i < b64s.length) {
b64[i] = b64s.charAt(i);
f64[b64s.charAt(i)] = i;
i++;
}
}
function utf8t2d(t) {
var _local1 = new Array();
var test = String.fromCharCode(237);
if (test.charCodeAt(0) < 0) {
var _local3 = 0;
while (_local3 < t.length) {
var _local2 = t.charCodeAt(_local3);
if (_local2 > 0) {
_local1[_local1.length] = _local2;
} else {
_local1[_local1.length] = ((256 + _local2) >> 6) | 192;
_local1[_local1.length] = ((256 + _local2) & 63) | 128;
}
_local3++;
}
} else {
var _local3 = 0;
while (_local3 < t.length) {
var _local2 = t.charCodeAt(_local3);
if (_local2 < 128) {
_local1[_local1.length] = _local2;
} else if ((_local2 > 127) && (_local2 < 2048)) {
_local1[_local1.length] = (_local2 >> 6) | 192;
_local1[_local1.length] = (_local2 & 63) | 128;
} else {
_local1[_local1.length] = (_local2 >> 12) | 224;
_local1[_local1.length] = ((_local2 >> 6) & 63) | 128;
_local1[_local1.length] = (_local2 & 63) | 128;
}
_local3++;
}
}
return(_local1);
}
function b64d2t(d) {
var _local3 = d;
var _local1 = new Array();
var _local2 = 0;
var dl = _local3.length;
if ((dl % 3) == 1) {
_local3[_local3.length] = 0;
}
_local3[_local3.length] = 0;
if ((dl % 3) == 2) {
_local3[_local3.length] = 0;
}
while (_local2 < _local3.length) {
_local1[_local1.length] = b64[_local3[_local2] >> 2];
_local1[_local1.length] = b64[((_local3[_local2] & 3) << 4) | (_local3[_local2 + 1] >> 4)];
_local1[_local1.length] = b64[((_local3[_local2 + 1] & 15) << 2) | (_local3[_local2 + 2] >> 6)];
_local1[_local1.length] = b64[_local3[_local2 + 2] & 63];
if ((_local2 % 57) == 54) {
_local1[_local1.length] = newline;
}
_local2 = _local2 + 3;
}
if ((dl % 3) == 1) {
_local1[_local1.length - 1] = (_local1[_local1.length - 2] = "=");
}
if ((dl % 3) == 2) {
_local1[_local1.length - 1] = "=";
}
var t = _local1.join("");
return(t);
}
function base64_encode(str) {
b64arrays();
return(b64d2t(utf8t2d(str)));
}
fillVals();
Symbol 312 Button
on (release) {
_root.getPage("http://www.killerviral.com/redir.php?urlId=2", "prize");
}
Symbol 314 Button
on (release) {
scoreBoard.enterComp();
}
Symbol 316 Button
on (release) {
_root.gotoAndPlay("startpage");
}
Symbol 317 Button
on (release) {
scoreBoard.challenge();
}
Instance of Symbol 300 MovieClip in Symbol 318 MovieClip Frame 1
onClipEvent (load) {
this.gotoAndStop(_root.heroName);
}
Symbol 318 MovieClip Frame 32
stop();
Instance of Symbol 300 MovieClip in Symbol 326 MovieClip Frame 1
onClipEvent (load) {
this.gotoAndStop(_root.heroName);
}
Symbol 326 MovieClip Frame 32
stop();