Frame 1
MochiAd.showPreGameAd({id:"1cb719e31683f5f2", res:"600x450"});
Frame 2
function __com_mochibot__(swfid, mc, lv, trk) {
var x;
var g;
var s;
var fv;
var sb;
var u;
var res;
var mb;
var mbc;
var pv;
mb = "__mochibot__";
mbc = "mochibot.com";
g = (_global ? (_global) : (_level0._root));
if (g[mb + swfid]) {
return(g[mb + swfid]);
}
s = System.security;
x = mc._root.getSWFVersion;
fv = (x ? (mc.getSWFVersion()) : ((_global ? 6 : 5)));
if (!s) {
s = {};
}
sb = s.sandboxType;
if (sb == "localWithFile") {
return(null);
}
x = s.allowDomain;
if (x) {
s.allowDomain(mbc);
}
x = s.allowInsecureDomain;
if (x) {
s.allowInsecureDomain(mbc);
}
pv = ((fv == 5) ? (getVersion()) : (System.capabilities.version));
u = (((((((((((("http://" + mbc) + "/my/core.swf?mv=8&fv=") + fv) + "&v=") + escape(pv)) + "&swfid=") + escape(swfid)) + "&l=") + lv) + "&f=") + mc) + (sb ? ("&sb=" + sb) : "")) + (trk ? "&t=1" : "");
lv = ((fv > 6) ? (mc.getNextHighestDepth()) : ((g[mb + "level"] ? (g[mb + "level"] + 1) : (lv))));
g[mb + "level"] = lv;
if (fv == 5) {
res = "_level" + lv;
if (!eval (res)) {
loadMovieNum (u, lv);
}
} else {
res = mc.createEmptyMovieClip(mb + swfid, lv);
res.loadMovie(u);
}
return(res);
}
__com_mochibot__("aea57add", this, 10301, true);
function itemHandler1(obj, item) {
getURL ("http://seditiongames.newgrounds.com/");
}
function itemHandler2(obj, item) {
_root.Game.removeMovieClip();
_root.BackGround.removeMovieClip();
gotoAndPlay (502);
}
function itemHandler3(obj, item) {
if (_root.Pause == true) {
_root.Pause = false;
} else {
_root.Pause = true;
}
}
function itemHandler4(obj, item) {
_quality = "LOW";
}
function itemHandler5(obj, item) {
_quality = "MEDIUM";
}
function itemHandler6(obj, item) {
_quality = "HIGH";
}
function itemHandler7(obj, item) {
_root.faggy_Sound.setVolume(100);
_root.sword_Sound.setVolume(100);
_root.boing_Sound.setVolume(100);
_root.lightning_Sound.setVolume(100);
_root.pickup1_Sound.setVolume(100);
_root.Scream_Sound.setVolume(100);
_root.shuriken_Sound.setVolume(100);
_root.m16_Sound.setVolume(100);
_root.mscream_Sound.setVolume(100);
_root.slash_Sound.setVolume(100);
_root.punch2.setVolume(100);
_root.killplant_Sound.setVolume(100);
_root.jump_Sound.setVolume(100);
_root.explode_Sound.setVolume(100);
_root.Spooks_Sound.setVolume(100);
_root.baddies_Sound.setVolume(100);
}
function itemHandler8(obj, item) {
_root.faggy_Sound.setVolume(0);
_root.Spooks_Sound.setVolume(0);
_root.sword_Sound.setVolume(0);
_root.boing_Sound.setVolume(0);
_root.lightning_Sound.setVolume(0);
_root.pickup1_Sound.setVolume(0);
_root.Scream_Sound.setVolume(0);
_root.shuriken_Sound.setVolume(0);
_root.m16_Sound.setVolume(0);
_root.mscream_Sound.setVolume(0);
_root.slash_Sound.setVolume(0);
_root.punch2.setVolume(0);
_root.killplant_Sound.setVolume(0);
_root.jump_Sound.setVolume(0);
_root.explode_Sound.setVolume(0);
_root.baddies_Sound.setVolume(0);
}
var myMenu = new ContextMenu();
myMenu.hideBuiltInItems();
item1 = new ContextMenuItem("...more from Sedition Games", itemHandler1);
myMenu.customItems.push(item1);
_root.menu = myMenu;
item2 = new ContextMenuItem("Restart", itemHandler2);
myMenu.customItems.push(item2);
_root.menu = myMenu;
item3 = new ContextMenuItem("Pause", itemHandler3);
myMenu.customItems.push(item3);
_root.menu = myMenu;
item4 = new ContextMenuItem("Quality: Low", itemHandler4);
myMenu.customItems.push(item4);
_root.menu = myMenu;
item5 = new ContextMenuItem("Quality: Medium", itemHandler5);
myMenu.customItems.push(item5);
_root.menu = myMenu;
item6 = new ContextMenuItem("Quality: High", itemHandler6);
myMenu.customItems.push(item6);
_root.menu = myMenu;
item7 = new ContextMenuItem("Sound: ON", itemHandler7);
myMenu.customItems.push(item7);
_root.menu = myMenu;
item8 = new ContextMenuItem("Sound: OFF", itemHandler8);
myMenu.customItems.push(item8);
_root.menu = myMenu;
savefile = SharedObject.getLocal("Samurai");
var song_Sound = new Sound();
song_Sound.attachSound("song_Sound");
var Spooks_Sound = new Sound();
Spooks_Sound.attachSound("Spooks_Sound");
var faggy_Sound = new Sound();
faggy_Sound.attachSound("faggy_Sound");
var mscream_Sound = new Sound();
mscream_Sound.attachSound("mscream_Sound");
var jump_Sound = new Sound();
jump_Sound.attachSound("jump_Sound");
var explode_Sound = new Sound();
explode_Sound.attachSound("explode_Sound");
var killplant_Sound = new Sound();
killplant_Sound.attachSound("killplant_Sound");
var punch2_Sound = new Sound();
punch2_Sound.attachSound("punch2_Sound");
var slash_Sound = new Sound();
slash_Sound.attachSound("slash_Sound");
var boing_Sound = new Sound();
boing_Sound.attachSound("boing_Sound");
var lightning_Sound = new Sound();
lightning_Sound.attachSound("lightning_Sound");
var m16_Sound = new Sound();
m16_Sound.attachSound("m16_Sound");
var pickup1_Sound = new Sound();
pickup1_Sound.attachSound("pickup1_Sound");
var Scream_Sound = new Sound();
Scream_Sound.attachSound("Scream_Sound");
var shuriken_Sound = new Sound();
shuriken_Sound.attachSound("shuriken_Sound");
var sword_Sound = new Sound();
sword_Sound.attachSound("sword_Sound");
var baddies_Sound = new Sound();
baddies_Sound.attachSound("baddies_Sound");
_root.Spooks_Sound.start();
ButtonX.onRelease = function () {
gotoAndPlay (502);
};
Frame 256
_root.Spooks_Sound.stop();
_root.baddies_Sound.start();
Frame 502
_root.killplant_Sound.start();
_root.baddies_Sound.stop();
_root.Spooks_Sound.start();
_root.Spooks_Sound.onSoundComplete = function () {
_root.Spooks_Sound.start();
};
Frame 515
stop();
_root.TotalKills = 0;
_root.TotalDeaths = 0;
_root.Level = 1;
_root.Armour = 1;
_quality = "MEDIUM";
Button1.onRelease = function () {
gotoAndPlay (516);
_root.killplant_Sound.start();
};
Button2.onRelease = function () {
_root.Level = _root.savefile.data.Level;
_root.killplant_Sound.start();
_root.TotalDeaths = _root.savefile.data.TotalDeaths;
_root.TotalKills = _root.savefile.data.TotalKills;
if (Boolean(_root.Level) == false) {
_root.Level = 1;
}
gotoAndPlay (517);
};
Button3.onRelease = function () {
};
Frame 516
stop();
Button1.onRelease = function () {
_root.killplant_Sound.start();
gotoAndPlay (517);
};
Frame 517
stop();
Button1.onRelease = function () {
_root.killplant_Sound.start();
_root.Spooks_Sound.stop();
_root.song_Sound.start();
gotoAndPlay (518);
};
Frame 518
if (_root.Armour < 1) {
_root.Armour = 1;
}
_root.savefile.data.Level = _root.Level;
_root.savefile.data.TotalDeaths = _root.TotalDeaths;
_root.savefile.data.TotalKills = _root.TotalKills;
_root.savefile.flush();
gotoAndPlay (519);
Frame 519
stop();
_root.FinishGame = false;
PlayerFrameNumber = 2;
PlayerDirection = "Left";
PlayerAttacking = false;
PlayerCount = 0;
PlayerAttackTime = 11;
ymax = 12;
xspeed = 0;
xmax = 15;
Inertia = 0.95;
JumpHeight = 30;
HoldUpKey = false;
PlayerHeight = 120;
_root.Player_xOffset = 0;
_root.InvincibleTimer = 0;
_root.Player_yspeed = 0;
_root.TileWidth = 400;
_root.Pause = false;
_root.Gravity = 1;
_root.Jumped = false;
_root.ScrollAmount = 0;
_root.Scrollx = 0;
_root.Scrolling = 0;
_root.yScrolling = 0;
LeftKey = 37;
RightKey = 39;
UpKey = 38;
PauseKey = 13;
AttackKey = 32;
_root.DieStatus = "Fall";
DieCount = 0;
PlayerDead = false;
LevelGraphicsObject = new Object();
FlameOb = new Object();
_root.id = 0;
_root.attachMovie("BackGround" + _root.Level, "BackGround", _root.id, LevelGraphicsObject);
_root.id++;
_root.attachMovie("Stage" + _root.Level, "Game", _root.id, LevelGraphicsObject);
_root.attachMovie("FadeBlack", "FadeBlack", 10000);
if (_root.Level == 11) {
_root.StartFloor = 17;
_root.FloorNumber = 35;
_root.yLimit = -88;
} else if (_root.Level == 21) {
_root.StartFloor = 2;
_root.FloorNumber = 16;
_root.yLimit = -70;
} else if (_root.Level == 22) {
_root.StartFloor = 2;
_root.FloorNumber = 13;
_root.yLimit = -70;
} else if (_root.Level == 23) {
_root.StartFloor = 2;
_root.FloorNumber = 13;
_root.yLimit = -167;
} else if (_root.Level == 31) {
_root.StartFloor = 2;
_root.FloorNumber = 27;
_root.yLimit = -70;
} else if (_root.Level == 32) {
_root.StartFloor = 2;
_root.FloorNumber = 20;
_root.yLimit = -70;
} else if (_root.Level == 33) {
_root.StartFloor = 5;
_root.FloorNumber = 8;
_root.yLimit = -45;
} else if (_root.Level == 43) {
_root.StartFloor = 2;
_root.FloorNumber = 10;
_root.yLimit = -9;
} else if (_root.Level == 44) {
_root.StartFloor = 2;
_root.FloorNumber = 28;
_root.yLimit = -102;
} else if (_root.Level == 45) {
_root.StartFloor = 5;
_root.FloorNumber = 8;
_root.yLimit = -50;
} else if (_root.Level == 50) {
_root.StartFloor = 8;
_root.FloorNumber = 20;
_root.yLimit = -120;
} else if (_root.Level == 70) {
_root.StartFloor = 2;
_root.FloorNumber = 20;
_root.yLimit = -120;
} else if (_root.Level == 60) {
_root.StartFloor = 7;
_root.FloorNumber = 11;
_root.yLimit = -120;
} else if (_root.Level == 80) {
_root.StartFloor = 2;
_root.FloorNumber = 5;
_root.yLimit = -120;
}
i = 1;
while (i < (_root.FloorNumber + 1)) {
_root.Game.BackObjects["BackObject" + i]._visible = false;
_root.Game.ForeObjects["ForeObject" + i]._visible = false;
_root.Game.Ground["Floor" + i]._visible = false;
i++;
}
SoundUP = function () {
if (((_root.Level == 43) || (_root.Level == 60)) || (_root.Level == 70)) {
_root.song_Sound.stop();
_root.faggy_Sound.start();
} else if (_root.Level == 80) {
_root.faggy_Sound.stop();
_root.song_Sound.start();
}
};
Middle = _root.StartFloor;
OldMiddle = Middle;
_root.ScrollAmount = _root.TileWidth * _root.StartFloor;
_root.Game.BackObjects["BackObject" + _root.StartFloor]._visible = true;
_root.Game.BackObjects["BackObject" + (_root.StartFloor + 1)]._visible = true;
_root.Game.BackObjects["BackObject" + (_root.StartFloor - 1)]._visible = true;
_root.Game.ForeObjects["ForeObject" + _root.StartFloor]._visible = true;
_root.Game.ForeObjects["ForeObject" + (_root.StartFloor + 1)]._visible = true;
_root.Game.ForeObjects["ForeObject" + (_root.StartFloor - 1)]._visible = true;
_root.Game.Ground["Floor" + _root.StartFloor]._visible = true;
_root.Game.Ground["Floor" + (_root.StartFloor + 1)]._visible = true;
_root.Game.Ground["Floor" + (_root.StartFloor - 1)]._visible = true;
_root.Game.Player.Arm1.gotoAndPlay(_root.Armour);
_root.Game.Player.Arm2.gotoAndPlay(_root.Armour);
_root.Game.Player.Leg1.gotoAndPlay(_root.Armour);
_root.Game.Player.Leg2.gotoAndPlay(_root.Armour);
_root.Game.Player.Head.gotoAndPlay(_root.Armour);
_root.Game.Player.Body.gotoAndPlay(_root.Armour);
if (_root.Armour > 1) {
_root.Game.Player.Face.gotoAndPlay(2);
}
_root.Game.Player.Weapon.gotoAndPlay(_root.Armour);
_root.song_Sound.onSoundComplete = function () {
_root.song_Sound.start();
};
_root.faggy_Sound.onSoundComplete = function () {
_root.faggy_Sound.start();
};
ViewTiles = function () {
OldMiddle = Middle;
Middle = Math.floor(_root.ScrollAmount / _root.TileWidth);
if (Middle > OldMiddle) {
_root.Game.Ground["Floor" + (Middle - 2)]._visible = false;
_root.Game.Ground["Floor" + (Middle + 1)]._visible = true;
_root.Game.BackObjects["BackObject" + (Middle - 2)]._visible = false;
_root.Game.BackObjects["BackObject" + (Middle + 1)]._visible = true;
_root.Game.ForeObjects["ForeObject" + (Middle - 2)]._visible = false;
_root.Game.ForeObjects["ForeObject" + (Middle + 1)]._visible = true;
} else if (Middle < OldMiddle) {
_root.Game.Ground["Floor" + (Middle + 2)]._visible = false;
_root.Game.Ground["Floor" + (Middle - 1)]._visible = true;
_root.Game.BackObjects["BackObject" + (Middle + 2)]._visible = false;
_root.Game.BackObjects["BackObject" + (Middle - 1)]._visible = true;
_root.Game.ForeObjects["ForeObject" + (Middle + 2)]._visible = false;
_root.Game.ForeObjects["ForeObject" + (Middle - 1)]._visible = true;
}
};
PlayerDie = function () {
_root.Pause = true;
if (!PlayerDead) {
if (_root.DieStatus == "Slash") {
_root.Game.Player.gotoAndPlay("Die1");
} else if (_root.DieStatus == "Burn") {
_root.Game.Player.gotoAndPlay("Die2");
} else if (_root.DieStatus == "Spark") {
_root.Game.Player.gotoAndPlay("Die3");
} else if (_root.DieStatus == "Poison") {
_root.Game.Player.gotoAndPlay("Die4");
} else {
_root.Game.Player.gotoAndPlay("Die1");
}
PlayerDead = true;
}
if (DieCount > 0) {
DieCount = DieCount - 1;
} else {
gotoAndPlay (518);
}
};
this.onEnterFrame = function () {
if (Key.isDown(16)) {
_root.InvincibleTimer = _root.InvincibleTimer + 9999;
}
if (_root.BackGround._y < _root.yLimit) {
if (!PlayerDead) {
_root.Scream_Sound.start();
DieStatus = "Fall";
_root.TotalDeaths = _root.TotalDeaths + 1;
_root.Armour = 1;
DieCount = 0;
}
PlayerDie();
}
if (_root.Armour <= 0) {
if (!PlayerDead) {
_root.Scream_Sound.start();
_root.TotalDeaths = _root.TotalDeaths + 1;
DieCount = 30;
}
PlayerDie();
}
if (!_root.Pause) {
if (_root.InvincibleTimer > 0) {
_root.InvincibleTimer = _root.InvincibleTimer - 1;
if (_root.InvincibleTimer == 0) {
_root.Game.Player._alpha = 100;
}
}
if (_root.Game.BackObjects.Door1.hitTest(_root.Game.Player)) {
_root.Level = _root.Level + 1;
SoundUP();
gotoAndPlay (518);
} else if (_root.Game.BackObjects.Door2.hitTest(_root.Game.Player)) {
_root.Level = _root.Level + 2;
SoundUP();
gotoAndPlay (518);
} else if (_root.Game.BackObjects.End1.hitTest(_root.Game.Player)) {
_root.Level = _root.Level + 10;
SoundUP();
gotoAndPlay (518);
} else if (_root.Game.BackObjects.End2.hitTest(_root.Game.Player)) {
_root.Level = _root.Level + 20;
SoundUP();
gotoAndPlay (518);
} else if (_root.Game.DeadDuck.hitTest(_root.Game.Player)) {
_root.BackGround.removeMovieClip();
_root.Game.removeMovieClip();
gotoAndPlay (520);
} else if (_root.FinishGame == true) {
_root.Game.removeMovieClip();
_root.BackGround.removeMovieClip();
gotoAndPlay (715);
delete this.onEnterFrame;
}
if (!PlayerAttacking) {
if (Key.isDown(AttackKey)) {
_root.slash_Sound.start();
PlayerCount = PlayerAttackTime;
PlayerAttacking = true;
_root.Game.Player.gotoAndPlay(PlayerDirection + "Attack");
if (_root.Armour == 4) {
_root.id++;
FlameOb._x = _root.Game.Player._x;
FlameOb._y = _root.Game.Player._y - (PlayerHeight / 2);
_root.Game.attachMovie("Flame", "Flame", _root.id, FlameOb);
if (PlayerDirection == "Left") {
_root.Game.Flame._rotation = -90;
} else {
_root.Game.Flame._rotation = 90;
}
}
}
} else if (PlayerCount > 0) {
PlayerCount = PlayerCount - 1;
} else {
PlayerAttacking = false;
}
if (Key.isDown(LeftKey)) {
PlayerDirection = "Left";
if (!PlayerAttacking) {
if (_root.Game.Player._currentframe > 22) {
_root.Game.Player.gotoAndPlay("LeftRun");
} else {
_root.Game.Player.gotoAndPlay(_root.Game.Player._currentframe + 1);
}
if (xspeed > (-xmax)) {
xspeed = xspeed - 1;
}
}
} else if (Key.isDown(RightKey)) {
PlayerDirection = "Right";
if (!PlayerAttacking) {
if ((_root.Game.Player._currentframe < 36) || (_root.Game.Player._currentframe > 56)) {
_root.Game.Player.gotoAndPlay("RightRun");
} else {
_root.Game.Player.gotoAndPlay(_root.Game.Player._currentframe + 1);
}
if (xspeed < xmax) {
xspeed = xspeed + 1;
}
}
} else if (!PlayerAttacking) {
_root.Game.Player.gotoAndPlay(PlayerDirection + "Stand");
}
while (_root.Game.Ground.hitTest(_root.Game.Player._x - 15, _root.Game.Player._y - 40, true)) {
_root.Game.Player._x++;
xspeed = 1;
}
while (_root.Game.Ground.hitTest(_root.Game.Player._x + 15, _root.Game.Player._y - 40, true)) {
_root.Game.Player._x--;
xspeed = -1;
}
while (_root.Game.Ground.hitTest(_root.Game.Player._x, _root.Game.Player._y - PlayerHeight, true)) {
_root.Game.Player._y++;
yspeed = 1;
}
if (Key.isDown(UpKey)) {
if (_root.Armour == 2) {
if (_root.Player_yspeed > 0) {
_root.Player_yspeed = _root.Player_yspeed / 2;
}
}
if (!_root.Jumped) {
_root.jump_Sound.start();
_root.Jumped = true;
if (_root.Armour == 3) {
Panda = 5;
} else {
Panda = 0;
}
_root.Player_yspeed = -(JumpHeight + Panda);
_root.Game.Player._y = _root.Game.Player._y - (JumpHeight + Panda);
}
}
_root.Player_yspeed = _root.Player_yspeed + _root.Gravity;
while (_root.Game.Ground.hitTest(_root.Game.Player._x, _root.Game.Player._y, true)) {
_root.Game.Player._y--;
_root.Player_yspeed = 0;
_root.Jumped = false;
}
if (!_root.Game.Ground.hitTest(_root.Game.Player._x, _root.Game.Player._y + 1, true)) {
_root.Jumped = true;
if (_root.Player_yspeed < ymax) {
_root.Player_yspeed = _root.Player_yspeed + 1;
if (_root.Player_yspeed > ymax) {
_root.Player_yspeed = ymax;
}
}
} else {
_root.Player_yspeed = 0;
_root.Jumped = false;
}
if (_root.Player_xOffset > 0) {
_root.Player_xOffset = _root.Player_xOffset - 1;
} else if (_root.Player_xOffset < 0) {
_root.Player_xOffset = _root.Player_xOffset + 1;
}
if ((_root.Player_xOffset > -1) && (_root.Player_xOffset < 1)) {
_root.Player_xOffset = 0;
}
xspeed = xspeed - _root.Player_xOffset;
xspeed = xspeed * Inertia;
if ((xspeed < 0.5) && (xspeed > -0.5)) {
xspeed = 0;
}
Position = _root.Game.Player._x + xspeed;
if ((Position >= 250) && (Position <= 350)) {
_root.Scrolling = 0;
}
if (Position > 350) {
PositionChange = Position - 350;
_root.Scrolling = PositionChange;
_root.Game.Ground._x = _root.Game.Ground._x - PositionChange;
_root.Game.ForeObjects._x = _root.Game.ForeObjects._x - PositionChange;
_root.Game.BackObjects._x = _root.Game.BackObjects._x - PositionChange;
_root.BackGround._x = _root.BackGround._x - (PositionChange / 15);
_root.ScrollAmount = _root.ScrollAmount + PositionChange;
Position = 350;
ViewTiles();
} else if (Position < 250) {
PositionChange = Position - 250;
_root.Scrolling = PositionChange;
_root.Game.Ground._x = _root.Game.Ground._x - PositionChange;
_root.Game.BackObjects._x = _root.Game.BackObjects._x - PositionChange;
_root.Game.ForeObjects._x = _root.Game.ForeObjects._x - PositionChange;
_root.BackGround._x = _root.BackGround._x - (PositionChange / 15);
_root.ScrollAmount = _root.ScrollAmount + PositionChange;
Position = 250;
ViewTiles();
}
if (!_root.Game.Ground.hitTest(_root.Game.Player._x, _root.Game.Player._y - PlayerHeight, true)) {
yPosition = _root.Game.Player._y + _root.Player_yspeed;
} else {
_root.Player.yspeed = 0;
}
if ((yPosition >= 100) && (yPosition <= 350)) {
_root.yScrolling = 0;
} else if (yPosition > 350) {
yPositionChange = yPosition - 350;
_root.yScrolling = yPositionChange;
_root.Game.Ground._y = _root.Game.Ground._y - yPositionChange;
_root.Game.BackObjects._y = _root.Game.BackObjects._y - yPositionChange;
_root.Game.ForeObjects._y = _root.Game.ForeObjects._y - yPositionChange;
_root.BackGround._y = _root.BackGround._y - (yPositionChange / 15);
_root.yScrollAmount = _root.yScrollAmount + yPositionChange;
yPosition = 350;
}
if (yPosition < 150) {
yPositionChange = yPosition - 150;
_root.yScrolling = yPositionChange;
_root.Game.Ground._y = _root.Game.Ground._y - yPositionChange;
_root.Game.BackObjects._y = _root.Game.BackObjects._y - yPositionChange;
_root.Game.ForeObjects._y = _root.Game.ForeObjects._y - yPositionChange;
_root.BackGround._y = _root.BackGround._y - (yPositionChange / 15);
_root.yScrollAmount = _root.yScrollAmount + yPositionChange;
yPosition = 150;
}
_root.Game.Player._x = Position;
_root.Game.Player._y = yPosition;
}
};
Frame 520
_root.song_Sound.stop();
_root.baddies_Sound.start();
Frame 714
_root.Level = 50;
_root.baddies_Sound.stop();
_root.song_Sound.start();
gotoAndPlay (518);
Frame 715
_root.song_Sound.stop();
_root.baddies_Sound.start();
Frame 768
_root.song_Sound.stop();
_root.baddies_Sound.start();
Frame 819
stop();
_root.Spooks_Sound.start();
_root.baddies_Sound.stop();
TotalDeaths_txt.text = _root.TotalDeaths;
TotalKills_txt.text = _root.TotalKills;
Button1.onRelease = function () {
gotoAndPlay (2);
_root.killplant_Sound.start();
};
Button2.onRelease = function () {
getURL ("http://seditiongames.newgrounds.com/");
_root.killplant_Sound.start();
};
Max.onRelease = function () {
getURL ("http://www.maxgames.com/");
_root.killplant_Sound.start();
};
Instance of Symbol 1078 MovieClip in Frame 820
onClipEvent (load) {
preloader_size = _width;
}
onClipEvent (enterFrame) {
_width = ((_root.getBytesLoaded() / _root.getBytesTotal()) * preloader_size);
}
Frame 821
ifFrameLoaded (_totalframes + 819) {
gotoAndPlay (2);
}
Frame 822
LC = new LocalConnection();
if (LC.domain() != "www.flashgamelicense.com") {
stop();
}
Symbol 33 MovieClip Frame 1
_visible = false;
Symbol 37 MovieClip [Blood] Frame 13
stop();
this.removeMovieClip();
Symbol 41 MovieClip [Burn] Frame 1
this.onEnterFrame = function () {
this._x = this._x - _global.scrolling;
};
Symbol 41 MovieClip [Burn] Frame 19
this.removeMovieClip();
Symbol 42 MovieClip [FreeSword] Frame 1
speed = 0;
max = 15;
yspeed = 0;
ymax = 20;
Begun = false;
Attacking = false;
Direction = "Right";
Dead = false;
ClangOb = new Object();
xOffset = 0;
Death = function () {
_root.mscream_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Die");
};
Burn = function () {
_root.mscream_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Burn");
};
Fall = function () {
yspeed = yspeed + _root.Gravity;
while (_root.Game.Ground.hitTest(_x, _y, true)) {
_y = (_y-1);
yspeed = 0;
}
while (_root.Game.Ground.hitTest(_x - 25, _y - 50, true)) {
_x = (_x+1);
speed = 2;
}
while (_root.Game.Ground.hitTest(_x + 25, _y - 50, true)) {
_x = (_x-1);
speed = -2;
}
if (!_root.Game.Ground.hitTest(_x, _y + 1, true)) {
if (yspeed < ymax) {
yspeed = yspeed + 1;
if (yspeed > ymax) {
yspeed = ymax;
}
}
} else {
yspeed = 0;
}
};
Visible = function () {
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
_visible = false;
} else {
_visible = true;
}
};
ChooseDirection = function () {
if ((_x - _root.Game.Player._x) > 0) {
if (!Attacking) {
if (speed > (-max)) {
speed = speed - 2;
}
if (Direction == "Left") {
gotoAndPlay ("RightRun");
}
}
Direction = "Right";
} else {
if (!Attacking) {
if (speed < max) {
speed = speed + 2;
}
if (Direction == "Right") {
gotoAndPlay ("LeftRun");
}
}
Direction = "Left";
}
};
Attack = function () {
if ((_x - _root.Game.Player._x) < 150) {
if ((_x - _root.Game.Player._x) > -150) {
if (!Attacking) {
Attacking = true;
gotoAndPlay(Direction + "SlashStand");
}
}
}
};
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Dead) {
Fall();
Visible();
ChooseDirection();
Attack();
if (_root.Game.Flame.hitTest(this)) {
Dead = true;
Burn();
} else if (_root.Game.Player.AttackZoneHero.hitTest(this.HitZone)) {
speed = speed / 2;
if (_root.Game.Player._x <= _x) {
_root.Player_xOffset = 2;
xOffset = max / 2;
} else {
_root.Player_xOffset = -2;
xOffset = (-max) / 2;
}
ClangOb._x = _x;
ClangOb._y = _y - 100;
_root.id++;
_root.Game.attachMovie("Clang", "Clang" + _root.id, _root.id, ClangOb);
} else if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
Dead = true;
Death();
} else if (_root.Game.Player.HitArea.hitTest(this.HitZone)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.Game.Player._alpha = 50;
_root.InvincibleTimer = 30;
} else {
_root.DieStatus = "Slash";
_root.Armour = 0;
}
}
}
}
if (xOffset > 0) {
xOffset = xOffset - 1;
} else if (xOffset < 0) {
xOffset = xOffset + 1;
}
_x = (_x - ((_root.Scrolling - speed) - xOffset));
_y = (_y - (_root.yScrolling - yspeed));
}
};
Symbol 42 MovieClip [FreeSword] Frame 2
stop();
Symbol 42 MovieClip [FreeSword] Frame 15
Begun = true;
Symbol 42 MovieClip [FreeSword] Frame 37
Attacking = false;
gotoAndPlay ("RightRun");
Symbol 42 MovieClip [FreeSword] Frame 60
gotoAndPlay ("LeftRun");
Symbol 42 MovieClip [FreeSword] Frame 82
Attacking = false;
gotoAndPlay ("LeftRun");
Symbol 42 MovieClip [FreeSword] Frame 105
gotoAndPlay ("RightRun");
Symbol 42 MovieClip [FreeSword] Frame 131
stop();
this.removeMovieClip();
Symbol 42 MovieClip [FreeSword] Frame 146
stop();
this.removeMovieClip();
Symbol 80 MovieClip Frame 1
Falling = false;
StartPlace = _y;
Rate = 1;
Started = false;
StartTime = 15;
Timer = StartTime;
this.onEnterFrame = function () {
if (!_root.Pause) {
if (Started) {
if (Timer > 0) {
Timer = Timer - 1;
} else {
Falling = true;
if (_root.Game.Player.hitTest(this)) {
_root.Game.Player._y = _root.Game.Player._y + Rate;
_root.Jumped = false;
}
this._y = this._y + Rate;
Rate = Rate + 1;
if (_y > (StartPlace + 2000)) {
_y = StartPlace;
Started = false;
Timer = StartTime;
Rate = 1;
Falling = false;
}
}
} else if (this.hitTest(_root.Game.Player)) {
Started = true;
}
}
};
Symbol 85 MovieClip [ItemPanda] Frame 1
stop();
Begun = false;
this.onEnterFrame = function () {
if (!Begun) {
if (_root.Game.Player.HitArea.hitTest(this)) {
_root.Armour = 3;
_root.pickup1_Sound.start();
Begun = true;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(2);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
this.gotoAndPlay(2);
}
}
};
Symbol 85 MovieClip [ItemPanda] Frame 20
stop();
Symbol 120 MovieClip Frame 1
stop();
Dead = false;
Death = function () {
this.gotoAndPlay(2);
};
this.onEnterFrame = function () {
if (!Dead) {
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
_root.explode_Sound.start();
Dead = true;
Death();
}
}
};
Symbol 120 MovieClip Frame 21
stop();
Symbol 126 MovieClip Frame 1
this.onEnterFrame = function () {
if (_root.Game.Player.hitTest(this)) {
_root.boing_Sound.start();
_root.Jumped = true;
_root.Player_yspeed = -50;
_root.Game.Player._y = _root.Game.Player._y - 50;
}
};
Symbol 133 MovieClip Frame 1
Rate = 1;
RateMax = 15;
Direction = -0.5;
this.onEnterFrame = function () {
if (!_root.Pause) {
if (_root.Game.Player.hitTest(this)) {
_root.Game.Player._y = _root.Game.Player._y + Rate;
_root.Jumped = false;
}
this._y = this._y + Rate;
if ((Rate < RateMax) && (Rate > (-RateMax))) {
Rate = Rate - Direction;
} else {
Direction = -Direction;
Rate = Rate - Direction;
}
}
};
Symbol 134 MovieClip Frame 1
Rate = 1;
RateMax = 15;
Direction = 0.5;
this.onEnterFrame = function () {
if (!_root.Pause) {
if (_root.Game.Player.hitTest(this)) {
_root.Game.Player._y = _root.Game.Player._y + Rate;
_root.Jumped = false;
}
this._y = this._y + Rate;
if ((Rate < RateMax) && (Rate > (-RateMax))) {
Rate = Rate - Direction;
} else {
Direction = -Direction;
Rate = Rate - Direction;
}
}
};
Symbol 137 MovieClip [ItemChicken] Frame 1
stop();
Begun = false;
this.onEnterFrame = function () {
if (!Begun) {
if (_root.Game.Player.HitArea.hitTest(this)) {
_root.Armour = 2;
_root.pickup1_Sound.start();
Begun = true;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(2);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
this.gotoAndPlay(2);
}
}
};
Symbol 137 MovieClip [ItemChicken] Frame 20
stop();
Symbol 155 MovieClip [ItemFire] Frame 1
stop();
Begun = false;
this.onEnterFrame = function () {
if (!Begun) {
if (_root.Game.Player.HitArea.hitTest(this)) {
_root.Armour = 4;
_root.pickup1_Sound.start();
Begun = true;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(2);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
this.gotoAndPlay(2);
}
}
};
Symbol 155 MovieClip [ItemFire] Frame 20
stop();
Symbol 161 MovieClip Frame 1
this.onEnterFrame = function () {
if (!_root.Pause) {
_rotation = (_rotation + 5);
}
};
Symbol 195 MovieClip Frame 1
stop();
Symbol 195 MovieClip Frame 2
stop();
Symbol 195 MovieClip Frame 3
stop();
Symbol 195 MovieClip Frame 4
stop();
Symbol 200 MovieClip Frame 1
stop();
Symbol 200 MovieClip Frame 2
stop();
Symbol 200 MovieClip Frame 3
stop();
Symbol 200 MovieClip Frame 4
stop();
Symbol 205 MovieClip Frame 1
stop();
Symbol 205 MovieClip Frame 2
stop();
Symbol 205 MovieClip Frame 3
stop();
Symbol 205 MovieClip Frame 4
stop();
Symbol 210 MovieClip Frame 1
stop();
Symbol 210 MovieClip Frame 2
stop();
Symbol 210 MovieClip Frame 3
stop();
Symbol 210 MovieClip Frame 4
stop();
Symbol 214 MovieClip Frame 1
stop();
Symbol 214 MovieClip Frame 2
stop();
Symbol 214 MovieClip Frame 3
stop();
Symbol 218 MovieClip Frame 1
stop();
Symbol 218 MovieClip Frame 2
stop();
Symbol 218 MovieClip Frame 3
stop();
Symbol 218 MovieClip Frame 4
stop();
Symbol 224 MovieClip Frame 1
HitArea._visible = false;
Symbol 224 MovieClip Frame 2
stop();
Symbol 224 MovieClip Frame 23
gotoAndPlay ("LeftRun");
Symbol 224 MovieClip Frame 35
gotoAndPlay ("LeftStand");
Symbol 224 MovieClip Frame 36
stop();
Symbol 224 MovieClip Frame 57
gotoAndPlay ("RightRun");
Symbol 224 MovieClip Frame 69
gotoAndPlay ("RightStand");
Symbol 224 MovieClip Frame 80
stop();
Symbol 224 MovieClip Frame 82
stop();
Symbol 224 MovieClip Frame 83
stop();
Symbol 224 MovieClip Frame 100
stop();
Symbol 229 MovieClip Frame 1
_visible = false;
Symbol 235 MovieClip Frame 1
Speed = 5;
Dir = -Speed;
yDir = Speed;
Begun = false;
Dead = false;
Fall = function () {
while (_root.Game.Ground.hitTest(_x, _y + 50, true)) {
_y = (_y-1);
}
while (_root.Game.Ground.hitTest(_x, _y, true)) {
_y = (_y+1);
}
while (_root.Game.Ground.hitTest(_x - 30, _y, true)) {
_x = (_x+1);
}
while (_root.Game.Ground.hitTest(_x + 90, _y, true)) {
_x = (_x-1);
}
};
Visible = function () {
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
_visible = false;
} else {
_visible = true;
}
};
ChooseDirection = function () {
if ((_x - _root.Game.Player._x) >= 0) {
Dir = -Speed;
} else {
Dir = Speed;
}
if ((_y - _root.Game.Player._y) >= 0) {
yDir = -Speed;
} else {
yDir = Speed;
}
};
Death = function () {
_root.killplant_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Die");
};
Burn = function () {
_root.killplant_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Burn");
};
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Dead) {
Fall();
Visible();
if (!Begun) {
if (((_x - _root.Game.Player._x) < 400) && ((_x - _root.Game.Player._x) > -400)) {
if (((_y - _root.Game.Player._y) < 400) && ((_y - _root.Game.Player._y) > -400)) {
Begun = true;
}
}
} else {
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
Dead = true;
Death();
} else if (_root.Game.Flame.hitTest(this)) {
Dead = true;
Burn();
} else if (_root.Game.Player.HitArea.hitTest(this.HitZone)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.InvincibleTimer = 30;
_root.Game.Player._alpha = 50;
} else {
_root.DieStatus = "Poison";
_root.Armour = 0;
}
}
}
ChooseDirection();
}
}
_x = (_x - ((_root.Scrolling - Dir) + (2 - Math.round(Math.random() * 4))));
_y = (_y - ((_root.yScrolling - yDir) + (2 - Math.round(Math.random() * 4))));
}
};
Symbol 235 MovieClip Frame 36
gotoAndPlay (2);
Symbol 235 MovieClip Frame 51
stop();
Symbol 235 MovieClip Frame 67
stop();
this.removeMovieClip();
Symbol 243 MovieClip Frame 1
speed = 0;
max = 5;
yspeed = 0;
ymax = 20;
Dir = -2;
Begun = false;
Direction = "Left";
Status = "Run";
StartTimer = 40;
ShurikenOb = new Object();
Timer = 4;
Dead = false;
Death = function () {
_root.Scream_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Die");
};
Fall = function () {
while (_root.Game.Ground.hitTest(_x, _y, true)) {
_y = (_y-1);
yspeed = 0;
}
while (_root.Game.Ground.hitTest(_x - 25, _y - 50, true)) {
_x = (_x+1);
speed = 2;
}
while (_root.Game.Ground.hitTest(_x + 25, _y - 50, true)) {
_x = (_x-1);
speed = 2;
}
if (!_root.Game.Ground.hitTest(_x, _y + 1, true)) {
if (yspeed < ymax) {
yspeed = yspeed + _root.Gravity;
if (yspeed > ymax) {
yspeed = ymax;
}
}
} else {
yspeed = 0;
}
};
Move = function () {
if (speed < max) {
if (speed > (-max)) {
speed = speed + Dir;
}
}
};
Visible = function () {
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
_visible = false;
} else {
_visible = true;
}
};
ChooseDirection = function () {
if ((_x - _root.Game.Player._x) >= 0) {
if (Status == "Run") {
if (Direction == "Right") {
gotoAndPlay ("LeftWalk");
}
Move();
}
Dir = -2;
Direction = "Left";
} else {
if (Status == "Run") {
if (Direction == "Left") {
gotoAndPlay ("RightWalk");
}
Move();
}
Dir = 2;
Direction = "Right";
}
};
Attack = function () {
if (Timer > 0) {
Timer = Timer - 1;
if (Timer == (StartTimer - 28)) {
Status = "Run";
}
} else {
Timer = StartTimer;
if (_visible) {
speed = 0;
Status = "Attacking";
gotoAndPlay(Direction + "Attack");
} else {
Status = "Run";
gotoAndPlay(Direction + Status);
}
}
};
Burn = function () {
_root.Scream_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Burn");
};
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Dead) {
Fall();
Visible();
if (!Begun) {
if (((_x - _root.Game.Player._x) < 300) && ((_x - _root.Game.Player._x) > -300)) {
if (((_y - _root.Game.Player._y) < 300) && ((_y - _root.Game.Player._y) > -300)) {
Begun = true;
gotoAndPlay ("LeftWalk");
}
}
} else {
if (_y > (_root.Game.Player._y + 1000)) {
if (Begun) {
Begun = false;
Death();
}
}
ChooseDirection();
Attack();
}
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
Dead = true;
Death();
} else if (_root.Game.Flame.hitTest(this)) {
Dead = true;
Burn();
}
}
_x = (_x - (_root.Scrolling - speed));
_y = (_y - (_root.yScrolling - yspeed));
}
};
Symbol 243 MovieClip Frame 14
gotoAndPlay ("LeftWalk");
Symbol 243 MovieClip Frame 27
gotoAndPlay ("RightWalk");
Symbol 243 MovieClip Frame 42
ShurikenOb._x = _x + 15;
ShurikenOb._y = _y - 90;
ShurikenOb._rotation = 90;
_root.id++;
_root.Game.attachMovie("BadFan", "BadFan" + _root.id, _root.id, ShurikenOb);
Symbol 243 MovieClip Frame 56
gotoAndPlay ("RightWalk");
Symbol 243 MovieClip Frame 71
ShurikenOb._x = _x - 15;
ShurikenOb._y = _y - 90;
ShurikenOb._rotation = -90;
_root.id++;
_root.Game.attachMovie("BadFan", "BadFan" + _root.id, _root.id, ShurikenOb);
Symbol 243 MovieClip Frame 85
gotoAndPlay ("LeftWalk");
Symbol 243 MovieClip Frame 103
stop();
Symbol 243 MovieClip Frame 118
stop();
this.removeMovieClip();
Symbol 252 MovieClip Frame 1
speed = 0;
max = 10;
yspeed = 0;
ymax = 10;
Dir = -2;
Begun = false;
Attacking = false;
Direction = "Left";
Status = "Run";
StartTimer = 0;
ShurikenOb = new Object();
Timer = StartTimer;
Dead = false;
Burn = function () {
_root.mscream_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Burn");
};
Death = function () {
_root.mscream_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Die");
};
Fall = function () {
while (_root.Game.Ground.hitTest(_x, _y, true)) {
_y = (_y-1);
yspeed = 0;
}
while (_root.Game.Ground.hitTest(_x - 25, _y - 50, true)) {
_x = (_x+1);
speed = 2;
}
while (_root.Game.Ground.hitTest(_x + 25, _y - 50, true)) {
_x = (_x-1);
speed = -2;
}
if (!_root.Game.Ground.hitTest(_x, _y + 1, true)) {
if (yspeed < ymax) {
yspeed = yspeed + _root.Gravity;
if (yspeed > ymax) {
yspeed = ymax;
}
}
} else {
yspeed = 0;
}
};
Move = function () {
if (speed < max) {
if (speed > (-max)) {
speed = speed + Dir;
}
}
};
Visible = function () {
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
_visible = false;
} else {
_visible = true;
}
};
ChooseDirection = function () {
if ((_x - _root.Game.Player._x) >= 0) {
if (Status == "Run") {
if (Direction == "Right") {
gotoAndPlay ("LeftRun");
}
Move();
}
Dir = -2;
Direction = "Left";
} else {
if (Status == "Run") {
if (Direction == "Left") {
gotoAndPlay ("RightRun");
}
Move();
}
Dir = 2;
Direction = "Right";
}
};
ChooseAttack = function () {
Value = Math.random();
if ((Value >= 0) && (Value < 0.8)) {
if (Value < 0.2) {
Status = "JumpKick";
speed = Dir * 8;
Timer = 30;
} else if ((Value >= 0.2) && (Value < 0.4)) {
Status = "Shuriken";
speed = (-Dir) * 3;
Timer = 40;
} else if ((Value >= 0.4) && (Value < 0.6)) {
Status = "StandShuriken";
speed = 0;
Timer = 20;
} else {
Status = "JumpShuriken";
speed = (-Dir) * 4;
yspeed = -21;
_y = (_y - 21);
Timer = 70;
}
} else {
Status = "Run";
Timer = 30;
}
gotoAndPlay(Direction + Status);
};
Attack = function () {
if (Timer > 0) {
Timer = Timer - 1;
} else if (_visible) {
ChooseAttack();
} else {
Status = "Run";
gotoAndPlay(Direction + Status);
}
};
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Dead) {
Fall();
Visible();
if (!Begun) {
if (((_x - _root.Game.Player._x) < 300) && ((_x - _root.Game.Player._x) > -300)) {
if (((_y - _root.Game.Player._y) < 300) && ((_y - _root.Game.Player._y) > -300)) {
Begun = true;
gotoAndPlay ("LeftRun");
}
}
} else {
ChooseDirection();
Attack();
if (_y > (_root.Game.Player._y + 1000)) {
if (Begun) {
Begun = false;
Death();
}
}
}
if (speed > 0) {
speed = speed - 0.25;
} else if (speed < 0) {
speed = speed + 0.25;
}
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
Dead = true;
Death();
} else if (_root.Game.Flame.hitTest(this)) {
Dead = true;
Burn();
} else if (_root.Game.Player.HitArea.hitTest(this)) {
if (Status == "JumpKick") {
_root.punch2_Sound.start();
_root.Player_xOffset = (-speed) * 0.5;
}
}
}
_x = (_x - (_root.Scrolling - speed));
_y = (_y - (_root.yScrolling - yspeed));
}
};
Symbol 252 MovieClip Frame 2
stop();
Symbol 252 MovieClip Frame 30
Status = "Stand";
speed = 0;
gotoAndPlay ("LeftStand");
Symbol 252 MovieClip Frame 55
ShurikenOb._x = _x;
ShurikenOb._y = _y - (_height / 2);
_root.shuriken_Sound.start();
ShurikenOb._rotation = -80;
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
ShurikenOb._rotation = -90;
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
ShurikenOb._rotation = -100;
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
Symbol 252 MovieClip Frame 65
gotoAndPlay ("LeftStand");
Symbol 252 MovieClip Frame 95
ShurikenOb._x = _x;
ShurikenOb._y = _y;
_root.shuriken_Sound.start();
ShurikenOb._rotation = -120;
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
Symbol 252 MovieClip Frame 105
ShurikenOb._x = _x;
ShurikenOb._y = _y;
_root.shuriken_Sound.start();
ShurikenOb._rotation = -100;
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
Symbol 252 MovieClip Frame 115
ShurikenOb._x = _x;
ShurikenOb._y = _y;
_root.shuriken_Sound.start();
ShurikenOb._rotation = -80;
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
Symbol 252 MovieClip Frame 135
gotoAndPlay ("LeftStand");
Symbol 252 MovieClip Frame 141
ShurikenOb._x = _x;
_root.shuriken_Sound.start();
ShurikenOb._y = _y - (_height / 2);
_root.id++;
Target = Math.atan((_x - _root.Game.Player._x) / (_root.Game.Player._y - _y));
if (_root.Game.Player._y > _y) {
Target = Target + Math.PI;
}
ShurikenOb._rotation = (180 * Target) / Math.PI;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
Symbol 252 MovieClip Frame 146
gotoAndPlay ("LeftStand");
Symbol 252 MovieClip Frame 163
gotoAndPlay ("LeftRun");
Symbol 252 MovieClip Frame 164
stop();
Symbol 252 MovieClip Frame 192
gotoAndPlay ("RightStand");
Symbol 252 MovieClip Frame 217
ShurikenOb._x = _x;
ShurikenOb._y = _y - (_height / 2);
_root.shuriken_Sound.start();
ShurikenOb._rotation = 80;
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
ShurikenOb._rotation = 90;
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
ShurikenOb._rotation = 100;
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
Symbol 252 MovieClip Frame 227
gotoAndPlay ("RightStand");
Symbol 252 MovieClip Frame 257
ShurikenOb._x = _x;
ShurikenOb._y = _y;
ShurikenOb._rotation = 120;
_root.shuriken_Sound.start();
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
Symbol 252 MovieClip Frame 267
ShurikenOb._x = _x;
ShurikenOb._y = _y;
_root.shuriken_Sound.start();
ShurikenOb._rotation = 100;
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
Symbol 252 MovieClip Frame 277
ShurikenOb._x = _x;
_root.shuriken_Sound.start();
ShurikenOb._y = _y;
ShurikenOb._rotation = 80;
_root.id++;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
Symbol 252 MovieClip Frame 297
gotoAndPlay ("RightStand");
Symbol 252 MovieClip Frame 303
ShurikenOb._x = _x;
ShurikenOb._y = _y - (_height / 2);
_root.shuriken_Sound.start();
_root.id++;
Target = Math.atan((_x - _root.Game.Player._x) / (_root.Game.Player._y - _y));
if (_root.Game.Player._y > _y) {
Target = Target + Math.PI;
}
ShurikenOb._rotation = (180 * Target) / Math.PI;
_root.Game.attachMovie("BadShuriken", "BadShuriken" + _root.id, _root.id, ShurikenOb);
Symbol 252 MovieClip Frame 308
gotoAndPlay ("RightStand");
Symbol 252 MovieClip Frame 325
gotoAndPlay ("RightRun");
Symbol 252 MovieClip Frame 341
stop();
Symbol 252 MovieClip Frame 356
stop();
this.removeMovieClip();
Symbol 253 MovieClip Frame 1
speed = 0;
max = 15;
yspeed = 0;
ymax = 20;
Begun = false;
Attacking = false;
Direction = "Right";
Dead = false;
ClangOb = new Object();
xOffset = 0;
Death = function () {
_root.mscream_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Die");
};
Burn = function () {
_root.mscream_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Burn");
};
Fall = function () {
yspeed = yspeed + _root.Gravity;
while (_root.Game.Ground.hitTest(_x, _y, true)) {
_y = (_y-1);
yspeed = 0;
}
while (_root.Game.Ground.hitTest(_x - 25, _y - 50, true)) {
_x = (_x+1);
speed = 2;
}
while (_root.Game.Ground.hitTest(_x + 25, _y - 50, true)) {
_x = (_x-1);
speed = -2;
}
if (!_root.Game.Ground.hitTest(_x, _y + 1, true)) {
if (yspeed < ymax) {
yspeed = yspeed + 1;
if (yspeed > ymax) {
yspeed = ymax;
}
}
} else {
yspeed = 0;
}
};
Visible = function () {
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
_visible = false;
} else {
_visible = true;
}
};
ChooseDirection = function () {
if ((_x - _root.Game.Player._x) > 0) {
if (!Attacking) {
if (speed > (-max)) {
speed = speed - 2;
}
if (Direction == "Left") {
gotoAndPlay ("RightRun");
}
}
Direction = "Right";
} else {
if (!Attacking) {
if (speed < max) {
speed = speed + 2;
}
if (Direction == "Right") {
gotoAndPlay ("LeftRun");
}
}
Direction = "Left";
}
};
Attack = function () {
if ((_x - _root.Game.Player._x) < 150) {
if ((_x - _root.Game.Player._x) > -150) {
if (!Attacking) {
Attacking = true;
gotoAndPlay(Direction + "SlashStand");
}
}
}
};
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Dead) {
Fall();
Visible();
if (!Begun) {
if (((_x - _root.Game.Player._x) < 300) && ((_x - _root.Game.Player._x) > -300)) {
if (((_y - _root.Game.Player._y) < 200) && ((_y - _root.Game.Player._y) > -200)) {
Begun = true;
}
}
} else {
if (_y > (_root.Game.Player._y + 1000)) {
Begun = false;
Dead();
}
ChooseDirection();
Attack();
}
if (_root.Game.Flame.hitTest(this)) {
Dead = true;
Burn();
} else if (_root.Game.Player.AttackZoneHero.hitTest(this.HitZone)) {
speed = speed / 2;
if (_root.Game.Player._x <= _x) {
_root.Player_xOffset = 2;
xOffset = max / 2;
} else {
_root.Player_xOffset = -2;
xOffset = (-max) / 2;
}
ClangOb._x = _x;
ClangOb._y = _y - 100;
_root.id++;
_root.Game.attachMovie("Clang", "Clang" + _root.id, _root.id, ClangOb);
} else if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
Dead = true;
Death();
} else if (_root.Game.Player.HitArea.hitTest(this.HitZone)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.Game.Player._alpha = 50;
_root.InvincibleTimer = 30;
} else {
_root.DieStatus = "Slash";
_root.Armour = 0;
}
}
}
}
if (xOffset > 0) {
xOffset = xOffset - 1;
} else if (xOffset < 0) {
xOffset = xOffset + 1;
}
_x = (_x - ((_root.Scrolling - speed) - xOffset));
_y = (_y - (_root.yScrolling - yspeed));
}
};
Symbol 253 MovieClip Frame 2
stop();
Symbol 253 MovieClip Frame 15
Begun = true;
Symbol 253 MovieClip Frame 37
Attacking = false;
gotoAndPlay ("RightRun");
Symbol 253 MovieClip Frame 60
gotoAndPlay ("LeftRun");
Symbol 253 MovieClip Frame 82
Attacking = false;
gotoAndPlay ("LeftRun");
Symbol 253 MovieClip Frame 105
gotoAndPlay ("RightRun");
Symbol 253 MovieClip Frame 131
stop();
Symbol 253 MovieClip Frame 146
stop();
this.removeMovieClip();
Symbol 275 MovieClip [BadArrow] Frame 1
speed = 20;
ClangOb = new Object();
this.onEnterFrame = function () {
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
_root.id++;
ClangOb._x = _x;
ClangOb._y = _y;
_root.Game.attachMovie("Clang", "Clang" + _root.id, _root.id, ClangOb);
this.removeMovieClip();
} else if (_root.Game.Ground.hitTest(_x, _y, true)) {
this.removeMovieClip();
} else if (_root.Game.Player.HitArea.hitTest(this)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.Game.Player._alpha = 50;
_root.InvincibleTimer = 30;
} else {
_root.Armour = 0;
}
}
}
_x = (_x + ((speed * Math.sin((_rotation * Math.PI) / 180)) - _root.Scrolling));
_y = (_y - ((speed * Math.cos((_rotation * Math.PI) / 180)) + _root.yScrolling));
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
this.removeMovieClip();
} else if (((_y - _root.Game.Player._y) > 450) || ((_y - _root.Game.Player._y) < -450)) {
this.removeMovieClip();
}
};
Symbol 277 MovieClip [BadShuriken] Frame 1
speed = 20;
ClangOb = new Object();
Hitted = false;
this.onEnterFrame = function () {
if (!Hitted) {
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
Hitted = true;
_root.id++;
ClangOb._x = _x;
ClangOb._y = _y;
_root.Game.attachMovie("Clang", "Clang" + _root.id, _root.id, ClangOb);
this._rotation = this._rotation - 180;
} else if (_root.Game.Player.HitArea.hitTest(this)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.Game.Player._alpha = 50;
_root.InvincibleTimer = 30;
} else {
_root.DieStatus = "Slash";
_root.Armour = 0;
}
}
}
}
_x = (_x + ((speed * Math.sin((_rotation * Math.PI) / 180)) - _root.Scrolling));
_y = (_y - ((speed * Math.cos((_rotation * Math.PI) / 180)) + _root.yScrolling));
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
this.removeMovieClip();
} else if (((_y - _root.Game.Player._y) > 450) || ((_y - _root.Game.Player._y) < -450)) {
this.removeMovieClip();
}
};
Symbol 277 MovieClip [BadShuriken] Frame 6
gotoAndPlay (2);
Symbol 279 MovieClip [BadFan] Frame 1
velocity = 15;
turning_speed = 3;
targ = _root.Game.Player;
xspeed = 0;
yspeed = 0;
ClangOb = new Object();
turning = turning_speed * (Math.PI/180);
Hit = function () {
if (_root.Game.Ground.hitTest(_x, _y, true)) {
this.removeMovieClip();
} else if (_root.Game.Player.HitArea.hitTest(this)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.InvincibleTimer = 30;
_root.Game.Player._alpha = 50;
} else {
_root.DieStatus = "Slash";
_root.Armour = 0;
}
}
}
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
_root.id++;
ClangOb._x = _x;
ClangOb._y = _y;
_root.Game.attachMovie("Clang", "Clang" + _root.id, _root.id, ClangOb);
this.removeMovieClip();
}
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
this.removeMovieClip();
} else if (((_y - _root.Game.Player._y) > 450) || ((_y - _root.Game.Player._y) < -450)) {
this.removeMovieClip();
}
};
this.onEnterFrame = function () {
Hit();
lrot2 = lrot;
lrot = _rotation;
waypoint = Math.atan((_x - targ._x) / (targ._y - _y));
if (targ._y > _y) {
waypoint = waypoint + Math.PI;
}
if (waypoint < 0) {
waypoint = waypoint + (Math.PI*2);
} else if (waypoint >= (Math.PI*2)) {
waypoint = waypoint - (Math.PI*2);
}
rota = _rotation * (Math.PI/180);
if (rota < 0) {
rota = rota + (Math.PI*2);
} else if (rota >= (Math.PI*2)) {
rota = rota - (Math.PI*2);
}
orota = waypoint - rota;
if (orota < 0) {
orota = orota + (Math.PI*2);
} else if (orota >= (Math.PI*2)) {
orota = orota - (Math.PI*2);
}
if ((rota < ((waypoint - (turning / 2)) + turning)) && (rota > (waypoint - (turning / 2)))) {
rota = waypoint;
} else if (orota <= Math.PI) {
rota = rota + turning;
} else {
rota = rota - turning;
}
if (_rotation == 0) {
_rotation = (_rotation+1);
rota = _rotation * (Math.PI/180);
}
_rotation = ((rota * 180) / Math.PI);
xspeed = velocity * Math.sin(rota);
yspeed = velocity * Math.cos(rota);
_x = (_x + xspeed);
_y = (_y - yspeed);
if ((((_rotation > 0) && (lrot < 0)) && (lrot2 > 0)) || (((_rotation < 0) && (lrot > 0)) && (lrot2 < 0))) {
_rotation = 0;
}
};
Symbol 279 MovieClip [BadFan] Frame 22
gotoAndPlay (2);
Symbol 283 MovieClip [FadeBlack] Frame 15
this.removeMovieClip();
Symbol 283 MovieClip [FadeBlack] Frame 30
this.removeMovieClip();
Symbol 331 MovieClip Frame 1
stop();
Symbol 337 MovieClip Frame 1
turning_speed = 1;
targ = _root.Game.Player;
StartCount = 60;
Count = 60;
ArrowOb = new Object();
Dir = "Left";
yspeed = 0;
ymax = 20;
Dead = false;
Death = function () {
_root.TotalKills = _root.TotalKills + 1;
_root.Scream_Sound.start();
gotoAndPlay ("Die");
};
Fall = function () {
while (_root.Game.Ground.hitTest(_x, _y, true)) {
_y = (_y-1);
yspeed = 0;
}
if (!_root.Game.Ground.hitTest(_x, _y + 1, true)) {
if (yspeed < ymax) {
yspeed = yspeed + _root.Gravity;
if (yspeed > ymax) {
yspeed = ymax;
}
}
} else {
yspeed = 0;
}
};
FireArrow = function () {
if (Count > 0) {
Count = Count - 1;
if (Count == (StartCount + 16)) {
ArrowOb._x = _x;
ArrowOb._y = _y - 40;
ArrowOb._rotation = Body._rotation;
_root.id++;
_root.Game.attachMovie("BadArrow", "BadArrow" + _root.id, _root.id, ArrowOb);
}
} else {
Count = StartCount + 45;
Body.gotoAndPlay(2);
}
};
Direction = function () {
if ((_x - _root.Game.Player._x) > 0) {
if (Dir == "Right") {
Body._rotation = Body._rotation + 180;
}
Dir = "Left";
Body._xscale = 100;
} else {
if (Dir == "Left") {
Body._rotation = Body._rotation - 180;
}
Dir = "Right";
Body._xscale = -100;
}
};
Burn = function () {
_root.Scream_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Burn");
};
Scroll = function () {
_x = (_x - _root.Scrolling);
_y = (_y - _root.yScrolling);
};
turning = turning_speed * (Math.PI/180);
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Dead) {
lrot2 = lrot;
lrot = Body._rotation;
waypoint = Math.atan((_x - targ._x) / (targ._y - _y));
if (targ._y > _y) {
waypoint = waypoint + Math.PI;
}
if (waypoint < 0) {
waypoint = waypoint + (Math.PI*2);
} else if (waypoint >= (Math.PI*2)) {
waypoint = waypoint - (Math.PI*2);
}
rota = Body._rotation * (Math.PI/180);
if (rota < 0) {
rota = rota + (Math.PI*2);
} else if (rota >= (Math.PI*2)) {
rota = rota - (Math.PI*2);
}
orota = waypoint - rota;
if (orota < 0) {
orota = orota + (Math.PI*2);
} else if (orota >= (Math.PI*2)) {
orota = orota - (Math.PI*2);
}
if ((rota < ((waypoint - (turning / 2)) + turning)) && (rota > (waypoint - (turning / 2)))) {
rota = waypoint;
} else if (orota <= Math.PI) {
rota = rota + turning;
} else {
rota = rota - turning;
}
if (Body._rotation == 0) {
Body._rotation++;
rota = Body._rotation * (Math.PI/180);
}
Body._rotation = (rota * 180) / Math.PI;
if ((((Body._rotation > 0) && (lrot < 0)) && (lrot2 > 0)) || (((Body._rotation < 0) && (lrot > 0)) && (lrot2 < 0))) {
Body._rotation = 0;
}
FireArrow();
Direction();
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
Dead = true;
Death();
} else if (_root.Game.Flame.hitTest(this)) {
Dead = true;
Burn();
}
}
Scroll();
}
};
Symbol 337 MovieClip Frame 2
stop();
Symbol 337 MovieClip Frame 3
stop();
Symbol 337 MovieClip Frame 26
stop();
Symbol 337 MovieClip Frame 41
stop();
this.removeMovieClip();
Symbol 392 MovieClip Frame 1
Begun = false;
xStart = _x;
yStart = _y;
max = 12;
rate = -1;
Status = "Standing";
xspeed = 0;
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Begun) {
Begun = true;
gotoAndPlay ("Charge");
Status = "Charging";
} else if (Status == "Charging") {
if (xspeed < max) {
xspeed = xspeed + rate;
}
if (_x > (xStart - 400)) {
_x = (_x + xspeed);
} else {
Status = "Walking";
gotoAndPlay ("Walk");
}
} else {
xspeed = 0;
if (_x < xStart) {
_x = (_x + 2);
} else {
Status = "Stand";
gotoAndPlay ("Stand");
Begun = false;
}
}
}
};
Symbol 392 MovieClip Frame 2
stop();
Symbol 392 MovieClip Frame 22
gotoAndPlay (6);
Symbol 392 MovieClip Frame 38
gotoAndPlay ("Walk");
Symbol 402 MovieClip Frame 1
Direction = 4;
yDirection = 4;
Started = false;
MoveAmount = 200;
xStart = _x;
yStart = _y;
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Started) {
if (_root.Game.Player.hitTest(this)) {
Started = true;
}
} else {
if (_root.Game.Player.hitTest(this)) {
_root.Game.Player._y = _root.Game.Player._y + yDirection;
_root.Game.Player._x = _root.Game.Player._x + Direction;
_root.Jumped = false;
}
this._y = this._y + yDirection;
this._x = this._x + Direction;
if ((_x < xStart) || (_x > (xStart + (2 * MoveAmount)))) {
Direction = -Direction;
}
if ((_y < (yStart - MoveAmount)) || (_y > (yStart + MoveAmount))) {
yDirection = -yDirection;
}
}
}
};
Symbol 438 MovieClip [Explosion] Frame 12
this.removeMovieClip();
Symbol 439 MovieClip [FreeAngel] Frame 1
speed = 0;
max = 8;
yspeed = 0;
ymax = 8;
Dir = -0.5;
yDir = 0.5;
Begun = false;
Direction = "Left";
Status = "Stand";
StartTimer = 60;
ShurikenOb = new Object();
Timer = 40;
Dead = false;
Death = function () {
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Die");
};
Move = function () {
if (speed < max) {
if (speed > (-max)) {
speed = speed + Dir;
}
if (yspeed > (-max)) {
yspeed = yspeed + yDir;
}
}
};
Visible = function () {
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
_visible = false;
} else {
_visible = true;
}
};
ChooseDirection = function () {
if ((_x - _root.Game.Player._x) > 0) {
if (Status == "Stand") {
if (Direction == "Right") {
gotoAndPlay ("LeftStand");
}
}
if ((_x - _root.Game.Player._x) < 150) {
Dir = 0.5;
} else if ((_x - _root.Game.Player._x) >= 150) {
if ((_x - _root.Game.Player._x) >= 250) {
Dir = -0.5;
} else {
Dir = 0;
}
}
Direction = "Left";
} else if ((_x - _root.Game.Player._x) <= 0) {
if (Status == "Stand") {
if (Direction == "Left") {
gotoAndPlay ("RightStand");
}
}
if ((_x - _root.Game.Player._x) > -150) {
Dir = -0.5;
} else if ((_x - _root.Game.Player._x) <= -150) {
if ((_x - _root.Game.Player._x) <= -250) {
Dir = 0.5;
} else {
Dir = 0;
}
}
Direction = "Right";
}
if ((_y - _root.Game.Player._y) >= 200) {
yDir = -0.5;
} else if ((_y - _root.Game.Player._y) <= -200) {
yDir = 0.5;
} else {
yDir = 0;
yspeed = 0;
}
Move();
};
Attack = function () {
if (Timer > 0) {
Timer = Timer - 1;
if (Timer == (StartTimer - 38)) {
Status = "Stand";
}
} else {
Timer = StartTimer;
if (_visible) {
speed = 0;
Status = "Attacking";
gotoAndPlay(Direction + "Attack");
} else {
Status = "Stand";
gotoAndPlay(Direction + Status);
}
}
};
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Dead) {
Visible();
ChooseDirection();
Attack();
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
Dead = true;
Death();
} else if (_root.Game.Flame.hitTest(this)) {
Dead = true;
Death();
}
}
speed = speed * 0.95;
_x = (_x - (_root.Scrolling - speed));
_y = (_y - (_root.yScrolling - yspeed));
}
};
Symbol 439 MovieClip [FreeAngel] Frame 2
stop();
Symbol 439 MovieClip [FreeAngel] Frame 24
ShurikenOb._x = _x - 10;
ShurikenOb._y = _y - (_height / 2);
_root.id++;
_root.lightning_Sound.start();
Target = Math.atan((_x - _root.Game.Player._x) / (_root.Game.Player._y - _y));
if (_root.Game.Player._y > _y) {
Target = Target + Math.PI;
}
ShurikenOb._rotation = (180 * Target) / Math.PI;
_root.Game.attachMovie("BadLightning", "BadLightning" + _root.id, _root.id, ShurikenOb);
Symbol 439 MovieClip [FreeAngel] Frame 40
gotoAndPlay ("LeftStand");
Symbol 439 MovieClip [FreeAngel] Frame 41
stop();
Symbol 439 MovieClip [FreeAngel] Frame 63
ShurikenOb._x = _x + 10;
ShurikenOb._y = _y - (_height / 2);
_root.id++;
_root.lightning_Sound.start();
Target = Math.atan((_x - _root.Game.Player._x) / (_root.Game.Player._y - _y));
if (_root.Game.Player._y > _y) {
Target = Target + Math.PI;
}
ShurikenOb._rotation = (180 * Target) / Math.PI;
_root.Game.attachMovie("BadLightning", "BadLightning" + _root.id, _root.id, ShurikenOb);
Symbol 439 MovieClip [FreeAngel] Frame 79
gotoAndPlay ("RightStand");
Symbol 439 MovieClip [FreeAngel] Frame 92
stop();
this.removeMovieClip();
Symbol 443 MovieClip [Clang] Frame 1
_root.sword_Sound.start();
Symbol 443 MovieClip [Clang] Frame 4
this.removeMovieClip();
Symbol 446 MovieClip [badbossbullet] Frame 1
speed = 15;
this.onEnterFrame = function () {
_x = (_x + ((speed * Math.sin((_rotation * Math.PI) / 180)) - _root.Scrolling));
_y = (_y - ((speed * Math.cos((_rotation * Math.PI) / 180)) + _root.yScrolling));
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
this.removeMovieClip();
} else if (((_y - _root.Game.Player._y) > 450) || ((_y - _root.Game.Player._y) < -450)) {
this.removeMovieClip();
} else if (_root.Game.Player.HitArea.hitTest(this)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.Game.Player._alpha = 50;
_root.InvincibleTimer = 30;
} else {
_root.DieStatus = "Spark";
_root.Armour = 0;
}
}
}
};
Symbol 449 MovieClip [BadLightning] Frame 1
speed = 15;
this.onEnterFrame = function () {
_x = (_x + ((speed * Math.sin((_rotation * Math.PI) / 180)) - _root.Scrolling));
_y = (_y - ((speed * Math.cos((_rotation * Math.PI) / 180)) + _root.yScrolling));
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
this.removeMovieClip();
} else if (((_y - _root.Game.Player._y) > 450) || ((_y - _root.Game.Player._y) < -450)) {
this.removeMovieClip();
} else if (_root.Game.Player.HitArea.hitTest(this)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.Game.Player._alpha = 50;
_root.InvincibleTimer = 30;
} else {
_root.DieStatus = "Spark";
_root.Armour = 0;
}
}
}
};
Symbol 465 MovieClip Frame 1
Rate = 1;
RateMax = 10;
Direction = 0.5;
this.onEnterFrame = function () {
if (!_root.Pause) {
if (_root.Game.Player.hitTest(this)) {
_root.Game.Player._x = _root.Game.Player._x + Rate;
_root.Jumped = false;
}
this._x = this._x + Rate;
if ((Rate < RateMax) && (Rate > (-RateMax))) {
Rate = Rate - Direction;
} else {
Direction = -Direction;
Rate = Rate - Direction;
}
}
};
Symbol 469 MovieClip Frame 1
this.onEnterFrame = function () {
if (_root.Game.Player.hitTest(this)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.InvincibleTimer = 30;
} else {
_root.DieStatus = "Burn";
_root.Armour = 0;
}
}
}
};
Symbol 485 MovieClip Frame 1
speed = 0;
max = 8;
yspeed = 0;
ymax = 8;
Dir = -0.5;
yDir = 0.5;
Begun = false;
Direction = "Left";
Status = "Stand";
StartTimer = 60;
ShurikenOb = new Object();
Timer = 40;
Dead = false;
Death = function () {
_root.explode_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Die");
};
Move = function () {
if (speed < max) {
if (speed > (-max)) {
speed = speed + Dir;
}
if (yspeed > (-max)) {
yspeed = yspeed + yDir;
}
}
};
Visible = function () {
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
_visible = false;
} else {
_visible = true;
}
};
ChooseDirection = function () {
if ((_x - _root.Game.Player._x) > 0) {
if (Status == "Stand") {
if (Direction == "Right") {
gotoAndPlay ("LeftStand");
}
}
if ((_x - _root.Game.Player._x) < 150) {
Dir = 0.5;
} else if ((_x - _root.Game.Player._x) >= 150) {
if ((_x - _root.Game.Player._x) >= 250) {
Dir = -0.5;
} else {
Dir = 0;
}
}
Direction = "Left";
} else if ((_x - _root.Game.Player._x) <= 0) {
if (Status == "Stand") {
if (Direction == "Left") {
gotoAndPlay ("RightStand");
}
}
if ((_x - _root.Game.Player._x) > -150) {
Dir = -0.5;
} else if ((_x - _root.Game.Player._x) <= -150) {
if ((_x - _root.Game.Player._x) <= -250) {
Dir = 0.5;
} else {
Dir = 0;
}
}
Direction = "Right";
}
if ((_y - _root.Game.Player._y) >= 200) {
yDir = -0.5;
} else if ((_y - _root.Game.Player._y) <= -200) {
yDir = 0.5;
} else {
yDir = 0;
yspeed = 0;
}
Move();
};
Attack = function () {
if (Timer > 0) {
Timer = Timer - 1;
if (Timer == (StartTimer - 38)) {
Status = "Stand";
}
} else {
Timer = StartTimer;
if (_visible) {
speed = 0;
Status = "Attacking";
gotoAndPlay(Direction + "Attack");
} else {
Status = "Stand";
gotoAndPlay(Direction + Status);
}
}
};
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Dead) {
Visible();
if (!Begun) {
if (((_x - _root.Game.Player._x) < 300) && ((_x - _root.Game.Player._x) > -300)) {
if (((_y - _root.Game.Player._y) < 300) && ((_y - _root.Game.Player._y) > -300)) {
Begun = true;
gotoAndPlay ("LeftStand");
}
}
} else {
if (_y > (_root.Game.Player._y + 1000)) {
Begun = false;
Dead();
}
ChooseDirection();
Attack();
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
Dead = true;
Death();
} else if (_root.Game.Flame.hitTest(this)) {
Dead = true;
Death();
}
}
}
speed = speed * 0.95;
_x = (_x - (_root.Scrolling - speed));
_y = (_y - (_root.yScrolling - yspeed));
}
};
Symbol 485 MovieClip Frame 2
stop();
Symbol 485 MovieClip Frame 24
ShurikenOb._x = _x - 10;
ShurikenOb._y = _y - (_height / 2);
_root.id++;
Target = Math.atan((_x - _root.Game.Player._x) / (_root.Game.Player._y - _y));
if (_root.Game.Player._y > _y) {
Target = Target + Math.PI;
}
ShurikenOb._rotation = (180 * Target) / Math.PI;
_root.Game.attachMovie("BadLightning", "BadLightning" + _root.id, _root.id, ShurikenOb);
Symbol 485 MovieClip Frame 40
gotoAndPlay ("LeftStand");
Symbol 485 MovieClip Frame 41
stop();
Symbol 485 MovieClip Frame 63
ShurikenOb._x = _x + 10;
ShurikenOb._y = _y - (_height / 2);
_root.lightning_Sound.start();
_root.id++;
Target = Math.atan((_x - _root.Game.Player._x) / (_root.Game.Player._y - _y));
if (_root.Game.Player._y > _y) {
Target = Target + Math.PI;
}
ShurikenOb._rotation = (180 * Target) / Math.PI;
_root.Game.attachMovie("BadLightning", "BadLightning" + _root.id, _root.id, ShurikenOb);
Symbol 485 MovieClip Frame 79
gotoAndPlay ("RightStand");
Symbol 485 MovieClip Frame 92
stop();
Symbol 553 MovieClip Frame 1
Dead = false;
Burn = function () {
_root.killplant_Sound.start();
_root.TotalKills = _root.TotalKills + 1;
gotoAndPlay ("Burn");
};
Death = function () {
_root.TotalKills = _root.TotalKills + 1;
_root.killplant_Sound.start();
gotoAndPlay ("Die");
};
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Dead) {
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
Dead = true;
Death();
} else if (_root.Game.Flame.hitTest(this)) {
Dead = true;
Burn();
} else if (_root.Game.Player.HitArea.hitTest(this)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.InvincibleTimer = 30;
} else {
_root.DieStatus = "Slash";
_root.Armour = 0;
}
}
}
}
}
};
Symbol 553 MovieClip Frame 56
gotoAndPlay (2);
Symbol 553 MovieClip Frame 71
stop();
Symbol 553 MovieClip Frame 86
stop();
this.removeMovieClip();
Symbol 709 MovieClip Frame 1
Rate = 3;
Begun = false;
StartX = _x;
StartY = _y;
this.onEnterFrame = function () {
if (!_root.Pause) {
if (!Begun) {
if (_root.Game.Player.hitTest(this)) {
Begun = true;
}
} else {
if (_root.Game.Player.hitTest(this)) {
_root.Game.Player._x = _root.Game.Player._x + Rate;
_root.Jumped = false;
}
if (_x < (StartX + 2800)) {
this._x = this._x + Rate;
} else if (_y < (StartY + _height)) {
_y = (_y + 1);
}
}
}
};
Symbol 772 MovieClip Frame 1
speed = 0;
max = 8;
yspeed = 0;
ymax = 8;
Dir = -0.5;
yDir = 0.5;
Begun = false;
Direction = "Left";
Status = "Stand";
StartTimer = 100;
Timer = 50;
xOffset = 0;
Dead = false;
ClangOb = new Object();
Death = function () {
gotoAndPlay ("Die");
};
Move = function () {
if (speed < max) {
if (speed > (-max)) {
speed = speed + Dir;
}
if (yspeed > (-max)) {
yspeed = yspeed + yDir;
}
}
};
Visible = function () {
if (((_x - _root.Game.Player._x) > 450) || ((_x - _root.Game.Player._x) < -450)) {
_visible = false;
} else {
_visible = true;
}
};
ChooseDirection = function () {
if ((_x - _root.Game.Player._x) > 0) {
if (Status == "Stand") {
if (Direction == "Right") {
gotoAndPlay ("LeftStand");
}
if ((_x - _root.Game.Player._x) < 150) {
Dir = 0.5;
} else if ((_x - _root.Game.Player._x) >= 150) {
if ((_x - _root.Game.Player._x) >= 250) {
Dir = -0.5;
} else {
Dir = 0;
}
}
}
Direction = "Left";
} else if ((_x - _root.Game.Player._x) <= 0) {
if (Status == "Stand") {
if (Direction == "Left") {
gotoAndPlay ("RightStand");
}
if ((_x - _root.Game.Player._x) > -150) {
Dir = -0.5;
} else if ((_x - _root.Game.Player._x) <= -150) {
if ((_x - _root.Game.Player._x) <= -250) {
Dir = 0.5;
} else {
Dir = 0;
}
}
}
Direction = "Right";
}
if ((_y - _root.Game.Player._y) >= 50) {
yDir = -0.5;
} else if ((_y - _root.Game.Player._y) <= -50) {
yDir = 0.5;
} else {
yDir = 0;
yspeed = 0;
}
Move();
};
Attack = function () {
if (Timer > 0) {
Timer = Timer - 1;
if (Timer == (StartTimer - 48)) {
Status = "Stand";
} else if (Timer == (StartTimer - 21)) {
if (Direction == "Left") {
speed = (-max) * 4;
} else {
speed = max * 4;
}
}
} else {
Timer = StartTimer;
if (_visible) {
Status = "Attacking";
_root.slash_Sound.start();
gotoAndPlay(Direction + "Attack");
} else {
Status = "Stand";
gotoAndPlay(Direction + Status);
}
}
};
this.onEnterFrame = function () {
if (!_root.Pause) {
Visible();
if (!Begun) {
if (((_x - _root.Game.Player._x) < 300) && ((_x - _root.Game.Player._x) > -300)) {
if (((_y - _root.Game.Player._y) < 300) && ((_y - _root.Game.Player._y) > -300)) {
Begun = true;
gotoAndPlay ("LeftStand");
}
}
} else {
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
speed = speed / 2;
if (_root.Game.Player._x <= _x) {
_root.Player_xOffset = 2;
xOffset = max;
} else {
_root.Player_xOffset = -2;
xOffset = -max;
}
ClangOb._x = _x;
ClangOb._y = _y - 100;
_root.id++;
_root.Game.attachMovie("Clang", "Clang" + _root.id, _root.id, ClangOb);
} else if (_root.Game.Player.HitArea.hitTest(this.HitZone)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.Game.Player._alpha = 50;
_root.InvincibleTimer = 30;
} else {
_root.DieStatus = "Burn";
_root.Armour = 0;
}
}
}
if (_y > (_root.Game.Player._y + 1000)) {
Begun = false;
Dead();
}
ChooseDirection();
Attack();
}
if (xOffset > 0) {
xOffset = xOffset - 1;
} else if (xOffset < 0) {
xOffset = xOffset + 1;
}
speed = speed + xOffset;
speed = speed * 0.95;
_x = (_x - (_root.Scrolling - speed));
_y = (_y - (_root.yScrolling - yspeed));
}
};
Symbol 772 MovieClip Frame 2
stop();
Symbol 772 MovieClip Frame 50
gotoAndPlay ("LeftStand");
Symbol 772 MovieClip Frame 51
stop();
Symbol 772 MovieClip Frame 99
gotoAndPlay ("RightStand");
Symbol 852 MovieClip [Flame] Frame 1
if (_rotation < 0) {
Dir = -20;
} else {
Dir = 20;
}
this.onEnterFrame = function () {
_x = (_x + Dir);
};
Symbol 852 MovieClip [Flame] Frame 11
this.removeMovieClip();
Symbol 857 MovieClip Frame 1
Ob = new Object();
Ob._x = _root.Game.Spawn._x;
Ob._y = _root.Game.Spawn._y;
_root.id++;
_root.Game.attachMovie("FreeAngel", "FreeAngel" + _root.id, _root.id, Ob);
Symbol 861 MovieClip Frame 1
Ob = new Object();
Ob._x = _root.Game.Spawn2._x;
Ob._y = _root.Game.Spawn2._y;
_root.id++;
_root.Game.attachMovie("FreeSword", "FreeAngel" + _root.id, _root.id, Ob);
Symbol 893 MovieClip Frame 1
stop();
Symbol 893 MovieClip Frame 10
gotoAndPlay (1);
Symbol 893 MovieClip Frame 11
stop();
Symbol 896 MovieClip Frame 1
dir = -1;
speed = 1;
max = 12;
Begun = false;
StartX = _x + 50;
Life = 50;
Alive = true;
count = 0;
Dead = function () {
if (Alive) {
_root.TotalKills = _root.TotalKills + 1;
Alive = false;
_root.Pause = true;
this.Crown.gotoAndStop(11);
gotoAndPlay ("Death");
}
};
this.onEnterFrame = function () {
_x = (_x - _root.Scrolling);
_y = (_y - _root.yScrolling);
if (!_root.Pause) {
if (Alive) {
_x = (_x + (dir * speed));
if (speed < max) {
speed++;
}
if (count < 300) {
count = count + 1;
} else {
count = 0;
_x = (_x - (dir * speed));
speed = 0;
dir = -dir;
}
if (_root.Game.Player.AttackZoneHero.hitTest(this.Crown)) {
_root.punch2_Sound.start();
this.Crown.gotoAndStop(2);
Life = Life - 1;
Life_txt.text = Life;
if (Life < 0) {
Dead();
}
} else if (_root.Game.Flame.hitTest(this.Crown)) {
this.Crown.gotoAndStop(2);
_root.punch2_Sound.start();
Life = Life - 1;
Life_txt.text = Life;
if (Life < 0) {
Dead();
}
}
}
}
};
Symbol 896 MovieClip Frame 9
gotoAndPlay (2);
Symbol 896 MovieClip Frame 45
_root.Pause = false;
Ob = new Object();
Ob._x = _root.Game.Player._x - 20;
Ob._y = _root.Game.Player._y - 80;
_root.Game.attachMovie("Explosion", "DeadDuck", 9999, Ob);
stop();
Symbol 898 MovieClip Frame 1
_visible = false;
this.onEnterFrame = function () {
_x = (_x - _root.Scrolling);
_y = (_y - _root.yScrolling);
};
Symbol 904 MovieClip [Stage45] Frame 1
_root.attachMovie("Duck", "Duck", 50);
Symbol 984 MovieClip [Duck] Frame 46
this.removeMovieClip();
Symbol 986 MovieClip [Emperor] Frame 46
this.removeMovieClip();
Symbol 1003 MovieClip Frame 1
ClangOb = new Object();
this.onEnterFrame = function () {
if (!_root.Pause) {
_x = (_x - _root.Scrolling);
_y = (_y - _root.yScrolling);
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
if (_root.Game.Player._x <= _x) {
_root.Player_xOffset = 2;
xOffset = max / 2;
} else {
_root.Player_xOffset = -2;
xOffset = (-max) / 2;
}
ClangOb._x = _x;
ClangOb._y = _root.Game.Player._y - 50;
_root.id++;
_root.Game.attachMovie("Clang", "Clang" + _root.id, _root.id, ClangOb);
} else if (_root.Game.Player.HitArea.hitTest(this)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.InvincibleTimer = 30;
} else {
_root.DieStatus = "Slash";
_root.Armour = 0;
}
}
}
}
};
Symbol 1003 MovieClip Frame 11
gotoAndPlay (2);
Symbol 1004 MovieClip Frame 1
ClangOb = new Object();
StartX = _x;
dir = -6;
this.onEnterFrame = function () {
if (!_root.Pause) {
if (_x < (StartX - 1000)) {
dir = -6;
} else if (_x > StartX) {
dir = 6;
}
_x = (_x - (_root.Scrolling - dir));
_y = (_y - _root.yScrolling);
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
if (_root.Game.Player._x <= _x) {
_root.Player_xOffset = 2;
} else {
_root.Player_xOffset = -2;
}
ClangOb._x = _x;
ClangOb._y = _root.Game.Player._y - 50;
_root.id++;
_root.Game.attachMovie("Clang", "Clang" + _root.id, _root.id, ClangOb);
} else if (_root.Game.Player.HitArea.hitTest(this)) {
if (_root.InvincibleTimer == 0) {
if (_root.Armour > 1) {
_root.Armour = 1;
_root.Game.Player.Arm1.gotoAndStop(_root.Armour);
_root.Game.Player.Arm2.gotoAndStop(_root.Armour);
_root.Game.Player.Leg1.gotoAndStop(_root.Armour);
_root.Game.Player.Leg2.gotoAndStop(_root.Armour);
_root.Game.Player.Head.gotoAndStop(_root.Armour);
_root.Game.Player.Body.gotoAndStop(_root.Armour);
_root.Game.Player.Face.gotoAndStop(1);
_root.Game.Player.Weapon.gotoAndStop(_root.Armour);
_root.InvincibleTimer = 30;
} else {
_root.DieStatus = "Slash";
_root.Armour = 0;
}
}
}
}
};
Symbol 1004 MovieClip Frame 11
gotoAndPlay (2);
Symbol 1010 MovieClip Frame 1
turning_speed = 5;
targ = _root.Game.Player;
StartCount = 30;
Count = 30;
ArrowOb = new Object();
yspeed = 0;
Dir = 0;
ymax = 15;
stop();
ClangOb = new Object();
Boss._rotation = -90;
Life = 50;
Dead = false;
Fall = function () {
while (_root.Game.Ground.hitTest(_x, _y, true)) {
_y = (_y-1);
yspeed = 0;
}
if (!_root.Game.Ground.hitTest(_x, _y + 1, true)) {
if (yspeed < ymax) {
yspeed = yspeed + 1;
if (yspeed > ymax) {
yspeed = ymax;
}
}
} else {
yspeed = 0;
}
};
FireArrow = function () {
if (Count > 0) {
Count = Count - 1;
if (Count == (StartCount + 16)) {
_root.m16_Sound.start();
ArrowOb._x = _x + (200 * Math.sin((Body._rotation * Math.PI) / 180));
ArrowOb._y = _y - (195 * Math.cos((Body._rotation * Math.PI) / 180));
ArrowOb._rotation = Body._rotation;
_root.id++;
_root.Game.attachMovie("badbossbullet", "badbossbullet" + _root.id, _root.id, ArrowOb);
} else if ((Count == (StartCount + 12)) || (Count == (StartCount + 8))) {
ArrowOb._x = _x + (200 * Math.sin((Body._rotation * Math.PI) / 180));
ArrowOb._y = _y - (195 * Math.cos((Body._rotation * Math.PI) / 180));
ArrowOb._rotation = Body._rotation;
_root.id++;
_root.Game.attachMovie("badbossbullet", "badbossbullet" + _root.id, _root.id, ArrowOb);
}
} else {
Count = StartCount + 45;
}
};
Direction = function () {
if ((_x - _root.Game.Player._x) > 150) {
if (Dir == 0) {
gotoAndPlay (3);
}
Dir = 3;
} else if ((_x - _root.Game.Player._x) < -150) {
if (Dir == 0) {
gotoAndPlay (29);
}
Dir = -3;
} else {
if (Dir == 3) {
gotoAndPlay (2);
} else if (Dir == -3) {
gotoAndPlay (28);
}
Dir = 0;
}
};
Burn = function () {
gotoAndPlay ("Burn");
};
Scroll = function () {
_x = (_x - (_root.Scrolling + Dir));
_y = (_y - _root.yScrolling);
};
turning = turning_speed * (Math.PI/180);
this.onEnterFrame = function () {
if (!_root.Pause) {
lrot2 = lrot;
lrot = Body._rotation;
waypoint = Math.atan((_x - targ._x) / (targ._y - _y));
if (targ._y > _y) {
waypoint = waypoint + Math.PI;
}
if (waypoint < 0) {
waypoint = waypoint + (Math.PI*2);
} else if (waypoint >= (Math.PI*2)) {
waypoint = waypoint - (Math.PI*2);
}
rota = Body._rotation * (Math.PI/180);
if (rota < 0) {
rota = rota + (Math.PI*2);
} else if (rota >= (Math.PI*2)) {
rota = rota - (Math.PI*2);
}
orota = waypoint - rota;
if (orota < 0) {
orota = orota + (Math.PI*2);
} else if (orota >= (Math.PI*2)) {
orota = orota - (Math.PI*2);
}
if ((rota < ((waypoint - (turning / 2)) + turning)) && (rota > (waypoint - (turning / 2)))) {
rota = waypoint;
} else if (orota <= Math.PI) {
rota = rota + turning;
} else {
rota = rota - turning;
}
if (Body._rotation == 0) {
Body._rotation--;
rota = Body._rotation * (Math.PI/180);
}
Body._rotation = (rota * 180) / Math.PI;
if ((((Body._rotation > 0) && (lrot < 0)) && (lrot2 > 0)) || (((Body._rotation < 0) && (lrot > 0)) && (lrot2 < 0))) {
Body._rotation = 0;
}
FireArrow();
Direction();
if (_root.Game.Player.AttackZoneHero.hitTest(this)) {
if (Life > 0) {
Life = Life - 1;
Life_txt.text = Life;
if (_root.Game.Player._x <= _x) {
_root.Player_xOffset = 5;
ClangOb._x = _root.Game.Player._x + 80;
} else {
_root.Player_xOffset = -5;
ClangOb._x = _root.Game.Player._x - 80;
}
ClangOb._y = _root.Game.Player._y - 50;
_root.id++;
_root.Game.attachMovie("Clang", "Clang" + _root.id, _root.id, ClangOb);
} else {
_root.TotalKills = _root.TotalKills + 1;
_root.FinishGame = true;
}
} else if (_root.Game.Flame.hitTest(this)) {
if (Life > 0) {
Life = Life - 1;
Life_txt.text = Life;
Burn();
} else {
_root.FinishGame = true;
}
}
Scroll();
}
};
Symbol 1010 MovieClip Frame 2
stop();
Symbol 1010 MovieClip Frame 27
gotoAndPlay (3);
Symbol 1010 MovieClip Frame 28
stop();
Symbol 1010 MovieClip Frame 53
gotoAndPlay (29);
Symbol 1014 MovieClip [Stage80] Frame 1
_root.attachMovie("Emperor", "Emperor", 50);
Symbol 1080 MovieClip [__Packages.MochiAd] Frame 0
class MochiAd
{
function MochiAd () {
}
static function getVersion() {
return("2.7");
}
static function showPreGameAd(options) {
var _local26 = {clip:_root, ad_timeout:3000, fadeout_time:250, regpt:"o", method:"showPreloaderAd", color:16747008, background:16777161, outline:13994812, no_progress_bar:false, ad_started:function () {
this.clip.stop();
}, ad_finished:function () {
this.clip.play();
}, ad_failed:function () {
trace("[MochiAd] Couldn't load an ad, make sure that your game's local security sandbox is configured for Access Network Only and that you are not using ad blocking software");
}, ad_loaded:function (width, height) {
}, ad_skipped:function () {
}, ad_progress:function (percent) {
}};
options = _parseOptions(options, _local26);
if ("c862232051e0a94e1c3609b3916ddb17".substr(0) == "dfeada81ac97cde83665f81c12da7def") {
options.ad_started();
options.ad_finished();
return(undefined);
}
var clip = options.clip;
var _local22 = 11000;
var _local25 = options.ad_timeout;
delete options.ad_timeout;
var fadeout_time = options.fadeout_time;
delete options.fadeout_time;
if (!load(options)) {
options.ad_failed();
options.ad_finished();
return(undefined);
}
options.ad_started();
var mc = clip._mochiad;
mc.onUnload = function () {
options.ad_finished();
};
var _local14 = _getRes(options);
var _local4 = _local14[0];
var _local13 = _local14[1];
mc._x = _local4 * 0.5;
mc._y = _local13 * 0.5;
var chk = mc.createEmptyMovieClip("_mochiad_wait", 3);
chk._x = _local4 * -0.5;
chk._y = _local13 * -0.5;
var _local6 = chk.createEmptyMovieClip("_mochiad_bar", 4);
if (options.no_progress_bar) {
_local6._visible = false;
delete options.no_progress_bar;
} else {
_local6._x = 10;
_local6._y = _local13 - 20;
}
var _local21 = options.color;
delete options.color;
var _local19 = options.background;
delete options.background;
var _local23 = options.outline;
delete options.outline;
var _local5 = _local6.createEmptyMovieClip("_outline", 1);
_local5.beginFill(_local19);
_local5.moveTo(0, 0);
_local5.lineTo(_local4 - 20, 0);
_local5.lineTo(_local4 - 20, 10);
_local5.lineTo(0, 10);
_local5.lineTo(0, 0);
_local5.endFill();
var _local3 = _local6.createEmptyMovieClip("_inside", 2);
_local3.beginFill(_local21);
_local3.moveTo(0, 0);
_local3.lineTo(_local4 - 20, 0);
_local3.lineTo(_local4 - 20, 10);
_local3.lineTo(0, 10);
_local3.lineTo(0, 0);
_local3.endFill();
_local3._xscale = 0;
var _local7 = _local6.createEmptyMovieClip("_outline", 3);
_local7.lineStyle(0, _local23, 100);
_local7.moveTo(0, 0);
_local7.lineTo(_local4 - 20, 0);
_local7.lineTo(_local4 - 20, 10);
_local7.lineTo(0, 10);
_local7.lineTo(0, 0);
chk.ad_msec = _local22;
chk.ad_timeout = _local25;
chk.started = getTimer();
chk.showing = false;
chk.last_pcnt = 0;
chk.fadeout_time = fadeout_time;
chk.fadeFunction = function () {
var _local2 = 100 * (1 - ((getTimer() - this.fadeout_start) / this.fadeout_time));
if (_local2 > 0) {
this._parent._alpha = _local2;
} else {
var _local3 = this._parent._parent;
MochiAd.unload(_local3);
delete this.onEnterFrame;
}
};
mc.lc.regContLC = function (lc_name) {
mc._containerLCName = lc_name;
};
var sendHostProgress = false;
mc.lc.sendHostLoadProgress = function (lc_name) {
sendHostProgress = true;
};
mc.lc.adLoaded = options.ad_loaded;
mc.lc.adSkipped = options.ad_skipped;
mc.lc.adjustProgress = function (msec) {
var _local2 = this.mc._mochiad_wait;
_local2.server_control = true;
_local2.started = getTimer();
_local2.ad_msec = msec;
};
mc.lc.rpc = function (callbackID, arg) {
MochiAd.rpc(clip, callbackID, arg);
};
mc.rpcTestFn = function (s) {
trace("[MOCHIAD rpcTestFn] " + s);
return(s);
};
chk.onEnterFrame = function () {
var _local6 = this._parent._parent;
var _local11 = this._parent._mochiad_ctr;
var _local5 = getTimer() - this.started;
var _local3 = false;
var _local4 = _local6.getBytesTotal();
var _local8 = _local6.getBytesLoaded();
var _local2 = (100 * _local8) / _local4;
var _local10 = (100 * _local5) / chk.ad_msec;
var _local9 = this._mochiad_bar._inside;
var _local13 = Math.min(100, Math.min(_local2 || 0, _local10));
_local13 = Math.max(this.last_pcnt, _local13);
this.last_pcnt = _local13;
_local9._xscale = _local13;
options.ad_progress(_local13);
if (sendHostProgress) {
clip._mochiad.lc.send(clip._mochiad._containerLCName, "notify", {id:"hostLoadPcnt", pcnt:_local2});
if (_local2 == 100) {
sendHostProgress = false;
}
}
if (!chk.showing) {
var _local7 = _local11.getBytesTotal();
if ((_local7 > 0) || (typeof(_local7) == "undefined")) {
chk.showing = true;
chk.started = getTimer();
} else if ((_local5 > chk.ad_timeout) && (_local2 == 100)) {
options.ad_failed();
_local3 = true;
}
}
if (_local5 > chk.ad_msec) {
_local3 = true;
}
if (((_local4 > 0) && (_local8 >= _local4)) && (_local3)) {
if (this.server_control) {
delete this.onEnterFrame;
} else {
this.fadeout_start = getTimer();
this.onEnterFrame = chk.fadeFunction;
}
}
};
}
static function showClickAwayAd(options) {
var _local9 = {clip:_root, ad_timeout:2000, fadeout_time:250, regpt:"o", method:"showClickAwayAd", res:"300x250", no_bg:true, ad_started:function () {
}, ad_finished:function () {
}, ad_loaded:function (width, height) {
}, ad_failed:function () {
trace("[MochiAd] Couldn't load an ad, make sure that your game's local security sandbox is configured for Access Network Only and that you are not using ad blocking software");
}, ad_skipped:function () {
}};
options = _parseOptions(options, _local9);
var clip = options.clip;
var _local8 = options.ad_timeout;
delete options.ad_timeout;
if (!load(options)) {
options.ad_failed();
options.ad_finished();
return(undefined);
}
options.ad_started();
var mc = clip._mochiad;
mc.onUnload = function () {
options.ad_finished();
};
var _local4 = _getRes(options);
var _local10 = _local4[0];
var _local7 = _local4[1];
mc._x = _local10 * 0.5;
mc._y = _local7 * 0.5;
var chk = mc.createEmptyMovieClip("_mochiad_wait", 3);
chk.ad_timeout = _local8;
chk.started = getTimer();
chk.showing = false;
mc.lc.adLoaded = options.ad_loaded;
mc.lc.adSkipped = options.ad_skipped;
mc.lc.rpc = function (callbackID, arg) {
MochiAd.rpc(clip, callbackID, arg);
};
mc.rpcTestFn = function (s) {
trace("[MOCHIAD rpcTestFn] " + s);
return(s);
};
var _local20 = false;
mc.lc.regContLC = function (lc_name) {
mc._containerLCName = lc_name;
};
chk.onEnterFrame = function () {
var _local5 = this._parent._mochiad_ctr;
var _local4 = getTimer() - this.started;
var _local2 = false;
if (!chk.showing) {
var _local3 = _local5.getBytesTotal();
if ((_local3 > 0) || (typeof(_local3) == "undefined")) {
_local2 = true;
chk.showing = true;
chk.started = getTimer();
} else if (_local4 > chk.ad_timeout) {
options.ad_failed();
_local2 = true;
}
}
if (_local2) {
delete this.onEnterFrame;
}
};
}
static function showInterLevelAd(options) {
var _local13 = {clip:_root, ad_timeout:2000, fadeout_time:250, regpt:"o", method:"showTimedAd", ad_started:function () {
this.clip.stop();
}, ad_finished:function () {
this.clip.play();
}, ad_failed:function () {
trace("[MochiAd] Couldn't load an ad, make sure that your game's local security sandbox is configured for Access Network Only and that you are not using ad blocking software");
}, ad_loaded:function (width, height) {
}, ad_skipped:function () {
}};
options = _parseOptions(options, _local13);
var clip = options.clip;
var _local10 = 11000;
var _local12 = options.ad_timeout;
delete options.ad_timeout;
var fadeout_time = options.fadeout_time;
delete options.fadeout_time;
if (!load(options)) {
options.ad_failed();
options.ad_finished();
return(undefined);
}
options.ad_started();
var mc = clip._mochiad;
mc.onUnload = function () {
options.ad_finished();
};
var _local5 = _getRes(options);
var _local14 = _local5[0];
var _local11 = _local5[1];
mc._x = _local14 * 0.5;
mc._y = _local11 * 0.5;
var chk = mc.createEmptyMovieClip("_mochiad_wait", 3);
chk.ad_msec = _local10;
chk.ad_timeout = _local12;
chk.started = getTimer();
chk.showing = false;
chk.fadeout_time = fadeout_time;
chk.fadeFunction = function () {
var _local2 = 100 * (1 - ((getTimer() - this.fadeout_start) / this.fadeout_time));
if (_local2 > 0) {
this._parent._alpha = _local2;
} else {
var _local3 = this._parent._parent;
MochiAd.unload(_local3);
delete this.onEnterFrame;
}
};
mc.lc.adLoaded = options.ad_loaded;
mc.lc.adSkipped = options.ad_skipped;
mc.lc.adjustProgress = function (msec) {
var _local2 = this.mc._mochiad_wait;
_local2.server_control = true;
_local2.started = getTimer();
_local2.ad_msec = msec - 250;
};
mc.lc.rpc = function (callbackID, arg) {
MochiAd.rpc(clip, callbackID, arg);
};
mc.rpcTestFn = function (s) {
trace("[MOCHIAD rpcTestFn] " + s);
return(s);
};
chk.onEnterFrame = function () {
var _local5 = this._parent._mochiad_ctr;
var _local4 = getTimer() - this.started;
var _local2 = false;
if (!chk.showing) {
var _local3 = _local5.getBytesTotal();
if ((_local3 > 0) || (typeof(_local3) == "undefined")) {
chk.showing = true;
chk.started = getTimer();
} else if (_local4 > chk.ad_timeout) {
options.ad_failed();
_local2 = true;
}
}
if (_local4 > chk.ad_msec) {
_local2 = true;
}
if (_local2) {
if (this.server_control) {
delete this.onEnterFrame;
} else {
this.fadeout_start = getTimer();
this.onEnterFrame = this.fadeFunction;
}
}
};
}
static function showPreloaderAd(options) {
trace("[MochiAd] DEPRECATED: showPreloaderAd was renamed to showPreGameAd in 2.0");
showPreGameAd(options);
}
static function showTimedAd(options) {
trace("[MochiAd] DEPRECATED: showTimedAd was renamed to showInterLevelAd in 2.0");
showInterLevelAd(options);
}
static function _allowDomains(server) {
var _local1 = server.split("/")[2].split(":")[0];
if (System.security) {
if (System.security.allowDomain) {
System.security.allowDomain("*");
System.security.allowDomain(_local1);
}
if (System.security.allowInsecureDomain) {
System.security.allowInsecureDomain("*");
System.security.allowInsecureDomain(_local1);
}
}
return(_local1);
}
static function load(options) {
var _local13 = {clip:_root, server:"http://x.mochiads.com/srv/1/", method:"load", depth:10333, id:"_UNKNOWN_"};
options = _parseOptions(options, _local13);
options.swfv = options.clip.getSWFVersion() || 6;
options.mav = getVersion();
var _local9 = options.clip;
if (!_isNetworkAvailable()) {
return(null);
}
if (_local9._mochiad_loaded) {
return(null);
}
var _local12 = options.depth;
delete options.depth;
var _local6 = _local9.createEmptyMovieClip("_mochiad", _local12);
var _local11 = _getRes(options);
options.res = (_local11[0] + "x") + _local11[1];
options.server = options.server + options.id;
delete options.id;
_local9._mochiad_loaded = true;
var _local4 = _local6.createEmptyMovieClip("_mochiad_ctr", 1);
for (var _local7 in options) {
_local4[_local7] = options[_local7];
}
var _local10 = _local4.server;
delete _local4.server;
var _local14 = _allowDomains(_local10);
_local6.onEnterFrame = function () {
if (this._mochiad_ctr._url != this._url) {
this.onEnterFrame = function () {
if (!this._mochiad_ctr) {
delete this.onEnterFrame;
MochiAd.unload(this._parent);
}
};
}
};
var _local5 = new LocalConnection();
var _local8 = ["", Math.floor(new Date().getTime()), random(999999)].join("_");
_local5.mc = _local6;
_local5.name = _local8;
_local5.hostname = _local14;
_local5.allowDomain = function (d) {
return(true);
};
_local5.allowInsecureDomain = _local5.allowDomain;
_local5.connect(_local8);
_local6.lc = _local5;
_local4.lc = _local8;
_local4.st = getTimer();
_local4.loadMovie(_local10 + ".swf", "POST");
return(_local6);
}
static function unload(clip) {
if (typeof(clip) == "undefined") {
clip = _root;
}
if (clip.clip && (clip.clip._mochiad)) {
clip = clip.clip;
}
if (!clip._mochiad) {
return(false);
}
if (clip._mochiad._containerLCName != undefined) {
clip._mochiad.lc.send(clip._mochiad._containerLCName, "notify", {id:"unload"});
}
clip._mochiad.removeMovieClip();
delete clip._mochiad_loaded;
delete clip._mochiad;
return(true);
}
static function _isNetworkAvailable() {
if (System.security) {
var _local1 = System.security;
if (_local1.sandboxType == "localWithFile") {
return(false);
}
}
return(true);
}
static function _getRes(options) {
var _local3 = options.clip.getBounds();
var _local2 = 0;
var _local1 = 0;
if (typeof(options.res) != "undefined") {
var _local4 = options.res.split("x");
_local2 = parseFloat(_local4[0]);
_local1 = parseFloat(_local4[1]);
} else {
_local2 = _local3.xMax - _local3.xMin;
_local1 = _local3.yMax - _local3.yMin;
}
if ((_local2 == 0) || (_local1 == 0)) {
_local2 = Stage.width;
_local1 = Stage.height;
}
return([_local2, _local1]);
}
static function _parseOptions(options, defaults) {
var _local4 = {};
for (var _local8 in defaults) {
_local4[_local8] = defaults[_local8];
}
if (options) {
for (var _local8 in options) {
_local4[_local8] = options[_local8];
}
}
if (_root.mochiad_options) {
var _local5 = _root.mochiad_options.split("&");
var _local2 = 0;
while (_local2 < _local5.length) {
var _local3 = _local5[_local2].split("=");
_local4[unescape(_local3[0])] = unescape(_local3[1]);
_local2++;
}
}
if (_local4.id == "test") {
trace("[MochiAd] WARNING: Using the MochiAds test identifier, make sure to use the code from your dashboard, not this example!");
}
return(_local4);
}
static function rpc(clip, callbackID, arg) {
switch (arg.id) {
case "setValue" :
setValue(clip, arg.objectName, arg.value);
break;
case "getValue" :
var _local4 = getValue(clip, arg.objectName);
clip._mochiad.lc.send(clip._mochiad._containerLCName, "rpcResult", callbackID, _local4);
break;
case "runMethod" :
var _local3 = runMethod(clip, arg.method, arg.args);
clip._mochiad.lc.send(clip._mochiad._containerLCName, "rpcResult", callbackID, _local3);
break;
default :
trace("[mochiads rpc] unknown rpc id: " + arg.id);
}
}
static function setValue(base, objectName, value) {
var _local2 = objectName.split(".");
var _local1;
_local1 = 0;
while (_local1 < (_local2.length - 1)) {
if ((base[_local2[_local1]] == undefined) || (base[_local2[_local1]] == null)) {
return(undefined);
}
base = base[_local2[_local1]];
_local1++;
}
base[_local2[_local1]] = value;
}
static function getValue(base, objectName) {
var _local2 = objectName.split(".");
var _local1;
_local1 = 0;
while (_local1 < (_local2.length - 1)) {
if ((base[_local2[_local1]] == undefined) || (base[_local2[_local1]] == null)) {
return(undefined);
}
base = base[_local2[_local1]];
_local1++;
}
return(base[_local2[_local1]]);
}
static function runMethod(base, methodName, argsArray) {
var _local2 = methodName.split(".");
var _local1;
_local1 = 0;
while (_local1 < (_local2.length - 1)) {
if ((base[_local2[_local1]] == undefined) || (base[_local2[_local1]] == null)) {
return(undefined);
}
base = base[_local2[_local1]];
_local1++;
}
if (typeof(base[_local2[_local1]]) == "function") {
return(base[_local2[_local1]].apply(base, argsArray));
}
return(undefined);
}
}