Frame 3
stop();
Frame 4
shotstarted = false;
score = 0;
radius = 24;
timer = 100;
level = 1;
ballstop = 0.5;
ball = 1;
while (ball <= balls) {
thisball = eval ("ball" + ball);
ball++;
}
Instance of Symbol 84 MovieClip "ball1" in Frame 4
onClipEvent (mouseDown) {
if (!_level0.shotstarted) {
powstart = getTimer();
moused = true;
}
}
onClipEvent (mouseUp) {
if ((!_level0.shotstarted) and moused) {
moused = false;
powstop = getTimer();
_level0.pwr = powstop - powstart;
_level0.cuex = _xmouse;
_level0.cuey = _ymouse;
_level0.shotstarted = true;
}
}
onClipEvent (enterFrame) {
cuex = _xmouse;
cuey = _ymouse;
ncuey = (10 * (-cuey)) / (math.abs(cuex) + math.abs(cuey));
ncuex = (10 * cuex) / (math.abs(cuex) + math.abs(cuey));
rot = (Math.atan2(ncuex, ncuey) * 180) / 3.142;
temppwr = getTimer() - powstart;
if (!_level0.shotstarted) {
if (moused) {
pb = int(temppwr / 50);
_level0.powerbar.gotoandstop(pb);
}
_level0.cue._x = _level0.ball1._x;
_level0.cue._y = _level0.ball1._y;
_level0.cue._rotation = ROT;
}
}
Instance of Symbol 86 MovieClip "t2" in Frame 4
onClipEvent (load) {
rtime = _level0.timer;
running = true;
lasttime = -99;
}
onClipEvent (enterFrame) {
if (running) {
rtime = rtime - 0.05;
if (rtime < 0) {
rtime = 0;
_level0.gameover = true;
_root.gotoandplay("explode");
running = false;
}
}
raw = int(rtime);
if (raw != lasttime) {
time = raw;
} else {
lasttime = raw;
}
}
Instance of Symbol 86 MovieClip "t5" in Frame 4
onClipEvent (load) {
rtime = _level0.timer;
running = true;
lasttime = -99;
}
onClipEvent (enterFrame) {
if (running) {
rtime = rtime - 0.05;
if (rtime < 0) {
rtime = 0;
_level0.gameover = true;
_root.gotoandplay("explode");
running = false;
}
}
raw = int(rtime);
if (raw != lasttime) {
time = raw;
} else {
lasttime = raw;
}
}
Instance of Symbol 86 MovieClip "t4" in Frame 4
onClipEvent (load) {
rtime = _level0.timer;
running = true;
lasttime = -99;
}
onClipEvent (enterFrame) {
if (running) {
rtime = rtime - 0.05;
if (rtime < 0) {
rtime = 0;
_level0.gameover = true;
_root.gotoandplay("explode");
running = false;
}
}
raw = int(rtime);
if (raw != lasttime) {
time = raw;
} else {
lasttime = raw;
}
}
Instance of Symbol 86 MovieClip "t7" in Frame 4
onClipEvent (load) {
rtime = _level0.timer;
running = true;
lasttime = -99;
}
onClipEvent (enterFrame) {
if (running) {
rtime = rtime - 0.05;
if (rtime < 0) {
rtime = 0;
_level0.gameover = true;
_root.gotoandplay("explode");
running = false;
}
}
raw = int(rtime);
if (raw != lasttime) {
time = raw;
} else {
lasttime = raw;
}
}
Instance of Symbol 86 MovieClip "t6" in Frame 4
onClipEvent (load) {
rtime = _level0.timer;
running = true;
lasttime = -99;
}
onClipEvent (enterFrame) {
if (running) {
rtime = rtime - 0.05;
if (rtime < 0) {
rtime = 0;
_level0.gameover = true;
_root.gotoandplay("explode");
running = false;
}
}
raw = int(rtime);
if (raw != lasttime) {
time = raw;
} else {
lasttime = raw;
}
}
Instance of Symbol 86 MovieClip "t3" in Frame 4
onClipEvent (load) {
rtime = _level0.timer;
running = true;
lasttime = -99;
}
onClipEvent (enterFrame) {
if (running) {
rtime = rtime - 0.05;
if (rtime < 0) {
rtime = 0;
_level0.gameover = true;
_root.gotoandplay("explode");
running = false;
}
}
raw = int(rtime);
if (raw != lasttime) {
time = raw;
} else {
lasttime = raw;
}
}
Frame 5
function init_balls() {
leveltext = level_text[level];
if (level_dynamite[level]) {
dynamite._x = 400;
dynamite._y = 300;
} else {
dynamite._x = -300;
dynamite._y = -300;
}
if (level_balls[level] == 1) {
startballx[1] = 200 + random(30);
startbally[1] = 120 + random(220);
startballx[2] = 160;
startbally[2] = 300;
startballx[3] = 160;
startbally[3] = 160;
startballx[4] = 160;
startbally[4] = 230;
startballx[5] = 330;
startbally[5] = 230;
startballx[6] = 430;
startbally[6] = 230;
startballx[7] = 530;
startbally[7] = 230;
} else if (level_balls[level] == 2) {
startballx[1] = (77.7 + random(20)) - random(20);
startbally[1] = (230 + random(20)) - random(20);
startballx[2] = 393.05;
startbally[2] = 265.6;
startballx[3] = 466.55;
startbally[3] = 168.5;
startballx[4] = 390.05;
startbally[4] = 212.6;
startballx[5] = 466.55;
startbally[5] = 302.3;
startballx[6] = 537;
startbally[6] = 212.6;
startballx[7] = 541;
startbally[7] = 265.6;
} else {
dynamite._x = random(500) + 75;
dynamite._y = random(160) + 150;
item = 1;
while (item <= 7) {
safe = false;
while (!safe) {
placex = random(500) + 75;
placey = random(200) + 130;
safe = true;
if (item == 1) {
dbx = dynamite._x - placex;
dby = dynamite._y - placey;
delta = Math.sqrt((dby * dby) + (dbx * dbx));
if (delta < 70) {
safe = false;
}
} else {
checki = 1;
while (checki <= (item - 1)) {
dbx = startballx[checki] - placex;
dby = startbally[checki] - placey;
delta = Math.sqrt((dby * dby) + (dbx * dbx));
if (delta < (radius * 2)) {
safe = false;
}
dbx = dynamite._x - placex;
dby = dynamite._y - placey;
delta = Math.sqrt((dby * dby) + (dbx * dbx));
if (delta < 70) {
safe = false;
}
checki++;
}
}
}
startballx[item] = placex;
startbally[item] = placey;
item++;
}
}
ball = 1;
while (ball <= balls) {
thisball = eval ("ball" + ball);
thisball._x = startballx[ball];
thisball._y = startbally[ball];
realx[ball] = thisball._x;
realy[ball] = _level0.starty - thisball._y;
eval ("t" + ball)._x = thisball._x;
eval ("t" + ball)._y = thisball._y;
eval ("t" + ball).rtime = Level_timer[level];
eval ("t" + ball).running = true;
potted[ball] = false;
ball++;
}
}
hit = 0;
bonus = 0;
gameover = false;
u = 30;
t = 0;
a = -1;
startx = white._x;
balls = 7;
ballspotted = 0;
starty = 400;
friction = 0.1;
explode._x = -999;
explode._y = -999;
explode.gotoandstop(1);
vx = new array(0, 0, 0);
vy = new array(0, 0, 0);
realx = new array(0, 200, 200);
realy = new array(0, 300, 300);
potted = new array();
startballx = new array();
startbally = new array();
max_level = 4;
level_text = new Array();
level_balls = new Array();
level_dynamite = new Array();
level_timer = new Array();
level_text[1] = "LEVEL ONE: CLEAR THE BOMBS IN 100 SECONDS !";
level_text[2] = "LEVEL TWO: CLEAR THE CIRCLE OF BOMBS !";
level_text[3] = "LEVEL THREE: DON'T DISTURB THE DYNAMITE !";
level_text[4] = "LEVEL FOUR: DON'T DISTURB THE DYNAMITE !";
level_text[5] = "LEVEL FIVE: DON'T DISTURB THE DYNAMITE !";
Level_balls[1] = 1;
Level_balls[2] = 2;
Level_balls[3] = 3;
Level_balls[4] = 3;
Level_balls[5] = 3;
level_dynamite[1] = false;
level_dynamite[2] = false;
level_dynamite[3] = true;
level_dynamite[4] = true;
level_dynamite[5] = true;
Level_timer[1] = 100;
Level_timer[2] = 95;
Level_timer[3] = 90;
Level_timer[4] = 80;
Level_timer[5] = 75;
ball = 1;
while (ball <= balls) {
thisball = eval ("ball" + ball);
ball++;
}
init_balls();
Frame 6
shotstarted = false;
Frame 7
cue.gotoandstop(1);
powerbar.gotoandstop(1);
Frame 8
if (gameover) {
gotoAndPlay (31);
}
Frame 9
var version = doc.firstChild.childNodes[1].firstChild.nodeValue;
if (!shotstarted) {
gotoAndPlay (8);
}
Frame 10
power = pwr / 50;
if (power > 15) {
power = 15;
}
ncuey = (power * (-cuey)) / (math.abs(cuex) + math.abs(cuey));
ncuex = (power * cuex) / (math.abs(cuex) + math.abs(cuey));
vx[1] = ncuex;
vy[1] = ncuey;
shotstarted = true;
cue.gotoandplay(2);
Frame 19
allstillc = 0;
ii = 1;
while (ii <= balls) {
if ((vx[ii] == 0) and (vy[ii] == 0)) {
allstillc++;
}
jj = ii + 1;
while (jj <= balls) {
white = eval ("_level0.ball" + ii);
red = eval ("_level0.ball" + jj);
why = starty - white._y;
rey = starty - red._y;
dby = (-why) + rey;
dbx = (-white._x) + red._x;
delta = Math.sqrt((dby * dby) + (dbx * dbx));
if (delta < radius) {
white._x = white._x - vx[ii];
white._y = white._y + vy[ii];
realx[ii] = realx[ii] - vx[ii];
realy[ii] = realy[ii] - vy[ii];
red._x = red._x - vx[jj];
red._y = red._y + vy[jj];
realx[jj] = realx[jj] - vx[jj];
realy[jj] = realy[jj] - vy[jj];
x1 = white._x;
y1 = starty - white._y;
x2 = red._x;
y2 = starty - red._y;
angle = Math.atan2(y2 - y1, x2 - x1);
x1 = vx[ii];
y1 = vy[ii];
x2 = vx[jj];
y2 = vy[jj];
if ((((Math.abs(x1) + Math.abs(x2)) + Math.abs(y1)) + Math.abs(y2)) > 3) {
shotsound.gotoandplay(2);
}
cma = Math.cos(-angle);
sma = Math.sin(-angle);
sa = Math.sin(angle);
ca = Math.cos(angle);
nx1 = (x1 * cma) - (y1 * sma);
ny1 = (x1 * sma) + (y1 * cma);
nx2 = (x2 * cma) - (y2 * sma);
ny2 = (x2 * sma) + (y2 * cma);
nx1 = nx2;
x1 = (nx1 * ca) - (ny1 * sa);
y1 = (nx1 * sa) + (ny1 * ca);
next1x = x1;
next1y = y1;
x2 = white._x;
y2 = starty - white._y;
x1 = red._x;
y1 = starty - red._y;
angle = Math.atan2(y2 - y1, x2 - x1);
x2 = vx[ii];
y2 = vy[ii];
x1 = vx[jj];
y1 = vy[jj];
nx1 = (x1 * Math.cos(-angle)) - (y1 * Math.sin(-angle));
ny1 = (x1 * Math.sin(-angle)) + (y1 * Math.cos(-angle));
nx2 = (x2 * Math.cos(-angle)) - (y2 * Math.sin(-angle));
ny2 = (x2 * Math.sin(-angle)) + (y2 * Math.cos(-angle));
nx1 = nx2;
x1 = (nx1 * Math.cos(angle)) - (ny1 * Math.sin(angle));
y1 = (nx1 * Math.sin(angle)) + (ny1 * Math.cos(angle));
next2x = x1;
next2y = y1;
vx[ii] = next1x;
vy[ii] = next1y;
vx[jj] = next2x;
vy[jj] = next2y;
}
jj++;
}
ii++;
}
Frame 20
function update_balls() {
ball = 1;
while (ball <= balls) {
bamc = eval ("ball" + ball);
if (dynamite.hit.hittest(bamc._x, bamc._y, true)) {
_level0.gameover = true;
_root.gotoandplay("explode");
}
if (!middle.hitTest(bamc._x, bamc._y, false)) {
check_pockets();
}
if (!potted[ball]) {
if (_level0.shotstarted) {
absvx = Math.ABS(vx[ball]);
absvy = Math.ABS(vy[ball]);
if ((absvx + absvy) == 0) {
lessy = 0;
lessx = 0;
} else {
lessy = absvy / (absvx + absvy);
lessx = absvx / (absvx + absvy);
}
if (Vx[ball] > 0) {
vx[ball] = vx[ball] - (_level0.friction * lessx);
} else {
vx[ball] = vx[ball] + (_level0.friction * lessx);
}
if (Vy[ball] > 0) {
vy[ball] = vy[ball] - (_level0.friction * lessy);
} else {
vy[ball] = vy[ball] + (_level0.friction * lessy);
}
if ((absvx < ballstop) and (absvy < ballstop)) {
vy[ball] = 0;
vx[ball] = 0;
}
realx[ball] = realx[ball] + vx[ball];
realy[ball] = realy[ball] + vy[ball];
thisball = eval ("ball" + ball);
thisball._x = realx[ball];
thisball._y = _level0.starty - realy[ball];
eval ("t" + ball)._x = thisball._x;
eval ("t" + ball)._y = thisball._y;
if (!middle.hitTest(bamc._x, bamc._y, false)) {
check_wall(ball);
}
}
}
ball++;
}
}
function check_pockets() {
bamc = eval ("ball" + ball);
p = 1;
while (p <= 6) {
pomc = eval ("pocket" + p);
if (pomc.hittest(bamc._x, bamc._y, true)) {
down.gotoandplay(2);
score = score + eval ("t" + ball).time;
bamc._visible = false;
vx[ball] = 0;
vy[ball] = 0;
bamc._x = 100;
bamc._y = 0;
realx[ball] = 130 + (ballspotted * 30);
realy[ball] = 350;
bamc._y = _level0.starty - realy[ball];
bamc._x = realx[ball];
bamc._visible = true;
potted[ball] = true;
if (ball > 1) {
ballspotted++;
pomc.gotoandplay("red");
} else {
pomc.gotoandplay("white");
_level0.gameover = true;
_root.gotoandplay("explode");
}
eval ("t" + ball).running = false;
eval ("t" + ball)._y = bamc._y;
eval ("t" + ball)._x = bamc._x;
}
p++;
}
}
function check_wall(index) {
if (realx[index] < 50) {
realx[index] = 50;
vx[index] = -vx[index];
}
if (realy[index] > 280) {
realy[index] = 280;
vy[index] = -vy[index];
}
if (realy[index] < 50) {
realy[index] = 50;
vy[index] = -vy[index];
}
if (realx[index] > 610) {
realx[index] = 610;
vx[index] = -vx[index];
}
}
update_balls();
if ((allstillc < balls) and (!gameover)) {
gotoAndPlay (19);
}
Frame 21
if (gameover) {
gotoAndPlay (31);
}
Frame 22
if (ballspotted == (balls - 1)) {
var teams_left = doc.firstChild.childNodes[0].firstChild.nodeValue;
gotoAndPlay (59);
}
Frame 28
if ((score > 500) and (_root.drz.magic < 10)) {
_level0.vel0 = true;
}
gotoAndPlay (6);
Frame 31
explode._x = 300;
explode._y = 200;
explode.gotoandplay(2);
Frame 43
ibpro_hackers_stop_now = 10;
gotoAndPlay (139);
Frame 58
stop();
Frame 59
level++;
Frame 138
if (level > max_level) {
gotoAndPlay (139);
} else {
gotoAndPlay (5);
}
Frame 139
explode.gotoandstop(1);
explode._x = -999;
stats_check = false;
Instance of Symbol 137 MovieClip "game_cooky" in Frame 139
onClipEvent (load) {
function write_game_cookie(game_id, f1, f2, f3, f4, f5, f6) {
name = "game" + game_id;
so = SharedObject.getLocal(name, "/");
so.data.game_id = game_id;
so.data.f1 = f1;
so.data.f2 = f2;
so.data.f3 = f3;
so.data.f4 = f4;
so.data.f5 = f5;
so.data.f6 = f6;
so.flush();
}
function read_game_cookie(game_id) {
name = "game" + game_id;
so = SharedObject.getLocal(name, "/");
if (so.data.game_id == null) {
result = false;
} else {
result = true;
_level0.checker = so.data.game_id;
_level0.f1 = so.data.f1;
_level0.f2 = so.data.f2;
_level0.f3 = so.data.f3;
_level0.f4 = so.data.f4;
_level0.f5 = so.data.f5;
_level0.f6 = so.data.f6;
}
return(result);
}
_visible = true;
}
Frame 140
game_id = "cdg_obbstats1";
if (stats_check == false) {
exists = game_cooky.read_game_cookie(game_id);
if (exists == false) {
game_cooky.write_game_cookie(game_id, 0, 0, 0, 0, 0, 0);
f1 = 0;
f2 = 0;
f3 = 0;
f4 = 0;
f5 = 0;
f6 = 0;
}
cookie_played = f1;
cookie_best = f2;
cookie_best_date = f3;
cookie_dummy1 = f4;
cookie_dummy2 = f5;
cookie_dummy3 = f6;
stats_check = true;
}
if (score > cookie_best) {
cookie_best = score;
myDate = new Date();
todaydate = (((myDate.getDate() + "/") + (1 + myDate.getUTCMonth())) + "/") + myDate.getFullYear();
todaydate = todaydate + ((" " + myDate.getHours()) + ":");
mins = myDate.getMinutes();
if (mins < 10) {
todaydate = todaydate + ("0" + mins);
} else {
todaydate = todaydate + mins;
}
cookie_best_date = todaydate;
}
cookie_played++;
f1 = cookie_played;
f2 = cookie_best;
f3 = cookie_best_date;
f4 = cookie_dummy1;
f5 = cookie_dummy2;
f6 = cookie_dummy3;
game_cooky.write_game_cookie(game_id, f1, f2, f3, f4, f5, f6);
stop();
Frame 149
stop();
Symbol 8 MovieClip Frame 7
gotoAndPlay (1);
Symbol 11 MovieClip Frame 32
gotoAndPlay (1);
Symbol 16 MovieClip Frame 1
doneLoading = 0;
stop();
Instance of Symbol 13 MovieClip "bkgd" in Symbol 16 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_parent.doneLoading == 0) {
total = _parent._parent.getBytesTotal();
isloaded = _parent._parent.getBytesLoaded();
p = 100 * (isLoaded / total);
_parent.bytes = ((int(isloaded / 1000) add " KB of ") add int(total / 1000)) add " KB";
_parent.percent = int(p) add "% LOADED";
_parent.bar._xscale = p;
if (Number(p) > Number(95)) {
_parent._parent.gotoAndPlay(Number(2));
_parent.gotoAndStop("off");
_parent.doneLoading = 1;
} else {
_parent._parent.gotoAndPlay(Number(1));
}
}
}
Instance of Symbol 13 MovieClip "bar" in Symbol 16 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_parent.doneLoading == 0) {
total = _parent._parent.getBytesTotal();
isloaded = _parent._parent.getBytesLoaded();
p = 100 * (isLoaded / total);
_parent.bytes = ((int(isloaded / 1000) add " KB of ") add int(total / 1000)) add " KB";
_parent.percent = int(p) add "% LOADED";
_parent.bar._xscale = p;
if (Number(p) > Number(95)) {
_parent._parent.gotoAndPlay(Number(2));
_parent.gotoAndStop("off");
_parent.doneLoading = 1;
} else {
_parent._parent.gotoAndPlay(Number(1));
}
}
}
Symbol 27 Button
on (release) {
play();
}
Symbol 32 Button
on (keyPress "~") {
command = "init";
this.loadVariables("highscores_bb.php?" + int(Math.random() * 100000), "POST");
gotoAndStop (3);
}
Symbol 36 Button
on (release) {
getURL ("http://www.mousebreaker.com/index.php?cdgtid=obb", "_blank");
}
Symbol 39 Button
on (release) {
getURL ("http://www.mousebreaker.com/index.php?cdgtid=obb", "_blank");
}
Symbol 42 Button
on (release) {
getURL ("http://www.mousebreaker.com/index.php?page=downloadagreement");
}
Symbol 74 MovieClip Frame 4
gotoAndPlay (1);
Symbol 77 MovieClip Frame 1
stop();
Symbol 77 MovieClip Frame 12
gotoAndStop (1);
Symbol 77 MovieClip Frame 30
gotoAndStop (1);
Symbol 88 MovieClip Frame 1
stop();
Symbol 92 MovieClip Frame 1
stop();
Symbol 97 MovieClip Frame 45
stop();
Symbol 102 MovieClip Frame 1
stop();
Symbol 102 MovieClip Frame 20
stop();
Symbol 106 MovieClip Frame 1
stop();
Symbol 108 MovieClip Frame 1
stop();
Symbol 110 Button
on (release) {
init_balls();
score = 0;
level = 1;
gotoAndPlay (4);
}
Symbol 118 Button
on (release) {
gotoAndPlay (5);
}
Symbol 124 Button
on (release) {
if (level > max_level) {
gotoAndPlay (149);
} else {
gotoAndPlay (4);
}
}
Symbol 148 Button
on (release) {
gotoAndPlay (4);
}
Symbol 149 Button
on (release) {
getURL ("http://www.mousebreaker.com/index.php?cdgtid=obb_bb", "_blank");
}