Frame 1
var nSound = 1;
var nPause = 1;
var _mochiads_game_id = "face0fd12fbcbbb6";
mochi.MochiServices.connect("face0fd12fbcbbb6");
MochiAd.showPreGameAd({id:"face0fd12fbcbbb6", res:"640x480"});
function __com_mochibot__(swfid, mc, lv, trk) {
var x;
var g;
var s;
var fv;
var sb;
var u;
var res;
var mb;
var mbc;
var pv;
mb = "__mochibot__";
mbc = "mochibot.com";
g = (_global ? (_global) : (_level0._root));
if (g[mb + swfid]) {
return(g[mb + swfid]);
}
s = System.security;
x = mc._root.getSWFVersion;
fv = (x ? (mc.getSWFVersion()) : ((_global ? 6 : 5)));
if (!s) {
s = {};
}
sb = s.sandboxType;
if (sb == "localWithFile") {
return(null);
}
x = s.allowDomain;
if (x) {
s.allowDomain(mbc);
}
x = s.allowInsecureDomain;
if (x) {
s.allowInsecureDomain(mbc);
}
pv = ((fv == 5) ? (getVersion()) : (System.capabilities.version));
u = (((((((((((("http://" + mbc) + "/my/core.swf?mv=8&fv=") + fv) + "&v=") + escape(pv)) + "&swfid=") + escape(swfid)) + "&l=") + lv) + "&f=") + mc) + (sb ? ("&sb=" + sb) : "")) + (trk ? "&t=1" : "");
lv = ((fv > 6) ? (mc.getNextHighestDepth()) : ((g[mb + "level"] ? (g[mb + "level"] + 1) : (lv))));
g[mb + "level"] = lv;
if (fv == 5) {
res = "_level" + lv;
if (!eval (res)) {
loadMovieNum (u, lv);
}
} else {
res = mc.createEmptyMovieClip(mb + swfid, lv);
res.loadMovie(u);
}
return(res);
}
__com_mochibot__("060e61e0", this, 10301, true);
Frame 2
mochi.MochiServices.addLinkEvent("http://x.mochiads.com/link/80f74814b7799d3e", "http://www.myfootballgames.co.uk", _root.cMFGSplash);
stop();
Instance of Symbol 31 MovieClip "cSkip" in Frame 2
on (release) {
_root.gotoAndPlay(4);
}
Frame 3
stop();
Frame 4
function InitGame() {
var _local2 = 0;
while (_local2 < 12) {
_root.vcPlayers[_local2] = _root.cPlayerTemplate.duplicateMovieClip("cPlayer" + _local2, _root.getNextHighestDepth(), {_x:320, _y:240});
_root.vcPlayers[_local2].filters = [_root.fShadow];
_local2++;
}
_root.vcGates[0] = _root.cGateTemplate.duplicateMovieClip("cGateBlue", _root.getNextHighestDepth(), {_x:321, _y:885});
_root.vcGates[0].filters = [_root.fShadow];
_root.vcGates[1] = _root.cGateTemplate.duplicateMovieClip("cGateRed", _root.getNextHighestDepth(), {_x:321, _y:-388});
_root.vcGates[1]._rotation = 180;
_root.vcGates[1].filters = [_root.fShadow];
if (_root.cScore) {
_root.cScore.removeMovieClip();
}
if (_root.cScores) {
_root.cScores.removeMovieClip();
}
if (_root.cMenu) {
_root.cMenu.removeMovieClip();
}
if (_root.cOnPause) {
_root.cOnPause.removeMovieClip();
}
if (_root.cTimer) {
_root.cTimer.removeMovieClip();
}
if (_root.cMouse) {
_root.cMouse.removeMovieClip();
}
if (_root.cResult) {
_root.cResult.removeMovieClip();
}
if (_root.cPlayMore) {
_root.cPlayMore.removeMovieClip();
}
_root.cScoreTemplate.duplicateMovieClip("cScore", _root.getNextHighestDepth(), {_x:-900, _y:240});
_root.cScoresTemplate.duplicateMovieClip("cScores", _root.getNextHighestDepth(), {_x:-900, _y:240});
_root.cMenuTemplate.duplicateMovieClip("cMenu", _root.getNextHighestDepth(), {_x:-500, _y:240});
_root.cOnPauseTemplate.duplicateMovieClip("cOnPause", _root.getNextHighestDepth(), {_x:-600, _y:240});
_root.cTimerTemplate.duplicateMovieClip("cTimer", _root.getNextHighestDepth(), {_x:-800, _y:240});
_root.cResultTemplate.duplicateMovieClip("cResult", _root.getNextHighestDepth(), {_x:-1000, _y:240});
_root.cPlayMoreTemplate.duplicateMovieClip("cPlayMore", _root.getNextHighestDepth(), {_x:-1000, _y:240});
mochi.MochiServices.addLinkEvent("http://x.mochiads.com/link/dd47e7029b3b6f5f", "http://www.myfootballgames.co.uk", _root.cPlayMore);
_root.nInterval = setInterval(_root.cTimer, "TickTack", 1000);
if (_root.nSound == 0) {
_root.cSound.gotoAndStop(2);
}
}
function ShutGame() {
clearInterval(_root.nInterval);
var _local2 = 0;
while (_local2 < 12) {
_root.vcPlayers[_local2].removeMovieClip();
_local2++;
}
_root.vcGates[0].removeMovieClip();
_root.vcGates[1].removeMovieClip();
_root.cBall._x = -660;
_root.cSelection._x = -620;
_root.cScore._x = -1000;
_root.cScores._x = -1000;
_root.cMenu._x = -1000;
_root.cOnPause._x = -1000;
_root.cTimer._x = -1000;
_root.cMouse._x = -1000;
_root.cResult._x = -1000;
_root.cPlayMore._x = -1000;
_root._x = 0;
_root._y = 0;
Mouse.show();
_root.nPause = 1;
}
function InitPlayers(nGoFull, nBallTeam) {
_root._x = 0;
_root._y = 0;
_root.cField._x = 320;
_root.cField._y = 240;
_root.vcPlayers[0].Init(Math.round(Math.random() * 2), (315 + (Math.random() * 200)) - 100, (490 + (Math.random() * 100)) - 50, 1);
_root.vcPlayers[0]._nRole = -1;
_root.vcPlayers[1].Init(Math.round(Math.random() * 2), (25 + (Math.random() * 200)) - 100, (560 + (Math.random() * 100)) - 50, 1);
_root.vcPlayers[2].Init(Math.round(Math.random() * 2), (25 + (Math.random() * 200)) - 100, (370 + (Math.random() * 100)) - 50, 1);
_root.vcPlayers[3].Init(Math.round(Math.random() * 2), (605 + (Math.random() * 200)) - 100, (560 + (Math.random() * 100)) - 50, 1);
_root.vcPlayers[4].Init(Math.round(Math.random() * 2), (605 + (Math.random() * 200)) - 100, (370 + (Math.random() * 100)) - 50, 1);
_root.cCurPlayer = _root.vcPlayers[0];
_root.cSelection.Move(-1000, -1000, -1);
_root.vcPlayers[5].Init(Math.round(Math.random() * 2) + 4, (315 + (Math.random() * 200)) - 100, (10 + (Math.random() * 100)) - 50, -1);
_root.vcPlayers[6].Init(Math.round(Math.random() * 2) + 4, (25 + (Math.random() * 200)) - 100, (130 + (Math.random() * 100)) - 50, -1);
_root.vcPlayers[7].Init(Math.round(Math.random() * 2) + 4, (25 + (Math.random() * 200)) - 100, (-60 + (Math.random() * 100)) - 50, -1);
_root.vcPlayers[8].Init(Math.round(Math.random() * 2) + 4, (605 + (Math.random() * 200)) - 100, (130 + (Math.random() * 100)) - 50, -1);
_root.vcPlayers[9].Init(Math.round(Math.random() * 2) + 4, (605 + (Math.random() * 200)) - 100, (-60 + (Math.random() * 100)) - 50, -1);
_root.vcPlayers[10].Init(3, 320, 800, 1);
_root.vcPlayers[10]._nRole = 5;
_root.vcPlayers[11].Init(3, 320, -320, -1);
_root.vcPlayers[11]._nRole = 5;
if (nGoFull == 1) {
stopAllSounds();
_root.cBallPlayer = _root.vcPlayers[0];
_root.cBall._nTeam = 1;
_root.cBall._x = -1000;
_root.cResult.PlayGoFull();
_root.cTimer.Reset();
_root.cScore.Reset();
_root.cScores.Reset();
_root.cMouseTemplate.duplicateMovieClip("cMouse", _root.getNextHighestDepth(), {_x:-1100, _y:240});
_root.cMouse.filters = [_root.fShadowMouse];
Mouse.hide();
} else {
if (nBallTeam == 1) {
_root.cBallPlayer = _root.vcPlayers[0];
_root.cBall._nTeam = 1;
} else {
_root.cBallPlayer = _root.vcPlayers[5];
_root.cBall._nTeam = -1;
}
_root.cResult.PlayGoEnd();
}
_root.cScore._x = 505 - _root._x;
_root.cScore._y = 10 - _root._y;
_root.cScores._x = 305 - _root._x;
_root.cScores._y = 10 - _root._y;
_root.cMenu._x = 25 - _root._x;
_root.cMenu._y = 10 - _root._y;
_root.cTimer._x = 85 - _root._x;
_root.cTimer._y = 10 - _root._y;
_root.cPlayMore._x = 538 - _root._x;
_root.cPlayMore._y = 450 - _root._y;
}
function PlaySound(sSound) {
if (_root.nSound == 1) {
var _local2 = new Sound(_root.cPlaySound);
_local2.attachSound(sSound);
_local2.start();
}
}
var vcPlayers = new Array(12);
var vcGates = new Array(2);
var fShadow = (new flash.filters.DropShadowFilter(6, 45, 0, 0.4, 2, 2, 1, 1, false, false, false));
var fShadowMouse = (new flash.filters.DropShadowFilter(4, 45, 0, 0.4, 2, 2, 1, 1, false, false, false));
var cCurPlayer = null;
var cBallPlayer = null;
var nInterval = null;
var nScores = -1;
stopAllSounds();
mochi.MochiServices.addLinkEvent("http://x.mochiads.com/link/6816dd948665f04b", "http://www.myfootballgames.co.uk", _root.cMFGMenu);
InitGame();
stop();
Instance of Symbol 140 MovieClip "cSelection" in Frame 4
onClipEvent (enterFrame) {
if (this._alpha > 30) {
this._alpha = this._alpha - 2;
this._rotation = this._rotation + 15;
} else {
this._rotation = this._rotation + 5;
}
}
Instance of Symbol 331 MovieClip "cInput" in Frame 5
onClipEvent (enterFrame) {
if (_root.nPause == 1) {
return(undefined);
}
var cp = _root.cCurPlayer;
cp.GetRotate(_root._xmouse, _root._ymouse);
var bKey = false;
if (cp.GetDistance(_root.cMouse._x, _root.cMouse._y) > 60) {
cp._fMoveX = 6 * cp._fSin;
cp._fMoveY = 6 * cp._fCos;
cp._nAct = 1;
bKey = true;
}
if ((Key.isDown(32) || (Key.isDown(16))) && (_root.cBall._nTeam != 1)) {
var np = _root.cBall.FindClosest(0, 4);
_root.cCore.SetCurPlayer(np);
bKey = true;
}
if (bKey == false) {
cp._fMoveX = 0;
cp._fMoveY = 0;
cp._nAct = 0;
}
}
onClipEvent (keyUp) {
if (((_root.cGo._nPlay == 1) || (_root.cGoal._nPlay == 1)) || (_root.cResult._nPlay == 1)) {
return(undefined);
}
if (Key.getCode() == 80) {
_root.nPause = ((_root.nPause == 1) ? 0 : 1);
if (_root.nPause == 1) {
_root.cOnPause._x = 320 - _root._x;
_root.cOnPause._y = 120 - _root._y;
Mouse.show();
} else {
_root.cOnPause._x = -850;
Mouse.hide();
}
} else if (Key.getCode() == 83) {
stopAllSounds();
_root.nSound = ((_root.nSound == 1) ? 0 : 1);
} else if (Key.getCode() == 77) {
_root.ShutGame();
_root.gotoAndPlay(4);
}
}
onClipEvent (mouseUp) {
if (_root.nPause == 1) {
return(undefined);
}
_root.cCurPlayer._nKick = 1;
}
Instance of Symbol 333 MovieClip "cCore" in Frame 5
onClipEvent (load) {
_root.InitPlayers(1, 1);
}
onClipEvent (enterFrame) {
if (_root.nPause == 1) {
return(undefined);
}
var p = null;
var b = _root.cBall;
var f = _root.cField;
var i = 0;
while (i < 12) {
p = _root.vcPlayers[i];
if (p._rotation != p._fRotate) {
p._rotation = p._fRotate;
}
if ((((((p._nRole == -1) && (p._nAct == 1)) || (((p._nRole == 1) || (p._nRole == 3)) && (p._nAct == 1))) || ((p._nRole == 5) && (((p._nAct == 1) || (p._nAct == 2)) || (p._nAct == 6)))) || ((p._nRole == 4) && (p._nAct == 1))) || ((p._nRole == 2) && ((p._nAct == 1) || (p._nAct == 3)))) {
var fx = (p._x + p._fMoveX);
var fy = (p._y - p._fMoveY);
var is = 0;
if ((fx > -145) && (fx < 785)) {
p._x = fx;
}
if ((fy > -395) && (fy < 890)) {
p._y = fy;
}
p.AnimateRun();
if (p == _root.cBallPlayer) {
b.Animate();
}
}
if (_root.cBallPlayer == null) {
if (p.CheckCollision(b, true, true)) {
SetBallPlayer(b, p);
ResetPlayers();
}
}
if (p._nKick > 0) {
if (p == _root.cBallPlayer) {
_root.PlaySound(((Math.random() > 0.5) ? "kick" : "kick2"));
b._fCos = p._fCos;
b._fSin = p._fSin;
b._fVelocity = 30;
b._nTeam = 0;
p.Kick();
_root.cBallPlayer = null;
} else {
p.Kick();
if (p.CheckCollision(b, false, true)) {
if (((i >= 10) || ((p._nTeam == -1) && (Math.random() >= 0.2))) || ((p._nTeam == 1) && (Math.random() >= 0.65))) {
SetBallPlayer(b, p);
}
}
}
p._nKick = 0;
ResetPlayers();
}
i++;
}
if (_root.cGateBlue.hitTest(b)) {
if (b.CheckGate(1) == 1) {
var dx = ((b._x + _root._x) - 320);
var dy = ((b._y + _root._y) - 240);
_root._x = _root._x - dx;
_root._y = _root._y - dy;
_root.cScore.GoalRed();
_root.cScores.OnGoal(-1);
_root.cResult.PlayGoal(1);
}
} else if (_root.cGateRed.hitTest(b)) {
if (b.CheckGate(-1) == 1) {
_root.cScore.GoalBlue();
_root.cScores.OnGoal(1);
_root.cResult.PlayGoal(-1);
}
}
p = _root.cCurPlayer;
_root.cSelection.Move(p._x, p._y, -1);
_root.cMouse._x = _root._xmouse;
_root.cMouse._y = _root._ymouse;
_root.cMouse._rotation = p._rotation;
var dx = ((p._x + _root._x) - 320);
var dy = ((p._y + _root._y) - 240);
if (Math.abs(dx) > _root.cAI.SPEED) {
dx = dx / 4;
}
if (Math.abs(dy) > _root.cAI.SPEED) {
dy = dy / 4;
}
if (Math.abs(dx) < 0.1) {
dx = 0;
}
if (Math.abs(dy) < 0.1) {
dy = 0;
}
_root._x = _root._x - dx;
_root._y = _root._y - dy;
_root.cScore._x = 505 - _root._x;
_root.cScore._y = 10 - _root._y;
_root.cScores._x = 305 - _root._x;
_root.cScores._y = 10 - _root._y;
_root.cMenu._x = 25 - _root._x;
_root.cMenu._y = 10 - _root._y;
_root.cTimer._x = 85 - _root._x;
_root.cTimer._y = 10 - _root._y;
_root.cPlayMore._x = 538 - _root._x;
_root.cPlayMore._y = 450 - _root._y;
b._fPX = b._x;
b._fPY = b._y;
if (_root.cBallPlayer != null) {
p = _root.cBallPlayer;
b._x = p._x + (32 * p._fSin);
b._y = p._y - (32 * p._fCos);
b._rotation = p._rotation;
} else if (b._fVelocity > 0) {
var bx = (b._x + (b._fVelocity * b._fSin));
var by = (b._y - (b._fVelocity * b._fCos));
if ((bx < -170) || (bx > 810)) {
b._fSin = -b._fSin;
}
if ((by < -425) || (by > 905)) {
b._fCos = -b._fCos;
}
b._x = b._x + (b._fVelocity * b._fSin);
b._y = b._y - (b._fVelocity * b._fCos);
b._fVelocity--;
if (b._fVelocity > 2) {
b.Animate();
}
if (b._fVelocity > 8) {
b.Animate();
}
if (b._fVelocity > 16) {
b.Animate();
}
if (b._fVelocity > 24) {
b.Animate();
}
} else {
if (b._x < -170) {
b._x = -170;
}
if (b._x > 810) {
b._x = 810;
}
if (b._y < -430) {
b._y = 430;
}
if (b._y > 910) {
b._y = 910;
}
}
}
Instance of Symbol 335 MovieClip "cAI" in Frame 5
onClipEvent (enterFrame) {
if (_root.nPause == 1) {
return(undefined);
}
var bt = _root.cBall._nTeam;
var bx = _root.cBall._x;
var by = _root.cBall._y;
var bp = _root.cBallPlayer;
var cpb = _root.cBall.FindClosest(0, 4, _root.cCurPlayer);
var cpr = _root.cBall.FindClosest(5, 9);
if (bt == 0) {
var i = 0;
while (i < 5) {
var p = _root.vcPlayers[i];
if ((p._nRole == 4) && (p != cpb)) {
SetRole(p, 0);
}
i++;
}
if ((cpb._nRole != -1) && (cpb._nRole != 4)) {
SetRole(cpb, 4);
}
var i = 5;
while (i < 10) {
var p = _root.vcPlayers[i];
if ((p._nRole == 4) && (p != cpr)) {
SetRole(p, 0);
}
i++;
}
if (cpr._nRole != 4) {
SetRole(cpr, 4);
}
} else if (bt == 1) {
var i = 0;
while (i < 5) {
var p = _root.vcPlayers[i];
if (p._nRole == 0) {
var rand = Math.random();
if (rand > 0) {
SetRole(p, 3);
} else {
SetRole(p, 1);
}
}
i++;
}
var i = 5;
while (i < 10) {
var p = _root.vcPlayers[i];
if (p._nRole == 0) {
SetRole(p, 1);
}
i++;
}
if ((bp._nRole != 5) && (cpr._nRole != 4)) {
SetRole(cpr, 4);
}
} else if (bt == -1) {
var i = 0;
while (i < 5) {
var p = _root.vcPlayers[i];
if (p._nRole == 0) {
SetRole(p, 1);
}
i++;
}
if (((cpb._nRole != -1) && (bp._nRole != 5)) && (cpb._nRole != 4)) {
SetRole(cpb, 4);
}
var i = 5;
while (i < 10) {
var p = _root.vcPlayers[i];
if (p._nRole == 0) {
var rand = (Math.random() - 0.7);
if (rand > 0) {
SetRole(p, 1);
} else {
SetRole(p, 3);
}
}
i++;
}
if ((bp._nRole != 5) && (bp._nRole != 2)) {
SetRole(bp, 2);
}
}
var i = 0;
while (i < 12) {
var p = _root.vcPlayers[i];
SetAction(p);
i++;
}
}
Frame 7
if (((_root.cTimer._nSecs <= 0) && (_root.cResult._nPlay == 0)) && (_root.nPause == 0)) {
_root.ShutGame();
if (_root.cResult._nSubmit == 1) {
_root.gotoAndPlay(10);
} else {
_root.gotoAndPlay(4);
}
} else {
_root.gotoAndPlay(5);
}
Frame 9
mochi.MochiServices.addLinkEvent("http://x.mochiads.com/link/0ba74b6bbd7f702e", "http://www.myfootballgames.co.uk", _root.cMFGCredits);
Frame 10
if (_root.nScores == -1) {
mochi.MochiScores.showLeaderboard({boardID:"2aca3af978628efe", width:640, height:480, onClose:function () {
_root.ShutGame();
_root.gotoAndStop(4);
}});
} else {
mochi.MochiScores.showLeaderboard({boardID:"2aca3af978628efe", score:_root.nScores, width:640, height:480, onClose:function () {
_root.gotoAndStop(4);
}});
}
stop();
Symbol 363 MovieClip [__Packages.mochi.MochiServices] Frame 0
class mochi.MochiServices
{
static var _id, _container, _clip, _sendChannelName, __get__comChannelName, onError, _listenChannel, _loader, _loaderListener, _sendChannel;
function MochiServices () {
}
static function get id() {
return(_id);
}
static function get clip() {
return(_container);
}
static function get childClip() {
return(_clip);
}
static function getVersion() {
return("1.43");
}
static function allowDomains(server) {
var _local1 = server.split("/")[2].split(":")[0];
if (System.security) {
if (System.security.allowDomain) {
System.security.allowDomain("*");
System.security.allowDomain(_local1);
}
if (System.security.allowInsecureDomain) {
System.security.allowInsecureDomain("*");
System.security.allowInsecureDomain(_local1);
}
}
return(_local1);
}
static function get isNetworkAvailable() {
if (System.security) {
var _local1 = System.security;
if (_local1.sandboxType == "localWithFile") {
return(false);
}
}
return(true);
}
static function set comChannelName(val) {
if (val != undefined) {
if (val.length > 3) {
_sendChannelName = val + "_fromgame";
initComChannels();
}
}
//return(__get__comChannelName());
}
static function get connected() {
return(_connected);
}
static function connect(id, clip, onError) {
if ((!_connected) && (_clip == undefined)) {
_connecting = true;
init(id, clip);
}
if (onError != undefined) {
mochi.MochiServices.onError = onError;
} else if (mochi.MochiServices.onError == undefined) {
mochi.MochiServices.onError = function (errorCode) {
};
}
}
static function disconnect() {
if (_connected || (_connecting)) {
_connecting = (_connected = false);
flush(true);
if (_clip != undefined) {
_clip.removeMovieClip();
delete _clip;
}
_listenChannel.close();
}
}
static function init(id, clip) {
_id = id;
if (clip != undefined) {
_container = clip;
} else {
_container = _root;
}
loadCommunicator(id, _container);
}
static function loadCommunicator(id, clip) {
var _local3 = "_mochiservices_com_" + id;
if (_clip != null) {
return(_clip);
}
if (!isNetworkAvailable) {
return(null);
}
if (urlOptions().servicesURL != undefined) {
_servicesURL = urlOptions().servicesURL;
}
allowDomains(_servicesURL);
_clip = clip.createEmptyMovieClip(_local3, 10336, false);
_listenChannelName = _listenChannelName + ((Math.floor(new Date().getTime()) + "_") + Math.floor(Math.random() * 99999));
_loader = new MovieClipLoader();
if (_loaderListener.waitInterval != null) {
clearInterval(_loaderListener.waitInterval);
}
_loaderListener = {};
_loaderListener.onLoadError = function (target_mc, errorCode, httpStatus) {
mochi.MochiServices.disconnect();
mochi.MochiServices.onError.apply(null, [errorCode]);
};
_loaderListener.onLoadStart = function (target_mc) {
this.isLoading = true;
};
_loaderListener.startTime = getTimer();
_loaderListener.wait = function () {
if ((getTimer() - this.startTime) > 10000) {
if (!this.isLoading) {
mochi.MochiServices.disconnect();
mochi.MochiServices.onError.apply(null, ["IOError"]);
}
clearInterval(this.waitInterval);
}
};
_loaderListener.waitInterval = setInterval(_loaderListener, "wait", 1000);
_loader.addListener(_loaderListener);
_loader.loadClip((((_servicesURL + "?listenLC=") + _listenChannelName) + "&mochiad_options=") + escape(_root.mochiad_options), _clip);
_sendChannel = new LocalConnection();
_sendChannel._queue = [];
listen();
return(_clip);
}
static function onStatus(infoObject) {
if (!(infoObject.level === "error")) {
} else {
_connected = false;
_listenChannel.connect(_listenChannelName);
}
}
static function listen() {
_listenChannel = new LocalConnection();
_listenChannel.handshake = function (args) {
mochi.MochiServices.__set__comChannelName(args.newChannel);
};
_listenChannel.allowDomain = function (d) {
return(true);
};
_listenChannel.allowInsecureDomain = _listenChannel.allowDomain;
_listenChannel._nextcallbackID = 0;
_listenChannel._callbacks = {};
_listenChannel.connect(_listenChannelName);
}
static function initComChannels() {
if (!_connected) {
_sendChannel.onStatus = function (infoObject) {
mochi.MochiServices.onStatus(infoObject);
};
_sendChannel.send(_sendChannelName, "onReceive", {methodName:"handshakeDone"});
_sendChannel.send(_sendChannelName, "onReceive", {methodName:"registerGame", id:_id, clip:_clip, version:getVersion()});
_listenChannel.onStatus = function (infoObject) {
mochi.MochiServices.onStatus(infoObject);
};
_listenChannel.onReceive = function (pkg) {
var _local5 = pkg.callbackID;
var _local4 = this._callbacks[_local5];
if (!_local4) {
return(undefined);
}
var _local2 = _local4.callbackMethod;
var _local3 = _local4.callbackObject;
if (_local3 && (typeof(_local2) == "string")) {
_local2 = _local3[_local2];
}
if (_local2 != undefined) {
_local2.apply(_local3, pkg.args);
}
delete this._callbacks[_local5];
};
_listenChannel.onError = function () {
mochi.MochiServices.onError.apply(null, ["IOError"]);
};
_connecting = false;
_connected = true;
while (_sendChannel._queue.length > 0) {
_sendChannel.send(_sendChannelName, "onReceive", _sendChannel._queue.shift());
}
}
}
static function flush(error) {
var _local1;
var _local2;
while (_sendChannel._queue.length > 0) {
_local1 = _sendChannel._queue.shift();
if (_local1.callbackID != null) {
_local2 = _listenChannel._callbacks[_local1.callbackID];
}
delete _listenChannel._callbacks[_local1.callbackID];
if (error) {
handleError(_local1.args, _local2.callbackObject, _local2.callbackMethod);
}
}
}
static function handleError(args, callbackObject, callbackMethod) {
if (args != null) {
if (args.onError != null) {
args.onError.apply(null, ["NotConnected"]);
}
if ((args.options != null) && (args.options.onError != null)) {
args.options.onError.apply(null, ["NotConnected"]);
}
}
if (callbackMethod != null) {
args = {};
args.error = true;
args.errorCode = "NotConnected";
if ((callbackObject != null) && (typeof(callbackMethod) == "string")) {
callbackObject[callbackMethod](args);
} else if (callbackMethod != null) {
callbackMethod.apply(args);
}
}
}
static function send(methodName, args, callbackObject, callbackMethod) {
if (_connected) {
_sendChannel.send(_sendChannelName, "onReceive", {methodName:methodName, args:args, callbackID:_listenChannel._nextcallbackID});
} else {
if ((_clip == undefined) || (!_connecting)) {
onError.apply(null, ["NotConnected"]);
handleError(args, callbackObject, callbackMethod);
flush(true);
return(undefined);
}
_sendChannel._queue.push({methodName:methodName, args:args, callbackID:_listenChannel._nextcallbackID});
}
_listenChannel._callbacks[_listenChannel._nextcallbackID] = {callbackObject:callbackObject, callbackMethod:callbackMethod};
_listenChannel._nextcallbackID++;
}
static function urlOptions() {
var _local5 = {};
if (_root.mochiad_options) {
var _local4 = _root.mochiad_options.split("&");
var _local2 = 0;
while (_local2 < _local4.length) {
var _local3 = _local4[_local2].split("=");
_local5[unescape(_local3[0])] = unescape(_local3[1]);
_local2++;
}
}
return(_local5);
}
static function addLinkEvent(url, burl, btn, onClick) {
var timeout = 1500;
var t0 = getTimer();
var _local2 = new Object();
_local2.mav = getVersion();
_local2.swfv = btn.getSWFVersion() || 6;
_local2.swfurl = btn._url;
_local2.fv = System.capabilities.version;
_local2.os = System.capabilities.os;
_local2.lang = System.capabilities.language;
_local2.scres = (System.capabilities.screenResolutionX + "x") + System.capabilities.screenResolutionY;
var s = "?";
var _local3 = 0;
for (var _local6 in _local2) {
if (_local3 != 0) {
s = s + "&";
}
_local3++;
s = ((s + _local6) + "=") + escape(_local2[_local6]);
}
if (!(netupAttempted || (_connected))) {
var ping = btn.createEmptyMovieClip("ping", 777);
var _local7 = btn.createEmptyMovieClip("nettest", 778);
netupAttempted = true;
ping.loadMovie("http://x.mochiads.com/linkping.swf?t=" + getTimer());
_local7.onEnterFrame = function () {
if ((ping._totalframes > 0) && (ping._totalframes == ping._framesloaded)) {
delete this.onEnterFrame;
} else if ((getTimer() - t0) > timeout) {
delete this.onEnterFrame;
mochi.MochiServices.netup = false;
}
};
}
var _local4 = btn.createEmptyMovieClip("clk", 1001);
_local4._alpha = 0;
_local4.beginFill(1044735);
_local4.moveTo(0, 0);
_local4.lineTo(0, btn._height);
_local4.lineTo(btn._width, btn._height);
_local4.lineTo(btn._width, 0);
_local4.lineTo(0, 0);
_local4.endFill();
_local4.onRelease = function () {
if (mochi.MochiServices.netup) {
getURL (url + s, "_blank");
} else {
getURL (burl, "_blank");
}
if (onClick != undefined) {
onClick();
}
};
}
static var _servicesURL = "http://www.mochiads.com/static/lib/services/services.swf";
static var _listenChannelName = "__ms_";
static var _connecting = false;
static var _connected = false;
static var netup = true;
static var netupAttempted = false;
}
Symbol 364 MovieClip [__Packages.MochiAd] Frame 0
class MochiAd
{
function MochiAd () {
}
static function getVersion() {
return("2.7");
}
static function showPreGameAd(options) {
var _local26 = {clip:_root, ad_timeout:3000, fadeout_time:250, regpt:"o", method:"showPreloaderAd", color:16747008, background:16777161, outline:13994812, no_progress_bar:false, ad_started:function () {
this.clip.stop();
}, ad_finished:function () {
this.clip.play();
}, ad_failed:function () {
}, ad_loaded:function (width, height) {
}, ad_skipped:function () {
}, ad_progress:function (percent) {
}};
options = _parseOptions(options, _local26);
if ("c862232051e0a94e1c3609b3916ddb17".substr(0) == "dfeada81ac97cde83665f81c12da7def") {
options.ad_started();
options.ad_finished();
return(undefined);
}
var clip = options.clip;
var _local22 = 11000;
var _local25 = options.ad_timeout;
delete options.ad_timeout;
var fadeout_time = options.fadeout_time;
delete options.fadeout_time;
if (!load(options)) {
options.ad_failed();
options.ad_finished();
return(undefined);
}
options.ad_started();
var mc = clip._mochiad;
mc.onUnload = function () {
options.ad_finished();
};
var _local14 = _getRes(options);
var _local4 = _local14[0];
var _local13 = _local14[1];
mc._x = _local4 * 0.5;
mc._y = _local13 * 0.5;
var chk = mc.createEmptyMovieClip("_mochiad_wait", 3);
chk._x = _local4 * -0.5;
chk._y = _local13 * -0.5;
var _local6 = chk.createEmptyMovieClip("_mochiad_bar", 4);
if (options.no_progress_bar) {
_local6._visible = false;
delete options.no_progress_bar;
} else {
_local6._x = 10;
_local6._y = _local13 - 20;
}
var _local21 = options.color;
delete options.color;
var _local19 = options.background;
delete options.background;
var _local23 = options.outline;
delete options.outline;
var _local5 = _local6.createEmptyMovieClip("_outline", 1);
_local5.beginFill(_local19);
_local5.moveTo(0, 0);
_local5.lineTo(_local4 - 20, 0);
_local5.lineTo(_local4 - 20, 10);
_local5.lineTo(0, 10);
_local5.lineTo(0, 0);
_local5.endFill();
var _local3 = _local6.createEmptyMovieClip("_inside", 2);
_local3.beginFill(_local21);
_local3.moveTo(0, 0);
_local3.lineTo(_local4 - 20, 0);
_local3.lineTo(_local4 - 20, 10);
_local3.lineTo(0, 10);
_local3.lineTo(0, 0);
_local3.endFill();
_local3._xscale = 0;
var _local7 = _local6.createEmptyMovieClip("_outline", 3);
_local7.lineStyle(0, _local23, 100);
_local7.moveTo(0, 0);
_local7.lineTo(_local4 - 20, 0);
_local7.lineTo(_local4 - 20, 10);
_local7.lineTo(0, 10);
_local7.lineTo(0, 0);
chk.ad_msec = _local22;
chk.ad_timeout = _local25;
chk.started = getTimer();
chk.showing = false;
chk.last_pcnt = 0;
chk.fadeout_time = fadeout_time;
chk.fadeFunction = function () {
var _local2 = 100 * (1 - ((getTimer() - this.fadeout_start) / this.fadeout_time));
if (_local2 > 0) {
this._parent._alpha = _local2;
} else {
var _local3 = this._parent._parent;
MochiAd.unload(_local3);
delete this.onEnterFrame;
}
};
mc.lc.regContLC = function (lc_name) {
mc._containerLCName = lc_name;
};
var sendHostProgress = false;
mc.lc.sendHostLoadProgress = function (lc_name) {
sendHostProgress = true;
};
mc.lc.adLoaded = options.ad_loaded;
mc.lc.adSkipped = options.ad_skipped;
mc.lc.adjustProgress = function (msec) {
var _local2 = this.mc._mochiad_wait;
_local2.server_control = true;
_local2.started = getTimer();
_local2.ad_msec = msec;
};
mc.lc.rpc = function (callbackID, arg) {
MochiAd.rpc(clip, callbackID, arg);
};
mc.rpcTestFn = function (s) {
return(s);
};
chk.onEnterFrame = function () {
var _local6 = this._parent._parent;
var _local11 = this._parent._mochiad_ctr;
var _local5 = getTimer() - this.started;
var _local3 = false;
var _local4 = _local6.getBytesTotal();
var _local8 = _local6.getBytesLoaded();
var _local2 = (100 * _local8) / _local4;
var _local10 = (100 * _local5) / chk.ad_msec;
var _local9 = this._mochiad_bar._inside;
var _local13 = Math.min(100, Math.min(_local2 || 0, _local10));
_local13 = Math.max(this.last_pcnt, _local13);
this.last_pcnt = _local13;
_local9._xscale = _local13;
options.ad_progress(_local13);
if (sendHostProgress) {
clip._mochiad.lc.send(clip._mochiad._containerLCName, "notify", {id:"hostLoadPcnt", pcnt:_local2});
if (_local2 == 100) {
sendHostProgress = false;
}
}
if (!chk.showing) {
var _local7 = _local11.getBytesTotal();
if ((_local7 > 0) || (typeof(_local7) == "undefined")) {
chk.showing = true;
chk.started = getTimer();
} else if ((_local5 > chk.ad_timeout) && (_local2 == 100)) {
options.ad_failed();
_local3 = true;
}
}
if (_local5 > chk.ad_msec) {
_local3 = true;
}
if (((_local4 > 0) && (_local8 >= _local4)) && (_local3)) {
if (this.server_control) {
delete this.onEnterFrame;
} else {
this.fadeout_start = getTimer();
this.onEnterFrame = chk.fadeFunction;
}
}
};
}
static function showClickAwayAd(options) {
var _local9 = {clip:_root, ad_timeout:2000, fadeout_time:250, regpt:"o", method:"showClickAwayAd", res:"300x250", no_bg:true, ad_started:function () {
}, ad_finished:function () {
}, ad_loaded:function (width, height) {
}, ad_failed:function () {
}, ad_skipped:function () {
}};
options = _parseOptions(options, _local9);
var clip = options.clip;
var _local8 = options.ad_timeout;
delete options.ad_timeout;
if (!load(options)) {
options.ad_failed();
options.ad_finished();
return(undefined);
}
options.ad_started();
var mc = clip._mochiad;
mc.onUnload = function () {
options.ad_finished();
};
var _local4 = _getRes(options);
var _local10 = _local4[0];
var _local7 = _local4[1];
mc._x = _local10 * 0.5;
mc._y = _local7 * 0.5;
var chk = mc.createEmptyMovieClip("_mochiad_wait", 3);
chk.ad_timeout = _local8;
chk.started = getTimer();
chk.showing = false;
mc.lc.adLoaded = options.ad_loaded;
mc.lc.adSkipped = options.ad_skipped;
mc.lc.rpc = function (callbackID, arg) {
MochiAd.rpc(clip, callbackID, arg);
};
mc.rpcTestFn = function (s) {
return(s);
};
var _local20 = false;
mc.lc.regContLC = function (lc_name) {
mc._containerLCName = lc_name;
};
chk.onEnterFrame = function () {
var _local5 = this._parent._mochiad_ctr;
var _local4 = getTimer() - this.started;
var _local2 = false;
if (!chk.showing) {
var _local3 = _local5.getBytesTotal();
if ((_local3 > 0) || (typeof(_local3) == "undefined")) {
_local2 = true;
chk.showing = true;
chk.started = getTimer();
} else if (_local4 > chk.ad_timeout) {
options.ad_failed();
_local2 = true;
}
}
if (_local2) {
delete this.onEnterFrame;
}
};
}
static function showInterLevelAd(options) {
var _local13 = {clip:_root, ad_timeout:2000, fadeout_time:250, regpt:"o", method:"showTimedAd", ad_started:function () {
this.clip.stop();
}, ad_finished:function () {
this.clip.play();
}, ad_failed:function () {
}, ad_loaded:function (width, height) {
}, ad_skipped:function () {
}};
options = _parseOptions(options, _local13);
var clip = options.clip;
var _local10 = 11000;
var _local12 = options.ad_timeout;
delete options.ad_timeout;
var fadeout_time = options.fadeout_time;
delete options.fadeout_time;
if (!load(options)) {
options.ad_failed();
options.ad_finished();
return(undefined);
}
options.ad_started();
var mc = clip._mochiad;
mc.onUnload = function () {
options.ad_finished();
};
var _local5 = _getRes(options);
var _local14 = _local5[0];
var _local11 = _local5[1];
mc._x = _local14 * 0.5;
mc._y = _local11 * 0.5;
var chk = mc.createEmptyMovieClip("_mochiad_wait", 3);
chk.ad_msec = _local10;
chk.ad_timeout = _local12;
chk.started = getTimer();
chk.showing = false;
chk.fadeout_time = fadeout_time;
chk.fadeFunction = function () {
var _local2 = 100 * (1 - ((getTimer() - this.fadeout_start) / this.fadeout_time));
if (_local2 > 0) {
this._parent._alpha = _local2;
} else {
var _local3 = this._parent._parent;
MochiAd.unload(_local3);
delete this.onEnterFrame;
}
};
mc.lc.adLoaded = options.ad_loaded;
mc.lc.adSkipped = options.ad_skipped;
mc.lc.adjustProgress = function (msec) {
var _local2 = this.mc._mochiad_wait;
_local2.server_control = true;
_local2.started = getTimer();
_local2.ad_msec = msec - 250;
};
mc.lc.rpc = function (callbackID, arg) {
MochiAd.rpc(clip, callbackID, arg);
};
mc.rpcTestFn = function (s) {
return(s);
};
chk.onEnterFrame = function () {
var _local5 = this._parent._mochiad_ctr;
var _local4 = getTimer() - this.started;
var _local2 = false;
if (!chk.showing) {
var _local3 = _local5.getBytesTotal();
if ((_local3 > 0) || (typeof(_local3) == "undefined")) {
chk.showing = true;
chk.started = getTimer();
} else if (_local4 > chk.ad_timeout) {
options.ad_failed();
_local2 = true;
}
}
if (_local4 > chk.ad_msec) {
_local2 = true;
}
if (_local2) {
if (this.server_control) {
delete this.onEnterFrame;
} else {
this.fadeout_start = getTimer();
this.onEnterFrame = this.fadeFunction;
}
}
};
}
static function showPreloaderAd(options) {
showPreGameAd(options);
}
static function showTimedAd(options) {
showInterLevelAd(options);
}
static function _allowDomains(server) {
var _local1 = server.split("/")[2].split(":")[0];
if (System.security) {
if (System.security.allowDomain) {
System.security.allowDomain("*");
System.security.allowDomain(_local1);
}
if (System.security.allowInsecureDomain) {
System.security.allowInsecureDomain("*");
System.security.allowInsecureDomain(_local1);
}
}
return(_local1);
}
static function load(options) {
var _local13 = {clip:_root, server:"http://x.mochiads.com/srv/1/", method:"load", depth:10333, id:"_UNKNOWN_"};
options = _parseOptions(options, _local13);
options.swfv = options.clip.getSWFVersion() || 6;
options.mav = getVersion();
var _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);
}
if (clip._mochiad._containerLCName != undefined) {
clip._mochiad.lc.send(clip._mochiad._containerLCName, "notify", {id:"unload"});
}
clip._mochiad.removeMovieClip();
delete clip._mochiad_loaded;
delete clip._mochiad;
return(true);
}
static function _isNetworkAvailable() {
if (System.security) {
var _local1 = System.security;
if (_local1.sandboxType == "localWithFile") {
return(false);
}
}
return(true);
}
static function _getRes(options) {
var _local3 = options.clip.getBounds();
var _local2 = 0;
var _local1 = 0;
if (typeof(options.res) != "undefined") {
var _local4 = options.res.split("x");
_local2 = parseFloat(_local4[0]);
_local1 = parseFloat(_local4[1]);
} else {
_local2 = _local3.xMax - _local3.xMin;
_local1 = _local3.yMax - _local3.yMin;
}
if ((_local2 == 0) || (_local1 == 0)) {
_local2 = Stage.width;
_local1 = Stage.height;
}
return([_local2, _local1]);
}
static function _parseOptions(options, defaults) {
var _local4 = {};
for (var _local8 in defaults) {
_local4[_local8] = defaults[_local8];
}
if (options) {
for (var _local8 in options) {
_local4[_local8] = options[_local8];
}
}
if (_root.mochiad_options) {
var _local5 = _root.mochiad_options.split("&");
var _local2 = 0;
while (_local2 < _local5.length) {
var _local3 = _local5[_local2].split("=");
_local4[unescape(_local3[0])] = unescape(_local3[1]);
_local2++;
}
}
if (_local4.id == "test") {
}
return(_local4);
}
static function rpc(clip, callbackID, arg) {
switch (arg.id) {
case "setValue" :
setValue(clip, arg.objectName, arg.value);
break;
case "getValue" :
var _local4 = getValue(clip, arg.objectName);
clip._mochiad.lc.send(clip._mochiad._containerLCName, "rpcResult", callbackID, _local4);
break;
case "runMethod" :
var _local3 = runMethod(clip, arg.method, arg.args);
clip._mochiad.lc.send(clip._mochiad._containerLCName, "rpcResult", callbackID, _local3);
}
}
static function setValue(base, objectName, value) {
var _local2 = objectName.split(".");
var _local1;
_local1 = 0;
while (_local1 < (_local2.length - 1)) {
if ((base[_local2[_local1]] == undefined) || (base[_local2[_local1]] == null)) {
return(undefined);
}
base = base[_local2[_local1]];
_local1++;
}
base[_local2[_local1]] = value;
}
static function getValue(base, objectName) {
var _local2 = objectName.split(".");
var _local1;
_local1 = 0;
while (_local1 < (_local2.length - 1)) {
if ((base[_local2[_local1]] == undefined) || (base[_local2[_local1]] == null)) {
return(undefined);
}
base = base[_local2[_local1]];
_local1++;
}
return(base[_local2[_local1]]);
}
static function runMethod(base, methodName, argsArray) {
var _local2 = methodName.split(".");
var _local1;
_local1 = 0;
while (_local1 < (_local2.length - 1)) {
if ((base[_local2[_local1]] == undefined) || (base[_local2[_local1]] == null)) {
return(undefined);
}
base = base[_local2[_local1]];
_local1++;
}
if (typeof(base[_local2[_local1]]) == "function") {
return(base[_local2[_local1]].apply(base, argsArray));
}
return(undefined);
}
}
Symbol 365 MovieClip [__Packages.mochi.MochiScores] Frame 0
class mochi.MochiScores
{
static var boardID, onClose, onError;
function MochiScores () {
}
static function setBoardID(boardID) {
mochi.MochiScores.boardID = boardID;
mochi.MochiServices.send("scores_setBoardID", {boardID:boardID});
}
static function showLeaderboard(options) {
if ((options.clip == null) || (options.clip == undefined)) {
options.clip = mochi.MochiServices.clip;
}
if ((options.clip != mochi.MochiServices.__get__clip()) || (mochi.MochiServices.__get__childClip()._target == undefined)) {
mochi.MochiServices.disconnect();
mochi.MochiServices.connect(mochi.MochiServices.__get__id(), options.clip);
}
delete options.clip;
if (options.name != null) {
if (typeof(options.name) == "object") {
if (options.name.text != undefined) {
options.name = options.name.text;
}
}
}
if (options.score != null) {
if (options.score instanceof TextField) {
if (options.score.text != undefined) {
options.score = options.score.text;
}
} else if (options.score instanceof mochi.MochiDigits) {
options.score = options.score.value;
}
var _local1 = Number(options.score);
if (isNaN(_local1)) {
} else if ((_local1 == Number.NEGATIVE_INFINITY) || (_local1 == Number.POSITIVE_INFINITY)) {
} else {
if (Math.floor(_local1) != _local1) {
}
options.score = _local1;
}
}
if (options.onDisplay != null) {
options.onDisplay();
} else {
mochi.MochiServices.__get__clip().stop();
}
if (options.onClose != null) {
onClose = options.onClose;
} else {
onClose = function () {
mochi.MochiServices.__get__clip().play();
};
}
if (options.onError != null) {
onError = options.onError;
} else {
onError = onClose;
}
if (options.boardID == null) {
if (boardID != null) {
options.boardID = boardID;
}
}
mochi.MochiServices.send("scores_showLeaderboard", {options:options}, null, doClose);
}
static function closeLeaderboard() {
mochi.MochiServices.send("scores_closeLeaderboard");
}
static function getPlayerInfo(callbackObj, callbackMethod) {
mochi.MochiServices.send("scores_getPlayerInfo", null, callbackObj, callbackMethod);
}
static function submit(score, name, callbackObj, callbackMethod) {
score = Number(score);
if (isNaN(score)) {
} else if ((score == Number.NEGATIVE_INFINITY) || (score == Number.POSITIVE_INFINITY)) {
} else {
if (Math.floor(score) != score) {
}
score = Number(score);
}
mochi.MochiServices.send("scores_submit", {score:score, name:name}, callbackObj, callbackMethod);
}
static function requestList(callbackObj, callbackMethod) {
mochi.MochiServices.send("scores_requestList", null, callbackObj, callbackMethod);
}
static function scoresArrayToObjects(scores) {
var _local5 = {};
var _local1;
var _local4;
var _local2;
var _local6;
for (var _local8 in scores) {
if (typeof(scores[_local8]) == "object") {
if ((scores[_local8].cols != null) && (scores[_local8].rows != null)) {
_local5[_local8] = [];
_local2 = scores[_local8];
_local4 = 0;
while (_local4 < _local2.rows.length) {
_local6 = {};
_local1 = 0;
while (_local1 < _local2.cols.length) {
_local6[_local2.cols[_local1]] = _local2.rows[_local4][_local1];
_local1++;
}
_local5[_local8].push(_local6);
_local4++;
}
} else {
_local5[_local8] = {};
for (var _local7 in scores[_local8]) {
_local5[_local8][_local7] = scores[_local8][_local7];
}
}
} else {
_local5[_local8] = scores[_local8];
}
}
return(_local5);
}
static function doClose(args) {
if (args.error == true) {
if (args.errorCode == undefined) {
args.errorCode = "IOError";
}
onError.apply(null, [args.errorCode]);
} else {
onClose.apply();
}
}
}
Symbol 366 MovieClip [__Packages.mochi.MochiDigits] Frame 0
class mochi.MochiDigits
{
var Encoder, Fragment, Sibling;
function MochiDigits (digit, index) {
Encoder = 0;
setValue(digit, index);
}
function get value() {
return(Number(toString()));
}
function set value(v) {
setValue(v);
//return(value);
}
function addValue(v) {
value = value + v;
}
function setValue(digit, index) {
var _local3 = digit.toString();
if ((index == undefined) || (isNaN(index))) {
index = 0;
}
Fragment = _local3.charCodeAt(index++) ^ Encoder;
if (index < _local3.length) {
Sibling = new mochi.MochiDigits(digit, index);
} else {
Sibling = null;
}
reencode();
}
function reencode() {
var _local2 = int(2147483647 * Math.random());
Fragment = Fragment ^ (_local2 ^ Encoder);
Encoder = _local2;
}
function toString() {
var _local2 = String.fromCharCode(Fragment ^ Encoder);
return(((Sibling != null) ? (_local2.concat(Sibling.toString())) : (_local2)));
}
}
Symbol 4 MovieClip Frame 1
stop();
Symbol 6 MovieClip Frame 1
stop();
Symbol 8 MovieClip Frame 1
stop();
Symbol 10 MovieClip Frame 1
stop();
Symbol 12 MovieClip Frame 1
stop();
Symbol 14 MovieClip Frame 1
stop();
Symbol 16 MovieClip Frame 1
stop();
Symbol 18 MovieClip Frame 1
stop();
Symbol 20 MovieClip Frame 1
stop();
Symbol 23 MovieClip Frame 1
stop();
Symbol 28 MovieClip Frame 90
_root.gotoAndPlay(3);
Symbol 56 MovieClip Frame 1
stop();
Symbol 56 MovieClip Frame 15
gotoAndPlay (2);
Symbol 58 Button
on (release) {
getURL ("http://www.pozirk.com", "_blank");
}
Symbol 60 MovieClip Frame 1
stop();
Symbol 68 Button
on (release) {
getURL ("http://www.zabej.info", "_blank");
}
Symbol 70 MovieClip Frame 1
stop();
Instance of Symbol 60 MovieClip in Symbol 77 MovieClip Frame 1
onClipEvent (load) {
var ns = new Sound(this);
ns.attachSound("nature_sound");
ns.start();
}
Symbol 77 MovieClip Frame 24
iButterFly.gotoAndStop(3);
Symbol 77 MovieClip Frame 26
iButterFly.gotoAndStop(4);
Symbol 77 MovieClip Frame 28
iButterFly.gotoAndStop(5);
Symbol 77 MovieClip Frame 30
iButterFly.gotoAndStop(6);
Symbol 77 MovieClip Frame 37
iButterFly.gotoAndStop(5);
Symbol 77 MovieClip Frame 39
iButterFly.gotoAndStop(4);
Symbol 77 MovieClip Frame 41
iButterFly.gotoAndStop(3);
Symbol 77 MovieClip Frame 43
iButterFly.gotoAndPlay(2);
Symbol 77 MovieClip Frame 96
_root.gotoAndPlay(3);
Instance of Symbol 70 MovieClip in Symbol 77 MovieClip Frame 97
onClipEvent (load) {
var ns = new Sound(this);
ns.attachSound("pencil_scratch");
ns.start();
}
Symbol 77 MovieClip Frame 155
_root.gotoAndPlay(3);
Symbol 84 Button
on (release) {
getURL ("http://www.pozirk.com", "_blank");
}
on (rollOver) {
_root.PlaySound("click");
}
Symbol 89 Button
on (release) {
_root.gotoAndPlay(5);
}
on (rollOver) {
_root.PlaySound("click");
}
Symbol 94 Button
on (release) {
_root.gotoAndStop(8);
}
on (rollOver) {
_root.PlaySound("click");
}
Symbol 99 Button
on (release) {
_root.nScores = -1;
_root.gotoAndStop(10);
}
on (rollOver) {
_root.PlaySound("click");
}
Symbol 104 Button
on (release) {
_root.nSound = 0;
_root.cSound.gotoAndStop(2);
}
on (rollOver) {
_root.PlaySound("click");
}
Symbol 109 Button
on (release) {
_root.nSound = 1;
_root.cSound.gotoAndStop(1);
}
on (rollOver) {
_root.PlaySound("click");
}
Symbol 110 MovieClip Frame 1
stop();
Symbol 115 Button
on (release) {
_root.gotoAndStop(9);
}
on (rollOver) {
_root.PlaySound("click");
}
Symbol 123 MovieClip Frame 1
function Show() {
this._sBlueScore = "PLAYER " + _nBlue;
this._sRedScore = _nRed + " COMPUTER";
}
function GoalBlue() {
this._nBlue++;
this.Show();
}
function GoalRed() {
this._nRed++;
this.Show();
}
function Reset() {
_nBlue = 0;
_nRed = 0;
this._sBlueScore = "PLAYER 0";
this._sRedScore = "0 COMPUTER";
}
var _nBlue = 0;
var _nRed = 0;
Symbol 126 Button
on (release) {
_root.ShutGame();
_root.gotoAndPlay(4);
}
Symbol 129 MovieClip Frame 1
function OnGoal(nTeam) {
if (nTeam == 1) {
this._nScores = this._nScores + 10;
} else {
this._nScores = this._nScores - 5;
}
this._sScores = "SCORE: " + this._nScores;
}
function Reset() {
this._nScores = 0;
this._sScores = "SCORE: 0";
}
var _nScores = 0;
Symbol 133 MovieClip Frame 1
function TickTack() {
if (!_root.nPause) {
this._nSecs--;
var _local3 = Math.floor(this._nSecs / 60);
var _local4 = this._nSecs - (_local3 * 60);
this._sTime = ((("0" + _local3) + ":") + ((_local4 < 10) ? "0" : "")) + _local4;
if (this._nSecs == 0) {
if (_root.cScore._nBlue > _root.cScore._nRed) {
_root.cResult.PlayWin();
} else if (_root.cScore._nBlue < _root.cScore._nRed) {
_root.cResult.PlayLoose();
} else {
_root.cResult.PlayDrawGame();
}
}
}
}
function Reset() {
this._nSecs = 180;
this._sTime = "03:00";
}
var _nSecs = 180;
Symbol 140 MovieClip Frame 1
function Move(fX, fY, alpha) {
_x = fX;
_y = fY;
if (alpha > 0) {
_alpha = alpha;
}
}
Symbol 163 MovieClip Frame 1
function Animate() {
if ((++nFrame) <= 12) {
gotoAndStop(nFrame);
} else {
nFrame = 1;
}
}
function FindClosest(nFrom, nTo, cNotHim) {
var _local7 = null;
var _local6 = 100000 /* 0x0186A0 */;
var _local4 = nFrom;
while (_local4 <= nTo) {
var _local3 = _root.vcPlayers[_local4];
if (_local3 != cNotHim) {
var _local5 = Math.sqrt(((this._x - _local3._x) * (this._x - _local3._x)) + ((this._y - _local3._y) * (this._y - _local3._y)));
if (_local5 < _local6) {
_local6 = _local5;
_local7 = _local3;
}
}
_local4++;
}
return(_local7);
}
function NearGate() {
var _local3 = this._x;
var _local2 = this._y;
if (((_local3 >= 97) && (_local3 <= 543)) && ((_local2 >= 732) && (_local2 <= 914))) {
return(1);
}
if (((_local3 >= 97) && (_local3 <= 543)) && ((_local2 >= -417) && (_local2 <= -235))) {
return(-1);
}
return(0);
}
function CheckGate(nTeam) {
if ((_root.cBallPlayer != null) && (nTeam != _root.cBallPlayer._nTeam)) {
return(1);
}
if ((_root.cBallPlayer != null) && (nTeam == _root.cBallPlayer._nTeam)) {
return(0);
}
if (nTeam == 1) {
if ((((this._x >= 210) || (this._x <= 430)) && (y >= 840)) && (y <= 920)) {
if (this._x != this._fPX) {
var _local3 = (this._y - this._fPY) / (this._x - this._fPX);
var _local6 = this._y - (_local3 * this._x);
if (_local3 != 0) {
var _local5 = (845 - _local6) / _local3;
if ((_local5 > 219) && (_local5 < 422)) {
return(1);
}
}
}
if ((Math.abs(_root.vcGates[0]._x - this._x) < 90) && (Math.abs(_root.vcGates[0]._y - this._y) < 24)) {
return(1);
}
this._fSin = -this._fSin;
this._fVelocity++;
return(0);
}
} else if (nTeam == -1) {
if ((((this._x >= 210) || (this._x <= 430)) && (y >= -425)) && (y <= -345)) {
if (this._x != this._fPX) {
var _local3 = (this._y - this._fPY) / (this._x - this._fPX);
var _local6 = this._y - (_local3 * this._x);
if (_local3 != 0) {
var _local5 = (-350 - _local6) / _local3;
if ((_local5 > 219) && (_local5 < 422)) {
return(1);
}
}
}
if ((Math.abs(_root.vcGates[1]._x - this._x) < 90) && (Math.abs(_root.vcGates[1]._y - this._y) < 24)) {
return(1);
}
this._fSin = -this._fSin;
this._fVelocity++;
return(0);
}
}
return(0);
}
var nFrame = 1;
var _fX = 0;
var _fY = 0;
var _fCos = 0;
var _fSin = 0;
var _fAngel = 0;
var _fVelocity = 0;
var _fPX = 0;
var _fPY = 0;
var _nTeam = 0;
stop();
Symbol 277 MovieClip Frame 1
function Init(nPlayer, fX, fY, nTeam) {
_nPlayer = nPlayer;
_x = ((_fToX = (_fStartX = fX)));
_y = ((_fToY = (_fStartY = fY)));
_fMoveX = (fMoveY = 0);
_nRole = 0;
_nTeam = nTeam;
_nFrame = (Math.round(Math.random() * 6) + 2) + (_nPlayer * 8);
this.gotoAndStop(_nFrame);
}
function AnimateRun(fX, fY) {
if (_nFrame >= ((_nPlayer * 8) + 9)) {
_nDir = -1;
} else if (_nFrame <= ((_nPlayer * 8) + 2)) {
_nDir = 1;
}
_nFrame = _nFrame + _nDir;
this.gotoAndStop(_nFrame);
}
function Kick() {
_nFrame = (_nPlayer * 8) + 2;
_nDir = -1;
this.gotoAndStop(_nFrame);
}
function LegPos(nNum) {
var _local2 = new Object();
_local2.x = this["cLeg" + nNum]._x + this._x;
_local2.y = this["cLeg" + nNum]._y + this._y;
return(_local2);
}
function GetRotate(xTo, yTo) {
var _local4 = xTo - this._x;
var _local3 = yTo - this._y;
var _local7 = Math.sqrt((_local4 * _local4) + (_local3 * _local3));
var _local6 = -_local3;
var _local5 = _local6 / _local7;
var _local2 = Math.acos(_local5) * ((_local4 < 0) ? -1 : 1);
this._fAngle = _local2;
this._fCos = _local5;
this._fSin = Math.sin(_local2);
_local2 = (_local2 * 180) / Math.PI;
this._fRotate = _local2;
}
function CheckCollision(cM, bShape, bFull) {
var _local6 = this.LegPos(1);
var _local5 = this.LegPos(2);
var _local4 = this.LegPos(3);
if (bFull == true) {
var _local8 = this.LegPos(4);
var _local7 = this.LegPos(5);
if ((((cM.hitTest(_local6.x, _local6.y, bShape) || (cM.hitTest(_local5.x, _local5.y, bShape))) || (cM.hitTest(_local4.x, _local4.y, bShape))) || (cM.hitTest(_local8.x, _local8.y, bShape))) || (cM.hitTest(_local7.x, _local7.y, bShape))) {
return(true);
}
} else if ((cM.hitTest(_local6.x, _local6.y, bShape) || (cM.hitTest(_local5.x, _local5.y, bShape))) || (cM.hitTest(_local4.x, _local4.y, bShape))) {
return(true);
}
return(false);
}
function GetDistance(px, py) {
var _local3 = this._x - px;
var _local2 = this._y - py;
return(Math.sqrt((_local3 * _local3) + (_local2 * _local2)));
}
var _nPlayer = 0;
var _nFrame = 0;
var _nDir = 1;
var _fStartX = 0;
var _fStartY = 0;
var _fMoveX = 0;
var _fMoveY = 0;
var _fToX = 0;
var _fToY = 0;
var _fAngle = 0;
var _fRotate = 0;
var _fCos = 0;
var _fSin = 0;
var _nAct = 0;
var _nKick = 0;
var _nRole = 0;
var _nTeam = 0;
stop();
Symbol 289 Button
on (release) {
_root.cResult._nSubmit = 1;
_root.nScores = _root.cScores._nScores;
_root.cResult.Stop();
}
on (rollOver) {
_root.PlaySound("click");
}
Symbol 294 Button
on (release) {
this.Stop();
_root.cBall._fVelocity = 0;
_root.InitPlayers(1, 1);
this._nBallTeam = 0;
}
on (rollOver) {
_root.PlaySound("click");
}
Symbol 299 Button
on (release) {
_root.cResult.Stop();
}
on (rollOver) {
_root.PlaySound("click");
}
Symbol 318 MovieClip Frame 1
function PrePlay(nType) {
this._x = 320 - _root._x;
this._y = 240 - _root._y;
if (nType == 1) {
stopAllSounds();
this._y = 240 - _root._y;
_root.cMouse._x = -800;
Mouse.show();
}
this._nPlay = 1;
_root.nPause = 1;
}
function PlayWin() {
this.PrePlay(1);
_root.PlaySound("win");
this.gotoAndPlay(3);
}
function PlayLoose() {
this.PrePlay(1);
_root.PlaySound("loose");
this.gotoAndPlay(46);
}
function PlayDrawGame() {
this.PrePlay(1);
_root.PlaySound("drawgame");
this.gotoAndPlay(89);
}
function PlayGoFull() {
this.PrePlay(0);
_root.PlaySound("crowd");
this.gotoAndPlay(132);
}
function PlayGoEnd() {
this.PrePlay(0);
this.gotoAndPlay(168);
}
function PlayGoal(nBallTeam) {
this.PrePlay(0);
_root.cBall._fVelocity = 0;
var _local3 = Math.random();
if (_local3 < 0.24) {
_root.PlaySound("goal");
} else if (_local3 < 0.62) {
_root.PlaySound("goal2");
} else {
_root.PlaySound("goal3");
}
this._nBallTeam = nBallTeam;
this.gotoAndPlay(180);
}
function Stop() {
this._x = -800;
this._nPlay = 0;
_root.nPause = 0;
this.gotoAndStop(2);
}
var _nPlay = 0;
var _nBallTeam = 0;
var _nSubmit = 0;
stop();
Symbol 318 MovieClip Frame 7
this._sRes = (((("PLAYER " + _root.cScore._nBlue) + " - ") + _root.cScore._nRed) + " COMPUTER\nSCORE: ") + _root.cScores._nScores;
mochi.MochiServices.addLinkEvent("http://x.mochiads.com/link/2f72c8cd5cc2a97b", "http://www.myfootballgames.co.uk", cMFGEnd);
Symbol 318 MovieClip Frame 45
this.gotoAndPlay(7);
Symbol 318 MovieClip Frame 50
this._sRes = (((("PLAYER " + _root.cScore._nBlue) + " - ") + _root.cScore._nRed) + " COMPUTER\nSCORE: ") + _root.cScores._nScores;
mochi.MochiServices.addLinkEvent("http://x.mochiads.com/link/2f72c8cd5cc2a97b", "http://www.myfootballgames.co.uk", cMFGEnd);
Symbol 318 MovieClip Frame 88
this.gotoAndPlay(50);
Symbol 318 MovieClip Frame 93
this._sRes = (((("PLAYER " + _root.cScore._nBlue) + " - ") + _root.cScore._nRed) + " COMPUTER\nSCORE: ") + _root.cScores._nScores;
mochi.MochiServices.addLinkEvent("http://x.mochiads.com/link/2f72c8cd5cc2a97b", "http://www.myfootballgames.co.uk", cMFGEnd);
Symbol 318 MovieClip Frame 131
this.gotoAndPlay(93);
Symbol 318 MovieClip Frame 179
this.Stop();
Symbol 318 MovieClip Frame 184
var nMin = Math.floor(_root.cTimer._nSecs / 60);
var nSec = (_root.cTimer._nSecs - (nMin * 60));
this._sGoalRes = ((((((("PLAYER " + _root.cScore._nBlue) + " - ") + _root.cScore._nRed) + " COMPUTER\nTIME LEFT: 0") + nMin) + ":") + ((nSec < 10) ? "0" : "")) + nSec;
Symbol 318 MovieClip Frame 210
this.Stop();
_root.cBall._fVelocity = 0;
_root.InitPlayers(0, this._nBallTeam);
this._nBallTeam = 0;
Symbol 333 MovieClip Frame 1
function SetCurPlayer(cPlayer) {
_root.cCurPlayer._fToX = _root.cCurPlayer._x;
_root.cCurPlayer._fToY = _root.cCurPlayer._y;
_root.cCurPlayer._nMove = 0;
_root.cSelection.Move(cPlayer._x, cPlayer._y, 100);
_root.cCurPlayer._nRole = 0;
cPlayer._nRole = -1;
_root.cCurPlayer = cPlayer;
}
function SetBallPlayer(cBall, cPlayer) {
_root.cBallPlayer = cPlayer;
cBall._fVelocity = 0;
cBall._nTeam = cPlayer._nTeam;
if ((cPlayer._nTeam == 1) && (cPlayer._nRole != 5)) {
SetCurPlayer(cPlayer);
}
}
function ResetPlayers() {
var _local3 = 0;
while (_local3 < 10) {
var _local2 = _root.vcPlayers[_local3];
if (_local2._nRole != -1) {
_local2._fMoveX = 0;
_local2._fMoveY = 0;
_local2._fToX = 0;
_local2._fToY = 0;
_local2._nKick = 0;
_local2._nAct = 0;
_local2._nRole = 0;
}
_local3++;
}
_root.vcPlayers[10]._nAct = 0;
_root.vcPlayers[11]._nAct = 0;
}
Symbol 335 MovieClip Frame 1
function Defender(p, type) {
var _local3 = p._nTeam * type;
if (p._nAct == 1) {
if ((Math.abs(p._x - p._fToX) < 10) && (Math.abs(p._y - p._fToY) < 10)) {
p._nAct = 2;
}
} else if (p._nAct == 0) {
if (_local3 == 1) {
p._fToX = (Math.random() * 860) - 110;
p._fToY = (Math.random() * 290) + 380;
} else {
p._fToX = (Math.random() * 860) - 110;
p._fToY = (Math.random() * 290) - 180;
}
p.GetRotate(p._fToX, p._fToY);
p._fMoveX = SPEED * p._fSin;
p._fMoveY = SPEED * p._fCos;
p._nAct = 1;
} else if (p._nAct == 2) {
var _local4 = Math.random();
if (_local4 > 0.7) {
p._nAct = 0;
} else {
p._nAct = 3;
}
} else {
p.GetRotate(_root.cBall._x, _root.cBall._y);
}
}
function Attacker(p) {
if (p._nAct == 1) {
if ((Math.abs(p._x - p._fToX) < 10) && (Math.abs(p._y - p._fToY) < 10)) {
p._nAct = 0;
}
} else if (p._nAct == 3) {
if ((Math.abs(p._x - p._fToX) < 10) && (Math.abs(p._y - p._fToY) < 10)) {
p._fToX = (Math.random() * 110) + 250;
p._fToY = (Math.random() * 40) + 780;
p.GetRotate(p._fToX, p._fToY);
p._nAct = 2;
}
} else if (p._nAct == 2) {
p._nKick = 1;
} else if (p._nAct == 0) {
var _local3 = Math.random();
if (_local3 < 0.2) {
p._fToX = (Math.random() * 860) - 110;
p._fToY = (Math.random() * 290) + 380;
p._nAct = 1;
} else if (_local3 < 0.8) {
p._fToX = Math.random() * 700;
p._fToY = (Math.random() * 290) + 430;
p._nAct = 3;
} else {
var _local4 = _root.cBall.FindClosest(5, 9, p);
p._fToX = _local4._x;
p._fToY = _local4._y;
p._nAct = 2;
}
p.GetRotate(p._fToX, p._fToY);
if (_local3 < 0.8) {
p._fMoveX = SPEED * p._fSin;
p._fMoveY = SPEED * p._fCos;
}
}
}
function Supporter(p) {
Defender(p, -1);
}
function Taker(p) {
if (_root.cBall.NearGate() == 0) {
if (p._nAct == 1) {
if ((Math.abs(p._x - p._fToX) < 20) && (Math.abs(p._y - p._fToY) < 20)) {
p._nAct = 2;
}
p._fToX = _root.cBall._x;
p._fToY = _root.cBall._y;
if ((_root.cBallPlayer != null) && (p.GetDistance(_root.cBallPlayer._x, _root.cBallPlayer._y) < p.GetDistance(_root.cBall._x, _root.cBall._y))) {
p._fToX = p._fToX - (p._fSin * 60);
p._fToY = p._fToY - (p._fCos * 60);
}
p.GetRotate(p._fToX, p._fToY);
p._fMoveX = SPEED * p._fSin;
p._fMoveY = SPEED * p._fCos;
} else if (p._nAct == 2) {
p._nKick = 1;
} else {
p._nAct = 1;
}
} else {
p._nAct = 0;
}
}
function Goalkeeper(p) {
var _local3 = _root.cBall._nTeam;
if (p._nAct == 1) {
if ((Math.abs(p._x - p._fToX) < 10) && (Math.abs(p._y - p._fToY) < 10)) {
p._nAct = 3;
}
} else if (p._nAct == 2) {
p._fToX = _root.cBall._x;
p._fToY = _root.cBall._y;
p.GetRotate(p._fToX, p._fToY);
if ((_local3 != 0) || ((_local3 == 0) && (p._nTeam == 1))) {
p._fMoveX = SPEED * p._fSin;
p._fMoveY = SPEED * p._fCos;
} else {
p._fMoveX = GOALKEEPER_SPEED * p._fSin;
p._fMoveY = GOALKEEPER_SPEED * p._fCos;
}
if ((Math.abs(p._x - p._fToX) < 10) && (Math.abs(p._y - p._fToY) < 10)) {
if ((p._nTeam != _local3) && (_local3 != 0)) {
p._nAct = 4;
} else {
p._nAct = 0;
}
}
if (((p._nTeam == 1) && (_root.cBall.NearGate() != 1)) || ((p._nTeam == -1) && (_root.cBall.NearGate() != -1))) {
p._nAct = 0;
}
if (p._nTeam == _local3) {
p._nAct = 0;
}
} else if (p._nAct == 3) {
p._fMoveX = 0;
p._fMoveY = 0;
var _local7 = _root.cBall._x;
var _local6 = _root.cBall._y;
if ((_local3 == 0) || (p._nTeam != _local3)) {
if (((p._nTeam == 1) && (_root.cBall.NearGate() == 1)) || ((p._nTeam == -1) && (_root.cBall.NearGate() == -1))) {
p._nAct = 2;
} else {
p.GetRotate(_root.cBall._x, _root.cBall._y);
var _local4 = SPEED * p._fSin;
if (((p._x + _local4) > 270) && ((p._x + _local4) < 370)) {
p._fMoveX = _local4;
p._nAct = 6;
} else if (((p._x <= 270) || (p._x >= 370)) || (p._y != p._fStartY)) {
p._nAct = 5;
}
}
} else if (p == _root.cBallPlayer) {
var _local5 = ((p._nTeam > 0) ? (_root.cBall.FindClosest(0, 4)) : (_root.cBall.FindClosest(5, 9)));
p.GetRotate(_local5._x, _local5._y);
p._nAct = 4;
} else {
p.GetRotate(_root.cBall._x, _root.cBall._y);
}
} else if (p._nAct == 4) {
p._nKick = 1;
p._nAct = 0;
} else if (p._nAct == 5) {
if ((Math.abs(p._x - p._fStartX) > 6) && (Math.abs(p._y - p._fStartY) > 6)) {
p._fToX = p._fStartX;
p._fToY = p._fStartY;
p._nAct = 1;
p.GetRotate(p._fToX, p._fToY);
p._fMoveX = SPEED * p._fSin;
p._fMoveY = SPEED * p._fCos;
} else {
p._nAct = 3;
}
} else if (p._nAct == 6) {
p._nAct = 3;
} else if (p._nAct == 0) {
p._fMoveX = 0;
p._fMoveY = 0;
p._nAct = 5;
}
}
function SetAction(p) {
switch (p._nRole) {
case 1 :
Defender(p, 1);
break;
case 2 :
Attacker(p);
break;
case 3 :
Supporter(p);
break;
case 4 :
Taker(p);
break;
case 5 :
Goalkeeper(p);
}
}
function SetRole(p, role) {
p._nRole = role;
p._fMoveX = 0;
p._fMoveY = 0;
p._fToX = 0;
p._fToY = 0;
p._nAct = 0;
p._nKick = 0;
}
var SPEED = 6;
var GOALKEEPER_SPEED = 24;
Symbol 341 Button
on (release) {
_root.ShutGame();
_root.gotoAndPlay(4);
}
on (rollOver) {
_root.PlaySound("click");
}
Symbol 360 Button
on (release) {
getURL ("http://www.pozirk.com", "_blank");
}