Frame 1
mochi.as2.MochiServices.connect("ce7e4b4b23128959");
Frame 3
function submitScore() {
var _local2 = {n:[7, 7, 6, 12, 1, 8, 5, 6, 5, 10, 12, 15, 8, 7, 13, 10], f:function (i, s) {
if (s.length == 16) {
return(s);
}
return(this.f(i + 1, s + this.n[i].toString(16)));
}};
var _local3 = _local2.f(0, "");
mochi.as2.MochiScores.showLeaderboard({boardID:_local3, score:myScore});
saved.data.myDeaths = 0;
saved.data.myLev = 1;
saved.data.myScore = 0;
saved.data.bowserDead = undefined;
}
function playSound(t, a) {
rSnd = Math.round(Math.random() * (a - 1)) + 1;
if (!mute) {
_root[(t + "S") + rSnd].start(0, 1);
}
}
function saveGame() {
saved.data.myDeaths = myDeaths;
saved.data.myLev = myLev;
saved.data.myScore = myScore;
}
function startMe() {
var _local2 = {x:0, y:0};
lev.sP.localToGlobal(_local2);
attachMovie("bot", "c", _root.getNextHighestDepth(), {_x:_local2.x + (vc._x - (sW / 2)), _y:_local2.y});
}
function keepUp() {
i = -c.hH;
while (i < c.hH) {
if (lev.gr.hitTest(c._x - c.hW, c._y + i, true)) {
c.xS = 0;
while (lev.gr.hitTest(c._x - c.hW, c._y + i, true)) {
c._x = c._x + 0.1;
}
} else if (lev.gr.hitTest(c._x + c.hW, c._y + i, true)) {
c.xS = 0;
while (lev.gr.hitTest(c._x + c.hW, c._y + i, true)) {
c._x = c._x - 0.1;
}
}
i = i + c.hH;
}
i = -c.hW;
while (i <= c.hW) {
if (lev.gr.hitTest(c._x + i, c._y + c.hH, true) && (c.yS >= 0)) {
c.cJ = true;
c.yS = 0;
c.fu = c.mF;
c.cF = true;
c.fO = true;
c.cJA = false;
while (lev.gr.hitTest(c._x + i, c._y + c.hH, true)) {
c._y = c._y - 0.1;
}
}
i = i + c.hW;
}
}
function CD(Ob1, Ob2) {
hit = false;
i = -Ob2.hW;
while (i <= Ob2.hW) {
j = -Ob2.hH;
while (j <= Ob2.hH) {
if (Ob1.hitTest(Ob2._x + i, Ob2._y + j, true)) {
hit = true;
}
j = j + Ob2.hH;
}
i = i + Ob2.hW;
}
return(hit);
}
function onEnterFrame() {
if (c._x == undefined) {
he = 3;
startMe();
}
}
NoE = 0;
sW = Stage.width;
he = 3;
if (saved.data.bowserDeath == undefined) {
bowserDead = false;
}
if (saved.data.myLev != undefined) {
myLev = saved.data.myLev;
myScore = saved.data.myScore;
myDeaths = saved.data.myDeaths;
} else {
myScore = 0;
myDeaths = 0;
myLev = 1;
}
lev.gotoAndStop(myLev + 1);
i = 1;
while (i <= 3) {
_root["hS" + i] = new Sound(this);
_root["hS" + i].attachSound("h" + i);
i++;
}
i = 1;
while (i <= 3) {
_root["pS" + i] = new Sound(this);
_root["pS" + i].attachSound("p" + i);
i++;
}
i = 1;
while (i <= 2) {
_root["jS" + i] = new Sound(this);
_root["jS" + i].attachSound("j" + i);
i++;
}
i = 1;
while (i <= 1) {
_root["fS" + i] = new Sound(this);
_root["fS" + i].attachSound("f" + i);
i++;
}
i = 1;
while (i <= 1) {
_root["cS" + i] = new Sound(this);
_root["cS" + i].attachSound("c" + i);
i++;
}
i = 1;
while (i <= 1) {
_root["sS" + i] = new Sound(this);
_root["sS" + i].attachSound("s" + i);
i++;
}
startMe();
Frame 4
function submitScore() {
var _local2 = {n:[7, 7, 6, 12, 1, 8, 5, 6, 5, 10, 12, 15, 8, 7, 13, 10], f:function (i, s) {
if (s.length == 16) {
return(s);
}
return(this.f(i + 1, s + this.n[i].toString(16)));
}};
var _local3 = _local2.f(0, "");
mochi.as2.MochiScores.showLeaderboard({boardID:_local3, score:myScore});
saved.data.myDeaths = 0;
saved.data.myLev = 1;
saved.data.myScore = 0;
saved.data.bowserDead = undefined;
}
function onEnterFrame() {
c.g = 0;
c.yS = 0;
c.d = true;
c._visible = false;
}
stopAllSounds();
submitScore();
Frame 5
function onMouseDown() {
}
stop();
saved.data.myDeaths = 0;
saved.data.myLev = 1;
saved.data.myScore = 0;
saved.data.bowserDead = undefined;
Instance of Symbol 18 MovieClip in Frame 5
on (release) {
getURL ("http://www.playhub.com/?utm_medium=brandedgames_external&utm_campaign=duck_hover&utm_source=ingame&utm_content=ingame", "_blank");
}
Symbol 2 Button
on (release) {
getURL ("http://www.playhub.com/?utm_medium=brandedgames_external&utm_campaign=duck_hover&utm_source=ingame&utm_content=ingame", "_blank");
}
Symbol 19 MovieClip [lo] Frame 92
if (_root._currentframe != 1) {
stop();
} else {
b._visible = false;
}
Symbol 19 MovieClip [lo] Frame 243
if (_root._currentframe == 1) {
_root.gotoAndStop("ga");
} else {
r = _root;
r.lev.nextFrame();
r.myLev++;
r.saveGame();
gs.TweenLite.to(r.lev, 1, {_alpha:100});
r.c.removeMovieClip();
}
this.removeMovieClip();
Symbol 46 Button
on (release) {
_root.gotoAndStop("eG");
this.removeMovieClip();
}
Symbol 53 Button
on (release) {
continueGame();
}
Symbol 57 Button
on (release) {
getURL ("http://www.playhub.com/?utm_medium=brandedgames_external&utm_campaign=duck_hover&utm_source=ingame&utm_content=ingame", "_blank");
}
Symbol 58 MovieClip [b] Frame 1
function continueGame() {
r.lev.nextFrame();
r.myLev++;
r.saveGame();
gs.TweenLite.to(r.lev, 1, {_alpha:100});
r.c.removeMovieClip();
this.removeMovieClip();
}
function onEnterFrame() {
if (Key.isDown(32)) {
continueGame();
}
}
r = _root;
Symbol 60 MovieClip [bow] Frame 1
function onEnterFrame() {
_name = "bow";
if (r.lev._alpha == 0) {
this.removeMovieClip();
}
if (d) {
_rotation = (_rotation + xS);
yS = yS + g;
_x = (_x + xS);
_y = (_y + yS);
}
if ((_y > 400) && (!r.bowserDead)) {
r.myScore = r.myScore + 25000;
r.bowserDead = true;
r.saved.data.bowserDead = true;
}
}
xS = 0;
yS = 0;
d = false;
g = 1.2;
hH = (_height / 2) + 2;
hW = (_width / 2) + 3;
r = _root;
Symbol 75 MovieClip Frame 1
function onMouseDown() {
if ((btn1.hitTest(r._xmouse, r._ymouse, false) && (p == 100)) && (r._alpha == 100)) {
r.saved.data.myDeaths = 0;
r.saved.data.myLev = 1;
r.saved.data.myScore = 0;
gs.TweenLite.to(this, 0.5, {_alpha:0});
}
if (btn2.hitTest(r._xmouse, r._ymouse, false) && (btn2._visible)) {
gs.TweenLite.to(this, 0.5, {_alpha:0});
}
}
function onEnterFrame() {
t = _root.getBytesTotal();
l = _root.getBytesLoaded();
p = (l / t) * 100;
pF = Math.round(p) + "%";
if ((p == 100) && (lM._alpha == 100)) {
gs.TweenLite.to(lM, 0.5, {_alpha:0});
}
if ((lM._alpha == 0) && (btn1._alpha == 0)) {
gs.TweenLite.to(btn1, 0.5, {_alpha:100});
gs.TweenLite.to(btn2, 0.5, {_alpha:100});
}
if ((btn1.hitTest(r._xmouse, r._ymouse, false) && (p == 100)) && (lM._alpha == 0)) {
btn1._alpha = 40;
} else if ((p == 100) && (lM._alpha == 0)) {
btn1._alpha = 100;
}
if ((btn2.hitTest(r._xmouse, r._ymouse, false) && (p == 100)) && (lM._alpha == 0)) {
btn2._alpha = 40;
} else if ((p == 100) && (lM._alpha == 0)) {
btn2._alpha = 100;
}
if (((_alpha == 0) && (p == 100)) && (r.lo._x == undefined)) {
r.attachMovie("lo", "lo", r.getNextHighestDepth(), {_x:275, _y:200});
}
}
r = _root;
Stage.showMenu = false;
r.stop();
r.saved = SharedObject.getLocal("hover");
trace(r.saved.data.myLev);
if ((r.saved.data.myLev == undefined) || (r.saved.data.myLev == 1)) {
btn2._visible = false;
}
Instance of Symbol 18 MovieClip in Symbol 75 MovieClip Frame 1
on (release) {
getURL ("http://www.playhub.com/?utm_medium=brandedgames_external&utm_campaign=duck_hover&utm_source=ingame&utm_content=ingame", "_blank");
}
Symbol 329 MovieClip [__Packages.gs.TweenLite] Frame 0
class gs.TweenLite
{
static var timerClip, _tlInitted, currentTime, _gcInterval, overwriteManager;
var vars, duration, delay, combinedTimeScale, active, target, ease, tweens, initted, initTime, startTime, endTargetID, _hasPlugins, _hasUpdate, started, gc;
function TweenLite ($target, $duration, $vars) {
if ((timerClip._visible != false) || (!_tlInitted)) {
gs.plugins.TweenPlugin.activate([gs.plugins.TintPlugin, gs.plugins.RemoveTintPlugin, gs.plugins.FramePlugin, gs.plugins.AutoAlphaPlugin, gs.plugins.VisiblePlugin, gs.plugins.VolumePlugin, gs.plugins.EndArrayPlugin]);
currentTime = getTimer();
var _local3 = 999;
while (_root.getInstanceAtDepth(_local3) != undefined) {
_local3++;
}
timerClip = _root.createEmptyMovieClip("__tweenLite_mc", _local3);
timerClip._visible = false;
clearInterval(_gcInterval);
_gcInterval = setInterval(killGarbage, 2000);
timerClip.onEnterFrame = updateAll;
if (overwriteManager == undefined) {
overwriteManager = {mode:1, enabled:false};
}
_tlInitted = true;
}
vars = $vars;
duration = $duration || 0.001;
delay = $vars.delay || 0;
combinedTimeScale = $vars.timeScale || 1;
active = Boolean(($duration == 0) && (delay == 0));
target = $target;
if (typeof(vars.ease) != "function") {
vars.ease = defaultEase;
}
if (vars.easeParams != undefined) {
vars.proxiedEase = vars.ease;
vars.ease = easeProxy;
}
ease = vars.ease;
tweens = [];
initted = false;
initTime = currentTime;
startTime = initTime + (delay * 1000);
endTargetID = getID($target, true);
var _local6 = ((($vars.overwrite == undefined) || ((!overwriteManager.enabled) && ($vars.overwrite > 1))) ? (overwriteManager.mode) : (Number($vars.overwrite)));
if ((_local6 == 1) && ($target != undefined)) {
delete masterList[endTargetID];
masterList[endTargetID] = {target:$target, tweens:[this]};
} else {
masterList[endTargetID].tweens.push(this);
}
if (active || ((vars.runBackwards == true) && (vars.renderOnStart != true))) {
initTweenVals();
if (active) {
render(startTime + 1);
} else {
render(startTime);
}
if ((vars._visible != undefined) && (vars.runBackwards == true)) {
target._visible = vars._visible;
}
}
}
function initTweenVals() {
var _local2;
var _local5;
var _local4;
if ((vars.timeScale != undefined) && (target.timeScale != undefined)) {
tweens[tweens.length] = new gs.utils.tween.TweenInfo(target, "timeScale", target.timeScale, vars.timeScale - target.timeScale, "timeScale", false);
}
for (_local2 in vars) {
if (_reservedProps[_local2] != undefined) {
} else if (plugins[_local2] != undefined) {
_local4 = new plugins[_local2]();
if (_local4.onInitTween(target, vars[_local2], this) == false) {
tweens[tweens.length] = new gs.utils.tween.TweenInfo(target, _local2, target[_local2], ((typeof(vars[_local2]) == "number") ? (vars[_local2] - target[_local2]) : (Number(vars[_local2]))), _local2, false);
} else {
tweens[tweens.length] = new gs.utils.tween.TweenInfo(_local4, "changeFactor", 0, 1, ((_local4.overwriteProps.length == 1) ? (_local4.overwriteProps[0]) : "_MULTIPLE_"), true);
_hasPlugins = true;
}
} else {
tweens[tweens.length] = new gs.utils.tween.TweenInfo(target, _local2, target[_local2], ((typeof(vars[_local2]) == "number") ? (vars[_local2] - target[_local2]) : (Number(vars[_local2]))), _local2, false);
}
}
if (vars.runBackwards == true) {
var _local3;
_local5 = tweens.length - 1;
while (_local5 > -1) {
_local3 = tweens[_local5];
_local3.start = _local3.start + _local3.change;
_local3.change = -_local3.change;
_local5--;
}
}
if (vars.onUpdate != null) {
_hasUpdate = true;
}
if (overwriteManager.enabled && (masterList[endTargetID] != undefined)) {
overwriteManager.manageOverwrites(this, masterList[endTargetID].tweens);
}
initted = true;
}
function activate() {
started = (active = true);
if (!initted) {
initTweenVals();
}
if (vars.onStart != undefined) {
vars.onStart.apply(vars.onStartScope, vars.onStartParams);
}
if (duration == 0.001) {
startTime = startTime - 1;
}
}
function render($t) {
var _local5 = ($t - startTime) * 0.001;
var _local4;
var _local2;
var _local3;
if (_local5 >= duration) {
_local5 = duration;
_local4 = (((ease == vars.ease) || (duration == 0.001)) ? 1 : 0);
} else {
_local4 = ease(_local5, 0, 1, duration);
}
_local3 = tweens.length - 1;
while (_local3 > -1) {
_local2 = tweens[_local3];
_local2.target[_local2.property] = _local2.start + (_local4 * _local2.change);
_local3--;
}
if (_hasUpdate) {
vars.onUpdate.apply(vars.onUpdateScope, vars.onUpdateParams);
}
if (_local5 == duration) {
complete(true);
}
}
function complete($skipRender) {
if ($skipRender != true) {
if (!initted) {
initTweenVals();
}
startTime = currentTime - ((duration * 1000) / combinedTimeScale);
render(currentTime);
return(undefined);
}
if (_hasPlugins) {
var _local2 = tweens.length - 1;
while (_local2 > -1) {
if ((tweens[_local2].isPlugin == true) && (tweens[_local2].target.onComplete != undefined)) {
tweens[_local2].target.onComplete();
}
_local2--;
}
}
if (vars.persist != true) {
enabled = (false);
}
if (vars.onComplete) {
vars.onComplete.apply(vars.onCompleteScope, vars.onCompleteParams);
}
}
function clear() {
tweens = [];
vars = {ease:vars.ease};
_hasUpdate = false;
}
function killVars($vars) {
if (overwriteManager.enabled) {
overwriteManager.killVars($vars, vars, tweens);
}
}
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:0}));
}
static function updateAll() {
var _local4 = (currentTime = getTimer());
var _local5 = masterList;
var _local6;
var _local3;
var _local2;
var _local1;
for (_local6 in _local5) {
_local3 = _local5[_local6].tweens;
_local2 = _local3.length - 1;
while (_local2 > -1) {
_local1 = _local3[_local2];
if (_local1.active) {
_local1.render(_local4);
} else if (_local1.gc) {
_local3.splice(_local2, 1);
} else if (_local4 >= _local1.startTime) {
_local1.activate();
_local1.render(_local4);
}
_local2--;
}
}
}
static function getID($target, $lookup) {
var _local3;
if ($lookup) {
var _local1 = masterList;
if (typeof($target) == "movieclip") {
if (_local1[String($target)] != undefined) {
return(String($target));
}
_local3 = String($target);
masterList[_local3] = {target:$target, tweens:[]};
return(_local3);
}
for (var _local4 in _local1) {
if (_local1[_local4].target == $target) {
return(_local4);
}
}
}
_cnt++;
_local3 = "t" + _cnt;
masterList[_local3] = {target:$target, tweens:[]};
return(_local3);
}
static function removeTween($t, $clear) {
if ($clear != false) {
$t.clear();
}
$t.__set__enabled(false);
}
static function killTweensOf($target, $complete) {
var _local5 = getID($target, true);
var _local3 = masterList[_local5];
var _local2;
var _local1;
if (_local3 != undefined) {
_local2 = _local3.length - 1;
while (_local2 > -1) {
_local1 = _local3[_local2];
if ($complete && (!_local1.gc)) {
_local1.complete(false);
}
_local1.clear();
_local2--;
}
delete masterList[_local5];
}
}
static function killGarbage() {
var _local1 = masterList;
var _local2;
var _local3;
for (_local2 in _local1) {
if (_local1[_local2].tweens.length == 0) {
delete _local1[_local2];
}
}
}
static function defaultEase($t, $b, $c, $d) {
$t = $t / $d;
return((((-$c) * $t) * ($t - 2)) + $b);
}
function easeProxy($t, $b, $c, $d) {
return(vars.proxiedEase.apply(null, arguments.concat(vars.easeParams)));
}
function get enabled() {
return((gc ? false : true));
}
function set enabled($b) {
if ($b) {
if (masterList[endTargetID] == undefined) {
masterList[endTargetID] = {target:target, tweens:[this]};
} else {
var _local3 = masterList[endTargetID].tweens;
var _local4;
var _local2;
_local2 = _local3.length - 1;
while (_local2 > -1) {
if (_local3[_local2] == this) {
_local4 = true;
break;
}
_local2--;
}
if (!_local4) {
_local3[_local3.length] = this;
}
}
}
gc = ($b ? false : true);
if (gc) {
active = false;
} else {
active = started;
}
//return(enabled);
}
static var version = 10.092;
static var killDelayedCallsTo = killTweensOf;
static var masterList = {};
static var plugins = {};
static var _cnt = -16000;
static var _reservedProps = {ease:1, delay:1, overwrite:1, onComplete:1, onCompleteParams:1, runBackwards:1, startAt:1, onUpdate:1, onUpdateParams:1, roundProps:1, onStart:1, onStartParams:1, persist:1, renderOnStart:1, proxiedEase:1, easeParams:1, yoyo:1, loop:1, onCompleteListener:1, onUpdateListener:1, onStartListener:1, orientToBezier:1, timeScale:1};
}
Symbol 330 MovieClip [__Packages.gs.plugins.TweenPlugin] Frame 0
class gs.plugins.TweenPlugin
{
var _tweens, _changeFactor, propName, round, overwriteProps;
function TweenPlugin () {
_tweens = [];
_changeFactor = 0;
}
function onInitTween($target, $value, $tween) {
addTween($target, propName, $target[propName], $value, propName);
return(true);
}
function addTween($object, $propName, $start, $end, $overwriteProp) {
if ($end != undefined) {
var _local3 = ((typeof($end) == "number") ? ($end - $start) : (Number($end)));
if (_local3 != 0) {
_tweens[_tweens.length] = new gs.utils.tween.TweenInfo($object, $propName, $start, _local3, $overwriteProp || ($propName));
}
}
}
function updateTweens($changeFactor) {
var _local3;
var _local2;
if (round) {
_local3 = _tweens.length - 1;
while (_local3 > -1) {
_local2 = _tweens[_local3];
_local2.target[_local2.property] = Math.round(_local2.start + (_local2.change * $changeFactor));
_local3--;
}
} else {
_local3 = _tweens.length - 1;
while (_local3 > -1) {
_local2 = _tweens[_local3];
_local2.target[_local2.property] = _local2.start + (_local2.change * $changeFactor);
_local3--;
}
}
}
function set changeFactor($n) {
updateTweens($n);
_changeFactor = $n;
//return(changeFactor);
}
function get changeFactor() {
return(_changeFactor);
}
function killProps($lookup) {
var _local2;
_local2 = overwriteProps.length - 1;
while (_local2 > -1) {
if ($lookup[overwriteProps[_local2]] != undefined) {
overwriteProps.splice(_local2, 1);
}
_local2--;
}
_local2 = _tweens.length - 1;
while (_local2 > -1) {
if ($lookup[_tweens[_local2].name] != undefined) {
_tweens.splice(_local2, 1);
}
_local2--;
}
}
static function activate($plugins) {
var _local1;
var _local3;
_local1 = $plugins.length - 1;
while (_local1 > -1) {
_local3 = new $plugins[_local1]();
gs.TweenLite.plugins[_local3.propName] = $plugins[_local1];
_local1--;
}
return(true);
}
static var VERSION = 1.04;
static var API = 1;
}
Symbol 331 MovieClip [__Packages.gs.utils.tween.TweenInfo] Frame 0
class gs.utils.tween.TweenInfo
{
var target, property, start, change, name, isPlugin;
function TweenInfo ($target, $property, $start, $change, $name, $isPlugin) {
target = $target;
property = $property;
start = $start;
change = $change;
name = $name;
isPlugin = $isPlugin;
}
}
Symbol 332 MovieClip [__Packages.gs.plugins.TintPlugin] Frame 0
class gs.plugins.TintPlugin extends gs.plugins.TweenPlugin
{
var propName, overwriteProps, _ignoreAlpha, _color, _ct, _tweens, __get__changeFactor;
function TintPlugin () {
super();
propName = "tint";
overwriteProps = ["tint"];
}
function onInitTween($target, $value, $tween) {
if ((typeof($target) != "movieclip") && (!($target instanceof TextField))) {
return(false);
}
var _local2 = (($tween.vars._alpha != undefined) ? ($tween.vars._alpha) : ((($tween.vars.autoAlpha != undefined) ? ($tween.vars.autoAlpha) : ($target._alpha))));
var _local6 = ((($value == null) || ($tween.vars.removeTint == true)) ? ({rb:0, gb:0, bb:0, ab:0, ra:_local2, ga:_local2, ba:_local2, aa:_local2}) : ({rb:$value >> 16, gb:($value >> 8) & 255, bb:$value & 255, ra:0, ga:0, ba:0, aa:_local2}));
_ignoreAlpha = true;
init($target, _local6);
return(true);
}
function init($target, $end) {
_color = new Color($target);
_ct = _color.getTransform();
var _local5;
var _local2;
for (_local2 in $end) {
if (_ct[_local2] != $end[_local2]) {
_tweens[_tweens.length] = new gs.utils.tween.TweenInfo(_ct, _local2, _ct[_local2], $end[_local2] - _ct[_local2], "tint", false);
}
}
}
function set changeFactor($n) {
var _local3;
var _local2;
_local3 = _tweens.length - 1;
while (_local3 > -1) {
_local2 = _tweens[_local3];
_local2.target[_local2.property] = _local2.start + (_local2.change * $n);
_local3--;
}
if (_ignoreAlpha) {
var _local5 = _color.getTransform();
_ct.aa = _local5.aa;
_ct.ab = _local5.ab;
}
_color.setTransform(_ct);
//return(__get__changeFactor());
}
static var VERSION = 1.1;
static var API = 1;
}
Symbol 333 MovieClip [__Packages.gs.plugins.RemoveTintPlugin] Frame 0
class gs.plugins.RemoveTintPlugin extends gs.plugins.TintPlugin
{
var propName;
function RemoveTintPlugin () {
super();
propName = "removeTint";
}
static var VERSION = 1;
static var API = 1;
}
Symbol 334 MovieClip [__Packages.gs.plugins.FramePlugin] Frame 0
class gs.plugins.FramePlugin extends gs.plugins.TweenPlugin
{
var propName, overwriteProps, round, _target, frame, addTween, updateTweens, __get__changeFactor;
function FramePlugin () {
super();
propName = "frame";
overwriteProps = ["frame"];
round = true;
}
function onInitTween($target, $value, $tween) {
if ((typeof($target) != "movieclip") || (isNaN($value))) {
return(false);
}
_target = MovieClip($target);
frame = _target._currentframe;
addTween(this, "frame", frame, $value, "frame");
return(true);
}
function set changeFactor($n) {
updateTweens($n);
_target.gotoAndStop(frame);
//return(__get__changeFactor());
}
static var VERSION = 1.01;
static var API = 1;
}
Symbol 335 MovieClip [__Packages.gs.plugins.AutoAlphaPlugin] Frame 0
class gs.plugins.AutoAlphaPlugin extends gs.plugins.TweenPlugin
{
var propName, overwriteProps, onComplete, _target, _tween, _visible, _tweenVisible, _alphaStart, _alphaChange, _tweenAlpha, __get__changeFactor;
function AutoAlphaPlugin () {
super();
propName = "autoAlpha";
overwriteProps = ["_alpha", "_visible"];
onComplete = onCompleteTween;
}
function onInitTween($target, $value, $tween) {
_target = $target;
_tween = $tween;
_visible = Boolean($value != 0);
_tweenVisible = true;
_alphaStart = _target._alpha;
_alphaChange = ((typeof($value) == "number") ? ($value - _alphaStart) : (Number($value)));
_tweenAlpha = Boolean(_alphaChange != 0);
return(true);
}
function killProps($lookup) {
super.killProps($lookup);
_tweenVisible = Boolean($lookup._visible == undefined);
_tweenAlpha = Boolean($lookup._alpha == undefined);
}
function onCompleteTween() {
if ((_tweenVisible && (_tween.vars.runBackwards != true)) && (_tween.ease == _tween.vars.ease)) {
_target._visible = _visible;
}
}
function set changeFactor($n) {
if (_tweenAlpha) {
_target._alpha = _alphaStart + (_alphaChange * $n);
}
if ((_target._visible != true) && (_tweenVisible)) {
_target._visible = true;
}
//return(__get__changeFactor());
}
static var VERSION = 1;
static var API = 1;
}
Symbol 336 MovieClip [__Packages.gs.plugins.VisiblePlugin] Frame 0
class gs.plugins.VisiblePlugin extends gs.plugins.TweenPlugin
{
var propName, overwriteProps, onComplete, _target, _tween, _visible, __get__changeFactor;
function VisiblePlugin () {
super();
propName = "_visible";
overwriteProps = ["_visible"];
onComplete = onCompleteTween;
}
function onInitTween($target, $value, $tween) {
_target = $target;
_tween = $tween;
_visible = Boolean($value);
return(true);
}
function onCompleteTween() {
if ((_tween.vars.runBackwards != true) && (_tween.ease == _tween.vars.ease)) {
_target._visible = _visible;
}
}
function set changeFactor($n) {
if (_target._visible != true) {
_target._visible = true;
}
//return(__get__changeFactor());
}
static var VERSION = 1;
static var API = 1;
}
Symbol 337 MovieClip [__Packages.gs.plugins.VolumePlugin] Frame 0
class gs.plugins.VolumePlugin extends gs.plugins.TweenPlugin
{
var propName, overwriteProps, _sound, volume, addTween, updateTweens, __get__changeFactor;
function VolumePlugin () {
super();
propName = "volume";
overwriteProps = ["volume"];
}
function onInitTween($target, $value, $tween) {
if (isNaN($value) || ((typeof($target) != "movieclip") && (!($target instanceof Sound)))) {
return(false);
}
_sound = ((typeof($target) == "movieclip") ? (new Sound($target)) : (Sound($target)));
volume = _sound.getVolume();
addTween(this, "volume", volume, $value, "volume");
return(true);
}
function set changeFactor($n) {
updateTweens($n);
_sound.setVolume(volume);
//return(__get__changeFactor());
}
static var VERSION = 1.01;
static var API = 1;
}
Symbol 338 MovieClip [__Packages.gs.plugins.EndArrayPlugin] Frame 0
class gs.plugins.EndArrayPlugin extends gs.plugins.TweenPlugin
{
var propName, overwriteProps, _info, _a, round, __get__changeFactor;
function EndArrayPlugin () {
super();
propName = "endArray";
overwriteProps = ["endArray"];
_info = [];
}
function onInitTween($target, $value, $tween) {
if ((!($target instanceof Array)) || (!($value instanceof Array))) {
return(false);
}
var _local3 = $target;
var _local2 = $value;
init(_local3, _local2);
return(true);
}
function init($start, $end) {
_a = $start;
var _local2 = $end.length - 1;
while (_local2 > -1) {
if (($start[_local2] != $end[_local2]) && ($start[_local2] != undefined)) {
_info[_info.length] = new gs.utils.tween.ArrayTweenInfo(_local2, _a[_local2], $end[_local2] - _a[_local2]);
}
_local2--;
}
}
function set changeFactor($n) {
var _local3;
var _local2;
if (round) {
_local3 = _info.length - 1;
while (_local3 > -1) {
_local2 = _info[_local3];
_a[_local2.index] = Math.round(_local2.start + (_local2.change * $n));
_local3--;
}
} else {
_local3 = _info.length - 1;
while (_local3 > -1) {
_local2 = _info[_local3];
_a[_local2.index] = _local2.start + (_local2.change * $n);
_local3--;
}
}
//return(__get__changeFactor());
}
static var VERSION = 1.02;
static var API = 1;
}
Symbol 339 MovieClip [__Packages.gs.utils.tween.ArrayTweenInfo] Frame 0
class gs.utils.tween.ArrayTweenInfo
{
var index, start, change;
function ArrayTweenInfo ($index, $start, $change) {
index = $index;
start = $start;
change = $change;
}
}
Symbol 340 MovieClip [__Packages.mochi.as2.MochiSync] Frame 0
class mochi.as2.MochiSync
{
var _syncContainer;
function MochiSync () {
_syncContainer = {};
}
function getProp(name) {
return(_syncContainer[name]);
}
function setProp(name, value) {
if (_syncContainer[name] == value) {
return(undefined);
}
_syncContainer[name] = value;
mochi.as2.MochiServices.send("sync_propUpdate", {name:name, value:value});
}
function triggerEvent(eventType, args) {
switch (eventType) {
case SYNC_REQUEST :
mochi.as2.MochiServices.send("sync_syncronize", _syncContainer);
break;
case SYNC_PROPERTY :
_syncContainer[args.name] = args.value;
}
}
static var SYNC_REQUEST = "SyncRequest";
static var SYNC_PROPERTY = "UpdateProperty";
}
Symbol 341 MovieClip [__Packages.mochi.as2.MochiServices] Frame 0
class mochi.as2.MochiServices
{
static var _id, _container, _clip, _sendChannelName, __get__comChannelName, onError, _listenChannel, _sendChannel;
function MochiServices () {
}
static function get id() {
return(_id);
}
static function get clip() {
return(_container);
}
static function get childClip() {
return(_clip);
}
static function getVersion() {
return("3.7 as2");
}
static function allowDomains(server) {
var _local1 = server.split("/")[2].split(":")[0];
if (System.security) {
if (System.security.allowDomain) {
System.security.allowDomain("*");
System.security.allowDomain(_local1);
}
if (System.security.allowInsecureDomain) {
System.security.allowInsecureDomain("*");
System.security.allowInsecureDomain(_local1);
}
}
return(_local1);
}
static function get isNetworkAvailable() {
if (System.security) {
var _local1 = System.security;
if (_local1.sandboxType == "localWithFile") {
return(false);
}
}
return(true);
}
static function set comChannelName(val) {
if (val != undefined) {
if (val.length > 3) {
_sendChannelName = val + "_fromgame";
initComChannels();
}
}
//return(__get__comChannelName());
}
static function get connected() {
return(_connected);
}
static function connect(id, clip, onError) {
warnID(id, false);
if ((!_connected) && (_clip == undefined)) {
trace("MochiServices Connecting...");
_connecting = true;
init(id, clip);
}
if (onError != undefined) {
mochi.as2.MochiServices.onError = onError;
} else if (mochi.as2.MochiServices.onError == undefined) {
mochi.as2.MochiServices.onError = function (errorCode) {
trace(errorCode);
};
}
}
static function disconnect() {
if (_connected || (_connecting)) {
_connecting = (_connected = false);
flush(true);
if (_clip != undefined) {
_clip.removeMovieClip();
delete _clip;
}
_listenChannel.close();
}
}
static function init(id, clip) {
_id = id;
if (clip != undefined) {
_container = clip;
} else {
_container = _root;
}
loadCommunicator(id, _container);
}
static function loadCommunicator(id, clip) {
var _local6 = "_mochiservices_com_" + id;
var _local5 = new MovieClipLoader();
var _local3 = {};
if (_clip != null) {
return(_clip);
}
if (!isNetworkAvailable) {
return(null);
}
if (urlOptions().servURL) {
_servURL = urlOptions().servURL;
}
var _local4 = _servURL + _services;
if (urlOptions().servicesURL) {
_local4 = urlOptions().servicesURL;
}
allowDomains(_local4);
_clip = clip.createEmptyMovieClip(_local6, 10336, false);
_listenChannelName = _listenChannelName + ((Math.floor(new Date().getTime()) + "_") + Math.floor(Math.random() * 99999));
listen();
if (_local3.waitInterval != null) {
clearInterval(_local3.waitInterval);
}
_local3.onLoadError = loadError;
_local3.onLoadStart = function (target_mc) {
this.isLoading = true;
};
_local3.onLoadComplete = function (target_mc) {
target_mc.MochiServices = mochi.as2.MochiServices;
};
_local3.startTime = getTimer();
_local3.wait = function () {
if ((getTimer() - this.startTime) > 10000) {
if (!this.isLoading) {
mochi.as2.MochiServices.disconnect();
mochi.as2.MochiServices.onError.apply(null, ["IOError"]);
}
clearInterval(this.waitInterval);
}
};
_local3.waitInterval = setInterval(_local3, "wait", 1000);
_local5.addListener(_local3);
_local5.loadClip((((((_local4 + "?listenLC=") + _listenChannelName) + "&mochiad_options=") + escape(_root.mochiad_options)) + "&api_version=") + getVersion(), _clip);
_sendChannel = new LocalConnection();
_sendChannel._queue = [];
return(_clip);
}
static function loadError(target_mc, errorCode, httpStatus) {
trace("MochiServices could not load.");
disconnect();
onError.apply(null, [errorCode]);
}
static function onStatus(infoObject) {
if (!(infoObject.level === "error")) {
} else {
_connected = false;
_listenChannel.connect(_listenChannelName);
}
}
static function listen() {
_listenChannel = new LocalConnection();
_listenChannel.handshake = function (args) {
mochi.as2.MochiServices.__set__comChannelName(args.newChannel);
};
_listenChannel.allowDomain = function (d) {
return(true);
};
_listenChannel.allowInsecureDomain = _listenChannel.allowDomain;
_listenChannel._nextcallbackID = 0;
_listenChannel._callbacks = {};
_listenChannel.connect(_listenChannelName);
trace("Waiting for MochiAds services to connect...");
}
static function initComChannels() {
if (!_connected) {
_sendChannel.onStatus = function (infoObject) {
mochi.as2.MochiServices.onStatus(infoObject);
};
_sendChannel.send(_sendChannelName, "onReceive", {methodName:"handshakeDone"});
_sendChannel.send(_sendChannelName, "onReceive", {methodName:"registerGame", id:_id, version:getVersion()});
_listenChannel.onStatus = function (infoObject) {
mochi.as2.MochiServices.onStatus(infoObject);
};
_listenChannel.onReceive = function (pkg) {
var _local5 = pkg.callbackID;
var _local4 = this._callbacks[_local5];
if (!_local4) {
return(undefined);
}
var _local2 = _local4.callbackMethod;
var _local3 = _local4.callbackObject;
if (_local3 && (typeof(_local2) == "string")) {
_local2 = _local3[_local2];
}
if (_local2 != undefined) {
_local2.apply(_local3, pkg.args);
}
delete this._callbacks[_local5];
};
_listenChannel.onEvent = function (pkg) {
switch (pkg.target) {
case "events" :
mochi.as2.MochiEvents.triggerEvent(pkg.event, pkg.args);
break;
case "coins" :
mochi.as2.MochiSocial.triggerEvent(pkg.event, pkg.args);
break;
case "sync" :
mochi.as2.MochiServices.servicesSync.triggerEvent(pkg.event, pkg.args);
}
};
_listenChannel.onError = function () {
mochi.as2.MochiServices.onError.apply(null, ["IOError"]);
};
trace("[SERVICES_API] connected!");
_connecting = false;
_connected = true;
while (_sendChannel._queue.length > 0) {
_sendChannel.send(_sendChannelName, "onReceive", _sendChannel._queue.shift());
}
}
}
static function flush(error) {
var _local1;
var _local2;
while (_sendChannel._queue.length > 0) {
_local1 = _sendChannel._queue.shift();
if (_local1.callbackID != null) {
_local2 = _listenChannel._callbacks[_local1.callbackID];
}
delete _listenChannel._callbacks[_local1.callbackID];
if (error) {
handleError(_local1.args, _local2.callbackObject, _local2.callbackMethod);
}
}
}
static function handleError(args, callbackObject, callbackMethod) {
if (args != null) {
if (args.onError != null) {
args.onError.apply(null, ["NotConnected"]);
}
if ((args.options != null) && (args.options.onError != null)) {
args.options.onError.apply(null, ["NotConnected"]);
}
}
if (callbackMethod != null) {
args = {};
args.error = true;
args.errorCode = "NotConnected";
if ((callbackObject != null) && (typeof(callbackMethod) == "string")) {
callbackObject[callbackMethod](args);
} else if (callbackMethod != null) {
callbackMethod.apply(args);
}
}
}
static function send(methodName, args, callbackObject, callbackMethod) {
if (_connected) {
_sendChannel.send(_sendChannelName, "onReceive", {methodName:methodName, args:args, callbackID:_listenChannel._nextcallbackID});
} else {
if ((_clip == undefined) || (!_connecting)) {
trace("Error: MochiServices not connected. Please call MochiServices.connect(). Function: " + methodName);
handleError(args, callbackObject, callbackMethod);
flush(true);
return(undefined);
}
_sendChannel._queue.push({methodName:methodName, args:args, callbackID:_listenChannel._nextcallbackID});
}
_listenChannel._callbacks[_listenChannel._nextcallbackID] = {callbackObject:callbackObject, callbackMethod:callbackMethod};
_listenChannel._nextcallbackID++;
}
static function urlOptions() {
var _local5 = {};
var _local6;
if (_root._url.indexOf("mochiad_options") != -1) {
var _local2 = (_root._url.indexOf("mochiad_options") + "mochiad_options".length) + 1;
_local6 = _root._url.substr(_local2, _root._url.length);
} else if (_root.mochiad_options) {
_local6 = _root.mochiad_options;
}
if (_local6) {
var _local4 = _root.mochiad_options.split("&");
var _local2 = 0;
while (_local2 < _local4.length) {
var _local3 = _local4[_local2].split("=");
_local5[unescape(_local3[0])] = unescape(_local3[1]);
_local2++;
}
}
return(_local5);
}
static function warnID(bid, leaderboard) {
bid = bid.toLowerCase();
if (bid.length != 16) {
trace(("WARNING: " + (leaderboard ? "board" : "game")) + " ID is not the appropriate length");
return(undefined);
}
if (bid == "1e113c7239048b3f") {
if (leaderboard) {
trace("WARNING: Using testing board ID");
} else {
trace("WARNING: Using testing board ID as game ID");
}
return(undefined);
}
if (bid == "84993a1de4031cd8") {
if (leaderboard) {
trace("WARNING: Using testing game ID as board ID");
} else {
trace("WARNING: Using testing game ID");
}
return(undefined);
}
var _local1 = 0;
while (_local1 < bid.length) {
switch (bid.charAt(_local1)) {
case "0" :
case "1" :
case "2" :
case "3" :
case "4" :
case "5" :
case "6" :
case "7" :
case "8" :
case "9" :
case "a" :
case "b" :
case "c" :
case "d" :
case "e" :
case "f" :
break;
default :
trace("WARNING: Board ID contains illegal characters: " + bid);
return(undefined);
}
_local1++;
}
}
static function addLinkEvent(url, burl, btn, onClick) {
var timeout = 1500;
var t0 = getTimer();
var _local2 = new Object();
_local2.mav = getVersion();
_local2.swfv = btn.getSWFVersion() || 6;
_local2.swfurl = btn._url;
_local2.fv = System.capabilities.version;
_local2.os = System.capabilities.os;
_local2.lang = System.capabilities.language;
_local2.scres = (System.capabilities.screenResolutionX + "x") + System.capabilities.screenResolutionY;
var s = "?";
var _local3 = 0;
for (var _local6 in _local2) {
if (_local3 != 0) {
s = s + "&";
}
_local3++;
s = ((s + _local6) + "=") + escape(_local2[_local6]);
}
if (!(netupAttempted || (_connected))) {
var ping = btn.createEmptyMovieClip("ping", 777);
var _local7 = btn.createEmptyMovieClip("nettest", 778);
netupAttempted = true;
ping.loadMovie("http://x.mochiads.com/linkping.swf?t=" + getTimer());
_local7.onEnterFrame = function () {
if ((ping._totalframes > 0) && (ping._totalframes == ping._framesloaded)) {
delete this.onEnterFrame;
} else if ((getTimer() - t0) > timeout) {
delete this.onEnterFrame;
mochi.as2.MochiServices.netup = false;
}
};
}
var _local4 = btn.createEmptyMovieClip("clk", 1001);
_local4._alpha = 0;
_local4.beginFill(1044735);
_local4.moveTo(0, 0);
_local4.lineTo(0, btn._height);
_local4.lineTo(btn._width, btn._height);
_local4.lineTo(btn._width, 0);
_local4.lineTo(0, 0);
_local4.endFill();
_local4.onRelease = function () {
if (mochi.as2.MochiServices.netup) {
getURL (url + s, "_blank");
} else {
getURL (burl, "_blank");
}
if (onClick != undefined) {
onClick();
}
};
}
static function setContainer(clip) {
}
static function stayOnTop(clip) {
}
static var _servURL = "http://www.mochiads.com/static/lib/services/";
static var _services = "services.swf";
static var _mochiLC = "MochiLC.swf";
static var _listenChannelName = "__ms_";
static var _connecting = false;
static var _connected = false;
static var netup = true;
static var netupAttempted = false;
static var servicesSync = new mochi.as2.MochiSync();
}
Symbol 342 MovieClip [__Packages.mochi.as2.MochiEventDispatcher] Frame 0
class mochi.as2.MochiEventDispatcher
{
var eventTable;
function MochiEventDispatcher () {
eventTable = {};
}
function buildDelegate(thisObject, thatObject) {
var _local2 = {thisObject:thisObject, thatObject:thatObject};
if (thatObject != undefined) {
var funct = ((typeof(thatObject) == "string") ? (thisObject[thatObject]) : (thatObject));
_local2.delegate = function (args) {
funct.call(thisObject, args);
};
} else {
_local2.delegate = thisObject;
}
return(_local2);
}
function compareDelegate(d_A, d_B) {
if ((d_A.thisObject != d_B.thisObject) || (d_A.thatObject != d_B.thatObject)) {
return(false);
}
return(true);
}
function addEventListener(event, thisObject, thatObject) {
removeEventListener(event, thisObject, thatObject);
eventTable[event].push(buildDelegate(thisObject, thatObject));
}
function removeEventListener(event, thisObject, thatObject) {
var _local3 = buildDelegate(thisObject, thatObject);
if (eventTable[event] == undefined) {
eventTable[event] = [];
return(undefined);
}
for (var _local4 in eventTable[event]) {
if (!compareDelegate(eventTable[event][_local4], _local3)) {
continue;
}
eventTable[event].splice(Number(_local4), 1);
}
}
function triggerEvent(event, args) {
if (eventTable[event] == undefined) {
return(undefined);
}
for (var _local4 in eventTable[event]) {
eventTable[event][_local4].delegate(args);
}
}
}
Symbol 343 MovieClip [__Packages.mochi.as2.MochiEvents] Frame 0
class mochi.as2.MochiEvents
{
static var gameStart, levelStart;
function MochiEvents () {
}
static function getVersion() {
return(mochi.as2.MochiServices.getVersion());
}
static function startSession(achievementID) {
mochi.as2.MochiServices.send("events_beginSession", {achievementID:achievementID}, null, null);
}
static function trigger(kind, obj) {
if (obj == undefined) {
obj = {};
} else if (obj.kind != undefined) {
trace("WARNING: optional arguements package contains key 'id', it will be overwritten");
obj.kind = kind;
}
mochi.as2.MochiServices.send("events_triggerEvent", {eventObject:obj}, null, null);
}
static function setNotifications(clip, style) {
var _local2 = {};
for (var _local3 in style) {
_local2[_local3] = style[_local3];
}
_local2.clip = clip;
mochi.as2.MochiServices.send("events_setNotifications", _local2, null, null);
}
static function addEventListener(eventType, thisObject, thatObject) {
_dispatcher.addEventListener(eventType, thisObject, thatObject);
}
static function triggerEvent(eventType, args) {
_dispatcher.triggerEvent(eventType, args);
}
static function removeEventListener(eventType, thisObject, thatObject) {
_dispatcher.removeEventListener(eventType, thisObject, thatObject);
}
static function startGame() {
gameStart = new Date().getTime();
trigger("start_game");
}
static function endGame() {
var _local1 = new Date().getTime() - gameStart;
trigger("end_game", {time:_local1});
}
static function startLevel() {
levelStart = new Date().getTime();
trigger("start_level");
}
static function endLevel() {
var _local1 = new Date().getTime() - levelStart;
trigger("end_level", {time:_local1});
}
static var ACHIEVEMENT_RECEIVED = "AchievementReceived";
static var ALIGN_TOP_LEFT = "ALIGN_TL";
static var ALIGN_TOP = "ALIGN_T";
static var ALIGN_TOP_RIGHT = "ALIGN_TR";
static var ALIGN_LEFT = "ALIGN_L";
static var ALIGN_CENTER = "ALIGN_C";
static var ALIGN_RIGHT = "ALIGN_R";
static var ALIGN_BOTTOM_LEFT = "ALIGN_BL";
static var ALIGN_BOTTOM = "ALIGN_B";
static var ALIGN_BOTTOM_RIGHT = "ALIGN_BR";
static var FORMAT_SHORT = "ShortForm";
static var FORMAT_LONG = "LongForm";
static var _dispatcher = new mochi.as2.MochiEventDispatcher();
}
Symbol 344 MovieClip [__Packages.mochi.as2.MochiSocial] Frame 0
class mochi.as2.MochiSocial
{
function MochiSocial () {
}
static function getVersion() {
return(mochi.as2.MochiServices.getVersion());
}
static function showLoginWidget(options) {
mochi.as2.MochiServices.setContainer();
mochi.as2.MochiServices.stayOnTop();
mochi.as2.MochiServices.send("coins_showLoginWidget", {options:options});
}
static function hideLoginWidget() {
mochi.as2.MochiServices.send("coins_hideLoginWidget");
}
static function requestLogin() {
mochi.as2.MochiServices.send("coins_requestLogin");
}
static function getUserInfo() {
mochi.as2.MochiServices.send("coins_getUserInfo");
}
static function saveUserProperties(properties) {
mochi.as2.MochiServices.send("coins_saveUserProperties", properties);
}
static function addEventListener(eventType, delegate) {
_dispatcher.addEventListener(eventType, delegate);
}
static function triggerEvent(eventType, args) {
_dispatcher.triggerEvent(eventType, args);
}
static function removeEventListener(eventType, delegate) {
_dispatcher.removeEventListener(eventType, delegate);
}
static var LOGGED_IN = "LoggedIn";
static var LOGGED_OUT = "LoggedOut";
static var LOGIN_SHOW = "LoginShow";
static var LOGIN_HIDE = "LoginHide";
static var LOGIN_SHOWN = "LoginShown";
static var PROFILE_SHOW = "ProfileShow";
static var PROFILE_HIDE = "ProfileHide";
static var PROPERTIES_SAVED = "PropertySaved";
static var WIDGET_LOADED = "WidgetLoaded";
static var USER_INFO = "UserInfo";
static var ERROR = "Error";
static var IO_ERROR = "IOError";
static var NO_USER = "NoUser";
static var PROPERTIES_SIZE = "PropertiesSize";
static var _dispatcher = new mochi.as2.MochiEventDispatcher();
}
Symbol 345 MovieClip [__Packages.mochi.as2.MochiScores] Frame 0
class mochi.as2.MochiScores
{
static var boardID, onClose, onError;
function MochiScores () {
}
static function setBoardID(boardID) {
mochi.as2.MochiServices.warnID(boardID, true);
mochi.as2.MochiScores.boardID = boardID;
mochi.as2.MochiServices.send("scores_setBoardID", {boardID:boardID});
}
static function showLeaderboard(options) {
options.clip = mochi.as2.MochiServices.clip;
if ((options.clip != mochi.as2.MochiServices.__get__clip()) || (mochi.as2.MochiServices.__get__childClip()._target == undefined)) {
mochi.as2.MochiServices.disconnect();
trace("WARNING! This application is attempting to connect to MochiServices inside a showLeaderboard call!");
trace("make sure MochiServices.connect is called as early in the application runtime as possible.");
mochi.as2.MochiServices.connect(mochi.as2.MochiServices.__get__id(), options.clip);
}
delete options.clip;
if (options.name != null) {
if (typeof(options.name) == "object") {
if (options.name.text != undefined) {
options.name = options.name.text;
}
}
}
if (options.score != null) {
if (options.score instanceof TextField) {
if (options.score.text != undefined) {
options.score = options.score.text;
}
} else if (options.score instanceof mochi.as2.MochiDigits) {
options.score = options.score.value;
}
var _local1 = Number(options.score);
if (isNaN(_local1)) {
trace(("ERROR: Submitted score '" + options.score) + "' will be rejected, score is 'Not a Number'");
} else if ((_local1 == Number.NEGATIVE_INFINITY) || (_local1 == Number.POSITIVE_INFINITY)) {
trace(("ERROR: Submitted score '" + options.score) + "' will be rejected, score is an infinite");
} else {
if (Math.floor(_local1) != _local1) {
trace(("WARNING: Submitted score '" + options.score) + "' will be truncated");
}
options.score = _local1;
}
}
if (options.onDisplay != null) {
options.onDisplay();
} else {
mochi.as2.MochiServices.__get__clip().stop();
}
if (options.onClose != null) {
onClose = options.onClose;
} else {
onClose = function () {
mochi.as2.MochiServices.__get__clip().play();
};
}
if (options.onError != null) {
onError = options.onError;
} else {
onError = onClose;
}
if (options.boardID == null) {
if (boardID != null) {
options.boardID = boardID;
}
}
mochi.as2.MochiServices.warnID(options.boardID, true);
trace("[MochiScores] NOTE: Security Sandbox Violation errors below are normal");
mochi.as2.MochiServices.send("scores_showLeaderboard", {options:options}, null, doClose);
}
static function closeLeaderboard() {
mochi.as2.MochiServices.send("scores_closeLeaderboard");
}
static function getPlayerInfo(callbackObj, callbackMethod) {
mochi.as2.MochiServices.send("scores_getPlayerInfo", null, callbackObj, callbackMethod);
}
static function submit(score, name, callbackObj, callbackMethod) {
score = Number(score);
if (isNaN(score)) {
trace(("ERROR: Submitted score '" + String(score)) + "' will be rejected, score is 'Not a Number'");
} else if ((score == Number.NEGATIVE_INFINITY) || (score == Number.POSITIVE_INFINITY)) {
trace(("ERROR: Submitted score '" + String(score)) + "' will be rejected, score is an infinite");
} else {
if (Math.floor(score) != score) {
trace(("WARNING: Submitted score '" + String(score)) + "' will be truncated");
}
score = Number(score);
}
mochi.as2.MochiServices.send("scores_submit", {score:score, name:name}, callbackObj, callbackMethod);
}
static function requestList(callbackObj, callbackMethod) {
mochi.as2.MochiServices.send("scores_requestList", null, callbackObj, callbackMethod);
}
static function scoresArrayToObjects(scores) {
var _local5 = {};
var _local1;
var _local4;
var _local2;
var _local6;
for (var _local8 in scores) {
if (typeof(scores[_local8]) == "object") {
if ((scores[_local8].cols != null) && (scores[_local8].rows != null)) {
_local5[_local8] = [];
_local2 = scores[_local8];
_local4 = 0;
while (_local4 < _local2.rows.length) {
_local6 = {};
_local1 = 0;
while (_local1 < _local2.cols.length) {
_local6[_local2.cols[_local1]] = _local2.rows[_local4][_local1];
_local1++;
}
_local5[_local8].push(_local6);
_local4++;
}
} else {
_local5[_local8] = {};
for (var _local7 in scores[_local8]) {
_local5[_local8][_local7] = scores[_local8][_local7];
}
}
} else {
_local5[_local8] = scores[_local8];
}
}
return(_local5);
}
static function doClose(args) {
if (args.error == true) {
if (args.errorCode == undefined) {
args.errorCode = "IOError";
}
onError.apply(null, [args.errorCode]);
} else {
onClose.apply();
}
}
}
Symbol 346 MovieClip [__Packages.mochi.as2.MochiDigits] Frame 0
class mochi.as2.MochiDigits
{
var Encoder, Fragment, Sibling;
function MochiDigits (digit, index) {
Encoder = 0;
setValue(digit, index);
}
function get value() {
return(Number(toString()));
}
function set value(v) {
setValue(v);
//return(value);
}
function addValue(v) {
value = value + v;
}
function setValue(digit, index) {
var _local3 = digit.toString();
if ((index == undefined) || (isNaN(index))) {
index = 0;
}
Fragment = _local3.charCodeAt(index++) ^ Encoder;
if (index < _local3.length) {
Sibling = new mochi.as2.MochiDigits(digit, index);
} else {
Sibling = null;
}
reencode();
}
function reencode() {
var _local2 = int(2147483647 * Math.random());
Fragment = Fragment ^ (_local2 ^ Encoder);
Encoder = _local2;
}
function toString() {
var _local2 = String.fromCharCode(Fragment ^ Encoder);
return(((Sibling != null) ? (_local2.concat(Sibling.toString())) : (_local2)));
}
}
Symbol 90 MovieClip Frame 1
stop();
Symbol 92 MovieClip Frame 1
function randTime() {
fN = Math.round(Math.random() * 4) + 2;
}
function onEnterFrame() {
fP++;
randTime();
if (fP >= fN) {
fP = 0;
myFrame = Math.round((Math.random() * 6) + 1);
gotoAndStop(myFrame);
}
}
stop();
fP = 0;
randTime();
Symbol 96 MovieClip [bot] Frame 1
function onEnterFrame() {
if (yS != 0) {
cJ = false;
}
if (cJA) {
cJ = true;
}
if (Key.isDown(82) && (!rP)) {
rP = true;
d = true;
}
if ((!d) && (r._currentframe != 4)) {
if (((Key.isDown(65) || (Key.isDown(37))) || (Key.isDown(39))) || (Key.isDown(68))) {
if (Key.isDown(65) || (Key.isDown(37))) {
xS = xS - xA;
_xscale = (-xSc);
}
if (Key.isDown(68) || (Key.isDown(39))) {
xS = xS + xA;
_xscale = xSc;
}
}
if (((Key.isDown(87) || (Key.isDown(38))) && (!jD)) && (cJ)) {
cJ = false;
cJA = false;
yS = jP;
jD = true;
fO = false;
r.playSound("j", 2);
} else if (((((((Key.isDown(87) || (Key.isDown(38))) && (fu > 0)) && (g >= 0)) && (!cJ)) && (cF)) && (yS > -20)) && ((!jD) || (fO))) {
g = 0;
yS = 0;
jD = true;
fO = true;
fi._visible = true;
fu--;
r.playSound("f", 1);
} else {
fi._visible = false;
if (g >= 0) {
g = 1.2;
}
}
}
if (!(Key.isDown(87) || (Key.isDown(38)))) {
jD = false;
}
if (yS > tY) {
yS = tY;
}
if (Math.abs(xS) < 0.1) {
xS = 0;
}
if (!d) {
xS = xS * f;
} else {
g = 1.2;
}
if ((yS < 0) && (g >= 0)) {
g = 1.2;
}
yS = yS + g;
_x = (_x + xS);
_y = (_y + yS);
if ((!d) && (g >= 0)) {
r.keepUp();
}
if (_alpha < 100) {
_alpha = (_alpha + 2);
}
if ((_y > 400) && (g >= 0)) {
if (!d) {
r.playSound("h", 3);
d = true;
yS = -20;
xS = xS * 0.75;
_y = 400;
r.he = 0;
} else if (d) {
i = 1;
while (i <= r.NoE) {
if (r["e" + i]._x != undefined) {
r["e" + i].removeMovieClip();
}
i++;
}
r.myDeaths++;
r.myScore = r.myScore - 500;
if (r.myScore < 0) {
r.myScore = 0;
}
r.saveGame();
r.lev.prevFrame();
r.lev.nextFrame();
this.removeMovieClip();
}
}
if (d) {
_rotation = (_rotation + xS);
fi._visible = false;
}
if (g < 0) {
if (r.lev._alpha == 100) {
gs.TweenLite.to(r.lev, 1, {_alpha:0});
}
if ((r.lev._alpha == 0) && (r.b._x == undefined)) {
r.myScore = r.myScore + ((500 + (r.he * 50)) + (r.myLev * 50));
if ((r.myLev % 5) == 0) {
r.attachMovie("b", "b", r.getNextHighestDepth(), {_x:r.vc._x, _y:200});
} else {
r.lev.nextFrame();
r.myLev++;
r.saveGame();
gs.TweenLite.to(r.lev, 1, {_alpha:100});
r.c.removeMovieClip();
}
}
} else if ((!d) && (g >= 0)) {
hit = r.CD(r.lev.eP, this);
if (hit) {
r.playSound("s", 1);
g = -1.2;
}
}
if ((_x < hW) && (!d)) {
_x = hW;
xS = 0;
}
r.vc.upDate();
}
_alpha = 0;
gs.TweenLite.to(this, 1, {_alpha:100});
jP = -15;
f = 0.9;
xA = 1.2;
g = 1.2;
fu = 20;
mF = fu;
th = 1.5;
rP = false;
xSc = _xscale;
hW = (b._width / 2) + 2;
hH = (b._height / 2) + 2;
xS = 0;
yS = 0.1;
d = false;
fP = 4;
jD = false;
fO = false;
cJ = true;
cJA = false;
cF = false;
tY = 14;
r = _root;
sP = false;
fi._visible = false;
fi.hW = fi._width / 2;
fi.hH = fi._height / 2;
Symbol 101 MovieClip [afur] Frame 1
function onEnterFrame() {
if (!d) {
if (r.c._x < _x) {
xS = xS - xA;
} else if (r.c._x > _x) {
xS = xS + xA;
}
if (xS > mX) {
xS = mX;
} else if (xS < (-mX)) {
xS = -mX;
}
}
if (r.c._x == undefined) {
_x = sX;
_y = sY;
}
if (r.lev._alpha == 0) {
this.removeMovieClip();
}
if (!d) {
i = -hH;
while (i < hH) {
if (r.lev.gr.hitTest(_x - hW, _y + i, true) && (xS < 0)) {
xS = xS * -1;
while (r.lev.gr.hitTest(_x - hW, _y + i, true)) {
_x = (_x + 0.1);
}
} else if (r.lev.gr.hitTest(_x + hW, _y + i, true) && (xS > 0)) {
xS = xS * -1;
while (r.lev.gr.hitTest(_x + hW, _y + i, true)) {
_x = (_x - 0.1);
}
}
i = i + hH;
}
i = -hW;
while (i < hW) {
if (r.lev.gr.hitTest(_x + i, _y + hH, true) && (yS > 0)) {
yS = 0;
while (r.lev.gr.hitTest(_x + i, _y + hH, true)) {
_y = (_y - 0.1);
}
}
i = i + (hW / 2);
}
}
if (yS > tY) {
yS = tY;
}
yS = yS + g;
_x = (_x + xS);
_y = (_y + yS);
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if (((((hit && (r.c._alpha >= 100)) && (r.c.yS < 2)) && (!d)) && (!r.c.d)) && (r.c.g > 0)) {
r.he--;
r.c.xS = xS * 3;
r.c._alpha = 70;
r.playSound("h", 3);
if (r.he <= 0) {
r.c.d = true;
}
} else if ((hit && (r.c.yS >= 2)) && (!r.c.d)) {
r.c.yS = bP;
d = true;
r.playSound("j", 2);
}
}
if (d) {
_rotation = (_rotation + xS);
}
if (_y > 400) {
r.myScore = r.myScore + 100;
this.removeMovieClip();
}
i = 1;
while (i <= r.NoE) {
if (((r["e" + i]._x != undefined) && (r["e" + i]._x != _x)) && (this.hitTest(r["e" + i]))) {
hit = r.CD(this, r["e" + i]);
if (hit && (d)) {
r["e" + i].d = true;
r.playSound("h", 3);
}
}
i++;
}
}
xS = 0;
xA = 0.4;
mX = 10;
sS = xS;
yS = 0;
d = false;
g = 1.2;
hH = (_height / 2) + 2;
hW = (_width / 2) + 3;
r = _root;
bP = -16;
sX = _x;
sY = _y;
tY = 14;
_alpha = 0;
gs.TweenLite.to(this, 0.5, {_alpha:100});
Symbol 105 MovieClip [bat] Frame 1
function onEnterFrame() {
if (r.c._x == undefined) {
_x = sX;
_y = sY;
}
if (r.lev._alpha == 0) {
this.removeMovieClip();
}
if (_x <= (r.vc._x - (r.sW / 2))) {
xS = sS;
}
if (!d) {
i = -hH;
while (i < hH) {
if (r.lev.gr.hitTest(_x - hW, _y + i, true) && (xS < 0)) {
xS = sS;
while (r.lev.gr.hitTest(_x - hW, _y + i, true)) {
_x = (_x + 0.1);
}
} else if (r.lev.gr.hitTest(_x + hW, _y + i, true) && (xS > 0)) {
xS = -sS;
while (r.lev.gr.hitTest(_x + hW, _y + i, true)) {
_x = (_x - 0.1);
}
}
i = i + hH;
}
}
_x = (_x + xS);
_y = (_y + yS);
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((((hit && (r.c._alpha >= 100)) && (r.c.yS < 2)) && (!d)) && (!r.c.d)) {
r.he--;
r.c._alpha = 70;
if (Math.abs(r.c.xS) > Math.abs(xS)) {
r.c.xS = (-xS) * 4;
r.c._x = r.c._x + (r.c.xS * 2);
} else {
r.c.xS = xS * 4;
r.c._x = r.c._x + (r.c.xS * 2);
}
r.playSound("h", 3);
if (r.he <= 0) {
r.c.d = true;
}
} else if ((hit && (r.c.yS >= 2)) && (!r.c.d)) {
r.c.yS = bP;
r.c.cF = true;
d = true;
r.playSound("j", 2);
}
}
if (d) {
_rotation = (_rotation + xS);
yS = yS + g;
}
if (_y > 400) {
r.myScore = r.myScore + 25;
this.removeMovieClip();
}
i = 1;
while (i <= r.NoE) {
if ((r["e" + i]._x != undefined) && (r["e" + i]._x != _x)) {
hit = r.CD(this, r["e" + i]);
if ((hit && (!r["e" + i].d)) && (!d)) {
xS = xS * -1;
r["e" + i].xS = r["e" + i].xS * -1;
r["e" + i]._x = r["e" + i]._x - (xS * 3);
_x = (_x + (xS * 3));
} else if (hit && (d)) {
r["e" + i].d = true;
r.playSound("h", 3);
}
}
i++;
}
}
xS = 3;
sS = xS;
yS = 0;
d = false;
g = 1.4;
hH = (_height / 2) + 2;
hW = 30;
r = _root;
bP = -20;
sX = _x;
sY = _y;
_alpha = 0;
gs.TweenLite.to(this, 0.5, {_alpha:100});
Symbol 107 MovieClip [bu] Frame 1
function onEnterFrame() {
if (r.lev._alpha == 0) {
this.removeMovieClip();
}
if (d) {
_name = yS;
_rotation = (_rotation + xS);
yS = yS + g;
_y = (_y + yS);
} else {
_name = "bu";
}
_x = (_x + xS);
if (Math.abs(_x - r.c._x) < 50) {
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (!r.c.d)) && (r.c.g >= 0)) {
r.c.d = true;
r.he = 0;
r.playSound("h", 3);
}
}
}
if ((((_y > 400) || (_x < 0)) && (!myDad.d)) && (myDad._x != undefined)) {
r.playSound("c", 1);
xS = -10;
yS = 0;
_x = sX;
_y = sY;
d = false;
_rotation = 0;
}
}
xS = -10;
bP = -20;
yS = 0;
g = 1.4;
d = false;
hH = (_height / 2) + 2;
hW = (_width / 2) + 3;
r = _root;
sX = _x;
sY = _y;
Symbol 109 MovieClip [can] Frame 1
function spawnMe() {
r.playSound("c", 1);
r.attachMovie("bu", "e" + myNum, r.getNextHighestDepth(), {_x:_x - (hW * 2), _y:_y});
r["e" + myNum].myDad = this;
}
function onEnterFrame() {
if (r.lev._alpha == 0) {
this.removeMovieClip();
}
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((((hit && (r.c._alpha >= 100)) && (r.c.yS < 2)) && (!d)) && (!r.c.d)) {
r.he--;
r.c.xS = r.c.xS * -3;
r.c._alpha = 50;
r.playSound("h", 3);
if (r.he <= 0) {
r.c.d = true;
}
} else if ((hit && (r.c.yS >= 2)) && (!r.c.d)) {
r.c.yS = bP;
d = true;
r.myScore = r.myScore + 75;
r.playSound("j", 2);
}
}
if (d) {
yS = yS + g;
_y = (_y + yS);
}
}
r = _root;
r.NoE++;
myNum = r.NoE;
hW = _width / 2;
hH = _height / 2;
yS = 0;
g = 1.4;
d = false;
bP = -20;
spawnMe();
Symbol 110 MovieClip [fur] Frame 1
function onEnterFrame() {
if (r.c._x == undefined) {
_x = sX;
_y = sY;
}
if (r.lev._alpha == 0) {
this.removeMovieClip();
}
if (!d) {
i = -hH;
while (i < hH) {
if (r.lev.gr.hitTest(_x - hW, _y + i, true) && (xS < 0)) {
xS = sS;
while (r.lev.gr.hitTest(_x - hW, _y + i, true)) {
_x = (_x + 0.1);
}
} else if (r.lev.gr.hitTest(_x + hW, _y + i, true) && (xS > 0)) {
xS = -sS;
while (r.lev.gr.hitTest(_x + hW, _y + i, true)) {
_x = (_x - 0.1);
}
}
i = i + hH;
}
i = -hW;
while (i < hW) {
if (r.lev.gr.hitTest(_x + i, _y + hH, true) && (yS > 0)) {
yS = 0;
while (r.lev.gr.hitTest(_x + i, _y + hH, true)) {
_y = (_y - 0.1);
}
}
i = i + (hW / 2);
}
}
yS = yS + g;
_x = (_x + xS);
_y = (_y + yS);
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((((hit && (r.c._alpha >= 100)) && (r.c.yS < 2)) && (!d)) && (!r.c.d)) {
r.he--;
r.c.xS = xS * 3;
r.c._alpha = 70;
r.playSound("h", 3);
if (r.he <= 0) {
r.c.d = true;
}
} else if ((hit && (r.c.yS >= 2)) && (!r.c.d)) {
r.c.yS = bP;
d = true;
r.playSound("j", 2);
}
}
if (d) {
_rotation = (_rotation + xS);
}
if (_y > 400) {
r.myScore = r.myScore + 25;
this.removeMovieClip();
}
i = 1;
while (i <= r.NoE) {
if (((r["e" + i]._x != undefined) && (r["e" + i]._x != _x)) && (this.hitTest(r["e" + i]))) {
hit = r.CD(this, r["e" + i]);
if ((hit && (!r["e" + i].d)) && (!d)) {
xS = xS * -1;
r["e" + i].xS = r["e" + i].xS * -1;
r["e" + i]._x = r["e" + i]._x - (xS * 3);
_x = (_x + (xS * 3));
} else if (hit && (d)) {
r["e" + i].d = true;
r.playSound("h", 3);
}
}
i++;
}
}
xS = 4;
sS = xS;
yS = 0;
d = false;
g = 1.2;
hH = (_height / 2) + 2;
hW = (_width / 2) + 3;
r = _root;
bP = -16;
sX = _x;
sY = _y;
_alpha = 0;
gs.TweenLite.to(this, 0.5, {_alpha:100});
Symbol 118 MovieClip Frame 1
function onMouseDown() {
if (this.hitTest(r._xmouse, r._ymouse, true) && (r.b._x == undefined)) {
play();
}
}
r = _root;
stop();
Symbol 118 MovieClip Frame 2
stop();
Symbol 118 MovieClip Frame 3
stop();
Symbol 118 MovieClip Frame 4
stop();
Symbol 118 MovieClip Frame 5
stop();
Symbol 118 MovieClip Frame 6
stop();
Symbol 118 MovieClip Frame 7
stop();
Symbol 123 MovieClip Frame 1
function onEnterFrame() {
gotoAndStop(r.he);
if (r.he == 0) {
gotoAndStop (4);
}
}
stop();
r = _root;
Symbol 130 MovieClip Frame 1
function onEnterFrame() {
if (btn.hitTest(r._xmouse, r._ymouse, false)) {
btn.gotoAndStop(2);
} else {
btn.gotoAndStop(1);
}
}
function onMouseDown() {
if (btn.hitTest(r._xmouse, r._ymouse, false)) {
nextFrame();
}
}
stop();
stopAllSounds();
r = _root;
r.mute = false;
if (r.songToPlay == undefined) {
r.songToPlay = 1;
}
bgmusic = new Sound(this);
bgmusic.attachSound("gM" + r.songToPlay);
bgmusic.start(0, 9999);
Symbol 130 MovieClip Frame 2
function onEnterFrame() {
if (btn.hitTest(_root._xmouse, _root._ymouse, false)) {
btn.gotoAndStop(2);
} else {
btn.gotoAndStop(1);
}
}
function onMouseDown() {
if (btn.hitTest(_root._xmouse, _root._ymouse, false)) {
prevFrame();
}
}
stopAllSounds();
_root.mute = true;
Symbol 135 MovieClip Frame 1
_visible = false;
Symbol 139 MovieClip Frame 1
function upDate() {
if ((!r.c.d) && (r.c.g >= 0)) {
_x = r.c._x;
}
if (_x < (w / 2)) {
_x = (w / 2);
}
_parent.filters = this.filters;
var _local3 = reanimator.matrix;
camera.colorTransform = reanimator.colorTransform;
_local3.invert();
_local3.translate(w * 0.5, h * 0.5);
camera.matrix = _local3;
}
var reanimator = (new flash.geom.Transform(this));
var camera = (new flash.geom.Transform(this._parent));
var w = Stage.width;
var h = Stage.height;
r = _root;
ySc = _yscale;
xSc = _xscale;
Symbol 143 MovieClip Frame 1
r = _root;
hW = _width / 2;
hH = _height / 2;
Symbol 159 MovieClip Frame 1
function onEnterFrame() {
var _local2 = {x:0, y:0};
this.localToGlobal(_local2);
if (this.hitTest(r.c)) {
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (!r.c.d)) && (r.c.g >= 0)) {
r.c.d = true;
r.he = 0;
r.playSound("h", 3);
}
}
}
fP++;
if (fP >= fN) {
fP = 0;
fN = Math.round((Math.random() * 6) + 6);
myFrame = Math.round((Math.random() * 8) + 1);
gotoAndStop(myFrame);
}
}
r = _root;
fP = 0;
fN = Math.round((Math.random() * 6) + 6);
hW = _width / 2;
hH = _height / 2;
myFrame = Math.round((Math.random() * 8) + 1);
gotoAndStop(myFrame);
Symbol 163 MovieClip Frame 1
function spawnMe() {
r.attachMovie("fur", "e" + myNum, r.getNextHighestDepth(), {_x:spX, _y:spY});
}
function onEnterFrame() {
if ((r.c._x == undefined) && (r["e" + myNum]._x == undefined)) {
spawnMe();
}
}
r = _root;
_visible = false;
r.NoE++;
myNum = r.NoE;
var mP = {x:0, y:0};
this.localToGlobal(mP);
spX = (mP.x + r.vc._x) - (r.sW / 2);
spY = mP.y;
spawnMe();
Symbol 171 MovieClip Frame 1
function onEnterFrame() {
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (!r.c.d)) && (_alpha == 100)) {
r.c.d = true;
r.playSound("h", 3);
} else if (sA) {
_alpha = 100;
}
}
sA = false;
i = 1;
while (i <= r.NoE) {
if (r["e" + i]._x != undefined) {
sA = true;
}
i++;
}
if (!sA) {
gs.TweenLite.to(this, 0.25, {_alpha:0});
}
}
r = _root;
hW = _width / 2;
hH = _height / 2;
Symbol 181 MovieClip Frame 1
function onEnterFrame() {
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (!r.c.d)) && (r.c.g >= 0)) {
r.c.mF = iBoost;
r.c.fu = r.c.mF;
}
}
}
r = _root;
hW = _width / 2;
hH = _height / 2;
Symbol 196 MovieClip Frame 1
function spawnMe() {
r.attachMovie("afur", "e" + myNum, r.getNextHighestDepth(), {_x:spX, _y:spY});
}
function onEnterFrame() {
if ((r.c._x == undefined) && (r["e" + myNum]._x == undefined)) {
spawnMe();
}
}
r = _root;
_visible = false;
r.NoE++;
myNum = r.NoE;
var mP = {x:0, y:0};
this.localToGlobal(mP);
spX = (mP.x + r.vc._x) - (r.sW / 2);
spY = mP.y;
spawnMe();
Symbol 208 MovieClip Frame 1
function onEnterFrame() {
if ((fP >= fN) && (yS == 0)) {
fP = 0;
yS = jP;
}
yS = yS + g;
if (yS > tY) {
yS = tY;
}
_y = (_y + yS);
i = -hW;
while (i < hW) {
if (r.lev.gr.hitTest(_x + i, _y + hH, true) && (yS > 0)) {
yS = 0;
fP++;
while (r.lev.gr.hitTest(_x + i, _y + hH, true)) {
_y = (_y - 0.1);
}
}
i = i + (hW / 2);
}
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (!r.c.d)) && (r.c.g >= 0)) {
r.c.d = true;
r.he = 0;
r.playSound("h", 3);
}
} else {
fP = 0;
}
}
r = _root;
yS = 0;
jP = -22;
g = 1.8;
tY = 14;
fP = 0;
fN = 20;
hW = _width / 2;
hH = _height / 2;
Symbol 214 MovieClip Frame 1
function spawnMe() {
r.attachMovie("bat", "e" + myNum, r.getNextHighestDepth(), {_x:spX, _y:spY});
}
function onEnterFrame() {
if ((r.c._x == undefined) && (r["e" + myNum]._x == undefined)) {
spawnMe();
}
}
r = _root;
_visible = false;
r.NoE++;
myNum = r.NoE;
var mP = {x:0, y:0};
this.localToGlobal(mP);
spX = (mP.x + r.vc._x) - (r.sW / 2);
spY = mP.y;
spawnMe();
Symbol 217 MovieClip Frame 1
function onEnterFrame() {
if ((((_alpha == 0) && (r.c.cJ)) && (r.c.yS == 0)) || (r.c._x == undefined)) {
gs.TweenLite.to(this, 0.5, {_alpha:100});
}
if (r.c._x != undefined) {
if ((this.hitTest(r.c) && (_alpha == 100)) && (!r.c.d)) {
r.playSound("p", 3);
gs.TweenLite.to(this, 0.5, {_alpha:0});
r.c.cJ = true;
r.c.cJA = true;
r.c.jD = false;
}
}
}
r = _root;
hW = _width / 2;
hH = _height / 2;
Symbol 226 MovieClip Frame 1
function onEnterFrame() {
if (r.c._x == undefined) {
_x = sX;
_y = sY;
}
if (r.lev._alpha == 0) {
this.removeMovieClip();
}
if (!d) {
yS = yS + g;
}
_x = (_x + xS);
_y = (_y + yS);
i = -hH;
while (i < hH) {
if (r.lev.gr.hitTest(_x - hW, _y + i, true) && (xS < 0)) {
xS = sS;
while (r.lev.gr.hitTest(_x - hW, _y + i, true)) {
_x = (_x + 0.1);
}
} else if (r.lev.gr.hitTest(_x + hW, _y + i, true) && (xS > 0)) {
xS = -sS;
while (r.lev.gr.hitTest(_x + hW, _y + i, true)) {
_x = (_x - 0.1);
}
}
i = i + hH;
}
i = -hW;
while (i < hW) {
if (r.lev.gr.hitTest(_x + i, _y + hH, true) && (yS > 0)) {
yS = 0;
while (r.lev.gr.hitTest(_x + i, _y + hH, true)) {
_y = (_y - 0.1);
}
}
i = i + (hW / 2);
}
if (this.hitTest(r.c)) {
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (!r.c.d)) && (r.c.g >= 0)) {
r.c.d = true;
r.he = 0;
r.playSound("h", 3);
}
}
}
if (r.bu._x != undefined) {
if (this.hitTest(r.bu) && (!r.bu.d)) {
r.bu.d = true;
tempX = xS;
xS = r.bu.xS / 2;
r.bu.xS = tempX / 2;
r.playSound("h", 3);
}
}
}
xS = 4;
sS = xS;
yS = 0;
g = 1.2;
hH = (_height / 2) + 2;
hW = (_width / 2) + 3;
r = _root;
sX = _x;
sY = _y;
_alpha = 0;
gs.TweenLite.to(this, 0.5, {_alpha:100});
Symbol 227 MovieClip Frame 1
function spawnMe() {
r.attachMovie("can", "e" + myNum, r.getNextHighestDepth(), {_x:spX, _y:spY});
}
function onEnterFrame() {
if ((r.c._x == undefined) && (r["e" + myNum]._x == undefined)) {
spawnMe();
}
}
r = _root;
_visible = false;
r.NoE++;
myNum = r.NoE;
var mP = {x:0, y:0};
this.localToGlobal(mP);
spX = (mP.x + r.vc._x) - (r.sW / 2);
spY = mP.y;
spawnMe();
Symbol 243 MovieClip Frame 1
function onEnterFrame() {
if (r.c._x == undefined) {
_x = sX;
_y = sY;
}
if (r.lev._alpha == 0) {
this.removeMovieClip();
}
if (!d) {
i = -hH;
while (i < hH) {
if (r.lev.gr.hitTest(_x - hW, _y + i, true) && (xS < 0)) {
xS = sS;
while (r.lev.gr.hitTest(_x - hW, _y + i, true)) {
_x = (_x + 0.1);
}
} else if (r.lev.gr.hitTest(_x + hW, _y + i, true) && (xS > 0)) {
xS = -sS;
while (r.lev.gr.hitTest(_x + hW, _y + i, true)) {
_x = (_x - 0.1);
}
}
i = i + hH;
}
}
_x = (_x + xS);
if (this.hitTest(r.c)) {
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (!r.c.d)) && (r.c.g >= 0)) {
r.c.d = true;
r.he = 0;
r.playSound("h", 3);
}
}
}
}
xS = 4;
sS = xS;
hH = (_height / 2) + 2;
hW = (_width / 2) + 3;
r = _root;
sX = _x;
sY = _y;
_alpha = 0;
gs.TweenLite.to(this, 0.5, {_alpha:100});
Symbol 249 MovieClip Frame 1
function onEnterFrame() {
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if (hit && (!r.c.d)) {
r.c.yS = bP;
r.c.cF = true;
r.playSound("j", 2);
if (r.he <= 0) {
r.c.d = true;
}
}
}
i = 1;
while (i <= 3) {
if (r.lev["sp" + i]._x != undefined) {
if (this.hitTest(r.lev["sp" + i]) && (r.lev["sp" + i].yS >= 0)) {
r.lev["sp" + i].yS = bP * 1.1;
}
}
i++;
}
}
hH = (_height / 2) + 2;
hW = (_width / 2) + 3;
r = _root;
bP = -26;
Symbol 268 MovieClip Frame 1
function onEnterFrame() {
if ((fP >= fN) && (yS == 0)) {
fP = 0;
yS = jP;
}
yS = yS + g;
if (yS > tY) {
yS = tY;
}
_y = (_y + yS);
i = -hW;
while (i < hW) {
if (r.lev.gr.hitTest(_x + i, _y + hH, true) && (yS > 0)) {
yS = 0;
fP++;
while (r.lev.gr.hitTest(_x + i, _y + hH, true)) {
_y = (_y - 0.1);
}
}
i = i + (hW / 2);
}
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (!r.c.d)) && (r.c.g >= 0)) {
r.c.d = true;
r.he = 0;
r.playSound("h", 3);
}
} else {
fP = 0;
}
}
r = _root;
yS = 0;
jP = -22;
g = 1.8;
tY = 14;
fP = 0;
fN = 20;
hW = _width / 2;
hH = _height / 2;
Symbol 277 MovieClip Frame 1
function onEnterFrame() {
if (this.hitTest(r.c)) {
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (!r.c.d)) && (r.c.g >= 0)) {
r.c.d = true;
r.he = 0;
r.playSound("h", 3);
}
}
}
}
r = _root;
hW = _width / 2;
hH = _height / 2;
Symbol 280 MovieClip Frame 1
function onEnterFrame() {
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if (hit && (!r.c.d)) {
r.c.yS = bP;
r.c.cF = true;
r.playSound("j", 2);
if (r.he <= 0) {
r.c.d = true;
}
}
}
i = 1;
while (i <= 3) {
if (r.lev["sp" + i]._x != undefined) {
if (this.hitTest(r.lev["sp" + i]) && (r.lev["sp" + i].yS >= 0)) {
r.lev["sp" + i].yS = bP * 1.25;
}
}
i++;
}
}
hH = (_height / 2) + 2;
hW = (_width / 2) + 3;
r = _root;
bP = -26;
Symbol 295 MovieClip Frame 1
function onEnterFrame() {
tP++;
if (_alpha > 0) {
_alpha = (100 - Math.round((tP / tN) * 100));
} else if (_alpha < 0) {
_alpha = 0;
}
if (_alpha <= 0) {
nextFrame();
}
if (r.c._x == undefined) {
_alpha = 100;
tP = 0;
}
}
stop();
tP = 0;
tN = 160;
r = _root;
Symbol 295 MovieClip Frame 2
function onEnterFrame() {
if (r.c._x == undefined) {
prevFrame();
}
}
Symbol 299 MovieClip Frame 1
function onEnterFrame() {
if (r.c._x < _x) {
xS = xS - xA;
} else if (r.c._x > _x) {
xS = xS + xA;
}
if (xS > mX) {
xS = mX;
} else if (xS < (-mX)) {
xS = -mX;
}
if (r.c._x > _x) {
_xscale = (-xSc);
} else if (r.c._x < _x) {
_xscale = xSc;
}
if (r.c._y > _y) {
yS = yS + yA;
} else if (r.c._y < _y) {
yS = yS - yA;
}
if (r.c._x == undefined) {
_x = sX;
_y = sY;
yS = 0;
xS = 0;
}
_x = (_x + xS);
_y = (_y + yS);
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (!r.c.d)) && (r.c.g >= 0)) {
r.c.d = true;
r.he = 0;
r.playSound("h", 3);
}
}
}
xS = 0;
yS = 0;
yA = 0.3;
xA = 1;
mX = 18;
xSc = _xscale;
hH = (_height / 2) + 2;
hW = (_width / 2) + 3;
r = _root;
bP = -16;
sX = _x;
sY = _y;
_alpha = 0;
gs.TweenLite.to(this, 0.5, {_alpha:60});
Symbol 310 MovieClip Frame 1
function onEnterFrame() {
if (this.hitTest(r.c)) {
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (!r.c.d)) && (r.c.g >= 0)) {
r.c.d = true;
r.he = 0;
r.playSound("h", 3);
}
}
}
}
r = _root;
Symbol 311 MovieClip Frame 1
function onEnterFrame() {
if (r.c._x == undefined) {
_x = sX;
_y = sY;
xS = sS;
}
if (r.lev._alpha == 0) {
this.removeMovieClip();
}
if (!d) {
i = -hH;
while (i < hH) {
if (r.lev.gr.hitTest(_x - hW, _y + i, true) && (xS < 0)) {
xS = sS;
while (r.lev.gr.hitTest(_x - hW, _y + i, true)) {
_x = (_x + 0.1);
}
} else if (r.lev.gr.hitTest(_x + hW, _y + i, true) && (xS > 0)) {
xS = -sS;
while (r.lev.gr.hitTest(_x + hW, _y + i, true)) {
_x = (_x - 0.1);
}
}
i = i + hH;
}
i = -hW;
while (i < hW) {
if (r.lev.gr.hitTest(_x + i, _y + hH, true) && (yS > 0)) {
yS = 0;
while (r.lev.gr.hitTest(_x + i, _y + hH, true)) {
_y = (_y - 0.1);
}
}
i = i + (hW / 2);
}
}
if (_y < 450) {
yS = yS + g;
}
_x = (_x + xS);
_y = (_y + yS);
if (r.c._x != undefined) {
hit = r.CD(this, r.c);
if ((hit && (r.c.yS > 0)) && (!r.c.d)) {
r.c.yS = 0;
r.c.cJ = true;
r.c.cF = true;
r.c.fu = r.c.mF;
r.c.xS = xS * 1.12;
while (hit) {
r.c._y = r.c._y - 0.1;
hit = r.CD(this, r.c);
}
}
} else {
xS = sS;
}
if (r.lev.bow._x != undefined) {
if (this.hitTest(r.lev.bow) && (!r.lev.bow.d)) {
r.lev.bow.xS = 10;
r.lev.bow.d = true;
r.playSound("h", 3);
}
}
}
xS = 4;
sS = xS;
yS = 0;
g = 1.2;
hH = (_height / 2) + 2;
hW = (b._width / 2) + 3;
r = _root;
sS = xS;
sX = _x;
sY = _y;
_alpha = 0;
gs.TweenLite.to(this, 0.5, {_alpha:100});
Symbol 326 MovieClip Frame 2
stop();
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 8
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 12
onClipEvent (load) {
iBoost = 60;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 13
onClipEvent (load) {
iBoost = 0;
}
Symbol 326 MovieClip Frame 17
r = _root;
if ((!r.mute) && (r.songToPlay != 2)) {
r.songToPlay = 2;
stopAllSounds();
bgmusic = new Sound(this);
bgmusic.attachSound("gM" + r.songToPlay);
bgmusic.start(0, 9999);
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 18
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 227 MovieClip in Symbol 326 MovieClip Frame 20
onClipEvent (load) {
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 20
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 21
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 26
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 143 MovieClip "eP" in Symbol 326 MovieClip Frame 26
onClipEvent (load) {
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 27
onClipEvent (load) {
iBoost = 60;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 29
onClipEvent (load) {
iBoost = 0;
}
Symbol 326 MovieClip Frame 33
r = _root;
if ((!r.mute) && (r.songToPlay != 3)) {
r.songToPlay = 3;
stopAllSounds();
bgmusic = new Sound(this);
bgmusic.attachSound("gM" + r.songToPlay);
bgmusic.start(0, 9999);
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 33
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 35
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 37
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 40
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 43
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 45
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 48
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 311 MovieClip in Symbol 326 MovieClip Frame 49
onClipEvent (load) {
fixed = false;
}
Instance of Symbol 181 MovieClip in Symbol 326 MovieClip Frame 49
onClipEvent (load) {
iBoost = 0;
}
Instance of Symbol 311 MovieClip in Symbol 326 MovieClip Frame 50
onClipEvent (load) {
fixed = true;
}
Instance of Symbol 311 MovieClip in Symbol 326 MovieClip Frame 51
onClipEvent (load) {
}
Symbol 326 MovieClip Frame 52
function onEnterFrame() {
_root.nextFrame();
}
Symbol 327 MovieClip Frame 1
function upDate() {
_parent.filters = this.filters;
var _local3 = reanimator.matrix;
camera.colorTransform = reanimator.colorTransform;
_local3.invert();
_local3.translate(w * 0.5, h * 0.5);
camera.matrix = _local3;
}
var reanimator = (new flash.geom.Transform(this));
var camera = (new flash.geom.Transform(this._parent));
var w = Stage.width;
var h = Stage.height;
r = _root;
ySc = _yscale;
xSc = _xscale;
upDate();