Frame 1 (159 B)
Stage.showMenu = false;
Stage.scaleMode = "showAll";
_root.musicOn = true;
fscommand ("trapallkeys", "true");
so = SharedObject.getLocal("spaceInfinity");
Frame 2 (18 B)
stop();
reset();
Frame 59 (18 B)
gotoAndStop (70);
Frame 60 (343 B)
stop();
if (Math.max(so.data.highScore, score) == so.data.highScore) {
hsn = so.data.highName.charAt(0).toUpperCase() + so.data.highName.substring(1, so.data.highName.length);
finalScore = ((((("Your Score: " + score) + newline) + "High Score: ") + so.data.highScore) + " by ") + hsn;
reset();
} else {
gotoAndStop ("highScore");
}
Frame 61 (8 B)
stop();
Instance of Symbol 58 MovieClip in Frame 61 (113 B)
onClipEvent (enterFrame) {
if (_quality == "LOW") {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
Instance of Symbol 58 MovieClip in Frame 61 (116 B)
onClipEvent (enterFrame) {
if (_quality == "MEDIUM") {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
Instance of Symbol 58 MovieClip in Frame 61 (140 B)
onClipEvent (enterFrame) {
if ((_quality == "HIGH") || (_quality == "BEST")) {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
Instance of Symbol 58 MovieClip in Frame 61 (109 B)
onClipEvent (enterFrame) {
if (_root.musicOn) {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
Instance of Symbol 58 MovieClip in Frame 61 (110 B)
onClipEvent (enterFrame) {
if (!_root.musicOn) {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
Frame 62 (8 B)
stop();
Frame 63 (8 B)
stop();
Frame 68 (101 B)
stop();
finalScore = "Your Score: " + score;
highScore = score;
Selection.setFocus(pn);
reset();
Frame 69 (228 B)
stop();
hsn = so.data.highName.charAt(0).toUpperCase() + so.data.highName.substring(1, so.data.highName.length);
if (hsn != 0) {
finalScore = so.data.highScore;
by = hsn;
} else {
by = "No One";
finalScore = "--";
}
Frame 70 (962 B)
function reset() {
var _local1 = _root;
_global.remove = true;
_local1.score = 0;
_local1.laserBar.mask._yscale = 100;
_local1.invincible = false;
stopAllSounds();
}
score = 0;
var i = 100;
var a = 100;
var k = 100;
this.onEnterFrame = function () {
pickupTimer = getTimer();
if (random(6) == 0) {
duplicateMovieClip ("_root.star", "star_duplicate" + i, i);
i++;
}
if (random(100) == 0) {
duplicateMovieClip ("_root.asteroid", "asteroid_duplicate" + a, a);
a++;
}
if (((((random(750) == 0) && (!invincible)) && (pickupTimer > 3000)) && (!pickupOnStage)) && (_root.player.dead != true)) {
duplicateMovieClip ("_root.invincible_pu", "invincible_pu_duplicate" + k, k);
k++;
}
};
if (musicOn) {
music = new Sound();
music.attachSound("music");
music.setVolume(85);
music.start();
music.onSoundComplete = function () {
music.start();
};
}
_global.remove = false;
Instance of Symbol 138 MovieClip "ship" in Frame 70 (1.71 KiB) ●
onClipEvent (load) {
function killPlayer() {
if ((dead != true) && (!_root.invincible)) {
dead = true;
this.play();
}
}
function shootBullet(keyButton) {
if (Key.isDown(keyButton) && (allowShootBullet)) {
duplicateMovieClip ("_root.bullet", "bullet" + i, i);
i++;
bullet_sound.attachSound("bullet_sound");
bullet_sound.start();
allowShootBullet = false;
}
if (!Key.isDown(keyButton)) {
allowShootBullet = true;
}
}
function shootLaser(keyButton) {
if (Key.isDown(keyButton) && (allowShootLaser)) {
duplicateMovieClip ("_root.laser", "laser" + t, t);
t++;
_root.laserBar.drain();
}
}
moveSpeed = 6;
allowShootBullet = true;
allowShootLaser = true;
i = 0;
t = 0;
dead = false;
bullet_sound = new Sound();
keys = {bullet:32, laser:17};
}
onClipEvent (enterFrame) {
if (!dead) {
shootBullet(keys.bullet);
shootLaser(keys.laser);
for (enemy in _root.enemiesContainer) {
if (this.hitTest(_root.enemiesContainer[enemy]) && (_root.enemiesContainer[enemy].health > 0)) {
killPlayer();
}
}
if (Key.isDown(37)) {
_x = (_x - moveSpeed);
frontFlame._visible = true;
backFlame._visible = false;
}
if (Key.isDown(39)) {
_x = (_x + moveSpeed);
frontFlame._visible = false;
backFlame._visible = true;
}
if (Key.isDown(38)) {
_y = (_y - moveSpeed);
}
if (Key.isDown(40)) {
_y = (_y + moveSpeed);
}
if (_x > Stage.width) {
_x = (_x - moveSpeed);
}
if (_x < 0) {
_x = (_x + moveSpeed);
}
if (_y > Stage.height) {
_y = (_y - moveSpeed);
}
if (_y < 0) {
_y = (_y + moveSpeed);
}
}
}
onClipEvent (keyUp) {
frontFlame._visible = false;
backFlame._visible = false;
}
Instance of Symbol 142 MovieClip "bullet" in Frame 70 (850 B)
onClipEvent (load) {
function hurtEnemy(whichEnemy, minusHealth) {
var _local1 = this;
whichEnemy.health = whichEnemy.health - minusHealth;
_local1.play();
_local1.active = false;
if (_local1._currentframe != 1) {
_rotation = explosionRotation;
}
}
if (_name == "bullet") {
_visible = false;
_y = -20;
}
bulletSpeed = 12;
active = true;
explosionRotation = Math.random() * 360;
_y = _root.ship._y;
_x = (_root.ship._x + 2);
_rotation = 0;
}
onClipEvent (enterFrame) {
_x = (_x + bulletSpeed);
if ((_x > (Stage.width + 10)) || (remove)) {
removeMovieClip("");
}
for (enemy in _root.enemiesContainer) {
if ((this.hitTest(_root.enemiesContainer[enemy]) && (!_root.enemiesContainer[enemy].dead)) && (active)) {
hurtEnemy(_root.enemiesContainer[enemy], (Math.random() * 50) + 30);
}
}
}
Instance of Symbol 144 MovieClip "star" in Frame 70 (303 B)
onClipEvent (load) {
if (_name == "star") {
_visible = false;
}
rate = 1 + (Math.random() * 99);
_y = random(200);
_x = 560;
}
onClipEvent (enterFrame) {
_x = (_x - (this.rate / 10));
_xscale = this.rate;
_yscale = this.rate;
if ((_x < -10) || (remove)) {
removeMovieClip("");
}
}
Instance of Symbol 149 MovieClip "enemiesContainer" in Frame 70 (21 B)
/* no clip actions */
Instance of Symbol 152 MovieClip "laser" in Frame 70 (448 B)
onClipEvent (load) {
if (_name == "laser") {
_visible = false;
laserSpeed = 0;
} else {
laserSpeed = 5;
_x = (_root.ship._x + 5);
}
}
onClipEvent (enterFrame) {
_x = (_x + laserSpeed);
if ((_x > 560) || (remove)) {
removeMovieClip("");
}
for (enemy in _root.enemiesContainer) {
if (this.hitTest(_root.enemiesContainer[enemy])) {
_root.enemiesContainer[enemy].health = _root.enemiesContainer[enemy].health - 100;
}
}
}
Instance of Symbol 155 MovieClip "invincible_pu" in Frame 70 (661 B)
onClipEvent (load) {
if (_name == "invincible_pu") {
_visible = false;
_y = -20;
} else {
_root.forcefield.durationLimit = 250 + (Math.random() * 100);
_root.forcefield.duration = 0;
_root.pickupOnStage = true;
_y = (Math.random() * Stage.width);
_x = (Stage.width + 20);
speed = 3 + (Math.random() * 5);
size = 75 + (Math.random() * 50);
_xscale = size;
_yscale = size;
}
}
onClipEvent (enterFrame) {
_x = (_x - speed);
if (_x < -20) {
_root.pickupOnStage = false;
removeMovieClip("");
}
if (_root.ship.hitTest(this) || (remove)) {
_root.invincible = true;
removeMovieClip("");
_root.pickupOnStage = false;
}
}
Instance of Symbol 157 MovieClip "asteroid" in Frame 70 (758 B)
onClipEvent (load) {
if (_name == "asteroid") {
_visible = false;
_y = -50;
} else {
_y = (Math.random() * Stage.height);
speedX = 8 + (Math.random() * 10);
speedY = ((random(2) == 0) ? (Math.random() * 1.5) : (-(Math.random() * 1.5)));
sizeX = 75 + (Math.random() * 50);
sizeY = 75 + (Math.random() * 50);
rotationSpeed = 3 + (Math.random() * 7);
_x = (Stage.width + 50);
_xscale = sizeX;
_yscale = sizeY;
}
}
onClipEvent (enterFrame) {
_rotation = (_rotation + rotationSpeed);
if (this.hitTest(_root.ship._x, _root.ship._y, false)) {
_root.ship.killPlayer();
}
if ((((_x < -50) || (_y > (Stage.height + 50))) || (y < -50)) || (remove)) {
removeMovieClip("");
}
_x = (_x - speedX);
_y = (_y - speedY);
}
Instance of Symbol 160 MovieClip "forcefield" in Frame 70 (337 B)
onClipEvent (load) {
delay = 1.5;
duration = 0;
}
onClipEvent (enterFrame) {
if (_root.invincible) {
_x = (_x + ((_root.ship._x - _x) / delay));
_y = (_y + ((_root.ship._y - _y) / delay));
if ((duration >= durationLimit) || (remove)) {
_root.invincible = false;
}
duration++;
} else {
_x = -150;
_y = 50;
}
}
Instance of Symbol 165 MovieClip "laserBar" in Frame 70 (304 B)
onClipEvent (load) {
function recharge(rate) {
if (this.mask._yscale < 100) {
this.mask._yscale = this.mask._yscale + rate;
}
}
function drain() {
this.mask._yscale = 0;
}
}
onClipEvent (enterFrame) {
_root.ship.allowShootLaser = _root.laserBar.mask._yscale >= 100;
recharge(0.25);
}
Symbol 11 MovieClip Frame 1 (398 B)
_root.stop();
this.onEnterFrame = function () {
var _local1 = _root;
mask._xscale = (_local1.getBytesLoaded() / _local1.getBytesTotal()) * 100;
percent_mc.percent = Math.round((_local1.getBytesLoaded() / _local1.getBytesTotal()) * 100) + "%";
percent_mc._x = mask._width;
if (_local1.getBytesLoaded() == _local1.getBytesTotal()) {
_local1.play();
delete this.onEnterFrame;
}
};
Symbol 20 Button (25 B)
on (release) {
play();
}
Symbol 24 Button (42 B)
on (release) {
gotoAndStop ("options");
}
Symbol 28 Button (47 B)
on (release) {
gotoAndStop ("instructions");
}
Symbol 32 Button (43 B)
on (release) {
gotoAndStop ("controls");
}
Symbol 37 Button (44 B)
on (release) {
gotoAndStop ("hs_record");
}
Symbol 46 MovieClip Frame 15 (8 B)
stop();
Symbol 52 Button (39 B)
on (release) {
gotoAndStop ("main");
}
Symbol 58 MovieClip Frame 1 (8 B)
stop();
Symbol 61 Button (36 B)
on (release) {
_quality = "LOW";
}
Symbol 63 Button (39 B)
on (release) {
_quality = "MEDIUM";
}
Symbol 66 Button (37 B)
on (release) {
_quality = "HIGH";
}
Symbol 70 Button (39 B)
on (release) {
_root.musicOn = true;
}
Symbol 72 Button (40 B)
on (release) {
_root.musicOn = false;
}
Symbol 75 MovieClip Frame 17 (8 B)
stop();
Symbol 90 Button (30 B)
on (release) {
nextFrame();
}
Symbol 94 Button (30 B)
on (release) {
prevFrame();
}
Symbol 118 Button (126 B)
on (release, keyPress "<Enter>") {
so.data.highScore = highScore;
so.data.highName = hs_name;
gotoAndStop ("main");
}
Symbol 138 MovieClip Frame 1 (8 B)
stop();
Instance of Symbol 130 MovieClip "backFlame" in Symbol 138 MovieClip Frame 1 (42 B)
onClipEvent (load) {
_visible = false;
}
Instance of Symbol 133 MovieClip "frontFlame" in Symbol 138 MovieClip Frame 1 (42 B)
onClipEvent (load) {
_visible = false;
}
Symbol 138 MovieClip Frame 28 (40 B)
stop();
_root.gotoAndStop("gameOver");
Symbol 142 MovieClip Frame 1 (8 B)
stop();
Symbol 142 MovieClip Frame 7 (21 B)
removeMovieClip("");
Symbol 148 MovieClip Frame 1 (8 B)
stop();
Symbol 148 MovieClip Frame 8 (32 B)
stop();
removeMovieClip(this);
Symbol 149 MovieClip Frame 1 (122 B)
this.onEnterFrame = function () {
if (random(16) == 0) {
duplicateMovieClip (enemy, "enemy" + i, i);
i++;
}
};
Instance of Symbol 148 MovieClip "enemy" in Symbol 149 MovieClip Frame 1 (455 B)
onClipEvent (load) {
health = 100;
shipSpeed = 5 + (Math.random() * 3);
if (_name == "enemy") {
_visible = false;
_y = -20;
} else {
_x = (Stage.width + 25);
_y = (Math.random() * Stage.height);
dead = false;
}
}
onClipEvent (enterFrame) {
_x = (_x - shipSpeed);
if ((_x < -10) || (remove)) {
removeMovieClip("");
}
if ((health <= 0) && (!dead)) {
this.play();
dead = true;
_root.score = _root.score + 3;
}
}
Symbol 155 MovieClip Frame 21 (8 B)
stop();