Frame 1
stop();
this.onEnterFrame = function () {
var _local1 = this;
if (_local1.getBytesLoaded() < _local1.getBytesTotal()) {
Total = _local1.getBytesTotal() / 1000;
Received = _local1.getBytesLoaded() / 1000;
Percentage = (Received / Total) * 100;
_local1.loadingvar = int(Percentage) add "%";
} else {
_local1.gotoAndPlay(2);
_local1.onEnterFrame = null;
}
};
Frame 2
stop();
count = 1;
_root.onEnterFrame = function () {
count++;
if (count >= 90) {
xxxpre_mc._alpha = xxxpre_mc._alpha - 3;
}
if (xxxpre_mc._alpha < 0) {
count = 0;
_root.onEnterFrame = null;
unloadMovie (xxxpre_mc);
nextFrame();
}
};
Frame 3
stop();
xxxpre_mc.onEnterFrame = null;
xxxpre_mc.unloadMovie();
Frame 4
function moveStuff() {
var _local1 = _root;
if (Key.isDown(37)) {
_local1.ball_mc._x = _local1.ball_mc._x - _local1.ball_mcspeed;
}
if (Key.isDown(39)) {
_local1.ball_mc._x = _local1.ball_mc._x + _local1.ball_mcspeed;
}
if (_local1.ball_mc._x > (StageWidth - (_local1.ball_mc._width / 2))) {
_local1.ball_mc._x = StageWidth - (_local1.ball_mc._width / 2);
}
if (_local1.ball_mc._x < (_local1.ball_mc._width / 2)) {
_local1.ball_mc._x = _local1.ball_mc._width / 2;
}
}
function makewalls() {
var _local1 = _root;
_local1.count3++;
if (_local1.count3 >= _local1.leveltime) {
_local1.count++;
_local1.count2++;
_local1.count4++;
if (_local1.count >= 20) {
_local1.count = 0;
_local1.count2 = 1000;
_local1.count4 = 2000;
}
wallnum = "wall" + _local1.count;
holenum = "hole" + _local1.count2;
wall.duplicateMovieClip(wallnum, _local1.count);
_local1["wall" + _local1.count]._y = 430;
hole.duplicateMovieClip(holenum, _local1.count2);
_local1["hole" + _local1.count2]._y = 430;
_local1["hole" + _local1.count2]._x = Math.abs((Math.round(Math.random() * 16) * 30) + 18);
if (random(3) != 1) {
holenum2 = "hole2" + _local1.count4;
hole2.duplicateMovieClip(holenum2, _local1.count4);
_local1["hole2" + _local1.count4]._y = 430;
_local1["hole2" + _local1.count4]._x = Math.abs((Math.round(Math.random() * 16) * 30) + 18);
}
_local1.count3 = 0;
}
_local1.ball_Ytemp = _local1.floorspeed;
if (_local1.ball_mc._y >= 380) {
_local1.ball_Ytemp = 0;
}
if (((_local1.ball_Ygoto == 0) || (_local1.hithole == 1)) || (_local1.hithole2 == 1)) {
if (!_local1.hitwall) {
_local1.ball_mc._y = _local1.ball_mc._y + _local1.ball_Ytemp;
}
_local1.hithole = 0;
_local1.hithole2 = 0;
_local1.hitwall = 0;
} else {
_local1.ball_mc._y = _local1.ball_Ygoto;
}
}
function makeScore() {
var _local1 = _root;
if ((_local1.levelup >= 120) && (_local1.leveltime >= 15)) {
_local1.leveltime = _local1.leveltime - 2;
_local1.levelup = 1;
_local1.floorspeed = _local1.floorspeed + _local1.fsincrement;
_local1.keepscore = _local1.keepscore + 1;
_local1.ball_mcspeed = _local1.ball_mcspeed + 0.1;
} else if ((_local1.levelup >= 120) && (_local1.leveltime < 15)) {
_local1.levelup = 1;
_local1.keepscore = _local1.keepscore + 1;
_local1.floorspeed = _local1.floorspeed + _local1.fsincrement2;
_local1.ball_mcspeed = _local1.ball_mcspeed + _local1.bsincrement;
}
_local1.levelup = _local1.levelup + 1;
_local1.scorekeep = _local1.scorekeep + 1;
_local1.score = Math.abs(Math.round(_local1.score + (((_local1.scorekeep / 8) * _local1.keepscore) / 8)));
if (_local1.ball_mc._y < 0) {
_local1.onEnterFrame = null;
stats.unloadMovie();
_local1.ball_mc.removeMovieClip();
gotoAndPlay (4);
}
}
stop();
_root.soundcount = 0;
_root.soundbits = ["1.mp3", "2.mp3", "3.mp3", "4.mp3", "5.mp3", "6.mp3", "7.mp3", "8.mp3", "9.mp3", "A.mp3", "B.mp3"];
_root["mainsound" + _root.soundcount] = new Sound();
_root["mainsound" + _root.soundcount].attachSound(_root.soundbits[_root.soundcount]);
_root["mainsound" + _root.soundcount].start(0, 4);
_root.score = 1;
_root.ball_mc._y = 5;
_root.ball_mc._x = 245;
_root.floorspeed = 5;
_root.levelup = 1;
_root.keepscore = 1;
_root.scorekeep = 1;
_root.count = 0;
_root.count2 = 1000;
_root.count4 = 2000;
_root.count3 = 5;
_root.ballcheck = 0;
StageWidth = 520;
_root.ball_mcspeed = 16;
_root.ball_Ygoto = 0;
_root.onEnterFrame = function () {
var _local1 = _root;
moveStuff();
makewalls();
makeScore();
_local1["mainsound" + _local1.soundcount].onSoundComplete = function () {
var _local1 = _root;
_local1.soundcount = _local1.soundcount + 1;
if (_local1.soundcount >= 10) {
_local1.soundcount = 10;
}
_local1["mainsound" + _local1.soundcount] = new Sound();
_local1["mainsound" + _local1.soundcount].attachSound(_local1.soundbits[_local1.soundcount]);
_local1["mainsound" + _local1.soundcount].start(0, 4);
};
};
Instance of Symbol 45 MovieClip "hole2" in Frame 4
onClipEvent (enterFrame) {
if (this._name != "hole2") {
if (this.hitTest(_root.ball_mc)) {
_root.hithole2 = 1;
_root.ball_Ygoto = 0;
}
this._y = this._y - _root.floorspeed;
if (this._y < -30) {
this.removeMovieClip();
}
}
}
Instance of Symbol 47 MovieClip "ball_mc" in Frame 4
onClipEvent (load) {
this.swapDepths(60000);
}
onClipEvent (enterFrame) {
if (this._y > 390) {
_root.ball_Ygoto = 385;
}
}
Instance of Symbol 45 MovieClip "hole" in Frame 4
onClipEvent (enterFrame) {
if (this._name != "hole") {
if (this.hitTest(_root.ball_mc)) {
_root.hithole = 1;
_root.ball_Ygoto = 0;
}
this._y = this._y - _root.floorspeed;
if (this._y < -30) {
this.removeMovieClip();
}
}
}
Instance of Symbol 13 MovieClip [wall] "wall" in Frame 4
onClipEvent (enterFrame) {
if (this._name != "wall") {
if ((this.hitTest(_root.ball_mc) && (this._y >= (_root.ball_mc._y - _root.floorspeed))) && (!_root.hithole)) {
_root.ball_Ygoto = this._y - 25;
_root.hitwall = 1;
}
this._y = this._y - _root.floorspeed;
if (this._y < -30) {
_root.ball_Ygoto = 0;
this.removeMovieClip();
}
}
}
Instance of Symbol 56 MovieClip "stats" in Frame 4
onClipEvent (load) {
this.swapDepths(60002);
}
Frame 5
stop();
stopAllSounds();
_root.onEnterFrame = null;
stats.unloadMovie();
_root.ball_mc.unloadMovie();
Instance of Symbol 64 MovieClip "endscene" in Frame 5
onClipEvent (load) {
this.swapDepths(60009);
}
Symbol 19 MovieClip Frame 30
gotoAndPlay (1);
Symbol 36 Button
on (release) {
_root.fsincrement = 0.2;
_root.fsincrement2 = 0.4;
_root.bsincrement = 0.2;
_root.leveltime = 50;
gotoAndStop (4);
}
Symbol 40 Button
on (release) {
_root.fsincrement = 0.5;
_root.fsincrement2 = 0.9;
_root.bsincrement = 0;
_root.leveltime = 30;
gotoAndStop (4);
}
Symbol 43 Button
on (release) {
_root.fsincrement = 0.05;
_root.fsincrement2 = 0.1;
_root.bsincrement = 0.5;
_root.leveltime = 50;
gotoAndStop (4);
}
Symbol 68 Button
on (release) {
unloadMovie (_root.endscene);
gotoAndStop (3);
}