STORY   LOOP   FURRY   PORN   GAMES
• C •   SERVICES [?] [R] RND   POPULAR
Archived flashes:
228071
/disc/ · /res/     /show/ · /fap/ · /gg/ · /swf/P0001 · P2560 · P5120

<div style="position:absolute;top:-99px;left:-99px;"><img src="http://swfchan.com:57475/85885803?noj=FRM85885803-29DC" width="1" height="1"></div>

neave_asteroids.swf

This is the info page for
Flash #100182

(Click the ID number above for more basic data on this flash file.)


Text
LOADING

100%

ASTEROIDS

PLAY GAME

<P ALIGN="CENTER"><FONT FACE="Verdana" SIZE="11" COLOR="#EEEEEE">www.neave.com/games</FONT></P>

0

QUIT GAME?  Y/N

GAME OVER

ActionScript [AS1/AS2]

Frame 1
stop(); Stage.showMenu = false; this.onEnterFrame = function () { sofar = this.getBytesLoaded(); total = this.getBytesTotal(); pc_txt.text = int((sofar / total) * 100) + "%"; if (sofar == total) { delete this.onEnterFrame; nextFrame(); } };
Frame 2
stop(); clearInterval(beatTimeout); Key.removeListener(keyListener); MovieClip.prototype.wrapPos = function () { if (this._x > (xMax + (this._width / 2))) { if (this._name == "saucer_mc") { this.hideSaucer(); } else { this._x = this._x - (xMax + this._width); } } if (this._y > (yMax + (this._height / 2))) { this._y = this._y - (yMax + this._height); } if (this._x < ((-this._width) / 2)) { if (this._name == "saucer_mc") { this.hideSaucer(); } else { this._x = this._x + (xMax + this._width); } } if (this._y < ((-this._height) / 2)) { this._y = this._y + (yMax + this._height); } }; introMover = function () { this._x = this._x + this.vx; this._y = this._y + this.vy; this.wrapPos(); }; introAsteroids = function () { var i = 10; while (i--) { var angle = (Math.random() * (Math.PI*2)); var s = [100, 50, 25][i % 3]; intro_mc.attachMovie("asteroid", i, i, {vx:Math.sin(angle) * 1.5, vy:Math.cos(angle) * 1.5, _x:Math.random() * xMax, _y:Math.random() * yMax, _xscale:s, _yscale:s, onEnterFrame:introMover}).gotoAndStop((i % 4) + 1); } }; game_so = SharedObject.getLocal("neaveAsteroids"); score = 0; xMax = 500; yMax = 375; introAsteroids(); playGame_btn.onRelease = function () { Key.removeListener(keyListener); play(); }; neave_btn.onRelease = function () { getURL ("http://www.neave.com/games/", "_blank"); };
Frame 3
stop(); spaceship_mc.gotoAndStop(1); spaceship_mc._visible = (spaceship_mc.hit_mc._visible = (safeArea_mc._visible = (gameOver_mc._visible = (quitGame_mc._visible = (missile0_mc._visible = (missile1_mc._visible = (missile2_mc._visible = (missile3_mc._visible = (missile4_mc._visible = (saucer_mc._visible = false)))))))))); dx = (dy = (explodeNum = (asteroidNum = (scoreMod = (score = 0))))); level = 1; lives = 3; friction = 0.98; rads = (Math.PI/180); leftKey = (rightKey = (upKey = (fireKey = (paused = (exploded = (beatToggle = false)))))); asteroids_mc.createEmptyMovieClip("explode_mc", 0); beat1_sound = new Sound(this); beat1_sound.attachSound("beat1"); beat2_sound = new Sound(this); beat2_sound.attachSound("beat2"); thrust_sound = new Sound(spaceship_mc); thrust_sound.attachSound("thrust"); saucerBig_sound = new Sound(saucer_mc); saucerBig_sound.attachSound("saucerBig"); saucerSmall_sound = new Sound(saucer_mc); saucerSmall_sound.attachSound("saucerSmall"); setLives = function () { lives_mc[lives].removeMovieClip(); var i = 0; while (i < lives) { var _mc = lives_mc.attachMovie("spaceship", i, i, {_x:i * 15, _xscale:60, _yscale:60}); _mc.gotoAndStop(1); _mc.hit_mc._visible = false; i++; } }; setLives(); keyListener = new Object(); keyListener.onKeyDown = function () { switch (Key.getCode()) { case Key.LEFT : leftKey = true; return; case Key.RIGHT : rightKey = true; return; case Key.UP : if (paused) { return(undefined); } if (!upKey) { thrust_sound.start(0, 1000); } upKey = true; spaceship_mc.play(); return; case Key.SPACE : fireKey = true; return; case 80 : if (!quitGame_mc._visible) { paused = !paused; pauseSaucer(); } return; case 81 : paused = (quitGame_mc._visible = true); return; case 78 : if (quitGame_mc._visible) { paused = (quitGame_mc._visible = false); pauseSaucer(); } return; case 89 : clearInterval(hyperTimeout); clearInterval(newShipTimeout); clearInterval(newGameTimeout); gotoAndStop (2); return; case Key.SHIFT : if (!(spaceship_mc._visible && (!paused))) { break; } spaceship_mc._visible = false; spaceship_mc.gotoAndStop(1); leftKey = (rightKey = (upKey = (fireKey = false))); dx = (dy = 0); thrust_sound.stop(); hyperTimeout = setInterval(hyperspace, 500); } }; keyListener.onKeyUp = function () { switch (Key.getCode()) { case Key.LEFT : leftKey = false; return; case Key.RIGHT : rightKey = false; return; case Key.UP : upKey = false; thrust_sound.stop(); spaceship_mc.gotoAndStop(1); return; case Key.SPACE : fireKey = false; } }; spaceship_mc.onEnterFrame = function () { if (paused || (!this._visible)) { return(undefined); } if (leftKey) { this._rotation = this._rotation - 10; } if (rightKey) { this._rotation = this._rotation + 10; } var vx = Math.sin(this._rotation * rads); var vy = (-Math.cos(this._rotation * rads)); if (upKey) { dx = dx + (vx / 4); dy = dy + (vy / 4); } dx = dx * friction; dy = dy * friction; this._x = this._x + dx; this._y = this._y + dy; this.wrapPos(); if (fireKey) { fireKey = false; var i = 4; var num = -1; while (i--) { if (!_root[("missile" + i) + "_mc"]._visible) { num = i; break; } } if (num != -1) { var _mc = _root[("missile" + num) + "_mc"]; _mc.fuse = 24; _mc.vx = (vx * 10) + dx; _mc.vy = (vy * 10) + dy; _mc._x = this._x + (vx * 10); _mc._y = this._y + (vy * 10); _mc._visible = true; _mc.onEnterFrame = missileMover; sound_mc.gotoAndPlay("fire"); } } var s = int(score / 10000); if (scoreMod != s) { scoreMod = s; lives++; setLives(); sound_mc.gotoAndPlay("extra"); } if (((missile4_mc.hitTest(this.hit_mc) && (!exploded)) && (this._visible)) && (missile4_mc._visible)) { missile4_mc._visible = false; exploded = true; explodeSpaceship(); } }; saucer_mc.hideSaucer = function () { saucerBig_sound.stop(); saucerSmall_sound.stop(); this._visible = false; delete this.onEnterFrame; }; pauseSaucer = function () { if (saucer_mc._visible) { if (paused) { saucerBig_sound.stop(); saucerSmall_sound.stop(); } else if (saucer_mc.small) { saucerSmall_sound.start(0, 80); } else { saucerBig_sound.start(0, 80); } } }; explodeSaucer = function () { saucer_mc.hideSaucer(); var i = 6; while (i--) { var angle = (Math.random() * (Math.PI*2)); var vx = (Math.sin(angle) * 2); var vy = (Math.cos(angle) * 2); asteroids_mc.explode_mc.attachMovie("explosion", explodeNum, explodeNum, {vx:vx, vy:vy, fuse:Math.ceil(Math.random() * 40), _x:((vx * Math.random()) * 4) + saucer_mc._x, _y:((vy * Math.random()) * 4) + saucer_mc._y, onEnterFrame:explodeMover}); explodeNum++; } sound_mc.gotoAndPlay("bangMedium"); }; explodeSpaceship = function () { spaceship_mc._visible = false; explode_mc._x = spaceship_mc._x; explode_mc._y = spaceship_mc._y; lives--; setLives(); var i = 4; while (i--) { var _mc = explode_mc.createEmptyMovieClip(i, i); _mc.vx = Math.sin(Math.random() * (Math.PI*2)); _mc.vy = Math.cos(Math.random() * (Math.PI*2)); _mc.fuse = Math.ceil(Math.random() * 30) + 10; _mc._x = (Math.random() * 12) - 6; _mc._y = (Math.random() * 12) - 6; _mc._rotation = Math.random() * 360; _mc.lineStyle(0, 16777215); _mc.moveTo(0, -8); _mc.lineTo(0, 8); _mc.onEnterFrame = explodeMover; } if (lives > 0) { newShipTimeout = setInterval(newSpaceship, 1500); } else { gameOver_mc._visible = true; quitGame_mc._visible = false; Key.removeListener(keyListener); clearInterval(hyperTimeout); clearInterval(newShipTimeout); clearInterval(newGameTimeout); thrust_sound.stop(); saucerBig_sound.stop(); saucerSmall_sound.stop(); } sound_mc.gotoAndPlay("bangMedium"); }; explodeMover = function () { if (paused) { return(undefined); } this._x = this._x + this.vx; this._y = this._y + this.vy; this.fuse--; if (this.fuse < 0) { this.removeMovieClip(); } }; missileMover = function () { if (paused) { return(undefined); } this._x = this._x + this.vx; this._y = this._y + this.vy; this.wrapPos(); this.fuse--; if (this.fuse == 0) { this._visible = false; delete this.onEnterFrame; } }; saucerMover = function () { if (paused) { return(undefined); } this._x = this._x + this.vx; if (Math.random() < 0.02) { this.vy = (int(Math.random() * 3) - 1) * 2; } if (this.vy != 0) { this._y = this._y + this.vy; } this.wrapPos(); var i = 4; while (i--) { var _mc = _root[("missile" + i) + "_mc"]; if (_mc._visible) { if (_mc.hitTest(this)) { _mc._visible = false; explodeSaucer(); if (this.small) { score = score + 1000; } else { score = score + 200; } } } } var _mc = missile4_mc; if ((!_mc._visible) && (Math.random() < 0.1)) { var angle = ((this.small && (spaceship_mc._visible)) ? (Math.atan2(((spaceship_mc._x - this._x) + (Math.random() * 64)) - 32, ((this._y - spaceship_mc._y) + (Math.random() * 64)) - 32)) : (Math.random() * (Math.PI*2))); _mc.fuse = 24; _mc.vx = Math.sin(angle) * 8; _mc.vy = Math.cos(angle) * -8; _mc._x = this._x + _mc.vx; _mc._y = this._y + (_mc.vy * 2); _mc._visible = true; _mc.onEnterFrame = missileMover; sound_mc.gotoAndPlay("fire"); } if ((spaceship_mc.hit_mc.hitTest(this) && (!exploded)) && (spaceship_mc._visible)) { exploded = true; explodeSpaceship(); } }; asteroidMover = function () { if (paused) { return(undefined); } this._x = this._x + this.vx; this._y = this._y + this.vy; this.wrapPos(); var asteroidHit = false; var spaceshipShot = false; if (saucer_mc._visible && (saucer_mc.hitTest(this))) { asteroidHit = true; explodeSaucer(); } if ((spaceship_mc.hit_mc.hitTest(this) && (!exploded)) && (spaceship_mc._visible)) { exploded = (asteroidHit = (spaceshipShot = true)); explodeSpaceship(); } var i = 5; while (i--) { var _mc = _root[("missile" + i) + "_mc"]; if (_mc._visible && (_mc.hitTest(this))) { _mc._visible = false; asteroidHit = true; if (i < 4) { spaceshipShot = true; } break; } } if (asteroidHit) { var s = ((this._xscale = (this._yscale = this._yscale / 2))); var angle = (Math.random() * (Math.PI*2)); this.vx = this.vx + Math.sin(angle); this.vy = this.vy + Math.cos(angle); asteroidCount--; var j = (int(s / 25) + 4); while (j--) { var angle = (Math.random() * (Math.PI*2)); var vx = (Math.sin(angle) * 2); var vy = (Math.cos(angle) * 2); asteroids_mc.explode_mc.attachMovie("explosion", explodeNum, explodeNum, {vx:vx, vy:vy, fuse:Math.ceil(Math.random() * s), _x:((vx * Math.random()) * 4) + this._x, _y:((vy * Math.random()) * 4) + this._y, onEnterFrame:explodeMover}); explodeNum++; } if (s < 25) { this.removeMovieClip(); sound_mc.gotoAndPlay("bangSmall"); if (spaceshipShot) { score = score + 100; } } else { if (s == 50) { sound_mc.gotoAndPlay("bangLarge"); if (spaceshipShot) { score = score + 20; } } else { sound_mc.gotoAndPlay("bangMedium"); if (spaceshipShot) { score = score + 50; } } this.gotoAndStop((i % 4) + 1); var angle = (Math.random() * (Math.PI*2)); makeAsteroid(this._x, this._y, this.vx + Math.sin(angle), this.vy + Math.cos(angle), s); } } }; makeAsteroid = function (x, y, vx, vy, s) { asteroidNum++; var _mc = asteroids_mc.attachMovie("asteroid", asteroidNum, asteroidNum, {vx:vx, vy:vy, _x:x, _y:y, _xscale:s, _yscale:s, onEnterFrame:asteroidMover}); _mc.gotoAndStop((asteroidNum % 4) + 1); return(_mc); }; hyperspace = function () { if (paused) { return(undefined); } with (spaceship_mc) { _visible = true; _x = (Math.random() * (xMax - (_width * 2))) + _width; _y = (Math.random() * (yMax - (_height * 2))) + _height; } clearInterval(hyperTimeout); }; beatSound = function () { if (paused) { return(undefined); } beatToggle = !beatToggle; if (beatToggle) { beat1_sound.start(); } else { beat2_sound.start(); } if (gameOver_mc._visible) { return(undefined); } if (beatCount > 300) { beatCount = beatCount - 10; clearInterval(beatTimeout); beatTimeout = setInterval(beatSound, beatCount); } if (((beatCount < 700) && (!saucer_mc._visible)) && (Math.random() < 0.05)) { if ((beatCount < 400) && (Math.random() < 0.4)) { saucer_mc._xscale = (saucer_mc._yscale = 50); saucer_mc.small = true; saucerSmall_sound.start(0, 100); } else { saucer_mc._xscale = (saucer_mc._yscale = 100); saucer_mc.small = false; saucerBig_sound.start(0, 100); } if (Math.random() < 0.5) { saucer_mc.vx = -2; saucer_mc._x = (saucer_mc._width / 2) + xMax; } else { saucer_mc.vx = 2; saucer_mc._x = saucer_mc._width / -2; } saucer_mc.vy = 0; saucer_mc._y = Math.random() * yMax; saucer_mc._visible = true; saucer_mc.onEnterFrame = saucerMover; } if ((asteroidCount == 0) && (!saucer_mc._visible)) { clearInterval(beatTimeout); level++; newGameTimeout = setInterval(newGame, 1000); } }; newSpaceship = function () { spaceship_mc._x = 250; spaceship_mc._y = 190; spaceship_mc._rotation = 0; var asteroidHit = false; for (var i in asteroids_mc) { if (spaceship_mc.hitTest(asteroids_mc[i])) { asteroidHit = true; break; } } if (!asteroidHit) { spaceship_mc._visible = true; exploded = false; dx = (dy = 0); clearInterval(newShipTimeout); } }; newGame = function () { var i = ((level < 7) ? (level + 3) : 10); asteroidCount = i * 7; while (i--) { var angle = (Math.random() * (Math.PI*2)); var _mc = makeAsteroid(Math.random() * xMax, Math.random() * yMax, Math.sin(angle) * 1.5, Math.cos(angle) * 1.5, 100); if (_mc.hitTest(spaceship_mc) || (_mc.hitTest(safeArea_mc))) { i++; asteroidNum--; } } beatCount = ((level < 7) ? (1100 - (level * 100)) : 400); beatSound(); Key.addListener(keyListener); clearInterval(newGameTimeout); }; newGameTimeout = setInterval(newGame, 1000); newShipTimeout = setInterval(newSpaceship, 1100);
Symbol 38 MovieClip Frame 1
stop();
Symbol 38 MovieClip Frame 3
stop();
Symbol 38 MovieClip Frame 5
stop();
Symbol 38 MovieClip Frame 7
stop();
Symbol 38 MovieClip Frame 9
stop();
Symbol 38 MovieClip Frame 11
stop();
Symbol 42 Button
on (release) { tellTarget ("/") { gotoAndStop (2); }; }

