Frame 1
ifFrameLoaded (15) {
gotoAndPlay (3);
}
Frame 2
gotoAndPlay (1);
Frame 3
function howhit(orb, finger) {
width = getProperty("hand" + finger, _width) / 2;
fx = getProperty("hand" + finger, _x);
ox = getProperty("ball" + orb, _x);
diff = Math.abs(fx - ox);
result = 1;
if (((0.8 * width) < diff) and ((1.1 * width) >= diff)) {
result = 2;
}
if ((1.1 * width) < diff) {
result = 4;
}
if ((ox < fx) and (result == 2)) {
result = 3;
}
return(result);
}
function aim(where) {
diff = Math.abs(where - center);
trip = (diff + 50) + random(215);
vel = trip / ((2 * initspeed) + 2);
if (center < where) {
vel = -vel;
}
return(vel);
}
backoffy = new array();
backoffx = new array();
hyspeed = new array();
hyaccel = new array();
hygoal = new array();
yspeed = new array();
xspeed = new array();
contact = new array();
hit = new array();
flying = new array();
launch = new array();
passed = new array();
bxoff = new array();
byoff = new array();
owner = new array();
spacing = new array();
center = 500;
gravity = 1;
initspeed = 25;
spacing[3] = 54;
spacing[4] = 52;
spacing[5] = 54;
spacing[6] = 54;
balls = 6;
k = 1;
while (balls >= k) {
yspeed[k] = 0;
flying[k] = 0;
passed[k] = 0;
owner[k] = (k % 2) + 1;
k++;
}
byoff[1] = 10;
byoff[2] = 10;
byoff[3] = 20;
byoff[4] = 10;
byoff[5] = 10;
byoff[6] = 20;
bxoff[1] = 10;
bxoff[2] = -10;
bxoff[3] = -10;
bxoff[4] = 10;
bxoff[5] = 0;
bxoff[6] = 0;
inc = 1;
finished = 0;
count = 0;
goplay = 0;
stop();
Frame 6
hygoal[1] = getProperty("hand1", _y);
hygoal[2] = getProperty("hand2", _y);
backoffx[1] = getProperty("handback1", _x) - getProperty("hand1", _x);
backoffy[1] = getProperty("handback1", _y) - getProperty("hand1", _y);
backoffx[2] = getProperty("handback2", _x) - getProperty("hand2", _x);
backoffy[2] = getProperty("handback2", _y) - getProperty("hand2", _y);
k = 1;
while (balls >= k) {
launch[k] = (spacing[balls] / balls) * (k - 1);
k++;
}
score = 0;
startDrag ("mouse", true, -50, hygoal[1], 1100, hygoal[1]);
Frame 7
play();
setProperty("hand1", _y , getProperty("hand1", _y) + hyspeed[1]);
hyaccel[1] = (-(getProperty("hand1", _y) - hygoal[1])) * 0.08;
hyspeed[1] = (hyspeed[1] + hyaccel[1]) * 0.82;
setProperty("hand2", _y , getProperty("hand2", _y) + hyspeed[2]);
hyaccel[2] = (-(getProperty("hand2", _y) - hygoal[2])) * 0.08;
hyspeed[2] = (hyspeed[2] + hyaccel[2]) * 0.82;
setProperty("hand1", _x , getProperty("mouse", _x) - 100);
setProperty("hand2", _x , getProperty("mouse", _x) + 100);
setProperty("handback1", _x , getProperty("hand1", _x) + backoffx[1]);
setProperty("handback1", _y , getProperty("hand1", _y) + backoffy[1]);
setProperty("handback2", _x , getProperty("hand2", _x) + backoffx[2]);
setProperty("handback2", _y , getProperty("hand2", _y) + backoffy[2]);
k = 1;
while (balls >= k) {
tosser = owner[k];
temp = getProperty("ball" + k, _y);
setProperty("ball" + k, _y , temp);
temp = getProperty("ball" + k, _x);
setProperty("ball" + k, _x , temp);
bossx = getProperty("hand" + tosser, _x);
bossy = getProperty("hand" + tosser, _y);
setProperty("ball" + k, _y , bossy + byoff[k]);
setProperty("ball" + k, _x , bossx + bxoff[k]);
k++;
}
if (goplay == 1) {
gotoAndPlay (11);
}
Frame 8
prevFrame();
Frame 11
play();
setProperty("hand1", _y , getProperty("hand1", _y) + hyspeed[1]);
hyaccel[1] = (-(getProperty("hand1", _y) - hygoal[1])) * 0.08;
hyspeed[1] = (hyspeed[1] + hyaccel[1]) * 0.82;
setProperty("hand2", _y , getProperty("hand2", _y) + hyspeed[2]);
hyaccel[2] = (-(getProperty("hand2", _y) - hygoal[2])) * 0.08;
hyspeed[2] = (hyspeed[2] + hyaccel[2]) * 0.82;
setProperty("hand1", _x , getProperty("mouse", _x) - 100);
setProperty("hand2", _x , getProperty("mouse", _x) + 100);
setProperty("handback1", _x , getProperty("hand1", _x) + backoffx[1]);
setProperty("handback1", _y , getProperty("hand1", _y) + backoffy[1]);
setProperty("handback2", _x , getProperty("hand2", _x) + backoffx[2]);
setProperty("handback2", _y , getProperty("hand2", _y) + backoffy[2]);
k = 1;
while (balls >= k) {
tosser = owner[k];
temp = getProperty("ball" + k, _y) + yspeed[k];
setProperty("ball" + k, _y , temp);
temp = getProperty("ball" + k, _x) + xspeed[k];
setProperty("ball" + k, _x , temp);
yspeed[k] = yspeed[k] + gravity;
if (flying[k] != 1) {
bossx = getProperty("hand" + tosser, _x);
bossy = getProperty("hand" + tosser, _y);
setProperty("ball" + k, _y , bossy + byoff[k]);
setProperty("ball" + k, _x , bossx + bxoff[k]);
}
k++;
}
count++;
k = 1;
while (balls >= k) {
if (flying[k] == 0) {
yspeed[k] = yspeed[k] - gravity;
if (count >= launch[k]) {
flying[k] = 1;
bx = getProperty("ball" + k, _x);
yspeed[k] = (-initspeed) + 5;
xspeed[k] = aim(bx);
tosser = owner[k];
hyspeed[tosser] = -15;
}
}
m = 1;
while (2 >= m) {
hx = getProperty("hand" + m, _x);
hy = getProperty("hand" + m, _y);
bx = getProperty("ball" + k, _x);
by = getProperty("ball" + k, _y);
if ((420 < by) and (finished != 1)) {
finished = 1;
stopDrag();
highscore_list.newScore = score;
highscore_list.gotoAndPlay("check_score");
inc = 0;
}
test = howhit(k, m);
if (((((hy < by) and (contact[k] < 1)) and (0 < yspeed[k])) and (test < 4)) and (flying[k] != 0)) {
hit[k] = m;
contact[k] = howhit(k, m);
if (contact[k] == 1) {
score = score + inc;
hyspeed[m] = yspeed[k];
}
if ((contact[k] == 2) or (contact[k] == 3)) {
hyspeed[m] = 7;
yspeed[k] = yspeed[k] * 0.6;
xspeed[k] = (-yspeed[k]) * 0.6;
if (contact[k] == 2) {
xspeed[k] = -xspeed[k];
}
}
}
if ((contact[k] == 1) and (hit[k] == m)) {
if (0 < hyspeed[m]) {
yspeed[k] = hyspeed[m];
bx = ((bx * 3) + hx) / 4;
} else {
contact[k] = 0;
hit[k] = 0;
yspeed[k] = -initspeed;
xspeed[k] = aim(bx);
}
}
setProperty("hand" + m, _x , hx);
setProperty("hand" + m, _y , hy);
setProperty("ball" + k, _x , bx);
setProperty("ball" + k, _y , by);
m++;
}
k++;
}
Frame 12
prevFrame();
Symbol 7 MovieClip Frame 1
total = _root.getBytesTotal();
Symbol 7 MovieClip Frame 2
percent = _root.getBytesLoaded() / total;
setProperty("bar", _xscale , percent * 100);
Symbol 7 MovieClip Frame 3
gotoAndPlay (2);
Symbol 58 Button
on (release) {
gotoAndPlay (13);
}
Symbol 62 MovieClip Frame 1
gameName = "juggling";
Symbol 62 MovieClip Frame 2
action = "read";
loadVariables ("/scores/highscore_engine.asp", "", "POST");
Symbol 62 MovieClip Frame 3
if (loaded == 1) {
gotoAndPlay (5);
}
Symbol 62 MovieClip Frame 4
gotoAndPlay (3);
Symbol 62 MovieClip Frame 5
stop();
Symbol 62 MovieClip Frame 10
if (goal == "high") {
if (newScore >= Number(todayHigh10)) {
gotoAndStop (11);
} else {
gotoAndStop (20);
}
}
if (goal == "low") {
if (Number(todayHigh10) >= newScore) {
gotoAndStop (11);
} else {
gotoAndStop (20);
}
}
Symbol 62 MovieClip Frame 11
stop();
Symbol 62 MovieClip Frame 13
updated = 0;
action = "insert";
loadVariables ("/scores/highscore_engine.asp", "", "POST");
Symbol 62 MovieClip Frame 14
if (updated == 1) {
gotoAndStop (20);
}
Symbol 62 MovieClip Frame 15
gotoAndPlay (14);
Symbol 62 MovieClip Frame 20
_root.reset.gotoAndStop("on");
gotoAndPlay (1);
Symbol 79 Button
on (release) {
balls = 3;
gotoAndPlay (6);
}
Symbol 80 Button
on (release) {
balls = 4;
gotoAndPlay (6);
}
Symbol 81 Button
on (release) {
balls = 5;
gotoAndPlay (6);
}
Symbol 82 Button
on (release) {
balls = 6;
gotoAndPlay (6);
}
Symbol 86 Button
on (release) {
getURL ("http://www.makaimedia.com", "_blank");
}
Symbol 90 Button
on (rollOver) {
call("/subs:rollover");
}
on (rollOut, dragOut) {
call("/subs:rollout");
}
on (release) {
getURL (url, "_self");
}
Symbol 94 Button
on (rollOver) {
call("/subs:rollover");
}
on (rollOut, dragOut) {
call("/subs:rollout");
}
on (release) {
getURL (url, "_self");
}
Symbol 98 Button
on (rollOver) {
call("/subs:rollover");
}
on (rollOut, dragOut) {
call("/subs:rollout");
}
on (release) {
getURL (url, "_self");
}
Symbol 99 Button
on (rollOver) {
call("/subs:rollover");
}
on (rollOut, dragOut) {
call("/subs:rollout");
}
on (release) {
getURL (url, "_self");
}
Symbol 103 Button
on (rollOver) {
call("/subs:rollover");
}
on (rollOut, dragOut) {
call("/subs:rollout");
}
on (release) {
getURL (url, "_self");
}
Symbol 107 Button
on (rollOver) {
call("/subs:rollover");
}
on (rollOut, dragOut) {
call("/subs:rollout");
}
on (release) {
getURL (url, "_self");
}
Symbol 111 Button
on (rollOver) {
call("/subs:rollover");
}
on (rollOut, dragOut) {
call("/subs:rollout");
}
on (release) {
getURL (url, "_self");
}
Symbol 115 Button
on (rollOver) {
call("/subs:rollover");
}
on (rollOut, dragOut) {
call("/subs:rollout");
}
on (release) {
getURL (url, "_self");
}
Symbol 116 Button
on (release) {
getURL (url, "_self");
}
Symbol 117 MovieClip Frame 1
url = "http://139.142.198.104/main.html";
Symbol 122 Button
on (release) {
hyspeed[1] = 0;
hyspeed[2] = 0;
goplay = 1;
}
Symbol 124 Button
on (release) {
tellTarget ("../") {
n = 1;
while (balls >= n) {
setProperty("ball" + n, _y , -80);
setProperty("ball" + n, _x , -80);
n++;
}
gotoAndStop ("reset");
};
}
Symbol 127 MovieClip Frame 1
stop();