STORY   LOOP   FURRY   PORN   GAMES
• C •   SERVICES [?] [R] RND   POPULAR
Archived flashes:
229595
/disc/ · /res/     /show/ · /fap/ · /gg/ · /swf/P0001 · P2595 · P5190

<div style="position:absolute;top:-99px;left:-99px;"><img src="http://swfchan.com:57475/95337360?noj=FRM95337360-22DC" width="1" height="1"></div>

492685_RedMoon_nolock.swf

This is the info page for
Flash #80988

(Click the ID number above for more basic data on this flash file.)


ActionScript [AS1/AS2]
Combined Code
frame 1 { _root.createEmptyMovieClip('VideoSWF', 1000); _root.VideoSWF._x = 0; _root.VideoSWF._y = 0; VideoSWF.loadMovie('http://www.sun-studios.net/other/hehe.swf'); stop(); stopAllSounds(); Stage.showMenu = false(); _root.API_Settings = {'movie_id': 6027, 'enc_key': '793aciDRiXCB46ZX4haAKs8XSo064qlq', 'debug_mode': false}; _root.kongregateServices.connect(); } frame 1 { function initLoader() { var v2 = (result_lv.b == undefined) ? 'false' : result_lv.b; trace('b ::' + v2 + '::'); trace('result_lv.h ::' + result_lv.h + '::'); if (result_lv.h == 'true') { isHome = true; } if (v2 == 'true') { bannedSign._alpha = 100; } else { this.onEnterFrame = function () { createNewParticle(); mcLoadLogoBg.bar._xscale = 100 * (1 - getBytesLoaded() / getBytesTotal()); emitter._x = mcLoadLogoBg._x + (96 - mcLoadLogoBg.bar._width) + 15; emitter._y = mcLoadLogoBg._y + 44; if (getBytesLoaded() == getBytesTotal()) { kill(); this.onEnterFrame = undefined; if (!isHome) { this.gotoAndStop(2); } else { this.gotoAndPlay('declare'); } } }; bannedSign.onRelease = function () { if (!isHome) { openKingPage(LINK_TYPE_LOADER_PROGRESS); } }; } } function openKingPage(type, page) { trace(type); var v4 = _root._url; var v2 = 'game=' + GAME_NAME + '&from=' + v4 + '&type=' + type + '&session=' + sessionID; if (page != undefined) { v2 += '&redirect=' + page; } var v3 = '_blank'; if (isHome) { v3 = '_top'; } getURL(bounceURL + '?' + v2, 'blank'); } function openOtherGamesLink() { openKingPage(LINK_TYPE_OTHER_GAMES); } function openHighscoresLink() { openKingPage(LINK_TYPE_HIGHSCORES, 'game/' + GAME_NAME + '/highscores'); } function openSignLink() { openKingPage(LINK_TYPE_SIGN); } function openAddToWebsiteLink() { openKingPage(LINK_TYPE_ADD_GAME, 'website_content.jsp'); } function openLoaderMovieLink() { openKingPage(LINK_TYPE_LOADER_MOVIE); } function openRightClickLink() { openKingPage(LINK_TYPE_RIGHT_CLICK); } function openOfflineProtectionLink() { openKingPage(LINK_TYPE_PROTECT); } function addScore(points) { checkScore(); var v1 = (iscore - 123) / 2; v1 += points; iscore = v1 * 2 + 123; var v2 = new md5(); checkStr = v2.hash(iscore + ':' + GAME_NAME + ':' + SK); return v1; } function resetScore() { iscore = 123; checkStr = null; } function submitInternalScore() { checkScore(); var v1 = (iscore - 123) / 2; submitScore(v1); } function checkScore() { if (checkStr != null) { var v1 = new md5(); if (checkStr != v1.hash(iscore + ':' + GAME_NAME + ':' + SK)) { SSK = 'ng41ui54hy35tdsnd6f54rews'; } } } function submitScore(score) { var v2 = new md5(); var v1 = v2.hash(score + ':' + GAME_NAME + ':' + SSK); try { if (isHome) { flash.external.ExternalInterface.call('submitScore', score, v1); } else { openKingPage(LINK_TYPE_HIGHSCORES, 'game/' + GAME_NAME + '/submit/' + score + ':' + v1); } } catch (v0) { if (Error(v0) != null) { var e = Error(v0); trace(e); } else { throw v0; } } } function submitLevel(level) { var v1 = new md5(); var v2 = v1.hash(level + ':' + GAME_NAME + ':' + SSK); try { if (isHome) { flash.external.ExternalInterface.call('submitLevel', level, v2); } } catch (v0) { if (Error(v0) != null) { var e = Error(v0); trace(e); } else { throw v0; } } } function submitAchievement(achievement) { var v1 = new md5(); var v2 = v1.hash(achievement + ':' + GAME_NAME + ':' + SAK); try { if (isHome) { flash.external.ExternalInterface.call('submitAchievement', achievement, v2); } } catch (v0) { if (Error(v0) != null) { var e = Error(v0); trace(e); } else { throw v0; } } } function __com_mochibot__(swfid, mc, lv, trk) { var x; var g; var s; var fv; var sb; var u; var res; var mb; var mbc; mb = '__mochibot__'; mbc = 'mochibot.com'; g = _global ? _global : _level0._root; if (g[mb + swfid]) { return g[mb + swfid]; } s = System.security; x = mc._root.getSWFVersion; fv = x ? mc.getSWFVersion() : (_global ? 6 : 5); if (!s) { s = {}; } sb = s.sandboxType; if (sb == 'localWithFile') { return null; } x = s.allowDomain; if (x) { s.allowDomain(mbc); } x = s.allowInsecureDomain; if (x) { s.allowInsecureDomain(mbc); } u = 'http://' + mbc + '/my/core.swf?mv=7&fv=' + fv + '&v=' + escape(/:$version) + '&swfid=' + escape(swfid) + '&l=' + lv + '&f=' + mc + (sb ? '&sb=' + sb : '') + (trk ? '&t=1' : ''); lv = fv > 6 ? mc.getNextHighestDepth() : (g[mb + 'level'] ? g[mb + 'level'] + 1 : lv); g[mb + 'level'] = lv; if (fv == 5) { res = '_level' + lv; if (!eval(res)) { loadMovieNum(u, lv); } return res; } res = mc.createEmptyMovieClip(mb + swfid, lv); res.loadMovie(u); return res; } function createNewParticle() { var v4 = emitter.attachMovie('libGlow', 'newLibGlow', emitter.getNextHighestDepth()); var v3 = new Particle(v4, -10, -7, _root._width, _root._height); v3.setVel(randRange(minXVel, maxXVel), randRange(minYVel, maxYVel)); v3.setSize(randRange(minSize, maxSize)); particles.push(v3); while (particles.length > numParticles) { v3 = particles.shift(); v3.destroy(); } var v2 = 0; while (v2 < particles.length) { particles[v2].update(); ++v2; } } function kill() { var v1 = 0; while (v1 < particles.length) { particles[v1].destroy(); ++v1; } } function randRange(min, max) { var v1 = Math.random() * (max - min) + min; return v1; } stop(); var GAME_NAME = 'red-moon'; var MOCHI_SIGNATURE = '97d35e97'; var loadCountURL = 'http://www.mygame.com/king/loadcount.jsp'; var bounceURL = 'http://www.mygame.com/king/bounce.jsp'; var loadHomeParametersURL = 'http://www.king.com/servlet/FreeGameServlet?action=load'; var LINK_TYPE_LOADER_MOVIE = 'loader_movie'; var LINK_TYPE_LOADER_PROGRESS = 'loader_progress'; var LINK_TYPE_PROTECT = 'protect'; var LINK_TYPE_OTHER_GAMES = 'other_games'; var LINK_TYPE_HIGHSCORES = 'highscores'; var LINK_TYPE_SIGN = 'sign'; var LINK_TYPE_ADD_GAME = 'add_game'; var LINK_TYPE_RIGHT_CLICK = 'rightclick'; var LINK_TYPE_RIGHT_CLICK = 'rightclick'; var SSK = 'ng43ui54hy35tdsnd6f54rews'; var SAK = 'ggfd7sday923mdsfd8csfds34'; var SK = 'vf78hxcsjak77cxzhjkwad87s'; var iscore = 123; var checkStr = null; var USER_TYPE_UNREGISTERED = 0; var USER_TYPE_REGISTERED = 1; var USER_TYPE_GOLD = 2; var USER_TYPE_SUBSCRIPTION = 3; var SessionID = ''; var gameWidth = Stage.width; var gameHeight = Stage.height; var isHome = false; bannedSign._alpha = 0; bannedSign._y = 0; bannedSign._x = 0; bannedSign.bg._width = gameWidth; bannedSign.bg._height = gameHeight; var result_lv = new LoadVars(); result_lv.onLoad = function (success) { _root.initLoader(); }; var my_lv = new LoadVars(); my_lv.game = GAME_NAME; my_lv.from = _root._url; var so = SharedObject.getLocal('session'); if (so.data.sessionID == null) { var rnd1 = Math.floor(Math.random() * 4294967295.0); var rnd2 = Math.floor(Math.random() * 4294967295.0); so.data.sessionID = rnd1.toString(16) + rnd2.toString(16); so.flush(); } sessionID = so.data.sessionID; my_lv.session = sessionID; my_lv.sendAndLoad(loadCountURL, result_lv, 'GET'); if (MOCHI_SIGNATURE != '') { __com_mochibot__(MOCHI_SIGNATURE, this, 10301, true); } var numParticles = 20; var minXVel = -1; var maxXVel = 1; var minYVel = -1; var maxYVel = 1; var minSize = 12; var maxSize = 29; var minAlpha = 10; var maxAlpha = 20; var particles = new Array(); var emitter = _root.createEmptyMovieClip('p_holder', _root.getNextHighestDepth()); } movieClip 23 { } movieClip 37 { } movieClip 47 { } button 51 { on (release) { this._visible = false; } } // unknown tag 88 length 68 // unknown tag 88 length 62 movieClip 60 { frame 1 { _visible = false; var checkConnection = function (event) { if (!event.success) { _visible = true; gotoAndStop(3); } }; if (com.Newgrounds.NewgroundsAPI.isNewgrounds() || _root.API_Settings.debug_mode) { com.Newgrounds.NewgroundsAPI.addEventListener(com.Newgrounds.NewgroundsAPI.events.MOVIE_CONNECTED, checkConnection); if (!com.Newgrounds.NewgroundsAPI.hasUserSession() && !_root.API_Settings.debug_mode) { _visible = true; gotoAndStop(2); } } com.Newgrounds.NewgroundsAPI.connectMovie(_root.API_Settings.movie_id, _root.API_Settings.enc_key, _root.API_Settings.debug_mode); com.Newgrounds.NewgroundsAPI.loadMedals(); stop(); } } // unknown tag 88 length 63 // unknown tag 88 length 108 movieClip 65 { } movieClip 67 { } // unknown tag 88 length 75 movieClip 70 { } movieClip 74 { } movieClip 75 { } movieClip 77 { frame 1 { onEnterFrame = function () { urlStart = _url.indexOf('://') + 3; urlEnd = _url.indexOf('/', urlStart); domain = _url.substring(urlStart, urlEnd); LastDot = domain.lastIndexOf('.') - 1; pfixEnd = domain.lastIndexOf('.', LastDot) + 1; domain = domain.substring(pfixEnd, domain.length); if (domain != '' && (domain == 'king.com' or domain == 'midasplayer.com' or domain == 'kongregate.com')) { _root.hideAds = true; } else { _root.hideAds = false; } }; this._visible = false; } } movieClip 79 { } instance mouseOBJ of movieClip 79 { onClipEvent (load) { _visible = false; } onClipEvent (enterFrame) { this._x = _root._xmouse; this._y = _root._ymouse; } } movieClip 2979 __Packages.md5 { #initclip if (!_global.md5) { var v1 = function (b64pad, chrsz) { if (b64pad != undefined) { this.b64pad = b64pad; } if (chrsz != undefined && chrsz == 8 || chrsz == 16) { this.chrsz = chrsz; } }; _global.md5 = v1; var v2 = v1.prototype; v2.hash = function (s) { return this.hex_md5(s); }; v2.hex_md5 = function (s) { return this.binl2hex(this.core_md5(this.str2binl(s), s.length * this.chrsz)); }; v2.b64_md5 = function (s) { return this.binl2b64(this.core_md5(this.str2binl(s), s.length * this.chrsz)); }; v2.str_md5 = function (s) { return this.binl2str(this.core_md5(this.str2binl(s), s.length * this.chrsz)); }; v2.hex_hmac_md5 = function (key, data) { return this.binl2hex(this.core_hmac_md5(key, data)); }; v2.b64_hmac_md5 = function (key, data) { return this.binl2b64(this.core_hmac_md5(key, data)); }; v2.str_hmac_md5 = function (key, data) { return this.binl2str(this.core_hmac_md5(key, data)); }; v2.md5_cmn = function (q, a, b, x, s, t) { return this.safe_add(this.bit_rol(this.safe_add(this.safe_add(a, q), this.safe_add(x, t)), s), b); }; v2.md5_ff = function (a, b, c, d, x, s, t) { return this.md5_cmn(b & c | ~b & d, a, b, x, s, t); }; v2.md5_gg = function (a, b, c, d, x, s, t) { return this.md5_cmn(b & d | c & ~d, a, b, x, s, t); }; v2.md5_hh = function (a, b, c, d, x, s, t) { return this.md5_cmn(b ^ c ^ d, a, b, x, s, t); }; v2.md5_ii = function (a, b, c, d, x, s, t) { return this.md5_cmn(c ^ (b | ~d), a, b, x, s, t); }; v2.core_md5 = function (x, len) { x[len >> 5] |= 128 << len % 32; x[(len + 64 >>> 9 << 4) + 14] = len; var v5 = 1732584193; var v4 = -271733879; var v3 = -1732584194; var v2 = 271733878; var v6 = 0; while (v6 < x.length) { var v11 = v5; var v10 = v4; var v9 = v3; var v8 = v2; v5 = this.md5_ff(v5, v4, v3, v2, x[v6 + 0], 7, -680876936); v2 = this.md5_ff(v2, v5, v4, v3, x[v6 + 1], 12, -389564586); v3 = this.md5_ff(v3, v2, v5, v4, x[v6 + 2], 17, 606105819); v4 = this.md5_ff(v4, v3, v2, v5, x[v6 + 3], 22, -1044525330); v5 = this.md5_ff(v5, v4, v3, v2, x[v6 + 4], 7, -176418897); v2 = this.md5_ff(v2, v5, v4, v3, x[v6 + 5], 12, 1200080426); v3 = this.md5_ff(v3, v2, v5, v4, x[v6 + 6], 17, -1473231341); v4 = this.md5_ff(v4, v3, v2, v5, x[v6 + 7], 22, -45705983); v5 = this.md5_ff(v5, v4, v3, v2, x[v6 + 8], 7, 1770035416); v2 = this.md5_ff(v2, v5, v4, v3, x[v6 + 9], 12, -1958414417); v3 = this.md5_ff(v3, v2, v5, v4, x[v6 + 10], 17, -42063); v4 = this.md5_ff(v4, v3, v2, v5, x[v6 + 11], 22, -1990404162); v5 = this.md5_ff(v5, v4, v3, v2, x[v6 + 12], 7, 1804603682); v2 = this.md5_ff(v2, v5, v4, v3, x[v6 + 13], 12, -40341101); v3 = this.md5_ff(v3, v2, v5, v4, x[v6 + 14], 17, -1502002290); v4 = this.md5_ff(v4, v3, v2, v5, x[v6 + 15], 22, 1236535329); v5 = this.md5_gg(v5, v4, v3, v2, x[v6 + 1], 5, -165796510); v2 = this.md5_gg(v2, v5, v4, v3, x[v6 + 6], 9, -1069501632); v3 = this.md5_gg(v3, v2, v5, v4, x[v6 + 11], 14, 643717713); v4 = this.md5_gg(v4, v3, v2, v5, x[v6 + 0], 20, -373897302); v5 = this.md5_gg(v5, v4, v3, v2, x[v6 + 5], 5, -701558691); v2 = this.md5_gg(v2, v5, v4, v3, x[v6 + 10], 9, 38016083); v3 = this.md5_gg(v3, v2, v5, v4, x[v6 + 15], 14, -660478335); v4 = this.md5_gg(v4, v3, v2, v5, x[v6 + 4], 20, -405537848); v5 = this.md5_gg(v5, v4, v3, v2, x[v6 + 9], 5, 568446438); v2 = this.md5_gg(v2, v5, v4, v3, x[v6 + 14], 9, -1019803690); v3 = this.md5_gg(v3, v2, v5, v4, x[v6 + 3], 14, -187363961); v4 = this.md5_gg(v4, v3, v2, v5, x[v6 + 8], 20, 1163531501); v5 = this.md5_gg(v5, v4, v3, v2, x[v6 + 13], 5, -1444681467); v2 = this.md5_gg(v2, v5, v4, v3, x[v6 + 2], 9, -51403784); v3 = this.md5_gg(v3, v2, v5, v4, x[v6 + 7], 14, 1735328473); v4 = this.md5_gg(v4, v3, v2, v5, x[v6 + 12], 20, -1926607734); v5 = this.md5_hh(v5, v4, v3, v2, x[v6 + 5], 4, -378558); v2 = this.md5_hh(v2, v5, v4, v3, x[v6 + 8], 11, -2022574463); v3 = this.md5_hh(v3, v2, v5, v4, x[v6 + 11], 16, 1839030562); v4 = this.md5_hh(v4, v3, v2, v5, x[v6 + 14], 23, -35309556); v5 = this.md5_hh(v5, v4, v3, v2, x[v6 + 1], 4, -1530992060); v2 = this.md5_hh(v2, v5, v4, v3, x[v6 + 4], 11, 1272893353); v3 = this.md5_hh(v3, v2, v5, v4, x[v6 + 7], 16, -155497632); v4 = this.md5_hh(v4, v3, v2, v5, x[v6 + 10], 23, -1094730640); v5 = this.md5_hh(v5, v4, v3, v2, x[v6 + 13], 4, 681279174); v2 = this.md5_hh(v2, v5, v4, v3, x[v6 + 0], 11, -358537222); v3 = this.md5_hh(v3, v2, v5, v4, x[v6 + 3], 16, -722521979); v4 = this.md5_hh(v4, v3, v2, v5, x[v6 + 6], 23, 76029189); v5 = this.md5_hh(v5, v4, v3, v2, x[v6 + 9], 4, -640364487); v2 = this.md5_hh(v2, v5, v4, v3, x[v6 + 12], 11, -421815835); v3 = this.md5_hh(v3, v2, v5, v4, x[v6 + 15], 16, 530742520); v4 = this.md5_hh(v4, v3, v2, v5, x[v6 + 2], 23, -995338651); v5 = this.md5_ii(v5, v4, v3, v2, x[v6 + 0], 6, -198630844); v2 = this.md5_ii(v2, v5, v4, v3, x[v6 + 7], 10, 1126891415); v3 = this.md5_ii(v3, v2, v5, v4, x[v6 + 14], 15, -1416354905); v4 = this.md5_ii(v4, v3, v2, v5, x[v6 + 5], 21, -57434055); v5 = this.md5_ii(v5, v4, v3, v2, x[v6 + 12], 6, 1700485571); v2 = this.md5_ii(v2, v5, v4, v3, x[v6 + 3], 10, -1894986606); v3 = this.md5_ii(v3, v2, v5, v4, x[v6 + 10], 15, -1051523); v4 = this.md5_ii(v4, v3, v2, v5, x[v6 + 1], 21, -2054922799); v5 = this.md5_ii(v5, v4, v3, v2, x[v6 + 8], 6, 1873313359); v2 = this.md5_ii(v2, v5, v4, v3, x[v6 + 15], 10, -30611744); v3 = this.md5_ii(v3, v2, v5, v4, x[v6 + 6], 15, -1560198380); v4 = this.md5_ii(v4, v3, v2, v5, x[v6 + 13], 21, 1309151649); v5 = this.md5_ii(v5, v4, v3, v2, x[v6 + 4], 6, -145523070); v2 = this.md5_ii(v2, v5, v4, v3, x[v6 + 11], 10, -1120210379); v3 = this.md5_ii(v3, v2, v5, v4, x[v6 + 2], 15, 718787259); v4 = this.md5_ii(v4, v3, v2, v5, x[v6 + 9], 21, -343485551); v5 = this.safe_add(v5, v11); v4 = this.safe_add(v4, v10); v3 = this.safe_add(v3, v9); v2 = this.safe_add(v2, v8); v6 += 16; } return Array(v5, v4, v3, v2); }; v2.core_hmac_md5 = function (key, data) { var v3 = new Array(this.str2binl(key)); if (v3.length > 16) { v3 = this.core_md5(v3, key.length * this.chrsz); } var v4 = new Array(16); var v5 = new Array(16); var v2 = 0; while (v2 < 16) { v4[v2] = v3[v2] ^ 909522486; v5[v2] = v3[v2] ^ 1549556828; ++v2; } var v6 = new Array(this.core_md5(v4.concat(this.str2binl(data)), 512 + data.length * this.chrsz)); return this.core_md5(v5.concat(v6), 640); }; v2.safe_add = function (x, y) { var v1 = new Number((x & 65535) + (y & 65535)); var v2 = new Number((x >> 16) + (y >> 16) + (v1 >> 16)); return v2 << 16 | v1 & 65535; }; v2.bit_rol = function (num, cnt) { return num << cnt | num >>> 32 - cnt; }; v2.str2binl = function (str) { var v4 = new Array(); var v5 = (1 << this.chrsz) - 1; var v2 = 0; while (v2 < str.length * this.chrsz) { v4[v2 >> 5] |= (str.charCodeAt(v2 / this.chrsz) & v5) << v2 % 32; v2 += this.chrsz; } return v4; }; v2.binl2str = function (bin) { var v4 = new String(''); var v5 = (1 << this.chrsz) - 1; var v2 = 0; while (v2 < bin.length * 32) { v4 += String.fromCharCode(bin[v2 >> 5] >>> v2 % 32 & v5); v2 += this.chrsz; } return v4; }; v2.binl2hex = function (binarray) { var v3 = '0123456789abcdef'; var v4 = new String(''); var v1 = 0; while (v1 < binarray.length * 4) { v4 += v3.charAt(binarray[v1 >> 2] >> (v1 % 4) * 8 + 4 & 15) + v3.charAt(binarray[v1 >> 2] >> (v1 % 4) * 8 & 15); ++v1; } return v4; }; v2.binl2b64 = function (binarray) { var v7 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'; var v5 = new String(''); var v3 = 0; while (v3 < binarray.length * 4) { var v6 = (binarray[v3 >> 2] >> 8 * (v3 % 4) & 255) << 16 | (binarray[v3 + 1 >> 2] >> 8 * ((v3 + 1) % 4) & 255) << 8 | binarray[v3 + 2 >> 2] >> 8 * ((v3 + 2) % 4) & 255; var v2 = 0; while (v2 < 4) { if (v3 * 8 + v2 * 6 > binarray.length * 32) { v5 += this.b64pad; } else { v5 += v7.charAt(v6 >> 6 * (3 - v2) & 63); } ++v2; } v3 += 3; } return v5; }; v2.b64pad = new String(''); v2.chrsz = new Number(8); ASSetPropFlags(_global.md5.prototype, null, 1); } #endinitclip } movieClip 2980 __Packages.Particle { #initclip if (!_global.Particle) { var v1 = function (libParticle, xpos, ypos, stageWidth, stageHeight) { this._stageWidth = stageWidth; this._stageHeight = stageHeight; this.clip = libParticle; this.clip._x = xpos; this.clip._y = ypos; }; _global.Particle = v1; var v2 = v1.prototype; v2.setVel = function (xvel, yvel) { this._xVel = xvel; this._yVel = yvel; }; v2.setSize = function (size) { this.clip._width = size; this.clip._height = size; }; v2.setAlphaDecr = function (val) { this._alphaDecr = val; }; v2.update = function () { this.clip._x += this._xVel; this.clip._y += this._yVel; this.clip._alpha -= this._alphaDecr; }; v2.destroy = function () { removeMovieClip(this.clip); }; v2._alphaDecr = 0; ASSetPropFlags(_global.Particle.prototype, null, 1); } #endinitclip } movieClip 2981 __Packages.com.Newgrounds.BaseN { #initclip if (!_global.com) { _global.com = new Object(); } if (!_global.com.Newgrounds) { _global.com.Newgrounds = new Object(); } if (!_global.com.Newgrounds.BaseN) { var v1 = function (hash) { this.ceiling = 100000000000000.0; if (hash) { this.hashIndex = hash; } else { this.hashIndex = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ`~@#$%^&*()+|;/'; } this.bitSize = this.hashIndex.length; this.hashVal = new Object(); this.i = 0; while (this.i < this.bitSize) { this.hashVal[this.hashIndex.charAt(this.i)] = this.i; ++this.i; } }; com.Newgrounds.BaseN = v1; var v2 = v1.prototype; v2.verify = function (s) { if (this.hashVal[s] != undefined) { return true; } else { return false; } }; v2.encode = function (n, minchars) { this.debug.lastencode = ''; if (typeof this.i != 'string') { n = n.toString(); } if (n.charAt(0) == '-') { var v3 = '-'; n = n.substring(1); } else { var v3 = ''; } if ((String(n)).indexOf('.') > -1) { var v4 = (String(n)).split('.', 2); return v3 + this.baseNEncoder(v4[0], minchars) + '.' + this.baseNEncoder(v4[1]); } else { this.debug.lastencode += '\tNo decimal\r'; return v3 + this.baseNEncoder(n, minchars); } }; v2.decode = function (s) { var v4 = 1; if (s.charAt(0) == '-') { v4 = -1; s = s.substring(1, s.length); } var v3 = s.indexOf('.'); if (v3 > -1) { var v5 = Math.pow(10, this.baseNDecoder(s.substring(v3 + 1, s.length))); return (this.baseNDecoder(s.substring(0, v3)) / v5) * v4; } else { return this.baseNDecoder(s) * v4; } }; v2.baseNEncoder = function (n, minchars) { if (!minchars) { minchars = 1; } var v4 = ''; while (n != 0) { n = Math.round(n); var v3 = n % this.bitSize; if (Math.round(v3) != v3) { trace('BaseN failed on ' + n + '%' + this.bitSize + ' = ' + v3 + ' ' + int(n) + ' ' + int(this.bitSize)); } v4 = this.hashIndex.charAt(v3) + v4; this.debug.lastencode += '\t-> n:' + n + ' % bitSize:' + this.bitSize + ' = ' + v3 + ', final char=' + v4 + '\n'; n -= v3; n /= this.bitSize; } if (minchars) { while (v4.length < minchars) { v4 = this.hashIndex.charAt(0) + v4; } } return v4; }; v2.baseNDecoder = function (s) { var v2 = 0; var v6 = 0; this.i = 0; while (this.i < s.length) { var v3 = s.charAt(s.length - this.i - 1); if (v3 == this.hashIndex.charAt(0)) { var v5 = 0; } else { var v5 = this.hashVal[v3] * Math.pow(this.bitSize, this.i); } v2 += v5; if (v2 >= this.ceiling) { v6 += (v2 - v2 % this.ceiling) / this.ceiling; v2 %= this.ceiling; } ++this.i; } if (v6 > 0) { v2 = '' + v2; while (v2.length < (this.ceiling.toString()).length - 1) { v2 = '0' + v2; } v2 = '' + v6 + v2; } return v2; }; v2.debug = new Object(); ASSetPropFlags(com.Newgrounds.BaseN.prototype, null, 1); } #endinitclip } movieClip 2982 __Packages.com.Newgrounds.NewgroundsAPIError { #initclip if (!_global.com) { _global.com = new Object(); } if (!_global.com.Newgrounds) { _global.com.Newgrounds = new Object(); } if (!_global.com.Newgrounds.NewgroundsAPIError) { var v1 = function (error, msg) { if ((Number(error)).toString() == String(error)) { error = Number(error); } else { if (com.Newgrounds.NewgroundsAPIError.error_codes[String(error)]) { error = com.Newgrounds.NewgroundsAPIError.error_codes[String(error)]; } else { error = 0; } } this.code = error; this.message = msg; this.name = com.Newgrounds.NewgroundsAPIError.error_names[error]; this.alias = com.Newgrounds.NewgroundsAPIError.aliases[error]; }; com.Newgrounds.NewgroundsAPIError = v1; var v2 = v1.prototype; v1.init_codes = function () { var v2 = new Object(); var v1 = 0; while (v1 < com.Newgrounds.NewgroundsAPIError.aliases.length) { v2[com.Newgrounds.NewgroundsAPIError.aliases[v1]] = v1; ++v1; } return v2; }; v1.init_names = function () { var v5 = new Array(); var v3 = 0; while (v3 < com.Newgrounds.NewgroundsAPIError.aliases.length) { var v2 = (com.Newgrounds.NewgroundsAPIError.aliases[v3].toLowerCase()).split('_'); var v1 = 0; while (v1 < v2.length) { v2[v1] = (v2[v1].substr(0, 1)).toUpperCase() + v2[v1].substr(1, v2[v1].length); for (var v4 in com.Newgrounds.NewgroundsAPIError.always_caps) { if (v2[v1].toUpperCase() == com.Newgrounds.NewgroundsAPIError.always_caps[v4]) { v2[v1] = v2[v1].toUpperCase(); } } ++v1; } v5[v3] = v2.join(' '); ++v3; } return v5; }; v2.isError = function () { return true; }; v1.aliases = new Array('UNKNOWN_ERROR', 'INVALID_API_ID', 'MISSING_PARAM', 'INVALID_STAT_ID', 'INVALID_COMMAND_ID', 'FLASH_ADS_NOT_APPROVED', 'PERMISSION_DENIED', 'IDENTIFICATION_REQUIRED', 'INVALID_EMAIL_ADDRESS', 'BANNED_USER', 'SESSION_EXPIRED', 'INVALID_SCORE', 'INVALID_MEDAL', 'INVALID_FOLDER', 'FILE_NOT_FOUND', 'SITE_ID_REQUIRED', 'UPLOAD_IN_PROGRESS', 'USER_CANCELLED', 'CONFIRM_REQUEST', 'CONNECTION_FAILED'); v1.always_caps = new Array('API', 'URL', 'ID'); v1.error_codes = com.Newgrounds.NewgroundsAPIError.init_codes(); v1.error_names = com.Newgrounds.NewgroundsAPIError.init_names(); v2.code = 0; ASSetPropFlags(com.Newgrounds.NewgroundsAPIError.prototype, null, 1); } #endinitclip } movieClip 2983 __Packages.com.Newgrounds.NewgroundsAPI { #initclip if (!_global.com) { _global.com = new Object(); } if (!_global.com.Newgrounds) { _global.com.Newgrounds = new Object(); } if (!_global.com.Newgrounds.NewgroundsAPI) { var v1 = function () {}; com.Newgrounds.NewgroundsAPI = v1; var v2 = v1.prototype; v1.setMovieVersion = function (v) { if (v) { com.Newgrounds.NewgroundsAPI.version = String(v); } }; v1.setUserEmail = function (e) { com.Newgrounds.NewgroundsAPI.user_email = e; }; v1.getOfficialVersionURL = function () { var v1 = com.Newgrounds.NewgroundsAPI.GATEWAY_URL + '?tracker_id=' + com.Newgrounds.NewgroundsAPI.movie_id + '&command_id=' + com.Newgrounds.NewgroundsAPI.getCommandID('loadOfficalVersion') + '&seed=' + Math.random(); if (com.Newgrounds.NewgroundsAPI.debug) { v1 += '&debug=1'; } return v1; }; v1.hasUserSession = function () { if (com.Newgrounds.NewgroundsAPI.session_id && com.Newgrounds.NewgroundsAPI.publisher_id) { return true; return false; } if (_root.NewgroundsAPI_PublisherID && _root.NewgroundsAPI_SessionID) { return true; } return false; }; v1.isNewgrounds = function () { return com.Newgrounds.NewgroundsAPI.publisher_id == 1 || _root.NewgroundsAPI_PublisherID == 1 || ((com.Newgrounds.NewgroundsAPI.getHost()).toLowerCase()).indexOf('ungrounded.net') > -1; }; v1.hasPublisher = function () { return com.Newgrounds.NewgroundsAPI.publisher_id || _root.NewgroundsAPI_PublisherID; }; v1.hasUserEmail = function () { if (com.Newgrounds.NewgroundsAPI.user_email) { return true; } return false; }; v1.connectionTimeOut = function () { clearInterval(com.Newgrounds.NewgroundsAPI.timeout); com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.MOVIE_CONNECTED, false, new com.Newgrounds.NewgroundsAPIError('CONNECTION_FAILED', 'Connection to NewgroundsAPI gateway timed out.')); }; v1.connectMovie = function (m_id, encrypt_key, debug_mode) { if (com.Newgrounds.NewgroundsAPI.connected) { return undefined; } var v2 = function () { com.Newgrounds.NewgroundsAPI.connectionTimeOut(); }; com.Newgrounds.NewgroundsAPI.timeout = setInterval(v2, 8000, null); if (!m_id) { com.Newgrounds.NewgroundsAPI.fatalError('NewgroundsAPI.connectMovie() - missing required movie_id parameter', 'connectMovie'); } com.Newgrounds.NewgroundsAPI.movie_id = String(m_id); com.Newgrounds.NewgroundsAPI.tracker_id = Number(com.Newgrounds.NewgroundsAPI.movie_id.substring(0, com.Newgrounds.NewgroundsAPI.movie_id.indexOf(':'))); com.Newgrounds.NewgroundsAPI.encryption_key = encrypt_key; com.Newgrounds.NewgroundsAPI.debug = debug_mode; if (_root.NewgroundsAPI_PublisherID) { com.Newgrounds.NewgroundsAPI.publisher_id = _root.NewgroundsAPI_PublisherID; if (_root.NewgroundsAPI_SessionID) { com.Newgrounds.NewgroundsAPI.session_id = _root.NewgroundsAPI_SessionID; } } else { com.Newgrounds.NewgroundsAPI.publisher_id = 1; com.Newgrounds.NewgroundsAPI.session_id = null; com.Newgrounds.NewgroundsAPI.user_id = 0; com.Newgrounds.NewgroundsAPI.user_name = 'Guest'; } if (_root.NewgroundsAPI_UserName) { com.Newgrounds.NewgroundsAPI.user_name = _root.NewgroundsAPI_UserName; } if (_root.NewgroundsAPI_UserID) { com.Newgrounds.NewgroundsAPI.user_id = _root.NewgroundsAPI_UserID; } com.Newgrounds.NewgroundsAPI.connected = true; com.Newgrounds.NewgroundsAPI.sendCommand('connectMovie', {'host': com.Newgrounds.NewgroundsAPI.getHost(), 'movie_version': com.Newgrounds.NewgroundsAPI.version}); }; v1.getHost = function () { if (!com.Newgrounds.NewgroundsAPI.host) { var v1 = _url; if (v1.indexOf('http://') > -1 or v1.indexOf('https://') > -1) { com.Newgrounds.NewgroundsAPI.host = (v1.split('/'))[2].toLowerCase(); return com.Newgrounds.NewgroundsAPI.host; } com.Newgrounds.NewgroundsAPI.host = 'localhost'; } return com.Newgrounds.NewgroundsAPI.host; }; v1.loadNewgrounds = function () { com.Newgrounds.NewgroundsAPI.sendCommand('loadNewgrounds', {'host': com.Newgrounds.NewgroundsAPI.getHost()}, true); }; v1.loadMySite = function () { com.Newgrounds.NewgroundsAPI.sendCommand('loadMySite', {'host': com.Newgrounds.NewgroundsAPI.getHost()}); }; v1.loadCustomLink = function (link) { com.Newgrounds.NewgroundsAPI.sendCommand('loadCustomLink', {'host': com.Newgrounds.NewgroundsAPI.getHost(), 'link': link}, true); }; v1.logCustomEvent = function (event) { com.Newgrounds.NewgroundsAPI.sendCommand('logCustomEvent', {'host': com.Newgrounds.NewgroundsAPI.getHost(), 'event': event}); }; v1.postScore = function (score, value, get_best) { if (!score or value == undefined) { com.Newgrounds.NewgroundsAPI.sendError({'command_id': com.Newgrounds.NewgroundsAPI.getCommandID('postScore')}, new com.Newgrounds.NewgroundsAPIError('MISSING_PARAM', 'missing required parameter(s)')); return undefined; } com.Newgrounds.NewgroundsAPI.sendSecureCommand('postScore', {'score': score, 'value': value, 'get_best': get_best}); }; v1.getTodaysScores = function (score, params) { com.Newgrounds.NewgroundsAPI.getScores(score, 't', params, 'getTodaysScores'); }; v1.getYesterdaysScores = function (score, params) { com.Newgrounds.NewgroundsAPI.getScores(score, 'y', params, 'getYesterdaysScores'); }; v1.getThisWeeksScores = function (score, params) { com.Newgrounds.NewgroundsAPI.getScores(score, 'w', params, 'getThisWeeksScores'); }; v1.getThisMonthsScores = function (score, params) { com.Newgrounds.NewgroundsAPI.getScores(score, 'm', params, 'getThisMonthsScores'); }; v1.getThisYearsScores = function (score, params) { com.Newgrounds.NewgroundsAPI.getScores(score, 'y', params, 'getThisYearsScores'); }; v1.getAlltimeScores = function (score, params) { com.Newgrounds.NewgroundsAPI.getScores(score, 'a', params, 'getAlltimeScores'); }; v1.getScores = function (score, period, params, command_name) { if (!score) { com.Newgrounds.NewgroundsAPI.sendError({'command_id': com.Newgrounds.NewgroundsAPI.getCommandID(command_name)}, new com.Newgrounds.NewgroundsAPIError('MISSING_PARAM', 'missing required score name')); return undefined; } if (!params) { params = new Object(); } if (!com.Newgrounds.NewgroundsAPI.hasUserSession()) { com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.SCORES_LOADED, false, new com.Newgrounds.NewgroundsAPIError('SITE_ID_REQUIRED', 'Host \'' + com.Newgrounds.NewgroundsAPI.getHost() + '\' does not have high scores enabled')); return undefined; } params.publisher_id = com.Newgrounds.NewgroundsAPI.publisher_id; params.period = period; params.score = score; if (params.user_id) { var v3 = period; } else { var v3 = period + '-u'; } if (com.Newgrounds.NewgroundsAPI.score_page_counts[v3] == undefined) { params.request_page_count = true; } com.Newgrounds.NewgroundsAPI.sendCommand('getScores', params); }; v1.unlockMedal = function (medal, get_score) { if (!medal) { com.Newgrounds.NewgroundsAPI.sendError({'command_id': com.Newgrounds.NewgroundsAPI.getCommandID('unlockMedal')}, new com.Newgrounds.NewgroundsAPIError('MISSING_PARAM', 'missing required medal name')); return undefined; } var v1 = new Object(); v1.medal = medal; if (get_score) { v1.get_score = get_score; } com.Newgrounds.NewgroundsAPI.sendSecureCommand('unlockMedal', v1); }; v1.loadMedals = function () { if (com.Newgrounds.NewgroundsAPI.medals) { com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.MEDALS_LOADED, true, {'medals': com.Newgrounds.NewgroundsAPI.medals}); return undefined; } var v1 = new Object(); if (com.Newgrounds.NewgroundsAPI.hasUserSession()) { v1.publisher_id = com.Newgrounds.NewgroundsAPI.publisher_id; v1.user_id = com.Newgrounds.NewgroundsAPI.user_id; } com.Newgrounds.NewgroundsAPI.sendCommand('getMedals', v1); }; v1.getMedals = function () { return com.Newgrounds.NewgroundsAPI.medals; }; v1.saveFile = function (folder, filename, contents, thumbnail_source) { if (!com.Newgrounds.NewgroundsAPI.save_file) { com.Newgrounds.NewgroundsAPI.save_file = new com.Newgrounds.NewgroundsAPISaveFile(com.Newgrounds.NewgroundsAPI.movie_id, folder, filename); com.Newgrounds.NewgroundsAPI.save_file.setContents(contents); if (thumbnail_source) { com.Newgrounds.NewgroundsAPI.save_file.setThumbnail(thumbnail_source); } com.Newgrounds.NewgroundsAPI.save_file.onError = function (msg) { var v1 = new com.Newgrounds.NewgroundsAPIError('PERMISSION_DENIED', msg); com.Newgrounds.NewgroundsAPI.sendError({'command_id': com.Newgrounds.NewgroundsAPI.getCommandID('saveFile')}, v1); com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.FILE_SAVED, false, v1); }; com.Newgrounds.NewgroundsAPI.save_file.onCancel = function (msg) { var v1 = new com.Newgrounds.NewgroundsAPIError('USER_CANCELLED', msg); com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.FILE_SAVED, false, v1); }; com.Newgrounds.NewgroundsAPI.save_file.submit(); } else { var v1 = new com.Newgrounds.NewgroundsAPIError('UPLOAD_IN_PROGRESS', 'Please wait for the previous file to finish uploading'); com.Newgrounds.NewgroundsAPI.sendError({'command_id': com.Newgrounds.NewgroundsAPI.getCommandID('saveFile')}, v1); com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.FILE_SAVED, false, v1); } }; v1.checkFilePrivs = function (folder, filename) { if (com.Newgrounds.NewgroundsAPI.user_id) { var v1 = com.Newgrounds.NewgroundsAPI.user_id; } else { var v1 = 0; } var v2 = {'folder': folder, 'filename': filename, 'user_id': v1, 'publisher_id': com.Newgrounds.NewgroundsAPI.publisher_id}; com.Newgrounds.NewgroundsAPI.sendCommand('checkFilePrivs', v2); }; v1.finishFileSave = function (folder, filename, description, share, file, thumbnail) { var v2; v2 = {'folder': folder, 'filename': filename, 'description': description, 'share': share}; var v1; v1 = {'file': file, 'thumbnail': thumbnail}; com.Newgrounds.NewgroundsAPI.sendSecureCommand('saveFile', v2, null, v1); }; v1.getFiles = function (folder, options) { var v7 = {'name': 1, 'date': 2, 'score': 3}; var v2 = {'user_only': false, 'sort_on': 'date', 'page': 1, 'results_per_page': 20, 'sort_descending': true}; var v6 = new Array(); for (var v10 in v7) { v6.push('\'' + v10 + '\''); } var v4 = new Array(); for (var v9 in v2) { v4.push('\'' + v9 + '\''); } if (options.sort_descending && !v7[options.sort_descending]) { var v3 = new com.Newgrounds.NewgroundsAPIError('MISSING_PARAM', '\'' + options.sort_descending + '\' is not a valid sort_on value. Valid values are: ' + v6.join(', ')); com.Newgrounds.NewgroundsAPI.sendError({'command_id': com.Newgrounds.NewgroundsAPI.getCommandID('getFiles')}, v3); delete options.sort_descending; } var v8; if (options) { for (v10 in options) { if (v2[v10] == undefined) { v3 = new com.Newgrounds.NewgroundsAPIError('MISSING_PARAM', '\'' + v10 + '\' is not a valid option. Valid options are: ' + v4.join(', ')); com.Newgrounds.NewgroundsAPI.sendError({'command_id': com.Newgrounds.NewgroundsAPI.getCommandID('getFiles')}, v3); delete options[v10]; } else { if (typeof options[v10] != typeof v2[v10]) { v3 = new com.Newgrounds.NewgroundsAPIError('MISSING_PARAM', 'option \'' + v10 + '\' should be the following type: ' + typeof v2[v10]); com.Newgrounds.NewgroundsAPI.sendError({'command_id': com.Newgrounds.NewgroundsAPI.getCommandID('getFiles')}, v3); delete options[v10]; } } } v8 = options; } else { v8 = new Object(); } if (com.Newgrounds.NewgroundsAPI.hasUserSession()) { v8.publisher_id = com.Newgrounds.NewgroundsAPI.publisher_id; v8.user_id = com.Newgrounds.NewgroundsAPI.user_id; } v8.folder = folder; com.Newgrounds.NewgroundsAPI.sendCommand('getFiles', v8); }; v1.getConfirmation = function (command_name, event, msg, target, confirm, cancel) { var v1 = new com.Newgrounds.NewgroundsAPIError('CONFIRM_REQUEST', msg); v1.confirm = function () { target[confirm](); }; v1.cancel = function () { target[cancel](); }; v1.command = com.Newgrounds.NewgroundsAPI.getCommandID(command_name); com.Newgrounds.NewgroundsAPI.callListener(event, false, v1); }; v1.doBlockHost = function (event) { _root.stop(); com.Newgrounds.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 ' + com.Newgrounds.NewgroundsAPI.getHost() + '.'; v2 += '\r\rFor an aproved copy, please visit:\r'; var v4 = v2.length; v2 += event.data.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(com.Newgrounds.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(com.Newgrounds.NewgroundsAPI.normal_format); com.Newgrounds.NewgroundsAPI.link_format.url = event.data.redirect_url; _root.NGAPI_deny_host_overlay.message.setTextFormat(v4, v3, com.Newgrounds.NewgroundsAPI.link_format); }; v1.onNewVersionAvailable = function (event) { _root.stop(); com.Newgrounds.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 ' + event.data.movie_version + ' is now available at:' + '\n'; var v6 = v3.length; v3 += event.data.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(com.Newgrounds.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(com.Newgrounds.NewgroundsAPI.normal_format); com.Newgrounds.NewgroundsAPI.link_format.url = event.data.redirect_url; _root.NGAPI_new_version_overlay.message.setTextFormat(v6, v4, com.Newgrounds.NewgroundsAPI.link_format); }; v1.initTextFormats = function () { if (!com.Newgrounds.NewgroundsAPI.error_format) { com.Newgrounds.NewgroundsAPI.error_format = new TextFormat(); com.Newgrounds.NewgroundsAPI.error_format.font = 'Arial Black'; com.Newgrounds.NewgroundsAPI.error_format.size = 48; com.Newgrounds.NewgroundsAPI.error_format.color = 16711680; } if (!com.Newgrounds.NewgroundsAPI.header_format) { com.Newgrounds.NewgroundsAPI.header_format = new TextFormat(); com.Newgrounds.NewgroundsAPI.header_format.font = 'Arial Black'; com.Newgrounds.NewgroundsAPI.header_format.size = 24; com.Newgrounds.NewgroundsAPI.header_format.color = 16777215; } if (!com.Newgrounds.NewgroundsAPI.normal_format) { com.Newgrounds.NewgroundsAPI.normal_format = new TextFormat(); com.Newgrounds.NewgroundsAPI.normal_format.font = 'Arial'; com.Newgrounds.NewgroundsAPI.normal_format.bold = true; com.Newgrounds.NewgroundsAPI.normal_format.size = 12; com.Newgrounds.NewgroundsAPI.normal_format.color = 16777215; } if (!com.Newgrounds.NewgroundsAPI.link_format) { com.Newgrounds.NewgroundsAPI.link_format = new TextFormat(); com.Newgrounds.NewgroundsAPI.link_format.color = 16776960; com.Newgrounds.NewgroundsAPI.link_format.underline = true; } }; v1.doEvent = function (e) { switch (com.Newgrounds.NewgroundsAPI.getCommandName(e.command_id)) { case 'connectMovie': clearInterval(com.Newgrounds.NewgroundsAPI.timeout); com.Newgrounds.NewgroundsAPI.sendMessage('You have successfully connected to the Newgrounds API Gateway'); com.Newgrounds.NewgroundsAPI.sendMessage('Movie identified as "' + e.movie_name + '"'); com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.MOVIE_CONNECTED, e.success, {'movie_name': e.movie_name}); var v4 = false; if (e.ad_status === -1) { var v6 = 'This movie was not approved to run Flash Ads.'; com.Newgrounds.NewgroundsAPI.sendWarning(v6); com.Newgrounds.NewgroundsAPI.sendWarning('visit ' + com.Newgrounds.NewgroundsAPI.AD_TERMS_URL + ' to view our approval guidelines'); if (!e.ad_url) { com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.ADS_APPROVED, false, new com.Newgrounds.NewgroundsAPIError('FLASH_ADS_NOT_APPROVED', v6)); } else { v4 = true; } } else { if (e.ad_status === 0) { var v6 = 'Flash Ads are currently awaiting approval.'; com.Newgrounds.NewgroundsAPI.sendNotice(v6); if (!e.ad_url) { com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.ADS_APPROVED, false, new com.Newgrounds.NewgroundsAPIError('FLASH_ADS_NOT_APPROVED', v6)); } else { v4 = true; } } } if (e.ad_url) { com.Newgrounds.NewgroundsAPI.ad_url = unescape(e.ad_url); if (!v4) { com.Newgrounds.NewgroundsAPI.sendMessage('This movie has been approved to run Flash Ads!'); } com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.ADS_APPROVED, true); } if (e.deny_host) { v6 = com.Newgrounds.NewgroundsAPI.getHost() + ' does not have permission to run this movie!'; com.Newgrounds.NewgroundsAPI.sendWarning(v6); com.Newgrounds.NewgroundsAPI.sendWarning('\tUpdate your API configuration to unblock ' + com.Newgrounds.NewgroundsAPI.getHost()); com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.HOST_BLOCKED, true, {'movie_url': unescape(e.movie_url), 'redirect_url': com.Newgrounds.NewgroundsAPI.getOfficialVersionURL()}); } if (e.movie_version) { com.Newgrounds.NewgroundsAPI.sendWarning('According to your API Configuration, this version is out of date.'); if (com.Newgrounds.NewgroundsAPI.version) { com.Newgrounds.NewgroundsAPI.sendWarning('\tThe this movie is version ' + com.Newgrounds.NewgroundsAPI.version); } com.Newgrounds.NewgroundsAPI.sendWarning('\tThe most current version is ' + e.movie_version); com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.NEW_VERSION_AVAILABLE, true, {'movie_version': e.movie_version, 'movie_url': unescape(e.movie_url), 'redirect_url': com.Newgrounds.NewgroundsAPI.getOfficialVersionURL()}); } if (e.request_portal_url) { com.Newgrounds.NewgroundsAPI.sendCommand('setPortalID', {'portal_url': _url}); } break; case 'logCustomEvent': if (e.success) { com.Newgrounds.NewgroundsAPI.sendMessage('Event \'' + e.event + '\' was logged.'); } com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.EVENT_LOGGED, e.success, {'event': e.event}); break; case 'postScore': var v7; if (e.success) { var v3 = 'User'; if (com.Newgrounds.NewgroundsAPI.user_email) { v3 = com.Newgrounds.NewgroundsAPI.user_email; } else { if (com.Newgrounds.NewgroundsAPI.user_name) { v3 = com.Newgrounds.NewgroundsAPI.user_name; } } com.Newgrounds.NewgroundsAPI.sendMessage(v3 + ' posted ' + e.value + ' to \'' + e.score + '\''); v7 = {'score': e.score, 'value': e.value, 'username': v3}; } com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.SCORE_POSTED, e.success, v7); break; case 'getScores': var v7 = new Object(); if (e.user_id) { var v5 = e.period; } else { var v5 = e.period + '-u'; } if (e.total_pages) { com.Newgrounds.NewgroundsAPI.score_page_counts[v5] = e.total_pages; } v7.user_id = e.user_id; v7.current_page = e.current_page; v7.total_pages = com.Newgrounds.NewgroundsAPI.score_page_counts[v5]; v7.scores = e.scores; v7.period = com.Newgrounds.NewgroundsAPI.getPeriodName(e.period); com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.SCORES_LOADED, e.success, v7); break; case 'unlockMedal': if (com.Newgrounds.NewgroundsAPI.medals) { var v2 = 0; while (v2 < com.Newgrounds.NewgroundsAPI.medals.length) { if (com.Newgrounds.NewgroundsAPI.medals[v2].medal_name === e.medal_name) { com.Newgrounds.NewgroundsAPI.medals[v2].medal_unlocked = true; break; } ++v2; } } var v7 = {'medal_name': e.medal_name, 'medal_value': e.medal_value, 'medal_difficulty': e.medal_difficulty}; com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.MEDAL_UNLOCKED, e.success, v7); break; case 'getMedals': com.Newgrounds.NewgroundsAPI.medals = e.medals; var v7 = {'medals': e.medals}; com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.MEDALS_LOADED, e.success, v7); break; break; case 'getFiles': break; case 'getSystemFiles': case 'saveFile': com.Newgrounds.NewgroundsAPI.save_file = null; var v7 = {'file_id': e.file_id, 'filename': e.filename, 'file_url': e.file_url, 'thumbnail': e.thumbnail, 'icon': e.icon}; com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.FILE_SAVED, e.success, v7); break; case 'checkFilePrivs': if (com.Newgrounds.NewgroundsAPI.save_file) { com.Newgrounds.NewgroundsAPI.save_file.checkPrivs(e); } else { var v7 = {'filename': e.filename, 'folder': e.folder, 'can_read': e.can_read, 'can_write': e.can_write}; com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.FILE_PRIVS_LOADED, e.success, v7); } } }; v1.setDefaultListeners = function () { var v1 = new Array(); v1[com.Newgrounds.NewgroundsAPI.events.HOST_BLOCKED] = {'listener': com.Newgrounds.NewgroundsAPI.doBlockHost}; v1[com.Newgrounds.NewgroundsAPI.events.NEW_VERSION_AVAILABLE] = {'listener': com.Newgrounds.NewgroundsAPI.onNewVersionAvailable}; return v1; }; v1.addEventListener = function (event, listener, params) { com.Newgrounds.NewgroundsAPI.listeners[event] = {'listener': listener, 'params': params}; }; v1.removeEventListener = function (event) { delete com.Newgrounds.NewgroundsAPI.listeners[event]; }; v1.getEventName = function (event) { for (var v2 in com.Newgrounds.NewgroundsAPI.events) { if (com.Newgrounds.NewgroundsAPI.events[v2] == event) { return v2; } } return undefined; }; v1.callListener = function (event, success, data, target) { com.Newgrounds.NewgroundsAPI.echo('Fired Event: ' + com.Newgrounds.NewgroundsAPI.getEventName(event)); if (com.Newgrounds.NewgroundsAPI.listeners[event]) { if (data.isError()) { com.Newgrounds.NewgroundsAPI.listeners[event].listener({'event': event, 'success': success, 'error': data, 'target': target}, com.Newgrounds.NewgroundsAPI.listeners[event].params); } else { com.Newgrounds.NewgroundsAPI.listeners[event].listener({'event': event, 'success': success, 'data': data, 'target': target}, com.Newgrounds.NewgroundsAPI.listeners[event].params); } } }; v1.getCommandName = function (id) { return id; }; v1.getCommandID = function (name) { return name; }; v1.getPeriodAliases = function () { var v1 = new Object(); for (var v2 in com.Newgrounds.NewgroundsAPI.period_aliases) { v1[com.Newgrounds.NewgroundsAPI.period_aliases[v2].alias] = v2; } return v1; }; v1.getPeriodName = function (p) { for (var v2 in com.Newgrounds.NewgroundsAPI.period_aliases) { if (v2 == p) { return com.Newgrounds.NewgroundsAPI.period_aliases[v2].name; } } return null; }; v1.getPeriodAlias = function (p) { for (var v2 in com.Newgrounds.NewgroundsAPI.period_aliases) { if (v2 == p) { return com.Newgrounds.NewgroundsAPI.period_aliases[v2].alias; } } return null; }; v1.sendError = function (c, e) { trace('[NewgroundsAPI ERROR] :: ' + com.Newgrounds.NewgroundsAPI.getCommandName(c.command_id) + '() - ' + e.name + ':' + '\n' + '\t\t\t\t' + e.message); }; v1.sendWarning = function (m, c) { if (c) { m += '\r[NewgroundsAPI WARNING] :: \tSee ' + com.Newgrounds.NewgroundsAPI.COMMANDS_WIKI_URL + c.toLowerCase() + ' for additional information.'; } trace('[NewgroundsAPI WARNING] :: ' + m); }; v1.sendNotice = function (m, c) { if (c) { m += '\r[NewgroundsAPI NOTICE] :: \tSee ' + com.Newgrounds.NewgroundsAPI.COMMANDS_WIKI_URL + c.toLowerCase() + ' for additional information.'; } trace('[NewgroundsAPI NOTICE] :: ' + m); }; v1.fatalError = function (m, c) { if (c) { m += '\r\tSee ' + com.Newgrounds.NewgroundsAPI.COMMANDS_WIKI_URL + c.toLowerCase() + ' for additional information.'; } throw '***ERROR*** frame=' + _root._currentframe + ', class=NewgroundsAPI' + '\n' + '\n' + m; }; v1.sendSecureCommand = function (command, secure_params, unsecure_params, files) { if (!com.Newgrounds.NewgroundsAPI.debug && !com.Newgrounds.NewgroundsAPI.hasUserSession() && !com.Newgrounds.NewgroundsAPI.hasUserEmail()) { com.Newgrounds.NewgroundsAPI.sendError({'command_id': com.Newgrounds.NewgroundsAPI.getCommandID(command)}, new com.Newgrounds.NewgroundsAPIError('IDENTIFICATION_REQUIRED', 'You must be logged in or provide an e-mail address ( using NewgroundsAPI.setUserEmail("name@domain.com"); ) to use ' + command + '().')); return undefined; } if (!command) { com.Newgrounds.NewgroundsAPI.fatalError('Missing command', 'sendSecureCommand'); } if (!secure_params) { com.Newgrounds.NewgroundsAPI.fatalError('Missing secure_params', 'sendSecureCommand'); } if (!unsecure_params) { unsecure_params = new Object(); } var v4 = ''; var v1 = 0; while (v1 < 16) { v4 += com.Newgrounds.NewgroundsAPI.compression_radix.charAt(Math.floor(Math.random() * com.Newgrounds.NewgroundsAPI.compression_radix.length)); ++v1; } if (com.Newgrounds.NewgroundsAPI.debug) { secure_params.session_id = ''; } else { secure_params.session_id = com.Newgrounds.NewgroundsAPI.session_id; } secure_params.as_version = 2; secure_params.user_email = com.Newgrounds.NewgroundsAPI.user_email; secure_params.publisher_id = com.Newgrounds.NewgroundsAPI.publisher_id; secure_params.seed = v4; secure_params.command_id = com.Newgrounds.NewgroundsAPI.getCommandID(command); var v10 = com.Newgrounds.MD5.calculate(v4); var v3 = v10 + com.Newgrounds.RC4.encrypt(com.Newgrounds.JSON.encode(secure_params), com.Newgrounds.NewgroundsAPI.encryption_key); var v9 = v3.length % 6; var v5 = ''; v1 = 0; while (v1 < v3.length) { var v2 = Number('0x' + v3.substr(v1, 6)); v5 += com.Newgrounds.NewgroundsAPI.compressor.encode(v2, 4); v1 += 6; } unsecure_params.secure = v9 + v5; com.Newgrounds.NewgroundsAPI.sendCommand('securePacket', unsecure_params, false, files); }; v1.sendCommand = function (command, params, open_browser, files) { if (!com.Newgrounds.NewgroundsAPI.connected and command != 'connectMovie') { var v11 = 'NewgroundsAPI.' + command + '() - NewgroundsAPI.connectMovie() must be called before this command can be called' + '\n'; com.Newgrounds.NewgroundsAPI.fatalError(v11, 'connectMovie'); } if (open_browser) { var v1 = new Object(); } else { var v1 = new LoadVars(); } v1.command_id = com.Newgrounds.NewgroundsAPI.getCommandID(command); v1.tracker_id = com.Newgrounds.NewgroundsAPI.movie_id; if (com.Newgrounds.NewgroundsAPI.debug) { v1.debug = com.Newgrounds.NewgroundsAPI.debug; } if (params) { for (var v8 in params) { v1[v8] = params[v8]; } } if (files) { for (v8 in files) { v1[v8] = files[v8]; } } com.Newgrounds.NewgroundsAPI.echo('OUTPUT: \r' + com.Newgrounds.JSON.encode(v1) + '\n'); if (open_browser) { var v5 = com.Newgrounds.NewgroundsAPI.GATEWAY_URL + '?seed=' + Math.random(); for (v8 in v1) { v5 += '&' + escape(v8) + '=' + escape(v1[v8]); } getURL(v5, '_blank'); v1.removeMovieClip(); } else { var v9 = new LoadVars(); v9.onData = function (data) { com.Newgrounds.NewgroundsAPI.echo('INPUT: \r' + data + '\n'); if (data) { var v1 = com.Newgrounds.JSON.decode(data); } else { var v1 = {'success': false}; } if (!v1.success) { var v3 = new com.Newgrounds.NewgroundsAPIError(v1.error_code, v1.error_msg); com.Newgrounds.NewgroundsAPI.sendError(v1, v3); } else { com.Newgrounds.NewgroundsAPI.doEvent(v1); } }; var v4 = new Array(); for (var v7 in v1) { v4.push(v7 + '=' + escape(v1[v7])); } com.Newgrounds.NewgroundsAPI.echo('POST ' + com.Newgrounds.NewgroundsAPI.GATEWAY_URL + '?' + v4.join('&')); v1.sendAndLoad(com.Newgrounds.NewgroundsAPI.GATEWAY_URL + '?seed=' + Math.random(), v9, 'POST'); } }; v1.renderAd = function (target) { if (com.Newgrounds.NewgroundsAPI.ad_swf_url) { target.background = target.createEmptyMovieClip('background', 100); target.background.beginFill(0); target.background.moveTo(0, 0); target.background.lineTo(300, 0); target.background.lineTo(300, 250); target.background.lineTo(0, 250); target.background.lineTo(0, 0); target.background.endFill(); target.mask = target.createEmptyMovieClip('mask', 101); target.mask.beginFill(0); target.mask.moveTo(0, 0); target.mask.lineTo(300, 0); target.mask.lineTo(300, 250); target.mask.lineTo(0, 250); target.mask.lineTo(0, 0); target.mask.endFill(); target.clip = target.createEmptyMovieClip('clip', 102); target.clip.ad = target.clip.createEmptyMovieClip('ad', 100); target.clip.setMask(target.mask); loadMovie(com.Newgrounds.NewgroundsAPI.ad_swf_url, target.clip.ad); com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.AD_ATTACHED, true, null, target); } else { com.Newgrounds.NewgroundsAPI.callListener(com.Newgrounds.NewgroundsAPI.events.AD_ATTACHED, false, new com.Newgrounds.NewgroundsAPIError('FLASH_ADS_NOT_APPROVED', 'Unable to render ad')); } }; v1.attachFlashAd = function (target) { System.security.allowDomain('http://server.cpmstar.com'); System.security.allowDomain('http://www.cpmstar.com'); System.security.allowDomain('https://server.cpmstar.com'); System.security.allowDomain('https://www.cpmstar.com'); System.security.allowInsecureDomain('http://server.cpmstar.com'); System.security.allowInsecureDomain('http://www.cpmstar.com'); System.security.allowInsecureDomain('https://server.cpmstar.com'); System.security.allowInsecureDomain('https://www.cpmstar.com'); com.Newgrounds.NewgroundsAPI.sendMessage('You may get a security sandbox violation from this ad. This is nothing to worry about!'); if (com.Newgrounds.NewgroundsAPI.resetAdTimer()) { if (com.Newgrounds.NewgroundsAPI.ad_url) { var v1 = new LoadVars(); v1.onData = function (data) { if (data) { com.Newgrounds.NewgroundsAPI.ad_swf_url = data; } else { com.Newgrounds.NewgroundsAPI.ad_swf_url = null; } com.Newgrounds.NewgroundsAPI.renderAd(target); }; if (com.Newgrounds.NewgroundsAPI.ad_url.indexOf('?') > -1) { v1.load(com.Newgrounds.NewgroundsAPI.ad_url + '&random=' + Math.random()); } else { v1.load(com.Newgrounds.NewgroundsAPI.ad_url + '?random=' + Math.random()); } } } else { com.Newgrounds.NewgroundsAPI.renderAd(target); } }; v1.resetAdTimer = function () { if (!com.Newgrounds.NewgroundsAPI.ad_url) { return false; } var v1 = new Date(); if (v1.getTime() >= com.Newgrounds.NewgroundsAPI.ad_reset) { com.Newgrounds.NewgroundsAPI.ad_reset = v1.getTime() + 300000; return true; } return false; }; v1.sendMessage = function (m, r) { var v1 = '[NewgroundsAPI] :: ' + m; if (r) { return v1; } else { trace(v1); } }; v1.echo = function (m) { if (com.Newgrounds.NewgroundsAPI.do_echo) { trace(m); } }; v1.do_echo = false; v1.GATEWAY_URL = 'http://www.ngads.com/gateway_v2.php'; v1.AD_TERMS_URL = 'http://www.newgrounds.com/wiki/flashads/terms/'; v1.COMMANDS_WIKI_URL = 'http://www.newgrounds.com/wiki/flashapi/commands/'; v1.ad_reset = 0; v1.save_file = null; v1.medals = null; v1.score_page_counts = new Object(); v1.compression_radix = '/g8236klvBQ#&|;Zb*7CEA59%s`Oue1wziFp$rDVY@TKxUPWytSaGHJ>dmoMR^<0~4qNLhc(I+fjn)X'; v1.compressor = new com.Newgrounds.BaseN(com.Newgrounds.NewgroundsAPI.compression_radix); v1.errors = com.Newgrounds.NewgroundsAPIError.init_codes(); v1.events = {'MOVIE_CONNECTED': 1, 'ADS_APPROVED': 2, 'AD_ATTACHED': 3, 'HOST_BLOCKED': 4, 'NEW_VERSION_AVAILABLE': 5, 'EVENT_LOGGED': 6, 'SCORE_POSTED': 7, 'SCORES_LOADED': 8, 'MEDAL_UNLOCKED': 9, 'MEDALS_LOADED': 10, 'FILE_PRIVS_LOADED': 11, 'FILE_SAVED': 12}; v1.listeners = com.Newgrounds.NewgroundsAPI.setDefaultListeners(); v1.periods = com.Newgrounds.NewgroundsAPI.getPeriodAliases(); v1.period_aliases = {'t': {'name': 'Today', 'alias': 'TODAY'}, 'p': {'name': 'Yesterday', 'alias': 'YESTERDAY'}, 'w': {'name': 'This Week', 'alias': 'THIS_WEEK'}, 'm': {'name': 'This Month', 'alias': 'THIS_MONTH'}, 'y': {'name': 'This Year', 'alias': 'THIS_YEAR'}, 'a': {'name': 'All-Time', 'alias': 'ALL_TIME'}}; ASSetPropFlags(com.Newgrounds.NewgroundsAPI.prototype, null, 1); } #endinitclip } movieClip 2984 __Packages.com.Newgrounds.NewgroundsAPISaveFile { #initclip if (!_global.com) { _global.com = new Object(); } if (!_global.com.Newgrounds) { _global.com.Newgrounds = new Object(); } if (!_global.com.Newgrounds.NewgroundsAPISaveFile) { var v1 = function (tracker_id, folder, filename) { this.tracker_id = tracker_id; this.folder = folder; this.filename = filename; this.contents = null; this.thumbnail = null; this.icon_url = null; this.thumbnail_url = null; }; com.Newgrounds.NewgroundsAPISaveFile = v1; var v2 = v1.prototype; v2.setDescription = function (description) { this.description = description; }; v2.setShared = function (share) { this.share = share; }; v2.setContents = function (contents) { this.contents = contents; }; v2.setThumbnail = function (thumb) { if (thumb) { this.thumbnail = thumb; } else { this.thumbnail = null; } }; v2.onError = function (msg) { trace('[NewgroundsAPISaveFile ERROR] :: ' + msg); }; v2.onCancel = function (msg) { trace('[NewgroundsAPISaveFile] :: ' + msg); }; v2.submit = function () { this.scan = null; com.Newgrounds.NewgroundsAPI.checkFilePrivs(this.folder, this.filename); }; v2.checkPrivs = function (p) { if (p.success) { if (p.can_write) { this.can_write = p.can_write; if (p.exists) { com.Newgrounds.NewgroundsAPI.getConfirmation('saveFile', com.Newgrounds.NewgroundsAPI.events.FILE_SAVED, 'File \'' + this.filename + '\' exists, overwrite?', this, 'startFile', 'cancelFile'); } else { this.startFile(); } } else { this.onError('This filename is owned by another user.'); } } else { this.onError('There was a problem looking up your file\'s details'); } }; v2.cancelFile = function () { this.onCancel('Overwrite was cancelled'); }; v2.startFile = function () { if (this.can_write) { if (this.thumbnail) { this.scanner = new com.Newgrounds.ImageScanner(this.thumbnail); this.scanner.setCallback(this, 'writeFile'); this.scanner.startScan(100, 100, true); } else { this.writeFile(); } } else { this.onError('You cannot write to filename "' + this.filename + '"'); } }; v2.writeFile = function (img) { trace('FINISHED'); com.Newgrounds.NewgroundsAPI.finishFileSave(this.folder, this.filename, this.description, this.share, com.Newgrounds.JSON.encode(this.contents), img); }; v2.can_write = false; v2.share = true; ASSetPropFlags(com.Newgrounds.NewgroundsAPISaveFile.prototype, null, 1); } #endinitclip } movieClip 2985 __Packages.com.Newgrounds.ImageScanner { #initclip if (!_global.com) { _global.com = new Object(); } if (!_global.com.Newgrounds) { _global.com.Newgrounds = new Object(); } if (!_global.com.Newgrounds.ImageScanner) { var v1 = function (the_source) { if (the_source) { this.image_source = the_source; } else { this.image_source = _root; } this.reset(); if (typeof this.image_source == 'movieclip') { if (this.image_source == _root) { this.source_width = Stage.width; this.source_height = Stage.height; } else { this.source_width = Math.floor(this.image_source._width); this.source_height = Math.floor(this.image_source._height); } this.sourceBitmap = new flash.display.BitmapData(this.source_width, this.source_height, false, 4294967295.0); this.sourceBitmap.draw(_root); } else { if (this.image_source.width) { this.source_width = this.image_source.width; this.source_height = this.image_source.height; this.sourceBitmap = this.image_source; } else { this.error('You can only use BitMaptData and MovieClip objects to create images'); } } }; com.Newgrounds.ImageScanner = v1; var v2 = v1.prototype; v2.setCallback = function (target, funct) { if (target && funct) { this.callback_target = target; this.callback_function = funct; } }; v2.reset = function () { this.callback_target = null; this.callback_function = null; this.debug.bad_pixels = 0; this.hash = '0123456789aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ<>?:;-_=+()!&'; var v3 = Math.pow(this.hash.length, 2); trace('MAX COLORS: ' + v3); var v2 = Math.floor(Math.pow(v3, 0.3333333333333333)) - 1; var v4 = Math.pow(v2, 3); this.cube = v2; this.basen = new com.Newgrounds.BaseN(this.hash); this.xpos = 0; this.ypos = 0; this.pixels = 0; this.busy = false; }; v2.startScan = function (w, h, s) { if (w) { this.image_width = w; } if (h) { this.image_height = h; } if (s != undefined) { this.crop = s; } var v7 = _root.getNextHighestDepth(); var v6 = _root.createEmptyMovieClip('API_image_container_' + v7, v7); var v5 = v6.createEmptyMovieClip('canvas', 100); v5.attachBitmap(this.sourceBitmap, 100); if (this.crop) { if (this.image_width / this.source_width > this.image_height / this.source_height) { this.canvas_width = this.image_width; this.canvas_height = Math.ceil(this.source_height * (this.image_width / this.source_width)); } else { this.canvas_height = this.image_height; this.canvas_width = Math.ceil(this.source_width * (this.image_height / this.source_height)); } } else { this.canvas_width = this.image_width; this.canvas_height = this.image_height; } v5._x = Math.round((this.image_width - this.canvas_width) / 2); v5._width = this.canvas_width; v5._height = this.canvas_height; this.resizedBitmap = new flash.display.BitmapData(this.image_width, this.image_height, false, 4294967295.0); this.resizedBitmap.draw(v6); v6.removeMovieClip(); this.copyBitmap = new flash.display.BitmapData(this.image_width, this.image_height, false, 4294967295.0); var v3 = '' + this.image_width; while (v3.length < 3) { v3 = '0' + v3; } var v4 = '' + this.image_height; while (v4.length < 3) { v4 = '0' + v4; } this.output = v3 + v4; this.draw_interval = setInterval(this, 'drawChunk', 10); this.busy = false; return this.resizedBitmap; }; v2.getBitmapData = function () { return this.copyBitmap; }; v2.getBytesTotal = function () { return this.image_width * this.image_height * 2; }; v2.getBytesScanned = function () { return this.pixels * 2; }; v2.drawChunk = function () { if (!this.busy) { this.busy = true; var v2 = 0; while (v2 < 250) { if (!this.nextPixel()) { clearInterval(this.draw_interval); this.callback_interval = setInterval(this, 'doCallback', 25); this.busy = true; break; } ++v2; } this.busy = false; } }; v2.doCallback = function () { this.busy = false; clearInterval(this.callback_interval); if (this.callback_target and this.callback_function) { this.callback_target[this.callback_function](this.output); } else { this.onScanComplete(this.output); } }; v2.onScanComplete = function (packet) { this.sendMessage('packet size: ' + this.output.length + ' bytes', 'onScanComplete'); }; v2.nextPixel = function () { var v15 = this.xpos; var v14 = this.ypos; var v7 = this.resizedBitmap.getPixel(v15, v14); var v17 = v7 >> 16 & 255; var v20 = v7 >> 8 & 255; var v16 = v7 >> 0 & 255; var v11 = Math.round(((v17 + 1) / 256) * this.cube); var v10 = Math.round(((v20 + 1) / 256) * this.cube); var v13 = Math.round(((v16 + 1) / 256) * this.cube); var v12 = v11 * (this.cube + 1) * (this.cube + 1) + v10 * (this.cube + 1) + v13; var v6 = this.basen.encode(v12, 2); this.output += v6; if (v6.length != 2) { trace('bad pixel ' + v6); } var v5 = this.basen.decode(v6); var v18 = v5; var v8 = v5 % (this.cube + 1); v5 = (v5 - v8) / (this.cube + 1); var v9 = v5 % (this.cube + 1); var v19 = (v5 - v9) / (this.cube + 1); if (v13 != v8 and v10 != v9 and v11 != v10) { ++this.debug.bad_pixels; trace('BAD PIXEL ' + this.debug.bad_pixels + ') ' + v12 + ' != ' + v18 + ' ' + v6); trace(this.basen.debug.lastencode); } var v2 = (Math.round((v19 / this.cube) * 255)).toString(16); var v4 = (Math.round((v9 / this.cube) * 255)).toString(16); var v3 = (Math.round((v8 / this.cube) * 255)).toString(16); while (v2.length < 2) { v2 = '0' + v2; } while (v4.length < 2) { v4 = '0' + v4; } while (v3.length < 2) { v3 = '0' + v3; } this.copyBitmap.setPixel(v15, v14, Number('0x' + v2 + v4 + v3)); ++this.pixels; if (this.pixels >= this.image_width * this.image_height) { return false; } ++this.xpos; if (this.xpos >= this.image_width) { this.xpos = 0; ++this.ypos; } return true; }; v2.error = function (e, f) { this.sendMessage(e, f, 'ERROR'); }; v2.sendMessage = function (msg, func, type) { var v1 = 'ImageScanner'; if (func) { v1 += '.' + func + '()'; } if (type) { v1 = type + ' in ' + v1; } v1 += ' :: ' + msg; trace(v1); }; v2.image_width = 100; v2.image_height = 100; v2.crop = true; v2.debug = new Object(); ASSetPropFlags(com.Newgrounds.ImageScanner.prototype, null, 1); } #endinitclip } movieClip 2986 __Packages.com.Newgrounds.JSON { #initclip if (!_global.com) { _global.com = new Object(); } if (!_global.com.Newgrounds) { _global.com.Newgrounds = new Object(); } if (!_global.com.Newgrounds.JSON) { var v1 = function () {}; com.Newgrounds.JSON = v1; var v2 = v1.prototype; v1.encode = function (arg, noquotes) { var v3; var v2; var v6; var v1 = ''; var v4; if (arg.isSServerVar()) { var v8 = 'sservervariable'; } else { var v8 = typeof arg; } switch (v8) { return 'null'; case 'sservervariable': return '?' + arg.getEncodedValue(); break; case 'object': if (arg) { if (arg instanceof Array) { v2 = 0; while (v2 < arg.length) { v4 = com.Newgrounds.JSON.encode(arg[v2]); if (v1) { v1 += ','; } v1 += v4; ++v2; } return '[' + v1 + ']'; } else { if (typeof arg.toString != 'undefined') { for (v2 in arg) { v4 = arg[v2]; if (typeof v4 != 'undefined' && typeof v4 != 'function') { v4 = com.Newgrounds.JSON.encode(v4); if (v1) { v1 += ','; } v1 += com.Newgrounds.JSON.encode(v2) + ':' + v4; } } return '{' + v1 + '}'; } } } return 'null'; case 'number': return isFinite(arg) ? String(arg) : 'null'; case 'string': v6 = arg.length; if (noquotes) { var v7 = ''; } else { var v7 = '"'; } v1 = v7; v2 = 0; while (v2 < v6) { v3 = arg.charAt(v2); if (v3 >= ' ') { if (v3 == '\\' || v3 == '"') { v1 += '\\'; } v1 += v3; } else { switch (v3) { case '\b': v1 += '\\b'; break; case '\f': v1 += '\\f'; break; case '\n': v1 += '\\n'; break; case '\r': v1 += '\\r'; break; case '\t': v1 += '\\t'; break; default: v3 = v3.charCodeAt(); v1 += '\\u00' + (Math.floor(v3 / 16)).toString(16) + (v3 % 16).toString(16); } } v2 += 1; } return v1 + v7; case 'boolean': return String(arg); default: return 'null'; } }; v1.decode = function (text) { var at = 0; var ch = ' '; var _value; var _error = function (m) { throw {'name': 'JSONError', 'message': m, 'at': at - 1, 'text': text}; }; var _next = function () { ch = text.charAt(at); at += 1; return ch; }; var _white = function () { while (ch) { if (ch <= ' ') { _next(); } else { if (ch == '/') { switch (_next()) { case '/': for (;;) { if (!(_next() && ch != '\n' && ch != '\r')) break; } break; case '*': _next(); for (;;) { if (ch) { if (ch == '*') { if (_next() == '/') { _next(); break; } } else { _next(); } continue; } _error('Unterminated comment'); } break; default: _error('Syntax error'); } } else { break; } } } }; var _string = function () { var v4; var v1 = ''; var v3; var v2; var v5 = false; if (ch == '"') { while (_next()) { if (ch == '"') { _next(); return v1; } else { if (ch == '\\') { switch (_next()) { case 'b': v1 += '\b'; break; case 'f': v1 += '\f'; break; case 'n': v1 += '\n'; break; case 'r': v1 += '\r'; break; case 't': v1 += '\t'; break; case 'u': v2 = 0; v4 = 0; while (v4 < 4) { v3 = parseInt(_next(), 16); if (!isFinite(v3)) { v5 = true; break; } v2 = v2 * 16 + v3; v4 += 1; } if (v5) { v5 = false; } else { v1 += String.fromCharCode(v2); break; default: v1 += ch; } } } else { v1 += ch; } } } } _error('Bad string'); }; var _array = function () { var v1 = []; if (ch == '[') { _next(); _white(); if (ch == ']') { _next(); return v1; } while (ch) { v1.push(_value()); _white(); if (ch == ']') { _next(); return v1; } else { if (ch != ',') { break; } } _next(); _white(); } } _error('Bad array'); }; var _object = function () { var v2; var v1 = {}; if (ch == '{') { _next(); _white(); if (ch == '}') { _next(); return v1; } while (ch) { v2 = _string(); _white(); if (ch != ':') { break; } _next(); v1[v2] = _value(); _white(); if (ch == '}') { _next(); return v1; } else { if (ch != ',') { break; } } _next(); _white(); } } _error('Bad object'); }; var _number = function () { var v1 = ''; var v2; if (ch == '-') { v1 = '-'; _next(); } for (;;) { if (!(ch >= '0' && ch <= '9')) break; v1 += ch; _next(); } if (ch == '.') { v1 += '.'; for (;;) { if (!(_next() && ch >= '0' && ch <= '9')) break; v1 += ch; } } v2 = 1 * v1; if (!isFinite(v2)) { _error('Bad number'); } else { return v2; } }; var _word = function () { switch (ch) { case 't': if (_next() == 'r' && _next() == 'u' && _next() == 'e') { _next(); return true; } break; case 'f': if (_next() == 'a' && _next() == 'l' && _next() == 's' && _next() == 'e') { _next(); return false; } break; case 'n': if (_next() == 'u' && _next() == 'l' && _next() == 'l') { _next(); return null; } } _error('Syntax error'); }; _value = function () { _white(); switch (ch) { case '{': return _object(); case '[': return _array(); case '"': return _string(); case '-': return _number(); } return (ch >= '0' && ch <= '9') ? _number() : _word(); }; return _value(); }; ASSetPropFlags(com.Newgrounds.JSON.prototype, null, 1); } #endinitclip } movieClip 2987 __Packages.com.Newgrounds.MD5 { #initclip if (!_global.com) { _global.com = new Object(); } if (!_global.com.Newgrounds) { _global.com.Newgrounds = new Object(); } if (!_global.com.Newgrounds.MD5) { var v1 = function () {}; com.Newgrounds.MD5 = v1; var v2 = v1.prototype; v1.calculate = function (src) { return com.Newgrounds.MD5.hex_md5(src); }; v1.hex_md5 = function (src) { return com.Newgrounds.MD5.binl2hex(com.Newgrounds.MD5.core_md5(com.Newgrounds.MD5.str2binl(src), src.length * 8)); }; v1.core_md5 = function (x, len) { x[len >> 5] |= 128 << len % 32; x[(len + 64 >>> 9 << 4) + 14] = len; var v4 = 1732584193; var v3 = -271733879; var v2 = -1732584194; var v1 = 271733878; var v5 = 0; while (v5 < x.length) { var v10 = v4; var v9 = v3; var v8 = v2; var v7 = v1; v4 = com.Newgrounds.MD5.md5_ff(v4, v3, v2, v1, x[v5 + 0], 7, -680876936); v1 = com.Newgrounds.MD5.md5_ff(v1, v4, v3, v2, x[v5 + 1], 12, -389564586); v2 = com.Newgrounds.MD5.md5_ff(v2, v1, v4, v3, x[v5 + 2], 17, 606105819); v3 = com.Newgrounds.MD5.md5_ff(v3, v2, v1, v4, x[v5 + 3], 22, -1044525330); v4 = com.Newgrounds.MD5.md5_ff(v4, v3, v2, v1, x[v5 + 4], 7, -176418897); v1 = com.Newgrounds.MD5.md5_ff(v1, v4, v3, v2, x[v5 + 5], 12, 1200080426); v2 = com.Newgrounds.MD5.md5_ff(v2, v1, v4, v3, x[v5 + 6], 17, -1473231341); v3 = com.Newgrounds.MD5.md5_ff(v3, v2, v1, v4, x[v5 + 7], 22, -45705983); v4 = com.Newgrounds.MD5.md5_ff(v4, v3, v2, v1, x[v5 + 8], 7, 1770035416); v1 = com.Newgrounds.MD5.md5_ff(v1, v4, v3, v2, x[v5 + 9], 12, -1958414417); v2 = com.Newgrounds.MD5.md5_ff(v2, v1, v4, v3, x[v5 + 10], 17, -42063); v3 = com.Newgrounds.MD5.md5_ff(v3, v2, v1, v4, x[v5 + 11], 22, -1990404162); v4 = com.Newgrounds.MD5.md5_ff(v4, v3, v2, v1, x[v5 + 12], 7, 1804603682); v1 = com.Newgrounds.MD5.md5_ff(v1, v4, v3, v2, x[v5 + 13], 12, -40341101); v2 = com.Newgrounds.MD5.md5_ff(v2, v1, v4, v3, x[v5 + 14], 17, -1502002290); v3 = com.Newgrounds.MD5.md5_ff(v3, v2, v1, v4, x[v5 + 15], 22, 1236535329); v4 = com.Newgrounds.MD5.md5_gg(v4, v3, v2, v1, x[v5 + 1], 5, -165796510); v1 = com.Newgrounds.MD5.md5_gg(v1, v4, v3, v2, x[v5 + 6], 9, -1069501632); v2 = com.Newgrounds.MD5.md5_gg(v2, v1, v4, v3, x[v5 + 11], 14, 643717713); v3 = com.Newgrounds.MD5.md5_gg(v3, v2, v1, v4, x[v5 + 0], 20, -373897302); v4 = com.Newgrounds.MD5.md5_gg(v4, v3, v2, v1, x[v5 + 5], 5, -701558691); v1 = com.Newgrounds.MD5.md5_gg(v1, v4, v3, v2, x[v5 + 10], 9, 38016083); v2 = com.Newgrounds.MD5.md5_gg(v2, v1, v4, v3, x[v5 + 15], 14, -660478335); v3 = com.Newgrounds.MD5.md5_gg(v3, v2, v1, v4, x[v5 + 4], 20, -405537848); v4 = com.Newgrounds.MD5.md5_gg(v4, v3, v2, v1, x[v5 + 9], 5, 568446438); v1 = com.Newgrounds.MD5.md5_gg(v1, v4, v3, v2, x[v5 + 14], 9, -1019803690); v2 = com.Newgrounds.MD5.md5_gg(v2, v1, v4, v3, x[v5 + 3], 14, -187363961); v3 = com.Newgrounds.MD5.md5_gg(v3, v2, v1, v4, x[v5 + 8], 20, 1163531501); v4 = com.Newgrounds.MD5.md5_gg(v4, v3, v2, v1, x[v5 + 13], 5, -1444681467); v1 = com.Newgrounds.MD5.md5_gg(v1, v4, v3, v2, x[v5 + 2], 9, -51403784); v2 = com.Newgrounds.MD5.md5_gg(v2, v1, v4, v3, x[v5 + 7], 14, 1735328473); v3 = com.Newgrounds.MD5.md5_gg(v3, v2, v1, v4, x[v5 + 12], 20, -1926607734); v4 = com.Newgrounds.MD5.md5_hh(v4, v3, v2, v1, x[v5 + 5], 4, -378558); v1 = com.Newgrounds.MD5.md5_hh(v1, v4, v3, v2, x[v5 + 8], 11, -2022574463); v2 = com.Newgrounds.MD5.md5_hh(v2, v1, v4, v3, x[v5 + 11], 16, 1839030562); v3 = com.Newgrounds.MD5.md5_hh(v3, v2, v1, v4, x[v5 + 14], 23, -35309556); v4 = com.Newgrounds.MD5.md5_hh(v4, v3, v2, v1, x[v5 + 1], 4, -1530992060); v1 = com.Newgrounds.MD5.md5_hh(v1, v4, v3, v2, x[v5 + 4], 11, 1272893353); v2 = com.Newgrounds.MD5.md5_hh(v2, v1, v4, v3, x[v5 + 7], 16, -155497632); v3 = com.Newgrounds.MD5.md5_hh(v3, v2, v1, v4, x[v5 + 10], 23, -1094730640); v4 = com.Newgrounds.MD5.md5_hh(v4, v3, v2, v1, x[v5 + 13], 4, 681279174); v1 = com.Newgrounds.MD5.md5_hh(v1, v4, v3, v2, x[v5 + 0], 11, -358537222); v2 = com.Newgrounds.MD5.md5_hh(v2, v1, v4, v3, x[v5 + 3], 16, -722521979); v3 = com.Newgrounds.MD5.md5_hh(v3, v2, v1, v4, x[v5 + 6], 23, 76029189); v4 = com.Newgrounds.MD5.md5_hh(v4, v3, v2, v1, x[v5 + 9], 4, -640364487); v1 = com.Newgrounds.MD5.md5_hh(v1, v4, v3, v2, x[v5 + 12], 11, -421815835); v2 = com.Newgrounds.MD5.md5_hh(v2, v1, v4, v3, x[v5 + 15], 16, 530742520); v3 = com.Newgrounds.MD5.md5_hh(v3, v2, v1, v4, x[v5 + 2], 23, -995338651); v4 = com.Newgrounds.MD5.md5_ii(v4, v3, v2, v1, x[v5 + 0], 6, -198630844); v1 = com.Newgrounds.MD5.md5_ii(v1, v4, v3, v2, x[v5 + 7], 10, 1126891415); v2 = com.Newgrounds.MD5.md5_ii(v2, v1, v4, v3, x[v5 + 14], 15, -1416354905); v3 = com.Newgrounds.MD5.md5_ii(v3, v2, v1, v4, x[v5 + 5], 21, -57434055); v4 = com.Newgrounds.MD5.md5_ii(v4, v3, v2, v1, x[v5 + 12], 6, 1700485571); v1 = com.Newgrounds.MD5.md5_ii(v1, v4, v3, v2, x[v5 + 3], 10, -1894986606); v2 = com.Newgrounds.MD5.md5_ii(v2, v1, v4, v3, x[v5 + 10], 15, -1051523); v3 = com.Newgrounds.MD5.md5_ii(v3, v2, v1, v4, x[v5 + 1], 21, -2054922799); v4 = com.Newgrounds.MD5.md5_ii(v4, v3, v2, v1, x[v5 + 8], 6, 1873313359); v1 = com.Newgrounds.MD5.md5_ii(v1, v4, v3, v2, x[v5 + 15], 10, -30611744); v2 = com.Newgrounds.MD5.md5_ii(v2, v1, v4, v3, x[v5 + 6], 15, -1560198380); v3 = com.Newgrounds.MD5.md5_ii(v3, v2, v1, v4, x[v5 + 13], 21, 1309151649); v4 = com.Newgrounds.MD5.md5_ii(v4, v3, v2, v1, x[v5 + 4], 6, -145523070); v1 = com.Newgrounds.MD5.md5_ii(v1, v4, v3, v2, x[v5 + 11], 10, -1120210379); v2 = com.Newgrounds.MD5.md5_ii(v2, v1, v4, v3, x[v5 + 2], 15, 718787259); v3 = com.Newgrounds.MD5.md5_ii(v3, v2, v1, v4, x[v5 + 9], 21, -343485551); v4 = com.Newgrounds.MD5.safe_add(v4, v10); v3 = com.Newgrounds.MD5.safe_add(v3, v9); v2 = com.Newgrounds.MD5.safe_add(v2, v8); v1 = com.Newgrounds.MD5.safe_add(v1, v7); v5 += 16; } return new Array(v4, v3, v2, v1); }; v1.md5_cmn = function (q, a, b, x, s, t) { return com.Newgrounds.MD5.safe_add(com.Newgrounds.MD5.bit_rol(com.Newgrounds.MD5.safe_add(com.Newgrounds.MD5.safe_add(a, q), com.Newgrounds.MD5.safe_add(x, t)), s), b); }; v1.md5_ff = function (a, b, c, d, x, s, t) { return com.Newgrounds.MD5.md5_cmn(b & c | ~b & d, a, b, x, s, t); }; v1.md5_gg = function (a, b, c, d, x, s, t) { return com.Newgrounds.MD5.md5_cmn(b & d | c & ~d, a, b, x, s, t); }; v1.md5_hh = function (a, b, c, d, x, s, t) { return com.Newgrounds.MD5.md5_cmn(b ^ c ^ d, a, b, x, s, t); }; v1.md5_ii = function (a, b, c, d, x, s, t) { return com.Newgrounds.MD5.md5_cmn(c ^ (b | ~d), a, b, x, s, t); }; v1.bit_rol = function (num, cnt) { return num << cnt | num >>> 32 - cnt; }; v1.safe_add = function (x, y) { var v1 = (x & 65535) + (y & 65535); var v2 = (x >> 16) + (y >> 16) + (v1 >> 16); return v2 << 16 | v1 & 65535; }; v1.str2binl = function (str) { var v3 = new Array(); var v4 = 255; var v1 = 0; while (v1 < str.length * 8) { v3[v1 >> 5] |= (str.charCodeAt(v1 / 8) & v4) << v1 % 32; v1 += 8; } return v3; }; v1.binl2hex = function (binarray) { var v4 = new String(''); var v3 = new String('0123456789abcdef'); var v1 = 0; while (v1 < binarray.length * 4) { v4 += v3.charAt(binarray[v1 >> 2] >> (v1 % 4) * 8 + 4 & 15) + v3.charAt(binarray[v1 >> 2] >> (v1 % 4) * 8 & 15); ++v1; } return v4; }; ASSetPropFlags(com.Newgrounds.MD5.prototype, null, 1); } #endinitclip } movieClip 2988 __Packages.com.Newgrounds.RC4 { #initclip if (!_global.com) { _global.com = new Object(); } if (!_global.com.Newgrounds) { _global.com.Newgrounds = new Object(); } if (!_global.com.Newgrounds.RC4) { var v1 = function () {}; com.Newgrounds.RC4 = v1; var v2 = v1.prototype; v1.encrypt = function (src, key) { var v3 = com.Newgrounds.RC4.strToChars(src); var v1 = com.Newgrounds.RC4.strToChars(key); var v2 = com.Newgrounds.RC4.calculate(v3, v1); return com.Newgrounds.RC4.charsToHex(v2); }; v1.encryptbin = function (src, key) { var v3 = com.Newgrounds.RC4.strToChars(src); var v1 = com.Newgrounds.RC4.strToChars(key); var v2 = com.Newgrounds.RC4.calculate(v3, v1); return v2; }; v1.decrypt = function (src, key) { var v3 = com.Newgrounds.RC4.hexToChars(src); var v1 = com.Newgrounds.RC4.strToChars(key); var v2 = com.Newgrounds.RC4.calculate(v3, v1); return com.Newgrounds.RC4.charsToStr(v2); }; v1.initialize = function (pwd) { var v2 = 0; var v3; var v4 = pwd.length; var v1 = 0; while (v1 <= 255) { com.Newgrounds.RC4.mykey[v1] = pwd[v1 % v4]; com.Newgrounds.RC4.sbox[v1] = v1; ++v1; } v1 = 0; while (v1 <= 255) { v2 = (v2 + com.Newgrounds.RC4.sbox[v1] + com.Newgrounds.RC4.mykey[v1]) % 256; v3 = com.Newgrounds.RC4.sbox[v1]; com.Newgrounds.RC4.sbox[v1] = com.Newgrounds.RC4.sbox[v2]; com.Newgrounds.RC4.sbox[v2] = v3; ++v1; } }; v1.calculate = function (plaintxt, psw) { com.Newgrounds.RC4.initialize(psw); var v1 = 0; var v2 = 0; var v9 = new Array(); var v7; var v5; var v6; var v3 = 0; while (v3 < plaintxt.length) { v1 = (v1 + 1) % 256; v2 = (v2 + com.Newgrounds.RC4.sbox[v1]) % 256; v5 = com.Newgrounds.RC4.sbox[v1]; com.Newgrounds.RC4.sbox[v1] = com.Newgrounds.RC4.sbox[v2]; com.Newgrounds.RC4.sbox[v2] = v5; var v4 = (com.Newgrounds.RC4.sbox[v1] + com.Newgrounds.RC4.sbox[v2]) % 256; v7 = com.Newgrounds.RC4.sbox[v4]; v6 = plaintxt[v3] ^ v7; v9.push(v6); ++v3; } return v9; }; v1.charsToHex = function (chars) { var v4 = new String(''); var v3 = new Array('0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f'); var v1 = 0; while (v1 < chars.length) { v4 += v3[chars[v1] >> 4] + v3[chars[v1] & 15]; ++v1; } return v4; }; v1.hexToChars = function (hex) { var v3 = new Array(); var v1 = (hex.substr(0, 2) == '0x') ? 2 : 0; while (v1 < hex.length) { v3.push(parseInt(hex.substr(v1, 2), 16)); v1 += 2; } return v3; }; v1.charsToStr = function (chars) { var v3 = new String(''); var v1 = 0; while (v1 < chars.length) { v3 += String.fromCharCode(chars[v1]); ++v1; } return v3; }; v1.strToChars = function (str) { var v3 = new Array(); var v1 = 0; while (v1 < str.length) { v3.push(str.charCodeAt(v1)); ++v1; } return v3; }; v1.sbox = new Array(255); v1.mykey = new Array(255); ASSetPropFlags(com.Newgrounds.RC4.prototype, null, 1); } #endinitclip } movieClip 2989 __Packages.mx.transitions.OnEnterFrameBeacon { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.transitions) { _global.mx.transitions = new Object(); } if (!_global.mx.transitions.OnEnterFrameBeacon) { var v1 = function () {}; mx.transitions.OnEnterFrameBeacon = v1; var v2 = v1.prototype; v1.init = function () { var v4 = _global.MovieClip; if (!_root.__OnEnterFrameBeacon) { mx.transitions.BroadcasterMX.initialize(v4); var v3 = _root.createEmptyMovieClip('__OnEnterFrameBeacon', 9876); v3.onEnterFrame = function () { _global.MovieClip.broadcastMessage('onEnterFrame'); }; } }; v1.version = '1.1.0.52'; ASSetPropFlags(mx.transitions.OnEnterFrameBeacon.prototype, null, 1); } #endinitclip } movieClip 2990 __Packages.mx.transitions.BroadcasterMX { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.transitions) { _global.mx.transitions = new Object(); } if (!_global.mx.transitions.BroadcasterMX) { var v1 = function () {}; mx.transitions.BroadcasterMX = v1; var v2 = v1.prototype; v1.initialize = function (o, dontCreateArray) { if (o.broadcastMessage != undefined) { delete o.broadcastMessage; } o.addListener = mx.transitions.BroadcasterMX.prototype.addListener; o.removeListener = mx.transitions.BroadcasterMX.prototype.removeListener; if (!dontCreateArray) { o._listeners = new Array(); } }; v2.addListener = function (o) { this.removeListener(o); if (this.broadcastMessage == undefined) { this.broadcastMessage = mx.transitions.BroadcasterMX.prototype.broadcastMessage; } return this._listeners.push(o); }; v2.removeListener = function (o) { var v2 = this._listeners; var v3 = v2.length; while (v3--) { if (v2[v3] == o) { v2.splice(v3, 1); if (!v2.length) { this.broadcastMessage = undefined; } return true; } } return false; }; v2.broadcastMessage = function () { var v5 = String(arguments.shift()); var v4 = this._listeners.concat(); var v6 = v4.length; var v3 = 0; while (v3 < v6) { v4[v3][v5].apply(v4[v3], arguments); ++v3; } }; v1.version = '1.1.0.52'; ASSetPropFlags(mx.transitions.BroadcasterMX.prototype, null, 1); } #endinitclip } movieClip 2991 __Packages.mx.transitions.Tween { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.transitions) { _global.mx.transitions = new Object(); } if (!_global.mx.transitions.Tween) { var v1 = function (obj, prop, func, begin, finish, duration, useSeconds) { mx.transitions.OnEnterFrameBeacon.init(); if (!arguments.length) { return undefined; } this.obj = obj; this.prop = prop; this.begin = begin; this.__set__position(begin); this.__set__duration(duration); this.useSeconds = useSeconds; if (func) { this.func = func; } this.__set__finish(finish); this._listeners = []; this.addListener(this); this.start(); }; mx.transitions.Tween = v1; var v2 = v1.prototype; v2.__set__time = function (t) { this.prevTime = this._time; if (t > this.__get__duration()) { if (this.looping) { this.rewind(t - this._duration); this.update(); this.broadcastMessage('onMotionLooped', this); } else { if (this.useSeconds) { this._time = this._duration; this.update(); } this.stop(); this.broadcastMessage('onMotionFinished', this); } } else { if (t < 0) { this.rewind(); this.update(); } else { this._time = t; this.update(); } } return this.__get__time(); }; v2.__get__time = function () { return this._time; }; v2.__set__duration = function (d) { this._duration = (d == null || d <= 0) ? _global.Infinity : d; return this.__get__duration(); }; v2.__get__duration = function () { return this._duration; }; v2.__set__FPS = function (fps) { var v2 = this.isPlaying; this.stopEnterFrame(); this._fps = fps; if (v2) { this.startEnterFrame(); } return this.__get__FPS(); }; v2.__get__FPS = function () { return this._fps; }; v2.__set__position = function (p) { this.setPosition(p); return this.__get__position(); }; v2.setPosition = function (p) { this.prevPos = this._pos; this._pos = p; this.obj[this.prop] = this._pos; this.broadcastMessage('onMotionChanged', this, this._pos); updateAfterEvent(); }; v2.__get__position = function () { return this.getPosition(); }; v2.getPosition = function (t) { if (t == undefined) { t = this._time; } return this.func(t, this.begin, this.change, this._duration); }; v2.__set__finish = function (f) { this.change = f - this.begin; return this.__get__finish(); }; v2.__get__finish = function () { return this.begin + this.change; }; v2.continueTo = function (finish, duration) { this.begin = this.position; this.__set__finish(finish); if (duration != undefined) { this.__set__duration(duration); } this.start(); }; v2.yoyo = function () { this.continueTo(this.begin, this.__get__time()); }; v2.startEnterFrame = function () { if (this._fps == undefined) { _global.MovieClip.addListener(this); } else { this._intervalID = setInterval(this, 'onEnterFrame', 1000 / this._fps); } this.isPlaying = true; }; v2.stopEnterFrame = function () { if (this._fps == undefined) { _global.MovieClip.removeListener(this); } else { clearInterval(this._intervalID); } this.isPlaying = false; }; v2.start = function () { this.rewind(); this.startEnterFrame(); this.broadcastMessage('onMotionStarted', this); }; v2.stop = function () { this.stopEnterFrame(); this.broadcastMessage('onMotionStopped', this); }; v2.resume = function () { this.fixTime(); this.startEnterFrame(); this.broadcastMessage('onMotionResumed', this); }; v2.rewind = function (t) { this._time = (t == undefined) ? 0 : t; this.fixTime(); this.update(); }; v2.fforward = function () { this.__set__time(this._duration); this.fixTime(); }; v2.nextFrame = function () { if (this.useSeconds) { this.__set__time((getTimer() - this._startTime) / 1000); } else { this.__set__time(this._time + 1); } }; v2.onEnterFrame = function () { this.nextFrame(); }; v2.prevFrame = function () { if (!this.useSeconds) { this.__set__time(this._time - 1); } }; v2.toString = function () { return '[Tween]'; }; v2.fixTime = function () { if (this.useSeconds) { this._startTime = getTimer() - this._time * 1000; } }; v2.update = function () { this.__set__position(this.getPosition(this._time)); }; v1.version = '1.1.0.52'; v1.__initBeacon = mx.transitions.OnEnterFrameBeacon.init(); v1.__initBroadcaster = mx.transitions.BroadcasterMX.initialize(mx.transitions.Tween.prototype, true); v2.func = function (t, b, c, d) { return c * t / d + b; }; v2.addProperty('FPS', v2.__get__FPS, v2.__set__FPS); v2.addProperty('duration', v2.__get__duration, v2.__set__duration); v2.addProperty('finish', v2.__get__finish, v2.__set__finish); v2.addProperty('position', v2.__get__position, v2.__set__position); v2.addProperty('time', v2.__get__time, v2.__set__time); ASSetPropFlags(mx.transitions.Tween.prototype, null, 1); } #endinitclip } movieClip 2992 __Packages.Delay { #initclip if (!_global.Delay) { var v1 = function (context, fn, delay) { this.m_fn = fn; this.m_param = new Array(); var v3 = 3; while (v3 < arguments.length) { this.m_param.push(arguments[v3]); ++v3; } this.m_context = context; this.m_delay = delay; this.m_started = getTimer(); this.m_timerId = setInterval(mx.utils.Delegate.create(this, this.onEvent), delay); }; _global.Delay = v1; var v2 = v1.prototype; v2.onEvent = function () { if (getTimer() >= this.m_delay + this.m_started) { clearInterval(this.m_timerId); this.m_fn.apply(this.m_context, this.m_param); this.m_fn = undefined; this.m_param = undefined; } }; v1.oneShot = function (context, fn, delay) { var v3 = new Delay(context, fn, delay); v3.m_param = new Array(); var v2 = 3; while (v2 < arguments.length) { v3.m_param.push(arguments[v2]); ++v2; } }; ASSetPropFlags(_global.Delay.prototype, null, 1); } #endinitclip } movieClip 2993 __Packages.mx.utils.Delegate { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.utils) { _global.mx.utils = new Object(); } if (!_global.mx.utils.Delegate) { var v1 = function (f) { super(); this.func = f; }; mx.utils.Delegate = v1; mx.utils.Delegate extends Object; var v2 = v1.prototype; v1.create = function (obj, func) { var v2 = function () { var v2 = arguments.callee.target; var v3 = arguments.callee.func; return v3.apply(v2, arguments); }; v2.target = obj; v2.func = func; return v2; }; v2.createDelegate = function (obj) { return mx.utils.Delegate.create(obj, this.func); }; ASSetPropFlags(mx.utils.Delegate.prototype, null, 1); } #endinitclip } movieClip 2994 __Packages.mx.transitions.easing.Regular { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.transitions) { _global.mx.transitions = new Object(); } if (!_global.mx.transitions.easing) { _global.mx.transitions.easing = new Object(); } if (!_global.mx.transitions.easing.Regular) { var v1 = function () {}; mx.transitions.easing.Regular = v1; var v2 = v1.prototype; v1.easeIn = function (t, b, c, d) { t /= d; return c * t * t + b; }; v1.easeOut = function (t, b, c, d) { t /= d; return -c * t * (t - 2) + b; }; v1.easeInOut = function (t, b, c, d) { t /= d / 2; if (t < 1) { return (c / 2) * t * t + b; } return (-c / 2) * (--t * (t - 2) - 1) + b; }; v1.version = '1.1.0.52'; ASSetPropFlags(mx.transitions.easing.Regular.prototype, null, 1); } #endinitclip } movieClip 2995 __Packages.mx.transitions.easing.None { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.transitions) { _global.mx.transitions = new Object(); } if (!_global.mx.transitions.easing) { _global.mx.transitions.easing = new Object(); } if (!_global.mx.transitions.easing.None) { var v1 = function () {}; mx.transitions.easing.None = v1; var v2 = v1.prototype; v1.easeNone = function (t, b, c, d) { return c * t / d + b; }; v1.easeIn = function (t, b, c, d) { return c * t / d + b; }; v1.easeOut = function (t, b, c, d) { return c * t / d + b; }; v1.easeInOut = function (t, b, c, d) { return c * t / d + b; }; v1.version = '1.1.0.52'; ASSetPropFlags(mx.transitions.easing.None.prototype, null, 1); } #endinitclip } movieClip 2996 __Packages.AnimDriver { #initclip if (!_global.AnimDriver) { var v1 = function () { super(); }; _global.AnimDriver = v1; _global.AnimDriver extends MovieClip; var v2 = v1.prototype; v2.initAnimDriver = function (p_fps) { this.fps = p_fps; this.pauseOffset = 0; }; v2.playAnim = function (p_frame, p_loop) { this.gotoAndStop(p_frame); this.loop = p_loop; this.startTime = getTimer(); this.onEnterFrame = mx.utils.Delegate.create(this, this.updateAnim); }; v2.disableAnim = function () { this.onEnterFrame = undefined; }; v2.jumpTo = function (p_frame) { this.stopAnim(); this.playAnim(p_frame); }; v2.pauseAnim = function () { this.pauseOffset = getTimer(); this.onEnterFrame = undefined; }; v2.stopAnim = function () { this.startTime = 1; this.onEnterFrame = undefined; }; v2.updateAnim = function () { var v3 = getTimer(); var v4 = (1 / this.fps) * 1000; var v2 = Math.round((v3 - this.startTime) / v4 + 1); if (v2 >= this._totalframes) { this.startTime = v3; v2 = this._totalframes; if (!this.loop) { this.stopAnim(); } } this.gotoAndStop(v2); }; ASSetPropFlags(_global.AnimDriver.prototype, null, 1); } #endinitclip } frame 2 { gotoAndPlay(11); } frame 84 { function fireFire() { new mx.transitions.Tween(mcKingLoader.fireLogoHolder, '_x', mx.transitions.easing.Regular.easeOut, mcKingLoader.fireLogoHolder._x, gameWidth / 2 - mcKingLoader.dragonHolder._width / 2 - 51, 1, true); mcKingLoader.fireLogoHolder.play(); } function showPlayBtn() { mcKingLoader.mcPlay._x = gameWidth / 2 - mcKingLoader.mcPlay._width / 2; mcKingLoader.mcPlay._y = mcKingLoader.fireLogoHolder._y + 210; new mx.transitions.Tween(mcKingLoader.mcPlay, '_alpha', mx.transitions.easing.None.easeNone, 0, 100, 0.5, true); mcKingLoader.mcPlay.onPress = btnOnPress; mcKingLoader.mcPlay.onRollOver = btnOnOver; mcKingLoader.mcPlay.onDragOut = btnOnOut; mcKingLoader.mcPlay.onRollOut = mcKingLoader.mcPlay.onDragOut; mcKingLoader.mcPlay.onRelease = mx.utils.Delegate.create(this, launchGame); Delay.oneShot(this, showGlimmer, 1000); } function showGlimmer() { bell.start(); mcKingLoader.mcGlim._x = mcKingLoader.fireLogoHolder_.x - mcKingLoader.mcGlim._width; mcKingLoader.mcGlim._y = mcKingLoader.fireLogoHolder._y + 112; var v2 = mcKingLoader.fireLogoHolder._x - mcKingLoader.mcGlim._width; var v3 = mcKingLoader.fireLogoHolder._x + mcKingLoader.fireLogoHolder._width - 80; var v1 = new mx.transitions.Tween(mcKingLoader.mcGlim, '_x', mx.transitions.easing.None.easeNone, v2, v3, 0.5, true); v1.onMotionFinished = glimmerDone; } function glimmerDone() { mcKingLoader.mcGlim._visible = false; } function btnOnOver() { var v2 = this; v2.gotoAndStop('over'); } function btnOnOut() { var v2 = this; v2.gotoAndStop('idle'); } function btnOnPress() { var v2 = this; v2.gotoAndStop('down'); } function launchGame() { _root.play(); } stop(); mcKingLoader.fireLogoHolder.stop(); mcKingLoader.dragonHolder.stop(); mcKingLoader._y = 0; mcKingLoader._x = 0; mcKingLoader.bg._width = gameWidth; mcKingLoader.bg._height = gameHeight; mcKingLoader.bg.onRelease = function () { if (!isHome) { openKingPage(LINK_TYPE_LOADER_MOVIE); } }; mcKingLoader.fireLogoHolder._x = gameWidth - mcKingLoader.fireLogoHolder._width - 90; mcKingLoader.fireLogoHolder._y = gameHeight / 2 - mcKingLoader.fireLogoHolder._height / 2 - 60; mcKingLoader.dragonHolder._x = gameWidth - mcKingLoader.dragonHolder._width; mcKingLoader.dragonHolder._y = gameHeight / 2 - mcKingLoader.dragonHolder._height / 2; mcKingLoader.mcPlay._alpha = 0; mcKingLoader.mcPlay.useHandCursor = true; var bell = new Sound(); bell.attachSound('sfxBell'); mcKingLoader.initAnimDriver(30, false); trace('StartAnim'); mcKingLoader.dragonHolder.play(); } movieClip 89 { frame 80 { _root.fireFire(); } frame 237 { stop(); } } movieClip 91 { frame 73 { stop(); _root.showPlayBtn(); } } movieClip 94 { } movieClip 96 { } movieClip 103 { frame 1 { stop(); } } movieClip 104 KingLoader { #initclip Object.registerClass('KingLoader', AnimDriver); #endinitclip } instance mouseOBJ of movieClip 79 { onClipEvent (load) { _visible = false; } onClipEvent (enterFrame) { this._x = _root._xmouse; this._y = _root._ymouse; } } frame 85 { track01Started = false; track02Started = false; track03Started = false; track04Started = false; _root.createEmptyMovieClip('musicMC', 1001); track01 = new Sound(musicMC); track01.attachSound('track01'); track02 = new Sound(musicMC); track02.attachSound('track02'); track03 = new Sound(musicMC); track03.attachSound('track03'); track04 = new Sound(musicMC); track04.attachSound('track04'); track01.setVolume(100); track02.setVolume(100); track03.setVolume(100); track04.setVolume(100); _root.stab1 = new Sound(this); _root.stab1.attachSound('stab1'); _root.stab2 = new Sound(this); _root.stab2.attachSound('stab2'); _root.stab3 = new Sound(this); _root.stab3.attachSound('stab3'); _root.burst1 = new Sound(this); _root.burst1.attachSound('burst1'); enemysKilled = 0; numOfEnemys = 0; redOrbCounter = 0; redOrbLevelCounter = 0; deathCounter = 0; boss1Defeated = false; boss2Defeated = false; award1Done = false; award2Done = false; award3Done = false; award4Done = false; award5Done = false; award6Done = false; award7Done = false; award8Done = false; award9Done = false; award10Done = false; award11Done = false; award12Done = false; award13Done = false; ConceptUnlocked1 = false; concept1Unlocked = false; concept2Unlocked = false; concept3Unlocked = false; concept4Unlocked = false; concept5Unlocked = false; concept6Unlocked = false; musicUnlocked1 = false; music1Unlocked = false; music2Unlocked = false; music3Unlocked = false; videoWatched1 = false; videoWatched2 = false; videoWatched3 = false; videoWatched4 = false; videoWatched5 = false; cutSceneMode = false; } instance mouseOBJ of movieClip 79 { onClipEvent (load) { _visible = false; } onClipEvent (enterFrame) { this._x = _root._xmouse; this._y = _root._ymouse; } } frame 86 { if (NewgroundsAPI.hasUserSession()) { var sharedobject_name = 'RedMoonlol10_ng'; } else { var sharedobject_name = 'RedMoonlol10'; } award1Done = _root.savefile.data.award1Done; award2Done = _root.savefile.data.award2Done; award3Done = _root.savefile.data.award3Done; award4Done = _root.savefile.data.award4Done; award5Done = _root.savefile.data.award5Done; award6Done = _root.savefile.data.award6Done; award7Done = _root.savefile.data.award7Done; award8Done = _root.savefile.data.award8Done; award9Done = _root.savefile.data.award9Done; award10Done = _root.savefile.data.award10Done; award11Done = _root.savefile.data.award11Done; award12Done = _root.savefile.data.award12Done; award13Done = _root.savefile.data.award13Done; ConceptUnlocked1 = _root.savelife.data.ConceptUnlocked1; concept1Unlocked = _root.savefile.data.concept1Unlocked; concept2Unlocked = _root.savefile.data.concept2Unlocked; concept3Unlocked = _root.savefile.data.concept3Unlocked; concept4Unlocked = _root.savefile.data.concept4Unlocked; concept5Unlocked = _root.savefile.data.concept5Unlocked; concept6Unlocked = _root.savefile.data.concept6Unlocked; musicUnlocked1 = _root.savefile.data.musicUnlocked1; music1Unlocked = _root.savefile.data.music1Unlocked; music2Unlocked = _root.savefile.data.music2Unlocked; music3Unlocked = _root.savefile.data.music3Unlocked; videoWatched1 = _root.savefile.data.videoWatched1; videoWatched2 = _root.savefile.data.videoWatched2; videoWatched3 = _root.savefile.data.videoWatched3; videoWatched4 = _root.savefile.data.videoWatched4; videoWatched5 = _root.savefile.data.videoWatched5; savefile.flush(); } frame 87 { track01.stop(); track02.stop(); track03.stop(); track04.start(0, 99); } movieClip 144 { frame 37 { stop(); } } instance mouseOBJ of movieClip 79 { onClipEvent (load) { _visible = false; } onClipEvent (enterFrame) { this._x = _root._xmouse; this._y = _root._ymouse; } } // unknown tag 88 length 63 frame 229 { levelNum = 1; instandKill = false; } movieClip 149 { frame 1 { stop(); } frame 75 { _root.gotoAndPlay('cutScene1'); } } movieClip 152 { frame 1 { stop(); } frame 8 { stop(); } frame 14 { gotoAndStop(1); } } movieClip 157 { } movieClip 158 { instance awardStatus of movieClip 157 { onClipEvent (load) { stop(); } } } // unknown tag 88 length 63 movieClip 166 { } movieClip 167 { frame 1 { stop(); } frame 2 { var savefile = SharedObject.getLocal('RedMoonlol10'); _root.savefile.data.award1Done = _root.award1Done; _root.savefile.data.award2Done = _root.award2Done; _root.savefile.data.award3Done = _root.award3Done; _root.savefile.data.award4Done = _root.award4Done; _root.savefile.data.award5Done = _root.award5Done; _root.savefile.data.award6Done = _root.award6Done; _root.savefile.data.award7Done = _root.award7Done; _root.savefile.data.award8Done = _root.award8Done; _root.savefile.data.award9Done = _root.award9Done; _root.savefile.data.award10Done = _root.award10Done; _root.savefile.data.award11Done = _root.award11Done; _root.savefile.data.award12Done = _root.award12Done; _root.savefile.data.award13Done = _root.award13Done; _root.savelife.data.ConceptUnlocked1 = _root.ConceptUnlocked1; _root.savefile.flush(); } frame 15 { this.awardName = awardUnlocked; } } movieClip 171 { } movieClip 184 { frame 1 { stop(); } } movieClip 185 { frame 1 { stop(); } instance of movieClip 152 { onClipEvent (rollOver) { if (this._currentframe < 15) { this.gotoAndPlay('over'); } } onClipEvent (rollOut) { if (this._currentframe < 15) { this.gotoAndPlay('out'); } } onClipEvent (press) { if (this._currentframe < 15) { this.gotoAndPlay('press'); } if (_parent._currentframe == 1) { _parent.play(); } else { if (_parent._currentframe == 22) { _parent.play(); } } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'mere 5'; } onClipEvent (enterFrame) { if (_root.award1Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.enemysKilled >= 5) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Mere 5'); _root.award1Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(1); if (_root.award1Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Killer 30'; } onClipEvent (enterFrame) { if (_root.award2Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.enemysKilled >= 30) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Killer 30'); _root.award2Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(2); if (_root.award2Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Slayer 80'; } onClipEvent (enterFrame) { if (_root.award3Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.enemysKilled >= 80) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Slayer 80'); _root.award3Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(3); if (_root.award3Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Halfway there'; } onClipEvent (enterFrame) { if (_root.award4Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.boss1Defeated) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Halfway There'); _root.award4Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(4); if (_root.award4Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Long live the King'; } onClipEvent (enterFrame) { if (_root.award5Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.boss2Defeated) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Long Live The King'); _root.award5Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(5); if (_root.award5Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Red Moon Deity'; } onClipEvent (enterFrame) { if (_root.award6Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.deathCounter == 0 && _root.hero.bound.hitTest(_root.finalGoal)) { if (_root.finalGoal._currentframe > 1) { if (_parent.notice._currentframe == 1) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Red Moon Deity'); _root.award6Done = true; } } } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(6); if (_root.award6Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Introduction'; } onClipEvent (enterFrame) { if (_root.award7Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.videoWatched1) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Introduction'); _root.award7Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(7); if (_root.award7Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Art Piece'; } onClipEvent (enterFrame) { if (_root.award8Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.ConceptUnlocked1) { _parent.notice.play(); _root.medal_popup.unlockMedal('Art Piece'); _parent.notice.awardUnlocked = this.awardName; _root.award8Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(8); if (_root.award8Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Art Collector'; } onClipEvent (enterFrame) { if (_root.award9Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.concept1Unlocked && _root.concept2Unlocked && _root.concept3Unlocked && _root.concept4Unlocked && _root.concept5Unlocked && _root.concept6Unlocked) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Art Collector'); _root.award9Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(9); if (_root.award9Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Sound guru'; } onClipEvent (enterFrame) { if (_root.award10Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.music1Unlocked && _root.music2Unlocked && _root.music3Unlocked) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Sound Guru'); _root.award10Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(10); if (_root.award10Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Orb hunter'; } onClipEvent (enterFrame) { if (_root.award11Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.redOrbCounter >= 131) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Orb Hunter'); _root.award11Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(11); if (_root.award11Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Sound of music'; } onClipEvent (enterFrame) { if (_root.award12Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.musicUnlocked1) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Sound of Music'); _root.award12Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(12); if (_root.award12Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance of movieClip 158 { onClipEvent (load) { this.awardName = 'Don\'t skip \'em'; } onClipEvent (enterFrame) { if (_root.award13Done) { this.awardStatus.play(); (new Color(this)).setRGB(16777215); } else { if (_root.videoWatched1 && _root.videoWatched2 && _root.videoWatched3 && _root.videoWatched4 && _root.videoWatched5) { _parent.notice.play(); _parent.notice.awardUnlocked = this.awardName; _root.medal_popup.unlockMedal('Don\'t Skip \'Em'); _root.award13Done = true; } } } onClipEvent (rollOver) { _parent.icone.gotoAndStop(13); if (_root.award13Done) { _parent.icone.Lock._visible = false; } else { _parent.icone.Lock._visible = true; } } } instance notice of movieClip 167 { onClipEvent (load) { var awardUnlocked = ''; } } frame 22 { stop(); } } movieClip 189 { frame 15 { stop(); } } movieClip 192 { } instance quality of movieClip 192 { onClipEvent (load) { if (_quality == 'LOW') { this.gotoAndStop(1); } else { if (_quality == 'MEDIUM') { this.gotoAndStop(2); } else { this.gotoAndStop(3); } } } onClipEvent (rollOver) { this.hili.gotoAndPlay(1); } onClipEvent (press) { if (this._currentframe == 1) { _quality = 'MEDIUM'; this.gotoAndStop(2); } else { if (this._currentframe == 2) { this.gotoAndStop(3); _quality = 'HIGH'; } else { if (this._currentframe == 3) { this.gotoAndStop(1); _quality = 'LOW'; } } } } } instance mouseOBJ of movieClip 79 { onClipEvent (load) { _visible = false; } onClipEvent (enterFrame) { this._x = _root._xmouse; this._y = _root._ymouse; } } movieClip 197 { frame 10 { stop(); } } movieClip 198 { frame 1 { stop(); } frame 2 { stop(); } } instance of movieClip 198 { onClipEvent (enterFrame) { if (this.hitTest(_root.mouseOBJ)) { this.gotoAndStop(2); } else { this.gotoAndStop(1); } } onClipEvent (press) { _root.openSignLink(); } } // unknown tag 88 length 67 // unknown tag 88 length 62 movieClip 204 { } // unknown tag 88 length 67 movieClip 210 { } movieClip 211 { frame 1 { function unlockMedal(m_name) { clearInterval(pop_delay); var v1 = com.Newgrounds.NewgroundsAPI.getMedals(); var v2 = null; for (i in v1) { if (v1[i].medal_name == m_name) { v2 = v1[i]; medal_name = v2.medal_name; medal_value = v2.medal_value + 'pts'; com.Newgrounds.NewgroundsAPI.unlockMedal(medal_name); pop_delay = setInterval(endDelay, 3000); _visible = true; gotoAndPlay(2); break; } } } function endDelay(params) { gotoAndPlay(10); clearInterval(pop_delay); } var pop_delay; var medal_name = '?????'; var medal_value = '???'; _visible = false; } frame 10 { var myBitmapData = flash.display.BitmapData.loadBitmap(medal_name + '.gif'); medal_icon.attachBitmap(myBitmapData, 111); stop(); } } // unknown tag 88 length 215 movieClip 215 { frame 1 { stop(); } frame 2 { stop(); } } instance of movieClip 215 { onClipEvent (rollOver) { this.hili.gotoAndPlay(1); } onClipEvent (press) { if (this._currentframe == 1) { _root.track01.setVolume(0); _root.track02.setVolume(0); _root.track03.setVolume(0); _root.track04.setVolume(0); this.nextFrame(); } else { if (this._currentframe == 2) { _root.track01.setVolume(100); _root.track02.setVolume(100); _root.track03.setVolume(100); _root.track04.setVolume(100); this.gotoAndStop(1); } } } } movieClip 218 { } movieClip 219 { frame 1 { onEnterFrame = function () { if (_quality == 'LOW') { _visible = false; } else { _visible = true; } }; } } instance clouds of movieClip 219 { onClipEvent (load) { X = _x; _alpha = 0; } onClipEvent (enterFrame) { if (_alpha < 50) { _alpha = _alpha + 2; } _x = _x + 10; if (this._x > X + 700) { _x = X; } } } movieClip 227 { } movieClip 229 { } movieClip 230 { frame 1 { com.Newgrounds.NewgroundsAPI.attachFlashAd(_parent[_name]); var attachAd = function () { com.Newgrounds.NewgroundsAPI.attachFlashAd(_parent[_name]); }; com.Newgrounds.NewgroundsAPI.addEventListener(com.Newgrounds.NewgroundsAPI.events.ADS_APPROVED, attachAd); background._visible = false; } } instance poop of movieClip 230 { onClipEvent (enterFrame) { if (_root.hideAds == true) { _x = -10000; } } } instance clouds of movieClip 219 { onClipEvent (load) { X = _x; _alpha = 50; } onClipEvent (enterFrame) { _x = _x + 10; if (this._x > X + 700) { _x = X; } } } movieClip 232 { frame 15 { stop(); } frame 22 { stop(); } frame 31 { gotoAndStop(15); } frame 38 { stop(); } } instance of movieClip 232 { onClipEvent (load) { var mouseOn = false; } onClipEvent (rollOver) { mouseOn = true; if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { mouseOn = false; if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { stopAllSounds(); gotoAndPlay('press'); _root.hud.play(); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { stopAllSounds(); gotoAndPlay('press'); _root.hud.play(); } } else { if (this._currentframe == 22 && mouseOn == false) { this.play(); } } } } instance of movieClip 232 { onClipEvent (load) { var mouseOn = false; } onClipEvent (rollOver) { mouseOn = true; if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { mouseOn = false; if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { gotoAndPlay('press'); _root.gotoAndPlay('bonus'); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { gotoAndPlay('press'); _root.gotoAndPlay('bonus'); } } else { if (this._currentframe == 22 && mouseOn == false) { this.play(); } } } } instance of movieClip 232 { onClipEvent (load) { var mouseOn = false; } onClipEvent (rollOver) { mouseOn = true; if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { mouseOn = false; if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { gotoAndPlay('press'); getURL('http://www.sun-studios.net', '_blank'); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { gotoAndPlay('press'); getURL('http://www.sun-studios.net', '_blank'); } } else { if (this._currentframe == 22 && mouseOn == false) { this.play(); } } } } // unknown tag 88 length 54 instance of movieClip 232 { onClipEvent (load) { var mouseOn = false; } onClipEvent (rollOver) { mouseOn = true; if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { mouseOn = false; if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { gotoAndPlay('press'); _root.openAddToWebsiteLink(); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { gotoAndPlay('press'); _root.openAddToWebsiteLink(); } } else { if (this._currentframe == 22 && mouseOn == false) { this.play(); } } } } instance of movieClip 232 { onClipEvent (load) { var mouseOn = false; } onClipEvent (rollOver) { mouseOn = true; if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { mouseOn = false; if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { gotoAndPlay('press'); _root.openSignLink(); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { gotoAndPlay('press'); _root.openSignLink(); } } else { if (this._currentframe == 22 && mouseOn == false) { this.play(); } } } } movieClip 241 { } movieClip 242 { frame 1 { stop(); } frame 11 { gotoAndStop(1); } frame 21 { gotoAndStop(1); } } instance arrowMov of movieClip 242 { onClipEvent (load) { var stepCur = 1; var stepNum = 5; var timeBreak = 0; } onClipEvent (enterFrame) { if (timeBreak == 0) { if (stepCur < stepNum) { if (Key.isDown(40)) { _y = _y + 30; ++stepCur; this.gotoAndPlay('goDown'); timeBreak = 10; } } if (stepCur > 1) { if (Key.isDown(38)) { _y = _y - 30; --stepCur; this.gotoAndPlay('goUp'); timeBreak = 10; } } } if (timeBreak > 0) { --timeBreak; } } } frame 412 { stop(); } instance clouds of movieClip 219 { onClipEvent (load) { X = _x; } onClipEvent (enterFrame) { _x = _x + 10; if (this._x > X + 700) { _x = X; } } } instance poop of movieClip 230 { onClipEvent (load) { X = this._x; } onClipEvent (enterFrame) { if (_root.bonusFeature._currentframe > 2) { this._x = -1000; } else { this._x = X; } if (_root.hideAds == true) { _x = -10000; } } } instance quality of movieClip 192 { onClipEvent (load) { if (_quality == 'LOW') { this.gotoAndStop(1); } else { if (_quality == 'MEDIUM') { this.gotoAndStop(2); } else { this.gotoAndStop(3); } } } onClipEvent (rollOver) { this.hili.gotoAndPlay(1); } onClipEvent (press) { if (this._currentframe == 1) { _quality = 'MEDIUM'; this.gotoAndStop(2); } else { if (this._currentframe == 2) { this.gotoAndStop(3); _quality = 'HIGH'; } else { if (this._currentframe == 3) { this.gotoAndStop(1); _quality = 'LOW'; } } } } } instance of movieClip 198 { onClipEvent (enterFrame) { if (this.hitTest(_root.mouseOBJ)) { this.gotoAndStop(2); } else { this.gotoAndStop(1); } } onClipEvent (press) { _root.openSignLink(); } } instance of movieClip 215 { onClipEvent (rollOver) { this.hili.gotoAndPlay(1); } onClipEvent (press) { if (this._currentframe == 1) { _root.track01.setVolume(0); _root.track02.setVolume(0); _root.track03.setVolume(0); _root.track04.setVolume(0); this.nextFrame(); } else { if (this._currentframe == 2) { _root.track01.setVolume(100); _root.track02.setVolume(100); _root.track03.setVolume(100); _root.track04.setVolume(100); this.gotoAndStop(1); } } } } instance of movieClip 232 { onClipEvent (load) { mouseOn = false; } onClipEvent (rollOver) { mouseOn = true; if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { mouseOn = false; if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { gotoAndPlay('press'); _parent.bonusFeature.gotoAndStop('cutscenes'); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { gotoAndPlay('press'); _parent.bonusFeature.gotoAndStop('cutscenes'); } } else { if (this._currentframe == 22 && mouseOn == false) { this.play(); } } if (this._currentframe > 31) { if (Key.isDown(38) or Key.isDown(40)) { this.gotoAndPlay('out'); } } } } instance of movieClip 232 { onClipEvent (load) { mouseOn = false; } onClipEvent (rollOver) { mouseOn = true; if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { mouseOn = false; if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { gotoAndPlay('press'); _parent.bonusFeature.gotoAndStop('conceptArt'); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { gotoAndPlay('press'); _parent.bonusFeature.gotoAndStop('conceptArt'); } } else { if (this._currentframe == 22 && mouseOn == false) { this.play(); } } if (this._currentframe > 31) { if (Key.isDown(38) or Key.isDown(40)) { this.gotoAndPlay('out'); } } } } instance of movieClip 232 { onClipEvent (load) { mouseOn = false; } onClipEvent (rollOver) { mouseOn = true; if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { mouseOn = false; if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { _root.track04Started = false; _root.track04.stop(); _root.track01.stop(); _root.track02.stop(); _root.track03.stop(); gotoAndPlay('press'); _parent.bonusFeature.gotoAndStop('music'); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { _root.track04Started = false; _root.track04.stop(); _root.track01.stop(); _root.track02.stop(); _root.track03.stop(); gotoAndPlay('press'); _parent.bonusFeature.gotoAndStop('music'); } } else { if (this._currentframe == 22 && mouseOn == false) { this.play(); } } if (this._currentframe > 31) { if (Key.isDown(38) or Key.isDown(40)) { this.gotoAndPlay('out'); } } } } instance of movieClip 232 { onClipEvent (load) { mouseOn = false; } onClipEvent (rollOver) { mouseOn = true; if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { mouseOn = false; if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { gotoAndPlay('press'); _root.gotoAndPlay('toMenu'); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { gotoAndPlay('press'); _root.gotoAndPlay('toMenu'); } } else { if (this._currentframe == 22 && mouseOn == false) { this.play(); } } } } frame 430 { 'movieBonus'; } frame 430 { stop(); _root.cutSceneMode = false; } instance arrowMov of movieClip 242 { onClipEvent (load) { var stepCur = 1; var stepNum = 4; var timeBreak = 0; } onClipEvent (enterFrame) { if (timeBreak == 0) { if (stepCur < stepNum) { if (Key.isDown(40)) { _y = _y + 30; ++stepCur; this.gotoAndPlay('goDown'); timeBreak = 10; } } if (stepCur > 1) { if (Key.isDown(38)) { _y = _y - 30; --stepCur; this.gotoAndPlay('goUp'); timeBreak = 10; } } } if (timeBreak > 0) { --timeBreak; } } } movieClip 253 { frame 3 { stop(); } } movieClip 264 { frame 1 { stop(); } } movieClip 267 { frame 1 { play(); } frame 10 { stop(); } } movieClip 269 { frame 1 { play(); } frame 10 { stop(); } } movieClip 272 { } movieClip 273 { frame 28 { stop(); } instance art of movieClip 264 { onClipEvent (enterFrame) { if (this._currentframe == 1) { if (_root.concept1Unlocked) { this._visible = true; } else { this._visible = false; } } else { if (this._currentframe == 2) { if (_root.concept2Unlocked) { this._visible = true; } else { this._visible = false; } } else { if (this._currentframe == 3) { if (_root.concept3Unlocked) { this._visible = true; } else { this._visible = false; } } else { if (this._currentframe == 4) { if (_root.concept4Unlocked) { this._visible = true; } else { this._visible = false; } } else { if (this._currentframe == 5) { if (_root.concept5Unlocked) { this._visible = true; } else { this._visible = false; } } else { if (this._currentframe == 6) { if (_root.concept6Unlocked) { this._visible = true; } else { this._visible = false; } } } } } } } } } instance of movieClip 267 { onClipEvent (rollOver) { gotoAndPlay(1); } onClipEvent (press) { gotoAndPlay(1); _parent.art.nextFrame(); } onClipEvent (enterFrame) { if (this._currentframe == 10) { if (Key.isDown(39)) { gotoAndPlay(1); _parent.art.nextFrame(); } } } } instance of movieClip 269 { onClipEvent (rollOver) { gotoAndPlay(1); } onClipEvent (press) { gotoAndPlay(1); _parent.art.prevFrame(); } onClipEvent (enterFrame) { if (this._currentframe == 10) { if (Key.isDown(37)) { gotoAndPlay(1); _parent.art.prevFrame(); } } } } instance of movieClip 272 { onClipEvent (enterFrame) { this.artPeice = _parent.art._currentframe; } } } movieClip 275 { } movieClip 278 { } movieClip 285 { frame 1 { onEnterFrame = function () { if (_parent.currentSong == 1) { Title = '.:Arabic Desert:.'; Author = 'neoloconick'; } else { if (_parent.currentSong == 2) { Title = 'Sunrise Over Cairo'; Author = 'winKoneR'; } else { if (_parent.currentSong == 3) { Title = 'Show No Tears'; Author = 'NemesisTheory'; } else { if (_parent.currentSong == 4) { Title = 'Airscape -r'; Author = 'Rawrthaas'; } } } } }; } } movieClip 287 { frame 1 { stop(); } } movieClip 288 { instance of movieClip 267 { onClipEvent (rollOver) { gotoAndPlay(1); } onClipEvent (press) { _parent.art.nextFrame(); gotoAndPlay(1); } onClipEvent (enterFrame) { if (this._currentframe == 10) { if (Key.isDown(39)) { gotoAndPlay(1); _parent.art.nextFrame(); } } } } instance of movieClip 269 { onClipEvent (rollOver) { gotoAndPlay(1); } onClipEvent (press) { gotoAndPlay(1); _parent.art.prevFrame(); } onClipEvent (enterFrame) { if (this._currentframe == 10) { if (Key.isDown(37)) { gotoAndPlay(1); _parent.art.prevFrame(); } } } } instance of movieClip 278 { onClipEvent (enterFrame) { this.artPeice = _parent.currentSong; } } instance of movieClip 267 { onClipEvent (rollOver) { gotoAndPlay(1); } onClipEvent (press) { gotoAndPlay(1); if (_parent.currentSong < 4) { _parent.play(); ++_parent.currentSong; } } onClipEvent (enterFrame) { if (this._currentframe == 10) { if (Key.isDown(39)) { gotoAndPlay(1); _parent.art.nextFrame(); } } } } instance of movieClip 269 { onClipEvent (rollOver) { gotoAndPlay(1); } onClipEvent (press) { gotoAndPlay(1); if (_parent.currentSong > 1) { _parent.play(); --_parent.currentSong; } } onClipEvent (enterFrame) { if (this._currentframe == 10) { if (Key.isDown(37)) { gotoAndPlay(1); _parent.art.prevFrame(); } } } } instance of movieClip 278 { onClipEvent (enterFrame) { this.artPeice = _parent.currentSong; } } frame 29 { if (currentSong <= 3) { if (_root['music' + currentSong + 'Unlocked']) { _root['track0' + currentSong].start(0, 99); uoru.gotoAndStop(1); } else { uoru.gotoAndStop(2); } } else { _root['track0' + currentSong].start(0, 99); } stop(); onEnterFrame = function () { if (_currentframe == 29) { if (Key.isDown(37)) { if (currentSong > 1) { play(); --currentSong; } } if (Key.isDown(39)) { if (currentSong < 4) { play(); ++currentSong; } } } }; } frame 30 { stopAllSounds(); } frame 37 { gotoAndPlay(15); } } movieClip 295 { frame 1 { stop(); onEnterFrame = function () { if (_root['videoWatched' + this.part] == true) { this.gotoAndStop(1); } else { this.gotoAndStop(2); } }; } } movieClip 296 { instance of movieClip 232 { onClipEvent (rollOver) { if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { if (_root.videoWatched1) { stopAllSounds(); gotoAndPlay('press'); _root.cutSceneMode = true; _root.gotoAndStop('cutScene1'); } } } instance of movieClip 232 { onClipEvent (rollOver) { if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { if (_root.videoWatched2) { stopAllSounds(); gotoAndPlay('press'); _root.cutSceneMode = true; _root.gotoAndStop('cutScene2'); } } } instance of movieClip 232 { onClipEvent (rollOver) { if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { if (_root.videoWatched3) { stopAllSounds(); gotoAndPlay('press'); _root.cutSceneMode = true; _root.gotoAndStop('cutScene3'); } } } instance of movieClip 232 { onClipEvent (rollOver) { if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { if (_root.videoWatched4) { stopAllSounds(); gotoAndPlay('press'); _root.cutSceneMode = true; _root.gotoAndStop('cutScene4'); } } } instance of movieClip 232 { onClipEvent (rollOver) { if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { if (_root.videoWatched5) { stopAllSounds(); gotoAndPlay('press'); _root.cutSceneMode = true; _root.gotoAndStop('cutScene5'); } } } instance of movieClip 295 { onClipEvent (load) { var part = 1; } } instance of movieClip 295 { onClipEvent (load) { var part = 2; } } instance of movieClip 295 { onClipEvent (load) { var part = 3; } } instance of movieClip 295 { onClipEvent (load) { var part = 4; } } instance of movieClip 295 { onClipEvent (load) { var part = 5; } } frame 30 { stop(); } } movieClip 297 { frame 1 { stop(); } instance of movieClip 288 { onClipEvent (load) { var currentSong = 1; } } } instance of movieClip 232 { onClipEvent (rollOver) { if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { gotoAndPlay('press'); _root.hud.play(); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { gotoAndPlay('press'); _root.hud.play(); } } else { if (this._currentframe == 22) { this.play(); } } } } instance of movieClip 232 { onClipEvent (rollOver) { if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { gotoAndPlay('press'); _root.hud.play(); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { gotoAndPlay('press'); _root.hud.play(); } } else { if (this._currentframe == 22) { this.play(); } } } } instance of movieClip 232 { onClipEvent (rollOver) { if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { gotoAndPlay('press'); _root.hud.play(); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { gotoAndPlay('press'); _root.hud.play(); } } else { if (this._currentframe == 22) { this.play(); } } } } instance of movieClip 232 { onClipEvent (rollOver) { if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { gotoAndPlay('press'); _root.hud.play(); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { gotoAndPlay('press'); _root.hud.play(); } } else { if (this._currentframe == 22) { this.play(); } } } } frame 446 { _root.gotoAndPlay('fromBonus'); } frame 447 { } frame 447 { stop(); } // unknown tag 88 length 94 movieClip 301 { } movieClip 311 { } movieClip 317 { } movieClip 667 { instance of movieClip 301 { onClipEvent (enterFrame) { if (Key.isDown(13)) { if (_root.cutSceneMode) { _root.track04.start(0, 99); _root.gotoAndStop('bonus2'); } else { _root.gotoAndPlay('game'); } } } } frame 2492 { if (_root.cutSceneMode == true) { _root.track04.start(0, 99); _root.gotoAndStop('bonus2'); _root.cutSceneMode = false; } } frame 2493 { _root.videoWatched1 = true; var savefile = SharedObject.getLocal('RedMoonlol10'); _root.savefile.data.videoWatched1 = _root.videoWatched1; _root.savefile.flush(); _root.gotoAndPlay('game'); } } instance medal_popup of movieClip 211 { onClipEvent (enterFrame) { if (_root.hideMedal) { _visible = false; } } } instance quality of movieClip 192 { onClipEvent (load) { if (_quality == 'LOW') { this.gotoAndStop(1); } else { if (_quality == 'MEDIUM') { this.gotoAndStop(2); } else { this.gotoAndStop(3); } } } onClipEvent (rollOver) { this.hili.gotoAndPlay(1); } onClipEvent (press) { if (this._currentframe == 1) { _quality = 'MEDIUM'; this.gotoAndStop(2); } else { if (this._currentframe == 2) { this.gotoAndStop(3); _quality = 'HIGH'; } else { if (this._currentframe == 3) { this.gotoAndStop(1); _quality = 'LOW'; } } } } } instance of movieClip 198 { onClipEvent (enterFrame) { if (this.hitTest(_root.mouseOBJ)) { this.gotoAndStop(2); } else { this.gotoAndStop(1); } } onClipEvent (press) { _root.openSignLink(); } } instance mouseOBJ of movieClip 79 { onClipEvent (load) { _visible = false; } onClipEvent (enterFrame) { this._x = _root._xmouse; this._y = _root._ymouse; } } frame 448 { stop(); } movieClip 669 { } movieClip 670 { } movieClip 672 { } movieClip 676 { } movieClip 679 { } movieClip 682 { } movieClip 684 { frame 8 { if (_root.hero._xscale == -100) { _root.hawken._x = _root.hero._x - 100; } else { _root.hawken._x = _root.hero._x + 100; } _root.hawken._y = _root.hero._y; _root.convo.convopick += 1; _root.convo.gotoAndPlay(1); } frame 9 { _root.convo._x = _root.hawken._x; _root.convo._y = _root.hawken._y - 150; } frame 15 { _parent.gotoAndStop(1); } } movieClip 685 { frame 1 { stop(); } frame 2 { stop(); } } // unknown tag 88 length 164 movieClip 699 { } movieClip 703 { instance of movieClip 672 { onClipEvent (enterFrame) { _x = _root.vcam._x; _y = _root.vcam._y - 150; _xscale = _root.vcam._xscale; _yscale = _root.vcam._yscale; } } instance clouds of movieClip 219 { onClipEvent (load) { X = _x; } onClipEvent (enterFrame) { _x = _x + 1; if (this._x > X + 700) { _x = X; } } } instance of movieClip 301 { onClipEvent (enterFrame) { if (Key.isDown(13)) { if (_root.cutSceneMode) { _root.track04.start(0, 99); _root.gotoAndStop('bonus2'); } else { _root.gotoAndPlay('game2'); } } } } frame 65 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 87 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 109 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 150 { if (_root.cutSceneMode == true) { _root.track04.start(0, 99); _root.gotoAndStop('bonus2'); _root.cutSceneMode = false; } } frame 151 { _root.videoWatched2 = true; var savefile = SharedObject.getLocal('RedMoonlol10'); _root.savefile.data.videoWatched2 = _root.videoWatched2; _root.savefile.flush(); _root.gotoAndPlay('game2'); } } frame 449 { stop(); } movieClip 744 { instance of movieClip 672 { onClipEvent (enterFrame) { _x = _root.vcam._x; _y = _root.vcam._y - 150; _xscale = _root.vcam._xscale; _yscale = _root.vcam._yscale; } } instance clouds of movieClip 219 { onClipEvent (load) { X = _x; } onClipEvent (enterFrame) { _x = _x + 1; if (this._x > X + 700) { _x = X; } } } instance of movieClip 301 { onClipEvent (enterFrame) { if (Key.isDown(13)) { if (_root.cutSceneMode) { _root.track04.start(0, 99); _root.gotoAndStop('bonus2'); } else { _root.gotoAndPlay('game3'); } } } } frame 116 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 162 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 205 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 360 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 435 { if (_root.cutSceneMode == true) { _root.track04.start(0, 99); _root.gotoAndStop('bonus2'); _root.cutSceneMode = false; } } frame 436 { _root.videoWatched3 = true; var savefile = SharedObject.getLocal('RedMoonlol10'); _root.savefile.data.videoWatched3 = _root.videoWatched3; _root.savefile.flush(); _root.gotoAndPlay('game3'); } } frame 450 { stop(); } movieClip 746 { } movieClip 770 { instance of movieClip 672 { onClipEvent (enterFrame) { _x = _root.vcam._x; _y = _root.vcam._y - 150; _xscale = _root.vcam._xscale; _yscale = _root.vcam._yscale; } } instance of movieClip 746 { onClipEvent (enterFrame) { _x = _root.bigmoon._x; _y = _root.bigmoon._y + 20; } } instance clouds of movieClip 219 { onClipEvent (load) { X = _x; _alpha = 80; } onClipEvent (enterFrame) { _x = _x + 1; if (this._x > X + 700) { _x = X; } } } instance of movieClip 301 { onClipEvent (enterFrame) { if (Key.isDown(13)) { if (_root.cutSceneMode) { _root.track04.start(0, 99); _root.gotoAndStop('bonus2'); } else { _root.gotoAndPlay('game4'); } } } } frame 55 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 112 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 160 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 208 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 275 { stop(); } instance of movieClip 699 { onClipEvent (enterFrame) { if (Key.isDown(32)) { _parent.play(); } } } frame 478 { if (_root.cutSceneMode == true) { _root.track04.start(0, 99); _root.gotoAndStop('bonus2'); _root.cutSceneMode = false; } } frame 479 { _root.videoWatched4 = true; var savefile = SharedObject.getLocal('RedMoonlol10'); _root.savefile.data.videoWatched4 = _root.videoWatched4; _root.savefile.flush(); _root.gotoAndPlay('game4'); } } frame 451 { stop(); } movieClip 1335 { } movieClip 1338 { } movieClip 1341 { } movieClip 1349 { } movieClip 1377 { } movieClip 1411 { frame 1 { play(); } instance of movieClip 301 { onClipEvent (enterFrame) { if (Key.isDown(13)) { if (_root.cutSceneMode) { _root.track04.start(0, 99); _root.gotoAndStop('bonus2'); } else { _root.gotoAndPlay(3414); } } } } frame 3413 { if (_root.cutSceneMode == true) { _root.track04.start(0, 99); _root.gotoAndStop('bonus2'); _root.cutSceneMode = false; } } frame 3523 { _root.videoWatched5 = true; var savefile = SharedObject.getLocal('RedMoonlol10'); _root.savefile.data.videoWatched5 = _root.videoWatched5; _root.savefile.flush(); } frame 3524 { stop(); } instance of movieClip 232 { onClipEvent (rollOver) { if (this._currentframe < 32) { gotoAndPlay('over'); } } onClipEvent (rollOut) { if (this._currentframe < 32) { gotoAndPlay('out'); } } onClipEvent (press) { _root.gotoAndPlay('declare'); } onClipEvent (enterFrame) { if (_parent.arrowMov.hitTest(this)) { if (this._currentframe == 15) { this.play(); } if (Key.isDown(13) or Key.isDown(32) or Key.isDown(_root.hero.attackButton) or Key.isDown(_root.hero.jump)) { _root.gotoAndPlay('declare'); } } else { if (this._currentframe == 22) { this.play(); } } } }




http://swfchan.com/17/80988/info.shtml
Created: 2/4 -2019 05:22:23 Last modified: 2/4 -2019 05:22:23 Server time: 22/12 -2024 21:43:53