STORY LOOP FURRY PORN GAMES C SERVICES [?] [R] RND POPULAR | Archived flashes: 229595 |
/disc/ · /res/ — /show/ · /fap/ · /gg/ · /swf/ | P0001 · P2595 · P5190 |
A Very Merry Christmas! |
This is the info page for Flash #60562 |
Fireworks! |
Fireworks! |
Help What is this? This is a fireworks simulation that allows you to experiment with both color and physics to create a unique, customised fireworks show. If this is all too much for you, simply click the bright `Fireworks!’ button in the top right corner. How does it work? When you click on the ‘Properties’ button you will see a number of menu options appear. You can use these to set specific properties for a new fireworks object. They are explained in more detail below. To apply a new set of properties, simply click on ‘Launch’. This will take you to the fireworks scene, where you can test your new fireworks. Click and hold the mouse within the scene, and drag to set the fireworks to a new angle. Release the mousebutton to place the new fireworks. You can return to the properties menu again and repeat these steps to add multiple objects as long as the simulation is paused. Press P at any time to pause / resume. Random show If you don’t feel like creating a custom scene, click the bright ‘Fireworks!’ button in the top right corner, this will instantly unpause the simulation and create a random fireworks show based on pre-set parameters. To change these parameters, return to the menu and click on ‘Random show’. Whenever you’re finished, launch by clicking ‘Launch’ or ‘Fireworks!’. Fireworks A fireworks object can carry 3 different charges. A single charge is defined by 2 basic properties: type and color. These can be set in the bottom half of the properties menu(seen as 3 columns). Click on the ‘Randomize’ button to set random values for all possible properties. The sim doesn't have any sound effects because they would probably become pretty repetitive and annoying - put on some good music and enjoy. |
Fireworks simulation |
v1.0 |
Created by Rens Rongen |
<p align="left"><font face="Verdana" size="10" color="#ffffff" letterSpacing="0.000000" kerning="0"><a href="mailto:rens.rongen@gmail.com&subject=Fireworks sim">rens.rongen@gmail.com</a></font></p> |
Feel free to contact me, any questions or suggestions are welcome. (cool screenschots of fireworks also :) have fun^ |
More stuff like this, soon on.. www.flashgameproject.com |
<p align="left"><font face="Verdana" size="10" color="#ffffff" letterSpacing="0.000000" kerning="0"><a href="mailto:rens.rongen@gmail.com">rens.rongen@gmail.com</a></font></p> |
Fireworks simulation |
Loading... |
ActionScript [AS1/AS2]
Frame 1function runSim() { attachMovie("Root", "World", 1).init(_root); } runSim();Symbol 11 Buttonon (press) { _quality = ((_quality == "LOW") ? "MEDIUM" : (((_quality == "MEDIUM") ? "HIGH" : (((_quality == "HIGH") ? "BEST" : "LOW"))))); this.qual = _quality; }Symbol 31 MovieClip [Root] Frame 1#initclip 28 Object.registerClass("Root", World); #endinitclipSymbol 43 MovieClip [spark_1] Frame 5stop();Symbol 48 MovieClip [flash] Frame 5gotoAndStop (1);Symbol 49 MovieClip [glitter] Frame 2stop();Symbol 49 MovieClip [glitter] Frame 6gotoAndStop (1);Symbol 53 MovieClip [fountain3] Frame 10stop();Symbol 81 MovieClip [__Packages.World] Frame 0class World extends MovieClip { var settings, dAPI, place, md, f_list, obj_count, light_count, wind, gravity, drag, root_y, objects, rdelay, active, clip, obj_clip, light_clip, guiLink, _xmouse, _ymouse, id; function World () { super(); settings = new Settings(); dAPI = new DrawingAPI(this); place = false; md = false; f_list = {}; obj_count = 0; light_count = 0; wind = 0; gravity = 0.1; drag = 0.5; root_y = 440; objects = {}; rdelay = 10; active = false; Key.addListener(this); } function init(mc) { clip = mc; obj_clip = _root.createEmptyMovieClip("objclip", _root.getNextHighestDepth()); light_clip = _root.createEmptyMovieClip("lightclip", _root.getNextHighestDepth()); guiLink = new GUI(this); } function onEnterFrame() { for (var _local3 in f_list) { this[f_list[_local3].f](); } for (var _local2 in objects) { if (active) { if ((objects[_local2].countdown == undefined) || (objects[_local2].countdown == 0)) { objects[_local2].render(); } else { objects[_local2].countdown--; } } } } function onMouseDown() { md = true; if (place) { settings.mx = _xmouse; settings.my = _ymouse; } } function onMouseUp() { if (place) { addInstance(); guiLink.game_menu.clip.deg.removeTextField(); } md = false; place = false; } function selectObject() { guiLink.gameMode(); f_list[f_list.length] = {f:"drawStuff"}; } function drawStuff() { if (md) { dAPI.drawArc(guiLink.game_menu.clip); } else { dAPI.drawPointer(guiLink.game_menu.clip); } } function removeObjects() { for (var _local2 in objects) { objects[_local2].clip.removeMovieClip(); delete objects[_local2]; } } function clearFList() { f_list = []; } function setRandomMode() { guiLink.gameMode(); f_list[f_list.length] = {f:"getRandomInstance"}; } function getRandomInstance() { if (active) { if (rdelay < 0) { setRandom(); addInstance(); rdelay = rdelay + ((1 + settings.rFreq) + Math.round(Math.random() * 30)); } rdelay--; } } function unsetFunction(fname) { var _local2 = 0; while (_local2 < f_list.length) { if (f_list[_local2].f == fname) { f_list.splice(_local2, 1); } _local2++; } } function addInstance() { id = "f_" + obj_count; switch (settings.ftype) { case "projectile" : objects[id] = new Projectile(this, settings.getSettings()); break; default : } obj_count++; } function setRandom() { settings.randomSettings(); } function displayData(obj) { } function get windDir() { return(wind); } function set windDir(newDir) { wind = (newDir - 50) / 100; //return(windDir); } function get gravF() { return(gravity); } function set gravF(newGrav) { gravity = (newGrav - 50) / 100; //return(gravF); } }Symbol 82 MovieClip [__Packages.Settings] Frame 0class Settings { var fonts, weight, amount, thrust, delay, cd, force, rotation, mx, my, rAmount, rFreq, pDec, rForce, ftype, hexchars, avprCharge, ClipsP, color_1, color_2, color_3, amount_1, amount_2, amount_3, type_1, type_2, type_3; function Settings () { fonts = new CustomFont(); weight = 60; amount = 35; thrust = 10; delay = 50; cd = 10; force = 10; rotation = 0; mx = 100; my = 100; rAmount = 20; rFreq = 30; pDec = 2; rForce = 20; ftype = "projectile"; hexchars = ["1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "a", "b", "c", "d", "e", "f"]; avprCharge = [{txt:"Particles", val:"Particle"}, {txt:"Glitter", val:"GlitterP"}, {txt:"Splash", val:"SplashP"}, {txt:"Flash", val:"FlashP"}, {txt:"Spread", val:"SpreadP"}, {txt:"Streak", val:"StreakP"}, {txt:"Flame", val:"FlameP"}, {txt:"Fountain", val:"FountainP"}]; ClipsP = {GlitterP:"glitter", SplashP:"flame", Particle:"spark_1", FlashP:"flash", SpreadP:"spark_3", StreakP:"fountain", FlameP:"flame", FountainP:"fountain"}; color_1 = "0xffffff"; color_2 = "0xffffff"; color_3 = "0xffffff"; amount_1 = 30; amount_2 = 0; amount_3 = 0; type_1 = "Particle"; type_2 = "Particle"; type_3 = "Particle"; } function randomSettings() { weight = 30 + (Math.random() * 70); amount = 20 + (Math.random() * 40); thrust = 15 + (Math.random() * 40); rotation = (-(MathX.PI / 6)) + (Math.random() * (MathX.PI / 3)); delay = Math.round(Math.random() * 40); cd = Math.round(Math.random() * 10); force = 5 + (Math.random() * rForce); mx = Math.random() * 500; var _local3 = 1; while (_local3 <= 3) { var _local4 = "0x"; var _local2 = 0; while (_local2 < 6) { _local4 = _local4 + hexchars[Math.round(Math.random() * 15)]; _local2++; } this["color_" + _local3] = _local4; this["amount_" + _local3] = Math.random() * rAmount; this["type_" + _local3] = avprCharge[Math.round(Math.random() * (avprCharge.length - 1))].val; _local3++; } } function set decay(num) { pDec = num / 25; //return(decay); } function get decay() { return(pDec * 25); } function getSettings() { var _local2 = {weight:weight, amount:amount, thrust:thrust, delay:delay, cd:cd, mx:mx, my:my, force:force, rotation:rotation, ftype:ftype, color_1:color_1, color_2:color_2, color_3:color_3, amount_1:amount_1, amount_2:amount_2, amount_3:amount_3, type_1:type_1, type_2:type_2, type_3:type_3}; return(_local2); } }Symbol 83 MovieClip [__Packages.CustomFont] Frame 0class CustomFont { var interface1, interface2, interface3; function CustomFont () { var _local2 = new TextFormat(); _local2.font = "Verdana"; _local2.bold = true; _local2.size = 10; var _local4 = new TextFormat(); _local4.font = "Verdana"; _local4.bold = true; _local4.size = 10; var _local3 = new TextFormat(); _local3.font = "Verdana"; _local3.size = 10; interface1 = {a:{s:"textColor", p:15395562}, b:{s:"selectable", p:false}, c:{s:"embedFonts", p:false}, d:{s:"embedCustom", p:_local2}}; interface2 = {a:{s:"textColor", p:16777215}, b:{s:"selectable", p:false}, c:{s:"embedFonts", p:false}, d:{s:"type", p:"dynamic"}, e:{s:"embedCustom", p:_local2}}; interface3 = {a:{s:"textColor", p:13421772}, b:{s:"selectable", p:false}, c:{s:"embedFonts", p:false}, d:{s:"type", p:"dynamic"}, e:{s:"embedCustom", p:_local3}}; } }Symbol 84 MovieClip [__Packages.Particle] Frame 0class Particle { var parent, id, cx, cy, altitude, ef, sx, sy, hexcol, dir, fx, fy, alpha, scale, ctype, clip, colorObj; function Particle (parent, vars) { this.parent = parent; id = vars.id; cx = vars.cx; cy = vars.cy; altitude = vars.alt; ef = vars.ef; sx = 0; sy = 0; hexcol = vars.hexcol; dir = Math.random() * 360; fx = (Math.sin(dir) * (-0.5 + (Math.random() * ef))) + (vars.sx / 5); fy = ((Math.cos(dir) * (-0.5 + (Math.random() * ef))) - (vars.sy / 5)) * -1; alpha = 100; scale = 100 + (Math.random() * 90); ctype = vars.ctype; attachClip(parent.obj_clip); } function render() { if (((altitude < 0) || (alpha < 0)) || (scale < 0)) { clip.removeMovieClip(); delete parent.objects[id]; } var _local2 = parent.gravity * 0.2; fx = fx / 2; fy = fy / 2; fx = fx + parent.windDir; fy = fy + (_local2 * 2); sx = sx + fx; sy = sy + fy; cx = cx + sx; cy = cy + sy; altitude = altitude - sy; alpha = alpha - parent.settings.pDec; scale = scale - parent.settings.pDec; setClip(); } function attachClip(mc) { clip = mc.createEmptyMovieClip(id, mc.getNextHighestDepth()); clip.attachMovie(ctype, id, clip.getNextHighestDepth()); clip.attachMovie("spark_4", id + "_", clip.getNextHighestDepth()); if (ctype == "spark_3") { clip[id].gotoAndPlay(Math.round(Math.random() * 20)); } clip._rotation = Math.random() * 360; colorObj = new Color(clip[id]); colorObj.setRGB(hexcol); setClip(); } function setClip() { clip._x = cx; clip._y = cy; clip._xscale = (clip._yscale = scale); clip._alpha = alpha; } }Symbol 85 MovieClip [__Packages.GlitterP] Frame 0class GlitterP extends Particle { var tm, alpha, scale, cd, rnd, altitude, clip, id, parent, hexcol, fx, fy, sx, sy, cx, cy, setClip; function GlitterP (parent, vars) { super(parent, vars); tm = 70; alpha = 0; scale = 10 + (Math.random() * 20); cd = -10; rnd = 30 + Math.round(Math.random() * 30); } function render() { if ((altitude < 0) || (tm < 0)) { clip.removeMovieClip(); delete parent.objects[id]; } if (tm == 70) { alpha = Math.random() * 100; } if (tm == rnd) { clip.gotoAndPlay(2); var _local2 = parent.obj_count + "_p"; var _local3 = {id:_local2, cx:0, alpha:100, adec:0, sc:50 + (Math.random() * 200), sdec:0, tm:5, cy:0, hexcol:hexcol, clip:"flash"}; parent.objects[_local2] = new Lightning(parent, clip, _local3); parent.obj_count++; } if (tm < 70) { cd = (((alpha <= 0) || (alpha >= 100)) ? (-cd) : (cd)); alpha = alpha + cd; } var _local6 = parent.gravity * 0.6; fx = fx / 2; fy = fy / 2; fx = fx + parent.windDir; sx = sx + fx; sy = sy + fy; cx = cx + sx; cy = cy + sy; altitude = altitude - sy; tm--; setClip(); } }Symbol 86 MovieClip [__Packages.Lightning] Frame 0class Lightning { var parent, cx, cy, alpha, adec, sc, sdec, tm, id, clip, colorObj; function Lightning (parent, holder, vars) { this.parent = parent; cx = vars.cx; cy = vars.cy; alpha = vars.alpha; adec = vars.adec; sc = vars.sc; sdec = vars.sdec; tm = vars.tm; id = vars.id; clip = holder.attachMovie(vars.clip, id, holder.getNextHighestDepth()); colorObj = new Color(clip); colorObj.setRGB(vars.hexcol); setClip(); parent.obj_count++; } function render() { tm--; alpha = alpha - adec; sc = sc - sdec; if (((alpha <= 0) || (tm == 0)) || (sc <= 0)) { removeObject(); } else { setClip(); } } function removeObject() { clip.removeMovieClip(); delete parent.objects[id]; } function setClip() { clip._x = cx; clip._y = cy; clip._xscale = (clip._yscale = sc); clip._alpha = alpha; } }Symbol 87 MovieClip [__Packages.SplashP] Frame 0class SplashP extends Particle { var tm, alpha, scale, altitude, clip, id, parent, fx, fy, sx, sy, cx, cy, setClip, hexcol; function SplashP (parent, vars) { super(parent, vars); tm = 50; alpha = 50; scale = 100; } function render() { if ((altitude < 0) || (alpha < 0)) { clip.removeMovieClip(); delete parent.objects[id]; } var _local4 = parent.gravity * 0.2; fx = fx / 2; fy = fy / 2; fx = fx + parent.windDir; fy = fy + _local4; sx = sx + fx; sy = sy + fy; cx = cx + sx; cy = cy + sy; altitude = altitude - sy; alpha = alpha - parent.settings.pDec; scale = scale - 1; setClip(); var _local2 = parent.obj_count + "_p"; var _local3 = {id:_local2, cx:cx, cy:cy, sx:sx, sy:sy, tm:10, ef:0, hexcol:hexcol, alt:altitude, ctype:"spark_3"}; parent.objects[_local2] = new Particle(parent, _local3); parent.obj_count++; } }Symbol 88 MovieClip [__Packages.FlashP] Frame 0class FlashP extends Particle { var tm, alpha, scale, cd, altitude, clip, id, parent, fx, fy, sx, sy, cx, cy, setClip; function FlashP (parent, vars) { super(parent, vars); tm = vars.tm; alpha = 50 + (Math.random() * 50); scale = 10 + (Math.random() * 50); cd = -10; } function render() { if (((altitude < 0) || (tm < 0)) || (scale < 0)) { clip.removeMovieClip(); delete parent.objects[id]; } var _local2 = parent.gravity * 0.6; fx = fx / 4; fy = fy / 4; fx = fx + parent.windDir; fy = fy + (_local2 / 5); sx = sx + fx; sy = sy + fy; cx = cx + sx; cy = cy + sy; altitude = altitude - sy; alpha = alpha + cd; scale = scale - 1; tm--; cd = (((alpha <= 50) || (alpha >= 100)) ? (-cd) : (cd)); setClip(); } }Symbol 89 MovieClip [__Packages.SpreadP] Frame 0class SpreadP extends Particle { var tm, alpha, scale, rnd, altitude, parent, hexcol, sy, sx, cy, cx, clip, id, fx, fy, rotation; function SpreadP (parent, vars) { super(parent, vars); tm = 50; alpha = 50; scale = 100; rnd = Math.random() * 5; } function render() { if (((altitude < 0) || (alpha < (28 + rnd))) || (scale < 0)) { var _local9 = Math.round(Math.random() * 2) + 1; var _local3 = 0; while (_local3 < _local9) { var _local2 = parent.obj_count + "_p"; var _local10 = {id:_local2, cx:cx, cy:cy, tm:20, sx:sx * 2, sy:sy * 2, ef:5, hexcol:hexcol, alt:altitude, ctype:"fountain3"}; parent.objects[_local2] = new StreakP(parent, _local10); parent.obj_count++; _local3++; } var _local2 = parent.obj_count + "_p"; var _local10 = {id:_local2, cx:cx, alpha:100, adec:0, sc:50, sdec:0, tm:5, cy:cy, hexcol:16777215, clip:"flash"}; parent.objects[_local2] = new Lightning(parent, parent.light_clip, _local10); parent.obj_count++; clip.removeMovieClip(); delete parent.objects[id]; } var _local11 = parent.gravity * 0.2; fx = fx / 2; fy = fy / 2; fx = fx + parent.windDir; fy = fy + _local11; sx = sx + fx; sy = sy + fy; cx = cx + sx; cy = cy + sy; altitude = altitude - sy; alpha = alpha - parent.settings.pDec; scale = scale - 1; rotation = (Math.atan2(sy, sx) * (180 / MathX.PI)) + 90; setClip(); } function setClip() { clip._x = cx; clip._y = cy; clip._xscale = (clip._yscale = scale); clip._alpha = alpha; clip._rotation = rotation; } }Symbol 90 MovieClip [__Packages.StreakP] Frame 0class StreakP extends Particle { var alpha, scale, sx, sy, altitude, clip, id, parent, fx, fy, cx, cy, rotation; function StreakP (parent, vars) { super(parent, vars); alpha = 100; scale = 100; sx = vars.sx / 4; sy = vars.sy / 4; } function render() { if ((altitude < 0) || (alpha < 0)) { clip.removeMovieClip(); delete parent.objects[id]; } var _local2 = parent.gravity * 0.2; fx = fx / 3; fy = fy / 3; fx = fx + parent.windDir; fy = fy + (_local2 * 2); sx = sx + fx; sy = sy + fy; cx = cx + sx; cy = cy + sy; altitude = altitude - sy; alpha = alpha - parent.settings.pDec; rotation = (Math.atan2(sy, sx) * (180 / MathX.PI)) + 90; setClip(); } function setClip() { clip._x = cx; clip._y = cy; clip._xscale = (clip._yscale = Math.abs(Math.pow((sx * sx) + (sy * sy), 0.5) * 20)); clip._alpha = alpha; clip._rotation = rotation; } }Symbol 91 MovieClip [__Packages.MathX] Frame 0class MathX { function MathX () { } static var PI = 3.14159; }Symbol 92 MovieClip [__Packages.FlameP] Frame 0class FlameP extends Particle { var tm, alpha, scale, altitude, clip, id, parent, fx, fy, sx, sy, cx, cy, hexcol, rotation; function FlameP (parent, vars) { super(parent, vars); tm = 50; alpha = 100; scale = 100; } function render() { if (((altitude < 0) || (alpha < 0)) || (scale < 0)) { clip.removeMovieClip(); delete parent.objects[id]; } var _local4 = parent.gravity * 0.2; fx = fx / 2; fy = fy / 2; fx = fx + parent.windDir; fy = fy + (_local4 * 3); sx = sx + fx; sy = sy + fy; cx = cx + sx; cy = cy + sy; altitude = altitude - sy; alpha = alpha - parent.settings.pDec; scale = scale - 1; if (tm < 45) { var _local2 = parent.obj_count + "_p"; var _local3 = {id:_local2, cx:cx, cy:cy, sx:sx, sy:sy, ef:0, tm:6, sc:scale, hexcol:hexcol, alt:altitude, ctype:"fountain_2"}; parent.objects[_local2] = new StaticP(parent, _local3); parent.obj_count++; } tm--; setClip(); } function setClip() { clip._x = cx; clip._y = cy; clip._xscale = (clip._yscale = scale); clip._alpha = alpha; clip._rotation = rotation; } }Symbol 93 MovieClip [__Packages.StaticP] Frame 0class StaticP extends Particle { var tm, alpha, scale, altitude, clip, id, parent, fx, fy, sx, sy, cx, cy, setClip; function StaticP (parent, vars) { super(parent, vars); tm = vars.tm; alpha = 100; scale = vars.sc; } function render() { if (((altitude < 0) || (alpha < 0)) || (tm < 0)) { clip.removeMovieClip(); delete parent.objects[id]; } tm--; var _local2 = parent.gravity * 0.2; fx = fx / 2; fy = fy / 2; fx = fx + parent.windDir; fy = fy + (_local2 * 3); sx = sx + fx; sy = sy + fy; cx = cx + sx; cy = cy + sy; altitude = altitude - sy; alpha = alpha - 15; scale = scale - parent.settings.pDec; setClip(); } }Symbol 94 MovieClip [__Packages.FountainP] Frame 0class FountainP extends Particle { var tm, alpha, scale, rnd, altitude, parent, hexcol, sy, sx, cy, cx, clip, id, fx, fy, rotation; function FountainP (parent, vars) { super(parent, vars); tm = 50; alpha = 50; scale = 100; rnd = Math.random() * 5; } function render() { if (((altitude < 0) || (alpha < (28 + rnd))) || (scale < 0)) { var _local9 = Math.round(Math.random() * 0) + 1; var _local3 = 0; while (_local3 < _local9) { var _local2 = parent.obj_count + "_p"; var _local10 = {id:_local2, cx:cx, cy:cy, sx:sx * 5, sy:sy * 5, tm:10, ef:0, hexcol:hexcol, alt:altitude, ctype:"spark_3"}; parent.objects[_local2] = new SplashP(parent, _local10); parent.obj_count++; _local3++; } var _local2 = parent.obj_count + "_p"; var _local10 = {id:_local2, cx:cx, alpha:100, adec:0, sc:50, sdec:0, tm:5, cy:cy, hexcol:16777215, clip:"flash"}; parent.objects[_local2] = new Lightning(parent, parent.light_clip, _local10); parent.obj_count++; clip.removeMovieClip(); delete parent.objects[id]; } var _local11 = parent.gravity * 0.2; fx = fx / 2; fy = fy / 2; fx = fx + parent.windDir; fy = fy + _local11; sx = sx + fx; sy = sy + fy; cx = cx + sx; cy = cy + sy; altitude = altitude - sy; alpha = alpha - parent.settings.pDec; scale = scale - 1; rotation = (Math.atan2(sy, sx) * (180 / MathX.PI)) + 90; setClip(); } function setClip() { clip._x = cx; clip._y = cy; clip._xscale = (clip._yscale = scale); clip._alpha = alpha; clip._rotation = rotation; } }Symbol 95 MovieClip [__Packages.DrawingAPI] Frame 0class DrawingAPI { var parent; function DrawingAPI (parent) { this.parent = parent; } function drawPointer(clip) { clip.clear(); if (((_ymouse < parent.root_y) && (_xmouse > 10)) && (_xmouse < 490)) { clip.lineStyle(1, 56576, 100); clip.moveTo(_xmouse - 5, parent.root_y); clip.lineTo(_xmouse, parent.root_y + 10); clip.moveTo(_xmouse + 5, parent.root_y); clip.lineTo(_xmouse, parent.root_y + 10); parent.place = true; } else { parent.place = false; if ((_xmouse <= 10) || (_xmouse >= 490)) { clip.lineStyle(1, 15597568, 100); clip.moveTo(_xmouse - 5, _ymouse - 5); clip.lineTo(_xmouse + 5, _ymouse + 5); clip.moveTo(_xmouse + 5, _ymouse - 5); clip.lineTo(_xmouse - 5, _ymouse + 5); } } } function drawArc(clip) { if (_ymouse < parent.root_y) { var _local5 = Math.atan2(parent.root_y - _ymouse, parent.settings.mx - _xmouse) - (Math.PI/2); parent.settings.rotation = (-_local5) + (-0.1 + (Math.random() * 0.2)); var _local4 = parent.settings.mx + (3 * (Math.sin(_local5) * 57.2957795130823)); var _local3 = parent.root_y + ((3 * (Math.cos(_local5) * 57.2957795130823)) * -1); clip.clear(); clip.lineStyle(2, 56576, 100); clip.moveTo(parent.settings.mx - 5, parent.root_y); clip.lineTo(parent.settings.mx, parent.root_y + 10); clip.moveTo(parent.settings.mx + 5, parent.root_y); clip.lineTo(parent.settings.mx, parent.root_y + 10); clip.lineStyle(1, 255, 100); clip.moveTo(parent.settings.mx, parent.root_y); clip.lineTo(_local4, _local3); clip.lineStyle(1, 16777215, 100); clip.lineStyle(1, 16777215, 100); clip.moveTo(_xmouse - 5, _ymouse - 5); clip.lineTo(_xmouse + 5, _ymouse + 5); clip.moveTo(_xmouse + 5, _ymouse - 5); clip.lineTo(_xmouse - 5, _ymouse + 5); new CustomText(clip, {cx:parent.settings.mx - 8, cy:parent.root_y + 10, wd:100, ht:20, dp:1, id:"deg", txt:Math.round(Math.abs(_local5) * 57.2957795130823) + "\u00B0", d:parent.settings.fonts.interface1}); } } }Symbol 96 MovieClip [__Packages.CustomText] Frame 0class CustomText { var parent, cx, cy, wd, ht, dp, id, txt, c, def, txtForm; function CustomText (parent, props) { this.parent = parent; cx = props.cx; cy = props.cy; wd = props.wd; ht = props.ht; dp = props.dp; id = props.id; txt = props.txt; c = props.c; def = props.d; getTextField(); } function getTextField() { if (parent[id] != null) { parent[id].removeTextField(); } parent.createTextField(id, dp, cx, cy, wd, ht); for (var _local2 in def) { if (def[_local2].s == "embedCustom") { txtForm = def[_local2].p; } else if (parent[id][def[_local2].s] != null) { parent[id][def[_local2].s] = def[_local2].p; } } gsTxt = (txt); } function set gsTxt(newTxt) { txt = newTxt; parent[id].text = txt; if (txtForm != null) { parent[id].setTextFormat(txtForm); } //return(gsTxt); } function removeText() { parent[id].removeTextField(); } function get gsTxt() { return(txt); } }Symbol 97 MovieClip [__Packages.GUI] Frame 0class GUI { var clip, parent, components, pri_menu, sec_menu, game_menu, count, current, select, help, rInit, textFields, typeObject, info_txt; function GUI (parent) { clip = parent.clip.createEmptyMovieClip("gui_clip", parent.clip.getNextHighestDepth()); this.parent = parent; components = {}; parent.events = new EventChannels(components); pri_menu = {cx:20, cy:20}; sec_menu = {cx:110, cy:20}; game_menu = {cx:0, cy:0}; count = 0; current = 1; select = 0; help = false; rInit = false; textFields = {}; typeObject = {slider:"Slider", select:"Select", cbtn:"CustomBtn", colors:"ColorSelect", wndsl:"ActiveSlider", quicks:"Quickstart"}; sec_menu.clip = clip.attachMovie("panel_sec", "panel_sec_clip", clip.getNextHighestDepth()); pri_menu.clip = clip.attachMovie("panel_pri", "panel_pri_clip", clip.getNextHighestDepth()); game_menu.clip = clip.attachMovie("panel_game", "panel_game_clip", clip.getNextHighestDepth()); pri_menu.clip.qual = _quality; game_menu.clip._visible = false; pri_menu.clip._x = pri_menu.cx; pri_menu.clip._y = pri_menu.cy; sec_menu.clip._x = sec_menu.cx; sec_menu.clip._y = sec_menu.cy; game_menu.clip._x = game_menu.cx; game_menu.clip._y = game_menu.cy; createOptMenu(0); createOptMenu(current); var _local3 = parent.settings.fonts.interface1; info_txt = new CustomText(clip, {cx:2, cy:1, wd:200, ht:20, dp:clip.getNextHighestDepth(), id:"info_txt", txt:"Paused, press P to unpause.", d:_local3}); Key.addListener(this); } function showMenu(sh) { clip._visible = (sh ? true : false); } function createOptMenu(ftype) { select = 0; switch (ftype) { case 1 : var _local2 = parent.settings.fonts.interface1; textFields.fuel_txt = new CustomText(sec_menu.clip, {cx:-89, cy:60, wd:100, ht:20, dp:1, id:"fuel_txt", txt:"Properties(%)", d:_local2}); textFields.charge_txt = new CustomText(sec_menu.clip, {cx:-50, cy:220, wd:100, ht:20, dp:3, id:"charge_txt", txt:"Bursting charge", d:_local2}); addComponent("slider", {cx:-50, cy:130, ref:"amount", c:"sec_menu"}, "Fuel amount"); addComponent("slider", {cx:90, cy:130, ref:"thrust", c:"sec_menu"}, "Thrust"); addComponent("slider", {cx:-50, cy:190, ref:"delay", c:"sec_menu"}, "Charge delay"); addComponent("slider", {cx:90, cy:160, ref:"weight", c:"sec_menu"}, "Weight"); addComponent("slider", {cx:-50, cy:160, ref:"cd", c:"sec_menu"}, "Launch delay"); addComponent("slider", {cx:90, cy:190, ref:"force", c:"sec_menu"}, "Explosive force"); addComponent("slider", {cx:90, cy:90, ref:"decay", c:"sec_menu"}, "Particle decay"); addComponent("colors", {cx:-30, cy:280, ref:"color_1", c:"sec_menu", fList:""}, "Color 1"); addComponent("colors", {cx:80, cy:280, ref:"color_2", c:"sec_menu", fList:""}, "Color 2"); addComponent("colors", {cx:190, cy:280, ref:"color_3", c:"sec_menu", fList:""}, "Color 3"); addComponent("select", {cx:-50, cy:240, ref:"type_1", c:"sec_menu", list:parent.settings.avprCharge}, "Type 1"); addComponent("select", {cx:60, cy:240, ref:"type_2", c:"sec_menu", list:parent.settings.avprCharge}, "Type 2"); addComponent("select", {cx:170, cy:240, ref:"type_3", c:"sec_menu", list:parent.settings.avprCharge}, "Type 3"); addComponent("slider", {cx:-40, cy:430, ref:"amount_1", c:"sec_menu"}, "Amount 1"); addComponent("slider", {cx:70, cy:430, ref:"amount_2", c:"sec_menu"}, "Amount 2"); addComponent("slider", {cx:180, cy:430, ref:"amount_3", c:"sec_menu"}, "Amount 3"); addComponent("cbtn", {cx:-89, cy:80, ref:1, c:"sec_menu", fList:["base.updateSettings"]}, "Randomize"); addComponent("cbtn", {cx:-89, cy:450, ref:3, c:"sec_menu", fList:["ptr.selectObject"]}, "Launch"); sec_menu.clip._visible = true; break; case 2 : break; case 3 : addComponent("wndsl", {cx:220, cy:480, ref:"windDir", c:"game_menu"}, "Wind force"); addComponent("wndsl", {cx:10, cy:480, ref:"gravF", c:"game_menu"}, "Overall gravity"); addComponent("cbtn", {cx:424, cy:460, ref:0, c:"game_menu", fList:["ptr.removeObjects"]}, "Clear"); addComponent("cbtn", {cx:424, cy:480, ref:0, c:"game_menu", fList:["base.designMode"]}, "Menu"); break; case 4 : textFields.random_info = new CustomText(pri_menu.clip, {cx:0, cy:60, wd:130, ht:20, dp:pri_menu.clip.getNextHighestDepth(), id:"rand_info", txt:"Custom parameters", d:parent.settings.fonts.interface1}); addComponent("slider", {cx:20, cy:130, ref:"rAmount", c:"pri_menu"}, "Average amount"); addComponent("slider", {cx:160, cy:130, ref:"rFreq", c:"pri_menu"}, "Launch frequency"); addComponent("slider", {cx:20, cy:170, ref:"decay", c:"pri_menu"}, "Particle decay"); addComponent("slider", {cx:160, cy:170, ref:"rForce", c:"pri_menu"}, "Avr. explosive force"); addComponent("cbtn", {cx:0, cy:220, ref:-1, c:"pri_menu", fList:["ptr.setRandomMode"]}, "Launch"); break; case 5 : default : addComponent("cbtn", {cx:0, cy:5, ref:2, c:"pri_menu", fList:["base.clearOptMenu", "base.createOptMenu", "base.showHelp"]}, "Help"); addComponent("cbtn", {cx:100, cy:5, ref:1, c:"pri_menu", fList:["base.clearOptMenu", "base.createOptMenu"]}, "Properties"); addComponent("cbtn", {cx:200, cy:5, ref:4, c:"pri_menu", fList:["base.setRandom"]}, "Random show"); addComponent("quicks", {cx:420, cy:10, ref:0, c:"pri_menu", fList:["ptr.setRandomMode"]}); } } function clearOptMenu() { if (help) { showHelp(); } for (var _local5 in components) { var _local3 = 0; while (_local3 < arguments.length) { this[arguments[_local3]].clip._visible = false; if (((components[_local5].c == arguments[_local3]) || ((arguments[_local3] == 1) && (components[_local5].c == "sec_menu"))) || ((arguments[_local3] == 2) && (components[_local5].c == "sec_menu"))) { components[_local5].clip.removeMovieClip(); parent.events.removeListener(components[_local5]); delete components[_local5]; } _local3++; } if (((components[_local5].type == "slider") && (components[_local5].c == "pri_menu")) || (components[_local5].ref < 0)) { components[_local5].clip.removeMovieClip(); parent.events.removeListener(components[_local5]); delete components[_local5]; } } for (var _local4 in textFields) { textFields[_local4].parent[textFields[_local4].id].removeTextField(); } rInit = false; } function updateSettings(n) { parent.setRandom(); clearOptMenu("sec_menu"); createOptMenu(n); } function clearGameMenu() { game_menu.clip._visible = false; for (var _local2 in components) { if (components[_local2].c == "game_menu") { components[_local2].clip.removeMovieClip(); parent.events.removeListener(components[_local2]); delete components[_local2]; } } } function designMode() { Mouse.show(); if (parent.active) { parent.removeObjects(); } parent.clearFList(); clearGameMenu(); createOptMenu(null); createOptMenu(1); pri_menu.clip._visible = true; } function gameMode() { clearOptMenu("pri_menu", "sec_menu"); createOptMenu(3); game_menu.clip._visible = true; } function setRandom() { if (!rInit) { clearOptMenu("sec_menu"); createOptMenu(4); rInit = true; } } function addComponent(cType, prm, info) { prm.base = this; var _local2 = "guic_" + count; components[_local2] = new eval ([typeObject[cType]])(cType, prm, info); } function showHelp() { if (!help) { help = true; clip.attachMovie("help_menu", "help_menu", clip.getNextHighestDepth()); clip.help_menu._x = 0; clip.help_menu._y = 15; } else { help = false; clip.help_menu.removeMovieClip(); } } function onKeyDown() { parent.active = (parent.active ? false : true); switch (Key.getCode()) { case 80 : if (parent.active) { info_txt.parent[info_txt.id].removeTextField(); } else { var _local2 = parent.settings.fonts.interface1; info_txt = new CustomText(clip, {cx:2, cy:1, wd:200, ht:20, dp:clip.getNextHighestDepth(), id:"info_txt", txt:"Paused, press P to unpause.", d:_local2}); } break; default : } } }Symbol 98 MovieClip [__Packages.EventChannels] Frame 0class EventChannels { var objList; function EventChannels (objList) { this.objList = objList; Mouse.addListener(this); Key.addListener(this); } function addListener(obj) { var _local3 = 1; while (_local3 < arguments.length) { obj.eventList[obj.eventList.length] = arguments[_local3]; var _local4 = arguments[_local3]; if (this[_local4] == null) { addChannel(obj.id, _local4); } this[_local4 + xt].list[obj.id] = obj.id; this[_local4 + xt].length++; _local3++; } } function removeListener(obj) { var _local5 = new Array(); _local5 = ((arguments.length == 1) ? (obj.eventList) : (arguments.splice(1, arguments.length))); var _local4 = 0; while (_local4 < _local5.length) { var _local3 = _local5[_local4]; delete this[_local3 + xt].list[obj.id]; this[_local3 + xt].length--; if (this[_local3 + xt].length < 1) { delete this[_local3]; delete this[_local3 + xt]; } _local4++; } } function addChannel(obj, channel) { this[channel + xt] = {length:0, list:{}}; this[channel] = function () { for (var _local2 in this[channel + EventChannels.xt].list) { this.objList[this[channel + EventChannels.xt].list[_local2]][channel](); } }; } static var xt = "_l"; }Symbol 99 MovieClip [__Packages.GUIComponent] Frame 0class GUIComponent { var type, cx, cy, c, base, ptr, ref, id, info, clip, eventList; function GUIComponent (cType, prm, info) { type = cType; cx = prm.cx; cy = prm.cy; c = prm.c; base = prm.base; ptr = base.parent; ref = prm.ref; id = "guic_" + base.count; this.info = info; clip = base[prm.c].clip.createEmptyMovieClip(id, base.count); clip._x = cx; clip._y = cy; type = cType; eventList = []; base.count++; } }Symbol 100 MovieClip [__Packages.Slider] Frame 0class Slider extends GUIComponent { var ptr, txtObj, clip, ref, id, info; function Slider (cType, prm, info) { super(cType, prm, info); ptr.events.addListener(this, "onMouseDown", "onMouseUp"); txtObj = {}; getClip(); } function getClip() { clip.attachMovie("slider_bar", "slider_bar", 1); clip.attachMovie("slider_obj", "slider_obj", 2); clip.slider_obj._x = ptr.settings[ref]; clip.slider_obj._y = -3; var _local2 = ptr.settings.fonts.interface1; txtObj = new CustomText(clip, {cx:40, cy:-15, wd:30, ht:20, dp:3, id:id, txt:Math.round(ptr.settings[ref]), d:_local2}); _local2 = ptr.settings.fonts.interface2; new CustomText(clip, {cx:-20, cy:-23, wd:130, ht:20, dp:4, id:id + "_s", txt:info, d:_local2}); } function onMouseDown() { if (clip.slider_bar.hitTest(_xmouse, _ymouse, false)) { ptr.events.addListener(this, "onMouseMove"); } } function onMouseMove() { var _local2 = clip.slider_bar._xmouse; if ((_local2 >= 0) && (_local2 <= 100)) { txtObj.gsTxt = Math.round(_local2); clip.slider_obj._x = (ptr.settings[ref] = _local2); } } function onMouseUp() { var _local2 = clip.slider_bar._xmouse; if ((clip.slider_bar.hitTest(_xmouse, _ymouse, false) && (_local2 >= 0)) && (_local2 <= 100)) { txtObj.gsTxt = Math.round(_local2); clip.slider_obj._x = (ptr.settings[ref] = _local2); } ptr.events.removeListener(this, "onMouseMove"); } }Symbol 101 MovieClip [__Packages.Select] Frame 0class Select extends GUIComponent { var list, current, ref, ptr, active, clip, id, def, base; function Select (cType, prm, info) { super(cType, prm, info); list = prm.list; current = 0; var _local3 = 0; while (_local3 < list.length) { if (list[_local3].val == ptr.settings[ref]) { current = _local3; } _local3++; } active = false; ptr.events.addListener(this, "onMouseUp"); clip.attachMovie("select_main", id, clip.getNextHighestDepth()); clip.attachMovie("lines", "lines_c", clip.getNextHighestDepth()); def = ptr.settings.fonts.interface1; writeText(0, 0); } function onMouseUp() { if (clip[id].hitTest(_xmouse, _ymouse, false)) { if (!active) { ptr.events.addListener(this); var _local2 = 0; while (_local2 < list.length) { var _local3 = "s_" + _local2; clip[id].attachMovie("select_sub", _local3, _local2); clip[id][_local3]._x = 0; clip[id][_local3]._y = 16 + (_local2 * 15); clip[id][_local3].gotoAndStop(1); new CustomText(clip[id][_local3], {cx:15, cy:0, wd:60, ht:20, dp:clip[id][_local3].getNextHighestDepth(), id:id, txt:list[_local2].txt, d:def}); clip[id][_local3].onRollOver = function () { this.gotoAndStop(2); }; clip[id][_local3].onRollOut = function () { this.gotoAndStop(1); }; _local2++; } active = true; base.select++; } else { var _local2 = 0; while (_local2 < list.length) { var _local3 = "s_" + _local2; if (clip[id][_local3].hitTest(_xmouse, _ymouse, false)) { current = _local2; ptr.settings[ref] = list[current].val; } clip[id][_local3].removeMovieClip(); _local2++; } active = false; base.select--; } } writeText(0, 0); } function writeText(cx, cy) { new CustomText(clip[id], {cx:cx, cy:cy, wd:60, ht:20, dp:clip[id].getNextHighestDepth(), id:id, txt:list[current].txt, d:def}); } }Symbol 102 MovieClip [__Packages.CustomBtn] Frame 0class CustomBtn extends GUIComponent { var functions, clip, ptr, ref; function CustomBtn (cType, prm, info) { super(cType, prm, info); functions = prm.fList; clip.attachMovie("cbtn", "c_btn", 1); clip.txt = info; ptr.events.addListener(this, "onMouseUp"); } function onMouseUp() { if (clip.hitTest(_xmouse, _ymouse, false)) { var _local2 = 0; while (_local2 < functions.length) { var _local4 = functions[_local2].substr(0, functions[_local2].indexOf(".")); var _local3 = functions[_local2].substr(functions[_local2].indexOf(".") + 1, functions[_local2].length); this[_local4][_local3](ref); _local2++; } } } }Symbol 103 MovieClip [__Packages.ColorSelect] Frame 0class ColorSelect extends GUIComponent { var currentHex, ref, ptr, sub, preview, clip, testObj, id, base, sel, active; function ColorSelect (cType, prm, info) { super(cType, prm, info); currentHex = ptr.settings[ref]; sub = {}; preview = {clip:clip.createEmptyMovieClip("prev", clip.getNextHighestDepth()), ball:clip.attachMovie("ball", "ball", clip.getNextHighestDepth())}; preview.ball._x = 45; preview.ball._y = 110; testObj = new Color(preview.ball); drawColor(); ptr.events.addListener(this, "onMouseDown", "onMouseUp"); var _local3 = ptr.settings.fonts.interface2; new CustomText(clip, {cx:-15, cy:-20, wd:100, ht:20, dp:clip.getNextHighestDepth(), id:id + "_s", txt:info, d:_local3}); } function drawColor() { var _local6 = [16711680, 65280, 255]; var _local3 = 0; while (_local3 < 3) { var _local2 = "s_" + _local3; sub[_local2] = {clip:clip.createEmptyMovieClip(_local2 + "c", clip.getNextHighestDepth()), lc:clip.createEmptyMovieClip(_local2 + "l", clip.getNextHighestDepth()), val:0}; sub[_local2].lc._x = _local3 * 9; sub[_local2].clip.lineStyle(1, 16777215, 0); sub[_local2].clip.beginGradientFill("linear", [0, _local6[_local3]], [0, 100], [0, 255], {matrixType:"box", x:0, y:0, w:15, h:100, r:(Math.PI/2)}); var _local4 = _local3 * 18; var _local5 = 0.392156862745098 * toDec(String(currentHex).substr(2 + (_local3 * 2), 2)); sub[_local2].clip.moveTo(_local4, 0); sub[_local2].clip.lineStyle(1, 16777215, 50); sub[_local2].clip.lineTo(15 + _local4, 0); sub[_local2].clip.lineStyle(1, 16777215, 0); sub[_local2].clip.lineTo(15 + _local4, 100); sub[_local2].clip.lineStyle(2, _local6[_local3], 100); sub[_local2].clip.lineTo(_local4, 100); sub[_local2].clip.lineStyle(1, 16777215, 0); sub[_local2].clip.lineTo(_local4, 0); sub[_local2].clip.endFill(); sub[_local2].val = String(currentHex).substr(2 + (_local3 * 2), 2); sub[_local2].lc.lineStyle(3, 16777215, _local5 + 50); sub[_local2].lc.moveTo(sub[_local2].lc._x, _local5); sub[_local2].lc.lineTo(sub[_local2].lc._x + 15, _local5); _local3++; } var _local15 = ptr.settings.fonts.interface3; new CustomText(clip, {cx:0, cy:115, wd:100, ht:20, dp:clip.getNextHighestDepth(), id:id + "hex", txt:currentHex, d:_local15}); previewFill(); } function onMouseDown() { if (base.select == 0) { for (var _local2 in sub) { if (sub[_local2].clip.hitTest(_xmouse, _ymouse, false)) { sel = sub[_local2]; ptr.events.addListener(this, "onMouseMove"); onMouseMove(); active = true; } } } } function onMouseUp() { if (active) { ptr.events.removeListener(this, "onMouseMove"); active = false; } } function onMouseMove() { if ((sel.lc._ymouse >= 0) && (sel.lc._ymouse <= 100)) { sel.lc.clear(); sel.lc.lineStyle(3, 16777215, sel.lc._ymouse + 50); sel.lc.moveTo(sel.lc._x, sel.lc._ymouse); sel.lc.lineTo(sel.lc._x + 15, sel.lc._ymouse); sel.val = toHex(Math.round(2.55 * sel.lc._ymouse)); currentHex = ""; for (var _local2 in sub) { currentHex = sub[_local2].val + currentHex; } currentHex = "0x" + currentHex; ptr.settings[ref] = String(currentHex); previewFill(); var _local3 = ptr.settings.fonts.interface3; new CustomText(clip, {cx:0, cy:115, wd:100, ht:20, dp:clip.getNextHighestDepth(), id:id + "hex", txt:currentHex, d:_local3}); } } function toHex(num) { var _local3 = ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "a", "b", "c", "d", "e", "f"]; var _local1 = new Number(num); var _local2 = "" + ((num < 16) ? "0" : ""); while (_local1 >= 16) { _local2 = _local2 + String(_local3[Math.floor(_local1 / 16)]); _local1 = _local1 - (16 * Math.floor(_local1 / 16)); } _local2 = _local2 + String(_local3[_local1]); return(_local2); } function toDec(hex) { var _local4 = {e0:0, e1:1, e2:2, e3:3, e4:4, e5:5, e6:6, e7:7, e8:8, e9:9, ea:10, eb:11, ec:12, ed:13, ee:14, ef:15}; var _local3 = 0; var _local2 = ""; while (hex.length > 1) { _local2 = hex.slice(0, 1); hex = hex.substr(1, hex.length); _local3 = _local3 + (16 * _local4["e" + _local2]); } _local2 = hex.slice(0, 1); _local3 = _local3 + _local4["e" + _local2]; return(_local3); } function previewFill() { preview.clip.clear(); preview.clip.beginFill(Number(currentHex), 100); preview.clip.lineStyle(1, 16777215, 0); preview.clip.moveTo(0, 105); preview.clip.lineTo(32, 105); preview.clip.lineTo(32, 115); preview.clip.lineTo(0, 115); preview.clip.lineTo(0, 105); preview.clip.endFill(); testObj.setRGB(Number(currentHex)); } }Symbol 104 MovieClip [__Packages.ActiveSlider] Frame 0class ActiveSlider extends GUIComponent { var ptr, clip, id, ref, md, cv; function ActiveSlider (cType, prm, info) { super(cType, prm, info); ptr.events.addListener(this, "onMouseDown", "onMouseUp"); clip.attachMovie("active_slider", "active_slider_c", clip.getNextHighestDepth()); new CustomText(clip, {cx:60, cy:-20, wd:100, ht:20, dp:clip.getNextHighestDepth(), id:id + "_s", txt:info, d:ptr.settings.fonts.interface2}); clip.active_slider_c.txt = ptr[ref]; clip.lineStyle(1, 16777215, 100); clip.moveTo(100 + (ptr[ref] * 200), 0); clip.lineTo(100 + (ptr[ref] * 200), 10); clip.onRollOver = function () { }; } function onMouseDown() { if (clip.hitTest(_xmouse, _ymouse, false)) { md = true; ptr.events.addListener(this, "onMouseMove"); } } function onMouseUp() { if (md) { ptr.events.removeListener(this, "onMouseMove"); md = false; onMouseMove(); } } function onMouseMove() { if ((clip._xmouse > 0) && (clip._xmouse < 200)) { clip.clear(); clip.lineStyle(1, 16777215, 100); clip.moveTo(clip._xmouse, 0); clip.lineTo(clip._xmouse, 10); cv = clip._xmouse / 2; ptr[ref] = cv; clip.active_slider_c.txt = ptr[ref]; } } }Symbol 105 MovieClip [__Packages.Quickstart] Frame 0class Quickstart extends GUIComponent { var functions, clip, ptr, base, ref; function Quickstart (cType, prm, info) { super(cType, prm, info); functions = prm.fList; clip.attachMovie("gobtn", "c_btn", 100); ptr.events.addListener(this, "onMouseDown"); getAnim(); } function onMouseDown() { if (clip.hitTest(_xmouse, _ymouse, true)) { if (!ptr.active) { base.info_txt.parent[base.info_txt.id].removeTextField(); } ptr.active = true; var _local2 = 0; while (_local2 < functions.length) { var _local4 = functions[_local2].substr(0, functions[_local2].indexOf(".")); var _local3 = functions[_local2].substr(functions[_local2].indexOf(".") + 1, functions[_local2].length); this[_local4][_local3](ref); _local2++; } } } function getAnim() { var _local2 = 0; while (_local2 < 10) { clip.attachMovie("fountain3", "f_" + _local2, 1 + _local2); clip["f_" + _local2]._height = 100 + (Math.random() * 100); clip["f_" + _local2]._rotation = Math.random() * 360; _local2++; } } }Symbol 106 MovieClip [__Packages.Fireworks] Frame 0class Fireworks { var parent, cx, cy, id, clip; function Fireworks (parent, vars) { this.parent = parent; cx = vars.mx; cy = parent.root_y; id = parent.id; getClip(); } function getClip() { clip = parent.obj_clip.attachMovie("arrow", parent.id, parent.obj_count); clip._x = cx; clip._y = cy; } }Symbol 107 MovieClip [__Packages.Projectile] Frame 0class Projectile extends Fireworks { var dir, rotation, weight, thrust, fuel, amount_1, amount_2, amount_3, delay, countdown, ef, fx, fy, sx, sy, color_1, color_2, color_3, type_1, type_2, type_3, altitude, speed, parent, vars, cy, cx, clip, id; function Projectile (parent, vars) { super(parent, vars); dir = (-vars.rotation) * (180 / MathX.PI); rotation = dir; weight = vars.weight; thrust = vars.thrust / 50; fuel = vars.amount; amount_1 = vars.amount_1; amount_2 = vars.amount_2; amount_3 = vars.amount_3; delay = vars.delay; countdown = vars.cd; ef = vars.force; fx = 0; fy = 0; sx = 0; sy = 0; color_1 = Number(vars.color_1); color_2 = Number(vars.color_2); color_3 = Number(vars.color_3); type_1 = parent.settings.type_1; type_2 = parent.settings.type_2; type_3 = parent.settings.type_3; altitude = 0; speed = 0; vars = {}; setClip(); } function render() { delay--; if (fuel <= 0) { thrust = 0; if (delay <= 0) { explode(); } } else { fuel = fuel - (thrust * 3); var _local2 = parent.obj_count + "_p"; vars = {id:_local2, cx:cx, cy:cy, sx:0, sy:0, ef:0, hexcol:16777215, alt:altitude, ctype:"spark_5"}; parent.objects[_local2] = new StaticP(parent, vars); parent.obj_count++; } if (altitude < 0) { explode(); } if (((cx + sx) < 0) || ((cx + sx) > 500)) { cx = (((cx + sx) < 0) ? 0 : 500); sx = -sx; } speed = Math.sqrt((sx * sx) + (sy * sy)); var _local3 = (weight * parent.gravity) / 100; fx = Math.sin(dir * (MathX.PI / 180)) * thrust; fy = (Math.cos(dir * (MathX.PI / 180)) * thrust) * -1; fx = fx - (sx / 100); fy = fy - (sy / 100); fx = fx + parent.windDir; fy = fy + _local3; sx = sx + fx; sy = sy + fy; cx = cx + sx; cy = cy + sy; altitude = altitude - sy; rotation = (Math.atan2(sy, sx) * (180 / MathX.PI)) + 90; dir = rotation; setClip(); } function explode() { var _local2 = 1; while (_local2 <= 3) { var _local5 = this["type_" + _local2]; var _local4 = 0; while (_local4 < this["amount_" + _local2]) { var _local3 = parent.obj_count + "_p"; vars = {id:_local3, cx:cx, cy:cy, sx:sx, sy:sy, tm:50, ef:ef, hexcol:this["color_" + _local2], alt:altitude, ctype:parent.settings.ClipsP[_local5]}; parent.objects[_local3] = new eval ([_local5])(parent, vars); parent.obj_count++; _local4++; } _local2++; } var _local3 = parent.obj_count + "_p"; vars = {id:_local3, cx:cx, alpha:100, adec:0, sc:100 + (ef * 3), sdec:0, tm:5, cy:cy, hexcol:16777215, clip:"flash"}; parent.objects[_local3] = new Lightning(parent, parent.light_clip, vars); parent.obj_count++; clip.removeMovieClip(); delete parent.objects[id]; } function setClip() { clip._x = cx; clip._y = cy; clip._rotation = rotation; } }
Library Items
Symbol 1 Graphic | Used by:2 | |
Symbol 2 MovieClip [slider_bar] | Uses:1 | |
Symbol 3 Graphic | Used by:4 | |
Symbol 4 MovieClip [slider_obj] | Uses:3 | |
Symbol 5 MovieClip [options_bg] | ||
Symbol 6 MovieClip [panel_game] | ||
Symbol 7 Graphic | Used by:12 | |
Symbol 8 Font | Used by:9 64 66 67 68 69 73 | |
Symbol 9 EditableText | Uses:8 | Used by:11 |
Symbol 10 Graphic | Used by:11 21 62 | |
Symbol 11 Button | Uses:9 10 | Used by:12 |
Symbol 12 MovieClip [panel_pri] | Uses:7 11 | |
Symbol 13 Graphic | Used by:14 | |
Symbol 14 MovieClip [panel_sec] | Uses:13 | |
Symbol 15 Graphic | Used by:21 | |
Symbol 16 Font | Used by:17 19 20 35 60 61 64 65 68 71 73 74 77 | |
Symbol 17 EditableText | Uses:16 | Used by:21 |
Symbol 18 Graphic | Used by:21 | |
Symbol 19 EditableText | Uses:16 | Used by:21 |
Symbol 20 EditableText | Uses:16 | Used by:21 |
Symbol 21 Button [cbtn] | Uses:15 17 18 19 20 10 | |
Symbol 22 Graphic | Used by:23 | |
Symbol 23 MovieClip [select_main] | Uses:22 | |
Symbol 24 Graphic | Used by:26 | |
Symbol 25 Graphic | Used by:26 | |
Symbol 26 MovieClip [select_sub] | Uses:24 25 | |
Symbol 27 ShapeTweening | Used by:30 | |
Symbol 28 ShapeTweening | Used by:30 | |
Symbol 29 Graphic | Used by:30 | |
Symbol 30 MovieClip [ball] | Uses:27 28 29 | |
Symbol 31 MovieClip [Root] | ||
Symbol 32 Graphic | Used by:33 | |
Symbol 33 MovieClip [arrow] | Uses:32 | |
Symbol 34 Graphic | Used by:36 | |
Symbol 35 EditableText | Uses:16 | Used by:36 |
Symbol 36 MovieClip [active_slider] | Uses:34 35 | |
Symbol 37 Graphic | Used by:38 | |
Symbol 38 MovieClip [spark_4] | Uses:37 | |
Symbol 39 Graphic | Used by:41 43 48 49 | |
Symbol 40 Graphic | Used by:41 | |
Symbol 41 MovieClip [spark_3] | Uses:39 40 | |
Symbol 42 Graphic | Used by:43 49 | |
Symbol 43 MovieClip [spark_1] | Uses:42 39 | |
Symbol 44 Graphic | Used by:48 49 | |
Symbol 45 Graphic | Used by:48 49 | |
Symbol 46 Graphic | Used by:48 49 | |
Symbol 47 Graphic | Used by:48 49 | |
Symbol 48 MovieClip [flash] | Uses:39 44 45 46 47 | |
Symbol 49 MovieClip [glitter] | Uses:42 39 44 45 46 47 | |
Symbol 50 Graphic | Used by:53 | |
Symbol 51 ShapeTweening | Used by:53 | |
Symbol 52 Graphic | Used by:53 | |
Symbol 53 MovieClip [fountain3] | Uses:50 51 52 | |
Symbol 54 Graphic | Used by:55 | |
Symbol 55 MovieClip [fountain] | Uses:54 | |
Symbol 56 Graphic | Used by:57 | |
Symbol 57 MovieClip [fountain_2] | Uses:56 | |
Symbol 58 Graphic | Used by:59 | |
Symbol 59 MovieClip [flame] | Uses:58 | |
Symbol 60 Text | Uses:16 | Used by:62 |
Symbol 61 Text | Uses:16 | Used by:62 |
Symbol 62 Button [gobtn] | Uses:60 61 10 | |
Symbol 63 Graphic | Used by:70 | |
Symbol 64 Text | Uses:16 8 | Used by:70 |
Symbol 65 Text | Uses:16 | Used by:70 |
Symbol 66 Text | Uses:8 | Used by:70 75 |
Symbol 67 Text | Uses:8 | Used by:70 75 |
Symbol 68 EditableText | Uses:8 16 | Used by:70 |
Symbol 69 Text | Uses:8 | Used by:70 |
Symbol 70 MovieClip [help_menu] | Uses:63 64 65 66 67 68 69 | |
Symbol 71 Text | Uses:16 | Used by:75 |
Symbol 72 Text | Used by:75 | |
Symbol 73 EditableText | Uses:8 16 | Used by:75 |
Symbol 74 Text | Uses:16 | Used by:75 |
Symbol 75 MovieClip [sponsor] | Uses:71 72 67 73 74 66 | |
Symbol 76 Graphic | Used by:78 | |
Symbol 77 Text | Uses:16 | Used by:78 |
Symbol 78 MovieClip [loading_bar] | Uses:76 77 | |
Symbol 79 Graphic | Used by:80 | |
Symbol 80 MovieClip [lines] | Uses:79 | |
Symbol 81 MovieClip [__Packages.World] | ||
Symbol 82 MovieClip [__Packages.Settings] | ||
Symbol 83 MovieClip [__Packages.CustomFont] | ||
Symbol 84 MovieClip [__Packages.Particle] | ||
Symbol 85 MovieClip [__Packages.GlitterP] | ||
Symbol 86 MovieClip [__Packages.Lightning] | ||
Symbol 87 MovieClip [__Packages.SplashP] | ||
Symbol 88 MovieClip [__Packages.FlashP] | ||
Symbol 89 MovieClip [__Packages.SpreadP] | ||
Symbol 90 MovieClip [__Packages.StreakP] | ||
Symbol 91 MovieClip [__Packages.MathX] | ||
Symbol 92 MovieClip [__Packages.FlameP] | ||
Symbol 93 MovieClip [__Packages.StaticP] | ||
Symbol 94 MovieClip [__Packages.FountainP] | ||
Symbol 95 MovieClip [__Packages.DrawingAPI] | ||
Symbol 96 MovieClip [__Packages.CustomText] | ||
Symbol 97 MovieClip [__Packages.GUI] | ||
Symbol 98 MovieClip [__Packages.EventChannels] | ||
Symbol 99 MovieClip [__Packages.GUIComponent] | ||
Symbol 100 MovieClip [__Packages.Slider] | ||
Symbol 101 MovieClip [__Packages.Select] | ||
Symbol 102 MovieClip [__Packages.CustomBtn] | ||
Symbol 103 MovieClip [__Packages.ColorSelect] | ||
Symbol 104 MovieClip [__Packages.ActiveSlider] | ||
Symbol 105 MovieClip [__Packages.Quickstart] | ||
Symbol 106 MovieClip [__Packages.Fireworks] | ||
Symbol 107 MovieClip [__Packages.Projectile] |
Special Tags
FileAttributes (69) | Timeline Frame 1 | Access local files only, Metadata not present, AS1/AS2. |
ExportAssets (56) | Timeline Frame 1 | Symbol 2 as "slider_bar" |
ExportAssets (56) | Timeline Frame 1 | Symbol 4 as "slider_obj" |
ExportAssets (56) | Timeline Frame 1 | Symbol 5 as "options_bg" |
ExportAssets (56) | Timeline Frame 1 | Symbol 6 as "panel_game" |
ExportAssets (56) | Timeline Frame 1 | Symbol 12 as "panel_pri" |
ExportAssets (56) | Timeline Frame 1 | Symbol 14 as "panel_sec" |
ExportAssets (56) | Timeline Frame 1 | Symbol 21 as "cbtn" |
ExportAssets (56) | Timeline Frame 1 | Symbol 23 as "select_main" |
ExportAssets (56) | Timeline Frame 1 | Symbol 26 as "select_sub" |
ExportAssets (56) | Timeline Frame 1 | Symbol 30 as "ball" |
ExportAssets (56) | Timeline Frame 1 | Symbol 31 as "Root" |
ExportAssets (56) | Timeline Frame 1 | Symbol 33 as "arrow" |
ExportAssets (56) | Timeline Frame 1 | Symbol 36 as "active_slider" |
ExportAssets (56) | Timeline Frame 1 | Symbol 38 as "spark_4" |
ExportAssets (56) | Timeline Frame 1 | Symbol 41 as "spark_3" |
ExportAssets (56) | Timeline Frame 1 | Symbol 43 as "spark_1" |
ExportAssets (56) | Timeline Frame 1 | Symbol 48 as "flash" |
ExportAssets (56) | Timeline Frame 1 | Symbol 49 as "glitter" |
ExportAssets (56) | Timeline Frame 1 | Symbol 53 as "fountain3" |
ExportAssets (56) | Timeline Frame 1 | Symbol 55 as "fountain" |
ExportAssets (56) | Timeline Frame 1 | Symbol 57 as "fountain_2" |
ExportAssets (56) | Timeline Frame 1 | Symbol 59 as "flame" |
ExportAssets (56) | Timeline Frame 1 | Symbol 62 as "gobtn" |
ExportAssets (56) | Timeline Frame 1 | Symbol 70 as "help_menu" |
ExportAssets (56) | Timeline Frame 1 | Symbol 75 as "sponsor" |
ExportAssets (56) | Timeline Frame 1 | Symbol 78 as "loading_bar" |
ExportAssets (56) | Timeline Frame 1 | Symbol 80 as "lines" |
ExportAssets (56) | Timeline Frame 1 | Symbol 81 as "__Packages.World" |
ExportAssets (56) | Timeline Frame 1 | Symbol 82 as "__Packages.Settings" |
ExportAssets (56) | Timeline Frame 1 | Symbol 83 as "__Packages.CustomFont" |
ExportAssets (56) | Timeline Frame 1 | Symbol 84 as "__Packages.Particle" |
ExportAssets (56) | Timeline Frame 1 | Symbol 85 as "__Packages.GlitterP" |
ExportAssets (56) | Timeline Frame 1 | Symbol 86 as "__Packages.Lightning" |
ExportAssets (56) | Timeline Frame 1 | Symbol 87 as "__Packages.SplashP" |
ExportAssets (56) | Timeline Frame 1 | Symbol 88 as "__Packages.FlashP" |
ExportAssets (56) | Timeline Frame 1 | Symbol 89 as "__Packages.SpreadP" |
ExportAssets (56) | Timeline Frame 1 | Symbol 90 as "__Packages.StreakP" |
ExportAssets (56) | Timeline Frame 1 | Symbol 91 as "__Packages.MathX" |
ExportAssets (56) | Timeline Frame 1 | Symbol 92 as "__Packages.FlameP" |
ExportAssets (56) | Timeline Frame 1 | Symbol 93 as "__Packages.StaticP" |
ExportAssets (56) | Timeline Frame 1 | Symbol 94 as "__Packages.FountainP" |
ExportAssets (56) | Timeline Frame 1 | Symbol 95 as "__Packages.DrawingAPI" |
ExportAssets (56) | Timeline Frame 1 | Symbol 96 as "__Packages.CustomText" |
ExportAssets (56) | Timeline Frame 1 | Symbol 97 as "__Packages.GUI" |
ExportAssets (56) | Timeline Frame 1 | Symbol 98 as "__Packages.EventChannels" |
ExportAssets (56) | Timeline Frame 1 | Symbol 99 as "__Packages.GUIComponent" |
ExportAssets (56) | Timeline Frame 1 | Symbol 100 as "__Packages.Slider" |
ExportAssets (56) | Timeline Frame 1 | Symbol 101 as "__Packages.Select" |
ExportAssets (56) | Timeline Frame 1 | Symbol 102 as "__Packages.CustomBtn" |
ExportAssets (56) | Timeline Frame 1 | Symbol 103 as "__Packages.ColorSelect" |
ExportAssets (56) | Timeline Frame 1 | Symbol 104 as "__Packages.ActiveSlider" |
ExportAssets (56) | Timeline Frame 1 | Symbol 105 as "__Packages.Quickstart" |
ExportAssets (56) | Timeline Frame 1 | Symbol 106 as "__Packages.Fireworks" |
ExportAssets (56) | Timeline Frame 1 | Symbol 107 as "__Packages.Projectile" |
Dynamic Text Variables
qual | Symbol 9 EditableText | "" |
txt | Symbol 17 EditableText | "" |
txt | Symbol 19 EditableText | "" |
txt | Symbol 20 EditableText | "" |
txt | Symbol 35 EditableText | "" |
|