Frame 1
stop();
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;
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);
}
u = (((((((((((("http://" + mbc) + "/my/core.swf?mv=7&fv=") + fv) + "&v=") + escape(getVersion())) + "&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);
}
function fin() {
if (proceed) {
_root.levelData = _root._url.slice(_root._url.lastIndexOf("?map=") + 5);
_root.redirectExit = true;
_root.gotoAndPlay(4);
} else {
play();
}
}
fscommand ("showmenu", "false");
__com_mochibot__("afe7691c", this, 10301, true);
var bob = Math.random();
if (_root._url.lastIndexOf("?map=") == -1) {
MochiAd.showPreGameAd({id:"f261a43f34277875", res:"800x600", ad_finished:fin, no_bg:true});
} else if (bob < 0.05) {
MochiAd.showPreGameAd({id:"f261a43f34277875", res:"800x600", ad_finished:fin, no_bg:true});
proceed = true;
} else {
_root.levelData = _root._url.slice(_root._url.lastIndexOf("?map=") + 5);
_root.redirectExit = true;
_root.gotoAndPlay(4);
}
_root.kongregateServices.connect();
Frame 2
var my_sound = new Sound();
my_sound.onLoad = function (success) {
if (success) {
_root.loading._visible = false;
status_txt.text = "Sound loaded";
} else {
status_txt.text = "Sound failed";
}
};
my_sound.onSoundComplete = function () {
my_sound.start();
};
my_sound.loadSound("http://www.earthnemesis.com/BrickLevels/Music.mp3", true);
Frame 3
_root.Multiplayer = false;
_root.globalSound = new Sound();
_root.attachMovie("jukeBox", "jb", 0);
if (typeof(depthcount) == "number") {
var j = 0;
while (j <= depthcount) {
_root["list_item" + j].removeMovieClip();
j++;
}
depthcount = 0;
}
if ((Message == undefined) || (Message == "undefined")) {
Message = "";
}
pupb.removeMovieClip();
stop();
Frame 6
function endIt() {
Buffer._visible = false;
initLoop(true);
Balls = [new Ball(400, 340, true, Balls.length)];
moreBricks2();
}
function moreBricks() {
cancelPowerups(true);
Buffer._visible = true;
i = 0;
onEnterFrame = function () {
if (i >= depthcount) {
trace("Tha end.");
endIt();
} else {
trace(i);
while (i < depthcount) {
trace(depthcount);
var _local2 = _root.createEmptyMovieClip("bob" + i, i);
_local2.removeMovieClip();
i++;
}
}
};
}
function moreBricks2() {
_root.lives = 3;
_root.livesStr = String(lives);
bottomBrick = 387.4;
level++;
bricks = 0;
var _local2 = 0;
while (_local2 < _root.Balls.length) {
_root.Balls[_local2].clip._x = (400 + (_local2 * 15)) - ((_local2 * 15) / 2);
_root.Balls[_local2].clip._y = 340;
_root.Balls[_local2].onDrop(true);
_local2++;
}
_root.Balls[_local2].paused = true;
_root.BG.nextFrame();
if (((level >= levels.length) && (levels.length != undefined)) && (levels.length != 0)) {
_root.gotoAndStop(35);
}
_local2 = 0;
b = 0;
c = 0;
_local2 = 0;
while (_local2 < levels[level].length) {
if (_local2 == 15) {
break;
}
var b = 0;
while (b < levels[level][_local2].length) {
if (levels[level][_local2][b] != -1) {
if (bottomBrick == 387.4) {
bottomBrick = depthcount;
}
var _local3 = _root.attachMovie("Brick", "Brick" + depthcount, depthcount);
_local3._y = 20 + (_local2 * 20);
_local3._x = b * 50;
_local3.frame = levels[level][_local2][b];
_local3.score = 0;
depthcount++;
bricks++;
}
b++;
}
_local2++;
}
topBrick = depthcount;
maxBricks = bricks;
}
function cont() {
moreBricks();
}
function onPause() {
_root.P._visible = true;
MM = onMouseMove;
onMouseMove = null;
onEnterFrame = null;
}
function onUnPause() {
onMouseMove = MM;
delete MM;
_root.P._visible = false;
initLoop(true);
}
function initLoop(skip) {
onEnterFrame = function () {
var _local1 = 0;
while (_local1 < Balls.length) {
Balls[_local1].moveclip();
_local1++;
}
if (Multiplayer) {
if (Key.isDown(37)) {
Paddle2x--;
}
if (Key.isDown(39)) {
Paddle2x++;
}
if (Paddle2x > 0) {
Paddle2x = Paddle2x - 0.5;
} else if (Paddle2x < 0) {
Paddle2x = Paddle2x + 0.5;
}
Paddle2._x = Paddle2._x + Paddle2x;
if (Paddle2._x >= 800) {
Paddle2x = -Paddle2x;
}
if (Paddle2._x <= 0) {
Paddle2x = -Paddle2x;
}
}
};
}
function AddpowerUp(code) {
cancelPowerups(false);
switch (code) {
case 1 :
var _local2 = 0;
while (_local2 < Balls.length) {
Balls[_local2].clip.play();
_local2++;
}
PowerUps.gotoAndPlay(1);
PowerUps.frame = 4;
_root.powerUp = "Death";
break;
case 2 :
_local2 = 0;
while (_local2 < Balls.length) {
Balls[_local2].accl++;
_local2++;
}
PowerUps.gotoAndPlay(1);
PowerUps.frame = 8;
_root.powerUp = "Fast";
break;
case 4 :
var _local3 = Balls.length;
_local2 = 0;
while (_local2 < _local3) {
Balls[_local2].triple();
_local2++;
}
PowerUps.gotoAndPlay(1);
PowerUps.frame = 9;
_root.powerUp = "Triple";
break;
case 5 :
onMouseMove = function () {
Paddle._x = (-_xmouse) + Stage.width;
};
PowerUps.gotoAndPlay(1);
PowerUps.frame = 3;
_root.powerUp = "Reverse";
_root.attachMovie("PUPbar", "pupb", _root.depthcount);
_root.depthcount++;
break;
case 6 :
Balls[0].setRadio(true);
_root.attachMovie("PUPbar", "pupb", _root.depthcount);
_root.depthcount++;
_local2 = 0;
while (_local2 < _root.Balls.length) {
_root.Balls[_local2].inner.gotoAndStop(1);
_local2++;
}
PowerUps.gotoAndPlay(1);
PowerUps.frame = 1;
_root.powerUp = "Radioactive";
break;
case 7 :
_local2 = 0;
while (_local2 < _root.Balls.length) {
_root.Balls[_local2].accl = -_root.Balls[_local2].accl;
_local2++;
}
PowerUps.gotoAndPlay(1);
PowerUps.frame = 2;
_root.powerUp = "Helium";
_root.attachMovie("PUPbar", "pupb", _root.depthcount);
_root.depthcount++;
case 8 :
break;
case 9 :
_root.powerUp = "Grow";
PowerUps.gotoAndPlay(1);
PowerUps.frame = 6;
Paddle.E2._x = Paddle.E2._x - 5;
Paddle.E1._x = Paddle.E1._x + 5;
Paddle.Middle._width = Paddle.Middle._width + 10;
Paddle.Middle._x = Paddle.Middle._x - 5;
Paddle2.E2._x = Paddle2.E2._x - 5;
Paddle2.E1._x = Paddle2.E1._x + 5;
Paddle2.Middle._width = Paddle2.Middle._width + 10;
Paddle2.Middle._x = Paddle2.Middle._x - 5;
break;
case 10 :
_root.powerUp = "Shrink";
PowerUps.gotoAndPlay(1);
PowerUps.frame = 5;
Paddle.E2._x = Paddle.E2._x + 5;
Paddle.E1._x = Paddle.E1._x - 5;
Paddle.Middle._width = Paddle.Middle._width - 10;
Paddle.Middle._x = Paddle.Middle._x + 5;
Paddle2.E2._x = Paddle2.E2._x + 5;
Paddle2.E1._x = Paddle2.E1._x - 5;
Paddle2.Middle._width = Paddle2.Middle._width - 10;
Paddle2.Middle._x = Paddle2.Middle._x + 5;
}
}
function cancelPowerups(timed) {
if (timed) {
Balls[0].setRadio(false);
onMouseMove = function () {
Paddle._x = _xmouse;
};
pupb.removeMovieClip();
}
var _local2 = 0;
while (_local2 < _root.Balls.length) {
if (_root.Balls[_local2].accl < 0) {
_root.Balls[_local2].accl = -_root.Balls[_local2].accl;
}
_root.Balls[_local2].inner.gotoAndStop(1);
_local2++;
}
}
levels = [[[-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, -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, -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, -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, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1], [-1, -1, -1, -1, -1, 26, 26, 26, 26, 26, -1, -1, -1, -1, -1, -1], [-1, -1, -1, -1, -1, 20, 20, 20, 20, 20, -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, -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, -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, -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, -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, -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], [-1, -1, -1, 26, 8, 8, 8, 8, 8, 8, 8, 26, -1, -1, -1, -1], [-1, -1, -1, 26, 2, 2, 2, 2, 2, 2, 2, 26, -1, -1, -1, -1], [-1, -1, -1, 26, 2, 1, 1, 1, 1, 1, 2, 26, -1, -1, -1, -1], [-1, -1, -1, 26, 2, 1, 1, 19, 1, 1, 2, 26, -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, -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, -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, 19, -1, -1, -1, -1, -1, -1, -1, -1, 19, -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, 26, -1, -1, 26, -1, -1, -1, -1, 1, 1], [1, 1, 1, -1, -1, -1, 26, -1, -1, 26, -1, -1, -1, 1, 1, 1], [1, 1, 1, 1, -1, -1, 26, -1, -1, 26, -1, -1, 1, 1, 1, 1], [1, 1, 1, 1, 1, -1, 26, -1, -1, 26, -1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 26, -1, -1, 26, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 26, -1, -1, 26, 1, 1, 1, 1, 1, 1], [22, 22, 22, 22, 22, 22, 22, -1, -1, 22, 22, 22, 22, 22, 22, 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, -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, -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, -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, 2, 18, -1, -1, -1, 17, 2, -1, -1, -1, -1, -1], [-1, -1, -1, -1, 3, 2, 8, 8, 8, 2, 3, -1, -1, -1, -1, -1], [-1, -1, -1, -1, 3, 3, 1, 12, 1, 3, 3, -1, -1, -1, -1, -1], [-1, -1, -1, -1, 3, 15, 1, 19, 1, 15, 3, -1, -1, -1, -1, -1], [-1, -1, -1, -1, 3, 3, 1, 1, 1, 3, 3, -1, -1, -1, -1, -1], [-1, -1, -1, -1, 3, 2, -1, -1, -1, 2, 3, -1, -1, -1, -1, -1], [-1, -1, -1, -1, 2, 4, -1, -1, -1, 4, 2, -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, -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, -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, -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, -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, 21, 1, 21, 1, 21, 1, 21, 1, -1, -1, -1, -1], [-1, -1, -1, 21, 26, 21, 26, 21, 26, 21, 26, 21, -1, -1, -1, -1], [-1, -1, -1, 20, 20, 20, 20, 10, 20, 20, 20, 20, -1, -1, -1, -1], [-1, -1, -1, 20, 21, 20, 21, 20, 21, 20, 21, 20, -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, -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, -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, -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], [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, 10, 1, 1, -1, -1, -1, -1, -1, -1], [-1, -1, -1, -1, -1, 1, 1, 10, 1, 1, -1, -1, -1, -1, -1, -1], [-1, -1, -1, -1, -1, 1, 1, 10, 1, 1, -1, -1, -1, -1, -1, -1], [-1, -1, -1, -1, -1, -1, 19, 19, 19, -1, -1, -1, -1, -1, -1, -1], [-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]], [[-1, 20, 20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20, 20, -1], [20, 20, 20, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 20, 20, 20], [20, 20, 20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20, 20, 20], [-1, 21, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 21, -1], [-1, 21, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 21, -1], [-1, 21, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 21, -1], [20, 20, 20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20, 20, 20], [20, 20, 20, 22, 22, 22, 22, 19, 19, 22, 22, 22, 22, 20, 20, 20], [20, 20, 20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20, 20, 20], [-1, 21, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 21, -1], [-1, 21, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 21, -1], [-1, 21, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 21, -1], [20, 20, 20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20, 20, 20], [20, 20, 20, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 20, 20, 20], [-1, 20, 20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20, 20, -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], [25, 24, 23, 22, 21, 20, -1, -1, -1, -1, 20, 21, 22, 23, 24, 25], [24, 23, 22, 21, 20, -1, -1, -1, -1, -1, -1, 20, 21, 22, 23, 24], [23, 22, 21, 20, -1, -1, -1, -1, -1, -1, -1, -1, 20, 21, 22, 23], [22, 21, 20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20, 21, 22], [21, 20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20, 21], [20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20, 20], [-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, -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], [18, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 18], [18, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 18], [19, -1, -1, -1, 14, -1, -1, -1, -1, -1, -1, 14, -1, -1, -1, 19], [-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, -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, -1, -1, -1, -1, 1, 2, 1, -1, -1, -1, -1, -1, -1, -1], [-1, -1, -1, -1, -1, 1, 2, 3, 2, 1, -1, -1, -1, -1, -1, -1], [-1, -1, -1, 1, 1, 2, 3, 14, 3, 2, 1, 1, -1, -1, -1, -1], [-1, 1, 1, 2, 2, 3, 14, 19, 14, 3, 2, 2, 1, 1, -1, -1], [1, 2, 2, 3, 3, 14, 19, 15, 19, 14, 3, 3, 2, 2, 1, 1], [-1, 1, 1, 2, 2, 3, 14, 19, 14, 3, 2, 2, 1, 1, -1, -1], [-1, -1, -1, 1, 1, 2, 3, 14, 3, 2, 1, 1, -1, -1, -1, -1], [-1, -1, -1, -1, -1, 1, 2, 3, 2, 1, -1, -1, -1, -1, -1, -1], [-1, -1, -1, -1, -1, -1, -1, 2, 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, -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, -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, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1], [-1, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, -1], [-1, 8, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 8, -1], [-1, 8, 1, 1, 1, 1, 1, 19, 19, 1, 1, 1, 1, 1, 8, -1], [-1, 8, 1, 1, 1, 1, 1, 17, 17, 1, 1, 1, 1, 1, 8, -1], [-1, 8, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 8, -1], [-1, 8, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 8, -1], [8, 8, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 8, 8], [-1, -1, -1, 15, -1, 15, -1, -1, 15, -1, -1, 15, -1, 15, -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, -1, -1, -1, -1, -1, -1, -1, -1, -1]], [[-1, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, -1], [20, 12, -1, 17, -1, -1, 18, 17, 17, 18, -1, -1, 17, -1, 12, 20], [20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20], [20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20], [20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20], [20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 20], [20, -1, -1, -1, 1, 1, -1, -1, -1, -1, 1, 1, -1, -1, -1, 20], [20, -1, -1, 1, 22, 22, 1, 1, 1, 1, 22, 22, 1, -1, -1, 20], [20, -1, 1, 22, 1, 1, 22, 22, 22, 22, 1, 1, 22, 1, -1, 20], [20, 1, 22, 1, -1, -1, 1, 10, 10, 1, -1, -1, 1, 22, 1, 20], [20, 22, 1, -1, 13, 13, 15, 1, 1, 15, 13, 13, -1, 1, 22, 20], [26, 26, 26, 26, 25, 25, 26, 26, 26, 26, 25, 25, 26, 26, 26, 26], [-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, -1, -1, -1, -1, -1, -1, -1], [-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]]];
onMouseMove = function () {
Paddle._x = _xmouse;
};
depthcount = 0;
score = 0;
lives = 3;
level = -1;
livesStr = String(lives);
bricks = 0;
maxBricks = 0;
topBrick = 0;
bottomBrick = 0;
scoreStr = String(score);
cont();
P._visible = false;
Paused = false;
var listener = {};
listener.onKeyDown = function () {
if (Key.isDown(80)) {
if (!Paused) {
onPause();
Paused = true;
} else {
onUnPause();
Paused = false;
}
}
};
Key.addListener(listener);
_root._quality = "AUTOLOW";
gravity = 6;
gravSpeed = 0.25;
xmov = 0;
c = false;
rotspd = 0;
prevX = 0;
prevY = 0;
Paddle2x = 0;
if (Multiplayer) {
Paddle2._x = 654;
Paddle2x = 0;
}
stop();
Instance of Symbol 252 MovieClip "Paddle" in Frame 6
onClipEvent (enterFrame) {
this._rotation = Math.round(_rotation);
if (this._rotation > 0) {
this._rotation--;
} else if (this._rotation < 0) {
this._rotation++;
}
}
Instance of Symbol 252 MovieClip "Paddle2" in Frame 6
onClipEvent (enterFrame) {
this._rotation = Math.round(_rotation);
if (this._rotation > 0) {
this._rotation--;
} else if (this._rotation < 0) {
this._rotation++;
}
}
Frame 32
function go(Name, score) {
trace("SCORE!");
trace(score);
Name = Name.slice(Name.toUpperCase().indexOf("KERNING=\"0\">") + 12, Name.toUpperCase().indexOf("</FONT>"));
trace(Name);
var _local3 = new LoadVars();
_local3.onData = function (src) {
trace(src);
trace("DONE!");
winScreen.show._visible = true;
};
var _local2 = new LoadVars();
_local2.name = Name;
_local2.score = score;
_local2.sendAndLoad("http://www.earthnemesis.com/HighScore/score.php", _local3, "POST");
}
_root.kongregateScores.submit(_root.score);
var i = 0;
while (i < _root.Balls.length) {
_root.Balls[i].remove();
i++;
}
delete _root.Balls;
Frame 33
function endIt() {
Buffer._visible = false;
if (_root.preview != true) {
clearMap();
} else {
renderMap();
_root.preview = false;
}
onEnterFrame = null;
}
function attachBrick(frame, points) {
trace(frame);
var _local3 = points;
Bricks.localToGlobal(_local3);
trace(_root.depthcount);
var brick = _root.attachMovie("Brick", "Brick" + _root.depthcount, _root.depthcount);
_root.depthcount++;
brick._x = _local3.x;
brick._y = _local3.y;
brick.inner.gotoAndStop(frame);
brick._alpha = 50;
brick.startDrag(false);
_root.onMouseDown = function () {
if (brick.hitTest(Bricks)) {
brick.removeMovieClip();
} else {
var _local2 = _root.attachMovie("Brick", "Brick" + _root.depthcount, _root.depthcount);
_root.depthcount++;
_local2._x = brick._x;
_local2._y = brick._y;
_local2.inner.gotoAndStop(frame);
snapToGrid(_local2);
}
};
Clips.push(brick);
}
function attachNullBrick() {
trace("NULL BRICK!");
trace(frame);
var brick = _root.attachMovie("X", "X" + _root.depthcount, _root.depthcount);
_root.depthcount++;
brick._x = _root._xmouse - (brick._width / 2);
brick._y = _root._ymouse - (brick._height / 2);
brick._alpha = 50;
brick.startDrag(false);
_root.onMouseDown = function () {
if (brick.hitTest(Bricks)) {
brick.removeMovieClip();
} else {
var _local3 = snapToGrid(brick);
level[_local3.y / 20][_local3.x / 50] = -1;
var _local2 = 0;
while (_local2 < depthcount) {
if (_root["Brick" + _local2].hitTest(brick)) {
_root["Brick" + _local2].removeMovieClip();
brick.removeMovieClip();
break;
}
_local2++;
}
}
};
Clips.push(brick);
}
function pos(num) {
((num < 0) ? (num = -num) : null);
return(num);
}
function snapToGrid(clip) {
var _local5 = Math.floor(clip._y / 20) * 20;
var _local4 = Math.ceil(clip._y / 20) * 20;
if (pos(clip._y - _local5) > pos(clip._y - _local4)) {
yGrid = _local4;
} else {
yGrid = _local5;
}
var _local3 = Math.floor(clip._x / 50) * 50;
var _local6 = Math.ceil(clip._x / 50) * 50;
if (pos(clip._x - _local3) > pos(clip._x - _local6)) {
xGrid = _local6;
} else {
xGrid = _local3;
}
clip._x = xGrid;
clip._y = yGrid;
trace(((xGrid / 50) + ":") + (yGrid / 20));
if ((((((yGrid / 20) >= 15) || (clip.hitTest(_root.Bob))) || (((yGrid / 20) == 0) && ((xGrid / 50) == 0))) || ((yGrid / 20) < 0)) || ((xGrid / 50) < 0)) {
clip.removeMovieClip();
} else {
level[yGrid / 20][xGrid / 50] = clip.inner._currentframe;
}
return({x:xGrid, y:yGrid});
}
function readData() {
var _local1 = "";
i = 0;
while (i < level.length) {
_local1 = _local1 + (level[i].join(",") + "|");
i++;
}
trace(_local1);
delete i;
return(_local1);
}
function clearMap() {
var _local2 = 0;
while (_local2 < depthcount) {
_root["Brick" + _local2].removeMovieClip();
_local2++;
}
depthcount = 0;
level = [[-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, -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, -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, -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, -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, -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, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]];
_root.depthcount = 0;
}
function transmit(Name, LvName) {
var _local2 = new LoadVars();
level[0][0] = -1;
_local2.map = readData();
trace(_local2.map);
_local2.name = Name;
_local2.LvName = LvName;
var _local3 = new LoadVars();
_local3.onData = function (src) {
if (src == "Done") {
_root.Message = "Map submitted, thank you. You can try it out in the user levels section.";
_root.gotoAndStop(3);
}
};
_local2.sendAndLoad("http://www.earthnemesis.com/BrickLevels/score2.php", _local3, "POST");
Bricks.Sub.enabled = false;
clearMap();
}
function playLevel(levelData) {
trace("Starting level!");
trace(levelData.join("|"));
trace(levelData.length);
i = 0;
Buffer._visible = true;
onEnterFrame = function () {
if (i >= depthcount) {
Buffer._visible = false;
_root.gotoAndStop("ULPlay");
} else {
if (i >= depthcount) {
Buffer._visible = false;
_root.gotoAndStop("ULPlay");
}
var _local2 = _root.createEmptyMovieClip("bob" + i, i);
_local2.removeMovieClip();
i++;
}
};
_root.levels = levelData;
}
function renderMap() {
var _local3 = 0;
while (_local3 < level.length) {
trace("i");
trace(_local3);
trace(level.length);
if (_local3 == 15) {
break;
}
var _local2 = 0;
while (_local2 < 16) {
if (level[_local3][_local2] != -1) {
var _local4 = _root.attachMovie("Brick", "Brick" + depthcount, depthcount);
_local4._y = 20 + ((_local3 - 1) * 20);
_local4._x = _local2 * 50;
_local4.frame = level[_local3][_local2];
depthcount++;
}
_local2++;
}
_root.maxBricks = bricks;
_local3++;
}
}
function testIt() {
_root.levelData = level;
_root.preview = true;
playLevel(level);
}
Buffer._visible = true;
i = 0;
onEnterFrame = function () {
if (i >= depthcount) {
endIt();
} else {
if (i >= depthcount) {
endIt();
}
var _local2 = _root.createEmptyMovieClip("bob" + i, i);
_local2.removeMovieClip();
i++;
}
};
var i = 0;
while (i < _root.Balls.length) {
_root.Balls[i].remove();
i++;
}
delete _root.Balls;
depthcount = 0;
pupb.removeMovieClip();
Frame 34
function onPause() {
_root.P._visible = true;
MM = onMouseMove;
onMouseMove = null;
onEnterFrame = null;
}
function onUnPause() {
onMouseMove = MM;
delete MM;
_root.P._visible = false;
initLoop(true);
}
function initLoop(skip) {
if (skip != true) {
Balls.push(new Ball(400, 340, true, Balls.length));
}
onEnterFrame = function () {
var _local1 = 0;
while (_local1 < Balls.length) {
Balls[_local1].moveclip();
_local1++;
}
if (Multiplayer) {
if (Key.isDown(37)) {
Paddle2x--;
}
if (Key.isDown(39)) {
Paddle2x++;
}
if (Paddle2x > 0) {
Paddle2x = Paddle2x - 0.5;
} else if (Paddle2x < 0) {
Paddle2x = Paddle2x + 0.5;
}
Paddle2._x = Paddle2._x + Paddle2x;
if (Paddle2._x >= 800) {
Paddle2x = -Paddle2x;
}
if (Paddle2._x <= 0) {
Paddle2x = -Paddle2x;
}
}
};
}
function AddpowerUp(code) {
cancelPowerups(false);
switch (code) {
case 1 :
var _local2 = 0;
while (_local2 < Balls.length) {
Balls[_local2].clip.play();
_local2++;
}
PowerUps.gotoAndPlay(1);
PowerUps.frame = 4;
_root.powerUp = "Death";
break;
case 2 :
_local2 = 0;
while (_local2 < Balls.length) {
Balls[_local2].accl++;
_local2++;
}
PowerUps.gotoAndPlay(1);
PowerUps.frame = 8;
_root.powerUp = "Fast";
break;
case 4 :
var _local3 = Balls.length;
_local2 = 0;
while (_local2 < _local3) {
Balls[_local2].triple();
_local2++;
}
PowerUps.gotoAndPlay(1);
PowerUps.frame = 9;
_root.powerUp = "Triple";
break;
case 5 :
onMouseMove = function () {
Paddle._x = (-_xmouse) + Stage.width;
};
PowerUps.gotoAndPlay(1);
PowerUps.frame = 3;
_root.powerUp = "Reverse";
_root.attachMovie("PUPbar", "pupb", _root.depthcount);
_root.depthcount++;
break;
case 6 :
Balls[0].setRadio(true);
_root.attachMovie("PUPbar", "pupb", _root.depthcount);
_root.depthcount++;
_local2 = 0;
while (_local2 < _root.Balls.length) {
_root.Balls[_local2].inner.gotoAndStop(1);
_local2++;
}
PowerUps.gotoAndPlay(1);
PowerUps.frame = 1;
_root.powerUp = "Radioactive";
break;
case 7 :
_local2 = 0;
while (_local2 < _root.Balls.length) {
_root.Balls[_local2].accl = -_root.Balls[_local2].accl;
_local2++;
}
PowerUps.gotoAndPlay(1);
PowerUps.frame = 2;
_root.powerUp = "Helium";
_root.attachMovie("PUPbar", "pupb", _root.depthcount);
_root.depthcount++;
case 8 :
break;
case 9 :
_root.powerUp = "Grow";
PowerUps.gotoAndPlay(1);
PowerUps.frame = 6;
Paddle.E2._x = Paddle.E2._x - 5;
Paddle.E1._x = Paddle.E1._x + 5;
Paddle.Middle._width = Paddle.Middle._width + 10;
Paddle.Middle._x = Paddle.Middle._x - 5;
Paddle2.E2._x = Paddle2.E2._x - 5;
Paddle2.E1._x = Paddle2.E1._x + 5;
Paddle2.Middle._width = Paddle2.Middle._width + 10;
Paddle2.Middle._x = Paddle2.Middle._x - 5;
break;
case 10 :
_root.powerUp = "Shrink";
PowerUps.gotoAndPlay(1);
PowerUps.frame = 5;
Paddle.E2._x = Paddle.E2._x + 5;
Paddle.E1._x = Paddle.E1._x - 5;
Paddle.Middle._width = Paddle.Middle._width - 10;
Paddle.Middle._x = Paddle.Middle._x + 5;
Paddle2.E2._x = Paddle2.E2._x + 5;
Paddle2.E1._x = Paddle2.E1._x - 5;
Paddle2.Middle._width = Paddle2.Middle._width - 10;
Paddle2.Middle._x = Paddle2.Middle._x + 5;
}
}
function cancelPowerups(timed) {
if (timed) {
trace("Cancelling timed powerups.");
Balls[0].setRadio(false);
onMouseMove = function () {
Paddle._x = _xmouse;
};
pupb.removeMovieClip();
}
var _local2 = 0;
while (_local2 < _root.Balls.length) {
if (_root.Balls[_local2].accl < 0) {
_root.Balls[_local2].accl = -_root.Balls[_local2].accl;
}
_root.Balls[_local2].inner.gotoAndStop(1);
_local2++;
}
}
function moreBricks() {
if (preview != true) {
_root.gotoAndStop("UserLevels");
} else {
_root.level = _root.levelData;
_root.prevFrame();
}
}
onMouseMove = function () {
Paddle._x = _xmouse;
};
depthcount = 0;
bricks = 0;
lives = 5;
topBrick = 0;
bottomBrick = 372.6;
livesStr = String(lives);
var i = 0;
while (i < levels.length) {
if (i == 15) {
break;
}
var b = 0;
while (b < 16) {
if (levels[i][b] != -1) {
if (bottomBrick == 372.6) {
bottomBrick = depthcount;
}
var currentBrick = _root.attachMovie("Brick", "Brick" + depthcount, depthcount);
currentBrick._y = (preview ? (20 + ((i - 1) * 20)) : (20 + (i * 20)));
currentBrick._x = b * 50;
currentBrick.frame = levels[i][b];
depthcount++;
bricks++;
}
b++;
}
topBrick = depthcount;
_root.maxBricks = bricks;
i++;
}
P._visible = false;
Paused = false;
var listener = {};
listener.onKeyDown = function () {
if (Key.isDown(80)) {
if (!Paused) {
onPause();
Paused = true;
} else {
onUnPause();
Paused = false;
}
}
};
Key.addListener(listener);
_root._quality = "AUTOLOW";
gravity = 6;
gravSpeed = 0.25;
xmov = 0;
c = false;
rotspd = 0;
prevX = 0;
prevY = 0;
Paddle2x = 0;
Balls = [];
if (Multiplayer) {
Paddle2._x = 654;
Paddle2x = 0;
}
initLoop(false);
stop();
Instance of Symbol 252 MovieClip "Paddle" in Frame 34
onClipEvent (enterFrame) {
this._rotation = Math.round(_rotation);
if (this._rotation > 0) {
this._rotation--;
} else if (this._rotation < 0) {
this._rotation++;
}
}
Instance of Symbol 252 MovieClip "Paddle2" in Frame 34
onClipEvent (enterFrame) {
this._rotation = Math.round(_rotation);
if (this._rotation > 0) {
this._rotation--;
} else if (this._rotation < 0) {
this._rotation++;
}
}
Frame 35
_root.score = 650;
_root.lives = 2;
_root.woot = 0;
var ii = 0;
var iii = 0;
onEnterFrame = function () {
if (_root.winScreen._currentframe == 1) {
if (iii < 20) {
if (ii < 4) {
ii++;
} else {
iii++;
_root.exploX = random(800);
_root.exploY = random(600);
ii = 0;
var _local2 = 0;
while (_local2 < 40) {
_root.attachMovie("fireWork", "fw" + _local2, _root.getNextHighestDepth());
_local2++;
}
}
} else {
_root.winScreen.play();
}
}
};
function go(Name, score) {
trace("SCORE!");
trace(score);
Name = Name.slice(Name.toUpperCase().indexOf("KERNING=\"1\">") + 15, Name.toUpperCase().indexOf("</B>"));
trace(Name);
var _local3 = new LoadVars();
_local3.onData = function (src) {
trace(src);
trace("DONE!");
winScreen.show._visible = true;
};
var _local2 = new LoadVars();
_local2.name = Name;
_local2.score = score;
_local2.sendAndLoad("http://www.earthnemesis.com/HighScore/score.php", _local3, "POST");
}
_root.kongregateScores.submit(_root.score);
my_sound.stop();
Instance of Symbol 139 MovieClip [fireWorkWhite] in Frame 35
onClipEvent (load) {
unloadMovie (this);
}
Instance of Symbol 138 MovieClip [fireWork] in Frame 35
onClipEvent (load) {
unloadMovie (this);
}
Frame 36
var i = 0;
while (i < depthcount) {
_root["Brick" + i].removeMovieClip();
i++;
}
_root.kongregateStats.submit("EasyGameComplete", 1);
_root.kongregateScores.submit(_root.score);
var i = 0;
while (i < depthcount) {
_root["Brick" + i].removeMovieClip();
i++;
}
prevFrame();
Frame 37
function playLevel(levelData) {
trace("Starting level!");
trace(levelData.join("|"));
trace(levelData.length);
var _local2 = 0;
while (_local2 <= depthcount) {
_root["list_item" + _local2].removeMovieClip();
_local2++;
}
depthcount = 0;
_root.levels = levelData;
_root.gotoAndStop("ULPlay");
}
function renderPage(base) {
var _local5 = 0;
while (_local5 < depthcount) {
_root["list_item" + _local5].removeMovieClip();
depthcount--;
_local5++;
}
var _local2 = base;
while (_local2 < (base + 2)) {
if ((maps[_local2] == undefined) || (maps[_local2] == "undefined")) {
break;
}
var _local4 = maps[_local2].split("|");
var _local3 = _root.attachMovie("list_item", "list_item" + depthcount, depthcount);
_local3._x = 17;
_local3._y = 105 + (200 * (_local2 - base));
_local3.url = ("http://www.earthnemesis.com/BrickLevels/" + _local4[0]) + ".txt";
_local3.LvName = _local4[0];
_local3.Author = _local4[1];
depthcount++;
_local2++;
}
Indicator = (("Page " + ((base / 2) + 1)) + "/") + (maps.length / 2);
currentPage = base;
}
var i = 0;
while (i < depthcount) {
_root["Brick" + i].removeMovieClip();
i++;
}
for (var i in Balls) {
_root.Balls[i].remove();
}
delete Balls;
var manifestLoader = new LoadVars();
depthcount = 0;
indicator = "Page 1/Error";
manifestLoader.onData = function (src) {
trace(src);
maps = src.split("||");
trace(maps.join(","));
trace("---");
renderPage(0);
};
manifestLoader.load("http://www.earthnemesis.com/BrickLevels/maps.txt");
Symbol 9 MovieClip Frame 1
function doIt() {
var _local3 = 0;
while (_local3 < levels.length) {
trace("i");
if (_local3 == 15) {
break;
}
var _local1 = 0;
while (_local1 < levels[_local3].length) {
if (levels[_local3][_local1] != -1) {
var _local2 = Holder.attachMovie("Brick", "Brick" + depthcount, depthcount);
_local2._width = 12.4;
_local2._height = 5;
_local2._y = 5 + (_local3 * 5);
_local2._x = _local1 * 12.5;
_local2.frame = levels[_local3][_local1];
depthcount++;
bricks++;
}
_local1++;
}
_local3++;
}
}
depthcount = 0;
trace("LEVELS:");
trace(levels.join("|"));
Symbol 14 Button
on (release) {
_root.playLevel(level);
}
Symbol 15 MovieClip [list_item] Frame 1
var ulauthor = ("by " + Author);
trace(Author);
a.text = ulauthor;
trace(LvName);
nam.text = LvName;
trace("Retreiving from " + url);
var dataLoader = new LoadVars();
dataLoader.onData = function (src) {
var _local2 = src.split("|");
level = [];
var _local1 = 0;
while (_local1 < _local2.length) {
level.push(_local2[_local1].split(","));
_local1++;
}
trace(src);
Preview.levels = level;
Preview.doIt();
};
dataLoader.load(url);
Symbol 23 MovieClip Frame 451
_parent.play();
Symbol 26 MovieClip Frame 1
_root.pUpTimerCD--;
Symbol 28 MovieClip [PUPbar] Frame 1
_root.pUpTimerCD = 11;
Symbol 28 MovieClip [PUPbar] Frame 24
stop();
Symbol 28 MovieClip [PUPbar] Frame 41
_root.cancelPowerups(true);
this.removeMovieClip();
Symbol 37 MovieClip Frame 1
stop();
if (don != true) {
_parent.frame = _parent.frame;
gotoAndStop(_parent.frame);
}
don = true;
trace("Frame 1!");
Symbol 40 MovieClip [Brick22] Frame 1
stop();
Instance of Symbol 37 MovieClip "inner" in Symbol 40 MovieClip [Brick22] Frame 1
onClipEvent (load) {
points = 1;
}
onClipEvent (enterFrame) {
if (hitTest(_root.Ball)) {
trace("Hit.");
trace(_parent.inner._currentframe);
if (_parent.inner._currentframe == 1) {
trace("Smash.");
if (done) {
} else {
_root.Ball.gravity = -_root.Ball.gravity;
_root.Ball._y = _root.Ball._y + _root.Ball.gravity;
_root.Ball._x = _root.Ball._x - _root.Ball.xmov;
_root.score = _root.score + (100 * points);
_root.scoreStr = String(_root.score);
trace(_root.score);
_root.bricks--;
if (_root.bricks == 0) {
_root.moreBricks();
}
_parent.play();
done = true;
}
} else if (_parent.inner._currentframe == 8) {
_root.Ball.gravity = -_root.Ball.gravity;
_root.Ball._y = _root.Ball._y + _root.Ball.gravity;
_root.Ball._x = _root.Ball._x - _root.Ball.xmov;
} else {
_parent.inner.prevFrame();
_root.Ball.gravity = -_root.Ball.gravity;
_root.Ball._y = _root.Ball._y + _root.Ball.gravity;
_root.Ball._x = _root.Ball._x - _root.Ball.xmov;
points++;
}
}
}
Symbol 95 MovieClip Frame 1
stop();
if (don != true) {
_parent.frame = _parent.frame;
gotoAndStop(_parent.frame);
}
don = true;
trace("Frame 1!");
Symbol 95 MovieClip Frame 8
_root.bricks--;
Symbol 95 MovieClip Frame 9
trace("BAH!");
Symbol 95 MovieClip Frame 10
_root.bricks--;
Symbol 95 MovieClip Frame 12
_root.bricks--;
Symbol 95 MovieClip Frame 13
_root.bricks--;
Symbol 95 MovieClip Frame 17
_root.bricks--;
Symbol 95 MovieClip Frame 26
_root.bricks--;
Symbol 124 MovieClip [Brick] Frame 1
stop();
Symbol 124 MovieClip [Brick] Frame 2
function posOrNegRand(num) {
var _local1 = ((Math.random() > 0.2) ? (Math.random() * num) : (Math.random() * (-num)));
return(_local1);
}
trace("Stuff:");
trace(BallX);
trace(BallY);
a.xmov = posOrNegRand(2) + this.BallX;
a.ymov = posOrNegRand(2) - this.BallY;
b.xmov = posOrNegRand(2) + this.BallX;
b.ymov = posOrNegRand(2) - this.BallY;
c.xmov = posOrNegRand(2) + this.BallX;
c.ymov = posOrNegRand(2) - this.BallY;
d.xmov = posOrNegRand(2) + this.BallX;
d.ymov = posOrNegRand(2) - this.BallY;
e.xmov = posOrNegRand(2) + this.BallX;
e.ymov = posOrNegRand(2) - this.BallY;
f.xmov = posOrNegRand(2) + this.BallX;
f.ymov = posOrNegRand(2) - this.BallY;
g.xmov = posOrNegRand(2) + this.BallX;
g.ymov = posOrNegRand(2) - this.BallY;
h.xmov = posOrNegRand(2) + this.BallX;
h.ymov = posOrNegRand(2) - this.BallY;
i.xmov = posOrNegRand(2) + this.BallX;
i.ymov = posOrNegRand(2) - this.BallY;
j.xmov = posOrNegRand(2) + this.BallX;
k.xmov = posOrNegRand(2) + this.BallX;
k.ymov = posOrNegRand(2) - this.BallY;
l.xmov = posOrNegRand(2) + this.BallX;
l.ymov = posOrNegRand(2) - this.BallY;
m.xmov = posOrNegRand(2) + this.BallX;
m.ymov = posOrNegRand(2) - this.BallY;
n.xmov = posOrNegRand(2) + this.BallX;
n.ymov = posOrNegRand(2) - this.BallY;
a.onEnterFrame = (b.onEnterFrame = (c.onEnterFrame = (d.onEnterFrame = (e.onEnterFrame = (f.onEnterFrame = (g.onEnterFrame = (h.onEnterFrame = (i.onEnterFrame = (j.onEnterFrame = (k.onEnterFrame = (l.onEnterFrame = (m.onEnterFrame = (n.onEnterFrame = function () {
this._alpha--;
if (this._alpha <= 0) {
this._parent.removeMovieClip();
}
this._x = this._x + this.xmov;
this._y = this._y + this.ymov;
this.ymov = this.ymov + 0.3;
this._rotation++;
})))))))))))));
stop();
Symbol 127 MovieClip Frame 1
stop();
Symbol 128 MovieClip [Ball] Frame 1
stop();
Symbol 128 MovieClip [Ball] Frame 10
stop();
_root.Balls[this.index].onDrop();
trace("Dropping index " + this.index);
gotoAndStop (1);
Symbol 135 MovieClip [mapUnit] Frame 1
trace("Retreiving from " + url);
var dataLoader = new LoadVars();
dataLoader.onData = function (src) {
var _local2 = src.split("|");
level = [];
var _local1 = 0;
while (_local1 < _local2.length) {
level.push(_local2[_local1].split(","));
_local1++;
}
trace(level.join(","));
var _local3 = new Object();
_local3.onLoadComplete = function (target_mc, httpStatus) {
trace(">> loadListener.onLoadComplete()");
trace(">> =============================");
trace(">> target_mc._width: " + target_mc._width);
trace(">> httpStatus: " + httpStatus);
trace(src);
target_mc.levels = level;
};
_local3.onLoadInit = function (target_mc) {
trace(">> loadListener.onLoadInit()");
trace(">> =============================");
trace(">> target_mc._width: " + target_mc._width);
};
var _local4 = new MovieClipLoader();
_local4.addListener(_local3);
_local4.loadClip("LevelPreview2.swf", Preview);
};
dataLoader.load(url);
Symbol 138 MovieClip [fireWork] Frame 1
gotoAndStop(random(2) + 1);
var xvar = ((Math.random() * 6) - (Math.random() * 6));
var yvar = ((-Math.random()) * 7);
var resizeVar = random(25);
var counter = 0;
_x = _root.exploX;
_y = _root.exploY;
var count = 0;
onEnterFrame = function () {
count++;
_root.woot++;
_x = (_x + xvar);
_y = (_y + yvar);
yvar = yvar + 0.2;
_height = resizeVar;
_width = resizeVar;
if (xvar < 0) {
_rotation = (_rotation + xvar);
} else {
_rotation = (_rotation - xvar);
}
if (_y > 600) {
yvar = (-Math.random()) * 8;
}
if (count > 100) {
_alpha = (_alpha - 15);
if (_alpha < 0) {
this.removeMovieClip();
}
}
};
Symbol 139 MovieClip [fireWorkWhite] Frame 1
gotoAndStop(random(2) + 1);
var xvar = ((Math.random() * 6) - (Math.random() * 6));
var yvar = ((-Math.random()) * 7);
var resizeVar = random(35);
var count = 0;
_x = random(800);
_y = (120 - (random(60) - random(60)));
onEnterFrame = function () {
count++;
_x = (_x + xvar);
_y = (_y + yvar);
yvar = yvar + 0.7;
_height = resizeVar;
_width = resizeVar;
if (_y > 650) {
unloadMovie (this);
}
if (xvar < 0) {
_rotation = (_rotation + xvar);
} else {
_rotation = (_rotation - xvar);
}
if (_y > 600) {
yvar = ((-Math.random()) * 40) + (count / 15);
}
if (count > 380) {
_alpha = (_alpha - 5);
if (_alpha < 0) {
this.removeMovieClip();
}
}
};
Symbol 410 MovieClip [__Packages.MochiAd] Frame 0
class MochiAd
{
function MochiAd () {
}
static function getVersion() {
return("2.1");
}
static function showPreGameAd(options) {
var _local27 = {clip:_root, ad_timeout:3000, fadeout_time:250, regpt:"o", method:"showPreloaderAd", color:16747008, background:16777161, outline:13994812, ad_started:function () {
this.clip.stop();
}, ad_finished:function () {
this.clip.play();
}};
options = _parseOptions(options, _local27);
var clip = options.clip;
var _local23 = 11000;
var _local26 = options.ad_timeout;
delete options.ad_timeout;
var fadeout_time = options.fadeout_time;
delete options.fadeout_time;
if (!load(options)) {
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 _local7 = chk.createEmptyMovieClip("_mochiad_bar", 4);
_local7._x = 10;
_local7._y = _local13 - 20;
var _local22 = options.color;
delete options.color;
var _local19 = options.background;
delete options.background;
var _local24 = options.outline;
delete options.outline;
var _local5 = _local7.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 = _local7.createEmptyMovieClip("_inside", 2);
_local3.beginFill(_local22);
_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 _local6 = _local7.createEmptyMovieClip("_outline", 3);
_local6.lineStyle(0, _local24, 100);
_local6.moveTo(0, 0);
_local6.lineTo(_local4 - 20, 0);
_local6.lineTo(_local4 - 20, 10);
_local6.lineTo(0, 10);
_local6.lineTo(0, 0);
chk.ad_msec = _local23;
chk.ad_timeout = _local26;
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.adLoaded = function (width, height) {
};
mc.lc.adjustProgress = function (msec) {
var _local2 = this.mc._mochiad_wait;
_local2.server_control = true;
_local2.started = getTimer();
_local2.ad_msec = msec;
};
chk.onEnterFrame = function () {
var _local6 = this._parent._parent;
var _local12 = this._parent._mochiad_ctr;
var _local5 = getTimer() - this.started;
var _local3 = false;
var _local4 = _local6.getBytesTotal();
var _local8 = _local6.getBytesLoaded();
var _local10 = (100 * _local8) / _local4;
var _local11 = (100 * _local5) / chk.ad_msec;
var _local9 = this._mochiad_bar._inside;
var _local2 = Math.min(100, Math.min(_local10 || 0, _local11));
_local2 = Math.max(this.last_pcnt, _local2);
this.last_pcnt = _local2;
_local9._xscale = _local2;
if (!chk.showing) {
var _local7 = _local12.getBytesTotal();
if ((_local7 > 0) || (typeof(_local7) == "undefined")) {
chk.showing = true;
chk.started = getTimer();
} else if (_local5 > chk.ad_timeout) {
_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 showInterLevelAd(options) {
trace("Displaying Ad!");
trace("--------------");
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();
}};
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_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 = function (width, height) {
};
mc.lc.adjustProgress = function (msec) {
var _local2 = this.mc._mochiad_wait;
_local2.server_control = true;
_local2.started = getTimer();
_local2.ad_msec = msec - 250;
};
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) {
_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 showTimedAd(options) {
showInterLevelAd(options);
}
static function showPreloaderAd(options) {
showPreGameAd(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 _loadCommunicator(options) {
var _local26 = {clip:_root, com_server:"http://x.mochiads.com/com/1/", method:"loadCommunicator", depth:10337, id:"_UNKNOWN_"};
options = _parseOptions(options, _local26);
options.swfv = options.clip.getSWFVersion() || 6;
options.mav = getVersion();
var _local18 = options.clip;
var _local20 = "_mochiad_com_" + options.id;
if (!_isNetworkAvailable()) {
return(null);
}
if (_local18[_local20]) {
return(_local18[_local20].lc);
}
var _local21 = options.com_server + options.id;
_allowDomains(_local21);
delete options.id;
delete options.com_server;
var _local25 = options.depth;
delete options.depth;
var _local17 = _local18.createEmptyMovieClip(_local20, _local25);
var _local11 = _local17.createEmptyMovieClip("_mochiad_com", 1);
for (var _local15 in options) {
_local11[_local15] = options[_local15];
}
var _local6 = new LocalConnection();
var _local16 = ["", Math.floor(new Date().getTime()), random(999999)].join("_");
_local6.mc = _local17;
_local6.name = _local16;
_local6.allowDomain = function (d) {
return(true);
};
_local6.allowInsecureDomain = _local6.allowDomain;
_local6.connect(_local16);
_local17.lc = _local6;
_local11.lc = _local16;
_local6._id = 0;
_local6._queue = [];
_local6.rpcResult = function (cb_arg) {
var _local8 = parseInt(cb_arg);
var _local4 = this._callbacks[_local8];
if (!_local4) {
return(undefined);
}
delete this._callbacks[_local8];
var _local5 = [];
var _local3 = 2;
while (_local3 < _local4.length) {
_local5.push(_local4[_local3]);
_local3++;
}
_local3 = 1;
while (_local3 < arguments.length) {
_local5.push(arguments[_local3]);
_local3++;
}
var _local6 = _local4[1];
var _local7 = _local4[0];
if (_local7 && (typeof(_local6) == "string")) {
_local6 = _local7[_local6];
}
if (_local6) {
_local6.apply(_local7, _local5);
}
};
_local6._didConnect = function (endpoint) {
this._endpoint = endpoint;
var _local4 = this._queue;
delete this._queue;
var _local5 = this.doSend;
var _local2 = 0;
while (_local2 < _local4.length) {
var _local3 = _local4[_local2];
_local5.apply(this, _local3);
_local2++;
}
};
_local6.doSend = function (args, cbobj, cbfn) {
if (this._endpoint == null) {
var _local4 = [];
var _local3 = 0;
while (_local3 < arguments.length) {
_local4.push(arguments[_local3]);
_local3++;
}
this._queue.push(_local4);
return(undefined);
}
this._id = this._id + 1;
var _local5 = this._id;
if ((cbfn === undefined) || (cbfn === null)) {
cbfn = cbobj;
}
this._callbacks[_local5] = [cbobj, cbfn];
var _local7 = new LocalConnection();
var _local9 = _local7.send(this._endpoint, "rpc", _local5, args);
};
_local6._callbacks = {};
_local6._callbacks[0] = [_local6, "_didConnect"];
_local11.st = getTimer();
_local11.loadMovie(_local21 + ".swf", "POST");
return(_local6);
}
static function fetchHighScores(options, callbackObj, callbackMethod) {
var _local1 = _loadCommunicator({id:options.id});
if (!_local1) {
return(false);
}
var _local4 = ["fetchHighScores", options];
_local1.doSend(["fetchHighScores", options], callbackObj, callbackMethod);
return(true);
}
static function sendHighScore(options, callbackObj, callbackMethod) {
var _local1 = _loadCommunicator({id:options.id});
if (!_local1) {
return(false);
}
var _local4 = ["sendHighScore", options];
_local1.doSend(["sendHighScore", options], callbackObj, callbackMethod);
return(true);
}
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);
}
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++;
}
}
return(_local4);
}
}
Symbol 411 MovieClip [__Packages.Ball] Frame 0
class Ball
{
var index, primaryBall, clip, accl, rotspd, ymov, xmov, prevY, prevX;
function Ball (x, y, primary, ind) {
index = ind;
primaryBall = primary;
clip = _root.attachMovie("Ball", "Ball" + _root.depthcount, _root.depthcount, {_x:x, _y:y});
clip.index = ind;
_root.depthcount++;
accl = 0.25;
rotspd = 0;
ymov = 0;
xmov = 0;
}
function remove() {
clip.removeMovieClip();
}
function moveclip() {
if (paused) {
_root.onMouseDown = function () {
Ball.paused = false;
};
return(undefined);
}
clip._x = clip._x + xmov;
clip._y = clip._y + ymov;
clip._rotation = clip._rotation + rotspd;
ymov = ymov + (accl / 2);
if (clip.hitTest(_root.Paddle)) {
accl = accl + 1E-5;
ymov = ymov + 0.5;
ymov = -ymov;
while (clip.hitTest(_root.Paddle)) {
clip._y--;
}
var _local7 = clip._x - _root.Paddle._x;
var _local8 = _local7 / ((_root.Paddle._width / 2) / 100);
_local7 = _local8;
_root.Paddle._rotation = _root.Paddle._rotation + (_local7 / 10);
xmov = xmov + (_local7 / 10);
rotspd = rotspd + (_local7 / 10);
} else if (clip.hitTest(_root.Paddle2)) {
accl = accl + 1E-5;
ymov = ymov + 0.5;
ymov = -ymov;
while (clip.hitTest(_root.Paddle2)) {
clip._y--;
}
var _local7 = clip._x - _root.Paddle2._x;
var _local8 = _local7 / ((_root.Paddle2._width / 2) / 100);
_local7 = _local8;
_root.Paddle2._rotation = _root.Paddle2._rotation + (_local7 / 10);
xmov = xmov + (_local7 / 10);
rotspd = rotspd + (_local7 / 10);
}
if (clip._x < 0) {
xmov = -xmov;
}
if (clip._x > 800) {
xmov = -xmov;
}
if (clip._y < 0) {
ymov = -ymov;
while (clip._y < 0) {
clip._y++;
}
}
if (clip._y > 600) {
onDrop();
}
var _local3 = _root.bottomBrick;
while (_local3 <= _root.topBrick) {
if (clip.hitTest(_root["Brick" + _local3]) && (_root["Brick" + _local3]._currentframe == 1)) {
if ((_root["Brick" + _local3].inner._currentframe == 8) || (_root["Brick" + _local3].inner._currentframe == 26)) {
if (!radioactive) {
var _local5 = clip._x;
var _local6 = clip._y;
clip._y = prevY;
if (!clip.hitTest(_root["Brick" + _local3])) {
ymov = -ymov;
} else {
clip._x = prevX;
if (!clip.hitTest(_root["Brick" + _local3])) {
xmov = -xmov;
}
}
} else {
_root["Brick" + _local3].nextFrame();
}
} else if ((_root["Brick" + _local3].inner._currentframe >= 10) && (_root["Brick" + _local3].inner._currentframe < 20)) {
switch (_root["Brick" + _local3].inner._currentframe) {
case 10 :
_root.AddpowerUp(2);
break;
case 11 :
_root.AddpowerUp(3);
break;
case 12 :
_root.AddpowerUp(1);
break;
case 13 :
_root.AddpowerUp(5);
break;
case 14 :
_root.AddpowerUp(7);
break;
case 15 :
_root.AddpowerUp(6);
break;
case 16 :
_root.AddpowerUp(8);
break;
case 17 :
_root.AddpowerUp(10);
break;
case 18 :
_root.AddpowerUp(9);
break;
case 19 :
_root.AddpowerUp(4);
}
_root["Brick" + _local3].BallX = xmov / 2;
_root["Brick" + _local3].BallY = ymov / 2;
_root["Brick" + _local3].nextFrame();
var _local5 = clip._x;
var _local6 = clip._y;
clip._y = prevY;
if (!clip.hitTest(_root["Brick" + _local3])) {
ymov = -ymov;
} else {
clip._x = prevX;
if (!clip.hitTest(_root["Brick" + _local3])) {
xmov = -xmov;
}
}
_root.bricks--;
if (_root.bricks <= 0) {
var _local4 = 0;
while (_local4 <= _root.maxBricks) {
_root["Brick" + _local4].removeMovieClip();
_local4++;
}
_root.moreBricks();
}
} else if (_root["Brick" + _local3].inner._currentframe != 9) {
if (clip.hitTest(_root["Brick" + _local3])) {
if (!radioactive) {
var _local5 = clip._x;
var _local6 = clip._y;
clip._y = prevY;
if (!clip.hitTest(_root["Brick" + _local3])) {
ymov = -ymov;
} else {
clip._x = prevX;
if (!clip.hitTest(_root["Brick" + _local3])) {
xmov = -xmov;
}
}
_root["Brick" + _local3].score = _root["Brick" + _local3].score + 100;
} else if (_root["Brick" + _local3].inner._currentframe < 10) {
_root["Brick" + _local3].score = _root["Brick" + _local3].score + (100 * _root["Brick" + _local3].inner._currentframe);
_root["Brick" + _local3].BallX = xmov / 2;
_root["Brick" + _local3].BallY = ymov / 2;
trace("More Stuff:");
trace(xmov / 2);
_root["Brick" + _local3].nextFrame();
_root.score = _root.score + _root["Brick" + _local3].score;
_root.scoreStr = _root.score;
_root.bricks--;
if (_root.bricks == 0) {
var _local4 = 0;
while (_local4 <= _root.maxBricks) {
_root["Brick" + _local4].removeMovieClip();
_local4++;
}
_root.moreBricks();
}
}
}
if (((_root["Brick" + _local3].inner._currentframe == 1) || (_root["Brick" + _local3].inner._currentframe == 9)) || (_root["Brick" + _local3].inner._currentframe == 20)) {
_root["Brick" + _local3].BallX = xmov / 2;
_root["Brick" + _local3].BallY = ymov / 2;
trace("More Stuff:");
trace(xmov / 2);
_root["Brick" + _local3].nextFrame();
_root.score = _root.score + _root["Brick" + _local3].score;
_root.scoreStr = _root.score;
_root.bricks--;
if (_root.bricks == 0) {
var _local4 = 0;
while (_local4 <= _root.maxBricks) {
_root["Brick" + _local4].removeMovieClip();
_local4++;
}
_root.moreBricks();
}
} else {
_root["Brick" + _local3].inner.prevFrame();
}
}
}
_local3++;
}
prevX = clip._x;
prevY = clip._y;
}
function triple() {
var _local3 = new Ball(clip._x, clip._y, false);
_local3.xmov = xmov + (Math.random() * 5);
_local3.ymov = ymov;
_local3.rotspd = rotspd;
var _local4 = new Ball(clip._x, clip._y, false);
_local4.xmov = xmov - (Math.random() * 5);
_local4.ymov = ymov;
_local4.rotspd = rotspd;
_root.Balls.push(_local3);
_root.Balls.push(_local4);
}
function onDrop(skip) {
if (primaryBall) {
if (_root.Balls.length > 1) {
if (this != _root.Balls[0]) {
_root.Balls[0].primaryBall = true;
} else {
_root.Balls[1].primaryBall = true;
}
remove();
var _local5 = [];
var _local3 = 0;
while (_local3 < _root.Balls.length) {
if (_root.Balls[_local3] != this) {
_local5.push(_root.Balls[_local3]);
}
_local3++;
}
_root.Balls = _local5;
} else {
if (skip != true) {
_root.lives--;
_root.livesStr = String(_root.lives);
_root.cancelPowerups(true);
}
paused = true;
if ((_root.lives == 0) && (_root._currentframe != 34)) {
remove();
var _local4 = 0;
while (_local4 < _root.depthcount) {
_root["Brick" + _local4].removeMovieClip();
_local4++;
}
_root.onEnterFrame = null;
_root.gotoAndStop("Lose");
} else if ((_root.lives == 0) && (_root._currentframe == 34)) {
_root.moreBricks();
} else {
clip._x = 400;
clip._y = 340;
accl = 0.25;
rotspd = 0;
ymov = 4;
xmov = 0;
}
}
} else {
remove();
var _local5 = [];
var _local3 = 0;
while (_local3 < _root.Balls.length) {
if (_root.Balls[_local3] != this) {
_local5.push(_root.Balls[_local3]);
}
_local3++;
}
_root.Balls = _local5;
}
}
function setRadio(t) {
radioactive = t;
}
static var paused = true;
static var radioactive = false;
}
Symbol 412 MovieClip [__Packages.toolTip] Frame 0
class toolTip
{
var Text, clip;
function toolTip (text, attachedTo) {
trace("New Tooltip!");
Text = text;
}
function showToolTip() {
clip = _root.createEmptyMovieClip("ToolTip" + _root.depthcount, _root.depthcount);
clip.createTextField("TextBox", 0, 0, 0, 190, 10);
clip.TextBox.autoSize = "left";
clip.TextBox.wordWrap = true;
clip.TextBox.selectable = false;
clip.TextBox.html = true;
if (Text.charAt(0) != "<") {
Text = ("<font face='Digital' color='#FFFFFF'>" + Text) + "</font>";
}
clip.TextBox.htmlText = Text;
clip.beginFill(10066329, 80);
clip.lineStyle(1, 0, 100);
clip.moveTo(0, 0);
clip.lineTo(clip.TextBox._width, 0);
clip.lineTo(clip.TextBox._width, clip.TextBox._height);
clip.lineTo(0, clip.TextBox._height);
clip.lineTo(0, 0);
clip.endFill();
clip._alpha = 0;
clip.speed = 0;
clip.Text = Text;
clip.TextBox.htmlText = "";
clip.onEnterFrame = function () {
if (this._alpha < 100) {
this._alpha = this._alpha + this.speed;
}
this.speed++;
this._x = _root._xmouse;
this._y = _root._ymouse;
this.TextBox.htmlText = this.Text.slice(0, this.speed * 2);
};
}
function hideToolTip() {
clip.current = clip.TextBox.htmlText;
trace(clip.current.length / 15);
clip.speed = 0;
clip.textRemoval = clip.current.length / 15;
clip.spd = clip.textRemoval;
clip.onEnterFrame = function () {
if (this._alpha > 0) {
this._alpha = this._alpha - this.speed;
}
this.speed++;
this.spd = this.spd + this.textRemoval;
this.TextBox.htmlText = this.current.slice(0, this.current.length - this.spd);
if (this.TextBox.htmlText == "") {
this.TextBox.removeTextField();
}
};
}
}
Symbol 166 MovieClip Frame 10
stop();
Symbol 170 MovieClip Frame 10
stop();
Symbol 174 MovieClip Frame 10
stop();
Symbol 177 Button
on (press) {
_parent.play();
_root.goTo = 5;
}
Symbol 180 MovieClip Frame 10
stop();
Symbol 183 Button
on (press) {
_parent.play();
_root.goTo = "Instructions";
}
Symbol 185 Button
on (press) {
_parent.play();
_root.goTo = "Editor";
}
Symbol 186 Button
on (press) {
_parent.play();
_root.goTo = "UserLevels";
}
Symbol 187 MovieClip Frame 69
stop();
Symbol 188 MovieClip Frame 118
stop();
Symbol 188 MovieClip Frame 151
_root.gotoAndStop(_root.goTo);
Symbol 191 MovieClip Frame 20
stop();
Symbol 191 MovieClip Frame 40
_root.prevFrame();
Symbol 199 MovieClip Frame 10
stop();
Symbol 203 MovieClip Frame 10
stop();
Symbol 214 Button
on (press) {
play();
_root.goTo = "WHERE TO GO";
}
Symbol 215 Button
on (press) {
play();
_root.goTo = "WHERE TO GO";
}
Symbol 218 Button
on (press) {
play();
_root.Multiplayer = false;
_root.goTo = "Play";
}
Symbol 219 Button
on (press) {
play();
_root.Multiplayer = false;
_root.goTo = "Play";
}
Symbol 220 Button
on (press) {
_root.Multiplayer = true;
_root.goTo = "Play";
play();
}
Symbol 221 Button
on (press) {
_root.Multiplayer = false;
_root.goTo = "Play";
play();
}
Symbol 222 Button
on (press) {
_parent.play();
_root.goTo = "WHERE TO GO";
}
Symbol 223 MovieClip Frame 43
stop();
Symbol 223 MovieClip Frame 55
_root.gotoAndStop("Play");
Symbol 244 MovieClip Frame 1
stop();
Symbol 252 MovieClip Frame 1
stop();
Symbol 273 MovieClip Frame 1
stop();
gotoAndStop(_parent.frame);
Symbol 276 MovieClip Frame 1
stop();
Symbol 276 MovieClip Frame 2
var my_fmt = new TextFormat();
my_fmt.font = "Font";
txt.embedFonts = true;
txt.text = _root.powerUp;
txt.setTextFormat(my_fmt);
trace("moo");
Symbol 276 MovieClip Frame 11
bob.gotoAndStop(frame);
Symbol 276 MovieClip Frame 14
var my_fmt = new TextFormat();
my_fmt.font = "Font";
txt.embedFonts = true;
txt.text = _root.powerUp;
txt.setTextFormat(my_fmt);
trace("moo");
Symbol 303 MovieClip Frame 1
var my_fmt1 = new TextFormat();
my_fmt1.font = "Font";
Box1.wordWrap = true;
Box1.embedFonts = true;
Box1.text = _root.scoreStr;
Box1.setTextFormat(my_fmt1);
var my_fmt1 = new TextFormat();
my_fmt1.font = "Font";
In.wordWrap = true;
In.embedFonts = true;
In.text = _root.scoreStr;
In.setTextFormat(my_fmt1);
Symbol 305 Button
on (release) {
_root.getURL("http://www.earthnemesis.com/HighScore/showScore.php", "_blank");
}
Symbol 307 Button
on (release) {
_root.go(a.Name, a.Box1.text);
trace("---------------------");
trace(Name);
btn._visible = false;
}
Symbol 308 Button
on (release) {
_root.my_sound.start();
_root.gotoAndStop(3);
}
Symbol 309 MovieClip Frame 1
_root.my_sound.stop();
Symbol 309 MovieClip Frame 164
show._visible = false;
Symbol 309 MovieClip Frame 165
stop();
Symbol 314 Button
on (release) {
play();
}
Symbol 316 Button
on (release) {
_root.clearMap();
_root.gotoAndStop(3);
}
Symbol 318 Button
on (release) {
_root.testIt();
}
Symbol 324 Button
on (release) {
var i = 0;
while (i < _root.level.length) {
var t = 0;
while (t < _root.level[i].length) {
if (((_root.level[i][t] != -1) && (_root.level[i][t] != 8)) && (_root.level[i][t] != 26)) {
j = true;
break;
}
t++;
}
if (j) {
break;
}
i++;
}
if (j != true) {
Name = "Level needs bricks";
} else {
g = (t = false);
var i = 0;
while (i < length(Name)) {
if ((Name.charAt(i) != " ") || (Name.charAt(i) != ".")) {
g = true;
break;
}
i++;
}
var i = 0;
while (i < length(LvName)) {
if ((LvName.charAt(i) != " ") || (LvName.charAt(i) != ".")) {
t = true;
break;
}
i++;
}
if (g && (t)) {
if ((((((Name != "") && (LvName != "")) && (Name != "undefined")) && (LvName != "undefined")) && (Name != "Enter Name")) && (LvName != "Enter Name")) {
_root.transmit(Name, LvName);
_parent.play();
} else {
if (((Name == "") || (Name == "undefined")) || (Name == "Enter Name")) {
Name = "Enter Name.";
}
if (((LvName == "") || (LvName == "undefined")) || (LvName == "Enter Name")) {
LvName = "Enter Name.";
}
}
} else {
Name = (LvName = "Enter Name");
}
}
}
Symbol 325 Button
on (release) {
_parent.play();
}
Symbol 326 MovieClip Frame 1
Name = "";
LvName = "";
Symbol 328 MovieClip Frame 1
Messages = ["", "Brick #1: One hit kill normal brick.", "Brick #2: Two hit kill normal brick.", "Brick #3: Three hit kill normal brick.", "Brick #4: Four hit kill normal brick.", "Brick #5: Five hit kill normal brick.", "Brick #6: Six hit kill normal brick.", "Brick #7: Seven hit kill normal brick.", "Indestructable brick.", "Slow down ball powerup", "Death powerup (kills you).", "Invert controls", "Helium: Inverts gravity.", "Radioactive: Makes the ball tear straight through all bricks, including indestructable ones.", "Shrink Paddle.", "Grow Paddle.", "Triple ball: Each ball becomes three balls.", "Brick #1: One hit kill normal brick.", "Brick #2: Two hit kill normal brick.", "Brick #3: Three hit kill normal brick.", "Brick #4: Four hit kill normal brick.", "Brick #5: Five hit kill normal brick.", "Brick #6: Six hit kill normal brick.", "Brick #7: Seven hit kill normal brick.", "Indestructable brick."];
var i = 1;
while (i < 27) {
new toolTip(Messages[i], this[i]);
this[i].gotoAndStop(i);
this[i].onPress = function () {
_root.attachBrick(this._currentframe, {x:this._x, y:this._y});
};
i++;
}
nullBrick.onPress = function () {
_root.attachNullBrick();
};
Name = "";
stop();
Symbol 328 MovieClip Frame 25
stop();
Symbol 349 MovieClip Frame 1
N.onKillFocus = function () {
N.text = "Max. 15 Chars";
};
N.onSetFocus = function () {
N.text = "";
};
Symbol 354 Button
on (release) {
_root.go(Name, Box1.text);
trace("---------------------");
trace(Name);
btn._visible = false;
}
Symbol 356 MovieClip Frame 1
stop();
var i = 0;
while (i < _root.Balls.length) {
_root.Balls[i].remove();
i++;
}
delete _root.Balls;
Symbol 356 MovieClip Frame 46
var i = 0;
while (i < 120) {
_root.attachMovie("fireWorkWhite", "fww" + i, _root.getNextHighestDepth());
i++;
}
Symbol 356 MovieClip Frame 255
stop();
_root.Name = "";
var my_fmt = new TextFormat();
my_fmt.font = "Font";
Box2.wordWrap = true;
Box2.embedFonts = true;
Box2.text = _root.livesStr;
Box2.setTextFormat(my_fmt);
var my_fmt1 = new TextFormat();
my_fmt1.font = "Font";
Box1.wordWrap = true;
Box1.embedFonts = true;
Box1.text = _root.scoreStr;
Box1.setTextFormat(my_fmt1);
show._visible = false;
Symbol 362 Button
on (release) {
gotoAndStop (3);
}
Symbol 363 Button
on (release) {
go();
_root.btn._visible = false;
}
Symbol 372 MovieClip Frame 10
stop();
Symbol 377 Button
on (release) {
if ((_root.currentPage - 1) > 0) {
_root.renderPage(_root.currentPage - 2);
}
}
Symbol 378 Button
on (release) {
if ((_root.currentPage + 2) < _root.maps.length) {
_root.renderPage(_root.currentPage + 2);
}
}
Symbol 379 Button
on (release) {
_root.gotoAndStop(3);
}
Symbol 381 MovieClip Frame 17
stop();
trace(_root.indicator);
Symbol 401 MovieClip Frame 10
stop();
Symbol 403 Button
on (release) {
_parent.play();
play();
}
Symbol 404 MovieClip Frame 96
stop();
Symbol 404 MovieClip Frame 157
stop();
Symbol 405 MovieClip Frame 19
stop();
Symbol 405 MovieClip Frame 98
_root.gotoAndStop(3);