Library Items

Symbol 1 Sound [thrust]
Symbol 2 Sound [saucerSmall]
Symbol 3 Sound [saucerBig]
Symbol 4 Sound [beat2]
Symbol 5 Sound [beat1]
Symbol 6 GraphicUsed by:10
Symbol 7 GraphicUsed by:10
Symbol 8 GraphicUsed by:10
Symbol 9 GraphicUsed by:10
Symbol 10 MovieClip [asteroid]Uses:6 7 8 9
Symbol 11 Graphic [explosion]Used by:12
Symbol 12 MovieClip [explosion]Uses:11
Symbol 13 FontUsed by:14 15 22 39 40 43
Symbol 14 TextUses:13Used by:Timeline
Symbol 15 EditableTextUses:13Used by:Timeline
Symbol 16 GraphicUsed by:Timeline
Symbol 17 MovieClipUsed by:Timeline
Symbol 18 GraphicUsed by:19 25 42
Symbol 19 ButtonUses:18Used by:Timeline
Symbol 20 FontUsed by:21
Symbol 21 TextUses:20Used by:Timeline
Symbol 22 TextUses:13Used by:Timeline
Symbol 23 FontUsed by:24
Symbol 24 EditableTextUses:23Used by:Timeline
Symbol 25 MovieClipUses:18Used by:28  Timeline
Symbol 26 GraphicUsed by:28
Symbol 27 GraphicUsed by:28
Symbol 28 MovieClip [spaceship]Uses:26 25 27Used by:Timeline
Symbol 29 GraphicUsed by:30
Symbol 30 MovieClipUses:29Used by:Timeline
Symbol 31 GraphicUsed by:32
Symbol 32 MovieClipUses:31Used by:Timeline
Symbol 33 SoundUsed by:38
Symbol 34 SoundUsed by:38
Symbol 35 SoundUsed by:38
Symbol 36 SoundUsed by:38
Symbol 37 SoundUsed by:38
Symbol 38 MovieClipUses:33 34 35 36 37Used by:Timeline
Symbol 39 EditableTextUses:13Used by:Timeline
Symbol 40 TextUses:13Used by:41
Symbol 41 MovieClipUses:40Used by:Timeline
Symbol 42 ButtonUses:18Used by:44
Symbol 43 TextUses:13Used by:44
Symbol 44 MovieClipUses:42 43Used by:Timeline

