Section 1
//bgArt_3 (kickingButt_fla.bgArt_3)
package kickingButt_fla {
import flash.display.*;
public dynamic class bgArt_3 extends MovieClip {
public function bgArt_3(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package kickingButt_fla
Section 2
//bgFrame_18 (kickingButt_fla.bgFrame_18)
package kickingButt_fla {
import flash.display.*;
public dynamic class bgFrame_18 extends MovieClip {
public function bgFrame_18(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package kickingButt_fla
Section 3
//body_16 (kickingButt_fla.body_16)
package kickingButt_fla {
import flash.display.*;
public dynamic class body_16 extends MovieClip {
public function body_16(){
addFrameScript(0, frame1, 15, frame16, 30, frame31, 45, frame46, 60, frame61, 75, frame76);
}
function frame1(){
stop();
}
function frame16(){
stop();
}
function frame31(){
stop();
}
function frame46(){
stop();
}
function frame61(){
stop();
}
function frame76(){
stop();
}
}
}//package kickingButt_fla
Section 4
//charZombie_25 (kickingButt_fla.charZombie_25)
package kickingButt_fla {
import flash.display.*;
public dynamic class charZombie_25 extends MovieClip {
public function charZombie_25(){
addFrameScript(0, frame1, 15, frame16);
}
function frame1(){
stop();
}
function frame16(){
stop();
}
}
}//package kickingButt_fla
Section 5
//cloud_7 (kickingButt_fla.cloud_7)
package kickingButt_fla {
import flash.display.*;
public dynamic class cloud_7 extends MovieClip {
public function cloud_7(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package kickingButt_fla
Section 6
//hand_15 (kickingButt_fla.hand_15)
package kickingButt_fla {
import flash.display.*;
public dynamic class hand_15 extends MovieClip {
public function hand_15(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package kickingButt_fla
Section 7
//itemFloor_8 (kickingButt_fla.itemFloor_8)
package kickingButt_fla {
import flash.display.*;
public dynamic class itemFloor_8 extends MovieClip {
public function itemFloor_8(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package kickingButt_fla
Section 8
//MainTimeline (kickingButt_fla.MainTimeline)
package kickingButt_fla {
import flash.events.*;
import flash.display.*;
import flash.text.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.geom.*;
import flash.media.*;
import flash.net.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.system.*;
import flash.ui.*;
import flash.utils.*;
import flash.xml.*;
public dynamic class MainTimeline extends MovieClip {
public var modeText:TextField;
public var spawnPlank3:MovieClip;
public var bgArt:MovieClip;
public var labelCleared:MovieClip;
public var spawnPlank1:MovieClip;
public var spawnSacro2:MovieClip;
public var itemFloor:MovieClip;
public var spawnSacro3:MovieClip;
public var btnIntroStart:introStartButton;
public var spawnSacro1:MovieClip;
public var loader_mc:movie_mc;
public var loaded_txt:TextField;
public var textPaused:MovieClip;
public var labelLevelStart:MovieClip;
public var bgFrame:MovieClip;
public var girl:MovieClip;
public var labelGameOver:MovieClip;
public var spawnPrisoner1:MovieClip;
public var spawnZombie1:MovieClip;
public var spawnPrisoner2:MovieClip;
public var spawnPrisoner3:MovieClip;
public var spawnPlank4:MovieClip;
public var cloud:MovieClip;
public var flyingKick:MovieClip;
public var spawnZombie2:MovieClip;
public var spawnPlank2:MovieClip;
public var myKey;
public var iBlockCounter;
public var iClothingOffset;
public var iKickCounter;
public var bGameOver;
public var iLevel;
public var bLevelCleared;
public var iGirlHitCounter;
public var iGirlFallYmod;
public var iGirlFallDirection;
public var iImmunityCountdown;
public var iEasyModeMultiplier;
public var bPaused;
public var iItemDirection;
public var iItemType;
public var iMaxEnemies;
public var iSpawnInterval;
public var iSpawnCountdown;
public var iEnemiesTillKey;
public var iMobsKilled;
public var iEnemyHitRangeExtend;
public var enemyArray:Array;
public var enemyMobType:Array;
public var enemyClothingOffset:Array;
public var enemyImmuneArray:Array;
public var enemyFallYmodArray:Array;
public var enemyHitCounterArray:Array;
public var enemyFallDirArray:Array;
public var myInterval:uint;
public function MainTimeline(){
addFrameScript(0, frame1, 1, frame2);
}
public function onProgress(_arg1:ProgressEvent):void{
var _local2:Number = _arg1.target.bytesLoaded;
var _local3:Number = _arg1.target.bytesTotal;
var _local4:Number = (_local2 / _local3);
loader_mc.scaleX = _local4;
loaded_txt.text = (("Loading... " + Math.round((_local4 * 100))) + "%");
}
public function onComplete(_arg1:Event):void{
loaded_txt.text = "Finished loading.";
btnIntroStart.alpha = 1;
btnIntroStart.addEventListener(MouseEvent.CLICK, startGame);
}
public function startGame(_arg1:MouseEvent):void{
gotoAndStop(2);
}
public function myTimer():void{
if ((((bgFrame.alpha > 0)) && ((iLevel < 6)))){
checkKey();
};
if ((((((bGameOver == false)) && ((labelLevelStart.alpha < 1)))) && ((bPaused == false)))){
if (iGirlHitCounter == 0){
moveGirl();
};
updateEnemyMovement();
if (girl.body.currentFrame == (iClothingOffset + 8)){
girlHitCheck();
};
enemyHitCheck();
if (iSpawnCountdown > 0){
iSpawnCountdown--;
} else {
iSpawnCountdown = iSpawnInterval;
runSpawner();
};
updateSpawnSpots();
fallingAnimationGirl();
fallingAnimationEnemy();
itemToTheFloor();
if (iImmunityCountdown > 0){
doImmunity();
};
levelClearanceCheck();
};
}
public function initLevel():void{
bgFrame.gotoAndStop(3);
bgFrame.alpha = 0.35;
setChildIndex(bgFrame, (numChildren - 1));
setChildIndex(labelGameOver, (numChildren - 1));
labelLevelStart.levelNumber.text = (("Level " + iLevel) + ":");
bgArt.gotoAndStop(iLevel);
if (iLevel == 1){
iMaxEnemies = 4;
iSpawnInterval = 70;
labelLevelStart.levelName.text = "\"Ghoulish Graveyard\"";
spawnZombie1.gotoAndStop(1);
spawnZombie1.x = 100;
spawnZombie2.gotoAndStop(1);
spawnZombie2.x = 800;
iEnemyHitRangeExtend = 0;
} else {
if (iLevel == 2){
iMaxEnemies = 6;
iSpawnInterval = 80;
labelLevelStart.levelName.text = "\"Mummified Museum\"";
spawnZombie1.x = -150;
spawnZombie2.x = -150;
spawnSacro1.gotoAndStop(1);
spawnSacro1.x = 100;
spawnSacro2.gotoAndStop(1);
spawnSacro2.x = 250;
spawnSacro3.gotoAndStop(1);
spawnSacro3.x = 800;
iEnemyHitRangeExtend = 5;
} else {
if (iLevel == 3){
iMaxEnemies = 7;
iSpawnInterval = 70;
labelLevelStart.levelName.text = "\"Prison Panic\"";
spawnSacro1.x = -150;
spawnSacro2.x = -150;
spawnSacro3.x = -150;
spawnPrisoner1.gotoAndStop(1);
spawnPrisoner1.x = 100;
spawnPrisoner2.gotoAndStop(1);
spawnPrisoner2.x = 650;
spawnPrisoner3.gotoAndStop(1);
spawnPrisoner3.x = 800;
iEnemyHitRangeExtend = 5;
} else {
if (iLevel == 4){
iMaxEnemies = 8;
iSpawnInterval = 110;
labelLevelStart.levelName.text = "\"Pirate Problems\"";
spawnPrisoner1.x = -150;
spawnPrisoner2.x = -150;
spawnPrisoner3.x = -150;
spawnPlank1.gotoAndStop(1);
spawnPlank1.x = 100;
spawnPlank2.gotoAndStop(1);
spawnPlank2.x = 250;
spawnPlank3.gotoAndStop(1);
spawnPlank3.x = 650;
spawnPlank4.gotoAndStop(1);
spawnPlank4.x = 800;
iEnemyHitRangeExtend = 5;
} else {
if (iLevel == 5){
iMaxEnemies = 9;
iSpawnInterval = 120;
labelLevelStart.levelName.text = "\"Hellish Hordes\"";
spawnPlank2.x = -150;
spawnPlank3.x = -150;
spawnPlank4.x = -150;
spawnPlank1.gotoAndStop(1);
spawnPlank1.x = 250;
spawnPrisoner1.gotoAndStop(1);
spawnPrisoner1.x = 800;
spawnSacro1.gotoAndStop(1);
spawnSacro1.x = 650;
spawnZombie1.gotoAndStop(1);
spawnZombie1.x = 100;
iEnemyHitRangeExtend = 5;
} else {
labelLevelStart.levelNumber.text = "Congratulations!";
labelLevelStart.levelName.text = "You have beaten the game!";
labelLevelStart.labelSpace.text = "";
flyingKick.alpha = 1;
setChildIndex(flyingKick, (numChildren - 1));
};
};
};
};
};
labelLevelStart.alpha = 1;
iMobsKilled = 0;
myKey = 0;
bPaused = false;
textPaused.alpha = 0;
}
public function checkKey():void{
var _local1:*;
var _local2:*;
if (myKey == 32){
if (labelLevelStart.alpha == 1){
labelLevelStart.alpha = 0;
bgFrame.alpha = 0;
} else {
if (enemyArray.length > 0){
_local1 = 0;
while (_local1 < enemyArray.length) {
_local2 = enemyArray[_local1];
removeChild(_local2);
_local1++;
};
};
myKey = 0;
iBlockCounter = 0;
iClothingOffset = 0;
iKickCounter = 0;
iGirlHitCounter = 0;
iGirlFallYmod = 0;
iGirlFallDirection = 1;
iImmunityCountdown = 0;
iItemDirection = 1;
iItemType = 0;
iSpawnCountdown = 10;
iEnemiesTillKey = (Math.floor((Math.random() * 5)) + 9);
iMobsKilled = 0;
enemyArray = [];
enemyMobType = [];
enemyClothingOffset = [];
enemyImmuneArray = [];
enemyFallYmodArray = [];
enemyHitCounterArray = [];
enemyFallDirArray = [];
girl.body.gotoAndStop((iClothingOffset + 1));
labelCleared.alpha = 0;
labelGameOver.alpha = 0;
labelLevelStart.alpha = 0;
bgFrame.alpha = 0;
girl.x = 450;
girl.y = 112;
girl.rotation = 0;
itemFloor.gotoAndStop(1);
girl.hand.gotoAndStop(1);
if (bGameOver == true){
initLevel();
} else {
iLevel++;
iMaxEnemies = 10;
iSpawnInterval = 70;
initLevel();
};
bGameOver = false;
bLevelCleared = false;
};
} else {
if (myKey == 73){
if (bGameOver == true){
if (labelGameOver.textI.text == "Press < i > to increase the Easy Mode effectiveness"){
iEasyModeMultiplier++;
labelGameOver.textI.text = ((("Level " + iLevel) + "'s 'Easy Mode' is set to v") + iEasyModeMultiplier);
modeText.text = ("Easy mode v" + iEasyModeMultiplier);
};
};
};
};
}
public function itemToTheFloor():void{
if (itemFloor.y < 190){
setChildIndex(itemFloor, (numChildren - 1));
itemFloor.x = (itemFloor.x + (iItemDirection * 10));
itemFloor.y = (itemFloor.y + (5 + (itemFloor.y / 10)));
if (itemFloor.y > 190){
itemFloor.y = 190;
};
};
if (itemFloor.x < 10){
itemFloor.x = 890;
};
if (itemFloor.x > 890){
itemFloor.x = 10;
};
}
public function levelClearanceCheck():void{
if ((((enemyArray.length == 0)) && ((labelCleared.alpha == 0)))){
if ((((((((((((((((((((((((spawnZombie1.currentFrame == 2)) && ((spawnZombie2.currentFrame == 2)))) && ((spawnSacro1.currentFrame == 2)))) && ((spawnSacro2.currentFrame == 2)))) && ((spawnSacro3.currentFrame == 2)))) && ((spawnPrisoner1.currentFrame == 2)))) && ((spawnPrisoner2.currentFrame == 2)))) && ((spawnPrisoner3.currentFrame == 2)))) && ((spawnPlank1.currentFrame == 2)))) && ((spawnPlank2.currentFrame == 2)))) && ((spawnPlank3.currentFrame == 2)))) && ((spawnPlank4.currentFrame == 2)))){
bLevelCleared = true;
modeText.text = "Normal mode";
iEasyModeMultiplier = 0;
bgFrame.gotoAndStop(1);
bgFrame.alpha = 0.35;
setChildIndex(bgFrame, (numChildren - 1));
setChildIndex(labelCleared, (numChildren - 1));
if (iLevel == 1){
labelCleared.mobAmount.text = (iMobsKilled + " zombies returned to the grave");
} else {
if (iLevel == 2){
labelCleared.mobAmount.text = (iMobsKilled + " mummies unwrapped");
} else {
if (iLevel == 3){
labelCleared.mobAmount.text = (iMobsKilled + " prisoners brought to justice");
} else {
if (iLevel == 4){
labelCleared.mobAmount.text = (iMobsKilled + " pirates sent overboard");
} else {
labelCleared.mobAmount.text = (iMobsKilled + " enemies slain. You have beaten the game!");
};
};
};
};
labelCleared.alpha = 1;
iMobsKilled = 0;
};
};
}
public function updateEnemyMovement():void{
var _local2:*;
var _local3:*;
var _local4:*;
var _local1:* = 0;
if (enemyArray.length > 0){
_local2 = 0;
while (_local2 < enemyArray.length) {
_local3 = enemyArray[_local2];
_local4 = 0;
if (enemyMobType[_local2] == 1){
_local4 = 3;
_local1 = 6;
};
if (enemyMobType[_local2] == 2){
_local4 = 4;
_local1 = 7;
};
if (enemyMobType[_local2] == 3){
_local4 = 5;
_local1 = 8;
};
if (enemyMobType[_local2] == 4){
_local4 = 6;
_local1 = 6;
};
_local3.x = (_local3.x - (_local4 * _local3.body.scaleX));
if (_local3.body.currentFrame == (enemyClothingOffset[_local2] + 10)){
_local3.body.gotoAndStop((enemyClothingOffset[_local2] + 1));
} else {
if (_local3.body.currentFrame == (enemyClothingOffset[_local2] + 2)){
if (Math.floor(((Math.random() * _local1) * (iEasyModeMultiplier + 1))) == 0){
_local3.body.gotoAndStop((_local3.body.currentFrame + 1));
} else {
_local3.body.gotoAndStop((enemyClothingOffset[_local2] + 1));
};
} else {
_local3.body.gotoAndStop((_local3.body.currentFrame + 1));
};
};
if (_local3.x < 0){
_local3.x = 900;
};
if (_local3.x > 900){
_local3.x = 0;
};
_local2++;
};
};
}
public function runSpawner():void{
if (enemyArray.length < iMaxEnemies){
if (spawnZombie1.currentFrame == 1){
spawnZombie1.gotoAndStop(3);
};
if (spawnZombie2.currentFrame == 1){
spawnZombie2.gotoAndStop(3);
};
if (spawnSacro1.currentFrame == 1){
spawnSacro1.gotoAndStop(3);
};
if (spawnSacro2.currentFrame == 1){
spawnSacro2.gotoAndStop(3);
};
if (spawnSacro3.currentFrame == 1){
spawnSacro3.gotoAndStop(3);
};
if (spawnPrisoner1.currentFrame == 1){
spawnPrisoner1.gotoAndStop(3);
};
if (spawnPrisoner2.currentFrame == 1){
spawnPrisoner2.gotoAndStop(3);
};
if (spawnPrisoner3.currentFrame == 1){
spawnPrisoner3.gotoAndStop(3);
};
if (spawnPlank1.currentFrame == 1){
spawnPlank1.gotoAndStop(3);
};
if (spawnPlank2.currentFrame == 1){
spawnPlank2.gotoAndStop(3);
};
if (spawnPlank3.currentFrame == 1){
spawnPlank3.gotoAndStop(3);
};
if (spawnPlank4.currentFrame == 1){
spawnPlank4.gotoAndStop(3);
};
};
}
public function updateSpawnSpots():void{
if (spawnZombie1.currentFrame > 2){
if (spawnZombie1.currentFrame < 20){
spawnZombie1.gotoAndStop((spawnZombie1.currentFrame + 1));
} else {
spawnZombie1.gotoAndStop(1);
spawnEnemy("Zombie", spawnZombie1.x);
};
};
if (spawnZombie2.currentFrame > 2){
if (spawnZombie2.currentFrame < 20){
spawnZombie2.gotoAndStop((spawnZombie2.currentFrame + 1));
} else {
spawnZombie2.gotoAndStop(1);
spawnEnemy("Zombie", spawnZombie2.x);
};
};
if (spawnSacro1.currentFrame > 2){
if (spawnSacro1.currentFrame < 20){
spawnSacro1.gotoAndStop((spawnSacro1.currentFrame + 1));
} else {
spawnSacro1.gotoAndStop(1);
spawnEnemy("Mummie", spawnSacro1.x);
};
};
if (spawnSacro2.currentFrame > 2){
if (spawnSacro2.currentFrame < 20){
spawnSacro2.gotoAndStop((spawnSacro2.currentFrame + 1));
} else {
spawnSacro2.gotoAndStop(1);
spawnEnemy("Mummie", spawnSacro2.x);
};
};
if (spawnSacro3.currentFrame > 2){
if (spawnSacro3.currentFrame < 20){
spawnSacro3.gotoAndStop((spawnSacro3.currentFrame + 1));
} else {
spawnSacro3.gotoAndStop(1);
spawnEnemy("Mummie", spawnSacro3.x);
};
};
if (spawnPrisoner1.currentFrame > 2){
if (spawnPrisoner1.currentFrame < 20){
spawnPrisoner1.gotoAndStop((spawnPrisoner1.currentFrame + 1));
} else {
spawnPrisoner1.gotoAndStop(1);
spawnEnemy("Prisoner", spawnPrisoner1.x);
};
};
if (spawnPrisoner2.currentFrame > 2){
if (spawnPrisoner2.currentFrame < 20){
spawnPrisoner2.gotoAndStop((spawnPrisoner2.currentFrame + 1));
} else {
spawnPrisoner2.gotoAndStop(1);
spawnEnemy("Prisoner", spawnPrisoner2.x);
};
};
if (spawnPrisoner3.currentFrame > 2){
if (spawnPrisoner3.currentFrame < 20){
spawnPrisoner3.gotoAndStop((spawnPrisoner3.currentFrame + 1));
} else {
spawnPrisoner3.gotoAndStop(1);
spawnEnemy("Prisoner", spawnPrisoner3.x);
};
};
if (spawnPlank1.currentFrame > 2){
if (spawnPlank1.currentFrame < 20){
spawnPlank1.gotoAndStop((spawnPlank1.currentFrame + 1));
} else {
spawnPlank1.gotoAndStop(1);
spawnEnemy("Pirate", spawnPlank1.x);
};
};
if (spawnPlank2.currentFrame > 2){
if (spawnPlank2.currentFrame < 20){
spawnPlank2.gotoAndStop((spawnPlank2.currentFrame + 1));
} else {
spawnPlank2.gotoAndStop(1);
spawnEnemy("Pirate", spawnPlank2.x);
};
};
if (spawnPlank3.currentFrame > 2){
if (spawnPlank3.currentFrame < 20){
spawnPlank3.gotoAndStop((spawnPlank3.currentFrame + 1));
} else {
spawnPlank3.gotoAndStop(1);
spawnEnemy("Pirate", spawnPlank3.x);
};
};
if (spawnPlank4.currentFrame > 2){
if (spawnPlank4.currentFrame < 20){
spawnPlank4.gotoAndStop((spawnPlank4.currentFrame + 1));
} else {
spawnPlank4.gotoAndStop(1);
spawnEnemy("Pirate", spawnPlank4.x);
};
};
}
public function spawnEnemy(_arg1:String, _arg2):void{
var _local3:*;
var _local4:* = 1;
if (_arg1 == "Zombie"){
_local3 = new zombieSprite();
_local4 = 1;
} else {
if (_arg1 == "Mummie"){
_local3 = new mummieSprite();
_local4 = 2;
} else {
if (_arg1 == "Prisoner"){
_local3 = new prisonerSprite();
_local4 = 3;
} else {
_local3 = new pirateSprite();
_local4 = 4;
};
};
};
_local3.x = _arg2;
_local3.y = 119;
if (Math.floor((Math.random() * 2)) == 0){
_local3.body.scaleX = 1;
_local3.hand.x = 0;
} else {
_local3.body.scaleX = -1;
_local3.hand.x = 10;
};
addChild(_local3);
enemyArray.push(_local3);
enemyMobType.push(_local4);
enemyClothingOffset.push(0);
enemyImmuneArray.push(0);
enemyFallYmodArray.push(0);
enemyHitCounterArray.push(0);
enemyFallDirArray.push(1);
if (iEnemiesTillKey > 0){
iEnemiesTillKey--;
};
if ((((iItemType == 0)) && ((iEnemiesTillKey == 0)))){
if (((!((spawnZombie1.currentFrame == 2))) || (!((spawnZombie2.currentFrame == 2))))){
iItemType = 2;
_local3.hand.gotoAndStop(iItemType);
} else {
if (((((!((spawnSacro1.currentFrame == 2))) || (!((spawnSacro2.currentFrame == 2))))) || (!((spawnSacro3.currentFrame == 2))))){
iItemType = 3;
_local3.hand.gotoAndStop(iItemType);
} else {
if (((((!((spawnPrisoner1.currentFrame == 2))) || (!((spawnPrisoner2.currentFrame == 2))))) || (!((spawnPrisoner3.currentFrame == 2))))){
iItemType = 4;
_local3.hand.gotoAndStop(iItemType);
} else {
if (((((((!((spawnPlank1.currentFrame == 2))) || (!((spawnPlank2.currentFrame == 2))))) || (!((spawnPlank3.currentFrame == 2))))) || (!((spawnPlank4.currentFrame == 2))))){
iItemType = 5;
_local3.hand.gotoAndStop(iItemType);
};
};
};
};
};
}
public function doImmunity():void{
iImmunityCountdown--;
if (iGirlHitCounter == 0){
girl.alpha = (1 - girl.alpha);
};
if (iImmunityCountdown == 0){
girl.alpha = 1;
};
}
public function enemyHitCheck():void{
var _local1:*;
var _local2:*;
if (iImmunityCountdown == 0){
if (enemyArray.length > 0){
_local1 = 0;
while (_local1 < enemyArray.length) {
_local2 = enemyArray[_local1];
if (_local2.body.currentFrame == (enemyClothingOffset[_local1] + 8)){
if (_local2.body.scaleX == 1){
if ((((girl.x > ((_local2.x - 45) - iEnemyHitRangeExtend))) && ((girl.x < _local2.x)))){
if ((((girl.body.scaleX == -1)) && ((girl.body.currentFrame == (iClothingOffset + 5))))){
} else {
iGirlFallDirection = -1;
girlIsHit();
};
};
} else {
if ((((girl.x < ((_local2.x + 55) + iEnemyHitRangeExtend))) && ((girl.x > _local2.x)))){
if ((((girl.body.scaleX == 1)) && ((girl.body.currentFrame == (iClothingOffset + 5))))){
} else {
iGirlFallDirection = 1;
girlIsHit();
};
};
};
};
_local1++;
};
};
};
}
public function girlHitCheck():void{
var _local1:*;
var _local2:*;
if (enemyArray.length > 0){
_local1 = 0;
while (_local1 < enemyArray.length) {
_local2 = enemyArray[_local1];
if (girl.body.scaleX == 1){
if ((((_local2.x > (girl.x - 55))) && ((_local2.x < girl.x)))){
enemyFallDirArray[_local1] = -1;
enemyImmuneArray[_local1] = 10;
_local2.body.gotoAndStop((enemyClothingOffset[_local1] + 1));
enemyFallYmodArray[_local1] = -17;
var _local3 = enemyHitCounterArray;
var _local4 = _local1;
var _local5 = (_local3[_local4] + 1);
_local3[_local4] = _local5;
enemyClothingOffset[_local1] = (enemyClothingOffset[_local1] + 15);
};
} else {
if ((((_local2.x < (girl.x + 65))) && ((_local2.x > girl.x)))){
enemyFallDirArray[_local1] = 1;
enemyImmuneArray[_local1] = 10;
_local2.body.gotoAndStop((enemyClothingOffset[_local1] + 1));
enemyFallYmodArray[_local1] = -17;
_local3 = enemyHitCounterArray;
_local4 = _local1;
_local5 = (_local3[_local4] + 1);
_local3[_local4] = _local5;
enemyClothingOffset[_local1] = (enemyClothingOffset[_local1] + 15);
};
};
_local1++;
};
};
}
public function fallingAnimationEnemy():void{
var _local1:*;
var _local2:*;
if (enemyArray.length > 0){
_local1 = 0;
while (_local1 < enemyArray.length) {
_local2 = enemyArray[_local1];
if (enemyHitCounterArray[_local1] > 0){
var _local3 = enemyHitCounterArray;
var _local4 = _local1;
var _local5 = (_local3[_local4] + 1);
_local3[_local4] = _local5;
if (enemyHitCounterArray[_local1] < 11){
_local2.rotation = (_local2.rotation + (10 * enemyFallDirArray[_local1]));
_local2.y = (_local2.y + enemyFallYmodArray[_local1]);
enemyFallYmodArray[_local1] = (enemyFallYmodArray[_local1] + 6);
_local2.x = (_local2.x + (enemyFallDirArray[_local1] * 30));
} else {
if (enemyHitCounterArray[_local1] == 11){
if (_local2.body.scaleX == 1){
if (enemyFallDirArray[_local1] == 1){
_local2.y = 180;
} else {
_local2.y = 175;
};
} else {
if (enemyFallDirArray[_local1] == 1){
_local2.y = 165;
} else {
_local2.y = 192;
};
};
} else {
if (enemyHitCounterArray[_local1] == 12){
if ((((enemyClothingOffset[_local1] == 30)) && ((((enemyMobType[_local1] == 1)) || ((enemyMobType[_local1] == 2)))))){
if (_local2.hand.currentFrame > 1){
_local2.hand.gotoAndStop(1);
itemFloor.y = 10;
itemFloor.x = _local2.x;
iItemDirection = enemyFallDirArray[_local1];
itemFloor.gotoAndStop(iItemType);
itemToTheFloor();
};
enemyArray.splice(_local1, 1);
iMobsKilled++;
enemyMobType.splice(_local1, 1);
enemyClothingOffset.splice(_local1, 1);
enemyImmuneArray.splice(_local1, 1);
enemyFallYmodArray.splice(_local1, 1);
enemyHitCounterArray.splice(_local1, 1);
enemyFallDirArray.splice(_local1, 1);
cloud.x = _local2.x;
removeChild(_local2);
cloud.gotoAndPlay(1);
} else {
if ((((enemyClothingOffset[_local1] == 45)) && ((((enemyMobType[_local1] == 3)) || ((enemyMobType[_local1] == 4)))))){
if (_local2.hand.currentFrame > 1){
_local2.hand.gotoAndStop(1);
itemFloor.y = 10;
itemFloor.x = _local2.x;
iItemDirection = enemyFallDirArray[_local1];
itemFloor.gotoAndStop(iItemType);
itemToTheFloor();
};
enemyArray.splice(_local1, 1);
iMobsKilled++;
enemyMobType.splice(_local1, 1);
enemyClothingOffset.splice(_local1, 1);
enemyImmuneArray.splice(_local1, 1);
enemyFallYmodArray.splice(_local1, 1);
enemyHitCounterArray.splice(_local1, 1);
enemyFallDirArray.splice(_local1, 1);
cloud.x = _local2.x;
removeChild(_local2);
cloud.gotoAndPlay(1);
} else {
enemyHitCounterArray[_local1] = 0;
enemyFallYmodArray[_local1] = 0;
_local2.body.gotoAndStop((enemyClothingOffset[_local1] + 1));
_local2.rotation = 0;
_local2.y = 118;
};
};
};
};
};
};
_local1++;
};
};
}
public function moveGirl():void{
if ((((myKey == 1)) && ((iKickCounter == 0)))){
girl.body.scaleX = 1;
girl.hand.x = 0;
} else {
if ((((myKey == 2)) && ((iKickCounter == 0)))){
girl.body.scaleX = -1;
girl.hand.x = 10;
};
};
if ((((((myKey == 1)) || ((myKey == 2)))) && ((((iKickCounter == 0)) || ((iKickCounter > 9)))))){
iKickCounter = 0;
if (girl.body.currentFrame > (iClothingOffset + 3)){
girl.body.gotoAndStop((iClothingOffset + 1));
} else {
girl.body.gotoAndStop((girl.body.currentFrame + 1));
};
girl.x = (girl.x - (girl.body.scaleX * 12));
} else {
if ((((myKey == 3)) || ((iKickCounter > 0)))){
if (iKickCounter == 0){
iKickCounter = 6;
girl.body.gotoAndStop((iClothingOffset + iKickCounter));
} else {
if (iKickCounter == 11){
iKickCounter = 0;
girl.body.gotoAndStop((iClothingOffset + 1));
} else {
iKickCounter++;
girl.body.gotoAndStop((iClothingOffset + iKickCounter));
};
};
girl.x = (girl.x - (girl.body.scaleX * 4));
myKey = 0;
} else {
if (myKey == 4){
if (iBlockCounter == 0){
iBlockCounter++;
girl.body.gotoAndStop((iClothingOffset + 5));
};
myKey = 0;
} else {
if (myKey == 32){
if ((((((itemFloor.x > (girl.x - 20))) && ((itemFloor.x < (girl.x + 20))))) && ((itemFloor.currentFrame > 1)))){
itemFloor.gotoAndStop(1);
girl.hand.gotoAndStop(iItemType);
} else {
if (girl.hand.currentFrame > 1){
if ((((((((spawnZombie1.x > (girl.x - 25))) && ((spawnZombie1.x < (girl.x + 25))))) && (!((spawnZombie1.currentFrame == 2))))) && ((iItemType == 2)))){
spawnZombie1.gotoAndStop(2);
removeKey();
};
if ((((((((spawnZombie2.x > (girl.x - 25))) && ((spawnZombie2.x < (girl.x + 25))))) && (!((spawnZombie2.currentFrame == 2))))) && ((iItemType == 2)))){
spawnZombie2.gotoAndStop(2);
removeKey();
};
if ((((((((spawnSacro1.x > (girl.x - 25))) && ((spawnSacro1.x < (girl.x + 25))))) && (!((spawnSacro1.currentFrame == 2))))) && ((iItemType == 3)))){
spawnSacro1.gotoAndStop(2);
removeKey();
};
if ((((((((spawnSacro2.x > (girl.x - 25))) && ((spawnSacro2.x < (girl.x + 25))))) && (!((spawnSacro2.currentFrame == 2))))) && ((iItemType == 3)))){
spawnSacro2.gotoAndStop(2);
removeKey();
};
if ((((((((spawnSacro3.x > (girl.x - 25))) && ((spawnSacro3.x < (girl.x + 25))))) && (!((spawnSacro3.currentFrame == 2))))) && ((iItemType == 3)))){
spawnSacro3.gotoAndStop(2);
removeKey();
};
if ((((((((spawnPrisoner1.x > (girl.x - 25))) && ((spawnPrisoner1.x < (girl.x + 25))))) && (!((spawnPrisoner1.currentFrame == 2))))) && ((iItemType == 4)))){
spawnPrisoner1.gotoAndStop(2);
removeKey();
};
if ((((((((spawnPrisoner2.x > (girl.x - 25))) && ((spawnPrisoner2.x < (girl.x + 25))))) && (!((spawnPrisoner2.currentFrame == 2))))) && ((iItemType == 4)))){
spawnPrisoner2.gotoAndStop(2);
removeKey();
};
if ((((((((spawnPrisoner3.x > (girl.x - 25))) && ((spawnPrisoner3.x < (girl.x + 25))))) && (!((spawnPrisoner3.currentFrame == 2))))) && ((iItemType == 4)))){
spawnPrisoner3.gotoAndStop(2);
removeKey();
};
if ((((((((spawnPlank1.x > (girl.x - 25))) && ((spawnPlank1.x < (girl.x + 25))))) && (!((spawnPlank1.currentFrame == 2))))) && ((iItemType == 5)))){
spawnPlank1.gotoAndStop(2);
removeKey();
};
if ((((((((spawnPlank2.x > (girl.x - 25))) && ((spawnPlank2.x < (girl.x + 25))))) && (!((spawnPlank2.currentFrame == 2))))) && ((iItemType == 5)))){
spawnPlank2.gotoAndStop(2);
removeKey();
};
if ((((((((spawnPlank3.x > (girl.x - 25))) && ((spawnPlank3.x < (girl.x + 25))))) && (!((spawnPlank3.currentFrame == 2))))) && ((iItemType == 5)))){
spawnPlank3.gotoAndStop(2);
removeKey();
};
if ((((((((spawnPlank4.x > (girl.x - 25))) && ((spawnPlank4.x < (girl.x + 25))))) && (!((spawnPlank4.currentFrame == 2))))) && ((iItemType == 5)))){
spawnPlank4.gotoAndStop(2);
removeKey();
};
};
};
};
};
};
};
if (iBlockCounter > 0){
iBlockCounter++;
if ((((iBlockCounter == 12)) && ((girl.body.currentFrame == (iClothingOffset + 5))))){
girl.body.gotoAndStop((iClothingOffset + 1));
};
if (iBlockCounter == 15){
iBlockCounter = 0;
};
};
if (girl.x < 0){
girl.x = 900;
};
if (girl.x > 900){
girl.x = 0;
};
}
public function removeKey():void{
girl.hand.gotoAndStop(1);
iEnemiesTillKey = (Math.floor((Math.random() * 5)) + 5);
iItemType = 0;
}
public function girlIsHit():void{
if (iClothingOffset < 75){
myKey = 0;
iImmunityCountdown = 40;
girl.body.gotoAndStop((iClothingOffset + 1));
iGirlFallYmod = -17;
iGirlHitCounter++;
iClothingOffset = (iClothingOffset + 15);
} else {
if (bGameOver == false){
iGirlHitCounter++;
bGameOver = true;
bgFrame.gotoAndStop(2);
bgFrame.alpha = 0.35;
setChildIndex(bgFrame, (numChildren - 1));
setChildIndex(labelGameOver, (numChildren - 1));
if (iLevel == 1){
labelGameOver.mobAmount.text = (iMobsKilled + " zombies returned to the grave");
labelGameOver.textI.text = "";
} else {
if (iLevel == 2){
labelGameOver.mobAmount.text = (iMobsKilled + " mummies unwrapped");
if (iEasyModeMultiplier < 1){
labelGameOver.textI.text = "Press < i > to increase the Easy Mode effectiveness";
} else {
labelGameOver.textI.text = ("Easy Mode Effectiveness is set to v" + iEasyModeMultiplier);
};
} else {
if (iLevel == 3){
labelGameOver.mobAmount.text = (iMobsKilled + " prisoners brought to justice");
if (iEasyModeMultiplier < 2){
labelGameOver.textI.text = "Press < i > to increase the Easy Mode effectiveness";
} else {
labelGameOver.textI.text = ("Easy Mode Effectiveness is set to v" + iEasyModeMultiplier);
};
} else {
if (iLevel == 4){
labelGameOver.mobAmount.text = (iMobsKilled + " pirates sent overboard");
if (iEasyModeMultiplier < 2){
labelGameOver.textI.text = "Press < i > to increase the Easy Mode effectiveness";
} else {
labelGameOver.textI.text = ("Easy Mode Effectiveness is set to v" + iEasyModeMultiplier);
};
} else {
labelGameOver.mobAmount.text = (iMobsKilled + " enemies slain");
if (iEasyModeMultiplier < 2){
labelGameOver.textI.text = "Press < i > to increase the Easy Mode effectiveness";
} else {
labelGameOver.textI.text = ("Easy Mode Effectiveness is set to v" + iEasyModeMultiplier);
};
};
};
};
};
labelGameOver.alpha = 1;
iMobsKilled = 0;
myKey = 0;
};
};
}
public function fallingAnimationGirl():void{
if (iGirlHitCounter > 0){
iGirlHitCounter++;
if (iGirlHitCounter < 11){
girl.rotation = (girl.rotation + (10 * iGirlFallDirection));
girl.y = (girl.y + iGirlFallYmod);
iGirlFallYmod = (iGirlFallYmod + 6);
girl.x = (girl.x + (iGirlFallDirection * 30));
} else {
if (iGirlHitCounter == 11){
if (girl.body.scaleX == 1){
if (iGirlFallDirection == 1){
girl.y = 180;
} else {
girl.y = 175;
};
} else {
if (iGirlFallDirection == 1){
girl.y = 165;
} else {
girl.y = 192;
};
};
} else {
if (iGirlHitCounter == 20){
iGirlHitCounter = 0;
iGirlFallYmod = 0;
girl.rotation = 0;
girl.y = 112;
};
};
};
};
}
public function keyPressed(_arg1:KeyboardEvent):void{
if ((((_arg1.keyCode == Keyboard.LEFT)) || ((_arg1.keyCode == 65)))){
myKey = 1;
} else {
if ((((_arg1.keyCode == Keyboard.RIGHT)) || ((_arg1.keyCode == 68)))){
myKey = 2;
} else {
if ((((_arg1.keyCode == Keyboard.UP)) || ((_arg1.keyCode == 87)))){
myKey = 3;
} else {
if ((((_arg1.keyCode == Keyboard.DOWN)) || ((_arg1.keyCode == 83)))){
myKey = 4;
} else {
if (_arg1.keyCode == 32){
myKey = 32;
} else {
if (_arg1.keyCode == 80){
myKey = 0;
if (bPaused == false){
bPaused = true;
textPaused.alpha = 1;
setChildIndex(textPaused, (numChildren - 1));
} else {
bPaused = false;
textPaused.alpha = 0;
};
} else {
if (_arg1.keyCode == 73){
myKey = 73;
} else {
myKey = 0;
};
};
};
};
};
};
};
}
function frame1(){
stop();
this.loaderInfo.addEventListener(ProgressEvent.PROGRESS, onProgress);
this.loaderInfo.addEventListener(Event.COMPLETE, onComplete);
}
function frame2(){
stop();
myKey = 0;
iBlockCounter = 0;
iClothingOffset = 0;
iKickCounter = 0;
bGameOver = false;
iLevel = 1;
bLevelCleared = false;
iGirlHitCounter = 0;
iGirlFallYmod = 0;
iGirlFallDirection = 1;
iImmunityCountdown = 0;
iEasyModeMultiplier = 0;
bPaused = false;
iItemDirection = 1;
iItemType = 0;
iMaxEnemies = 8;
iSpawnInterval = 70;
iSpawnCountdown = 10;
iEnemiesTillKey = (Math.floor((Math.random() * 5)) + 9);
iMobsKilled = 0;
iEnemyHitRangeExtend = 0;
enemyArray = [];
enemyMobType = [];
enemyClothingOffset = [];
enemyImmuneArray = [];
enemyFallYmodArray = [];
enemyHitCounterArray = [];
enemyFallDirArray = [];
stage.addEventListener(KeyboardEvent.KEY_DOWN, keyPressed);
girl.body.gotoAndStop((iClothingOffset + 1));
myInterval = setInterval(myTimer, 50);
labelCleared.alpha = 0;
labelGameOver.alpha = 0;
labelLevelStart.alpha = 0;
bgFrame.alpha = 0;
modeText.text = "Normal mode";
iEasyModeMultiplier = 0;
spawnZombie1.gotoAndStop(2);
spawnZombie1.x = -150;
spawnZombie2.gotoAndStop(2);
spawnZombie2.x = -150;
spawnSacro1.gotoAndStop(2);
spawnSacro1.x = -150;
spawnSacro2.gotoAndStop(2);
spawnSacro1.x = -150;
spawnSacro3.gotoAndStop(2);
spawnSacro1.x = -150;
spawnPrisoner1.gotoAndStop(2);
spawnPrisoner1.x = -150;
spawnPrisoner2.gotoAndStop(2);
spawnPrisoner2.x = -150;
spawnPrisoner3.gotoAndStop(2);
spawnPrisoner3.x = -150;
spawnPlank1.gotoAndStop(2);
spawnPlank1.x = -150;
spawnPlank2.gotoAndStop(2);
spawnPlank2.x = -150;
spawnPlank3.gotoAndStop(2);
spawnPlank3.x = -150;
spawnPlank4.gotoAndStop(2);
spawnPlank4.x = -150;
initLevel();
}
}
}//package kickingButt_fla
Section 9
//mobPrisoner_31 (kickingButt_fla.mobPrisoner_31)
package kickingButt_fla {
import flash.display.*;
public dynamic class mobPrisoner_31 extends MovieClip {
public function mobPrisoner_31(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package kickingButt_fla
Section 10
//mummieMob_27 (kickingButt_fla.mummieMob_27)
package kickingButt_fla {
import flash.display.*;
public dynamic class mummieMob_27 extends MovieClip {
public function mummieMob_27(){
addFrameScript(0, frame1, 15, frame16);
}
function frame1(){
stop();
}
function frame16(){
stop();
}
}
}//package kickingButt_fla
Section 11
//pirateBase_29 (kickingButt_fla.pirateBase_29)
package kickingButt_fla {
import flash.display.*;
public dynamic class pirateBase_29 extends MovieClip {
public function pirateBase_29(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package kickingButt_fla
Section 12
//sacrophage_13 (kickingButt_fla.sacrophage_13)
package kickingButt_fla {
import flash.display.*;
public dynamic class sacrophage_13 extends MovieClip {
public function sacrophage_13(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package kickingButt_fla
Section 13
//spawnPlank_4 (kickingButt_fla.spawnPlank_4)
package kickingButt_fla {
import flash.display.*;
public dynamic class spawnPlank_4 extends MovieClip {
public function spawnPlank_4(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package kickingButt_fla
Section 14
//spawnPrisoner_5 (kickingButt_fla.spawnPrisoner_5)
package kickingButt_fla {
import flash.display.*;
public dynamic class spawnPrisoner_5 extends MovieClip {
public function spawnPrisoner_5(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package kickingButt_fla
Section 15
//spawnZombie_6 (kickingButt_fla.spawnZombie_6)
package kickingButt_fla {
import flash.display.*;
public dynamic class spawnZombie_6 extends MovieClip {
public function spawnZombie_6(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package kickingButt_fla
Section 16
//introStartButton (introStartButton)
package {
import flash.display.*;
public dynamic class introStartButton extends MovieClip {
}
}//package
Section 17
//movie_mc (movie_mc)
package {
import flash.display.*;
public dynamic class movie_mc extends MovieClip {
}
}//package
Section 18
//mummieSprite (mummieSprite)
package {
import flash.display.*;
public dynamic class mummieSprite extends MovieClip {
public var body:MovieClip;
public var hand:MovieClip;
}
}//package
Section 19
//pirateSprite (pirateSprite)
package {
import flash.display.*;
public dynamic class pirateSprite extends MovieClip {
public var body:MovieClip;
public var hand:MovieClip;
}
}//package
Section 20
//prisonerSprite (prisonerSprite)
package {
import flash.display.*;
public dynamic class prisonerSprite extends MovieClip {
public var body:MovieClip;
public var hand:MovieClip;
}
}//package
Section 21
//zombieSprite (zombieSprite)
package {
import flash.display.*;
public dynamic class zombieSprite extends MovieClip {
public var body:MovieClip;
public var hand:MovieClip;
}
}//package