Frame 1
stop();
loaded = false;
_root.createEmptyMovieClip("outline", this.getNextHighestDepth());
outline.lineStyle(3, 0, 100, true, "none", "round", "miter", 1);
outline.beginFill(16777215);
outline.moveTo(125, 112.5);
outline.lineTo(375, 112.5);
outline.lineTo(375, 137.5);
outline.lineTo(125, 137.5);
outline.lineTo(125, 112.5);
outline.endFill();
_root.onEnterFrame = function () {
if (loaded == false) {
_root.createEmptyMovieClip("preloader", this.getNextHighestDepth());
preloader.lineStyle(0, 0, 100, true, "none", "round", "miter", 1);
preloader.beginFill(0);
preloader.moveTo(125, 112.5);
preloader.lineTo(125 + ((_root.getBytesLoaded() / _root.getBytesTotal()) * 250), 112.5);
preloader.lineTo(125 + ((_root.getBytesLoaded() / _root.getBytesTotal()) * 250), 137.5);
preloader.lineTo(125, 137.5);
preloader.lineTo(125, 112.5);
preloader.endFill();
if (_root.getBytesLoaded() == _root.getBytesTotal()) {
outline.removeMovieClip();
preloader.removeMovieClip();
loaded = true;
play();
}
}
};
Frame 2
function buildLevel() {
attachMovies();
levelx = 0;
while (levelx <= 40) {
levely = 0;
while (levely <= 20) {
if (arrLevel[levely][levelx] == 1) {
if (((arrLevel[levely - 1][levelx] == 22) and (arrLevel[levely][levelx - 1] == 22)) or ((arrLevel[levely - 1][levelx] == 21) and (arrLevel[levely][levelx + 1] == 21))) {
Slope = slope.attachMovie("block", "slope", slope.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
} else {
Block = block.attachMovie("block", "block", block.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
}
}
if (arrLevel[levely][levelx] == 11) {
Block = block.attachMovie("block", "block", block.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
arrLevel[levely][levelx + 1] = 0;
Block.gotoAndStop(3);
Block.dir = 1;
Block.onThis = false;
Block.startLoc = (levelx * 25) + 12.5;
Block.onEnterFrame = function () {
if (_root.Paused == false) {
this._x = this._x + this.dir;
if (((((_root.block.hitTest((block._x + this._x) - 25, (block._y + this._y) + 1, true) or _root.block.hitTest((block._x + this._x) + 75, (block._y + this._y) + 1, true)) or _root.slope.hitTest((block._x + this._x) - 25, (block._y + this._y) + 1, true)) or _root.slope.hitTest((block._x + this._x) + 75, (block._y + this._y) + 1, true)) or _root.slope.hitTest((block._x + this._x) - 25, (block._y + this._y) + 24, true)) or _root.slope.hitTest((block._x + this._x) + 75, (block._y + this._y) + 24, true)) {
this.dir = this.dir * -1;
}
if ((_root.player.hitTest(block._x + this._x, (block._y + this._y) - halfwidth, true) or _root.player.hitTest((block._x + this._x) + 25, (block._y + this._y) - halfwidth, true)) or _root.player.hitTest((block._x + this._x) + 50, (block._y + this._y) - halfwidth, true)) {
if (_root.playerMoving == false) {
_root.dx = 2.00001 * this.dir;
}
this.onThis = true;
} else {
this.onThis = flase;
}
if (this.onThis == true) {
_root.player._rotation = _root.player._rotation - (this.dir * Math.PI);
}
if (dead == true) {
this._x = this.startLoc;
}
}
};
}
if (arrLevel[levely][levelx] == 12) {
Ladder = ladder.attachMovie("ladder", "ladder", ladder.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
}
if (arrLevel[levely][levelx] == 21) {
Slope = slope.attachMovie("block", "slope", slope.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
Slope.gotoAndStop(2);
}
if (arrLevel[levely][levelx] == 22) {
Slope = slope.attachMovie("block", "slope", slope.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
Slope.gotoAndStop(2);
Slope._rotation = 270;
Slope._y = Slope._y + 25;
}
if (arrLevel[levely][levelx] == 23) {
Slope = slope.attachMovie("block", "slope", slope.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
Slope.gotoAndStop(2);
Slope._rotation = 180;
Slope._y = Slope._y + 25;
Slope._x = Slope._x + 25;
}
if (arrLevel[levely][levelx] == 24) {
Slope = slope.attachMovie("block", "slope", slope.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
Slope.gotoAndStop(2);
Slope._rotation = 90;
Slope._x = Slope._x + 25;
}
if (arrLevel[levely][levelx] == 31) {
lockTotal = lockTotal + 1;
Lock = lock.attachMovie("lock", "lock", lock.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
Lock.locked = true;
Lock.onEnterFrame = function () {
if (_root.player.hitTest((lock._x + this._x) + halfwidth, (lock._y + this._y) + halfwidth, true) and (this.locked == true)) {
this.locked = false;
this.gotoAndStop(2);
_root.unlocked = _root.unlocked + 1;
if (musicOn == true) {
lockSound.start();
}
}
if (dead == true) {
this.gotoAndStop(1);
this.locked = true;
}
};
}
if (arrLevel[levely][levelx] == 32) {
Gate = gate.attachMovie("gate", "gate", gate.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
Gate.onEnterFrame = function () {
while (_root.player.hitTest((gate._x + this._x) - dx, ((gate._y + this._y) + halfwidth) - dy, true) and (_root.locked == true)) {
dx--;
}
while (_root.player.hitTest(((gate._x + this._x) + 25) - dx, ((gate._y + this._y) + halfwidth) - dy, true) and (_root.locked == true)) {
dx++;
}
if (lockTotal == unlocked) {
this.gotoAndStop(2);
locked = false;
}
if (dead == true) {
this.gotoAndStop(1);
locked = true;
}
};
}
if (arrLevel[levely][levelx] == 33) {
Door = door.attachMovie("door", "door", door.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
Door.onEnterFrame = function () {
if (_root.player.hitTest((door._x + this._x) + halfwidth, (door._y + this._y) + halfwidth, true)) {
if (locked == false) {
if (scorelevel == coinTotal) {
scorelevel = scorelevel + 1;
}
endlevel();
_root.gotoAndStop(_root._currentframe + 1);
}
}
};
}
if (arrLevel[levely][levelx] == 41) {
Mover = mover.attachMovie("enemy", "enemy", mover.getNextHighestDepth(), {_x:(levelx * 25) + 12.5, _y:(levely * 25) + 12.5});
Mover.gotoAndStop(1);
Mover.dir = 2;
Mover.bonk = 0;
Mover.bonked = false;
Mover.startLoc = (levelx * 25) + 12.5;
Mover.onEnterFrame = function () {
if (_root.Paused == false) {
this._x = this._x + this.dir;
this._rotation = this._rotation + (this.dir * Math.PI);
if (((((_root.block.hitTest((mover._x + this._x) + halfwidth, mover._y + this._y, true) or _root.block.hitTest((mover._x + this._x) - halfwidth, mover._y + this._y, true)) or _root.slope.hitTest((mover._x + this._x) + r45, (mover._y + this._y) + r45, true)) or _root.slope.hitTest((mover._x + this._x) - r45, (mover._y + this._y) + r45, true)) or (((!_root.block.hitTest((mover._x + this._x) + halfwidth, ((mover._y + this._y) + halfwidth) + 1, true)) and (!_root.slope.hitTest((mover._x + this._x) + halfwidth, ((mover._y + this._y) + halfwidth) + 1, true))) and (this.dir == 2))) or (((this.dir == -2) and (!_root.block.hitTest((mover._x + this._x) - halfwidth, ((mover._y + this._y) + halfwidth) + 1, true))) and (!_root.slope.hitTest((mover._x + this._x) - halfwidth, ((mover._y + this._y) + halfwidth) + 1, true)))) {
this.dir = this.dir * -1;
}
if ((_root.mover.hitTest(((mover._x + this._x) + halfwidth) + 3, mover._y + this._y, true) or _root.mover.hitTest(((mover._x + this._x) - halfwidth) - 3, mover._y + this._y, true)) and (this.bonked == false)) {
this.bonked = true;
this.dir = this.dir * -1;
}
if (this.bonked == true) {
this.bonk++;
}
if (this.bonk >= 6) {
this.bonked = false;
this.bonk = 0;
}
if (((_root.player.hitTest((mover._x + this._x) + halfwidth, mover._y + this._y, true) or _root.player.hitTest((mover._x + this._x) - halfwidth, mover._y + this._y, true)) or _root.player.hitTest(mover._x + this._x, (mover._y + this._y) + halfwidth, true)) or _root.player.hitTest(mover._x + this._x, (mover._y + this._y) - halfwidth, true)) {
hurt = true;
}
if (dead == true) {
this._x = this.startLoc;
}
}
};
}
if (arrLevel[levely][levelx] == 42) {
Turret = turret.attachMovie("enemy", "enemy", turret.getNextHighestDepth(), {_x:(levelx * 25) + 12.5, _y:(levely * 25) + 12.5});
Turret.gotoAndStop(2);
Bullets = bullets.attachMovie("bullet", "bullet", bullets.getNextHighestDepth(), {_x:(levelx * 25) + 12.5, _y:(levely * 25) + 12.5});
Bullets.fired = false;
Bullets.reload = false;
Bullets.reloading = 0;
Bullets.startLoc = (levelx * 25) + 12.5;
Bullets.onEnterFrame = function () {
if (_root.Paused == false) {
if (((_root.player._x > (bullets._x + this._x)) and ((_root.player._y >= ((bullets._y + this._y) - halfwidth)) and (_root.player._y <= ((bullets._y + this._y) + halfwidth)))) and (this.fired == false)) {
this.fired = true;
}
if ((this.fired == true) and (this.reload == false)) {
this._x = this._x + bspeed;
}
if ((_root.block.hitTest(((bullets._x + this._x) - halfwidth) + 1, bullets._y + this._y, true) or _root.slope.hitTest(((bullets._x + this._x) - halfwidth) + 1, bullets._y + this._y, true)) and (this.reload == false)) {
this.reload = true;
this._x = this.startLoc;
}
if (this.reload == true) {
this.reloading++;
}
if ((this.reloading >= reloadDelay) or (dead == true)) {
this.reloading = 0;
this.reload = false;
this.fired = false;
this._x = this.startLoc;
}
p = (-halfwidth) + 1;
while (p <= -1) {
if ((_root.player.hitTest((bullets._x + this._x) + p, bullets._y + this._y, true) and (this.reload == false)) and (this.fired == true)) {
hurt = true;
this.reload = true;
this._x = this.startLoc;
}
p++;
}
}
};
}
if (arrLevel[levely][levelx] == 43) {
Turret = turret.attachMovie("enemy", "enemy", turret.getNextHighestDepth(), {_x:(levelx * 25) + 12.5, _y:(levely * 25) + 12.5});
Turret.gotoAndStop(2);
Turret._rotation = 180;
Bullets = bullets.attachMovie("bullet", "bullet", bullets.getNextHighestDepth(), {_x:(levelx * 25) + 12.5, _y:(levely * 25) + 12.5});
Bullets._rotation = 180;
Bullets.fired = false;
Bullets.reload = false;
Bullets.reloading = 0;
Bullets.startLoc = (levelx * 25) + 12.5;
Bullets.onEnterFrame = function () {
if (_root.Paused == false) {
if (((_root.player._x < (bullets._x + this._x)) and ((_root.player._y >= ((bullets._y + this._y) - halfwidth)) and (_root.player._y <= ((bullets._y + this._y) + halfwidth)))) and (this.fired == false)) {
this.fired = true;
}
if ((this.fired == true) and (this.reload == false)) {
this._x = this._x - bspeed;
}
if ((_root.block.hitTest(((bullets._x + this._x) + halfwidth) - 1, bullets._y + this._y, true) or _root.slope.hitTest(((bullets._x + this._x) + halfwidth) - 1, bullets._y + this._y, true)) and (this.reload == false)) {
this.reload = true;
this._x = this.startLoc;
}
if (this.reload == true) {
this.reloading++;
}
if ((this.reloading >= reloadDelay) or (dead == true)) {
this.reloading = 0;
this.reload = false;
this.fired = false;
this._x = this.startLoc;
}
p = 1;
while (p <= (halfwidth - 1)) {
if ((_root.player.hitTest((bullets._x + this._x) + p, bullets._y + this._y, true) and (this.reload == false)) and (this.fired == true)) {
hurt = true;
this.reload = true;
this._x = this.startLoc;
}
p++;
}
}
};
}
if (arrLevel[levely][levelx] == 44) {
Spike = spiketrap.attachMovie("spike", "spike", spiketrap.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
Spike.onEnterFrame = function () {
lx = 0;
while (lx <= 25) {
if (_root.player.hitTest((spiketrap._x + this._x) + lx, (spiketrap._y + this._y) + halfwidth, true)) {
hurt = true;
onground = true;
}
while (_root.player.hitTest(((spiketrap._x + this._x) + lx) - dx, ((spiketrap._y + this._y) + halfwidth) - dy, true)) {
dy--;
}
lx++;
}
};
}
if (arrLevel[levely][levelx] == 5) {
coinTotal = coinTotal + 1;
Coin = coins.attachMovie("coins", "coin", coins.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
Coin.taken = false;
Coin.onEnterFrame = function () {
if (_root.player.hitTest((coins._x + this._x) + halfwidth, (coins._y + this._y) + halfwidth, true) and (this.taken == false)) {
this.taken = true;
scorelevel = scorelevel + 1;
this.gotoAndStop(2);
if (musicOn == true) {
coinSound.start();
}
}
};
}
if (arrLevel[levely][levelx] == 6) {
Oneup = oneup.attachMovie("oneup", "oneup", oneup.getNextHighestDepth(), {_x:levelx * 25, _y:levely * 25});
Oneup.taken = false;
Oneup.onEnterFrame = function () {
if (_root.player.hitTest((oneup._x + this._x) + halfwidth, (oneup._y + this._y) + halfwidth, true) and (this.taken == false)) {
this.taken = true;
lives = lives + 1;
this.gotoAndStop(2);
}
};
}
levely++;
}
levelx++;
}
restart();
gameOn = true;
tag.tagdisplay.text = "Level " + levelnow;
tag.tagdisplay._alpha = 100;
player.onEnterFrame = function () {
if (Paused == false) {
game();
}
};
_root.pauseMenu.musicSwitch.onRelease = function () {
if (musicOn == false) {
musicOn = true;
} else {
musicOn = false;
}
};
_root.pauseMenu.BTNmenu.onRelease = function () {
if (Paused == true) {
_root.pauseMenu._y = -125;
Paused = false;
endlevel();
gotoAndStop ("mainmenu");
}
};
_root.pauseMenu.BTNcont.onRelease = function () {
if (Paused == true) {
_root.pauseMenu._alpha = 0;
Paused = false;
if (_root.tag._currentframe != 32) {
_root.tag.play();
}
if ((player.dying._currentframe != 12) and (player.dying._currentframe != 1)) {
player.dying.play();
}
}
};
}
function game() {
if (Key.isDown(27) and (Paused == false)) {
Paused = true;
pauseMenu._alpha = 100;
tag.stop();
player.dying.stop();
}
if ((Key.isDown(32) and (onground == true)) and (dy >= (-halfwidth))) {
dy = -jump;
if (musicOn == true) {
jumpSound.start();
}
}
if (Key.isDown(37)) {
dx = dx - speed;
}
if (Key.isDown(39)) {
dx = dx + speed;
}
if ((Key.isDown(39) != true) and (Key.isDown(37) != true)) {
playerMoving = false;
} else {
playerMoving = true;
}
if ((Key.isDown(38) != true) and (Key.isDown(40) != true)) {
playerClimb = false;
} else {
playerClimb = true;
}
if (Key.isDown(38) and (climbing == true)) {
dy = -2;
}
if (Key.isDown(40) and (climbing == true)) {
dy = 2;
}
if (ladder.hitTest(player._x, (player._y + halfwidth) + 1, true) or ladder.hitTest(player._x, (player._y + halfwidth) - 1, true)) {
climbing = true;
} else {
climbing = false;
}
if (onground == true) {
bounce = 0;
} else if (dy > bounce) {
bounce = dy;
}
if (((bounce >= 5) and (onground == false)) and (block.hitTest(player._x, player._y + halfwidth, true) or slope.hitTest(player._x, player._y + halfwidth, true))) {
dy = -0.6 * bounce;
if (musicOn == true) {
bounceSound.start();
}
}
p = -3;
while (p <= 3) {
if (slope.hitTest((player._x - r45) + p, player._y + r45, true) and (playerMoving == false)) {
dx++;
}
if (slope.hitTest((player._x + r45) - p, player._y + r45, true) and (playerMoving == false)) {
dx--;
}
if (((block.hitTest((player._x + p) - 3, player._y + halfwidth, true) or slope.hitTest((player._x + p) - 3, player._y + halfwidth, true)) or slope.hitTest((player._x - r45) - p, ((player._y + r45) + p) + 3, true)) or slope.hitTest((player._x + r45) + p, ((player._y + r45) + p) + 3, true)) {
onground = true;
} else {
onground = false;
}
while (((block.hitTest((player._x + dx) + p, ((player._y + halfwidth) + 1) + dy, true) or slope.hitTest((player._x + dx) + p, ((player._y + halfwidth) + 1) + dy, true)) or slope.hitTest((player._x - r45) + dx, ((player._y + r45) + 1) + dy, true)) or slope.hitTest((player._x + r45) + dx, ((player._y + r45) + 1) + dy, true)) {
dy--;
}
p++;
}
while (((block.hitTest(player._x + dx, ((player._y - halfwidth) + 3) + dy, true) or slope.hitTest(player._x + dx, ((player._y - halfwidth) + 3) + dy, true)) or slope.hitTest((player._x - r45) + dx, (player._y - r45) + dy, true)) or slope.hitTest((player._x + r45) + dx, (player._y - r45) + dy, true)) {
dy++;
}
while (block.hitTest(((player._x - halfwidth) + dx) + 1, player._y + dy, true) or slope.hitTest(((player._x - halfwidth) + 1) + dx, player._y + dy, true)) {
dx++;
}
while (block.hitTest(((player._x + halfwidth) - 1) + dx, player._y + dy, true) or slope.hitTest(((player._x + halfwidth) - 1) + dx, player._y + dy, true)) {
dx--;
}
if (hurt == true) {
if (shielded == true) {
shield._alpha = 0;
recovery++;
if (player.dying._currentframe == 1) {
player.dying.play();
if (musicOn == true) {
hurtSound.start();
}
}
} else {
dead = true;
}
}
if (recovery > recoverTime) {
hurt = false;
shielded = false;
recovery = 0;
}
if (dead == true) {
death++;
restart();
unlocked = 0;
tag.tagdisplay.text = "You Died";
tag.gotoAndPlay(1);
tag.tagdisplay._alpha = 100;
}
if (death >= 3) {
if (musicOn == true) {
deathSound.start();
}
dead = false;
death = 0;
lives = lives - 1;
}
if (lives == 0) {
endlevel();
gotoAndStop ("gameover");
dead = false;
}
if (climbing == false) {
dy = dy + gravity;
} else if (playerClimb == false) {
if (dy < -1) {
dy = dy + gravity;
} else if (dy > 1) {
dy = dy - gravity;
}
}
if (dy > maxgravity) {
dy = maxgravity;
}
if (dy < (-jump)) {
dy = -jump;
}
if (dx > maxspeed) {
dx = maxspeed;
}
if (dx < (-maxspeed)) {
dx = -maxspeed;
}
if (dx > 0) {
dx = dx - inertia;
}
if (dx < 0) {
dx = dx + inertia;
}
if (((dx <= 1) and (dx >= -1)) and (playerMoving == false)) {
dx = 0;
}
if ((dy <= 1) and (dy >= -1)) {
dy = 0;
}
player._rotation = player._rotation + (dx * Math.PI);
scoreCounter.scorecount.text = score + scorelevel;
livesCounter.lifecount.text = lives;
moveLevel();
}
function endlevel() {
score = score + scorelevel;
coinTotal = 0;
scorelevel = 0;
locked = true;
gameOn = false;
pasued = false;
lockTotal = 0;
unlocked = 0;
backDrop.removeMovieClip();
bounds.removeMovieClip();
block.removeMovieClip();
slope.removeMovieClip();
lock.removeMovieClip();
gate.removeMovieClip();
ladder.removeMovieClip();
mover.removeMovieClip();
bullets.removeMovieClip();
turret.removeMovieClip();
spiketrap.removeMovieClip();
door.removeMovieClip();
tag.removeMovieClip();
pauseMenu.removeMovieClip();
coins.removeMovieClip();
oneup.removeMovieClip();
scoreCounter.removeMovieClip();
livesCounter.removeMovieClip();
shield.removeMovieClip();
player.removeMovieClip();
}
function restart() {
dx = 0;
dy = 0;
recovery = 0;
hurt = false;
shielded = true;
player.dying.gotoAndStop(1);
shield.gotoAndStop(playercolor);
player.gotoAndStop(playercolor);
shield._alpha = 100;
pauseMenu._alpha = 0;
backDrop._y = 125 + (0.25 * yoffset);
backDrop._x = 250 + (0.25 * xoffset);
bounds._y = yoffset;
bounds._x = xoffset;
block._y = yoffset;
block._x = xoffset;
slope._y = yoffset;
slope._x = xoffset;
lock._y = yoffset;
lock._x = xoffset;
gate._y = yoffset;
gate._x = xoffset;
ladder._y = yoffset;
ladder._x = xoffset;
door._y = yoffset;
door._x = xoffset;
mover._y = yoffset;
mover._x = xoffset;
turret._y = yoffset;
turret._x = xoffset;
bullets._y = yoffset;
bullets._x = xoffset;
spiketrap._y = yoffset;
spiketrap._x = xoffset;
coins._y = yoffset;
coins._x = xoffset;
oneup._y = yoffset;
oneup._x = xoffset;
}
function moveLevel() {
backDrop._x = backDrop._x - (0.25 * dx);
bounds._x = bounds._x - dx;
block._x = block._x - dx;
slope._x = slope._x - dx;
lock._x = lock._x - dx;
gate._x = gate._x - dx;
ladder._x = ladder._x - dx;
door._x = door._x - dx;
mover._x = mover._x - dx;
turret._x = turret._x - dx;
bullets._x = bullets._x - dx;
spiketrap._x = spiketrap._x - dx;
coins._x = coins._x - dx;
oneup._x = oneup._x - dx;
backDrop._y = backDrop._y - (0.25 * dy);
bounds._y = bounds._y - dy;
block._y = block._y - dy;
slope._y = slope._y - dy;
lock._y = lock._y - dy;
gate._y = gate._y - dy;
ladder._y = ladder._y - dy;
door._y = door._y - dy;
mover._y = mover._y - dy;
turret._y = turret._y - dy;
bullets._y = bullets._y - dy;
spiketrap._y = spiketrap._y - dy;
coins._y = coins._y - dy;
oneup._y = oneup._y - dy;
}
function attachMovies() {
attachMovie("backDrop", "backDrop", 1, {_x:250, _y:125});
attachMovie("bounds", "bounds", 2, {_x:0, _y:0});
_root.createEmptyMovieClip("lock", 3);
_root.createEmptyMovieClip("coins", 4);
_root.createEmptyMovieClip("oneup", 5);
_root.createEmptyMovieClip("door", 6);
_root.createEmptyMovieClip("gate", 7);
_root.createEmptyMovieClip("ladder", 8);
_root.createEmptyMovieClip("mover", 9);
_root.createEmptyMovieClip("bullets", 10);
_root.createEmptyMovieClip("turret", 11);
_root.createEmptyMovieClip("spiketrap", 12);
_root.createEmptyMovieClip("block", 13);
_root.createEmptyMovieClip("slope", 14);
attachMovie("shield", "shield", 15, {_x:250, _y:125});
attachMovie("player", "player", 16, {_x:250, _y:125});
attachMovie("scoreCounter", "scoreCounter", 17, {_x:435, _y:18});
attachMovie("livesCounter", "livesCounter", 18, {_x:65, _y:18});
attachMovie("tag", "tag", 19, {_x:250, _y:125});
attachMovie("pauseMenu", "pauseMenu", 20, {_x:250, _y:125});
}
arrLevel = new Array();
dy = 0;
dx = 0;
r45 = 8.83883476483184;
maxgravity = 25;
halfwidth = 12.5;
bounce = 0;
gravity = 2;
speed = 1.5;
maxspeed = 8;
inertia = 1;
onground = false;
jump = 16;
dead = false;
death = 0;
pinkUnlocked = false;
playerMoving = false;
climbing = false;
playerClimb = false;
Paused = false;
bspeed = 6;
reloadDelay = 16;
recoverTime = 16;
levelnow = 0;
score = 0;
coinTotal = 0;
scorelevel = 0;
locked = true;
lockTotal = 0;
unlocked = 0;
shielded = true;
hurt = false;
recovery = 0;
musicOn = false;
gameOn = false;
bounceSound = new Sound();
bounceSound.attachSound("bounce.wav");
coinSound = new Sound();
coinSound.attachSound("coin.wav");
deathSound = new Sound();
deathSound.attachSound("death.wav");
hurtSound = new Sound();
hurtSound.attachSound("hurt.wav");
jumpSound = new Sound();
jumpSound.attachSound("jump.wav");
lockSound = new Sound();
lockSound.attachSound("lock.wav");
_root.onEnterFrame = function () {
if (musicOn == true) {
musicSwitch.gotoAndStop(1);
pauseMenu.musicSwitch.gotoAndStop(1);
} else {
musicSwitch.gotoAndStop(2);
pauseMenu.musicSwitch.gotoAndStop(2);
}
if ((Paused == false) and (gameOn == true)) {
if (tag.tagdisplay._alpha > -2) {
tag.tagdisplay._alpha = tag.tagdisplay._alpha - 2;
}
Mouse.hide();
} else {
Mouse.show();
}
};
Frame 3
stop();
BTNplay.onRelease = function () {
gotoAndStop ("level1");
lives = 3;
score = 0;
};
BTNselection.onRelease = function () {
gotoAndStop ("selection");
};
BTNhowTo.onRelease = function () {
gotoAndStop ("howTo");
};
musicSwitch.onRelease = function () {
if (musicOn == false) {
musicOn = true;
this.gotoAndStop(1);
} else {
musicOn = false;
this.gotoAndStop(2);
}
};
Frame 4
function empty() {
playerBlue.removeMovieClip();
playerGreen.removeMovieClip();
playerOrange.removeMovieClip();
playerWhite.removeMovieClip();
playerBrown.removeMovieClip();
playerPink.removeMovieClip();
shield.removeMovieClip();
gotoAndStop ("mainmenu");
}
attachMovie("shield", "shield", getNextHighestDepth(), {_x:137.5, _y:-100});
attachMovie("player", "playerBlue", getNextHighestDepth(), {_x:175, _y:100});
attachMovie("player", "playerGreen", getNextHighestDepth(), {_x:250, _y:100});
attachMovie("player", "playerOrange", getNextHighestDepth(), {_x:325, _y:100});
attachMovie("player", "playerWhite", getNextHighestDepth(), {_x:212.5, _y:175});
attachMovie("player", "playerBrown", getNextHighestDepth(), {_x:287.5, _y:175});
attachMovie("player", "playerPink", getNextHighestDepth(), {_x:137.5, _y:-100});
playerGreen.gotoAndStop(2);
playerOrange.gotoAndStop(3);
playerWhite.gotoAndStop(4);
playerBrown.gotoAndStop(5);
playerPink.gotoAndStop(6);
shield._xscale = 200;
shield._yscale = 200;
playerBlue.onRelease = function () {
playercolor = 1;
empty();
};
playerBlue.onEnterFrame = function () {
this._xscale = 200;
this._yscale = 200;
if (this.hitTest(_root._xmouse, _root._ymouse)) {
_root.shield._x = this._x;
_root.shield._y = this._y;
_root.shield.gotoAndStop(1);
}
};
playerGreen.onRelease = function () {
playercolor = 2;
empty();
};
playerGreen.onEnterFrame = function () {
this._xscale = 200;
this._yscale = 200;
if (this.hitTest(_root._xmouse, _root._ymouse)) {
_root.shield._x = this._x;
_root.shield._y = this._y;
_root.shield.gotoAndStop(2);
}
};
playerOrange.onRelease = function () {
playercolor = 3;
empty();
};
playerOrange.onEnterFrame = function () {
this._xscale = 200;
this._yscale = 200;
if (this.hitTest(_root._xmouse, _root._ymouse)) {
_root.shield._x = this._x;
_root.shield._y = this._y;
_root.shield.gotoAndStop(3);
}
};
playerWhite.onRelease = function () {
playercolor = 4;
empty();
};
playerWhite.onEnterFrame = function () {
this._xscale = 200;
this._yscale = 200;
if (this.hitTest(_root._xmouse, _root._ymouse)) {
_root.shield._x = this._x;
_root.shield._y = this._y;
_root.shield.gotoAndStop(4);
}
};
playerBrown.onRelease = function () {
playercolor = 5;
empty();
};
playerBrown.onEnterFrame = function () {
this._xscale = 200;
this._yscale = 200;
if (this.hitTest(_root._xmouse, _root._ymouse)) {
_root.shield._x = this._x;
_root.shield._y = this._y;
_root.shield.gotoAndStop(5);
}
};
playerPink.onRelease = function () {
playercolor = 6;
empty();
};
playerPink.onEnterFrame = function () {
if (pinkUnlocked == true) {
this._y = 175;
}
this._xscale = 200;
this._yscale = 200;
if (this.hitTest(_root._xmouse, _root._ymouse)) {
_root.shield._x = this._x;
_root.shield._y = this._y;
_root.shield.gotoAndStop(6);
} else {
_root.shield._x = -100;
}
};
BTNreturn.onRelease = function () {
empty();
};
Frame 5
BTNreturn.onRelease = function () {
_root.gotoAndStop("mainmenu");
};
Frame 6
stop();
_root.player.removeMovieClip();
_root.scoreMC.removeMovieClip();
_root.livesMC.removeMovieClip();
BTNmenu.onRelease = function () {
_root.tag.removeMovieClip();
_root.gotoAndStop("mainmenu");
};
goldcount.text = "Gold: " + score;
Frame 7
levelnow = 1;
xoffset = 12.5;
yoffset = 87.5;
arrLevel[0] = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
arrLevel[1] = new Array(1, 0, 0, 0, 0, 0, 0, 31, 1, 0, 1, 31, 24, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 31, 1);
arrLevel[2] = new Array(1, 0, 0, 0, 22, 1, 1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 5, 1, 5, 1, 1);
arrLevel[3] = new Array(1, 1, 21, 0, 0, 0, 0, 0, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1);
arrLevel[4] = new Array(1, 0, 0, 0, 0, 0, 0, 5, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 23, 1, 0, 0, 1, 1, 1, 1, 21, 0, 0, 0, 0, 0, 0, 1);
arrLevel[5] = new Array(1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 1, 0, 1, 5, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 23, 1, 0, 0, 0, 0, 0, 0, 1);
arrLevel[6] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 24, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 21, 0, 0, 0, 0, 0, 1);
arrLevel[7] = new Array(1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1, 42, 0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 21, 0, 0, 0, 23, 1, 0, 0, 0, 0, 0, 1);
arrLevel[8] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 43, 1, 21, 0, 0, 0, 0, 1);
arrLevel[9] = new Array(1, 0, 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 1, 1, 1, 5, 1, 1, 0, 0, 0, 1, 0, 23, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1);
arrLevel[10] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1);
arrLevel[11] = new Array(1, 0, 0, 0, 0, 1, 1, 0, 1, 0, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1);
arrLevel[12] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 0, 1, 1, 1);
arrLevel[13] = new Array(1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 22, 1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 0, 1, 1, 1);
arrLevel[14] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 24, 0, 1, 1, 1);
arrLevel[15] = new Array(1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 21, 0, 0, 0, 0, 0, 22, 1, 1, 1, 1, 1, 21, 0, 22, 1, 1, 21, 0, 0, 0, 0, 0, 22, 1, 1, 1);
arrLevel[16] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 21, 0, 22, 1, 1, 1, 24, 0, 0, 0, 23, 1, 1, 24, 0, 0, 23, 1, 1, 1, 1, 1, 1, 1, 1, 1);
arrLevel[17] = new Array(1, 1, 1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 0, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1);
arrLevel[18] = new Array(1, 1, 1, 1, 0, 0, 0, 22, 1, 1, 1, 21, 0, 0, 0, 0, 32, 0, 22, 1, 0, 41, 0, 0, 0, 0, 0, 0, 0, 41, 0, 1, 21, 0, 0, 0, 0, 0, 33, 1);
arrLevel[19] = new Array(1, 1, 1, 1, 44, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 44, 1, 1, 1, 1, 1, 1, 1, 1, 1, 44, 1, 1, 1, 1, 1, 1, 1, 1, 1);
buildLevel();
Frame 8
levelnow = 2;
xoffset = 212.5;
yoffset = 87.5;
arrLevel[0] = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
arrLevel[1] = new Array(1, 0, 1, 1, 1, 1, 0, 0, 23, 1, 42, 0, 0, 0, 0, 0, 0, 0, 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 23, 1, 1);
arrLevel[2] = new Array(1, 0, 1, 5, 1, 1, 31, 0, 0, 1, 24, 0, 0, 0, 0, 0, 0, 0, 1, 1, 5, 1, 5, 1, 5, 1, 1, 0, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 31, 1);
arrLevel[3] = new Array(1, 0, 1, 0, 1, 1, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1);
arrLevel[4] = new Array(1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 43, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 21, 0, 0, 0, 23, 1);
arrLevel[5] = new Array(1, 0, 23, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 24, 0, 0, 0, 23, 1, 21, 0, 0, 0, 1);
arrLevel[6] = new Array(1, 0, 0, 0, 23, 1, 24, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 23, 1, 1, 21, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[7] = new Array(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 21, 0, 0, 1, 24, 0, 6, 21, 0, 0, 0, 0, 0, 1, 1, 1);
arrLevel[8] = new Array(1, 1, 1, 21, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 24, 0, 23, 1, 1, 1, 1, 1, 0, 0, 22, 1, 24, 0, 0, 0, 0, 0, 0, 1);
arrLevel[9] = new Array(1, 24, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 0, 0, 0, 0, 1, 1, 0, 1);
arrLevel[10] = new Array(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[11] = new Array(1, 0, 22, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 24, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 0, 0, 1);
arrLevel[12] = new Array(1, 0, 0, 0, 23, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 24, 0, 0, 0, 1);
arrLevel[13] = new Array(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[14] = new Array(1, 1, 1, 21, 0, 1, 0, 0, 0, 22, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 0, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[15] = new Array(1, 24, 0, 0, 0, 1, 1, 24, 0, 1, 24, 0, 0, 0, 0, 0, 23, 21, 0, 0, 0, 22, 24, 0, 0, 0, 0, 0, 1, 1, 1, 24, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[16] = new Array(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 23, 1, 1, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[17] = new Array(1, 0, 22, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1);
arrLevel[18] = new Array(1, 41, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 0, 0, 0, 21, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 33, 1);
arrLevel[19] = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 44, 44, 44, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
buildLevel();
Frame 9
levelnow = 3;
xoffset = -687.5;
yoffset = -337.5;
arrLevel[0] = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
arrLevel[1] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 24, 0, 0, 0, 23, 1, 1, 24, 0, 0, 0, 0, 0, 1);
arrLevel[2] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 31, 0, 43, 1, 0, 0, 0, 0, 0, 0, 1);
arrLevel[3] = new Array(1, 42, 0, 0, 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 22, 1, 1, 1, 1, 0, 22, 1, 1, 1, 0, 1);
arrLevel[4] = new Array(1, 0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 1, 1, 0, 1, 24, 0, 0, 0, 1);
arrLevel[5] = new Array(1, 5, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 24, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 1);
arrLevel[6] = new Array(1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 24, 0, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 1);
arrLevel[7] = new Array(1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 24, 0, 1, 1, 1, 24, 0, 0, 0, 0, 0, 0, 1, 0, 23, 0, 1, 0, 0, 1, 1, 1);
arrLevel[8] = new Array(1, 0, 0, 0, 0, 0, 22, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 31, 0, 0, 1, 0, 0, 0, 23, 1);
arrLevel[9] = new Array(1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 0, 23, 1, 0, 0, 0, 0, 22, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1);
arrLevel[10] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 1, 0, 0, 1, 0, 0, 22, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1);
arrLevel[11] = new Array(1, 1, 1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 1, 1, 24, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 0, 1, 1, 1, 0, 0, 1);
arrLevel[12] = new Array(1, 1, 1, 1, 21, 0, 0, 0, 0, 0, 0, 0, 1, 1, 24, 0, 0, 0, 0, 0, 1, 1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 24, 0, 0, 1);
arrLevel[13] = new Array(1, 0, 0, 23, 1, 21, 0, 0, 0, 0, 0, 0, 1, 1, 42, 0, 0, 0, 0, 1, 1, 1, 1, 1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 1);
arrLevel[14] = new Array(1, 0, 0, 0, 23, 1, 21, 0, 0, 0, 0, 0, 23, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 21, 0, 0, 22, 1, 1, 1, 0, 0, 1, 0, 0, 23, 1);
arrLevel[15] = new Array(1, 21, 0, 0, 0, 23, 1, 1, 1, 0, 0, 0, 0, 5, 1, 0, 0, 1, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 24, 0, 0, 0, 1, 1, 0, 0, 1);
arrLevel[16] = new Array(1, 1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 1, 24, 0, 0, 1, 0, 0, 0, 0, 0, 22, 1, 1, 1, 0, 22, 1, 0, 1, 24, 0, 0, 1);
arrLevel[17] = new Array(1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 23, 0, 0, 0, 5, 0, 0, 0, 0, 22, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 1, 1);
arrLevel[18] = new Array(1, 33, 0, 32, 0, 1, 0, 41, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 1, 0, 22, 1, 1, 1, 1, 1, 1, 21, 5, 0, 1, 0, 0, 1, 1);
arrLevel[19] = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 44, 1, 44, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 44, 1, 1, 1, 1, 1);
buildLevel();
Frame 10
levelnow = 4;
xoffset = 212.5;
yoffset = -337.5;
arrLevel[0] = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
arrLevel[1] = new Array(1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 1, 24, 0, 0, 31, 0, 0, 23, 1, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 33, 1);
arrLevel[2] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 22, 1, 21, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 1, 1, 1);
arrLevel[3] = new Array(1, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 24, 0, 0, 0, 0, 1);
arrLevel[4] = new Array(1, 0, 22, 1, 1, 1, 1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1);
arrLevel[5] = new Array(1, 0, 0, 0, 0, 0, 0, 23, 21, 0, 0, 0, 0, 22, 1, 21, 0, 0, 0, 22, 1, 21, 0, 0, 0, 0, 0, 0, 41, 0, 0, 22, 1, 24, 0, 0, 0, 0, 0, 1);
arrLevel[6] = new Array(1, 21, 0, 0, 0, 0, 0, 0, 23, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 1, 1, 24, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[7] = new Array(1, 1, 1, 1, 1, 1, 21, 0, 0, 23, 21, 41, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 41, 22, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[8] = new Array(1, 24, 0, 0, 0, 0, 23, 21, 0, 0, 23, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 24, 0, 0, 22, 1, 1, 1, 21, 0, 0, 0, 0, 31, 0, 0, 1);
arrLevel[9] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 21, 0, 0, 5, 0, 0, 1);
arrLevel[10] = new Array(1, 42, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 21, 0, 23, 1, 0, 0, 5, 0, 0, 1);
arrLevel[11] = new Array(1, 0, 0, 0, 22, 1, 1, 1, 21, 0, 5, 0, 0, 0, 23, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 21, 0, 1, 0, 0, 6, 0, 0, 1);
arrLevel[12] = new Array(1, 0, 0, 0, 0, 23, 1, 1, 24, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1);
arrLevel[13] = new Array(1, 1, 21, 0, 0, 0, 1, 24, 0, 0, 0, 0, 0, 0, 0, 1, 0, 22, 1, 1, 1, 1, 1, 1, 21, 0, 0, 0, 41, 0, 0, 0, 22, 1, 44, 44, 44, 21, 0, 1);
arrLevel[14] = new Array(1, 1, 24, 0, 0, 22, 24, 0, 22, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 23, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 24, 0, 1);
arrLevel[15] = new Array(1, 42, 0, 0, 22, 24, 0, 22, 24, 0, 0, 0, 0, 21, 0, 23, 21, 0, 22, 1, 1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[16] = new Array(1, 31, 0, 22, 24, 0, 22, 24, 0, 0, 0, 0, 0, 23, 21, 0, 23, 1, 1, 24, 23, 1, 1, 1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 21, 0, 0, 0, 1);
arrLevel[17] = new Array(1, 1, 1, 24, 0, 22, 24, 0, 0, 0, 0, 0, 0, 0, 23, 21, 0, 23, 24, 0, 0, 23, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 24, 0, 0, 0, 1);
arrLevel[18] = new Array(1, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1);
arrLevel[19] = new Array(1, 1, 1, 1, 1, 1, 44, 44, 44, 44, 44, 44, 44, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
buildLevel();
Frame 11
levelnow = 5;
xoffset = 162.5;
yoffset = -162.5;
arrLevel[0] = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
arrLevel[1] = new Array(1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1);
arrLevel[2] = new Array(1, 0, 22, 1, 1, 21, 0, 0, 0, 22, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 21, 0, 0, 0, 1);
arrLevel[3] = new Array(1, 0, 1, 24, 0, 23, 1, 5, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 0, 0, 0, 1);
arrLevel[4] = new Array(1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 21, 0, 0, 0, 0, 0, 0, 0, 31, 0, 43, 1, 0, 0, 0, 1);
arrLevel[5] = new Array(1, 0, 1, 0, 0, 0, 0, 0, 0, 22, 1, 21, 0, 0, 22, 1, 1, 21, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 23, 1, 24, 5, 1, 1, 0, 0, 1);
arrLevel[6] = new Array(1, 0, 1, 0, 21, 0, 0, 0, 0, 1, 42, 0, 0, 0, 0, 0, 23, 1, 1, 21, 0, 0, 0, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 43, 1, 24, 0, 0, 1);
arrLevel[7] = new Array(1, 0, 1, 0, 1, 21, 0, 0, 0, 1, 0, 0, 23, 1, 24, 0, 0, 0, 23, 1, 21, 0, 0, 0, 0, 0, 0, 0, 23, 1, 24, 0, 0, 0, 0, 0, 0, 0, 1, 1);
arrLevel[8] = new Array(1, 0, 1, 0, 23, 1, 21, 0, 0, 1, 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1);
arrLevel[9] = new Array(1, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 23, 1, 24, 0, 0, 23, 21, 0, 0, 23, 1, 24, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 1, 1);
arrLevel[10] = new Array(1, 0, 1, 0, 0, 0, 0, 22, 1, 1, 5, 41, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 24, 0, 0, 23, 1);
arrLevel[11] = new Array(1, 0, 1, 0, 0, 22, 1, 1, 1, 1, 1, 1, 1, 1, 1, 21, 0, 0, 0, 0, 41, 31, 1, 21, 0, 0, 0, 0, 22, 1, 1, 1, 33, 0, 32, 0, 0, 0, 0, 1);
arrLevel[12] = new Array(1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 21, 0, 0, 0, 1);
arrLevel[13] = new Array(1, 0, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[14] = new Array(1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 21, 0, 0, 1);
arrLevel[15] = new Array(1, 0, 1, 0, 0, 0, 0, 0, 0, 22, 1, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 24, 0, 0, 1);
arrLevel[16] = new Array(1, 0, 1, 0, 0, 0, 0, 22, 1, 1, 24, 0, 0, 0, 0, 0, 0, 0, 23, 1, 24, 0, 0, 0, 0, 0, 23, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1);
arrLevel[17] = new Array(1, 0, 0, 0, 0, 22, 1, 1, 1, 42, 5, 0, 0, 31, 41, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 43, 1);
arrLevel[18] = new Array(1, 0, 0, 22, 1, 1, 1, 1, 24, 0, 23, 1, 1, 1, 1, 1, 24, 0, 0, 0, 0, 0, 23, 1, 24, 0, 0, 0, 0, 0, 23, 1, 24, 0, 0, 22, 1, 1, 1, 1);
arrLevel[19] = new Array(1, 1, 1, 1, 1, 1, 1, 1, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 1, 1, 1, 1, 1, 1);
buildLevel();
Frame 12
if (score == 30) {
levelnow = "X";
xoffset = 162.5;
yoffset = -312.5;
arrLevel[0] = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
arrLevel[1] = new Array(1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 33, 1);
arrLevel[2] = new Array(1, 0, 12, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
arrLevel[3] = new Array(1, 0, 12, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1);
arrLevel[4] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[5] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 24, 0, 0, 0, 23, 1, 1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 1);
arrLevel[6] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 21, 0, 0, 0, 23, 1, 24, 0, 0, 22, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 43, 1);
arrLevel[7] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 22, 1, 1, 0, 0, 0, 0, 0, 5, 0, 0, 22, 1, 42, 0, 0, 0, 0, 5, 0, 0, 0, 0, 1, 21, 0, 0, 0, 0, 0, 31, 1);
arrLevel[8] = new Array(1, 0, 12, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 23, 1, 1, 1);
arrLevel[9] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[10] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[11] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[12] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 22, 21, 0, 0, 22, 21, 0, 0, 22, 21, 0, 0, 22, 21, 0, 0, 22, 21, 0, 0, 22, 21, 0, 22, 21, 0, 0, 0, 0, 0, 31, 1);
arrLevel[13] = new Array(1, 0, 12, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 1, 1);
arrLevel[14] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[15] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[16] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 0, 22, 44, 44, 21, 0, 0, 0, 0, 0, 0, 0, 0, 1);
arrLevel[17] = new Array(1, 0, 12, 0, 0, 0, 0, 0, 22, 1, 1, 1, 21, 0, 0, 0, 0, 23, 1, 1, 1, 24, 0, 0, 0, 0, 22, 1, 1, 1, 1, 21, 0, 0, 0, 0, 0, 0, 31, 1);
arrLevel[18] = new Array(1, 0, 23, 1, 24, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1, 1, 1);
arrLevel[19] = new Array(1, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 1);
buildLevel();
} else {
play();
}
Frame 13
stop();
if (score == 36) {
pinkUnlocked = true;
advice.text = "You've unlocked a new character!";
} else {
advice.text = "Try collecting all the coins!";
}
BTNmenu.onRelease = function () {
_root.tag.removeMovieClip();
_root.gotoAndStop("mainmenu");
};
goldcount.text = "Gold: " + score;
Symbol 23 MovieClip Frame 1
stop();
Symbol 23 MovieClip Frame 2
stop();
Symbol 29 MovieClip [tag] Frame 32
stop();
Symbol 33 MovieClip [block] Frame 1
stop();
Symbol 33 MovieClip [block] Frame 2
stop();
Symbol 33 MovieClip [block] Frame 3
stop();
Symbol 38 MovieClip Frame 1
stop();
Symbol 38 MovieClip Frame 12
stop();
Symbol 44 MovieClip [player] Frame 1
stop();
Symbol 44 MovieClip [player] Frame 2
stop();
Symbol 44 MovieClip [player] Frame 3
stop();
Symbol 44 MovieClip [player] Frame 4
stop();
Symbol 44 MovieClip [player] Frame 5
stop();
Symbol 44 MovieClip [player] Frame 6
stop();
Symbol 47 MovieClip [lock] Frame 1
stop();
Symbol 47 MovieClip [lock] Frame 2
stop();
Symbol 49 MovieClip [door] Frame 1
stop();
Symbol 49 MovieClip [door] Frame 2
stop();
Symbol 51 MovieClip [gate] Frame 1
stop();
Symbol 51 MovieClip [gate] Frame 2
stop();
Symbol 56 MovieClip [enemy] Frame 1
stop();
Symbol 56 MovieClip [enemy] Frame 2
stop();
Symbol 60 MovieClip [spike] Frame 1
stop();
Symbol 62 MovieClip [coins] Frame 1
stop();
Symbol 62 MovieClip [coins] Frame 2
stop();
Symbol 74 MovieClip [oneup] Frame 1
stop();
Symbol 74 MovieClip [oneup] Frame 2
stop();
Symbol 76 MovieClip [backDrop] Frame 1
stop();
Symbol 83 MovieClip [shield] Frame 1
stop();
Symbol 83 MovieClip [shield] Frame 2
stop();
Symbol 83 MovieClip [shield] Frame 3
stop();
Symbol 83 MovieClip [shield] Frame 4
stop();
Symbol 83 MovieClip [shield] Frame 5
stop();
Symbol 83 MovieClip [shield] Frame 6
stop();