Combined Code
frame 1 {
function encodeLevel(level) {
mlevel = level.searchreplace(';', ',');
nlevel = mlevel.searchreplace(' ', '');
arr = nlevel.split(',');
fin = '';
i = 0;
while (i < arr.length) {
if (encnum[parseInt(arr[i])] != undefined && !isNaN(parseInt(arr[i]))) {
fin += encnum[parseInt(arr[i])];
}
++i;
}
return fin;
}
function decodeLevel(level) {
arr = level.split('');
fin = ';';
count = 0;
i = 0;
while (i < arr.length) {
if (decnum[arr[i]] != undefined) {
fin += decnum[arr[i]];
if (count < 2) {
fin += ',';
++count;
} else {
fin += ';';
count = 0;
}
}
++i;
}
return fin;
}
ver = '0.12.1';
NewgroundsAPI.connectMovie(10912);
var myMenu = new ContextMenu();
myMenu.builtInItems.loop = false;
myMenu.builtInItems.forward_back = false;
myMenu.builtInItems.play = false;
myMenu.builtInItems.rewind = false;
_root.menu = myMenu;
System.security.allowDomain('www.willseph.com');
System.security.allowInsecureDomain('www.willseph.com');
System.security.allowDomain('www.twitter.com');
System.security.allowInsecureDomain('www.twitter.com');
System.security.allowDomain('www.bit.ly');
System.security.allowInsecureDomain('www.bit.ly');
System.security.allowDomain('www.heyzap.com');
System.security.allowInsecureDomain('www.heyzap.com');
System.security.loadPolicyFile('http://willseph.com/crossdomain.xml');
popup = false;
String.prototype.searchreplace = function (finder, replace) {
var v2 = this;
var v8 = 0;
while (v8 < v2.length) {
var v3 = v2.indexOf(finder, v8);
if (v3 == -1) {
break;
} else {
var v4 = v2.substr(0, v3);
var v5 = v2.substr(v3 + finder.length, v2.length);
v2 = v4 + replace + v5;
v8 = v4.length + replace.length;
}
}
return v2;
};
encnum = new Array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p');
decnum = new Array();
i = 0;
while (i < encnum.length) {
decnum[encnum[i]] = i;
++i;
}
}
frame 1 {
stop();
}
movieClip 2 {
}
movieClip 4 {
}
// unknown tag 88 length 220
movieClip 8 {
frame 5 {
stop();
}
}
movieClip 14 {
frame 1 {
stop();
}
}
movieClip 17 {
frame 9 {
stop();
_root.fader.play();
}
}
movieClip 18 {
frame 1 {
stop();
}
frame 2 {
clip.gotoAndPlay(1);
}
frame 3 {
clip.gotoAndPlay(1);
}
frame 4 {
clip.gotoAndPlay(1);
}
frame 5 {
clip.gotoAndPlay(1);
}
frame 6 {
clip.gotoAndPlay(1);
}
frame 7 {
clip.gotoAndPlay(1);
}
frame 8 {
clip.gotoAndPlay(1);
}
frame 9 {
clip.gotoAndPlay(1);
}
frame 10 {
clip.gotoAndPlay(1);
}
frame 11 {
stop();
}
frame 11 {
clip.gotoAndPlay(1);
}
}
instance Preloader of movieClip 18 {
onClipEvent (enterFrame) {
if (_root.getBytesLoaded() <= _root.getBytesTotal()) {
gotoAndStop(Math.floor((_root.getBytesLoaded() / _root.getBytesTotal()) * 10) + 1);
}
loadtext = 'LOADING ' + Math.round((_root.getBytesLoaded() / _root.getBytesTotal()) * 100) + '%';
}
}
movieClip 20 {
frame 1 {
stop();
}
frame 10 {
stop();
_root.play();
}
}
movieClip 306 __Packages.NewgroundsAPI {
#initclip
if (!_global.NewgroundsAPI) {
var v1 = function () {};
_global.NewgroundsAPI = v1;
var v2 = v1.prototype;
v1.connectMovie = function (id) {
if (!id) {
NewgroundsAPI.SendError('Missing required \'id\' parameter in NewgroundsAPI.connectMovie(id:Number)');
} else {
if (!NewgroundsAPI.tracker_id) {
NewgroundsAPI.SendMessage('Connecting to API gateway...');
NewgroundsAPI.tracker_id = id;
NewgroundsAPI.host = (_url.split('/'))[2].toLowerCase();
if (NewgroundsAPI.host.length < 1) {
NewgroundsAPI.host = 'localhost';
}
var v2 = new Object();
NewgroundsAPI.SendEvent(NewgroundsAPI.MOVIE_VIEWS);
}
}
};
v1.setMovieVersion = function (movie_version) {
if (!movie_version) {
NewgroundsAPI.SendError('Missing required \'version\' in NewgroundsAPI.setMovieVersion(version:String)');
} else {
NewgroundsAPI.version = movie_version;
}
};
v1.debugMode = function () {
NewgroundsAPI.debug = true;
};
v1.addCustomEvent = function (stat_id, stat_name) {
if (!stat_id) {
NewgroundsAPI.SendError('Missing required \'id\' parameter in NewgroundsAPI.AddCustomEvent(id:Number, event_name:String)');
} else {
if (!stat_name) {
NewgroundsAPI.SendError('Missing required \'event_name\' parameter in NewgroundsAPI.AddCustomEvent(id:Number, event_name:String)');
} else {
NewgroundsAPI.custom_events[stat_name] = NewgroundsAPI.CUSTOM_STATS + stat_id;
NewgroundsAPI.SendMessage('Created custom event: ' + stat_name);
}
}
};
v1.addCustomLink = function (stat_id, stat_name) {
if (!stat_id) {
NewgroundsAPI.SendError('Missing required \'id\' parameter in NewgroundsAPI.AddCustomLink(id:Number, link_name:String)');
} else {
if (!stat_name) {
NewgroundsAPI.SendError('Missing required \'link_name\' parameter in NewgroundsAPI.AddCustomLink(id:Number, link_name:String)');
} else {
NewgroundsAPI.custom_links[stat_name] = NewgroundsAPI.CUSTOM_STATS + stat_id;
NewgroundsAPI.SendMessage('Created custom link ' + stat_id + ': ' + stat_name);
}
}
};
v1.loadMySite = function () {
NewgroundsAPI.SendLink(NewgroundsAPI.AUTHOR_SITE);
};
v1.loadNewgrounds = function (special) {
if (special) {
var v1 = {'page': special};
}
NewgroundsAPI.SendLink(NewgroundsAPI.NEWGROUNDS, v1);
};
v1.logCustomEvent = function (event_name) {
if (!event_name) {
NewgroundsAPI.SendError('Missing required \'event_name\' parameter in NewgroundsAPI.logCustomEvent(event_name:String)');
} else {
if (!NewgroundsAPI.custom_events[event_name]) {
NewgroundsAPI.SendError('Attempted to log undefined custom event: ' + event_name);
} else {
NewgroundsAPI.SendEvent(NewgroundsAPI.custom_events[event_name]);
}
}
};
v1.loadCustomLink = function (link_name) {
if (!link_name) {
NewgroundsAPI.SendError('Missing required \'link_name\' parameter in NewgroundsAPI.loadCustomLink(link_name:String)');
} else {
if (!NewgroundsAPI.custom_links[link_name]) {
NewgroundsAPI.SendError('Attempted to open undefined custom link: ' + link_name);
} else {
NewgroundsAPI.SendLink(NewgroundsAPI.custom_links[link_name]);
}
}
};
v1.getAdURL = function () {
return NewgroundsAPI.movie_options.ad_url;
};
v1.getMovieURL = function () {
if (NewgroundsAPI.movie_options.movie_url) {
return NewgroundsAPI.movie_options.movie_url;
} else {
return 'Newgrounds.com';
}
};
v1.getNewVersionURL = function () {
return NewgroundsAPI.GATEWAY_URL + '?&id=' + NewgroundsAPI.tracker_id + '&host=' + escape(NewgroundsAPI.host) + '&stat=' + NewgroundsAPI.NEW_VERSION;
};
v1.SendEvent = function (id) {
NewgroundsAPI.SendStat(id, false);
};
v1.SendLink = function (id, extra) {
NewgroundsAPI.SendStat(id, true, extra);
};
v1.ReadGatewayData = function (params) {
for (var v2 in params) {
params[v2] = unescape(params[v2]);
NewgroundsAPI.movie_options[v2] = params[v2];
}
if (params.settings_loaded) {
NewgroundsAPI.SendMessage('You have successfully connected to the Newgrounds API gateway!');
NewgroundsAPI.SendMessage('Movie Identified as \'' + NewgroundsAPI.movie_options.movie_name + '\'');
if (NewgroundsAPI.movie_options.message) {
NewgroundsAPI.SendMessage(NewgroundsAPI.movie_options.message);
}
if (NewgroundsAPI.movie_options.ad_url) {
NewgroundsAPI.SendMessage('Your movie has been approved to run Flash Ads');
NewgroundsAPI.onAdsApproved(NewgroundsAPI.movie_options.ad_url);
}
if (NewgroundsAPI.movie_options.movie_version and NewgroundsAPI.movie_options.movie_version.toString() != NewgroundsAPI.version.toString()) {
NewgroundsAPI.SendMessage('WARNING: The movie version configured in your API settings does not match this movie\'s version!');
NewgroundsAPI.onNewVersionAvailable(NewgroundsAPI.movie_options.movie_version, NewgroundsAPI.getMovieURL(), NewgroundsAPI.getNewVersionURL());
}
if (NewgroundsAPI.movie_options.deny_host) {
NewgroundsAPI.SendMessage('You have blocked \'localHost\' in your API settings.');
NewgroundsAPI.SendMessage('If you wish to test your movie you will need to remove this block.');
NewgroundsAPI.onDenyHost(NewgroundsAPI.host, NewgroundsAPI.getMovieURL(), NewgroundsAPI.getNewVersionURL());
}
if (NewgroundsAPI.movie_options.request_portal_url == 1) {
var v4 = NewgroundsAPI.GATEWAY_URL + '?&id=' + NewgroundsAPI.tracker_id + '&portal_url=' + escape(_url);
var v3 = new XML();
v3.ignoreWhite = true;
v3.load(v4);
}
} else {
if (!NewgroundsAPI.movie_options.settings_loaded) {
NewgroundsAPI.SendError('Could not establish connection to the API gateway.');
}
}
};
v1.SendStat = function (stat_id, open_in_browser, extra) {
if (!NewgroundsAPI.tracker_id) {
NewgroundsAPI.SendError('API calls cannot be made without a valid movie id.');
NewgroundsAPI.SendError('Did you remember to add the "NewgroundsAPI.connectMovie()" code?');
} else {
var v7 = NewgroundsAPI.GATEWAY_URL + '?&id=' + NewgroundsAPI.tracker_id + '&host=' + escape(NewgroundsAPI.host) + '&stat=' + stat_id;
for (var v9 in extra) {
v7 += '&' + escape(v9) + '=' + escape(extra[v9]);
}
trace(v7);
if (NewgroundsAPI.debug) {
v7 += '&debug=1';
}
if (open_in_browser) {
getURL(v7, '_blank');
} else {
var v10 = new XML();
v10.ignoreWhite = true;
v10.onLoad = function (success) {
var v6 = new Object();
var v3 = 0;
while (v3 < this.firstChild.childNodes.length) {
var v4 = this.firstChild.childNodes[v3];
var v5 = v4.nodeName;
var v2 = v4.attributes.value;
if (v2 == Number(v2)) {
v2 = Number(v2);
}
v6[v5] = v2;
++v3;
}
NewgroundsAPI.ReadGatewayData(v6);
};
v10.load(v7);
}
}
};
v1.SendError = function (msg) {
trace('[NEWGROUNDS API ERROR] :: ' + msg);
};
v1.SendMessage = function (msg) {
trace('[NEWGROUNDS API] :: ' + msg);
};
v1.InitTextFormats = function () {
if (!NewgroundsAPI.error_format) {
NewgroundsAPI.error_format = new TextFormat();
NewgroundsAPI.error_format.font = 'Arial Black';
NewgroundsAPI.error_format.size = 48;
NewgroundsAPI.error_format.color = 16711680;
}
if (!NewgroundsAPI.header_format) {
NewgroundsAPI.header_format = new TextFormat();
NewgroundsAPI.header_format.font = 'Arial Black';
NewgroundsAPI.header_format.size = 24;
NewgroundsAPI.header_format.color = 16777215;
}
if (!NewgroundsAPI.normal_format) {
NewgroundsAPI.normal_format = new TextFormat();
NewgroundsAPI.normal_format.font = 'Arial';
NewgroundsAPI.normal_format.bold = true;
NewgroundsAPI.normal_format.size = 12;
NewgroundsAPI.normal_format.color = 16777215;
}
if (!NewgroundsAPI.link_format) {
NewgroundsAPI.link_format = new TextFormat();
NewgroundsAPI.link_format.color = 16776960;
NewgroundsAPI.link_format.underline = true;
}
};
v1.onNewVersionAvailable = function (version, movie_url, redirect_url) {
NewgroundsAPI.InitTextFormats();
var v2 = new Object();
v2.x = Stage.width / 2;
v2.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(v2.x - 240, v2.y - 120);
_root.NGAPI_new_version_overlay.lineTo(v2.x + 240, v2.y - 120);
_root.NGAPI_new_version_overlay.lineTo(v2.x + 240, v2.y + 80);
_root.NGAPI_new_version_overlay.lineTo(v2.x - 240, v2.y + 80);
_root.NGAPI_new_version_overlay.lineTo(v2.x - 240, v2.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(v2.x + 210, v2.y - 110);
_root.NGAPI_new_version_overlay.exit.lineTo(v2.x + 230, v2.y - 110);
_root.NGAPI_new_version_overlay.exit.lineTo(v2.x + 230, v2.y - 90);
_root.NGAPI_new_version_overlay.exit.lineTo(v2.x + 210, v2.y - 90);
_root.NGAPI_new_version_overlay.exit.lineTo(v2.x + 210, v2.y - 110);
_root.NGAPI_new_version_overlay.exit.endFill();
_root.NGAPI_new_version_overlay.exit.moveTo(v2.x + 214, v2.y - 106);
_root.NGAPI_new_version_overlay.exit.lineTo(v2.x + 226, v2.y - 94);
_root.NGAPI_new_version_overlay.exit.moveTo(v2.x + 226, v2.y - 106);
_root.NGAPI_new_version_overlay.exit.lineTo(v2.x + 214, v2.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 v3 = 'Version ' + version + ' is now available at:' + '\n';
var v5 = v3.length;
v3 += movie_url;
var v4 = v3.length;
_root.NGAPI_new_version_overlay.createTextField('mouseblocker', 99, -10, -10, 1000, 1000);
_root.NGAPI_new_version_overlay.createTextField('newversion', 100, v2.x - 210, v2.y - 90, 400, 80);
_root.NGAPI_new_version_overlay.newversion.text = 'New Version Available!';
_root.NGAPI_new_version_overlay.newversion.setTextFormat(NewgroundsAPI.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 = v3;
_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(NewgroundsAPI.normal_format);
NewgroundsAPI.link_format.url = redirect_url;
_root.NGAPI_new_version_overlay.message.setTextFormat(v5, v4, NewgroundsAPI.link_format);
};
v1.onDenyHost = function (hostname, movie_url, redirect_url) {
NewgroundsAPI.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 v2 = 'This movie has not been approved for use on ' + hostname + '.';
v2 += '\r\rFor an aproved copy, please visit:\r';
var v4 = v2.length;
v2 += movie_url;
var v3 = v2.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(NewgroundsAPI.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 = v2;
_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(NewgroundsAPI.normal_format);
NewgroundsAPI.link_format.url = redirect_url;
_root.NGAPI_deny_host_overlay.message.setTextFormat(v4, v3, NewgroundsAPI.link_format);
};
v1.isInstalled = function () {
return true;
};
v1.onAdsApproved = function (ad_url) {};
v1.movie_options = new Object();
v1.custom_events = new Object();
v1.custom_links = new Object();
v1.MOVIE_VIEWS = 1;
v1.AUTHOR_SITE = 2;
v1.NEWGROUNDS = 3;
v1.NEW_VERSION = 4;
v1.CUSTOM_STATS = 50;
v1.GATEWAY_URL = 'http://www.ngads.com/gateway.php';
ASSetPropFlags(_global.NewgroundsAPI.prototype, null, 1);
}
#endinitclip
}
frame 2 {
function checkArray(ar, st) {
found = false;
q = 0;
while (q < ar.length) {
if (ar[q] == st) {
found = true;
break;
}
++q;
}
return found;
}
function playSound(link) {
if (!mute) {
_root['sound_' + link] = new Sound();
_root['sound_' + link].attachSound(link);
_root['sound_' + link].start();
}
}
function breakTile() {
if (onExists) {
if (onObject.ob == 'break') {
onObject.play();
_root.playSound('tile');
}
}
}
function checkWin() {
if (inGame && canMove) {
win = true;
for (var v2 in _root) {
if (_root[v2].ob == 'block' || _root[v2].ob == 'player' || _root[v2].ob == 'hole' || _root[v2].ob == undefined || _root[v2]._name == 'chooser' || _root[v2].ob == 'combine' || _root[v2].ob == 'animation' || _root[v2].ob == 'inst') {
null;
} else {
win = false;
break;
}
}
if (win) {
newd = _root.getNextHighestDepth();
attachMovie('message', 'message' + newd, newd);
_root['message' + newd]._x = 0;
_root['message' + newd]._y = 0;
inGame = false;
}
}
}
function moveUP() {
if (!_root.instructing && !popup) {
if (canMove && inGame) {
thingExists = false;
farExists = false;
for (var v2 in _root) {
if (_root[v2].currentY == _root.player.currentY - 1 && _root[v2].currentX == _root.player.currentX && _root[v2].ob != 'break' && _root[v2].ob != '' && _root[v2].ob != undefined) {
thingExists = true;
theObject = _root[v2];
}
if (_root[v2].currentY == _root.player.currentY - 2 && _root[v2].currentX == _root.player.currentX && _root[v2]._name != 'animation' && _root[v2].ob != 'break' && _root[v2].ob != '' && _root[v2].ob != undefined) {
farExists = true;
farObject = _root[v2];
}
if (_root[v2].currentY == _root.player.currentY && _root[v2].currentX == _root.player.currentX && _root[v2]._name != 'player' && _root[v2].ob != '' && _root[v2].ob != undefined) {
onExists = true;
onObject = _root[v2];
}
}
if (thingExists) {
if (_root.theObject.ob == 'square') {
if (!farExists) {
_root.moveObject('up');
_root.movePlayer('up');
} else {
if (farObject.ob == 'square') {
_root.aCombine(2, 1);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('up');
} else {
if (farObject.ob == 'hole') {
_root.playSound('clunk');
_root.intoHole(2, 1);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('up');
} else {
if (farObject.ob == 'break') {
_root.moveObject('up');
_root.movePlayer('up');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'triangle') {
if (!farExists) {
_root.moveObject('up');
_root.movePlayer('up');
} else {
if (farObject.ob == 'triangle') {
_root.aCombine(2, 2);
_root.theObject.unloadMovie();
_root.farObject.ob = 'block';
_root.farObject.gotoAndStop(6);
_root.movePlayer('up');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(2, 2);
_root.theObject.unloadMovie();
_root.movePlayer('up');
} else {
if (farObject.ob == 'break') {
_root.moveObject('up');
_root.movePlayer('up');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'plus') {
if (!farExists) {
_root.moveObject('up');
_root.movePlayer('up');
} else {
if (farObject.ob == 'plus') {
_root.theObject.unloadMovie();
_root.chooser.swapDepths(_root.getNextHighestDepth());
_root.chooser._x = _root.farObject._x;
_root.chooser._y = _root.farObject._y;
_root.aCombine(2, 3);
_root.farObject.unloadMovie();
_root.player._alpha = 0;
_root.canMove = false;
_root.diamondSelect = true;
_root.movePlayer('up');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(2, 3);
_root.theObject.unloadMovie();
_root.movePlayer('up');
} else {
if (farObject.ob == 'break') {
_root.moveObject('up');
_root.movePlayer('up');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'circle') {
if (!farExists) {
_root.moveObject('up');
_root.movePlayer('up');
} else {
if (farObject.ob == 'circle') {
_root.aCombine(2, 4);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('up');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(2, 4);
_root.theObject.unloadMovie();
_root.movePlayer('up');
} else {
if (farObject.ob == 'break') {
_root.moveObject('up');
_root.movePlayer('up');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'break') {
_root.movePlayer('up');
}
}
}
}
}
} else {
_root.movePlayer('up');
_root.playSound('move');
}
} else {
if (_root.diamondSelect) {
_root.playSound('scroll');
if (_root.chooser._currentframe == _root.chooser._totalframes) {
_root.chooser.gotoAndStop(1);
} else {
_root.chooser.nextFrame();
}
}
}
}
}
function moveLEFT() {
if (!_root.instructing && !popup) {
if (canMove && inGame) {
checkWin();
thingExists = false;
farExists = false;
for (var v2 in _root) {
if (_root[v2].currentX == _root.player.currentX - 1 && _root[v2].currentY == _root.player.currentY && _root[v2].ob != 'break' && _root[v2].ob != '' && _root[v2].ob != undefined) {
thingExists = true;
theObject = _root[v2];
}
if (_root[v2].currentX == _root.player.currentX - 2 && _root[v2].currentY == _root.player.currentY && _root[v2]._name != 'animation' && _root[v2].ob != 'break' && _root[v2].ob != '' && _root[v2].ob != undefined) {
farExists = true;
farObject = _root[v2];
}
if (_root[v2].currentY == _root.player.currentY && _root[v2].currentX == _root.player.currentX && _root[v2]._name != 'player' && _root[v2].ob != '' && _root[v2].ob != undefined) {
onExists = true;
onObject = _root[v2];
}
}
if (thingExists) {
if (_root.theObject.ob == 'square') {
if (!farExists) {
_root.moveObject('left');
_root.movePlayer('left');
} else {
if (farObject.ob == 'square') {
_root.aCombine(3, 1);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('left');
} else {
if (farObject.ob == 'hole') {
_root.playSound('clunk');
_root.intoHole(3, 1);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('left');
} else {
if (farObject.ob == 'break') {
_root.moveObject('left');
_root.movePlayer('left');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'triangle') {
if (!farExists) {
_root.moveObject('left');
_root.movePlayer('left');
} else {
if (farObject.ob == 'triangle') {
_root.aCombine(3, 2);
_root.theObject.unloadMovie();
_root.farObject.ob = 'block';
_root.farObject.gotoAndStop(6);
_root.movePlayer('left');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(3, 2);
_root.theObject.unloadMovie();
_root.movePlayer('left');
} else {
if (farObject.ob == 'break') {
_root.moveObject('left');
_root.movePlayer('left');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'plus') {
if (!farExists) {
_root.moveObject('left');
_root.movePlayer('left');
} else {
if (farObject.ob == 'plus') {
_root.theObject.unloadMovie();
_root.chooser.swapDepths(_root.getNextHighestDepth());
_root.chooser._x = _root.farObject._x;
_root.chooser._y = _root.farObject._y;
_root.aCombine(3, 3);
_root.farObject.unloadMovie();
_root.player._alpha = 0;
_root.canMove = false;
_root.diamondSelect = true;
_root.movePlayer('left');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(3, 3);
_root.theObject.unloadMovie();
_root.movePlayer('left');
} else {
if (farObject.ob == 'break') {
_root.moveObject('left');
_root.movePlayer('left');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'circle') {
if (!farExists) {
_root.moveObject('left');
_root.movePlayer('left');
} else {
if (farObject.ob == 'circle') {
_root.aCombine(3, 4);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('left');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(3, 4);
_root.theObject.unloadMovie();
_root.movePlayer('left');
} else {
if (farObject.ob == 'break') {
_root.moveObject('left');
_root.movePlayer('left');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'break') {
_root.movePlayer('left');
}
}
}
}
}
} else {
_root.movePlayer('left');
_root.playSound('move');
}
}
}
}
function moveDOWN() {
if (!_root.instructing && !popup) {
if (canMove && inGame) {
checkWin();
thingExists = false;
farExists = false;
for (var v2 in _root) {
if (_root[v2].currentY == _root.player.currentY + 1 && _root[v2].currentX == _root.player.currentX && _root[v2].ob != 'break' && _root[v2].ob != '' && _root[v2].ob != undefined) {
thingExists = true;
theObject = _root[v2];
}
if (_root[v2].currentY == _root.player.currentY + 2 && _root[v2].currentX == _root.player.currentX && _root[v2]._name != 'animation' && _root[v2].ob != 'break' && _root[v2].ob != '' && _root[v2].ob != undefined) {
farExists = true;
farObject = _root[v2];
}
if (_root[v2].currentY == _root.player.currentY && _root[v2].currentX == _root.player.currentX && _root[v2]._name != 'player' && _root[v2].ob != '' && _root[v2].ob != undefined) {
onExists = true;
onObject = _root[v2];
}
}
if (thingExists) {
if (_root.theObject.ob == 'square') {
if (!farExists) {
_root.moveObject('down');
_root.movePlayer('down');
} else {
if (farObject.ob == 'square') {
_root.aCombine(4, 1);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('down');
} else {
if (farObject.ob == 'hole') {
_root.playSound('clunk');
_root.intoHole(4, 1);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('down');
} else {
if (farObject.ob == 'break') {
_root.moveObject('down');
_root.movePlayer('down');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'triangle') {
if (!farExists) {
_root.moveObject('down');
_root.movePlayer('down');
} else {
if (farObject.ob == 'triangle') {
_root.aCombine(4, 2);
_root.theObject.unloadMovie();
_root.farObject.ob = 'block';
_root.farObject.gotoAndStop(6);
_root.movePlayer('down');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(4, 2);
_root.theObject.unloadMovie();
_root.movePlayer('down');
} else {
if (farObject.ob == 'break') {
_root.moveObject('down');
_root.movePlayer('down');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'plus') {
if (!farExists) {
_root.moveObject('down');
_root.movePlayer('down');
} else {
if (farObject.ob == 'plus') {
_root.theObject.unloadMovie();
_root.chooser.swapDepths(_root.getNextHighestDepth());
_root.chooser._x = _root.farObject._x;
_root.chooser._y = _root.farObject._y;
_root.aCombine(4, 3);
_root.farObject.unloadMovie();
_root.player._alpha = 0;
_root.canMove = false;
_root.diamondSelect = true;
_root.movePlayer('down');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(4, 3);
_root.theObject.unloadMovie();
_root.movePlayer('down');
} else {
if (farObject.ob == 'break') {
_root.moveObject('down');
_root.movePlayer('down');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'circle') {
if (!farExists) {
_root.moveObject('down');
_root.movePlayer('down');
} else {
if (farObject.ob == 'circle') {
_root.aCombine(4, 4);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('down');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(4, 4);
_root.theObject.unloadMovie();
_root.movePlayer('down');
} else {
if (farObject.ob == 'break') {
_root.moveObject('down');
_root.movePlayer('down');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'break') {
_root.movePlayer('down');
}
}
}
}
}
} else {
_root.movePlayer('down');
_root.playSound('move');
}
} else {
if (_root.diamondSelect) {
_root.playSound('scroll');
if (_root.chooser._currentframe == 1) {
_root.chooser.gotoAndStop(_root.chooser._totalframes);
} else {
_root.chooser.prevFrame();
}
}
}
}
}
function moveRIGHT() {
if (!_root.instructing && !popup) {
if (canMove && inGame) {
checkWin();
thingExists = false;
farExists = false;
for (var v2 in _root) {
if (_root[v2].currentX == _root.player.currentX + 1 && _root[v2].currentY == _root.player.currentY && _root[v2].ob != 'break' && _root[v2].ob != '' && _root[v2].ob != undefined) {
thingExists = true;
theObject = _root[v2];
}
if (_root[v2].currentX == _root.player.currentX + 2 && _root[v2].currentY == _root.player.currentY && _root[v2]._name != 'animation' && _root[v2].ob != 'break' && _root[v2].ob != '' && _root[v2].ob != undefined) {
farExists = true;
farObject = _root[v2];
}
if (_root[v2].currentY == _root.player.currentY && _root[v2].currentX == _root.player.currentX && _root[v2]._name != 'player' && _root[v2].ob != '' && _root[v2].ob != undefined) {
onExists = true;
onObject = _root[v2];
}
}
if (thingExists) {
if (_root.theObject.ob == 'square') {
if (!farExists) {
_root.moveObject('right');
_root.movePlayer('right');
} else {
if (farObject.ob == 'square') {
_root.aCombine(5, 1);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('right');
} else {
if (farObject.ob == 'hole') {
_root.playSound('clunk');
_root.intoHole(5, 1);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('right');
} else {
if (farObject.ob == 'break') {
_root.moveObject('right');
_root.movePlayer('right');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'triangle') {
if (!farExists) {
_root.moveObject('right');
_root.movePlayer('right');
} else {
if (farObject.ob == 'triangle') {
_root.aCombine(5, 2);
_root.theObject.unloadMovie();
_root.farObject.ob = 'block';
_root.farObject.gotoAndStop(6);
_root.movePlayer('right');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(5, 2);
_root.theObject.unloadMovie();
_root.movePlayer('right');
} else {
if (farObject.ob == 'break') {
_root.moveObject('right');
_root.movePlayer('right');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'plus') {
if (!farExists) {
_root.moveObject('right');
_root.movePlayer('right');
} else {
if (farObject.ob == 'plus') {
_root.theObject.unloadMovie();
_root.chooser.swapDepths(_root.getNextHighestDepth());
_root.chooser._x = _root.farObject._x;
_root.chooser._y = _root.farObject._y;
_root.aCombine(5, 3);
_root.farObject.unloadMovie();
_root.player._alpha = 0;
_root.canMove = false;
_root.diamondSelect = true;
_root.movePlayer('right');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(5, 3);
_root.theObject.unloadMovie();
_root.movePlayer('right');
} else {
if (farObject.ob == 'break') {
_root.moveObject('right');
_root.movePlayer('right');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'circle') {
if (!farExists) {
_root.moveObject('right');
_root.movePlayer('right');
} else {
if (farObject.ob == 'circle') {
_root.aCombine(5, 4);
_root.theObject.unloadMovie();
_root.farObject.unloadMovie();
_root.movePlayer('right');
} else {
if (farObject.ob == 'hole') {
_root.playSound('fall');
_root.intoHole(5, 4);
_root.theObject.unloadMovie();
_root.movePlayer('right');
} else {
if (farObject.ob == 'break') {
_root.moveObject('right');
_root.movePlayer('right');
_root.theObject.swapDepths(_root.getNextHighestDepth());
}
}
}
}
} else {
if (_root.theObject.ob == 'break') {
_root.movePlayer('right');
}
}
}
}
}
} else {
_root.movePlayer('right');
_root.playSound('move');
}
}
}
}
function movePlayer(dir) {
_root.breakTile();
if (dir == 'up') {
_root.player._y -= 30;
--_root.player.currentY;
_root.player.gotoAndStop(2);
} else {
if (dir == 'left') {
_root.player._x -= 30;
--_root.player.currentX;
_root.player.gotoAndStop(3);
} else {
if (dir == 'down') {
_root.player._y += 30;
++_root.player.currentY;
_root.player.gotoAndStop(4);
} else {
if (dir == 'right') {
_root.player._x += 30;
++_root.player.currentX;
_root.player.gotoAndStop(5);
}
}
}
}
++_root.movesLog;
}
function moveObject(dir) {
_root.playSound('push');
_root.theObject.swapDepths(_root.getNextHighestDepth());
if (dir == 'up') {
_root.theObject._y -= 30;
--_root.theObject.currentY;
_root.theObject.gotoAndStop(2);
} else {
if (dir == 'left') {
_root.theObject._x -= 30;
--_root.theObject.currentX;
_root.theObject.gotoAndStop(3);
} else {
if (dir == 'down') {
_root.theObject._y += 30;
++_root.theObject.currentY;
_root.theObject.gotoAndStop(4);
} else {
if (dir == 'right') {
_root.theObject._x += 30;
++_root.theObject.currentX;
_root.theObject.gotoAndStop(5);
}
}
}
}
}
function intoHole(frame, ob) {
_root.playSound('push');
_root.animation._x = _root.farObject._x;
_root.animation._y = _root.farObject._y;
_root.animation.gotoAndStop(frame);
_root.animation.clip.shape.gotoAndStop(ob);
_root.animation.swapDepths(_root.getNextHighestDepth());
}
function aCombine(frame, ob) {
_root.playSound('push');
_root.combine._x = _root.farObject._x;
_root.combine._y = _root.farObject._y;
_root.combine.gotoAndStop(frame);
_root.combine.clip.shape.gotoAndStop(ob);
_root.playSound('combine');
_root.combine.swapDepths(_root.getNextHighestDepth());
}
function choose(what) {
if (!_root.instructing && !popup) {
_root.playSound('click');
z = _root.getNextHighestDepth();
attachMovie(what, what + z, z);
_root[what + z]._x = _root.chooser._x;
_root[what + z]._y = _root.chooser._y;
_root[what + z].currentX = _root[what + z]._x / 30;
_root[what + z].currentY = _root[what + z]._y / 30;
_root[what + z].ob = what;
_root[what + z].fromPlus = true;
_root.chooser._x = 999;
_root.chooser._y = 999;
_root.player._alpha = 100;
_root.canMove = true;
_root.diamondSelect = false;
}
}
function loadLevel(lv) {
_root.diamondSelect = false;
lv = (lv.split(' ')).join('');
for (var v2 in _root) {
if (_root[v2].canClear || _root[v2].fromPlus) {
_root[v2].unloadMovie();
_root[v2].removeMovieClip();
}
}
item = lv.split(';');
keys = new Array('player', 'block', 'square', 'circle', 'triangle', 'plus', 'hole', 'break');
j = 0;
while (j < item.length) {
nd = _root.getNextHighestDepth();
_root.zz = nd;
indiv = item[j].split(',');
if (indiv[2] != 0) {
attachMovie(keys[Math.round(parseInt(indiv[2]))], keys[Math.round(parseInt(indiv[2]))] + nd, nd);
_root[keys[indiv[2]] + nd].currentX = Math.round(parseInt(indiv[0]));
_root[keys[indiv[2]] + nd].currentY = Math.round(parseInt(indiv[1]));
_root[keys[indiv[2]] + nd]._x = _root[keys[indiv[2]] + nd].currentX * 30;
_root[keys[indiv[2]] + nd]._y = _root[keys[indiv[2]] + nd].currentY * 30;
_root[keys[indiv[2]] + nd].ob = keys[Math.round(parseInt(indiv[2]))];
_root[keys[indiv[2]] + nd].canClear = true;
} else {
_root.player.currentX = Math.round(parseInt(indiv[0]));
_root.player.currentY = Math.round(parseInt(indiv[1]));
_root.player._x = _root.player.currentX * 30;
_root.player._y = _root.player.currentY * 30;
_root.player.ob = keys[Math.round(parseInt(indiv[2]))];
}
++j;
}
_root.player.swapDepths(_root.getNextHighestDepth());
}
function reloadCreator(lv) {
_root.diamondSelect = false;
item = lv.split(';');
keys = new Array('player', 'block', 'square', 'circle', 'triangle', 'plus', 'hole', 'break');
j = 0;
while (j < item.length) {
nd = _root.getNextHighestDepth();
indiv = item[j].split(',');
if (indiv[2] != 0) {
attachMovie(keys[Math.round(parseInt(indiv[2]))], keys[Math.round(parseInt(indiv[2]))] + nd, nd);
_root[keys[indiv[2]] + nd].currentX = Math.round(parseInt(indiv[0]));
_root[keys[indiv[2]] + nd].currentY = Math.round(parseInt(indiv[1]));
_root[keys[indiv[2]] + nd]._x = _root[keys[indiv[2]] + nd].currentX * 25;
_root[keys[indiv[2]] + nd]._y = _root[keys[indiv[2]] + nd].currentY * 25;
_root[keys[indiv[2]] + nd].ob = keys[Math.round(parseInt(indiv[2]))];
_root[keys[indiv[2]] + nd].canClear = true;
_root[keys[indiv[2]] + nd]._width = 25;
_root[keys[indiv[2]] + nd]._height = 25;
} else {
dm = _root.getNextHighestDepth();
_root.attachMovie('player', 'playerMC', dm);
_root.playerMC.currentX = Math.round(parseInt(indiv[0]));
_root.playerMC.currentY = Math.round(parseInt(indiv[1]));
_root.playerMC._x = _root.playerMC.currentX * 25;
_root.playerMC._y = _root.playerMC.currentY * 25;
_root.playerMC._width = 25;
_root.playerMC._height = 25;
_root.playerMC.ob = 'player';
_root.playerPlaced = true;
_root.playerMC.createdByMaker = true;
}
++j;
}
_root.player.swapDepths(_root.getNextHighestDepth());
}
stop();
for (var i in _root) {
_root[i].initX = _root[i]._x / 30;
_root[i].initY = _root[i]._y / 30;
_root[i].currentX = _root[i].initX;
_root[i].currentY = _root[i].initY;
}
var savefile = SharedObject.getLocal('tolkaht');
_root.currentlevel = savefile.data.clevel;
_root.music = savefile.data.music;
_root.completed = savefile.data.completed;
if (savefile.data.clevel == undefined) {
_root.currentlevel = 0;
}
if (savefile.data.music == undefined) {
_root.music = true;
}
if (savefile.data.completed == undefined) {
_root.completed = 'Q';
savefile.data.completed = 'Q';
savefile.flush();
}
}
frame 2 {
levels = new Array(';11,7,0;13,7,2;14,7,6;', ';14,7,6;15,7,3;11,7,0;13,7,2;', ';14,8,3;13,8,3;14,6,2;13,6,2;11,7,0;', ';12,9,1;13,9,1;14,9,1;14,5,1;13,5,1;12,5,1;11,9,1;10,8,1;9,7,1;10,6,1;11,5,1;11,7,0;15,6,4;16,6,4;15,8,4;16,8,4;17,7,1;15,5,1;15,9,1;16,9,1;16,5,1;', ';13,6,0;12,8,5;12,9,5;14,9,3;', ';12,3,0;12,2,1;11,3,1;13,3,1;12,4,3;12,5,7;12,9,3;12,10,1;13,9,1;13,8,1;13,7,1;13,6,1;13,4,1;11,4,1;11,5,1;11,6,1;11,7,1;11,8,1;13,5,1;11,9,1;', ';8,7,0;10,7,7;11,7,7;12,7,7;13,7,7;14,7,7;15,7,7;16,7,7;', ';15,9,4;16,9,4;15,7,1;15,6,1;15,5,1;17,9,6;16,7,5;16,6,5;8,8,1;8,7,1;8,6,1;8,5,1;9,4,1;10,4,1;11,4,1;12,4,1;15,4,1;13,4,1;14,4,1;16,4,1;17,4,1;18,5,1;18,6,1;18,7,1;18,8,1;18,9,1;17,10,1;16,10,1;15,10,1;14,10,1;13,10,1;12,10,1;11,10,1;10,10,1;8,9,1;9,10,1;12,8,0;', ';17,8,0;18,6,1;7,7,1;7,8,1;7,5,1;7,3,1;7,4,1;8,2,1;9,2,1;10,2,1;12,2,1;13,2,1;11,2,1;14,2,1;15,2,1;16,2,1;17,2,1;18,3,1;18,4,1;18,5,1;18,7,1;18,8,1;17,9,1;16,9,1;15,9,1;14,9,1;13,9,1;11,9,1;10,9,1;9,9,1;8,9,1;12,9,1;7,6,1;8,5,1;9,5,1;11,5,1;12,5,1;13,5,1;14,5,1;16,5,1;17,5,1;12,7,1;14,7,1;15,7,1;16,7,1;11,7,1;10,7,1;9,7,1;11,6,3;12,4,5;14,4,5;17,7,4;11,4,5;15,4,5;', ';15,6,1;15,7,1;15,8,1;15,5,1;15,4,1;14,9,1;14,3,1;13,3,1;12,3,1;11,3,1;10,3,1;9,4,1;9,5,1;9,6,1;9,7,1;9,8,1;10,9,1;11,9,1;12,9,1;13,9,1;11,5,5;12,5,5;13,5,5;13,6,5;13,7,5;12,7,5;11,7,5;11,6,5;12,6,0;', ';17,6,0;12,5,6;12,6,6;12,8,6;13,8,6;13,7,6;13,6,6;13,5,6;11,6,6;11,7,6;11,8,6;12,3,1;14,3,1;13,3,1;15,3,1;16,3,1;17,3,1;18,4,1;18,5,1;18,6,1;18,7,1;18,8,1;17,9,1;15,9,1;16,9,1;14,9,1;13,9,1;12,9,1;11,9,1;10,9,1;9,9,1;8,9,1;7,8,1;7,7,1;7,6,1;7,5,1;7,4,1;8,3,1;10,3,1;9,3,1;12,4,6;13,4,6;11,4,6;11,2,1;11,3,4;15,6,2;15,7,2;16,7,2;15,5,5;16,5,5;', _root.decodeLevel('f26926j65565e25a255214313413513613713813914a15b16c17c19c18c1611711911811a11b11c11e11d11i11h11f11g11j21k31ac1bc1dc1cc1fc1ec1hc1gc1ic1jb1ka1l91l81l71l61l51l41k44494k94444551581681651j51i51j81i817918a1741831h41g31h91ga1821g21gb18b1591541j41j91a64e74774h64c60963873f73g639a1fa1f31931g51851891g91'), ';11,10,7;8,8,0;6,4,1;7,4,1;8,4,1;9,4,1;11,4,1;12,4,1;13,4,1;14,4,1;15,4,1;17,4,1;16,4,1;10,4,1;5,5,1;5,6,1;5,7,1;5,8,1;5,10,1;5,9,1;6,11,1;7,11,1;8,11,1;9,11,1;10,11,1;12,11,1;11,11,1;14,11,1;15,11,1;16,11,1;17,11,1;13,11,1;18,10,1;18,9,1;18,8,1;18,7,1;18,6,1;18,5,1;8,6,5;8,7,5;9,7,5;9,8,5;11,5,7;11,6,7;11,7,7;11,9,7;14,6,1;16,6,1;16,7,1;16,8,1;16,9,1;15,9,1;14,9,1;13,6,1;15,5,1;12,9,5;12,8,5;15,6,4;13,7,6;13,8,6;14,10,1;10,8,7;', ';8,6,0;14,9,1;16,4,7;15,4,7;16,3,7;15,3,7;16,2,7;15,2,7;16,7,7;15,7,7;16,6,7;15,6,7;16,5,7;15,5,7;16,9,6;16,10,2;16,1,7;15,1,7;6,6,4;6,7,1;6,5,1;7,5,1;11,3,1;12,4,1;12,5,1;12,6,1;9,1,1;10,1,1;8,2,1;10,5,4;11,7,1;11,8,1;11,9,1;8,3,1;9,4,1;10,3,2;15,12,6;15,11,1;14,10,1;13,12,7;13,11,7;9,11,5;8,11,5;8,10,7;8,12,3;7,8,1;7,7,1;8,8,6;8,7,2;9,7,1;9,5,1;10,6,4;9,6,4;7,12,1;7,11,1;7,10,1;7,9,1;5,6,1;8,5,1;17,13,1;10,13,1;9,13,1;10,13,1;9,13,1;16,13,1;15,13,1;14,13,1;13,13,1;12,13,1;11,13,1;8,13,1;18,12,1;18,11,1;18,10,1;18,9,1;18,8,1;18,7,1;17,1,1;13,10,1;12,10,1;13,10,1;12,10,1;16,0,1;15,0,1;14,1,1;13,1,1;12,1,1;11,1,1;11,10,1;10,10,1;9,10,1;18,6,1;18,5,1;18,4,1;18,3,1;18,2,1;', ';18,9,1;18,7,1;18,6,1;18,8,1;18,10,1;15,11,1;17,11,1;16,11,1;14,11,1;13,11,1;12,11,1;11,11,1;10,11,1;9,11,1;8,11,1;7,11,1;6,10,1;6,9,1;6,8,1;6,7,1;6,6,1;6,5,1;18,5,1;15,4,1;17,4,1;16,4,1;14,4,1;13,4,1;12,4,1;11,4,1;10,4,1;9,4,1;8,4,1;7,4,1;16,6,0;7,7,6;7,8,6;14,6,2;14,10,2;12,8,2;10,6,2;10,9,2;10,10,4;12,6,4;14,8,4;10,5,3;12,9,3;12,5,3;14,7,3;10,8,5;10,7,5;12,10,5;12,7,5;14,9,5;14,5,5;', _root.decodeLevel('nd49a1597744524421621881981a71b61b51b41b31a219218317214014415112352251912902a13913713613510810711511411314313012011611111213373874a15a1691681671661546631536552755955a338633a48919b19c18c16c17c15c18d5ba5cd1cc1cb1ca1c91c33f81e91d91f71f61f51f41f31f21h01j71k71od7o92'), _root.decodeLevel('c97ca58a1d74b51b61a61d51d61e61e81d81d91b91b81a81c70da1db1cc1a91bc1ac19618517517c19c18c1981991891881ba1aa19a16616716816916c15a15b1c85b75a75e71b41e21e31d41b01c01d01e11931a01911921a41b22c64'), _root.decodeLevel('ic1e15845916921815ia1i91i81i71i61h61g71g61g51g41f31e31c31d31b31a319419519619719316274175173172174275276116314412344754852612411413615815717618618717948a49a18b16c76b16a15a15910d10c10b1081071061051041031021011001101201301501401601801901701a01b01d01c01o01m01k01l01i01j01g01f01h01e01o11o21o31o41o51o61o71o81o91oa1ob1oc1od1nd1ld1jd1md1kd1hd1id1fd1gd1ed1dd1cd1ad1bd19d17d18d16d15d14d13d12d11d11c0n04m17n27m21h34i31i21j21k21l21g31g21m31m41l51l61l81l91la1ma1mb1nb1g16j33n85n75kb5ka51b52b52c54913911812813811171378256578c1996986c95c85b95b85b75c75d75d85d95ba5ca5da5a44646i55'), _root.decodeLevel('3a1391381371361351341331321411511611711811911a11b11c11e11d11g11f11h11i11j11k11l21l31l41l61l71l81l91la14b16b15b17b18b19b1bb1ab1db1cb1eb1fb1gb1hb1ib1jb1kb1j52k53k42k62k77j77i77i67i57i47i37j37k37l56h44h54h64k95j95i95h95f95g95e95c95d95b95a95995895795695595495533m54n54oa1o81o91o71o61o51o41o31o21n21m21na1ma1m83m43n93n73460'), _root.decodeLevel('390e45e55565555595695795995895a95b95d95c95e95f95g95g85g75g65g55g45g35g25f25e25c25d25b25a25925825725625525425325335345355365375385495f11d11311411511611711811911a11b11c11e11g11h11h21h31h41h51h61h71h81h91ha1ga1fa1ea1da1ba1ca1aa18a19a17a16a15a14a13a12a1291281211221231251241261271'), _root.decodeLevel('fc0oa7o97o87o77o67o47o57o37o27o17o07n07m07l07k07j07i07h07g03f03e07d07b07c07a079078077077177277377477577677777877977a7na1n71n91n81n61n51n41n31n21n11l11m11k11j11h11i11g11d11e11f11c11911b11a118118218318418518618818718918a1c87b87d87e87f87g87h87i87j87k87k77k57k67k47k37j37i37h37g37f37d37e37c37b37b47b57b67b77g73f73h72g62f62e72i74h64g54f54e64d74j75i65h55g45f45e55d65c758b18c1nb1nc1oc48d4'), _root.decodeLevel('ec1kb1ia1i91ka1k91ja3641745545ga7977c47b47a479476a79a79974b4a84g84g94a75875f95fa5fb5d807b18b19819614a1db1cb1ca1c91c81c71c61c51b51a51951j45j72i72i62j62k62m71m81m91ma1mb1mc1m61m51m41m31m21l21k21j21i21h21g21f21e21d21c31b31a319318217216215214213213313413513613713813913a13b1kc1lc1jc1ic1hc1gc1fc1dc1bc1ac19c18c17c16c15c14c13c1da3d33f41g41h41g51f51f61g61'), _root.decodeLevel('b57l71l31k21755665881571561g42g82h65f65g63e53i73k61h71f71f51i51h51d84i21j21h31g21f21e31d31c31b41b61c61b71b81b91ca1da1e91fa1ga1h91i91j91k91l61l81l51l41k80a61a319318316417315314312413411511611712813811911a12b13b14b15a16a17a18a19a1aa1984393j44k53d54'), _root.decodeLevel('623e94412867b91b81b71961a61a77977877887987a87a979978903313413513613713813913a14a15a17a16a18a19a1aa1ba1ca1da1ea1fa1ga1ha1h91h81h71h61h51h41h31h21h11h01g01e01d01c01a01901801701501401301311321601b01f01721731741751761781771791716817g42d72f54e54g83g33f75f65d53g63557657577594524477487587671451g74e75681444434645635c75c85855845'), _root.decodeLevel('491481471461451441431421521721921a21c21d21f21g21i41i51i61i71i81i91g91f91d91b91991891691591791a91c91e91h91e21b21821621587687787887987a87b87c87d87e87f87g87h87h67g67f67e67d67c67b67a67967867767667567547647747947847a47b47c47d47e47f47g47h47g37g57g77e77e57e37c37c57c77a77a57a37837857877677657637i21h27i37j37f55533570f73h17h35'));
numLevels = levels.length;
j = 0;
while (j < levels.length) {
_root['level' + j] = levels[j];
++j;
}
}
movieClip 37 {
frame 116 {
stop();
}
}
button 38 {
on (press) {
NewgroundsAPI.loadMySite();
}
}
movieClip 40 {
}
movieClip 44 {
}
movieClip 45 {
}
movieClip 48 {
}
movieClip 52 {
}
movieClip 55 {
}
movieClip 56 {
}
movieClip 58 {
}
movieClip 59 {
}
movieClip 60 {
}
button 62 {
on (press) {
getURL('http://www.newgrounds.com/', '_blank');
}
}
movieClip 63 {
frame 264 {
stop();
if (_root.l == undefined || _root.l == '') {
_root.play();
} else {
_root.level = _root.decodeLevel(_root.l);
_root.newGame = false;
_root.continueGame = false;
_root.fromTester = false;
_root.fromImport = false;
_root.jumpGame = true;
_root.currentlevel = 0;
_root.gotoAndStop('engine');
}
}
}
movieClip 71 {
}
// unknown tag 88 length 96
button 80 {
on (press) {
_root.playSound('click');
System.setClipboard(_root.encodeLevel(_root.level));
}
}
button 84 {
on (press) {
_root.inExport = false;
this.removeMovieClip();
}
}
movieClip 85 exportPanel {
frame 1 {
Selection.setFocus('exportText');
Selection.setSelection(0, exportText.text.length);
}
}
movieClip 88 messageCreate {
}
movieClip 90 message {
}
movieClip 92 block {
}
movieClip 93 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 94 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 95 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 96 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 97 plus {
frame 1 {
stop();
}
}
movieClip 99 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 100 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 101 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 102 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 103 circle {
frame 1 {
stop();
}
}
movieClip 105 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 106 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 107 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 108 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 110 triangle {
frame 1 {
stop();
}
}
movieClip 111 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 112 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 113 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 114 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 115 square {
frame 1 {
stop();
}
}
movieClip 116 changer {
frame 1 {
ob = 'triangle';
obt = 'changer';
stop();
}
instance of movieClip 110 triangle {
onClipEvent (load) {
ob = 'triangle';
}
}
frame 2 {
ob = 'square';
}
instance of movieClip 115 square {
onClipEvent (load) {
ob = 'square';
}
}
frame 3 {
ob = 'plus';
}
instance of movieClip 97 plus {
onClipEvent (load) {
ob = 'plus';
}
}
frame 4 {
ob = 'circle';
}
instance of movieClip 103 circle {
onClipEvent (load) {
ob = 'circle';
}
}
}
movieClip 118 hole {
}
movieClip 122 {
frame 5 {
_parent.gotoAndStop(1);
}
}
movieClip 123 player {
frame 1 {
stop();
_root.inAnimation = false;
}
frame 2 {
_root.inAnimation = true;
}
frame 3 {
_root.inAnimation = true;
}
frame 4 {
_root.inAnimation = true;
}
frame 5 {
_root.inAnimation = true;
}
}
movieClip 126 {
}
movieClip 128 break {
frame 1 {
stop();
ob = 'break';
}
instance of movieClip 126 {
onClipEvent (load) {
r1 = random(2);
if (r1 == 0) {
_xscale = 100;
} else {
_xscale = -100;
}
r2 = random(2);
if (r2 == 0) {
_yscale = 100;
} else {
_yscale = -100;
}
}
}
frame 2 {
ob = 'hole';
}
instance of movieClip 126 {
onClipEvent (load) {
r1 = random(2);
if (r1 == 0) {
_xscale = 100;
} else {
_xscale = -100;
}
r2 = random(2);
if (r2 == 0) {
_yscale = 100;
} else {
_yscale = -100;
}
}
}
frame 6 {
stop();
}
instance of movieClip 126 {
onClipEvent (load) {
r1 = random(2);
if (r1 == 0) {
_xscale = 100;
} else {
_xscale = -100;
}
r2 = random(2);
if (r2 == 0) {
_yscale = 100;
} else {
_yscale = -100;
}
}
}
}
button 134 {
on (press) {
_root.playerMC.currentX = 0;
_root.playerMC.currentY = 0;
for (var i in _root) {
if (_root[i].ob != undefined && _root[i].currentX >= 0 && _root[i].currentX <= 24 && _root[i].currentY >= 0 && _root[i].currentY <= 13) {
_root[i].removeMovieClip();
}
}
_root.level = '';
_root.inExport = false;
_root.reloadCreator(_root.decodeLevel(importText.text));
this.removeMovieClip();
}
}
movieClip 135 importPanel {
frame 1 {
importText.text = '';
Selection.setFocus('importText');
}
}
button 139 {
on (press) {
_root.playSound('click');
System.setClipboard(exportTextLink.text);
}
}
movieClip 140 ExportLink {
frame 1 {
Selection.setFocus('exportTextLink');
Selection.setSelection(0, exportTextLink.text.length);
exportTextLink.text = _root.lastExportLink;
}
}
frame 3 {
stop();
level = '';
inCreate = false;
jumpGame = false;
ghost._x = 999;
ghost._y = 999;
for (var i in _root) {
if (_root[i].createdByMaker) {
_root[i].unloadMovie();
_root[i].removeMovieClip();
}
}
for (var k in _root) {
if (_root[k].canClear || _root[k].fromPlus) {
_root[k].removeMovieClip();
}
if (_root[k].ob == 'player' || _root[k]._name == 'animation' || _root[k]._name == 'combine' || _root[k].fromSelector) {
_root[k].removeMovieClip();
_root[k].unloadMovie();
}
}
inGame = false;
noPlayMode = true;
if (music) {
musicPlayer.gotoAndStop(2);
} else {
musicPlayer.gotoAndStop(1);
}
chooser.removeMovieClip();
for (var i in _root) {
if (_root[i]._name == 'chooser') {
_root[i].unloadMovie();
_root[i].removeMovieClip();
trace(_root[i].getDepth());
}
}
version.text = 'ver ' + ver;
}
movieClip 142 {
}
movieClip 146 {
frame 1 {
stop();
}
frame 2 {
_root.playSound('scroll');
}
}
instance of movieClip 146 {
onClipEvent (load) {
label.text = 'NEW GAME';
}
onClipEvent (rollOver) {
gotoAndStop(2);
label.text = 'NEW GAME';
}
onClipEvent (rollOut) {
gotoAndStop(1);
label.text = 'NEW GAME';
}
onClipEvent (press) {
_root.playSound('click');
_root.flasher.gotoAndPlay(1);
_root.newGame = true;
_root.continueGame = false;
_root.fromTester = false;
_root.fromImport = false;
_root.currentlevel = 0;
_root.gotoAndStop('engine');
}
}
instance of movieClip 146 {
onClipEvent (load) {
label.text = 'IMPORT';
}
onClipEvent (rollOver) {
gotoAndStop(2);
label.text = 'IMPORT';
}
onClipEvent (rollOut) {
gotoAndStop(1);
label.text = 'IMPORT';
}
onClipEvent (press) {
_root.playSound('click');
_root.goingToDesigner = false;
_root.flasher.gotoAndPlay(1);
_root.gotoAndStop('import');
}
}
instance of movieClip 146 {
onClipEvent (load) {
label.text = 'LEVEL SELECT';
}
onClipEvent (rollOver) {
gotoAndStop(2);
label.text = 'LEVEL SELECT';
}
onClipEvent (rollOut) {
gotoAndStop(1);
label.text = 'LEVEL SELECT';
}
onClipEvent (press) {
_root.gotoAndStop('lvSelect');
}
}
instance of movieClip 146 {
onClipEvent (load) {
label.text = 'CREDITS';
}
onClipEvent (rollOver) {
gotoAndStop(2);
label.text = 'CREDITS';
}
onClipEvent (rollOut) {
gotoAndStop(1);
label.text = 'CREDITS';
}
onClipEvent (press) {
_root.playSound('click');
_root.flasher.gotoAndPlay(1);
_root.nextFrame();
}
}
instance of movieClip 146 {
onClipEvent (load) {
label.text = 'DESIGNER';
}
onClipEvent (rollOver) {
this.gotoAndStop(2);
label.text = 'DESIGNER';
}
onClipEvent (rollOut) {
gotoAndStop(1);
label.text = 'DESIGNER';
}
onClipEvent (press) {
_root.playSound('click');
_root.flasher.gotoAndPlay(1);
_root.gotoAndStop('creator');
}
}
movieClip 148 {
frame 1 {
stop();
}
instance of movieClip 146 {
onClipEvent (load) {
label.text = 'CONTINUE';
}
onClipEvent (rollOver) {
gotoAndStop(2);
label.text = 'CONTINUE';
}
onClipEvent (rollOut) {
gotoAndStop(1);
label.text = 'CONTINUE';
}
onClipEvent (press) {
_root.playSound('click');
_root.flasher.gotoAndPlay(1);
_root.continueGame = true;
_root.newGame = false;
_root.fromTester = false;
_root.fromImport = false;
_root.gotoAndStop('engine');
}
}
}
instance of movieClip 148 {
onClipEvent (enterFrame) {
if (_root.currentlevel == 0) {
gotoAndStop(1);
} else {
gotoAndStop(2);
}
}
}
button 152 {
on (release) {
_root.music = true;
_root.savefile.data.music = true;
_root.savefile.flush();
nextFrame();
}
}
button 155 {
on (release) {
_root.music = false;
_root.savefile.data.music = false;
_root.savefile.flush();
prevFrame();
}
}
movieClip 156 {
frame 1 {
stop();
}
}
movieClip 158 {
}
movieClip 160 {
}
instance of movieClip 146 {
onClipEvent (load) {
label.text = 'MORE GAMES!';
}
onClipEvent (rollOver) {
gotoAndStop(2);
label.text = 'MORE GAMES!';
}
onClipEvent (rollOut) {
gotoAndStop(1);
label.text = 'MORE GAMES!';
}
onClipEvent (press) {
_root.playSound('click');
_root.flasher.gotoAndPlay(1);
getURL('http://www.newgrounds.com/', '_blank');
}
}
button 165 {
on (release) {
NewgroundsAPI.loadNewgrounds();
}
}
movieClip 166 {
}
movieClip 167 {
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');
} else {}
};
ngads_redirect.load(ngad_url);
}
if (NewgroundsAPI.getAdURL()) {
startAd(NewgroundsAPI.getAdURL());
}
NewgroundsAPI.onAdsApproved = function (ad_url) {
startAd(ad_url);
};
stop();
}
}
movieClip 169 {
frame 6 {
stop();
}
}
frame 4 {
messanger._alpha = 75;
messanger.gotoAndStop(1);
messanger.txt.mytext.text = '\n\nPRESS ANY KEY TO EXIT';
}
movieClip 170 {
}
movieClip 173 {
}
movieClip 175 {
}
movieClip 176 {
frame 1 {
stop();
}
frame 10 {
stop();
}
}
instance messanger of movieClip 176 {
onClipEvent (keyDown) {
if (_currentframe == 1 && !_root.popup) {
play();
}
_root.prevFrame();
}
}
button 183 {
on (release) {
NewgroundsAPI.loadMySite();
}
}
button 187 {
on (release) {
getURL('http://www.twitter.com/SamGoldfield', '_blank');
}
}
button 193 {
on (release) {
getURL('http://www.newgrounds.com/audio/listen/99632', '_blank');
}
}
movieClip 199 {
}
frame 5 {
function loadMsg() {
messanger.swapDepths(_root.getNextHighestDepth());
if ((_root.fromTester || _root.fromImport) && !_root.jumpGame && !_root.newGame && !_root.continueGame) {
messanger._alpha = 75;
messanger.gotoAndStop(1);
messanger.txt.mytext.text = '\nPRESS SPACE TO RESTART.\nPRESS Q TO EXIT.';
messanger.txt.levelN.text = '';
} else {
if (_root.jumpGame && !_root.newGame && !_root.continueGame) {
messanger._alpha = 75;
messanger.gotoAndStop(1);
messanger.txt.mytext.text = 'PRESS SPACE TO RESTART.\nPRESS Q TO EXIT.\nPRESS I FOR INFORMATION.';
messanger.txt.levelN.text = '';
} else {
if (_root.newGame || _root.continueGame) {
messanger._alpha = 75;
messanger.gotoAndStop(1);
if (_root.currentlevel + 1 < 10) {
messanger.txt.levelN.text = '0' + (_root.currentlevel + 1);
} else {
messanger.txt.levelN.text = _root.currentlevel + 1;
}
if (_root.currentlevel == 0) {
messanger.txt.mytext.text = '\nUSE WASD OR ARROW KEYS TO MOVE. PUSH THE BLOCK INTO THE HOLE.\nPRESS SPACE TO RESTART, OR Q TO QUIT TO RETURN TO THE MENU.';
} else {
if (_root.currentlevel == 1) {
messanger.txt.mytext.text = '\nSQUARES WILL FILL HOLES, BUT OTHER OBJECTS WILL NOT.\nTHE OBJECTIVE IS TO CLEAR THE MAP, LEAVING ONLY HOLES AND WALLS.';
} else {
if (_root.currentlevel == 2) {
messanger.txt.mytext.text = '\n\nPUSHING TWO CIRCLES OR SQUARES TOGETHER REMOVES THEM.';
} else {
if (_root.currentlevel == 3) {
messanger.txt.mytext.text = '\n\nPUSHING TWO TRIANGLES TOGETHER WILL CREATE A WALL.';
} else {
if (_root.currentlevel == 4) {
messanger.txt.mytext.text = '\nPUSHING TOGETHER TWO DIAMONDS LETS YOU CHOOSE AN OBJECT.\nCHOOSE WITH UP AND DOWN OR W AND S, SELECT WITH ENTER.';
} else {
if (_root.currentlevel == 5) {
messanger.txt.mytext.text = '\nCRACKED TILES WILL BREAK AFTER STOPPING ON THEM ONCE.\nAFTER THAT, IT BECOMES A HOLE.';
} else {
if (_root.currentlevel == 6) {
messanger.txt.mytext.text = '\n\nALL CRACKED TILES MUST BE BROKEN BEFORE THE LEVEL IS COMPLETED.';
} else {
messanger._alpha = 75;
messanger.gotoAndStop(1);
messanger.txt.mytext.text = '\nPRESS SPACE TO RESTART.\nPRESS Q TO EXIT.';
}
}
}
}
}
}
}
} else {
messanger._alpha = 0;
}
}
}
}
function instruct() {
if (_root.jumpGame && !popup) {
_root.instructor.instText.gotoAndStop(1);
_root.instructor._x = 0;
_root.instructor._y = 0;
_root.instructor.swapDepths(_root.getNextHighestDepth());
_root.instructor.ob = 'inst';
instructing = true;
}
}
loadMsg();
for (var n in _root) {
if (_root[n].fromSelector) {
_root[n].unloadMovie();
_root[n].removeMovieClip();
}
}
trace(_root.level);
chooser.swapDepths(_root.getNextHighestDepth());
}
frame 5 {
function continuePlaying() {
if (!popup) {
if (!inGame && !noPlayMode) {
if (_root.fromTester) {
_root['message' + newd].removeMovieClip();
_root['message' + newd].unloadMovie();
_root.gotoAndStop('creator');
} else {
if (_root.jumpGame) {
_root['message' + newd].removeMovieClip();
_root['message' + newd].unloadMovie();
_root.gotoAndStop('menu');
} else {
if (_root.fromImport) {
_root['message' + newd].removeMovieClip();
_root['message' + newd].unloadMovie();
_root.gotoAndStop('import');
} else {
if (_root.newGame && !_root.continueGame) {
if (_root.currentlevel < numLevels - 1) {
_root['message' + newd].removeMovieClip();
_root['message' + newd].unloadMovie();
++_root.currentlevel;
_root.level = _root['level' + _root.currentlevel];
_root.loadLevel(_root.level);
savefile.data.clevel = _root.currentlevel;
_root.completed += _root.currentlevel + 'Q';
savefile.data.completed += _root.currentlevel + 'Q';
savefile.flush();
inGame = true;
loadMsg();
} else {
gotoAndStop('nolevels');
}
movesLog = 0;
} else {
if (_root.continueGame) {
if (_root.currentlevel < numLevels - 1) {
_root['message' + newd].removeMovieClip();
_root['message' + newd].unloadMovie();
++_root.currentlevel;
_root.level = _root['level' + _root.currentlevel];
_root.loadLevel(_root.level);
_root.completed += _root.currentlevel + 'Q';
savefile.data.completed += _root.currentlevel + 'Q';
savefile.data.clevel = _root.currentlevel;
savefile.flush();
inGame = true;
loadMsg();
} else {
gotoAndStop('nolevels');
}
movesLog = 0;
}
}
}
}
}
}
}
}
function quit() {
if (!popup) {
if (inGame && canMove && !noPlayMode && !_root.instructing) {
if (_root.fromTester) {
_root['message' + newd].removeMovieClip();
_root['message' + newd].unloadMovie();
_root.gotoAndStop('creator');
}
if (!_root.fromTester && (_root.fromImport || _root.jumpGame)) {
_root['message' + newd].removeMovieClip();
_root['message' + newd].unloadMovie();
_root.gotoAndStop('menu');
} else {
if (_root.newGame && !_root.continueGame) {
_root['message' + newd].removeMovieClip();
_root['message' + newd].unloadMovie();
_root.gotoAndStop('menu');
} else {
if (_root.continueGame) {
_root['message' + newd].removeMovieClip();
_root['message' + newd].unloadMovie();
_root.gotoAndStop('menu');
}
}
}
}
}
}
function restart() {
if (!popup) {
if (inGame && canMove && !_root.instructing) {
if (_root.fromImport || _root.newGame || _root.continueGame || _root.fromTester || _root.jumpGame) {
loadLevel(level);
loadMsg();
}
}
}
}
stop();
if (newGame) {
currentlevel = 0;
savefile.data.clevel = 0;
savefile.flush();
}
if (!_root.fromImport && !_root.fromTester && !_root.jumpGame) {
level = _root['level' + currentlevel];
movesLog = 0;
}
loadLevel(level);
canMove = true;
inGame = true;
inCreate = false;
noPlayMode = false;
ghost._x = 999;
ghost._y = 999;
for (var i in _root) {
if (_root[i].createdByMaker) {
_root[i].unloadMovie();
}
}
}
frame 5 {
for (var i in _root) {
if (_root[i]._name == 'chooser') {
trace(_root[i].getDepth());
}
}
}
frame 5 {
function oneSecond() {
++_root.timeLogger;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance player of movieClip 123 player {
onClipEvent (load) {
ob = 'player';
}
onClipEvent (enterFrame) {
_root.checkWin();
}
onClipEvent (keyPress 'w') {
_root.moveUP();
}
onClipEvent (keyPress 'a') {
_root.instructor.instText.prevFrame();
_root.moveLEFT();
}
onClipEvent (keyPress 's') {
_root.moveDOWN();
}
onClipEvent (keyPress 'd') {
_root.instructor.instText.nextFrame();
_root.moveRIGHT();
}
onClipEvent (keyPress 'W') {
_root.moveUP();
}
onClipEvent (keyPress 'A') {
_root.instructor.instText.prevFrame();
_root.moveLEFT();
}
onClipEvent (keyPress 'S') {
_root.moveDOWN();
}
onClipEvent (keyPress 'D') {
_root.instructor.instText.nextFrame();
_root.moveRIGHT();
}
onClipEvent (keyPress '<Up>') {
_root.moveUP();
}
onClipEvent (keyPress '<Left>') {
_root.instructor.instText.prevFrame();
_root.moveLEFT();
}
onClipEvent (keyPress '<Down>') {
_root.moveDOWN();
}
onClipEvent (keyPress '<Right>') {
_root.instructor.instText.nextFrame();
_root.moveRIGHT();
}
onClipEvent (keyPress '<Space>') {
_root.restart();
}
onClipEvent (keyPress '<Enter>') {
if (!_root.canMove) {
_root.choose(_root.chooser.ob);
}
}
onClipEvent (rollOver) {
this.useHandCursor = false;
}
onClipEvent (keyPress 'q') {
if (_root.instructing) {
_root.instructor._x = 999;
_root.instructor._y = 999;
_root.instructing = false;
} else {
_root.quit();
}
}
onClipEvent (keyPress 'Q') {
if (_root.instructing) {
_root.instructor._x = 999;
_root.instructor._y = 999;
_root.instructing = false;
} else {
_root.quit();
}
}
onClipEvent (keyPress 'i') {
if (!_root.instructing && _root.inGame && _root.canMove) {
_root.instruct();
}
}
onClipEvent (keyPress 'I') {
if (!_root.instructing && _root.inGame && _root.canMove) {
_root.instruct();
}
}
onClipEvent (keyUp) {
if (!_root.inGame && !_root.noPlayMode) {
if (_root.readyToContinue._currentframe == 1) {
_root.readyToContinue.nextFrame();
} else {
if (_root.readyToContinue._currentframe == 2) {
_root.readyToContinue.gotoAndStop(1);
_root.continuePlaying();
}
}
}
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
instance of movieClip 92 block {
onClipEvent (load) {
ob = 'block';
currentX = _x / 30;
currentY = _y / 30;
}
}
movieClip 200 {
frame 9 {
_parent._x = 999;
_parent._y = 999;
stop();
_parent.gotoAndStop(1);
}
}
movieClip 201 {
frame 9 {
_parent._x = 999;
_parent._y = 999;
stop();
_parent.gotoAndStop(1);
}
}
movieClip 202 {
frame 9 {
_parent._x = 999;
_parent._y = 999;
stop();
_parent.gotoAndStop(1);
}
}
movieClip 203 {
frame 9 {
_parent._x = 999;
_parent._y = 999;
stop();
_parent.gotoAndStop(1);
}
}
movieClip 204 {
frame 1 {
stop();
}
}
instance animation of movieClip 204 {
onClipEvent (load) {
ob = 'animation';
}
}
movieClip 206 {
frame 1 {
stop();
}
frame 2 {
stop();
}
frame 3 {
stop();
}
}
movieClip 211 {
frame 1 {
stop();
}
}
movieClip 212 {
frame 9 {
_root.combine._x = 999;
_root.combine._y = 999;
_root.combine.gotoAndStop(1);
}
}
movieClip 213 {
frame 9 {
_root.combine._x = 999;
_root.combine._y = 999;
_root.combine.gotoAndStop(1);
stop();
}
}
movieClip 214 {
frame 9 {
_root.combine._x = 999;
_root.combine._y = 999;
_root.combine.gotoAndStop(1);
}
}
movieClip 215 {
frame 9 {
_root.combine._x = 999;
_root.combine._y = 999;
_root.combine.gotoAndStop(1);
}
}
movieClip 216 {
frame 1 {
stop();
}
}
instance combine of movieClip 216 {
onClipEvent (load) {
ob = 'combine';
}
}
movieClip 218 {
}
instance messanger of movieClip 176 {
onClipEvent (keyDown) {
if (_currentframe == 1 && !_root.popup) {
play();
}
}
onClipEvent (load) {
this.swapDepths(_root.getNextHighestDepth());
}
}
movieClip 231 {
frame 1 {
stop();
}
}
movieClip 232 instructor {
}
frame 6 {
importText.text = _root.encodeLevel(level);
Selection.setFocus('importText');
Selection.setSelection(0, importText.text.length);
}
frame 6 {
player._x = 999;
player._y = 999;
noPlayMode = true;
inCreate = false;
ghost._x = 999;
ghost._y = 999;
for (var i in _root) {
if (_root[i].createdByMaker) {
_root[i].unloadMovie();
}
}
for (var k in _root) {
if (_root[k].canClear || _root[k].fromPlus) {
_root[k].unloadMovie();
}
if (_root[k].ob == 'player') {
_root[k].removeMovieClip();
_root[k].unloadMovie();
}
}
inGame = false;
for (var i in _root) {
if (_root[i].ob == 'combine' || _root[i].ob == 'animation' || _root[i]._name == 'choose') {
_root[i].removeMovieClip();
_root[i].unloadMovie();
}
}
for (var k in _root) {
if (_root[k].canClear || _root[k].fromPlus) {
_root[k].removeMovieClip();
_root[k].unloadMovie();
}
}
}
frame 6 {
chooser.removeMovieClip();
for (var i in _root) {
if (_root[i]._name == 'chooser') {
_root[i].unloadMovie();
_root[i].removeMovieClip();
trace(_root[i].getDepth());
}
}
}
button 238 {
on (press) {
_root.gotoAndStop('menu');
}
}
button 242 {
on (press) {
_root.level = _root.decodeLevel(_root.importText.text);
_root.fromImport = true;
_root.fromTester = false;
_root.continueGame = false;
_root.newGame = false;
_root.gotoAndStop('engine');
}
}
frame 7 {
stop();
}
frame 7 {
_root['message' + newd].removeMovieClip();
_root['message' + newd].unloadMovie();
_root.currentlevel = 0;
_root.level = _root['level' + _root.currentlevel];
savefile.data.clevel = _root.currentlevel;
savefile.flush();
inGame = false;
for (var k in _root) {
if (_root[k].canClear || _root[k].fromPlus) {
_root[k].unloadMovie();
}
if (_root[k].ob == 'player') {
_root[k].removeMovieClip();
_root[k].unloadMovie();
}
}
}
movieClip 244 {
}
instance of movieClip 244 {
onClipEvent (keyUp) {
_root.gotoAndStop('menu');
}
}
movieClip 247 {
}
movieClip 249 {
}
movieClip 251 {
}
frame 8 {
function export() {
nd = _root.getNextHighestDepth();
attachMovie('exportPanel', 'exportPanel' + nd, nd);
_root['exportPanel' + nd].exportText.text = _root.encodeLevel(_root.level);
_root['exportPanel' + nd]._x = 0;
_root['exportPanel' + nd]._y = 0;
_root.inExport = true;
}
function exportLink(s) {
nd = _root.getNextHighestDepth();
attachMovie('ExportLink', 'ExportLink' + nd, nd);
_root['ExportLink' + nd].exportTextLink.text = _root.lastExportLink;
trace(_root.lastExportLink);
_root['ExportLink' + nd]._x = 0;
_root['ExportLink' + nd]._y = 0;
_root.inExport = true;
}
function importL() {
nd = _root.getNextHighestDepth();
attachMovie('importPanel', 'importPanel' + nd, nd);
_root['importPanel' + nd]._x = 0;
_root['importPanel' + nd]._y = 0;
_root.inExport = true;
}
for (var i in _root) {
if (_root[i].ob == 'combine' || _root[i].ob == 'animation' || _root[i]._name == 'choose') {
_root[i].removeMovieClip();
_root[i].unloadMovie();
}
}
for (var k in _root) {
if (_root[k].canClear || _root[k].fromPlus) {
_root[k].removeMovieClip();
_root[k].unloadMovie();
}
}
for (var k in _root) {
if (_root[k].currentX == 0 && _root[k].currentY == 0) {
trace(_root[k].ob);
}
}
trace(level);
messanger.removeMovieClip();
keys = new Array('player', 'block', 'square', 'circle', 'triangle', 'plus', 'hole', 'break');
ghostNumber = 0;
playerPlaced = false;
stop();
inCreate = true;
player._x = 999;
player._y = 999;
for (var k in _root) {
if (_root[k].canClear || _root[k].fromPlus) {
_root[k].unloadMovie();
}
if (_root[k].ob == 'player') {
_root[k].removeMovieClip();
_root[k].unloadMovie();
}
}
_root.playerMC.removeMovieClip();
_root.playerMC.unloadMovie();
inGame = false;
_root.reloadCreator(level);
inExport = false;
noPlayMode = true;
twitter_array = new Array('Try%20my%20new%20sweet', 'Check%20out%20this%20awesome', 'I%20bet%20you%20can\'t%20beat%20this', 'Try%20this%20really%20hard', 'This%20is%20a%20really%20tricky');
}
frame 8 {
chooser.removeMovieClip();
for (var i in _root) {
if (_root[i]._name == 'chooser') {
_root[i].unloadMovie();
_root[i].removeMovieClip();
trace(_root[i].getDepth());
}
}
}
frame 8 {
function getCodT(l) {
send.sendAndLoad('http://www.willseph.com/push/share.php?l=' + l, receiveT, 'POST');
}
function getCodF(l) {
send.sendAndLoad('http://www.willseph.com/push/share.php?l=' + l, receiveF, 'POST');
}
function getCodL(l) {
send.sendAndLoad('http://www.willseph.com/push/share.php?l=' + l, receiveL, 'POST');
}
send = new LoadVars();
receiveT = new LoadVars();
receiveF = new LoadVars();
receiveL = new LoadVars();
receiveT.onLoad = function () {
getURL('http://twitter.com/home?status=' + twitter_array[random(5)] + '%20level%20I%20made%20in%20%23Push%21%20-%20http%3A%2F%2Fwillseph.com/push/?l=' + this.s, '_blank');
};
receiveF.onLoad = function () {
getURL('http://www.facebook.com/share.php?u=http://www.willseph.com/push/%3Fl%3D' + this.s + '&t=Push!%20-%20Custom Level', '_blank');
};
receiveL.onLoad = function () {
_root.lastExportLink = 'http://www.willseph.com/push/?l=' + this.s;
_root.exportLink(_root.lastExportLink);
};
}
movieClip 254 {
}
movieClip 263 {
frame 8 {
stop();
}
}
instance ghost of movieClip 263 {
onClipEvent (enterFrame) {
if (_root.inCreate && !_root.inExport) {
if (_root.ghostNumber > 0) {
gotoAndStop(_root.ghostNumber);
if (_root._xmouse < 625 && _root._ymouse < 350) {
_x = Math.round((_root._xmouse + 10) / 25) * 25 - 25;
_y = Math.round((_root._ymouse + 10) / 25) * 25 - 25;
xPos = Math.round((_root._xmouse + 10) / 25) - 1;
yPos = Math.round((_root._ymouse + 10) / 25) - 1;
}
}
} else {
_x = 999;
_y = 999;
}
}
onClipEvent (mouseDown) {
if (_root.inCreate && !_root.inExport) {
noOverwrite = true;
for (var i in _root) {
if (_root[i].currentX == xPos && _root[i].currentY == yPos && _root[i]._name != 'ghost' && _root[i].ob != undefined && _root[i].ob != '') {
noOverwrite = false;
break;
}
}
if (_root.ghostNumber > 0 && xPos >= 0 && xPos <= 24 && yPos >= 0 && yPos <= 13 && _root._xmouse < 625 && _root._ymouse < 350) {
if (_root.ghostNumber > 1 && _root.ghostNumber < 9) {
if (!noOverwrite) {
for (var k in _root) {
if (_root[k].currentX == xPos && _root[k].currentY == yPos && _root[k]._name != 'ghost') {
if (_root[k]._name != 'playerMC') {
_root[k].unloadMovie();
_root[k].removeMovieClip();
_root.playSound('scroll');
} else {
return undefined;
}
}
}
}
_root.playSound('click');
dm = _root.getNextHighestDepth();
_root.attachMovie(_root.keys[_root.ghostNumber - 1], _root.keys[_root.ghostNumber - 1] + dm, dm);
_root[_root.keys[_root.ghostNumber - 1] + dm]._x = Math.round((_root._xmouse + 10) / 25) * 25 - 25;
_root[_root.keys[_root.ghostNumber - 1] + dm]._y = Math.round((_root._ymouse + 10) / 25) * 25 - 25;
_root[_root.keys[_root.ghostNumber - 1] + dm].currentX = Math.round((_root._xmouse + 10) / 25) - 1;
_root[_root.keys[_root.ghostNumber - 1] + dm].currentY = Math.round((_root._ymouse + 10) / 25) - 1;
_root[_root.keys[_root.ghostNumber - 1] + dm]._width = 25;
_root[_root.keys[_root.ghostNumber - 1] + dm]._height = 25;
_root[_root.keys[_root.ghostNumber - 1] + dm].ob = _root.keys[_root.ghostNumber - 1];
_root[_root.keys[_root.ghostNumber - 1] + dm].createdByMaker = true;
} else {
if (_root.ghostNumber == 1) {
if (!noOverwrite) {
for (var k in _root) {
if (_root[k].currentX == xPos && _root[k].currentY == yPos && _root[k]._name != 'ghost') {
if (_root[k]._name != 'playerMC') {
_root[k].unloadMovie();
_root[k].removeMovieClip();
_root.playSound('scroll');
} else {
return undefined;
}
}
}
}
_root.playSound('click');
if (!_root.playerPlaced) {
dm = _root.getNextHighestDepth();
_root.attachMovie('player', 'playerMC', dm);
_root.playerMC._x = Math.round((_root._xmouse + 10) / 25) * 25 - 25;
_root.playerMC._y = Math.round((_root._ymouse + 10) / 25) * 25 - 25;
_root.playerMC.currentX = Math.round((_root._xmouse + 10) / 25) - 1;
_root.playerMC.currentY = Math.round((_root._ymouse + 10) / 25) - 1;
_root.playerMC._width = 25;
_root.playerMC._height = 25;
_root.playerMC.ob = 'player';
_root.playerPlaced = true;
_root.playerMC.createdByMaker = true;
} else {
_root.playerMC._x = Math.round((_root._xmouse + 10) / 25) * 25 - 25;
_root.playerMC._y = Math.round((_root._ymouse + 10) / 25) * 25 - 25;
_root.playerMC.currentX = Math.round((_root._xmouse + 10) / 25) - 1;
_root.playerMC.currentY = Math.round((_root._ymouse + 10) / 25) - 1;
_root.playerMC._width = 25;
_root.playerMC._height = 25;
}
}
}
if (_root.ghostNumber == 9) {
for (var k in _root) {
if (_root[k].currentX == xPos && _root[k].currentY == yPos && _root[k]._name != 'ghost') {
if (_root[k]._name != 'playerMC') {
_root[k].unloadMovie();
_root[k].removeMovieClip();
_root.playSound('scroll');
}
}
}
}
}
this.swapDepths(_root.getNextHighestDepth());
}
}
}
instance of movieClip 263 {
onClipEvent (load) {
num = 1;
gotoAndStop(num);
}
onClipEvent (press) {
if (!_root.inExport) {
_root.ghostNumber = num;
}
}
onClipEvent (rollOver) {
if (_root.inExport) {
this.useHandCursor = false;
} else {
this.useHandCursor = true;
}
}
}
instance of movieClip 263 {
onClipEvent (load) {
num = 2;
gotoAndStop(num);
}
onClipEvent (press) {
if (!_root.inExport) {
_root.ghostNumber = num;
}
}
onClipEvent (rollOver) {
if (_root.inExport) {
this.useHandCursor = false;
} else {
this.useHandCursor = true;
}
}
}
instance of movieClip 263 {
onClipEvent (load) {
num = 3;
gotoAndStop(num);
}
onClipEvent (press) {
if (!_root.inExport) {
_root.ghostNumber = num;
}
}
onClipEvent (rollOver) {
if (_root.inExport) {
this.useHandCursor = false;
} else {
this.useHandCursor = true;
}
}
}
instance of movieClip 263 {
onClipEvent (load) {
num = 4;
gotoAndStop(num);
}
onClipEvent (press) {
if (!_root.inExport) {
_root.ghostNumber = num;
}
}
onClipEvent (rollOver) {
if (_root.inExport) {
this.useHandCursor = false;
} else {
this.useHandCursor = true;
}
}
}
instance of movieClip 263 {
onClipEvent (load) {
num = 5;
gotoAndStop(num);
}
onClipEvent (press) {
if (!_root.inExport) {
_root.ghostNumber = num;
}
}
onClipEvent (rollOver) {
if (_root.inExport) {
this.useHandCursor = false;
} else {
this.useHandCursor = true;
}
}
}
instance of movieClip 263 {
onClipEvent (load) {
num = 6;
gotoAndStop(num);
}
onClipEvent (press) {
if (!_root.inExport) {
_root.ghostNumber = num;
}
}
onClipEvent (rollOver) {
if (_root.inExport) {
this.useHandCursor = false;
} else {
this.useHandCursor = true;
}
}
}
instance of movieClip 263 {
onClipEvent (load) {
num = 7;
gotoAndStop(num);
}
onClipEvent (press) {
if (!_root.inExport) {
_root.ghostNumber = num;
}
}
onClipEvent (rollOver) {
if (_root.inExport) {
this.useHandCursor = false;
} else {
this.useHandCursor = true;
}
}
}
instance of movieClip 263 {
onClipEvent (load) {
num = 8;
gotoAndStop(num);
}
onClipEvent (press) {
if (!_root.inExport) {
_root.ghostNumber = num;
}
}
onClipEvent (rollOver) {
if (_root.inExport) {
this.useHandCursor = false;
} else {
this.useHandCursor = true;
}
}
}
instance of movieClip 263 {
onClipEvent (load) {
num = 9;
gotoAndStop(num);
}
onClipEvent (press) {
if (!_root.inExport) {
_root.ghostNumber = num;
}
}
onClipEvent (rollOver) {
if (_root.inExport) {
this.useHandCursor = false;
} else {
this.useHandCursor = true;
}
}
}
button 266 {
on (press) {
if (!_root.inExport) {
_root.playSound('click');
objects_array = new Array();
objects_array.player = 0;
objects_array.block = 1;
objects_array.square = 2;
objects_array.circle = 3;
objects_array.triangle = 4;
objects_array.plus = 5;
objects_array.hole = 6;
objects_array.break = 7;
str = ';';
for (var i in _root) {
if (_root[i].ob != undefined && _root[i].currentX >= 0 && _root[i].currentX <= 24 && _root[i].currentY >= 0 && _root[i].currentY <= 13 && _root[i].currentX != undefined && _root[i].currentY != undefined) {
if (str.indexOf(';' + _root[i].currentX + ',' + _root[i].currentY + ',') == -1) {
str += _root[i].currentX + ',' + _root[i].currentY + ',' + objects_array[_root[i].ob] + ';';
}
}
}
_root.level = str;
_root.continueGame = false;
_root.newGame = false;
_root.fromTester = true;
_root.fromImport = false;
_root.gotoAndStop('engine');
}
}
}
button 269 {
on (press) {
if (!_root.inExport) {
_root.playSound('click');
objects_array = new Array();
objects_array.player = 0;
objects_array.block = 1;
objects_array.square = 2;
objects_array.circle = 3;
objects_array.triangle = 4;
objects_array.plus = 5;
objects_array.hole = 6;
objects_array.break = 7;
str = ';';
for (var i in _root) {
if (_root[i].ob != undefined && _root[i].currentX >= 0 && _root[i].currentX <= 24 && _root[i].currentY >= 0 && _root[i].currentY <= 13 && _root[i].currentX != undefined && _root[i].currentY != undefined) {
if (str.indexOf(';' + _root[i].currentX + ',' + _root[i].currentY + ',') == -1) {
str += _root[i].currentX + ',' + _root[i].currentY + ',' + objects_array[_root[i].ob] + ';';
}
}
}
_root.level = str;
_root.export();
}
}
}
button 272 {
on (press) {
if (!_root.inExport) {
_root.playSound('click');
for (var i in _root) {
if (_root[i].ob != 'player' && _root[i].ob != undefined && _root[i].currentX >= 0 && _root[i].currentX <= 24 && _root[i].currentY >= 0 && _root[i].currentY <= 13) {
_root[i].removeMovieClip();
}
_root.playerMC._x = 999;
_root.playerMC._y = 999;
_root.playerMC.currentX = 999;
_root.playerMC.currentY = 999;
}
_root.level = '';
}
}
}
button 275 {
on (press) {
if (!_root.inExport) {
_root.playSound('click');
_root.gotoAndStop('menu');
}
}
}
button 279 {
on (press) {
if (!_root.inExport) {
_root.playSound('click');
_root.importL();
}
}
}
button 283 {
on (press) {
if (!_root.inExport) {
_root.playSound('click');
objects_array = new Array();
objects_array.player = 0;
objects_array.block = 1;
objects_array.square = 2;
objects_array.circle = 3;
objects_array.triangle = 4;
objects_array.plus = 5;
objects_array.hole = 6;
objects_array.break = 7;
str = ';';
for (var i in _root) {
if (_root[i].ob != undefined && _root[i].currentX >= 0 && _root[i].currentX <= 24 && _root[i].currentY >= 0 && _root[i].currentY <= 13 && _root[i].currentX != undefined && _root[i].currentY != undefined) {
if (str.indexOf(';' + _root[i].currentX + ',' + _root[i].currentY + ',') == -1) {
str += _root[i].currentX + ',' + _root[i].currentY + ',' + objects_array[_root[i].ob] + ';';
}
}
}
_root.getCodF(_root.encodeLevel(str));
}
}
}
button 287 {
on (press) {
if (!_root.inExport) {
_root.playSound('click');
objects_array = new Array();
objects_array.player = 0;
objects_array.block = 1;
objects_array.square = 2;
objects_array.circle = 3;
objects_array.triangle = 4;
objects_array.plus = 5;
objects_array.hole = 6;
objects_array.break = 7;
str = ';';
for (var i in _root) {
if (_root[i].ob != undefined && _root[i].currentX >= 0 && _root[i].currentX <= 24 && _root[i].currentY >= 0 && _root[i].currentY <= 13 && _root[i].currentX != undefined && _root[i].currentY != undefined) {
if (str.indexOf(';' + _root[i].currentX + ',' + _root[i].currentY + ',') == -1) {
str += _root[i].currentX + ',' + _root[i].currentY + ',' + objects_array[_root[i].ob] + ';';
}
}
}
_root.getCodT(_root.encodeLevel(str));
}
}
}
button 290 {
on (press) {
if (!_root.inExport) {
_root.inExport = true;
_root.playSound('click');
objects_array = new Array();
objects_array.player = 0;
objects_array.block = 1;
objects_array.square = 2;
objects_array.circle = 3;
objects_array.triangle = 4;
objects_array.plus = 5;
objects_array.hole = 6;
objects_array.break = 7;
str = ';';
for (var i in _root) {
if (_root[i].ob != undefined && _root[i].currentX >= 0 && _root[i].currentX <= 24 && _root[i].currentY >= 0 && _root[i].currentY <= 13 && _root[i].currentX != undefined && _root[i].currentY != undefined) {
if (str.indexOf(';' + _root[i].currentX + ',' + _root[i].currentY + ',') == -1) {
str += _root[i].currentX + ',' + _root[i].currentY + ',' + objects_array[_root[i].ob] + ';';
}
}
}
_root.getCodL(_root.encodeLevel(str));
}
}
}
frame 9 {
function moveLevelUp() {
for (var v2 in _root) {
if (_root[v2].fromSelector) {
_root[v2].removeMovieClip();
}
}
if (_root.currentLevel == 25) {
_root.currentLevel = 1;
} else {
++_root.currentLevel;
}
if (_root.currentLevel < 10) {
_root.levelMc.levelNum.text = '0' + _root.currentLevel;
} else {
_root.levelMc.levelNum.text = _root.currentLevel;
}
drawLevel(_root.currentLevel - 1);
}
function moveLevelDown() {
for (var v2 in _root) {
if (_root[v2].fromSelector) {
_root[v2].removeMovieClip();
}
}
if (_root.currentLevel == 1) {
_root.currentLevel = 25;
} else {
--_root.currentLevel;
}
if (_root.currentLevel < 10) {
_root.levelMc.levelNum.text = '0' + _root.currentLevel;
} else {
_root.levelMc.levelNum.text = _root.currentLevel;
}
drawLevel(_root.currentLevel - 1);
}
function drawLevel(num) {
comparray = _root.completed.split('Q');
if (num > 0) {
if (checkArray(comparray, num)) {
canLoad = true;
} else {
canLoad = false;
}
} else {
canLoad = true;
}
if (canLoad) {
lv = _root['level' + num];
_root.diamondSelect = false;
item = lv.split(';');
keys = new Array('player', 'block', 'square', 'circle', 'triangle', 'plus', 'hole', 'break');
j = 0;
while (j < item.length) {
nd = _root.getNextHighestDepth();
indiv = item[j].split(',');
attachMovie(keys[Math.round(parseInt(indiv[2]))], keys[Math.round(parseInt(indiv[2]))] + nd + 'c', nd);
_root[keys[indiv[2]] + nd + 'c'].currentX = Math.round(parseInt(indiv[0]));
_root[keys[indiv[2]] + nd + 'c'].currentY = Math.round(parseInt(indiv[1]));
_root[keys[indiv[2]] + nd + 'c']._x = _root[keys[indiv[2]] + nd + 'c'].currentX * 25;
_root[keys[indiv[2]] + nd + 'c']._y = _root[keys[indiv[2]] + nd + 'c'].currentY * 25;
_root[keys[indiv[2]] + nd + 'c'].fromSelector = true;
_root[keys[indiv[2]] + nd + 'c']._width = 25;
_root[keys[indiv[2]] + nd + 'c']._height = 25;
++j;
}
_root.player.swapDepths(_root.getNextHighestDepth());
_root.temp = _root.levelMc.levelNum.text;
levelMc.gotoAndStop(1);
bgGrid.gotoAndStop(1);
_root.levelMc.levelNum.text = _root.temp;
} else {
_root.temp = _root.levelMc.levelNum.text;
levelMc.gotoAndStop(2);
bgGrid.gotoAndStop(2);
_root.levelMc.levelNum.text = _root.temp;
}
}
currentLevel = 1;
drawLevel(0);
}
movieClip 292 {
frame 1 {
stop();
}
}
instance of movieClip 263 {
onClipEvent (load) {
num = 1;
gotoAndStop(num);
}
onClipEvent (press) {
if (!_root.inExport) {
_root.ghostNumber = num;
}
}
onClipEvent (rollOver) {
if (_root.inExport) {
this.useHandCursor = false;
} else {
this.useHandCursor = true;
}
}
}
button 293 {
on (press) {
if (!_root.inExport) {
_root.gotoAndStop('menu');
}
}
}
movieClip 295 {
}
instance of movieClip 295 {
onClipEvent (keyPress '<Up>') {
_root.moveLevelUp();
}
onClipEvent (keyPress 'w') {
_root.moveLevelUp();
}
onClipEvent (keyPress 'W') {
_root.moveLevelUp();
}
onClipEvent (keyPress '<Down>') {
_root.moveLevelDown();
}
onClipEvent (keyPress 's') {
_root.moveLevelDown();
}
onClipEvent (keyPress 'S') {
_root.moveLevelDown();
}
}
movieClip 298 {
}
movieClip 300 {
}
button 301 {
on (press) {
_root.playSound('click');
_root.flasher.gotoAndPlay(1);
_root.continueGame = true;
_root.newGame = false;
_root.fromTester = false;
_root.fromImport = false;
_root.currentlevel = _root.currentLevel - 1;
_root.gotoAndStop('engine');
}
}
movieClip 305 {
frame 1 {
stop();
}
}