Frame 1
Security.allowDomain("*");
MochiAd.showPreGameAd({id:"531b4c24918c6f84", res:"640x480"});
mochi.MochiServices.connect("531b4c24918c6f84");
Frame 2
function gameMenu(menu, obj) {
getURL (_root.webSite, "_blank");
}
function qualityHigh() {
_quality = "high";
}
function qualityLow() {
_quality = "low";
}
this._lockroot = true;
var gameName = "solitaire";
vNum = "1.02";
gameQuality = "AUTO";
_quality = "HIGH";
authorsSite = "http://www.terrypaton.com";
var menu_cm = new ContextMenu();
menu_cm.customItems.push(new ContextMenuItem(authorsSite, gameMenu));
menu_cm.customItems.push(new ContextMenuItem("HIGH Quality", qualityHigh));
menu_cm.customItems.push(new ContextMenuItem("LOW Quality", qualityLow));
menu_cm.hideBuiltInItems();
_root.menu = menu_cm;
legalDomain = "http://www.terrypaton.com";
gameLocation = _root._url.substr(0, legalDomain.length);
if (gameLocation != legalDomain) {
}
Frame 3
gameLoadingName = "solitaire";
loadingClip.onEnterFrame = function () {
pL = Math.floor((this._parent.getBytesLoaded() / this._parent.getBytesTotal()) * 100);
if (pL < 100) {
this.mask._xscale = (pL / 100) * 100;
this._parent.stop();
} else {
i = 0;
while (i < stringLength) {
removeMovieClip(eval ("loadingHolder.l" + i));
i++;
}
this._parent.play();
}
};
stringLength = gameLoadingName.length;
wordOffset = (stringLength * 20) / 2;
this.createEmptyMovieClip("loadingHolder", 1);
loadingHolder._x = (320 - wordOffset) + 10;
loadingHolder._y = 160;
i = 0;
while (i < stringLength) {
t = loadingHolder.attachMovie("letter", "l" + i, i);
t._x = i * 20;
t._y = 50;
t.angle = i;
t.Lvar.text = gameLoadingName.charAt(i);
t._xscale = (t._yscale = 200);
new letterClass(t, (-i) * 1.2, 5);
i++;
}
stop();
Frame 6
function gameLoop() {
switch (gameState) {
case "playing" :
return;
case "dragging" :
draggingClip = draggingArray[0];
var parentClip = draggingClip.clip;
parentClipY = parentClip._y;
parentClipX = parentClip._x;
jc = 1;
while (jc < draggingArray.length) {
to = draggingArray[jc];
tc = to.clip;
a = parentClipX;
b = parentClipY + 15;
xDif = a - tc._x;
yDif = b - tc._y;
tc._x = tc._x + (xDif / 1.5);
tc._y = tc._y + (yDif / 2);
parentClipY = tc._y;
parentClipX = tc._x;
jc++;
}
return;
case "confirm redeal" :
confirmRedealClip = attachMovie("confirmRedealClip", "confirmRedealClip", 100);
confirmRedealClip._alpha = 0;
confirmRedealClip.alphaTo(100, 1, "");
confirmRedealClip._xscale = 130;
confirmRedealClip._yscale = 130;
confirmRedealClip.scaleTo(100, 1);
confirmRedealClip._x = 320;
confirmRedealClip._y = 240;
confirmRedealClip.confirmBtn.onRollOver = function () {
this.scaleTo(130, 0.5);
};
confirmRedealClip.confirmBtn.onRollOut = function () {
this.scaleTo(100, 0.5);
};
confirmRedealClip.cancelBtn.onRollOver = function () {
this.scaleTo(130, 0.5);
};
confirmRedealClip.cancelBtn.onRollOut = function () {
this.scaleTo(100, 0.5);
};
confirmRedealClip.confirmBtn.onRelease = function () {
this._parent.alphaTo(0, 0.5, "", 0, function () {
removeMovieClip(this);
});
movieLoc.redeal();
};
confirmRedealClip.cancelBtn.onRelease = function () {
this._parent.alphaTo(0, 0.5, "", 0, function () {
removeMovieClip(this);
});
movieLoc.gameState = "playing";
};
gameState = "confirm redeal wait";
return;
case "confirm redeal wait" :
return;
case "game complete" :
gcw = 30;
trace(gameState);
gameState = "game complete wait";
return;
case "game complete wait" :
gcw--;
if (gcw < 1) {
gotoAndPlay (24);
gameState = "game over scene";
}
return;
case "prepare for setup" :
delete cardObjects;
delete cardPosition;
i = 0;
while (i < 1000) {
removeMovieClip(eval ("cardHolder.c" + i));
i++;
}
sw = 10;
gameState = "setup";
return;
case "setup" :
gameAlreadyWon = false;
sw--;
if (sw >= 1) {
break;
}
setup();
gameState = "playing";
}
}
function playSound(temp) {
switch (temp) {
case "points" :
pointsSnd.start();
return;
case "card flip" :
a = random(2) + 1;
eval (("card" + a) + "Snd").start();
return;
case "wrong" :
wrongSnd.start();
return;
case "pick up" :
pickupSnd.start();
return;
case "drop" :
dropSnd.start();
return;
case "mouseOver" :
mouseOverSnd.start();
return;
case "mouseDown" :
mouseDownSnd.start();
return;
case "game complete" :
gameCompleteSnd.start();
return;
case "foundation" :
dropFoundationSnd.start();
return;
case "flip deck" :
flipDeckSnd.start();
}
}
function attachSoundFromLibrary(idname) {
var _local2 = new Sound(this);
_local2.attachSound(idname);
return(_local2);
}
function setupHighscoreSubmission() {
submitScoreBtnClip.onRelease = function () {
mochi.MochiScores.showLeaderboard({boardID:"e9dfc7702c7a8ae7", onClose:function () {
}, score:score});
submitScoreBtnClip._visible = false;
};
}
function showHighscores() {
mochi.MochiScores.showLeaderboard({boardID:"e9dfc7702c7a8ae7", onClose:function () {
}, res:"640x480", showTableRank:true});
}
onEnterFrame = gameLoop;
storage = SharedObject.getLocal(gameName + "Bstorage");
score = storage.data.score;
yourRedeals = storage.data.redeals;
confirmRedeal = storage.data.confirmRedeal;
if (confirmRedeal == undefined) {
storage.data.confirmRedeal = true;
confirmRedeal = true;
}
trace("confirmRedeal = " + confirmRedeal);
if (score == undefined) {
storage.data.score = 0;
score = 0;
}
if (yourRedeals == undefined) {
storage.data.redeals = 0;
yourRedeals = 0;
}
flipDeckSnd = attachSoundFromLibrary("flipDeck.wav");
mouseOverSnd = attachSoundFromLibrary("mouseOver.wav");
mouseDownSnd = attachSoundFromLibrary("mouseDown.wav");
wrongSnd = attachSoundFromLibrary("wrongSnd.wav");
dropSnd = attachSoundFromLibrary("dropSnd.wav");
pickupSnd = attachSoundFromLibrary("pickupSnd.wav");
pointsSnd = attachSoundFromLibrary("pointsSnd.wav");
card1Snd = attachSoundFromLibrary("card1Snd.wav");
card2Snd = attachSoundFromLibrary("card2Snd.wav");
card3Snd = attachSoundFromLibrary("card3Snd.wav");
gameCompleteSnd = attachSoundFromLibrary("gameComplete.wav");
fireWorkSnd1 = attachSoundFromLibrary("fireWorks1.wav");
fireWorkSnd2 = attachSoundFromLibrary("fireWorks2.wav");
fireWorkSnd3 = attachSoundFromLibrary("fireWorks3.wav");
dropFoundationSnd = attachSoundFromLibrary("dropFoundation.wav");
Frame 7
_global.$createTweenController = function () {
var _local3 = _root.createEmptyMovieClip("__tweenController__", 123432);
_local3.$_tweenPropList = new Array();
_local3.$_tTime = getTimer();
_local3.onEnterFrame = _global.$updateTweens;
};
ASSetPropFlags(_global, "$createTweenController", 1, 0);
_global.$removeTweenController = function () {
delete _root.__tweenController__.$_tweenPropList;
delete _root.__tweenController__.$_tTime;
delete _root.__tweenController__.onEnterFrame;
_root.__tweenController__.removeMovieClip();
};
ASSetPropFlags(_global, "$removeTweenController", 1, 0);
_global.$addTween = function (mtarget, prop, propDest, timeSeconds, animType, delay, callback, extra1, extra2, extras) {
if (timeSeconds == undefined) {
timeSeconds = 0;
}
if ((animType == undefined) || (animType == "")) {
animType = "easeOutExpo";
}
if (delay == undefined) {
delay = 0;
}
if (typeof(prop) == "string") {
var _local7 = [prop];
var _local11 = [mtarget[prop]];
var _local9 = [propDest];
} else {
var _local7 = [];
var _local11 = [];
var _local9 = [];
for (var _local32 in prop) {
_local11.push(mtarget[prop[_local32]]);
}
for (var _local32 in prop) {
_local7.push(prop[_local32]);
}
for (var _local32 in propDest) {
_local9.push(propDest[_local32]);
}
}
var _local12 = false;
if (_root.__tweenController__ == undefined) {
_global.$createTweenController();
}
var _local4 = _root.__tweenController__.$_tweenPropList;
var _local8 = _root.__tweenController__.$_tTime;
for (var _local32 in _local11) {
if ((_local9[_local32] != undefined) && (!mtarget.$_isTweenLocked)) {
if (mtarget.$_tweenCount > 0) {
var _local3 = 0;
while (_local3 < _local4.length) {
if ((_local4[_local3]._targ == mtarget) && (_local4[_local3]._prop == _local7[_local32])) {
if ((_local8 + (delay * 1000)) < _local4[_local3]._timeDest) {
_local4.splice(_local3, 1);
_local3--;
mtarget.$_tweenCount--;
}
}
_local3++;
}
}
_local4.push({_prop:_local7[_local32], _targ:mtarget, _propStart:undefined, _propDest:_local9[_local32], _timeStart:_local8, _timeDest:_local8 + (timeSeconds * 1000), _animType:animType, _extra1:extra1, _extra2:extra2, _extras:extras, _delay:delay, _isPaused:false, _timePaused:0, _callback:(_local12 ? undefined : (callback))});
mtarget.$_tweenCount = ((mtarget.$_tweenCount > 0) ? (mtarget.$_tweenCount + 1) : 1);
_local12 = true;
}
}
ASSetPropFlags(mtarget, "$_tweenCount", 1, 0);
};
ASSetPropFlags(_global, "$addTween", 1, 0);
_global.$updateTweens = function () {
var _local8 = (this.$_tTime = getTimer());
var _local6 = 0;
while (_local6 < this.$_tweenPropList.length) {
var _local3 = this.$_tweenPropList[_local6];
if (_local3._targ.toString() == undefined) {
this.$_tweenPropList.splice(_local6, 1);
_local6--;
} else if (((_local3._timeStart + (_local3._delay * 1000)) <= _local8) && (!_local3._isPaused)) {
if (_local3._propStart == undefined) {
if (_local3._prop.substr(0, 10) == "__special_") {
if (_local3._prop == "__special_mc_frame__") {
_local3._propStart = _local3._targ._currentframe;
} else if (_local3._prop == "__special_mc_ra__") {
_local3._propStart = new Color(_local3._targ).getTransform().ra;
} else if (_local3._prop == "__special_mc_rb__") {
_local3._propStart = new Color(_local3._targ).getTransform().rb;
} else if (_local3._prop == "__special_mc_ga__") {
_local3._propStart = new Color(_local3._targ).getTransform().ga;
} else if (_local3._prop == "__special_mc_gb__") {
_local3._propStart = new Color(_local3._targ).getTransform().gb;
} else if (_local3._prop == "__special_mc_ba__") {
_local3._propStart = new Color(_local3._targ).getTransform().ba;
} else if (_local3._prop == "__special_mc_bb__") {
_local3._propStart = new Color(_local3._targ).getTransform().bb;
} else if (_local3._prop == "__special_mc_aa__") {
_local3._propStart = new Color(_local3._targ).getTransform().aa;
} else if (_local3._prop == "__special_mc_ab__") {
_local3._propStart = new Color(_local3._targ).getTransform().ab;
} else if (_local3._prop == "__special_text_r__") {
_local3._propStart = _local3._targ.textColor >> 16;
} else if (_local3._prop == "__special_text_g__") {
_local3._propStart = (_local3._targ.textColor & 65280) >> 8;
} else if (_local3._prop == "__special_text_b__") {
_local3._propStart = _local3._targ.textColor & 255;
} else if (_local3._prop == "__special_sound_volume__") {
_local3._propStart = _local3._targ.getVolume();
} else if (_local3._prop == "__special_sound_pan__") {
_local3._propStart = _local3._targ.getPan();
} else if (_local3._prop == "__special_bst_t__") {
_local3._propStart = 0;
_local3._extras.__special_bst_ix__ = _local3._targ._x;
_local3._extras.__special_bst_iy__ = _local3._targ._y;
} else if (_local3._prop == "__special_blur_x__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.BlurFilter) {
_local3._propStart = _local3._targ.filters[_local5].blurX;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 0;
}
} else if (_local3._prop == "__special_blur_y__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.BlurFilter) {
_local3._propStart = _local3._targ.filters[_local5].blurY;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 0;
}
} else if (_local3._prop == "__special_glow_color__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.GlowFilter) {
_local3._propStart = _local3._targ.filters[_local5].color;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 16777215 /* 0xFFFFFF */;
}
} else if (_local3._prop == "__special_glow_alpha__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.GlowFilter) {
_local3._propStart = _local3._targ.filters[_local5].alpha;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 1;
}
} else if (_local3._prop == "__special_glow_blurX__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.GlowFilter) {
_local3._propStart = _local3._targ.filters[_local5].blurX;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 0;
}
} else if (_local3._prop == "__special_glow_blurY__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.GlowFilter) {
_local3._propStart = _local3._targ.filters[_local5].blurY;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 0;
}
} else if (_local3._prop == "__special_glow_strength__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.GlowFilter) {
_local3._propStart = _local3._targ.filters[_local5].strength;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 1;
}
} else if (_local3._prop == "__special_bevel_distance__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.BevelFilter) {
_local3._propStart = _local3._targ.filters[_local5].distance;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 0;
}
} else if (_local3._prop == "__special_bevel_angle__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.BevelFilter) {
_local3._propStart = _local3._targ.filters[_local5].angle;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 45;
}
} else if (_local3._prop == "__special_bevel_highlightColor__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.BevelFilter) {
_local3._propStart = _local3._targ.filters[_local5].highlightColor;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 16777215 /* 0xFFFFFF */;
}
} else if (_local3._prop == "__special_bevel_highlightAlpha__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.BevelFilter) {
_local3._propStart = _local3._targ.filters[_local5].highlightAlpha;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 1;
}
} else if (_local3._prop == "__special_bevel_shadowColor__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.BevelFilter) {
_local3._propStart = _local3._targ.filters[_local5].shadowColor;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 0;
}
} else if (_local3._prop == "__special_bevel_shadowAlpha__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.BevelFilter) {
_local3._propStart = _local3._targ.filters[_local5].shadowAlpha;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 1;
}
} else if (_local3._prop == "__special_bevel_blurX__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.BevelFilter) {
_local3._propStart = _local3._targ.filters[_local5].blurX;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 0;
}
} else if (_local3._prop == "__special_bevel_blurY__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.BevelFilter) {
_local3._propStart = _local3._targ.filters[_local5].blurY;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 0;
}
} else if (_local3._prop == "__special_bevel_strength__") {
var _local5 = 0;
while (_local5 < _local3._targ.filters.length) {
if (_local3._targ.filters[_local5] instanceof flash.filters.BevelFilter) {
_local3._propStart = _local3._targ.filters[_local5].strength;
}
_local5++;
}
if (_local3._propStart == undefined) {
_local3._propStart = 1;
}
} else {
_local3._propStart = _local3._targ[_local3._prop];
}
} else {
_local3._propStart = _local3._targ[_local3._prop];
}
}
var _local10 = _local3._timeDest + (_local3._delay * 1000);
if (_local10 <= _local8) {
var _local4 = _local3._propDest;
} else {
var _local4 = _global.findTweenValue(_local3._propStart, _local3._propDest, _local3._timeStart, _local8 - (_local3._delay * 1000), _local3._timeDest, _local3._animType, _local3._extra1, _local3._extra2);
}
_local3._targ[_local3._prop] = (_local3._extras.mustRound ? (Math.round(_local4)) : (_local4));
if (_local3._prop == "__special_mc_frame__") {
_local3._targ.gotoAndStop(Math.round(_local4));
} else if (_local3._prop == "__special_mc_ra__") {
new Color(_local3._targ).setTransform({ra:_local4});
} else if (_local3._prop == "__special_mc_rb__") {
new Color(_local3._targ).setTransform({rb:_local4});
} else if (_local3._prop == "__special_mc_ga__") {
new Color(_local3._targ).setTransform({ga:_local4});
} else if (_local3._prop == "__special_mc_gb__") {
new Color(_local3._targ).setTransform({gb:_local4});
} else if (_local3._prop == "__special_mc_ba__") {
new Color(_local3._targ).setTransform({ba:_local4});
} else if (_local3._prop == "__special_mc_bb__") {
new Color(_local3._targ).setTransform({bb:_local4});
} else if (_local3._prop == "__special_mc_aa__") {
new Color(_local3._targ).setTransform({aa:_local4});
} else if (_local3._prop == "__special_mc_ab__") {
new Color(_local3._targ).setTransform({ab:_local4});
}
if (_local3._prop == "__special_bst_t__") {
var _local7 = _local3._extras;
var _local9 = _global.findPointOnCurve(_local7.__special_bst_ix__, _local7.__special_bst_iy__, _local7.__special_bst_cx__, _local7.__special_bst_cy__, _local7.__special_bst_dx__, _local7.__special_bst_dy__, _local4);
if (_local3._extras.mustRound) {
_local3._targ._x = Math.round(_local9.x);
_local3._targ._y = Math.round(_local9.y);
} else {
_local3._targ._x = _local9.x;
_local3._targ._y = _local9.y;
}
}
if ((typeof(_local3._targ) != "movieclip") && (_local3._prop == "__special_text_b__")) {
_local3._targ.textColor = ((_local3._targ.__special_text_r__ << 16) + (_local3._targ.__special_text_g__ << 8)) + _local3._targ.__special_text_b__;
}
if (_local3._prop == "__special_sound_volume__") {
_local3._targ.setVolume(_local4);
}
if (_local3._prop == "__special_sound_pan__") {
_local3._targ.setPan(_local4);
}
if (_local3._prop == "__special_blur_x__") {
_global.$setFilterProperty(_local3._targ, "blur_blurX", _local4, _local3._extras);
}
if (_local3._prop == "__special_blur_y__") {
_global.$setFilterProperty(_local3._targ, "blur_blurY", _local4, _local3._extras);
}
if (_local3._prop == "__special_glow_color__") {
_global.$setFilterProperty(_local3._targ, "glow_color", _global.findTweenColor(_local3, _local8), _local3._extras);
}
if (_local3._prop == "__special_glow_alpha__") {
_global.$setFilterProperty(_local3._targ, "glow_alpha", _local4, _local3._extras);
}
if (_local3._prop == "__special_glow_blurX__") {
_global.$setFilterProperty(_local3._targ, "glow_blurX", _local4, _local3._extras);
}
if (_local3._prop == "__special_glow_blurY__") {
_global.$setFilterProperty(_local3._targ, "glow_blurY", _local4, _local3._extras);
}
if (_local3._prop == "__special_glow_strength__") {
_global.$setFilterProperty(_local3._targ, "glow_strength", _local4, _local3._extras);
}
if (_local3._prop == "__special_bevel_distance__") {
_global.$setFilterProperty(_local3._targ, "bevel_distance", _local4, _local3._extras);
}
if (_local3._prop == "__special_bevel_angle__") {
_global.$setFilterProperty(_local3._targ, "bevel_angle", _local4, _local3._extras);
}
if (_local3._prop == "__special_bevel_highlightColor__") {
_global.$setFilterProperty(_local3._targ, "bevel_highlightColor", _global.findTweenColor(_local3, _local8), _local3._extras);
}
if (_local3._prop == "__special_bevel_highlightAlpha__") {
_global.$setFilterProperty(_local3._targ, "bevel_highlightAlpha", _local4, _local3._extras);
}
if (_local3._prop == "__special_bevel_shadowColor__") {
_global.$setFilterProperty(_local3._targ, "bevel_shadowColor", _global.findTweenColor(_local3, _local8), _local3._extras);
}
if (_local3._prop == "__special_bevel_shadowAlpha__") {
_global.$setFilterProperty(_local3._targ, "bevel_shadowAlpha", _local4, _local3._extras);
}
if (_local3._prop == "__special_bevel_blurX__") {
_global.$setFilterProperty(_local3._targ, "bevel_blurX", _local4, _local3._extras);
}
if (_local3._prop == "__special_bevel_blurY__") {
_global.$setFilterProperty(_local3._targ, "bevel_blurY", _local4, _local3._extras);
}
if (_local3._prop == "__special_bevel_strength__") {
_global.$setFilterProperty(_local3._targ, "bevel_strength", _local4, _local3._extras);
}
if (_local3._targ.onTweenUpdate != undefined) {
_local3._targ.onTweenUpdate(_local3._prop);
}
if (_local10 <= _local8) {
if (_local3._targ.onTweenComplete != undefined) {
_local3._targ.onTweenComplete(_local3._prop);
}
_global.$stopTween(_local3._targ, [_local3._prop], false);
_local6--;
if (_local3._callback != undefined) {
if (_global.backwardCallbackTweening) {
var _local11 = _local3._targ.createEmptyMovieClip("__child__", 122344);
_local3._callback.apply(_local11, null);
_local11.removeMovieClip();
} else {
_local3._callback.apply(_local3._targ, null);
}
}
}
}
_local6++;
}
if (this.$_tweenPropList.length == 0) {
_global.$removeTweenController();
}
};
ASSetPropFlags(_global, "$updateTween", 1, 0);
_global.$stopTween = function (mtarget, props, wipeFuture) {
var _local4 = _root.__tweenController__.$_tweenPropList;
var _local7;
for (var _local9 in _local4) {
_local7 = _local4[_local9]._prop;
var _local5 = 0;
while ((_local5 < props.length) || ((_local5 < 1) && (props == undefined))) {
if (((_local4[_local9]._targ == mtarget) && ((_local7 == props[_local5]) || (props == undefined))) && (wipeFuture || ((_local4[_local9]._timeDest + (_local4[_local9]._delay * 1000)) <= getTimer()))) {
switch (_local7) {
case "__special_mc_frame__" :
case "__special_mc_ra__" :
case "__special_mc_rb__" :
case "__special_mc_ga__" :
case "__special_mc_gb__" :
case "__special_mc_ba__" :
case "__special_mc_bb__" :
case "__special_mc_aa__" :
case "__special_mc_ab__" :
case "__special_sound_volume__" :
case "__special_bst_t__" :
delete mtarget[_local7];
break;
case "__special_text_b__" :
delete mtarget.__special_text_r__;
delete mtarget.__special_text_g__;
delete mtarget.__special_text_b__;
}
_local4.splice(_local9, 1);
}
_local5++;
}
}
if (props == undefined) {
delete mtarget.$_tweenCount;
} else {
mtarget.$_tweenCount = 0;
for (var _local9 in _local4) {
if (_local4[_local9]._targ == mtarget) {
mtarget.$_tweenCount++;
}
}
if (mtarget.$_tweenCount == 0) {
delete mtarget.$_tweenCount;
}
}
if (_local4.length == 0) {
_global.$removeTweenController();
}
};
ASSetPropFlags(_global, "$stopTween", 1, 0);
_global.$setFilterProperty = function (mtarget, propName, propValue, extras) {
var _local1;
var _local7 = false;
var _local3 = [];
_local1 = 0;
while (_local1 < mtarget.filters.length) {
_local3.push(mtarget.filters[_local1]);
_local1++;
}
if (propName.substr(0, 5) == "blur_") {
_local1 = 0;
while (_local1 < mtarget.filters.length) {
if (_local3[_local1] instanceof flash.filters.BlurFilter) {
_local3[_local1][propName.substr(5)] = propValue;
if (extras.__special_blur_quality__ != undefined) {
_local3[_local1].quality = extras.__special_blur_quality__;
}
_local7 = true;
break;
}
_local1++;
}
if (!_local7) {
var _local9;
var _local8 = ((extras.__special_blur_quality__ == undefined) ? 2 : (extras.__special_blur_quality__));
if (propName == "blur_blurX") {
_local9 = new flash.filters.BlurFilter(propValue, 0, _local8);
}
if (propName == "blur_blurY") {
_local9 = new flash.filters.BlurFilter(0, propValue, _local8);
}
_local3.push(_local9);
}
} else if (propName.substr(0, 5) == "glow_") {
_local1 = 0;
while (_local1 < mtarget.filters.length) {
if (_local3[_local1] instanceof flash.filters.GlowFilter) {
_local3[_local1][propName.substr(5)] = propValue;
if (extras.__special_glow_quality__ != undefined) {
_local3[_local1].quality = extras.__special_glow_quality__;
}
if (extras.__special_glow_inner__ != undefined) {
_local3[_local1].inner = extras.__special_glow_inner__;
}
if (extras.__special_glow_knockout__ != undefined) {
_local3[_local1].knockout = extras.__special_glow_knockout__;
}
_local7 = true;
break;
}
_local1++;
}
if (!_local7) {
var _local8 = ((extras.__special_glow_quality__ == undefined) ? 2 : (extras.__special_glow_quality__));
var _local12 = ((extras.__special_glow_inner__ == undefined) ? false : (extras.__special_glow_inner__));
var _local10 = ((extras.__special_glow_knockout__ == undefined) ? false : (extras.__special_glow_knockout__));
if (propName == "glow_color") {
var _local9 = new flash.filters.GlowFilter(propValue, 1, 0, 0, 1, _local8, _local12, _local10);
}
if (propName == "glow_alpha") {
var _local9 = new flash.filters.GlowFilter(16777215, propValue, 0, 0, 1, _local8, _local12, _local10);
}
if (propName == "glow_blurX") {
var _local9 = new flash.filters.GlowFilter(16777215, 1, propValue, 0, 1, _local8, _local12, _local10);
}
if (propName == "glow_blurY") {
var _local9 = new flash.filters.GlowFilter(16777215, 1, 0, propValue, 1, _local8, _local12, _local10);
}
if (propName == "glow_strength") {
var _local9 = new flash.filters.GlowFilter(16777215, 1, 0, 0, propValue, _local8, _local12, _local10);
}
_local3.push(_local9);
}
} else if (propName.substr(0, 6) == "bevel_") {
_local1 = 0;
while (_local1 < mtarget.filters.length) {
if (_local3[_local1] instanceof flash.filters.BevelFilter) {
_local3[_local1][propName.substr(6)] = propValue;
if (extras.__special_bevel_quality__ != undefined) {
_local3[_local1].quality = extras.__special_bevel_quality__;
}
if (extras.__special_bevel_type__ != undefined) {
_local3[_local1].inner = extras.__special_bevel_type__;
}
if (extras.__special_bevel_knockout__ != undefined) {
_local3[_local1].knockout = extras.__special_bevel_knockout__;
}
_local7 = true;
break;
}
_local1++;
}
if (!_local7) {
var _local8 = ((extras.__special_bevel_quality__ == undefined) ? 2 : (extras.__special_bevel_quality__));
var _local11 = ((extras.__special_bevel_type__ == undefined) ? "inner" : (extras.__special_bevel_type__));
var _local10 = ((extras.__special_bevel_knockout__ == undefined) ? false : (extras.__special_bevel_knockout__));
if (propName == "bevel_distance") {
var _local9 = new flash.filters.BevelFilter(propValue, 45, 16777215, 1, 0, 1, 0, 0, 1, _local8, _local11, _local10);
}
if (propName == "bevel_angle") {
var _local9 = new flash.filters.BevelFilter(0, propValue, 16777215, 1, 0, 1, 0, 0, 1, _local8, _local11, _local10);
}
if (propName == "bevel_highlightColor") {
var _local9 = new flash.filters.BevelFilter(0, 45, propValue, 1, 0, 1, 0, 0, 1, _local8, _local11, _local10);
}
if (propName == "bevel_highlightAlpha") {
var _local9 = new flash.filters.BevelFilter(0, 45, 16777215, propValue, 0, 1, 0, 0, 1, _local8, _local11, _local10);
}
if (propName == "bevel_shadowColor") {
var _local9 = new flash.filters.BevelFilter(0, 45, 16777215, 1, propValue, 1, 0, 0, 1, _local8, _local11, _local10);
}
if (propName == "bevel_shadowAlpha") {
var _local9 = new flash.filters.BevelFilter(0, 45, 16777215, 1, 0, propValue, 0, 0, 1, _local8, _local11, _local10);
}
if (propName == "bevel_blurX") {
var _local9 = new flash.filters.BevelFilter(0, 45, 16777215, 1, 0, 1, propValue, 0, 1, _local8, _local11, _local10);
}
if (propName == "bevel_blurY") {
var _local9 = new flash.filters.BevelFilter(0, 45, 16777215, 1, 0, 1, 0, propValue, 1, _local8, _local11, _local10);
}
if (propName == "bevel_strength") {
var _local9 = new flash.filters.BevelFilter(0, 45, 16777215, 1, 0, 1, 0, 0, propValue, _local8, _local11, _local10);
}
_local3.push(_local9);
}
} else {
return(undefined);
}
mtarget.filters = _local3;
};
MovieClip.prototype.tween = (TextField.prototype.tween = (Sound.prototype.tween = function (prop, propDest, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, prop, propDest, timeSeconds, animType, delay, callback, extra1, extra2);
}));
ASSetPropFlags(MovieClip.prototype, "tween", 1, 0);
ASSetPropFlags(TextField.prototype, "tween", 1, 0);
ASSetPropFlags(Sound.prototype, "tween", 1, 0);
MovieClip.prototype.roundedTween = (TextField.prototype.roundedTween = (Sound.prototype.roundedTween = function (prop, propDest, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, prop, propDest, timeSeconds, animType, delay, callback, extra1, extra2, {mustRound:true});
}));
ASSetPropFlags(MovieClip.prototype, "roundedTween", 1, 0);
ASSetPropFlags(TextField.prototype, "roundedTween", 1, 0);
ASSetPropFlags(Sound.prototype, "roundedTween", 1, 0);
MovieClip.prototype.stopTween = (TextField.prototype.stopTween = (Sound.prototype.stopTween = function (props) {
if (typeof(props) == "string") {
props = [props];
}
if (props != undefined) {
var _local4 = 1;
while (_local4 < arguments.length) {
props.push(arguments[_local4]);
_local4++;
}
}
_global.$stopTween(this, props, true);
}));
ASSetPropFlags(MovieClip.prototype, "stopTween", 1, 0);
ASSetPropFlags(TextField.prototype, "stopTween", 1, 0);
ASSetPropFlags(Sound.prototype, "stopTween", 1, 0);
MovieClip.prototype.pauseTween = (TextField.prototype.pauseTween = (Sound.prototype.pauseTween = function (props) {
if (props != undefined) {
if (typeof(props) == "string") {
props = [props];
}
var _local6 = 1;
while (_local6 < Arguments.length) {
props.push(Arguments[_local6]);
_local6++;
}
}
var _local4 = _root.__tweenController__.$_tweenPropList;
var _local5;
for (var _local7 in _local4) {
if ((_local4[_local7]._targ == this) && (!_local4[_local7]._isPaused)) {
if (props != undefined) {
_local5 = false;
for (var _local6 in props) {
if (props[_local6] == _local4[_local7]._prop) {
_local5 = true;
break;
}
}
}
if ((props == undefined) || (_local5)) {
_local4[_local7]._isPaused = true;
_local4[_local7]._timePaused = _root.__tweenController__.$_tTime;
}
}
}
}));
ASSetPropFlags(MovieClip.prototype, "pauseTween", 1, 0);
ASSetPropFlags(TextField.prototype, "pauseTween", 1, 0);
ASSetPropFlags(Sound.prototype, "pauseTween", 1, 0);
MovieClip.prototype.resumeTween = (TextField.prototype.resumeTween = (Sound.prototype.resumeTween = function (props) {
if (props != undefined) {
if (typeof(props) == "string") {
props = [props];
}
var _local7 = 1;
while (_local7 < Arguments.length) {
props.push(Arguments[_local7]);
_local7++;
}
}
var _local3 = _root.__tweenController__.$_tweenPropList;
var _local5;
var _local6;
for (var _local8 in _local3) {
if ((_local3[_local8]._targ == this) && (_local3[_local8]._isPaused)) {
if (props != undefined) {
_local5 = false;
for (var _local7 in props) {
if (props[_local7] == _local3[_local8]._prop) {
_local5 = true;
break;
}
}
}
if ((props == undefined) || (_local5)) {
_local3[_local8]._isPaused = false;
_local6 = _root.__tweenController__.$_tTime - _local3[_local8]._timePaused;
_local3[_local8]._timeStart = _local3[_local8]._timeStart + _local6;
_local3[_local8]._timeDest = _local3[_local8]._timeDest + _local6;
_local3[_local8]._timePaused = 0;
}
}
}
}));
ASSetPropFlags(MovieClip.prototype, "resumeTween", 1, 0);
ASSetPropFlags(TextField.prototype, "resumeTween", 1, 0);
ASSetPropFlags(Sound.prototype, "resumeTween", 1, 0);
MovieClip.prototype.lockTween = (TextField.prototype.lockTween = (Sound.prototype.lockTween = function () {
this.$_isTweenLocked = true;
ASSetPropFlags(this, "this.$_isTweenLocked", 1, 0);
}));
ASSetPropFlags(MovieClip.prototype, "lockTween", 1, 0);
ASSetPropFlags(TextField.prototype, "lockTween", 1, 0);
ASSetPropFlags(Sound.prototype, "lockTween", 1, 0);
MovieClip.prototype.unlockTween = (TextField.prototype.unlockTween = (Sound.prototype.unlockTween = function () {
delete this.$_isTweenLocked;
}));
ASSetPropFlags(MovieClip.prototype, "unlockTween", 1, 0);
ASSetPropFlags(TextField.prototype, "unlockTween", 1, 0);
ASSetPropFlags(Sound.prototype, "unlockTween", 1, 0);
MovieClip.prototype.getTweens = (TextField.prototype.getTweens = (Sound.prototype.getTweens = function () {
return(this.$_tweenCount);
}));
ASSetPropFlags(MovieClip.prototype, "getTweens", 1, 0);
ASSetPropFlags(TextField.prototype, "getTweens", 1, 0);
ASSetPropFlags(Sound.prototype, "getTweens", 1, 0);
MovieClip.prototype.isTweening = (TextField.prototype.isTweening = (Sound.prototype.isTweening = function () {
return(((this.$_tweenCount > 0) ? true : false));
}));
ASSetPropFlags(MovieClip.prototype, "isTweening", 1, 0);
ASSetPropFlags(TextField.prototype, "isTweening", 1, 0);
ASSetPropFlags(Sound.prototype, "isTweening", 1, 0);
MovieClip.prototype.alphaTo = (TextField.prototype.alphaTo = function (propDest_a, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "_alpha", propDest_a, timeSeconds, animType, delay, callback, extra1, extra2);
});
ASSetPropFlags(MovieClip.prototype, "alphaTo", 1, 0);
ASSetPropFlags(TextField.prototype, "alphaTo", 1, 0);
MovieClip.prototype.frameTo = function (propDest_frame, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "__special_mc_frame__", propDest_frame, timeSeconds, animType, delay, callback, extra1, extra2);
};
ASSetPropFlags(MovieClip.prototype, "frameTo", 1, 0);
MovieClip.prototype.resizeTo = (TextField.prototype.resizeTo = function (propDest_width, propDest_height, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, ["_width", "_height"], [propDest_width, propDest_height], timeSeconds, animType, delay, callback, extra1, extra2);
});
ASSetPropFlags(MovieClip.prototype, "resizeTo", 1, 0);
ASSetPropFlags(TextField.prototype, "resizeTo", 1, 0);
MovieClip.prototype.rotateTo = (TextField.prototype.rotateTo = function (propDest_rotation, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "_rotation", propDest_rotation, timeSeconds, animType, delay, callback, extra1, extra2);
});
ASSetPropFlags(MovieClip.prototype, "rotateTo", 1, 0);
ASSetPropFlags(TextField.prototype, "rotateTo", 1, 0);
MovieClip.prototype.scaleTo = (TextField.prototype.scaleTo = function (propDest_scale, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, ["_xscale", "_yscale"], [propDest_scale, propDest_scale], timeSeconds, animType, delay, callback, extra1, extra2);
});
ASSetPropFlags(MovieClip.prototype, "scaleTo", 1, 0);
ASSetPropFlags(TextField.prototype, "scaleTo", 1, 0);
MovieClip.prototype.xScaleTo = (TextField.prototype.xScaleTo = function (propDest_scale, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "_xscale", propDest_scale, timeSeconds, animType, delay, callback, extra1, extra2);
});
ASSetPropFlags(MovieClip.prototype, "xScaleTo", 1, 0);
ASSetPropFlags(TextField.prototype, "xScaleTo", 1, 0);
MovieClip.prototype.yScaleTo = (TextField.prototype.yScaleTo = function (propDest_scale, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "_yscale", propDest_scale, timeSeconds, animType, delay, callback, extra1, extra2);
});
ASSetPropFlags(MovieClip.prototype, "yScaleTo", 1, 0);
ASSetPropFlags(TextField.prototype, "yScaleTo", 1, 0);
TextField.prototype.scrollTo = function (propDest_scroll, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "scroll", propDest_scroll, timeSeconds, animType, delay, callback, extra1, extra2);
};
ASSetPropFlags(TextField.prototype, "scrollTo", 1, 0);
MovieClip.prototype.slideTo = (TextField.prototype.slideTo = function (propDest_x, propDest_y, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, ["_x", "_y"], [propDest_x, propDest_y], timeSeconds, animType, delay, callback, extra1, extra2);
});
ASSetPropFlags(MovieClip.prototype, "slideTo", 1, 0);
ASSetPropFlags(TextField.prototype, "slideTo", 1, 0);
MovieClip.prototype.roundedSlideTo = (TextField.prototype.roundedSlideTo = function (propDest_x, propDest_y, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, ["_x", "_y"], [propDest_x, propDest_y], timeSeconds, animType, delay, callback, extra1, extra2, {mustRound:true});
});
ASSetPropFlags(MovieClip.prototype, "roundedSlideTo", 1, 0);
ASSetPropFlags(TextField.prototype, "roundedSlideTo", 1, 0);
MovieClip.prototype.xSlideTo = (TextField.prototype.xSlideTo = function (propDest_x, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "_x", propDest_x, timeSeconds, animType, delay, callback, extra1, extra2);
});
ASSetPropFlags(MovieClip.prototype, "xSlideTo", 1, 0);
ASSetPropFlags(TextField.prototype, "xSlideTo", 1, 0);
MovieClip.prototype.roundedXSlideTo = (TextField.prototype.roundedXSlideTo = function (propDest_x, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "_x", propDest_x, timeSeconds, animType, delay, callback, extra1, extra2, {mustRound:true});
});
ASSetPropFlags(MovieClip.prototype, "roundedXSlideTo", 1, 0);
ASSetPropFlags(TextField.prototype, "roundedXSlideTo", 1, 0);
MovieClip.prototype.ySlideTo = (TextField.prototype.ySlideTo = function (propDest_y, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "_y", propDest_y, timeSeconds, animType, delay, callback, extra1, extra2);
});
ASSetPropFlags(MovieClip.prototype, "ySlideTo", 1, 0);
ASSetPropFlags(TextField.prototype, "ySlideTo", 1, 0);
MovieClip.prototype.roundedYSlideTo = (TextField.prototype.roundedYSlideTo = function (propDest_y, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "_y", propDest_y, timeSeconds, animType, delay, callback, extra1, extra2, {mustRound:true});
});
ASSetPropFlags(MovieClip.prototype, "roundedYSlideTo", 1, 0);
ASSetPropFlags(TextField.prototype, "roundedYSlideTo", 1, 0);
MovieClip.prototype.bezierSlideTo = (TextField.prototype.bezierSlideTo = function (cpoint_x, cpoint_y, propDest_x, propDest_y, timeSeconds, animType, delay, callback, extra1, extra2) {
var _local3 = new Object();
_local3.__special_bst_ix__ = undefined;
_local3.__special_bst_iy__ = undefined;
_local3.__special_bst_cx__ = cpoint_x;
_local3.__special_bst_cy__ = cpoint_y;
_local3.__special_bst_dx__ = propDest_x;
_local3.__special_bst_dy__ = propDest_y;
_global.$addTween(this, "__special_bst_t__", 1, timeSeconds, animType, delay, callback, extra1, extra2, _local3);
});
ASSetPropFlags(MovieClip.prototype, "bezierSlideTo", 1, 0);
ASSetPropFlags(TextField.prototype, "bezierSlideTo", 1, 0);
MovieClip.prototype.roundedBezierSlideTo = (TextField.prototype.roundedBezierSlideTo = function (cpoint_x, cpoint_y, propDest_x, propDest_y, timeSeconds, animType, delay, callback, extra1, extra2) {
var _local3 = new Object();
_local3.__special_bst_ix__ = undefined;
_local3.__special_bst_iy__ = undefined;
_local3.__special_bst_cx__ = cpoint_x;
_local3.__special_bst_cy__ = cpoint_y;
_local3.__special_bst_dx__ = propDest_x;
_local3.__special_bst_dy__ = propDest_y;
_local3.mustRound = true;
_global.$addTween(this, "__special_bst_t__", 1, timeSeconds, animType, delay, callback, extra1, extra2, _local3);
});
ASSetPropFlags(MovieClip.prototype, "roundedBezierSlideTo", 1, 0);
ASSetPropFlags(TextField.prototype, "roundedBezierSlideTo", 1, 0);
Sound.prototype.volumeTo = function (propDest_volume, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "__special_sound_volume__", propDest_volume, timeSeconds, animType, delay, callback, extra1, extra2);
};
ASSetPropFlags(Sound.prototype, "volumeTo", 1, 0);
Sound.prototype.panTo = function (propDest_volume, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "__special_sound_pan__", propDest_volume, timeSeconds, animType, delay, callback, extra1, extra2);
};
ASSetPropFlags(Sound.prototype, "panTo", 1, 0);
MovieClip.prototype.colorTo = function (propDest_color, timeSeconds, animType, delay, callback, extra1, extra2) {
if (propDest_color == null) {
this.colorTransformTo(100, 0, 100, 0, 100, 0, undefined, undefined, timeSeconds, animType, delay, callback, extra1, extra2);
} else {
var _local3 = propDest_color >> 16;
var _local5 = (propDest_color & 65280) >> 8;
var _local4 = propDest_color & 255;
this.colorTransformTo(0, _local3, 0, _local5, 0, _local4, undefined, undefined, timeSeconds, animType, delay, callback, extra1, extra2);
}
};
ASSetPropFlags(MovieClip.prototype, "colorTo", 1, 0);
TextField.prototype.colorTo = function (propDest_color, timeSeconds, animType, delay, callback, extra1, extra2) {
var _local3 = propDest_color >> 16;
var _local6 = (propDest_color & 65280) >> 8;
var _local4 = propDest_color & 255;
_global.$addTween(this, ["__special_text_r__", "__special_text_g__", "__special_text_b__"], [_local3, _local6, _local4], timeSeconds, animType, delay, callback, extra1, extra2);
};
ASSetPropFlags(TextField.prototype, "colorTo", 1, 0);
MovieClip.prototype.colorTransformTo = function () {
if ((typeof(arguments[0]) == "object") && (arguments[0] != undefined)) {
_global.$addTween(this, ["__special_mc_ra__", "__special_mc_rb__", "__special_mc_ga__", "__special_mc_gb__", "__special_mc_ba__", "__special_mc_bb__", "__special_mc_aa__", "__special_mc_ab__"], [arguments[0].ra, arguments[0].rb, arguments[0].ga, arguments[0].gb, arguments[0].ba, arguments[0].bb, arguments[0].aa, arguments[0].ab], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5], arguments[6]);
} else {
_global.$addTween(this, ["__special_mc_ra__", "__special_mc_rb__", "__special_mc_ga__", "__special_mc_gb__", "__special_mc_ba__", "__special_mc_bb__", "__special_mc_aa__", "__special_mc_ab__"], [arguments[0], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5], arguments[6], arguments[7]], arguments[8], arguments[9], arguments[10], arguments[11], arguments[12], arguments[13]);
}
};
ASSetPropFlags(MovieClip.prototype, "colorTransformTo", 1, 0);
MovieClip.prototype.blurTo = (TextField.prototype.blurTo = function () {
if ((typeof(arguments[0]) == "object") && (arguments[0] != undefined)) {
_global.$addTween(this, ["__special_blur_x__", "__special_blur_y__"], [arguments[0].blurX, arguments[0].blurY], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5], arguments[6], {__special_blur_quality__:arguments[0].quality});
} else {
_global.$addTween(this, ["__special_blur_x__", "__special_blur_y__"], [arguments[0], arguments[0]], arguments[2], arguments[3], arguments[4], arguments[5], arguments[6], arguments[7], {__special_blur_quality__:arguments[1]});
}
});
ASSetPropFlags(MovieClip.prototype, "blurTo", 1, 0);
ASSetPropFlags(TextField.prototype, "blurTo", 1, 0);
MovieClip.prototype.xyBlurTo = (TextField.prototype.xyBlurTo = function (propDest_blurX, propDest_blurY, quality, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, ["__special_blur_x__", "__special_blur_y__"], [propDest_blurX, propDest_blurY], timeSeconds, animType, delay, callback, extra1, extra2, {__special_blur_quality__:quality});
});
ASSetPropFlags(MovieClip.prototype, "xyBlurTo", 1, 0);
ASSetPropFlags(TextField.prototype, "xyBlurTo", 1, 0);
MovieClip.prototype.xBlurTo = (TextField.prototype.xBlurTo = function (propDest_blur, quality, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "__special_blur_x__", propDest_blur, timeSeconds, animType, delay, callback, extra1, extra2, {__special_blur_quality__:quality});
});
ASSetPropFlags(MovieClip.prototype, "xBlurTo", 1, 0);
ASSetPropFlags(TextField.prototype, "xBlurTo", 1, 0);
MovieClip.prototype.yBlurTo = (TextField.prototype.yBlurTo = function (propDest_blur, quality, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, "__special_blur_y__", propDest_blur, timeSeconds, animType, delay, callback, extra1, extra2, {__special_blur_quality__:quality});
});
ASSetPropFlags(MovieClip.prototype, "yBlurTo", 1, 0);
ASSetPropFlags(TextField.prototype, "yBlurTo", 1, 0);
MovieClip.prototype.glowTo = (TextField.prototype.glowTo = function () {
if ((typeof(arguments[0]) == "object") && (arguments[0] != undefined)) {
_global.$addTween(this, ["__special_glow_color__", "__special_glow_alpha__", "__special_glow_blurX__", "__special_glow_blurY__", "__special_glow_strength__"], [arguments[0].color, arguments[0].alpha, arguments[0].blurX, arguments[0].blurY, arguments[0].strength], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5], arguments[6], {__special_glow_quality__:arguments[0].quality, __special_glow_inner__:arguments[0].inner, __special_glow_knockout__:arguments[0].knockout});
} else {
_global.$addTween(this, ["__special_glow_color__", "__special_glow_alpha__", "__special_glow_blurX__", "__special_glow_blurY__", "__special_glow_strength__"], [arguments[0], arguments[1], arguments[2], arguments[2], arguments[3]], arguments[7], arguments[8], arguments[9], arguments[10], arguments[11], arguments[12], {__special_glow_quality__:arguments[4], __special_glow_inner__:arguments[5], __special_glow_knockout__:arguments[6]});
}
});
ASSetPropFlags(MovieClip.prototype, "glowTo", 1, 0);
ASSetPropFlags(TextField.prototype, "glowTo", 1, 0);
MovieClip.prototype.xyGlowTo = (TextField.prototype.xyGlowTo = function (propDest_color, propDest_alpha, propDest_blurX, propDest_blurY, propDest_strength, quality, inner, knockout, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, ["__special_glow_color__", "__special_glow_alpha__", "__special_glow_blurX__", "__special_glow_blurY__", "__special_glow_strength__"], [propDest_color, propDest_alpha, propDest_blurX, propDest_blurY, propDest_strength], timeSeconds, animType, delay, callback, extra1, extra2, {__special_glow_quality__:quality, __special_glow_inner__:inner, __special_glow_knockout__:knockout});
});
ASSetPropFlags(MovieClip.prototype, "xyGlowTo", 1, 0);
ASSetPropFlags(TextField.prototype, "xyGlowTo", 1, 0);
MovieClip.prototype.xGlowTo = (TextField.prototype.xGlowTo = function (propDest_color, propDest_alpha, propDest_blur, propDest_strength, quality, inner, knockout, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, ["__special_glow_color__", "__special_glow_alpha__", "__special_glow_blurX__", "__special_glow_strength__"], [propDest_color, propDest_alpha, propDest_blur, propDest_strength], timeSeconds, animType, delay, callback, extra1, extra2, {__special_glow_quality__:quality, __special_glow_inner__:inner, __special_glow_knockout__:knockout});
});
ASSetPropFlags(MovieClip.prototype, "xGlowTo", 1, 0);
ASSetPropFlags(TextField.prototype, "xGlowTo", 1, 0);
MovieClip.prototype.yGlowTo = (TextField.prototype.yGlowTo = function (propDest_color, propDest_alpha, propDest_blur, propDest_strength, quality, inner, knockout, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, ["__special_glow_color__", "__special_glow_alpha__", "__special_glow_blurY__", "__special_glow_strength__"], [propDest_color, propDest_alpha, propDest_blur, propDest_strength], timeSeconds, animType, delay, callback, extra1, extra2, {__special_glow_quality__:quality, __special_glow_inner__:inner, __special_glow_knockout__:knockout});
});
ASSetPropFlags(MovieClip.prototype, "yGlowTo", 1, 0);
ASSetPropFlags(TextField.prototype, "yGlowTo", 1, 0);
MovieClip.prototype.bevelTo = (TextField.prototype.bevelTo = function () {
if ((typeof(arguments[0]) == "object") && (arguments[0] != undefined)) {
_global.$addTween(this, ["__special_bevel_distance__", "__special_bevel_angle__", "__special_bevel_highlightColor__", "__special_bevel_highlightAlpha__", "__special_bevel_shadowColor__", "__special_bevel_shadowAlpha__", "__special_bevel_blurX__", "__special_bevel_blurY__", "__special_bevel_strength__"], [arguments[0].distance, arguments[0].angle, arguments[0].highlightColor, arguments[0].highlightAlpha * 100, arguments[0].shadowColor, arguments[0].shadowAlpha * 100, arguments[0].blurX, arguments[0].blurY, arguments[0].strength], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5], arguments[6], {__special_bevel_quality__:arguments[0].quality, __special_bevel_type__:arguments[0].type, __special_bevel_knockout__:arguments[0].knockout});
} else {
_global.$addTween(this, ["__special_bevel_distance__", "__special_bevel_angle__", "__special_bevel_highlightColor__", "__special_bevel_highlightAlpha__", "__special_bevel_shadowColor__", "__special_bevel_shadowAlpha__", "__special_bevel_blurX__", "__special_bevel_blurY__", "__special_bevel_strength__"], [arguments[0], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5], arguments[6], arguments[6], arguments[7]], arguments[11], arguments[12], arguments[13], arguments[14], arguments[15], arguments[16], {__special_bevel_quality__:arguments[8], __special_bevel_type__:arguments[9], __special_bevel_knockout__:arguments[10]});
}
});
ASSetPropFlags(MovieClip.prototype, "bevelTo", 1, 0);
ASSetPropFlags(TextField.prototype, "bevelTo", 1, 0);
MovieClip.prototype.xyBevelTo = (TextField.prototype.xyBevelTo = function (propDest_distance, propDest_angle, propDest_highlightColor, propDest_highlightAlpha, propDest_shadowColor, propDest_shadowAlpha, propDest_blurX, propDest_blurY, propDest_strength, quality, type, knockout, timeSeconds, animType, delay, callback, extra1, extra2) {
_global.$addTween(this, ["__special_bevel_distance__", "__special_bevel_angle__", "__special_bevel_highlightColor__", "__special_bevel_highlightAlpha__", "__special_bevel_shadowColor__", "__special_bevel_shadowAlpha__", "__special_bevel_blurX__", "__special_bevel_blurY__", "__special_bevel_blurY__", "__special_bevel_strength__"], [propDest_distance, propDest_angle, propDest_highlightColor, propDest_highlightAlpha, propDest_shadowColor, propDest_shadowAlpha, propDest_blur, propDest_blur, propDest_strength], timeSeconds, animType, delay, callback, extra1, extra2, {__special_bevel_quality__:quality, __special_bevel_type__:type, __special_bevel_knockout__:knockout});
});
ASSetPropFlags(MovieClip.prototype, "xyBevelTo", 1, 0);
ASSetPropFlags(TextField.prototype, "xyBevelTo", 1, 0);
_global.findPointOnCurve = function (p1x, p1y, cx, cy, p2x, p2y, t) {
return({x:p1x + (t * (((2 * (1 - t)) * (cx - p1x)) + (t * (p2x - p1x)))), y:p1y + (t * (((2 * (1 - t)) * (cy - p1y)) + (t * (p2y - p1y))))});
};
ASSetPropFlags(_global, "findPointOnCurve", 1, 0);
_global.findTweenColor = function (objProp, tTime) {
var _local8 = objProp._propStart >> 16;
var _local4 = objProp._propDest >> 16;
var _local5 = (objProp._propStart >> 8) & 255;
var _local6 = (objProp._propDest >> 8) & 255;
var _local9 = objProp._propStart & 255;
var _local7 = objProp._propDest & 255;
var _local12 = Math.round(_global.findTweenValue(_local8, _local4, objProp._timeStart, tTime - (objProp._delay * 1000), objProp._timeDest, objProp._animType, objProp._extra1, objProp._extra2));
var _local10 = Math.round(_global.findTweenValue(_local5, _local6, objProp._timeStart, tTime - (objProp._delay * 1000), objProp._timeDest, objProp._animType, objProp._extra1, objProp._extra2));
var _local3 = Math.round(_global.findTweenValue(_local9, _local7, objProp._timeStart, tTime - (objProp._delay * 1000), objProp._timeDest, objProp._animType, objProp._extra1, objProp._extra2));
return(((_local12 << 16) + (_local10 << 8)) + _local3);
};
_global.findTweenValue = function (_propStart, _propDest, _timeStart, _timeNow, _timeDest, _animType, _extra1, _extra2) {
var _local1 = _timeNow - _timeStart;
var _local4 = _propStart;
var _local2 = _propDest - _propStart;
var _local3 = _timeDest - _timeStart;
var _local6 = _extra1;
var _local7 = _extra2;
var _local5 = _extra1;
switch (_animType.toLowerCase()) {
case "linear" :
return(((_local2 * _local1) / _local3) + _local4);
case "easeinquad" :
_local1 = _local1 / _local3;
return(((_local2 * _local1) * _local1) + _local4);
case "easeoutquad" :
_local1 = _local1 / _local3;
return((((-_local2) * _local1) * (_local1 - 2)) + _local4);
case "easeinoutquad" :
_local1 = _local1 / (_local3 / 2);
if (_local1 < 1) {
return((((_local2 / 2) * _local1) * _local1) + _local4);
}
_local1--;
return((((-_local2) / 2) * ((_local1 * (_local1 - 2)) - 1)) + _local4);
case "easeoutinquad" :
if (_local1 < (_local3 / 2)) {
return((findTweenValue(0, _local2, 0, _local1 * 2, _local3, "easeOutQuad") * 0.5) + _local4);
}
return(((findTweenValue(0, _local2, 0, (_local1 * 2) - _local3, _local3, "easeInQuad") * 0.5) + (_local2 * 0.5)) + _local4);
case "easeincubic" :
_local1 = _local1 / _local3;
return((((_local2 * _local1) * _local1) * _local1) + _local4);
case "easeoutcubic" :
_local1 = (_local1 / _local3) - 1;
return((_local2 * (((_local1 * _local1) * _local1) + 1)) + _local4);
case "easeinoutcubic" :
_local1 = _local1 / (_local3 / 2);
if (_local1 < 1) {
return(((((_local2 / 2) * _local1) * _local1) * _local1) + _local4);
}
_local1 = _local1 - 2;
return(((_local2 / 2) * (((_local1 * _local1) * _local1) + 2)) + _local4);
case "easeoutincubic" :
if (_local1 < (_local3 / 2)) {
return((findTweenValue(0, _local2, 0, _local1 * 2, _local3, "easeOutCubic") * 0.5) + _local4);
}
return(((findTweenValue(0, _local2, 0, (_local1 * 2) - _local3, _local3, "easeInCubic") * 0.5) + (_local2 * 0.5)) + _local4);
case "easeinquart" :
_local1 = _local1 / _local3;
return(((((_local2 * _local1) * _local1) * _local1) * _local1) + _local4);
case "easeoutquart" :
_local1 = (_local1 / _local3) - 1;
return(((-_local2) * ((((_local1 * _local1) * _local1) * _local1) - 1)) + _local4);
case "easeinoutquart" :
_local1 = _local1 / (_local3 / 2);
if (_local1 < 1) {
return((((((_local2 / 2) * _local1) * _local1) * _local1) * _local1) + _local4);
}
_local1 = _local1 - 2;
return((((-_local2) / 2) * ((((_local1 * _local1) * _local1) * _local1) - 2)) + _local4);
case "easeoutinquart" :
if (_local1 < (_local3 / 2)) {
return((findTweenValue(0, _local2, 0, _local1 * 2, _local3, "easeOutQuart") * 0.5) + _local4);
}
return(((findTweenValue(0, _local2, 0, (_local1 * 2) - _local3, _local3, "easeInQuart") * 0.5) + (_local2 * 0.5)) + _local4);
case "easeinquint" :
_local1 = _local1 / _local3;
return((((((_local2 * _local1) * _local1) * _local1) * _local1) * _local1) + _local4);
case "easeoutquint" :
_local1 = (_local1 / _local3) - 1;
return((_local2 * (((((_local1 * _local1) * _local1) * _local1) * _local1) + 1)) + _local4);
case "easeinoutquint" :
_local1 = _local1 / (_local3 / 2);
if (_local1 < 1) {
return(((((((_local2 / 2) * _local1) * _local1) * _local1) * _local1) * _local1) + _local4);
}
_local1 = _local1 - 2;
return(((_local2 / 2) * (((((_local1 * _local1) * _local1) * _local1) * _local1) + 2)) + _local4);
case "easeoutinquint" :
if (_local1 < (_local3 / 2)) {
return((findTweenValue(0, _local2, 0, _local1 * 2, _local3, "easeOutQuint") * 0.5) + _local4);
}
return(((findTweenValue(0, _local2, 0, (_local1 * 2) - _local3, _local3, "easeInQuint") * 0.5) + (_local2 * 0.5)) + _local4);
case "easeinsine" :
return((((-_local2) * Math.cos((_local1 / _local3) * (Math.PI/2))) + _local2) + _local4);
case "easeoutsine" :
return((_local2 * Math.sin((_local1 / _local3) * (Math.PI/2))) + _local4);
case "easeinoutsine" :
return((((-_local2) / 2) * (Math.cos((Math.PI * _local1) / _local3) - 1)) + _local4);
case "easeoutinsine" :
if (_local1 < (_local3 / 2)) {
return((findTweenValue(0, _local2, 0, _local1 * 2, _local3, "easeOutSine") * 0.5) + _local4);
}
return(((findTweenValue(0, _local2, 0, (_local1 * 2) - _local3, _local3, "easeInSine") * 0.5) + (_local2 * 0.5)) + _local4);
case "easeinexpo" :
return(((_local1 == 0) ? (_local4) : ((_local2 * Math.pow(2, 10 * ((_local1 / _local3) - 1))) + _local4)));
case "easeoutexpo" :
return(((_local1 == _local3) ? (_local4 + _local2) : ((_local2 * ((-Math.pow(2, (-10 * _local1) / _local3)) + 1)) + _local4)));
case "easeinoutexpo" :
if (_local1 == 0) {
return(_local4);
}
if (_local1 == _local3) {
return(_local4 + _local2);
}
_local1 = _local1 / (_local3 / 2);
if (_local1 < 1) {
return(((_local2 / 2) * Math.pow(2, 10 * (_local1 - 1))) + _local4);
}
_local1--;
return(((_local2 / 2) * ((-Math.pow(2, -10 * _local1)) + 2)) + _local4);
case "easeoutinexpo" :
if (_local1 == 0) {
return(_local4);
}
if (_local1 == _local3) {
return(_local4 + _local2);
}
_local1 = _local1 / (_local3 / 2);
if (_local1 < 1) {
return(((_local2 / 2) * ((-Math.pow(2, (-10 * _local1) / 1)) + 1)) + _local4);
}
return(((_local2 / 2) * (Math.pow(2, (10 * (_local1 - 2)) / 1) + 1)) + _local4);
case "easeincirc" :
_local1 = _local1 / _local3;
return(((-_local2) * (Math.sqrt(1 - (_local1 * _local1)) - 1)) + _local4);
case "easeoutcirc" :
_local1 = (_local1 / _local3) - 1;
return((_local2 * Math.sqrt(1 - (_local1 * _local1))) + _local4);
case "easeinoutcirc" :
_local1 = _local1 / (_local3 / 2);
if (_local1 < 1) {
return((((-_local2) / 2) * (Math.sqrt(1 - (_local1 * _local1)) - 1)) + _local4);
}
_local1 = _local1 - 2;
return(((_local2 / 2) * (Math.sqrt(1 - (_local1 * _local1)) + 1)) + _local4);
case "easeoutincirc" :
if (_local1 < (_local3 / 2)) {
return((findTweenValue(0, _local2, 0, _local1 * 2, _local3, "easeOutCirc") * 0.5) + _local4);
}
return(((findTweenValue(0, _local2, 0, (_local1 * 2) - _local3, _local3, "easeInCirc") * 0.5) + (_local2 * 0.5)) + _local4);
case "easeinelastic" :
if (_local1 == 0) {
return(_local4);
}
_local1 = _local1 / _local3;
if (_local1 == 1) {
return(_local4 + _local2);
}
if (!_local7) {
_local7 = _local3 * 0.3;
}
if ((!_local6) || (_local6 < Math.abs(_local2))) {
_local6 = _local2;
_local5 = _local7 / 4;
} else {
_local5 = (_local7 / (Math.PI*2)) * Math.asin(_local2 / _local6);
}
_local1 = _local1 - 1;
return((-((_local6 * Math.pow(2, 10 * _local1)) * Math.sin((((_local1 * _local3) - _local5) * (Math.PI*2)) / _local7))) + _local4);
case "easeoutelastic" :
if (_local1 == 0) {
return(_local4);
}
_local1 = _local1 / _local3;
if (_local1 == 1) {
return(_local4 + _local2);
}
if (!_local7) {
_local7 = _local3 * 0.3;
}
if ((!_local6) || (_local6 < Math.abs(_local2))) {
_local6 = _local2;
_local5 = _local7 / 4;
} else {
_local5 = (_local7 / (Math.PI*2)) * Math.asin(_local2 / _local6);
}
return((((_local6 * Math.pow(2, -10 * _local1)) * Math.sin((((_local1 * _local3) - _local5) * (Math.PI*2)) / _local7)) + _local2) + _local4);
case "easeinoutelastic" :
if (_local1 == 0) {
return(_local4);
}
_local1 = _local1 / (_local3 / 2);
if (_local1 == 2) {
return(_local4 + _local2);
}
if (!_local7) {
_local7 = _local3 * 0.45;
}
if ((!_local6) || (_local6 < Math.abs(_local2))) {
_local6 = _local2;
_local5 = _local7 / 4;
} else {
_local5 = (_local7 / (Math.PI*2)) * Math.asin(_local2 / _local6);
}
if (_local1 < 1) {
_local1 = _local1 - 1;
return((-0.5 * ((_local6 * Math.pow(2, 10 * _local1)) * Math.sin((((_local1 * _local3) - _local5) * (Math.PI*2)) / _local7))) + _local4);
}
_local1 = _local1 - 1;
return(((((_local6 * Math.pow(2, -10 * _local1)) * Math.sin((((_local1 * _local3) - _local5) * (Math.PI*2)) / _local7)) * 0.5) + _local2) + _local4);
case "easeoutinelastic" :
if (_local1 < (_local3 / 2)) {
return((findTweenValue(0, _local2, 0, _local1 * 2, _local3, "easeOutElastic") * 0.5) + _local4);
}
return(((findTweenValue(0, _local2, 0, (_local1 * 2) - _local3, _local3, "easeInElastic") * 0.5) + (_local2 * 0.5)) + _local4);
case "easeinback" :
if (_local5 == undefined) {
_local5 = 1.70158;
}
_local1 = _local1 / _local3;
return((((_local2 * _local1) * _local1) * (((_local5 + 1) * _local1) - _local5)) + _local4);
case "easeoutback" :
if (_local5 == undefined) {
_local5 = 1.70158;
}
_local1 = (_local1 / _local3) - 1;
return((_local2 * (((_local1 * _local1) * (((_local5 + 1) * _local1) + _local5)) + 1)) + _local4);
case "easeinoutback" :
if (_local5 == undefined) {
_local5 = 1.70158;
}
_local1 = _local1 / (_local3 / 2);
if (_local1 < 1) {
_local5 = _local5 * 1.525;
return(((_local2 / 2) * ((_local1 * _local1) * (((_local5 + 1) * _local1) - _local5))) + _local4);
}
_local1 = _local1 - 2;
_local5 = _local5 * 1.525;
return(((_local2 / 2) * (((_local1 * _local1) * (((_local5 + 1) * _local1) + _local5)) + 2)) + _local4);
case "easeoutinback" :
if (_local1 < (_local3 / 2)) {
return((findTweenValue(0, _local2, 0, _local1 * 2, _local3, "easeOutBack") * 0.5) + _local4);
}
return(((findTweenValue(0, _local2, 0, (_local1 * 2) - _local3, _local3, "easeInBack") * 0.5) + (_local2 * 0.5)) + _local4);
case "easeinbounce" :
return((_local2 - findTweenValue(0, _local2, 0, _local3 - _local1, _local3, "easeOutBounce")) + _local4);
case "easeoutbounce" :
_local1 = _local1 / _local3;
if (_local1 < 0.363636363636364) {
return((_local2 * ((7.5625 * _local1) * _local1)) + _local4);
}
if (_local1 < 0.727272727272727) {
_local1 = _local1 - 0.545454545454545;
return((_local2 * (((7.5625 * _local1) * _local1) + 0.75)) + _local4);
}
if (_local1 < 0.909090909090909) {
_local1 = _local1 - 0.818181818181818;
return((_local2 * (((7.5625 * _local1) * _local1) + 0.9375)) + _local4);
}
_local1 = _local1 - 0.954545454545455;
return((_local2 * (((7.5625 * _local1) * _local1) + 0.984375)) + _local4);
case "easeinoutbounce" :
if (_local1 < (_local3 / 2)) {
return((findTweenValue(0, _local2, 0, _local1 * 2, _local3, "easeInBounce") * 0.5) + _local4);
}
return(((findTweenValue(0, _local2, 0, (_local1 * 2) - _local3, _local3, "easeOutBounce") * 0.5) + (_local2 * 0.5)) + _local4);
case "easeoutinbounce" :
if (_local1 < (_local3 / 2)) {
return((findTweenValue(0, _local2, 0, _local1 * 2, _local3, "easeOutBounce") * 0.5) + _local4);
}
return(((findTweenValue(0, _local2, 0, (_local1 * 2) - _local3, _local3, "easeInBounce") * 0.5) + (_local2 * 0.5)) + _local4);
}
trace(("MC TWEEN ### Error on transition: there's no \"" + _animType) + "\" animation type.");
return(0);
};
ASSetPropFlags(_global, "findTweenValue", 1, 0);
_quality = "HIGH";
this.playBtn.onRelease = function () {
gotoAndPlay (23);
playSound("mouseDown");
};
this.playBtn.onRollOver = function () {
playSound("mouseOver");
this.scaleTo(140, 0.5);
};
this.playBtn.onRollOut = function () {
this.scaleTo(130, 0.5);
};
viewHighscoreBtn.onRelease = function () {
soundManager.playSound("mouse down");
showHighscores();
};
viewHighscoreBtn.onRollOver = function () {
gs.TweenMax.to(this, 0.25, {glowFilter:{color:16777215, blurX:10, blurY:10, alpha:1}});
soundManager.playSound("mouse over");
};
viewHighscoreBtn.onRollOut = (viewHighscoreBtn.onReleaseOutside = function () {
gs.TweenMax.to(this, 0.25, {glowFilter:{alpha:0}});
});
this.reset_btn.onRelease = function () {
playSound("mouseDown");
_root.score = 0;
_root.yourScoreTextBox.text = _root.score;
resetclip.gotoAndPlay(2);
storage.data.score = 0;
storage.flush();
};
this.reset_btn.onRollOver = function () {
playSound("mouseOver");
};
yourScoreTextBox.text = score;
var linkageId = "cardsBitmap";
var myBitmapData = flash.display.BitmapData.loadBitmap(linkageId);
i = 0;
while (i < 52) {
clip = introCardsHolder.attachMovie("card", "c" + i, i);
var bitmap_mc = clip.createEmptyMovieClip("card", clip.getNextHighestDepth());
var btnBitmap = (new flash.display.BitmapData(73, 98, true, 13421772));
suitPos = Math.floor(i / 13);
xloc = (i - (suitPos * 13)) * 73;
yloc = suitPos * 98;
clip._x = 320;
clip._y = -200;
switch (random(3)) {
case 0 :
clip.slideTo(30, Math.random() * 480, 1 + (Math.random() * 1), "", i / 2);
break;
case 1 :
clip.slideTo(610, Math.random() * 480, 1 + (Math.random() * 1), "", i / 2);
break;
case 2 :
clip.slideTo(Math.random() * 610, 10, 0.5 + (Math.random() * 1), "", i / 2);
}
clip.rotateTo(Math.random() * 360, 0.5 + (Math.random() * 1), "", i / 2);
btnBitmap.copyPixels(myBitmapData, new flash.geom.Rectangle(xloc, yloc, xloc + 73, yloc + 98), new flash.geom.Point(0, 0));
bitmap_mc.attachBitmap(btnBitmap, this.getNextHighestDepth(), "always", true);
if ((Math.random() * 10) < 2) {
clip.cardBacking = clip.attachMovie("backOfCardClip", "cardBacking", 2);
}
clip.cardUnderlay._visible = false;
i++;
}
Frame 22
stop();
Frame 23
function testGameWon() {
totalCardCount = 0;
for (var _local1 in cardPosition.pos15) {
totalCardCount++;
}
for (var _local1 in cardPosition.pos16) {
totalCardCount++;
}
for (var _local1 in cardPosition.pos17) {
totalCardCount++;
}
for (var _local1 in cardPosition.pos18) {
totalCardCount++;
}
if (totalCardCount > 51) {
if (gameAlreadyWon == false) {
trace("game has been solved");
playSound("game complete");
score++;
gameAlreadyWon = true;
gameState = "game complete";
}
}
updateTextBoxes();
}
function generateKitty() {
tally = 0;
putOutKittyArray = new Array();
for (var _local1 in cardPosition.deck) {
putOutKittyArray.push(cardPosition.deck[_local1]);
tally++;
}
amountInKitty = 0;
if (tally == 0) {
count = 0;
for (var _local1 in cardPosition.pos7) {
trace(_local1);
cardPosition.deck["slot" + count] = cardPosition.pos7[_local1];
tempObject = cardPosition.deck["slot" + count];
delete cardPosition.pos7[_local1];
tempObject.revealed = false;
tc = tempObject.clip;
tc.slot = count;
tempObject.slot = count;
tc.cardBacking._visible = true;
count++;
}
deckxOffset = 0;
deckyOffset = 0;
playSound("flip deck");
currentDepth = cardHolder.getNextHighestDepth();
l = 0;
while (l < count) {
tObj = cardPosition.deck["slot" + l];
tClip = tObj.clip;
if (l > (count - 3)) {
tClip.cardBacking._xscale = 0;
tClip.cardBacking.xScaleTo(100, 0.5);
}
tClip.swapDepths(currentDepth);
tClip.stopTween();
tClip.slideTo(deckLocation._x, deckLocation._y + deckyOffset, 1);
tObj.slot = l;
deckxOffset = deckxOffset + 0.5;
deckyOffset = deckyOffset + 0.25;
currentDepth++;
l++;
}
} else {
playSound("card flip");
amountInKitty = 0;
jj = 0;
while (jj < 52) {
tempObject = cardPosition.pos7["slot" + jj];
if (tempObject != undefined) {
amountInKitty++;
tempObject.clip.stopTween();
tempObject.clip.slideTo(position7._x, position7._y, 0.5);
}
jj++;
}
newSlot = amountInKitty;
cardC = 0;
card1 = putOutKittyArray[0];
card2 = putOutKittyArray[1];
card3 = putOutKittyArray[2];
if (card1 != undefined) {
tc = card1.clip;
card1.revealed = true;
tc.cardBacking._visible = false;
cardPosition.pos7["slot" + newSlot] = cardPosition.deck["slot" + (tally - 1)];
delete cardPosition.deck["slot" + (tally - 1)];
card1.pos = 7;
tc.pos = 7;
card1.slot = newSlot;
tc.slot = newSlot;
theDepth = cardHolder.getNextHighestDepth();
tc.swapDepths(theDepth);
tc.stopTween();
theXPos = position7._x + (cardC * cardSlotOffset);
tc.slideTo(theXPos, position7._y, 1, "", 0);
cardC++;
newSlot++;
}
if (card2 != undefined) {
tc = card2.clip;
card2.revealed = true;
tc.cardBacking._visible = false;
theDepth = cardHolder.getNextHighestDepth();
tc.swapDepths(theDepth);
card2.pos = pos7;
card2.slot = newSlot;
cardPosition.pos7["slot" + newSlot] = cardPosition.deck["slot" + (tally - 2)];
delete cardPosition.deck["slot" + (tally - 2)];
card2.pos = 7;
tc.pos = 7;
theDepth = cardHolder.getNextHighestDepth();
tc.swapDepths(theDepth);
tc.stopTween();
theXPos = position7._x + (cardC * cardSlotOffset);
tc.slideTo(theXPos, position7._y, 1, "", 0);
cardC++;
tc.slot = newSlot;
newSlot++;
}
if (card3 != undefined) {
tc = card3.clip;
card3.revealed = true;
tc.cardBacking._visible = false;
cardPosition.pos7["slot" + newSlot] = cardPosition.deck["slot" + (tally - 3)];
delete cardPosition.deck["slot" + (tally - 3)];
card3.pos = 7;
tc.pos = 7;
theDepth = cardHolder.getNextHighestDepth();
tc.swapDepths(theDepth);
tc.stopTween();
theXPos = position7._x + (cardC * cardSlotOffset);
tc.slideTo(theXPos, position7._y, 1, "", 0);
cardC++;
card3.slot = newSlot;
tc.slot = newSlot;
newSlot++;
}
}
}
function displayKitty() {
playSound("card flip");
amountInKitty = 0;
for (var _local1 in cardPosition.pos7) {
amountInKitty++;
}
cardCount = 0;
i = 0;
while (i < amountInKitty) {
tempObject = cardPosition.pos7["slot" + i];
i++;
}
}
function stopCardDrag(tempObj) {
stopDrag();
dropX = _xmouse;
dropY = _ymouse;
if (dropY > 140) {
dropPos = Math.floor(dropX / 91);
dropPosRef = "position";
} else if (dropX > 270) {
dropPos = 15 + Math.floor((dropX - 273) / 91);
dropPosRef = "foundation";
} else {
trace("user drops on kitty");
dropPos = 7;
dropPosRef = "position";
if (pickUpPos < 7) {
isLegal = false;
}
}
to = draggingArray[0];
returnPos = to.pos;
returnSlot = to.slot;
if (cardPosition["pos" + dropPos].slot0 == undefined) {
lastSlot = 0;
} else {
lastSlot = undefined;
k = 0;
while (lastSlot == undefined) {
if (cardPosition["pos" + dropPos]["slot" + k] == undefined) {
if (cardPosition["pos" + dropPos]["slot" + (k + 1)] == undefined) {
lastSlot = k;
}
} else {
k++;
}
}
}
topCardInPos = cardPosition["pos" + dropPos]["slot" + (lastSlot - 1)];
isLegal = false;
if ((dropPosRef == "foundation") && (draggingArray.length < 2)) {
if ((lastSlot == 0) && (topCardInPos == undefined)) {
if (to.value == 0) {
isLegal = true;
playSound("foundation");
}
}
if ((to.suit == topCardInPos.suit) && (topCardInPos.value == (to.value - 1))) {
isLegal = true;
}
}
if (dropPos == 7) {
isLegal = false;
}
if (dropPosRef == "position") {
if ((lastSlot == 0) && (topCardInPos == undefined)) {
if (to.value == 12) {
isLegal = true;
}
}
if (topCardInPos.value == (to.value + 1)) {
if ((to.suit == "hearts") && (topCardInPos.suit == "spades")) {
isLegal = true;
}
if ((to.suit == "hearts") && (topCardInPos.suit == "clubs")) {
isLegal = true;
}
if ((to.suit == "diamonds") && (topCardInPos.suit == "spades")) {
isLegal = true;
}
if ((to.suit == "diamonds") && (topCardInPos.suit == "clubs")) {
isLegal = true;
}
if ((to.suit == "spades") && (topCardInPos.suit == "hearts")) {
isLegal = true;
}
if ((to.suit == "spades") && (topCardInPos.suit == "diamonds")) {
isLegal = true;
}
if ((to.suit == "clubs") && (topCardInPos.suit == "hearts")) {
isLegal = true;
}
if ((to.suit == "clubs") && (topCardInPos.suit == "diamonds")) {
isLegal = true;
}
}
}
if (dropPos == pickUpPos) {
canAuto = false;
trace("double click detected");
FcardCount = 0;
i = 0;
while (i < 30) {
tempObject = cardPosition.pos15["slot" + i];
if (tempObject != undefined) {
trace(i);
FcardCount++;
}
i++;
}
trace("FcardCount at 15 = " + FcardCount);
tN = FcardCount - 1;
trace(tN);
foundObj1 = cardPosition.pos15["slot" + tN];
trace(foundObj1);
if ((FcardCount == 0) && (foundObj1 == undefined)) {
if (to.value == 0) {
canAuto = true;
autoNewPos = 15;
lastSlot = FcardCount;
}
} else {
trace(foundObj1.value);
if (foundObj1.value == (to.value - 1)) {
if (to.suit == foundObj1.suit) {
canAuto = true;
autoNewPos = 15;
lastSlot = FcardCount;
}
}
}
if ((!canAuto) && (draggingArray.length < 2)) {
trace("canAuto = " + canAuto);
FcardCount = 0;
i = 0;
while (i < 30) {
tempObject = cardPosition.pos16["slot" + i];
if (tempObject != undefined) {
FcardCount++;
}
i++;
}
trace(("foundation16 contains " + FcardCount) + " cards");
foundObj2 = cardPosition.pos16["slot" + (FcardCount - 1)];
if ((FcardCount == 0) && (foundObj2 == undefined)) {
if (to.value == 0) {
canAuto = true;
autoNewPos = 16;
lastSlot = FcardCount;
}
} else if (foundObj2.value == (to.value - 1)) {
if (to.suit == foundObj2.suit) {
canAuto = true;
autoNewPos = 16;
lastSlot = FcardCount;
}
}
}
if (!canAuto) {
FcardCount = 0;
i = 0;
while (i < 30) {
tempObject = cardPosition.pos17["slot" + i];
if (tempObject != undefined) {
FcardCount++;
}
i++;
}
trace(("foundation17 contains " + FcardCount) + " cards");
foundObj3 = cardPosition.pos17["slot" + (FcardCount - 1)];
if ((FcardCount == 0) && (foundObj3 == undefined)) {
if (to.value == 0) {
canAuto = true;
autoNewPos = 17;
lastSlot = FcardCount;
}
} else if (foundObj3.value == (to.value - 1)) {
if (to.suit == foundObj3.suit) {
canAuto = true;
autoNewPos = 17;
lastSlot = FcardCount;
}
}
}
if (!canAuto) {
FcardCount = 0;
i = 0;
while (i < 30) {
tempObject = cardPosition.pos18["slot" + i];
if (tempObject != undefined) {
FcardCount++;
}
i++;
}
trace(("foundation18 contains " + FcardCount) + " cards");
foundObj4 = cardPosition.pos18["slot" + (FcardCount - 1)];
if ((FcardCount == 0) && (foundObj4 == undefined)) {
if (to.value == 0) {
canAuto = true;
autoNewPos = 18;
lastSlot = FcardCount;
}
} else if (foundObj4.value == (to.value - 1)) {
if (to.suit == foundObj4.suit) {
canAuto = true;
autoNewPos = 18;
lastSlot = FcardCount;
}
}
}
if (canAuto) {
isLegal = true;
trace("card can move to position " + autoNewPos);
dropPos = (to.pos = autoNewPos);
if (pickUpPos < 7) {
revealCard = cardPosition["pos" + pickUpPos]["slot" + (pickUpSlot - 1)];
if ((revealCard.revealed == false) || (revealCard.revealed == undefined)) {
tempCard = revealCard.clip;
if (tempCard != undefined) {
playSound("card flip");
revealCard.revealed = true;
tempCard.cardBacking.xScaleTo(0, 0.5, "", 0, function () {
this._visible = false;
});
tempCard.card._xscale = 0;
tempCard.card.xScaleTo(100, 1);
}
}
}
}
}
if (isLegal) {
returnSlot = lastSlot;
to.pos = dropPos;
to.slot = returnSlot;
l = pickUpSlot;
while (l < (pickUpSlot + 40)) {
delete cardPosition["pos" + pickUpPos]["slot" + l];
l++;
}
if (newPos < 7) {
playSound("drop");
}
newSlot = to.slot;
newPos = to.pos;
jc = 0;
while (jc < draggingArray.length) {
to = draggingArray[jc];
tc = to.clip;
cardPosition["pos" + newPos]["slot" + (lastSlot + jc)] = new Object();
cardPosition["pos" + newPos]["slot" + (lastSlot + jc)] = to;
to.pos = newPos;
to.slot = lastSlot + jc;
jc++;
}
if (pickUpPos < 7) {
revealCard = cardPosition["pos" + pickUpPos]["slot" + (pickUpSlot - 1)];
if ((revealCard.revealed == false) || (revealCard.revealed == undefined)) {
tempCard = revealCard.clip;
if (tempCard != undefined) {
playSound("card flip");
revealCard.revealed = true;
tempCard.cardBacking.xScaleTo(0, 0.5, "", 0, function () {
this._visible = false;
});
tempCard.card._xscale = 0;
tempCard.card.xScaleTo(100, 1);
}
}
}
} else {
playSound("wrong");
}
newSlot = to.slot;
newPos = to.pos;
if (newPos < 15) {
dropPosRef = "position";
returnSlotOffset = cardSlotOffset;
} else {
dropPosRef = "foundation";
returnSlotOffset = 0;
}
trace(" ");
jc = 0;
while (jc < draggingArray.length) {
to = draggingArray[jc];
tc = to.clip;
deck = eval (dropPosRef + newPos);
if (newPos < 7) {
returnToXPos = deck._x;
returnToYPos = deck._y + (returnSlot * returnSlotOffset);
}
if (newPos == 7) {
returnToXPos = to.pickUpX;
returnToYPos = deck._y;
}
if (newPos > 7) {
returnToXPos = deck._x;
returnToYPos = deck._y;
}
theDepth = cardHolder.getNextHighestDepth();
tc.swapDepths(theDepth);
tc.slideTo(returnToXPos, returnToYPos, 0.75, "", 0.05 * jc);
returnSlot++;
jc++;
}
gameState = "playing";
testGameWon();
}
function startCardDrag(tempObj) {
cardRevealed = tempObj.revealed;
pickUpPos = tempObj.pos;
pickUpSlot = tempObj.slot;
if (cardRevealed == true) {
if (pickUpPos == 7) {
pickUpSlot = tempObj.slot;
tempObj.pickUpX = tempObj.clip._x;
amountInKitty = 0;
for (var _local2 in cardPosition.pos7) {
amountInKitty++;
}
if (pickUpSlot == (amountInKitty - 1)) {
tempObj.clip.swapDepths(cardHolder.getNextHighestDepth());
tempObj.clip.stopTween();
tempObj.clip.startDrag();
draggingArray = new Array();
draggingArray.push(tempObj);
playSound("pick up");
gameState = "dragging";
}
}
if (pickUpPos > 7) {
pickUpSlot = tempObj.slot;
tempObj.clip.swapDepths(cardHolder.getNextHighestDepth());
tempObj.clip.stopTween();
tempObj.clip.startDrag();
draggingArray = new Array();
draggingArray.push(tempObj);
currentSlotNum = pickUpSlot;
currentSlotNum++;
i = currentSlotNum;
while (i < 30) {
k = 0;
while (k < 52) {
t = cardObjects["card" + k];
if ((t.pos == pickUpPos) && (t.slot == currentSlotNum)) {
draggingArray.push(t);
t.clip.swapDepths(cardHolder.getNextHighestDepth());
currentSlotNum++;
}
k++;
}
i++;
}
playSound("pick up");
gameState = "dragging";
}
if (pickUpPos < 7) {
pickUpSlot = tempObj.slot;
tempObj.clip.swapDepths(cardHolder.getNextHighestDepth());
tempObj.clip.stopTween();
tempObj.clip.startDrag();
draggingArray = new Array();
draggingArray.push(tempObj);
currentSlotNum = pickUpSlot;
currentSlotNum++;
i = currentSlotNum;
while (i < 50) {
k = 0;
while (k < 52) {
t = cardObjects["card" + k];
if (((t.pos == pickUpPos) && (t.slot == currentSlotNum)) && (i != tempObj.cardNum)) {
draggingArray.push(t);
t.clip.swapDepths(cardHolder.getNextHighestDepth());
currentSlotNum++;
}
k++;
}
i++;
}
playSound("pick up");
gameState = "dragging";
}
}
}
function postionCards() {
currentDepth = 10;
l = 0;
while (l < 7) {
yOffset = 0;
var tally = 0;
for (var v in cardPosition["pos" + l]) {
tally++;
}
j = 0;
while (j < tally) {
tObj = cardPosition["pos" + l]["slot" + j];
tClip = tObj.clip;
tClip._x = deckLocation._x;
tClip._y = deckLocation._y;
tClip.slideTo(eval ("position" + l)._x, eval ("position" + l)._y + yOffset, 1, "", j / 20);
tObj.pos = l;
tObj.slot = j;
tClip.swapDepths(currentDepth);
if (tObj.revealed == true) {
tClip.cardBacking._visible = false;
}
currentDepth++;
yOffset = yOffset + cardSlotOffset;
j++;
}
l++;
}
tally = 0;
for (var v in cardPosition.deck) {
tally++;
}
deckxOffset = 0;
deckyOffset = 0;
l = 0;
while (l < tally) {
tObj = cardPosition.deck["slot" + l];
tClip = tObj.clip;
tClip._x = deckLocation._x;
tClip._y = deckLocation._y + deckyOffset;
tClip.swapDepths(currentDepth);
tObj.slot = l;
deckxOffset = deckxOffset + 0.5;
deckyOffset = deckyOffset + 0.25;
currentDepth++;
l++;
}
}
function setUpCardInteractions(tempClip) {
tempClip.onPress = function () {
startCardDrag(this.object);
};
}
function updateTextBoxes() {
solvedTextBox.text = totalCardCount;
redealsTextBox.text = yourRedeals;
winsTextBox.text = score;
}
function redeal() {
yourRedeals++;
storage.data.redeals = yourRedeals;
updateTextBoxes();
movieLoc.gameState = "prepare for setup";
}
function setup() {
totalCardCount = 0;
movieLoc = this;
confirmToggle.onRollOver = function () {
playSound("mouseOver");
};
updateTextBoxes();
confirmToggle.onRelease = function () {
playSound("mouseDown");
if (movieLoc.confirmRedeal) {
movieLoc.confirmRedeal = false;
confirmRedealCheckBox.gotoAndStop(2);
} else {
movieLoc.confirmRedeal = true;
confirmRedealCheckBox.gotoAndStop(1);
}
movieLoc.storage.data.confirmRedeal = confirmRedeal;
};
cardSlotOffset = 22;
var _local5 = "cardsBitmap";
var _local4 = flash.display.BitmapData.loadBitmap(_local5);
cardObjects = new Object();
suitArray = new Array({suit:"clubs", colour:"black"}, {suit:"diamonds", colour:"red"}, {suit:"hearts", colour:"red"}, {suit:"spades", colour:"black"});
positionArray = new Array(0, 1, 2, 3, 4, 5, 6, 7, 10);
currentSetPostion = 0;
totalCardsPositioned = -1;
thePos = positionArray[currentSetPostion];
i = 0;
while (i < 52) {
t = (cardObjects["card" + i] = new Object());
clip = (t.clip = cardHolder.attachMovie("card", "c" + i, i));
clip.object = t;
suitPos = Math.floor(i / 13);
t.value = i - (suitPos * 13);
var _local3 = clip.createEmptyMovieClip("card", clip.getNextHighestDepth());
var _local2 = new flash.display.BitmapData(73, 98, true, 13421772);
xloc = (i - (suitPos * 13)) * 73;
yloc = suitPos * 98;
_local2.copyPixels(_local4, new flash.geom.Rectangle(xloc, yloc, xloc + 73, yloc + 98), new flash.geom.Point(0, 0));
_local3.attachBitmap(_local2, this.getNextHighestDepth(), "always", true);
t.suit = suitArray[suitPos].suit;
t.colour = suitArray[suitPos].colour;
clip.cardBacking = clip.attachMovie("backOfCardClip", "cardBacking", 2);
clip.cardUnderlay._visible = false;
setUpCardInteractions(t.clip);
t.cardNum = i;
i++;
}
cardPosition = new Object();
cardArray = new Array();
i = 0;
while (i < 52) {
cardArray[i] = cardObjects["card" + i];
i++;
}
cardArray.randomize();
cardPosition.pos7 = new Object();
num = 0;
cardAmounts = new Array(1, 2, 3, 4, 5, 6, 7);
l = 0;
while (l < 7) {
cardPosition["pos" + l] = new Object();
amountToAdd = cardAmounts[l];
m = 0;
while (m < amountToAdd) {
card = cardArray[num];
cardPosition["pos" + l]["slot" + m] = card;
num++;
m++;
}
card.revealed = true;
l++;
}
cardPosition.deck = new Object();
deckNum = 0;
l = num;
while (l < 52) {
card = cardArray[num];
cardPosition.deck["slot" + deckNum] = card;
card.revealed = false;
deckNum++;
num++;
l++;
}
cardPosition.pos15 = new Object();
cardPosition.pos16 = new Object();
cardPosition.pos17 = new Object();
cardPosition.pos18 = new Object();
postionCards();
}
gameState = "prepare for setup";
stop();
kittyTriggerBtn.onRelease = function () {
generateKitty();
};
redealBtn.onRelease = function () {
playSound("mouseDown");
if (!confirmRedeal) {
redeal();
} else {
gameState = "confirm redeal";
}
};
redealBtn.onRollOver = function () {
this.scaleTo(110, 1);
playSound("mouseOver");
};
redealBtn.onRollOut = function () {
this.scaleTo(100, 1);
};
onMouseUp = function () {
if (gameState == "dragging") {
stopCardDrag();
}
};
if (confirmRedeal) {
confirmRedealCheckBox.gotoAndStop(1);
} else {
confirmRedealCheckBox.gotoAndStop(2);
}
Array.prototype.randomize = function () {
var _local2 = this.length;
if (_local2 == 0) {
return(undefined);
}
while (_local2-- , _local2) {
var _local3 = Math.floor(Math.random() * (_local2 + 1));
var _local5 = this[_local2];
var _local4 = this[_local3];
this[_local2] = _local4;
this[_local3] = _local5;
}
return(this);
};
totalCardCount = 0;
updateTextBoxes();
trace("score:" + score);
Frame 24
function snowClass() {
}
function launchFireWorks(cx, cy, fxtype) {
sndR = random(3) + 1;
if (sndR == 1) {
fireWorkSnd1.start();
}
if (sndR == 2) {
fireWorkSnd2.start();
}
if (sndR == 3) {
fireWorkSnd3.start();
}
fxAm = random(20) + 20;
rotDiv = 360 / fxAm;
fxNum = this.effectsHolder.getNextHighestDepth();
this.effectsHolder.createEmptyMovieClip("fxholder" + fxNum, fxNum);
i = 0;
while (i < fxAm) {
t = eval ("effectsHolder.fxholder" + fxNum).attachMovie("fireWorksParticle", "fx" + i, i + (100 * fxNum));
t._x = cx;
t._y = cy;
t.gotoAndStop(fxtype);
t.rot = i * rotDiv;
t.fxtype = fxtype;
i++;
}
}
function fountain() {
if ((Math.random() * 10) < 4) {
i = 0;
while (i < particleAmount) {
t = effectsHolder.attachMovie("fountainParticle", "fx" + fxNum, fxNum);
t.gotoAndStop(Math.floor(Math.random() * 4) + 1);
t._x = centerXLoc;
t._y = centerYLoc;
t.rot = (-180 + (Math.random() * 90)) - 45;
t._xscale = (t._yscale = (Math.random() * 80) + 20);
t.fxtype = 1;
t.speed = fountainSpeed;
fxNum++;
if (fxNum > 1000) {
fxNum = 0;
}
i++;
}
}
}
_quality = "high";
scoreTextBox.text = score;
storage.data.score = score;
this.playBtn.onRelease = function () {
playSound("mouseDown");
removeMovieClip(highHolder);
gotoAndPlay (23);
};
this.playBtn.onRollOver = function () {
playSound("mouseOver");
this.scaleTo(140, 0.5);
};
this.playBtn.onRollOut = function () {
this.scaleTo(130, 0.5);
};
scoreTextBox.text = String(score);
if (score > 0) {
setupHighscoreSubmission();
} else {
submitScoreBtnClip._visible = false;
}
viewHighscoreBtn.onRelease = function () {
showHighscores();
};
storage.flush();
effectsType = Math.floor(Math.random() * 3);
switch (effectsType) {
case 0 :
c = 0;
d = 3 + random(5);
snowNum = 1;
i = 0;
while (i < 25) {
t = effectsHolder.attachMovie("snow", "s" + snowNum, snowNum);
t.gotoAndStop(Math.floor(Math.random() * 4) + 1);
snowNum++;
i++;
}
effectsHolder.onEnterFrame = function () {
c++;
if (c > d) {
c = 0;
d = 10 + random(5);
t = effectsHolder.attachMovie("snow", "s" + snowNum, snowNum);
t.gotoAndStop(Math.floor(Math.random() * 4) + 1);
snowNum++;
}
};
break;
case 1 :
effectsHolder.c = 10;
effectsHolder.onEnterFrame = function () {
this.c--;
if (this.c < 1) {
this.c = random(30) + 10;
launchFireWorks(random(600) + 20, random(400) + 40, random(4) + 1);
}
};
break;
case 2 :
centerXLoc = 320;
centerYLoc = 480;
particleAmount = 2;
fxNum = 0;
fountainSpeed = 22;
effectsHolder.onEnterFrame = function () {
fountain();
};
}
congratsTextBox.text = "WELL DONE! YOU HAVE SOLVED THE DECK!";
if (score == 20) {
congratsTextBox.text = "NICE! YOU'VE BEATEN 20 GAMES!";
}
if (score == 50) {
congratsTextBox.text = "EXCELLENT! 50 GAMES WON!";
}
if (score == 100) {
congratsTextBox.text = "WELL DONE! YOU'VE BEATEN 100 GAMES!";
}
if (score == 150) {
congratsTextBox.text = "WELL DONE! YOU MUST LOVE SOLITAIRE!";
}
if (score == 200) {
congratsTextBox.text = "CONGRATULATIONS! YOU'VE IMPRESSED TERRY!";
}
if (score == 300) {
congratsTextBox.text = "AMAZING! 300 GAMES WON!";
}
if (score == 400) {
congratsTextBox.text = "AWESOME! 400 GAMES!";
}
if (score == 500) {
congratsTextBox.text = "TERRY THANKS YOU FOR PLAYING!";
}
if (score == 600) {
congratsTextBox.text = "INCREDIBLE PLAYING!";
}
if (score == 700) {
congratsTextBox.text = "YOUR VERY PERSISTANT!";
}
if (score == 800) {
congratsTextBox.text = "FANTASTIC!";
}
if (score == 900) {
congratsTextBox.text = "TERRY THANKS YOU FOR PLAYING!";
}
if (score == 1000) {
congratsTextBox.text = "YOU ARE TRULY A LEGEND!";
}
if (score == 1200) {
congratsTextBox.text = "YOU ENJOY PLAYING THIS GAME DON'T YOU?";
}
if (score == 1500) {
congratsTextBox.text = "YOUR DEDICATED!";
}
if (score > 2000) {
congratsTextBox.text = "YOUR A LEGEND!";
}
if (score == 3000) {
congratsTextBox.text = "WOW 3000 GAMES WON!";
}
if (score > 3000) {
congratsTextBox.text = "YOUR A LEGEND!";
}
if (score > 4000) {
congratsTextBox.text = "YOU REALLY LOVE SOLITAIRE DON'T YOU?";
}
if (score > 5000) {
congratsTextBox.text = "ACE! YOU SOLVED IT!";
}
if (score > 6000) {
congratsTextBox.text = "BRILLIANT DEDICATION!";
}
if (score > 7000) {
congratsTextBox.text = "YOUR A MASTER PLAYER";
}
snowClass.prototype = new MovieClip();
snowClass.prototype.onLoad = function () {
this.i = 1 + (Math.random() * 2);
this.k = -3.14159265358979 + (Math.random() * Math.PI);
this._x = 10 + random(630);
this._y = -5;
this.rad = 0;
this._rotation = random(360);
};
snowClass.prototype.onEnterFrame = function () {
this.rad = this.rad + ((this.k / 180) * 3.1415);
this._x = this._x - Math.cos(this.rad);
this._y = this._y + this.i;
if (((this._x > 655) || (this._x < -15)) || (this._y > 500)) {
removeMovieClip(this);
}
};
Object.registerClass("snow", snowClass);
Frame 32
stop();
Symbol 129 MovieClip [__Packages.mochi.MochiServices] Frame 0
class mochi.MochiServices
{
static var _id, _container, _clip, _sendChannelName, _rcvChannelName, __get__comChannelName, onError, _listenChannel, _rcvChannel, _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.31");
}
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";
_rcvChannelName = val;
initComChannels();
}
}
//return(__get__comChannelName());
}
static function get connected() {
return(_connected);
}
static function connect(id, clip, onError) {
if ((!_connected) && (_clip == undefined)) {
trace("MochiServices Connecting...");
_connecting = true;
init(id, clip);
}
if (onError != undefined) {
mochi.MochiServices.onError = onError;
} else if (mochi.MochiServices.onError == undefined) {
mochi.MochiServices.onError = function (errorCode) {
trace(errorCode);
};
}
}
static function disconnect() {
if (_connected || (_connecting)) {
_connecting = (_connected = false);
flush(true);
if (_clip != undefined) {
_clip.removeMovieClip();
delete _clip;
}
_listenChannel.close();
_rcvChannel.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 _local2 = "_mochiservices_com_" + id;
if (_clip != null) {
return(_clip);
}
if (!isNetworkAvailable) {
return(null);
}
allowDomains(_gatewayURL);
_clip = clip.createEmptyMovieClip(_local2, 10336, false);
_loader = new MovieClipLoader();
if (_loaderListener.waitInterval != null) {
clearInterval(_loaderListener.waitInterval);
}
_loaderListener = {};
_loaderListener.onLoadError = function (target_mc, errorCode, httpStatus) {
trace("MochiServices could not load.");
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(_gatewayURL, _clip);
_sendChannel = new LocalConnection();
_sendChannel._queue = [];
_rcvChannel = new LocalConnection();
_rcvChannel.allowDomain = function (d) {
return(true);
};
_rcvChannel.allowInsecureDomain = _rcvChannel.allowDomain;
_rcvChannel._nextcallbackID = 0;
_rcvChannel._callbacks = {};
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.connect(_listenChannelName);
trace("Waiting for MochiAds services to connect...");
}
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()});
_rcvChannel.onStatus = function (infoObject) {
mochi.MochiServices.onStatus(infoObject);
};
_rcvChannel.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];
};
_rcvChannel.onError = function () {
mochi.MochiServices.onError.apply(null, ["IOError"]);
};
_rcvChannel.connect(_rcvChannelName);
trace("connected!");
_connecting = false;
_connected = true;
_listenChannel.close();
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 = _rcvChannel._callbacks[_local1.callbackID];
}
delete _rcvChannel._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 (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:_rcvChannel._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:_rcvChannel._nextcallbackID});
}
_rcvChannel._callbacks[_rcvChannel._nextcallbackID] = {callbackObject:callbackObject, callbackMethod:callbackMethod};
_rcvChannel._nextcallbackID++;
}
static var _gatewayURL = "http://www.mochiads.com/static/lib/services/services.swf";
static var _listenChannelName = "__mochiservices";
static var _connecting = false;
static var _connected = false;
}
Symbol 130 MovieClip [__Packages.MochiAd] Frame 0
class MochiAd
{
function MochiAd () {
}
static function getVersion() {
return("2.3");
}
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();
}, ad_failed:function () {
trace("[MochAd] Couldn't load an ad, make sure that your game's local security sandbox is configured for Access Network Only and that you are not using ad blocking software");
}, ad_loaded:function (width, height) {
}};
options = _parseOptions(options, _local27);
if ("5cc6f7dfb67f2f08341c831480f7c2a7".length == 0) {
options.ad_started();
options.ad_finished();
return(undefined);
}
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_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 _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 = options.ad_loaded;
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) {
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 showInterLevelAd(options) {
var _local13 = {clip:_root, ad_timeout:2000, fadeout_time:250, regpt:"o", method:"showTimedAd", ad_started:function () {
this.clip.stop();
}, ad_finished:function () {
this.clip.play();
}, ad_failed:function () {
trace("[MochAd] Couldn't load an ad, make sure that your game's local security sandbox is configured for Access Network Only and that you are not using ad blocking software");
}, ad_loaded:function (width, height) {
}};
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.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) {
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 showTimedAd(options) {
trace("[MochiAd] DEPRECATED: showTimedAd was renamed to showInterLevelAd in 2.0");
showInterLevelAd(options);
}
static function showPreloaderAd(options) {
trace("[MochiAd] DEPRECATED: showPreloaderAd was renamed to showPreGameAd in 2.0");
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++;
}
}
if (_local4.id == "test") {
trace("[MochiAd] WARNING: Using the MochiAds test identifier, make sure to use the code from your dashboard, not this example!");
}
return(_local4);
}
}
Symbol 131 MovieClip [__Packages.fireWorksClass] Frame 0
class fireWorksClass extends MovieClip
{
var x, _x, y, _y, xCenter, yCenter, depth, fall, _rotation, fxtype, speed, _alpha, removeMovieClip, temprot, rot;
function fireWorksClass () {
super();
}
function onLoad() {
x = _x;
y = _y;
xCenter = _x;
yCenter = _y;
depth = 1;
fall = Math.random(0.2) + 0.5;
_rotation = random(360);
if (fxtype == 1) {
speed = random(5) + 4;
}
if (fxtype == 2) {
speed = random(9) + 4;
}
if (fxtype == 3) {
speed = random(5) + 4;
}
if (fxtype == 4) {
speed = random(7) + 4;
}
}
function onEnterFrame() {
depth = depth + speed;
speed = speed * 0.95;
if (speed < 3) {
yCenter = yCenter + fall;
fall = fall * 1.1;
_alpha = _alpha - 3;
if (_alpha < 10) {
removeMovieClip();
}
}
temprot = (rot / 180) * Math.PI;
x = xCenter + (depth * Math.sin(temprot));
y = yCenter + (depth * Math.cos(temprot));
_x = x;
_y = y;
if ((((x < 0) || (x > 640)) || (y < 0)) || (y > 480)) {
removeMovieClip();
}
}
}
Symbol 132 MovieClip [__Packages.letterClass] Frame 0
class letterClass extends MovieClip
{
var _ref;
function letterClass (clip, angle, ySize) {
super();
_ref = clip;
if (ySize == undefined) {
ySize = 10;
}
_ref.radiusY = ySize;
_ref.speed = 0.1;
_ref.y = (_ref.centerY = _ref._y);
_ref.angle = angle;
if (_ref.angle == undefined) {
_ref.angle = 10;
}
_ref.myShakeLoop = setInterval(moveLoop, 30, _ref);
}
function moveLoop(_clipRef) {
_clipRef.y = _clipRef.centerY + (Math.sin(_clipRef.angle) * _clipRef.radiusY);
_clipRef.angle = _clipRef.angle + _clipRef.speed;
_clipRef._y = _clipRef.y;
}
}
Symbol 133 MovieClip [__Packages.fountainClass] Frame 0
class fountainClass extends MovieClip
{
var x, _x, y, _y, xCenter, yCenter, depth, fall, _rotation, speed, _alpha, removeMovieClip, temprot, rot;
function fountainClass () {
super();
}
function onLoad() {
x = _x;
y = _y;
xCenter = _x;
yCenter = _y;
depth = 1;
fall = Math.random(0.2) + 0.5;
_rotation = random(360);
}
function onEnterFrame() {
depth = depth + speed;
speed = speed * 0.95;
if (speed < 3) {
yCenter = yCenter + fall;
fall = fall * 1.1;
_alpha = _alpha - 3;
if (_alpha < 10) {
removeMovieClip();
}
}
temprot = (rot / 180) * Math.PI;
x = xCenter + (depth * Math.sin(temprot));
y = yCenter + (depth * Math.cos(temprot));
_x = x;
_y = y;
}
}
Symbol 134 MovieClip [__Packages.mx.transitions.OnEnterFrameBeacon] Frame 0
class mx.transitions.OnEnterFrameBeacon
{
function OnEnterFrameBeacon () {
}
static function init() {
var _local4 = _global.MovieClip;
if (!_root.__OnEnterFrameBeacon) {
mx.transitions.BroadcasterMX.initialize(_local4);
var _local3 = _root.createEmptyMovieClip("__OnEnterFrameBeacon", 9876);
_local3.onEnterFrame = function () {
_global.MovieClip.broadcastMessage("onEnterFrame");
};
}
}
static var version = "1.1.0.52";
}
Symbol 135 MovieClip [__Packages.mx.transitions.BroadcasterMX] Frame 0
class mx.transitions.BroadcasterMX
{
var _listeners;
function BroadcasterMX () {
}
static function initialize(o, dontCreateArray) {
if (o.broadcastMessage != undefined) {
delete o.broadcastMessage;
}
o.addListener = mx.transitions.BroadcasterMX.prototype.addListener;
o.removeListener = mx.transitions.BroadcasterMX.prototype.removeListener;
if (!dontCreateArray) {
o._listeners = new Array();
}
}
function addListener(o) {
removeListener(o);
if (broadcastMessage == undefined) {
broadcastMessage = mx.transitions.BroadcasterMX.prototype.broadcastMessage;
}
return(_listeners.push(o));
}
function removeListener(o) {
var _local2 = _listeners;
var _local3 = _local2.length;
while (_local3--) {
if (_local2[_local3] == o) {
_local2.splice(_local3, 1);
if (!_local2.length) {
broadcastMessage = undefined;
}
return(true);
}
}
return(false);
}
function broadcastMessage() {
var _local5 = String(arguments.shift());
var _local4 = _listeners.concat();
var _local6 = _local4.length;
var _local3 = 0;
while (_local3 < _local6) {
_local4[_local3][_local5].apply(_local4[_local3], arguments);
_local3++;
}
}
static var version = "1.1.0.52";
}
Symbol 136 MovieClip [__Packages.mx.transitions.Tween] Frame 0
class mx.transitions.Tween
{
var obj, prop, begin, useSeconds, _listeners, addListener, prevTime, _time, looping, _duration, broadcastMessage, isPlaying, _fps, prevPos, _pos, change, _intervalID, _startTime;
function Tween (obj, prop, func, begin, finish, duration, useSeconds) {
mx.transitions.OnEnterFrameBeacon.init();
if (!arguments.length) {
return;
}
this.obj = obj;
this.prop = prop;
this.begin = begin;
position = (begin);
this.duration = (duration);
this.useSeconds = useSeconds;
if (func) {
this.func = func;
}
this.finish = (finish);
_listeners = [];
addListener(this);
start();
}
function set time(t) {
prevTime = _time;
if (t > duration) {
if (looping) {
rewind(t - _duration);
update();
broadcastMessage("onMotionLooped", this);
} else {
if (useSeconds) {
_time = _duration;
update();
}
stop();
broadcastMessage("onMotionFinished", this);
}
} else if (t < 0) {
rewind();
update();
} else {
_time = t;
update();
}
//return(time);
}
function get time() {
return(_time);
}
function set duration(d) {
_duration = (((d == null) || (d <= 0)) ? (_global.Infinity) : (d));
//return(duration);
}
function get duration() {
return(_duration);
}
function set FPS(fps) {
var _local2 = isPlaying;
stopEnterFrame();
_fps = fps;
if (_local2) {
startEnterFrame();
}
//return(FPS);
}
function get FPS() {
return(_fps);
}
function set position(p) {
setPosition(p);
//return(position);
}
function setPosition(p) {
prevPos = _pos;
obj[prop] = (_pos = p);
broadcastMessage("onMotionChanged", this, _pos);
updateAfterEvent();
}
function get position() {
return(getPosition());
}
function getPosition(t) {
if (t == undefined) {
t = _time;
}
return(func(t, begin, change, _duration));
}
function set finish(f) {
change = f - begin;
//return(finish);
}
function get finish() {
return(begin + change);
}
function continueTo(finish, duration) {
begin = position;
this.finish = (finish);
if (duration != undefined) {
this.duration = (duration);
}
start();
}
function yoyo() {
continueTo(begin, time);
}
function startEnterFrame() {
if (_fps == undefined) {
_global.MovieClip.addListener(this);
} else {
_intervalID = setInterval(this, "onEnterFrame", 1000 / _fps);
}
isPlaying = true;
}
function stopEnterFrame() {
if (_fps == undefined) {
_global.MovieClip.removeListener(this);
} else {
clearInterval(_intervalID);
}
isPlaying = false;
}
function start() {
rewind();
startEnterFrame();
broadcastMessage("onMotionStarted", this);
}
function stop() {
stopEnterFrame();
broadcastMessage("onMotionStopped", this);
}
function resume() {
fixTime();
startEnterFrame();
broadcastMessage("onMotionResumed", this);
}
function rewind(t) {
_time = ((t == undefined) ? 0 : (t));
fixTime();
update();
}
function fforward() {
time = (_duration);
fixTime();
}
function nextFrame() {
if (useSeconds) {
time = ((getTimer() - _startTime) / 1000);
} else {
time = (_time + 1);
}
}
function onEnterFrame() {
nextFrame();
}
function prevFrame() {
if (!useSeconds) {
time = (_time - 1);
}
}
function toString() {
return("[Tween]");
}
function fixTime() {
if (useSeconds) {
_startTime = getTimer() - (_time * 1000);
}
}
function update() {
position = (getPosition(_time));
}
static var version = "1.1.0.52";
static var __initBeacon = mx.transitions.OnEnterFrameBeacon.init();
static var __initBroadcaster = mx.transitions.BroadcasterMX.initialize(mx.transitions.Tween.prototype, true);
function func(t, b, c, d) {
return(((c * t) / d) + b);
}
}
Symbol 137 MovieClip [__Packages.mx.transitions.easing.Strong] Frame 0
class mx.transitions.easing.Strong
{
function Strong () {
}
static function easeIn(t, b, c, d) {
t = t / d;
return((((((c * t) * t) * t) * t) * t) + b);
}
static function easeOut(t, b, c, d) {
t = (t / d) - 1;
return((c * (((((t * t) * t) * t) * t) + 1)) + b);
}
static function easeInOut(t, b, c, d) {
t = t / (d / 2);
if (t < 1) {
return(((((((c / 2) * t) * t) * t) * t) * t) + b);
}
t = t - 2;
return(((c / 2) * (((((t * t) * t) * t) * t) + 2)) + b);
}
static var version = "1.1.0.52";
}
Symbol 138 MovieClip [__Packages.mx.transitions.easing.Bounce] Frame 0
class mx.transitions.easing.Bounce
{
function Bounce () {
}
static function easeOut(t, b, c, d) {
t = t / d;
if (t < 0.363636363636364) {
return((c * ((7.5625 * t) * t)) + b);
}
if (t < 0.727272727272727) {
t = t - 0.545454545454545;
return((c * (((7.5625 * t) * t) + 0.75)) + b);
}
if (t < 0.909090909090909) {
t = t - 0.818181818181818;
return((c * (((7.5625 * t) * t) + 0.9375)) + b);
}
t = t - 0.954545454545455;
return((c * (((7.5625 * t) * t) + 0.984375)) + b);
}
static function easeIn(t, b, c, d) {
return((c - easeOut(d - t, 0, c, d)) + b);
}
static function easeInOut(t, b, c, d) {
if (t < (d / 2)) {
return((easeIn(t * 2, 0, c, d) * 0.5) + b);
}
return(((easeOut((t * 2) - d, 0, c, d) * 0.5) + (c * 0.5)) + b);
}
static var version = "1.1.0.52";
}
Symbol 139 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) {
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 (typeof(options.score) == "object") {
if (options.score.text != undefined) {
options.score = options.score.text;
}
}
}
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) {
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 140 MovieClip [__Packages.gs.TweenLite] Frame 0
class gs.TweenLite
{
static var _e, _classInitted, _curTime, _gc, _listening;
var tweenID, endTargetID, vars, duration, delay, target, tweens, _subTweens, _hst, _initted, _active, initTime, startTime;
function TweenLite ($target, $duration, $vars) {
_cnt++;
tweenID = "tw" + _cnt;
endTargetID = getID($target, true);
if (($vars.overwrite != false) && ($target != undefined)) {
delete _all[endTargetID];
_all[endTargetID] = {info:[$target, endTargetID]};
}
_all[endTargetID][tweenID] = this;
vars = $vars;
duration = $duration || 0.001;
delay = $vars.delay || 0;
target = $target;
if (typeof(vars.ease) != "function") {
vars.ease = defaultEase;
}
if (vars.easeParams != undefined) {
vars.proxiedEase = vars.ease;
vars.ease = easeProxy;
}
if (typeof(vars.autoAlpha) == "number") {
vars._alpha = vars.autoAlpha;
}
tweens = [];
_subTweens = [];
_hst = (_initted = false);
_active = ($duration == 0) && (delay == 0);
if ((_e._visible != false) || (!_classInitted)) {
_curTime = getTimer();
_e = _root.createEmptyMovieClip("_tweenLite_mc", _root.getNextHighestDepth() || 9999);
_e.swapDepths(-1);
_e._visible = false;
clearInterval(_gc);
_gc = setInterval(killGarbage, 2000);
_e.onEnterFrame = executeAll;
_classInitted = true;
}
initTime = _curTime;
if (_active || ((vars.runBackwards == true) && (vars.renderOnStart != true))) {
initTweenVals();
startTime = _curTime;
if (_active) {
render(startTime + 1);
} else {
render(startTime);
}
}
if ((!_active) && (!_listening)) {
_listening = true;
}
}
function initTweenVals($hrp, $reservedProps) {
var _local6 = typeof(target) == "movieclip";
var _local8;
var _local2;
if (target instanceof Array) {
var _local9 = vars.endArray || ([]);
_local2 = 0;
while (_local2 < _local9.length) {
if ((target[_local2] != _local9[_local2]) && (target[_local2] != undefined)) {
tweens.push({o:target, p:_local2.toString(), s:target[_local2], c:_local9[_local2] - target[_local2]});
}
_local2++;
}
} else {
for (_local8 in vars) {
if ((((((((((((((((((_local8 == "ease") || (_local8 == "delay")) || (_local8 == "overwrite")) || (_local8 == "onComplete")) || (_local8 == "onCompleteParams")) || (_local8 == "onCompleteScope")) || (_local8 == "runBackwards")) || (_local8 == "onUpdate")) || (_local8 == "onUpdateParams")) || (_local8 == "onUpdateScope")) || (_local8 == "autoAlpha")) || (_local8 == "onStart")) || (_local8 == "onStartParams")) || (_local8 == "onStartScope")) || (_local8 == "renderOnStart")) || (_local8 == "proxiedEase")) || (_local8 == "easeParams")) || ($hrp && ($reservedProps.indexOf((" " + _local8) + " ") != -1))) {
} else if ((_local8 == "tint") && (_local6 || (target instanceof TextField))) {
var _local4 = new Color(target);
var _local3 = vars._alpha;
if (_local3 != undefined) {
delete vars._alpha;
_local2 = tweens.length - 1;
while (_local2 > -1) {
if (tweens[_local2].p == "_alpha") {
tweens.splice(_local2, 1);
break;
}
_local2--;
}
} else {
_local3 = target._alpha;
}
if ((vars[_local8] == null) || (vars[_local8] == "")) {
addSubTween(tintProxy, _local4.getTransform(), {rb:0, gb:0, bb:0, ab:0, ra:_local3, ga:_local3, ba:_local3, aa:_local3}, {color:_local4});
} else {
addSubTween(tintProxy, _local4.getTransform(), {rb:vars[_local8] >> 16, gb:(vars[_local8] >> 8) & 255, bb:vars[_local8] & 255, ra:0, ga:0, ba:0, aa:_local3}, {color:_local4});
}
} else if ((_local8 == "frame") && (_local6)) {
addSubTween(frameProxy, {frame:target._currentframe}, {frame:vars[_local8]}, {mc:target});
} else if ((_local8 == "volume") && (_local6 || (target instanceof Sound))) {
var _local5;
if (_local6) {
_local5 = new Sound(target);
} else {
_local5 = Sound(target);
}
addSubTween(volumeProxy, {volume:_local5.getVolume()}, {volume:vars[_local8]}, {sound:_local5});
} else if (target[_local8] != undefined) {
if (typeof(vars[_local8]) == "number") {
tweens.push({o:target, p:_local8, s:target[_local8], c:vars[_local8] - target[_local8]});
} else {
tweens.push({o:target, p:_local8, s:target[_local8], c:Number(vars[_local8])});
}
}
}
}
if (vars.runBackwards == true) {
var _local7;
_local2 = tweens.length - 1;
while (_local2 > -1) {
_local7 = tweens[_local2];
_local7.s = _local7.s + _local7.c;
_local7.c = _local7.c * -1;
_local2--;
}
}
if (typeof(vars.autoAlpha) == "number") {
target._visible = !((vars.runBackwards == true) && (target._alpha == 0));
}
_initted = true;
}
function addSubTween($proxy, $target, $props, $info) {
var _local5 = {proxy:$proxy, target:$target, info:$info};
_subTweens.push(_local5);
for (var _local8 in $props) {
if ($target[_local8] != undefined) {
if (typeof($props[_local8]) == "number") {
tweens.push({o:$target, p:_local8, s:$target[_local8], c:$props[_local8] - $target[_local8], sub:_local5});
} else {
tweens.push({o:$target, p:_local8, s:$target[_local8], c:Number($props[_local8]), sub:_local5});
}
}
}
_hst = true;
}
static function to($target, $duration, $vars) {
return(new gs.TweenLite($target, $duration, $vars));
}
static function from($target, $duration, $vars) {
$vars.runBackwards = true;
return(new gs.TweenLite($target, $duration, $vars));
}
static function delayedCall($delay, $onComplete, $onCompleteParams, $onCompleteScope) {
return(new gs.TweenLite($onComplete, 0, {delay:$delay, onComplete:$onComplete, onCompleteParams:$onCompleteParams, onCompleteScope:$onCompleteScope, overwrite:false}));
}
function render($t) {
var _local5 = ($t - startTime) / 1000;
if (_local5 > duration) {
_local5 = duration;
}
var _local3;
var _local2;
var _local4 = vars.ease(_local5, 0, 1, duration);
_local2 = tweens.length - 1;
while (_local2 > -1) {
_local3 = tweens[_local2];
_local3.o[_local3.p] = _local3.s + (_local4 * _local3.c);
_local2--;
}
if (_hst) {
_local2 = _subTweens.length - 1;
while (_local2 > -1) {
_subTweens[_local2].proxy(_subTweens[_local2]);
_local2--;
}
}
if (vars.onUpdate != undefined) {
vars.onUpdate.apply(vars.onUpdateScope, vars.onUpdateParams);
}
if (_local5 == duration) {
complete(true);
}
}
static function executeAll() {
var _local5 = (_curTime = getTimer());
if (_listening) {
var _local2 = _all;
var _local1;
var _local4;
var _local3;
for (_local3 in _local2) {
for (_local4 in _local2[_local3]) {
_local1 = _local2[_local3][_local4];
if (_local1.active) {
_local1.render(_local5);
}
}
}
}
}
static function removeTween($t) {
_all[$t.endTargetID][$t.tweenID] = {active:false};
delete _all[$t.endTargetID][$t.tweenID];
}
static function killTweensOf($tg, $complete) {
var _local3 = getID($tg, true);
if ($complete) {
var _local1 = _all[_local3];
for (var _local2 in _local1) {
_local1[_local2].complete(false);
}
}
delete _all[_local3];
}
function complete($skipRender) {
if ($skipRender != true) {
if (!_initted) {
initTweenVals();
}
startTime = _curTime - (duration * 1000);
render(_curTime);
return(undefined);
}
if ((typeof(vars.autoAlpha) == "number") && (target._alpha == 0)) {
target._visible = false;
}
if (vars.onComplete) {
vars.onComplete.apply(vars.onCompleteScope, vars.onCompleteParams);
}
removeTween(this);
}
static function getID($tg, $lookup) {
var _local3;
if ($lookup) {
var _local1 = _all;
if (typeof($tg) == "movieclip") {
if (_local1[String($tg)] != undefined) {
return(String($tg));
}
_local3 = String($tg);
_all[_local3] = {info:[$tg, _local3]};
return(_local3);
}
for (var _local4 in _local1) {
if (_local1[_local4].info[0] == $tg) {
return(_local4);
}
}
}
_cnt++;
_local3 = "t" + _cnt;
_all[_local3] = {info:[$tg, _local3]};
return(_local3);
}
static function killGarbage() {
if (_listening) {
var _local1 = _all;
var _local2;
var _local3;
var _local5;
var _local6 = 0;
var _local4 = 0;
for (_local3 in _local1) {
_local4 = 0;
for (_local5 in _local1[_local3]) {
_local2 = _local1[_local3][_local5];
if (_local2.tweens == undefined) {
} else {
_local4++;
}
}
if (_local4 == 0) {
delete _local1[_local3];
} else {
_local6++;
}
}
if (_local6 == 0) {
_listening = false;
}
}
}
static function defaultEase($t, $b, $c, $d) {
$t = $t / $d;
return((((-$c) * $t) * ($t - 2)) + $b);
}
function easeProxy($t, $b, $c, $d) {
var _local3 = this;
return(_local3.proxiedEase.apply(null, arguments.concat(_local3.easeParams)));
}
static function tintProxy($o) {
$o.info.color.setTransform($o.target);
}
static function frameProxy($o) {
$o.info.mc.gotoAndStop(Math.round($o.target.frame));
}
static function volumeProxy($o) {
$o.info.sound.setVolume($o.target.volume);
}
function get active() {
if (_active) {
return(true);
}
if (((_curTime - initTime) / 1000) > delay) {
_active = true;
startTime = initTime + (delay * 1000);
if (!_initted) {
initTweenVals();
} else if (typeof(vars.autoAlpha) == "number") {
target._visible = true;
}
if (duration == 0.001) {
startTime = startTime - 1;
}
if (vars.onStart != undefined) {
vars.onStart.apply(vars.onStartScope, vars.onStartParams);
}
return(true);
}
return(false);
}
static var version = 6.21;
static var killDelayedCallsTo = killTweensOf;
static var _all = new Object();
static var _cnt = -16000;
static var _hrp = false;
}
Symbol 141 MovieClip [__Packages.gs.TweenFilterLite] Frame 0
class gs.TweenFilterLite extends gs.TweenLite
{
var _clrsa, _filters, _matrix, target, vars, _cmf, _endMatrix, tweens, startTime, duration, _hst, _subTweens;
function TweenFilterLite ($target, $duration, $vars) {
super($target, $duration, $vars);
if ((gs.TweenLite.version < 6.21) || (gs.TweenLite.version == undefined)) {
trace("TweenFilterLite error: Please update your TweenLite class. TweenFilterLite requires a more recent version. Download updates at http://www.TweenLite.com.");
}
if ($vars.type != undefined) {
trace(("TweenFilterLite warning: " + $target) + " appears to be using deprecated syntax. Please update to the new syntax. See http://www.TweenFilterLite.com for details.");
}
}
static function to($target, $duration, $vars) {
return(new gs.TweenFilterLite($target, $duration, $vars));
}
static function from($target, $duration, $vars) {
$vars.runBackwards = true;
return(new gs.TweenFilterLite($target, $duration, $vars));
}
function initTweenVals($hrp, $reservedProps) {
_clrsa = [];
_filters = [];
_matrix = _idMatrix.slice();
$reservedProps = $reservedProps || "";
$reservedProps = $reservedProps + " blurFilter glowFilter colorMatrixFilter dropShadowFilter bevelFilter ";
if ((typeof(target) == "movieclip") || (target instanceof TextField)) {
var _local4;
var _local5;
if (vars.blurFilter != undefined) {
_local5 = vars.blurFilter;
addFilter("blur", _local5, flash.filters.BlurFilter, ["blurX", "blurY", "quality"], new flash.filters.BlurFilter(0, 0, _local5.quality || 2));
}
if (vars.glowFilter != undefined) {
_local5 = vars.glowFilter;
addFilter("glow", _local5, flash.filters.GlowFilter, ["alpha", "blurX", "blurY", "color", "quality", "strength", "inner", "knockout"], new flash.filters.GlowFilter(16777215, 0, 0, 0, _local5.strength || 1, _local5.quality || 2, _local5.inner, _local5.knockout));
}
if (vars.colorMatrixFilter != undefined) {
_local5 = vars.colorMatrixFilter;
var _local11 = addFilter("colorMatrix", _local5, flash.filters.ColorMatrixFilter, [], new flash.filters.ColorMatrixFilter(_matrix));
_cmf = _local11.filter;
_matrix = _cmf.matrix;
if ((_local5.matrix != undefined) && (_local5.matrix instanceof Array)) {
_endMatrix = _local5.matrix;
} else {
if (_local5.relative == true) {
_endMatrix = _matrix.slice();
} else {
_endMatrix = _idMatrix.slice();
}
_endMatrix = setBrightness(_endMatrix, _local5.brightness);
_endMatrix = setContrast(_endMatrix, _local5.contrast);
_endMatrix = setHue(_endMatrix, _local5.hue);
_endMatrix = setSaturation(_endMatrix, _local5.saturation);
_endMatrix = setThreshold(_endMatrix, _local5.threshold);
if (!isNaN(_local5.colorize)) {
_endMatrix = colorize(_endMatrix, _local5.colorize, _local5.amount);
} else if (!isNaN(_local5.color)) {
_endMatrix = colorize(_endMatrix, _local5.color, _local5.amount);
}
}
_local4 = 0;
while (_local4 < _endMatrix.length) {
if ((_matrix[_local4] != _endMatrix[_local4]) && (_matrix[_local4] != undefined)) {
tweens.push({o:_matrix, p:_local4.toString(), s:_matrix[_local4], c:_endMatrix[_local4] - _matrix[_local4]});
}
_local4++;
}
}
if (vars.dropShadowFilter != undefined) {
_local5 = vars.dropShadowFilter;
addFilter("dropShadow", _local5, flash.filters.DropShadowFilter, ["alpha", "angle", "blurX", "blurY", "color", "distance", "quality", "strength", "inner", "knockout", "hideObject"], new flash.filters.DropShadowFilter(0, 45, 0, 0, 0, 0, 1, _local5.quality || 2, _local5.inner, _local5.knockout, _local5.hideObject));
}
if (vars.bevelFilter != undefined) {
_local5 = vars.bevelFilter;
addFilter("bevel", _local5, flash.filters.BevelFilter, ["angle", "blurX", "blurY", "distance", "highlightAlpha", "highlightColor", "quality", "shadowAlpha", "shadowColor", "strength"], new flash.filters.BevelFilter(0, 0, 16777215, 0.5, 0, 0.5, 2, 2, 0, _local5.quality || 2));
}
if (vars.runBackwards == true) {
var _local3;
_local4 = 0;
while (_local4 < _clrsa.length) {
_local3 = _clrsa[_local4];
_local3.sr = _local3.sr + _local3.cr;
_local3.cr = _local3.cr * -1;
_local3.sg = _local3.sg + _local3.cg;
_local3.cg = _local3.cg * -1;
_local3.sb = _local3.sb + _local3.cb;
_local3.cb = _local3.cb * -1;
_local3.f[_local3.p] = ((_local3.sr << 16) | (_local3.sg << 8)) | _local3.sb;
_local4++;
}
}
super.initTweenVals(true, $reservedProps);
} else {
super.initTweenVals($hrp, $reservedProps);
}
}
function addFilter($name, $fv, $filterType, $props, $defaultFilter) {
var _local5 = {type:$filterType};
var _local8 = target.filters;
var _local3;
_local3 = 0;
while (_local3 < _local8.length) {
if (_local8[_local3] instanceof $filterType) {
_local5.filter = _local8[_local3];
break;
}
_local3++;
}
if (_local5.filter == undefined) {
_local5.filter = $defaultFilter;
_local8.push(_local5.filter);
target.filters = _local8;
}
var _local2;
var _local9;
var _local4;
var _local7;
_local3 = 0;
while (_local3 < $props.length) {
_local2 = $props[_local3];
if ($fv[_local2] != undefined) {
if (((_local2 == "color") || (_local2 == "highlightColor")) || (_local2 == "shadowColor")) {
_local4 = HEXtoRGB(_local5.filter[_local2]);
_local7 = HEXtoRGB($fv[_local2]);
_clrsa.push({f:_local5.filter, p:_local2, sr:_local4.rb, cr:_local7.rb - _local4.rb, sg:_local4.gb, cg:_local7.gb - _local4.gb, sb:_local4.bb, cb:_local7.bb - _local4.bb});
} else if ((((_local2 == "quality") || (_local2 == "inner")) || (_local2 == "knockout")) || (_local2 == "hideObject")) {
_local5.filter[_local2] = $fv[_local2];
} else {
if (typeof($fv[_local2]) == "number") {
_local9 = $fv[_local2] - _local5.filter[_local2];
} else {
_local9 = Number($fv[_local2]);
}
tweens.push({o:_local5.filter, p:_local2, s:_local5.filter[_local2], c:_local9});
}
}
_local3++;
}
_filters.push(_local5);
_hf = true;
return(_local5);
}
function render($t) {
var _local11 = ($t - startTime) / 1000;
if (_local11 > duration) {
_local11 = duration;
}
var _local7 = vars.ease(_local11, 0, 1, duration);
var _local4;
var _local3;
var _local5;
var _local9;
var _local10;
var _local8;
_local3 = tweens.length - 1;
while (_local3 > -1) {
_local4 = tweens[_local3];
_local4.o[_local4.p] = _local4.s + (_local7 * _local4.c);
_local3--;
}
if (_hf) {
_local3 = _clrsa.length - 1;
while (_local3 > -1) {
_local4 = _clrsa[_local3];
_local9 = _local4.sr + (_local7 * _local4.cr);
_local10 = _local4.sg + (_local7 * _local4.cg);
_local8 = _local4.sb + (_local7 * _local4.cb);
_local4.f[_local4.p] = ((_local9 << 16) | (_local10 << 8)) | _local8;
_local3--;
}
if (_cmf) {
_cmf.matrix = _matrix;
}
var _local6 = target.filters;
_local3 = 0;
while (_local3 < _filters.length) {
_local5 = _local6.length - 1;
while (_local5 > -1) {
if (_local6[_local5] instanceof _filters[_local3].type) {
_local6.splice(_local5, 1, _filters[_local3].filter);
break;
}
_local5--;
}
_local3++;
}
target.filters = _local6;
}
if (_hst) {
_local3 = _subTweens.length - 1;
while (_local3 > -1) {
_subTweens[_local3].proxy(_subTweens[_local3]);
_local3--;
}
}
if (vars.onUpdate != undefined) {
vars.onUpdate.apply(vars.onUpdateScope, vars.onUpdateParams);
}
if (_local11 == duration) {
super.complete(true);
}
}
function HEXtoRGB($n) {
return({rb:$n >> 16, gb:($n >> 8) & 255, bb:$n & 255});
}
static function colorize($m, $color, $amount) {
if (($color == undefined) || (isNaN($color))) {
return($m);
}
if ($amount == undefined) {
$amount = 1;
}
var _local3 = (($color >> 16) & 255) / 255;
var _local5 = (($color >> 8) & 255) / 255;
var _local2 = ($color & 255) / 255;
var _local4 = 1 - $amount;
var _local7 = [_local4 + (($amount * _local3) * _lumR), ($amount * _local3) * _lumG, ($amount * _local3) * _lumB, 0, 0, ($amount * _local5) * _lumR, _local4 + (($amount * _local5) * _lumG), ($amount * _local5) * _lumB, 0, 0, ($amount * _local2) * _lumR, ($amount * _local2) * _lumG, _local4 + (($amount * _local2) * _lumB), 0, 0, 0, 0, 0, 1, 0];
return(applyMatrix(_local7, $m));
}
static function setThreshold($m, $n) {
if (($n == undefined) || (isNaN($n))) {
return($m);
}
var _local2 = [_lumR * 256, _lumG * 256, _lumB * 256, 0, -256 * $n, _lumR * 256, _lumG * 256, _lumB * 256, 0, -256 * $n, _lumR * 256, _lumG * 256, _lumB * 256, 0, -256 * $n, 0, 0, 0, 1, 0];
return(applyMatrix(_local2, $m));
}
static function setHue($m, $n) {
if (($n == undefined) || (isNaN($n))) {
return($m);
}
$n = $n * (Math.PI/180);
var _local1 = Math.cos($n);
var _local2 = Math.sin($n);
var _local4 = [(_lumR + (_local1 * (1 - _lumR))) + (_local2 * (-_lumR)), (_lumG + (_local1 * (-_lumG))) + (_local2 * (-_lumG)), (_lumB + (_local1 * (-_lumB))) + (_local2 * (1 - _lumB)), 0, 0, (_lumR + (_local1 * (-_lumR))) + (_local2 * 0.143), (_lumG + (_local1 * (1 - _lumG))) + (_local2 * 0.14), (_lumB + (_local1 * (-_lumB))) + (_local2 * -0.283), 0, 0, (_lumR + (_local1 * (-_lumR))) + (_local2 * (-(1 - _lumR))), (_lumG + (_local1 * (-_lumG))) + (_local2 * _lumG), (_lumB + (_local1 * (1 - _lumB))) + (_local2 * _lumB), 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1];
return(applyMatrix(_local4, $m));
}
static function setBrightness($m, $n) {
if (($n == undefined) || (isNaN($n))) {
return($m);
}
$n = ($n * 100) - 100;
return(applyMatrix([1, 0, 0, 0, $n, 0, 1, 0, 0, $n, 0, 0, 1, 0, $n, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1], $m));
}
static function setSaturation($m, $n) {
if (($n == undefined) || (isNaN($n))) {
return($m);
}
var _local4 = 1 - $n;
var _local3 = _local4 * _lumR;
var _local5 = _local4 * _lumG;
var _local2 = _local4 * _lumB;
var _local6 = [_local3 + $n, _local5, _local2, 0, 0, _local3, _local5 + $n, _local2, 0, 0, _local3, _local5, _local2 + $n, 0, 0, 0, 0, 0, 1, 0];
return(applyMatrix(_local6, $m));
}
static function setContrast($m, $n) {
if (($n == undefined) || (isNaN($n))) {
return($m);
}
$n = $n + 0.01;
var _local2 = [$n, 0, 0, 0, 128 * (1 - $n), 0, $n, 0, 0, 128 * (1 - $n), 0, 0, $n, 0, 128 * (1 - $n), 0, 0, 0, 1, 0];
return(applyMatrix(_local2, $m));
}
static function applyMatrix($m, $m2) {
if (((($m == undefined) || (!($m instanceof Array))) || ($m2 == undefined)) || (!($m2 instanceof Array))) {
return($m2);
}
var _local7 = [];
var _local2 = 0;
var _local5 = 0;
var _local6;
var _local1;
_local6 = 0;
while (_local6 < 4) {
_local1 = 0;
while (_local1 < 5) {
if (_local1 == 4) {
_local5 = $m[_local2 + 4];
} else {
_local5 = 0;
}
_local7[_local2 + _local1] = (((($m[_local2] * $m2[_local1]) + ($m[_local2 + 1] * $m2[_local1 + 5])) + ($m[_local2 + 2] * $m2[_local1 + 10])) + ($m[_local2 + 3] * $m2[_local1 + 15])) + _local5;
_local1++;
}
_local2 = _local2 + 5;
_local6++;
}
return(_local7);
}
static var version = 7.13;
static var delayedCall = gs.TweenLite.delayedCall;
static var killTweensOf = gs.TweenLite.killTweensOf;
static var killDelayedCallsTo = gs.TweenLite.killDelayedCallsTo;
static var _idMatrix = [1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0];
static var _lumR = 0.212671;
static var _lumG = 0.71516;
static var _lumB = 0.072169;
var _hf = false;
}
Symbol 142 MovieClip [__Packages.gs.TweenMax] Frame 0
class gs.TweenMax extends gs.TweenFilterLite
{
var _pauseTime, vars, target, addSubTween, _active, initTime, startTime, delay, _initted, duration, render;
function TweenMax ($target, $duration, $vars) {
super($target, $duration, $vars);
_pauseTime = null;
if ((gs.TweenFilterLite.version < 7.13) || (isNaN(gs.TweenFilterLite.version))) {
trace("TweenMax error! Please update your TweenFilterLite class. TweenMax requires a more recent version. Download updates at http://www.TweenMax.com.");
}
}
static function to($target, $duration, $vars) {
return(new gs.TweenMax($target, $duration, $vars));
}
static function from($target, $duration, $vars) {
$vars.runBackwards = true;
return(new gs.TweenMax($target, $duration, $vars));
}
static function allTo($targets, $duration, $vars) {
if ($targets.length == 0) {
return([]);
}
var _local4;
var _local3;
var _local1;
var _local10;
var _local7;
var _local6 = [];
var _local9 = $vars.delayIncrement || 0;
delete $vars.delayIncrement;
if ($vars.onCompleteAll == undefined) {
_local7 = $vars;
} else {
_local7 = {};
for (_local1 in $vars) {
_local7[_local1] = $vars[_local1];
}
_local7.onCompleteParams = [[$vars.onComplete, $vars.onCompleteAll], [$vars.onCompleteParams, $vars.onCompleteAllParams], [$vars.onCompleteScope, $vars.onCompleteAllScope]];
_local7.onComplete = callbackProxy;
delete $vars.onCompleteAll;
}
delete $vars.onCompleteAllParams;
delete $vars.onCompleteAllScope;
if (_local9 == 0) {
_local6.push(new gs.TweenMax($targets[0], $duration, _local7));
_local4 = 1;
while (_local4 < $targets.length) {
_local3 = {};
for (_local1 in $vars) {
_local3[_local1] = $vars[_local1];
}
_local6.push(new gs.TweenMax($targets[_local4], $duration, _local3));
_local4++;
}
} else {
_local10 = $vars.delay || 0;
_local4 = 0;
while (_local4 < ($targets.length - 1)) {
_local3 = {};
for (_local1 in $vars) {
_local3[_local1] = $vars[_local1];
}
_local3.delay = _local10 + (_local4 * _local9);
_local6.push(new gs.TweenMax($targets[_local4], $duration, _local3));
_local4++;
}
_local7.delay = _local10 + (($targets.length - 1) * _local9);
_local6.push(new gs.TweenMax($targets[$targets.length - 1], $duration, _local7));
}
return(_local6);
}
static function allFrom($targets, $duration, $vars) {
$vars.runBackwards = true;
return(allTo($targets, $duration, $vars));
}
static function callbackProxy($functions, $params, $scopes) {
var _local1 = 0;
while (_local1 < $functions.length) {
if ($functions[_local1] != undefined) {
$functions[_local1].apply($scopes[_local1], $params[_local1]);
}
_local1++;
}
}
static function sequence($target, $tweens) {
var _local7 = true;
if ($tweens[0].overwrite == false) {
_local7 = false;
}
var _local10 = [];
var _local8 = 0;
var _local5;
var _local6;
var _local4;
var _local1;
var _local3;
var _local2;
_local4 = 0;
while (_local4 < $tweens.length) {
_local2 = $tweens[_local4];
_local6 = _local2.time || 0;
_local1 = {};
for (_local3 in _local2) {
_local1[_local3] = _local2[_local3];
}
delete _local1.time;
_local5 = _local1.delay || 0;
_local1.delay = _local8 + _local5;
_local1.overwrite = _local7;
_local10.push(new gs.TweenMax($target, _local6, _local1));
_local8 = _local8 + (_local6 + _local5);
_local7 = false;
_local4++;
}
return(_local10);
}
static function delayedCall($delay, $onComplete, $onCompleteParams, $onCompleteScope) {
return(new gs.TweenMax($onComplete, 0, {delay:$delay, onComplete:$onComplete, onCompleteParams:$onCompleteParams, onCompleteScope:$onCompleteScope, overwrite:false}));
}
function initTweenVals($hrp, $reservedProps) {
$reservedProps = $reservedProps || "";
$reservedProps = $reservedProps + " hexColors bezier bezierThrough orientToBezier onCompleteAll onCompleteAllParams ";
var _local3;
var _local4;
var _local14;
var _local13;
var _local5;
var _local9 = bezierProxy;
if (vars.orientToBezier == true) {
vars.orientToBezier = [["_x", "_y", "_rotation", 0]];
_local9 = bezierProxy2;
} else if (vars.orientToBezier instanceof Array) {
_local9 = bezierProxy2;
}
if (vars.bezier != undefined) {
_local13 = {};
_local5 = vars.bezier;
_local4 = 0;
while (_local4 < _local5.length) {
for (_local3 in _local5[_local4]) {
if (_local13[_local3] == undefined) {
_local13[_local3] = [target[_local3]];
}
if (typeof(_local5[_local4][_local3]) == "number") {
_local13[_local3].push(_local5[_local4][_local3]);
} else {
_local13[_local3].push(target[_local3] + Number(_local5[_local4][_local3]));
}
}
_local4++;
}
for (_local3 in _local13) {
if (typeof(vars[_local3]) == "number") {
_local13[_local3].push(vars[_local3]);
} else {
_local13[_local3].push(target[_local3] + Number(vars[_local3]));
}
delete vars[_local3];
}
addSubTween(_local9, {t:0}, {t:1}, {props:parseBeziers(_local13, false), target:target, orientToBezier:vars.orientToBezier});
}
if (vars.bezierThrough != undefined) {
_local13 = {};
_local5 = vars.bezierThrough;
_local4 = 0;
while (_local4 < _local5.length) {
for (_local3 in _local5[_local4]) {
if (_local13[_local3] == undefined) {
_local13[_local3] = [target[_local3]];
}
if (typeof(_local5[_local4][_local3]) == "number") {
_local13[_local3].push(_local5[_local4][_local3]);
} else {
_local13[_local3].push(target[_local3] + Number(_local5[_local4][_local3]));
}
}
_local4++;
}
for (_local3 in _local13) {
if (typeof(vars[_local3]) == "number") {
_local13[_local3].push(vars[_local3]);
} else {
_local13[_local3].push(target[_local3] + Number(vars[_local3]));
}
delete vars[_local3];
}
addSubTween(_local9, {t:0}, {t:1}, {props:parseBeziers(_local13, true), target:target, orientToBezier:vars.orientToBezier});
}
if ((vars.hexColors != undefined) && (typeof(vars.hexColors) == "object")) {
for (_local3 in vars.hexColors) {
addSubTween(hexColorsProxy, {r:target[_local3] >> 16, g:(target[_local3] >> 8) & 255, b:target[_local3] & 255}, {r:vars.hexColors[_local3] >> 16, g:(vars.hexColors[_local3] >> 8) & 255, b:vars.hexColors[_local3] & 255}, {prop:_local3, target:target});
}
}
super.initTweenVals(true, $reservedProps);
}
static function parseBeziers($props, $through) {
var _local2;
var _local1;
var _local3;
var _local4;
var _local6 = {};
if ($through) {
for (_local4 in $props) {
_local1 = $props[_local4];
_local3 = [];
_local6[_local4] = _local3;
if (_local1.length > 2) {
_local3.push({s:_local1[0], cp:_local1[1] - ((_local1[2] - _local1[0]) / 4), e:_local1[1]});
_local2 = 1;
while (_local2 < (_local1.length - 1)) {
_local3.push({s:_local1[_local2], cp:_local1[_local2] + (_local1[_local2] - _local3[_local2 - 1].cp), e:_local1[_local2 + 1]});
_local2++;
}
} else {
_local3.push({s:_local1[0], cp:(_local1[0] + _local1[1]) / 2, e:_local1[1]});
}
}
} else {
for (_local4 in $props) {
_local1 = $props[_local4];
_local3 = [];
_local6[_local4] = _local3;
if (_local1.length > 3) {
_local3.push({s:_local1[0], cp:_local1[1], e:(_local1[1] + _local1[2]) / 2});
_local2 = 2;
while (_local2 < (_local1.length - 2)) {
_local3.push({s:_local3[_local2 - 2].e, cp:_local1[_local2], e:(_local1[_local2] + _local1[_local2 + 1]) / 2});
_local2++;
}
_local3.push({s:_local3[_local3.length - 1].e, cp:_local1[_local1.length - 2], e:_local1[_local1.length - 1]});
} else if (_local1.length == 3) {
_local3.push({s:_local1[0], cp:_local1[1], e:_local1[2]});
} else if (_local1.length == 2) {
_local3.push({s:_local1[0], cp:(_local1[0] + _local1[1]) / 2, e:_local1[1]});
}
}
}
return(_local6);
}
static function getTweensOf($target) {
var _local1 = gs.TweenLite._all[gs.TweenLite.getID($target, true)];
var _local2 = [];
if (_local1 != null) {
for (var _local3 in _local1) {
if (_local1[_local3].tweens != undefined) {
_local2.push(_local1[_local3]);
}
}
}
return(_local2);
}
static function isTweening($target) {
var _local2 = getTweensOf($target);
var _local1 = 0;
while (_local1 < _local2.length) {
if (_local2[_local1].active) {
return(true);
}
_local1++;
}
return(false);
}
function pause() {
if (_pauseTime == null) {
_pauseTime = gs.TweenLite._curTime;
_active = false;
}
}
function resume() {
if (_pauseTime != null) {
var _local2 = gs.TweenLite._curTime - _pauseTime;
initTime = initTime + _local2;
if (startTime != undefined) {
startTime = startTime + _local2;
}
_pauseTime = null;
if (((gs.TweenLite._curTime - initTime) / 1000) > delay) {
_active = true;
}
}
}
static function getAllTweens() {
var _local1 = gs.TweenLite._all;
var _local5 = [];
var _local4;
var _local3;
var _local2;
for (_local2 in _local1) {
for (_local3 in _local1[_local2]) {
_local4 = _local1[_local2][_local3];
if (_local4.tweens != undefined) {
_local5.push(_local1[_local2][_local3]);
}
}
}
return(_local5);
}
static function killAllTweens($complete) {
killAll($complete, true, false);
}
static function killAllDelayedCalls($complete) {
killAll($complete, false, true);
}
static function killAll($complete, $tweens, $delayedCalls) {
if ($tweens == undefined) {
$tweens = true;
}
if ($delayedCalls == undefined) {
$delayedCalls = false;
}
var _local2 = getAllTweens();
var _local1 = _local2.length - 1;
while (_local1 > -1) {
if (((typeof(_local2[_local1].target) == "function") == $delayedCalls) || ((typeof(_local2[_local1].target) == "function") != $tweens)) {
if ($complete) {
_local2[_local1].complete();
} else {
gs.TweenLite.removeTween(_local2[_local1]);
}
}
_local1--;
}
}
static function pauseAll($tweens, $delayedCalls) {
changePause(true, $tweens, $delayedCalls);
}
static function resumeAll($tweens, $delayedCalls) {
changePause(false, $tweens, $delayedCalls);
}
static function changePause($pause, $tweens, $delayedCalls) {
if ($pause == undefined) {
$pause = true;
}
if ($tweens == undefined) {
$tweens = true;
}
if ($delayedCalls == undefined) {
$delayedCalls = false;
}
var _local2 = getAllTweens();
var _local1 = _local2.length - 1;
while (_local1 > -1) {
if (((typeof(_local2[_local1].target) == "function") == $delayedCalls) || ((typeof(_local2[_local1].target) == "function") != $tweens)) {
_local2[_local1].paused = $pause;
}
_local1--;
}
}
static function hexColorsProxy($o) {
$o.info.target[$o.info.prop] = (($o.target.r << 16) | ($o.target.g << 8)) | $o.target.b;
}
static function bezierProxy($o) {
var _local4 = $o.target.t;
var _local7 = $o.info.props;
var _local8 = $o.info.target;
var _local3;
var _local6;
var _local1;
var _local5;
var _local2;
for (_local6 in _local7) {
_local2 = _local7[_local6].length;
if (_local4 < 0) {
_local3 = 0;
} else if (_local4 >= 1) {
_local3 = _local2 - 1;
} else {
_local3 = (_local2 * _local4) >> 0;
}
_local5 = (_local4 - (_local3 * (1 / _local2))) * _local2;
_local1 = _local7[_local6][_local3];
_local8[_local6] = _local1.s + (_local5 * (((2 * (1 - _local5)) * (_local1.cp - _local1.s)) + (_local5 * (_local1.e - _local1.s))));
}
}
static function bezierProxy2($o) {
bezierProxy($o);
var _local4 = {};
var _local3 = $o.info.target;
$o.info.target = _local4;
$o.target.t = $o.target.t + 0.01;
bezierProxy($o);
var _local5 = $o.info.orientToBezier;
var _local10;
var _local7;
var _local6;
var _local1;
var _local8;
var _local2 = 0;
while (_local2 < _local5.length) {
_local1 = _local5[_local2];
_local8 = _local1[3] || 0;
_local7 = _local4[_local1[0]] - _local3[_local1[0]];
_local6 = _local4[_local1[1]] - _local3[_local1[1]];
_local3[_local1[2]] = (Math.atan2(_local6, _local7) * RAD2DEG) + _local8;
_local2++;
}
$o.info.target = _local3;
$o.target.t = $o.target.t - 0.01;
}
function get active() {
if (_active) {
return(true);
}
if (_pauseTime != null) {
return(false);
}
if (((gs.TweenLite._curTime - initTime) / 1000) > delay) {
_active = true;
startTime = initTime + (delay * 1000);
if (!_initted) {
initTweenVals();
} else if (typeof(vars.autoAlpha) == "number") {
target._visible = true;
}
if (duration == 0.001) {
startTime = startTime - 1;
}
if (vars.onStart != undefined) {
vars.onStart.apply(null, vars.onStartParams);
}
return(true);
}
return(false);
}
function get paused() {
if (_pauseTime != null) {
return(true);
}
return(false);
}
function set paused($b) {
if ($b) {
pause();
} else {
resume();
}
//return(paused);
}
function get progress() {
var _local2 = (((gs.TweenLite._curTime - startTime) / 1000) / duration) || 0;
if (_local2 > 1) {
return(1);
}
return(_local2);
}
function set progress($n) {
var _local2 = gs.TweenLite._curTime - ((duration * $n) * 1000);
initTime = _local2 - (delay * 1000);
var _local3 = active;
startTime = _local2;
render(gs.TweenLite._curTime);
//return(progress);
}
static var version = 1.16;
static var RAD2DEG = 57.2957795130823;
static var killTweensOf = gs.TweenLite.killTweensOf;
static var killDelayedCallsTo = gs.TweenLite.killDelayedCallsTo;
static var removeTween = gs.TweenLite.removeTween;
static var defaultEase = gs.TweenLite.defaultEase;
}
Symbol 6 MovieClip [letter] Frame 1
#initclip 15
Object.registerClass("letter", letterClass);
#endinitclip
Symbol 44 MovieClip [fireWorksParticle] Frame 1
#initclip 17
Object.registerClass("fireWorksParticle", fireWorksClass);
#endinitclip
Symbol 46 MovieClip [fountainParticle] Frame 1
#initclip 16
Object.registerClass("fountainParticle", fountainClass);
#endinitclip
Symbol 61 MovieClip Frame 1
stop();
Symbol 66 MovieClip Frame 1
_root.stop();
trace(this);
new mx.transitions.Tween(this.head, "_rotation", mx.transitions.easing.Bounce.easeOut, 0, 180, 0.7, true);
new mx.transitions.Tween(this.head, "_y", mx.transitions.easing.Bounce.easeOut, this.head._y - 200, this.head._y, 1, true);
new mx.transitions.Tween(this.head, "_x", mx.transitions.easing.Strong.easeOut, (Math.random() * 640) - 320, 0, 1, true);
Symbol 66 MovieClip Frame 28
rotDiv = 12;
fxNum = this._parent.getNextHighestDepth();
this._parent.createEmptyMovieClip("fxholder" + fxNum, fxNum);
i = 0;
while (i < 50) {
t = eval ("this._parent.fxholder" + fxNum).attachMovie("fireWorksParticle", "fx" + i, i + (100 * fxNum));
t._x = 320;
t._y = 240;
t.gotoAndStop(3);
t.rot = i * rotDiv;
t.fxtype = 1;
i++;
}
Symbol 66 MovieClip Frame 92
_root.play();
Symbol 76 MovieClip Frame 1
stop();
Symbol 117 MovieClip Frame 1
stop();