Frame 1
Set("/ball1:vel", 2.7111);
Set("/ball1:theta", (Math.pi / 4) + 0.1);
setProperty("/ball1", _x , 177);
setProperty("/ball1", _y , 225);
velo = 0.15;
score = 0;
curve = 0.8;
Set("/ball:vel", 1.1111111);
Set("/ball:theta", (5 * math.pi) / 4);
setProperty("/ball", _x , 200);
setProperty("/ball", _y , 200);
startDrag ("/tracker", true);
Mouse.show();
fscommand (showmenu, false);
fscommand (fullscreen, true);
Frame 2
xa = a;
xb = b;
b = getProperty("/ball1", _x) - getProperty("/ball", _x);
a = getProperty("/ball1", _y) - getProperty("/ball", _y);
if (((math.abs(xa) < 10) and (math.abs(xb) < 10)) and (0 < barmy)) {
gamma = Math.atan(b / a) + 1.0471975511966;
ala = (random(10) / 1000) + gamma;
Set("/ball:theta", /ball:theta + ala);
Set("/ball1:theta", /ball1:theta + ala);
setProperty("/ball1", _x , getProperty("/ball1", _x) + (/ball1:vel * Math.sin(/ball1:theta)));
setProperty("/ball1", _y , getProperty("/ball1", _y) + (/ball1:vel * (-Math.cos(/ball1:theta))));
setProperty("/ball", _x , getProperty("/ball", _x) + (/ball:vel * Math.sin(/ball:theta)));
setProperty("/ball", _y , getProperty("/ball", _y) + (/ball:vel * (-Math.cos(/ball:theta))));
barmy = -10;
}
barmy++;
setProperty("/ball1", _x , getProperty("/ball1", _x) + (/ball1:vel * Math.sin(/ball1:theta)));
setProperty("/ball1", _y , getProperty("/ball1", _y) + (/ball1:vel * (-Math.cos(/ball1:theta))));
ab = getProperty("/ball1", _x) - 200;
bb = -(getProperty("/ball1", _y) - 200);
neu = Math.atan(ab / bb);
if ((/ball1:theta == 0) or (/ball1:theta == (2 * math.pi))) {
neu = math.pi;
}
abl = ab * ab;
bbl = bb * bb;
ro = abl + bbl;
if ((bb < 0) and (0 < ab)) {
neu = math.pi - neu;
}
if ((bb < 0) and (ab < 0)) {
neu = math.pi + neu;
}
if ((bb < 0) and (0 < ab)) {
neu = (2 * math.pi) - neu;
}
m = 1;
while (m < 10) {
if (theta >= (2 * math.pi)) {
tbar = theta - (2 * math.pi);
}
if (theta < 0) {
theta = theta + (2 * math.pi);
}
m++;
}
tbar = math.pi - theta;
m = 1;
while (m < 10) {
if (tbar >= (2 * math.pi)) {
tbar = tbar - (2 * math.pi);
}
if (tbar < 0) {
tbar = tbar + (2 * math.pi);
}
m++;
}
m = 1;
while (m < 10) {
if ((2 * math.pi) < neu) {
neu = neu - (2 * math.pi);
}
if (neu < 0) {
neu = neu + (2 * math.pi);
}
m++;
}
if (((33400 < Math.abs(ro)) and (ro < ((183 + /ball1:vel) * (183 + /ball1:vel)))) and (Math.abs(phi - neu) < 0.18)) {
Set("/ball1:theta", (math.pi + (2 * neu)) - /ball1:theta);
Set("/ball1:theta", /ball1:theta + ((neu - phi) / curve));
Set("/ball1:vel", /ball1:vel + velo);
dis = 1;
}
if ((((((33400 < Math.abs(ro)) and (ro < 34500)) and (((2 * math.pi) - 0.09) < (phi + neu))) and ((phi + neu) < ((2 * math.pi) + 0.09))) and (dis != 1)) and ((6.1 < neu) or (neu < 0.2))) {
Set("/ball1:theta", (math.pi + (2 * neu)) - /ball1:theta);
Set("/ball1:vel", /ball1:vel + velo);
}
dis = 0;
if (5 >= getProperty("/ball1", _y)) {
gotoAndStop (4);
}
if (getProperty("/ball1", _y) >= 395) {
gotoAndStop (4);
}
if (getProperty("/ball1", _x) >= 395) {
gotoAndStop (4);
}
if (5 >= getProperty("/ball1", _x)) {
gotoAndStop (4);
}
phi = (Math.PI * getProperty("/tracker", _x)) / 180;
m = 1;
while (m < 10) {
if ((2 * math.pi) < phi) {
phi = phi - (2 * math.pi);
}
if (phi < 0) {
phi = phi + (2 * math.pi);
}
m++;
}
setProperty("/bat1", _rotation , ((360 * phi) / 2) / math.pi);
setProperty("/ball", _x , getProperty("/ball", _x) + (/ball:vel * Math.sin(/ball:theta)));
setProperty("/ball", _y , getProperty("/ball", _y) + (/ball:vel * (-Math.cos(/ball:theta))));
ab = getProperty("/ball", _x) - 200;
bb = -(getProperty("/ball", _y) - 200);
neu = Math.atan(ab / bb);
if ((/ball:theta == 0) or (/ball:theta == (2 * math.pi))) {
neu = math.pi;
}
abl = ab * ab;
bbl = bb * bb;
ro = abl + bbl;
if ((bb < 0) and (0 < ab)) {
neu = math.pi - neu;
}
if ((bb < 0) and (ab < 0)) {
neu = math.pi + neu;
}
if ((bb < 0) and (0 < ab)) {
neu = (2 * math.pi) - neu;
}
m = 1;
while (m < 10) {
if (theta >= (2 * math.pi)) {
tbar = theta - (2 * math.pi);
}
if (theta < 0) {
theta = theta + (2 * math.pi);
}
m++;
}
tbar = math.pi - theta;
m = 1;
while (m < 10) {
if (tbar >= (2 * math.pi)) {
tbar = tbar - (2 * math.pi);
}
if (tbar < 0) {
tbar = tbar + (2 * math.pi);
}
m++;
}
m = 1;
while (m < 10) {
if ((2 * math.pi) < neu) {
neu = neu - (2 * math.pi);
}
if (neu < 0) {
neu = neu + (2 * math.pi);
}
m++;
}
if (((33400 < Math.abs(ro)) and (ro < ((183 + /ball:vel) * (183 + /ball:vel)))) and (Math.abs(phi - neu) < 0.18)) {
Set("/ball:theta", (math.pi + (2 * neu)) - /ball:theta);
Set("/ball:theta", /ball:theta + ((neu - phi) / curve));
Set("/ball:vel", /ball:vel + velo);
dis = 1;
}
if ((((((33400 < Math.abs(ro)) and (ro < 34500)) and (((2 * math.pi) - 0.09) < (phi + neu))) and ((phi + neu) < ((2 * math.pi) + 0.09))) and (dis != 1)) and ((6.1 < neu) or (neu < 0.2))) {
Set("/ball:theta", (math.pi + (2 * neu)) - /ball:theta);
Set("/ball:vel", /ball:vel + velo);
}
dis = 0;
if (5 >= getProperty("/ball", _y)) {
gotoAndStop (4);
}
if (getProperty("/ball", _y) >= 395) {
gotoAndStop (4);
}
if (getProperty("/ball", _x) >= 395) {
gotoAndStop (4);
}
if (5 >= getProperty("/ball", _x)) {
gotoAndStop (4);
}
Frame 3
score = score + int(/ball:vel + /ball1:vel);
gotoAndPlay (2);
Frame 4
stop();
Instance of Symbol 21 MovieClip in Frame 4
onClipEvent (mouseDown) {
_parent.gotoAndPlay(1);
}
Symbol 15 Button
on (release) {
getURL ("http://www.oidamedia.co.uk", "_blank");
}
Symbol 21 MovieClip Frame 12
stop();