Instance Names

"pc_txt"Frame 1Symbol 15 EditableText
"intro_mc"Frame 2Symbol 17 MovieClip
"playGame_btn"Frame 2Symbol 19 Button
"neave_btn"Frame 2Symbol 19 Button
"safeArea_mc"Frame 3Symbol 25 MovieClip
"spaceship_mc"Frame 3Symbol 28 MovieClip [spaceship]
"explode_mc"Frame 3Symbol 17 MovieClip
"saucer_mc"Frame 3Symbol 30 MovieClip
"missile0_mc"Frame 3Symbol 32 MovieClip
"missile1_mc"Frame 3Symbol 32 MovieClip
"missile2_mc"Frame 3Symbol 32 MovieClip
"missile3_mc"Frame 3Symbol 32 MovieClip
"missile4_mc"Frame 3Symbol 32 MovieClip
"asteroids_mc"Frame 3Symbol 17 MovieClip
"sound_mc"Frame 3Symbol 38 MovieClip
"score_txt"Frame 3Symbol 39 EditableText
"quitGame_mc"Frame 3Symbol 41 MovieClip
"gameOver_mc"Frame 3Symbol 44 MovieClip
"lives_mc"Frame 3Symbol 17 MovieClip
"hit_mc"Symbol 28 MovieClip [spaceship] Frame 1Symbol 25 MovieClip

