Frame 1
stop();
mysound = new Sound();
mysound.attachSound("ini.mp3");
mysound.start(0, 200);
Frame 9
stop();
Frame 10
stop();
mysound = new Sound();
mysound.attachSound("12.mp3");
mysound.start(0, 200);
Instance of Symbol 74 MovieClip in Frame 10
onClipEvent (load) {
b1x = 2;
b1y = 1;
b2x = 3;
b2y = 2;
b3x = 2;
b3y = 1;
b4x = 1;
b4y = 2;
redlife = 1;
yellowlife = 1;
redhit = 0;
yellowhit = 0;
redcounter = 0;
yellowcounter = 0;
aa = new Sound();
aa.attachSound("105.mp3");
}
onClipEvent (enterFrame) {
if (_root.rbug.hitTest(_root.ybug) == true) {
var xx;
var yy;
xx = _root.rbug._x - _root.ybug._x;
yy = _root.rbug._y - _root.ybug._y;
if (xx < 0) {
_root.rbug._x = _root.rbug._x - 2;
_root.ybug._x = _root.ybug._x + 2;
} else {
_root.rbug._x = _root.rbug._x + 2;
_root.ybug._x = _root.ybug._x - 2;
}
if (yy < 0) {
_root.rbug._y = _root.rbug._y - 2;
_root.ybug._y = _root.ybug._y + 2;
} else {
_root.rbug._y = _root.rbug._y + 2;
_root.ybug._y = _root.ybug._y - 2;
}
}
if ((((_root.rbug.hitTest(_root.ball1) == true) || (_root.rbug.hitTest(_root.ball2) == true)) || (_root.rbug.hitTest(_root.ball3) == true)) || (_root.rbug.hitTest(_root.ball4) == true)) {
if (redcounter == 1) {
_root["rok" + redlife]._visible = false;
redlife = redlife + 1;
aa.start(0, 1);
if (redlife == 8) {
_root.mysound.stop();
_root.gotoAndPlay(20);
}
}
redhit = 1;
}
if (redhit == 1) {
redcounter++;
if (redcounter == 150) {
redcounter = 1;
redhit = 0;
}
_root.rbug._visible = redcounter % 2;
}
if ((((_root.ybug.hitTest(_root.ball1) == true) || (_root.ybug.hitTest(_root.ball2) == true)) || (_root.ybug.hitTest(_root.ball3) == true)) || (_root.ybug.hitTest(_root.ball4) == true)) {
if (yellowcounter == 1) {
_root["yok" + yellowlife]._visible = false;
yellowlife = yellowlife + 1;
aa.start(0, 1);
if (yellowlife == 8) {
_root.mysound.stop();
_root.gotoAndPlay(15);
}
}
yellowhit = 1;
}
if (yellowhit == 1) {
yellowcounter++;
if (yellowcounter == 150) {
yellowcounter = 1;
yellowhit = 0;
}
_root.ybug._visible = yellowcounter % 2;
}
_root.ball1._x = _root.ball1._x - b1x;
_root.ball1._y = _root.ball1._y - b1y;
_root.ball2._x = _root.ball2._x + b2x;
_root.ball2._y = _root.ball2._y - b2y;
_root.ball3._x = _root.ball3._x - b3x;
_root.ball3._y = _root.ball3._y - b3y;
_root.ball4._x = _root.ball4._x + b4x;
_root.ball4._y = _root.ball4._y - b4y;
if (_root.ball1._y < 40) {
_root.ball1._y = 40;
b1y = b1y * -1;
}
if (_root.ball1._y > 360) {
_root.ball1._y = 360;
b1y = b1y * -1;
}
if (_root.ball1._x > 470) {
_root.ball1._x = 470;
b1x = b1x * -1;
}
if (_root.ball1._x < 80) {
_root.ball1._x = 80;
b1x = b1x * -1;
}
if (_root.ball2._y < 40) {
_root.ball2._y = 40;
b2y = b2y * -1;
}
if (_root.ball2._y > 360) {
_root.ball2._y = 360;
b2y = b2y * -1;
}
if (_root.ball2._x > 470) {
_root.ball2._x = 470;
b2x = b2x * -1;
}
if (_root.ball2._x < 80) {
_root.ball2._x = 80;
b2x = b2x * -1;
}
if (_root.ball3._y < 40) {
_root.ball3._y = 40;
b3y = b3y * -1;
}
if (_root.ball3._y > 360) {
_root.ball3._y = 360;
b3y = b3y * -1;
}
if (_root.ball3._x > 470) {
_root.ball3._x = 470;
b3x = b3x * -1;
}
if (_root.ball3._x < 80) {
_root.ball3._x = 80;
b3x = b3x * -1;
}
if (_root.ball4._y < 40) {
_root.ball4._y = 40;
b4y = b4y * -1;
}
if (_root.ball4._y > 360) {
_root.ball4._y = 360;
b4y = b4y * -1;
}
if (_root.ball4._x > 470) {
_root.ball4._x = 470;
b4x = b4x * -1;
}
if (_root.ball4._x < 80) {
_root.ball4._x = 80;
b4x = b4x * -1;
}
if (_root.ball1.hitTest(_root.ball2) == true) {
b1x = b1x * -1;
b2x = b2x * -1;
b1y = b1y * -1;
b2y = b2y * -1;
}
if (_root.ball1.hitTest(_root.ball3) == true) {
b1x = b1x * -1;
b3x = b3x * -1;
b1y = b1y * -1;
b3y = b3y * -1;
}
if (_root.ball1.hitTest(_root.ball4) == true) {
b1x = b1x * -1;
b4x = b4x * -1;
b1y = b1y * -1;
b4y = b4y * -1;
}
if (_root.ball2.hitTest(_root.ball3) == true) {
b2x = b2x * -1;
b3x = b3x * -1;
b2y = b2y * -1;
b3y = b3y * -1;
}
if (_root.ball2.hitTest(_root.ball4) == true) {
b2x = b2x * -1;
b4x = b4x * -1;
b2y = b2y * -1;
b4y = b4y * -1;
}
if (_root.ball3.hitTest(_root.ball4) == true) {
b3x = b3x * -1;
b4x = b4x * -1;
b3y = b3y * -1;
b4y = b4y * -1;
}
}
Instance of Symbol 10 MovieClip "ybug" in Frame 10
onClipEvent (load) {
speed = 3;
}
onClipEvent (enterFrame) {
if (Key.isDown(37) && (!Key.isDown(39))) {
_x = (_x - speed);
_rotation = 270;
}
if (Key.isDown(39) && (!Key.isDown(37))) {
_x = (_x + speed);
_rotation = 90;
}
if (Key.isDown(38) && (!Key.isDown(40))) {
_y = (_y - speed);
_rotation = 0;
}
if (Key.isDown(40) && (!Key.isDown(38))) {
_y = (_y + speed);
_rotation = 180;
}
if (((Key.isDown(37) && (Key.isDown(38))) && (!Key.isDown(39))) && (!Key.isDown(40))) {
_rotation = 315;
}
if (((Key.isDown(39) && (Key.isDown(38))) && (!Key.isDown(37))) && (!Key.isDown(40))) {
_rotation = 45;
}
if (((Key.isDown(37) && (Key.isDown(40))) && (!Key.isDown(39))) && (!Key.isDown(38))) {
_rotation = 225;
}
if (((Key.isDown(39) && (Key.isDown(40))) && (!Key.isDown(37))) && (!Key.isDown(38))) {
_rotation = 135;
}
if (_y < 30) {
_y = 30;
}
if (_y > 370) {
_y = 370;
}
if (_x > 480) {
_x = 480;
}
if (_x < 70) {
_x = 70;
}
}
Instance of Symbol 12 MovieClip "rbug" in Frame 10
onClipEvent (load) {
speed = 3;
}
onClipEvent (enterFrame) {
if (Key.isDown(65) && (!Key.isDown(68))) {
_x = (_x - speed);
_rotation = 270;
}
if (Key.isDown(68) && (!Key.isDown(65))) {
_x = (_x + speed);
_rotation = 90;
}
if (Key.isDown(87) && (!Key.isDown(83))) {
_y = (_y - speed);
_rotation = 0;
}
if (Key.isDown(83) && (!Key.isDown(87))) {
_y = (_y + speed);
_rotation = 180;
}
if (((Key.isDown(65) && (Key.isDown(87))) && (!Key.isDown(68))) && (!Key.isDown(83))) {
_rotation = 315;
}
if (((Key.isDown(68) && (Key.isDown(87))) && (!Key.isDown(65))) && (!Key.isDown(83))) {
_rotation = 45;
}
if (((Key.isDown(65) && (Key.isDown(83))) && (!Key.isDown(68))) && (!Key.isDown(87))) {
_rotation = 225;
}
if (((Key.isDown(68) && (Key.isDown(83))) && (!Key.isDown(65))) && (!Key.isDown(87))) {
_rotation = 135;
}
if (_y < 30) {
_y = 30;
}
if (_y > 370) {
_y = 370;
}
if (_x > 480) {
_x = 480;
}
if (_x < 70) {
_x = 70;
}
}
Frame 15
stop();
abc = new Sound();
abc.attachSound("win.mp3");
abc.start(0, 122);
Frame 20
stop();
abc = new Sound();
abc.attachSound("win.mp3");
abc.start(0, 122);
Symbol 47 Button
on (release) {
_root.mysound.stop();
_root.gotoAndPlay(9);
}
Symbol 57 MovieClip Frame 1
Symbol 57 MovieClip Frame 2
Symbol 57 MovieClip Frame 3
Symbol 57 MovieClip Frame 4
Symbol 57 MovieClip Frame 5
Symbol 57 MovieClip Frame 6
Symbol 57 MovieClip Frame 7
Symbol 57 MovieClip Frame 8
Symbol 57 MovieClip Frame 9
Symbol 57 MovieClip Frame 10
Symbol 64 MovieClip Frame 600
_root.gotoAndPlay(10);
Symbol 96 MovieClip Frame 20
gotoAndPlay (1);
Symbol 97 Button
on (release) {
_root.abc.stop();
gotoAndPlay (9);
}
Symbol 109 MovieClip Frame 10
gotoAndPlay (1);