Frame 1
Button.prototype.tabEnabled = false;
MovieClip.prototype.tabEnabled = false;
fscommand ("trapallkeys", "true");
fscommand ("allowscale", "false");
fscommand ("showmenu", "false");
Stage.scaleMode = "noScale";
_quality = "HIGH";
_root.game_id = "1687";
_root.main_link = "http://www.2DPlay.com/index.php?gameid=" + _root.game_id;
_root.download_link = "http://www.2DPlay.com/downloadgame.php?gameid=" + _root.game_id;
_root.get_game_link = "http://www.2DPlay.com/freecontent.htm";
_root.scores_link = ("http://www.2Dplay.com/highscores.php?gameid=" + _root.game_id) + "&hiscore=";
_root.viewscores_link = "http://www.2dplay.com/showscores.php?gameid=" + _root.game_id;
stop();
Instance of Symbol 92 MovieClip [TMPfric6p884d] in Frame 1
//component parameters
onClipEvent (construct) {
flashVersion = 8;
gameID = 1687;
movieFramerate = 30;
skipPreloader = false;
startFrameLabel = "init_game";
}
Frame 4
function hex_md5(s) {
return(binl2hex(core_md5(str2binl(s), s.length * chrsz)));
}
function b64_md5(s) {
return(binl2b64(core_md5(str2binl(s), s.length * chrsz)));
}
function str_md5(s) {
return(binl2str(core_md5(str2binl(s), s.length * chrsz)));
}
function hex_hmac_md5(key, data) {
return(binl2hex(core_hmac_md5(key, data)));
}
function b64_hmac_md5(key, data) {
return(binl2b64(core_hmac_md5(key, data)));
}
function str_hmac_md5(key, data) {
return(binl2str(core_hmac_md5(key, data)));
}
function md5_vm_test() {
return(hex_md5("abc") == "900150983cd24fb0d6963f7d28e17f72");
}
function core_md5(x, len) {
x[len >> 5] = x[len >> 5] | (128 << (len % 32));
x[(((len + 64) >>> 9) << 4) + 14] = len;
var _local4 = 1732584193 /* 0x67452301 */;
var _local3 = -271733879;
var _local2 = -1732584194;
var _local1 = 271733878 /* 0x10325476 */;
var _local5 = 0;
while (_local5 < x.length) {
var _local10 = _local4;
var _local9 = _local3;
var _local8 = _local2;
var _local7 = _local1;
_local4 = md5_ff(_local4, _local3, _local2, _local1, x[_local5 + 0], 7, -680876936);
_local1 = md5_ff(_local1, _local4, _local3, _local2, x[_local5 + 1], 12, -389564586);
_local2 = md5_ff(_local2, _local1, _local4, _local3, x[_local5 + 2], 17, 606105819);
_local3 = md5_ff(_local3, _local2, _local1, _local4, x[_local5 + 3], 22, -1044525330);
_local4 = md5_ff(_local4, _local3, _local2, _local1, x[_local5 + 4], 7, -176418897);
_local1 = md5_ff(_local1, _local4, _local3, _local2, x[_local5 + 5], 12, 1200080426);
_local2 = md5_ff(_local2, _local1, _local4, _local3, x[_local5 + 6], 17, -1473231341);
_local3 = md5_ff(_local3, _local2, _local1, _local4, x[_local5 + 7], 22, -45705983);
_local4 = md5_ff(_local4, _local3, _local2, _local1, x[_local5 + 8], 7, 1770035416);
_local1 = md5_ff(_local1, _local4, _local3, _local2, x[_local5 + 9], 12, -1958414417);
_local2 = md5_ff(_local2, _local1, _local4, _local3, x[_local5 + 10], 17, -42063);
_local3 = md5_ff(_local3, _local2, _local1, _local4, x[_local5 + 11], 22, -1990404162);
_local4 = md5_ff(_local4, _local3, _local2, _local1, x[_local5 + 12], 7, 1804603682);
_local1 = md5_ff(_local1, _local4, _local3, _local2, x[_local5 + 13], 12, -40341101);
_local2 = md5_ff(_local2, _local1, _local4, _local3, x[_local5 + 14], 17, -1502002290);
_local3 = md5_ff(_local3, _local2, _local1, _local4, x[_local5 + 15], 22, 1236535329);
_local4 = md5_gg(_local4, _local3, _local2, _local1, x[_local5 + 1], 5, -165796510);
_local1 = md5_gg(_local1, _local4, _local3, _local2, x[_local5 + 6], 9, -1069501632);
_local2 = md5_gg(_local2, _local1, _local4, _local3, x[_local5 + 11], 14, 643717713);
_local3 = md5_gg(_local3, _local2, _local1, _local4, x[_local5 + 0], 20, -373897302);
_local4 = md5_gg(_local4, _local3, _local2, _local1, x[_local5 + 5], 5, -701558691);
_local1 = md5_gg(_local1, _local4, _local3, _local2, x[_local5 + 10], 9, 38016083);
_local2 = md5_gg(_local2, _local1, _local4, _local3, x[_local5 + 15], 14, -660478335);
_local3 = md5_gg(_local3, _local2, _local1, _local4, x[_local5 + 4], 20, -405537848);
_local4 = md5_gg(_local4, _local3, _local2, _local1, x[_local5 + 9], 5, 568446438);
_local1 = md5_gg(_local1, _local4, _local3, _local2, x[_local5 + 14], 9, -1019803690);
_local2 = md5_gg(_local2, _local1, _local4, _local3, x[_local5 + 3], 14, -187363961);
_local3 = md5_gg(_local3, _local2, _local1, _local4, x[_local5 + 8], 20, 1163531501);
_local4 = md5_gg(_local4, _local3, _local2, _local1, x[_local5 + 13], 5, -1444681467);
_local1 = md5_gg(_local1, _local4, _local3, _local2, x[_local5 + 2], 9, -51403784);
_local2 = md5_gg(_local2, _local1, _local4, _local3, x[_local5 + 7], 14, 1735328473);
_local3 = md5_gg(_local3, _local2, _local1, _local4, x[_local5 + 12], 20, -1926607734);
_local4 = md5_hh(_local4, _local3, _local2, _local1, x[_local5 + 5], 4, -378558);
_local1 = md5_hh(_local1, _local4, _local3, _local2, x[_local5 + 8], 11, -2022574463);
_local2 = md5_hh(_local2, _local1, _local4, _local3, x[_local5 + 11], 16, 1839030562);
_local3 = md5_hh(_local3, _local2, _local1, _local4, x[_local5 + 14], 23, -35309556);
_local4 = md5_hh(_local4, _local3, _local2, _local1, x[_local5 + 1], 4, -1530992060);
_local1 = md5_hh(_local1, _local4, _local3, _local2, x[_local5 + 4], 11, 1272893353);
_local2 = md5_hh(_local2, _local1, _local4, _local3, x[_local5 + 7], 16, -155497632);
_local3 = md5_hh(_local3, _local2, _local1, _local4, x[_local5 + 10], 23, -1094730640);
_local4 = md5_hh(_local4, _local3, _local2, _local1, x[_local5 + 13], 4, 681279174);
_local1 = md5_hh(_local1, _local4, _local3, _local2, x[_local5 + 0], 11, -358537222);
_local2 = md5_hh(_local2, _local1, _local4, _local3, x[_local5 + 3], 16, -722521979);
_local3 = md5_hh(_local3, _local2, _local1, _local4, x[_local5 + 6], 23, 76029189);
_local4 = md5_hh(_local4, _local3, _local2, _local1, x[_local5 + 9], 4, -640364487);
_local1 = md5_hh(_local1, _local4, _local3, _local2, x[_local5 + 12], 11, -421815835);
_local2 = md5_hh(_local2, _local1, _local4, _local3, x[_local5 + 15], 16, 530742520);
_local3 = md5_hh(_local3, _local2, _local1, _local4, x[_local5 + 2], 23, -995338651);
_local4 = md5_ii(_local4, _local3, _local2, _local1, x[_local5 + 0], 6, -198630844);
_local1 = md5_ii(_local1, _local4, _local3, _local2, x[_local5 + 7], 10, 1126891415);
_local2 = md5_ii(_local2, _local1, _local4, _local3, x[_local5 + 14], 15, -1416354905);
_local3 = md5_ii(_local3, _local2, _local1, _local4, x[_local5 + 5], 21, -57434055);
_local4 = md5_ii(_local4, _local3, _local2, _local1, x[_local5 + 12], 6, 1700485571);
_local1 = md5_ii(_local1, _local4, _local3, _local2, x[_local5 + 3], 10, -1894986606);
_local2 = md5_ii(_local2, _local1, _local4, _local3, x[_local5 + 10], 15, -1051523);
_local3 = md5_ii(_local3, _local2, _local1, _local4, x[_local5 + 1], 21, -2054922799);
_local4 = md5_ii(_local4, _local3, _local2, _local1, x[_local5 + 8], 6, 1873313359);
_local1 = md5_ii(_local1, _local4, _local3, _local2, x[_local5 + 15], 10, -30611744);
_local2 = md5_ii(_local2, _local1, _local4, _local3, x[_local5 + 6], 15, -1560198380);
_local3 = md5_ii(_local3, _local2, _local1, _local4, x[_local5 + 13], 21, 1309151649);
_local4 = md5_ii(_local4, _local3, _local2, _local1, x[_local5 + 4], 6, -145523070);
_local1 = md5_ii(_local1, _local4, _local3, _local2, x[_local5 + 11], 10, -1120210379);
_local2 = md5_ii(_local2, _local1, _local4, _local3, x[_local5 + 2], 15, 718787259);
_local3 = md5_ii(_local3, _local2, _local1, _local4, x[_local5 + 9], 21, -343485551);
_local4 = safe_add(_local4, _local10);
_local3 = safe_add(_local3, _local9);
_local2 = safe_add(_local2, _local8);
_local1 = safe_add(_local1, _local7);
_local5 = _local5 + 16;
}
return(Array(_local4, _local3, _local2, _local1));
}
function md5_cmn(q, a, b, x, s, t) {
return(safe_add(bit_rol(safe_add(safe_add(a, q), safe_add(x, t)), s), b));
}
function md5_ff(a, b, c, d, x, s, t) {
return(md5_cmn((b & c) | ((~b) & d), a, b, x, s, t));
}
function md5_gg(a, b, c, d, x, s, t) {
return(md5_cmn((b & d) | (c & (~d)), a, b, x, s, t));
}
function md5_hh(a, b, c, d, x, s, t) {
return(md5_cmn((b ^ c) ^ d, a, b, x, s, t));
}
function md5_ii(a, b, c, d, x, s, t) {
return(md5_cmn(c ^ (b | (~d)), a, b, x, s, t));
}
function core_hmac_md5(key, data) {
var _local2 = str2binl(key);
if (_local2.length > 16) {
_local2 = core_md5(_local2, key.length * chrsz);
}
var _local3 = Array(16);
var _local4 = Array(16);
var _local1 = 0;
while (_local1 < 16) {
_local3[_local1] = _local2[_local1] ^ 909522486;
_local4[_local1] = _local2[_local1] ^ 1549556828;
_local1++;
}
var _local5 = core_md5(_local3.concat(str2binl(data)), 512 + (data.length * chrsz));
return(core_md5(_local4.concat(_local5), 640));
}
function safe_add(x, y) {
var _local1 = (x & 65535) + (y & 65535);
var _local2 = ((x >> 16) + (y >> 16)) + (_local1 >> 16);
return((_local2 << 16) | (_local1 & 65535));
}
function bit_rol(num, cnt) {
return((num << cnt) | (num >>> (32 - cnt)));
}
function str2binl(str) {
var _local3 = Array();
var _local4 = (1 << chrsz) - 1;
var _local1 = 0;
while (_local1 < (str.length * chrsz)) {
_local3[_local1 >> 5] = _local3[_local1 >> 5] | ((str.charCodeAt(_local1 / chrsz) & _local4) << (_local1 % 32));
_local1 = _local1 + chrsz;
}
return(_local3);
}
function binl2str(bin) {
var _local3 = "";
var _local4 = (1 << chrsz) - 1;
var _local1 = 0;
while (_local1 < (bin.length * 32)) {
_local3 = _local3 + String.fromCharCode((bin[_local1 >> 5] >>> (_local1 % 32)) & _local4);
_local1 = _local1 + chrsz;
}
return(_local3);
}
function binl2hex(binarray) {
var _local3 = (hexcase ? "0123456789ABCDEF" : "0123456789abcdef");
var _local4 = "";
var _local1 = 0;
while (_local1 < (binarray.length * 4)) {
_local4 = _local4 + (_local3.charAt((binarray[_local1 >> 2] >> (((_local1 % 4) * 8) + 4)) & 15) + _local3.charAt((binarray[_local1 >> 2] >> ((_local1 % 4) * 8)) & 15));
_local1++;
}
return(_local4);
}
function binl2b64(binarray) {
var _local6 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
var _local4 = "";
var _local2 = 0;
while (_local2 < (binarray.length * 4)) {
var _local5 = ((((binarray[_local2 >> 2] >> (8 * (_local2 % 4))) & 255) << 16) | (((binarray[(_local2 + 1) >> 2] >> (8 * ((_local2 + 1) % 4))) & 255) << 8)) | ((binarray[(_local2 + 2) >> 2] >> (8 * ((_local2 + 2) % 4))) & 255);
var _local1 = 0;
while (_local1 < 4) {
if (((_local2 * 8) + (_local1 * 6)) > (binarray.length * 32)) {
_local4 = _local4 + b64pad;
} else {
_local4 = _local4 + _local6.charAt((_local5 >> (6 * (3 - _local1))) & 63);
}
_local1++;
}
_local2 = _local2 + 3;
}
return(_local4);
}
var newContextMenu = (new Classes.ContextMenuController());
var gameSettings = (new Classes.SettingsController());
var sndController = (new Classes.SoundController());
var mainController = (new Classes.GameController(sndController));
stop();
var hexcase = 0;
var b64pad = "";
var chrsz = 8;
Frame 5
_root.startFromLevel = 1;
sndController.playMusicTrack("bushsong.wav");
stop();
Instance of Symbol 102 MovieClip [ButtonMC] in Frame 5
//component parameters
onClipEvent (construct) {
labelString = "Play";
flashing = true;
}
onClipEvent (load) {
pressAction = function () {
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"game_mode_select"});
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Frame 5
//component parameters
onClipEvent (construct) {
labelString = "Instructions";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"instructions"});
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Frame 5
//component parameters
onClipEvent (construct) {
labelString = "High Scores";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.viewscores_link, "_blank");
};
}
Instance of Symbol 112 MovieClip [2dplayButton] in Frame 5
//component parameters
onClipEvent (construct) {
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.main_link, "_blank");
};
}
Frame 6
stop();
Frame 7
stop();
Instance of Symbol 102 MovieClip [ButtonMC] in Frame 7
//component parameters
onClipEvent (construct) {
labelString = "Main Menu";
flashing = true;
}
onClipEvent (load) {
pressAction = function () {
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"main_menu"});
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Frame 7
//component parameters
onClipEvent (construct) {
labelString = "(quality settings)";
flashing = false;
}
onClipEvent (load) {
labelString = _root.mainController.getQualityString();
initDynamicButton();
pressAction = function () {
_root.mainController.switchQuality();
labelString = _root.mainController.getQualityString();
initDynamicButton();
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Frame 7
//component parameters
onClipEvent (construct) {
labelString = "(sound settings)";
flashing = false;
}
onClipEvent (load) {
labelString = _root.mainController.getSoundString();
initDynamicButton();
pressAction = function () {
_root.mainController.switchSound();
labelString = _root.mainController.getSoundString();
initDynamicButton();
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Frame 7
//component parameters
onClipEvent (construct) {
labelString = "Get Game For Your Site";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.get_game_link, "_blank");
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Frame 7
//component parameters
onClipEvent (construct) {
labelString = "Play More Games";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.main_link, "_blank");
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Frame 7
//component parameters
onClipEvent (construct) {
labelString = "High Scores";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.viewscores_link, "_blank");
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Frame 7
//component parameters
onClipEvent (construct) {
labelString = "Download Game";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.download_link, "_blank");
};
}
Frame 8
stop();
Frame 9
sndController.playMusicTrack("bushsong.wav");
gameMap.init();
stop();
Frame 10
mainController.buildLevel();
stop();
Frame 11
sndController.playMusicTrack("bushsong.wav");
stop();
Frame 12
sndController.stopMusic();
stop();
Frame 13
sndController.stopMusic();
stop();
Symbol 23 Button
on (press) {
getURL ("http://www.2DPlay.com/index.php?gameid=" + _parent.gameID, "_blank");
}
Symbol 25 MovieClip Frame 1
stop();
Symbol 83 MovieClip Frame 1
_parent.showLogo();
stop();
Instance of Symbol 25 MovieClip in Symbol 83 MovieClip Frame 11
onClipEvent (load) {
_parent.sfx.stop();
_parent.sfx = new Sound(_parent);
_parent.sfx.attachSound("SCIFI.WAV");
_parent.sfx.start(0, 1);
}
Instance of Symbol 25 MovieClip in Symbol 83 MovieClip Frame 69
onClipEvent (load) {
_parent.sfx.stop();
_parent.sfx = new Sound(_parent);
_parent.sfx.attachSound("BEEPDBL.WAV");
_parent.sfx.start(0, 1);
}
Instance of Symbol 25 MovieClip in Symbol 83 MovieClip Frame 82
onClipEvent (load) {
_parent.sfx.stop();
_parent.sfx = new Sound(_parent);
_parent.sfx.attachSound("INSERT4.WAV");
_parent.sfx.start(0, 1);
}
Instance of Symbol 25 MovieClip in Symbol 83 MovieClip Frame 96
onClipEvent (load) {
_parent.sfx.stop();
_parent.sfx = new Sound(_parent);
_parent.sfx.attachSound("MSOVR2.WAV");
_parent.sfx.start(0, 1);
}
Instance of Symbol 25 MovieClip in Symbol 83 MovieClip Frame 112
onClipEvent (load) {
_parent.sfx.stop();
_parent.sfx = new Sound(_parent);
_parent.sfx.attachSound("BLOOB.WAV");
_parent.sfx.start(0, 1);
}
Symbol 92 MovieClip [TMPfric6p884d] Frame 1
function detectFlashVersion(detectVersion) {
var _local3 = System.capabilities.version;
var _local2;
var _local1 = 0;
while (_local1 < _local3.length) {
_local2 = Number(_local3.charAt(_local1));
if (!isNaN(_local2)) {
_local2 = ((!isNaN(Number(_local3.charAt(_local1 + 1)))) ? (Number(String(_local2) + _local3.charAt(_local1 + 1))) : (_local2));
break;
}
_local1++;
}
if (_local2 < detectVersion) {
gotoAndPlay (3);
} else {
gotoAndPlay (2);
}
}
function startPreload() {
this.onEnterFrame = function () {
this.preload();
};
}
function preload() {
var _local3 = _root.getBytesTotal();
var _local4 = _root.getBytesLoaded();
var _local5 = Math.floor((_local4 / _local3) * 100);
loader_bar.mask._xscale = _local5;
loader_bar._alpha = ((loader_bar._alpha < 100) ? (loader_bar._alpha + 10) : 100);
if ((_local4 >= _local3) && (_local3 > 0)) {
delete this.onEnterFrame;
_root.gotoAndPlay(startFrameLabel);
}
}
function showLogo() {
this.playbackPercent = 0;
this.onEnterFrame = function () {
this.logoFrameStep();
};
}
function logoFrameStep() {
var _local3 = 30;
var _local2 = 200;
var _local4 = Math.floor(playbackPercent * _local2) + 1;
playbackPercent = playbackPercent + ((_local3 / movieFramerate) / _local2);
logo.gotoAndStop(_local4);
if ((playbackPercent >= 1) || (skipPreloader)) {
delete this.onEnterFrame;
startPreload();
}
}
_visible = false;
detectFlashVersion(flashVersion);
stop();
Symbol 92 MovieClip [TMPfric6p884d] Frame 2
loader_bar.mask._xscale = 0;
loader_bar._alpha = 0;
_visible = true;
stop();
Symbol 92 MovieClip [TMPfric6p884d] Frame 3
messageField.html = true;
messageField.multiline = true;
messageField.htmlText = ((("<font face='_sans' color='#FFFFFF'><p align='center'>You will need the <a href='http://www.adobe.com/go/getflashplayer'><u>Flash Player version " + flashVersion) + "</u></a> to play this game\r\r\rAlternatively you can download the game from <a href='http://www.2dplay.com'><u>2DPlay.com</u></a> by clicking <a href='http://www.2dplay.com/downloadgame.php?gameid=") + gameID) + "'><u>here</u></a></p></font>";
_visible = true;
stop();
Symbol 1342 MovieClip [__Packages.Classes.ObjectTransition] Frame 0
class Classes.ObjectTransition
{
var transObject, transitionState;
function ObjectTransition (_transObject, _appear) {
transObject = _transObject;
appear = _appear;
if (appear) {
transObject._alpha = 0;
transitionState = 0;
} else {
transObject._alpha = 100;
transitionState = 100;
}
var thisObject = this;
transObject.onEnterFrame = function () {
thisObject.update();
};
}
function update() {
transObject.filters = [new flash.filters.BlurFilter(20 - (transitionState / 5), 20 - (transitionState / 5), 1)];
transObject._alpha = transitionState;
if (appear) {
transitionState = transitionState + transitionSpeed;
if (transitionState >= 100) {
transObject._alpha = 100;
transObject.filters = [];
delete transObject.onEnterFrame;
}
} else {
transitionState = transitionState - transitionSpeed;
if (transitionState <= 0) {
delete transObject.onEnterFrame;
transObject._visible = false;
transObject.removeMovieClip();
}
}
}
var appear = true;
var transitionSpeed = 10;
}
Symbol 1343 MovieClip [__Packages.Classes.ButtonMC] Frame 0
class Classes.ButtonMC extends MovieClip
{
var initScale, _xscale, scaleAmp, labelField, hitAreaMC, flashing, onEnterFrame;
function ButtonMC () {
super();
initScale = _xscale;
scaleAmp = (initScale / 100) * 7;
hitAreaMC._width = labelField.textWidth;
hitAreaMC._height = labelField.textHeight;
hitAreaMC.onRelease = function () {
this._parent.pressAction();
};
if (!flashing) {
hitAreaMC.onRollOver = function () {
this._parent.mouseOver();
};
hitAreaMC.onRollOut = (hitAreaMC.onDragOut = function () {
this._parent.mouseOut();
});
} else {
onEnterFrame = function () {
this.sinus = this.sinus + 0.15;
this._xscale = (this._yscale = this.initScale + (this.scaleAmp * Math.abs(Math.sin(this.sinus))));
};
}
}
function initDynamicButton() {
hitAreaMC._width = labelField.textWidth;
hitAreaMC._height = labelField.textHeight;
}
function mouseOver() {
onEnterFrame = function () {
this.sinus = ((this.sinus >= (Math.PI/2)) ? (Math.PI/2) : (this.sinus + 0.15));
this._xscale = (this._yscale = this.initScale + (this.scaleAmp * Math.sin(this.sinus)));
if (this.sinus == (Math.PI/2)) {
delete this.onEnterFrame;
}
};
}
function mouseOut() {
onEnterFrame = function () {
this.sinus = ((this.sinus <= 0) ? 0 : (this.sinus - 0.15));
this._xscale = (this._yscale = this.initScale + (this.scaleAmp * Math.sin(this.sinus)));
if (this.sinus == 0) {
delete this.onEnterFrame;
}
};
}
var sinus = 0;
}
Symbol 1344 MovieClip [__Packages.Classes.SelectedIcon] Frame 0
class Classes.SelectedIcon extends MovieClip
{
var _alpha, type;
function SelectedIcon () {
super();
_alpha = 0;
}
function select(_type) {
type = _type;
}
function update() {
_alpha = Math.abs(Math.sin(selectSinus)) * 100;
selectSinus = selectSinus + 0.25;
}
var selectSinus = 0;
}
Symbol 1345 MovieClip [__Packages.Classes.MapButtonMC] Frame 0
class Classes.MapButtonMC extends MovieClip
{
var hit_area, _name, onEnterFrame, _visible, reachedStage;
function MapButtonMC () {
super();
}
function enable() {
hit_area.onRelease = function () {
this._parent.selectLocation();
};
if (_name != "alien_ship") {
onEnterFrame = function () {
this.hit_area.filters = [new flash.filters.GlowFilter(16777215, 1, 16, 16, Math.abs(Math.sin(this.sinus)) * 3, 2)];
this.sinus = this.sinus + 0.15;
};
} else {
_visible = true;
}
}
function disable() {
if (_name != "alien_ship") {
hit_area.filters = [new flash.filters.ColorMatrixFilter([0.3, 0.59, 0.11, 0, 0, 0.3, 0.59, 0.11, 0, 0, 0.3, 0.59, 0.11, 0, 0, 0, 0, 0, 1, 0])];
} else {
_visible = false;
}
}
function selectLocation() {
var _local3 = _root.mainController;
_local3.locationSelected(reachedStage);
}
var sinus = 0;
}
Symbol 1346 MovieClip [__Packages.Classes.GameController] Frame 0
class Classes.GameController
{
var sndController, gameSettings, curLevelScore, goalReached, salesGoal, gamePaused, timeOut, customers, totalCustomers, pickupMoneyWarningFlag, timer, newItemWarningFlag, gameLevel, gameFieldMC, customerAppearCounter, customerAppearTime, interfaceMC, careerMode, totalSatisfaction, maxCustomersAtOnce, totalScore, showThiefWarningFlag, levelData, briefTipType;
function GameController () {
sndController = _root.sndController;
gameSettings = _root.gameSettings;
}
function get tipText() {
var _local2 = ["Customers will give you less money if you serve them undercooked or overcooked hot dogs", "Give customers part of their order to satisfy them and to stop them from leaving so quickly", "You will get less money from customers if you serve them the wrong items", "Customers will give you more money if you serve them quicker", "Leaving money on the counter will prevent new customers from coming to the stand", "Try serving angry customers first"];
var _local3 = "Tip: " + _local2[nextTipIndex];
nextTipIndex++;
if (nextTipIndex == _local2.length) {
nextTipIndex = 0;
}
return(_local3);
}
function addCash(dCash) {
curLevelScore = curLevelScore + dCash;
if (curLevelScore < 0) {
curLevelScore = 0;
}
if ((!goalReached) && (curLevelScore >= salesGoal)) {
goalReached = true;
}
}
function update() {
if (gamePaused) {
return(undefined);
}
if (timeOut) {
var _local4 = 0;
var _local3 = 0;
while (_local3 < 5) {
if (customers[_local3] == 0) {
_local4++;
}
_local3++;
}
if (_local4 == 5) {
levelFinished();
} else if ((totalCustomers == 0) && (pickupMoneyWarningFlag)) {
pickupMoneyWarningFlag = false;
_root.attachMovie("popup_caption", "pickupmoney_warn_mc", _root.getNextHighestDepth(), {caption:"Pick up all the money!"});
}
} else {
timer.update();
var _local5 = timer.__get__getPercentage();
if (_local5 <= 0) {
if (_root.brief_tip_clip.removeMovieClip()) {
_root.brief_tip_clip.removeMovieClip();
}
timeOut = true;
_local5 = 0;
}
if (newItemWarningFlag) {
newItemWarningFlag = false;
_root.attachMovie("popup_caption_new_item", "new_item_warn_mc", _root.getNextHighestDepth(), {level:gameLevel, caption:"A new item has been added to your hot dog stand"});
}
}
gameFieldMC.update();
customerAppearCounter++;
if (customerAppearCounter > customerAppearTime) {
customerAppearCounter = 0;
attachNewCustomer();
}
var _local7 = (360 * _local5) + 180;
var _local6 = (360 * (_local5 * 12)) - 90;
interfaceMC.clock.hour_hand._rotation = _local7;
interfaceMC.clock.minute_hand._rotation = _local6;
interfaceMC.goalStr = (careerMode ? ("Goal: $" + salesGoal) : "");
interfaceMC.moneyStr = "$" + curLevelScore;
interfaceMC.satisfaction_meter.face._x = totalSatisfaction * 60;
interfaceMC.satisfaction_meter.face.gotoAndStop(1 + Math.floor(totalSatisfaction * 7));
}
function customerServed(goodState) {
var _local2 = maxCustomersAtOnce + (goodState ? 1 : -1);
if (_local2 > 5) {
_local2 = 5;
} else if (_local2 < 1) {
_local2 = 1;
}
maxCustomersAtOnce = _local2;
}
function setOverallSatisfaction(dSat) {
totalSatisfaction = totalSatisfaction + (dSat * 0.2);
totalSatisfaction = ((totalSatisfaction > 1) ? 1 : (totalSatisfaction));
totalSatisfaction = ((totalSatisfaction < 0) ? 0 : (totalSatisfaction));
}
function levelFinished() {
delete _root.onEnterFrame;
interfaceMC.clock.hour_hand._rotation = 180;
interfaceMC.clock.minute_hand._rotation = -90;
if (curLevelScore >= salesGoal) {
totalScore = totalScore + curLevelScore;
}
_root.attachMovie("popup_window", "popup_window", _root.getNextHighestDepth(), {frameLabel:"closing", captionType:"level_end", salesGoal:salesGoal, curLevelScore:curLevelScore, totalScore:totalScore});
}
function freeCustomerPosition(customerPosition) {
customers[customerPosition] = customers[customerPosition] - 1;
}
function attachNewCustomer() {
var _local3 = [];
var _local2 = 0;
while (_local2 < 5) {
if (customers[_local2] == 0) {
_local3.push(_local2);
}
_local2++;
}
if (((_local3.length > 0) && (totalCustomers < maxCustomersAtOnce)) && (!timeOut)) {
var _local4 = _local3[Math.floor(Math.random() * _local3.length)];
totalCustomers++;
customers[_local4] = customers[_local4] + 1;
gameFieldMC.attachNewCustomer(_local4, gameLevel);
}
}
function attachCash(positionIndex, cashAmount, xPos) {
customers[positionIndex] = customers[positionIndex] + 1;
gameFieldMC.attachCash(positionIndex, cashAmount, xPos);
}
function showThiefWarning() {
if (showThiefWarningFlag) {
showThiefWarningFlag = false;
_root.attachMovie("popup_caption", "thief_warn_mc", _root.getNextHighestDepth(), {caption:"Quick! Click on thieves who don't pay"});
}
}
function startGame($careerMode) {
Classes.Map.showAllReachedStages = true;
careerMode = $careerMode;
totalScore = 0;
gameLevel = 1;
gameLevel = Number(_root.startFromLevel);
showThiefWarningFlag = true;
pickupMoneyWarningFlag = true;
levelData = gameSettings.getSettingObject("levelData", gameLevel);
if (careerMode) {
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"game_map"});
} else {
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"start_level"});
}
}
function resetScore() {
totalScore = 0;
}
function locationSelected($reachedStage) {
if ($reachedStage > gameSettings.__get__reachedStage()) {
gameSettings.__set__reachedStage($reachedStage);
}
gameLevel = (($reachedStage - 1) * 5) + 1;
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"start_level"});
}
function get mapLocation() {
levelData = gameSettings.getSettingObject("levelData", gameLevel);
return(levelData.location);
}
function buildLevel() {
curLevelScore = 0;
customers = [0, 0, 0, 0, 0];
customerAppearCounter = 0;
totalSatisfaction = 0.5;
levelData = gameSettings.getSettingObject("levelData", gameLevel);
maxCustomersAtOnce = gameSettings.getSettingNumber("maxCustomersAtOnce");
customerAppearTime = levelData.customerAppearTime;
salesGoal = levelData.levelSalesGoal;
gameFieldMC = _root.gameFieldMC;
interfaceMC = _root.interfaceMC;
interfaceMC.goalStr = (careerMode ? ("Goal: $" + salesGoal) : "");
interfaceMC.moneyStr = "$" + curLevelScore;
interfaceMC.satisfaction_meter.face._x = 30;
interfaceMC.satisfaction_meter.face.gotoAndStop(4);
interfaceMC.clock.hour_hand._rotation = 180;
interfaceMC.clock.minute_hand._rotation = -90;
gameFieldMC.startLevel(gameLevel, levelData.locationCharacters, levelData.customerWaitingTime, levelData.location, levelData.customersCheat, levelData.servingTimeSpan);
var _local4 = gameSettings.getDayName((gameLevel - 1) % 5);
_root.attachMovie("popup_window", "popup_window", _root.getNextHighestDepth(), {frameLabel:"opening", captionType:"level_start", dayName:(careerMode ? (_local4) : "Speed mode"), goalStr:(careerMode ? ("You need to make $" + salesGoal) : "Earn as much as you can!")});
}
function startLevel() {
newItemWarningFlag = false;
briefTipType = -1;
if (careerMode) {
switch (gameLevel) {
case 2 :
case 3 :
case 4 :
case 7 :
case 9 :
case 12 :
newItemWarningFlag = true;
}
if ((gameLevel == 1) && (gameSettings.showBriefTips)) {
gameSettings.showBriefTips = false;
briefTipType = 0;
_root.attachMovie("brief_tip_clip", "brief_tip_clip", _root.getNextHighestDepth(), {type:0});
}
}
goalReached = false;
timeOut = false;
totalCustomers = 0;
timer = new Classes.TimerController();
if (careerMode) {
timer.setTimer(gameSettings.getSettingNumber("dayTimeSpan"));
} else {
timer.setTimer(gameSettings.getSettingNumber("speedModeTimeSpan"));
}
_root.onEnterFrame = function () {
_root.mainController.update();
};
gamePaused = false;
}
function pauseGame(setPause) {
if (gamePaused != setPause) {
gamePaused = setPause;
if (gamePaused) {
_root.attachMovie("pauseMenuMC", "pauseMenuMC", _root.getNextHighestDepth());
} else {
timer.pauseOff();
}
}
}
function quitGame() {
delete _root.onEnterFrame;
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"main_menu"});
}
function switchSound() {
soundEnabled = !soundEnabled;
if (soundEnabled) {
sndController.setSoundVolume(100);
} else {
sndController.setSoundVolume(0);
}
}
function getSoundString() {
if (soundEnabled) {
return("Switch Sound OFF");
}
return("Switch Sound ON");
}
function switchQuality() {
switch (_quality) {
case "HIGH" :
_quality = "MEDIUM";
return;
case "MEDIUM" :
_quality = "HIGH";
return;
case "LOW" :
_quality = "HIGH";
}
}
function getQualityString() {
switch (_quality) {
case "HIGH" :
return("Set Graphics Quality To MEDIUM");
case "MEDIUM" :
return("Set Graphics Quality To HIGH");
case "LOW" :
return("Set Graphics Quality To HIGH");
}
}
var soundEnabled = true;
var nextTipIndex = 0;
}
Symbol 1347 MovieClip [__Packages.Classes.SoundController] Frame 0
class Classes.SoundController
{
var musicTrackSound, musicTrackPlaying;
function SoundController () {
musicTrackSound = new Sound(_root);
}
function setSoundVolume(volume) {
musicTrackSound.setVolume(volume);
}
function playSFX(sfxLink, loopCount) {
if (!loopCount) {
loopCount = 1;
}
var _local2 = new Sound(_root);
_local2.attachSound(sfxLink);
_local2.start(0, loopCount);
}
function playRandomSFX(sfxLinkPrefix, rndSoundsCount, loopCount) {
if (!loopCount) {
loopCount = 1;
}
var _local2 = new Sound(_root);
var _local3 = Math.floor(Math.random() * rndSoundsCount);
_local2.attachSound((sfxLinkPrefix + "_") + _local3);
_local2.start(0, loopCount);
}
function stopMusic() {
musicTrackSound.stop();
musicTrackPlaying = null;
}
function playMusicTrack(trackLink) {
if (musicTrackPlaying != trackLink) {
musicTrackSound.stop();
musicTrackSound.attachSound(trackLink);
musicTrackSound.start(0, 999999);
musicTrackPlaying = trackLink;
}
}
}
Symbol 1348 MovieClip [__Packages.Classes.SettingsController] Frame 0
class Classes.SettingsController
{
var settings, shared, showBriefTips;
function SettingsController () {
settings = new Object();
settings.customerMaxSpeed = 5;
settings.maxCustomersAtOnce = 2;
settings.escapeSpeed = 8;
settings.dayTimeSpan = 120;
settings.speedModeTimeSpan = 300;
settings.onionCookingTime = 320;
settings.burgerCookingTime = 500;
settings.sausageCookingTime = 470;
settings.friesCookingTime = 210;
settings.daysNames = ["Monday", "Tuesday", "Wednesday", "Thursday", "Friday"];
settings.burgerPrice = 20;
settings.hotdogPrice = 15;
settings.ketchupPrice = 2;
settings.mustardPrice = 3;
settings.onionsPrice = 4;
settings.friesPrice = 10;
settings.colaPrice = 7;
settings.lemonadePrice = 7;
settings.burgerPenalty = 13;
settings.hotdogPenalty = 7;
settings.onionPenalty = 1;
settings.customerStatePenalty = 3;
settings.ingredientPenalty = 0.05;
settings.ingredientBonus = 0.05;
settings.satisfactionStatePenalty = 0.05;
settings.perfectOrderBonus = 0.15;
settings.throwAwayPenaltyBurgerBun = 1;
settings.throwAwayPenaltyHotdogBun = 1;
settings.throwAwayPenaltySausage = 2;
settings.throwAwayPenaltyBurger = 2;
settings.throwAwayPenaltyOnion = 1;
settings.throwAwayPenaltyFries = 1;
shared = SharedObject.getLocal("2DPlay_HotDogBush_SO", "/");
if (!shared.data.playedBefore) {
shared.data.playedBefore = true;
shared.data.reachedStage = 1;
showBriefTips = true;
} else {
showBriefTips = false;
}
settings.customerPersonalData = {oldwoman:{waitingTimeMultipl:1.1, cheatPercentage:0.1, tipAmount:0}, oldman:{waitingTimeMultipl:1.1, cheatPercentage:0.05, tipAmount:0.1}, hiphop_man:{waitingTimeMultipl:1.1, cheatPercentage:0.1, tipAmount:0.1}, worker:{waitingTimeMultipl:1.1, cheatPercentage:0.05, tipAmount:0.2}, generic_woman:{waitingTimeMultipl:1.1, cheatPercentage:0, tipAmount:0.2}, generic_man:{waitingTimeMultipl:1.1, cheatPercentage:0.05, tipAmount:0.1}, business_man:{waitingTimeMultipl:1.1, cheatPercentage:0.15, tipAmount:0.3}, business_woman:{waitingTimeMultipl:1.1, cheatPercentage:0.1, tipAmount:0.1}, boy:{waitingTimeMultipl:1.1, cheatPercentage:0.15, tipAmount:0}, girl:{waitingTimeMultipl:1.1, cheatPercentage:0.05, tipAmount:0.1}, tourist:{waitingTimeMultipl:1.1, cheatPercentage:0.1, tipAmount:0.2}, tourist_girl:{waitingTimeMultipl:1.1, cheatPercentage:0, tipAmount:0.1}, mafia_man:{waitingTimeMultipl:1.1, cheatPercentage:0.15, tipAmount:0}, driver:{waitingTimeMultipl:1.1, cheatPercentage:0.05, tipAmount:0.1}, policeman:{waitingTimeMultipl:1.1, cheatPercentage:0.05, tipAmount:0.1}, bum:{waitingTimeMultipl:1.1, cheatPercentage:0.1, tipAmount:0}, alien:{waitingTimeMultipl:1.1, cheatPercentage:0.15, tipAmount:0}, sportsman:{waitingTimeMultipl:1.1, cheatPercentage:0.1, tipAmount:0.1}, sportswoman:{waitingTimeMultipl:1.1, cheatPercentage:0.05, tipAmount:0.2}, mascot:{waitingTimeMultipl:1.1, cheatPercentage:0.05, tipAmount:0.1}};
settings.levelOrderItems = [{fries:0, onion:false, drink:"none", sauce:"ketchup", snack:"hot_dog"}, {fries:0, onion:false, drink:"lemonade", sauce:"ketchup", snack:"hot_dog"}, {fries:1, onion:false, drink:"lemonade", sauce:"ketchup", snack:"hot_dog"}, {fries:1, onion:false, drink:"lemonade", sauce:"ketchup", snack:"both"}, {fries:1, onion:false, drink:"lemonade", sauce:"ketchup", snack:"both"}, {fries:1, onion:false, drink:"lemonade", sauce:"ketchup", snack:"both"}, {fries:1, onion:true, drink:"lemonade", sauce:"ketchup", snack:"both"}, {fries:1, onion:true, drink:"lemonade", sauce:"ketchup", snack:"both"}, {fries:1, onion:true, drink:"both", sauce:"ketchup", snack:"both"}, {fries:1, onion:true, drink:"both", sauce:"ketchup", snack:"both"}, {fries:1, onion:true, drink:"both", sauce:"ketchup", snack:"both"}, {fries:1, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:1, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:2, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:2, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:2, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:2, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:2, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:2, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:2, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:2, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:2, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:3, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:3, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:3, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:3, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:3, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:3, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:3, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:3, onion:true, drink:"both", sauce:"both", snack:"both"}, {fries:3, onion:true, drink:"both", sauce:"both", snack:"both"}];
settings.levelData = [{levelSalesGoal:150, customerAppearTime:100, customerWaitingTime:900, servingTimeSpan:1000, customersCheat:false, location:"bronx", locationCharacters:["oldwoman", "hiphop_man", "generic_woman", "generic_man", "bum"]}, {levelSalesGoal:175, customerAppearTime:95, customerWaitingTime:880, servingTimeSpan:1000, customersCheat:false, location:"bronx", locationCharacters:["oldwoman", "oldman", "worker", "mafia_man", "policeman"]}, {levelSalesGoal:200, customerAppearTime:90, customerWaitingTime:870, servingTimeSpan:1000, customersCheat:true, location:"bronx", locationCharacters:["hiphop_man", "generic_woman", "generic_man", "driver", "bum"]}, {levelSalesGoal:225, customerAppearTime:90, customerWaitingTime:860, servingTimeSpan:1000, customersCheat:false, location:"bronx", locationCharacters:["oldman", "generic_woman", "boy", "mafia_man", "policeman"]}, {levelSalesGoal:250, customerAppearTime:90, customerWaitingTime:850, servingTimeSpan:1000, customersCheat:true, location:"bronx", locationCharacters:["oldwoman", "hiphop_man", "worker", "generic_woman", "mafia_man"]}, {levelSalesGoal:290, customerAppearTime:89, customerWaitingTime:847, servingTimeSpan:1000, customersCheat:false, location:"yankees_stadium", locationCharacters:["oldman", "generic_woman", "boy", "tourist", "mascot"]}, {levelSalesGoal:300, customerAppearTime:88, customerWaitingTime:847, servingTimeSpan:1000, customersCheat:false, location:"yankees_stadium", locationCharacters:["hiphop_man", "generic_man", "tourist_girl", "policeman", "sportsman"]}, {levelSalesGoal:310, customerAppearTime:87, customerWaitingTime:847, servingTimeSpan:1000, customersCheat:true, location:"yankees_stadium", locationCharacters:["oldman", "worker", "generic_woman", "girl", "sportswoman"]}, {levelSalesGoal:320, customerAppearTime:86, customerWaitingTime:845, servingTimeSpan:1000, customersCheat:false, location:"yankees_stadium", locationCharacters:["oldwoman", "generic_man", "boy", "tourist_girl", "mascot"]}, {levelSalesGoal:330, customerAppearTime:86, customerWaitingTime:843, servingTimeSpan:1000, customersCheat:true, location:"yankees_stadium", locationCharacters:["hiphop_man", "worker", "generic_man", "boy", "girl"]}, {levelSalesGoal:350, customerAppearTime:85, customerWaitingTime:843, servingTimeSpan:1000, customersCheat:false, location:"central_park", locationCharacters:["oldman", "tourist", "tourist_girl", "sportsman", "sportswoman"]}, {levelSalesGoal:360, customerAppearTime:85, customerWaitingTime:840, servingTimeSpan:1000, customersCheat:true, location:"central_park", locationCharacters:["oldwoman", "generic_woman", "boy", "girl", "policeman"]}, {levelSalesGoal:370, customerAppearTime:83, customerWaitingTime:837, servingTimeSpan:1000, customersCheat:false, location:"central_park", locationCharacters:["hiphop_man", "tourist", "tourist_girl", "bum", "sportswoman"]}, {levelSalesGoal:380, customerAppearTime:83, customerWaitingTime:837, servingTimeSpan:1000, customersCheat:true, location:"central_park", locationCharacters:["oldwoman", "oldman", "boy", "girl", "sportsman"]}, {levelSalesGoal:390, customerAppearTime:82, customerWaitingTime:835, servingTimeSpan:1000, customersCheat:true, location:"central_park", locationCharacters:["oldman", "generic_woman", "girl", "tourist", "sportswoman"]}, {levelSalesGoal:410, customerAppearTime:80, customerWaitingTime:835, servingTimeSpan:1000, customersCheat:true, location:"times_square", locationCharacters:["generic_man", "tourist", "tourist_girl", "driver", "bum"]}, {levelSalesGoal:415, customerAppearTime:80, customerWaitingTime:833, servingTimeSpan:1000, customersCheat:true, location:"times_square", locationCharacters:["worker", "generic_woman", "business_woman", "girl", "tourist"]}, {levelSalesGoal:420, customerAppearTime:80, customerWaitingTime:830, servingTimeSpan:1000, customersCheat:false, location:"times_square", locationCharacters:["oldwoman", "hiphop_man", "business_man", "tourist_girl", "policeman"]}, {levelSalesGoal:425, customerAppearTime:75, customerWaitingTime:830, servingTimeSpan:1000, customersCheat:true, location:"times_square", locationCharacters:["generic_woman", "boy", "girl", "tourist", "policeman"]}, {levelSalesGoal:430, customerAppearTime:75, customerWaitingTime:830, servingTimeSpan:1000, customersCheat:true, location:"times_square", locationCharacters:["oldman", "generic_woman", "generic_man", "business_woman", "tourist_girl"]}, {levelSalesGoal:435, customerAppearTime:74, customerWaitingTime:830, servingTimeSpan:1000, customersCheat:true, location:"wall_street", locationCharacters:["worker", "generic_man", "business_man", "business_woman", "policeman"]}, {levelSalesGoal:440, customerAppearTime:73, customerWaitingTime:829, servingTimeSpan:1000, customersCheat:true, location:"wall_street", locationCharacters:["oldman", "generic_woman", "business_woman", "mafia_man", "driver"]}, {levelSalesGoal:445, customerAppearTime:73, customerWaitingTime:829, servingTimeSpan:1000, customersCheat:true, location:"wall_street", locationCharacters:["oldman", "worker", "generic_woman", "business_man", "bum"]}, {levelSalesGoal:450, customerAppearTime:73, customerWaitingTime:828, servingTimeSpan:1000, customersCheat:true, location:"wall_street", locationCharacters:["worker", "business_man", "business_woman", "tourist", "policeman"]}, {levelSalesGoal:455, customerAppearTime:72, customerWaitingTime:827, servingTimeSpan:1000, customersCheat:true, location:"wall_street", locationCharacters:["oldman", "generic_woman", "generic_man", "business_man", "driver"]}, {levelSalesGoal:460, customerAppearTime:70, customerWaitingTime:820, servingTimeSpan:1000, customersCheat:true, location:"alien_ship", locationCharacters:["generic_woman", "boy", "tourist", "alien", "mascot"]}, {levelSalesGoal:475, customerAppearTime:60, customerWaitingTime:800, servingTimeSpan:1000, customersCheat:true, location:"alien_ship", locationCharacters:["generic_woman", "boy", "alien", "mascot"]}, {levelSalesGoal:490, customerAppearTime:50, customerWaitingTime:750, servingTimeSpan:1000, customersCheat:true, location:"alien_ship", locationCharacters:["generic_woman", "alien", "mascot"]}, {levelSalesGoal:505, customerAppearTime:50, customerWaitingTime:700, servingTimeSpan:1000, customersCheat:true, location:"alien_ship", locationCharacters:["alien", "mascot"]}, {levelSalesGoal:520, customerAppearTime:40, customerWaitingTime:700, servingTimeSpan:1000, customersCheat:true, location:"alien_ship", locationCharacters:["alien"]}, {customerAppearTime:30, customerWaitingTime:750, servingTimeSpan:1000, customersCheat:true, locationCharacters:["oldwoman", "oldman", "hiphop_man", "worker", "generic_woman", "generic_man", "business_man", "business_woman", "boy", "girl", "tourist", "tourist_girl", "mafia_man", "driver", "policeman", "bum", "sportsman", "sportswoman", "mascot"]}];
}
function get reachedStage() {
return(shared.data.reachedStage);
}
function set reachedStage($stage) {
shared.data.reachedStage = $stage;
shared.flush();
//return(reachedStage);
}
function getSettingNumber(settingLink, gameLevel) {
if (!_root.mainController.careerMode) {
gameLevel = 31;
}
gameLevel = ((gameLevel == undefined) ? 1 : (gameLevel));
if (typeof(settings[settingLink]) == "number") {
return(settings[settingLink]);
}
var _local3 = settings[settingLink][gameLevel - 1];
if (_local3 == undefined) {
_local3 = settings[settingLink][settings[settingLink].length - 1];
}
return(_local3);
}
function getDayName(dayIndex) {
return(settings.daysNames[dayIndex]);
}
function getSettingObject(settingLink, gameLevel) {
if (!_root.mainController.careerMode) {
gameLevel = 31;
}
var _local3 = settings[settingLink][gameLevel - 1];
if (_local3 == undefined) {
_local3 = settings[settingLink][settings[settingLink].length - 1];
}
return(_local3);
}
function getCustomerData(customerLink) {
var _local2 = settings.customerPersonalData[customerLink];
return(_local2);
}
function setTestSettings() {
settings.dayTimeSpan = _root.dayTimeSpan;
settings.onionCookingTime = _root.onionCookingTime;
settings.burgerCookingTime = _root.burgerCookingTime;
settings.sausageCookingTime = _root.sausageCookingTime;
settings.friesCookingTime = _root.friesCookingTime;
settings.burgerPrice = _root.burgerPrice;
settings.hotdogPrice = _root.hotdogPrice;
settings.ketchupPrice = _root.ketchupPrice;
settings.mustardPrice = _root.mustardPrice;
settings.onionsPrice = _root.onionsPrice;
settings.friesPrice = _root.friesPrice;
settings.colaPrice = _root.colaPrice;
settings.lemonadePrice = _root.lemonadePrice;
settings.burgerPenalty = _root.burgerPenalty;
settings.hotdogPenalty = _root.hotdogPenalty;
settings.onionPenalty = _root.onionPenalty;
settings.customerStatePenalty = _root.customerStatePenalty;
settings.ingredientPenalty = _root.ingredientPenalty;
settings.ingredientBonus = _root.ingredientBonus;
settings.satisfactionStatePenalty = _root.satisfactionStatePenalty;
settings.perfectOrderBonus = _root.perfectOrderBonus;
settings.levelData = [];
settings.levelData.push({levelSalesGoal:_root.levelSalesGoal, customerAppearTime:_root.customerAppearTime, servingTimeSpan:_root.servingTimeSpan, customerWaitingTime:_root.customerWaitingTime, customersCheat:true, location:"bronx", locationCharacters:["oldwoman"]});
settings.levelOrderItems = [];
settings.levelOrderItems.push({snack:_root.snack, drink:_root.drink, onion:_root.onion, sauce:_root.sauce, fries:_root.fries});
settings.throwAwayPenaltyBurgerBun = _root.throwAwayPenaltyBurgerBun;
settings.throwAwayPenaltyHotdogBun = _root.throwAwayPenaltyHotdogBun;
settings.throwAwayPenaltySausage = _root.throwAwayPenaltySausage;
settings.throwAwayPenaltyBurger = _root.throwAwayPenaltyBurger;
settings.throwAwayPenaltyOnion = _root.throwAwayPenaltyOnion;
settings.throwAwayPenaltyFries = _root.throwAwayPenaltyFries;
}
function getSettingArray(settingLink, gameLevel) {
if (!_root.mainController.careerMode) {
gameLevel = 31;
}
var _local3 = settings[settingLink][gameLevel - 1];
if (_local3 == undefined) {
_local3 = settings[settingLink][settings[settingLink].length - 1];
}
return(_local3);
}
}
Symbol 1349 MovieClip [__Packages.Classes.TimerController] Frame 0
class Classes.TimerController
{
var timeDisp, timeOffset, timeInit;
function TimerController () {
}
function update() {
timeDisp = getTimer() - timeOffset;
}
function setTimer(timeInitSeconds) {
timeInit = timeInitSeconds * 1000;
timeOffset = getTimer();
}
function get getPercentage() {
var _local2 = timeInit - (getTimer() - timeOffset);
if (_local2 < 0) {
return(-1);
}
return(1 - (_local2 / timeInit));
}
function getTimerString() {
var _local4 = Math.floor((timeInit - (getTimer() - timeOffset)) / 1000);
var _local3 = String(_local4 % 60);
_local3 = ((_local3.length == 1) ? ("0" + _local3) : (_local3));
var _local2 = String(Math.floor(_local4 / 60));
_local2 = ((_local2.length == 1) ? ("0" + _local2) : (_local2));
return((_local2 + ":") + _local3);
}
function pauseOff() {
timeOffset = getTimer() - timeDisp;
}
}
Symbol 1350 MovieClip [__Packages.Classes.GameField] Frame 0
class Classes.GameField extends MovieClip
{
var gameSettings, sndController, gameLevel, burgerItemIcon, burgerBunItemIcon, burger_bun_btn, burger_btn, hotdogItemIcon, hotdogBunItemIcon, hotdog_bun_btn, hotdog_btn, potatosItemIcon, potatos_btn, onionItemIcon, onion_btn, lemonadeItemIcon, lemonade_btn, colaItemIcon, cola_btn, mustardIcon, mustard_btn, ketchupIcon, ketchup_btn, selectedItemMC, selectedIcon, customerDepth, leavingCustomerDepth, backgroundMC, locationCharacters, customerWaitingTime, customersCheat, servingTimeSpan, friesPlaced, onionsCooking, sausagesCooking, burgersCooking, hotdogBunsCooking, burgerBunsCooking, friesCooking, trashCanMC, customersMC, objectsMC;
function GameField () {
super();
gameSettings = _root.gameSettings;
sndController = _root.sndController;
}
function startLevel(_gameLevel, _locationCharacters, _customerWaitingTime, location, _customersCheat, _servingTimeSpan) {
gameLevel = _gameLevel;
var _local4 = gameSettings.getSettingObject("levelOrderItems", gameLevel);
switch (_local4.snack) {
case Classes.ItemType.HOT_DOG :
burgerItemIcon._visible = false;
burgerBunItemIcon._visible = false;
burger_bun_btn.enabled = false;
burger_btn.enabled = false;
hotdogItemIcon._visible = true;
hotdogBunItemIcon._visible = true;
hotdog_bun_btn.enabled = true;
hotdog_btn.enabled = true;
break;
case Classes.ItemType.BURGER :
hotdogItemIcon._visible = false;
hotdogBunItemIcon._visible = false;
hotdog_bun_btn.enabled = false;
hotdog_btn.enabled = false;
burgerItemIcon._visible = true;
burgerBunItemIcon._visible = true;
burger_bun_btn.enabled = true;
burger_btn.enabled = true;
break;
case Classes.ItemType.BOTH :
hotdogItemIcon._visible = true;
hotdogBunItemIcon._visible = true;
hotdog_bun_btn.enabled = true;
hotdog_btn.enabled = true;
burgerItemIcon._visible = true;
burgerBunItemIcon._visible = true;
burger_bun_btn.enabled = true;
burger_btn.enabled = true;
}
if (_local4.fries == 0) {
potatosItemIcon._visible = false;
potatos_btn.enabled = false;
} else {
potatosItemIcon._visible = true;
potatos_btn.enabled = true;
}
if (_local4.onion == 0) {
onionItemIcon._visible = false;
onion_btn.enabled = false;
} else {
onionItemIcon._visible = true;
onion_btn.enabled = true;
}
switch (_local4.drink) {
case Classes.ItemType.COLA :
lemonadeItemIcon._visible = false;
lemonade_btn.enabled = false;
colaItemIcon._visible = true;
cola_btn.enabled = true;
break;
case Classes.ItemType.LEMONADE :
colaItemIcon._visible = false;
cola_btn.enabled = false;
lemonadeItemIcon._visible = true;
lemonade_btn.enabled = true;
break;
case Classes.ItemType.NONE :
colaItemIcon._visible = false;
lemonadeItemIcon._visible = false;
cola_btn.enabled = false;
lemonade_btn.enabled = false;
break;
case Classes.ItemType.BOTH :
colaItemIcon._visible = true;
lemonadeItemIcon._visible = true;
cola_btn.enabled = true;
lemonade_btn.enabled = true;
}
switch (_local4.sauce) {
case Classes.ItemType.KETCHUP :
mustardIcon._visible = false;
mustard_btn.enabled = false;
ketchupIcon._visible = true;
ketchup_btn.enabled = true;
break;
case Classes.ItemType.MUSTARD :
ketchupIcon._visible = false;
ketchup_btn.enabled = false;
mustardIcon._visible = true;
mustard_btn.enabled = true;
break;
case Classes.ItemType.NONE :
ketchupIcon._visible = false;
mustardIcon._visible = false;
ketchup_btn.enabled = false;
mustard_btn.enabled = false;
break;
case Classes.ItemType.BOTH :
ketchupIcon._visible = true;
mustardIcon._visible = true;
ketchup_btn.enabled = true;
mustard_btn.enabled = true;
}
selectedItemMC = (selectedIcon = undefined);
customerDepth = 6000;
leavingCustomerDepth = 3000;
if (!_root.mainController.careerMode) {
switch (gameSettings.__get__reachedStage()) {
case 1 :
location = "bronx";
break;
case 2 :
location = "yankees_stadium";
break;
case 3 :
location = "central_park";
break;
case 4 :
location = "times_square";
break;
case 5 :
location = "wall_street";
break;
default :
location = "alien_ship";
}
}
backgroundMC.gotoAndStop(location);
switch (location) {
case "bronx" :
sndController.playMusicTrack("bronx_ambi.wav");
break;
case "yankees_stadium" :
sndController.playMusicTrack("yankee_stadium_ambi.wav");
break;
case "central_park" :
sndController.playMusicTrack("central_park_ambi.wav");
break;
case "times_square" :
sndController.playMusicTrack("times_square_ambi.wav");
break;
case "wall_street" :
sndController.playMusicTrack("wall_street_ambi.wav");
break;
case "alien_ship" :
sndController.playMusicTrack("ufo_ambi.wav");
}
locationCharacters = _locationCharacters;
customerWaitingTime = _customerWaitingTime;
customersCheat = _customersCheat;
servingTimeSpan = _servingTimeSpan;
friesPlaced = false;
onionsCooking = [false, false];
sausagesCooking = [false, false, false];
burgersCooking = [false, false, false];
hotdogBunsCooking = [false, false, false];
burgerBunsCooking = [false, false, false];
friesCooking = [false, false, false];
}
function throwAwayItem() {
switch (selectedItemMC.type) {
case Classes.ItemType.HOT_DOG_BUN :
case Classes.ItemType.BURGER_BUN :
case Classes.ItemType.SAUSAGE :
case Classes.ItemType.BURGER :
case Classes.ItemType.ONION :
case Classes.ItemType.FRIES :
Classes.ThrowAwayItemPenalty.givePenalty(selectedItemMC);
clearItemPosition(selectedItemMC.type, selectedItemMC.index);
selectedItemMC.removeMovieClip();
sndController.playSFX("garbage.01.wav");
}
}
function placeItem(item) {
switch (item.type) {
case Classes.ItemType.HOT_DOG_BUN :
case Classes.ItemType.BURGER_BUN :
case Classes.ItemType.SAUSAGE :
case Classes.ItemType.BURGER :
case Classes.ItemType.ONION :
case Classes.ItemType.FRIES :
if (!trashCanMC.hitTest(item._x, item._y, true)) {
break;
}
Classes.ThrowAwayItemPenalty.givePenalty(item);
clearItemPosition(item.type, item.index);
sndController.playSFX("garbage.01.wav");
return(true);
}
switch (item.type) {
case Classes.ItemType.HOT_DOG_BUN :
case Classes.ItemType.BURGER_BUN :
case Classes.ItemType.COLA :
case Classes.ItemType.LEMONADE :
case Classes.ItemType.FRIES :
for (var _local5 in customersMC) {
var _local4 = customersMC[_local5];
if ((_local4.state == Classes.Customer.STATE_WAITING_FOR_ORDER) && (_local4.hitTest(item._x, item._y, true))) {
if (_local4.takeOrder(item)) {
clearItemPosition(item.type, item.index);
return(true);
}
return(false);
}
}
break;
case Classes.ItemType.KETCHUP :
case Classes.ItemType.MUSTARD :
case Classes.ItemType.ONION :
for (var _local6 in objectsMC) {
var _local3 = objectsMC[_local6];
if ((_local3.hitTest(item._x, item._y, true) && ((_local3.type == Classes.ItemType.HOT_DOG_BUN) || (_local3.type == Classes.ItemType.BURGER_BUN))) && (_local3.ingredients[item.type] == 0)) {
_local3.attachIngredient(item.type, item.cookingState + 1);
clearItemPosition(item.type, item.index);
selectedItemMC = _local3;
_local3.selected = true;
return(true);
}
}
break;
case Classes.ItemType.SAUSAGE :
for (var _local6 in objectsMC) {
var _local3 = objectsMC[_local6];
if ((_local3.hitTest(item._x, item._y, true) && (_local3.type == Classes.ItemType.HOT_DOG_BUN)) && (_local3.ingredients[item.type] == 0)) {
_local3.attachIngredient(item.type, item.cookingState + 1);
clearItemPosition(item.type, item.index);
selectedItemMC = _local3;
_local3.selected = true;
return(true);
}
}
break;
case Classes.ItemType.BURGER :
for (var _local6 in objectsMC) {
var _local3 = objectsMC[_local6];
if ((_local3.hitTest(item._x, item._y, true) && (_local3.type == Classes.ItemType.BURGER_BUN)) && (_local3.ingredients[item.type] == 0)) {
_local3.attachIngredient(item.type, item.cookingState + 1);
clearItemPosition(item.type, item.index);
selectedItemMC = _local3;
_local3.selected = true;
return(true);
}
}
}
}
function orderTaken() {
clearItemPosition(selectedItemMC.type, selectedItemMC.index);
selectedItemMC.removeMovieClip();
}
function selectItem(item) {
switch (item.type) {
case Classes.ItemType.HOT_DOG_BUN :
case Classes.ItemType.BURGER_BUN :
switch (selectedItemMC.type) {
case Classes.ItemType.ONION :
if (item.ingredients[Classes.ItemType.ONION] == 0) {
item.attachIngredient(selectedItemMC.type, selectedItemMC.cookingState + 1);
clearItemPosition(selectedItemMC.type, selectedItemMC.index);
selectedItemMC.removeMovieClip();
item.select();
selectedItemMC = item;
return(true);
}
break;
case Classes.ItemType.BURGER :
if ((item.type == Classes.ItemType.BURGER_BUN) && (item.ingredients[Classes.ItemType.BURGER] == 0)) {
item.attachIngredient(selectedItemMC.type, selectedItemMC.cookingState + 1);
clearItemPosition(selectedItemMC.type, selectedItemMC.index);
selectedItemMC.removeMovieClip();
item.select();
selectedItemMC = item;
return(true);
}
break;
case Classes.ItemType.SAUSAGE :
if (!((item.type == Classes.ItemType.HOT_DOG_BUN) && (item.ingredients[Classes.ItemType.SAUSAGE] == 0))) {
break;
}
item.attachIngredient(selectedItemMC.type, selectedItemMC.cookingState + 1);
clearItemPosition(selectedItemMC.type, selectedItemMC.index);
selectedItemMC.removeMovieClip();
item.select();
selectedItemMC = item;
return(true);
}
}
selectedItemMC.unselect();
selectedItemMC = item;
return(false);
}
function draggableItemReleased(item) {
switch (item.type) {
case Classes.ItemType.COLA :
case Classes.ItemType.LEMONADE :
case Classes.ItemType.KETCHUP :
case Classes.ItemType.MUSTARD :
placeItem(item);
}
item.removeMovieClip();
}
function clearItemPosition(itemType, itemIndex) {
var _local2;
switch (itemType) {
case Classes.ItemType.SAUSAGE :
_local2 = sausagesCooking;
break;
case Classes.ItemType.BURGER :
_local2 = burgersCooking;
break;
case Classes.ItemType.HOT_DOG_BUN :
_local2 = hotdogBunsCooking;
break;
case Classes.ItemType.BURGER_BUN :
_local2 = burgerBunsCooking;
break;
case Classes.ItemType.ONION :
_local2 = onionsCooking;
break;
case Classes.ItemType.FRIES :
_local2 = friesCooking;
}
_local2[itemIndex] = false;
}
function selectIcon(item) {
switch (item.type) {
case Classes.ItemType.COLA :
case Classes.ItemType.LEMONADE :
case Classes.ItemType.KETCHUP :
case Classes.ItemType.MUSTARD :
selectedIcon = this["selected_icon_" + item.type];
selectedIcon.select(item.type);
break;
case Classes.ItemType.HOT_DOG_BUN :
case Classes.ItemType.BURGER_BUN :
if ((selectedIcon.type == Classes.ItemType.KETCHUP) || (selectedIcon.type == Classes.ItemType.MUSTARD)) {
item.attachIngredient(selectedIcon.type, 1);
}
selectedIcon._alpha = 0;
selectedIcon = undefined;
break;
default :
selectedIcon._alpha = 0;
selectedIcon = undefined;
}
}
function attachNewItem(itemType) {
switch (itemType) {
case Classes.ItemType.RAW_FRIES :
if (!friesPlaced) {
friesPlaced = true;
var _local6 = gameSettings.getSettingNumber("friesCookingTime", gameLevel);
var _local7 = {cookingStateCounter:_local6, gameFieldMC:this, type:itemType, _x:141, _y:250};
objectsMC.attachMovie("DraggableItemMC", "item_" + friesDepth, friesDepth, _local7);
}
break;
case Classes.ItemType.COLA :
case Classes.ItemType.LEMONADE :
case Classes.ItemType.KETCHUP :
case Classes.ItemType.MUSTARD :
var _local7 = {gameFieldMC:this, type:itemType, _x:_root._xmouse, _y:_root._ymouse};
objectsMC.attachMovie("DraggableItemMC", "item_" + relishDepth, relishDepth, _local7);
break;
default :
var _local4 = getItemsAmount(itemType);
if (!_local4.isFreeSpace) {
break;
}
var _local5 = _local4.depth;
var _local6 = gameSettings.getSettingNumber(itemType + "CookingTime", gameLevel);
_local7 = {cookingStateCounter:_local6, gameFieldMC:this, index:_local4.freeSpaceIndex, type:itemType, _x:_local4.x, _y:_local4.y};
objectsMC.attachMovie("DraggableItemMC", "item_" + _local5, _local5, _local7);
}
switch (itemType) {
case Classes.ItemType.RAW_FRIES :
sndController.playSFX("deep_frying.01.wav");
break;
case Classes.ItemType.FRIES :
sndController.playSFX("fries_in_holder.01.wav");
break;
case Classes.ItemType.COLA :
sndController.playSFX("fizzy_can_open.01.wav");
break;
case Classes.ItemType.LEMONADE :
sndController.playSFX("drink_pour.01.wav");
break;
case Classes.ItemType.ONION :
sndController.playSFX("onion_pan.01.wav");
break;
case Classes.ItemType.BURGER_BUN :
case Classes.ItemType.HOT_DOG_BUN :
sndController.playRandomSFX("bun", 2);
break;
case Classes.ItemType.BURGER :
sndController.playSFX("burgers.01.wav");
break;
case Classes.ItemType.SAUSAGE :
sndController.playSFX("grill_sizzling.01.wav");
}
if ((_root.mainController.briefTipType == 0) && (itemType == Classes.ItemType.HOT_DOG_BUN)) {
_root.mainController.briefTipType++;
_root.brief_tip_clip.gotoAndStop("put_hot_dog");
}
if ((_root.mainController.briefTipType == 1) && (itemType == Classes.ItemType.SAUSAGE)) {
_root.mainController.briefTipType++;
_root.brief_tip_clip.gotoAndStop("hot_dog_cooking");
}
}
function attachReadyFries() {
var _local2 = 0;
while (_local2 < 3) {
attachNewItem(Classes.ItemType.FRIES);
_local2++;
}
friesPlaced = false;
}
function attachCash(positionIndex, cashAmount, xPos) {
sndController.playRandomSFX("coinslap", 3);
var _local2 = positionIndex + 5;
objectsMC.attachMovie("cash_mc", "cash_" + _local2, _local2, {_x:xPos, index:positionIndex, cashAmount:cashAmount});
}
function attachNewCustomer(customerIndex) {
var _local3 = Math.floor(Math.random() * locationCharacters.length);
var _local2 = locationCharacters[_local3];
var _local4 = {type:_local2, index:customerIndex, gameLevel:gameLevel, gameFieldMC:this, waitingTime:customerWaitingTime, cheat:customersCheat, servingTimeCounter:servingTimeSpan};
customersMC.attachMovie("customerMC", "customer_" + customerDepth, customerDepth, _local4);
customerDepth--;
}
function update() {
for (var _local2 in customersMC) {
customersMC[_local2].update();
}
for (var _local3 in objectsMC) {
objectsMC[_local3].update();
}
selectedIcon.update();
}
function getItemsAmount(itemType) {
var _local4;
var _local3;
switch (itemType) {
case Classes.ItemType.SAUSAGE :
_local4 = sausagesCooking;
_local3 = [{x:517, y:258, depth:60}, {x:545, y:263, depth:61}, {x:573, y:268, depth:62}];
break;
case Classes.ItemType.BURGER :
_local4 = burgersCooking;
_local3 = [{x:490, y:225, depth:50}, {x:470, y:260, depth:51}, {x:450, y:295, depth:52}];
break;
case Classes.ItemType.HOT_DOG_BUN :
_local4 = hotdogBunsCooking;
_local3 = [{x:205, y:267, depth:20}, {x:240, y:267, depth:21}, {x:275, y:267, depth:22}];
break;
case Classes.ItemType.BURGER_BUN :
_local4 = burgerBunsCooking;
_local3 = [{x:317, y:295, depth:32}, {x:332, y:260, depth:31}, {x:347, y:225, depth:30}];
break;
case Classes.ItemType.ONION :
_local4 = onionsCooking;
_local3 = [{x:404, y:233, depth:40}, {x:380, y:282, depth:41}];
break;
case Classes.ItemType.FRIES :
_local4 = friesCooking;
_local3 = [{x:85, y:286, depth:10}, {x:112, y:290, depth:11}, {x:139, y:295, depth:12}];
}
var _local9 = false;
var _local6;
var _local8;
var _local7;
var _local5;
var _local2 = 0;
while (_local2 < _local4.length) {
if (!_local4[_local2]) {
_local4[_local2] = true;
_local9 = true;
_local6 = _local2;
_local8 = _local3[_local2].x;
_local7 = _local3[_local2].y;
_local5 = _local3[_local2].depth;
break;
}
_local2++;
}
return({isFreeSpace:_local9, freeSpaceIndex:_local6, x:_local8, y:_local7, depth:_local5});
}
var friesDepth = 1;
var relishDepth = 70;
}
Symbol 1351 MovieClip [__Packages.Classes.ItemType] Frame 0
class Classes.ItemType
{
function ItemType () {
}
static var RAW_FRIES = "raw_fries";
static var FRIES = "fries";
static var KETCHUP = "ketchup";
static var MUSTARD = "mustard";
static var LEMONADE = "lemonade";
static var COLA = "cola";
static var SAUSAGE = "sausage";
static var BURGER = "burger";
static var HOT_DOG = "hot_dog";
static var ONION = "onion";
static var HOT_DOG_BUN = "hot_dog_bun";
static var BURGER_BUN = "burger_bun";
static var BOTH = "both";
static var NONE = "none";
static var SNACK = "snack";
static var DRINK = "drink";
}
Symbol 1352 MovieClip [__Packages.Classes.ThrowAwayItemPenalty] Frame 0
class Classes.ThrowAwayItemPenalty
{
function ThrowAwayItemPenalty () {
}
static function givePenalty(item) {
var _local2;
var _local3 = _root.gameSettings;
switch (item.type) {
case Classes.ItemType.HOT_DOG_BUN :
_local2 = _local3.getSettingNumber("throwAwayPenaltyHotdogBun");
if (item.ingredients.sausage != 0) {
_local2 = _local2 + _local3.getSettingNumber("throwAwayPenaltySausage");
}
if (item.ingredients.onion != 0) {
_local2 = _local2 + _local3.getSettingNumber("throwAwayPenaltyOnion");
}
break;
case Classes.ItemType.BURGER_BUN :
_local2 = _local3.getSettingNumber("throwAwayPenaltyBurgerBun");
if (item.ingredients.burger != 0) {
_local2 = _local2 + _local3.getSettingNumber("throwAwayPenaltyBurger");
}
if (item.ingredients.onion != 0) {
_local2 = _local2 + _local3.getSettingNumber("throwAwayPenaltyOnion");
}
break;
case Classes.ItemType.SAUSAGE :
_local2 = _local3.getSettingNumber("throwAwayPenaltySausage");
break;
case Classes.ItemType.BURGER :
_local2 = _local3.getSettingNumber("throwAwayPenaltyBurger");
break;
case Classes.ItemType.ONION :
_local2 = _local3.getSettingNumber("throwAwayPenaltyOnion");
break;
case Classes.ItemType.FRIES :
_local2 = _local3.getSettingNumber("throwAwayPenaltyFries");
}
var _local5 = item._parent;
_local5.attachMovie("cashAmountMC", "cashAmountMC_" + _local5.getNextHighestDepth(), _local5.getNextHighestDepth(), {cashAmount:"-$" + _local2, _x:item._x, _y:item._y});
var _local6 = _root.mainController;
_local6.addCash(-_local2);
}
}
Symbol 1353 MovieClip [__Packages.Classes.DraggableItem] Frame 0
class Classes.DraggableItem extends MovieClip
{
var ingredients, initDepth, getDepth, cookingCounts, dragged, selected, cookingStateCounter, type, onPress, onRelease, onReleaseOutside, onRollOut, onRollOver, initX, _x, initY, _y, filters, gameFieldMC, removeMovieClip, attachMovie, hot_dog_bun_top, burger_bun_top, swapDepths, startDrag, stopDrag;
function DraggableItem () {
super();
ingredients = {sausage:0, burger:0, onion:0, ketchup:0, mustard:0};
initDepth = getDepth();
cookingCounts = [];
dragged = (selected = false);
var _local3 = 0;
while (_local3 < 5) {
cookingCounts.push(_local3 * Math.floor(cookingStateCounter / 5));
_local3++;
}
cookingCounts.reverse();
cookingCounts.splice(2, 1);
switch (type) {
case Classes.ItemType.RAW_FRIES :
break;
case Classes.ItemType.KETCHUP :
case Classes.ItemType.MUSTARD :
case Classes.ItemType.LEMONADE :
case Classes.ItemType.COLA :
var thisObj = this;
var _local4 = {};
_local4.onMouseUp = function () {
thisObj.gameFieldMC.draggableItemReleased(thisObj);
Mouse.removeListener(this);
};
Mouse.addListener(_local4);
pressed();
break;
default :
if (type == Classes.ItemType.ONION) {
cookingCounts = [280, 240, 40, 0];
}
onPress = function () {
this.pressed();
};
onRelease = (onReleaseOutside = function () {
this.rollOut();
this.released();
});
onRollOut = function () {
this.rollOut();
};
onRollOver = function () {
this.rollOver();
};
}
initX = _x;
initY = _y;
attachIngredient(type, 1);
}
function rollOut() {
var _local2 = new flash.geom.Transform(this);
_local2.colorTransform = new flash.geom.ColorTransform(1, 1, 1, 1, 0, 0, 0, 0);
}
function rollOver() {
var _local2 = new flash.geom.Transform(this);
_local2.colorTransform = new flash.geom.ColorTransform(0.7, 0.7, 0.7, 1, 77, 77, 77, 0);
}
function update() {
switch (type) {
case Classes.ItemType.SAUSAGE :
case Classes.ItemType.BURGER :
case Classes.ItemType.ONION :
if ((cookingStateCounter != 0) && (!dragged)) {
cookingStateCounter--;
if (cookingStateCounter == cookingCounts[cookingState]) {
cookingState++;
if (cookingState == 3) {
filters = [];
if (!soundBurntPlayed) {
soundBurntPlayed = true;
_root.sndController.playSFX("burnt.01.wav");
}
}
this[type].gotoAndStop(cookingState + 1);
}
}
if (cookingState == 2) {
if (!soundReadyPlayed) {
if (type == Classes.ItemType.SAUSAGE) {
if ((_root.mainController.briefTipType == 2) && (_root.brief_tip_clip._currentframe != 75)) {
_root.mainController.briefTipType++;
_root.brief_tip_clip.gotoAndStop("drag_hot_dog");
}
}
soundReadyPlayed = true;
_root.sndController.playSFX("oven_done.01.wav");
}
var _local5 = new flash.geom.Transform(this);
filters = new Array(new flash.filters.GlowFilter(16776960, 1, 8, 8, Math.abs(Math.sin(glowSinus)) * 2, 1, false, false));
_local5.colorTransform = new flash.geom.ColorTransform(0.7, 0.7, 0.7, 1, 77, 77, 77, 0);
glowSinus = glowSinus + 0.25;
}
break;
case Classes.ItemType.RAW_FRIES :
cookingStateCounter--;
if (cookingStateCounter != 0) {
break;
}
gameFieldMC.attachReadyFries();
removeMovieClip();
}
if (selected) {
if ((((type != Classes.ItemType.KETCHUP) && (type != Classes.ItemType.MUSTARD)) && (type != Classes.ItemType.LEMONADE)) && (type != Classes.ItemType.COLA)) {
var _local5 = new flash.geom.Transform(this);
var _local4 = (Math.abs(Math.sin(selectSinus)) * 0.3) + 0.7;
var _local3 = (Math.abs(Math.sin(selectSinus)) * -77) + 77;
_local5.colorTransform = new flash.geom.ColorTransform(_local4, _local4, _local4, 1, _local3, _local3, _local3, 0);
selectSinus = selectSinus + 0.25;
}
}
}
function attachIngredient(ingredientType, ingredientState) {
if (ingredientType == type) {
var _local5 = ingredientDepths[ingredientType];
switch (ingredientType) {
case Classes.ItemType.HOT_DOG_BUN :
var _local7 = ingredientDepths.bun_top;
attachMovie("hot_dog_bun_top", "hot_dog_bun_top", _local7);
break;
case Classes.ItemType.BURGER_BUN :
_local7 = ingredientDepths.bun_top;
attachMovie("burger_bun_top", "burger_bun_top", _local7);
}
var _local6 = attachMovie(type, ingredientType, _local5);
_local6.gotoAndStop(ingredientState);
} else {
ingredients[ingredientType] = ingredientState;
switch (type) {
case Classes.ItemType.HOT_DOG_BUN :
var _local5 = ingredientDepths[ingredientType];
attachMovie("hot_dog_" + ingredientType, ingredientType, _local5);
this[ingredientType].gotoAndStop(ingredientState);
hot_dog_bun_top._y = (this[Classes.ItemType.KETCHUP]._y = (this[Classes.ItemType.MUSTARD]._y = 0));
if (ingredients[Classes.ItemType.SAUSAGE] > 0) {
hot_dog_bun_top._y = hot_dog_bun_top._y - 10;
this[Classes.ItemType.KETCHUP]._y = this[Classes.ItemType.KETCHUP]._y - 7;
this[Classes.ItemType.MUSTARD]._y = this[Classes.ItemType.MUSTARD]._y - 7;
}
if (ingredients[Classes.ItemType.KETCHUP] > 0) {
hot_dog_bun_top._y = hot_dog_bun_top._y - 5;
this[Classes.ItemType.MUSTARD]._y = this[Classes.ItemType.MUSTARD]._y - 7;
}
if (ingredients[Classes.ItemType.MUSTARD] > 0) {
hot_dog_bun_top._y = hot_dog_bun_top._y - 5;
}
if ((ingredientType == Classes.ItemType.KETCHUP) || (ingredientType == Classes.ItemType.MUSTARD)) {
_root.sndController.playRandomSFX("squirt", 6);
}
break;
case Classes.ItemType.BURGER_BUN :
_local5 = ingredientDepths[ingredientType];
attachMovie("burger_" + ingredientType, ingredientType, _local5);
this[ingredientType].gotoAndStop(ingredientState);
burger_bun_top._y = (this[Classes.ItemType.KETCHUP]._y = (this[Classes.ItemType.MUSTARD]._y = 0));
if (ingredients[Classes.ItemType.BURGER] > 0) {
burger_bun_top._y = burger_bun_top._y - 10;
this[Classes.ItemType.KETCHUP]._y = this[Classes.ItemType.KETCHUP]._y - 7;
this[Classes.ItemType.MUSTARD]._y = this[Classes.ItemType.MUSTARD]._y - 7;
}
if (ingredients[Classes.ItemType.KETCHUP] > 0) {
burger_bun_top._y = burger_bun_top._y - 5;
this[Classes.ItemType.MUSTARD]._y = this[Classes.ItemType.MUSTARD]._y - 7;
}
if (ingredients[Classes.ItemType.MUSTARD] > 0) {
burger_bun_top._y = burger_bun_top._y - 5;
}
if (!((ingredientType == Classes.ItemType.KETCHUP) || (ingredientType == Classes.ItemType.MUSTARD))) {
break;
}
_root.sndController.playRandomSFX("squirt", 6);
}
}
}
function pressed() {
gameFieldMC.selectIcon(this);
if (!gameFieldMC.selectItem(this)) {
selected = true;
dragged = true;
swapDepths(highestDepth);
startDrag(false);
}
if (type == Classes.ItemType.SAUSAGE) {
if (_root.mainController.briefTipType == 3) {
_root.mainController.briefTipType++;
_root.brief_tip_clip.removeMovieClip();
}
}
}
function select() {
selected = true;
dragged = true;
swapDepths(highestDepth);
startDrag(false);
}
function unselect() {
selected = false;
var _local2 = new flash.geom.Transform(this);
_local2.colorTransform = new flash.geom.ColorTransform(1, 1, 1, 1, 0, 0, 0, 0);
}
function released() {
if (gameFieldMC.placeItem(this)) {
removeMovieClip();
} else if (dragged) {
dragged = false;
_x = initX;
_y = initY;
swapDepths(initDepth);
stopDrag();
}
}
var cookingState = 0;
static var ingredientDepths = {fries:1, money:1, hot_dog_bun:1, burger_bun:1, sausage:3, burger:3, onion:2, ketchup:4, mustard:5, bun_top:6};
static var highestDepth = 100;
var glowSinus = 0;
var selectSinus = 0;
var soundReadyPlayed = false;
var soundBurntPlayed = false;
}
Symbol 1354 MovieClip [__Packages.Classes.Customer] Frame 0
class Classes.Customer extends MovieClip
{
var state, overallSatisfactionInc, perfectOrder, mainController, gameSettings, skinMC, hairsMC, dressMC, faceMCFrameDisplacement, faceMC, cacheAsBitmap, orderPrice, satisfactionState, escapeSpeed, gameLevel, maxSpeed, type, cheatPercentage, tipAmount, waitingTime, satisfactionStatesCounts, index, _x, sx, orderItemsLeft, snackOrder, friesAmountOrder, drinksOrder, gotoAndStop, onRollOut, onReleaseOutside, onRollOver, gameFieldMC, orderBalloonMC, stateCounter, servingTimeCounter, onPress, cheat, swapDepths, _parent, dx, _y, removeMovieClip, shakeCounter, shakeX, shakeY, attachMovie, getNextHighestDepth;
function Customer () {
super();
state = STATE_TAKING_PLACE;
overallSatisfactionInc = 0;
perfectOrder = true;
mainController = _root.mainController;
gameSettings = _root.gameSettings;
var _local7 = Math.floor(Math.random() * 3) + 1;
skinMC.gotoAndStop(Math.floor(_local7));
hairsMC.gotoAndStop(Math.floor(Math.random() * 3) + 1);
dressMC.gotoAndStop(Math.floor(Math.random() * 3) + 1);
faceMCFrameDisplacement = ((_local7 - 1) * 4) + 1;
faceMC.gotoAndStop(faceMCFrameDisplacement);
cacheAsBitmap = true;
orderPrice = 0;
satisfactionState = 0;
escapeSpeed = gameSettings.getSettingNumber("escapeSpeed", gameLevel);
maxSpeed = gameSettings.getSettingNumber("customerMaxSpeed", gameLevel);
var _local6 = gameSettings.getCustomerData(type);
cheatPercentage = _local6.cheatPercentage;
tipAmount = _local6.tipAmount;
waitingTime = Math.floor(waitingTime * _local6.waitingTimeMultipl);
satisfactionStatesCounts = [];
var _local4 = 0;
while (_local4 < 4) {
satisfactionStatesCounts.push(_local4 * Math.floor(waitingTime / 4));
_local4++;
}
satisfactionStatesCounts.reverse();
switch (index) {
case 0 :
case 1 :
case 2 :
if ((index == 2) && (Math.random() < 0.5)) {
_x = 650;
sx = -1;
} else {
_x = -150;
sx = 1;
}
break;
case 3 :
case 4 :
_x = 650;
sx = -1;
}
var _local5 = gameSettings.getSettingObject("levelOrderItems", gameLevel);
orderItemsLeft = 1;
switch (_local5.snack) {
case Classes.ItemType.HOT_DOG :
snackOrder = {type:Classes.ItemType.HOT_DOG_BUN};
break;
case Classes.ItemType.BURGER :
snackOrder = {type:Classes.ItemType.BURGER_BUN};
break;
case Classes.ItemType.BOTH :
if (Math.random() < 0.5) {
snackOrder = {type:Classes.ItemType.HOT_DOG_BUN};
} else {
snackOrder = {type:Classes.ItemType.BURGER_BUN};
}
}
if (Math.random() < 0.7) {
switch (_local5.sauce) {
case Classes.ItemType.KETCHUP :
snackOrder.ketchup = 1;
break;
case Classes.ItemType.MUSTARD :
snackOrder.mustard = 1;
break;
case Classes.ItemType.BOTH :
if (Math.random() < 0.33) {
snackOrder.ketchup = 1;
} else if (Math.random() < 0.66) {
snackOrder.mustard = 1;
} else {
snackOrder.ketchup = 1;
snackOrder.mustard = 1;
}
}
}
if (_local5.onion && (Math.random() < 0.5)) {
snackOrder.onion = 1;
}
if ((Math.random() < 0.7) && (_local5.fries > 0)) {
friesAmountOrder = Math.floor(Math.random() * (_local5.fries + 1));
orderItemsLeft = orderItemsLeft + friesAmountOrder;
} else {
friesAmountOrder = 0;
}
if (Math.random() < 0.7) {
switch (_local5.drink) {
case Classes.ItemType.NONE :
case Classes.ItemType.COLA :
case Classes.ItemType.LEMONADE :
drinksOrder = _local5.drink;
break;
case Classes.ItemType.BOTH :
if (Math.random() >= 0.5) {
(Classes.ItemType.LEMONADE);// not popped
} else {
(Classes.ItemType.COLA);// not popped
}
gotoAndStop(type)[this] = "drinksOrder";
}
} else {
drinksOrder = Classes.ItemType.NONE;
}
orderItemsLeft = (((drinksOrder == Classes.ItemType.COLA) || (drinksOrder == Classes.ItemType.LEMONADE)) ? (orderItemsLeft + 1) : (orderItemsLeft));
onRollOut = (onReleaseOutside = function () {
this.rollOut();
});
onRollOver = function () {
this.rollOver();
};
}
function rollOut() {
var _local2 = new flash.geom.Transform(this);
_local2.colorTransform = new flash.geom.ColorTransform(1, 1, 1, 1, 0, 0, 0, 0);
}
function rollOver() {
if (state == STATE_WAITING_FOR_ORDER) {
var _local2 = new flash.geom.Transform(this);
_local2.colorTransform = new flash.geom.ColorTransform(0.7, 0.7, 0.7, 1, 77, 77, 77, 0);
}
}
function pressed() {
if (takeOrder(gameFieldMC.selectedItemMC)) {
gameFieldMC.orderTaken();
} else if ((gameFieldMC.selectedIcon.type == Classes.ItemType.COLA) || (gameFieldMC.selectedIcon.type == Classes.ItemType.LEMONADE)) {
if (drinksOrder == gameFieldMC.selectedIcon.type) {
if (drinksOrder == Classes.ItemType.COLA) {
orderPrice = orderPrice + gameSettings.getSettingNumber("colaPrice");
overallSatisfactionInc = overallSatisfactionInc + gameSettings.getSettingNumber("ingredientBonus");
} else if (drinksOrder == Classes.ItemType.LEMONADE) {
orderPrice = orderPrice + gameSettings.getSettingNumber("lemonadePrice");
overallSatisfactionInc = overallSatisfactionInc + gameSettings.getSettingNumber("ingredientBonus");
}
drinksOrder = Classes.ItemType.NONE;
orderBalloonMC.takeOrder(Classes.ItemType.DRINK);
orderItemsLeft--;
increaseSatisfaction();
}
}
}
function takeOrder(item) {
switch (item.type) {
case Classes.ItemType.HOT_DOG_BUN :
case Classes.ItemType.BURGER_BUN :
if ((snackOrder.type == item.type) && ((item.ingredients.sausage + item.ingredients.burger) > 0)) {
if (snackOrder.mustard == 1) {
if (item.ingredients.mustard == 1) {
orderPrice = orderPrice + gameSettings.getSettingNumber("mustardPrice");
overallSatisfactionInc = overallSatisfactionInc + gameSettings.getSettingNumber("ingredientBonus");
} else {
overallSatisfactionInc = overallSatisfactionInc - gameSettings.getSettingNumber("ingredientPenalty");
perfectOrder = false;
}
} else if (item.ingredients.mustard == 1) {
overallSatisfactionInc = overallSatisfactionInc - gameSettings.getSettingNumber("ingredientPenalty");
perfectOrder = false;
}
if (snackOrder.ketchup == 1) {
if (item.ingredients.ketchup == 1) {
orderPrice = orderPrice + gameSettings.getSettingNumber("ketchupPrice");
overallSatisfactionInc = overallSatisfactionInc + gameSettings.getSettingNumber("ingredientBonus");
} else {
overallSatisfactionInc = overallSatisfactionInc - gameSettings.getSettingNumber("ingredientPenalty");
perfectOrder = false;
}
} else if (item.ingredients.ketchup == 1) {
overallSatisfactionInc = overallSatisfactionInc - gameSettings.getSettingNumber("ingredientPenalty");
perfectOrder = false;
}
if (snackOrder.onion == 1) {
if (item.ingredients.onion > 0) {
orderPrice = orderPrice + gameSettings.getSettingNumber("onionsPrice");
orderPrice = orderPrice - (Math.abs(item.ingredients.onion - 3) * gameSettings.getSettingNumber("onionPenalty"));
overallSatisfactionInc = overallSatisfactionInc + gameSettings.getSettingNumber("ingredientBonus");
overallSatisfactionInc = overallSatisfactionInc - (Math.abs(item.ingredients.onion - 3) * gameSettings.getSettingNumber("ingredientPenalty"));
perfectOrder = ((item.ingredients.onion != 3) ? false : (perfectOrder));
} else {
overallSatisfactionInc = overallSatisfactionInc - gameSettings.getSettingNumber("ingredientPenalty");
perfectOrder = false;
}
} else if (item.ingredients.onion > 0) {
overallSatisfactionInc = overallSatisfactionInc - gameSettings.getSettingNumber("ingredientPenalty");
perfectOrder = false;
}
if (item.type == Classes.ItemType.HOT_DOG_BUN) {
orderPrice = orderPrice + gameSettings.getSettingNumber("hotdogPrice");
orderPrice = orderPrice - (Math.abs(item.ingredients.sausage - 3) * gameSettings.getSettingNumber("hotdogPenalty"));
overallSatisfactionInc = overallSatisfactionInc + gameSettings.getSettingNumber("ingredientBonus");
overallSatisfactionInc = overallSatisfactionInc - (Math.abs(item.ingredients.sausage - 3) * gameSettings.getSettingNumber("ingredientPenalty"));
perfectOrder = ((item.ingredients.sausage != 3) ? false : (perfectOrder));
} else {
orderPrice = orderPrice + gameSettings.getSettingNumber("burgerPrice");
orderPrice = orderPrice - (Math.abs(item.ingredients.burger - 3) * gameSettings.getSettingNumber("burgerPenalty"));
overallSatisfactionInc = overallSatisfactionInc + gameSettings.getSettingNumber("ingredientBonus");
overallSatisfactionInc = overallSatisfactionInc - (Math.abs(item.ingredients.burger - 3) * gameSettings.getSettingNumber("ingredientPenalty"));
perfectOrder = ((item.ingredients.burger != 3) ? false : (perfectOrder));
}
snackOrder.type = Classes.ItemType.NONE;
orderBalloonMC.takeOrder(Classes.ItemType.SNACK);
orderItemsLeft--;
increaseSatisfaction();
return(true);
}
break;
case Classes.ItemType.FRIES :
if (friesAmountOrder > 0) {
orderPrice = orderPrice + gameSettings.getSettingNumber("friesPrice");
friesAmountOrder--;
orderBalloonMC.takeOrder(Classes.ItemType.FRIES);
overallSatisfactionInc = overallSatisfactionInc + gameSettings.getSettingNumber("ingredientBonus");
orderItemsLeft--;
increaseSatisfaction();
return(true);
}
break;
case Classes.ItemType.COLA :
case Classes.ItemType.LEMONADE :
if (drinksOrder != item.type) {
break;
}
if (drinksOrder == Classes.ItemType.COLA) {
orderPrice = orderPrice + gameSettings.getSettingNumber("colaPrice");
overallSatisfactionInc = overallSatisfactionInc + gameSettings.getSettingNumber("ingredientBonus");
} else if (drinksOrder == Classes.ItemType.LEMONADE) {
orderPrice = orderPrice + gameSettings.getSettingNumber("lemonadePrice");
overallSatisfactionInc = overallSatisfactionInc + gameSettings.getSettingNumber("ingredientBonus");
}
drinksOrder = Classes.ItemType.NONE;
orderBalloonMC.takeOrder(Classes.ItemType.DRINK);
orderItemsLeft--;
increaseSatisfaction();
return(true);
}
return(false);
}
function increaseSatisfaction() {
if (satisfactionState == 0) {
stateCounter = waitingTime;
} else {
satisfactionState--;
shaking = false;
stateCounter = ((satisfactionState > 0) ? (satisfactionStatesCounts[satisfactionState - 1]) : (waitingTime));
faceMC.gotoAndStop(faceMCFrameDisplacement + satisfactionState);
}
}
function attachCash() {
mainController.customerServed(servingTimeCounter > 0);
delete onPress;
if (perfectOrder) {
orderPrice = Math.floor(orderPrice * (1 + tipAmount));
overallSatisfactionInc = overallSatisfactionInc + gameSettings.getSettingNumber("perfectOrderBonus");
}
overallSatisfactionInc = overallSatisfactionInc - gameSettings.getSettingNumber("satisfactionStatePenalty");
orderPrice = orderPrice - (satisfactionState * gameSettings.getSettingNumber("customerStatePenalty"));
mainController.setOverallSatisfaction(overallSatisfactionInc);
if (orderPrice < 1) {
orderPrice = 1;
}
if ((Math.random() < cheatPercentage) && (cheat)) {
swapDepths(_parent.getNextHighestDepth());
onPress = function () {
this.stateCounter = 90;
this.state = Classes.Customer.STATE_CATCHED;
var _local2 = {_x:-19, _y:-56};
this.orderBalloonMC = this.attachMovie("escape_balloon", "escape_balloon", this.getNextHighestDepth(), _local2);
var _local5 = new Classes.ObjectTransition(this.orderBalloonMC, true);
delete this.onPress;
};
mainController.showThiefWarning();
state = STATE_ESCAPING;
} else {
stateCounter = 20;
mainController.attachCash(index, orderPrice, _x + 45);
state = STATE_WAITING_BEFORE_LEAVING;
}
}
function update() {
switch (state) {
case STATE_TAKING_PLACE :
takingPlace();
break;
case STATE_WAITING :
waiting();
break;
case STATE_WAITING_FOR_ORDER :
servingTimeCounter--;
waitingForOrder();
break;
case STATE_WAITING_BEFORE_LEAVING :
waitingBeforeLeaving();
break;
case STATE_ESCAPING :
escaping();
break;
case STATE_CATCHED :
catched();
break;
case STATE_LEAVING :
leaving();
}
}
function catched() {
stateCounter--;
if (stateCounter == 0) {
var _local2 = new Classes.ObjectTransition(orderBalloonMC, false);
mainController.attachCash(index, orderPrice, _x + 45);
state = STATE_LEAVING;
}
}
function leaving() {
yAmp = yAmp * 1.25;
yAmp = ((yAmp > 3) ? 3 : (yAmp));
dx = dx + 0.3;
dx = ((dx > maxSpeed) ? (maxSpeed) : (dx));
_y = initY + (yAmp * Math.sin(sinus));
_x = _x + (dx * sx);
sinus = sinus + 0.3;
if ((_x > 650) || (_x < -150)) {
mainController.freeCustomerPosition(index);
mainController.totalCustomers--;
removeMovieClip();
}
}
function escaping() {
yAmp = yAmp * 1.25;
yAmp = ((yAmp > 3) ? 3 : (yAmp));
dx = escapeSpeed;
_y = initY + (yAmp * Math.sin(sinus));
_x = _x + (dx * sx);
sinus = sinus + 0.3;
if ((_x > 650) || (_x < -150)) {
mainController.freeCustomerPosition(index);
mainController.totalCustomers--;
removeMovieClip();
}
}
function waitingBeforeLeaving() {
stateCounter--;
if (stateCounter == 0) {
sinus = 0;
dx = 0;
yAmp = 1;
swapDepths(gameFieldMC.leavingCustomerDepth);
gameFieldMC.leavingCustomerDepth--;
state = STATE_LEAVING;
}
}
function waitingForOrder() {
stateCounter--;
if (shaking) {
shakeCounter--;
if (shakeCounter > 45) {
_x = (shakeX + (Math.random() * 1)) - 0.5;
_y = (shakeY + (Math.random() * 1)) - 0.5;
} else {
_x = shakeX;
_y = shakeY;
shakeCounter = ((shakeCounter == 0) ? 60 : (shakeCounter));
}
}
if (stateCounter > 0) {
if (stateCounter == satisfactionStatesCounts[satisfactionState]) {
satisfactionState++;
if (satisfactionState == 3) {
if (!angrySoundPlayed) {
angrySoundPlayed = true;
switch (type) {
case "oldwoman" :
_root.sndController.playSFX("gramma.01.wav");
break;
case "oldman" :
case "bum" :
_root.sndController.playSFX("gramps.01.wav");
break;
case "generic_woman" :
case "business_woman" :
case "tourist_girl" :
case "sportswoman" :
_root.sndController.playSFX("woman.01.wav");
break;
case "boy" :
_root.sndController.playSFX("boy.01.wav");
break;
case "girl" :
_root.sndController.playSFX("girl.01.wav");
break;
case "alien" :
_root.sndController.playRandomSFX("alien", 5);
break;
default :
_root.sndController.playRandomSFX("man_growl", 2);
}
}
shakeCounter = 60;
shaking = true;
}
faceMC.gotoAndStop(faceMCFrameDisplacement + satisfactionState);
}
if (orderItemsLeft == 0) {
stateCounter = 0;
}
} else {
orderBalloonMC.remove();
if (orderItemsLeft == 0) {
attachCash();
} else {
overallSatisfactionInc = (-satisfactionState) * gameSettings.getSettingNumber("customerStatePenalty");
mainController.setOverallSatisfaction(overallSatisfactionInc);
stateCounter = 20;
state = STATE_WAITING_BEFORE_LEAVING;
delete onPress;
}
}
}
function waiting() {
stateCounter--;
if (stateCounter == 0) {
var _local2 = {_x:-19, _y:-56, drinksOrder:drinksOrder, friesAmountOrder:friesAmountOrder, snackOrder:snackOrder};
orderBalloonMC = attachMovie("orderBalloonMC", "orderBalloonMC", getNextHighestDepth(), _local2);
stateCounter = waitingTime;
onPress = function () {
this.pressed();
};
shakeX = _x;
shakeY = _y;
state = STATE_WAITING_FOR_ORDER;
}
}
function takingPlace() {
_y = initY + (yAmp * Math.sin(sinus));
sinus = sinus + 0.3;
dx = Math.abs(_x - positions[index]) / 5;
if (dx > maxSpeed) {
dx = maxSpeed;
} else {
yAmp = yAmp * 0.8;
}
_x = _x + (dx * sx);
if (dx < 0.2) {
_x = positions[index];
_y = initY;
stateCounter = 20;
state = STATE_WAITING;
}
}
var sinus = 0;
static var positions = [20, 140, 260, 380, 500];
var initY = 60;
var yAmp = 3;
var shaking = false;
var angrySoundPlayed = false;
static var STATE_TAKING_PLACE = "takingPlace";
static var STATE_WAITING = "waiting";
static var STATE_WAITING_FOR_ORDER = "waitingForOrder";
static var STATE_WAITING_BEFORE_LEAVING = "waitingBeforeLeaving";
static var STATE_ESCAPING = "escaping";
static var STATE_CATCHED = "catched";
static var STATE_LEAVING = "leaving";
}
Symbol 1355 MovieClip [__Packages.Classes.Map] Frame 0
class Classes.Map extends MovieClip
{
static var showAllReachedStages;
var bronx, yankees_stadium, central_park, times_square, wall_street, alien_ship;
function Map () {
super();
}
function init() {
var _local7 = _root.mainController;
var _local5 = _local7.__get__mapLocation();
for (var _local6 in this) {
var _local3 = this[_local6];
_local3.disable();
}
if (showAllReachedStages) {
showAllReachedStages = false;
var _local4 = [bronx, yankees_stadium, central_park, times_square, wall_street, alien_ship];
_local4 = _local4.slice(0, _root.gameSettings.reachedStage);
for (var _local6 in _local4) {
var _local3 = _local4[_local6];
_local3.enable();
}
} else {
for (var _local6 in this) {
var _local3 = this[_local5];
_local3.enable();
}
}
}
}
Symbol 1356 MovieClip [__Packages.Classes.Cash] Frame 0
class Classes.Cash extends MovieClip
{
var mainController, _x, _y, dx, dy, currentStep, onPress, onRollOut, onRollOver, cashAmount, index, removeMovieClip;
function Cash () {
super();
mainController = _root.mainController;
if (_x < 70) {
_x = 70;
} else if (_x > 580) {
_x = 580;
}
if ((_x > 320) && (_x <= 350)) {
_x = 320;
}
if ((_x > 350) && (_x < 380)) {
_x = 380;
}
_y = 205;
dx = 200 - _x;
dy = 385 - _y;
var _local4 = Math.sqrt((dx * dx) + (dy * dy));
currentStep = Math.floor(_local4 / speed);
dx = dx / currentStep;
dy = dy / currentStep;
onPress = function () {
_root.sndController.playSFX("cash_register.01.wav");
this._parent.attachMovie("cashAmountMC", "cashAmountMC_" + this.getDepth(), this.getDepth() + 100, {cashAmount:"$" + this.cashAmount, _x:this._x, _y:this._y});
this.clicked = true;
this.swapDepths(this.index + 200);
delete this.onPress;
};
onRollOut = function () {
this.rollOut();
};
onRollOver = function () {
this.rollOver();
};
var _local6 = new Classes.ObjectTransition(this, true);
}
function rollOut() {
var _local2 = new flash.geom.Transform(this);
_local2.colorTransform = new flash.geom.ColorTransform(1, 1, 1, 1, 0, 0, 0, 0);
}
function rollOver() {
var _local2 = new flash.geom.Transform(this);
_local2.colorTransform = new flash.geom.ColorTransform(0.7, 0.7, 0.7, 1, 77, 77, 77, 0);
}
function update() {
if (clicked) {
_x = _x + dx;
_y = _y + dy;
currentStep--;
if (currentStep == 0) {
mainController.addCash(cashAmount);
mainController.freeCustomerPosition(index);
removeMovieClip();
}
}
}
var speed = 25;
var clicked = false;
}
Symbol 1357 MovieClip [__Packages.Classes.OrderBalloon] Frame 0
class Classes.OrderBalloon extends MovieClip
{
var snackOrder, snack_mc, fries_mc, friesAmountOrder, drinks_mc, drinksOrder, cacheAsBitmap;
function OrderBalloon () {
super();
var _local3;
if ((snackOrder.ketchup != 1) && (snackOrder.mustard != 1)) {
_local3 = "plain";
} else if ((snackOrder.ketchup == 1) && (snackOrder.mustard != 1)) {
_local3 = Classes.ItemType.KETCHUP;
} else if ((snackOrder.ketchup != 1) && (snackOrder.mustard == 1)) {
_local3 = Classes.ItemType.MUSTARD;
} else {
_local3 = Classes.ItemType.BOTH;
}
var _local4 = ((snackOrder.type == Classes.ItemType.BURGER_BUN) ? (Classes.ItemType.BURGER) : (Classes.ItemType.HOT_DOG));
snack_mc.gotoAndStop((_local4 + "_") + _local3);
snack_mc.onion._visible = snackOrder.onion == 1;
fries_mc.gotoAndStop(friesAmountOrder + 1);
drinks_mc.gotoAndStop(drinksOrder);
cacheAsBitmap = true;
var _local5 = new Classes.ObjectTransition(this, true);
}
function takeOrder(itemType) {
switch (itemType) {
case Classes.ItemType.SNACK :
var _local2 = new Classes.ObjectTransition(snack_mc, false);
break;
case Classes.ItemType.FRIES :
if (fries_mc._currentframe == 2) {
_local2 = new Classes.ObjectTransition(fries_mc, false);
} else {
fries_mc.prevFrame();
}
break;
case Classes.ItemType.DRINK :
_local2 = new Classes.ObjectTransition(drinks_mc, false);
}
}
function remove() {
var _local2 = new Classes.ObjectTransition(this, false);
}
}
Symbol 1358 MovieClip [__Packages.Classes.ContextMenuController] Frame 0
class Classes.ContextMenuController
{
var cm;
function ContextMenuController () {
init();
}
function init() {
cm = new ContextMenu();
cm.hideBuiltInItems();
cm.customItems.push(new ContextMenuItem("High scores", highScores));
cm.customItems.push(new ContextMenuItem("Play more games", playMoreGames));
cm.customItems.push(new ContextMenuItem("Get game for your site", getGame));
cm.customItems.push(new ContextMenuItem("Download this game", downloadGame));
_root.menu = cm;
}
function highScores(obj, menuItem) {
getURL (_root.viewscores_link, "_blank");
}
function playMoreGames(obj, menuItem) {
getURL (_root.main_link, "_blank");
}
function getGame(obj, menuItem) {
getURL (_root.get_game_link, "_blank");
}
function downloadGame(obj, menuItem) {
getURL (_root.download_link, "_blank");
}
}
Symbol 102 MovieClip [ButtonMC] Frame 1
#initclip 34
Object.registerClass("ButtonMC", Classes.ButtonMC);
#endinitclip
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 103 MovieClip [speed_mode_begin_warning] Frame 1
//component parameters
onClipEvent (construct) {
labelString = "Continue";
flashing = true;
}
onClipEvent (load) {
pressAction = function () {
_parent.removeMovieClip();
};
}
Symbol 112 MovieClip [2dplayButton] Frame 1
#initclip 18
Object.registerClass("2dplayButton", Classes.ButtonMC);
#endinitclip
Symbol 117 MovieClip [popup_window_caption] Frame 1
stop();
Symbol 117 MovieClip [popup_window_caption] Frame 3
if (!_root.mainController.careerMode) {
gotoAndPlay ("speed_mode");
} else {
neededCashStr = "Needed: $" + _parent.salesGoal;
earnedCashStr = "Earned: $" + _parent.curLevelScore;
totalCashStr = "Total: $" + _parent.totalScore;
if (_parent.curLevelScore < _parent.salesGoal) {
_root.sndController.playSFX("wahwah.01.wav");
gotoAndPlay ("failure");
} else {
_root.sndController.playSFX("tada.01.wav");
gotoAndStop ("success");
}
}
Instance of Symbol 102 MovieClip [ButtonMC] "succes_start_next" in Symbol 117 MovieClip [popup_window_caption] Frame 4
//component parameters
onClipEvent (construct) {
labelString = "Start Next Day";
flashing = true;
}
onClipEvent (load) {
pressAction = function () {
var _local3 = _root.mainController.gameLevel;
switch (_local3) {
case 30 :
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"game_finished"});
_parent._parent.removeMovieClip();
break;
case 25 :
_root.mainController.gameLevel++;
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"alien_intro"});
_parent._parent.removeMovieClip();
break;
case 5 :
case 10 :
case 15 :
case 20 :
_root.mainController.gameLevel++;
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"game_map"});
_parent._parent.removeMovieClip();
break;
default :
_root.mainController.gameLevel++;
_root.gotoAndPlay("start_level");
_parent._parent.removeMovieClip();
}
};
}
Instance of Symbol 112 MovieClip [2dplayButton] in Symbol 117 MovieClip [popup_window_caption] Frame 4
//component parameters
onClipEvent (construct) {
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.main_link, "_blank");
};
}
Symbol 117 MovieClip [popup_window_caption] Frame 5
tipText = _root.mainController.tipText;
stop();
Instance of Symbol 102 MovieClip [ButtonMC] "failure_restart" in Symbol 117 MovieClip [popup_window_caption] Frame 5
//component parameters
onClipEvent (construct) {
labelString = "Try Day Again";
flashing = true;
}
onClipEvent (load) {
pressAction = function () {
_root.gotoAndPlay("start_level");
_parent._parent.removeMovieClip();
};
}
Instance of Symbol 102 MovieClip [ButtonMC] "failure_submit" in Symbol 117 MovieClip [popup_window_caption] Frame 5
//component parameters
onClipEvent (construct) {
labelString = "Submit Your Score";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
var _local3 = _root.hex_md5(((("gameid=" + _root.game_id) + "&hiscore=") + _parent._parent.totalScore) + "2DPlay.com/");
getURL ((((("http://www.2DPlay.com/highscores.php?gameid=" + _root.game_id) + "&hiscore=") + _parent._parent.totalScore) + "&hash=") + _local3, "_blank");
};
}
Instance of Symbol 102 MovieClip [ButtonMC] "failure_main_menu" in Symbol 117 MovieClip [popup_window_caption] Frame 5
//component parameters
onClipEvent (construct) {
labelString = "Main Menu";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
_root.mainController.quitGame();
_parent._parent.removeMovieClip();
};
}
Symbol 117 MovieClip [popup_window_caption] Frame 6
finalCashStr = "Total earnings: $" + _parent.totalScore;
stop();
Instance of Symbol 102 MovieClip [ButtonMC] "failure_restart" in Symbol 117 MovieClip [popup_window_caption] Frame 6
//component parameters
onClipEvent (construct) {
labelString = "Try Again";
flashing = true;
}
onClipEvent (load) {
pressAction = function () {
_root.mainController.resetScore();
_root.gotoAndPlay("start_level");
_parent._parent.removeMovieClip();
};
}
Instance of Symbol 102 MovieClip [ButtonMC] "failure_main_menu" in Symbol 117 MovieClip [popup_window_caption] Frame 6
//component parameters
onClipEvent (construct) {
labelString = "Main Menu";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
_root.mainController.quitGame();
_parent._parent.removeMovieClip();
};
}
Symbol 120 MovieClip [popup_caption] Frame 60
this.removeMovieClip();
Symbol 127 MovieClip [popup_caption_new_item] Frame 1
var mc = this["place_" + level];
arrow_mc._x = mc._x;
arrow_mc._y = mc._y;
Symbol 127 MovieClip [popup_caption_new_item] Frame 60
this.removeMovieClip();
Symbol 131 MovieClip [popup_window] Frame 1
blockButton.useHandCursor = false;
gotoAndPlay(frameLabel);
Symbol 131 MovieClip [popup_window] Frame 2
_root.sndController.playSFX("grill_close.01.wav");
Symbol 131 MovieClip [popup_window] Frame 36
caption.gotoAndStop(captionType);
_root.gotoAndPlay("day_completed");
stop();
Symbol 131 MovieClip [popup_window] Frame 37
caption.gotoAndStop(captionType);
Symbol 131 MovieClip [popup_window] Frame 81
_root.sndController.playSFX("grill_open.01.wav");
Symbol 131 MovieClip [popup_window] Frame 100
_root.mainController.startLevel();
this.removeMovieClip();
Symbol 131 MovieClip [popup_window] Frame 101
_root.sndController.playSFX("grill_open.01.wav");
Symbol 131 MovieClip [popup_window] Frame 120
_root.mainController.buildLevel(false);
_root.mainController.startLevel();
this.removeMovieClip();
Symbol 133 MovieClip [select_relish_icon] Frame 1
#initclip 19
Object.registerClass("select_relish_icon", Classes.SelectedIcon);
#endinitclip
Symbol 135 MovieClip [select_cola_icon] Frame 1
#initclip 20
Object.registerClass("select_cola_icon", Classes.SelectedIcon);
#endinitclip
Symbol 137 MovieClip [select_lemonade_icon] Frame 1
#initclip 21
Object.registerClass("select_lemonade_icon", Classes.SelectedIcon);
#endinitclip
Symbol 155 MovieClip [ufo] Frame 1
#initclip 22
Object.registerClass("ufo", Classes.MapButtonMC);
#endinitclip
this.reachedStage = 6;
Symbol 159 MovieClip [cashAmountMC] Frame 20
this.removeMovieClip();
Symbol 164 MovieClip [location_wall_street] Frame 1
#initclip 23
Object.registerClass("location_wall_street", Classes.MapButtonMC);
#endinitclip
this.reachedStage = 5;
Symbol 169 MovieClip [location_stadium] Frame 1
#initclip 24
Object.registerClass("location_stadium", Classes.MapButtonMC);
#endinitclip
this.reachedStage = 2;
Symbol 174 MovieClip [location_bronks] Frame 1
#initclip 25
Object.registerClass("location_bronks", Classes.MapButtonMC);
#endinitclip
this.reachedStage = 1;
Symbol 179 MovieClip [location_park] Frame 1
#initclip 26
Object.registerClass("location_park", Classes.MapButtonMC);
#endinitclip
this.reachedStage = 3;
Symbol 189 MovieClip [location_times_square] Frame 1
#initclip 27
Object.registerClass("location_times_square", Classes.MapButtonMC);
#endinitclip
this.reachedStage = 4;
Symbol 198 MovieClip [game_map] Frame 1
#initclip 28
Object.registerClass("game_map", Classes.Map);
#endinitclip
Symbol 202 MovieClip [cash_mc] Frame 1
#initclip 29
Object.registerClass("cash_mc", Classes.Cash);
#endinitclip
stop();
Symbol 202 MovieClip [cash_mc] Frame 2
stop();
Symbol 202 MovieClip [cash_mc] Frame 3
stop();
Symbol 268 MovieClip Frame 1
stop();
Symbol 274 MovieClip [orderBalloonMC] Frame 1
#initclip 30
Object.registerClass("orderBalloonMC", Classes.OrderBalloon);
#endinitclip
Symbol 757 MovieClip [customerMC] Frame 1
#initclip 31
Object.registerClass("customerMC", Classes.Customer);
#endinitclip
Symbol 758 MovieClip [pauseMenuMC] Frame 1
var transition = (new Classes.ObjectTransition(this, true));
blockButton.useHandCursor = false;
stop();
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 758 MovieClip [pauseMenuMC] Frame 1
//component parameters
onClipEvent (construct) {
labelString = "";
flashing = false;
}
onClipEvent (load) {
labelString = _root.mainController.getQualityString();
initDynamicButton();
pressAction = function () {
_root.mainController.switchQuality();
labelString = _root.mainController.getQualityString();
initDynamicButton();
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 758 MovieClip [pauseMenuMC] Frame 1
//component parameters
onClipEvent (construct) {
labelString = "";
flashing = false;
}
onClipEvent (load) {
labelString = _root.mainController.getSoundString();
initDynamicButton();
pressAction = function () {
_root.mainController.switchSound();
labelString = _root.mainController.getSoundString();
initDynamicButton();
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 758 MovieClip [pauseMenuMC] Frame 1
//component parameters
onClipEvent (construct) {
labelString = "Get Game For Your Site";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.get_game_link, "_blank");
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 758 MovieClip [pauseMenuMC] Frame 1
//component parameters
onClipEvent (construct) {
labelString = "Play More Games";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.main_link, "_blank");
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 758 MovieClip [pauseMenuMC] Frame 1
//component parameters
onClipEvent (construct) {
labelString = "High Scores";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.viewscores_link, "_blank");
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 758 MovieClip [pauseMenuMC] Frame 1
//component parameters
onClipEvent (construct) {
labelString = "Download Game";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.download_link, "_blank");
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 758 MovieClip [pauseMenuMC] Frame 1
//component parameters
onClipEvent (construct) {
labelString = "Resume Game";
flashing = true;
}
onClipEvent (load) {
pressAction = function () {
var _local3 = new Classes.ObjectTransition(_parent, false);
_parent.play();
_root.mainController.pauseGame(false);
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 758 MovieClip [pauseMenuMC] Frame 1
//component parameters
onClipEvent (construct) {
labelString = "Quit Game";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
_root.mainController.quitGame();
_parent.removeMovieClip();
};
}
Symbol 758 MovieClip [pauseMenuMC] Frame 2
stop();
Symbol 820 Button
on (press) {
attachNewItem("cola");
}
Symbol 821 Button
on (press) {
attachNewItem("lemonade");
}
Symbol 823 Button
on (release) {
attachNewItem("raw_fries");
}
Symbol 825 Button
on (release) {
attachNewItem("hot_dog_bun");
}
Symbol 827 Button
on (release) {
attachNewItem("burger_bun");
}
Symbol 829 Button
on (release) {
attachNewItem("onion");
}
Symbol 831 Button
on (release) {
attachNewItem("burger");
}
Symbol 833 Button
on (release) {
attachNewItem("sausage");
}
Symbol 835 Button
on (press) {
throwAwayItem();
}
Symbol 838 Button
on (press) {
attachNewItem("ketchup");
}
Symbol 839 Button
on (press) {
attachNewItem("mustard");
}
Symbol 840 MovieClip [GameFieldMC] Frame 1
#initclip 32
Object.registerClass("GameFieldMC", Classes.GameField);
#endinitclip
Symbol 841 MovieClip [DraggableItemMC] Frame 1
#initclip 33
Object.registerClass("DraggableItemMC", Classes.DraggableItem);
#endinitclip
Symbol 842 MovieClip [TransitionMC] Frame 1
blockButton.useHandCursor = false;
Symbol 842 MovieClip [TransitionMC] Frame 8
_root.gotoAndPlay(frameLabel);
Symbol 842 MovieClip [TransitionMC] Frame 15
this.removeMovieClip();
Symbol 849 MovieClip Frame 10
stop();
Symbol 852 MovieClip Frame 10
stop();
Symbol 855 MovieClip Frame 10
stop();
Symbol 858 MovieClip Frame 10
stop();
Symbol 859 MovieClip [brief_tip_clip] Frame 72
stop();
Symbol 859 MovieClip [brief_tip_clip] Frame 73
stop();
Symbol 859 MovieClip [brief_tip_clip] Frame 74
stop();
Symbol 859 MovieClip [brief_tip_clip] Frame 75
stop();
Symbol 860 MovieClip Frame 1
stop();
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 860 MovieClip Frame 46
//component parameters
onClipEvent (construct) {
labelString = "Button label";
flashing = false;
}
Instance of Symbol 112 MovieClip [2dplayButton] in Symbol 860 MovieClip Frame 47
//component parameters
onClipEvent (construct) {
flashing = false;
}
Symbol 905 MovieClip Frame 1
stop();
Symbol 910 Button
on (release) {
if (_currentframe < (_totalframes - 30)) {
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"main_menu"});
}
}
Symbol 967 MovieClip Frame 565
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"main_menu"});
stop();
Symbol 991 Button
on (release) {
getURL (_root.main_link, "_blank");
}
Symbol 1023 MovieClip Frame 1
stop();
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 1023 MovieClip Frame 1
//component parameters
onClipEvent (construct) {
labelString = "More";
flashing = true;
}
onClipEvent (load) {
pressAction = function () {
_parent.nextFrame();
};
}
Symbol 1023 MovieClip Frame 2
stop();
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 1023 MovieClip Frame 2
//component parameters
onClipEvent (construct) {
labelString = "Main Menu";
flashing = true;
}
onClipEvent (load) {
pressAction = function () {
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"main_menu"});
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 1023 MovieClip Frame 2
//component parameters
onClipEvent (construct) {
labelString = "Back";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
_parent.prevFrame();
};
}
Symbol 1053 Button
on (press) {
_root.mainController.startGame(true);
}
Symbol 1056 Button
on (press) {
if (_root.gameSettings.reachedStage < 3) {
_root.attachMovie("speed_mode_begin_warning", "speed_mode_begin_warning", _root.getNextHighestDepth());
} else {
_root.mainController.startGame(false);
}
}
Symbol 1069 MovieClip Frame 1
stop();
Instance of Symbol 112 MovieClip [2dplayButton] in Symbol 1075 MovieClip Frame 1
//component parameters
onClipEvent (construct) {
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.main_link, "_blank");
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 1075 MovieClip Frame 1
//component parameters
onClipEvent (construct) {
labelString = "Pause";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
_root.mainController.pauseGame(true);
};
}
Symbol 1093 Button
on (release) {
if (_currentframe < (_totalframes - 30)) {
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"game_map"});
}
}
Symbol 1113 MovieClip Frame 14
stop();
Symbol 1195 MovieClip Frame 296
stop();
Symbol 1200 MovieClip Frame 926
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"game_map"});
stop();
Symbol 1267 MovieClip Frame 296
stop();
Symbol 1300 MovieClip Frame 18
stop();
Symbol 1331 MovieClip Frame 8
stop();
Symbol 1336 MovieClip Frame 8
stop();
Symbol 1341 MovieClip Frame 771
finalScoreStr = "Total earnings: $" + _root.mainController.totalScore;
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 1341 MovieClip Frame 771
//component parameters
onClipEvent (construct) {
labelString = "Main Menu";
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
_root.attachMovie("TransitionMC", "TransitionMC", _root.getNextHighestDepth(), {frameLabel:"main_menu"});
};
}
Instance of Symbol 102 MovieClip [ButtonMC] in Symbol 1341 MovieClip Frame 771
//component parameters
onClipEvent (construct) {
labelString = "Submit Score";
flashing = true;
}
onClipEvent (load) {
pressAction = function () {
var _local2 = _root.mainController.totalScore;
var _local3 = _root.hex_md5(((("gameid=" + _root.game_id) + "&hiscore=") + _local2) + "2DPlay.com/");
getURL ((((("http://www.2DPlay.com/highscores.php?gameid=" + _root.game_id) + "&hiscore=") + _local2) + "&hash=") + _local3, "_blank");
};
}
Instance of Symbol 112 MovieClip [2dplayButton] in Symbol 1341 MovieClip Frame 771
//component parameters
onClipEvent (construct) {
flashing = false;
}
onClipEvent (load) {
pressAction = function () {
getURL (_root.main_link, "_blank");
};
}
Symbol 1341 MovieClip Frame 775
_root.sndController.playMusicTrack("bushsong.wav");
stop();