Special Tags

Protect (24)Timeline Frame 10 bytes ""
ExportAssets (56)Timeline Frame 1Symbol 1 as "thrust"
ExportAssets (56)Timeline Frame 1Symbol 2 as "saucerSmall"
ExportAssets (56)Timeline Frame 1Symbol 3 as "saucerBig"
ExportAssets (56)Timeline Frame 1Symbol 4 as "beat2"
ExportAssets (56)Timeline Frame 1Symbol 5 as "beat1"
ExportAssets (56)Timeline Frame 1Symbol 10 as "asteroid"
ExportAssets (56)Timeline Frame 1Symbol 11 as "explosion"
ExportAssets (56)Timeline Frame 1Symbol 11 as "explosion"
ExportAssets (56)Timeline Frame 1Symbol 12 as "explosion"
ExportAssets (56)Timeline Frame 3Symbol 28 as "spaceship"

Labels

"fire"Symbol 38 MovieClip Frame 2
"bangLarge"Symbol 38 MovieClip Frame 4
"bangMedium"Symbol 38 MovieClip Frame 6
"bangSmall"Symbol 38 MovieClip Frame 8
"extra"Symbol 38 MovieClip Frame 10

Dynamic Text Variables

scoreSymbol 39 EditableText"0"




http://swfchan.com/21/100182/info.shtml
Created: 21/3 -2019 11:27:36 Last modified: 21/3 -2019 11:27:36 Server time: 29/04 -2024 01:10:05