Frame 1
var my_cm = new ContextMenu();
my_cm.hideBuiltInItems();
_root.menu = my_cm;
MochiAd.showPreGameAd({id:"5265e27be1530b1a", res:"800x600"});
Frame 3
if (_root.getBytesLoaded() < _root.getBytesTotal()) {
gotoAndStop ("Loading");
}
Frame 7
stop();
Symbol 2 MovieClip Frame 1
onPress = function () {
getURL ("http://www.freeworldgroup.com");
};
Symbol 5 MovieClip Frame 1
function Replace() {
if (sVariable.length == 0) {
tTxt.text = sTxt;
} else {
tTxt.variable = sVariable;
}
tTxt.autoSize = autoSize;
if (autoSize == "right") {
tTxt._x = -Math.floor(tTxt._width);
} else if (autoSize == "center") {
tTxt._x = -Math.floor(tTxt._width / 2);
} else {
tTxt._x = 0;
}
}
var sTxt;
var bBmp;
var bMultiline;
var autoSize;
var sVariable;
Replace();
this.cacheAsBitmap = bBmp;
Symbol 6 MovieClip Frame 1
_x = (Stage.width / 2);
_y = ((Stage.height / 2) - 30);
Symbol 6 MovieClip Frame 25
stop();
var rate;
var all = _root.getBytesTotal();
onEnterFrame = function () {
var _local3 = _root.getBytesLoaded();
rate = int((_local3 / all) * 100) + "%";
mLoading._alpha = Math.round(SFM.linearCycle(getTimer(), 1000, 100));
if (_local3 == all) {
delete this.onEnterFrame;
if ((_root._mochiad instanceof MovieClip) != true) {
_root.play();
}
}
};
Instance of Symbol 5 MovieClip in Symbol 6 MovieClip Frame 25
//component parameters
onClipEvent (construct) {
sTxt = "TXT";
sVariable = "_parent.rate";
autoSize = "center";
bBmp = false;
}
Instance of Symbol 5 MovieClip "mLoading" in Symbol 6 MovieClip Frame 25
//component parameters
onClipEvent (construct) {
sTxt = "Loading...";
sVariable = "";
autoSize = "center";
bBmp = false;
}
Symbol 830 MovieClip [__Packages.MochiAd] Frame 0
class MochiAd
{
function MochiAd () {
}
static function getVersion() {
return("2.0");
}
static function showPreGameAd(options) {
var _local27 = {clip:_root, ad_timeout:3000, fadeout_time:250, regpt:"o", method:"showPreloaderAd", color:16747008, background:16777161, outline:13994812, ad_started:function () {
this.clip.stop();
}, ad_finished:function () {
this.clip.play();
}};
options = _parseOptions(options, _local27);
var clip = options.clip;
var _local23 = 11000;
var _local26 = options.ad_timeout;
delete options.ad_timeout;
var fadeout_time = options.fadeout_time;
delete options.fadeout_time;
if (!load(options)) {
options.ad_finished();
return(undefined);
}
options.ad_started();
var mc = clip._mochiad;
mc.onUnload = function () {
options.ad_finished();
};
var _local14 = _getRes(options);
var _local4 = _local14[0];
var _local13 = _local14[1];
mc._x = _local4 * 0.5;
mc._y = _local13 * 0.5;
var chk = mc.createEmptyMovieClip("_mochiad_wait", 3);
chk._x = _local4 * -0.5;
chk._y = _local13 * -0.5;
var _local7 = chk.createEmptyMovieClip("_mochiad_bar", 4);
_local7._x = 10;
_local7._y = _local13 - 20;
var _local22 = options.color;
delete options.color;
var _local19 = options.background;
delete options.background;
var _local24 = options.outline;
delete options.outline;
var _local5 = _local7.createEmptyMovieClip("_outline", 1);
_local5.beginFill(_local19);
_local5.moveTo(0, 0);
_local5.lineTo(_local4 - 20, 0);
_local5.lineTo(_local4 - 20, 10);
_local5.lineTo(0, 10);
_local5.lineTo(0, 0);
_local5.endFill();
var _local3 = _local7.createEmptyMovieClip("_inside", 2);
_local3.beginFill(_local22);
_local3.moveTo(0, 0);
_local3.lineTo(_local4 - 20, 0);
_local3.lineTo(_local4 - 20, 10);
_local3.lineTo(0, 10);
_local3.lineTo(0, 0);
_local3.endFill();
_local3._xscale = 0;
var _local6 = _local7.createEmptyMovieClip("_outline", 3);
_local6.lineStyle(0, _local24, 100);
_local6.moveTo(0, 0);
_local6.lineTo(_local4 - 20, 0);
_local6.lineTo(_local4 - 20, 10);
_local6.lineTo(0, 10);
_local6.lineTo(0, 0);
chk.ad_msec = _local23;
chk.ad_timeout = _local26;
chk.started = getTimer();
chk.showing = false;
chk.last_pcnt = 0;
chk.fadeout_time = fadeout_time;
chk.fadeFunction = function () {
var _local2 = 100 * (1 - ((getTimer() - this.fadeout_start) / this.fadeout_time));
if (_local2 > 0) {
this._parent._alpha = _local2;
} else {
var _local3 = this._parent._parent;
MochiAd.unload(_local3);
delete this.onEnterFrame;
}
};
mc.lc.adLoaded = function (width, height) {
};
mc.lc.adjustProgress = function (msec) {
var _local2 = this.mc._mochiad_wait;
_local2.server_control = true;
_local2.started = getTimer();
_local2.ad_msec = msec;
};
chk.onEnterFrame = function () {
var _local6 = this._parent._parent;
var _local12 = this._parent._mochiad_ctr;
var _local5 = getTimer() - this.started;
var _local3 = false;
var _local4 = _local6.getBytesTotal();
var _local8 = _local6.getBytesLoaded();
var _local10 = (100 * _local8) / _local4;
var _local11 = (100 * _local5) / chk.ad_msec;
var _local9 = this._mochiad_bar._inside;
var _local2 = Math.min(100, Math.min(_local10 || 0, _local11));
_local2 = Math.max(this.last_pcnt, _local2);
this.last_pcnt = _local2;
_local9._xscale = _local2;
if (!chk.showing) {
var _local7 = _local12.getBytesTotal();
if ((_local7 > 0) || (typeof(_local7) == "undefined")) {
chk.showing = true;
chk.started = getTimer();
} else if (_local5 > chk.ad_timeout) {
_local3 = true;
}
}
if (_local5 > chk.ad_msec) {
_local3 = true;
}
if (((_local4 > 0) && (_local8 >= _local4)) && (_local3)) {
if (this.server_control) {
delete this.onEnterFrame;
} else {
this.fadeout_start = getTimer();
this.onEnterFrame = chk.fadeFunction;
}
}
};
}
static function showInterLevelAd(options) {
var _local13 = {clip:_root, ad_timeout:2000, fadeout_time:250, regpt:"o", method:"showTimedAd", ad_started:function () {
this.clip.stop();
}, ad_finished:function () {
this.clip.play();
}};
options = _parseOptions(options, _local13);
var clip = options.clip;
var _local10 = 11000;
var _local12 = options.ad_timeout;
delete options.ad_timeout;
var fadeout_time = options.fadeout_time;
delete options.fadeout_time;
if (!load(options)) {
options.ad_finished();
return(undefined);
}
options.ad_started();
var mc = clip._mochiad;
mc.onUnload = function () {
options.ad_finished();
};
var _local5 = _getRes(options);
var _local14 = _local5[0];
var _local11 = _local5[1];
mc._x = _local14 * 0.5;
mc._y = _local11 * 0.5;
var chk = mc.createEmptyMovieClip("_mochiad_wait", 3);
chk.ad_msec = _local10;
chk.ad_timeout = _local12;
chk.started = getTimer();
chk.showing = false;
chk.fadeout_time = fadeout_time;
chk.fadeFunction = function () {
var _local2 = 100 * (1 - ((getTimer() - this.fadeout_start) / this.fadeout_time));
if (_local2 > 0) {
this._parent._alpha = _local2;
} else {
var _local3 = this._parent._parent;
MochiAd.unload(_local3);
delete this.onEnterFrame;
}
};
mc.lc.adLoaded = function (width, height) {
};
mc.lc.adjustProgress = function (msec) {
var _local2 = this.mc._mochiad_wait;
_local2.server_control = true;
_local2.started = getTimer();
_local2.ad_msec = msec - 250;
};
chk.onEnterFrame = function () {
var _local5 = this._parent._mochiad_ctr;
var _local4 = getTimer() - this.started;
var _local2 = false;
if (!chk.showing) {
var _local3 = _local5.getBytesTotal();
if ((_local3 > 0) || (typeof(_local3) == "undefined")) {
chk.showing = true;
chk.started = getTimer();
} else if (_local4 > chk.ad_timeout) {
_local2 = true;
}
}
if (_local4 > chk.ad_msec) {
_local2 = true;
}
if (_local2) {
if (this.server_control) {
delete this.onEnterFrame;
} else {
this.fadeout_start = getTimer();
this.onEnterFrame = this.fadeFunction;
}
}
};
}
static function showTimedAd(options) {
showInterLevelAd(options);
}
static function showPreloaderAd(options) {
showPreGameAd(options);
}
static function _allowDomains(server) {
var _local1 = server.split("/")[2].split(":")[0];
if (System.security) {
if (System.security.allowDomain) {
System.security.allowDomain("*");
System.security.allowDomain(_local1);
}
if (System.security.allowInsecureDomain) {
System.security.allowInsecureDomain("*");
System.security.allowInsecureDomain(_local1);
}
}
return(_local1);
}
static function _loadCommunicator(options) {
var _local26 = {clip:_root, com_server:"http://x.mochiads.com/com/1/", method:"loadCommunicator", depth:10337, id:"_UNKNOWN_"};
options = _parseOptions(options, _local26);
options.swfv = options.clip.getSWFVersion() || 6;
options.mav = getVersion();
var _local18 = options.clip;
var _local20 = "_mochiad_com_" + options.id;
if (!_isNetworkAvailable()) {
return(null);
}
if (_local18[_local20]) {
return(_local18[_local20].lc);
}
var _local21 = options.com_server + options.id;
_allowDomains(_local21);
delete options.id;
delete options.com_server;
var _local25 = options.depth;
delete options.depth;
var _local17 = _local18.createEmptyMovieClip(_local20, _local25);
var _local11 = _local17.createEmptyMovieClip("_mochiad_com", 1);
for (var _local15 in options) {
_local11[_local15] = options[_local15];
}
var _local6 = new LocalConnection();
var _local16 = ["", Math.floor(new Date().getTime()), random(999999)].join("_");
_local6.mc = _local17;
_local6.name = _local16;
_local6.allowDomain = function (d) {
return(true);
};
_local6.allowInsecureDomain = _local6.allowDomain;
_local6.connect(_local16);
_local17.lc = _local6;
_local11.lc = _local16;
_local6._id = 0;
_local6._queue = [];
_local6.rpcResult = function (cb_arg) {
var _local8 = parseInt(cb_arg);
var _local4 = this._callbacks[_local8];
if (!_local4) {
return(undefined);
}
delete this._callbacks[_local8];
var _local5 = [];
var _local3 = 2;
while (_local3 < _local4.length) {
_local5.push(_local4[_local3]);
_local3++;
}
_local3 = 1;
while (_local3 < arguments.length) {
_local5.push(arguments[_local3]);
_local3++;
}
var _local6 = _local4[1];
var _local7 = _local4[0];
if (_local7 && (typeof(_local6) == "string")) {
_local6 = _local7[_local6];
}
if (_local6) {
_local6.apply(_local7, _local5);
}
};
_local6._didConnect = function (endpoint) {
this._endpoint = endpoint;
var _local4 = this._queue;
delete this._queue;
var _local5 = this.doSend;
var _local2 = 0;
while (_local2 < _local4.length) {
var _local3 = _local4[_local2];
_local5.apply(this, _local3);
_local2++;
}
};
_local6.doSend = function (args, cbobj, cbfn) {
if (this._endpoint == null) {
var _local4 = [];
var _local3 = 0;
while (_local3 < arguments.length) {
_local4.push(arguments[_local3]);
_local3++;
}
this._queue.push(_local4);
return(undefined);
}
this._id = this._id + 1;
var _local5 = this._id;
if ((cbfn === undefined) || (cbfn === null)) {
cbfn = cbobj;
}
this._callbacks[_local5] = [cbobj, cbfn];
var _local7 = new LocalConnection();
var _local9 = _local7.send(this._endpoint, "rpc", _local5, args);
};
_local6._callbacks = {};
_local6._callbacks[0] = [_local6, "_didConnect"];
_local11.st = getTimer();
_local11.loadMovie(_local21 + ".swf", "POST");
return(_local6);
}
static function fetchHighScores(options, callbackObj, callbackMethod) {
var _local1 = _loadCommunicator({id:options.id});
if (!_local1) {
return(false);
}
var _local4 = ["fetchHighScores", options];
_local1.doSend(["fetchHighScores", options], callbackObj, callbackMethod);
return(true);
}
static function sendHighScore(options, callbackObj, callbackMethod) {
var _local1 = _loadCommunicator({id:options.id});
if (!_local1) {
return(false);
}
var _local4 = ["sendHighScore", options];
_local1.doSend(["sendHighScore", options], callbackObj, callbackMethod);
return(true);
}
static function load(options) {
var _local13 = {clip:_root, server:"http://x.mochiads.com/srv/1/", method:"load", depth:10333, id:"_UNKNOWN_"};
options = _parseOptions(options, _local13);
options.swfv = options.clip.getSWFVersion() || 6;
options.mav = getVersion();
var _local9 = options.clip;
if (!_isNetworkAvailable()) {
return(null);
}
if (_local9._mochiad_loaded) {
return(null);
}
var _local12 = options.depth;
delete options.depth;
var _local6 = _local9.createEmptyMovieClip("_mochiad", _local12);
var _local11 = _getRes(options);
options.res = (_local11[0] + "x") + _local11[1];
options.server = options.server + options.id;
delete options.id;
_local9._mochiad_loaded = true;
var _local4 = _local6.createEmptyMovieClip("_mochiad_ctr", 1);
for (var _local7 in options) {
_local4[_local7] = options[_local7];
}
var _local10 = _local4.server;
delete _local4.server;
var _local14 = _allowDomains(_local10);
_local6.onEnterFrame = function () {
if (this._mochiad_ctr._url != this._url) {
this.onEnterFrame = function () {
if (!this._mochiad_ctr) {
delete this.onEnterFrame;
MochiAd.unload(this._parent);
}
};
}
};
var _local5 = new LocalConnection();
var _local8 = ["", Math.floor(new Date().getTime()), random(999999)].join("_");
_local5.mc = _local6;
_local5.name = _local8;
_local5.hostname = _local14;
_local5.allowDomain = function (d) {
return(true);
};
_local5.allowInsecureDomain = _local5.allowDomain;
_local5.connect(_local8);
_local6.lc = _local5;
_local4.lc = _local8;
_local4.st = getTimer();
_local4.loadMovie(_local10 + ".swf", "POST");
return(_local6);
}
static function unload(clip) {
if (typeof(clip) == "undefined") {
clip = _root;
}
if (clip.clip && (clip.clip._mochiad)) {
clip = clip.clip;
}
if (!clip._mochiad) {
return(false);
}
clip._mochiad.removeMovieClip();
delete clip._mochiad_loaded;
delete clip._mochiad;
return(true);
}
static function _isNetworkAvailable() {
if (System.security) {
var _local1 = System.security;
if (_local1.sandboxType == "localWithFile") {
return(false);
}
}
return(true);
}
static function _getRes(options) {
var _local3 = options.clip.getBounds();
var _local2 = 0;
var _local1 = 0;
if (typeof(options.res) != "undefined") {
var _local4 = options.res.split("x");
_local2 = parseFloat(_local4[0]);
_local1 = parseFloat(_local4[1]);
} else {
_local2 = _local3.xMax - _local3.xMin;
_local1 = _local3.yMax - _local3.yMin;
}
if ((_local2 == 0) || (_local1 == 0)) {
_local2 = Stage.width;
_local1 = Stage.height;
}
return([_local2, _local1]);
}
static function _parseOptions(options, defaults) {
var _local4 = {};
for (var _local8 in defaults) {
_local4[_local8] = defaults[_local8];
}
if (options) {
for (var _local8 in options) {
_local4[_local8] = options[_local8];
}
}
if (_root.mochiad_options) {
var _local5 = _root.mochiad_options.split("&");
var _local2 = 0;
while (_local2 < _local5.length) {
var _local3 = _local5[_local2].split("=");
_local4[unescape(_local3[0])] = unescape(_local3[1]);
_local2++;
}
}
return(_local4);
}
}
Symbol 831 MovieClip [__Packages.Global] Frame 0
class Global
{
static var pause, main, game, warningBox, fadeEffect, mainContainer, userMouse;
function Global () {
}
static function runAll() {
var _local2 = runArr.length;
var _local1 = 0;
while (_local1 < _local2) {
if (objArr[_local1][runArr[_local1]] == undefined) {
objArr.splice(_local1, 1);
runArr.splice(_local1, 1);
_local1--;
_local2--;
} else {
objArr[_local1][runArr[_local1]]();
}
_local1++;
}
}
static function gameRunAll() {
if (pause) {
return(undefined);
}
var _local2 = gameRunArr.length;
var _local1 = 0;
while (_local1 < _local2) {
if (gameObjArr[_local1][gameRunArr[_local1]] == undefined) {
gameObjArr.splice(_local1, 1);
gameRunArr.splice(_local1, 1);
_local1--;
_local2--;
} else {
gameObjArr[_local1][gameRunArr[_local1]]();
}
_local1++;
}
_local2 = gameDelayRunArr.length;
_local1 = 0;
while (_local1 < _local2) {
if (gameDelayObjArr[_local1][gameDelayRunArr[_local1][0]] == undefined) {
gameDelayObjArr.splice(_local1, 1);
gameDelayRunArr.splice(_local1, 1);
_local1--;
_local2--;
} else if ((--gameDelayRunArr[_local1][1]) <= 0) {
gameDelayObjArr[_local1][gameDelayRunArr[_local1][0]]();
gameDelayObjArr.splice(_local1, 1);
gameDelayRunArr.splice(_local1, 1);
_local1--;
_local2--;
}
_local1++;
}
}
static function outputAllGameRun() {
var _local2 = gameRunArr.length;
trace("totalGameRun=" + _local2);
var _local1 = 0;
while (_local1 < _local2) {
trace((gameObjArr[_local1]._name + ",") + gameRunArr[_local1]);
_local1++;
}
trace("-----------------------------------------------------------------");
}
static function addRun(obj, runF) {
objArr.push(obj);
runArr.push(runF);
}
static function delRun(obj, runF) {
var _local2 = runArr.length;
var _local1 = 0;
while (_local1 < _local2) {
if ((obj == objArr[_local1]) && (runF == runArr[_local1])) {
objArr.splice(_local1, 1);
runArr.splice(_local1, 1);
return(true);
}
_local1++;
}
return(false);
}
static function addGameRun(obj, runF) {
gameObjArr.push(obj);
gameRunArr.push(runF);
}
static function delGameRun(obj, runF) {
var _local2 = gameRunArr.length;
var _local1 = 0;
while (_local1 < _local2) {
if ((obj == gameObjArr[_local1]) && (runF == gameRunArr[_local1])) {
gameObjArr.splice(_local1, 1);
gameRunArr.splice(_local1, 1);
return(true);
}
_local1++;
}
return(false);
}
static function addGameDelayRun(obj, runF, delayTime) {
gameDelayObjArr.push(obj);
gameDelayRunArr.push([runF, delayTime]);
}
static function delGameDelayRun(obj, runF) {
var _local2 = gameDelayRunArr.length;
var _local1 = 0;
while (_local1 < _local2) {
if ((obj == gameDelayObjArr[_local1]) && (runF == gameDelayRunArr[_local1][0])) {
gameDelayObjArr.splice(_local1, 1);
gameDelayRunArr.splice(_local1, 1);
return(true);
}
_local1++;
}
return(false);
}
static function addMc(mc) {
mcArr.push(mc);
}
static function delMc(mc) {
if (Common.arrDel(mcArr, mc) == -1) {
trace(("mc: " + mc) + " \u4E0D\u5B58\u5728\u6216\u5DF2\u7ECF\u88AB\u5220\u9664");
}
}
static function outputMcs() {
trace((("\u5171" + mcArr.length) + "\u4E2AMc,") + mcArr);
trace("-----------------------------------");
}
static function addBmd(bmd) {
bmdArr.push(bmd);
return(bmd);
}
static function delBmd(bmd) {
if (Common.arrDel(bmdArr, bmd) == -1) {
trace(("bmd: " + bmd) + " \u4E0D\u5B58\u5728\u6216\u5DF2\u7ECF\u88AB\u5220\u9664");
}
}
static function outputBmds() {
trace(("\u5171" + bmdArr.length) + "\u4E2ABmd");
trace("-----------------------------------");
}
static function outputAll() {
trace("main=" + main);
trace("game=" + game);
trace("warningBox=" + warningBox);
trace("fadeEffect=" + fadeEffect);
trace("mainContainer=" + mainContainer);
trace("userMouse=" + userMouse);
trace("pause=" + pause);
trace("gameInterface:");
for (var _local1 in gameInterface) {
trace((_local1 + "=") + gameInterface[_local1]);
}
trace(("\u5171" + objArr.length) + "\u4E2Aobj");
trace(objArr);
trace(runArr);
trace(("\u5171" + gameObjArr.length) + "\u4E2AgameObj");
trace(gameObjArr);
trace(gameRunArr);
outputMcs();
outputBmds();
}
static var gameInterface = new Object();
static var objArr = new Array();
static var runArr = new Array();
static var gameObjArr = new Array();
static var gameRunArr = new Array();
static var gameDelayObjArr = new Array();
static var gameDelayRunArr = new Array();
static var mcArr = new Array();
static var bmdArr = new Array();
var initF = (_root.onEnterFrame = function () {
runAll();
gameRunAll();
});
}
Symbol 832 MovieClip [__Packages.basic.Mc] Frame 0
class basic.Mc extends MovieClip
{
var swapDepths, _parent, removeMovieClip;
function Mc () {
super();
}
function remove() {
swapDepths(_parent.getNextHighestDepth());
removeMovieClip();
}
}
Symbol 833 MovieClip [__Packages.FWG.BasicMain] Frame 0
class FWG.BasicMain extends basic.Mc
{
var _parent, gameName, playerInfo, isFirstPlay, sndBg, stageData, pageId, targetMoney, dTargetMoney, qualitySetting, musicCredits, snd_mc, __musicOn, __soundOn, delayMc, delayFrameId;
function BasicMain (_gameName, _stageWid, _stageHei) {
super();
Global.main = this;
_parent.stop();
gameName = _gameName;
playerInfo = new FWG.PlayerInfo();
isFirstPlay = true;
currentScore = (0);
score = (0);
stageNum = (1);
Global.fadeEffect.hide();
sndBg = new Sound();
sndBg.attachSound("SndBg");
musicOn = (true);
soundOn = (true);
Global.fadeEffect.fadeShow();
stageData = new FWG.StageData(["currentScore", "score", "stageNum"]);
Common.cSetTimeout(this, "addPageMenu", 100);
}
function addPageMenu() {
fadeTo("FWG.PageMenu");
}
function restartStage() {
stageData.restartStage();
score = (0);
trace("\u65E5\u540E\u89E3\u51B3");
}
function resetStageData() {
__currentScore = 0;
}
function resetGameData() {
stageData.resetGameData();
}
function startNewStage() {
resetStageData();
stageData.update();
}
function instPlay() {
if (isFirstPlay) {
showInst();
} else {
playGame();
}
}
function initBtn(btn) {
switch (btn.__get__label()) {
case "Play Game" :
btn._press = function () {
Global.main.instPlay();
};
break;
case "Play" :
case "Skip" :
btn._press = function () {
Global.main.instPlay();
};
break;
case "Start New Game" :
btn._press = function () {
Global.main.instPlay();
};
break;
case "Next Stage" :
btn._press = function () {
Global.main.nextStage();
};
break;
case "Play Again" :
btn._press = function () {
Global.main.playAgain();
};
break;
case "Instructions" :
btn._press = function () {
Global.main.showInst();
};
break;
case "Key Settings" :
btn._press = function () {
Global.main.fadeTo("FWG.PageKeySetting");
};
break;
case "View Highscores" :
btn._press = function () {
this.getURL("http://www.freeworldgroup.com/score/index.asp?game=" + Global.main.gameName, "_blank");
};
break;
case "Download Games" :
btn._press = function () {
this.getURL("http://www.ifungames.com", "_blank");
};
break;
case "More Online Games" :
btn._press = function () {
this.getURL("http://www.freeworldgroup.com", "_blank");
};
break;
case "Add Games to Your Site" :
btn._press = function () {
this.getURL("http://www.freeworldgroup.com/koalafiles.htm", "_blank");
};
break;
case "Copyright 2007 freeworldgroup.com" :
btn._press = function () {
this.getURL("http://www.freeworldgroup.com", "_blank");
};
break;
case "Credits" :
btn._press = function () {
Global.main.showCredits();
};
break;
case "Menu" :
btn._press = function () {
ui.Alt.hide();
Global.main.gotoMenu();
};
break;
case "Submit Score" :
btn._press = function () {
trace("score=" + Global.main.__get__score());
if (Global.main.__get__score() <= 0) {
ui.Alt.show("Your score is 0 !");
ui.Alt.hideDelay(2000);
} else {
Global.main.showSubmitScore();
}
};
}
}
function addScore(dScore) {
currentScore = currentScore + dScore;
score = score + dScore;
}
function get currentScore() {
return(__currentScore);
}
function set currentScore(_currentScore) {
__currentScore = _currentScore;
//return(currentScore);
}
function get score() {
return(__score);
}
function set score(_score) {
__score = _score;
//return(score);
}
function get stageNum() {
return(__stageNum);
}
function set stageNum(_stageNum) {
__stageNum = _stageNum;
//return(stageNum);
}
function fadeTo(_pageId, onFadeShow) {
pageId = _pageId;
Global.fadeEffect.fadeHide();
if (!onFadeShow) {
Global.fadeEffect.onShow = function () {
};
} else {
Global.fadeEffect.onShow = onFadeShow;
}
Global.fadeEffect.onHide = function () {
Global.mainContainer.putIn(Global.main.pageId);
Global.fadeEffect.fadeShow();
Global.fadeEffect.onHide = function () {
};
};
}
function flipTo(_pageId) {
Global.fadeEffect.flip();
Global.mainContainer.putIn(new _pageId[undefined]());
}
function playGame() {
score = (0);
currentScore = (0);
targetMoney = (dTargetMoney = 300);
trace("target\u672A\u5904\u7406");
fadeTo("FWG.PageOptions");
}
function showQualitySetting() {
Global.pause = true;
qualitySetting.fadeShow();
qualitySetting.onHide = function () {
Global.pause = false;
};
}
function showCredits() {
musicCredits.fadeShow();
}
function hideCredits() {
musicCredits.fadeHide();
}
function showSubmitScore() {
FWG.SubmitScore.show();
}
function showInst() {
fadeTo("FWG.PageInst");
}
function playSound(soundId) {
if (soundOn) {
var _local2 = snd_mc[soundId];
if (snd_mc[soundId] == undefined) {
var _local4 = snd_mc.getNextHighestDepth();
_local2 = (snd_mc[soundId] = new Sound(snd_mc.createEmptyMovieClip("mc" + _local4, _local4)));
_local2.attachSound(soundId);
}
_local2.start();
}
}
function get musicOn() {
return(__musicOn);
}
function set musicOn(_musicOn) {
__musicOn = _musicOn;
if (__musicOn) {
sndBg.start(0, 10000);
} else {
sndBg.stop();
}
//return(musicOn);
}
function get soundOn() {
return(__soundOn);
}
function set soundOn(_soundOn) {
__soundOn = _soundOn;
//return(soundOn);
}
function gotoMenu() {
trace("Alert.showAlert=" + ui.Alert.__get__showAlert());
Global.pause = true;
if (ui.Alert.__get__showAlert()) {
ui.Alert.show("Back To Main Menu?", gotoMenuHandler);
} else {
gotoMenuHandler(true);
}
}
function gotoMenuHandler(value) {
if (value) {
Global.main.resetGameData();
Global.main.fadeTo("FWG.PageMenu");
} else {
Global.pause = false;
}
}
function delayGoto(_delayMc, _delayFrameId) {
delayMc = _delayMc;
delayFrameId = _delayFrameId;
Global.addRun(this, "goto");
}
function goto() {
Global.delRun(this, "goto");
delayMc.gotoAndStop(delayFrameId);
delayMc = null;
delayFrameId = null;
}
function stageClear() {
trace("stageClear");
stageData.update();
fadeTo("FWG.PageStageClear");
}
function win() {
fadeTo("FWG.PageWin");
}
function lose() {
fadeTo("FWG.PageGameOver");
}
function fadeToPageGame() {
fadeTo("FWG.PageGame");
}
function nextStage() {
stageNum = ((stageNum+1));
stageData.update();
stageData.initByObj();
fadeToPageGame();
}
function playAgain() {
stageData.resetGameData();
playGame();
}
var __currentScore = 0;
var __score = 0;
var __stageNum = 1;
}
Symbol 834 MovieClip [__Packages.basic.Obj] Frame 0
class basic.Obj
{
function Obj () {
}
function clear() {
}
}
Symbol 835 MovieClip [__Packages.FWG.LocalSetting] Frame 0
class FWG.LocalSetting extends basic.Obj
{
var lso, dataObj;
function LocalSetting (saveName) {
super();
lso = SharedObject.getLocal(saveName + "_as2", "/");
if (lso.data.dataObj) {
dataObj = Common.cloneObj(lso.data.dataObj);
} else {
trace(saveName + " \u7B2C\u4E00\u6B21\u8BBE\u5B9A");
lso.data.defaultDataObj = Common.cloneObj(dataObj);
}
lso.data.dataObj = dataObj;
}
function clear() {
super.clear();
lso = null;
}
function getDefault() {
return(lso.data.defaultDataObj);
}
function setDefault() {
dataObj = Common.cloneObj(lso.data.defaultDataObj);
}
function flush() {
lso.flush();
}
}
Symbol 836 MovieClip [__Packages.Common] Frame 0
class Common
{
static var tempArr;
function Common () {
}
static function setRGB(mc, color) {
new Color(mc).setRGB(color);
}
static function setRGBOffset(mc, color, modeNum) {
trace("Common.setRGBOffset \u672A\u6D4B\u8BD5");
if (isNaN(modeNum)) {
modeNum = 1;
}
var _local1 = mc.transform.colorTransform;
_local1.redOffset = ((color >> 16) & 255) - (255 * modeNum);
_local1.greenOffset = ((color >> 8) & 255) - (255 * modeNum);
_local1.blueOffset = (color & 255) - (255 * modeNum);
mc.transform.colorTransform = _local1;
}
static function disorder(arr) {
trace("Common.disorder \u672A\u6D4B\u8BD5");
var _local5 = arr.length;
var _local1 = 0;
while (_local1 < _local5) {
var _local3 = random(_local5);
var _local4 = arr[_local1];
arr[_local1] = arr[_local3];
arr[_local3] = _local4;
_local1++;
}
}
static function arrDel(arr, item) {
var _local3 = arr.length;
var _local1 = 0;
while (_local1 < _local3) {
if (arr[_local1] == item) {
arr.splice(_local1, 1);
return(_local1);
}
_local1++;
}
return(-1);
}
static function forEach(arr, f) {
var _local3 = arr.length;
var _local1 = 0;
while (_local1 < _local3) {
f(arr[_local1], _local1, arr);
_local1++;
}
}
static function getSum(numArr) {
trace("Common.getSum \u672A\u6D4B\u8BD5");
var totalValue = 0;
forEach(numArr, function (value) {
totalValue = totalValue + value;
});
return(totalValue);
}
static function getChildAt(mc, index) {
var _local2 = 0;
for (var _local4 in mc) {
var _local1 = mc[_local4];
if ((_local1 instanceof MovieClip) && (_local2 == index)) {
return(_local1);
}
_local2++;
}
return(null);
}
static function getNumChildren(mc) {
var _local2 = 0;
for (var _local3 in mc) {
if (mc[_local3] instanceof MovieClip) {
_local2++;
}
}
return(_local2);
}
static function randomStop(mc, totalFs) {
if (isNaN(totalFs)) {
totalFs = mc._totalframes;
}
mc.gotoAndStop(random(totalFs) + 1);
}
static function getAllChildren(mc, recursion, notClearTempArr) {
if (recursion && (!notClearTempArr)) {
tempArr = new Array();
}
var _local2 = new Array();
for (var _local5 in mc) {
var _local1 = mc[_local5];
if ((_local1 instanceof MovieClip) && (!isInTempArr(_local1))) {
tempArr.push(_local1);
_local2.push(_local1);
if (recursion) {
_local2 = _local2.concat(getAllChildren(_local1, true, true));
}
}
}
return(_local2);
}
static function isInTempArr(value) {
var _local2 = tempArr.length;
var _local1 = 0;
while (_local1 < _local2) {
if (tempArr[_local1] == value) {
return(true);
}
_local1++;
}
return(false);
}
static function getAllChildrenByOrder(mc, varName, recursion) {
trace("Common.getAllChildrenByOrder \u672A\u6D4B\u8BD5");
var _local1 = getAllChildren(mc, recursion);
_local1.sortOn(varName, Array.NUMERIC);
return(_local1);
}
static function cSetTimeout(objectReference, methodName, timeout) {
return(setTimeout(objectReference, methodName, timeout));
}
static function cClearTimeout(timeoutId) {
clearTimeout(timeoutId);
}
static function randomLine(mc, x1, y1, x2, y2, d) {
trace("Common.randomLine \u672A\u6D4B\u8BD5");
var _local2 = new flash.geom.Point(x2 - x1, y2 - y1);
var _local8 = _local2.length;
var _local4 = Math.round(_local8 / d);
_local2.x = _local2.x / _local4;
_local2.y = _local2.y / _local4;
mc.moveTo(x1, y1);
var _local1 = 1;
while (_local1 < _local4) {
mc.lineTo((x1 + (_local2.x * _local1)) + ((Math.random() - 0.5) * d), (y1 + (_local2.y * _local1)) + ((Math.random() - 0.5) * d));
_local1++;
}
mc.lineTo(x2, y2);
}
static function selectTxt(txt) {
Selection.setFocus(txt);
Selection.setSelection(0, txt.text.length);
}
static function cloneObj(obj, varName, depth) {
if (isNaN(depth)) {
depth = 0;
}
if (varName == undefined) {
varName = "";
}
var _local5 = getObjType(obj);
switch (_local5) {
case "Array" :
return(obj.slice());
case "Object" :
var _local2 = new Object();
for (varName in obj) {
_local2[varName] = cloneObj(obj[varName], varName, depth + 1);
}
return(_local2);
}
return(obj);
}
static function getObjType(obj) {
switch (obj.constructor) {
case Boolean :
return("Boolean");
case Number :
return("Number");
case String :
return("String");
case Array :
return("Array");
}
return("Object");
}
static function objToStr(obj, depth) {
if (isNaN(depth)) {
depth = 0;
}
var _local3 = obj + newline;
for (var _local4 in obj) {
_local3 = _local3 + ((((((getSpaces(depth) + "|-") + getObjType(obj[_local4])) + ":") + _local4) + " -- ") + objToStr(obj[_local4], depth + 1));
}
return(_local3);
}
static function getSpaces(total) {
var _local2 = "";
var _local1 = 0;
while (_local1 < total) {
_local2 = _local2 + " ";
_local1++;
}
return(_local2);
}
static function drawRect() {
var _local3 = arguments[0];
var _local2 = arguments[1];
var _local4;
var _local5;
var _local6;
var _local7;
switch (_local2.constructor) {
case flash.geom.Rectangle :
_local4 = _local2.x;
_local5 = _local2.y;
_local6 = _local2.x + _local2.width;
_local7 = _local2.y + _local2.height;
break;
case Number :
_local4 = _local2;
_local5 = arguments[2];
_local6 = arguments[3];
_local7 = arguments[4];
break;
default :
_local4 = _local2.xMin;
_local5 = _local2.yMin;
_local6 = _local2.xMax;
_local7 = _local2.yMax;
}
_local3.moveTo(_local4, _local5);
_local3.lineTo(_local6, _local5);
_local3.lineTo(_local6, _local7);
_local3.lineTo(_local4, _local7);
_local3.lineTo(_local4, _local5);
}
static var a2r = 57.2957795130823;
static var p0 = new flash.geom.Point();
static var bf = new flash.filters.BlurFilter();
static var cf = new flash.filters.ConvolutionFilter(3, 3, [1, 1, 1, 1, 30, 1, 1, 1, 1], 38);
}
Symbol 837 MovieClip [__Packages.FWG.PlayerInfo] Frame 0
class FWG.PlayerInfo extends FWG.LocalSetting
{
function PlayerInfo () {
super("FWGPlayerInfo");
}
static var DEFAULT_PLAYERNAME = "MrNoName";
var dataObj = {playerName:DEFAULT_PLAYERNAME};
}
Symbol 838 MovieClip [__Packages.ui.SBtn] Frame 0
class ui.SBtn extends basic.Mc
{
var useHandCursor, filters0, filters, greyFilters, __selectAble, rollOver, rollOut, press, release, enabled, __errorPress;
function SBtn () {
super();
useHandCursor = true;
filters0 = filters.slice();
greyFilters = filters.concat([greyFilter]);
__selectAble = true;
}
function remove() {
super.remove();
errorPress = (null);
filters0 = null;
greyFilters = null;
rollOver = null;
rollOut = null;
press = null;
release = null;
}
function onRollOver() {
if (selectAble) {
if (Global.userMouse != null) {
Global.userMouse.rollOver();
}
rollOver();
}
}
function onRollOut() {
if (selectAble) {
if (Global.userMouse != null) {
Global.userMouse.rollOut();
}
rollOut();
}
}
function onPress() {
if (selectAble) {
press();
} else if (errorPress) {
errorPress();
}
}
function onRelease() {
if (selectAble) {
release();
}
}
function get selectAble() {
return(__selectAble);
}
function set selectAble(_selectAble) {
__selectAble = _selectAble;
if (__selectAble) {
enabled = true;
useHandCursor = true;
filters = filters0;
} else {
if (!errorPress) {
enabled = false;
}
useHandCursor = false;
}
//return(selectAble);
}
function get errorPress() {
return(__errorPress);
}
function set errorPress(_errorPress) {
__errorPress = _errorPress;
enabled = true;
//return(errorPress);
}
static var greyFilter = new flash.filters.ColorMatrixFilter([0.15, 0.295, 0.055, 0, 0, 0.15, 0.295, 0.055, 0, 0, 0.15, 0.295, 0.055, 0, 0, 0, 0, 0, 1, 0]);
}
Symbol 839 MovieClip [__Packages.FWG.Btn] Frame 0
class FWG.Btn extends ui.SBtn
{
var clear, beginFill, getBounds, selectedFilters, filters, unselectedFilters, rollOverFilters, rollOutFilters, __label, __selected, enabled, __get__selectAble, _press, __get__errorPress, _alpha;
function Btn () {
super();
clear();
beginFill(16711680, 0);
Common.drawRect(this, getBounds(this));
selectedFilters = [yellowGlowFilter].concat(filters);
unselectedFilters = filters.slice();
rollOverFilters = [redGlowFilter].concat(filters);
rollOutFilters = filters.slice();
}
function remove() {
super.remove();
selectedFilters = null;
unselectedFilters = null;
rollOverFilters = null;
rollOutFilters = null;
}
function get label() {
return(__label);
}
function set label(_label) {
__label = _label;
Global.main.initBtn(this);
//return(label);
}
function get selected() {
return(__selected);
}
function set selected(_selected) {
__selected = _selected;
if (__selected) {
enabled = false;
filters = selectedFilters;
rollOverEffect();
} else {
enabled = true;
filters = unselectedFilters;
rollOutEffect();
}
//return(selected);
}
function rollOver() {
if (selected) {
return(undefined);
}
if (__get__selectAble()) {
rollOverEffect();
super.rollOver(null);
}
}
function rollOut() {
if (selected) {
return(undefined);
}
if (__get__selectAble()) {
rollOutEffect();
super.rollOut(null);
}
}
function press() {
if (selected) {
return(undefined);
}
if (__get__selectAble()) {
Global.main.playSound("SndPress", this);
rollOutEffect();
super.press(null);
_press();
} else if (__get__errorPress()) {
__get__errorPress()();
}
}
function release() {
if (selected) {
return(undefined);
}
if (__get__selectAble()) {
super.release(null);
}
}
function rollOverEffect() {
_alpha = 80;
filters = rollOverFilters;
}
function rollOutEffect() {
_alpha = 100;
filters = rollOutFilters;
}
static var redGlowFilter = new flash.filters.GlowFilter(16711680);
static var yellowGlowFilter = new flash.filters.GlowFilter(16776960);
}
Symbol 840 MovieClip [__Packages.FWG.BtnSs] Frame 0
class FWG.BtnSs extends FWG.Btn
{
var __set__label;
function BtnSs () {
super();
__set__label("Submit Score");
Global.main.btnSs = this;
}
function remove() {
Global.main.btnSs = null;
super.remove();
}
}
Symbol 841 MovieClip [__Packages.FWG.StageData] Frame 0
class FWG.StageData extends basic.Obj
{
var varNameList, dataObj0, prevDataObj, dataObj;
function StageData (_varNameList) {
super();
trace("stageData\u521D\u59CB\u5316");
varNameList = _varNameList;
dataObj0 = new Object();
prevDataObj = new Object();
dataObj = new Object();
allCopyMain();
}
function clear() {
super.clear();
varNameList = null;
dataObj0 = null;
prevDataObj = null;
dataObj = null;
}
function addVars(_varNameList) {
trace("stageData\u6DFB\u52A0\u9879");
allCopyMain(_varNameList);
varNameList = varNameList.concat(_varNameList);
traceDataObj();
}
function allCopyMain(_varNameList) {
copyMain(dataObj0, _varNameList);
copyMain(prevDataObj, _varNameList);
copyMain(dataObj, _varNameList);
}
function updatePrevDataObj() {
copyMain(prevDataObj);
}
function copyMain(obj, _varNameList) {
if (!_varNameList) {
_varNameList = varNameList;
}
var _local5 = _varNameList.length;
var _local2 = 0;
while (_local2 < _local5) {
var _local3 = _varNameList[_local2];
obj[_local3] = Common.cloneObj(Global.main[_local3], _local3);
_local2++;
}
}
function initByObj(obj) {
if (!obj) {
obj = dataObj;
}
}
function update() {
trace("stageData\u5B58\u50A8\u6E38\u620F\u6570\u636E");
copyMain(prevDataObj);
copyMain(dataObj);
traceDataObj();
}
function restartStage() {
trace("stageData\u91CD\u8BBE\u4E3A\u4E0A\u4E00\u5173\u6570\u636E");
initByObj(prevDataObj);
traceDataObj();
}
function resetGameData() {
trace("stageData\u91CD\u8BBE\u4E3A\u6E38\u620F\u5F00\u59CB\u65F6\u7684\u6570\u636E");
initByObj(dataObj0);
traceDataObj();
}
function traceDataObj() {
trace(("stagedata.dataObj=" + Common.objToStr(dataObj)) + "\n--------------------------------------");
}
}
Symbol 842 MovieClip [__Packages.FWG.AlphaFadeSp] Frame 0
class FWG.AlphaFadeSp extends basic.Mc
{
var onShow, onHide, _visible, _alpha;
function AlphaFadeSp () {
super();
onShow = function () {
};
onHide = function () {
};
}
function remove() {
Global.delRun(this, "hideRun");
Global.delRun(this, "showRun");
super.remove();
onShow = null;
onHide = null;
}
function show() {
_visible = true;
_alpha = 100;
}
function hide() {
_visible = false;
_alpha = 0;
}
function fadeShow() {
_visible = true;
Global.delRun(this, "showRun");
Global.addRun(this, "showRun");
}
function fadeHide() {
Global.delRun(this, "hideRun");
Global.addRun(this, "hideRun");
}
function showRun() {
if (((_alpha = _alpha + 20)) > 90) {
Global.delRun(this, "showRun");
show();
onShow();
}
}
function hideRun() {
if (_alpha <= 10) {
_alpha = 0;
Global.delRun(this, "hideRun");
hide();
onHide();
return(undefined);
}
_alpha = _alpha - 20;
}
}
Symbol 843 MovieClip [__Packages.FWG.MusicCredits] Frame 0
class FWG.MusicCredits extends FWG.AlphaFadeSp
{
var hide, btnBack;
function MusicCredits () {
super();
Global.main.musicCredits = this;
hide();
btnBack._press = function () {
Global.main.hideCredits();
};
}
function remove() {
super.remove();
Global.main.musicCredits = null;
}
}
Symbol 844 MovieClip [__Packages.ui.Alt] Frame 0
class ui.Alt extends basic.Mc
{
static var alt;
var msgTxt, _visible, enabled, bg, _x, _parent, _y;
function Alt () {
super();
alt = this;
msgTxt.autoSize = "center";
_visible = false;
enabled = false;
}
static function show(_msg, x, y) {
alt.show_(_msg, x, y);
}
static function hide() {
alt.hide_();
}
function show_(_msg, x, y) {
_visible = true;
msg = (_msg);
bg._width = msgTxt._width + 10;
if (isNaN(x)) {
_x = _parent._xmouse;
} else {
_x = x;
}
if (isNaN(y)) {
_y = _parent._ymouse;
} else {
_y = y;
}
var _local3 = bg.getBounds(_root);
_local3.x = _local3.xMin;
_local3.y = _local3.yMin;
_local3.width = _local3.xMax - _local3.xMin;
_local3.height = _local3.yMax - _local3.yMin;
if (_local3.x < 0) {
_x = (_local3.width / 2) + 5;
} else if ((_local3.x + _local3.width) > Global.main.stageWid) {
_x = (Global.main.stageWid - (_local3.width / 2)) - 5;
}
if (_local3.y < 0) {
_y = (_local3.height / 2) + 5;
} else if ((_local3.y + _local3.height) > Global.main.stageHei) {
_y = (Global.main.stageHei - (_local3.height / 2)) - 5;
}
}
function hide_() {
_visible = false;
}
static function hideDelay(delayTime) {
Common.cClearTimeout(timeoutId);
timeoutId = Common.cSetTimeout(alt, "hide_", delayTime);
}
function set msg(_msg) {
msgTxt.text = _msg;
//return(msg);
}
function get msg() {
return(msgTxt.text);
}
static var timeoutId = -1;
}
Symbol 845 MovieClip [__Packages.FWG.SubmitScore] Frame 0
class FWG.SubmitScore extends basic.Mc
{
static var submitScore;
var stop, _visible, btnSubmit, btnX, send_var, nameTxt, localToGlobal, scoreTxt, gotoAndStop;
function SubmitScore () {
super();
stop();
_visible = false;
submitScore = this;
btnSubmit._press = function () {
FWG.SubmitScore.submitScore.checkSubmit();
};
btnX._press = function () {
FWG.SubmitScore.hide();
};
}
function remove() {
super.remove();
send_var = null;
submitScore = null;
}
function checkSubmit() {
var _local2 = new flash.geom.Point(nameTxt.x, nameTxt.y);
localToGlobal(_local2);
Common.selectTxt(nameTxt);
switch (nameTxt.text) {
case "" :
case FWG.PlayerInfo.DEFAULT_PLAYERNAME :
ui.Alt.show("Your Name, please", _local2.x + 50, _local2.y - 30);
ui.Alt.hideDelay(2000);
return(undefined);
}
submit();
}
function init() {
nameTxt.text = Global.main.playerInfo.dataObj.playerName;
scoreTxt.text = String(Global.main.__get__score());
Common.selectTxt(nameTxt);
trace((("playerName=" + nameTxt.text) + ",score=") + scoreTxt.text);
send_var = new LoadVars();
send_var.game = Global.main.gameName;
}
function hideAlt() {
ui.Alt.hide();
}
static function show() {
submitScore._show();
}
function _show() {
_visible = true;
init();
}
static function hide() {
submitScore._hide();
}
function _hide() {
_visible = false;
gotoAndStop(1);
send_var = null;
}
function submit() {
send_var.score = scoreTxt.text;
send_var.name = nameTxt.text;
if (send_var.name == "") {
send_var.name = "guest" + random(1000);
}
Global.main.playerInfo.dataObj.playerName = send_var.name;
var _local2 = new LoadVars();
_local2.onLoad = function () {
FWG.SubmitScore.submitScore.gotoAndStop(3);
};
send_var.sendAndLoad("http://www.freeworldgroup.com/score/score.asp", _local2, "POST");
gotoAndStop(2);
Global.main.btnSs._visible = false;
}
}
Symbol 846 MovieClip [__Packages.ui.Alert] Frame 0
class ui.Alert extends FWG.AlphaFadeSp
{
static var alert;
var btnYes, btnNo, onCallBack, msgTxt;
function Alert () {
super();
alert = this;
alert.hide();
btnYes._press = function () {
ui.Alert.callBack(true);
};
btnNo._press = function () {
ui.Alert.callBack(false);
};
}
function remove() {
super.remove();
if (alert == this) {
alert = null;
}
onCallBack = null;
}
static function show(_msg, _onCallBack) {
if (alert) {
alert.__set__msg(_msg);
alert.onCallBack = _onCallBack;
alert.fadeShow();
} else {
_onCallBack(true);
}
}
function set msg(_msg) {
msgTxt.text = _msg;
//return(msg);
}
function get msg() {
return(msgTxt.text);
}
static function callBack(_flag) {
alert.flag = _flag;
alert.fadeHide();
alert.onHide = function () {
this.onCallBack(this.flag);
};
}
static function get showAlert() {
trace("alert=" + alert);
return(alert._name != undefined);
}
}
Symbol 847 MovieClip [__Packages.FWG.Main] Frame 0
class FWG.Main extends FWG.BasicMain
{
var targetMoney, dTargetMoney, stageData, __get__score, lose, __set__score, __set__currentScore;
function Main () {
super("topchef", 800, 600);
targetMoney = (dTargetMoney = firstTarget);
stageData.addVars(["targetMoney", "dTargetMoney"]);
}
function addScore(dScore) {
super.addScore(dScore);
var _local2 = Global.game._parent;
_local2.scoreTxt.text = Global.main.score;
}
function stageClear() {
dTargetMoney = dTargetMoney + 100;
targetMoney = __get__score() + dTargetMoney;
super.stageClear();
}
function stageClearOrLose() {
if (__get__score() >= targetMoney) {
stageClear();
} else {
lose();
}
}
function playAgain() {
super.playAgain();
__set__score(0);
__set__currentScore(0);
targetMoney = (dTargetMoney = firstTarget);
}
static var firstTarget = 300;
}
Symbol 848 MovieClip [__Packages.FWG.WarningBox] Frame 0
class FWG.WarningBox extends basic.Mc
{
var stop, _visible, onHide, gotoAndPlay;
function WarningBox () {
super();
Global.warningBox = this;
stop();
_visible = false;
}
function remove() {
Global.warningBox = null;
onHide = null;
super.remove();
}
function show() {
_visible = true;
gotoAndPlay("show");
}
function hide() {
gotoAndPlay("hide");
}
}
Symbol 849 MovieClip [__Packages.TestBmd] Frame 0
class TestBmd extends flash.display.BitmapData
{
function TestBmd (width, height, transparent, fillColor) {
super(width, height, transparent, fillColor);
Global.addBmd(this);
}
function dispose() {
Global.delBmd(this);
super.dispose();
}
}
Symbol 850 MovieClip [__Packages.FWG.BtnM] Frame 0
class FWG.BtnM extends FWG.Btn
{
var redCircle;
function BtnM () {
super();
redCircle._visible = false;
}
}
Symbol 851 MovieClip [__Packages.FWG._3Btn] Frame 0
class FWG._3Btn extends basic.Mc
{
var btnQ, btnM, btnS;
function _3Btn () {
super();
btnQ.rollOver = function () {
ui.Alt.show("Quality");
};
btnQ._press = function () {
Global.main.showQualitySetting();
ui.Alt.hide();
};
btnQ.rollOut = function () {
ui.Alt.hide();
};
btnM.rollOver = function () {
if (Global.main.__get__musicOn()) {
ui.Alt.show("Music Off");
} else {
ui.Alt.show("Music On");
}
};
btnM._press = function () {
if (Global.main.__get__musicOn()) {
Global.main.__set__musicOn(false);
this.redCircle._visible = true;
} else {
Global.main.__set__musicOn(true);
this.redCircle._visible = false;
}
ui.Alt.hide();
};
btnM.rollOut = function () {
ui.Alt.hide();
};
if (Global.main.__get__musicOn()) {
btnM.redCircle._visible = false;
} else {
btnM.redCircle._visible = true;
}
btnS.rollOver = function () {
if (Global.main.__get__soundOn()) {
ui.Alt.show("Sound Off");
} else {
ui.Alt.show("Sound On");
}
};
btnS._press = function () {
if (Global.main.__get__soundOn()) {
Global.main.__set__soundOn(false);
this.redCircle._visible = true;
} else {
Global.main.__set__soundOn(true);
this.redCircle._visible = false;
}
ui.Alt.hide();
};
btnS.rollOut = function () {
ui.Alt.hide();
};
if (Global.main.__get__soundOn()) {
btnS.redCircle._visible = false;
} else {
btnS.redCircle._visible = true;
}
}
}
Symbol 852 MovieClip [__Packages.FWG.BtnAgtys] Frame 0
class FWG.BtnAgtys extends FWG.Btn
{
var __set__label;
function BtnAgtys () {
super();
__set__label("Add Games to Your Site");
}
}
Symbol 853 MovieClip [__Packages.FWG.BtnCopyright] Frame 0
class FWG.BtnCopyright extends FWG.Btn
{
var __set__label;
function BtnCopyright () {
super();
__set__label("Copyright 2007 freeworldgroup.com");
}
}
Symbol 854 MovieClip [__Packages.FWG.BtnCredits] Frame 0
class FWG.BtnCredits extends FWG.Btn
{
var __set__label;
function BtnCredits () {
super();
__set__label("Credits");
}
}
Symbol 855 MovieClip [__Packages.FWG.BtnDg] Frame 0
class FWG.BtnDg extends FWG.Btn
{
var __set__label;
function BtnDg () {
super();
__set__label("Download Games");
}
}
Symbol 856 MovieClip [__Packages.FWG.BtnInstructions] Frame 0
class FWG.BtnInstructions extends FWG.Btn
{
var __set__label;
function BtnInstructions () {
super();
__set__label("Instructions");
}
}
Symbol 857 MovieClip [__Packages.FWG.BtnMenu] Frame 0
class FWG.BtnMenu extends FWG.Btn
{
var __set__label;
function BtnMenu () {
super();
__set__label("Menu");
}
}
Symbol 858 MovieClip [__Packages.FWG.BtnMog] Frame 0
class FWG.BtnMog extends FWG.Btn
{
var __set__label;
function BtnMog () {
super();
__set__label("More Online Games");
}
}
Symbol 859 MovieClip [__Packages.FWG.BtnPa] Frame 0
class FWG.BtnPa extends FWG.Btn
{
var __set__label;
function BtnPa () {
super();
__set__label("Play Again");
}
}
Symbol 860 MovieClip [__Packages.FWG.BtnPg] Frame 0
class FWG.BtnPg extends FWG.Btn
{
var __set__label;
function BtnPg () {
super();
__set__label("Play Game");
}
}
Symbol 861 MovieClip [__Packages.FWG.BtnPlay] Frame 0
class FWG.BtnPlay extends FWG.Btn
{
var __set__label;
function BtnPlay () {
super();
__set__label("Play");
}
}
Symbol 862 MovieClip [__Packages.FWG.BtnVh] Frame 0
class FWG.BtnVh extends FWG.Btn
{
var __set__label;
function BtnVh () {
super();
__set__label("View Highscores");
}
}
Symbol 863 MovieClip [__Packages.effect.ClipMov] Frame 0
class effect.ClipMov extends basic.Mc
{
var L, clipArr, id;
function ClipMov () {
super();
var _local4 = Common.getChildAt(this, 0);
L = _local4._totalframes;
var _local5 = _local4.filters;
clipArr = new Array();
initClip(_local4, 0, _local5);
var _local3 = 1;
while (_local3 < L) {
initClip(_local4.duplicateMovieClip("clip" + _local3, _local3), _local3, _local5);
_local3++;
}
id = random(L);
Global.addRun(this, "run");
}
function remove() {
Global.delRun(this, "run");
super.remove();
clipArr = null;
}
function run() {
clipArr[id]._visible = false;
if ((++id) >= L) {
id = 0;
}
clipArr[id]._visible = true;
}
function initClip(clip, id, filters) {
clip.gotoAndStop(id);
clip.cacheAsBitmap = true;
clip.filters = filters;
clip._visible = false;
clipArr.push(clip);
}
}
Symbol 864 MovieClip [__Packages.topChef.ManEffect] Frame 0
class topChef.ManEffect extends basic.Mc
{
var stop, _visible;
function ManEffect () {
super();
stop();
hide();
}
function show() {
_visible = true;
Common.randomStop(this);
}
function hide() {
_visible = false;
}
}
Symbol 865 MovieClip [__Packages.topChef.Man] Frame 0
class topChef.Man extends ui.SBtn
{
var posDot, parts, useHandCursor, body, id, effect;
function Man () {
super();
}
function remove() {
super.remove();
posDot = null;
parts = null;
}
function init(_id) {
useHandCursor = true;
body.head = body.part4;
id = _id;
body.head.gotoAndStop(id + 1);
body.head.head.stop();
parts = new Array();
if (id >= 7) {
body.gotoAndStop(2);
var _local2 = 0;
while (_local2 <= 5) {
body["part" + _local2].id = _local2 + 6;
_local2++;
}
} else {
body.gotoAndStop(1);
var _local2 = 0;
while (_local2 <= 5) {
body["part" + _local2].id = _local2;
_local2++;
}
}
var _local2 = 0;
while (_local2 <= 5) {
var _local3 = body["part" + _local2];
parts.push(_local3);
_local3.blood = body["blood" + _local2];
_local2++;
}
}
function getPart() {
var _local2;
if (parts.length > 2) {
_local2 = parts.splice(random(parts.length - 2), 1)[0];
} else if (parts.length > 0) {
_local2 = parts.shift();
} else {
_local2 = null;
}
if (_local2) {
_local2.blood.nextFrame();
var _local3 = _local2.id;
_local2.swapDepths(0);
_local2.removeMovieClip();
return(_local3);
}
remove();
return(-1);
}
function normal() {
effect.hide();
body.head.head.gotoAndStop(1);
}
function afraid() {
effect.show();
body.head.head.gotoAndStop(2);
}
function sad() {
effect.hide();
body.head.head.gotoAndStop(3);
}
function get totalPart() {
return(parts.length);
}
static var totalMan = 10;
}
Symbol 866 MovieClip [__Packages.topChef.PosDot] Frame 0
class topChef.PosDot extends basic.Mc
{
var target;
function PosDot () {
super();
}
function remove() {
super.remove();
target = null;
}
}
Symbol 867 MovieClip [__Packages.topChef.Plate] Frame 0
class topChef.Plate extends basic.Mc
{
var stop, manId, gotoAndStop, bodyPart, cookId, value, food;
function Plate () {
super();
stop();
}
function getFoodFromMan(man) {
manId = man.id;
gotoAndStop(2);
bodyPart.gotoAndStop(man.getPart() + 1);
}
function getFoodFromCooker(_manId, _cookId, _value) {
manId = _manId;
cookId = _cookId;
value = _value;
gotoAndStop(cookId + 3);
food.gotoAndStop(value + 1);
}
function getFoodFromPlate(chefPlate) {
gotoAndStop(chefPlate._currentframe);
food.gotoAndStop(chefPlate.value + 1);
chefPlate.hideFood();
}
function hideFood() {
gotoAndStop(1);
}
}
Symbol 868 MovieClip [__Packages.topChef.Chef] Frame 0
class topChef.Chef extends basic.Mc
{
var gotoAndStop, x0, _x, y0, _y, __life, action, onCutFinish, onGotoCookFinish, onGotoGetFoodFinish, onBringFoodToCustomer, currentSeat, currentMan, currentCooker, body, plate, throwFoodObject;
function Chef () {
super();
gotoAndStop("front");
x0 = _x;
y0 = _y;
__life = 3;
action = 0;
}
function remove() {
Global.delGameRun(this, "gotoCutRun");
Global.delGameRun(this, "gotoCookRun");
Global.delGameRun(this, "gotoGetFoodRun");
super.remove();
onCutFinish = null;
onGotoCookFinish = null;
onGotoGetFoodFinish = null;
onBringFoodToCustomer = null;
currentSeat = null;
currentMan = null;
currentCooker = null;
}
function prepareToCut() {
gotoAndStop("back");
body.stop();
}
function gotoCut(man) {
prepareToCut();
currentMan = man;
action = NOTHING;
Global.addGameRun(this, "gotoCutRun");
}
function gotoCutRun() {
if (walkToTarget(currentMan.posDot)) {
Global.delGameRun(this, "gotoCutRun");
cutMan();
}
}
function cutMan() {
gotoAndStop("cut");
}
function cutFinish() {
action = CUTFINISHED;
plate.getFoodFromMan(currentMan);
onCutFinish();
}
function gotoCook(cooker) {
throwFoodObject = null;
currentCooker = cooker;
prepareWalkTo(currentCooker.posDot);
action = NOTHING;
Global.addGameRun(this, "gotoCookRun");
}
function gotoCookRun() {
if (walkToTarget(currentCooker.posDot)) {
Global.delGameRun(this, "gotoCookRun");
currentCooker.cook(currentMan.id);
plate.hideFood();
onGotoCookFinish();
currentCooker = null;
currentMan = null;
action = GOTOCOOKFINISHED;
}
}
function gotoGetFood(cooker) {
throwFoodObject = null;
currentCooker = cooker;
prepareWalkTo(currentCooker.posDot);
action = NOTHING;
Global.addGameRun(this, "gotoGetFoodRun");
}
function gotoGetFoodRun() {
if (walkToTarget(currentCooker.posDot)) {
Global.delGameRun(this, "gotoGetFoodRun");
gotoAndStop("front");
body.stop();
plate.getFoodFromCooker(currentCooker.manId, currentCooker.id, currentCooker.getFood());
currentCooker = null;
onGotoGetFoodFinish();
action = GOTOGETFOODFINISHED;
}
}
function bringFoodToCustomer(seat) {
currentSeat = seat;
prepareWalkTo(currentSeat.posDot);
action = NOTHING;
Global.addGameRun(this, "bringFoodToCustomerRun");
}
function bringFoodToCustomerRun() {
if (walkToTarget(currentSeat.posDot)) {
Global.delGameRun(this, "bringFoodToCustomerRun");
gotoAndStop("front");
body.stop();
onBringFoodToCustomer(currentSeat);
action = BRINGFOODTOCUSTOMERFINISHED;
}
}
function prepareThrowFood() {
throwFoodObject = {_currentframe:plate._currentframe, value:plate.value};
}
function throwFood() {
if (throwFoodObject) {
gotoAndStop("throw");
}
}
function onThrowFood() {
gotoAndStop("front");
}
function walkToTarget(target) {
var _local2 = new flash.geom.Point(target._x - _x, target._y - _y);
if (_local2.length < v) {
_x = target._x;
_y = target._y;
body.gotoAndStop(1);
return(true);
}
body.nextFrame();
_local2.normalize(v);
_x = _x + _local2.x;
_y = _y + _local2.y;
return(false);
}
function prepareWalkTo(target) {
var _local2 = target._x - _x;
var _local3 = target._y - _y;
if ((_local2 * _local2) <= 10000) {
if (_local3 < 0) {
gotoAndStop("back");
} else {
gotoAndStop("front");
}
} else if (_local2 < 0) {
gotoAndStop("left");
} else {
gotoAndStop("right");
}
body.stop();
}
function hurt() {
life = ((life-1));
}
function get life() {
return(__life);
}
function set life(_life) {
__life = _life;
Global.game.checkLife(__life);
//return(life);
}
static var v = 20;
static var NOTHING = 0;
static var CUTFINISHED = 1;
static var GOTOCOOKFINISHED = 2;
static var GOTOGETFOODFINISHED = 3;
static var BRINGFOODTOCUSTOMERFINISHED = 4;
}
Symbol 869 MovieClip [__Packages.ui.SimpleClock] Frame 0
class ui.SimpleClock extends basic.Mc
{
var onTimeUp, time, totalTime, t0, t, gotoAndStop, _totalframes;
function SimpleClock () {
super();
stop();
}
function remove() {
super.remove();
onTimeUp = null;
}
function init(_totalTime) {
time = (totalTime = _totalTime);
update();
}
function start() {
t0 = getTimer();
Global.addGameRun(this, "run");
}
function stop() {
Global.delGameRun(this, "run");
}
function run() {
t = getTimer();
var _local2 = t - t0;
if (_local2 > 100) {
_local2 = 0;
t0 = getTimer();
}
time = time - (_local2 / 1000);
t0 = t;
update();
if (time <= 0) {
onTimeUp();
}
}
function update() {
gotoAndStop(int((time / totalTime) * _totalframes));
}
}
Symbol 870 MovieClip [__Packages.topChef.Seat] Frame 0
class topChef.Seat extends basic.Mc
{
var ghost, posDot, manId, cookId, score, plate;
function Seat () {
super();
}
function remove() {
super.remove();
ghost = null;
posDot = null;
}
function order(_manId, _cookId) {
manId = _manId;
cookId = _cookId;
if (isNaN(cookId)) {
cookId = random(topChef.Cooker.totalCooker);
}
ghost.order(manId, cookId);
}
function showFood(chefPlate) {
score = 0;
if (manId == chefPlate.manId) {
score = score + 40;
}
if (cookId == chefPlate.cookId) {
score = score + 30;
}
switch (chefPlate.value) {
case 0 :
score = score + 0;
break;
case 1 :
score = score + 10;
break;
case 2 :
score = score + 30;
break;
case 3 :
score = score + 10;
}
plate.getFoodFromPlate(chefPlate);
}
function hideFood() {
plate.hideFood();
}
}
Symbol 871 MovieClip [__Packages.topChef.Cooker] Frame 0
class topChef.Cooker extends ui.SBtn
{
var stop, delayTime, cookProgress, _xscale, cookGoodDelayTime, posDot, __id, cookName, isCooking, manId, gotoAndStop, smoke, value, food;
function Cooker () {
super();
stop();
delayTime = 0;
cookProgress.gotoAndStop(1);
cookProgress._visible = false;
cookProgress._xscale = _xscale;
cookGoodDelayTime = 165 - (Global.main.__get__stageNum() * 15);
if (cookGoodDelayTime < 90) {
cookGoodDelayTime = 90;
}
}
function remove() {
Global.delGameRun(this, "cookRun");
super.remove();
posDot = null;
}
function get id() {
return(__id);
}
function set id(_id) {
__id = _id;
cookName = cookNameArr[__id];
//return(id);
}
function cook(_manId) {
isCooking = true;
manId = _manId;
gotoAndStop(2);
smoke._alpha = 70;
Global.addGameRun(this, "cookRun");
value = 0;
cookProgress.gotoAndStop(1);
cookProgress._visible = true;
}
function getFood() {
Global.delGameRun(this, "cookRun");
isCooking = false;
gotoAndStop(1);
cookProgress._visible = false;
return(value);
}
function cookRun() {
if ((++delayTime) >= ((value == 2) ? 150 : 60)) {
delayTime = 0;
value++;
food.value = value;
cookProgress.gotoAndStop(value + 1);
smoke._alpha = smoke._alpha + 40;
}
}
static var cookNameArr = ["Boil", "Fry", "Grill", "Sushi"];
static var totalCooker = 4;
}
Symbol 872 MovieClip [__Packages.topChef.CookingFood] Frame 0
class topChef.CookingFood extends basic.Mc
{
var __value, gotoAndStop;
function CookingFood () {
super();
value = (0);
}
function set value(_value) {
__value = _value;
gotoAndStop(__value + 1);
//return(value);
}
function get value() {
return(__value);
}
}
Symbol 873 MovieClip [__Packages.topChef.Tips] Frame 0
class topChef.Tips extends basic.Mc
{
var _visible, delayDelayTime, delayTime;
function Tips () {
super();
_visible = false;
}
function remove() {
Global.delGameRun(this, "showRun");
super.remove();
}
function show() {
return(undefined);
}
function hide() {
return(undefined);
}
function restartCount() {
delayDelayTime = 90;
_visible = false;
}
function showRun() {
if (delayDelayTime > 0) {
delayDelayTime--;
} else if ((--delayTime) <= 0) {
delayTime = 10;
_visible = !_visible;
}
}
}
Symbol 874 MovieClip [__Packages.topChef.TipsChooseAGuy] Frame 0
class topChef.TipsChooseAGuy extends topChef.Tips
{
function TipsChooseAGuy () {
super();
}
}
Symbol 875 MovieClip [__Packages.topChef.TipsChooseACooker] Frame 0
class topChef.TipsChooseACooker extends topChef.Tips
{
function TipsChooseACooker () {
super();
}
}
Symbol 876 MovieClip [__Packages.topChef.TipsChooseACustomer] Frame 0
class topChef.TipsChooseACustomer extends topChef.Tips
{
function TipsChooseACustomer () {
super();
}
}
Symbol 877 MovieClip [__Packages.FWG.BasicGame] Frame 0
class FWG.BasicGame extends basic.Mc
{
var onStageClear, onGameOver, onTimeUp;
function BasicGame () {
super();
Global.game = this;
}
function remove() {
super.remove();
onStageClear = null;
onGameOver = null;
onTimeUp = null;
Global.game = null;
}
function start(_stageNum) {
}
function restart() {
}
function init() {
}
function stageClear() {
Global.pause = true;
onStageClear();
}
function gameOver() {
Global.pause = true;
onGameOver();
}
function playAgain() {
}
}
Symbol 878 MovieClip [__Packages.topChef.Game] Frame 0
class topChef.Game extends FWG.BasicGame
{
var manArr, cookerArr, chef, pressObjArr, lifeBar, totalGhost, clock, effectArea, ghostArea, tipsChooseAGuy, tipsChooseACooker, tipsChooseACustomer, hitRec, __get__allClickAble;
function Game () {
super();
trace("stageNum=" + Global.main.__get__stageNum());
}
function remove() {
super.remove();
seatMap = null;
manArr = null;
cookerArr = null;
}
function run() {
if (chef.action == topChef.Chef.NOTHING) {
return(undefined);
}
if (pressObjArr.length > 0) {
var _local2 = pressObjArr.shift();
switch (chef.action) {
case topChef.Chef.CUTFINISHED :
chef.gotoCook(_local2);
break;
case topChef.Chef.GOTOCOOKFINISHED :
break;
case topChef.Chef.GOTOGETFOODFINISHED :
chef.bringFoodToCustomer(getSeatByGhost(_local2));
break;
case topChef.Chef.BRINGFOODTOCUSTOMERFINISHED :
}
chef.action = topChef.Chef.NOTHING;
}
}
function init() {
topChef.Ghost.coming = false;
allClickAble = (true);
Global.addGameRun(this, "run");
pressObjArr = new Array();
var _local2;
var _local6;
lifeBar.stop();
playSndScreemDelay();
chef.onCutFinish = function () {
};
chef.onGotoCookFinish = function () {
Global.game.setClickAble(Global.game.hasOrderingGhost(), true, false, true, "cooking");
};
chef.onGotoGetFoodFinish = function () {
};
chef.onBringFoodToCustomer = function (seat) {
seat.showFood(this.plate);
if ((seat.manId == this.plate.manId) && (seat.cookId == this.plate.cookId)) {
seat.ghost.eat();
} else {
seat.ghost.reOrder();
seat.hideFood();
}
Global.game.setClickAble(Global.game.hasOrderingGhost(), true, false, true, "cooking");
};
_local2 = seatMap.length - 1;
while (_local2 >= 0) {
var _local5 = (seatMap[_local2] = this["seat" + _local2]);
_local5.posDot = this["seatPosDot" + _local2];
_local2--;
}
totalGhost = seatMap.length;
manArr = new Array(5);
cookerArr = new Array(8);
addGhost();
_local6 = manArr.length;
var _local7 = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9];
_local2 = 0;
while (_local2 < _local6) {
var _local4 = (manArr[_local2] = this["man" + _local2]);
this["manPosDot" + _local2].target = _local4;
_local4.init(_local7.splice(random(_local7.length), 1)[0]);
_local4.posDot = this["manPosDot" + _local2];
_local4.rollOver = function () {
this.afraid();
Global.game.tipsChooseAGuy.restartCount();
};
_local4.rollOut = function () {
this.normal();
};
_local4.press = function () {
this.sad();
Global.game.tipsChooseAGuy.hide();
Global.game.setClickAble(false, true, false, false);
Global.addGameDelayRun(this, "normal", 60);
Global.game.chef.gotoCut(this);
};
_local2++;
}
_local6 = cookerArr.length;
_local2 = 0;
while (_local2 < _local6) {
var _local3 = (cookerArr[_local2] = this["cooker" + _local2]);
this["cookerPosDot" + _local2].target = _local3;
_local3.posDot = this["cookerPosDot" + _local2];
_local3.id = _local2 % topChef.Cooker.totalCooker;
_local3.rollOver = function () {
ui.Alt.show(this.cookName);
Global.game.tipsChooseACooker.restartCount();
};
_local3.rollOut = function () {
ui.Alt.hide();
};
_local3.press = function () {
ui.Alt.hide();
if (this.isCooking) {
Global.game.chef.gotoGetFood(this);
Global.game.setClickAble(false, false, true, false);
} else {
Global.game.pressObjArr.push(this);
Global.game.setClickAble(false, false, false, false);
}
};
_local2++;
}
setClickMenAble(true);
setClickCookersAble(false);
clock.onTimeUp = function () {
Global.game.finishJob();
};
startGame();
}
function initThrow(plateHitArea) {
if (plateHitArea._parent._parent != chef) {
return(undefined);
}
if (Global.game.chef._currentframe == 4) {
plateHitArea.onRollOver = function () {
ui.Alt.show("Throw Away");
ui.Alt.hideDelay(5000);
};
plateHitArea.onRollOut = function () {
ui.Alt.hide();
};
plateHitArea.onPress = function () {
ui.Alt.hide();
Global.game.throwFood();
};
}
}
function throwFood() {
chef.prepareThrowFood();
chef.throwFood();
Global.game.setClickAble(Global.game.hasOrderingGhost(), true, false, true, "cooking");
}
function playSndScreemDelay() {
Global.addGameDelayRun(this, "playSndScreem", random(240) + 240);
}
function playSndScreem() {
Global.main.playSound("SndScreem");
playSndScreemDelay();
}
function ghostRunAway(ghost) {
var _local2 = getSeatByGhost(ghost);
ghost.runAway();
_local2.ghost = null;
}
function startGame() {
Global.pause = false;
clock.init(120);
clock.start();
}
function addScore(dScore) {
var _local2 = effectArea.getNextHighestDepth();
effectArea.attachMovie("topChef.ScorePopUp", "scorePopUp" + _local2, _local2, {_x:chef._x, _y:chef._y - 100, score:dScore});
Global.main.addScore(dScore);
}
function finishJob() {
Global.pause = true;
Global.main.stageClearOrLose();
}
function addGhostDelay(delayTime) {
if (isNaN(delayTime)) {
if (Common.getNumChildren(ghostArea) <= 1) {
delayTime = random(150) + 30;
} else {
delayTime = random(150) + ((10 - Global.main.__get__stageNum()) * 30);
}
}
trace("delayTime=" + delayTime);
Global.addGameDelayRun(this, "addGhost", delayTime);
}
function addGhost() {
if ((topChef.Ghost.coming || (getTotalOrder() >= Global.main.__get__stageNum())) || (Common.getNumChildren(ghostArea) >= totalGhost)) {
addGhostDelay(90);
return(undefined);
}
var _local4 = ghostArea.getNextHighestDepth();
var _local3 = ghostArea.attachMovie("topChef.Ghost", "ghost" + _local4, _local4);
var _local2 = 0;
while (_local2 < totalGhost) {
if (!seatMap[_local2].ghost) {
seatMap[_local2].ghost = _local3;
_local3.mov(_local2);
break;
}
_local2++;
}
_local3.rollOver = function () {
this.tipsChooseACustomer.restartCount();
};
_local3.press = function () {
Global.game.pressObjArr.push(this);
Global.game.tipsChooseACustomer.hide();
Global.game.setClickAble(false, false, false, false);
};
_local3.onSit = function () {
Global.game.onSit(this);
};
_local3.onNotRedo = function () {
this.eat();
Global.game.setClickAble(Global.game.hasOrderingGhost(), true, false, true, "cooking");
};
_local3.onRedo = function () {
Global.game.getSeatByGhost(this).hideFood();
Global.game.setClickAble(Global.game.hasOrderingGhost(), true, false, true, "cooking");
if (Global.game.chef._currentframe == 4) {
Global.game.chef.throwFood();
}
};
_local3.onEatFinish = function () {
var _local2 = Global.game.getSeatByGhost(this);
_local2.hideFood();
this.waitingToPay();
};
_local3.onWaitingToPayFinish = function () {
Global.game.addScore(Global.game.getSeatByGhost(this).score);
Global.game.ghostRunAway(this);
};
_local3.onRunAway = function () {
Global.game.addGhostDelay(random(60));
};
}
function onSit(ghost) {
order(getSeatByGhost(ghost));
switch (chef.action) {
case topChef.Chef.GOTOCOOKFINISHED :
case topChef.Chef.BRINGFOODTOCUSTOMERFINISHED :
setClickMenAble(true);
}
addGhostDelay();
}
function order(seat) {
seat.order(getRanManId());
}
function getRanManId() {
var _local4 = manArr.length;
var _local7 = random(_local4);
var _local5;
var _local6 = -1;
var _local2 = 0;
while (_local2 < _local4) {
var _local3 = (_local2 + _local7) % _local4;
if (_local6 < manArr[_local3].totalPart) {
_local5 = manArr[_local3];
_local6 = _local5.totalPart;
}
_local2++;
}
return(_local5.id);
}
function getGhostSeatIndex(ghost) {
var _local3 = seatMap.length;
var _local2 = 0;
while (_local2 < _local3) {
if (seatMap[_local2].ghost == ghost) {
return(_local2);
}
_local2++;
}
return(-1);
}
function setClickAble(value1, value2, value3, value4, cookerAction) {
setClickMenAble(value1);
setClickCookersAble(value2, cookerAction);
setClickGhostAble(value3);
}
function setClickMenAble(value) {
if (value) {
tipsChooseAGuy.show();
} else {
tipsChooseAGuy.hide();
}
Common.forEach(manArr, function (man) {
man.selectAble = value;
});
}
function setClickCookersAble(value, action) {
var _local2;
if (action == undefined) {
if (value) {
tipsChooseACooker.show();
} else {
tipsChooseACooker.hide();
}
Common.forEach(cookerArr, function (cooker) {
if (cooker.isCooking) {
cooker.selectAble = false;
} else {
cooker.selectAble = value;
}
});
} else {
Common.forEach(cookerArr, function (cooker) {
if (cooker.isCooking) {
cooker.selectAble = value;
} else {
cooker.selectAble = false;
}
});
}
}
function setClickGhostAble(value) {
if (value) {
tipsChooseACustomer.show();
} else {
tipsChooseACustomer.hide();
}
Common.forEach(seatMap, function (seat) {
var _local1 = seat.ghost;
if (_local1) {
if (_local1.action == topChef.GhostAction.ORDERING) {
_local1.selectAble = value;
} else {
_local1.selectAble = false;
}
}
});
}
function getSeatByGhost(ghost) {
var _local3 = seatMap.length;
var _local2 = 0;
while (_local2 < _local3) {
if (seatMap[_local2].ghost == ghost) {
return(seatMap[_local2]);
}
_local2++;
}
return(null);
}
function checkLife(__life) {
allClickAble = (false);
Global.pause = true;
chef._visible = false;
if (chef._currentframe == 4) {
chef.plate.gotoAndStop(1);
Global.game.setClickAble(Global.game.hasOrderingGhost(), true, false, true, "cooking");
}
var _local3 = Global.game.effectArea2.getNextHighestDepth();
var _local2 = Global.game.effectArea2.attachMovie("topChef.ChefBurnEffect", "effect" + _local3, _local3, {_x:chef._x, _y:chef._y});
_local2.life = __life;
_local2.onBurn = function () {
Global.game.updateChefBodys(this);
};
_local2.onBurnFinish = function () {
Global.game.onBurnFinish(this.life);
};
}
function onBurnFinish(__life) {
updateChefBodys(chef);
allClickAble = (true);
Global.pause = false;
chef._visible = true;
if (__life <= 0) {
Global.main.lose();
}
lifeBar.gotoAndStop(4 - __life);
}
function set allClickAble(_allClickAble) {
if (_allClickAble) {
hitRec._x = -1000;
} else {
hitRec._x = 0;
}
//return(__get__allClickAble());
}
function setChefBody(chefBody) {
chefBody.type = "chefBody";
chefBody.gotoAndStop(4 - chef.life);
}
function updateChefBodys(chefObj) {
Common.forEach(Common.getAllChildren(chefObj, true), function (chefBody) {
if (chefBody.type == "chefBody") {
Global.game.setChefBody(chefBody);
}
});
}
function getTotalCookingCooker() {
var _local3 = 0;
var _local4 = cookerArr.length;
var _local2 = 0;
while (_local2 < _local4) {
if (cookerArr[_local2].isCooking) {
_local3++;
}
_local2++;
}
return(_local3);
}
function getTotalOrder() {
var _local3 = 0;
var _local2 = 0;
while (_local2 < totalGhost) {
if (seatMap[_local2].ghost.action == topChef.GhostAction.ORDERING) {
_local3++;
}
_local2++;
}
return(_local3);
}
function hasOrderingGhost() {
if (getTotalOrder() == 0) {
return(false);
}
if (getTotalOrder() <= getTotalCookingCooker()) {
return(false);
}
return(true);
}
var seatMap = [null, null, null, null];
}
Symbol 879 MovieClip [__Packages.topChef.Ghost] Frame 0
class topChef.Ghost extends basic.Mc
{
static var coming;
var heart, _x, ghostPosDot, attachMovie, onSit, onEatFinish, onOrderFinish, onReOrderFinish, onNotRedo, onRedo, onWaitingToPayFinish, onPayFinish, onRunAway, action, body, isMoving, waitingValue, waitingDelayTime, customBox, onPress, onRollOver, onRollOut, _y, effect, _rotation, delayTime;
function Ghost () {
super();
Common.randomStop(this);
heart.stop();
_x = -1000;
ghostPosDot = attachMovie("topChef.GhostPosDot", "ghostPosDot", 0);
}
function remove() {
Global.delGameRun(this, "eatRun");
Global.delGameRun(this, "waitingRun");
super.remove();
onSit = null;
onEatFinish = null;
ghostPosDot = null;
onOrderFinish = null;
onReOrderFinish = null;
onNotRedo = null;
onRedo = null;
onWaitingToPayFinish = null;
onPayFinish = null;
onRunAway = null;
}
function init() {
ghostPosDot.ghost = this;
ghostPosDot.onF = function (id) {
if (isNaN(id)) {
this.ghost.onRunAway();
this.ghost.remove();
return(undefined);
}
this.ghost.sit(id);
};
coming = true;
action = topChef.GhostAction.OUTSIDE;
body.rollOver = function () {
this._parent.rollOver();
};
body.press = function () {
this._parent.press();
};
body.selectAble = false;
}
function mov(id) {
body.gotoAndStop(1);
isMoving = true;
ghostPosDot.mov(id);
}
function sit(id) {
coming = false;
isMoving = false;
body.gotoAndStop(2);
onSit(id);
}
function initWait() {
Global.delGameRun(this, "waitingRun");
Global.addGameRun(this, "waitingRun");
waitingValue = 1;
heart.gotoAndStop(waitingValue);
waitingDelayTime = 0;
}
function waitingRun() {
if ((++waitingDelayTime) >= 300) {
waitingDelayTime = 0;
waitingOverTime();
}
}
function waitingOverTime() {
waitingValue++;
heart.gotoAndStop(waitingValue);
if (waitingValue >= 4) {
customBox.hide();
waitingValue = 0;
heart._visible = false;
burnChef();
Global.delGameRun(this, "waitingRun");
}
}
function burnChef() {
delete onPress;
delete onRollOver;
delete onRollOut;
var _local3 = Global.game.effectArea.getNextHighestDepth();
var _local2 = Global.game.effectArea.attachMovie("topChef.FireBall", "fireBall" + _local3, _local3, {x:_x, y:_y});
_local2.ghost = this;
_local2.onRemoved = function () {
Global.addGameDelayRun(this.ghost, "runAwayDelay", 30);
};
}
function runAwayDelay() {
Global.game.ghostRunAway(this);
}
function order(manId, cookId) {
action = topChef.GhostAction.ORDERING;
customBox.order(manId, cookId);
initWait();
}
function reOrder() {
customBox.reOrder();
Global.delGameRun(this, "waitingRun");
waitingDelayTime = Infinity;
waitingValue = Infinity;
Global.addGameDelayRun(this, "waitingOverTime", 60);
}
function reOrderFinish() {
onReOrderFinish();
}
function notRedo(manId, cookId) {
customBox.notRedo(manId, cookId);
Global.addGameDelayRun(this, "onNotRedo", 60);
}
function redo() {
customBox.redo();
Global.addGameDelayRun(this, "onRedoDelay", 60);
}
function onRedoDelay() {
order();
onRedo();
}
function eat() {
heart._visible = false;
Global.delGameRun(this, "waitingRun");
customBox.hide();
if (Global.game.getSeatByGhost(this).score == 100) {
effect.show(1);
} else {
effect.show(2);
}
action = topChef.GhostAction.EATING;
Global.addGameDelayRun(this, "eatRunDelay", 30);
}
function eatRunDelay() {
_rotation = 5;
effect.hide();
delayTime = 255 - (Global.main.__get__stageNum() * 45);
if (delayTime < 30) {
delayTime = 30;
}
Global.addGameRun(this, "eatRun");
}
function eatRun() {
if ((--delayTime) <= 0) {
Global.delGameRun(this, "eatRun");
_rotation = 0;
onEatFinish();
return(undefined);
}
if ((delayTime % 5) == 0) {
_rotation = _rotation * -1;
}
}
function waitingToPay() {
action = topChef.GhostAction.WAITINGTOPAY;
customBox.pay();
Global.addGameDelayRun(this, "waitingToPayFinish", 60);
}
function waitingToPayFinish() {
customBox.hide();
onWaitingToPayFinish();
}
function pay(manId, cookId) {
action = topChef.GhostAction.PAYING;
}
function runAway() {
action = topChef.GhostAction.RUNNINGAWAY;
body.gotoAndStop(1);
ghostPosDot.mov();
}
function get selectAble() {
return(body.selectAble);
}
function set selectAble(_selectAble) {
body.selectAble = _selectAble;
//return(selectAble);
}
}
Symbol 880 MovieClip [__Packages.topChef.GhostAction] Frame 0
class topChef.GhostAction
{
function GhostAction () {
}
static var OUTSIDE = 1;
static var ORDERING = 3;
static var EATING = 5;
static var WAITINGTOPAY = 6;
static var PAYING = 7;
static var RUNNINGAWAY = 8;
}
Symbol 881 MovieClip [__Packages.FWG.BtnQ0] Frame 0
class FWG.BtnQ0 extends FWG.Btn
{
var __set__label;
function BtnQ0 () {
super();
__set__label("LOW");
}
}
Symbol 882 MovieClip [__Packages.FWG.BtnQ1] Frame 0
class FWG.BtnQ1 extends FWG.Btn
{
var __set__label;
function BtnQ1 () {
super();
__set__label("MEDIUM");
}
}
Symbol 883 MovieClip [__Packages.FWG.BtnQ2] Frame 0
class FWG.BtnQ2 extends FWG.Btn
{
var __set__label;
function BtnQ2 () {
super();
__set__label("HIGH");
}
}
Symbol 884 MovieClip [__Packages.FWG.BtnQ3] Frame 0
class FWG.BtnQ3 extends FWG.Btn
{
var __set__label;
function BtnQ3 () {
super();
__set__label("BEST");
}
}
Symbol 885 MovieClip [__Packages.FWG.QualitySetting] Frame 0
class FWG.QualitySetting extends FWG.AlphaFadeSp
{
var hide, btnOK, _quality, __get__quality;
function QualitySetting () {
super();
Global.main.qualitySetting = this;
hide();
var _local3 = 0;
while (_local3 < 4) {
this["btn" + _local3]._press = function () {
Global.main.qualitySetting.quality = this.label;
};
_local3++;
}
btnOK._press = function () {
Global.main.qualitySetting.fadeHide();
};
}
function remove() {
super.remove();
Global.main.qualitySetting = null;
}
function fadeShow() {
super.fadeShow();
quality = (_quality);
}
function set quality(__quality) {
var _local3 = 0;
while (_local3 < 4) {
var _local2 = this["btn" + _local3];
if (_local2.label == __quality) {
_local2.selected = true;
} else {
_local2.selected = false;
}
_local3++;
}
_quality = __quality;
//return(__get__quality());
}
}
Symbol 886 MovieClip [__Packages.FWG.PageGame] Frame 0
class FWG.PageGame extends basic.Mc
{
var scoreTxt, targetTxt;
function PageGame () {
super();
scoreTxt.text = Global.main.score;
targetTxt.text = Global.main.targetMoney;
}
}
Symbol 887 MovieClip [__Packages.FWG.PageGameOver] Frame 0
class FWG.PageGameOver extends FWG.AlphaFadeSp
{
var scoreTxt;
function PageGameOver () {
super();
scoreTxt.text = Global.main.score;
}
}
Symbol 888 MovieClip [__Packages.FWG.BtnSkip] Frame 0
class FWG.BtnSkip extends FWG.Btn
{
var __set__label;
function BtnSkip () {
super();
__set__label("Skip");
}
}
Symbol 889 MovieClip [__Packages.FWG.Instructions] Frame 0
class FWG.Instructions extends basic.Mc
{
var stop, btnNext, btnBack, _totalframes, _currentframe, btnPlay, btnSkip;
function Instructions () {
super();
stop();
setPos();
Global.main.isFirstPlay = false;
btnNext._press = function () {
this._parent.nextFrame();
this._parent.setPos();
};
btnBack._press = function () {
this._parent.prevFrame();
this._parent.setPos();
};
}
function setPos() {
btnPlay._visible = _currentframe == _totalframes;
btnSkip._visible = (btnNext._visible = _currentframe != _totalframes);
btnBack._visible = _currentframe > 1;
}
}
Symbol 890 MovieClip [__Packages.FWG.PageInst] Frame 0
class FWG.PageInst extends basic.Mc
{
function PageInst () {
super();
}
}
Symbol 891 MovieClip [__Packages.FWG.Logo] Frame 0
class FWG.Logo extends ui.SBtn
{
var press;
function Logo () {
super();
press = function () {
this.getURL("http://www.freeworldgroup.com/", "_blank");
};
}
}
Symbol 892 MovieClip [__Packages.FWG.PageMenu] Frame 0
class FWG.PageMenu extends basic.Mc
{
function PageMenu () {
super();
Global.pause = false;
}
}
Symbol 893 MovieClip [__Packages.FWG.PageOptions] Frame 0
class FWG.PageOptions extends basic.Mc
{
var scoreTxt, btnOk;
function PageOptions () {
super();
scoreTxt.text = FWG.Main.firstTarget;
btnOk._press = function () {
Global.main.fadeToPageGame();
};
}
}
Symbol 894 MovieClip [__Packages.FWG.BtnNs] Frame 0
class FWG.BtnNs extends FWG.Btn
{
var __set__label;
function BtnNs () {
super();
__set__label("Next Stage");
}
}
Symbol 895 MovieClip [__Packages.topChef.GhostPosDot] Frame 0
class topChef.GhostPosDot extends basic.Mc
{
var stop, ghost, onF, currentId, nextFrame, dot;
function GhostPosDot () {
super();
stop();
}
function remove() {
Global.delGameRun(this, "movRun");
super.remove();
ghost = null;
onF = null;
}
function mov(id) {
currentId = id;
Global.delGameRun(this, "movRun");
Global.addGameRun(this, "movRun");
}
function movRun() {
nextFrame();
ghost._x = dot._x;
ghost._y = dot._y;
}
function f(id) {
if (isNaN(id)) {
Global.delGameRun(this, "movRun");
onF();
}
if (id == currentId) {
Global.delGameRun(this, "movRun");
onF(id);
}
}
}
Symbol 896 MovieClip [__Packages.topChef.CustomBox] Frame 0
class topChef.CustomBox extends basic.Mc
{
var cacheAsBitmap, stop, onPay, manId0, cookId0, gotoAndStop, head, cooker, _visible, _parent, scoreTxt, _currentframe;
function CustomBox () {
super();
cacheAsBitmap = true;
stop();
hide();
}
function remove() {
super.remove();
onPay = null;
}
function order(manId, cookId) {
if (isNaN(manId)) {
manId = manId0;
}
if (isNaN(cookId)) {
cookId = cookId0;
}
manId0 = manId;
cookId0 = cookId;
gotoAndStop("order");
if (!isNaN(manId)) {
head.gotoAndStop(manId + 1);
}
if (!isNaN(cookId)) {
cooker.gotoAndStop(cookId + 1);
}
show();
}
function reOrder() {
gotoAndStop("reOrder");
head.gotoAndStop(manId0 + 1);
cooker.gotoAndStop(cookId0 + 1);
show();
_visible = true;
}
function notRedo(manId, cookId) {
head.gotoAndStop(manId + 1);
cooker.gotoAndStop(cookId + 1);
gotoAndStop("notRedo");
show();
_visible = true;
}
function redo() {
gotoAndStop("redo");
show();
_visible = true;
}
function pay() {
gotoAndStop("pay");
show();
}
function initPay() {
var _local2 = Global.game.getSeatByGhost(_parent).score;
scoreTxt.text = _local2;
if (_local2 < 100) {
gotoAndStop(random(3) + _currentframe);
} else {
gotoAndStop((random(4) + _currentframe) + 3);
}
}
function payDelay() {
onPay();
hide();
}
function hideDelay() {
hide();
}
function show() {
_visible = true;
}
function hide() {
_visible = false;
}
}
Symbol 897 MovieClip [__Packages.topChef.GhostEffect] Frame 0
class topChef.GhostEffect extends basic.Mc
{
var stop, _visible, gotoAndStop;
function GhostEffect () {
super();
stop();
hide();
}
function show(value) {
_visible = true;
gotoAndStop(value);
}
function hide() {
_visible = false;
}
}
Symbol 898 MovieClip [__Packages.topChef.ScorePopUp] Frame 0
class topChef.ScorePopUp extends basic.Mc
{
var score, body;
function ScorePopUp () {
super();
body.txt.text = score;
}
}
Symbol 899 MovieClip [__Packages.topChef.FireBall] Frame 0
class topChef.FireBall extends basic.Mc
{
var depth, target, ghost, onRemoved, x, y, attachMovie;
function FireBall () {
super();
depth = 10000;
shoot(Global.game.chef);
}
function remove() {
super.remove();
target = null;
ghost = null;
onRemoved = null;
trace("remove");
}
function shoot(__target) {
target = __target;
Global.addGameRun(this, "run");
}
function run() {
var _local2 = new flash.geom.Point(target._x - x, target._y - y);
if (_local2.length < 5) {
x = target._x;
y = target._y;
Global.delGameRun(this, "run");
Global.game.chef.hurt();
onRemoved();
Global.addGameDelayRun(this, "remove", 60);
return(undefined);
}
x = x + (_local2.x * 0.2);
y = y + (_local2.y * 0.2);
depth--;
attachMovie("burnFire", "burnFire" + depth, depth, {_x:x, _y:y});
}
}
Symbol 900 MovieClip [__Packages.FWG.PageStageClear] Frame 0
class FWG.PageStageClear extends basic.Mc
{
var scoreTxt, targetTxt, btnOk;
function PageStageClear () {
super();
scoreTxt.text = Global.main.score;
targetTxt.text = Global.main.targetMoney;
btnOk._press = function () {
Global.main.nextStage();
};
}
}
Symbol 901 MovieClip [__Packages.FWG.MainContainer] Frame 0
class FWG.MainContainer extends basic.Mc
{
var page, attachMovie;
function MainContainer () {
super();
Global.mainContainer = this;
}
function remove() {
super.remove();
Global.mainContainer = null;
}
function putIn(mcId) {
page = attachMovie(mcId, "page", 0);
}
}
Symbol 902 MovieClip [__Packages.effect.FadeEffect] Frame 0
class effect.FadeEffect extends basic.Mc
{
var onShow, onHide;
function FadeEffect () {
super();
Global.fadeEffect = this;
onShow = function () {
};
onHide = function () {
};
}
function remove() {
super.remove();
onShow = null;
onHide = null;
Global.fadeEffect = null;
}
function fadeShow() {
}
function fadeHide() {
}
function flip() {
}
function show() {
}
function hide() {
}
function fadeRun() {
}
}
Symbol 903 MovieClip [__Packages.effect.SimpleFade] Frame 0
class effect.SimpleFade extends effect.FadeEffect
{
var gotoAndPlay, gotoAndStop;
function SimpleFade () {
super();
}
function fadeShow() {
gotoAndPlay("fadeShow");
}
function fadeHide() {
gotoAndPlay("fadeHide");
}
function show() {
gotoAndStop("show");
}
function hide() {
gotoAndStop("hide");
}
}
Symbol 904 MovieClip [__Packages.FWG.BtnS] Frame 0
class FWG.BtnS extends FWG.Btn
{
var redCircle;
function BtnS () {
super();
redCircle._visible = false;
}
}
Symbol 9 MovieClip Frame 1
_x = (Stage.width / 2);
_y = (Stage.height / 2);
this._visible = false;
_parent.gotoAndStop("Logo");
if (_root._url.indexOf("freeworldgroup.com") == -1) {
this._visible = true;
_parent.stop();
} else {
this._visible = false;
_parent.gotoAndStop("Logo");
}
Symbol 33 MovieClip Frame 1
_x = (Stage.width / 2);
_y = (Stage.height / 2);
_root.stop();
onPress = function () {
getURL ("http://www.freeworldgroup.com/", "_blank");
};
Symbol 33 MovieClip Frame 146
stop();
_root.play();
Symbol 37 MovieClip [FWG.BtnS] Frame 1
#initclip 153
Object.registerClass("FWG.BtnS", FWG.BtnS);
#endinitclip
Symbol 41 MovieClip [FWG.BtnM] Frame 1
#initclip 76
Object.registerClass("FWG.BtnM", FWG.BtnM);
#endinitclip
Symbol 43 MovieClip [FWG.BtnQ] Frame 1
#initclip 77
Object.registerClass("FWG.BtnQ", FWG.Btn);
#endinitclip
Symbol 44 MovieClip [FWG._3Btn] Frame 1
#initclip 78
Object.registerClass("FWG._3Btn", FWG._3Btn);
#endinitclip
Symbol 47 MovieClip [FWG.BtnAgtys] Frame 1
#initclip 79
Object.registerClass("FWG.BtnAgtys", FWG.BtnAgtys);
#endinitclip
Symbol 49 MovieClip [FWG.BtnCopyright] Frame 1
#initclip 80
Object.registerClass("FWG.BtnCopyright", FWG.BtnCopyright);
#endinitclip
Symbol 51 MovieClip [FWG.BtnCredits] Frame 1
#initclip 81
Object.registerClass("FWG.BtnCredits", FWG.BtnCredits);
#endinitclip
Symbol 53 MovieClip [FWG.BtnDg] Frame 1
#initclip 82
Object.registerClass("FWG.BtnDg", FWG.BtnDg);
#endinitclip
Symbol 55 MovieClip [FWG.BtnInstructions] Frame 1
#initclip 83
Object.registerClass("FWG.BtnInstructions", FWG.BtnInstructions);
#endinitclip
Symbol 57 MovieClip [FWG.BtnMenu] Frame 1
#initclip 84
Object.registerClass("FWG.BtnMenu", FWG.BtnMenu);
#endinitclip
Symbol 59 MovieClip [FWG.BtnMog] Frame 1
#initclip 85
Object.registerClass("FWG.BtnMog", FWG.BtnMog);
#endinitclip
Symbol 61 MovieClip [FWG.BtnPa] Frame 1
#initclip 86
Object.registerClass("FWG.BtnPa", FWG.BtnPa);
#endinitclip
Symbol 63 MovieClip [FWG.BtnPg] Frame 1
#initclip 87
Object.registerClass("FWG.BtnPg", FWG.BtnPg);
#endinitclip
Symbol 65 MovieClip [FWG.BtnPlay] Frame 1
#initclip 88
Object.registerClass("FWG.BtnPlay", FWG.BtnPlay);
#endinitclip
Symbol 67 MovieClip [FWG.BtnSs] Frame 1
#initclip 89
Object.registerClass("FWG.BtnSs", FWG.BtnSs);
#endinitclip
Symbol 69 MovieClip [FWG.BtnSubmit] Frame 1
#initclip 90
Object.registerClass("FWG.BtnSubmit", FWG.Btn);
#endinitclip
Symbol 71 MovieClip [FWG.BtnVh] Frame 1
#initclip 91
Object.registerClass("FWG.BtnVh", FWG.BtnVh);
#endinitclip
Symbol 73 MovieClip [FWG.BtnX] Frame 1
#initclip 92
Object.registerClass("FWG.BtnX", FWG.Btn);
#endinitclip
Symbol 75 MovieClip Frame 1
this.onPress = function () {
};
this.useHandCursor = false;
Symbol 77 MovieClip [FWG.BtnBack] Frame 1
#initclip 93
Object.registerClass("FWG.BtnBack", FWG.Btn);
#endinitclip
Symbol 81 MovieClip [FWG.MusicCredits] Frame 1
#initclip 94
Object.registerClass("FWG.MusicCredits", FWG.MusicCredits);
#endinitclip
Symbol 90 MovieClip [topChef.FireLight] Frame 1
#initclip 95
Object.registerClass("topChef.FireLight", effect.ClipMov);
#endinitclip
Symbol 166 MovieClip [topChef.Fire] Frame 1
#initclip 96
Object.registerClass("topChef.Fire", effect.ClipMov);
#endinitclip
Symbol 194 MovieClip Frame 11
stop();
Symbol 195 MovieClip Frame 1
stop();
Symbol 353 MovieClip [topChef.ManEffect] Frame 1
#initclip 97
Object.registerClass("topChef.ManEffect", topChef.ManEffect);
#endinitclip
Symbol 354 MovieClip [topChef.Man] Frame 1
#initclip 98
Object.registerClass("topChef.Man", topChef.Man);
#endinitclip
Symbol 355 MovieClip [topChef.PosDot] Frame 1
#initclip 99
Object.registerClass("topChef.PosDot", topChef.PosDot);
#endinitclip
Symbol 359 MovieClip Frame 1
Global.game.setChefBody(this);
Symbol 362 MovieClip Frame 5
head.gotoAndStop(_parent.manId + 1);
Symbol 362 MovieClip Frame 11
head.gotoAndStop(_parent.manId + 1);
Symbol 376 MovieClip [topChef.Plate] Frame 1
#initclip 100
Object.registerClass("topChef.Plate", topChef.Plate);
#endinitclip
Symbol 376 MovieClip [topChef.Plate] Frame 3
Global.game.initThrow(plateHitArea);
Symbol 376 MovieClip [topChef.Plate] Frame 4
Global.game.initThrow(plateHitArea);
Symbol 376 MovieClip [topChef.Plate] Frame 5
Global.game.initThrow(plateHitArea);
Symbol 376 MovieClip [topChef.Plate] Frame 6
Global.game.initThrow(plateHitArea);
Symbol 380 MovieClip Frame 1
Global.game.setChefBody(this);
Symbol 384 MovieClip Frame 1
Global.game.setChefBody(this);
Symbol 388 MovieClip Frame 1
Global.game.setChefBody(this);
Symbol 389 MovieClip Frame 16
gotoAndStop (1);
Symbol 394 MovieClip Frame 1
Global.game.setChefBody(this);
Symbol 398 MovieClip Frame 1
Global.game.setChefBody(this);
Symbol 402 MovieClip Frame 1
Global.game.setChefBody(this);
Symbol 403 MovieClip Frame 5
gotoAndStop (2);
Symbol 407 MovieClip Frame 1
Global.game.setChefBody(this);
Symbol 411 MovieClip Frame 1
Global.game.setChefBody(this);
Symbol 419 MovieClip Frame 1
stop();
Global.addGameDelayRun(this, "play", random(30) + 60);
Symbol 421 MovieClip Frame 7
Global.main.playSound("SndCut");
Symbol 421 MovieClip Frame 12
stop();
_parent.cutFinish();
Symbol 422 MovieClip Frame 1
plate.getFoodFromPlate(_parent.throwFoodObject);
Symbol 422 MovieClip Frame 22
Global.main.playSound("SndBreak");
Symbol 422 MovieClip Frame 27
_parent.onThrowFood();
Symbol 423 MovieClip [topChef.Chef] Frame 1
#initclip 101
Object.registerClass("topChef.Chef", topChef.Chef);
#endinitclip
Symbol 431 MovieClip [ui.SimpleClock] Frame 1
#initclip 102
Object.registerClass("ui.SimpleClock", ui.SimpleClock);
#endinitclip
Symbol 432 MovieClip [topChef.Seat] Frame 1
#initclip 103
Object.registerClass("topChef.Seat", topChef.Seat);
#endinitclip
Symbol 439 MovieClip Frame 1
stop();
Symbol 450 MovieClip Frame 1
_parent.hitArea.gotoAndStop(1);
Symbol 450 MovieClip Frame 2
_parent.hitArea.gotoAndStop(1);
Symbol 450 MovieClip Frame 3
_parent.hitArea.gotoAndStop(2);
Symbol 450 MovieClip Frame 4
_parent.hitArea.gotoAndStop(1);
Symbol 459 MovieClip [topChef.CookingFood0] Frame 1
#initclip 104
Object.registerClass("topChef.CookingFood0", topChef.CookingFood);
#endinitclip
Symbol 483 MovieClip [topChef.CookSmoke] Frame 1
#initclip 105
Object.registerClass("topChef.CookSmoke", effect.ClipMov);
#endinitclip
Symbol 484 MovieClip [topChef.Cooker0] Frame 1
#initclip 106
Object.registerClass("topChef.Cooker0", topChef.Cooker);
#endinitclip
Symbol 484 MovieClip [topChef.Cooker0] Frame 2
stop();
Symbol 489 MovieClip Frame 1
stop();
Symbol 492 MovieClip [topChef.CookingFood1] Frame 1
#initclip 107
Object.registerClass("topChef.CookingFood1", topChef.CookingFood);
#endinitclip
Symbol 493 MovieClip [topChef.Cooker1] Frame 1
#initclip 108
Object.registerClass("topChef.Cooker1", topChef.Cooker);
#endinitclip
Symbol 493 MovieClip [topChef.Cooker1] Frame 2
stop();
Symbol 498 MovieClip Frame 1
stop();
Symbol 503 MovieClip [topChef.CookingFood2] Frame 1
#initclip 109
Object.registerClass("topChef.CookingFood2", topChef.CookingFood);
#endinitclip
Symbol 504 MovieClip [topChef.Cooker2] Frame 1
#initclip 110
Object.registerClass("topChef.Cooker2", topChef.Cooker);
#endinitclip
Symbol 504 MovieClip [topChef.Cooker2] Frame 2
stop();
Symbol 509 MovieClip Frame 1
stop();
Symbol 514 MovieClip [topChef.CutEffect] Frame 1
#initclip 111
Object.registerClass("topChef.CutEffect", effect.ClipMov);
#endinitclip
Symbol 515 MovieClip [topChef.Cooker3] Frame 1
#initclip 112
Object.registerClass("topChef.Cooker3", topChef.Cooker);
#endinitclip
Symbol 515 MovieClip [topChef.Cooker3] Frame 2
stop();
Symbol 518 MovieClip [topChef.TipsChooseAGuy] Frame 1
#initclip 113
Object.registerClass("topChef.TipsChooseAGuy", topChef.TipsChooseAGuy);
#endinitclip
Symbol 521 MovieClip [topChef.TipsChooseACooker] Frame 1
#initclip 114
Object.registerClass("topChef.TipsChooseACooker", topChef.TipsChooseACooker);
#endinitclip
Symbol 524 MovieClip [topChef.TipsChooseACustomer] Frame 1
#initclip 115
Object.registerClass("topChef.TipsChooseACustomer", topChef.TipsChooseACustomer);
#endinitclip
Symbol 530 MovieClip [topChef.Game] Frame 1
#initclip 116
Object.registerClass("topChef.Game", topChef.Game);
#endinitclip
init();
Symbol 542 MovieClip [FWG.BtnOK] Frame 1
#initclip 117
Object.registerClass("FWG.BtnOK", FWG.Btn);
#endinitclip
Symbol 544 MovieClip [FWG.BtnQ0] Frame 1
#initclip 118
Object.registerClass("FWG.BtnQ0", FWG.BtnQ0);
#endinitclip
Symbol 546 MovieClip [FWG.BtnQ1] Frame 1
#initclip 119
Object.registerClass("FWG.BtnQ1", FWG.BtnQ1);
#endinitclip
Symbol 548 MovieClip [FWG.BtnQ2] Frame 1
#initclip 120
Object.registerClass("FWG.BtnQ2", FWG.BtnQ2);
#endinitclip
Symbol 550 MovieClip [FWG.BtnQ3] Frame 1
#initclip 121
Object.registerClass("FWG.BtnQ3", FWG.BtnQ3);
#endinitclip
Symbol 551 MovieClip [FWG.QualitySetting] Frame 1
#initclip 122
Object.registerClass("FWG.QualitySetting", FWG.QualitySetting);
#endinitclip
Symbol 555 MovieClip [FWG.BtnYes] Frame 1
#initclip 123
Object.registerClass("FWG.BtnYes", FWG.Btn);
#endinitclip
Symbol 557 MovieClip [FWG.BtnNo] Frame 1
#initclip 124
Object.registerClass("FWG.BtnNo", FWG.Btn);
#endinitclip
Symbol 558 MovieClip [ui.Alert] Frame 1
#initclip 125
Object.registerClass("ui.Alert", ui.Alert);
#endinitclip
Symbol 559 MovieClip [FWG.PageGame] Frame 1
#initclip 126
Object.registerClass("FWG.PageGame", FWG.PageGame);
#endinitclip
Symbol 575 MovieClip [FWG.SubmitScore] Frame 1
#initclip 127
Object.registerClass("FWG.SubmitScore", FWG.SubmitScore);
#endinitclip
Symbol 576 MovieClip [FWG.PageGameOver] Frame 1
#initclip 128
Object.registerClass("FWG.PageGameOver", FWG.PageGameOver);
#endinitclip
Symbol 579 MovieClip Frame 1
this.onPress = function () {
};
this.useHandCursor = false;
Symbol 583 MovieClip [FWG.BtnSkip] Frame 1
#initclip 129
Object.registerClass("FWG.BtnSkip", FWG.BtnSkip);
#endinitclip
Symbol 585 MovieClip [FWG.BtnNext] Frame 1
#initclip 130
Object.registerClass("FWG.BtnNext", FWG.Btn);
#endinitclip
Symbol 652 MovieClip Frame 16
gotoAndStop (1);
Symbol 674 MovieClip Frame 1
function delay(delayTime) {
stop();
if (isNaN(delayTime)) {
delayTime = 4500;
}
setTimeout(this, "play", delayTime);
}
Symbol 674 MovieClip Frame 15
delay();
Symbol 674 MovieClip Frame 16
delay();
Symbol 674 MovieClip Frame 34
delay();
Symbol 674 MovieClip Frame 90
delay();
Symbol 674 MovieClip Frame 104
delay();
Symbol 674 MovieClip Frame 162
delay();
Symbol 674 MovieClip Frame 165
delay(5500);
Symbol 674 MovieClip Frame 191
delay();
Symbol 674 MovieClip Frame 260
delay();
Symbol 674 MovieClip Frame 261
delay();
Symbol 674 MovieClip Frame 262
delay();
Symbol 675 MovieClip [FWG.Instructions] Frame 1
#initclip 131
Object.registerClass("FWG.Instructions", FWG.Instructions);
#endinitclip
Symbol 676 MovieClip [FWG.PageInst] Frame 1
#initclip 132
Object.registerClass("FWG.PageInst", FWG.PageInst);
#endinitclip
Symbol 684 MovieClip [FWG.Logo] Frame 1
#initclip 133
Object.registerClass("FWG.Logo", FWG.Logo);
#endinitclip
Symbol 685 MovieClip [FWG.PageMenu] Frame 1
#initclip 134
Object.registerClass("FWG.PageMenu", FWG.PageMenu);
#endinitclip
Instance of Symbol 684 MovieClip [FWG.Logo] in Symbol 685 MovieClip [FWG.PageMenu] Frame 1
on (release) {
getURL ("http://www.freeworldgroup.com/", "_blank");
}
Symbol 690 MovieClip [FWG.PageOptions] Frame 1
#initclip 135
Object.registerClass("FWG.PageOptions", FWG.PageOptions);
#endinitclip
Symbol 694 MovieClip [ui.Alt] Frame 1
#initclip 136
Object.registerClass("ui.Alt", ui.Alt);
#endinitclip
Symbol 696 MovieClip [FWG.BtnNs] Frame 1
#initclip 137
Object.registerClass("FWG.BtnNs", FWG.BtnNs);
#endinitclip
Symbol 698 MovieClip [topChef.GhostPosDot] Frame 1
#initclip 138
Object.registerClass("topChef.GhostPosDot", topChef.GhostPosDot);
#endinitclip
Symbol 698 MovieClip [topChef.GhostPosDot] Frame 16
f(0);
Symbol 698 MovieClip [topChef.GhostPosDot] Frame 21
f(1);
Symbol 698 MovieClip [topChef.GhostPosDot] Frame 25
f(2);
Symbol 698 MovieClip [topChef.GhostPosDot] Frame 30
f(3);
Symbol 698 MovieClip [topChef.GhostPosDot] Frame 41
stop();
f();
Symbol 717 MovieClip [ghost0] Frame 1
#initclip 139
Object.registerClass("ghost0", ui.SBtn);
#endinitclip
Symbol 736 MovieClip [topChef.CustomBox] Frame 1
#initclip 140
Object.registerClass("topChef.CustomBox", topChef.CustomBox);
#endinitclip
Symbol 736 MovieClip [topChef.CustomBox] Frame 5
initPay();
Symbol 739 MovieClip [topChef.GhostEffect] Frame 1
#initclip 141
Object.registerClass("topChef.GhostEffect", topChef.GhostEffect);
#endinitclip
Symbol 749 MovieClip [ghost1] Frame 1
#initclip 142
Object.registerClass("ghost1", ui.SBtn);
#endinitclip
Symbol 771 MovieClip [ghost2] Frame 1
#initclip 143
Object.registerClass("ghost2", ui.SBtn);
#endinitclip
Symbol 786 MovieClip [ghost3] Frame 1
#initclip 144
Object.registerClass("ghost3", ui.SBtn);
#endinitclip
Symbol 795 MovieClip [ghost4] Frame 1
#initclip 145
Object.registerClass("ghost4", ui.SBtn);
#endinitclip
Symbol 796 MovieClip [topChef.Ghost] Frame 1
#initclip 146
Object.registerClass("topChef.Ghost", topChef.Ghost);
#endinitclip
init();
Symbol 796 MovieClip [topChef.Ghost] Frame 2
init();
Symbol 796 MovieClip [topChef.Ghost] Frame 3
init();
Symbol 796 MovieClip [topChef.Ghost] Frame 4
init();
Symbol 796 MovieClip [topChef.Ghost] Frame 5
init();
Symbol 800 MovieClip [topChef.ScorePopUp] Frame 1
#initclip 147
Object.registerClass("topChef.ScorePopUp", topChef.ScorePopUp);
#endinitclip
Symbol 800 MovieClip [topChef.ScorePopUp] Frame 45
stop();
this.removeMovieClip();
Symbol 801 MovieClip [topChef.FireBall] Frame 1
#initclip 148
Object.registerClass("topChef.FireBall", topChef.FireBall);
#endinitclip
Symbol 812 MovieClip Frame 11
stop();
Symbol 813 MovieClip [topChef.ChefBurnEffect] Frame 11
onBurn();
Symbol 813 MovieClip [topChef.ChefBurnEffect] Frame 30
onBurnFinish();
this.removeMovieClip();
Symbol 814 MovieClip [burnFire] Frame 39
this.removeMovieClip();
Symbol 820 MovieClip [FWG.PageStageClear] Frame 1
#initclip 149
Object.registerClass("FWG.PageStageClear", FWG.PageStageClear);
#endinitclip
Symbol 826 MovieClip Frame 1
stop();
Symbol 827 MovieClip [FWG.MainContainer] Frame 1
#initclip 150
Object.registerClass("FWG.MainContainer", FWG.MainContainer);
#endinitclip
Symbol 828 MovieClip [effect.SimpleFade] Frame 1
#initclip 151
Object.registerClass("effect.SimpleFade", effect.SimpleFade);
#endinitclip
stop();
Symbol 828 MovieClip [effect.SimpleFade] Frame 10
onHide();
Symbol 828 MovieClip [effect.SimpleFade] Frame 20
onShow();
Symbol 829 MovieClip [FWG.Main] Frame 1
#initclip 152
Object.registerClass("FWG.Main", FWG.Main);
#endinitclip