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

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

h2o panic.swf

This is the info page for
Flash #56834

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


Text
Press spacebar to begin!

[press enter for help]

<p align="center"><font face="Franklin Gothic Medium Cond" size="20" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>10</b></font></p>

The ball has

lives left.

WINS!

Press Ctrl to play again

You destroyed him! You're a hero!

Arrow Keys

Mouse

ActionScript [AS3]

Section 1
//electric_12 (h2opanic_fla.electric_12) package h2opanic_fla { import flash.display.*; public dynamic class electric_12 extends MovieClip { public function electric_12(){ addFrameScript(0, frame1, 4, frame5); } function frame1(){ stop(); } function frame5(){ stop(); } } }//package h2opanic_fla
Section 2
//AAGun (AAGun) package { import flash.events.*; import flash.display.*; public class AAGun extends MovieClip { private var ay:Number;// = 0 private var ax:Number;// = 0 var speed:Number;// = 1 private var vx:Number;// = 0 private var vy:Number;// = 0 public function AAGun(){ speed = 1; ax = 0; vx = 0; vy = 0; ay = 0; super(); this.x = 275; this.y = 50; addEventListener(Event.ENTER_FRAME, moveGun); } public function moveGun(_arg1:Event){ var newx:*; var newy:*; var myKeyUp:Function; var event = _arg1; myKeyUp = function (_arg1:KeyboardEvent):void{ trace("myKeyUp"); ax = 0; ay = 0; }; newx = this.x; newy = this.y; if (MovieClip(parent).A_Button){ newx = (newx - speed); ax = -0.2; vx = (vx + ax); vy = (vy + ay); newx = (newx + vx); newy = (newy + vy); }; if (MovieClip(parent).D_Button){ newx = (newx + speed); ax = 0.2; vx = (vx + ax); vy = (vy + ay); newx = (newx + vx); newy = (newy + vy); }; if (MovieClip(parent).W_Button){ newy = (newy - speed); ay = -0.2; vx = (vx + ax); vy = (vy + ay); newx = (newx + vx); newy = (newy + vy); }; if (MovieClip(parent).S_Button){ newy = (newy + speed); ay = 0.2; vx = (vx + ax); vy = (vy + ay); newx = (newx + vx); newy = (newy + vy); }; if (newx < 10){ newx = 10; }; if (newx > 540){ newx = 540; }; if (newy < 20){ newy = 20; }; if (newy > 380){ newy = 380; }; this.x = newx; this.y = newy; } } }//package
Section 3
//Asteroid (Asteroid) package { import flash.events.*; import flash.display.*; public class Asteroid extends MovieClip { var canStartAsteroid;// = true private var vx:Number; private var vy:Number;// = -400 public function Asteroid(){ vy = -400; canStartAsteroid = true; super(); addFrameScript(0, frame1); init(); } private function init():void{ this.y = (this.y + vy); addEventListener(Event.ENTER_FRAME, onEnterFrame); } public function resetAsteroid():void{ this.y = ((Math.random() * -100) - 100); this.x = (Math.random() * 550); vy = ((Math.random() * 2) + 4); } public function startAsteroid():void{ if (canStartAsteroid == true){ this.x = (Math.random() * 550); this.y = ((Math.random() * -100) - 100); vy = ((Math.random() * 2) + 4); canStartAsteroid = false; }; } function frame1(){ stop(); } private function onEnterFrame(_arg1:Event):void{ if (canStartAsteroid == false){ this.y = (this.y + vy); }; if ((this.y - 50) > stage.stageHeight){ this.y = ((Math.random() * -400) - 100); this.x = (Math.random() * 550); vy = ((Math.random() * 2) + 4); canStartAsteroid = true; }; } } }//package
Section 4
//Bullet (Bullet) package { import flash.events.*; import flash.display.*; public class Bullet extends MovieClip { private var myBulletRotation:Number;// = 0 private var deltaY; private var deltaX; private var bulletMoving:Boolean;// = false public function Bullet(){ bulletMoving = false; myBulletRotation = 0; super(); init(); } public function startBullet(_arg1, _arg2, _arg3, _arg4, _arg5:Number):void{ if (bulletMoving == false){ this.x = _arg1; this.y = _arg2; deltaX = _arg3; deltaY = _arg4; myBulletRotation = _arg5; this.rotation = myBulletRotation; bulletMoving = true; }; } public function init():void{ this.x = 150; this.y = 600; addEventListener(Event.ENTER_FRAME, moveBullet); } public function resetBullet():void{ this.x = 150; this.y = 600; bulletMoving = false; } public function moveBullet(_arg1:Event){ if (bulletMoving == true){ this.y = (this.y + deltaY); this.x = (this.x + deltaX); if ((((((((this.y < 0)) || ((this.y > 400)))) || ((this.x < 0)))) || ((this.x > 550)))){ this.x = 150; this.y = 600; bulletMoving = false; }; }; } } }//package
Section 5
//elec (elec) package { import flash.display.*; public dynamic class elec extends MovieClip { } }//package
Section 6
//gunshot (gunshot) package { import flash.media.*; public dynamic class gunshot extends Sound { } }//package
Section 7
//popcork (popcork) package { import flash.media.*; public dynamic class popcork extends Sound { } }//package
Section 8
//popcork2 (popcork2) package { import flash.media.*; public dynamic class popcork2 extends Sound { } }//package
Section 9
//popcork3 (popcork3) package { import flash.media.*; public dynamic class popcork3 extends Sound { } }//package
Section 10
//StartTrigGame (StartTrigGame) package { import flash.events.*; import flash.media.*; import flash.display.*; import flash.text.*; import flash.utils.*; public class StartTrigGame extends MovieClip { public var left:Boolean; public var txtScore:TextField; public var right:Boolean; var canFire:Boolean;// = true private var myHitSound3:Sound; public var jump:Boolean; private var myHitSound2:Sound; private var numAsteroids:Number;// = 8 public var W_Button; var shotxspeed:Number;// = 0 public var grav:Number; private var asteroidArray:Array; private var bulletArray:Array; var bulletSpeed:Number;// = 5 public var acc:Number; public var test:int; public var up:Boolean; private var score:int;// = 10 public var jumpAble; public var down:Boolean; public var minusNumNum:Number; public var S_Button; public var vx:Number; public var vy:Number; public var startit2:Boolean; public var startit3:Boolean; public var time:Number; var shotyspeed:Number;// = 0 public var jumpHeight:Number; public var minusNum:Number; var myTimer:Timer; private var myHitSound:Sound; public var startit:Boolean; public var A_Button; public var maxSpeed:Number; public var elec1:MovieClip; private var numBullets:Number;// = 17 public var man:MovieClip; var whichBullet:Number;// = 0 public var ground:MovieClip; public var D_Button:Boolean; public var timerTime:Timer; public var water_mc:MovieClip; private var myCannon:AAGun; public var startit16:Boolean; var whichAsteroid:Number;// = 0 public function StartTrigGame(){ score = 10; bulletSpeed = 5; shotxspeed = 0; shotyspeed = 0; numBullets = 17; whichBullet = 0; canFire = true; numAsteroids = 8; whichAsteroid = 0; super(); addFrameScript(0, frame1, 1, frame2, 2, frame3, 3, frame4, 4, frame5, 5, frame6); init(); } function timerFunction(_arg1:TimerEvent):void{ asteroidArray[whichAsteroid].startAsteroid(); whichAsteroid++; if (whichAsteroid >= (asteroidArray.length - 1)){ whichAsteroid = 0; }; } public function gravity(_arg1){ grav++; if (man.hitTestObject(ground)){ grav--; grav = 0; grav = (grav - (jumpHeight / minusNum)); minusNum = (minusNum + minusNumNum); jumpAble = true; if (minusNum >= jumpHeight){ minusNumNum = 0; grav = (grav + (jumpHeight / minusNum)); }; }; if (right){ vx++; }; if (left){ vx--; }; if (((!(right)) && (!(left)))){ vx = (vx * acc); }; if (((((man.x + man.width) > 550)) || (((man.x - man.width) < 0)))){ vx = (vx * -6); }; if (vx >= maxSpeed){ vx = maxSpeed; }; if (vx <= -(maxSpeed)){ vx = -(maxSpeed); }; if (up){ if (jumpAble){ grav = (grav - jumpHeight); jumpAble = false; minusNum = 2; minusNumNum = 2; }; }; man.y = (man.y + grav); man.x = (man.x + vx); } function frame3(){ stop(); grav = 5; jump = false; vx = 10; vy = 10; acc = 0.9; maxSpeed = 11; jumpHeight = 14; jumpAble = false; minusNum = 2; minusNumNum = 2; stage.addEventListener(Event.ENTER_FRAME, gravity); timerTime = new Timer(1000, 100); timerTime.addEventListener(TimerEvent.TIMER, timerCountDown); timerTime.start(); time = 100; test = 95; if (man.hitTestObject(water_mc)){ grav = 20; trace("WHYWONTYOUWORK"); jumpHeight = 1; maxSpeed = 2; }; } function frame4(){ stop(); stop(); score = 10; startit3 = false; stage.addEventListener(KeyboardEvent.KEY_DOWN, keyDown4); timerTime.stop(); time = 100; } function frame5(){ stop(); score = 10; startit2 = false; stage.addEventListener(KeyboardEvent.KEY_DOWN, keyDown3); timerTime.stop(); time = 100; } function frame6(){ stop(); } function frame1(){ stop(); startit = false; stage.addEventListener(KeyboardEvent.KEY_DOWN, keyDown2); startit16 = false; stage.addEventListener(KeyboardEvent.KEY_DOWN, keyDown16); } public function timerCountDown(_arg1:TimerEvent):void{ time--; if (time == 0){ gotoAndPlay(4); }; if (time == 13){ elec1.gotoAndPlay(2); }; } function frame2(){ right = false; left = false; up = false; down = false; stage.addEventListener(KeyboardEvent.KEY_DOWN, checkKeys); stage.addEventListener(KeyboardEvent.KEY_UP, checkKeyUp); } public function keyDown2(_arg1:KeyboardEvent){ if (_arg1.keyCode == 32){ startit = true; gotoAndPlay(2); }; } public function keyDown4(_arg1:KeyboardEvent){ if (_arg1.keyCode == 17){ startit3 = true; gotoAndPlay(1); }; } public function keyDown3(_arg1:KeyboardEvent){ if (_arg1.keyCode == 17){ startit2 = true; gotoAndPlay(1); }; } public function onEnterFrame(_arg1:Event):void{ var _local2:Number; var _local3:Number; var _local4:int; var _local5:int; _local2 = Math.atan2((mouseY - myCannon.y), (mouseX - myCannon.x)); _local3 = Math.round(((_local2 * 180) / Math.PI)); myCannon.rotation = _local3; _local4 = (bulletArray.length - 1); while (_local4 >= 0) { _local5 = (asteroidArray.length - 1); while (_local5 >= 0) { if (man.hitTestObject(asteroidArray[_local5])){ score++; myHitSound2.play(0, 1); trace(score); txtScore.text = String(score); asteroidArray[_local5].resetAsteroid(); }; if (bulletArray[_local4].hitTestObject(man)){ bulletArray[_local4].resetBullet(); score--; myHitSound.play(0, 1); txtScore.text = String(score); trace(score); if (score == 0){ gotoAndStop(5); }; }; if (bulletArray[_local4].hitTestObject(asteroidArray[_local5])){ myHitSound3.play(0, 1); asteroidArray[_local5].resetAsteroid(); bulletArray[_local4].resetBullet(); }; _local5--; }; _local4--; }; } public function keyDownFunction(_arg1:KeyboardEvent){ } private function init():void{ var _local1:uint; var _local2:uint; var _local3:*; var _local4:*; myHitSound = new popcork2(); myHitSound2 = new popcork(); myHitSound3 = new popcork3(); myCannon = new AAGun(); bulletArray = new Array(); asteroidArray = new Array(); _local1 = 0; while (_local1 < numAsteroids) { _local3 = new Asteroid(); addChild(_local3); asteroidArray.push(_local3); _local1++; }; addChild(myCannon); _local2 = 0; while (_local2 < numBullets) { _local4 = new Bullet(); addChild(_local4); bulletArray.push(_local4); _local2++; }; addEventListener(Event.ENTER_FRAME, onEnterFrame); stage.addEventListener(MouseEvent.MOUSE_DOWN, onMousePress); stage.addEventListener(MouseEvent.MOUSE_UP, onMyMouseUp); myTimer = new Timer(1000); myTimer.addEventListener(TimerEvent.TIMER, timerFunction); myTimer.start(); } public function checkKeys(_arg1:KeyboardEvent){ if (_arg1.keyCode == ((37) || (87))){ left = true; }; if (_arg1.keyCode == ((38) || (83))){ up = true; }; if (_arg1.keyCode == ((39) || (65))){ right = true; }; if (_arg1.keyCode == ((40) || (68))){ down = true; }; } public function checkKeyUp(_arg1:KeyboardEvent){ if (_arg1.keyCode == ((37) || (87))){ _arg1.keyCode = 0; left = false; }; if (_arg1.keyCode == ((38) || (83))){ _arg1.keyCode = 0; up = false; }; if (_arg1.keyCode == ((39) || (65))){ _arg1.keyCode = 0; right = false; }; if (_arg1.keyCode == ((40) || (68))){ _arg1.keyCode = 0; down = false; }; } public function keyDown16(_arg1:KeyboardEvent){ if (_arg1.keyCode == 13){ startit16 = true; gotoAndPlay(6); }; } public function onMyMouseUp(_arg1:MouseEvent):void{ canFire = true; } public function onMousePress(_arg1:MouseEvent):void{ var _local2:Number; var _local3:Number; var _local4:Number; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; _local2 = (myCannon.y - mouseY); _local3 = (myCannon.x - mouseX); _local4 = Math.sqrt(((_local3 * _local3) + (_local2 * _local2))); _local5 = ((myCannon.y - mouseY) / _local4); shotyspeed = (bulletSpeed * _local5); shotyspeed = (shotyspeed * -1); _local6 = ((mouseX - myCannon.x) / _local4); shotxspeed = (bulletSpeed * _local6); _local7 = Math.atan2((mouseY - myCannon.y), (mouseX - myCannon.x)); _local8 = Math.round(((_local7 * 180) / Math.PI)); if (canFire == true){ bulletArray[whichBullet].startBullet(myCannon.x, myCannon.y, shotxspeed, shotyspeed, _local8); whichBullet++; if (whichBullet >= (bulletArray.length - 1)){ whichBullet = 0; }; canFire = false; }; } } }//package
Section 11
//turret (turret) package { import flash.display.*; public dynamic class turret extends MovieClip { } }//package

