Frame 1
NewgroundsAPI.connectMovie(6864);
mochi.as2.MochiServices.connect("62449faecb8e5e15");
Frame 2
stop();
Stage.showMenu = false;
saved = SharedObject.getLocal("Frequent");
money = saved.data.money;
shoes = saved.data.shoes;
hat = saved.data.hat;
bound = saved.data.bound;
wings = saved.data.wings;
mute = false;
if (saved.data.money == undefined) {
money = 0;
}
if (saved.data.shoes == undefined) {
shoes = 0;
}
if (saved.data.hat == undefined) {
hat = 0;
}
if (saved.data.bound == undefined) {
bound = 0;
}
if (saved.data.wings == undefined) {
wings = 0;
}
Instance of Symbol 61 MovieClip in Frame 2
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded();
total = _root.getBytesTotal();
percent = int(loaded / (total / 100));
this.gotoAndStop(Math.round(percent / 4));
}
Instance of Symbol 81 MovieClip "char" in Frame 2
onClipEvent (load) {
restitution = 0.4;
ySpeed = 0;
xSpeed = 0;
friction = 0.95;
gravity = 1.6;
}
onClipEvent (enterFrame) {
if (this._x < 0) {
this._x = 0;
xSpeed = xSpeed * (-restitution);
} else if (this._x > 550) {
this._x = 550;
xSpeed = xSpeed * (-restitution);
}
if (this._y < 0) {
this._y = 0;
ySpeed = ySpeed * (-restitution);
} else if (this._y > 400) {
this._y = 400;
ySpeed = ySpeed * (-restitution);
}
if (grabbed) {
started = true;
onGround = false;
xFromMouse = _root._xmouse - this._x;
yFromMouse = _root._ymouse - this._y;
if (xFromMouse < 0) {
xSpeed = xFromMouse / 4;
} else if (xFromMouse > 0) {
xSpeed = xFromMouse / 4;
}
if (yFromMouse < 0) {
ySpeed = yFromMouse / 4;
} else if (yFromMouse > 0) {
ySpeed = yFromMouse / 4;
}
}
this._rotation = xSpeed * 4;
ySpeed = ySpeed + gravity;
ySpeed = ySpeed * friction;
xSpeed = xSpeed * friction;
if (this._rotation > 90) {
this._rotation = 90;
} else if (this._rotation < -90) {
this._rotation = -90;
}
this._y = this._y + ySpeed;
this._x = this._x + xSpeed;
}
onClipEvent (mouseDown) {
if (this.hitTest(_root._xmouse, _root._ymouse, true)) {
grabbed = true;
}
}
onClipEvent (mouseUp) {
grabbed = false;
}
Instance of Symbol 95 MovieClip "screen" in Frame 2
onClipEvent (enterFrame) {
if (_root.transition) {
this._alpha = this._alpha + 10;
if (this._alpha > 100) {
_root.transition = false;
this._alpha = 0;
_root.nextFrame();
}
}
}
Instance of Symbol 101 MovieClip "cloud" in Frame 3
onClipEvent (load) {
myScale = this._xscale;
winDirection = 2;
framesNeeded = 64;
framesPassed = framesNeeded;
}
onClipEvent (enterFrame) {
if (_root.char._x > this._x) {
this._xscale = -myScale;
winDirection = -2;
} else {
this._xscale = myScale;
winDirection = 2;
}
this._x = this._x - _root.char.xSpeed;
if ((this._x + 500) < _root.char._x) {
this._x = this._x + (random(350) + 750);
this._y = random(150) + 50;
}
if (this.scope.hitTest(_root.char)) {
inSite = true;
} else {
inSite = false;
}
if (this.wind.hitTest(_root.char)) {
_root.char.xSpeed = _root.char.xSpeed - winDirection;
_root.char.ySpeed = _root.char.ySpeed + 2;
}
framesPassed++;
if (inSite && (framesPassed >= framesNeeded)) {
framesPassed = 0;
this.play();
}
}
Instance of Symbol 104 MovieClip "spring" in Frame 3
onClipEvent (enterFrame) {
this._x = this._x - _root.char.xSpeed;
if ((this._x + 500) < _root.char._x) {
this.gotoAndStop(1);
this._x = this._x + (random(250) + 650);
}
if (this.spring.hitTest(_root.char) && (this._currentframe == 1)) {
if (!_root.mute) {
_root.char.jumpSound.start(0, 1);
}
this.play();
_root.char.ySpeed = -40;
}
}
Instance of Symbol 111 MovieClip "hand" in Frame 3
onClipEvent (load) {
explodeSound = new Sound(this);
explodeSound.attachSound("explode");
explodeSound.setVolume(20);
}
onClipEvent (enterFrame) {
if (this.hitTest(_root.spring)) {
this._x = this._x + 250;
}
this._x = this._x - _root.char.xSpeed;
if ((this._x + 500) < _root.char._x) {
this.gotoAndStop(1);
this._x = this._x + (random(750) + 750);
}
if (this.range.hitTest(_root.char) && (this._currentframe == 1)) {
if (!_root.mute) {
explodeSound.start(0, 1);
}
this.play();
_root.char._visible = false;
_root.char._y = _root.char._y + 750;
_root.char.ySpeed = 0;
_root.char.xSpeed = 0;
}
}
Instance of Symbol 120 MovieClip "goomba" in Frame 3
onClipEvent (load) {
xSpeed = 5;
canMove = true;
}
onClipEvent (enterFrame) {
while (this.hitTest(_root.spring) || (this.hitTest(_root.hand))) {
this._x = this._x + 25;
}
this._x = this._x - _root.char.xSpeed;
if (canMove) {
framesPassed++;
if (this.body._x >= 150) {
xSpeed = -5;
} else if (this.body._x <= 0) {
xSpeed = 5;
}
this.body._x = this.body._x + xSpeed;
}
if ((this._x + 750) < _root.char._x) {
this.gotoAndStop(1);
this._x = this._x + (random(100) + 1000);
}
if (this.body.hitTest(_root.char) && (this.body._currentframe == 1)) {
this.xSpot = this._x;
canMove = false;
this.body.play();
if (_root.char.ySpeed > 0) {
_root.char.ySpeed = _root.char.ySpeed * -1.2;
} else {
_root.char.ySpeed = _root.char.ySpeed * 1.2;
}
}
}
Instance of Symbol 121 MovieClip "wingBonus" in Frame 3
onClipEvent (load) {
if (_root.wings == 0) {
this._visible = false;
}
}
onClipEvent (enterFrame) {
this._x = this._x - _root.char.xSpeed;
if ((this._alpha < 100) && (this._alpha > 0)) {
this._alpha = this._alpha - 10;
}
if ((this._x + 750) < _root.char._x) {
this._alpha = 100;
this._x = this._x + (random(350) + 750);
this._y = random(200) + 50;
if (this.hitTest(_root.cloud)) {
this._x = this._x + 250;
}
}
if ((this.hitTest(_root.char) && (this._alpha == 100)) && (_root.wings != 0)) {
this._alpha = this._alpha - 10;
_root.char.flapPower = _root.char.maxPower;
}
}
Instance of Symbol 125 MovieClip in Frame 3
onClipEvent (enterFrame) {
this._x = this._x - _root.char.xSpeed;
if ((this._alpha < 100) && (this._alpha > 0)) {
this._alpha = this._alpha - 10;
}
if ((this._x + 500) < _root.char._x) {
this._alpha = 100;
this._x = this._x + (random(1000) + 750);
this._y = random(200) + 50;
if (this.hitTest(_root.cloud) || (this.hitTest(_root.wingBonus))) {
this._x = this._x + 250;
}
}
if (this.hitTest(_root.char) && (this._alpha == 100)) {
this._alpha = this._alpha - 10;
_root.money = _root.money + 1000;
}
}
Instance of Symbol 127 MovieClip "boundaries" in Frame 3
onClipEvent (load) {
if (_root.bound == 1) {
this._xscale = this._xscale * 1.2;
this._yscale = this._yscale * 1.2;
} else if (_root.bound == 2) {
this._xscale = this._xscale * 1.4;
this._yscale = this._yscale * 1.4;
}
}
Instance of Symbol 81 MovieClip "char" in Frame 3
onClipEvent (load) {
rBeenPressed = false;
lBeenPressed = false;
hBoost = 3;
hAccel = 16;
jumpSound = new Sound(this);
jumpSound.attachSound("jump");
jumpSound.setVolume(40);
if ((_root.hat == 2) && (_root.shoes == 2)) {
gravity = 0.4;
} else if ((_root.hat == 2) || (_root.shoes == 2)) {
gravity = 0.6;
} else {
gravity = 0.8;
}
if ((_root.hat == 1) && (_root.shoes != 1)) {
restitution = 0.5;
} else if ((_root.hat == 1) && (_root.shoes == 1)) {
restitution = 0.75;
} else if (_root.shoes == 1) {
restitution = 0.65;
} else {
restitution = 0.4;
}
if (_root.wings == 1) {
flapPower = 5.5;
} else if (_root.wings == 2) {
flapPower = 6;
} else if (_root.wings == 3) {
flapPower = 6.5;
} else if (_root.wings == 4) {
flapPower = 7;
} else {
flapPower = 5;
}
maxPower = flapPower;
flapped = false;
started = false;
startX = this._x;
startY = this._y;
xDistance = 0;
onGround = false;
ySpeed = 0;
xSpeed = 0;
friction = 0.999;
}
onClipEvent (enterFrame) {
if (((Key.isDown(39) && (!rBeenPressed)) && (hBoost > 0)) && (started)) {
xSpeed = xSpeed + hAccel;
hBoost--;
rBeenPressed = true;
} else if (!Key.isDown(39)) {
rBeenPressed = false;
}
if (((Key.isDown(37) && (!lBeenPressed)) && (hBoost > 0)) && (started)) {
xSpeed = xSpeed - hAccel;
hBoost--;
lBeenPressed = true;
} else if (!Key.isDown(37)) {
lBeenPressed = false;
}
if (this._y < -100) {
this._y = -100;
ySpeed = 0;
}
if (this._y > 400) {
_root.score = xDistance;
_root.transition = true;
}
if (!_root.boundaries.hitTest(this._x, this._y, true)) {
grabbed = false;
}
if (grabbed) {
started = true;
onGround = false;
xFromMouse = _root._xmouse - this._x;
yFromMouse = _root._ymouse - this._y;
if (xFromMouse < 0) {
xSpeed = xFromMouse / 4;
} else if (xFromMouse > 0) {
xSpeed = xFromMouse / 4;
}
if (yFromMouse < 0) {
ySpeed = yFromMouse / 4;
} else if (yFromMouse > 0) {
ySpeed = yFromMouse / 4;
}
} else if (!started) {
while (_root.ground.hitTest(this._x, this._y + 22, true)) {
onGround = true;
ySpeed = 0;
this._y = this._y - 0.1;
}
this._rotation = 0;
if (!onGround) {
this._rotation = xSpeed * 1.5;
ySpeed = ySpeed + gravity;
ySpeed = ySpeed * friction;
xSpeed = xSpeed * friction;
}
} else {
if (_root.boundaries._alpha > 0) {
_root.boundaries._alpha = _root.boundaries._alpha - 10;
}
if (_root.ground.hitTest(this._x, this._y + 22, true) && (ySpeed > 10)) {
ySpeed = ySpeed * (-restitution);
if (!_root.mute) {
jumpSound.start(0, 1);
}
}
this._rotation = xSpeed * 4;
ySpeed = ySpeed + gravity;
ySpeed = ySpeed * friction;
xSpeed = xSpeed * friction;
xDistance = xDistance + xSpeed;
_root.boundaries._x = _root.boundaries._x - xSpeed;
xDistance = Math.round(xDistance);
}
if (this._rotation > 90) {
this._rotation = 90;
} else if (this._rotation < -90) {
this._rotation = -90;
}
this._y = this._y + ySpeed;
if (this._x < 0) {
this._x = 0;
xSpeed = xSpeed * -1;
}
if (this._x < 400) {
this._x = this._x + xSpeed;
} else {
this._x = 400;
}
}
onClipEvent (mouseDown) {
if (started && (!flapped)) {
flapped = true;
ySpeed = ySpeed - flapPower;
flapPower = flapPower - 0.05;
if (this._currentframe != 3) {
this.gotoAndStop(this._currentframe + 1);
} else {
this.gotoAndStop(1);
}
}
if (this.hitTest(_root._xmouse, _root._ymouse, true)) {
grabbed = true;
}
}
onClipEvent (mouseUp) {
flapped = false;
grabbed = false;
}
Instance of Symbol 136 MovieClip in Frame 3
onClipEvent (load) {
stopAllSounds();
_root.isPlaying = false;
if ((!_root.mute) && (!_root.isPlaying)) {
_root.isPlaying = true;
bgmusic = new Sound(this);
bgmusic.attachSound("song");
bgmusic.start(0, 9999);
}
buttonDown = false;
}
onClipEvent (enterFrame) {
if (Key.isDown(77) && (!buttonDown)) {
buttonDown = true;
if (_root.mute) {
_root.isPlaying = true;
_root.mute = false;
bgmusic = new Sound(this);
bgmusic.attachSound("Song");
bgmusic.start(0, 9999);
} else {
_root.mute = true;
}
} else if (!Key.isDown(77)) {
buttonDown = false;
}
if (_root.mute) {
_root.isPlaying = false;
this.gotoAndStop(2);
stopAllSounds();
} else {
this.gotoAndStop(1);
}
}
Instance of Symbol 139 MovieClip in Frame 3
onClipEvent (load) {
beenPressed = false;
}
onClipEvent (enterFrame) {
if (Key.isDown(81) && (!beenPressed)) {
beenPressed = true;
if (_quality == "HIGH") {
_quality = "MEDIUM";
} else if (_quality == "MEDIUM") {
_quality = "LOW";
} else if (_quality == "LOW") {
_quality = "HIGH";
}
} else if (!Key.isDown(81)) {
beenPressed = false;
}
}
Instance of Symbol 141 MovieClip in Frame 3
onClipEvent (load) {
maxPower = _root.char.maxPower;
}
onClipEvent (enterFrame) {
current = _root.char.flapPower;
percent = int(current / (maxPower / 100));
this.gotoAndStop(Math.round(percent / 4));
}
Instance of Symbol 145 MovieClip in Frame 3
onClipEvent (enterFrame) {
if (_root.char._y < 0) {
this._x = _root.char._x;
this._visible = true;
_root.beyondTop = Math.round(Math.abs(_root.char._y));
} else {
this._visible = false;
}
}
Instance of Symbol 151 MovieClip in Frame 3
onClipEvent (load) {
this.gotoAndStop(_root.char.hBoost);
}
onClipEvent (enterFrame) {
this.gotoAndStop(_root.char.hBoost);
if (_root.char.hBoost <= 0) {
this._visible = false;
}
}
Frame 4
moneySound = new Sound(this);
moneySound.attachSound("money");
moneySound.setVolume(60);
money = money + score;
saved.data.money = money;
if (score < 1000) {
note = score + " micrometres";
} else if (score < 100000) {
note = Math.round(score / 1000) + " centimetres";
} else {
note = Math.round(score / 100000) + " metres";
}
Instance of Symbol 162 MovieClip "buyBound" in Frame 4
onClipEvent (enterFrame) {
if (_root.bound == 0) {
_root.boundType = "Big: 10,000";
} else if (_root.bound == 1) {
_root.boundType = "Huge: 100,000";
} else {
_root.buyBound._visible = false;
}
}
Instance of Symbol 166 MovieClip "buyWings" in Frame 4
onClipEvent (enterFrame) {
if (_root.wings == 0) {
_root.wingType = "Bird: 2,500";
} else if (_root.wings == 1) {
_root.wingType = "Bat: 10,000";
} else if (_root.wings == 2) {
_root.wingType = "Angel: 75,000";
} else if (_root.wings == 3) {
_root.wingType = "Dragon: 750,000";
} else {
_root.buyWings._visible = false;
}
}
Instance of Symbol 170 MovieClip "buyShoes" in Frame 4
onClipEvent (enterFrame) {
if (_root.shoes == 0) {
_root.shoeType = "Rubber: 25,000";
} else if (_root.shoes == 1) {
_root.shoeType = "Rocket: 1,000,000";
} else {
_root.buyShoes._visible = false;
}
}
Instance of Symbol 174 MovieClip "buyHats" in Frame 4
onClipEvent (enterFrame) {
if (_root.hat == 0) {
_root.hatType = "Bunny ears: 5,000";
} else if (_root.hat == 1) {
_root.hatType = "Propellor: 250,000";
} else {
_root.buyHats._visible = false;
}
}
Instance of Symbol 95 MovieClip "screen" in Frame 4
onClipEvent (enterFrame) {
if (_root.transition) {
this._alpha = this._alpha + 10;
if (this._alpha > 100) {
_root.transition = false;
this._alpha = 0;
_root.gotoAndStop(3);
}
}
}
Symbol 21 MovieClip Frame 40
stop();
Symbol 35 Button
on (press) {
tellTarget (_root) {
nextFrame();
};
}
Symbol 36 Button
on (press) {
gotoAndStop ("end");
_root.play();
}
Instance of Symbol 11 MovieClip in Symbol 37 MovieClip Frame 1
onClipEvent (load) {
_root.stop();
PercentLoaded = int((_root.getBytesLoaded() / _root.getBytesTotal()) * 100);
if (PercentLoaded != 100) {
_parent.gotoAndStop(PercentLoaded);
} else {
_parent.gotoAndStop("lastframe");
}
}
onClipEvent (enterFrame) {
PercentLoaded = int((_root.getBytesLoaded() / _root.getBytesTotal()) * 100);
if (PercentLoaded != 100) {
_parent.gotoAndStop(PercentLoaded);
} else {
_parent.gotoAndPlay("loaded");
}
}
Symbol 37 MovieClip Frame 101
play();
Symbol 37 MovieClip Frame 165
stop();
Symbol 43 Button
on (release) {
NewgroundsAPI.loadNewgrounds();
}
Symbol 49 Button
on (release) {
NewgroundsAPI.loadNewgrounds();
}
Symbol 51 MovieClip Frame 1
function startAd(ngad_url) {
trace("opening " + ngad_url);
System.security.allowDomain("70.87.128.99");
System.security.allowInsecureDomain("70.87.128.99");
System.security.allowDomain("ads.shizmoo.com");
System.security.allowInsecureDomain("ads.shizmoo.com");
System.security.allowDomain("www.cpmstar.com");
System.security.allowInsecureDomain("www.cpmstar.com");
System.security.allowDomain("server.cpmstar.com");
System.security.allowInsecureDomain("server.cpmstar.com");
var ngads_redirect = new XML();
ngads_redirect.ignoreWhite = true;
ngads_redirect.onLoad = function (success) {
trace("[NEWGROUNDS FLASH ADS] :: You may get a 'Security Sandbox Violation' ... this is normal, do not freak out!");
if (success) {
ng_ad.loadMovie(ngads_redirect.toString(), "GET");
}
};
ngads_redirect.load(ngad_url);
}
if (NewgroundsAPI.getAdURL()) {
startAd(NewgroundsAPI.getAdURL());
}
NewgroundsAPI.onAdsApproved = function (ad_url) {
startAd(ad_url);
};
stop();
Symbol 177 MovieClip [__Packages.NewgroundsAPI] Frame 0
class NewgroundsAPI
{
static var tracker_id, host, version, debug, error_format, header_format, normal_format, link_format;
function NewgroundsAPI () {
}
static function connectMovie(id) {
if (!id) {
SendError("Missing required 'id' parameter in NewgroundsAPI.connectMovie(id:Number)");
} else if (!tracker_id) {
SendMessage("Connecting to API gateway...");
tracker_id = id;
host = _url.split("/")[2].toLowerCase();
if (host.length < 1) {
host = "localhost";
}
var _local2 = new Object();
SendEvent(MOVIE_VIEWS);
}
}
static function setMovieVersion(movie_version) {
if (!movie_version) {
SendError("Missing required 'version' in NewgroundsAPI.setMovieVersion(version:String)");
} else {
version = movie_version;
}
}
static function debugMode() {
debug = true;
}
static function addCustomEvent(stat_id, stat_name) {
if (!stat_id) {
SendError("Missing required 'id' parameter in NewgroundsAPI.AddCustomEvent(id:Number, event_name:String)");
} else if (!stat_name) {
SendError("Missing required 'event_name' parameter in NewgroundsAPI.AddCustomEvent(id:Number, event_name:String)");
} else {
custom_events[stat_name] = CUSTOM_STATS + stat_id;
SendMessage("Created custom event: " + stat_name);
}
}
static function addCustomLink(stat_id, stat_name) {
if (!stat_id) {
SendError("Missing required 'id' parameter in NewgroundsAPI.AddCustomLink(id:Number, link_name:String)");
} else if (!stat_name) {
SendError("Missing required 'link_name' parameter in NewgroundsAPI.AddCustomLink(id:Number, link_name:String)");
} else {
custom_links[stat_name] = CUSTOM_STATS + stat_id;
SendMessage((("Created custom link " + stat_id) + ": ") + stat_name);
}
}
static function loadMySite() {
SendLink(AUTHOR_SITE);
}
static function loadNewgrounds(special) {
if (special) {
var _local1 = {page:special};
}
SendLink(NEWGROUNDS, _local1);
}
static function logCustomEvent(event_name) {
if (!event_name) {
SendError("Missing required 'event_name' parameter in NewgroundsAPI.logCustomEvent(event_name:String)");
} else if (!custom_events[event_name]) {
SendError("Attempted to log undefined custom event: " + event_name);
} else {
SendEvent(custom_events[event_name]);
}
}
static function loadCustomLink(link_name) {
if (!link_name) {
SendError("Missing required 'link_name' parameter in NewgroundsAPI.loadCustomLink(link_name:String)");
} else if (!custom_links[link_name]) {
SendError("Attempted to open undefined custom link: " + link_name);
} else {
SendLink(custom_links[link_name]);
}
}
static function getAdURL() {
return(movie_options.ad_url);
}
static function getMovieURL() {
if (movie_options.movie_url) {
return(movie_options.movie_url);
}
return("Newgrounds.com");
}
static function getNewVersionURL() {
return((((((GATEWAY_URL + "?&id=") + tracker_id) + "&host=") + escape(host)) + "&stat=") + NEW_VERSION);
}
static function SendEvent(id) {
SendStat(id, false);
}
static function SendLink(id, extra) {
SendStat(id, true, extra);
}
static function ReadGatewayData(params) {
for (var _local2 in params) {
params[_local2] = unescape(params[_local2]);
movie_options[_local2] = params[_local2];
}
if (params.settings_loaded) {
SendMessage("You have successfully connected to the Newgrounds API gateway!");
SendMessage(("Movie Identified as '" + movie_options.movie_name) + "'");
if (movie_options.message) {
SendMessage(movie_options.message);
}
if (movie_options.ad_url) {
SendMessage("Your movie has been approved to run Flash Ads");
onAdsApproved(movie_options.ad_url);
}
if (movie_options.movie_version and (movie_options.movie_version.toString() != version.toString())) {
SendMessage("WARNING: The movie version configured in your API settings does not match this movie's version!");
onNewVersionAvailable(movie_options.movie_version, getMovieURL(), getNewVersionURL());
}
if (movie_options.deny_host) {
SendMessage("You have blocked 'localHost' in your API settings.");
SendMessage("If you wish to test your movie you will need to remove this block.");
onDenyHost(host, getMovieURL(), getNewVersionURL());
}
if (movie_options.request_portal_url == 1) {
var _local4 = (((GATEWAY_URL + "?&id=") + tracker_id) + "&portal_url=") + escape(_url);
var _local3 = new XML();
_local3.ignoreWhite = true;
_local3.load(_local4);
}
} else if (!movie_options.settings_loaded) {
SendError("Could not establish connection to the API gateway.");
}
}
static function SendStat(stat_id, open_in_browser, extra) {
if (!tracker_id) {
SendError("API calls cannot be made without a valid movie id.");
SendError("Did you remember to add the \"NewgroundsAPI.connectMovie()\" code?");
} else {
var _local7 = (((((GATEWAY_URL + "?&id=") + tracker_id) + "&host=") + escape(host)) + "&stat=") + stat_id;
for (var _local9 in extra) {
_local7 = _local7 + ((("&" + escape(_local9)) + "=") + escape(extra[_local9]));
}
trace(_local7);
if (debug) {
_local7 = _local7 + "&debug=1";
}
if (open_in_browser) {
getURL (_local7, "_blank");
} else {
var _local10 = new XML();
_local10.ignoreWhite = true;
_local10.onLoad = function (success) {
var _local6 = new Object();
var _local3 = 0;
while (_local3 < this.firstChild.childNodes.length) {
var _local4 = this.firstChild.childNodes[_local3];
var _local5 = _local4.nodeName;
var _local2 = _local4.attributes.value;
if (_local2 == Number(_local2)) {
_local2 = Number(_local2);
}
_local6[_local5] = _local2;
_local3++;
}
NewgroundsAPI.ReadGatewayData(_local6);
};
_local10.load(_local7);
}
}
}
static function SendError(msg) {
trace("[NEWGROUNDS API ERROR] :: " + msg);
}
static function SendMessage(msg) {
trace("[NEWGROUNDS API] :: " + msg);
}
static function InitTextFormats() {
if (!error_format) {
error_format = new TextFormat();
error_format.font = "Arial Black";
error_format.size = 48;
error_format.color = 16711680 /* 0xFF0000 */;
}
if (!header_format) {
header_format = new TextFormat();
header_format.font = "Arial Black";
header_format.size = 24;
header_format.color = 16777215 /* 0xFFFFFF */;
}
if (!normal_format) {
normal_format = new TextFormat();
normal_format.font = "Arial";
normal_format.bold = true;
normal_format.size = 12;
normal_format.color = 16777215 /* 0xFFFFFF */;
}
if (!link_format) {
link_format = new TextFormat();
link_format.color = 16776960 /* 0xFFFF00 */;
link_format.underline = true;
}
}
static function onNewVersionAvailable(version, movie_url, redirect_url) {
InitTextFormats();
var _local2 = new Object();
_local2.x = Stage.width / 2;
_local2.y = Stage.height / 2;
_root.createEmptyMovieClip("NGAPI_new_version_overlay", _root.getNextHighestDepth());
_root.NGAPI_new_version_overlay.lineStyle(1, 0, 100);
_root.NGAPI_new_version_overlay.beginFill(0, 70);
_root.NGAPI_new_version_overlay.moveTo(-10, -10);
_root.NGAPI_new_version_overlay.lineTo(-10, 1000);
_root.NGAPI_new_version_overlay.lineTo(1000, 1000);
_root.NGAPI_new_version_overlay.lineTo(1000, -10);
_root.NGAPI_new_version_overlay.lineTo(-10, -10);
_root.NGAPI_new_version_overlay.endFill();
_root.NGAPI_new_version_overlay.lineStyle(10, 0, 100);
_root.NGAPI_new_version_overlay.beginFill(51);
_root.NGAPI_new_version_overlay.moveTo(_local2.x - 240, _local2.y - 120);
_root.NGAPI_new_version_overlay.lineTo(_local2.x + 240, _local2.y - 120);
_root.NGAPI_new_version_overlay.lineTo(_local2.x + 240, _local2.y + 80);
_root.NGAPI_new_version_overlay.lineTo(_local2.x - 240, _local2.y + 80);
_root.NGAPI_new_version_overlay.lineTo(_local2.x - 240, _local2.y - 120);
_root.NGAPI_new_version_overlay.endFill();
_root.NGAPI_new_version_overlay.createEmptyMovieClip("exit", 1000);
_root.NGAPI_new_version_overlay.exit.lineStyle(2, 39423, 100);
_root.NGAPI_new_version_overlay.exit.beginFill(0, 50);
_root.NGAPI_new_version_overlay.exit.moveTo(_local2.x + 210, _local2.y - 110);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 230, _local2.y - 110);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 230, _local2.y - 90);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 210, _local2.y - 90);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 210, _local2.y - 110);
_root.NGAPI_new_version_overlay.exit.endFill();
_root.NGAPI_new_version_overlay.exit.moveTo(_local2.x + 214, _local2.y - 106);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 226, _local2.y - 94);
_root.NGAPI_new_version_overlay.exit.moveTo(_local2.x + 226, _local2.y - 106);
_root.NGAPI_new_version_overlay.exit.lineTo(_local2.x + 214, _local2.y - 94);
_root.NGAPI_new_version_overlay.exit.onMouseUp = function () {
if (_root.NGAPI_new_version_overlay.exit.hitTest(_root._xmouse, _root._ymouse)) {
_root.NGAPI_new_version_overlay.removeMovieClip();
}
};
var _local3 = (("Version " + version) + " is now available at:") + newline;
var _local5 = _local3.length;
_local3 = _local3 + movie_url;
var _local4 = _local3.length;
_root.NGAPI_new_version_overlay.createTextField("mouseblocker", 99, -10, -10, 1000, 1000);
_root.NGAPI_new_version_overlay.createTextField("newversion", 100, _local2.x - 210, _local2.y - 90, 400, 80);
_root.NGAPI_new_version_overlay.newversion.text = "New Version Available!";
_root.NGAPI_new_version_overlay.newversion.setTextFormat(header_format);
_root.NGAPI_new_version_overlay.createTextField("message", 101, (Stage.width - 400) / 2, Stage.height / 2, 400, 40);
_root.NGAPI_new_version_overlay.message.text = _local3;
_root.NGAPI_new_version_overlay.message.multiline = true;
_root.NGAPI_new_version_overlay.message.wordWrap = true;
_root.NGAPI_new_version_overlay.message.html = true;
_root.NGAPI_new_version_overlay.message.setTextFormat(normal_format);
link_format.url = redirect_url;
_root.NGAPI_new_version_overlay.message.setTextFormat(_local5, _local4, link_format);
}
static function onDenyHost(hostname, movie_url, redirect_url) {
InitTextFormats();
_root.createEmptyMovieClip("NGAPI_deny_host_overlay", _root.getNextHighestDepth());
_root.NGAPI_deny_host_overlay.lineStyle(20, 0, 100);
_root.NGAPI_deny_host_overlay.beginFill(6684672);
_root.NGAPI_deny_host_overlay.moveTo(0, 0);
_root.NGAPI_deny_host_overlay.lineTo(Stage.width, 0);
_root.NGAPI_deny_host_overlay.lineTo(Stage.width, Stage.height);
_root.NGAPI_deny_host_overlay.lineTo(0, Stage.height);
_root.NGAPI_deny_host_overlay.lineTo(0, 0);
_root.NGAPI_deny_host_overlay.endFill();
var _local2 = ("This movie has not been approved for use on " + hostname) + ".";
_local2 = _local2 + "\r\rFor an aproved copy, please visit:\r";
var _local4 = _local2.length;
_local2 = _local2 + movie_url;
var _local3 = _local2.length;
_root.NGAPI_deny_host_overlay.createTextField("mousekill", 100, 0, 0, Stage.width, Stage.height);
_root.NGAPI_deny_host_overlay.createTextField("error", 101, (Stage.width - 400) / 2, (Stage.height / 2) - 100, 400, 200);
_root.NGAPI_deny_host_overlay.error.text = "ERROR!";
_root.NGAPI_deny_host_overlay.error.setTextFormat(error_format);
_root.NGAPI_deny_host_overlay.createTextField("message", 102, (Stage.width - 400) / 2, Stage.height / 2, 400, 200);
_root.NGAPI_deny_host_overlay.message.text = _local2;
_root.NGAPI_deny_host_overlay.message.multiline = true;
_root.NGAPI_deny_host_overlay.message.wordWrap = true;
_root.NGAPI_deny_host_overlay.message.html = true;
_root.NGAPI_deny_host_overlay.message.setTextFormat(normal_format);
link_format.url = redirect_url;
_root.NGAPI_deny_host_overlay.message.setTextFormat(_local4, _local3, link_format);
}
static function isInstalled() {
return(true);
}
static function onAdsApproved(ad_url) {
}
static var movie_options = new Object();
static var custom_events = new Object();
static var custom_links = new Object();
static var MOVIE_VIEWS = 1;
static var AUTHOR_SITE = 2;
static var NEWGROUNDS = 3;
static var NEW_VERSION = 4;
static var CUSTOM_STATS = 50;
static var GATEWAY_URL = "http://www.ngads.com/gateway.php";
}
Symbol 178 MovieClip [__Packages.mochi.as2.MochiServices] Frame 0
class mochi.as2.MochiServices
{
static var _id, _container, _clip, _sendChannelName, __get__comChannelName, onError, _listenChannel, _loader, _loaderListener, _sendChannel;
function MochiServices () {
}
static function get id() {
return(_id);
}
static function get clip() {
return(_container);
}
static function get childClip() {
return(_clip);
}
static function getVersion() {
return("3.0");
}
static function allowDomains(server) {
var _local1 = server.split("/")[2].split(":")[0];
if (System.security) {
if (System.security.allowDomain) {
System.security.allowDomain("*");
System.security.allowDomain(_local1);
}
if (System.security.allowInsecureDomain) {
System.security.allowInsecureDomain("*");
System.security.allowInsecureDomain(_local1);
}
}
return(_local1);
}
static function get isNetworkAvailable() {
if (System.security) {
var _local1 = System.security;
if (_local1.sandboxType == "localWithFile") {
return(false);
}
}
return(true);
}
static function set comChannelName(val) {
if (val != undefined) {
if (val.length > 3) {
_sendChannelName = val + "_fromgame";
initComChannels();
}
}
//return(__get__comChannelName());
}
static function get connected() {
return(_connected);
}
static function connect(id, clip, onError) {
if ((!_connected) && (_clip == undefined)) {
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 _local3 = "_mochiservices_com_" + id;
if (_clip != null) {
return(_clip);
}
if (!isNetworkAvailable) {
return(null);
}
if (urlOptions().servicesURL != undefined) {
_servicesURL = urlOptions().servicesURL;
}
allowDomains(_servicesURL);
_clip = clip.createEmptyMovieClip(_local3, 10336, false);
_listenChannelName = _listenChannelName + ((Math.floor(new Date().getTime()) + "_") + Math.floor(Math.random() * 99999));
listen();
_loader = new MovieClipLoader();
if (_loaderListener.waitInterval != null) {
clearInterval(_loaderListener.waitInterval);
}
_loaderListener = {};
_loaderListener.onLoadError = function (target_mc, errorCode, httpStatus) {
trace("MochiServices could not load.");
mochi.as2.MochiServices.disconnect();
mochi.as2.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.as2.MochiServices.disconnect();
mochi.as2.MochiServices.onError.apply(null, ["IOError"]);
}
clearInterval(this.waitInterval);
}
};
_loaderListener.waitInterval = setInterval(_loaderListener, "wait", 1000);
_loader.addListener(_loaderListener);
_loader.loadClip((((_servicesURL + "?listenLC=") + _listenChannelName) + "&mochiad_options=") + escape(_root.mochiad_options), _clip);
_sendChannel = new LocalConnection();
_sendChannel._queue = [];
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.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, clip:_clip, 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.onError = function () {
mochi.as2.MochiServices.onError.apply(null, ["IOError"]);
};
trace("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)) {
onError.apply(null, ["NotConnected"]);
handleError(args, callbackObject, callbackMethod);
flush(true);
return(undefined);
}
_sendChannel._queue.push({methodName:methodName, args:args, callbackID:_listenChannel._nextcallbackID});
}
_listenChannel._callbacks[_listenChannel._nextcallbackID] = {callbackObject:callbackObject, callbackMethod:callbackMethod};
_listenChannel._nextcallbackID++;
}
static function urlOptions() {
var _local5 = {};
if (_root.mochiad_options) {
var _local4 = _root.mochiad_options.split("&");
var _local2 = 0;
while (_local2 < _local4.length) {
var _local3 = _local4[_local2].split("=");
_local5[unescape(_local3[0])] = unescape(_local3[1]);
_local2++;
}
}
return(_local5);
}
static function addLinkEvent(url, burl, btn, onClick) {
var timeout = 1500;
var t0 = getTimer();
var _local2 = new Object();
_local2.mav = getVersion();
_local2.swfv = btn.getSWFVersion() || 6;
_local2.swfurl = btn._url;
_local2.fv = System.capabilities.version;
_local2.os = System.capabilities.os;
_local2.lang = System.capabilities.language;
_local2.scres = (System.capabilities.screenResolutionX + "x") + System.capabilities.screenResolutionY;
var s = "?";
var _local3 = 0;
for (var _local6 in _local2) {
if (_local3 != 0) {
s = s + "&";
}
_local3++;
s = ((s + _local6) + "=") + escape(_local2[_local6]);
}
if (!(netupAttempted || (_connected))) {
var ping = btn.createEmptyMovieClip("ping", 777);
var _local7 = btn.createEmptyMovieClip("nettest", 778);
netupAttempted = true;
ping.loadMovie("http://x.mochiads.com/linkping.swf?t=" + getTimer());
_local7.onEnterFrame = function () {
if ((ping._totalframes > 0) && (ping._totalframes == ping._framesloaded)) {
delete this.onEnterFrame;
} else if ((getTimer() - t0) > timeout) {
delete this.onEnterFrame;
mochi.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 var _servicesURL = "http://www.mochiads.com/static/lib/services/services.swf";
static var _listenChannelName = "__ms_";
static var _connecting = false;
static var _connected = false;
static var netup = true;
static var netupAttempted = false;
}
Symbol 179 MovieClip [__Packages.mochi.as2.MochiScores] Frame 0
class mochi.as2.MochiScores
{
static var boardID, onClose, onError;
function MochiScores () {
}
static function setBoardID(boardID) {
mochi.as2.MochiScores.boardID = boardID;
mochi.as2.MochiServices.send("scores_setBoardID", {boardID:boardID});
}
static function showLeaderboard(options) {
if ((options.clip == null) || (options.clip == undefined)) {
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();
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 () {
};
}
if (options.onError != null) {
onError = options.onError;
} else {
onError = onClose;
}
if (options.boardID == null) {
if (boardID != null) {
options.boardID = boardID;
}
}
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 180 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 60 Button
on (release) {
_root.transition = true;
}
Symbol 68 MovieClip Frame 1
stop();
Symbol 73 MovieClip Frame 1
stop();
Symbol 78 MovieClip Frame 1
stop();
Symbol 81 MovieClip Frame 1
stop();
Instance of Symbol 68 MovieClip in Symbol 81 MovieClip Frame 1
onClipEvent (load) {
if (_root.shoes == 0) {
this._visible = false;
} else if (_root.shoes == 2) {
this.gotoAndStop(2);
}
}
Instance of Symbol 73 MovieClip in Symbol 81 MovieClip Frame 1
onClipEvent (load) {
if (_root.wings == 0) {
this._visible = false;
} else {
this.gotoAndStop(_root.wings);
}
}
Instance of Symbol 73 MovieClip in Symbol 81 MovieClip Frame 1
onClipEvent (load) {
if (_root.wings == 0) {
this._visible = false;
} else {
this.gotoAndStop(_root.wings);
}
}
Instance of Symbol 78 MovieClip in Symbol 81 MovieClip Frame 1
onClipEvent (load) {
if (_root.hat == 0) {
this._visible = false;
} else if (_root.hat == 2) {
this.gotoAndStop(2);
}
}
Instance of Symbol 78 MovieClip in Symbol 81 MovieClip Frame 1
onClipEvent (load) {
if (_root.hat == 0) {
this._visible = false;
} else if (_root.hat == 2) {
this.gotoAndStop(2);
}
}
Symbol 101 MovieClip Frame 1
stop();
Symbol 104 MovieClip Frame 1
stop();
Symbol 104 MovieClip Frame 10
stop();
Symbol 111 MovieClip Frame 1
stop();
Symbol 111 MovieClip Frame 11
stop();
Symbol 119 MovieClip Frame 1
stop();
Symbol 119 MovieClip Frame 21
stop();
Instance of Symbol 73 MovieClip in Symbol 121 MovieClip Frame 1
onClipEvent (load) {
if (_root.wings == 0) {
this._visible = false;
} else {
this.gotoAndStop(_root.wings);
}
}
Instance of Symbol 73 MovieClip in Symbol 121 MovieClip Frame 1
onClipEvent (load) {
if (_root.wings == 0) {
this._visible = false;
} else {
this.gotoAndStop(_root.wings);
}
}
Symbol 133 Button
on (release) {
if (!_root.mute) {
_root.mute = true;
} else {
_root.mute = false;
bgmusic = new Sound(this);
bgmusic.attachSound("Song");
bgmusic.start(0, 9999);
bgmusic.setVolume(40);
}
}
Symbol 136 MovieClip Frame 1
stop();
Symbol 137 Button
on (release) {
if (_quality == "HIGH") {
_quality = "MEDIUM";
} else if (_quality == "MEDIUM") {
_quality = "LOW";
} else if (_quality == "LOW") {
_quality = "HIGH";
}
}
Symbol 155 Button
on (release) {
_root.saved.data.money = _root.money;
_root.transition = true;
}
Symbol 160 Button
on (release) {
if ((_root.money >= 10000) && (_root.bound == 0)) {
if (!_root.mute) {
_root.moneySound.start(0, 1);
}
_root.money = _root.money - 10000;
_root.bound = 1;
} else if ((_root.money >= 100000) && (_root.bound == 1)) {
if (!_root.mute) {
_root.moneySound.start(0, 1);
}
_root.money = _root.money - 100000;
_root.bound = 2;
}
_root.saved.data.bound = _root.bound;
}
Symbol 164 Button
on (release) {
if ((_root.money >= 2500) && (_root.wings == 0)) {
if (!_root.mute) {
_root.moneySound.start(0, 1);
}
_root.money = _root.money - 2500;
_root.wings = 1;
} else if ((_root.money >= 10000) && (_root.wings == 1)) {
if (!_root.mute) {
_root.moneySound.start(0, 1);
}
_root.money = _root.money - 10000;
_root.wings = 2;
} else if ((_root.money >= 75000) && (_root.wings == 2)) {
if (!_root.mute) {
_root.moneySound.start(0, 1);
}
_root.money = _root.money - 75000;
_root.wings = 3;
} else if ((_root.money >= 750000) && (_root.wings == 3)) {
if (!_root.mute) {
_root.moneySound.start(0, 1);
}
_root.money = _root.money - 750000;
_root.wings = 4;
}
_root.saved.data.wings = _root.wings;
}
Symbol 168 Button
on (release) {
_root.saved.data.shoes = _root.shoes;
if ((_root.money >= 25000) && (_root.shoes == 0)) {
if (!_root.mute) {
_root.moneySound.start(0, 1);
}
_root.money = _root.money - 25000;
_root.shoes = 1;
} else if ((_root.money >= 1000000) && (_root.shoes == 1)) {
if (!_root.mute) {
_root.moneySound.start(0, 1);
}
_root.money = _root.money - 1000000;
_root.shoes = 2;
}
_root.saved.data.shoes = _root.shoes;
}
Symbol 172 Button
on (release) {
if ((_root.money >= 5000) && (_root.hat == 0)) {
if (!_root.mute) {
_root.moneySound.start(0, 1);
}
_root.money = _root.money - 5000;
_root.hat = 1;
} else if ((_root.money >= 250000) && (_root.hat == 1)) {
if (!_root.mute) {
_root.moneySound.start(0, 1);
}
_root.money = _root.money - 250000;
_root.hat = 2;
}
_root.saved.data.hat = _root.hat;
}
Symbol 176 Button
on (release) {
var o = {n:[2, 7, 15, 1, 1, 12, 1, 3, 2, 3, 0, 7, 14, 14, 8, 8], f:function (i, s) {
if (s.length == 16) {
return(s);
}
return(this.f(i + 1, s + this.n[i].toString(16)));
}};
var boardID = o.f(0, "");
mochi.as2.MochiScores.showLeaderboard({boardID:boardID, score:_root.score});
}