Frame 1
function playSound(mc, sound, offset, loops, volumeMod) {
if (sfxMuteVal) {
playingSound = new Sound(mc);
playingSound.attachSound(sound);
if (volumeMod == undefined) {
volUse = sfxVolume;
}
playingSound.setVolume(volUse);
if (loops == undefined) {
loops = 1;
}
if (offset == undefined) {
offset = 0;
}
playingSound.start(offset, loops);
}
return(playingSound);
}
if (started_game) {
gotoAndStop (4);
} else {
stop();
first_game = true;
submit_score = false;
Stage.showMenu = false;
}
preloader_mc.onRelease = function () {
getURL ("http://www.rustyarcade.com/ref/burnstuffanddie/preloader", "_blank");
};
preloader_mc.onEnterFrame = function () {
preloader_mc.gotoAndStop(Math.round((_root.getBytesLoaded() / _root.getBytesTotal()) * 100));
};
alpha_level = 30;
Volume = 50;
sfxVolume = 100;
muteVal = true;
sfxMuteVal = true;
pausedVal = true;
saveData = SharedObject.getLocal("userData");
soundPlaying = "mainTheme";
if (saveData.data.game != true) {
saveData.data.ach_survive_1 = false;
saveData.data.ach_survive_2 = false;
saveData.data.ach_survive_5 = false;
saveData.data.ach_survive_10 = false;
saveData.data.ach_oxygen_5 = false;
saveData.data.ach_oxygen_10 = false;
saveData.data.ach_oxygen_20 = false;
saveData.data.ach_burn_10 = false;
saveData.data.ach_burn_20 = false;
saveData.data.ach_burn_50 = false;
saveData.data.ach_combo_5 = false;
saveData.data.ach_combo_10 = false;
saveData.data.ach_combo_20 = false;
saveData.data.ach_combo_50 = false;
saveData.data.ach_die_1 = false;
saveData.data.ach_die_5 = false;
saveData.data.ach_die_10 = false;
saveData.data.game = true;
saveData.data.died = 0;
saveData.flush();
}
Frame 2
mochi.as2.MochiAd.showPreGameAd({id:"e503c992d5a7a8e2", res:"720x405"});
Frame 3
rustyIntro.onRelease = function () {
getURL ("http://www.rustyarcade.com/ref/burnstuffanddie/intro", "_blank");
};
stop();
Frame 4
function __com_mochibot__(swfid, mc, lv, trk) {
var x;
var g;
var s;
var fv;
var sb;
var u;
var res;
var mb;
var mbc;
var pv;
mb = "__mochibot__";
mbc = "mochibot.com";
g = (_global ? (_global) : (_level0._root));
if (g[mb + swfid]) {
return(g[mb + swfid]);
}
s = System.security;
x = mc._root.getSWFVersion;
fv = (x ? (mc.getSWFVersion()) : ((_global ? 6 : 5)));
if (!s) {
s = {};
}
sb = s.sandboxType;
if (sb == "localWithFile") {
return(null);
}
x = s.allowDomain;
if (x) {
s.allowDomain(mbc);
}
x = s.allowInsecureDomain;
if (x) {
s.allowInsecureDomain(mbc);
}
pv = ((fv == 5) ? (getVersion()) : (System.capabilities.version));
u = (((((((((((("http://" + mbc) + "/my/core.swf?mv=8&fv=") + fv) + "&v=") + escape(pv)) + "&swfid=") + escape(swfid)) + "&l=") + lv) + "&f=") + mc) + (sb ? ("&sb=" + sb) : "")) + (trk ? "&t=1" : "");
lv = ((fv > 6) ? (mc.getNextHighestDepth()) : ((g[mb + "level"] ? (g[mb + "level"] + 1) : (lv))));
g[mb + "level"] = lv;
if (fv == 5) {
res = "_level" + lv;
if (!eval (res)) {
loadMovieNum (u, lv);
}
} else {
res = mc.createEmptyMovieClip(mb + swfid, lv);
res.loadMovie(u);
}
return(res);
}
__com_mochibot__("bd594f1d", this, 10301, true);
function playGame() {
gotoAndPlay (7);
}
function gotoMenu() {
gotoAndPlay (4);
}
delete_out = true;
if (!started_game) {
mochi.as2.MochiServices.connect("e503c992d5a7a8e2");
}
started_game = true;
removeMovieClip(game_over);
if (submit_score > 0) {
gotoAndStop ("submit");
}
if (instant_play && (submit_score == false)) {
instant_play = false;
gotoAndPlay (7);
} else if ((soundPlaying == "mainTheme") && (_root.muteVal)) {
backgroundMusic.stop();
soundPlaying = "menuTheme";
backgroundMusic = new Sound(_root.bgmusicmc);
backgroundMusic.attachSound("menuTheme");
backgroundMusic.setVolume(_root.Volume);
backgroundMusic.start(0, 200);
}
stop();
Instance of Symbol 178 MovieClip "bgmusicmc" in Frame 4
onClipEvent (load) {
this.swapDepths(_root.getNextHighestDepth());
}
Frame 5
num_medals = 0;
if (saveData.data.ach_survive_1) {
num_medals++;
}
if (saveData.data.ach_survive_2) {
num_medals++;
}
if (saveData.data.ach_survive_10) {
num_medals++;
}
if (saveData.data.ach_oxygen_5) {
num_medals++;
}
if (saveData.data.ach_oxygen_10) {
num_medals++;
}
if (saveData.data.ach_oxygen_20) {
num_medals++;
}
if (saveData.data.ach_burn_10) {
num_medals++;
}
if (saveData.data.ach_burn_20) {
num_medals++;
}
if (saveData.data.ach_burn_50) {
num_medals++;
}
if (saveData.data.ach_combo_5) {
num_medals++;
}
if (saveData.data.ach_combo_10) {
num_medals++;
}
if (saveData.data.ach_combo_50) {
num_medals++;
}
if (saveData.data.ach_combo_50) {
num_medals++;
}
if (saveData.data.ach_die_1) {
num_medals++;
}
if (saveData.data.ach_die_5) {
num_medals++;
}
if (saveData.data.ach_die_10) {
num_medals++;
}
medals_text = ("YOU HAVE " + num_medals) + " OUT OF 17 MEDALS";
stop();
Instance of Symbol 230 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_survive_1) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 235 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_survive_5) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 239 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_survive_2) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 242 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_survive_10) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 245 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_combo_5) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 249 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_combo_10) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 253 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_combo_20) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 257 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_combo_50) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 263 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_burn_10) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 267 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_burn_20) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 272 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_burn_50) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 277 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_die_1) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 282 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_die_5) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 285 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_die_10) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 293 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_oxygen_5) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 297 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_oxygen_10) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Instance of Symbol 300 MovieClip in Frame 5
onClipEvent (load) {
if (!_root.saveData.data.ach_oxygen_20) {
this._alpha = _root.alpha_level;
} else {
this._alpha = 100;
}
}
Frame 6
var o = {n:[4, 12, 3, 13, 10, 8, 9, 7, 3, 9, 12, 7, 8, 9, 2, 8], f:function (i, s) {
if (s.length == 16) {
return(s);
}
return(this.f(i + 1, s + this.n[i].toString(16)));
}};
var boardID = o.f(0, "");
mochi.as2.MochiScores.showLeaderboard({boardID:boardID, score:submit_score, onClose:function () {
_root.gotoMenu();
}});
submit_score = false;
stop();
Frame 7
char._x = -200;
char._y = -200;
play();
Instance of Symbol 496 MovieClip "fire" in Frame 7
onClipEvent (load) {
this._x = this._x + (Math.cos(_angle) * 20);
this._y = this._y + (Math.sin(_angle) * 20);
this._xscale = _strength;
this._yscale = _strength;
}
onClipEvent (enterFrame) {
if (_active) {
this._x = this._x + _travel;
this._x = this._x + (Math.cos(_angle) * _vel);
this._y = this._y + (Math.sin(_angle) * _vel);
this._yscale = this._yscale + _raise;
if (_vel >= 0.3) {
_vel = _vel - 0.3;
}
}
}
Frame 96
delete_out = false;
if ((soundPlaying == "menuTheme") && (_root.muteVal)) {
backgroundMusic.stop();
soundPlaying = "mainTheme";
backgroundMusic = new Sound(_root.bgmusicmc);
backgroundMusic.attachSound("mainTheme");
backgroundMusic.setVolume(_root.Volume);
backgroundMusic.start(0, 200);
}
BurnStuff.main(_root);
stop();
Symbol 36 MovieClip Frame 1
stop();
Symbol 36 MovieClip Frame 100
_root.play_button._y = 330;
stop();
Symbol 41 MovieClip Frame 10
stop();
Symbol 46 Button
on (release) {
_root.play();
}
Symbol 577 MovieClip [__Packages.mochi.as2.MochiAd] Frame 0
class mochi.as2.MochiAd
{
function MochiAd () {
}
static function getVersion() {
return("3.02 as2");
}
static function showPreGameAd(options) {
var _local26 = {clip:_root, ad_timeout:3000, fadeout_time:250, regpt:"o", method:"showPreloaderAd", color:16747008, background:16777161, outline:13994812, no_progress_bar:false, ad_started:function () {
this.clip.stop();
}, ad_finished:function () {
this.clip.play();
}, ad_failed:function () {
trace("[MochiAd] Couldn't load an ad, make sure that your game's local security sandbox is configured for Access Network Only and that you are not using ad blocking software");
}, ad_loaded:function (width, height) {
}, ad_skipped:function () {
}, ad_progress:function (percent) {
}};
options = _parseOptions(options, _local26);
if ("c862232051e0a94e1c3609b3916ddb17".substr(0) == "dfeada81ac97cde83665f81c12da7def") {
options.ad_started();
options.ad_finished();
return(undefined);
}
var clip = options.clip;
var _local22 = 11000;
var _local25 = options.ad_timeout;
delete options.ad_timeout;
var fadeout_time = options.fadeout_time;
delete options.fadeout_time;
if (!load(options)) {
options.ad_failed();
options.ad_finished();
return(undefined);
}
options.ad_started();
var mc = clip._mochiad;
mc.onUnload = function () {
options.ad_finished();
};
var _local14 = _getRes(options);
var _local4 = _local14[0];
var _local13 = _local14[1];
mc._x = _local4 * 0.5;
mc._y = _local13 * 0.5;
var chk = mc.createEmptyMovieClip("_mochiad_wait", 3);
chk._x = _local4 * -0.5;
chk._y = _local13 * -0.5;
var _local6 = chk.createEmptyMovieClip("_mochiad_bar", 4);
if (options.no_progress_bar) {
_local6._visible = false;
delete options.no_progress_bar;
} else {
_local6._x = 10;
_local6._y = _local13 - 20;
}
var _local21 = options.color;
delete options.color;
var _local19 = options.background;
delete options.background;
var _local23 = options.outline;
delete options.outline;
var _local5 = _local6.createEmptyMovieClip("_outline", 1);
_local5.beginFill(_local19);
_local5.moveTo(0, 0);
_local5.lineTo(_local4 - 20, 0);
_local5.lineTo(_local4 - 20, 10);
_local5.lineTo(0, 10);
_local5.lineTo(0, 0);
_local5.endFill();
var _local3 = _local6.createEmptyMovieClip("_inside", 2);
_local3.beginFill(_local21);
_local3.moveTo(0, 0);
_local3.lineTo(_local4 - 20, 0);
_local3.lineTo(_local4 - 20, 10);
_local3.lineTo(0, 10);
_local3.lineTo(0, 0);
_local3.endFill();
_local3._xscale = 0;
var _local7 = _local6.createEmptyMovieClip("_outline", 3);
_local7.lineStyle(0, _local23, 100);
_local7.moveTo(0, 0);
_local7.lineTo(_local4 - 20, 0);
_local7.lineTo(_local4 - 20, 10);
_local7.lineTo(0, 10);
_local7.lineTo(0, 0);
chk.ad_msec = _local22;
chk.ad_timeout = _local25;
chk.started = getTimer();
chk.showing = false;
chk.last_pcnt = 0;
chk.fadeout_time = fadeout_time;
chk.fadeFunction = function () {
var _local2 = 100 * (1 - ((getTimer() - this.fadeout_start) / this.fadeout_time));
if (_local2 > 0) {
this._parent._alpha = _local2;
} else {
var _local3 = this._parent._parent;
mochi.as2.MochiAd.unload(_local3);
delete this.onEnterFrame;
}
};
mc.lc.regContLC = function (lc_name) {
mc._containerLCName = lc_name;
};
var sendHostProgress = false;
mc.lc.sendHostLoadProgress = function (lc_name) {
sendHostProgress = true;
};
mc.lc.adLoaded = options.ad_loaded;
mc.lc.adSkipped = options.ad_skipped;
mc.lc.adjustProgress = function (msec) {
var _local2 = this.mc._mochiad_wait;
_local2.server_control = true;
_local2.started = getTimer();
_local2.ad_msec = msec;
};
mc.lc.rpc = function (callbackID, arg) {
mochi.as2.MochiAd.rpc(clip, callbackID, arg);
};
mc.rpcTestFn = function (s) {
trace("[MOCHIAD rpcTestFn] " + s);
return(s);
};
chk.onEnterFrame = function () {
var _local6 = this._parent._parent;
var _local11 = this._parent._mochiad_ctr;
var _local5 = getTimer() - this.started;
var _local3 = false;
var _local4 = _local6.getBytesTotal();
var _local8 = _local6.getBytesLoaded();
var _local2 = (100 * _local8) / _local4;
var _local10 = (100 * _local5) / chk.ad_msec;
var _local9 = this._mochiad_bar._inside;
var _local13 = Math.min(100, Math.min(_local2 || 0, _local10));
_local13 = Math.max(this.last_pcnt, _local13);
this.last_pcnt = _local13;
_local9._xscale = _local13;
options.ad_progress(_local13);
if (sendHostProgress) {
mochi.as2.MochiAd.containerNotify(clip, {id:"hostLoadPcnt", pcnt:_local2}, clip._mochiad._containerLCName);
if (_local2 == 100) {
sendHostProgress = false;
}
}
if (!chk.showing) {
var _local7 = _local11.getBytesTotal();
if ((_local7 > 0) || (typeof(_local7) == "undefined")) {
chk.showing = true;
chk.started = getTimer();
} else if ((_local5 > chk.ad_timeout) && (_local2 == 100)) {
options.ad_failed();
_local3 = true;
}
}
if (_local5 > chk.ad_msec) {
_local3 = true;
}
if (((_local4 > 0) && (_local8 >= _local4)) && (_local3)) {
if (this.server_control) {
delete this.onEnterFrame;
} else {
this.fadeout_start = getTimer();
this.onEnterFrame = chk.fadeFunction;
}
}
};
}
static function showClickAwayAd(options) {
var _local9 = {clip:_root, ad_timeout:2000, fadeout_time:250, regpt:"o", method:"showClickAwayAd", res:"300x250", no_bg:true, ad_started:function () {
}, ad_finished:function () {
}, ad_loaded:function (width, height) {
}, ad_failed:function () {
trace("[MochiAd] Couldn't load an ad, make sure that your game's local security sandbox is configured for Access Network Only and that you are not using ad blocking software");
}, ad_skipped:function () {
}};
options = _parseOptions(options, _local9);
var clip = options.clip;
var _local8 = options.ad_timeout;
delete options.ad_timeout;
if (!load(options)) {
options.ad_failed();
options.ad_finished();
return(undefined);
}
options.ad_started();
var mc = clip._mochiad;
mc.onUnload = function () {
options.ad_finished();
};
var _local4 = _getRes(options);
var _local10 = _local4[0];
var _local7 = _local4[1];
mc._x = _local10 * 0.5;
mc._y = _local7 * 0.5;
var chk = mc.createEmptyMovieClip("_mochiad_wait", 3);
chk.ad_timeout = _local8;
chk.started = getTimer();
chk.showing = false;
mc.lc.adLoaded = options.ad_loaded;
mc.lc.adSkipped = options.ad_skipped;
mc.lc.rpc = function (callbackID, arg) {
mochi.as2.MochiAd.rpc(clip, callbackID, arg);
};
mc.rpcTestFn = function (s) {
trace("[MOCHIAD rpcTestFn] " + s);
return(s);
};
var _local20 = false;
mc.lc.regContLC = function (lc_name) {
mc._containerLCName = lc_name;
};
chk.onEnterFrame = function () {
var _local5 = this._parent._mochiad_ctr;
var _local4 = getTimer() - this.started;
var _local2 = false;
if (!chk.showing) {
var _local3 = _local5.getBytesTotal();
if ((_local3 > 0) || (typeof(_local3) == "undefined")) {
_local2 = true;
chk.showing = true;
chk.started = getTimer();
} else if (_local4 > chk.ad_timeout) {
options.ad_failed();
_local2 = true;
}
}
if (_local2) {
delete this.onEnterFrame;
}
};
}
static function showInterLevelAd(options) {
var _local13 = {clip:_root, ad_timeout:2000, fadeout_time:250, regpt:"o", method:"showTimedAd", ad_started:function () {
this.clip.stop();
}, ad_finished:function () {
this.clip.play();
}, ad_failed:function () {
trace("[MochiAd] Couldn't load an ad, make sure that your game's local security sandbox is configured for Access Network Only and that you are not using ad blocking software");
}, ad_loaded:function (width, height) {
}, ad_skipped:function () {
}};
options = _parseOptions(options, _local13);
var clip = options.clip;
var _local10 = 11000;
var _local12 = options.ad_timeout;
delete options.ad_timeout;
var fadeout_time = options.fadeout_time;
delete options.fadeout_time;
if (!load(options)) {
options.ad_failed();
options.ad_finished();
return(undefined);
}
options.ad_started();
var mc = clip._mochiad;
mc.onUnload = function () {
options.ad_finished();
};
var _local5 = _getRes(options);
var _local14 = _local5[0];
var _local11 = _local5[1];
mc._x = _local14 * 0.5;
mc._y = _local11 * 0.5;
var chk = mc.createEmptyMovieClip("_mochiad_wait", 3);
chk.ad_msec = _local10;
chk.ad_timeout = _local12;
chk.started = getTimer();
chk.showing = false;
chk.fadeout_time = fadeout_time;
chk.fadeFunction = function () {
var _local2 = 100 * (1 - ((getTimer() - this.fadeout_start) / this.fadeout_time));
if (_local2 > 0) {
this._parent._alpha = _local2;
} else {
var _local3 = this._parent._parent;
mochi.as2.MochiAd.unload(_local3);
delete this.onEnterFrame;
}
};
mc.lc.adLoaded = options.ad_loaded;
mc.lc.adSkipped = options.ad_skipped;
mc.lc.adjustProgress = function (msec) {
var _local2 = this.mc._mochiad_wait;
_local2.server_control = true;
_local2.started = getTimer();
_local2.ad_msec = msec - 250;
};
mc.lc.rpc = function (callbackID, arg) {
mochi.as2.MochiAd.rpc(clip, callbackID, arg);
};
mc.rpcTestFn = function (s) {
trace("[MOCHIAD rpcTestFn] " + s);
return(s);
};
chk.onEnterFrame = function () {
var _local5 = this._parent._mochiad_ctr;
var _local4 = getTimer() - this.started;
var _local2 = false;
if (!chk.showing) {
var _local3 = _local5.getBytesTotal();
if ((_local3 > 0) || (typeof(_local3) == "undefined")) {
chk.showing = true;
chk.started = getTimer();
} else if (_local4 > chk.ad_timeout) {
options.ad_failed();
_local2 = true;
}
}
if (_local4 > chk.ad_msec) {
_local2 = true;
}
if (_local2) {
if (this.server_control) {
delete this.onEnterFrame;
} else {
this.fadeout_start = getTimer();
this.onEnterFrame = this.fadeFunction;
}
}
};
}
static function showPreloaderAd(options) {
trace("[MochiAd] DEPRECATED: showPreloaderAd was renamed to showPreGameAd in 2.0");
showPreGameAd(options);
}
static function showTimedAd(options) {
trace("[MochiAd] DEPRECATED: showTimedAd was renamed to showInterLevelAd in 2.0");
showInterLevelAd(options);
}
static function _allowDomains(server) {
var _local1 = server.split("/")[2].split(":")[0];
if (System.security) {
if (System.security.allowDomain) {
System.security.allowDomain("*");
System.security.allowDomain(_local1);
}
if (System.security.allowInsecureDomain) {
System.security.allowInsecureDomain("*");
System.security.allowInsecureDomain(_local1);
}
}
return(_local1);
}
static function load(options) {
var _local13 = {clip:_root, server:"http://x.mochiads.com/srv/1/", method:"load", depth:10333, id:"_UNKNOWN_"};
options = _parseOptions(options, _local13);
options.swfv = options.clip.getSWFVersion() || 6;
options.mav = getVersion();
var _local7 = options.clip;
if (!_isNetworkAvailable()) {
return(null);
}
if (_local7._mochiad_loaded) {
return(null);
}
var _local12 = options.depth;
delete options.depth;
var _local6 = _local7.createEmptyMovieClip("_mochiad", _local12);
var _local11 = _getRes(options);
options.res = (_local11[0] + "x") + _local11[1];
options.server = options.server + options.id;
delete options.id;
_local7._mochiad_loaded = true;
if (_local7._url.indexOf("http") != 0) {
trace("[MochiAd] NOTE: Security Sandbox Violation errors below are normal");
}
var _local4 = _local6.createEmptyMovieClip("_mochiad_ctr", 1);
for (var _local8 in options) {
_local4[_local8] = options[_local8];
}
var _local10 = _local4.server;
delete _local4.server;
var _local14 = _allowDomains(_local10);
_local6.onEnterFrame = function () {
if (this._mochiad_ctr._url != this._url) {
this.onEnterFrame = function () {
if (!this._mochiad_ctr) {
delete this.onEnterFrame;
mochi.as2.MochiAd.unload(this._parent);
}
};
}
};
var _local5 = new Object();
var _local9 = ["", Math.floor(new Date().getTime()), random(999999)].join("_");
_local5.mc = _local6;
_local5.name = _local9;
_local5.hostname = _local14;
_local5.allowDomain = function (d) {
return(true);
};
_local5.allowInsecureDomain = _local5.allowDomain;
_local5.connect(_local9);
_local6.lc = _local5;
_local4.lc = _local9;
_local4.st = getTimer();
_local4.loadMovie(_local10 + ".swf", "POST");
return(_local6);
}
static function unload(clip) {
if (typeof(clip) == "undefined") {
clip = _root;
}
if (clip.clip && (clip.clip._mochiad)) {
clip = clip.clip;
}
if (!clip._mochiad) {
return(false);
}
containerNotify(clip, {id:"unload"}, clip._mochiad._containerLCName);
clip._mochiad.removeMovieClip();
delete clip._mochiad_loaded;
delete clip._mochiad;
return(true);
}
static function _isNetworkAvailable() {
if (System.security) {
var _local1 = System.security;
if (_local1.sandboxType == "localWithFile") {
return(false);
}
}
return(true);
}
static function _getRes(options) {
var _local3 = options.clip.getBounds();
var _local2 = 0;
var _local1 = 0;
if (typeof(options.res) != "undefined") {
var _local4 = options.res.split("x");
_local2 = parseFloat(_local4[0]);
_local1 = parseFloat(_local4[1]);
} else {
_local2 = _local3.xMax - _local3.xMin;
_local1 = _local3.yMax - _local3.yMin;
}
if ((_local2 == 0) || (_local1 == 0)) {
_local2 = Stage.width;
_local1 = Stage.height;
}
return([_local2, _local1]);
}
static function _parseOptions(options, defaults) {
var _local4 = {};
for (var _local8 in defaults) {
_local4[_local8] = defaults[_local8];
}
if (options) {
for (var _local8 in options) {
_local4[_local8] = options[_local8];
}
}
if (_root.mochiad_options) {
var _local5 = _root.mochiad_options.split("&");
var _local2 = 0;
while (_local2 < _local5.length) {
var _local3 = _local5[_local2].split("=");
_local4[unescape(_local3[0])] = unescape(_local3[1]);
_local2++;
}
}
if (_local4.id == "test") {
trace("[MochiAd] WARNING: Using the MochiAds test identifier, make sure to use the code from your dashboard, not this example!");
}
return(_local4);
}
static function rpc(clip, callbackID, arg) {
switch (arg.id) {
case "setValue" :
setValue(clip, arg.objectName, arg.value);
break;
case "getValue" :
var _local4 = getValue(clip, arg.objectName);
containerRpcResult(clip, callbackID, _local4, clip._mochiad._containerLCName);
break;
case "runMethod" :
var _local3 = runMethod(clip, arg.method, arg.args);
containerRpcResult(clip, callbackID, _local3, clip._mochiad._containerLCName);
break;
default :
trace("[mochiads rpc] unknown rpc id: " + arg.id);
}
}
static function setValue(base, objectName, value) {
var _local2 = objectName.split(".");
var _local1;
_local1 = 0;
while (_local1 < (_local2.length - 1)) {
if ((base[_local2[_local1]] == undefined) || (base[_local2[_local1]] == null)) {
return(undefined);
}
base = base[_local2[_local1]];
_local1++;
}
base[_local2[_local1]] = value;
}
static function getValue(base, objectName) {
var _local2 = objectName.split(".");
var _local1;
_local1 = 0;
while (_local1 < (_local2.length - 1)) {
if ((base[_local2[_local1]] == undefined) || (base[_local2[_local1]] == null)) {
return(undefined);
}
base = base[_local2[_local1]];
_local1++;
}
return(base[_local2[_local1]]);
}
static function runMethod(base, methodName, argsArray) {
var _local2 = methodName.split(".");
var _local1;
_local1 = 0;
while (_local1 < (_local2.length - 1)) {
if ((base[_local2[_local1]] == undefined) || (base[_local2[_local1]] == null)) {
return(undefined);
}
base = base[_local2[_local1]];
_local1++;
}
if (typeof(base[_local2[_local1]]) == "function") {
return(base[_local2[_local1]].apply(base, argsArray));
}
return(undefined);
}
static function containerNotify(clip, args, lcName) {
var _local1 = clip._mochiad._mochiad_ctr.ad.app;
if (_local1.notify) {
_local1.notify(args);
} else {
new LocalConnection().send(lcName, "notify", args);
}
}
static function containerRpcResult(clip, callbackID, val, lcName) {
var _local1 = clip._mochiad._mochiad_ctr.ad.app;
if (_local1.rpcResult) {
_local1.rpcResult(callbackID, val);
} else {
new LocalConnection().send(lcName, "rpcResult", callbackID, val);
}
}
}
Symbol 578 MovieClip [__Packages.mochi.as2.MochiServices] Frame 0
class mochi.as2.MochiServices
{
static var _id, _container, _clip, _sendChannelName, __get__comChannelName, onError, _listenChannel, _loader, _loaderListener, _sendChannel;
function MochiServices () {
}
static function get id() {
return(_id);
}
static function get clip() {
return(_container);
}
static function get childClip() {
return(_clip);
}
static function getVersion() {
return("3.02 as2");
}
static function allowDomains(server) {
var _local1 = server.split("/")[2].split(":")[0];
if (System.security) {
if (System.security.allowDomain) {
System.security.allowDomain("*");
System.security.allowDomain(_local1);
}
if (System.security.allowInsecureDomain) {
System.security.allowInsecureDomain("*");
System.security.allowInsecureDomain(_local1);
}
}
return(_local1);
}
static function get isNetworkAvailable() {
if (System.security) {
var _local1 = System.security;
if (_local1.sandboxType == "localWithFile") {
return(false);
}
}
return(true);
}
static function set comChannelName(val) {
if (val != undefined) {
if (val.length > 3) {
_sendChannelName = val + "_fromgame";
initComChannels();
}
}
//return(__get__comChannelName());
}
static function get connected() {
return(_connected);
}
static function connect(id, clip, onError) {
warnID(id, false);
if ((!_connected) && (_clip == undefined)) {
trace("MochiServices Connecting...");
_connecting = true;
init(id, clip);
}
if (onError != undefined) {
mochi.as2.MochiServices.onError = onError;
} else if (mochi.as2.MochiServices.onError == undefined) {
mochi.as2.MochiServices.onError = function (errorCode) {
trace(errorCode);
};
}
}
static function disconnect() {
if (_connected || (_connecting)) {
_connecting = (_connected = false);
flush(true);
if (_clip != undefined) {
_clip.removeMovieClip();
delete _clip;
}
_listenChannel.close();
}
}
static function init(id, clip) {
_id = id;
if (clip != undefined) {
_container = clip;
} else {
_container = _root;
}
loadCommunicator(id, _container);
}
static function loadCommunicator(id, clip) {
var _local3 = "_mochiservices_com_" + id;
if (_clip != null) {
return(_clip);
}
if (!isNetworkAvailable) {
return(null);
}
if (urlOptions().servicesURL != undefined) {
_servicesURL = urlOptions().servicesURL;
}
allowDomains(_servicesURL);
_clip = clip.createEmptyMovieClip(_local3, 10336, false);
_listenChannelName = _listenChannelName + ((Math.floor(new Date().getTime()) + "_") + Math.floor(Math.random() * 99999));
listen();
_loader = new MovieClipLoader();
if (_loaderListener.waitInterval != null) {
clearInterval(_loaderListener.waitInterval);
}
_loaderListener = {};
_loaderListener.onLoadError = function (target_mc, errorCode, httpStatus) {
trace("MochiServices could not load.");
mochi.as2.MochiServices.disconnect();
mochi.as2.MochiServices.onError.apply(null, [errorCode]);
};
_loaderListener.onLoadStart = function (target_mc) {
this.isLoading = true;
};
_loaderListener.startTime = getTimer();
_loaderListener.wait = function () {
if ((getTimer() - this.startTime) > 10000) {
if (!this.isLoading) {
mochi.as2.MochiServices.disconnect();
mochi.as2.MochiServices.onError.apply(null, ["IOError"]);
}
clearInterval(this.waitInterval);
}
};
_loaderListener.waitInterval = setInterval(_loaderListener, "wait", 1000);
_loader.addListener(_loaderListener);
_loader.loadClip((((_servicesURL + "?listenLC=") + _listenChannelName) + "&mochiad_options=") + escape(_root.mochiad_options), _clip);
_sendChannel = new LocalConnection();
_sendChannel._queue = [];
return(_clip);
}
static function onStatus(infoObject) {
if (!(infoObject.level === "error")) {
} else {
_connected = false;
_listenChannel.connect(_listenChannelName);
}
}
static function listen() {
_listenChannel = new LocalConnection();
_listenChannel.handshake = function (args) {
mochi.as2.MochiServices.__set__comChannelName(args.newChannel);
};
_listenChannel.allowDomain = function (d) {
return(true);
};
_listenChannel.allowInsecureDomain = _listenChannel.allowDomain;
_listenChannel._nextcallbackID = 0;
_listenChannel._callbacks = {};
_listenChannel.connect(_listenChannelName);
trace("Waiting for MochiAds services to connect...");
}
static function initComChannels() {
if (!_connected) {
_sendChannel.onStatus = function (infoObject) {
mochi.as2.MochiServices.onStatus(infoObject);
};
_sendChannel.send(_sendChannelName, "onReceive", {methodName:"handshakeDone"});
_sendChannel.send(_sendChannelName, "onReceive", {methodName:"registerGame", id:_id, clip:_clip, version:getVersion()});
_listenChannel.onStatus = function (infoObject) {
mochi.as2.MochiServices.onStatus(infoObject);
};
_listenChannel.onReceive = function (pkg) {
var _local5 = pkg.callbackID;
var _local4 = this._callbacks[_local5];
if (!_local4) {
return(undefined);
}
var _local2 = _local4.callbackMethod;
var _local3 = _local4.callbackObject;
if (_local3 && (typeof(_local2) == "string")) {
_local2 = _local3[_local2];
}
if (_local2 != undefined) {
_local2.apply(_local3, pkg.args);
}
delete this._callbacks[_local5];
};
_listenChannel.onError = function () {
mochi.as2.MochiServices.onError.apply(null, ["IOError"]);
};
trace("connected!");
_connecting = false;
_connected = true;
while (_sendChannel._queue.length > 0) {
_sendChannel.send(_sendChannelName, "onReceive", _sendChannel._queue.shift());
}
}
}
static function flush(error) {
var _local1;
var _local2;
while (_sendChannel._queue.length > 0) {
_local1 = _sendChannel._queue.shift();
if (_local1.callbackID != null) {
_local2 = _listenChannel._callbacks[_local1.callbackID];
}
delete _listenChannel._callbacks[_local1.callbackID];
if (error) {
handleError(_local1.args, _local2.callbackObject, _local2.callbackMethod);
}
}
}
static function handleError(args, callbackObject, callbackMethod) {
if (args != null) {
if (args.onError != null) {
args.onError.apply(null, ["NotConnected"]);
}
if ((args.options != null) && (args.options.onError != null)) {
args.options.onError.apply(null, ["NotConnected"]);
}
}
if (callbackMethod != null) {
args = {};
args.error = true;
args.errorCode = "NotConnected";
if ((callbackObject != null) && (typeof(callbackMethod) == "string")) {
callbackObject[callbackMethod](args);
} else if (callbackMethod != null) {
callbackMethod.apply(args);
}
}
}
static function send(methodName, args, callbackObject, callbackMethod) {
if (_connected) {
_sendChannel.send(_sendChannelName, "onReceive", {methodName:methodName, args:args, callbackID:_listenChannel._nextcallbackID});
} else {
if ((_clip == undefined) || (!_connecting)) {
onError.apply(null, ["NotConnected"]);
handleError(args, callbackObject, callbackMethod);
flush(true);
return(undefined);
}
_sendChannel._queue.push({methodName:methodName, args:args, callbackID:_listenChannel._nextcallbackID});
}
_listenChannel._callbacks[_listenChannel._nextcallbackID] = {callbackObject:callbackObject, callbackMethod:callbackMethod};
_listenChannel._nextcallbackID++;
}
static function urlOptions() {
var _local5 = {};
if (_root.mochiad_options) {
var _local4 = _root.mochiad_options.split("&");
var _local2 = 0;
while (_local2 < _local4.length) {
var _local3 = _local4[_local2].split("=");
_local5[unescape(_local3[0])] = unescape(_local3[1]);
_local2++;
}
}
return(_local5);
}
static function warnID(bid, leaderboard) {
bid = bid.toLowerCase();
if (bid.length != 16) {
trace(("WARNING: " + (leaderboard ? "board" : "game")) + " ID is not the appropriate length");
return(undefined);
}
if (bid == "1e113c7239048b3f") {
if (leaderboard) {
trace("WARNING: Using testing board ID");
} else {
trace("WARNING: Using testing board ID as game ID");
}
return(undefined);
}
if (bid == "84993a1de4031cd8") {
if (leaderboard) {
trace("WARNING: Using testing game ID as board ID");
} else {
trace("WARNING: Using testing game ID");
}
return(undefined);
}
var _local1 = 0;
while (_local1 < bid.length) {
switch (bid.charAt(_local1)) {
case "0" :
case "1" :
case "2" :
case "3" :
case "4" :
case "5" :
case "6" :
case "7" :
case "8" :
case "9" :
case "a" :
case "b" :
case "c" :
case "d" :
case "e" :
case "f" :
break;
default :
trace("WARNING: Board ID contains illegal characters: " + bid);
return(undefined);
}
_local1++;
}
}
static function addLinkEvent(url, burl, btn, onClick) {
var timeout = 1500;
var t0 = getTimer();
var _local2 = new Object();
_local2.mav = getVersion();
_local2.swfv = btn.getSWFVersion() || 6;
_local2.swfurl = btn._url;
_local2.fv = System.capabilities.version;
_local2.os = System.capabilities.os;
_local2.lang = System.capabilities.language;
_local2.scres = (System.capabilities.screenResolutionX + "x") + System.capabilities.screenResolutionY;
var s = "?";
var _local3 = 0;
for (var _local6 in _local2) {
if (_local3 != 0) {
s = s + "&";
}
_local3++;
s = ((s + _local6) + "=") + escape(_local2[_local6]);
}
if (!(netupAttempted || (_connected))) {
var ping = btn.createEmptyMovieClip("ping", 777);
var _local7 = btn.createEmptyMovieClip("nettest", 778);
netupAttempted = true;
ping.loadMovie("http://x.mochiads.com/linkping.swf?t=" + getTimer());
_local7.onEnterFrame = function () {
if ((ping._totalframes > 0) && (ping._totalframes == ping._framesloaded)) {
delete this.onEnterFrame;
} else if ((getTimer() - t0) > timeout) {
delete this.onEnterFrame;
mochi.as2.MochiServices.netup = false;
}
};
}
var _local4 = btn.createEmptyMovieClip("clk", 1001);
_local4._alpha = 0;
_local4.beginFill(1044735);
_local4.moveTo(0, 0);
_local4.lineTo(0, btn._height);
_local4.lineTo(btn._width, btn._height);
_local4.lineTo(btn._width, 0);
_local4.lineTo(0, 0);
_local4.endFill();
_local4.onRelease = function () {
if (mochi.as2.MochiServices.netup) {
getURL (url + s, "_blank");
} else {
getURL (burl, "_blank");
}
if (onClick != undefined) {
onClick();
}
};
}
static var _servicesURL = "http://www.mochiads.com/static/lib/services/services.swf";
static var _listenChannelName = "__ms_";
static var _connecting = false;
static var _connected = false;
static var netup = true;
static var netupAttempted = false;
}
Symbol 579 MovieClip [__Packages.mochi.as2.MochiScores] Frame 0
class mochi.as2.MochiScores
{
static var boardID, onClose, onError;
function MochiScores () {
}
static function setBoardID(boardID) {
mochi.as2.MochiServices.warnID(boardID, true);
mochi.as2.MochiScores.boardID = boardID;
mochi.as2.MochiServices.send("scores_setBoardID", {boardID:boardID});
}
static function showLeaderboard(options) {
if ((options.clip == null) || (options.clip == undefined)) {
options.clip = mochi.as2.MochiServices.clip;
}
if ((options.clip != mochi.as2.MochiServices.__get__clip()) || (mochi.as2.MochiServices.__get__childClip()._target == undefined)) {
mochi.as2.MochiServices.disconnect();
trace("WARNING! This application is attempting to connect to MochiServices inside a showLeaderboard call!");
trace("make sure MochiServices.connect is called as early in the application runtime as possible.");
mochi.as2.MochiServices.connect(mochi.as2.MochiServices.__get__id(), options.clip);
}
delete options.clip;
if (options.name != null) {
if (typeof(options.name) == "object") {
if (options.name.text != undefined) {
options.name = options.name.text;
}
}
}
if (options.score != null) {
if (options.score instanceof TextField) {
if (options.score.text != undefined) {
options.score = options.score.text;
}
} else if (options.score instanceof mochi.as2.MochiDigits) {
options.score = options.score.value;
}
var _local1 = Number(options.score);
if (isNaN(_local1)) {
trace(("ERROR: Submitted score '" + options.score) + "' will be rejected, score is 'Not a Number'");
} else if ((_local1 == Number.NEGATIVE_INFINITY) || (_local1 == Number.POSITIVE_INFINITY)) {
trace(("ERROR: Submitted score '" + options.score) + "' will be rejected, score is an infinite");
} else {
if (Math.floor(_local1) != _local1) {
trace(("WARNING: Submitted score '" + options.score) + "' will be truncated");
}
options.score = _local1;
}
}
if (options.onDisplay != null) {
options.onDisplay();
} else {
mochi.as2.MochiServices.__get__clip().stop();
}
if (options.onClose != null) {
onClose = options.onClose;
} else {
onClose = function () {
mochi.as2.MochiServices.__get__clip().play();
};
}
if (options.onError != null) {
onError = options.onError;
} else {
onError = onClose;
}
if (options.boardID == null) {
if (boardID != null) {
options.boardID = boardID;
}
}
mochi.as2.MochiServices.warnID(options.boardID, true);
trace("[MochiScores] NOTE: Security Sandbox Violation errors below are normal");
mochi.as2.MochiServices.send("scores_showLeaderboard", {options:options}, null, doClose);
}
static function closeLeaderboard() {
mochi.as2.MochiServices.send("scores_closeLeaderboard");
}
static function getPlayerInfo(callbackObj, callbackMethod) {
mochi.as2.MochiServices.send("scores_getPlayerInfo", null, callbackObj, callbackMethod);
}
static function submit(score, name, callbackObj, callbackMethod) {
score = Number(score);
if (isNaN(score)) {
trace(("ERROR: Submitted score '" + String(score)) + "' will be rejected, score is 'Not a Number'");
} else if ((score == Number.NEGATIVE_INFINITY) || (score == Number.POSITIVE_INFINITY)) {
trace(("ERROR: Submitted score '" + String(score)) + "' will be rejected, score is an infinite");
} else {
if (Math.floor(score) != score) {
trace(("WARNING: Submitted score '" + String(score)) + "' will be truncated");
}
score = Number(score);
}
mochi.as2.MochiServices.send("scores_submit", {score:score, name:name}, callbackObj, callbackMethod);
}
static function requestList(callbackObj, callbackMethod) {
mochi.as2.MochiServices.send("scores_requestList", null, callbackObj, callbackMethod);
}
static function scoresArrayToObjects(scores) {
var _local5 = {};
var _local1;
var _local4;
var _local2;
var _local6;
for (var _local8 in scores) {
if (typeof(scores[_local8]) == "object") {
if ((scores[_local8].cols != null) && (scores[_local8].rows != null)) {
_local5[_local8] = [];
_local2 = scores[_local8];
_local4 = 0;
while (_local4 < _local2.rows.length) {
_local6 = {};
_local1 = 0;
while (_local1 < _local2.cols.length) {
_local6[_local2.cols[_local1]] = _local2.rows[_local4][_local1];
_local1++;
}
_local5[_local8].push(_local6);
_local4++;
}
} else {
_local5[_local8] = {};
for (var _local7 in scores[_local8]) {
_local5[_local8][_local7] = scores[_local8][_local7];
}
}
} else {
_local5[_local8] = scores[_local8];
}
}
return(_local5);
}
static function doClose(args) {
if (args.error == true) {
if (args.errorCode == undefined) {
args.errorCode = "IOError";
}
onError.apply(null, [args.errorCode]);
} else {
onClose.apply();
}
}
}
Symbol 580 MovieClip [__Packages.mochi.as2.MochiDigits] Frame 0
class mochi.as2.MochiDigits
{
var Encoder, Fragment, Sibling;
function MochiDigits (digit, index) {
Encoder = 0;
setValue(digit, index);
}
function get value() {
return(Number(toString()));
}
function set value(v) {
setValue(v);
//return(value);
}
function addValue(v) {
value = value + v;
}
function setValue(digit, index) {
var _local3 = digit.toString();
if ((index == undefined) || (isNaN(index))) {
index = 0;
}
Fragment = _local3.charCodeAt(index++) ^ Encoder;
if (index < _local3.length) {
Sibling = new mochi.as2.MochiDigits(digit, index);
} else {
Sibling = null;
}
reencode();
}
function reencode() {
var _local2 = int(2147483647 * Math.random());
Fragment = Fragment ^ (_local2 ^ Encoder);
Encoder = _local2;
}
function toString() {
var _local2 = String.fromCharCode(Fragment ^ Encoder);
return(((Sibling != null) ? (_local2.concat(Sibling.toString())) : (_local2)));
}
}
Symbol 581 MovieClip [__Packages.BurnStuff] Frame 0
class BurnStuff
{
static var char, gun, air_bar, fuzz;
var engine, player, char_face;
function BurnStuff () {
engine = new org.cove.flade.DynamicsEngine();
engine.setDamping(0.96);
engine.setGravity(0, 0.4);
engine.setSurfaceBounce(0.2);
engine.setSurfaceFriction(0.001);
engine.addSurface(new org.cove.flade.surfaces.LineSurface(10, 10, 10, 395));
engine.addSurface(new org.cove.flade.surfaces.LineSurface(10, 395, 710, 395));
engine.addSurface(new org.cove.flade.surfaces.LineSurface(710, 395, 710, 10));
player = new org.cove.flade.primitives.RectangleParticle(360, 200, p_width, p_height, false);
engine.addPrimitive(player);
char = _root.char;
gun = char.gun;
air_bar = _root.air_bar;
fuzz = _root.fuzz;
fuzz._alpha = 0;
_root.air_box.power_burn._alpha = 0;
_root.air_box.power_speed._alpha = 0;
_root.air_box.power_points._alpha = 0;
_root.air_box.power_jump._alpha = 0;
char_face = char._xscale;
_root.score = 0;
_root.backgroundMusic.setVolume(_root.Volume);
_root.pausedVal = true;
}
function run() {
if (_root.pausedVal) {
if (!dead) {
sortJumping();
sortRunning();
if (firing) {
if (!crawling) {
spawnFire(char._x, char._y, firevel, aim);
} else {
spawnFire(char._x, char._y + 10, firevel, aim);
}
}
if ((spawnTimer >= spawnTime) && (Math.random() < spawnRate)) {
spawnBox();
spawnTimer = 0;
} else {
spawnTimer++;
}
if ((oxygen_spawn >= oxygen_spawn_time) && (Math.random() < spawnRate)) {
spawnOxygen();
oxygen_spawn = 0;
} else {
oxygen_spawn++;
}
if ((power_spawn >= power_spawn_time) && (Math.random() < spawnRate)) {
spawnPowerUp();
power_spawn = 0;
} else {
power_spawn++;
}
if (jump_power > 0) {
jump_power--;
if (jump_power == 0) {
_root.air_box.power_jump._alpha = 0;
}
}
if (point_power > 0) {
point_power--;
if (point_power == 0) {
_root.air_box.power_points._alpha = 0;
}
}
if (burn_power > 0) {
burn_power--;
if (burn_power == 0) {
_root.air_box.power_burn._alpha = 0;
}
}
if (speed_power > 0) {
speed_power--;
if (speed_power == 0) {
_root.air_box.power_speed._alpha = 0;
}
}
sortBoxes();
sortOxygens();
sortFires();
air = air - air_reduce;
time_elapsed = time_elapsed + (1 / fps);
if ((Math.round(time_elapsed * 1000) % 1000) == 0) {
sortAchievements();
}
} else if (_root.delete_out) {
_root.delete_out = false;
var _local4 = 0;
while (_local4 < boxes.length) {
boxes[_local4].box.dmc.removeMovieClip();
engine.removePrimitive(boxes[_local4].box);
engine.removeSurface(boxes[_local4].surface);
_local4++;
}
boxes.splice(0);
_local4 = 0;
while (_local4 < oxygens.length) {
oxygens[_local4].box.dmc.removeMovieClip();
engine.removePrimitive(oxygens[_local4].box);
_local4++;
}
oxygens.splice(0);
fires.splice(0);
_local4 = 100;
while (_local4 < _root.getNextHighestDepth()) {
var _local3 = _root.getInstanceAtDepth(_local4);
if ((_local3._name != "game_over") && (_local3._name != "bgmusicmc")) {
_local3.removeMovieClip();
}
_local4++;
}
engine.resetEngine();
_root.onEnterFrame = undefined;
}
updateEngine();
updateVisuals();
}
}
function objectXSpeed(p) {
return(p.curr.x - p.prev.x);
}
function objectYSpeed(p) {
return(p.curr.y - p.prev.y);
}
function particleDistance(p1, p2) {
var _local2 = p1.curr.x - p2.curr.x;
var _local1 = p1.curr.y - p2.curr.y;
return(Math.sqrt((_local2 * _local2) + (_local1 * _local1)));
}
function particleDistanceVal(p1, xval, yval) {
var _local2 = p1.curr.x - xval;
var _local1 = p1.curr.y - yval;
return(Math.sqrt((_local2 * _local2) + (_local1 * _local1)));
}
function randBetween(min, max) {
return((Math.random() * (max - min)) + min);
}
function spawnBox(xval) {
if (xval == undefined) {
xval = (Math.random() * 650) + 30;
}
var _local3 = new org.cove.flade.primitives.RectangleParticle(xval, -10, box_size, box_size);
engine.addPrimitive(_local3);
var _local2 = new Object();
_local2.box = _local3;
_local2.y1 = 0;
_local2.y2 = 0;
_local2.x1 = 0;
_local2.x2 = 0;
_local2.fire = false;
_local2.burned = false;
_local2.falling = true;
boxes.push(_local2);
}
function spawnOxygen(xval, yval) {
if (xval == undefined) {
xval = (Math.random() * 650) + 30;
}
if (yval == undefined) {
yval = -10;
}
if (xval < 30) {
xval = 30;
}
if (xval > 680) {
xval = 680;
}
var _local4 = new org.cove.flade.primitives.RectangleParticle(xval, yval, box_size, box_size, false);
engine.addPrimitive(_local4);
var _local5 = new Object();
_local5.box = _local4;
var _local6 = "o2" + _root.getNextHighestDepth();
duplicateMovieClip ("o2tank", _local6, _root.getNextHighestDepth());
_local4.dmc = _root[_local6];
var _local8 = oxygens.push(_local5);
}
function spawnPowerUp(xval, yval) {
if (xval == undefined) {
xval = (Math.random() * 650) + 30;
}
if (yval == undefined) {
yval = -10;
}
var _local4 = new org.cove.flade.primitives.RectangleParticle(xval, yval, box_size, box_size, false);
engine.addPrimitive(_local4);
var _local3 = new Object();
_local3.box = _local4;
_local3.ptype = Math.round(Math.random() * 3) + 1;
var _local5 = "o2" + _root.getNextHighestDepth();
duplicateMovieClip ("powerups", _local5, _root.getNextHighestDepth());
_local4.dmc = _root[_local5];
_root[_local5].gotoAndStop((_local3.ptype * 3) - 2);
var _local8 = oxygens.push(_local3);
}
function spawnFire(xpos, ypos, vel, angle, strength) {
duplicateMovieClip ("fire", "fire" + fi, 100 + fi);
var _local3 = _root["fire" + fi];
_local3._x = xpos;
_local3._y = ypos;
_local3._active = true;
_local3._travel = randBetween(-0.3, 0.3);
_local3._angle = angle;
if ((vel > 0) && (burn_power > 0)) {
vel = vel + burn_boost;
}
_local3._vel = vel;
_local3._strength = strength;
_local3._raise = randBetween(-0.1, 0.4);
_local3._yscale = randBetween(80, 85);
fi++;
if (fi > fimax) {
fi = 0;
}
}
function sortJumping() {
if (jumping && (Math.round((player.prev.y - 0.0837) * 30) == Math.round(player.curr.y * 30))) {
jumping = false;
char.gotoAndStop(ani_skid);
}
if ((Key.isDown(87) || (Key.isDown(38))) && (!jumping)) {
jumping = true;
player.prev.y = player.prev.y + yspeed;
if (jump_power > 0) {
player.prev.y = player.prev.y + jump_boost;
}
char.gotoAndStop(ani_jump);
}
}
function sortRunning() {
var _local2 = objectXSpeed(player);
if (Key.isDown(65) || (Key.isDown(37))) {
player.prev.x = player.prev.x + xspeed;
if (speed_power > 0) {
player.prev.x = player.prev.x + speed_boost;
}
if (!jumping) {
if (char._xscale < 0) {
char.gotoAndStop(ani_walk);
} else {
char.gotoAndStop(ani_bwalk);
}
}
} else if (Key.isDown(68) || (Key.isDown(39))) {
player.prev.x = player.prev.x - xspeed;
if (speed_power > 0) {
player.prev.x = player.prev.x - speed_boost;
}
if (!jumping) {
if (char._xscale > 0) {
char.gotoAndStop(ani_walk);
} else {
char.gotoAndStop(ani_bwalk);
}
}
} else if (Math.abs(_local2) < xslow) {
player.prev.x = player.curr.x;
if (!jumping) {
char.gotoAndStop(ani_still);
}
} else if (_local2 > 0) {
player.prev.x = player.prev.x + xslow;
if (!jumping) {
char.gotoAndStop(ani_skid);
}
} else if (_local2 < 0) {
player.prev.x = player.prev.x - xslow;
if (!jumping) {
char.gotoAndStop(ani_skid);
}
}
if (_local2 > xmax) {
player.prev.x = player.prev.x + xspeed;
if (speed_power > 0) {
player.prev.x = player.prev.x + speed_boost;
}
} else if (_local2 < (-xmax)) {
player.prev.x = player.prev.x - xspeed;
if (speed_power > 0) {
player.prev.x = player.prev.x - speed_boost;
}
}
}
function updateEngine() {
engine.timeStep();
engine.paintPrimitives();
engine.paintConstraints();
}
function sortBoxes() {
var _local3 = 0;
while (_local3 < boxes.length) {
if (!boxes[_local3].burned) {
if ((boxes[_local3].falling && (Math.round(boxes[_local3].box.curr.y * 100) == Math.round(boxes[_local3].y1 * 100))) && (Math.round(boxes[_local3].box.prev.y * 100) == Math.round(boxes[_local3].y2 * 100))) {
var _local8 = new org.cove.flade.surfaces.RectangleTile(boxes[_local3].box.curr.x, boxes[_local3].box.curr.y, box_size, box_size);
engine.addSurface(_local8);
engine.removePrimitive(boxes[_local3].box);
boxes[_local3].surface = _local8;
boxes[_local3].falling = false;
} else {
if (boxes[_local3].falling && (boxes[_local3].fire)) {
_root.score = _root.score + 1;
}
boxes[_local3].y1 = boxes[_local3].box.curr.y;
boxes[_local3].y2 = boxes[_local3].box.prev.y;
boxes[_local3].x1 = boxes[_local3].box.curr.x;
boxes[_local3].x2 = boxes[_local3].box.prev.x;
}
var _local6 = 0;
while (_local6 < fimax) {
var _local4 = _root["fire" + _local6];
if (((_local4 != undefined) && (!boxes[_local3].fire)) && (!boxes[_local3].burned)) {
var _local7 = particleDistanceVal(boxes[_local3].box, _local4._x, _local4._y);
if (_local7 < 30) {
var _local5 = new Object();
_local5.box = _local3;
_local5.str = 100;
fires.push(_local5);
boxes[_local3].fire = true;
if (fires.length > max_combo) {
max_combo = fires.length;
}
boxes[_local3].box.dmc.nextFrame();
if (boxes[_local3].falling) {
if (jumping) {
addScore(200, "mid air burn", boxes[_local3].box.curr.x, boxes[_local3].box.curr.y);
} else {
addScore(150, "falling burn", boxes[_local3].box.curr.x, boxes[_local3].box.curr.y);
}
} else if (jumping) {
addScore(125, "jump burn bonus", boxes[_local3].box.curr.x, boxes[_local3].box.curr.y);
} else {
addScore(100, "burned!", boxes[_local3].box.curr.x, boxes[_local3].box.curr.y);
}
}
}
_local6++;
}
}
_local3++;
}
}
function sortOxygens() {
var _local3 = 0;
while (_local3 < oxygens.length) {
if (particleDistance(oxygens[_local3].box, player) < 30) {
engine.removePrimitive(oxygens[_local3].box);
oxygens[_local3].box.dmc.gotoAndStop(oxygens[_local3].box.dmc._currentframe + 2);
if (oxygens[_local3].ptype == undefined) {
oxygen_give = oxygen_give + oxygen_ammount;
_root.playSound(_root.powerups, "oxygen.mp3");
oxygens_got++;
} else if (oxygens[_local3].ptype == 1) {
point_power = power_length;
_root.playSound(_root.powerups, "point.mp3");
_root.air_box.power_points._alpha = 60;
} else if (oxygens[_local3].ptype == 2) {
jump_power = power_length;
_root.playSound(_root.powerups, "shoes.wav");
_root.air_box.power_jump._alpha = 60;
} else if (oxygens[_local3].ptype == 3) {
speed_power = power_length;
_root.playSound(_root.powerups, "speed.mp3");
_root.air_box.power_speed._alpha = 60;
} else if (oxygens[_local3].ptype == 4) {
burn_power = power_length;
_root.playSound(_root.powerups, "burn.mp3");
_root.air_box.power_burn._alpha = 60;
}
oxygens.splice(_local3, 1);
}
var _local5 = 0;
while (_local5 < fimax) {
var _local4 = _root["fire" + _local5];
if (_local4 != undefined) {
var _local6 = particleDistanceVal(oxygens[_local3].box, _local4._x, _local4._y);
if (_local6 < 20) {
if (oxygens[_local3].ptype == undefined) {
addScore(30, "oxygen splosion", oxygens[_local3].box.curr.x, oxygens[_local3].box.curr.y);
oxygen_give = oxygen_ammount / 10;
} else if (oxygens[_local3].ptype == 1) {
addScore(100, "coin burn", oxygens[_local3].box.curr.x, oxygens[_local3].box.curr.y);
} else if (oxygens[_local3].ptype == 2) {
addScore(50, "burnt shoes", oxygens[_local3].box.curr.x, oxygens[_local3].box.curr.y);
} else if (oxygens[_local3].ptype == 3) {
addScore(50, "energy can pop", oxygens[_local3].box.curr.x, oxygens[_local3].box.curr.y);
} else if (oxygens[_local3].ptype == 4) {
addScore(20, "fuel explosion", oxygens[_local3].box.curr.x, oxygens[_local3].box.curr.y);
}
oxygens[_local3].box.dmc.nextFrame();
engine.removePrimitive(oxygens[_local3].box);
oxygens.splice(_local3, 1);
}
}
_local5++;
}
_local3++;
}
}
function sortFires() {
var _local2 = 0;
while (_local2 < fires.length) {
if ((Math.round(fires[_local2].str) % 3) == 0) {
spawnFire(boxes[fires[_local2].box].x1 - box_size, boxes[fires[_local2].box].y1, 0, 0, fires[_local2].str);
air = air - air_fire_decrease;
}
fires[_local2].str = fires[_local2].str - (90 / fires[_local2].str);
if (fires[_local2].str <= 10) {
boxes[fires[_local2].box].fire = false;
boxes[fires[_local2].box].burned = true;
burned_things++;
fires.splice(_local2, 1);
}
_local2++;
}
}
function sortAchievements() {
if ((!_root.saveData.data.ach_survive_1) && (time_elapsed >= 60)) {
_root.saveData.data.ach_survive_1 = true;
_root.saveData.flush();
_root.achievement_got = 1;
} else if ((!_root.saveData.data.ach_survive_2) && (time_elapsed >= 120)) {
_root.saveData.data.ach_survive_2 = true;
_root.saveData.flush();
_root.achievement_got = 2;
} else if ((!_root.saveData.data.ach_survive_5) && (time_elapsed >= 300)) {
_root.saveData.data.ach_survive_5 = true;
_root.saveData.flush();
_root.achievement_got = 3;
} else if ((!_root.saveData.data.ach_survive_10) && (time_elapsed >= 600)) {
_root.saveData.data.ach_survive_10 = true;
_root.saveData.flush();
_root.achievement_got = 4;
}
if ((!_root.saveData.data.ach_oxygen_5) && (oxygens_got >= 5)) {
_root.saveData.data.ach_oxygen_5 = true;
_root.saveData.flush();
_root.achievement_got = 5;
} else if ((!_root.saveData.data.ach_oxygen_10) && (oxygens_got >= 10)) {
_root.saveData.data.ach_oxygen_10 = true;
_root.saveData.flush();
_root.achievement_got = 6;
} else if ((!_root.saveData.data.ach_oxygen_20) && (oxygens_got >= 20)) {
_root.saveData.data.ach_oxygen_20 = true;
_root.saveData.flush();
_root.achievement_got = 7;
}
if ((!_root.saveData.data.ach_combo_5) && (max_combo >= 5)) {
_root.saveData.data.ach_combo_5 = true;
_root.saveData.flush();
_root.achievement_got = 8;
} else if ((!_root.saveData.data.ach_combo_10) && (max_combo >= 10)) {
_root.saveData.data.ach_combo_10 = true;
_root.saveData.flush();
_root.achievement_got = 9;
} else if ((!_root.saveData.data.ach_combo_20) && (max_combo >= 20)) {
_root.saveData.data.ach_combo_20 = true;
_root.saveData.flush();
_root.achievement_got = 10;
} else if ((!_root.saveData.data.ach_combo_50) && (max_combo >= 50)) {
_root.saveData.data.ach_combo_50 = true;
_root.saveData.flush();
_root.achievement_got = 11;
}
if ((!_root.saveData.data.ach_burn_10) && (burned_things >= 10)) {
_root.saveData.data.ach_burn_10 = true;
_root.saveData.flush();
_root.achievement_got = 12;
} else if ((!_root.saveData.data.ach_burn_20) && (burned_things >= 20)) {
_root.saveData.data.ach_burn_20 = true;
_root.saveData.flush();
_root.achievement_got = 13;
} else if ((!_root.saveData.data.ach_burn_50) && (burned_things >= 50)) {
_root.saveData.data.ach_burn_50 = true;
_root.saveData.flush();
_root.achievement_got = 14;
}
}
function addScore(val, reason, xval, yval) {
if (point_power > 0) {
val = val * point_boost;
}
_root.score = _root.score + val;
if ((xval != undefined) && (yval != undefined)) {
duplicateMovieClip ("add_point", "ap" + si, 210 + si);
_root["ap" + si]._x = xval;
_root["ap" + si]._y = yval;
_root["ap" + si]._point_text = "+" + val;
if (reason == undefined) {
_root["ap" + si]._point_reason = " ";
} else {
_root["ap" + si]._point_reason = reason;
}
si++;
if (si > simax) {
si = 0;
}
}
}
function updateVisuals() {
char._x = player.curr.x;
char._y = player.curr.y;
if (!dead) {
if ((_root._xmouse - _root.char._x) > 0) {
char._xscale = char_face;
} else {
char._xscale = -char_face;
}
}
air_bar._xscale = air;
if (oxygen_give > 0) {
air = air + oxygen_give_speed;
oxygen_give = oxygen_give - oxygen_give_speed;
if (air > 100) {
air = 100;
oxygen_give = 0;
}
}
if (air < 40) {
xspeed = 0.05 + (0.00875 * air);
yspeed = 6 + (0.1 * air);
fuzz._x = char._x;
fuzz._y = char._y;
fuzz._alpha = ((-air) * 2.5) + 100;
_root.backgroundMusic.setVolume(((air * 2.5) + 10) / (100 / _root.Volume));
}
if ((!oxygen_thrown) && (air <= 20)) {
oxygen_thrown = true;
if (Math.random() <= 0.5) {
spawnOxygen(char._x - oxygen_dist);
} else {
spawnOxygen(char._x + oxygen_dist);
}
oxygen_dist = oxygen_dist + 10;
} else if (oxygen_thrown && (air > 20)) {
oxygen_thrown = false;
}
if ((!crawling) && (air <= 10)) {
gun._y = 0.1;
gun._x = gun._x + 5;
ani_still = 6;
ani_walk = 7;
ani_bwalk = 8;
ani_skid = 9;
ani_jump = 10;
crawling = true;
player.width = p_width_crawl;
} else if (crawling && (air > 10)) {
gun._y = -12.5;
gun._x = gun._x - 5;
ani_still = 1;
ani_walk = 2;
ani_bwalk = 3;
ani_skid = 4;
ani_jump = 5;
crawling = false;
player.width = p_width;
}
if ((air <= 0) && (!dead)) {
dead = true;
char.swapDepths(_root.getNextHighestDepth());
_root.game_over.swapDepths(_root.getNextHighestDepth());
_root.game_over.play();
char.gotoAndStop(11);
player.prev.x = player.curr.x;
_root.saveData.data.died++;
_root.saveData.flush();
if ((!_root.saveData.data.ach_die_1) && (_root.saveData.data.died >= 1)) {
_root.saveData.data.ach_die_1 = true;
_root.saveData.flush();
_root.achievement_got = 15;
} else if ((!_root.saveData.data.ach_die_5) && (_root.saveData.data.died >= 5)) {
_root.saveData.data.ach_die_5 = true;
_root.saveData.flush();
_root.achievement_got = 16;
} else if ((!_root.saveData.data.ach_die_10) && (_root.saveData.data.died >= 10)) {
_root.saveData.data.ach_die_10 = true;
_root.saveData.flush();
_root.achievement_got = 17;
}
}
}
static function main(mc) {
var b = new BurnStuff();
b.spawnBox();
mc.onEnterFrame = function () {
b.run();
};
char.stop();
gun.onEnterFrame = function () {
var _local3 = _root._xmouse - BurnStuff.char._x;
var _local2 = _root._ymouse - BurnStuff.char._y;
b.aim = Math.atan2(_local2, _local3);
if (BurnStuff.char._xscale < 0) {
var _local4 = ((Math.atan2(_local3, _local2) * 180) / Math.PI) + 90;
} else {
var _local4 = (b.aim * 180) / Math.PI;
}
BurnStuff.gun._rotation = _local4;
};
mouseListener.onMouseDown = function () {
b.firing = true;
};
mouseListener.onMouseUp = function () {
b.firing = false;
};
Mouse.addListener(mouseListener);
}
var boxes = new Array();
var oxygens = new Array();
var fires = new Array();
var air = 100;
static var air_reduce = 0.09;
static var air_fire_decrease = 0.05;
var time_elapsed = 0;
static var fps = 30;
var oxygens_got = 0;
var max_combo = 0;
var burned_things = 0;
var dead = false;
var crawling = false;
var jumping = true;
var firing = false;
var yspeed = 10;
var xspeed = 0.4;
var xslow = 0.2;
var xmax = 6;
var firevel = 11;
var fi = 0;
static var fimax = 90;
static var simax = 5;
var si = 0;
static var spawnTime = 60;
static var spawnRate = 0.1;
var spawnTimer = 0;
static var oxygen_spawn_time = 500;
var oxygen_spawn = 0;
static var power_spawn_time = 300;
var power_spawn = 0;
static var power_length = 300;
var jump_power = 0;
var jump_boost = 5;
var point_power = 0;
var point_boost = 2;
var burn_power = 0;
var burn_boost = 5;
var speed_power = 0;
var speed_boost = 0.6;
var aim = 0;
static var mouseListener = new Object();
var oxygen_give = 0;
static var oxygen_give_speed = 0.5;
static var oxygen_ammount = 30;
var oxygen_thrown = false;
var oxygen_dist = 60;
var ani_still = 1;
var ani_walk = 2;
var ani_bwalk = 3;
var ani_skid = 4;
var ani_jump = 5;
static var box_size = 20;
static var p_height = 30;
static var p_width = 15;
static var p_width_crawl = 25;
}
Symbol 582 MovieClip [__Packages.org.cove.flade.DynamicsEngine] Frame 0
class org.cove.flade.DynamicsEngine
{
var primitives, surfaces, constraints, gravity, coeffRest, coeffFric, coeffDamp;
function DynamicsEngine () {
primitives = new Array();
surfaces = new Array();
constraints = new Array();
gravity = new org.cove.flade.util.Vector(0, 1);
coeffRest = 1.5;
coeffFric = 0.01;
coeffDamp = 0.99;
}
function resetEngine() {
primitives.splice(0);
surfaces.splice(0);
constraints.splice(0);
}
function addPrimitive(p) {
primitives.push(p);
}
function removePrimitive(p) {
var _local2 = 0;
while (_local2 < primitives.length) {
if (primitives[_local2] == p) {
if (primitives[_local2].isBox) {
primitives[_local2].dmc.removeMovieClip();
}
primitives.splice(_local2, 1);
return(undefined);
}
_local2++;
}
}
function addSurface(s) {
surfaces.push(s);
}
function removeSurface(s) {
var _local2 = 0;
while (_local2 < surfaces.length) {
if (surfaces[_local2] == s) {
surfaces.splice(_local2, 1);
return(undefined);
}
_local2++;
}
}
function addConstraint(c) {
constraints.push(c);
}
function removeConstraint(c) {
var _local2 = 0;
while (_local2 < constraints.length) {
if (constraints[_local2] == c) {
constraints.splice(_local2, 1);
return(undefined);
}
_local2++;
}
}
function paintSurfaces() {
var _local2 = 0;
while (_local2 < surfaces.length) {
surfaces[_local2].paint();
_local2++;
}
}
function paintPrimitives() {
var _local2 = 0;
while (_local2 < primitives.length) {
primitives[_local2].paint();
_local2++;
}
}
function paintConstraints() {
var _local2 = 0;
while (_local2 < constraints.length) {
constraints[_local2].paint();
_local2++;
}
}
function timeStep() {
verlet();
satisfyConstraints();
checkCollisions();
}
function setSurfaceBounce(kfr) {
coeffRest = 1 + kfr;
}
function setSurfaceFriction(f) {
coeffFric = f;
}
function setDamping(d) {
coeffDamp = d;
}
function setGravity(gx, gy) {
gravity.x = gx;
gravity.y = gy;
}
function verlet() {
var _local2 = 0;
while (_local2 < primitives.length) {
primitives[_local2].verlet(this);
_local2++;
}
}
function satisfyConstraints() {
var _local2 = 0;
while (_local2 < constraints.length) {
constraints[_local2].resolve();
_local2++;
}
}
function checkCollisions() {
var _local4 = 0;
while (_local4 < surfaces.length) {
var _local3 = surfaces[_local4];
if (_local3.getActiveState()) {
var _local2 = 0;
while (_local2 < primitives.length) {
primitives[_local2].checkCollision(_local3, this);
_local2++;
}
}
_local4++;
}
}
}
Symbol 583 MovieClip [__Packages.org.cove.flade.util.Vector] Frame 0
class org.cove.flade.util.Vector
{
var x, y;
function Vector (px, py) {
x = px;
y = py;
}
function setTo(px, py) {
x = px;
y = py;
}
function copy(v) {
x = v.x;
y = v.y;
}
function dot(v) {
return((x * v.x) + (y * v.y));
}
function cross(v) {
return((x * v.y) - (y * v.x));
}
function plus(v) {
x = x + v.x;
y = y + v.y;
return(this);
}
function plusNew(v) {
return(new org.cove.flade.util.Vector(x + v.x, y + v.y));
}
function minus(v) {
x = x - v.x;
y = y - v.y;
return(this);
}
function minusNew(v) {
return(new org.cove.flade.util.Vector(x - v.x, y - v.y));
}
function mult(s) {
x = x * s;
y = y * s;
return(this);
}
function multNew(s) {
return(new org.cove.flade.util.Vector(x * s, y * s));
}
function distance(v) {
var _local3 = x - v.x;
var _local2 = y - v.y;
return(Math.sqrt((_local3 * _local3) + (_local2 * _local2)));
}
function normalize() {
var _local2 = Math.sqrt((x * x) + (y * y));
x = x / _local2;
y = y / _local2;
return(this);
}
function magnitude() {
return(Math.sqrt((x * x) + (y * y)));
}
function project(b) {
var _local5 = dot(b);
var _local4 = (b.x * b.x) + (b.y * b.y);
var _local3 = new org.cove.flade.util.Vector(0, 0);
_local3.x = (_local5 / _local4) * b.x;
_local3.y = (_local5 / _local4) * b.y;
return(_local3);
}
}
Symbol 584 MovieClip [__Packages.org.cove.flade.primitives.Particle] Frame 0
class org.cove.flade.primitives.Particle
{
var init, curr, prev, temp, extents, bmin, bmax, mtd, isVisible, dmc;
function Particle (posX, posY) {
init = new org.cove.flade.util.Vector(posX, posY);
curr = new org.cove.flade.util.Vector(posX, posY);
prev = new org.cove.flade.util.Vector(posX, posY);
temp = new org.cove.flade.util.Vector(0, 0);
extents = new org.cove.flade.util.Vector(0, 0);
bmin = 0;
bmax = 0;
mtd = new org.cove.flade.util.Vector(0, 0);
initializeContainer();
isVisible = true;
}
function initializeContainer() {
var _local3 = 300 + _root.getNextHighestDepth();
var _local4 = "_" + _local3;
dmc = _root.createEmptyMovieClip(_local4, _local3);
}
function setVisible(v) {
isVisible = v;
}
function verlet(sysObj) {
temp.x = curr.x;
temp.y = curr.y;
curr.x = curr.x + ((sysObj.coeffDamp * (curr.x - prev.x)) + sysObj.gravity.x);
curr.y = curr.y + ((sysObj.coeffDamp * (curr.y - prev.y)) + sysObj.gravity.y);
prev.x = temp.x;
prev.y = temp.y;
}
function pin() {
curr.x = init.x;
curr.y = init.y;
prev.x = init.x;
prev.y = init.y;
}
function setPos(px, py) {
curr.x = px;
curr.y = py;
prev.x = px;
prev.y = py;
}
function getCardXProjection() {
bmin = curr.x - extents.x;
bmax = curr.x + extents.x;
}
function getCardYProjection() {
bmin = curr.y - extents.y;
bmax = curr.y + extents.y;
}
function getAxisProjection(axis) {
var _local5 = new org.cove.flade.util.Vector(Math.abs(axis.x), Math.abs(axis.y));
var _local2 = curr.dot(axis);
var _local3 = extents.dot(_local5);
bmin = _local2 - _local3;
bmax = _local2 + _local3;
}
function setMTD(depthX, depthY, depthN, surfNormal) {
var _local4 = Math.abs(depthX);
var _local3 = Math.abs(depthY);
var _local2 = Math.abs(depthN);
if ((_local4 < _local3) && (_local4 < _local2)) {
mtd.setTo(depthX, 0);
} else if ((_local3 < _local4) && (_local3 < _local2)) {
mtd.setTo(0, depthY);
} else if ((_local2 < _local4) && (_local2 < _local3)) {
mtd = surfNormal.multNew(depthN);
}
}
function setXYMTD(depthX, depthY) {
var _local3 = Math.abs(depthX);
var _local2 = Math.abs(depthY);
if (_local3 < _local2) {
mtd.setTo(depthX, 0);
} else {
mtd.setTo(0, depthY);
}
}
function resolveCollision(normal, sysObj) {
var _local2 = curr.minusNew(prev);
var _local3 = normal.dot(_local2);
var _local8 = _local2.minusNew(normal.multNew(_local3));
var _local4 = _local8.multNew(sysObj.coeffFric);
var _local5 = normal.multNew(_local3 * sysObj.coeffRest);
var _local6 = _local5.plusNew(_local4);
var _local7 = _local2.minusNew(_local6);
curr.plus(mtd);
prev = curr.minusNew(_local7);
}
function paint() {
}
function checkCollision(surface, sysObj) {
}
}
Symbol 585 MovieClip [__Packages.org.cove.flade.surfaces.Surface] Frame 0
interface org.cove.flade.surfaces.Surface
{
}
Symbol 586 MovieClip [__Packages.org.cove.flade.primitives.CircleParticle] Frame 0
class org.cove.flade.primitives.CircleParticle extends org.cove.flade.primitives.Particle
{
var radius, contactRadius, extents, closestPoint, dmc, curr;
function CircleParticle (px, py, r) {
super(px, py);
radius = r;
contactRadius = r;
extents = new org.cove.flade.util.Vector(r, r);
closestPoint = new org.cove.flade.util.Vector(0, 0);
}
function paint() {
dmc.clear();
dmc.lineStyle(0, 6710886, 100);
org.cove.flade.graphics.Graphics.paintCircle(dmc, curr.x, curr.y, radius);
}
function checkCollision(surface, sysObj) {
surface.resolveCircleCollision(this, sysObj);
}
}
Symbol 587 MovieClip [__Packages.org.cove.flade.graphics.Graphics] Frame 0
class org.cove.flade.graphics.Graphics
{
function Graphics () {
}
static function paintLine(dmc, x0, y0, x1, y1) {
dmc.moveTo(x0, y0);
dmc.lineTo(x1, y1);
}
static function paintCircle(dmc, x, y, r) {
var mtp8r = (0.414213562373095 * r);
var msp4r = (0.707106781186547 * r);
with (dmc) {
moveTo(x + r, y);
curveTo(r + x, mtp8r + y, msp4r + x, msp4r + y);
curveTo(mtp8r + x, r + y, x, r + y);
curveTo((-mtp8r) + x, r + y, (-msp4r) + x, msp4r + y);
curveTo((-r) + x, mtp8r + y, (-r) + x, y);
curveTo((-r) + x, (-mtp8r) + y, (-msp4r) + x, (-msp4r) + y);
curveTo((-mtp8r) + x, (-r) + y, x, (-r) + y);
curveTo(mtp8r + x, (-r) + y, msp4r + x, (-msp4r) + y);
curveTo(r + x, (-mtp8r) + y, r + x, y);
}
}
static function paintRectangle(dmc, x, y, w, h) {
var w2 = (w / 2);
var h2 = (h / 2);
with (dmc) {
moveTo(x - w2, y - h2);
lineTo(x + w2, y - h2);
lineTo(x + w2, y + h2);
lineTo(x - w2, y + h2);
lineTo(x - w2, y - h2);
}
}
}
Symbol 588 MovieClip [__Packages.org.cove.flade.primitives.RectangleParticle] Frame 0
class org.cove.flade.primitives.RectangleParticle extends org.cove.flade.primitives.Particle
{
var width, height, vertex, extents, isbox, dmc, isVisible, curr;
function RectangleParticle (px, py, w, h, isBox) {
super(px, py);
width = w;
height = h;
vertex = new org.cove.flade.util.Vector(0, 0);
extents = new org.cove.flade.util.Vector(w / 2, h / 2);
isbox = isBox;
if (isbox == undefined) {
isbox = true;
}
if (isbox) {
var _local4 = 200 + _root.getNextHighestDepth();
var _local5 = "_" + _local4;
duplicateMovieClip ("box", "b" + _local4, _local4);
dmc = _root["b" + _local4];
}
}
function paint() {
if (isVisible) {
dmc._x = curr.x;
dmc._y = curr.y;
}
}
function initializeContainer() {
}
function checkCollision(surface, sysObj) {
surface.resolveRectangleCollision(this, sysObj);
}
}
Symbol 589 MovieClip [__Packages.org.cove.flade.constraints.Constraint] Frame 0
interface org.cove.flade.constraints.Constraint
{
}
Symbol 590 MovieClip [__Packages.org.cove.flade.surfaces.AbstractTile] Frame 0
class org.cove.flade.surfaces.AbstractTile
{
var center, verts, normal, isVisible, isActivated, dmc, minX, maxX, minY, maxY;
function AbstractTile (cx, cy) {
center = new org.cove.flade.util.Vector(cx, cy);
verts = new Array();
normal = new org.cove.flade.util.Vector(0, 0);
isVisible = true;
isActivated = true;
initializeContainer();
}
function initializeContainer() {
var _local3 = _root.getNextHighestDepth();
var _local4 = "_" + _local3;
dmc = _root.createEmptyMovieClip(_local4, _local3);
}
function setVisible(v) {
isVisible = v;
}
function setActiveState(a) {
isActivated = a;
}
function getActiveState() {
return(isActivated);
}
function createBoundingRect(rw, rh) {
var _local2 = center.y - (rh / 2);
var _local3 = center.y + (rh / 2);
var _local5 = center.x - (rw / 2);
var _local4 = center.x + (rw / 2);
verts.push(new org.cove.flade.util.Vector(_local4, _local3));
verts.push(new org.cove.flade.util.Vector(_local4, _local2));
verts.push(new org.cove.flade.util.Vector(_local5, _local2));
verts.push(new org.cove.flade.util.Vector(_local5, _local3));
setCardProjections();
}
function testIntervals(boxMin, boxMax, tileMin, tileMax) {
if (boxMax < tileMin) {
return(0);
}
if (tileMax < boxMin) {
return(0);
}
var _local2 = tileMax - boxMin;
var _local1 = tileMin - boxMax;
if (Math.abs(_local2) < Math.abs(_local1)) {
return(_local2);
}
return(_local1);
}
function setCardProjections() {
getCardXProjection();
getCardYProjection();
}
function getCardXProjection() {
minX = verts[0].x;
var _local2 = 1;
while (_local2 < verts.length) {
if (verts[_local2].x < minX) {
minX = verts[_local2].x;
}
_local2++;
}
maxX = verts[0].x;
_local2 = 1;
while (_local2 < verts.length) {
if (verts[_local2].x > maxX) {
maxX = verts[_local2].x;
}
_local2++;
}
}
function getCardYProjection() {
minY = verts[0].y;
var _local2 = 1;
while (_local2 < verts.length) {
if (verts[_local2].y < minY) {
minY = verts[_local2].y;
}
_local2++;
}
maxY = verts[0].y;
_local2 = 1;
while (_local2 < verts.length) {
if (verts[_local2].y > maxY) {
maxY = verts[_local2].y;
}
_local2++;
}
}
function onContact() {
}
}
Symbol 591 MovieClip [__Packages.org.cove.flade.surfaces.RectangleTile] Frame 0
class org.cove.flade.surfaces.RectangleTile extends org.cove.flade.surfaces.AbstractTile implements org.cove.flade.surfaces.Surface
{
var rectWidth, rectHeight, createBoundingRect, isVisible, dmc, center, onContact, normal, testIntervals, minX, maxX, minY, maxY;
function RectangleTile (cx, cy, rw, rh) {
super(cx, cy);
rectWidth = rw;
rectHeight = rh;
createBoundingRect(rw, rh);
}
function paint() {
if (isVisible) {
dmc.clear();
dmc.lineStyle(0, 2237064, 100);
org.cove.flade.graphics.Graphics.paintRectangle(dmc, center.x, center.y, rectWidth, rectHeight);
}
}
function resolveCircleCollision(p, sysObj) {
if (isCircleColliding(p)) {
onContact();
p.resolveCollision(normal, sysObj);
}
}
function resolveRectangleCollision(p, sysObj) {
if (isRectangleColliding(p)) {
onContact();
p.resolveCollision(normal, sysObj);
}
}
function isCircleColliding(p) {
p.getCardXProjection();
var _local6 = testIntervals(p.bmin, p.bmax, minX, maxX);
if (_local6 == 0) {
return(false);
}
p.getCardYProjection();
var _local5 = testIntervals(p.bmin, p.bmax, minY, maxY);
if (_local5 == 0) {
return(false);
}
var _local11 = Math.abs(_local6) < p.radius;
var _local12 = Math.abs(_local5) < p.radius;
if (_local11 && (_local12)) {
var _local10 = center.x + (sign(p.curr.x - center.x) * (rectWidth / 2));
var _local9 = center.y + (sign(p.curr.y - center.y) * (rectHeight / 2));
var _local4 = p.curr.x - _local10;
var _local3 = p.curr.y - _local9;
var _local8 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
var _local7 = p.radius - _local8;
if (_local7 > 0) {
_local4 = _local4 / _local8;
_local3 = _local3 / _local8;
p.mtd.setTo(_local4 * _local7, _local3 * _local7);
normal.setTo(_local4, _local3);
return(true);
}
return(false);
}
p.setXYMTD(_local6, _local5);
normal.setTo(p.mtd.x / Math.abs(_local6), p.mtd.y / Math.abs(_local5));
return(true);
}
function isRectangleColliding(p) {
p.getCardXProjection();
var _local4 = testIntervals(p.bmin, p.bmax, minX, maxX);
if (_local4 == 0) {
return(false);
}
p.getCardYProjection();
var _local3 = testIntervals(p.bmin, p.bmax, minY, maxY);
if (_local3 == 0) {
return(false);
}
p.setXYMTD(_local4, _local3);
normal.setTo(p.mtd.x / Math.abs(_local4), p.mtd.y / Math.abs(_local3));
return(true);
}
function sign(val) {
if (val < 0) {
return(-1);
}
if (val > 0) {
return(1);
}
}
}
Symbol 592 MovieClip [__Packages.org.cove.flade.surfaces.LineSurface] Frame 0
class org.cove.flade.surfaces.LineSurface extends org.cove.flade.surfaces.AbstractTile implements org.cove.flade.surfaces.Surface
{
var p1, p2, collNormal, isVisible, dmc, onContact, faceNormal, collisionDepth, testIntervals, minY, maxY, minX, maxX, sideNormal, minS, maxS, minF, maxF, rise, run, sign, slope, invB, setCardProjections, p3, p4, verts;
function LineSurface (p1x, p1y, p2x, p2y) {
super(0, 0);
p1 = new org.cove.flade.util.Vector(p1x, p1y);
p2 = new org.cove.flade.util.Vector(p2x, p2y);
calcFaceNormal();
collNormal = new org.cove.flade.util.Vector(0, 0);
setCollisionDepth(30);
}
function paint() {
if (isVisible) {
dmc.clear();
dmc.lineStyle(0, 2237064, 100);
org.cove.flade.graphics.Graphics.paintLine(dmc, p1.x, p1.y, p2.x, p2.y);
}
}
function resolveCircleCollision(p, sysObj) {
if (isCircleColliding(p)) {
onContact();
p.resolveCollision(faceNormal, sysObj);
}
}
function resolveRectangleCollision(p, sysObj) {
if (isRectangleColliding(p)) {
onContact();
p.resolveCollision(collNormal, sysObj);
}
}
function setCollisionDepth(d) {
collisionDepth = d;
precalculate();
}
function isCircleColliding(p) {
findClosestPoint(p.curr, p.closestPoint);
var _local3 = p.closestPoint.minusNew(p.curr);
_local3.normalize();
if (inequality(p.curr)) {
var _local5 = Math.abs(_local3.x);
_local3.x = ((faceNormal.x < 0) ? (_local5) : (-_local5));
_local3.y = Math.abs(_local3.y);
}
var _local4 = p.curr.plusNew(_local3.mult(p.radius));
if (segmentInequality(_local4)) {
if (_local4.distance(p.closestPoint) > collisionDepth) {
return(false);
}
var _local7 = _local4.x - p.closestPoint.x;
var _local6 = _local4.y - p.closestPoint.y;
p.mtd.setTo(-_local7, -_local6);
return(true);
}
return(false);
}
function isRectangleColliding(p) {
p.getCardYProjection();
var _local7 = testIntervals(p.bmin, p.bmax, minY, maxY);
if (_local7 == 0) {
return(false);
}
p.getCardXProjection();
var _local8 = testIntervals(p.bmin, p.bmax, minX, maxX);
if (_local8 == 0) {
return(false);
}
p.getAxisProjection(sideNormal);
var _local10 = testIntervals(p.bmin, p.bmax, minS, maxS);
if (_local10 == 0) {
return(false);
}
p.getAxisProjection(faceNormal);
var _local9 = testIntervals(p.bmin, p.bmax, minF, maxF);
if (_local9 == 0) {
return(false);
}
var _local4 = Math.abs(_local8);
var _local3 = Math.abs(_local7);
var _local6 = Math.abs(_local10);
var _local5 = Math.abs(_local9);
if (((_local4 <= _local3) && (_local4 <= _local6)) && (_local4 <= _local5)) {
p.mtd.setTo(_local8, 0);
collNormal.setTo(p.mtd.x / _local4, 0);
} else if (((_local3 <= _local4) && (_local3 <= _local6)) && (_local3 <= _local5)) {
p.mtd.setTo(0, _local7);
collNormal.setTo(0, p.mtd.y / _local3);
} else if (((_local5 <= _local4) && (_local5 <= _local3)) && (_local5 <= _local6)) {
p.mtd = faceNormal.multNew(_local9);
collNormal.copy(faceNormal);
} else if (((_local6 <= _local4) && (_local6 <= _local3)) && (_local6 <= _local5)) {
p.mtd = sideNormal.multNew(_local10);
collNormal.copy(sideNormal);
}
return(true);
}
function precalculate() {
rise = p2.y - p1.y;
run = p2.x - p1.x;
sign = ((run >= 0) ? 1 : -1);
slope = rise / run;
invB = 1 / ((run * run) + (rise * rise));
createRectangle();
calcSideNormal();
setCardProjections();
setAxisProjections();
}
function calcFaceNormal() {
faceNormal = new org.cove.flade.util.Vector(0, 0);
var _local3 = p2.x - p1.x;
var _local2 = p2.y - p1.y;
faceNormal.setTo(_local2, -_local3);
faceNormal.normalize();
}
function segmentInequality(toPoint) {
var _local2 = findU(toPoint);
var _local3 = inequality(toPoint);
return(((_local2 >= 0) && (_local2 <= 1)) && (_local3));
}
function inequality(toPoint) {
var _local2 = ((slope * (toPoint.x - p1.x)) + (p1.y - toPoint.y)) * sign;
return(_local2 <= 0);
}
function findClosestPoint(toPoint, returnVect) {
var _local2 = findU(toPoint);
if (_local2 <= 0) {
returnVect.copy(p1);
return(undefined);
}
if (_local2 >= 1) {
returnVect.copy(p2);
return(undefined);
}
var _local5 = p1.x + (_local2 * (p2.x - p1.x));
var _local4 = p1.y + (_local2 * (p2.y - p1.y));
returnVect.setTo(_local5, _local4);
}
function findU(p) {
var _local2 = ((p.x - p1.x) * run) + ((p.y - p1.y) * rise);
return(_local2 * invB);
}
function createRectangle() {
var _local5 = p2.x + ((-faceNormal.x) * collisionDepth);
var _local3 = p2.y + ((-faceNormal.y) * collisionDepth);
var _local4 = p1.x + ((-faceNormal.x) * collisionDepth);
var _local2 = p1.y + ((-faceNormal.y) * collisionDepth);
p3 = new org.cove.flade.util.Vector(_local5, _local3);
p4 = new org.cove.flade.util.Vector(_local4, _local2);
verts.push(p1);
verts.push(p2);
verts.push(p3);
verts.push(p4);
}
function setAxisProjections() {
var _local2;
minF = p2.dot(faceNormal);
maxF = p3.dot(faceNormal);
if (minF > maxF) {
_local2 = minF;
minF = maxF;
maxF = _local2;
}
minS = p1.dot(sideNormal);
maxS = p2.dot(sideNormal);
if (minS > maxS) {
_local2 = minS;
minS = maxS;
maxS = _local2;
}
}
function calcSideNormal() {
sideNormal = new org.cove.flade.util.Vector(0, 0);
var _local3 = p3.x - p2.x;
var _local2 = p3.y - p2.y;
sideNormal.setTo(_local2, -_local3);
sideNormal.normalize();
}
}
Symbol 62 MovieClip Frame 112
_root.play();
Symbol 110 Button
on (release) {
getURL ("http://www.rustyarcade.com/ref/burnstuffanddie/menu", "_blank");
}
Symbol 113 Button
on (release) {
if (first_game) {
clearSure._x = -300;
optionsBox._x = -300;
instructionsBox._x = 255;
} else {
gotoAndPlay (7);
}
}
Symbol 117 Button
on (release) {
getURL ("http://www.rustyarcade.com/blog/read/35", "_blank");
}
Symbol 121 Button
on (release) {
instructionsBox._x = -300;
clearSure._x = -300;
if (optionsBox._x < 0) {
optionsBox._x = 177;
} else {
optionsBox._x = -200;
}
}
Symbol 125 Button
on (release) {
gotoAndStop (5);
}
Symbol 133 Button
on (release) {
getURL ("http://www.rustyarcade.com/ref/burnstuffanddie/menu", "_blank");
}
Symbol 139 MovieClip Frame 1
if (_root.muteVal) {
gotoAndStop (1);
} else {
gotoAndStop (2);
}
Symbol 142 MovieClip Frame 1
if (_root.sfxMuteVal) {
stop();
} else {
gotoAndStop (2);
}
Symbol 148 Button
on (release) {
getURL ("http://www.rustyarcade.com/ref/burnstuffanddie/options", "_blank");
}
Symbol 156 Button
on (release) {
_root._quality = "MEDIUM";
}
Symbol 158 Button
on (release) {
_root._quality = "HIGH";
}
Symbol 160 Button
on (release) {
_root._quality = "LOW";
}
Symbol 162 Button
on (release) {
getURL ("http://www.rustyarcade.com/blog/read/35", "_blank");
}
Symbol 163 MovieClip Frame 1
mute_btn.onRelease = function () {
_root.muteVal = !_root.muteVal;
if (_root.muteVal) {
if (position) {
_root.backgroundMusic.start(position, 1);
} else {
_root.backgroundMusic.start(0, 1);
}
mute_btn.gotoAndStop(1);
} else {
var position = _root.backgroundMusic.duration;
_root.backgroundMusic.stop();
mute_btn.gotoAndStop(2);
}
};
mute_sfx_btn.onRelease = function () {
_root.sfxMuteVal = !_root.sfxMuteVal;
if (_root.sfxMuteVal) {
mute_sfx_btn.gotoAndStop(1);
} else {
mute_sfx_btn.gotoAndStop(2);
}
};
Instance of Symbol 152 MovieClip in Symbol 163 MovieClip Frame 1
onClipEvent (mouseDown) {
if (this.hitTest(_level0._xmouse, _level0._ymouse)) {
followMouse = true;
}
}
onClipEvent (enterFrame) {
if (followMouse) {
this._x = (_level0._xmouse - _parent._x) + (this._width / 2);
if (this._x < lineStart) {
this._x = lineStart;
} else if (this._x > lineEnd) {
this._x = lineEnd;
}
_root.Volume = Math.round((this._x - lineStart) / lineRatio);
}
}
onClipEvent (mouseUp) {
followMouse = false;
_root.Volume = Math.round((this._x - lineStart) / lineRatio);
if (_root.Volume < 0) {
_root.Volume = 0;
} else if (_root.Volume > 100) {
_root.Volume = 100;
}
_root.backgroundMusic.setVolume(_root.Volume);
}
onClipEvent (load) {
linemc = _parent.audioslider;
lineStart = (linemc._x - (linemc._width / 2)) + (this._width / 2);
lineEnd = (linemc._x + (linemc._width / 2)) - (this._width / 2);
lineLength = lineEnd - lineStart;
lineRatio = lineLength / 100;
this._x = (_root.Volume * lineRatio) + lineStart;
followMouse = false;
}
Instance of Symbol 152 MovieClip in Symbol 163 MovieClip Frame 1
onClipEvent (mouseDown) {
if (this.hitTest(_level0._xmouse, _level0._ymouse)) {
followMouse = true;
}
}
onClipEvent (enterFrame) {
if (followMouse) {
this._x = (_level0._xmouse - _parent._x) + (this._width / 2);
if (this._x < lineStart) {
this._x = lineStart;
} else if (this._x > lineEnd) {
this._x = lineEnd;
}
_root.sfxVolume = Math.round((this._x - lineStart) / lineRatio);
}
}
onClipEvent (mouseUp) {
_root.sfxVolume = Math.round((this._x - lineStart) / lineRatio);
if (followMouse) {
_root.playSound(this, "shoes.wav");
}
followMouse = false;
if (_root.sfxVolume < 0) {
_root.sfxVolume = 0;
} else if (_root.sfxVolume > 100) {
_root.sfxVolume = 100;
}
}
onClipEvent (load) {
linemc = _parent.audioslider2;
lineStart = (linemc._x - (linemc._width / 2)) + (this._width / 2);
lineEnd = (linemc._x + (linemc._width / 2)) - (this._width / 2);
lineLength = lineEnd - lineStart;
lineRatio = lineLength / 100;
this._x = (_root.sfxVolume * lineRatio) + lineStart;
followMouse = false;
}
Symbol 167 Button
on (release) {
optionsBox._x = -300;
instructionsBox._x = -300;
clearSure._x = 360;
}
Symbol 172 Button
on (release) {
_root.saveData.data.ach_survive_1 = false;
_root.saveData.data.ach_survive_2 = false;
_root.saveData.data.ach_survive_5 = false;
_root.saveData.data.ach_survive_10 = false;
_root.saveData.data.ach_oxygen_5 = false;
_root.saveData.data.ach_oxygen_10 = false;
_root.saveData.data.ach_oxygen_20 = false;
_root.saveData.data.ach_burn_10 = false;
_root.saveData.data.ach_burn_20 = false;
_root.saveData.data.ach_burn_50 = false;
_root.saveData.data.ach_combo_5 = false;
_root.saveData.data.ach_combo_10 = false;
_root.saveData.data.ach_combo_20 = false;
_root.saveData.data.ach_combo_50 = false;
_root.saveData.data.ach_die_1 = false;
_root.saveData.data.ach_die_5 = false;
_root.saveData.data.ach_die_10 = false;
_root.saveData.data.game = true;
_root.saveData.data.died = 0;
_root.saveData.flush();
this._x = -200;
}
Symbol 175 Button
on (release) {
this._x = -200;
}
Symbol 184 Button
on (release) {
_root.first_game = false;
_root.playGame();
}
Symbol 304 Button
on (release) {
gotoAndStop (4);
}
Symbol 308 Button
on (release) {
getURL ("http://www.rustyarcade.com/ref/burnstuffanddie/medals", "_blank");
}
Symbol 315 MovieClip Frame 33
stop();
Symbol 319 MovieClip Frame 25
stop();
Symbol 321 MovieClip Frame 74
stop();
Symbol 341 MovieClip Frame 16
stop();
removeMovieClip(_parent);
this._x = -200;
this._y = -200;
Symbol 345 MovieClip Frame 20
removeMovieClip(_parent);
Symbol 346 MovieClip Frame 1
stop();
Symbol 413 MovieClip Frame 17
stop();
Symbol 428 MovieClip Frame 1
gotoAndStop((Math.round(Math.random() * 29) * 2) + 1);
Symbol 428 MovieClip Frame 22
_root.playSound(this, "shatter.wav");
Symbol 428 MovieClip Frame 24
_root.playSound(this, "shatter.wav");
Symbol 428 MovieClip Frame 26
_root.playSound(this, "shatter.wav");
Symbol 428 MovieClip Frame 28
_root.playSound(this, "shatter.wav");
Symbol 428 MovieClip Frame 30
_root.playSound(this, "crack.wav");
Symbol 428 MovieClip Frame 32
_root.playSound(this, "crack.wav");
Symbol 428 MovieClip Frame 38
_root.playSound(this, "crack.wav");
Symbol 428 MovieClip Frame 40
_root.playSound(this, "crack.wav");
Symbol 428 MovieClip Frame 48
_root.playSound(this, "explode.wav");
Symbol 428 MovieClip Frame 50
_root.playSound(this, "explode.wav");
Symbol 428 MovieClip Frame 52
_root.playSound(this, "explode.wav");
Symbol 428 MovieClip Frame 54
_root.playSound(this, "crack.wav");
Symbol 428 MovieClip Frame 56
_root.playSound(this, "crack.wav");
Symbol 433 MovieClip Frame 37
stop();
removeMovieClip(this);
Symbol 441 MovieClip Frame 24
removeMovieClip(_parent);
Symbol 449 MovieClip Frame 20
removeMovieClip(_parent);
Symbol 481 MovieClip Frame 16
stop();
removeMovieClip(_parent);
this._x = -200;
this._y = -200;
Symbol 488 MovieClip Frame 20
removeMovieClip(_parent);
Symbol 493 MovieClip Frame 20
removeMovieClip(_parent);
Symbol 494 MovieClip Frame 1
stop();
Symbol 496 MovieClip Frame 50
stop();
removeMovieClip(this);
Symbol 514 Button
on (release) {
getURL ("http://www.rustyarcade.com/ref/burnstuffanddie/gameover", "_blank");
}
Symbol 525 Button
on (release) {
getURL ("http://www.rustyarcade.com/blog/read/35", "_blank");
}
Symbol 526 Button
on (release) {
_root.play();
}
Symbol 527 Button
on (release) {
_root.instant_play = true;
_root.play();
}
Symbol 528 Button
on (release) {
_root.submit_score = _root.score;
_root.play();
}
Symbol 529 Button
on (release) {
getURL ("http://www.rustyarcade.com", "_blank");
}
Symbol 530 Button
on (release) {
getURL ("http://www.rustyarcade.com/ref/burnstuffanddie/gameover", "_blank");
}
Symbol 533 Button
on (release) {
_root.pausedVal = true;
_root.air_bar.btn_pause.gotoAndStop(1);
this.gotoAndStop(1);
}
Symbol 535 MovieClip Frame 1
stop();
Symbol 535 MovieClip Frame 126
_root.delete_out = true;
Symbol 535 MovieClip Frame 143
stop();
Symbol 545 MovieClip Frame 1
_root.playSound(this, "321.mp3");
Symbol 552 MovieClip Frame 1
if (_root.muteVal) {
gotoAndStop (1);
} else {
gotoAndStop (2);
}
Symbol 555 MovieClip Frame 1
if (_root.sfxMuteVal) {
gotoAndStop (1);
} else {
gotoAndStop (2);
}
Symbol 558 MovieClip Frame 1
if (_root.pausedVal) {
gotoAndStop (1);
} else {
gotoAndStop (2);
}
Symbol 561 MovieClip Frame 1
gotoAndStop(_root.stupid_achievement_var);
Symbol 570 MovieClip Frame 29
if (_root.achievement_got) {
_root.playSound(this, "medal.mp3");
_root.stupid_achievement_var = _root.achievement_got;
_root.achievement_got = false;
} else {
gotoAndPlay (1);
}
Symbol 574 MovieClip Frame 1
btn_sfx.onRelease = function () {
_root.sfxMuteVal = !_root.sfxMuteVal;
if (_root.sfxMuteVal) {
btn_sfx.gotoAndStop(1);
} else {
btn_sfx.gotoAndStop(2);
}
};
btn_mute.onRelease = function () {
_root.muteVal = !_root.muteVal;
if (_root.muteVal) {
if (position) {
_root.backgroundMusic.start(position, 1);
} else {
_root.backgroundMusic.start(0, 1);
}
btn_mute.gotoAndStop(1);
} else {
var position = _root.backgroundMusic.duration;
_root.backgroundMusic.stop();
btn_mute.gotoAndStop(2);
}
};
btn_pause.onRelease = function () {
_root.pausedVal = !_root.pausedVal;
if (_root.pausedVal) {
btn_pause.gotoAndStop(1);
_root.game_over.gotoAndStop(1);
} else {
btn_pause.gotoAndStop(2);
_root.game_over.gotoAndStop(144);
}
};