Library Items

Symbol 1 Sound {popcork3}
Symbol 2 Sound {popcork2}
Symbol 3 Sound {popcork}
Symbol 4 Sound {gunshot}
Symbol 5 ShapeTweeningUsed by:9
Symbol 6 ShapeTweeningUsed by:9
Symbol 7 ShapeTweeningUsed by:9
Symbol 8 GraphicUsed by:9
Symbol 9 MovieClipUses:5 6 7 8Used by:10
Symbol 10 MovieClip {Bullet}Uses:9
Symbol 11 ShapeTweeningUsed by:14
Symbol 12 ShapeTweeningUsed by:14
Symbol 13 GraphicUsed by:14
Symbol 14 MovieClipUses:11 12 13Used by:15
Symbol 15 MovieClip {Asteroid}Uses:14
Symbol 16 GraphicUsed by:24
Symbol 17 GraphicUsed by:24
Symbol 18 GraphicUsed by:24
Symbol 19 GraphicUsed by:24
Symbol 20 GraphicUsed by:24
Symbol 21 GraphicUsed by:24
Symbol 22 GraphicUsed by:24
Symbol 23 GraphicUsed by:24
Symbol 24 MovieClip {elec}Uses:16 17 18 19 20 21 22 23Used by:68
Symbol 25 ShapeTweeningUsed by:28
Symbol 26 ShapeTweeningUsed by:28
Symbol 27 GraphicUsed by:28
Symbol 28 MovieClip {turret}Uses:25 26 27Used by:Timeline
Symbol 29 BitmapUsed by:30
Symbol 30 GraphicUses:29Used by:Timeline
Symbol 31 FontUsed by:32 65 66 67 80 81 83 88 89
Symbol 32 TextUses:31Used by:33
Symbol 33 MovieClipUses:32Used by:Timeline
Symbol 34 FontUsed by:35
Symbol 35 TextUses:34Used by:Timeline
Symbol 36 SoundUsed by:Timeline
Symbol 37 GraphicUsed by:40
Symbol 38 GraphicUsed by:40 69
Symbol 39 GraphicUsed by:40
Symbol 40 MovieClipUses:37 38 39Used by:Timeline
Symbol 41 SoundUsed by:Timeline
Symbol 42 GraphicUsed by:50
Symbol 43 GraphicUsed by:50
Symbol 44 GraphicUsed by:45
Symbol 45 MovieClipUses:44Used by:46
Symbol 46 MovieClipUses:45Used by:50
Symbol 47 GraphicUsed by:48
Symbol 48 MovieClipUses:47Used by:49
Symbol 49 MovieClipUses:48Used by:50
Symbol 50 MovieClipUses:42 43 46 49Used by:Timeline
Symbol 51 GraphicUsed by:52
Symbol 52 MovieClipUses:51Used by:Timeline
Symbol 53 ShapeTweeningUsed by:62
Symbol 54 ShapeTweeningUsed by:62
Symbol 55 ShapeTweeningUsed by:62
Symbol 56 ShapeTweeningUsed by:62
Symbol 57 ShapeTweeningUsed by:62
Symbol 58 ShapeTweeningUsed by:62
Symbol 59 ShapeTweeningUsed by:62
Symbol 60 ShapeTweeningUsed by:62
Symbol 61 GraphicUsed by:62
Symbol 62 MovieClipUses:53 54 55 56 57 58 59 60 61Used by:Timeline
Symbol 63 GraphicUsed by:64
Symbol 64 MovieClipUses:63Used by:Timeline
Symbol 65 EditableTextUses:31Used by:Timeline
Symbol 66 TextUses:31Used by:Timeline
Symbol 67 TextUses:31Used by:Timeline
Symbol 68 MovieClipUses:24Used by:69
Symbol 69 MovieClip {h2opanic_fla.electric_12}Uses:38 68Used by:Timeline
Symbol 70 GraphicUsed by:Timeline
Symbol 71 ShapeTweeningUsed by:79
Symbol 72 ShapeTweeningUsed by:79
Symbol 73 ShapeTweeningUsed by:79
Symbol 74 ShapeTweeningUsed by:79
Symbol 75 ShapeTweeningUsed by:79
Symbol 76 ShapeTweeningUsed by:79
Symbol 77 ShapeTweeningUsed by:79
Symbol 78 GraphicUsed by:79
Symbol 79 MovieClipUses:71 72 73 74 75 76 77 78Used by:Timeline
Symbol 80 TextUses:31Used by:Timeline
Symbol 81 TextUses:31Used by:82
Symbol 82 MovieClipUses:81Used by:Timeline
Symbol 83 TextUses:31Used by:Timeline
Symbol 84 GraphicUsed by:Timeline
Symbol 85 GraphicUsed by:Timeline
Symbol 86 BitmapUsed by:87
Symbol 87 GraphicUses:86Used by:Timeline
Symbol 88 TextUses:31Used by:Timeline
Symbol 89 TextUses:31Used by:Timeline

Instance Names

"water_mc"Frame 2Symbol 40 MovieClip
"man"Frame 3Symbol 62 MovieClip
"water_mc"Frame 3Symbol 40 MovieClip
"water_mc"Frame 3Symbol 40 MovieClip
"ground"Frame 3Symbol 64 MovieClip
"txtScore"Frame 3Symbol 65 EditableText
"elec1"Frame 3Symbol 69 MovieClip {h2opanic_fla.electric_12}

Special Tags

FileAttributes (69)Timeline Frame 1Access local files only, Metadata not present, AS3.




http://swfchan.com/12/56834/info.shtml
Created: 18/4 -2019 21:51:57 Last modified: 18/4 -2019 21:51:57 Server time: 26/04 -2024 07:08:55