Frame 1
stop();
Kyle.changeRightClickMenu();
Instance of Symbol 16 MovieClip "titleGrav" in Frame 1
onClipEvent (enterFrame) {
var counter = Math.floor((_root.getBytesLoaded() / _root.getBytesTotal()) * 100);
if (counter >= 100) {
_root.blackFader._visible = true;
_root.blackFader.swapDepths(_root.getNextHighestDepth());
_root.blackFader.play();
}
}
Instance of Symbol 25 MovieClip "trail" in Frame 1
onClipEvent (load) {
i = 0;
if (_name != "trail") {
_x = (_root.titleGrav._x + (127 * Math.sin(_root.titleBall.ball._rotation * (Math.PI/180))));
_y = (_root.titleGrav._y + (-127 * Math.cos(_root.titleBall.ball._rotation * (Math.PI/180))));
}
}
onClipEvent (enterFrame) {
i++;
if (_name == "trail") {
if (i > 5) {
duplicateMovieClip (this, "trai", _root.getNextHighestDepth());
i = 0;
}
}
}
Instance of Symbol 29 MovieClip in Frame 1
on (release) {
getURL ("http://www.armorgames.com/", "_blank");
}
Instance of Symbol 33 MovieClip "blackFader" in Frame 1
onClipEvent (load) {
_visible = false;
}
Frame 4
var muteMusic = false;
var muteSound = false;
var pauseGame = false;
var StageHeight = 400;
var StageWidth = 550;
stopAllSounds();
loopSound = new Sound(this);
loopSound.attachSound("loopSound");
loopSound.start(0, 999);
crashSound = new Sound(this);
crashSound.attachSound("crash");
beepSound = new Sound(this);
beepSound.attachSound("beep");
fireSound = new Sound(this);
fireSound.attachSound("fire");
finishSound = new Sound(this);
finishSound.attachSound("finish");
playSound = new Sound(this);
playSound.attachSound("play");
clickSound = new Sound(this);
clickSound.attachSound("click");
Frame 5
stop();
Instance of Symbol 74 MovieClip in Frame 5
onClipEvent (load) {
if (_root.muteMusic) {
gotoAndStop (2);
} else {
gotoAndStop (1);
}
}
on (release) {
if (_currentframe == 1) {
stopAllSounds();
_root.muteMusic = true;
gotoAndStop (2);
} else if (_currentframe == 2) {
_root.loopSound.start(0, 999);
_root.muteMusic = false;
gotoAndStop (1);
}
}
Instance of Symbol 77 MovieClip in Frame 5
onClipEvent (load) {
if (_root.muteSound) {
gotoAndStop (2);
} else {
gotoAndStop (1);
}
}
on (release) {
if (_currentframe == 1) {
_root.muteSound = true;
gotoAndStop (2);
} else if (_currentframe == 2) {
_root.muteSound = false;
gotoAndStop (1);
}
}
Instance of Symbol 81 MovieClip in Frame 5
onClipEvent (load) {
if (_root._quality == "HIGH") {
this.gotoAndStop(1);
} else if (_root._quality == "MEDIUM") {
this.gotoAndStop(2);
} else if (_root._quality == "LOW") {
this.gotoAndStop(3);
}
}
on (release) {
if (_currentframe == 1) {
_root._quality = "medium";
gotoAndStop (2);
} else if (_currentframe == 2) {
_root._quality = "low";
gotoAndStop (3);
} else if (_currentframe == 3) {
_root._quality = "high";
gotoAndStop (1);
}
}
Instance of Symbol 84 MovieClip in Frame 5
on (release) {
if (!_root.muteSound) {
_root.playSound.start(0, 1);
}
_root.nextFrame();
}
on (rollOver) {
_root.titleGrav.gotoAndStop(2);
}
on (rollOut) {
_root.titleGrav.gotoAndStop(1);
}
Instance of Symbol 25 MovieClip "trail" in Frame 5
onClipEvent (load) {
i = 0;
if (_name != "trail") {
_x = (_root.titleGrav._x + (127 * Math.sin(_root.titleBall.ball._rotation * (Math.PI/180))));
_y = (_root.titleGrav._y + (-127 * Math.cos(_root.titleBall.ball._rotation * (Math.PI/180))));
}
}
onClipEvent (enterFrame) {
i++;
if (_name == "trail") {
if (i > 5) {
duplicateMovieClip (this, "trai", _root.getNextHighestDepth());
i = 0;
}
}
}
Instance of Symbol 87 MovieClip in Frame 5
on (release) {
getURL ("http://www.armorgames.com/", "_blank");
}
Instance of Symbol 90 MovieClip in Frame 5
on (release) {
getURL ("http://www.kchampgames.com/", "_blank");
}
Instance of Symbol 96 MovieClip in Frame 5
onClipEvent (load) {
if (_root.muteSound) {
gotoAndStop (2);
} else {
gotoAndStop (1);
}
}
on (release) {
if (_currentframe == 1) {
_root.muteSound = true;
gotoAndStop (2);
} else if (_currentframe == 2) {
_root.muteSound = false;
gotoAndStop (1);
}
}
Instance of Symbol 99 MovieClip in Frame 5
onClipEvent (load) {
if (_root.muteMusic) {
gotoAndStop (2);
} else {
gotoAndStop (1);
}
}
on (release) {
if (_currentframe == 1) {
stopAllSounds();
_root.muteMusic = true;
gotoAndStop (2);
} else if (_currentframe == 2) {
_root.loopSound.start(0, 999);
_root.muteMusic = false;
gotoAndStop (1);
}
}
Instance of Symbol 101 MovieClip in Frame 5
on (release) {
getURL ("http://armorgames.com/author/kchamp", "_blank");
}
Frame 6
function quitGame() {
_root.gotoAndStop("menu");
}
function resetGame() {
power = 0;
ballAngle = 0;
levelNumber = 1;
_root.gotoAndStop("game");
}
function resetLevel() {
_root.fader.swapDepths(_root.getNextHighestDepth());
_root.fader._visible = true;
_root.fader.play();
_root.gameOn = false;
_root.ball._x = _root.ball.startX;
_root.ball._y = _root.ball.startY;
_root.ball.xspeed = 0;
_root.ball.yspeed = 0;
}
function fire() {
_root.pulser._x = _root.ball._x;
_root.pulser._y = _root.ball._y;
_root.pulser.gotoAndPlay(1);
_root.pen.clear();
_root.pen.moveTo(_root.ball._x, _root.ball._y);
_root.gameOn = true;
_root.lastPower = _root.power;
_root.lastAngle = _root.ballAngle;
_root.ball.xspeed = (power / 10) * Math.sin(ballAngle * (Math.PI/180));
_root.ball.yspeed = ((-1 * power) / 10) * Math.cos(ballAngle * (Math.PI/180));
}
function spawnGravity(number, xpos, ypos, scale) {
duplicateMovieClip (gravity, "gravity" + number, _root.getNextHighestDepth());
_root["gravity" + number]._x = xpos;
_root["gravity" + number]._y = ypos;
_root["gravity" + number]._xscale = _root["gravity" + number]._xscale * scale;
_root["gravity" + number]._yscale = _root["gravity" + number]._yscale * scale;
}
function spawnRepel(number, xpos, ypos, scale) {
duplicateMovieClip (repel, "repel" + number, _root.getNextHighestDepth());
_root["repel" + number]._x = xpos;
_root["repel" + number]._y = ypos;
_root["repel" + number]._xscale = _root["repel" + number]._xscale * scale;
_root["repel" + number]._yscale = _root["repel" + number]._yscale * scale;
}
function spawnBlock(number, xpos, ypos, Width, Height) {
duplicateMovieClip (block, "block" + number, _root.getNextHighestDepth());
_root["block" + number]._x = xpos;
_root["block" + number]._y = ypos;
_root["block" + number]._width = Width;
_root["block" + number]._height = Height;
}
function nextLevel() {
clearPlanets();
levelNumber++;
_root.lastPower = 0;
_root.lastAngle = 0;
if (levelNumber == 1) {
_root.ball._x = 160;
_root.ball._y = 250;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 500;
_root.finishCircle._y = 250;
}
if (levelNumber == 2) {
_root.ball._x = 160;
_root.ball._y = 250;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 500;
_root.finishCircle._y = 250;
spawnGravity(0, 340, 380, 1);
}
if (levelNumber == 3) {
_root.ball._x = 160;
_root.ball._y = 235;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 525;
_root.finishCircle._y = 235;
spawnGravity(0, 340, 235, 1.5);
}
if (levelNumber == 4) {
_root.ball._x = 50;
_root.ball._y = 80;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 650;
_root.finishCircle._y = 395;
spawnBlock(0, 347, 258, 20, 100);
spawnBlock(1, 347, 118, 20, 100);
}
if (levelNumber == 5) {
_root.ball._x = 140;
_root.ball._y = 435;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 575;
_root.finishCircle._y = 405;
spawnBlock(0, 90, 470, 200, 20);
spawnBlock(1, 330, 290, 50, 200);
spawnGravity(0, 355, 300, 1.5);
}
if (levelNumber == 6) {
_root.ball._x = 65;
_root.ball._y = 225;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 630;
_root.finishCircle._y = 235;
spawnGravity(0, 200, 70, 2);
spawnGravity(1, 365, 405, 1.5);
spawnGravity(2, 505, 70, 2);
}
if (levelNumber == 7) {
_root.ball._x = 350;
_root.ball._y = 410;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 350;
_root.finishCircle._y = 100;
spawnGravity(0, 350, 250, 1);
spawnGravity(1, 265, 220, 1);
spawnGravity(2, 435, 220, 1);
}
if (levelNumber == 8) {
_root.ball._x = 150;
_root.ball._y = 250;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 530;
_root.finishCircle._y = 250;
spawnRepel(0, 340, 110, 1);
}
if (levelNumber == 9) {
_root.ball._x = 110;
_root.ball._y = 70;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 590;
_root.finishCircle._y = 70;
spawnGravity(0, 350, 90, 1);
spawnRepel(0, 350, 300, 1);
}
if (levelNumber == 10) {
_root.ball._x = 530;
_root.ball._y = 410;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 80;
_root.finishCircle._y = 80;
spawnBlock(0, 330, 440, 200, 20);
spawnBlock(1, 490, 10, 200, 20);
spawnGravity(0, 250, 220, 0.5);
spawnGravity(1, 250, 360, 0.5);
spawnGravity(2, 450, 120, 0.5);
spawnGravity(3, 450, 260, 0.5);
spawnRepel(0, 250, 290, 0.5);
spawnRepel(1, 250, 430, 0.5);
spawnRepel(2, 450, 50, 0.5);
spawnRepel(3, 450, 190, 0.5);
}
if (levelNumber == 11) {
_root.ball._x = 30;
_root.ball._y = 450;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 510;
_root.finishCircle._y = 320;
spawnBlock(0, 10, 470, 200, 20);
spawnBlock(1, 225, 290, 50, 200);
spawnBlock(2, 425, 290, 50, 200);
spawnGravity(0, 350, 50, 1);
spawnGravity(1, 350, 330, 1);
spawnGravity(2, 350, 440, 1);
}
if (levelNumber == 12) {
_root.ball._x = 60;
_root.ball._y = 280;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 640;
_root.finishCircle._y = 270;
spawnBlock(0, 340, 260, 20, 20);
spawnGravity(0, 210, 160, 1);
spawnGravity(1, 410, 160, 1);
spawnGravity(2, 550, 210, 0.5);
spawnGravity(3, 310, 380, 1);
spawnGravity(4, 500, 380, 1);
spawnRepel(0, 310, 160, 1);
spawnRepel(1, 510, 160, 1);
spawnRepel(2, 210, 380, 1);
spawnRepel(3, 410, 380, 1);
spawnRepel(4, 550, 330, 0.5);
}
if (levelNumber == 13) {
_root.ball._x = 360;
_root.ball._y = 430;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 360;
_root.finishCircle._y = 200;
spawnGravity(0, 120, 260, 0.5);
spawnGravity(1, 210, 260, 0.5);
spawnGravity(2, 290, 260, 0.5);
spawnGravity(3, 360, 260, 0.5);
spawnGravity(4, 430, 260, 0.5);
spawnGravity(5, 510, 260, 0.5);
spawnGravity(6, 600, 260, 0.5);
}
if (levelNumber == 14) {
_root.ball._x = 640;
_root.ball._y = 440;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 70;
_root.finishCircle._y = 110;
spawnBlock(0, 440, 330, 20, 150);
spawnBlock(1, 470, 460, 200, 20);
spawnRepel(0, 410, 260, 1.5);
spawnGravity(0, 240, 260, 2);
}
if (levelNumber == 15) {
_root.ball._x = 70;
_root.ball._y = 230;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 630;
_root.finishCircle._y = 240;
spawnGravity(0, 160, 160, 1.5);
spawnGravity(1, 140, 390, 1);
spawnGravity(2, 440, 30, 3);
spawnGravity(3, 345, 360, 1.5);
spawnGravity(4, 560, 410, 0.5);
}
if (levelNumber == 16) {
_root.ball._x = 30;
_root.ball._y = 330;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 630;
_root.finishCircle._y = 350;
spawnBlock(0, 10, 455, 100, 30);
spawnBlock(1, 125, -20, 30, 300);
spawnBlock(2, 125, 360, 30, 120);
spawnBlock(3, 365, -45, 30, 250);
spawnBlock(4, 365, 290, 30, 200);
spawnBlock(5, 655, 80, 30, 400);
spawnGravity(0, 190, 190, 0.5);
spawnGravity(1, 450, 450, 0.5);
}
if (levelNumber == 17) {
_root.ball._x = 80;
_root.ball._y = 400;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 640;
_root.finishCircle._y = 230;
spawnBlock(0, 65, 450, 200, 20);
spawnBlock(1, 335, 390, 30, 80);
spawnGravity(0, 350, 180, 4);
}
if (levelNumber == 18) {
_root.ball._x = 295;
_root.ball._y = 280;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 460;
_root.finishCircle._y = 200;
spawnBlock(0, 25, 20, 150, 20);
spawnBlock(0, 345, 200, 10, 200);
spawnGravity(0, 350, 50, 3);
spawnRepel(0, 150, 445, 1);
}
if (levelNumber == 19) {
_root.ball._x = 350;
_root.ball._y = 120;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 350;
_root.finishCircle._y = 260;
spawnGravity(0, 350, 190, 1);
spawnGravity(1, 350, 330, 1);
}
if (levelNumber == 20) {
_root.ball._x = 640;
_root.ball._y = 360;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 230;
_root.finishCircle._y = 420;
spawnBlock(0, 110, 450, 300, 20);
spawnBlock(1, 160, 165, 20, 150);
spawnBlock(2, 220, 100, 300, 20);
spawnBlock(3, 570, 155, 20, 150);
spawnBlock(4, 400, 265, 20, 150);
spawnBlock(5, 535, 420, 150, 20);
spawnRepel(0, 70, 390, 1);
spawnRepel(1, 200, 150, 1);
spawnRepel(2, 370, 30, 1);
spawnRepel(3, 550, 150, 1);
spawnRepel(4, 470, 400, 1);
}
if (levelNumber == 21) {
_root.ball._x = 80;
_root.ball._y = 340;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 580;
_root.finishCircle._y = 410;
spawnGravity(0, 180, 250, 1);
spawnGravity(1, 180, 430, 1);
spawnGravity(2, 400, 250, 1);
spawnGravity(3, 400, 430, 1);
spawnGravity(4, 610, 60, 1);
spawnGravity(5, 640, 460, 1);
spawnRepel(0, 290, 250, 1);
spawnRepel(1, 290, 430, 1);
spawnRepel(2, 510, 430, 1);
}
if (levelNumber == 22) {
_root.ball._x = 360;
_root.ball._y = 420;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 360;
_root.finishCircle._y = 210;
spawnBlock(0, 320, 240, 100, 20);
spawnGravity(0, 290, 250, 0.5);
spawnGravity(1, 570, 100, 2);
}
if (levelNumber == 23) {
_root.ball._x = 300;
_root.ball._y = 420;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 440;
_root.finishCircle._y = 390;
spawnBlock(0, 260, 235, 100, 30);
spawnBlock(1, 350, 310, 20, 120);
spawnRepel(0, 170, 250, 2);
spawnRepel(1, 480, 220, 1);
spawnRepel(2, 580, 310, 1);
}
if (levelNumber == 24) {
_root.ball._x = 630;
_root.ball._y = 440;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 190;
_root.finishCircle._y = 160;
spawnBlock(0, 315, 365, 50, 50);
spawnRepel(0, 120, 120, 0.5);
spawnRepel(1, 190, 450, 1);
spawnRepel(2, 690, 240, 2);
spawnGravity(0, 90, 320, 1);
spawnGravity(1, 290, 250, 1.5);
spawnGravity(2, 480, 60, 3);
spawnGravity(3, 490, 350, 0.5);
}
if (levelNumber == 25) {
_root.ball._x = 650;
_root.ball._y = 330;
_root.ball.startX = _root.ball._x;
_root.ball.startY = _root.ball._y;
_root.finishCircle._x = 230;
_root.finishCircle._y = 450;
spawnBlock(0, 255, 230, 50, 20);
spawnBlock(1, 210, 380, 100, 20);
spawnBlock(2, 460, 460, 200, 20);
spawnBlock(3, 670, 280, 20, 200);
spawnRepel(0, 70, 300, 1.5);
spawnRepel(1, 160, 300, 0.5);
spawnRepel(2, 180, 20, 0.75);
spawnRepel(3, 410, 430, 1);
spawnRepel(4, 630, 100, 1);
spawnGravity(0, 100, 410, 1);
spawnGravity(1, 260, 90, 2);
spawnGravity(2, 350, 180, 1.5);
spawnGravity(3, 510, 390, 0.5);
spawnGravity(4, 580, 220, 0.5);
}
if (levelNumber == 26) {
removeMovieClip(_root.boundaryTracker);
_root.cleanUp();
_root.gotoAndStop("results");
}
resetLevel();
_root.score_mc.swapDepths(_root.getNextHighestDepth());
_root.level_mc.swapDepths(_root.getNextHighestDepth());
_root.pen.clear();
_root.power = 0;
_root.ballAngle = 0;
_root.powerSetter.slider._x = 0;
_root.powerSetter.power_txt.text = 0;
_root.angleSetter.angleArrow._rotation = 0;
_root.angleSetter.angle_txt.text = 0;
}
function clearPlanets() {
i = 0;
while (i < 25) {
removeMovieClip(_root["gravity" + i]);
removeMovieClip(_root["repel" + i]);
removeMovieClip(_root["block" + i]);
i++;
}
}
function cleanUp() {
clearPlanets();
removeMovieClip(_root.score_mc);
removeMovieClip(_root.level_mc);
}
stop();
var gameOn = false;
var power = 0;
var ballAngle = 0;
var lastPower = 0;
var lastAngle = 0;
var score = 0;
var sparkC = 0;
var levelNumber = 0;
var playerName = "Unnamed";
nextLevel();
onEnterFrame = function () {
score_mc.score_txt.text = "Score: " + Kyle.addCommas(_root.score);
level_mc.level_txt.text = ("Level: " + levelNumber) + "/25";
lastShot_txt.text = (("Power: " + _root.lastPower) + " , Angle: ") + _root.lastAngle;
if (Key.isDown(38)) {
if (_root.power < 100) {
_root.power++;
_root.powerSetter.slider._x = _root.powerSetter.slider._x + 2;
}
}
if (Key.isDown(40)) {
if (_root.power > 0) {
_root.power--;
_root.powerSetter.slider._x = _root.powerSetter.slider._x - 2;
}
}
if (Key.isDown(37)) {
if (_root.ballAngle >= 1) {
_root.ballAngle--;
} else {
_root.ballAngle = 359;
}
_root.angleSetter.angleArrow._rotation--;
_root.angleSetter.angle_txt.text = _root.ballAngle;
}
if (Key.isDown(39)) {
if (_root.ballAngle <= 359) {
_root.ballAngle++;
} else {
_root.ballAngle = 0;
}
_root.angleSetter.angleArrow._rotation++;
_root.angleSetter.angle_txt.text = _root.ballAngle;
}
if (Key.isDown(32)) {
if (!_root.gameOn) {
if (_root.power > 0) {
if (!_root.muteSound) {
_root.fireSound.start(0, 1);
}
_root.fire();
}
}
}
if (Key.isDown(82)) {
if (_root.gameOn) {
if (!_root.muteSound) {
_root.beepSound.start(0, 1);
}
_root.resetLevel();
_root.minusTen._visible = true;
_root.minusTen.play();
_root.score = _root.score - 10;
}
}
};
Instance of Symbol 117 MovieClip "powerSetter" in Frame 6
onClipEvent (enterFrame) {
_root.power = Math.round(slider._x / 2);
power_txt.text = _root.power;
}
Instance of Symbol 126 MovieClip "angleSetter" in Frame 6
onClipEvent (load) {
var tempX = 0;
var active = false;
var mouseListener = new Object();
mouseListener.onMouseDown = function () {
this.isDown = true;
};
mouseListener.onMouseUp = function () {
this.isDown = false;
};
Mouse.addListener(mouseListener);
}
onClipEvent (enterFrame) {
if (mouseListener.isDown == false) {
active = false;
Mouse.show();
}
if (active) {
_root.ballAngle = _root.ballAngle - (tempX - Math.round(_root._xmouse));
tempX = Math.round(_root._xmouse);
if (_root.ballAngle < 0) {
_root.ballAngle = _root.ballAngle + 360;
}
if (_root.ballAngle > 360) {
_root.ballAngle = _root.ballAngle - 360;
}
angleArrow._rotation = _root.ballAngle;
angle_txt.text = _root.ballAngle;
}
}
on (press) {
active = true;
tempX = _root._xmouse;
Mouse.hide();
}
Instance of Symbol 137 MovieClip "tracerLine" in Frame 6
onClipEvent (enterFrame) {
if (_root.gameOn) {
_visible = false;
} else {
_visible = true;
}
_x = _root.ball._x;
_y = _root.ball._y;
lineBox._y = -20 - (_root.power * 2);
_rotation = _root.ballAngle;
}
Instance of Symbol 25 MovieClip "trail" in Frame 6
onClipEvent (load) {
i = 0;
if (_name != "trail") {
_x = _root.ball._x;
_y = _root.ball._y;
}
}
onClipEvent (enterFrame) {
i++;
if (_name == "trail") {
if (i > 5) {
if (_root.gameOn) {
duplicateMovieClip (this, "trai", _root.getNextHighestDepth());
i = 0;
}
}
}
}
Instance of Symbol 139 MovieClip "pen" in Frame 6
onClipEvent (load) {
_x = 0;
_y = 0;
}
onClipEvent (enterFrame) {
lineStyle(1, 3355443, 100);
if (_root.gameOn) {
lineTo(_root.ball._x, _root.ball._y);
} else {
moveTo(_root.ball._x, _root.ball._y);
}
}
Instance of Symbol 152 MovieClip "boundaryTracker" in Frame 6
onClipEvent (load) {
stop();
}
onClipEvent (enterFrame) {
if (((_root.ball._y < 0) and (_root.ball._x > 0)) and (_root.ball._x < 700)) {
swapDepths(_root.getNextHighestDepth());
gotoAndStop (1);
_y = 10;
_x = _root.ball._x;
textBox.distance.text = -Math.round(_root.ball._y);
}
if ((_root.ball._y < 0) and (_root.ball._x > 700)) {
swapDepths(_root.getNextHighestDepth());
gotoAndStop (2);
_y = 10;
_x = 690;
textBox.distance.text = (-Math.round(_root.ball._y)) + Math.round(_root.ball._x - 700);
}
if (((_root.ball._x > 700) and (_root.ball._y > 0)) and (_root.ball._y < 500)) {
swapDepths(_root.getNextHighestDepth());
gotoAndStop (3);
_y = _root.ball._y;
_x = 690;
textBox.distance.text = Math.round(_root.ball._x - 700);
}
if ((_root.ball._x > 700) and (_root.ball._y > 500)) {
swapDepths(_root.getNextHighestDepth());
gotoAndStop (4);
_y = 490;
_x = 690;
textBox.distance.text = Math.round(_root.ball._x - 700) + Math.round(_root.ball._y - 500);
}
if (((_root.ball._y > 500) and (_root.ball._x > 0)) and (_root.ball._x < 700)) {
swapDepths(_root.getNextHighestDepth());
gotoAndStop (5);
_y = 490;
_x = _root.ball._x;
textBox.distance.text = Math.round(_root.ball._y - 500);
}
if ((_root.ball._y > 500) and (_root.ball._x < 0)) {
swapDepths(_root.getNextHighestDepth());
gotoAndStop (6);
_y = 490;
_x = 10;
textBox.distance.text = Math.round(_root.ball._y - 500) + (-Math.round(_root.ball._x));
}
if (((_root.ball._x < 0) and (_root.ball._y > 0)) and (_root.ball._y < 500)) {
swapDepths(_root.getNextHighestDepth());
gotoAndStop (7);
_y = _root.ball._y;
_x = 10;
textBox.distance.text = -Math.round(_root.ball._x);
}
if ((_root.ball._x < 0) and (_root.ball._y < 0)) {
swapDepths(_root.getNextHighestDepth());
gotoAndStop (8);
_y = 10;
_x = 10;
textBox.distance.text = (-Math.round(_root.ball._x)) + (-Math.round(_root.ball._y));
}
if ((((_root.ball._x > 0) and (_root.ball._x < 700)) and (_root.ball._y > 0)) and (_root.ball._y < 500)) {
_y = -500;
_x = -500;
}
}
Instance of Symbol 160 MovieClip "finishCircle" in Frame 6
onClipEvent (enterFrame) {
if (Kyle.circleCollide(this, _root.ball)) {
if (!_root.muteSound) {
_root.finishSound.start(0, 1);
}
_root.plusHundred._visible = true;
_root.plusHundred.play();
_root.score = _root.score + 100;
_root.nextLevel();
}
}
Instance of Symbol 18 MovieClip "ball" in Frame 6
onClipEvent (load) {
var xspeed = 0;
var yspeed = 0;
var startX = _x;
var startY = _y;
}
onClipEvent (enterFrame) {
_x = (_x + xspeed);
_y = (_y + yspeed);
xspeed = xspeed * 0.999;
yspeed = yspeed * 0.999;
}
Instance of Symbol 175 MovieClip "minusTen" in Frame 6
onClipEvent (load) {
_visible = false;
}
Instance of Symbol 179 MovieClip "plusHundred" in Frame 6
onClipEvent (load) {
_visible = false;
}
Instance of Symbol 189 MovieClip "instructions" in Frame 6
onClipEvent (enterFrame) {
gotoAndStop(_root.levelNumber);
}
Instance of Symbol 196 MovieClip "youSure" in Frame 6
onClipEvent (load) {
_visible = false;
}
Frame 7
stop();
onEnterFrame = function () {
_root.score_txt.text = Kyle.addCommas(_root.score);
};
Instance of Symbol 210 MovieClip "enterName" in Frame 7
onClipEvent (load) {
_visible = false;
}
Frame 8
function __rankz_send__(par1, par2, par3, par4) {
par227 = new LoadVars();
par228 = new LoadVars();
par227.flashkey = par2;
par227.SU0249 = par1;
par227.bmFtZTE = ab3.rankz.Armor_Bot_30_En_AS1.Encode(par3);
par227.c2NvcmUx = ab3.rankz.Armor_Bot_30_En_AS1.Encode(par4 + "j%e%a%n%s");
par227.flashkey = par227.flashkey.split("=").join("");
par227.SU0249 = par227.SU0249.split("=").join("");
par228.onLoad = function (success) {
if (success) {
trace(par228.msg);
} else {
trace(par228.loaded);
}
};
par227.sendAndLoad("http://rankz.armorbot.com/submit/", par228, "POST");
}
bXlnYW1lX25hbWVfdmFyaWFibGU = _root.playerName;
bXlnYW1lX3Njb3JlX3ZhcmlhYmxl = _root.score;
__rankz_send__("MzE1M2olZSVhJW4lcw==", "SWxLTkJGeVA=", bXlnYW1lX25hbWVfdmFyaWFibGU, bXlnYW1lX3Njb3JlX3ZhcmlhYmxl);
getURL ("http://www.rankz.armorbot.com/Gravitex/", "_blank");
gotoAndStop ("menu");
Frame 9
gotoAndStop ("menu");
Instance of Symbol 160 MovieClip "finish" in Frame 16
onClipEvent (enterFrame) {
if (Kyle.circleCollide(this, _root.ball)) {
trace("win");
}
if (Kyle.circleCollide(this, _root.ball)) {
this._visible = false;
}
}
Instance of Symbol 18 MovieClip "ball" in Frame 16
onClipEvent (load) {
var xspeed = 0;
var yspeed = 0;
var startX = _x;
var startY = _y;
}
onClipEvent (enterFrame) {
_x = (_x + xspeed);
_y = (_y + yspeed);
xspeed = xspeed * 0.997;
yspeed = yspeed * 0.997;
}
Instance of Symbol 18 MovieClip "ball" in Frame 20
onClipEvent (load) {
var xspeed = 0;
var yspeed = 0;
var startX = _x;
var startY = _y;
}
onClipEvent (enterFrame) {
_x = (_x + xspeed);
_y = (_y + yspeed);
xspeed = xspeed * 0.999;
yspeed = yspeed * 0.999;
}
Symbol 9 MovieClip [sparklet] Frame 1
if (_name == "sparklet") {
stop();
}
Symbol 9 MovieClip [sparklet] Frame 11
removeMovieClip(this);
Symbol 16 MovieClip Frame 1
stop();
Symbol 16 MovieClip Frame 2
stop();
Instance of Symbol 19 MovieClip "ball" in Symbol 20 MovieClip Frame 1
onClipEvent (enterFrame) {
_rotation = (_rotation + 4);
}
Symbol 25 MovieClip Frame 50
removeMovieClip(this);
Symbol 33 MovieClip Frame 1
stop();
Symbol 33 MovieClip Frame 35
_root.play();
Symbol 33 MovieClip Frame 70
removeMovieClip(this);
Symbol 236 MovieClip [__Packages.Kyle] Frame 0
class Kyle
{
function Kyle () {
}
static function rotateToMouse(object) {
var _local5 = object._x - _root._xmouse;
var _local4 = object._y - _root._ymouse;
var _local2 = Math.atan2(_local4, _local5);
var _local3 = _local2 * 57.2957795130823;
object._rotation = _local3 - 90;
}
static function rotateTo(object1, object2) {
var _local4 = object1._x - object2._x;
var _local3 = object1._y - object2._y;
var _local1 = Math.atan2(_local3, _local4);
var _local2 = _local1 * 57.2957795130823;
object1._rotation = _local2 - 90;
}
static function getAngle(object1, object2) {
var _local4 = object1._x - object2._x;
var _local3 = object1._y - object2._y;
var _local1 = Math.atan2(_local3, _local4);
var _local2 = _local1 * 57.2957795130823;
return(_local2 - 90);
}
static function getDistance(object1, object2) {
return(Math.sqrt(Math.pow(Math.abs(object1._y - object2._y), 2) + Math.pow(Math.abs(object1._x - object2._x), 2)));
}
static function circleCollide(object1, object2) {
var _local1 = Math.sqrt(Math.pow(Math.abs(object1._y - object2._y), 2) + Math.pow(Math.abs(object1._x - object2._x), 2));
var _local2 = (object1._width / 2) + (object2._width / 2);
if (_local1 < _local2) {
return(true);
}
return(false);
}
static function addCommas(n) {
var _local1 = n.toString();
var _local3 = 1;
if (_local1.indexOf(".") == -1) {
var _local2 = "";
_local1 = _local1.split("");
} else {
var _local2 = _local1.substr(_local1.indexOf("."), _local1.length);
_local1 = _local1.substr(0, _local1.indexOf(".")).split("");
}
for (var _local4 in _local1) {
var _local2 = _local1[_local4] + _local2;
if ((_local3++) == 3) {
_local3 = 1;
_local2 = (((isNaN(_local1[0]) && (_local4 > 1)) || ((!isNaN(_local1[0])) && (_local4 >= 1))) ? ("," + _local2) : (_local2));
}
}
return(_local2);
}
static function siteLock(domainName) {
var _local2 = _url.indexOf("://") + 3;
var _local6 = _url.indexOf("/", _local2);
var _local3 = _url.substring(_local2, _local6);
var _local5 = _local3.lastIndexOf(".") - 1;
var _local4 = _local3.lastIndexOf(".", _local5) + 1;
_local3 = _local3.substring(_local4, _local3.length);
if (_local3 != domainName) {
_root._x = 50000;
_root._y = 40000;
}
}
static function changeRightClickMenu() {
function menuChoiceOne() {
getURL ("http://www.kchampgames.com");
}
var _local2 = new ContextMenu();
_local2.hideBuiltInItems();
_local2.customItems.push(new ContextMenuItem("kChamp Games", menuChoiceOne));
_root.menu = _local2;
}
}
Symbol 237 MovieClip [__Packages.ab3.rankz.Armor_Bot_30_En_AS1] Frame 0
class ab3.rankz.Armor_Bot_30_En_AS1 extends Object
{
static var _CharsReverseLookup;
var _Armor_Bot_30_En_AS1Str, _Armor_Bot_30_En_AS1Count;
function Armor_Bot_30_En_AS1 () {
super();
}
static function Encode(str) {
var _local1 = new ab3.rankz.Armor_Bot_30_En_AS1();
return(_local1.encodeArmor_Bot_30_En_AS1(str));
}
static function Decode(str) {
var _local1 = new ab3.rankz.Armor_Bot_30_En_AS1();
return(_local1.decodeArmor_Bot_30_En_AS1(str));
}
static function StringReplaceAll(source, find, replacement) {
return(source.split(find).join(replacement));
}
static function InitReverseChars() {
_CharsReverseLookup = new Array();
var _local1 = 0;
while (_local1 < _Chars.length) {
_CharsReverseLookup[_Chars[_local1]] = _local1;
_local1++;
}
return(true);
}
static function UrlDecode(str) {
str = StringReplaceAll(str, "\\", " ");
str = unescape(str);
return(str);
}
static function UrlEncode(str) {
str = escape(str);
str = StringReplaceAll(str, "\\", "%2B");
str = StringReplaceAll(str, "%20", "+");
return(str);
}
function setArmor_Bot_30_En_AS1Str(str) {
_Armor_Bot_30_En_AS1Str = str;
_Armor_Bot_30_En_AS1Count = 0;
}
function readArmor_Bot_30_En_AS1() {
if (!_Armor_Bot_30_En_AS1Str) {
return(_EndOfInput);
}
if (_Armor_Bot_30_En_AS1Count >= _Armor_Bot_30_En_AS1Str.length) {
return(_EndOfInput);
}
var _local2 = _Armor_Bot_30_En_AS1Str.charCodeAt(_Armor_Bot_30_En_AS1Count) & 255;
_Armor_Bot_30_En_AS1Count++;
return(_local2);
}
function encodeArmor_Bot_30_En_AS1(str) {
setArmor_Bot_30_En_AS1Str(str);
var _local3 = "";
var _local2 = new Array(3);
var _local5 = 0;
var _local4 = false;
while ((!_local4) && (((_local2[0] = readArmor_Bot_30_En_AS1())) != _EndOfInput)) {
_local2[1] = readArmor_Bot_30_En_AS1();
_local2[2] = readArmor_Bot_30_En_AS1();
_local3 = _local3 + _Chars[_local2[0] >> 2];
if (_local2[1] != _EndOfInput) {
_local3 = _local3 + _Chars[((_local2[0] << 4) & 48) | (_local2[1] >> 4)];
if (_local2[2] != _EndOfInput) {
_local3 = _local3 + _Chars[((_local2[1] << 2) & 60) | (_local2[2] >> 6)];
_local3 = _local3 + _Chars[_local2[2] & 63];
} else {
_local3 = _local3 + _Chars[(_local2[1] << 2) & 60];
_local3 = _local3 + "=";
_local4 = true;
}
} else {
_local3 = _local3 + _Chars[(_local2[0] << 4) & 48];
_local3 = _local3 + "=";
_local3 = _local3 + "=";
_local4 = true;
}
_local5 = _local5 + 4;
if (_local5 >= 76) {
_local3 = _local3 + newline;
_local5 = 0;
}
}
return(_local3);
}
function readReverseArmor_Bot_30_En_AS1() {
if (!_Armor_Bot_30_En_AS1Str) {
return(_EndOfInput);
}
while (true) {
if (_Armor_Bot_30_En_AS1Count >= _Armor_Bot_30_En_AS1Str.length) {
return(_EndOfInput);
}
var _local2 = _Armor_Bot_30_En_AS1Str.charAt(_Armor_Bot_30_En_AS1Count);
_Armor_Bot_30_En_AS1Count++;
if (_CharsReverseLookup[_local2]) {
return(_CharsReverseLookup[_local2]);
}
if (_local2 == "A") {
return(0);
}
}
}
function ntos(n) {
var _local1 = n.toString(16);
if (_local1.length == 1) {
_local1 = "0" + _local1;
}
_local1 = "%" + _local1;
return(unescape(_local1));
}
function decodeArmor_Bot_30_En_AS1(str) {
setArmor_Bot_30_En_AS1Str(str);
var _local3 = "";
var _local2 = new Array(4);
var _local4 = false;
while (((!_local4) && (((_local2[0] = readReverseArmor_Bot_30_En_AS1())) != _EndOfInput)) && (((_local2[1] = readReverseArmor_Bot_30_En_AS1())) != _EndOfInput)) {
_local2[2] = readReverseArmor_Bot_30_En_AS1();
_local2[3] = readReverseArmor_Bot_30_En_AS1();
_local3 = _local3 + ntos(((_local2[0] << 2) & 255) | (_local2[1] >> 4));
if (_local2[2] != _EndOfInput) {
_local3 = _local3 + ntos(((_local2[1] << 4) & 255) | (_local2[2] >> 2));
if (_local2[3] != _EndOfInput) {
_local3 = _local3 + ntos(((_local2[2] << 6) & 255) | _local2[3]);
} else {
_local4 = true;
}
} else {
_local4 = true;
}
}
return(_local3);
}
function toHex(n) {
var _local4 = "";
var _local3 = true;
var _local1 = 32;
while (_local1 > 0) {
_local1 = _local1 - 4;
var _local2 = (n >> _local1) & 15;
if ((!_local3) || (_local2 != 0)) {
_local3 = false;
_local4 = _local4 + _Digits[_local2];
}
}
return(((_local4 == "") ? "0" : (_local4)));
}
function pad(str, len, pad) {
var _local2 = str;
var _local1 = str.length;
while (_local1 < len) {
_local2 = pad + _local2;
_local1++;
}
return(_local2);
}
function encodeHex(str) {
var _local4 = "";
var _local2 = 0;
while (_local2 < str.length) {
_local4 = _local4 + pad(toHex(str.charCodeAt(_local2) & 255), 2, "0");
_local2++;
}
return(_local4);
}
function decodeHex(str) {
var _local5 = "";
var _local3 = "";
var _local2 = 0;
while (_local2 < str.length) {
_local3 = _local3 + str.charAt(_local2);
if (_local3.length == 2) {
_local5 = _local5 + ntos(parseInt("0x" + _local3));
_local3 = "";
}
_local2++;
}
return(_local5);
}
static var _EndOfInput = -1;
static var _Chars = new Array("A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "+", "/");
static var _CharsReverseLookupInited = InitReverseChars();
static var _Digits = new Array("0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "a", "b", "c", "d", "e", "f");
}
Symbol 52 Button
on (press) {
getURL ("http://www.armorgames.com", "_blank");
}
Symbol 55 MovieClip Frame 1
_root.stop();
gotoAndPlay (2);
Symbol 55 MovieClip Frame 218
_root.play();
Symbol 67 MovieClip Frame 1
_root.stop();
gotoAndPlay (2);
Instance of Symbol 63 MovieClip in Symbol 67 MovieClip Frame 26
on (release) {
getURL ("http://www.kchampgames.com", "_blank");
}
Symbol 67 MovieClip Frame 181
_root.play();
Symbol 74 MovieClip Frame 1
stop();
Symbol 74 MovieClip Frame 2
stop();
Symbol 77 MovieClip Frame 1
stop();
Symbol 77 MovieClip Frame 2
stop();
Symbol 93 Button
on (release) {
getURL ("http://www.armorgames.com/", "_blank");
}
Symbol 104 Button
on (release) {
_root.youSure._visible = true;
}
Symbol 113 Button
on (release) {
if (_root.power >= 1) {
if (!_root.muteSound) {
_root.clickSound.start(0, 1);
}
_root.power--;
_root.powerSetter.slider._x = _root.powerSetter.slider._x - 2;
}
}
Symbol 116 Button
on (release) {
if (_root.power <= 99) {
if (!_root.muteSound) {
_root.clickSound.start(0, 1);
}
_root.power++;
_root.powerSetter.slider._x = _root.powerSetter.slider._x + 2;
}
}
Instance of Symbol 108 MovieClip "slider" in Symbol 117 MovieClip Frame 1
onClipEvent (load) {
var active = false;
var mouseListener = new Object();
mouseListener.onMouseDown = function () {
this.isDown = true;
};
mouseListener.onMouseUp = function () {
this.isDown = false;
};
Mouse.addListener(mouseListener);
}
onClipEvent (enterFrame) {
if (mouseListener.isDown == false) {
active = false;
}
if (active) {
_x = ((_root._xmouse - _parent._x) - 5);
}
if (_x < 0) {
_x = 0;
}
if (_x > 200) {
_x = 200;
}
}
on (press) {
active = true;
}
Symbol 121 Button
on (release) {
if (!_root.gameOn) {
if (_root.power > 0) {
if (!_root.muteSound) {
_root.fireSound.start(0, 1);
}
_root.fire();
}
}
}
Symbol 130 Button
on (release) {
if (_root.gameOn) {
if (!_root.muteSound) {
_root.beepSound.start(0, 1);
}
_root.resetLevel();
_root.minusTen._visible = true;
_root.minusTen.play();
_root.score = _root.score - 10;
}
}
Symbol 131 Button
on (release) {
if (!_root.muteSound) {
_root.clickSound.start(0, 1);
}
if (_root.ballAngle >= 1) {
_root.ballAngle--;
} else {
_root.ballAngle = 359;
}
_root.angleSetter.angleArrow._rotation--;
_root.angleSetter.angle_txt.text = _root.ballAngle;
}
Symbol 132 Button
on (release) {
if (!_root.muteSound) {
_root.clickSound.start(0, 1);
}
if (_root.ballAngle <= 359) {
_root.ballAngle++;
} else {
_root.ballAngle = 1;
}
_root.angleSetter.angleArrow._rotation++;
_root.angleSetter.angle_txt.text = _root.ballAngle;
}
Instance of Symbol 14 MovieClip in Symbol 140 MovieClip Frame 1
onClipEvent (load) {
var mass = (_parent._width / 75);
}
onClipEvent (enterFrame) {
var gravityDirection = Kyle.getAngle(_parent, _root.ball);
var distanceToBall = Kyle.getDistance(_parent, _root.ball);
if (_root.gameOn) {
if (_parent._name != "gravity") {
_root.ball.xspeed = _root.ball.xspeed + ((((-1 * mass) * Math.sin(gravityDirection * (Math.PI/180))) * (1 / distanceToBall)) * 25);
_root.ball.yspeed = _root.ball.yspeed + (((mass * Math.cos(gravityDirection * (Math.PI/180))) * (1 / distanceToBall)) * 25);
}
}
if (Kyle.circleCollide(_parent, _root.ball)) {
if (_parent._name != "gravity") {
if (!_root.muteSound) {
_root.crashSound.start(0, 1);
}
_root.minusTen._visible = true;
_root.minusTen.play();
_root.score = _root.score - 10;
i = 0;
while (i < 5) {
duplicateMovieClip (_root.sparklet, "sparklet" + _root.sparkC, _root.getNextHighestDepth());
_root["sparklet" + _root.sparkC]._x = _root.ball._x;
_root["sparklet" + _root.sparkC]._y = _root.ball._y;
var dx = (_parent._x - _root.ball._x);
var dy = (_parent._y - _root.ball._y);
_root["sparklet" + _root.sparkC]._xscale = 100 + ((Math.random() * 40) - 20);
_root["sparklet" + _root.sparkC]._yscale = _root["sparklet" + _root.sparkC]._xscale;
var myRadians = Math.atan2(dy, dx);
var myDegrees = (myRadians * 57.2957795130823);
_root["sparklet" + _root.sparkC]._rotation = (myDegrees - 90) + ((Math.random() * 120) - 60);
_root.sparkC++;
i++;
}
_root.resetLevel();
}
}
}
Instance of Symbol 143 MovieClip "repel" in Symbol 144 MovieClip Frame 1
onClipEvent (load) {
var mass = (_parent._width / 200);
}
onClipEvent (enterFrame) {
var gravityDirection = Kyle.getAngle(_parent, _root.ball);
var distanceToBall = Kyle.getDistance(_parent, _root.ball);
if (_root.gameOn) {
if (_parent._name != "repel") {
_root.ball.xspeed = _root.ball.xspeed - ((((-1 * mass) * Math.sin(gravityDirection * (Math.PI/180))) * (1 / distanceToBall)) * 25);
_root.ball.yspeed = _root.ball.yspeed - (((mass * Math.cos(gravityDirection * (Math.PI/180))) * (1 / distanceToBall)) * 25);
}
}
if (Kyle.circleCollide(_parent, _root.ball)) {
if (_parent._name != "repel") {
_root.minusTen._visible = true;
_root.minusTen.play();
_root.score = _root.score - 10;
i = 0;
while (i < 5) {
duplicateMovieClip (_root.sparklet, "sparklet" + _root.sparkC, _root.getNextHighestDepth());
_root["sparklet" + _root.sparkC]._x = _root.ball._x;
_root["sparklet" + _root.sparkC]._y = _root.ball._y;
var dx = (_parent._x - _root.ball._x);
var dy = (_parent._y - _root.ball._y);
_root["sparklet" + _root.sparkC]._xscale = 100 + ((Math.random() * 40) - 20);
_root["sparklet" + _root.sparkC]._yscale = _root["sparklet" + _root.sparkC]._xscale;
var myRadians = Math.atan2(dy, dx);
var myDegrees = (myRadians * 57.2957795130823);
_root["sparklet" + _root.sparkC]._rotation = (myDegrees - 90) + ((Math.random() * 120) - 60);
_root.sparkC++;
i++;
}
_root.resetLevel();
}
}
}
Instance of Symbol 146 MovieClip in Symbol 147 MovieClip Frame 1
onClipEvent (enterFrame) {
if (hitTest(_root.ball._x, _root.ball._y, false)) {
if (_parent._name != "block") {
if (!_root.muteSound) {
_root.crashSound.start(0, 1);
}
_root.minusTen._visible = true;
_root.minusTen.play();
_root.score = _root.score - 10;
i = 0;
while (i < 5) {
duplicateMovieClip (_root.sparklet, "sparklet" + _root.sparkC, _root.getNextHighestDepth());
_root["sparklet" + _root.sparkC]._x = _root.ball._x;
_root["sparklet" + _root.sparkC]._y = _root.ball._y;
_root["sparklet" + _root.sparkC]._xscale = 100 + ((Math.random() * 40) - 20);
_root["sparklet" + _root.sparkC]._yscale = _root["sparklet" + _root.sparkC]._xscale;
if ((_root.ball._x - 10) < _parent._x) {
_root["sparklet" + _root.sparkC]._rotation = 270 + ((Math.random() * 120) - 60);
}
if ((_root.ball._x + 10) > (_parent._x + _width)) {
_root["sparklet" + _root.sparkC]._rotation = 90 + ((Math.random() * 120) - 60);
}
if ((_root.ball._y - 10) < _parent._y) {
_root["sparklet" + _root.sparkC]._rotation = 0 + ((Math.random() * 120) - 60);
}
if ((_root.ball._y + 10) > (_parent._y + _height)) {
_root["sparklet" + _root.sparkC]._rotation = 180 + ((Math.random() * 120) - 60);
}
_root.sparkC++;
i++;
}
_root.resetLevel();
}
}
}
Symbol 163 MovieClip Frame 20
stop();
_x = -500;
Symbol 172 MovieClip Frame 20
_visible = false;
gotoAndStop (1);
Symbol 175 MovieClip Frame 1
stop();
Symbol 175 MovieClip Frame 60
_visible = false;
gotoAndStop (1);
Symbol 179 MovieClip Frame 1
stop();
Symbol 179 MovieClip Frame 60
_visible = false;
gotoAndStop (1);
Instance of Symbol 193 MovieClip in Symbol 196 MovieClip Frame 1
on (release) {
removeMovieClip(_root.boundaryTracker);
_root.cleanUp();
_root.gotoAndStop("menu");
}
Instance of Symbol 195 MovieClip in Symbol 196 MovieClip Frame 1
on (release) {
_root.youSure._visible = false;
}
Symbol 198 Button
on (release) {
_root.enterName._visible = true;
}
Symbol 200 Button
on (release) {
_root.resetGame();
}
Instance of Symbol 206 MovieClip in Symbol 210 MovieClip Frame 1
on (release) {
_root.playerName = _root.enterName.name_txt.text;
_root.gotoAndPlay("highScores");
}
Instance of Symbol 208 MovieClip in Symbol 210 MovieClip Frame 1
on (release) {
_root.enterName._visible = false;
}