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

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

plod.swf

This is the info page for
Flash #124748

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


Text
SEND TO FRIENDS

CATCH ALL
THE BURGLARS!

S

TO SWING BAton!

PRESS

<p align="left"><font face="Funny farm hard" size="20" color="#ffffff" letterSpacing="0.000000" kerning="1">SCORE:</font></p>

<p align="left"><font face="Funny farm hard" size="15" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>???</b></font></p>

<p align="left"><font face="Funny farm hard" size="15" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="left"><font face="Funny farm hard" size="20" color="#cccccc" letterSpacing="0.000000" kerning="1"><b>x 10</b></font></p>

<p align="right"><font face="Funny farm hard" size="25" color="#ffff00" letterSpacing="0.000000" kerning="1"><b>120</b></font></p>

PAUSE

TIME:

<p align="right"><font face="Funny farm hard" size="25" color="#ffff00" letterSpacing="0.000000" kerning="1"><b>1</b></font></p>

LEVEL:

<p align="left"><font face="Funny farm hard" size="20" color="#ffff00" letterSpacing="0.000000" kerning="1">0000000</font></p>

MORE GAMES

QUIT

<p align="center"><font face="Funny farm hard" size="28" color="#ffff00" letterSpacing="0.000000" kerning="1"><b>MUSIC: ON</b></font></p>

RESUME GAME

- PAUSED -

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

TOP SCORE

INSTRUCTIONS

your logo

your logo

your site link here

MAIN MENU

NEXT

REPLAY

RIGHTO!

START GAME

SUBMIT TOP SCORE

<p align="center"><font face="Funny farm hard" size="40" color="#ffff00" letterSpacing="0.000000" kerning="1"><b>LEVEL@!</b></font></p>

<p align="center"><font face="standard 07_53_8pt_st" size="8" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>200</b></font></p>

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

LEVEL 1

CHIEF:

"Those darn burglars are up to their old
tricks!  Catch ‘em all, and recover the
evidence!"

"Cripes, this never ends!  I wanna see
those little robbers behind bars!"

"Newsflash sergeant, lift your game!!
That outlaw gang is still on the loose.
Bring ‘em back here, loot and all!"

"Another break in!  Arrest the lot of
‘em, and don’t pocket the goods!"

"On your bike, lad.  Those crims won’t
arrest themselves!"

"More robberies.  Round up the
baddies, and then we can all have a
cup a tea."

"Burglar gang strikes again!  Find
‘em son, and fast!"

"Those darn burglars are up to their old
tricks!  Bring ‘em back here, loot and all!"

"CLEAN UP THOSE STREETS!  THe Mayor'S
birthday will not be ruined!"

"GET THOSE CRIMINALS IN THE NICK AS
FAST AS YOU CAN, OR do you have prior
Engagements?"

"look, i've told everyone that you're a
ruddy good copper.  don't make me a
liar!"

"The streets used to be dirty, with crime.
NOw they're just a bit dusty.  Don't forget
to wash your hands when you're done."

"well well well.  You've managed to make
it this far!  I may need to buy you a cake
sir."

"There’s been a huge heist downtown!  Get
the loot back, and arrest those crims!"

"Only one more day until you retire.
good luck there chappy!"

<p align="left"><font face="Funny farm hard" size="22" color="#ffffff" letterSpacing="0.000000" kerning="1"><b>000000</b></font></p>

SCORE:

GAME OVER!

<p align="left"><font face="Funny farm hard" size="30" color="#ffff00" letterSpacing="0.000000" kerning="1"><b>000000</b></font></p>

SCORE:

WELL DONE!

You've cleaned up this town!

INSTRUCTIONS

JUMP

MOVE RIGHT

MOVE LEFT

RUN

Shift

SWING BAton

Controls

Goal

- collect evidence -
- collect ALL the clues -
- catch ALL the burglars

<p align="left"><font face="Funny farm hard" size="40" color="#ffff00" letterSpacing="0.000000" kerning="1"><b>0000000000</b></font></p>

SCORE:

<p align="left"><font face="Funny farm hard" size="22" color="#ffff00" letterSpacing="0.000000" kerning="1"><b>TIME</b></font></p>

TIME BONUS:

<p align="left"><font face="Funny farm hard" size="22" color="#ffff00" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

EVIDENCE BONUS:

LEVEL COMPETE!

OUT OF TIME!

thistler.net

©

sponsored by:

ActionScript [AS3]

Section 1
//Background (com.gamezhero.api.as3.gui.Background) package com.gamezhero.api.as3.gui { import flash.display.*; public class Background extends MovieClip { private var _bg:MovieClip; private var _goal:MovieClip; public function Background(g:MovieClip){ super(); _goal = g; _goal.addChild(this); ini(); iniEvents(); } private function iniEvents():void{ } private function getBg():MovieClip{ var mc:MovieClip; mc = new MovieClip(); mc.graphics.beginFill(0, 1); mc.graphics.lineStyle(0, 0, 0); mc.graphics.moveTo(0, 0); mc.graphics.lineTo(1000, 0); mc.graphics.lineTo(1000, 1000); mc.graphics.lineTo(0, 1000); mc.graphics.lineTo(0, 0); mc.graphics.endFill(); return (mc); } private function ini():void{ _bg = getBg(); this.addChild(_bg); } public function remove():void{ clearEvents(); _goal.removeChild(this); } public function update(w:Number, h:Number):void{ this.x = 0; this.y = 0; this.width = (w + 100); this.height = (h + 100); } private function clearEvents():void{ } } }//package com.gamezhero.api.as3.gui
Section 2
//Indicator (com.gamezhero.api.as3.gui.Indicator) package com.gamezhero.api.as3.gui { import flash.events.*; import flash.display.*; import flash.text.*; import flash.utils.*; public class Indicator extends MovieClip { private var _timer:Timer; private var _indicator:MovieClip; private var _timer_2:Timer; private var _dalpha:Number; private var _current:Number;// = 0 private var _info_text:TextField; private var _arr:Array; private var _n:uint;// = 10 private var _goal:MovieClip; public function Indicator(g:MovieClip){ _n = 10; _dalpha = (360 / _n); _arr = new Array(); _current = 0; super(); _goal = g; _goal.addChild(this); ini(); iniEvents(); } public function createInfoText():void{ var fontFormat:TextFormat; var w:Number; var h:Number; _info_text = new TextField(); fontFormat = new TextFormat(); fontFormat.color = 0xFFFFFF; fontFormat.size = 11; fontFormat.font = "Arial"; _info_text.defaultTextFormat = fontFormat; _info_text.autoSize = TextFieldAutoSize.CENTER; _indicator.addChild(_info_text); w = 100; h = 20; w = _info_text.width; h = _info_text.height; _info_text.x = (-(w) / 2); _info_text.y = -10; } private function getBorder():MovieClip{ var cr:Number; var boxWidth:Number; var boxHeight:Number; var mc:MovieClip; cr = 10; boxWidth = 150; boxHeight = 150; mc = new MovieClip(); mc.graphics.beginFill(0x333333, 1); mc.graphics.moveTo(cr, 0); mc.graphics.lineTo((boxWidth - cr), 0); mc.graphics.curveTo(boxWidth, 0, boxWidth, cr); mc.graphics.lineTo(boxWidth, cr); mc.graphics.lineTo(boxWidth, (boxHeight - cr)); mc.graphics.curveTo(boxWidth, boxHeight, (boxWidth - cr), boxHeight); mc.graphics.lineTo((boxWidth - cr), boxHeight); mc.graphics.lineTo(cr, boxHeight); mc.graphics.curveTo(0, boxHeight, 0, (boxHeight - cr)); mc.graphics.lineTo(0, (boxHeight - cr)); mc.graphics.lineTo(0, cr); mc.graphics.curveTo(0, 0, cr, 0); mc.graphics.lineTo(cr, 0); mc.graphics.endFill(); _indicator.addChild(mc); mc.x = (-(mc.width) / 2); mc.y = (-(mc.height) / 2); return (mc); } private function iniEvents():void{ _timer.addEventListener(TimerEvent.TIMER, updateIndicator); _timer.start(); _timer_2.addEventListener(TimerEvent.TIMER, updateCurrent); _timer_2.start(); } private function ini():void{ var i:uint; var fooMc:MovieClip; this.visible = false; _timer = new Timer((1000 / 40), 0); _timer_2 = new Timer((1000 / 20), 0); _indicator = new MovieClip(); this.addChild(_indicator); getBorder(); i = 0; while (i < _n) { fooMc = getItem(); fooMc.rotation = (_dalpha * i); fooMc.alpha = 0.2; _arr.push(fooMc); i++; }; createInfoText(); } public function setVal(val:String):void{ _info_text.text = val; } private function updateCurrent(event:TimerEvent=null):void{ _current++; if (_current >= _arr.length){ _current = 0; }; _arr[_current].alpha = 1; event.updateAfterEvent(); } public function setSize(w:Number, h:Number):void{ this.visible = true; this.width = w; this.height = h; } public function remove():void{ clearEvents(); _goal.removeChild(this); } private function getItem():MovieClip{ var mc:MovieClip; mc = new MovieClip(); mc.graphics.beginFill(0xFFFFFF, 1); mc.graphics.lineStyle(0, 0, 0); mc.graphics.moveTo(32.3, -5.7); mc.graphics.curveTo(30, -3.3, 30, 0); mc.graphics.curveTo(30, 3.3, 32.3, 5.6); mc.graphics.curveTo(34.7, 8, 38.05, 8); mc.graphics.lineTo(57, 8); mc.graphics.curveTo(60.3, 8, 62.6, 5.6); mc.graphics.curveTo(65, 3.3, 65, 0); mc.graphics.curveTo(65, -3.3, 62.6, -5.7); mc.graphics.curveTo(60.3, -8, 57, -8); mc.graphics.lineTo(38.05, -8); mc.graphics.curveTo(34.7, -8, 32.3, -5.7); mc.graphics.endFill(); _indicator.addChild(mc); return (mc); } private function updateIndicator(event:TimerEvent=null):void{ var i:uint; i = 0; while (i < _n) { _arr[i].alpha = (_arr[i].alpha - 0.07); if (_arr[i].alpha <= 0){ _arr[i].alpha = 0; }; i++; }; event.updateAfterEvent(); } public function setPos(x:Number, y:Number):void{ this.visible = true; this.x = x; this.y = y; } public function update(w:Number, h:Number):void{ this.visible = true; this.x = (w / 2); this.y = (h / 2); } private function clearEvents():void{ _timer.removeEventListener(TimerEvent.TIMER, updateIndicator); _timer_2.removeEventListener(TimerEvent.TIMER, updateCurrent); } } }//package com.gamezhero.api.as3.gui
Section 3
//URL (com.gamezhero.api.as3.utils.URL) package com.gamezhero.api.as3.utils { public class URL { private var _scheme:String; private var _host:String; private var _query:String; private var _path:String; private var _userinfo:String; private var _port:String; private var _fragment:String; private var _url:String; private static const PATTERN:RegExp = /^([A-Za-z0-9_+.]{1,8}:\/\/)?([!-~]+@)?([^\/?#:]*)(:[0-9]*)?(\/[^?#]*)?(\?[^#]*)?(\#.*)?/i; public function URL(url:String):void{ var result:Array; super(); result = url.match(URL.PATTERN); _url = result[0]; _scheme = result[1]; _userinfo = result[2]; _host = result[3]; _port = result[4]; _path = result[5]; _query = result[6]; _fragment = result[7]; } public function get port():int{ return (((_port.length <= 0)) ? undefined : int(_port.substring(1, _port.length))); } public function get query():Object{ var ret:Object; var _parse:String; var _intovars:Array; var i:int; var _kv:Array; ret = {raw:undefined, parsed:undefined}; if (((_query) && ((_query.length > 0)))){ ret.raw = _query; _parse = _query.substring(1, _query.length); _intovars = _parse.split("&"); ret.parsed = ((_intovars.length > 0)) ? {} : undefined; i = 0; while (i < _intovars.length) { _kv = _intovars[i].split("="); ret.parsed[_kv[0]] = _kv[1]; i++; }; }; return (ret); } public function get fragment():String{ return (((_fragment.length <= 0)) ? undefined : _fragment); } public function get scheme():String{ return (((_scheme.length <= 0)) ? undefined : _scheme.substring(0, (_scheme.length - 3))); } public function get host():String{ return (((_host.length <= 0)) ? undefined : _host); } public function get path():String{ return (((_path.length <= 0)) ? undefined : _path); } public function get url():String{ return (((_url.length <= 0)) ? undefined : _url); } public function get userinfo():Object{ var ret:Object; var arr:Array; ret = {user:undefined, pass:undefined}; if (_userinfo){ arr = _userinfo.substring(0, (_userinfo.length - 1)).split(":"); ret.user = (arr[0]) ? arr[0] : ret.user; ret.pass = (arr[1]) ? arr[1] : ret.pas; }; return (ret); } } }//package com.gamezhero.api.as3.utils
Section 4
//GamePreloader (com.gamezhero.api.as3.GamePreloader) package com.gamezhero.api.as3 { import flash.events.*; import flash.display.*; import flash.net.*; import com.google.analytics.*; import flash.utils.*; import com.gamezhero.api.as3.gui.*; import flash.ui.*; public class GamePreloader extends MovieClip { private var _obj_listener_preloader:Object; private var _scale_old:String; private var _obj:Object; private var _timer:Timer; private var _loader_preloader_skin:Loader; private var _send_localconnection_preloader:LocalConnection; private var _align_old:String; private var _in_target:String; private var _in_url:String;// = "null" private var _indicator:Indicator; private var _bg:Background; private var _error_flag:Boolean;// = false private var _amount_try:uint;// = 10 private var _quality_old:String; private var _gamezhero_code_preloader:Number; private var _recive_localconnection_preloader:LocalConnection; private var _debug_flag:Boolean;// = false private var _rate_old:Number; private var _send_name_connection_preloader:String; private var _recived_name_connection_preloader:String; private var _preloader_active_flag:Boolean;// = false private var _urls:Dictionary; private var _par:MovieClip; private var _tracker:GATracker; public static const finish:String = "PRELOAD_COMPLETE"; public function GamePreloader(par:MovieClip, iniObject:Object=null){ var par = par; var iniObject = iniObject; _timer = new Timer((1000 / 10), 0); _error_flag = false; _preloader_active_flag = false; _in_url = "null"; _obj = new Object(); _urls = new Dictionary(); _debug_flag = false; _amount_try = 10; _recive_localconnection_preloader = new LocalConnection(); _send_localconnection_preloader = new LocalConnection(); _loader_preloader_skin = new Loader(); _obj_listener_preloader = new Object(); super(); _par = par; _par.addChild(this); if (iniObject != null){ _obj = iniObject; }; _debug_flag = _obj["debug"]; //unresolved jump var _slot1 = e; _debug_flag = false; _bg = new Background(this); _indicator = new Indicator(this); _gamezhero_code_preloader = new Date().getTime(); _recived_name_connection_preloader = ("_recived_gamezhero_preloader_" + _gamezhero_code_preloader); _send_name_connection_preloader = ("_send_gamezhero_preloader_" + _gamezhero_code_preloader); iniLocalConnectionsPreloader(); iniEvents(); iniStage(); iniGoogleAnalitics(); } private function beginScenario2():void{ _error_flag = true; clearTimers(); _timer.addEventListener(TimerEvent.TIMER, updatePreloader2); _timer.start(); } private function resizeAction(event:Event=null):void{ var obj:Object; var event = event; obj = new Object(); obj.width = stage.stageWidth; obj.height = stage.stageHeight; //unresolved jump var _slot1 = e; obj.width = 550; obj.height = 400; if ((((_error_flag == false)) && ((_preloader_active_flag == true)))){ _send_localconnection_preloader.send(_send_name_connection_preloader, GamezheroGlobal.toText([117, 112, 100, 97, 116, 101, 80, 111, 115]), obj); //unresolved jump var _slot1 = e; beginScenario2(); }; _indicator.update(obj.width, obj.height); _bg.update(obj.width, obj.height); } private function iniEvents():void{ _par.loaderInfo.addEventListener(IOErrorEvent.IO_ERROR, ioErrorHandler); _loader_preloader_skin.contentLoaderInfo.addEventListener(Event.INIT, preloaderLoaderInit); _loader_preloader_skin.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, preloaderLoaderError); _recive_localconnection_preloader.addEventListener(StatusEvent.STATUS, onStatusRecivePreloader); _recive_localconnection_preloader.addEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorRecivePreloader); _send_localconnection_preloader.addEventListener(StatusEvent.STATUS, onStatusSendPreloader); _send_localconnection_preloader.addEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorSendPreloader); } private function updatePreloader2(event:TimerEvent=null):void{ var proc:Number; var obj:Object; var event = event; iniStageSettings(); proc = (_par.loaderInfo.bytesLoaded / _par.loaderInfo.bytesTotal); _indicator.setVal((Math.round((proc * 100)) + " %")); if (proc >= 1){ action(); }; obj = new Object(); obj.width = stage.stageWidth; obj.height = stage.stageHeight; //unresolved jump var _slot1 = e; obj.width = 550; obj.height = 400; event.updateAfterEvent(); } private function updatePreloader1(event:TimerEvent=null):void{ var proc:Number; var obj:Object; var event = event; iniStageSettings(); proc = (_par.loaderInfo.bytesLoaded / _par.loaderInfo.bytesTotal); _indicator.setVal("Loading..."); obj = new Object(); obj.width = stage.stageWidth; obj.height = stage.stageHeight; //unresolved jump var _slot1 = e; obj.width = 550; obj.height = 400; obj.loaded = proc; _send_localconnection_preloader.send(_send_name_connection_preloader, GamezheroGlobal.toText([117, 112, 100, 97, 116, 101, 80, 114, 101, 108, 111, 97, 100, 101, 114]), obj); event.updateAfterEvent(); } private function onStatusRecivePreloader(infoObject:StatusEvent=null):void{ switch (infoObject.level){ case "status": break; case "error": beginScenario2(); break; }; } public function action(evt:Event=null):void{ clearTimers(); _timer.addEventListener(TimerEvent.TIMER, actionDone); _timer.start(); } private function checkPreloader(event:TimerEvent=null):void{ _send_localconnection_preloader.send(_send_name_connection_preloader, GamezheroGlobal.toText([112, 114, 101, 108, 111, 97, 100, 101, 114, 73, 115, 79, 107]), null); } private function onErrorRecivePreloader(infoObject:SecurityErrorEvent=null):void{ beginScenario2(); } private function ioErrorHandler(event:IOErrorEvent=null):void{ beginScenario2(); } private function clearTimers():void{ _timer.removeEventListener(TimerEvent.TIMER, updatePreloader1); _timer.removeEventListener(TimerEvent.TIMER, updatePreloader2); _timer.removeEventListener(TimerEvent.TIMER, actionDone); } private function preloaderLoaderComplete(event:Event=null):void{ } private function onStatusSendPreloader(infoObject:StatusEvent=null):void{ switch (infoObject.level){ case "status": break; case "error": beginScenario2(); break; }; } private function iniGoogleAnalitics():void{ _tracker = new GATracker(this, "UA-262190-1", "AS3", false); _tracker.trackEvent("preloader", "loading", GamezheroGlobal.gameName); //unresolved jump var _slot1 = e; } private function preloaderLoaderInit(event:Event=null):void{ var foo:Timer; foo = new Timer(200, 1); foo.addEventListener(TimerEvent.TIMER, checkPreloader); foo.start(); } private function onErrorSendPreloader(infoObject:SecurityErrorEvent=null):void{ beginScenario2(); } private function actionDone(event:TimerEvent=null):void{ var evnt:Event; this.alpha = (this.alpha - 1); if (this.alpha <= 1){ this.alpha = 0; clearEvents(); clearStageEvents(); clearTimers(); setStageSettings(); evnt = new Event(finish); this.dispatchEvent(evnt); _indicator.remove(); _bg.remove(); _par.removeChild(this); }; event.updateAfterEvent(); } private function iniContextMenu():void{ var domain:String; var game_name:String; var gamezheroMenu:ContextMenu; var defaultItems:ContextMenuBuiltInItems; var title:String; var menuItemFoo:ContextMenuItem; domain = GamezheroGlobal.getDomain(_par.stage); game_name = GamezheroGlobal.gameName; _obj.gamezhero_url = (((("http://www.gamezhero.com/?utm_campaign=" + game_name) + "&utm_source=") + domain) + "&utm_medium=preloader"); _obj.gamezhero_menu = {Free Online Games @ Gamezhero.com:(((("http://www.gamezhero.com/?utm_campaign=" + game_name) + "&utm_source=") + domain) + "&utm_medium=context_menu"), Send To Friends:(((((("http://www.gamezhero.com/sendtofriends/" + game_name) + "-onlinegames.html?utm_campaign=") + game_name) + "&utm_source=") + domain) + "&utm_medium=send_to_friends_context_menu"), Put This Game To Your Blog or Site:(((((("http://www.gamezhero.com/freewebsitegames/" + game_name) + "-onlinegames.html?utm_campaign=") + game_name) + "&utm_source=") + domain) + "&utm_medium=free_web_site_games_context")}; gamezheroMenu = new ContextMenu(); gamezheroMenu.hideBuiltInItems(); defaultItems = gamezheroMenu.builtInItems; defaultItems.quality = true; defaultItems.print = true; for (title in _obj.gamezhero_menu) { menuItemFoo = new ContextMenuItem(title); _urls[menuItemFoo] = _obj.gamezhero_menu[title]; menuItemFoo.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, getURLContextMenu); gamezheroMenu.customItems.push(menuItemFoo); }; this.parent.contextMenu = gamezheroMenu; } private function getInfo():Object{ var obj:UserInfo; obj = new UserInfo(_par); return ((obj as Object)); } private function clearStageEvents():void{ stage.removeEventListener(Event.RESIZE, resizeAction); //unresolved jump var _slot1 = e; } private function iniStageEvents():void{ stage.addEventListener(Event.RESIZE, resizeAction); resizeAction(); } private function preloaderLoaderError(IOErrorEvent:Event=null):void{ beginScenario2(); } private function moveAction(event:MouseEvent=null):void{ } private function gotoAction(event:MouseEvent=null):void{ trace((((("gotoAction 2 " + _in_url) + " ") + _in_target) + " ")); if (_in_url != "null"){ GamezheroGlobal.getURL(_in_url, _in_target); _in_url = "null"; }; } private function iniLocalConnectionsPreloader():void{ var dom:String; _obj_listener_preloader = new Object(); _obj_listener_preloader.preloaderOk = function ():void{ _send_localconnection_preloader.send(_send_name_connection_preloader, GamezheroGlobal.toText([105, 110, 105, 80, 114, 101, 108, 111, 97, 100, 101, 114]), getInfo()); beginScenario1(); }; _obj_listener_preloader.preloaderGetUrlAction = function (url:String, target:String):void{ var url = url; var target = target; _tracker.trackEvent("preloader", "click", GamezheroGlobal.gameName); //unresolved jump var _slot1 = e; gotoActionIni(url, target); }; _obj_listener_preloader.finishAction = function (val:Object):void{ action(); }; dom = GamezheroGlobal.toText([102, 105, 108, 101, 115, 46, 103, 97, 109, 101, 122, 104, 101, 114, 111, 46, 99, 111, 109]); _recive_localconnection_preloader.allowInsecureDomain(dom); _recive_localconnection_preloader.allowDomain(dom); _recive_localconnection_preloader.client = _obj_listener_preloader; _recive_localconnection_preloader.connect(_recived_name_connection_preloader); //unresolved jump var _slot1 = e; beginScenario2(); _send_localconnection_preloader.allowInsecureDomain(dom); _send_localconnection_preloader.allowDomain(dom); } private function iniStage(event:Event=null):void{ var event = event; this.removeEventListener(Event.ENTER_FRAME, iniStage); getStageSettings(); iniStageSettings(); iniContextMenu(); iniStageEvents(); if (_debug_flag == false){ loadPreloaderSkin(); } else { beginScenario2(); }; //unresolved jump var _slot1 = e; _amount_try--; if (_amount_try <= 0){ beginScenario2(); } else { this.addEventListener(Event.ENTER_FRAME, iniStage); }; } private function getStageSettings():void{ _scale_old = stage.scaleMode; _align_old = stage.align; _rate_old = stage.frameRate; _quality_old = stage.quality; } private function gotoActionIni(url:String, target:String):void{ trace((((("gotoAction 1 " + url) + " ") + target) + " ")); _in_url = url; _in_target = target; gotoAction(); } private function getURLContextMenu(evt:ContextMenuEvent=null):void{ GamezheroGlobal.getURL(_urls[evt.target], "_blank"); } private function iniStageSettings():void{ stage.scaleMode = StageScaleMode.NO_SCALE; stage.align = StageAlign.TOP_LEFT; stage.frameRate = 20; stage.quality = StageQuality.HIGH; } private function clearEvents():void{ _par.loaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, ioErrorHandler); this.removeEventListener(Event.ENTER_FRAME, iniStage); _loader_preloader_skin.contentLoaderInfo.removeEventListener(Event.INIT, preloaderLoaderInit); _loader_preloader_skin.contentLoaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, preloaderLoaderError); _recive_localconnection_preloader.removeEventListener(StatusEvent.STATUS, onStatusRecivePreloader); _recive_localconnection_preloader.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorRecivePreloader); _recive_localconnection_preloader.client = {}; _recive_localconnection_preloader.close(); _recive_localconnection_preloader = new LocalConnection(); _send_localconnection_preloader.removeEventListener(StatusEvent.STATUS, onStatusSendPreloader); _send_localconnection_preloader.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorSendPreloader); _send_localconnection_preloader = new LocalConnection(); } private function loadPreloaderSkin():void{ var url:String; var request:URLRequest; url = (GamezheroGlobal.toText([104, 116, 116, 112, 58, 47, 47, 102, 105, 108, 101, 115, 46, 103, 97, 109, 101, 122, 104, 101, 114, 111, 46, 99, 111, 109, 47, 112, 114, 101, 108, 111, 97, 100, 101, 114, 47, 112, 114, 101, 108, 111, 97, 100, 101, 114, 95, 118, 49, 46, 115, 119, 102, 63, 103, 97, 109, 101, 122, 104, 101, 114, 111, 67, 111, 100, 101, 61]) + String(_gamezhero_code_preloader)); request = new URLRequest(url); _loader_preloader_skin.load(request); addChild(_loader_preloader_skin); //unresolved jump var _slot1 = e; beginScenario2(); } private function beginScenario1():void{ _preloader_active_flag = true; clearTimers(); _timer.addEventListener(TimerEvent.TIMER, updatePreloader1); _timer.start(); resizeAction(); } private function setStageSettings():void{ stage.scaleMode = _scale_old; stage.align = _align_old; stage.frameRate = _rate_old; stage.quality = _quality_old; } } }//package com.gamezhero.api.as3
Section 5
//GamezheroApi (com.gamezhero.api.as3.GamezheroApi) package com.gamezhero.api.as3 { import flash.events.*; import flash.display.*; import flash.system.*; public class GamezheroApi { private static var _score_continue_function:Function; private static var _preloader_next_step_function:Function; private static var _preloader_goal:MovieClip; private static var _score_submit_function:Function; private static var _score_error_function:Function; private static var _score_goal:MovieClip; public function GamezheroApi(){ super(); } private static function scoreSubmitAction(event:Event=null):void{ _score_submit_function.apply(); } public static function preloader(target:MovieClip, nextStep:Function):void{ var gamePreloader:GamePreloader; _preloader_goal = (target as MovieClip); _preloader_next_step_function = nextStep; if (GamezheroGlobal.gameName == "unset"){ trace("Error. GamezheroApi don't ini !"); } else { gamePreloader = new GamePreloader(_preloader_goal, {debug:false}); gamePreloader.addEventListener(GamePreloader.finish, preloaderNextStep); }; } public static function ini(gameName:String):void{ Security.allowDomain("www.gamezhero.com", "gamezhero.com", "files.gamezhero.com", "data.gamezhero.com", "*.gamezhero.com"); Security.allowInsecureDomain("www.gamezhero.com", "gamezhero.com", "files.gamezhero.com", "data.gamezhero.com", "*.gamezhero.com"); GamezheroGlobal.gameName = gameName; } private static function scoreErrorAction(event:Event=null):void{ _score_error_function.apply(); } public static function linkSendToFrined():void{ GamezheroGlobal.getURL((((((("http://www.gamezhero.com/sendtofriends/" + GamezheroGlobal.gameName) + "-games.html?utm_campaign=") + GamezheroGlobal.gameName) + "&utm_source=") + GamezheroGlobal.getDomain()) + "&utm_medium=send_to_friend"), "_blank"); } private static function scoreContinueAction(event:Event=null):void{ _score_continue_function.apply(); } public static function score(target:MovieClip, gameCode:String, scoreValue:Number, scoreX:Number, scoreY:Number, submitAction:Function, continueAction:Function, errorAction:Function, scoreSkin:Object=null):void{ var score_value:Number; var score_x_pos:Number; var score_y_pos:Number; var score_skin:Object; var scoreGamezheroForm:SubmitArea; GamezheroGlobal.gameCode = gameCode; _score_goal = (target as MovieClip); _score_submit_function = submitAction; _score_continue_function = continueAction; _score_error_function = errorAction; if (GamezheroGlobal.gameName == "unset"){ trace("Error. GamezheroApi don't ini !"); } else { score_value = scoreValue; score_x_pos = scoreX; score_y_pos = scoreY; score_skin = scoreSkin; if (score_skin == null){ score_skin = {border:{width:4, color:0xFFFFFF, alpha:100}, background:{topColor:0x999999, bottomColor:0x666666, topAlpha:100, bottomAlpha:100, cornerRadius:10}, language:"ENG"}; }; scoreGamezheroForm = new SubmitArea(_score_goal, score_x_pos, score_y_pos, score_value, score_skin); scoreGamezheroForm.addEventListener(SubmitArea.SUBMITED, scoreSubmitAction); scoreGamezheroForm.addEventListener(SubmitArea.CONTINUE, scoreContinueAction); scoreGamezheroForm.addEventListener(SubmitArea.ERROR, scoreErrorAction); }; } private static function preloaderNextStep(event:Event=null):void{ _preloader_next_step_function.apply(); } public static function linkTopScore():void{ GamezheroGlobal.getURL((((((("http://www.gamezhero.com/topscore/" + GamezheroGlobal.gameName) + "/top100.html?utm_campaign=") + GamezheroGlobal.gameName) + "&utm_source=") + GamezheroGlobal.getDomain()) + "&utm_medium=top_score"), "_blank"); } public static function linkMoreGames():void{ GamezheroGlobal.getURL((((("http://www.gamezhero.com/?utm_campaign=" + GamezheroGlobal.gameName) + "&utm_source=") + GamezheroGlobal.getDomain()) + "&utm_medium=more_free_games"), "_blank"); } public static function linkZorroLogo():void{ GamezheroGlobal.getURL((((("http://www.gamezhero.com/?utm_campaign=" + GamezheroGlobal.gameName) + "&utm_source=") + GamezheroGlobal.getDomain()) + "&utm_medium=zorro_logo"), "_blank"); } public static function linkPublish():void{ GamezheroGlobal.getURL((((((("http://www.gamezhero.com/freewebsitegames/" + GamezheroGlobal.gameName) + "-games.html?utm_campaign=") + GamezheroGlobal.gameName) + "&utm_source=") + GamezheroGlobal.getDomain()) + "&utm_medium=free_web_site_games"), "_blank"); } } }//package com.gamezhero.api.as3
Section 6
//GamezheroGlobal (com.gamezhero.api.as3.GamezheroGlobal) package com.gamezhero.api.as3 { import flash.display.*; import flash.net.*; import com.gamezhero.api.as3.utils.*; import flash.external.*; public class GamezheroGlobal { public static const SAFARI:String = "safari"; public static const FIREFOX:String = "firefox"; public static const CHROME:String = "chrome"; public static const IE:String = "ie"; public static const OPERA:String = "opera"; public static var gameNameVar:String = "unset"; public static var host:String = "error"; public static var browser:String = "unset"; public static var gameCodeVar:String = "unset"; public function GamezheroGlobal(){ super(); } public static function getDomain(stage:Stage=null):String{ var url:URL; var stage = stage; if (host != "error"){ return (host); }; url = new URL(stage.loaderInfo.url); host = url.host; if (url.host == null){ host = "local"; }; //unresolved jump var _slot1 = e; host = "error"; return (host); } public static function toText(arr:Array):String{ var st_url:String; var i:Number; st_url = ""; i = 0; while (i < arr.length) { st_url = (st_url + String.fromCharCode(arr[i])); i++; }; return (st_url); } public static function getURL(url:String, window:String):void{ var url_req:URLRequest; url_req = new URLRequest(url); navigateToURL(url_req, window); } public static function get gameName():String{ return (gameNameVar); } public static function getBrowser():String{ var st:String; if (browser == "unset"){ if (ExternalInterface.available){ st = ExternalInterface.call("function (){ return navigator['userAgent']}"); st = st.toLowerCase(); if (st.indexOf("firefox") != -1){ browser = FIREFOX; } else { if (st.indexOf("chrome") != -1){ browser = CHROME; } else { if (st.indexOf("safari") != -1){ browser = SAFARI; } else { if (st.indexOf("opera") != -1){ browser = OPERA; } else { browser = IE; }; }; }; }; //unresolved jump var _slot1 = e; browser = IE; } else { browser = IE; }; }; return (browser); } public static function set gameName(name:String):void{ gameNameVar = name; } public static function set gameCode(name:String):void{ gameCodeVar = name; } public static function get gameCode():String{ return (gameCodeVar); } } }//package com.gamezhero.api.as3
Section 7
//SubmitArea (com.gamezhero.api.as3.SubmitArea) package com.gamezhero.api.as3 { import flash.events.*; import flash.display.*; import flash.net.*; import flash.text.*; import flash.utils.*; import com.gamezhero.api.as3.gui.*; public class SubmitArea extends MovieClip { private var x_pos:Number;// = 0 private var loader_skin:Loader; private var skin_info:Object; private var sendLocalConnection_engine:LocalConnection; private var _indicator:Indicator; private var score:Number; private var engine_mc:MovieClip; private var gamezheroCode_engine:Number; private var sendNameConnection_engine:String; private var objListenerSkin:Object; private var _loader_url:String;// = "null" public var versionGame:String;// = "2.0" private var objListenerEngine:Object; private var reciveLocalConnection_engine:LocalConnection; private var infoText:TextField; private var goal:MovieClip; private var _loader:URLVariables; private var sendLocalConnection_skin:LocalConnection; private var recivedNameConnection_skin:String; private var score_value:Number;// = 0 private var sendNameConnection_skin:String; private var y_pos:Number;// = 0 private var skin_mc:MovieClip; private var reciveLocalConnection_skin:LocalConnection; private var recivedNameConnection_engine:String; private var gamezheroCode_skin:Number; private var loader_engine:Loader; public static const SUBMITED:String = "gamezhero_submited"; public static const CONTINUE:String = "gamezhero_continue"; public static const ERROR:String = "gamezhero_error"; public function SubmitArea(g:DisplayObject, x_:Number, y_:Number, score_:Number, skin_:Object){ versionGame = "2.0"; score_value = 0; x_pos = 0; y_pos = 0; reciveLocalConnection_skin = new LocalConnection(); sendLocalConnection_skin = new LocalConnection(); reciveLocalConnection_engine = new LocalConnection(); sendLocalConnection_engine = new LocalConnection(); loader_skin = new Loader(); loader_engine = new Loader(); objListenerSkin = new Object(); objListenerEngine = new Object(); _loader = new URLVariables(); _loader_url = "null"; super(); gamezheroCode_skin = new Date().getTime(); gamezheroCode_engine = gamezheroCode_skin; recivedNameConnection_skin = ("_send_gamezhero_skin_" + gamezheroCode_skin); sendNameConnection_skin = ("_recive_gamezhero_skin_" + gamezheroCode_skin); recivedNameConnection_engine = ("_send_gamezhero_engine_" + gamezheroCode_engine); sendNameConnection_engine = ("_recive_gamezhero_engine_" + gamezheroCode_engine); iniLocalConnectionsSkin(); iniLocalConnectionsEngine(); iniSubmitArea(g, x_, y_, score_, skin_); iniEvents(); } private function onStatusReciveEngine(infoObject:StatusEvent=null):void{ switch (infoObject.level){ case "status": break; case "error": infoText.text = "Error Connections 'Recive From Engine'"; break; }; } private function engineLoaderError(IOErrorEvent:Event=null):void{ infoText.text = "Error Loading Engine..."; errorAction(); } public function createInfoText():void{ var fontFormat:TextFormat; infoText = new TextField(); infoText.autoSize = TextFieldAutoSize.LEFT; fontFormat = new TextFormat(); fontFormat.color = 0xFFFFFF; fontFormat.size = 11; fontFormat.font = "Arial"; infoText.defaultTextFormat = fontFormat; this.addChild(infoText); infoText.x = 10; infoText.y = 10; infoText.visible = false; } private function iniEvents():void{ loader_skin.contentLoaderInfo.addEventListener(Event.INIT, skinLoaderInit); loader_skin.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, skinLoaderError); loader_engine.contentLoaderInfo.addEventListener(Event.INIT, engineLoaderInit); loader_engine.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, engineLoaderError); reciveLocalConnection_skin.addEventListener(StatusEvent.STATUS, onStatusReciveSkin); reciveLocalConnection_skin.addEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorReciveSkin); sendLocalConnection_skin.addEventListener(StatusEvent.STATUS, onStatusSendSkin); sendLocalConnection_skin.addEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorSendSkin); reciveLocalConnection_engine.addEventListener(StatusEvent.STATUS, onStatusReciveEngine); reciveLocalConnection_engine.addEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorReciveEngine); sendLocalConnection_engine.addEventListener(StatusEvent.STATUS, onStatusSendEngine); sendLocalConnection_engine.addEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorSendEngine); } private function onErrorReciveSkin(infoObject:SecurityErrorEvent=null):void{ errorAction(); } private function toText(arr:Array):String{ var st_url:String; var i:Number; st_url = ""; i = 0; while (i < arr.length) { st_url = (st_url + String.fromCharCode(arr[i])); i++; }; return (st_url); } public function errorAction():void{ diactivateAllEvents(); deleteAll(); dispatchEvent(new Event(ERROR)); } public function submitAction(username:String=""):void{ diactivateAllEvents(); deleteAll(); dispatchEvent(new Event(SUBMITED)); } private function onErrorSendEngine(infoObject:SecurityErrorEvent=null):void{ errorAction(); } private function diactivateAllEvents():void{ loader_skin.contentLoaderInfo.removeEventListener(Event.INIT, skinLoaderInit); loader_skin.contentLoaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, skinLoaderError); loader_engine.contentLoaderInfo.removeEventListener(Event.INIT, engineLoaderInit); loader_engine.contentLoaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, engineLoaderError); reciveLocalConnection_skin.removeEventListener(StatusEvent.STATUS, onStatusReciveSkin); reciveLocalConnection_skin.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorReciveSkin); sendLocalConnection_skin.removeEventListener(StatusEvent.STATUS, onStatusSendSkin); sendLocalConnection_skin.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorSendSkin); reciveLocalConnection_engine.removeEventListener(StatusEvent.STATUS, onStatusReciveEngine); reciveLocalConnection_engine.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorReciveEngine); sendLocalConnection_engine.removeEventListener(StatusEvent.STATUS, onStatusSendEngine); sendLocalConnection_engine.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, onErrorSendEngine); } private function checkSkin(event:TimerEvent=null):void{ sendLocalConnection_skin.send(sendNameConnection_skin, "skinIsOk"); } private function onErrorReciveEngine(infoObject:SecurityErrorEvent=null):void{ errorAction(); } private function sendScoreAction(event:MouseEvent=null):void{ var request:URLRequest; if (_loader_url != "null"){ request = new URLRequest(_loader_url); request.method = URLRequestMethod.POST; request.data = _loader; navigateToURL(request, "_blank"); _loader = new URLVariables(); _loader_url = "null"; submitAction(); }; } private function loadEngine():void{ var url:String; var request:URLRequest; infoText.text = "Loading Engine..."; url = (toText([104, 116, 116, 112, 58, 47, 47, 102, 105, 108, 101, 115, 46, 103, 97, 109, 101, 122, 104, 101, 114, 111, 46, 99, 111, 109, 47, 115, 99, 111, 114, 101, 47, 101, 110, 103, 105, 110, 101, 47, 101, 110, 103, 105, 110, 101, 95, 118, 49, 46, 115, 119, 102, 63, 103, 97, 109, 101, 122, 104, 101, 114, 111, 67, 111, 100, 101, 61]) + gamezheroCode_engine); request = new URLRequest(url); loader_engine.load(request); addChild(loader_engine); //unresolved jump var _slot1 = e; infoText.text = "Error Loading Engine..."; errorAction(); } private function iniLocalConnectionsEngine():void{ var dom:String; objListenerEngine = new Object(); objListenerEngine.engineOk = function ():void{ sendLocalConnection_engine.send(sendNameConnection_engine, "iniEngine", skin_info); infoText.text = "Engine Connections..."; }; objListenerEngine.engineError = function ():void{ infoText.text = "Error Engine..."; }; objListenerEngine.submitActionDone = function (obj:Object):void{ sendScore(obj); }; objListenerEngine.engineActivated = function ():void{ iniSkin(); }; dom = toText([102, 105, 108, 101, 115, 46, 103, 97, 109, 101, 122, 104, 101, 114, 111, 46, 99, 111, 109]); reciveLocalConnection_engine.allowDomain(dom); reciveLocalConnection_engine.allowInsecureDomain(dom); reciveLocalConnection_engine.client = objListenerEngine; reciveLocalConnection_engine.connect(recivedNameConnection_engine); sendLocalConnection_engine.allowDomain(dom); sendLocalConnection_engine.allowInsecureDomain(dom); } private function onStatusSendSkin(infoObject:StatusEvent=null):void{ switch (infoObject.level){ case "status": break; case "error": infoText.text = "Error Connections 'Send To Skin'"; break; }; } private function skinLoaderInit(event:Event=null):void{ var foo:Timer; infoText.text = "Check Skin Connection... "; foo = new Timer(200, 1); foo.addEventListener(TimerEvent.TIMER, checkSkin); foo.start(); } private function checkEngine(event:TimerEvent=null):void{ sendLocalConnection_engine.send(sendNameConnection_engine, "engineIsOk"); } private function moveAction(event:MouseEvent=null):void{ } private function onStatusSendEngine(infoObject:StatusEvent=null):void{ switch (infoObject.level){ case "status": break; case "error": infoText.text = "Error Connections 'Send To Engine'"; break; }; } private function onStatusReciveSkin(infoObject:StatusEvent=null):void{ switch (infoObject.level){ case "status": break; case "error": infoText.text = "Error Connections 'Recive From Skin'"; break; }; } private function iniSkin():void{ loader_skin.x = x_pos; loader_skin.y = y_pos; infoText.text = ""; _indicator.remove(); //unresolved jump var _slot1 = e; sendLocalConnection_skin.send(sendNameConnection_skin, "iniSkin", skin_info); } private function loadSkin():void{ var url:String; var request:URLRequest; infoText.text = "Loading Skin..."; url = (toText([104, 116, 116, 112, 58, 47, 47, 102, 105, 108, 101, 115, 46, 103, 97, 109, 101, 122, 104, 101, 114, 111, 46, 99, 111, 109, 47, 115, 99, 111, 114, 101, 47, 115, 107, 105, 110, 47, 115, 107, 105, 110, 95, 118, 49, 46, 115, 119, 102, 63, 103, 97, 109, 101, 122, 104, 101, 114, 111, 67, 111, 100, 101, 61]) + gamezheroCode_skin); request = new URLRequest(url); loader_skin.load(request); addChild(loader_skin); //unresolved jump var _slot1 = e; infoText.text = "Error Loading Skin..."; errorAction(); } private function iniLocalConnectionsSkin():void{ var dom:String; objListenerSkin = new Object(); objListenerSkin.skinOk = function ():void{ loadEngine(); }; objListenerSkin.submitAction = function (userName:String):void{ sendLocalConnection_engine.send(sendNameConnection_engine, toText([115, 101, 110, 100, 83, 99, 111, 114, 101]), userName); }; objListenerSkin.errorInputActin = function ():void{ }; objListenerSkin.continueAction = function ():void{ continueAction(); }; dom = toText([102, 105, 108, 101, 115, 46, 103, 97, 109, 101, 122, 104, 101, 114, 111, 46, 99, 111, 109]); reciveLocalConnection_skin.allowInsecureDomain(dom); reciveLocalConnection_skin.allowDomain(dom); reciveLocalConnection_skin.client = objListenerSkin; reciveLocalConnection_skin.connect(recivedNameConnection_skin); sendLocalConnection_skin.allowInsecureDomain(dom); sendLocalConnection_skin.allowDomain(dom); } private function engineLoaderInit(event:Event=null):void{ var foo:Timer; infoText.text = "Check Engine Connection..."; foo = new Timer(200, 1); foo.addEventListener(TimerEvent.TIMER, checkEngine); foo.start(); } private function onErrorSendSkin(infoObject:SecurityErrorEvent=null):void{ errorAction(); } public function continueAction():void{ diactivateAllEvents(); deleteAll(); dispatchEvent(new Event(CONTINUE)); } private function iniSubmitArea(g:DisplayObject, x_:Number, y_:Number, score_:Number, skin_:Object):void{ goal = (g as MovieClip); goal.addChild(this); x_pos = x_; y_pos = y_; score_value = Math.abs(Math.round(score_)); skin_info = skin_; skin_info.score = score_value; skin_info.gameName = GamezheroGlobal.gameName; skin_info.gameCode = GamezheroGlobal.gameCode; skin_info.domain = GamezheroGlobal.getDomain(goal.stage); _indicator = new Indicator(goal); _indicator.setSize(50, 50); _indicator.setPos(30, 30); createInfoText(); loadSkin(); } private function sendScore(obj:Object):void{ var i:String; _loader = new URLVariables(); _loader_url = obj.url; for (i in obj.vars) { _loader[i] = obj.vars[i]; }; sendScoreAction(); } private function fromText(txt:String):Array{ var arr:Array; var i:Number; arr = new Array(); i = 0; while (i < txt.length) { arr.push(txt.charCodeAt(i)); i++; }; return (arr); } private function skinLoaderError(IOErrorEvent:Event=null):void{ infoText.text = "Error Loading Skin..."; errorAction(); } private function deleteAll():void{ this.removeChild(infoText); //unresolved jump var _slot1 = e; this.removeChild(loader_skin); //unresolved jump var _slot1 = e; this.removeChild(loader_engine); //unresolved jump var _slot1 = e; _indicator.remove(); //unresolved jump var _slot1 = e; goal.removeChild(this); //unresolved jump var _slot1 = e; } } }//package com.gamezhero.api.as3
Section 8
//UserInfo (com.gamezhero.api.as3.UserInfo) package com.gamezhero.api.as3 { import flash.display.*; import flash.system.*; import flash.external.*; public class UserInfo { public var flash_domain:String; private var _stage:Stage; public var ad_zone:String;// = "preloader" public var flash_height:Number; public var flash_vars:Object; public var referrer:String; public var flash_url:String; public var browser:String; public var href:String; private var _goal:MovieClip; public var flash_width:Number; public var api_version:String;// = "AS3 - v3.0" public var publisher:String;// = "gamezhero" public var capabilities:String; public var game_name:String; public function UserInfo(g:MovieClip){ var g = g; publisher = "gamezhero"; ad_zone = "preloader"; api_version = "AS3 - v3.0"; _goal = g; _stage = _goal.stage; //unresolved jump var _slot1 = e; super(); iniInfo(); } private function iniInfo():void{ var i:String; this["publisher"] = "gamezhero"; this["ad_zone"] = "preloader"; this["api_version"] = "AS3 - v3.0"; this["flash_vars"] = new Object(); this["capabilities"] = Capabilities.serverString; if (ExternalInterface.available){ this["href"] = ExternalInterface.call("function (){return document.location.href}"); //unresolved jump var _slot1 = e; this["href"] = "-1"; this["browser"] = ExternalInterface.call("function (){var st = ''; for (i in navigator){ if (typeof(navigator[i])!='function'){ st+=i+'='+navigator[i]+'&'; }} return st}"); //unresolved jump var _slot1 = e; this["browser"] = "-1"; this["referrer"] = ExternalInterface.call("function (){return document.referrer}"); //unresolved jump var _slot1 = e; this["referrer"] = "-1"; } else { this["href"] = "-1"; this["browser"] = "-1"; this["referrer"] = "-1"; }; this["game_name"] = GamezheroGlobal.gameName; this["flash_domain"] = GamezheroGlobal.getDomain(); this["flash_width"] = _stage.stageWidth; this["flash_height"] = _stage.stageHeight; this["flash_url"] = _stage.root.loaderInfo.url; //unresolved jump var _slot1 = e; for (i in _stage.root.loaderInfo.parameters) { this["flash_vars"][i] = _stage.root.loaderInfo.parameters[i]; }; //unresolved jump var _slot1 = e; } } }//package com.gamezhero.api.as3
Section 9
//CampaignInfo (com.google.analytics.campaign.CampaignInfo) package com.google.analytics.campaign { import com.google.analytics.utils.*; public class CampaignInfo { private var _new:Boolean; private var _empty:Boolean; public function CampaignInfo(empty:Boolean=true, newCampaign:Boolean=false){ super(); _empty = empty; _new = newCampaign; } public function isEmpty():Boolean{ return (_empty); } public function toURLString():String{ var v:Variables; v = toVariables(); return (v.toString()); } public function toVariables():Variables{ var variables:Variables; variables = new Variables(); variables.URIencode = true; if (((!(isEmpty())) && (isNew()))){ variables.utmcn = utmcn; }; if (((!(isEmpty())) && (!(isNew())))){ variables.utmcr = utmcr; }; return (variables); } public function isNew():Boolean{ return (_new); } public function get utmcn():String{ return ("1"); } public function get utmcr():String{ return ("1"); } } }//package com.google.analytics.campaign
Section 10
//CampaignKey (com.google.analytics.campaign.CampaignKey) package com.google.analytics.campaign { public class CampaignKey { public var UCMD:String;// = "utm_medium" public var UCID:String;// = "utm_id" public var UCTR:String;// = "utm_term" public var UCSR:String;// = "utm_source" public var UCNO:String;// = "utm_nooverride" public var UCCN:String;// = "utm_campaign" public var UGCLID:String;// = "gclid" public var UCCT:String;// = "utm_content" public function CampaignKey(){ UCCN = "utm_campaign"; UCCT = "utm_content"; UCID = "utm_id"; UCMD = "utm_medium"; UCNO = "utm_nooverride"; UCSR = "utm_source"; UCTR = "utm_term"; UGCLID = "gclid"; super(); } } }//package com.google.analytics.campaign
Section 11
//CampaignManager (com.google.analytics.campaign.CampaignManager) package com.google.analytics.campaign { import com.google.analytics.core.*; import com.google.analytics.v4.*; import com.google.analytics.debug.*; import com.google.analytics.utils.*; public class CampaignManager { private var _config:Configuration; private var _domainHash:Number; private var _debug:DebugConfiguration; private var _timeStamp:Number; private var _referrer:String; private var _buffer:Buffer; public static const trackingDelimiter:String = "|"; public function CampaignManager(config:Configuration, debug:DebugConfiguration, buffer:Buffer, domainHash:Number, referrer:String, timeStamp:Number){ super(); _config = config; _debug = debug; _buffer = buffer; _domainHash = domainHash; _referrer = referrer; _timeStamp = timeStamp; } public function hasNoOverride(search:String):Boolean{ var key:CampaignKey; var variables:Variables; var value:String; key = _config.campaignKey; if (search == ""){ return (false); }; variables = new Variables(search); value = ""; if (variables.hasOwnProperty(key.UCNO)){ value = variables[key.UCNO]; switch (value){ case "1": return (true); case "": case "0": default: return (false); }; }; return (false); } public function getCampaignInformation(search:String, noSessionInformation:Boolean):CampaignInfo{ var campInfo:CampaignInfo; var campaignTracker:CampaignTracker; var duplicateCampaign:Boolean; var campNoOverride:Boolean; var responseCount:int; var oldTracker:CampaignTracker; var sessionCount:int; campInfo = new CampaignInfo(); duplicateCampaign = false; campNoOverride = false; responseCount = 0; if (((_config.allowLinker) && (_buffer.isGenuine()))){ if (!_buffer.hasUTMZ()){ return (campInfo); }; }; campaignTracker = getTrackerFromSearchString(search); if (isValid(campaignTracker)){ campNoOverride = hasNoOverride(search); if (((campNoOverride) && (!(_buffer.hasUTMZ())))){ return (campInfo); }; }; if (!isValid(campaignTracker)){ campaignTracker = getOrganicCampaign(); if (((!(_buffer.hasUTMZ())) && (isIgnoredKeyword(campaignTracker)))){ return (campInfo); }; }; if (((!(isValid(campaignTracker))) && (noSessionInformation))){ campaignTracker = getReferrerCampaign(); if (((!(_buffer.hasUTMZ())) && (isIgnoredReferral(campaignTracker)))){ return (campInfo); }; }; if (!isValid(campaignTracker)){ if (((!(_buffer.hasUTMZ())) && (noSessionInformation))){ campaignTracker = getDirectCampaign(); }; }; if (!isValid(campaignTracker)){ return (campInfo); }; if (((_buffer.hasUTMZ()) && (!(_buffer.utmz.isEmpty())))){ oldTracker = new CampaignTracker(); oldTracker.fromTrackerString(_buffer.utmz.campaignTracking); duplicateCampaign = (oldTracker.toTrackerString() == campaignTracker.toTrackerString()); responseCount = _buffer.utmz.responseCount; }; if (((!(duplicateCampaign)) || (noSessionInformation))){ sessionCount = _buffer.utma.sessionCount; responseCount++; if (sessionCount == 0){ sessionCount = 1; }; _buffer.utmz.domainHash = _domainHash; _buffer.utmz.campaignCreation = _timeStamp; _buffer.utmz.campaignSessions = sessionCount; _buffer.utmz.responseCount = responseCount; _buffer.utmz.campaignTracking = campaignTracker.toTrackerString(); _debug.info(_buffer.utmz.toString(), VisualDebugMode.geek); campInfo = new CampaignInfo(false, true); } else { campInfo = new CampaignInfo(false, false); }; return (campInfo); } public function isValid(tracker:CampaignTracker):Boolean{ if (((tracker) && (tracker.isValid()))){ return (true); }; return (false); } public function getTrackerFromSearchString(search:String):CampaignTracker{ var organicCampaign:CampaignTracker; var camp:CampaignTracker; var key:CampaignKey; var variables:Variables; organicCampaign = getOrganicCampaign(); camp = new CampaignTracker(); key = _config.campaignKey; if (search == ""){ return (camp); }; variables = new Variables(search); if (variables.hasOwnProperty(key.UCID)){ camp.id = variables[key.UCID]; }; if (variables.hasOwnProperty(key.UCSR)){ camp.source = variables[key.UCSR]; }; if (variables.hasOwnProperty(key.UGCLID)){ camp.clickId = variables[key.UGCLID]; }; if (variables.hasOwnProperty(key.UCCN)){ camp.name = variables[key.UCCN]; } else { camp.name = "(not set)"; }; if (variables.hasOwnProperty(key.UCMD)){ camp.medium = variables[key.UCMD]; } else { camp.medium = "(not set)"; }; if (variables.hasOwnProperty(key.UCTR)){ camp.term = variables[key.UCTR]; } else { if (((organicCampaign) && (!((organicCampaign.term == ""))))){ camp.term = organicCampaign.term; }; }; if (variables.hasOwnProperty(key.UCCT)){ camp.content = variables[key.UCCT]; }; return (camp); } public function getOrganicCampaign():CampaignTracker{ var camp:CampaignTracker; var ref:URL; var name:String; var tmp:Array; var currentOrganicSource:OrganicReferrer; var keyword:String; if (((isInvalidReferrer(_referrer)) || (isFromGoogleCSE(_referrer, _config)))){ return (camp); }; ref = new URL(_referrer); name = ""; if (ref.hostName != ""){ if (ref.hostName.indexOf(".") > -1){ tmp = ref.hostName.split("."); switch (tmp.length){ case 2: name = tmp[0]; break; case 3: name = tmp[1]; break; }; }; }; if (_config.organic.match(name)){ currentOrganicSource = _config.organic.getReferrerByName(name); keyword = _config.organic.getKeywordValue(currentOrganicSource, ref.search); camp = new CampaignTracker(); camp.source = currentOrganicSource.engine; camp.name = "(organic)"; camp.medium = "organic"; camp.term = keyword; }; return (camp); } public function isIgnoredReferral(tracker:CampaignTracker):Boolean{ if (((tracker) && ((tracker.medium == "referral")))){ return (_config.organic.isIgnoredReferral(tracker.source)); }; return (false); } public function getDirectCampaign():CampaignTracker{ var camp:CampaignTracker; camp = new CampaignTracker(); camp.source = "(direct)"; camp.name = "(direct)"; camp.medium = "(none)"; return (camp); } public function isIgnoredKeyword(tracker:CampaignTracker):Boolean{ if (((tracker) && ((tracker.medium == "organic")))){ return (_config.organic.isIgnoredKeyword(tracker.term)); }; return (false); } public function getReferrerCampaign():CampaignTracker{ var camp:CampaignTracker; var ref:URL; var hostname:String; var content:String; if (((isInvalidReferrer(_referrer)) || (isFromGoogleCSE(_referrer, _config)))){ return (camp); }; ref = new URL(_referrer); hostname = ref.hostName; content = ref.path; if (hostname.indexOf("www.") == 0){ hostname = hostname.substr(4); }; camp = new CampaignTracker(); camp.source = hostname; camp.name = "(referral)"; camp.medium = "referral"; camp.content = content; return (camp); } public static function isInvalidReferrer(referrer:String):Boolean{ var url:URL; if ((((((referrer == "")) || ((referrer == "-")))) || ((referrer == "0")))){ return (true); }; if (referrer.indexOf("://") > -1){ url = new URL(referrer); if ((((url.protocol == Protocols.file)) || ((url.protocol == Protocols.none)))){ return (true); }; }; return (false); } public static function isFromGoogleCSE(referrer:String, config:Configuration):Boolean{ var url:URL; url = new URL(referrer); if (url.hostName.indexOf(config.google) > -1){ if (url.search.indexOf((config.googleSearchParam + "=")) > -1){ if (url.path == ("/" + config.googleCsePath)){ return (true); }; }; }; return (false); } } }//package com.google.analytics.campaign
Section 12
//CampaignTracker (com.google.analytics.campaign.CampaignTracker) package com.google.analytics.campaign { import com.google.analytics.utils.*; public class CampaignTracker { public var content:String; public var id:String; public var clickId:String; public var name:String; public var term:String; public var medium:String; public var source:String; public function CampaignTracker(id:String="", source:String="", clickId:String="", name:String="", medium:String="", term:String="", content:String=""){ super(); this.id = id; this.source = source; this.clickId = clickId; this.name = name; this.medium = medium; this.term = term; this.content = content; } public function toTrackerString():String{ var data:Array; data = []; _addIfNotEmpty(data, "utmcid=", id); _addIfNotEmpty(data, "utmcsr=", source); _addIfNotEmpty(data, "utmgclid=", clickId); _addIfNotEmpty(data, "utmccn=", name); _addIfNotEmpty(data, "utmcmd=", medium); _addIfNotEmpty(data, "utmctr=", term); _addIfNotEmpty(data, "utmcct=", content); return (data.join(CampaignManager.trackingDelimiter)); } public function isValid():Boolean{ if (((((!((id == ""))) || (!((source == ""))))) || (!((clickId == ""))))){ return (true); }; return (false); } private function _addIfNotEmpty(arr:Array, field:String, value:String):void{ if (value != ""){ value = value.split("+").join("%20"); value = value.split(" ").join("%20"); arr.push((field + value)); }; } public function fromTrackerString(tracker:String):void{ var data:String; var vars:Variables; data = tracker.split(CampaignManager.trackingDelimiter).join("&"); vars = new Variables(data); if (vars.hasOwnProperty("utmcid")){ this.id = vars["utmcid"]; }; if (vars.hasOwnProperty("utmcsr")){ this.source = vars["utmcsr"]; }; if (vars.hasOwnProperty("utmccn")){ this.name = vars["utmccn"]; }; if (vars.hasOwnProperty("utmcmd")){ this.medium = vars["utmcmd"]; }; if (vars.hasOwnProperty("utmctr")){ this.term = vars["utmctr"]; }; if (vars.hasOwnProperty("utmcct")){ this.content = vars["utmcct"]; }; if (vars.hasOwnProperty("utmgclid")){ this.clickId = vars["utmgclid"]; }; } } }//package com.google.analytics.campaign
Section 13
//BrowserInfo (com.google.analytics.core.BrowserInfo) package com.google.analytics.core { import com.google.analytics.v4.*; import com.google.analytics.utils.*; public class BrowserInfo { private var _config:Configuration; private var _info:Environment; public function BrowserInfo(config:Configuration, info:Environment){ super(); _config = config; _info = info; } public function get utmul():String{ return (_info.language.toLowerCase()); } public function get utmje():String{ return ("0"); } public function toURLString():String{ var v:Variables; v = toVariables(); return (v.toString()); } public function get utmsr():String{ return (((_info.screenWidth + "x") + _info.screenHeight)); } public function get utmcs():String{ return (_info.languageEncoding); } public function get utmfl():String{ var v:Version; if (_config.detectFlash){ v = _info.flashVersion; return (((((v.major + ".") + v.minor) + " r") + v.build)); }; return ("-"); } public function toVariables():Variables{ var variables:Variables; variables = new Variables(); variables.URIencode = true; variables.utmcs = utmcs; variables.utmsr = utmsr; variables.utmsc = utmsc; variables.utmul = utmul; variables.utmje = utmje; variables.utmfl = utmfl; return (variables); } public function get utmsc():String{ return ((_info.screenColorDepth + "-bit")); } } }//package com.google.analytics.core
Section 14
//Buffer (com.google.analytics.core.Buffer) package com.google.analytics.core { import flash.events.*; import com.google.analytics.v4.*; import com.google.analytics.debug.*; import flash.net.*; import com.google.analytics.data.*; public dynamic class Buffer { private var _volatile:Boolean; private var _data:Object; private var _OBJ:Object; private var _utmb:UTMB; private var _utmc:UTMC; private var _utma:UTMA; private var _debug:DebugConfiguration; private var _utmk:UTMK; private var _config:Configuration; private var _utmv:UTMV; private var _utmx:UTMX; private var _utmz:UTMZ; private var _SO:SharedObject; public function Buffer(config:Configuration, debug:DebugConfiguration, volatile:Boolean=false, data:Object=null){ var prop:String; super(); _config = config; _debug = debug; _data = data; _volatile = volatile; if (_volatile){ _OBJ = new Object(); if (_data){ for (prop in _data) { _OBJ[prop] = _data[prop]; }; }; }; } public function save():void{ var flushStatus:String; if (!isVolatile()){ flushStatus = null; flushStatus = _SO.flush(); //unresolved jump var _slot1 = e; _debug.warning("Error...Could not write SharedObject to disk"); switch (flushStatus){ case SharedObjectFlushStatus.PENDING: _debug.info("Requesting permission to save object..."); _SO.addEventListener(NetStatusEvent.NET_STATUS, _onFlushStatus); break; case SharedObjectFlushStatus.FLUSHED: _debug.info("Value flushed to disk."); break; }; }; } public function get utmv():UTMV{ if (!hasUTMV()){ _createUMTV(); }; return (_utmv); } public function get utmx():UTMX{ if (!hasUTMX()){ _createUMTX(); }; return (_utmx); } public function get utmz():UTMZ{ if (!hasUTMZ()){ _createUMTZ(); }; return (_utmz); } public function hasUTMA():Boolean{ if (_utma){ return (true); }; return (false); } public function hasUTMB():Boolean{ if (_utmb){ return (true); }; return (false); } public function clearCookies():void{ utma.reset(); utmb.reset(); utmc.reset(); utmz.reset(); utmv.reset(); utmk.reset(); } public function resetCurrentSession():void{ _clearUTMB(); _clearUTMC(); save(); } public function hasUTMC():Boolean{ if (_utmc){ return (true); }; return (false); } public function hasUTMK():Boolean{ if (_utmk){ return (true); }; return (false); } public function getLinkerUrl(targetUrl:String="", useHash:Boolean=false):String{ var linkerParams:String; var formattedUrl:String; var urlFields:Array; linkerParams = toLinkerParams(); formattedUrl = targetUrl; urlFields = targetUrl.split("#"); if (linkerParams){ if (useHash){ if (1 >= urlFields.length){ formattedUrl = (formattedUrl + ("#" + linkerParams)); } else { formattedUrl = (formattedUrl + ("&" + linkerParams)); }; } else { if (1 >= urlFields.length){ if (targetUrl.indexOf("?") > -1){ formattedUrl = (formattedUrl + "&"); } else { formattedUrl = (formattedUrl + "?"); }; formattedUrl = (formattedUrl + linkerParams); } else { formattedUrl = urlFields[0]; if (targetUrl.indexOf("?") > -1){ formattedUrl = (formattedUrl + "&"); } else { formattedUrl = (formattedUrl + "?"); }; formattedUrl = (formattedUrl + ((linkerParams + "#") + urlFields[1])); }; }; }; return (formattedUrl); } public function generateCookiesHash():Number{ var value:String; value = ""; value = (value + utma.valueOf()); value = (value + utmb.valueOf()); value = (value + utmc.valueOf()); value = (value + utmx.valueOf()); value = (value + utmz.valueOf()); value = (value + utmv.valueOf()); return (Utils.generateHash(value)); } private function _createUMTA():void{ _utma = new UTMA(); _utma.proxy = this; } private function _createUMTB():void{ _utmb = new UTMB(); _utmb.proxy = this; } private function _createUMTC():void{ _utmc = new UTMC(); } public function hasUTMV():Boolean{ if (_utmv){ return (true); }; return (false); } private function _createUMTK():void{ _utmk = new UTMK(); _utmk.proxy = this; } public function hasUTMX():Boolean{ if (_utmx){ return (true); }; return (false); } public function hasUTMZ():Boolean{ if (_utmz){ return (true); }; return (false); } private function _createUMTV():void{ _utmv = new UTMV(); _utmv.proxy = this; } private function _createUMTX():void{ _utmx = new UTMX(); _utmx.proxy = this; } private function _createUMTZ():void{ _utmz = new UTMZ(); _utmz.proxy = this; } public function updateUTMA(timestamp:Number):void{ if (_debug.verbose){ _debug.info((("updateUTMA( " + timestamp) + " )"), VisualDebugMode.advanced); }; if (!utma.isEmpty()){ if (isNaN(utma.sessionCount)){ utma.sessionCount = 1; } else { utma.sessionCount = (utma.sessionCount + 1); }; utma.lastTime = utma.currentTime; utma.currentTime = timestamp; }; } public function isGenuine():Boolean{ if (!hasUTMK()){ return (true); }; return ((utmk.hash == generateCookiesHash())); } private function _onFlushStatus(event:NetStatusEvent):void{ _debug.info("User closed permission dialog..."); switch (event.info.code){ case "SharedObject.Flush.Success": _debug.info("User granted permission -- value saved."); break; case "SharedObject.Flush.Failed": _debug.info("User denied permission -- value not saved."); break; }; _SO.removeEventListener(NetStatusEvent.NET_STATUS, _onFlushStatus); } public function toLinkerParams():String{ var output:String; output = ""; output = (output + utma.toURLString()); output = (output + ("&" + utmb.toURLString())); output = (output + ("&" + utmc.toURLString())); output = (output + ("&" + utmx.toURLString())); output = (output + ("&" + utmz.toURLString())); output = (output + ("&" + utmv.toURLString())); output = (output + ("&__utmk=" + generateCookiesHash())); return (output); } private function _clearUTMA():void{ _utma = null; if (!isVolatile()){ _SO.data.utma = null; delete _SO.data.utma; }; } private function _clearUTMC():void{ _utmc = null; } private function _clearUTMB():void{ _utmb = null; if (!isVolatile()){ _SO.data.utmb = null; delete _SO.data.utmb; }; } public function update(name:String, value):void{ if (isVolatile()){ _OBJ[name] = value; } else { _SO.data[name] = value; }; } public function createSO():void{ var saveSO:Boolean; UTMZ.defaultTimespan = _config.conversionTimeout; UTMB.defaultTimespan = _config.sessionTimeout; if (!_volatile){ _SO = SharedObject.getLocal(_config.cookieName, _config.cookiePath); //unresolved jump var _slot1 = e; if (_debug.active){ _debug.warning(((("Shared Object " + _config.cookieName) + " failed to be set\nreason: ") + _slot1.message)); }; saveSO = false; if (_SO.data.utma){ if (!hasUTMA()){ _createUMTA(); }; _utma.fromSharedObject(_SO.data.utma); if (_debug.verbose){ _debug.info(("found: " + _utma.toString(true)), VisualDebugMode.geek); }; if (_utma.isExpired()){ if (_debug.verbose){ _debug.warning("UTMA has expired", VisualDebugMode.advanced); }; _clearUTMA(); saveSO = true; }; }; if (_SO.data.utmb){ if (!hasUTMB()){ _createUMTB(); }; _utmb.fromSharedObject(_SO.data.utmb); if (_debug.verbose){ _debug.info(("found: " + _utmb.toString(true)), VisualDebugMode.geek); }; if (_utmb.isExpired()){ if (_debug.verbose){ _debug.warning("UTMB has expired", VisualDebugMode.advanced); }; _clearUTMB(); saveSO = true; }; }; if (_SO.data.utmc){ delete _SO.data.utmc; saveSO = true; }; if (_SO.data.utmk){ if (!hasUTMK()){ _createUMTK(); }; _utmk.fromSharedObject(_SO.data.utmk); if (_debug.verbose){ _debug.info(("found: " + _utmk.toString()), VisualDebugMode.geek); }; }; if (!hasUTMX()){ _createUMTX(); }; if (_SO.data.utmv){ if (!hasUTMV()){ _createUMTV(); }; _utmv.fromSharedObject(_SO.data.utmv); if (_debug.verbose){ _debug.info(("found: " + _utmv.toString(true)), VisualDebugMode.geek); }; if (_utmv.isExpired()){ if (_debug.verbose){ _debug.warning("UTMV has expired", VisualDebugMode.advanced); }; _clearUTMV(); saveSO = true; }; }; if (_SO.data.utmz){ if (!hasUTMZ()){ _createUMTZ(); }; _utmz.fromSharedObject(_SO.data.utmz); if (_debug.verbose){ _debug.info(("found: " + _utmz.toString(true)), VisualDebugMode.geek); }; if (_utmz.isExpired()){ if (_debug.verbose){ _debug.warning("UTMZ has expired", VisualDebugMode.advanced); }; _clearUTMZ(); saveSO = true; }; }; if (saveSO){ save(); }; }; } private function _clearUTMZ():void{ _utmz = null; if (!isVolatile()){ _SO.data.utmz = null; delete _SO.data.utmz; }; } private function _clearUTMV():void{ _utmv = null; if (!isVolatile()){ _SO.data.utmv = null; delete _SO.data.utmv; }; } public function isVolatile():Boolean{ return (_volatile); } public function get utma():UTMA{ if (!hasUTMA()){ _createUMTA(); }; return (_utma); } public function get utmb():UTMB{ if (!hasUTMB()){ _createUMTB(); }; return (_utmb); } public function get utmc():UTMC{ if (!hasUTMC()){ _createUMTC(); }; return (_utmc); } public function get utmk():UTMK{ if (!hasUTMK()){ _createUMTK(); }; return (_utmk); } } }//package com.google.analytics.core
Section 15
//DocumentInfo (com.google.analytics.core.DocumentInfo) package com.google.analytics.core { import com.google.analytics.v4.*; import com.google.analytics.utils.*; import com.google.analytics.external.*; public class DocumentInfo { private var _config:Configuration; private var _utmr:String; private var _adSense:AdSenseGlobals; private var _info:Environment; private var _pageURL:String; public function DocumentInfo(config:Configuration, info:Environment, formatedReferrer:String, pageURL:String=null, adSense:AdSenseGlobals=null){ super(); _config = config; _info = info; _utmr = formatedReferrer; _pageURL = pageURL; _adSense = adSense; } public function get utmr():String{ if (!_utmr){ return ("-"); }; return (_utmr); } public function toURLString():String{ var v:Variables; v = toVariables(); return (v.toString()); } private function _renderPageURL(pageURL:String=""):String{ var pathname:String; var search:String; pathname = _info.locationPath; search = _info.locationSearch; if (((!(pageURL)) || ((pageURL == "")))){ pageURL = (pathname + unescape(search)); if (pageURL == ""){ pageURL = "/"; }; }; return (pageURL); } public function get utmp():String{ return (_renderPageURL(_pageURL)); } private function _generateHitId():Number{ var hid:Number; if (((_adSense.hid) && (!((_adSense.hid == ""))))){ hid = Number(_adSense.hid); } else { hid = Math.round((Math.random() * 2147483647)); _adSense.hid = String(hid); }; return (hid); } public function get utmhid():String{ return (String(_generateHitId())); } public function toVariables():Variables{ var variables:Variables; variables = new Variables(); variables.URIencode = true; if (((_config.detectTitle) && (!((utmdt == ""))))){ variables.utmdt = utmdt; }; variables.utmhid = utmhid; variables.utmr = utmr; variables.utmp = utmp; return (variables); } public function get utmdt():String{ return (_info.documentTitle); } } }//package com.google.analytics.core
Section 16
//Domain (com.google.analytics.core.Domain) package com.google.analytics.core { import com.google.analytics.debug.*; public class Domain { private var _mode:DomainNameMode; private var _name:String; private var _debug:DebugConfiguration; public function Domain(mode:DomainNameMode=null, name:String="", debug:DebugConfiguration=null){ super(); _debug = debug; if (mode == null){ mode = DomainNameMode.auto; }; _mode = mode; if (mode == DomainNameMode.custom){ this.name = name; } else { _name = name; }; } public function get mode():DomainNameMode{ return (_mode); } public function set mode(value:DomainNameMode):void{ _mode = value; if (_mode == DomainNameMode.none){ _name = ""; }; } public function get name():String{ return (_name); } public function set name(value:String):void{ if (((!((value.charAt(0) == "."))) && (_debug))){ _debug.warning(("missing leading period \".\", cookie will only be accessible on " + value), VisualDebugMode.geek); }; _name = value; } } }//package com.google.analytics.core
Section 17
//DomainNameMode (com.google.analytics.core.DomainNameMode) package com.google.analytics.core { public class DomainNameMode { private var _value:int; private var _name:String; public static const custom:DomainNameMode = new DomainNameMode(2, "custom"); ; public static const none:DomainNameMode = new DomainNameMode(0, "none"); ; public static const auto:DomainNameMode = new DomainNameMode(1, "auto"); ; public function DomainNameMode(value:int=0, name:String=""){ super(); _value = value; _name = name; } public function valueOf():int{ return (_value); } public function toString():String{ return (_name); } } }//package com.google.analytics.core
Section 18
//Ecommerce (com.google.analytics.core.Ecommerce) package com.google.analytics.core { import com.google.analytics.debug.*; import com.google.analytics.ecommerce.*; public class Ecommerce { private var _debug:DebugConfiguration; private var _trans:Array; public function Ecommerce(debug:DebugConfiguration){ super(); this._debug = debug; _trans = new Array(); } public function getTransaction(orderId:String):Transaction{ var i:Number; i = 0; while (i < _trans.length) { if (_trans[i].id == orderId){ return (_trans[i]); }; i++; }; return (null); } public function getTransLength():Number{ return (_trans.length); } public function getTransFromArray(i:Number):Transaction{ return (_trans[i]); } public function addTransaction(id:String, affiliation:String, total:String, tax:String, shipping:String, city:String, state:String, country:String):Transaction{ var newTrans:Transaction; newTrans = getTransaction(id); if (newTrans == null){ newTrans = new Transaction(id, affiliation, total, tax, shipping, city, state, country); _trans.push(newTrans); } else { newTrans.affiliation = affiliation; newTrans.total = total; newTrans.tax = tax; newTrans.shipping = shipping; newTrans.city = city; newTrans.state = state; newTrans.country = country; }; return (newTrans); } } }//package com.google.analytics.core
Section 19
//EventInfo (com.google.analytics.core.EventInfo) package com.google.analytics.core { import com.google.analytics.utils.*; import com.google.analytics.data.*; public class EventInfo { private var _isEventHit:Boolean; private var _ext10:X10; private var _x10:X10; public function EventInfo(isEventHit:Boolean, xObject:X10, extObject:X10=null){ super(); _isEventHit = isEventHit; _x10 = xObject; _ext10 = extObject; } public function toURLString():String{ var v:Variables; v = toVariables(); return (v.toString()); } public function get utmt():String{ return ("event"); } public function get utme():String{ return (_x10.renderMergedUrlString(_ext10)); } public function toVariables():Variables{ var variables:Variables; variables = new Variables(); variables.URIencode = true; if (_isEventHit){ variables.utmt = utmt; }; variables.utme = utme; return (variables); } } }//package com.google.analytics.core
Section 20
//EventTracker (com.google.analytics.core.EventTracker) package com.google.analytics.core { import com.google.analytics.v4.*; public class EventTracker { private var _parent:GoogleAnalyticsAPI; public var name:String; public function EventTracker(name:String, parent:GoogleAnalyticsAPI){ super(); this.name = name; _parent = parent; } public function trackEvent(action:String, label:String=null, value:Number=NaN):Boolean{ return (_parent.trackEvent(name, action, label, value)); } } }//package com.google.analytics.core
Section 21
//ga_internal (com.google.analytics.core.ga_internal) package com.google.analytics.core { public namespace ga_internal; }//package com.google.analytics.core
Section 22
//GIFRequest (com.google.analytics.core.GIFRequest) package com.google.analytics.core { import flash.events.*; import flash.display.*; import com.google.analytics.v4.*; import com.google.analytics.debug.*; import flash.net.*; import com.google.analytics.utils.*; import flash.system.*; public class GIFRequest { private var _info:Environment; private var _count:int; private var _utmac:String; private var _alertcount:int; private var _debug:DebugConfiguration; private var _lastRequest:URLRequest; private var _buffer:Buffer; private var _config:Configuration; private var _requests:Array; public function GIFRequest(config:Configuration, debug:DebugConfiguration, buffer:Buffer, info:Environment){ super(); _config = config; _debug = debug; _buffer = buffer; _info = info; _count = 0; _alertcount = 0; _requests = []; } public function get utmn():String{ return ((Utils.generate32bitRandom() as String)); } public function onIOError(event:IOErrorEvent):void{ var url:String; var id:String; var msg:String; url = _lastRequest.url; id = String((_requests.length - 1)); msg = (("Gif Request #" + id) + " failed"); if (_debug.GIFRequests){ if (!_debug.verbose){ if (url.indexOf("?") > -1){ url = url.split("?")[0]; }; url = _shortenURL(url); }; if (int(_debug.mode) > int(VisualDebugMode.basic)){ msg = (msg + ((" \"" + url) + "\" does not exists or is unreachable")); }; _debug.failure(msg); } else { _debug.warning(msg); }; _removeListeners(event.target); } public function send(account:String, variables:Variables=null, force:Boolean=false, rateLimit:Boolean=false):void{ var localPath:String; var localImage:URLRequest; var remoteImage:URLRequest; _utmac = account; if (!variables){ variables = new Variables(); }; variables.URIencode = false; variables.pre = ["utmwv", "utmn", "utmhn", "utmt", "utme", "utmcs", "utmsr", "utmsc", "utmul", "utmje", "utmfl", "utmdt", "utmhid", "utmr", "utmp"]; variables.post = ["utmcc"]; if (_debug.verbose){ _debug.info(((("tracking: " + _buffer.utmb.trackCount) + "/") + _config.trackingLimitPerSession), VisualDebugMode.geek); }; if ((((_buffer.utmb.trackCount < _config.trackingLimitPerSession)) || (force))){ if (rateLimit){ updateToken(); }; if (((((force) || (!(rateLimit)))) || ((_buffer.utmb.token >= 1)))){ if (((!(force)) && (rateLimit))){ _buffer.utmb.token = (_buffer.utmb.token - 1); }; _buffer.utmb.trackCount = (_buffer.utmb.trackCount + 1); if (_debug.verbose){ _debug.info(_buffer.utmb.toString(), VisualDebugMode.geek); }; variables.utmwv = utmwv; variables.utmn = Utils.generate32bitRandom(); if (_info.domainName != ""){ variables.utmhn = _info.domainName; }; if (_config.sampleRate < 1){ variables.utmsp = (_config.sampleRate * 100); }; if ((((_config.serverMode == ServerOperationMode.local)) || ((_config.serverMode == ServerOperationMode.both)))){ localPath = _info.locationSWFPath; if (localPath.lastIndexOf("/") > 0){ localPath = localPath.substring(0, localPath.lastIndexOf("/")); }; localImage = new URLRequest(); if (_config.localGIFpath.indexOf("http") == 0){ localImage.url = _config.localGIFpath; } else { localImage.url = (localPath + _config.localGIFpath); }; localImage.url = (localImage.url + ("?" + variables.toString())); if (((_debug.active) && (_debug.GIFRequests))){ _debugSend(localImage); } else { sendRequest(localImage); }; }; if ((((_config.serverMode == ServerOperationMode.remote)) || ((_config.serverMode == ServerOperationMode.both)))){ remoteImage = new URLRequest(); if (_info.protocol == Protocols.HTTPS){ remoteImage.url = _config.secureRemoteGIFpath; } else { if (_info.protocol == Protocols.HTTP){ remoteImage.url = _config.remoteGIFpath; } else { remoteImage.url = _config.remoteGIFpath; }; }; variables.utmac = utmac; variables.utmcc = encodeURIComponent(utmcc); remoteImage.url = (remoteImage.url + ("?" + variables.toString())); if (((_debug.active) && (_debug.GIFRequests))){ _debugSend(remoteImage); } else { sendRequest(remoteImage); }; }; }; }; } public function onSecurityError(event:SecurityErrorEvent):void{ if (_debug.GIFRequests){ _debug.failure(event.text); }; } public function get utmsp():String{ return (((_config.sampleRate * 100) as String)); } public function get utmcc():String{ var cookies:Array; cookies = []; if (_buffer.hasUTMA()){ cookies.push((_buffer.utma.toURLString() + ";")); }; if (_buffer.hasUTMZ()){ cookies.push((_buffer.utmz.toURLString() + ";")); }; if (_buffer.hasUTMV()){ cookies.push((_buffer.utmv.toURLString() + ";")); }; return (cookies.join("+")); } public function get utmac():String{ return (_utmac); } public function get utmwv():String{ return (_config.version); } public function sendRequest(request:URLRequest):void{ var loader:Loader; var context:LoaderContext; var request = request; loader = new Loader(); loader.name = String(_count++); context = new LoaderContext(false); loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, onIOError); loader.contentLoaderInfo.addEventListener(Event.COMPLETE, onComplete); _lastRequest = request; _requests[loader.name] = new RequestObject(request); loader.load(request, context); //unresolved jump var _slot1 = e; _debug.failure("\"Loader.load()\" could not instanciate Gif Request"); } private function _removeListeners(target:Object):void{ target.removeEventListener(IOErrorEvent.IO_ERROR, onIOError); target.removeEventListener(Event.COMPLETE, onComplete); } public function updateToken():void{ var timestamp:Number; var tokenDelta:Number; timestamp = new Date().getTime(); tokenDelta = ((timestamp - _buffer.utmb.lastTime) * (_config.tokenRate / 1000)); if (_debug.verbose){ _debug.info(("tokenDelta: " + tokenDelta), VisualDebugMode.geek); }; if (tokenDelta >= 1){ _buffer.utmb.token = Math.min(Math.floor((_buffer.utmb.token + tokenDelta)), _config.bucketCapacity); _buffer.utmb.lastTime = timestamp; if (_debug.verbose){ _debug.info(_buffer.utmb.toString(), VisualDebugMode.geek); }; }; } private function _shortenURL(url:String):String{ var paths:Array; if (url.length > 60){ paths = url.split("/"); while (url.length > 60) { paths.shift(); url = ("../" + paths.join("/")); }; }; return (url); } public function get utmhn():String{ return (_info.domainName); } private function _debugSend(request:URLRequest):void{ var data:String; var _local3:String; data = ""; switch (_debug.mode){ case VisualDebugMode.geek: data = ((("Gif Request #" + _alertcount) + ":\n") + request.url); break; case VisualDebugMode.advanced: _local3 = request.url; if (_local3.indexOf("?") > -1){ _local3 = _local3.split("?")[0]; }; _local3 = _shortenURL(_local3); data = (((("Send Gif Request #" + _alertcount) + ":\n") + _local3) + " ?"); break; case VisualDebugMode.basic: default: data = (((("Send " + _config.serverMode.toString()) + " Gif Request #") + _alertcount) + " ?"); }; _debug.alertGifRequest(data, request, this); _alertcount++; } public function onComplete(event:Event):void{ var id:String; var msg:String; var url:String; id = event.target.loader.name; _requests[id].complete(); msg = (("Gif Request #" + id) + " sent"); url = _requests[id].request.url; if (_debug.GIFRequests){ if (!_debug.verbose){ if (url.indexOf("?") > -1){ url = url.split("?")[0]; }; url = _shortenURL(url); }; if (int(_debug.mode) > int(VisualDebugMode.basic)){ msg = (msg + ((" to \"" + url) + "\"")); }; _debug.success(msg); } else { _debug.info(msg); }; _removeListeners(event.target); } } }//package com.google.analytics.core
Section 23
//IdleTimer (com.google.analytics.core.IdleTimer) package com.google.analytics.core { import flash.events.*; import flash.display.*; import com.google.analytics.v4.*; import com.google.analytics.debug.*; import flash.utils.*; public class IdleTimer { private var _loop:Timer; private var _stage:Stage; private var _lastMove:int; private var _debug:DebugConfiguration; private var _session:Timer; private var _inactivity:Number; private var _buffer:Buffer; public function IdleTimer(config:Configuration, debug:DebugConfiguration, display:DisplayObject, buffer:Buffer){ var delay:Number; var inactivity:Number; var sessionTimeout:Number; super(); delay = config.idleLoop; inactivity = config.idleTimeout; sessionTimeout = config.sessionTimeout; _loop = new Timer((delay * 1000)); _session = new Timer((sessionTimeout * 1000), 1); _debug = debug; _stage = display.stage; _buffer = buffer; _lastMove = getTimer(); _inactivity = (inactivity * 1000); _loop.addEventListener(TimerEvent.TIMER, checkForIdle); _session.addEventListener(TimerEvent.TIMER_COMPLETE, endSession); _stage.addEventListener(MouseEvent.MOUSE_MOVE, onMouseMove); _debug.info(((((("delay: " + delay) + "sec , inactivity: ") + inactivity) + "sec, sessionTimeout: ") + sessionTimeout), VisualDebugMode.geek); _loop.start(); } private function onMouseMove(event:MouseEvent):void{ _lastMove = getTimer(); if (_session.running){ _debug.info("session timer reset", VisualDebugMode.geek); _session.reset(); }; } public function endSession(event:TimerEvent):void{ _session.removeEventListener(TimerEvent.TIMER_COMPLETE, endSession); _debug.info("session timer end session", VisualDebugMode.geek); _session.reset(); _buffer.resetCurrentSession(); _debug.info(_buffer.utmb.toString(), VisualDebugMode.geek); _debug.info(_buffer.utmc.toString(), VisualDebugMode.geek); _session.addEventListener(TimerEvent.TIMER_COMPLETE, endSession); } public function checkForIdle(event:TimerEvent):void{ var current:int; current = getTimer(); if ((current - _lastMove) >= _inactivity){ if (!_session.running){ _debug.info("session timer start", VisualDebugMode.geek); _session.start(); }; }; } } }//package com.google.analytics.core
Section 24
//Organic (com.google.analytics.core.Organic) package com.google.analytics.core { import com.google.analytics.utils.*; public class Organic { private var _sourcesCache:Array; private var _sourcesEngine:Array; private var _ignoredKeywords:Array; private var _ignoredReferralsCache:Object; private var _ignoredReferrals:Array; private var _ignoredKeywordsCache:Object; private var _sources:Array; public static var throwErrors:Boolean = false; public function Organic(){ super(); _sources = []; _sourcesCache = []; _sourcesEngine = []; _ignoredReferrals = []; _ignoredReferralsCache = {}; _ignoredKeywords = []; _ignoredKeywordsCache = {}; } public function getKeywordValue(or:OrganicReferrer, path:String):String{ var keyword:String; keyword = or.keyword; return (getKeywordValueFromPath(keyword, path)); } public function isIgnoredKeyword(keyword:String):Boolean{ if (_ignoredKeywordsCache.hasOwnProperty(keyword)){ return (true); }; return (false); } public function isIgnoredReferral(referrer:String):Boolean{ if (_ignoredReferralsCache.hasOwnProperty(referrer)){ return (true); }; return (false); } public function clear():void{ clearEngines(); clearIgnoredReferrals(); clearIgnoredKeywords(); } public function get ignoredKeywordsCount():int{ return (_ignoredKeywords.length); } public function match(name:String):Boolean{ if (name == ""){ return (false); }; name = name.toLowerCase(); if (_sourcesEngine[name] != undefined){ return (true); }; return (false); } public function get count():int{ return (_sources.length); } public function addSource(engine:String, keyword:String):void{ var orgref:OrganicReferrer; orgref = new OrganicReferrer(engine, keyword); if (_sourcesCache[orgref.toString()] == undefined){ _sources.push(orgref); _sourcesCache[orgref.toString()] = (_sources.length - 1); if (_sourcesEngine[orgref.engine] == undefined){ _sourcesEngine[orgref.engine] = [(_sources.length - 1)]; } else { _sourcesEngine[orgref.engine].push((_sources.length - 1)); }; } else { if (throwErrors){ throw (new Error((orgref.toString() + " already exists, we don't add it."))); }; }; } public function clearIgnoredKeywords():void{ _ignoredKeywords = []; _ignoredKeywordsCache = {}; } public function clearEngines():void{ _sources = []; _sourcesCache = []; _sourcesEngine = []; } public function get ignoredReferralsCount():int{ return (_ignoredReferrals.length); } public function addIgnoredReferral(referrer:String):void{ if (_ignoredReferralsCache[referrer] == undefined){ _ignoredReferrals.push(referrer); _ignoredReferralsCache[referrer] = (_ignoredReferrals.length - 1); } else { if (throwErrors){ throw (new Error((("\"" + referrer) + "\" already exists, we don't add it."))); }; }; } public function clearIgnoredReferrals():void{ _ignoredReferrals = []; _ignoredReferralsCache = {}; } public function getReferrerByName(name:String):OrganicReferrer{ var index:int; if (match(name)){ index = _sourcesEngine[name][0]; return (_sources[index]); }; return (null); } public function addIgnoredKeyword(keyword:String):void{ if (_ignoredKeywordsCache[keyword] == undefined){ _ignoredKeywords.push(keyword); _ignoredKeywordsCache[keyword] = (_ignoredKeywords.length - 1); } else { if (throwErrors){ throw (new Error((("\"" + keyword) + "\" already exists, we don't add it."))); }; }; } public function get sources():Array{ return (_sources); } public static function getKeywordValueFromPath(keyword:String, path:String):String{ var value:String; var vars:Variables; if (path.indexOf((keyword + "=")) > -1){ if (path.charAt(0) == "?"){ path = path.substr(1); }; path = path.split("+").join("%20"); vars = new Variables(path); value = vars[keyword]; }; return (value); } } }//package com.google.analytics.core
Section 25
//OrganicReferrer (com.google.analytics.core.OrganicReferrer) package com.google.analytics.core { public class OrganicReferrer { private var _engine:String; private var _keyword:String; public function OrganicReferrer(engine:String, keyword:String){ super(); this.engine = engine; this.keyword = keyword; } public function set engine(value:String):void{ _engine = value.toLowerCase(); } public function get keyword():String{ return (_keyword); } public function toString():String{ return (((engine + "?") + keyword)); } public function get engine():String{ return (_engine); } public function set keyword(value:String):void{ _keyword = value.toLowerCase(); } } }//package com.google.analytics.core
Section 26
//RequestObject (com.google.analytics.core.RequestObject) package com.google.analytics.core { import flash.net.*; import flash.utils.*; public class RequestObject { public var start:int; public var request:URLRequest; public var end:int; public function RequestObject(request:URLRequest){ super(); start = getTimer(); this.request = request; } public function toString():String{ var data:Array; data = []; data.push((("duration: " + duration) + "ms")); data.push(("url: " + request.url)); return ((("{ " + data.join(", ")) + " }")); } public function get duration():int{ if (!hasCompleted()){ return (0); }; return ((end - start)); } public function hasCompleted():Boolean{ return ((end > 0)); } public function complete():void{ end = getTimer(); } } }//package com.google.analytics.core
Section 27
//ServerOperationMode (com.google.analytics.core.ServerOperationMode) package com.google.analytics.core { public class ServerOperationMode { private var _value:int; private var _name:String; public static const both:ServerOperationMode = new ServerOperationMode(2, "both"); ; public static const remote:ServerOperationMode = new ServerOperationMode(1, "remote"); ; public static const local:ServerOperationMode = new ServerOperationMode(0, "local"); ; public function ServerOperationMode(value:int=0, name:String=""){ super(); _value = value; _name = name; } public function valueOf():int{ return (_value); } public function toString():String{ return (_name); } } }//package com.google.analytics.core
Section 28
//TrackerCache (com.google.analytics.core.TrackerCache) package com.google.analytics.core { import com.google.analytics.v4.*; import flash.errors.*; public class TrackerCache implements GoogleAnalyticsAPI { public var tracker:GoogleAnalyticsAPI; private var _ar:Array; public static var CACHE_THROW_ERROR:Boolean; public function TrackerCache(tracker:GoogleAnalyticsAPI=null){ super(); this.tracker = tracker; _ar = []; } public function size():uint{ return (_ar.length); } public function flush():void{ var o:Object; var name:String; var args:Array; var l:int; var i:int; if (tracker == null){ return; }; if (size() > 0){ l = _ar.length; while (i < l) { o = _ar.shift(); name = (o.name as String); args = (o.args as Array); if (((!((name == null))) && ((name in tracker)))){ (tracker[name] as Function).apply(tracker, args); }; i++; }; }; } public function enqueue(name:String, ... _args):Boolean{ if (name == null){ return (false); }; _ar.push({name:name, args:_args}); return (true); } public function link(targetUrl:String, useHash:Boolean=false):void{ enqueue("link", targetUrl, useHash); } public function addOrganic(newOrganicEngine:String, newOrganicKeyword:String):void{ enqueue("addOrganic", newOrganicEngine, newOrganicKeyword); } public function setAllowLinker(enable:Boolean):void{ enqueue("setAllowLinker", enable); } public function getLinkerUrl(url:String="", useHash:Boolean=false):String{ if (CACHE_THROW_ERROR){ throw (new IllegalOperationError("The tracker is not ready and you can use the 'getLinkerUrl' method for the moment.")); }; return (""); } public function getClientInfo():Boolean{ if (CACHE_THROW_ERROR){ throw (new IllegalOperationError("The tracker is not ready and you can use the 'getClientInfo' method for the moment.")); }; return (false); } public function trackTrans():void{ enqueue("trackTrans"); } public function trackPageview(pageURL:String=""):void{ enqueue("trackPageview", pageURL); } public function setClientInfo(enable:Boolean):void{ enqueue("setClientInfo", enable); } public function trackEvent(category:String, action:String, label:String=null, value:Number=NaN):Boolean{ enqueue("trackEvent", category, action, label, value); return (true); } public function linkByPost(formObject:Object, useHash:Boolean=false):void{ enqueue("linkByPost", formObject, useHash); } public function setCookieTimeout(newDefaultTimeout:int):void{ enqueue("setCookieTimeout", newDefaultTimeout); } public function isEmpty():Boolean{ return ((_ar.length == 0)); } public function getDetectTitle():Boolean{ if (CACHE_THROW_ERROR){ throw (new IllegalOperationError("The tracker is not ready and you can use the 'getDetectTitle' method for the moment.")); }; return (false); } public function resetSession():void{ enqueue("resetSession"); } public function setDetectFlash(enable:Boolean):void{ enqueue("setDetectFlash", enable); } public function clear():void{ _ar = []; } public function setCampNameKey(newCampNameKey:String):void{ enqueue("setCampNameKey", newCampNameKey); } public function addItem(item:String, sku:String, name:String, category:String, price:Number, quantity:int):void{ enqueue("addItem", item, sku, name, category, price, quantity); } public function createEventTracker(objName:String):EventTracker{ if (CACHE_THROW_ERROR){ throw (new IllegalOperationError("The tracker is not ready and you can use the 'createEventTracker' method for the moment.")); }; return (null); } public function clearIgnoredOrganic():void{ enqueue("clearIgnoredOrganic"); } public function setVar(newVal:String):void{ enqueue("setVar", newVal); } public function setDomainName(newDomainName:String):void{ enqueue("setDomainName", newDomainName); } public function addTrans(orderId:String, affiliation:String, total:Number, tax:Number, shipping:Number, city:String, state:String, country:String):void{ if (CACHE_THROW_ERROR){ throw (new IllegalOperationError("The tracker is not ready and you can use the 'addTrans' method for the moment.")); }; } public function setCampSourceKey(newCampSrcKey:String):void{ enqueue("setCampSourceKey", newCampSrcKey); } public function setCampContentKey(newCampContentKey:String):void{ enqueue("setCampContentKey", newCampContentKey); } public function clearIgnoredRef():void{ enqueue("clearIgnoredRef"); } public function setLocalServerMode():void{ enqueue("setLocalServerMode"); } public function getLocalGifPath():String{ if (CACHE_THROW_ERROR){ throw (new IllegalOperationError("The tracker is not ready and you can use the 'getLocalGifPath' method for the moment.")); }; return (""); } public function setAllowAnchor(enable:Boolean):void{ enqueue("setAllowAnchor", enable); } public function setLocalGifPath(newLocalGifPath:String):void{ enqueue("setLocalGifPath", newLocalGifPath); } public function getVersion():String{ if (CACHE_THROW_ERROR){ throw (new IllegalOperationError("The tracker is not ready and you can use the 'getVersion' method for the moment.")); }; return (""); } public function setCookiePath(newCookiePath:String):void{ enqueue("setCookiePath", newCookiePath); } public function setSampleRate(newRate:Number):void{ enqueue("setSampleRate", newRate); } public function setAllowHash(enable:Boolean):void{ enqueue("setAllowHash", enable); } public function addIgnoredOrganic(newIgnoredOrganicKeyword:String):void{ enqueue("addIgnoredOrganic", newIgnoredOrganicKeyword); } public function setCampNOKey(newCampNOKey:String):void{ enqueue("setCampNOKey", newCampNOKey); } public function getServiceMode():ServerOperationMode{ if (CACHE_THROW_ERROR){ throw (new IllegalOperationError("The tracker is not ready and you can use the 'getServiceMode' method for the moment.")); }; return (null); } public function setLocalRemoteServerMode():void{ enqueue("setLocalRemoteServerMode"); } public function cookiePathCopy(newPath:String):void{ enqueue("cookiePathCopy", newPath); } public function setDetectTitle(enable:Boolean):void{ enqueue("setDetectTitle", enable); } public function getDetectFlash():Boolean{ if (CACHE_THROW_ERROR){ throw (new IllegalOperationError("The tracker is not ready and you can use the 'getDetectFlash' method for the moment.")); }; return (false); } public function setCampaignTrack(enable:Boolean):void{ enqueue("setCampaignTrack", enable); } public function clearOrganic():void{ enqueue("clearOrganic"); } public function setCampTermKey(newCampTermKey:String):void{ enqueue("setCampTermKey", newCampTermKey); } public function addIgnoredRef(newIgnoredReferrer:String):void{ enqueue("addIgnoredRef", newIgnoredReferrer); } public function setCampMediumKey(newCampMedKey:String):void{ enqueue("setCampMediumKey", newCampMedKey); } public function setSessionTimeout(newTimeout:int):void{ enqueue("setSessionTimeout", newTimeout); } public function setRemoteServerMode():void{ enqueue("setRemoteServerMode"); } public function element(){ return (_ar[0]); } public function getAccount():String{ if (CACHE_THROW_ERROR){ throw (new IllegalOperationError("The tracker is not ready and you can use the 'getAccount' method for the moment.")); }; return (""); } } }//package com.google.analytics.core
Section 29
//TrackerMode (com.google.analytics.core.TrackerMode) package com.google.analytics.core { public class TrackerMode { public static const BRIDGE:String = "Bridge"; public static const AS3:String = "AS3"; public function TrackerMode(){ super(); } } }//package com.google.analytics.core
Section 30
//Utils (com.google.analytics.core.Utils) package com.google.analytics.core { public class Utils { public function Utils(){ super(); } public static function trim(raw:String, everything:Boolean=false):String{ var whitespaces:Array; var str:String; var i:int; var iLeft:int; var iRight:int; if (raw == ""){ return (""); }; whitespaces = [" ", "\n", "\r", "\t"]; str = raw; if (everything){ i = 0; while ((((i < whitespaces.length)) && ((str.indexOf(whitespaces[i]) > -1)))) { str = str.split(whitespaces[i]).join(""); i++; }; } else { iLeft = 0; while ((((iLeft < str.length)) && ((whitespaces.indexOf(str.charAt(iLeft)) > -1)))) { iLeft++; }; str = str.substr(iLeft); iRight = (str.length - 1); while ((((iRight >= 0)) && ((whitespaces.indexOf(str.charAt(iRight)) > -1)))) { iRight--; }; str = str.substring(0, (iRight + 1)); }; return (str); } public static function generateHash(input:String):int{ var hash:int; var leftMost7:int; var pos:int; var current:int; hash = 1; leftMost7 = 0; if (((!((input == null))) && (!((input == ""))))){ hash = 0; pos = (input.length - 1); while (pos >= 0) { current = input.charCodeAt(pos); hash = ((((hash << 6) & 268435455) + current) + (current << 14)); leftMost7 = (hash & 266338304); if (leftMost7 != 0){ hash = (hash ^ (leftMost7 >> 21)); }; pos--; }; }; return (hash); } public static function generate32bitRandom():int{ return (Math.round((Math.random() * 2147483647))); } public static function validateAccount(account:String):Boolean{ var rel:RegExp; rel = /^UA-[0-9]*-[0-9]*$/; return (rel.test(account)); } } }//package com.google.analytics.core
Section 31
//Cookie (com.google.analytics.data.Cookie) package com.google.analytics.data { public interface Cookie { function toURLString():String; function toSharedObject():Object; function set creation(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\data;Cookie.as:Date):void; function fromSharedObject(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\data;Cookie.as:Object):void; function get expiration():Date; function isExpired():Boolean; function set expiration(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\data;Cookie.as:Date):void; function get creation():Date; } }//package com.google.analytics.data
Section 32
//UTMA (com.google.analytics.data.UTMA) package com.google.analytics.data { import com.google.analytics.utils.*; public class UTMA extends UTMCookie { private var _domainHash:Number; private var _firstTime:Number; private var _currentTime:Number; private var _sessionId:Number; private var _lastTime:Number; private var _sessionCount:Number; public function UTMA(domainHash:Number=NaN, sessionId:Number=NaN, firstTime:Number=NaN, lastTime:Number=NaN, currentTime:Number=NaN, sessionCount:Number=NaN){ super("utma", "__utma", ["domainHash", "sessionId", "firstTime", "lastTime", "currentTime", "sessionCount"], (Timespan.twoyears * 1000)); this.domainHash = domainHash; this.sessionId = sessionId; this.firstTime = firstTime; this.lastTime = lastTime; this.currentTime = currentTime; this.sessionCount = sessionCount; } public function get lastTime():Number{ return (_lastTime); } public function set lastTime(value:Number):void{ _lastTime = value; update(); } public function get sessionCount():Number{ return (_sessionCount); } public function get firstTime():Number{ return (_firstTime); } public function set sessionId(value:Number):void{ _sessionId = value; update(); } public function set sessionCount(value:Number):void{ _sessionCount = value; update(); } public function set firstTime(value:Number):void{ _firstTime = value; update(); } public function set currentTime(value:Number):void{ _currentTime = value; update(); } public function get sessionId():Number{ return (_sessionId); } public function set domainHash(value:Number):void{ _domainHash = value; update(); } public function get currentTime():Number{ return (_currentTime); } public function get domainHash():Number{ return (_domainHash); } } }//package com.google.analytics.data
Section 33
//UTMB (com.google.analytics.data.UTMB) package com.google.analytics.data { import com.google.analytics.utils.*; public class UTMB extends UTMCookie { private var _lastTime:Number; private var _domainHash:Number; private var _trackCount:Number; private var _token:Number; public static var defaultTimespan:Number = Timespan.thirtyminutes; public function UTMB(domainHash:Number=NaN, trackCount:Number=NaN, token:Number=NaN, lastTime:Number=NaN){ super("utmb", "__utmb", ["domainHash", "trackCount", "token", "lastTime"], (defaultTimespan * 1000)); this.domainHash = domainHash; this.trackCount = trackCount; this.token = token; this.lastTime = lastTime; } public function get token():Number{ return (_token); } public function set trackCount(value:Number):void{ _trackCount = value; update(); } public function set lastTime(value:Number):void{ _lastTime = value; update(); } public function get lastTime():Number{ return (_lastTime); } public function set domainHash(value:Number):void{ _domainHash = value; update(); } public function get domainHash():Number{ return (_domainHash); } public function set token(value:Number):void{ _token = value; update(); } public function get trackCount():Number{ return (_trackCount); } } }//package com.google.analytics.data
Section 34
//UTMC (com.google.analytics.data.UTMC) package com.google.analytics.data { public class UTMC extends UTMCookie { private var _domainHash:Number; public function UTMC(domainHash:Number=NaN){ super("utmc", "__utmc", ["domainHash"]); this.domainHash = domainHash; } public function set domainHash(value:Number):void{ _domainHash = value; update(); } public function get domainHash():Number{ return (_domainHash); } } }//package com.google.analytics.data
Section 35
//UTMCookie (com.google.analytics.data.UTMCookie) package com.google.analytics.data { import com.google.analytics.core.*; public class UTMCookie implements Cookie { protected var inURL:String; protected var name:String; private var _creation:Date; private var _expiration:Date; public var proxy:Buffer; private var _timespan:Number; protected var fields:Array; public function UTMCookie(name:String, inURL:String, fields:Array, timespan:Number=0){ super(); this.name = name; this.inURL = inURL; this.fields = fields; _timestamp(timespan); } public function isEmpty():Boolean{ var empty:int; var field:String; var i:int; empty = 0; i = 0; while (i < fields.length) { field = fields[i]; if ((((this[field] is Number)) && (isNaN(this[field])))){ empty++; } else { if ((((this[field] is String)) && ((this[field] == "")))){ empty++; }; }; i++; }; if (empty == fields.length){ return (true); }; return (false); } protected function update():void{ resetTimestamp(); if (proxy){ proxy.update(name, toSharedObject()); }; } public function fromSharedObject(data:Object):void{ var field:String; var len:int; var i:int; len = fields.length; i = 0; while (i < len) { field = fields[i]; if (data[field]){ this[field] = data[field]; }; i++; }; if (data.creation){ this.creation = data.creation; }; if (data.expiration){ this.expiration = data.expiration; }; } private function _timestamp(timespan:Number):void{ creation = new Date(); _timespan = timespan; if (timespan > 0){ expiration = new Date((creation.valueOf() + timespan)); }; } public function isExpired():Boolean{ var current:Date; var diff:Number; current = new Date(); diff = (expiration.valueOf() - current.valueOf()); if (diff <= 0){ return (true); }; return (false); } public function set expiration(value:Date):void{ _expiration = value; } public function get creation():Date{ return (_creation); } public function reset():void{ var field:String; var i:int; i = 0; while (i < fields.length) { field = fields[i]; if ((this[field] is Number)){ this[field] = NaN; } else { if ((this[field] is String)){ this[field] = ""; }; }; i++; }; resetTimestamp(); update(); } public function valueOf():String{ var data:Array; var field:String; var value:*; var testData:Array; var testOut:String; var i:int; data = []; testOut = ""; i = 0; while (i < fields.length) { field = fields[i]; value = this[field]; if ((value is String)){ if (value == ""){ value = "-"; data.push(value); } else { data.push(value); }; } else { if ((value is Number)){ if (value == 0){ data.push(value); } else { if (isNaN(value)){ value = "-"; data.push(value); } else { data.push(value); }; }; }; }; i++; }; if (isEmpty()){ return ("-"); }; return (("" + data.join("."))); } public function resetTimestamp(timespan:Number=NaN):void{ if (!isNaN(timespan)){ _timespan = timespan; }; _creation = null; _expiration = null; _timestamp(_timespan); } public function get expiration():Date{ if (_expiration){ return (_expiration); }; return (new Date((new Date().valueOf() + 1000))); } public function toURLString():String{ return (((inURL + "=") + valueOf())); } public function toSharedObject():Object{ var data:Object; var field:String; var value:*; var i:int; data = {}; i = 0; for (;i < fields.length;i++) { field = fields[i]; value = this[field]; if ((value is String)){ data[field] = value; } else { if (value == 0){ data[field] = value; } else { if (isNaN(value)){ continue; } else { data[field] = value; }; }; }; }; data.creation = creation; data.expiration = expiration; return (data); } public function toString(showTimestamp:Boolean=false):String{ var data:Array; var field:String; var value:*; var len:int; var i:int; var str:String; data = []; len = fields.length; i = 0; for (;i < len;i++) { field = fields[i]; value = this[field]; if ((value is String)){ data.push((((field + ": \"") + value) + "\"")); } else { if (value == 0){ data.push(((field + ": ") + value)); } else { if (isNaN(value)){ continue; } else { data.push(((field + ": ") + value)); }; }; }; }; str = (((name.toUpperCase() + " {") + data.join(", ")) + "}"); if (showTimestamp){ str = (str + (((" creation:" + creation) + ", expiration:") + expiration)); }; return (str); } public function set creation(value:Date):void{ _creation = value; } } }//package com.google.analytics.data
Section 36
//UTMK (com.google.analytics.data.UTMK) package com.google.analytics.data { public class UTMK extends UTMCookie { private var _hash:Number; public function UTMK(hash:Number=NaN){ super("utmk", "__utmk", ["hash"]); this.hash = hash; } public function get hash():Number{ return (_hash); } public function set hash(value:Number):void{ _hash = value; update(); } } }//package com.google.analytics.data
Section 37
//UTMV (com.google.analytics.data.UTMV) package com.google.analytics.data { import com.google.analytics.utils.*; public class UTMV extends UTMCookie { private var _domainHash:Number; private var _value:String; public function UTMV(domainHash:Number=NaN, value:String=""){ super("utmv", "__utmv", ["domainHash", "value"], (Timespan.twoyears * 1000)); this.domainHash = domainHash; this.value = value; } public function get value():String{ return (_value); } public function set value(value:String):void{ _value = value; update(); } public function get domainHash():Number{ return (_domainHash); } public function set domainHash(value:Number):void{ _domainHash = value; update(); } } }//package com.google.analytics.data
Section 38
//UTMX (com.google.analytics.data.UTMX) package com.google.analytics.data { public class UTMX extends UTMCookie { private var _value:String; public function UTMX(){ super("utmx", "__utmx", ["value"], 0); _value = "-"; } public function set value(value:String):void{ _value = value; } public function get value():String{ return (_value); } } }//package com.google.analytics.data
Section 39
//UTMZ (com.google.analytics.data.UTMZ) package com.google.analytics.data { import com.google.analytics.utils.*; public class UTMZ extends UTMCookie { private var _domainHash:Number; private var _campaignSessions:Number; private var _campaignTracking:String; private var _responseCount:Number; private var _campaignCreation:Number; public static var defaultTimespan:Number = Timespan.sixmonths; public function UTMZ(domainHash:Number=NaN, campaignCreation:Number=NaN, campaignSessions:Number=NaN, responseCount:Number=NaN, campaignTracking:String=""){ super("utmz", "__utmz", ["domainHash", "campaignCreation", "campaignSessions", "responseCount", "campaignTracking"], (defaultTimespan * 1000)); this.domainHash = domainHash; this.campaignCreation = campaignCreation; this.campaignSessions = campaignSessions; this.responseCount = responseCount; this.campaignTracking = campaignTracking; } public function get campaignCreation():Number{ return (_campaignCreation); } public function set campaignSessions(value:Number):void{ _campaignSessions = value; update(); } public function set responseCount(value:Number):void{ _responseCount = value; update(); } public function set campaignCreation(value:Number):void{ _campaignCreation = value; update(); } public function get campaignSessions():Number{ return (_campaignSessions); } public function get responseCount():Number{ return (_responseCount); } public function set domainHash(value:Number):void{ _domainHash = value; update(); } public function get campaignTracking():String{ return (_campaignTracking); } public function set campaignTracking(value:String):void{ _campaignTracking = value; update(); } public function get domainHash():Number{ return (_domainHash); } } }//package com.google.analytics.data
Section 40
//X10 (com.google.analytics.data.X10) package com.google.analytics.data { public class X10 { private var _delimEnd:String;// = ")" private var _delimSet:String;// = "*" private var _escapeChar:String;// = "'" private var _delimBegin:String;// = "(" private var _delimNumValue:String;// = "!" private var _key:String;// = "k" private var _set:Array; private var _projectData:Object; private var _hasData:int; private var _escapeCharMap:Object; private var _minimum:int; private var _value:String;// = "v" public function X10(){ _key = "k"; _value = "v"; _set = [_key, _value]; _delimBegin = "("; _delimEnd = ")"; _delimSet = "*"; _delimNumValue = "!"; _escapeChar = "'"; super(); _projectData = {}; _escapeCharMap = {}; _escapeCharMap[_escapeChar] = "'0"; _escapeCharMap[_delimEnd] = "'1"; _escapeCharMap[_delimSet] = "'2"; _escapeCharMap[_delimNumValue] = "'3"; _minimum = 1; } private function _clearInternal(projectId:Number, type:String):void{ var isEmpty:Boolean; var i:int; var l:int; if (((hasProject(projectId)) && (!((_projectData[projectId][type] == undefined))))){ _projectData[projectId][type] = undefined; isEmpty = true; l = _set.length; i = 0; while (i < l) { if (_projectData[projectId][_set[i]] != undefined){ isEmpty = false; break; }; i++; }; if (isEmpty){ _projectData[projectId] = undefined; _hasData = (_hasData - 1); }; }; } public function hasData():Boolean{ return ((_hasData > 0)); } private function _setInternal(projectId:Number, type:String, num:Number, value:String):void{ if (!hasProject(projectId)){ _projectData[projectId] = {}; }; if (_projectData[projectId][type] == undefined){ _projectData[projectId][type] = []; }; _projectData[projectId][type][num] = value; _hasData = (_hasData + 1); } public function hasProject(projectId:Number):Boolean{ return (_projectData[projectId]); } public function clearKey(projectId:Number):void{ _clearInternal(projectId, _key); } private function _renderDataType(data:Array):String{ var result:Array; var str:String; var i:int; result = []; i = 0; while (i < data.length) { if (data[i] != undefined){ str = ""; if (((!((i == _minimum))) && ((data[(i - 1)] == undefined)))){ str = (str + i.toString()); str = (str + _delimNumValue); }; str = (str + _escapeExtensibleValue(data[i])); result.push(str); }; i++; }; return (((_delimBegin + result.join(_delimSet)) + _delimEnd)); } public function getKey(projectId:Number, num:Number):String{ return ((_getInternal(projectId, _key, num) as String)); } public function clearValue(projectId:Number):void{ _clearInternal(projectId, _value); } public function renderMergedUrlString(extObject:X10=null):String{ var result:Array; var projectId:String; if (!extObject){ return (renderUrlString()); }; result = [extObject.renderUrlString()]; for (projectId in _projectData) { if (((hasProject(Number(projectId))) && (!(extObject.hasProject(Number(projectId)))))){ result.push((projectId + _renderProject(_projectData[projectId]))); }; }; return (result.join("")); } public function setValue(projectId:Number, num:Number, value:Number):Boolean{ if (((((!((Math.round(value) == value))) || (isNaN(value)))) || ((value == Infinity)))){ return (false); }; _setInternal(projectId, _value, num, value.toString()); return (true); } public function renderUrlString():String{ var result:Array; var projectId:String; result = []; for (projectId in _projectData) { if (hasProject(Number(projectId))){ result.push((projectId + _renderProject(_projectData[projectId]))); }; }; return (result.join("")); } private function _getInternal(projectId:Number, type:String, num:Number):Object{ if (((hasProject(projectId)) && (!((_projectData[projectId][type] == undefined))))){ return (_projectData[projectId][type][num]); }; return (undefined); } public function setKey(projectId:Number, num:Number, value:String):Boolean{ _setInternal(projectId, _key, num, value); return (true); } public function getValue(projectId:Number, num:Number){ var value:*; value = _getInternal(projectId, _value, num); if (value == null){ return (null); }; return (Number(value)); } private function _renderProject(project:Object):String{ var result:String; var needTypeQualifier:Boolean; var i:int; var data:Array; var l:int; result = ""; needTypeQualifier = false; l = _set.length; i = 0; while (i < l) { data = project[_set[i]]; if (data){ if (needTypeQualifier){ result = (result + _set[i]); }; result = (result + _renderDataType(data)); needTypeQualifier = false; } else { needTypeQualifier = true; }; i++; }; return (result); } private function _escapeExtensibleValue(value:String):String{ var result:String; var i:int; var c:String; var escaped:String; result = ""; i = 0; while (i < value.length) { c = value.charAt(i); escaped = _escapeCharMap[c]; if (escaped){ result = (result + escaped); } else { result = (result + c); }; i++; }; return (result); } } }//package com.google.analytics.data
Section 41
//_Style (com.google.analytics.debug._Style) package com.google.analytics.debug { import flash.net.*; import flash.text.*; public class _Style { public var borderColor:uint; public var backgroundColor:uint; private var _sheet:StyleSheet; public var roundedCorner:uint; public var alertColor:uint; public var infoColor:uint; public var successColor:uint; private var _loader:URLLoader; public var failureColor:uint; private var _defaultSheet:String; public var warningColor:uint; public function _Style(){ super(); _sheet = new StyleSheet(); _loader = new URLLoader(); _init(); } private function _parseSheet(data:String):void{ _sheet.parseCSS(data); } public function get sheet():StyleSheet{ return (_sheet); } private function _init():void{ _defaultSheet = ""; _defaultSheet = (_defaultSheet + "a{text-decoration: underline;}\n"); _defaultSheet = (_defaultSheet + ".uiLabel{color: #000000;font-family: Arial;font-size: 12;margin-left: 2;margin-right: 2;}\n"); _defaultSheet = (_defaultSheet + ".uiWarning{color: #ffffff;font-family: Arial;font-size: 14;font-weight: bold;margin-left: 6;margin-right: 6;}\n"); _defaultSheet = (_defaultSheet + ".uiAlert{color: #ffffff;font-family: Arial;font-size: 14;font-weight: bold;margin-left: 6;margin-right: 6;}\n"); _defaultSheet = (_defaultSheet + ".uiInfo{color: #000000;font-family: Arial;font-size: 14;font-weight: bold;margin-left: 6;margin-right: 6;}\n"); _defaultSheet = (_defaultSheet + ".uiSuccess{color: #ffffff;font-family: Arial;font-size: 12;font-weight: bold;margin-left: 6;margin-right: 6;}\n"); _defaultSheet = (_defaultSheet + ".uiFailure{color: #ffffff;font-family: Arial;font-size: 12;font-weight: bold;margin-left: 6;margin-right: 6;}\n"); _defaultSheet = (_defaultSheet + ".uiAlertAction{color: #ffffff;text-align: center;font-family: Arial;font-size: 12;font-weight: bold;margin-left: 6;margin-right: 6;}\n"); _defaultSheet = (_defaultSheet + ".uiAlertTitle{color: #ffffff;font-family: Arial;font-size: 16;font-weight: bold;margin-left: 6;margin-right: 6;}\n"); _defaultSheet = (_defaultSheet + "\n"); roundedCorner = 6; backgroundColor = 0xCCCCCC; borderColor = 0x555555; infoColor = 16777113; alertColor = 0xFFCC00; warningColor = 0xCC0000; successColor = 0xFF00; failureColor = 0xFF0000; _parseSheet(_defaultSheet); } } }//package com.google.analytics.debug
Section 42
//Alert (com.google.analytics.debug.Alert) package com.google.analytics.debug { import flash.events.*; public class Alert extends Label { public var actionOnNextLine:Boolean;// = true public var autoClose:Boolean;// = true private var _actions:Array; public function Alert(text:String, actions:Array, tag:String="uiAlert", color:uint=0, alignement:Align=null, stickToEdge:Boolean=false, actionOnNextLine:Boolean=true){ var i:int; autoClose = true; actionOnNextLine = true; if (color == 0){ color = Style.alertColor; }; if (alignement == null){ alignement = Align.center; }; super(text, tag, color, alignement, stickToEdge); this.selectable = true; super.mouseChildren = true; this.buttonMode = true; this.mouseEnabled = true; this.useHandCursor = true; this.actionOnNextLine = actionOnNextLine; _actions = []; i = 0; while (i < actions.length) { actions[i].container = this; _actions.push(actions[i]); i++; }; } protected function getAction(name:String):AlertAction{ var i:int; i = 0; while (i < _actions.length) { if (name == _actions[i].activator){ return (_actions[i]); }; i++; }; return (null); } override protected function layout():void{ super.layout(); _defineActions(); } protected function spaces(num:int):String{ var str:String; var spc:String; var i:int; str = ""; spc = " "; i = 0; while (i < (num + 1)) { str = (str + spc); i++; }; return (str); } override public function onLink(event:TextEvent):void{ var action:AlertAction; if (isValidAction(event.text)){ action = getAction(event.text); if (action){ action.execute(); }; }; if (autoClose){ close(); }; } protected function isValidAction(action:String):Boolean{ var i:int; i = 0; while (i < _actions.length) { if (action == _actions[i].activator){ return (true); }; i++; }; return (false); } private function _defineActions():void{ var str:String; var actions:Array; var action:AlertAction; var i:int; str = ""; if (actionOnNextLine){ str = (str + "\n"); } else { str = (str + " |"); }; str = (str + " "); actions = []; i = 0; while (i < _actions.length) { action = _actions[i]; actions.push((((("<a href=\"event:" + action.activator) + "\">") + action.name) + "</a>")); i++; }; str = (str + actions.join(" | ")); appendText(str, "uiAlertAction"); } public function close():void{ if (parent != null){ parent.removeChild(this); }; } } }//package com.google.analytics.debug
Section 43
//AlertAction (com.google.analytics.debug.AlertAction) package com.google.analytics.debug { public class AlertAction { public var container:Alert; private var _callback; public var name:String; public var activator:String; public function AlertAction(name:String, activator:String, callback){ super(); this.name = name; this.activator = activator; _callback = callback; } public function execute():void{ if (_callback){ if ((_callback is Function)){ (_callback as Function)(); } else { if ((_callback is String)){ var _local1 = container; _local1[_callback](); }; }; }; } } }//package com.google.analytics.debug
Section 44
//Align (com.google.analytics.debug.Align) package com.google.analytics.debug { public class Align { private var _value:int; private var _name:String; public static const bottomRight:Align = new Align(18, "bottomRight"); ; public static const right:Align = new Align(16, "right"); ; public static const left:Align = new Align(32, "left"); ; public static const topRight:Align = new Align(17, "topRight"); ; public static const bottom:Align = new Align(2, "bottom"); ; public static const bottomLeft:Align = new Align(34, "bottomLeft"); ; public static const topLeft:Align = new Align(33, "topLeft"); ; public static const center:Align = new Align(0x0100, "center"); ; public static const none:Align = new Align(0, "none"); ; public static const top:Align = new Align(1, "top"); ; public function Align(value:int=0, name:String=""){ super(); _value = value; _name = name; } public function valueOf():int{ return (_value); } public function toString():String{ return (_name); } } }//package com.google.analytics.debug
Section 45
//Background (com.google.analytics.debug.Background) package com.google.analytics.debug { import flash.display.*; public class Background { public function Background(){ super(); } public static function drawRounded(target, g:Graphics, width:uint=0, height:uint=0):void{ var W:uint; var H:uint; var R:uint; R = Style.roundedCorner; if ((((width > 0)) && ((height > 0)))){ W = width; H = height; } else { W = target.width; H = target.height; }; if (((target.stickToEdge) && (!((target.alignement == Align.none))))){ switch (target.alignement){ case Align.top: g.drawRoundRectComplex(0, 0, W, H, 0, 0, R, R); break; case Align.topLeft: g.drawRoundRectComplex(0, 0, W, H, 0, 0, 0, R); break; case Align.topRight: g.drawRoundRectComplex(0, 0, W, H, 0, 0, R, 0); break; case Align.bottom: g.drawRoundRectComplex(0, 0, W, H, R, R, 0, 0); break; case Align.bottomLeft: g.drawRoundRectComplex(0, 0, W, H, 0, R, 0, 0); break; case Align.bottomRight: g.drawRoundRectComplex(0, 0, W, H, R, 0, 0, 0); break; case Align.left: g.drawRoundRectComplex(0, 0, W, H, 0, R, 0, R); break; case Align.right: g.drawRoundRectComplex(0, 0, W, H, R, 0, R, 0); break; case Align.center: g.drawRoundRect(0, 0, W, H, R, R); break; }; } else { g.drawRoundRect(0, 0, W, H, R, R); }; } } }//package com.google.analytics.debug
Section 46
//Debug (com.google.analytics.debug.Debug) package com.google.analytics.debug { import flash.events.*; import flash.ui.*; public class Debug extends Label { private var _lines:Array; private var _preferredForcedWidth:uint;// = 540 public var maxLines:uint;// = 16 private var _linediff:int;// = 0 public static var count:uint; public function Debug(color:uint=0, alignement:Align=null, stickToEdge:Boolean=false){ _linediff = 0; _preferredForcedWidth = 540; maxLines = 16; if (alignement == null){ alignement = Align.bottom; }; super("", "uiLabel", color, alignement, stickToEdge); this.name = ("Debug" + count++); _lines = []; selectable = true; addEventListener(KeyboardEvent.KEY_DOWN, onKey); } public function close():void{ dispose(); } public function writeBold(message:String):void{ write(message, true); } override protected function dispose():void{ removeEventListener(KeyboardEvent.KEY_DOWN, onKey); super.dispose(); } override public function get forcedWidth():uint{ if (this.parent){ if (UISprite(this.parent).forcedWidth > _preferredForcedWidth){ return (_preferredForcedWidth); }; return (UISprite(this.parent).forcedWidth); } else { }; return (!NULL!); } private function onKey(event:KeyboardEvent=null):void{ var lines:Array; switch (event.keyCode){ case Keyboard.DOWN: lines = _getLinesToDisplay(1); break; case Keyboard.UP: lines = _getLinesToDisplay(-1); break; default: lines = null; }; if (lines == null){ return; }; text = lines.join("\n"); } public function write(message:String, bold:Boolean=false):void{ var inputLines:Array; var pre:String; var post:String; var i:int; var lines:Array; if (message.indexOf("") > -1){ inputLines = message.split("\n"); } else { inputLines = [message]; }; pre = ""; post = ""; if (bold){ pre = "<b>"; post = "</b>"; }; i = 0; while (i < inputLines.length) { _lines.push(((pre + inputLines[i]) + post)); i++; }; lines = _getLinesToDisplay(); text = lines.join("\n"); } private function _getLinesToDisplay(direction:int=0):Array{ var lines:Array; var start:uint; var end:uint; if ((_lines.length - 1) > maxLines){ if ((_linediff <= 0)){ _linediff = (_linediff + direction); } else { if ((((_linediff > 0)) && ((direction < 0)))){ _linediff = (_linediff + direction); }; }; start = ((_lines.length - maxLines) + _linediff); end = (start + maxLines); lines = _lines.slice(start, end); } else { lines = _lines; }; return (lines); } } }//package com.google.analytics.debug
Section 47
//DebugConfiguration (com.google.analytics.debug.DebugConfiguration) package com.google.analytics.debug { import com.google.analytics.core.*; import flash.net.*; import flash.utils.*; import flash.ui.*; public class DebugConfiguration { public var showHideKey:Number; private var _mode:VisualDebugMode; private var _verbose:Boolean;// = false public var destroyKey:Number; public var GIFRequests:Boolean;// = false public var infoTimeout:Number;// = 1000 public var showInfos:Boolean;// = true public var minimizedOnStart:Boolean;// = false private var _active:Boolean;// = false public var traceOutput:Boolean;// = false public var layout:ILayout; public var warningTimeout:Number;// = 1500 public var javascript:Boolean;// = false public var showWarnings:Boolean;// = true private var _visualInitialized:Boolean;// = false public function DebugConfiguration(){ _active = false; _verbose = false; _visualInitialized = false; _mode = VisualDebugMode.basic; traceOutput = false; javascript = false; GIFRequests = false; showInfos = true; infoTimeout = 1000; showWarnings = true; warningTimeout = 1500; minimizedOnStart = false; showHideKey = Keyboard.SPACE; destroyKey = Keyboard.BACKSPACE; super(); } public function get verbose():Boolean{ return (_verbose); } public function set verbose(value:Boolean):void{ _verbose = value; } public function set mode(value):void{ if ((value is String)){ switch (value){ case "geek": value = VisualDebugMode.geek; break; case "advanced": value = VisualDebugMode.advanced; break; case "basic": default: value = VisualDebugMode.basic; }; }; _mode = value; } public function success(message:String):void{ if (layout){ layout.createSuccessAlert(message); }; if (traceOutput){ trace((("[+] " + message) + " !!")); }; } public function get active():Boolean{ return (_active); } private function _initializeVisual():void{ if (layout){ layout.init(); _visualInitialized = true; }; } private function _destroyVisual():void{ if (((layout) && (_visualInitialized))){ layout.destroy(); }; } public function warning(message:String, mode:VisualDebugMode=null):void{ if (_filter(mode)){ return; }; if (((layout) && (showWarnings))){ layout.createWarning(message); }; if (traceOutput){ trace((("## " + message) + " ##")); }; } private function _filter(mode:VisualDebugMode=null):Boolean{ return (((mode) && ((int(mode) >= int(this.mode))))); } public function failure(message:String):void{ if (layout){ layout.createFailureAlert(message); }; if (traceOutput){ trace((("[-] " + message) + " !!")); }; } public function get mode(){ return (_mode); } public function set active(value:Boolean):void{ _active = value; if (_active){ _initializeVisual(); } else { _destroyVisual(); }; } protected function trace(message:String):void{ var messages:Array; var pre0:String; var pre1:String; var len:int; var i:int; var msgs:Array; var j:int; messages = []; pre0 = ""; pre1 = ""; if (this.mode == VisualDebugMode.geek){ pre0 = (getTimer() + " - "); pre1 = (new Array(pre0.length).join(" ") + " "); }; if (message.indexOf("\n") > -1){ msgs = message.split("\n"); j = 0; while (j < msgs.length) { if (msgs[j] == ""){ } else { if (j == 0){ messages.push((pre0 + msgs[j])); } else { messages.push((pre1 + msgs[j])); }; }; j++; }; } else { messages.push((pre0 + message)); }; len = messages.length; i = 0; while (i < len) { trace(messages[i]); i++; }; } public function alert(message:String):void{ if (layout){ layout.createAlert(message); }; if (traceOutput){ trace((("!! " + message) + " !!")); }; } public function info(message:String, mode:VisualDebugMode=null):void{ if (_filter(mode)){ return; }; if (((layout) && (showInfos))){ layout.createInfo(message); }; if (traceOutput){ trace(message); }; } public function alertGifRequest(message:String, request:URLRequest, ref:GIFRequest):void{ if (layout){ layout.createGIFRequestAlert(message, request, ref); }; if (traceOutput){ trace(((">> " + message) + " <<")); }; } } }//package com.google.analytics.debug
Section 48
//FailureAlert (com.google.analytics.debug.FailureAlert) package com.google.analytics.debug { public class FailureAlert extends Alert { public function FailureAlert(debug:DebugConfiguration, text:String, actions:Array){ var alignement:Align; var stickToEdge:Boolean; var actionOnNextLine:Boolean; alignement = Align.bottomLeft; stickToEdge = true; actionOnNextLine = false; if (debug.verbose){ text = ((("<u><span class=\"uiAlertTitle\">Failure</span>" + spaces(18)) + "</u>\n\n") + text); alignement = Align.center; stickToEdge = false; actionOnNextLine = true; }; super(text, actions, "uiFailure", Style.failureColor, alignement, stickToEdge, actionOnNextLine); } } }//package com.google.analytics.debug
Section 49
//GIFRequestAlert (com.google.analytics.debug.GIFRequestAlert) package com.google.analytics.debug { public class GIFRequestAlert extends Alert { public function GIFRequestAlert(text:String, actions:Array){ super(text, actions); } } }//package com.google.analytics.debug
Section 50
//ILayout (com.google.analytics.debug.ILayout) package com.google.analytics.debug { import flash.display.*; import com.google.analytics.core.*; import flash.net.*; public interface ILayout { function createWarning(:String):void; function addToStage(:DisplayObject):void; function createGIFRequestAlert(_arg1:String, _arg2:URLRequest, _arg3:GIFRequest):void; function createPanel(_arg1:String, _arg2:uint, _arg3:uint):void; function createInfo(:String):void; function createFailureAlert(:String):void; function addToPanel(_arg1:String, _arg2:DisplayObject):void; function init():void; function createSuccessAlert(:String):void; function createVisualDebug():void; function createAlert(:String):void; function destroy():void; function bringToFront(:DisplayObject):void; function isAvailable():Boolean; } }//package com.google.analytics.debug
Section 51
//Info (com.google.analytics.debug.Info) package com.google.analytics.debug { import flash.events.*; import flash.utils.*; public class Info extends Label { private var _timer:Timer; public function Info(text:String="", timeout:uint=3000){ super(text, "uiInfo", Style.infoColor, Align.top, true); if (timeout > 0){ _timer = new Timer(timeout, 1); _timer.start(); _timer.addEventListener(TimerEvent.TIMER_COMPLETE, onComplete, false, 0, true); }; } public function onComplete(event:TimerEvent):void{ close(); } override public function onLink(event:TextEvent):void{ switch (event.text){ case "hide": close(); break; }; } public function close():void{ if (parent != null){ parent.removeChild(this); }; } } }//package com.google.analytics.debug
Section 52
//Label (com.google.analytics.debug.Label) package com.google.analytics.debug { import flash.events.*; import flash.display.*; import flash.text.*; public class Label extends UISprite { private var _text:String; private var _textField:TextField; private var _color:uint; protected var selectable:Boolean; public var stickToEdge:Boolean; private var _background:Shape; private var _tag:String; public static var count:uint = 0; public function Label(text:String="", tag:String="uiLabel", color:uint=0, alignement:Align=null, stickToEdge:Boolean=false){ super(); this.name = ("Label" + count++); selectable = false; _background = new Shape(); _textField = new TextField(); _text = text; _tag = tag; if (alignement == null){ alignement = Align.none; }; this.alignement = alignement; this.stickToEdge = stickToEdge; if (color == 0){ color = Style.backgroundColor; }; _color = color; _textField.addEventListener(TextEvent.LINK, onLink); } override protected function dispose():void{ _textField.removeEventListener(TextEvent.LINK, onLink); super.dispose(); } private function _draw():void{ var g:Graphics; var W:uint; var H:uint; g = _background.graphics; g.clear(); g.beginFill(_color); W = _textField.width; H = _textField.height; if (forcedWidth > 0){ W = forcedWidth; }; Background.drawRounded(this, g, W, H); g.endFill(); } override protected function layout():void{ _textField.type = TextFieldType.DYNAMIC; _textField.autoSize = TextFieldAutoSize.LEFT; _textField.background = false; _textField.selectable = selectable; _textField.multiline = true; _textField.styleSheet = Style.sheet; this.text = _text; addChild(_background); addChild(_textField); } public function get text():String{ return (_textField.text); } public function set tag(value:String):void{ _tag = value; text = ""; } public function set text(value:String):void{ if (value == ""){ value = _text; }; _textField.htmlText = (((("<span class=\"" + tag) + "\">") + value) + "</span>"); _text = value; _draw(); resize(); } public function appendText(value:String, newtag:String=""):void{ if (value == ""){ return; }; if (newtag == ""){ newtag = tag; }; _textField.htmlText = (_textField.htmlText + (((("<span class=\"" + newtag) + "\">") + value) + "</span>")); _text = (_text + value); _draw(); resize(); } public function onLink(event:TextEvent):void{ } public function get tag():String{ return (_tag); } } }//package com.google.analytics.debug
Section 53
//Layout (com.google.analytics.debug.Layout) package com.google.analytics.debug { import flash.events.*; import flash.display.*; import com.google.analytics.core.*; import flash.net.*; import com.google.analytics.*; public class Layout implements ILayout { private var _display:DisplayObject; private var _infoQueue:Array; private var _maxCharPerLine:int;// = 85 private var _hasInfo:Boolean; private var _warningQueue:Array; private var _hasDebug:Boolean; private var _hasWarning:Boolean; private var _mainPanel:Panel; private var _GRAlertQueue:Array; private var _debug:DebugConfiguration; public var visualDebug:Debug; private var _hasGRAlert:Boolean; public function Layout(debug:DebugConfiguration, display:DisplayObject){ _maxCharPerLine = 85; super(); _display = display; _debug = debug; _hasWarning = false; _hasInfo = false; _hasDebug = false; _hasGRAlert = false; _warningQueue = []; _infoQueue = []; _GRAlertQueue = []; } private function onKey(event:KeyboardEvent=null):void{ switch (event.keyCode){ case _debug.showHideKey: _mainPanel.visible = !(_mainPanel.visible); break; case _debug.destroyKey: destroy(); break; }; } public function bringToFront(visual:DisplayObject):void{ _display.stage.setChildIndex(visual, (_display.stage.numChildren - 1)); } public function createFailureAlert(message:String):void{ var actionClose:AlertAction; var fa:Alert; if (_debug.verbose){ message = _filterMaxChars(message); actionClose = new AlertAction("Close", "close", "close"); } else { actionClose = new AlertAction("X", "close", "close"); }; fa = new FailureAlert(_debug, message, [actionClose]); addToPanel("analytics", fa); if (_hasDebug){ if (_debug.verbose){ message = message.split("\n").join(""); message = _filterMaxChars(message, 66); }; visualDebug.writeBold(message); }; } public function init():void{ var spaces:int; var W:uint; var H:uint; var mp:Panel; spaces = 10; W = (_display.stage.stageWidth - (spaces * 2)); H = (_display.stage.stageHeight - (spaces * 2)); mp = new Panel("analytics", W, H); mp.alignement = Align.top; mp.stickToEdge = false; mp.title = ("Google Analytics v" + GATracker.version); _mainPanel = mp; addToStage(mp); bringToFront(mp); if (_debug.minimizedOnStart){ _mainPanel.onToggle(); }; createVisualDebug(); _display.stage.addEventListener(KeyboardEvent.KEY_DOWN, onKey, false, 0, true); } public function addToPanel(name:String, visual:DisplayObject):void{ var d:DisplayObject; var panel:Panel; d = _display.stage.getChildByName(name); if (d){ panel = (d as Panel); panel.addData(visual); } else { trace((("panel \"" + name) + "\" not found")); }; } private function _clearInfo(event:Event):void{ _hasInfo = false; if (_infoQueue.length > 0){ createInfo(_infoQueue.shift()); }; } private function _filterMaxChars(message:String, maxCharPerLine:int=0):String{ var CRLF:String; var output:Array; var lines:Array; var line:String; var i:int; CRLF = "\n"; output = []; lines = message.split(CRLF); if (maxCharPerLine == 0){ maxCharPerLine = _maxCharPerLine; }; i = 0; while (i < lines.length) { line = lines[i]; while (line.length > maxCharPerLine) { output.push(line.substr(0, maxCharPerLine)); line = line.substring(maxCharPerLine); }; output.push(line); i++; }; return (output.join(CRLF)); } public function createWarning(message:String):void{ var w:Warning; if (((_hasWarning) || (!(isAvailable())))){ _warningQueue.push(message); return; }; message = _filterMaxChars(message); _hasWarning = true; w = new Warning(message, _debug.warningTimeout); addToPanel("analytics", w); w.addEventListener(Event.REMOVED_FROM_STAGE, _clearWarning, false, 0, true); if (_hasDebug){ visualDebug.writeBold(message); }; } private function _clearGRAlert(event:Event):void{ _hasGRAlert = false; if (_GRAlertQueue.length > 0){ createGIFRequestAlert.apply(this, _GRAlertQueue.shift()); }; } public function createSuccessAlert(message:String):void{ var actionClose:AlertAction; var sa:Alert; if (_debug.verbose){ message = _filterMaxChars(message); actionClose = new AlertAction("Close", "close", "close"); } else { actionClose = new AlertAction("X", "close", "close"); }; sa = new SuccessAlert(_debug, message, [actionClose]); addToPanel("analytics", sa); if (_hasDebug){ if (_debug.verbose){ message = message.split("\n").join(""); message = _filterMaxChars(message, 66); }; visualDebug.writeBold(message); }; } public function isAvailable():Boolean{ return (!((_display.stage == null))); } public function createAlert(message:String):void{ var a:Alert; message = _filterMaxChars(message); a = new Alert(message, [new AlertAction("Close", "close", "close")]); addToPanel("analytics", a); if (_hasDebug){ visualDebug.writeBold(message); }; } public function createInfo(message:String):void{ var i:Info; if (((_hasInfo) || (!(isAvailable())))){ _infoQueue.push(message); return; }; message = _filterMaxChars(message); _hasInfo = true; i = new Info(message, _debug.infoTimeout); addToPanel("analytics", i); i.addEventListener(Event.REMOVED_FROM_STAGE, _clearInfo, false, 0, true); if (_hasDebug){ visualDebug.write(message); }; } public function createGIFRequestAlert(message:String, request:URLRequest, ref:GIFRequest):void{ var f:Function; var gra:GIFRequestAlert; var message = message; var request = request; var ref = ref; if (_hasGRAlert){ _GRAlertQueue.push([message, request, ref]); return; }; _hasGRAlert = true; f = function ():void{ ref.sendRequest(request); }; message = _filterMaxChars(message); gra = new GIFRequestAlert(message, [new AlertAction("OK", "ok", f), new AlertAction("Cancel", "cancel", "close")]); addToPanel("analytics", gra); gra.addEventListener(Event.REMOVED_FROM_STAGE, _clearGRAlert, false, 0, true); if (_hasDebug){ if (_debug.verbose){ message = message.split("\n").join(""); message = _filterMaxChars(message, 66); }; visualDebug.write(message); }; } public function createVisualDebug():void{ if (!visualDebug){ visualDebug = new Debug(); visualDebug.alignement = Align.bottom; visualDebug.stickToEdge = true; addToPanel("analytics", visualDebug); _hasDebug = true; }; } public function addToStage(visual:DisplayObject):void{ _display.stage.addChild(visual); } private function _clearWarning(event:Event):void{ _hasWarning = false; if (_warningQueue.length > 0){ createWarning(_warningQueue.shift()); }; } public function createPanel(name:String, width:uint, height:uint):void{ var p:Panel; p = new Panel(name, width, height); p.alignement = Align.center; p.stickToEdge = false; addToStage(p); bringToFront(p); } public function destroy():void{ _mainPanel.close(); _debug.layout = null; } } }//package com.google.analytics.debug
Section 54
//Margin (com.google.analytics.debug.Margin) package com.google.analytics.debug { public class Margin { public var bottom:int; public var top:int; public var right:int; public var left:int; public function Margin(top:int=0, bottom:int=0, left:int=0, right:int=0){ super(); this.top = top; this.bottom = bottom; this.left = left; this.right = right; } } }//package com.google.analytics.debug
Section 55
//Panel (com.google.analytics.debug.Panel) package com.google.analytics.debug { import flash.events.*; import flash.display.*; public class Panel extends UISprite { protected var baseAlpha:Number; private var _border:Shape; private var _name:String; private var _title:Label; private var _data:UISprite; private var _backgroundColor:uint; private var _colapsed:Boolean; private var _stickToEdge:Boolean; private var _background:Shape; private var _savedW:uint; private var _mask:Sprite; private var _savedH:uint; private var _borderColor:uint; public function Panel(name:String, width:uint, height:uint, backgroundColor:uint=0, borderColor:uint=0, baseAlpha:Number=0.3, alignement:Align=null, stickToEdge:Boolean=false){ super(); _name = name; this.name = name; this.mouseEnabled = false; _colapsed = false; forcedWidth = width; forcedHeight = height; this.baseAlpha = baseAlpha; _background = new Shape(); _data = new UISprite(); _data.forcedWidth = width; _data.forcedHeight = height; _data.mouseEnabled = false; _title = new Label(name, "uiLabel", 0xFFFFFF, Align.topLeft, stickToEdge); _title.buttonMode = true; _title.margin.top = 0.6; _title.margin.left = 0.6; _title.addEventListener(MouseEvent.CLICK, onToggle); _title.mouseChildren = false; _border = new Shape(); _mask = new Sprite(); _mask.useHandCursor = false; _mask.mouseEnabled = false; _mask.mouseChildren = false; if (alignement == null){ alignement = Align.none; }; this.alignement = alignement; this.stickToEdge = stickToEdge; if (backgroundColor == 0){ backgroundColor = Style.backgroundColor; }; _backgroundColor = backgroundColor; if (borderColor == 0){ borderColor = Style.borderColor; }; _borderColor = borderColor; } public function set stickToEdge(value:Boolean):void{ _stickToEdge = value; _title.stickToEdge = value; } public function onToggle(event:MouseEvent=null):void{ if (_colapsed){ _data.visible = true; } else { _data.visible = false; }; _colapsed = !(_colapsed); _update(); resize(); } override protected function dispose():void{ _title.removeEventListener(MouseEvent.CLICK, onToggle); super.dispose(); } private function _draw():void{ var W:uint; var H:uint; var g0:Graphics; var g01:Graphics; var g1:Graphics; var g2:Graphics; if (((_savedW) && (_savedH))){ forcedWidth = _savedW; forcedHeight = _savedH; }; if (!_colapsed){ W = forcedWidth; H = forcedHeight; } else { W = _title.width; H = _title.height; _savedW = forcedWidth; _savedH = forcedHeight; forcedWidth = W; forcedHeight = H; }; g0 = _background.graphics; g0.clear(); g0.beginFill(_backgroundColor); Background.drawRounded(this, g0, W, H); g0.endFill(); g01 = _data.graphics; g01.clear(); g01.beginFill(_backgroundColor, 0); Background.drawRounded(this, g01, W, H); g01.endFill(); g1 = _border.graphics; g1.clear(); g1.lineStyle(0.1, _borderColor); Background.drawRounded(this, g1, W, H); g1.endFill(); g2 = _mask.graphics; g2.clear(); g2.beginFill(_backgroundColor); Background.drawRounded(this, g2, (W + 1), (H + 1)); g2.endFill(); } override protected function layout():void{ _update(); addChild(_background); addChild(_data); addChild(_title); addChild(_border); addChild(_mask); mask = _mask; } public function get title():String{ return (_title.text); } public function get stickToEdge():Boolean{ return (_stickToEdge); } public function set title(value:String):void{ _title.text = value; } private function _update():void{ _draw(); if (baseAlpha < 1){ _background.alpha = baseAlpha; _border.alpha = baseAlpha; }; } public function addData(child:DisplayObject):void{ _data.addChild(child); } public function close():void{ dispose(); if (parent != null){ parent.removeChild(this); }; } } }//package com.google.analytics.debug
Section 56
//Style (com.google.analytics.debug.Style) package com.google.analytics.debug { public const Style:_Style = new _Style(); }//package com.google.analytics.debug
Section 57
//SuccessAlert (com.google.analytics.debug.SuccessAlert) package com.google.analytics.debug { public class SuccessAlert extends Alert { public function SuccessAlert(debug:DebugConfiguration, text:String, actions:Array){ var alignement:Align; var stickToEdge:Boolean; var actionOnNextLine:Boolean; alignement = Align.bottomLeft; stickToEdge = true; actionOnNextLine = false; if (debug.verbose){ text = ((("<u><span class=\"uiAlertTitle\">Success</span>" + spaces(18)) + "</u>\n\n") + text); alignement = Align.center; stickToEdge = false; actionOnNextLine = true; }; super(text, actions, "uiSuccess", Style.successColor, alignement, stickToEdge, actionOnNextLine); } } }//package com.google.analytics.debug
Section 58
//UISprite (com.google.analytics.debug.UISprite) package com.google.analytics.debug { import flash.events.*; import flash.display.*; public class UISprite extends Sprite { private var _forcedHeight:uint; protected var listenResize:Boolean; public var alignement:Align; private var _forcedWidth:uint; public var margin:Margin; protected var alignTarget:DisplayObject; public function UISprite(alignTarget:DisplayObject=null){ super(); listenResize = false; alignement = Align.none; this.alignTarget = alignTarget; margin = new Margin(); addEventListener(Event.ADDED_TO_STAGE, _onAddedToStage); addEventListener(Event.REMOVED_FROM_STAGE, _onRemovedFromStage); } protected function dispose():void{ var d:DisplayObject; var i:int; i = 0; while (i < numChildren) { d = getChildAt(i); if (d){ removeChild(d); }; i++; }; } protected function layout():void{ } public function get forcedHeight():uint{ if (_forcedHeight){ return (_forcedHeight); }; return (height); } public function alignTo(alignement:Align, target:DisplayObject=null):void{ var H:uint; var W:uint; var X:uint; var Y:uint; var t:UISprite; if (target == null){ if ((parent is Stage)){ target = this.stage; } else { target = parent; }; }; if (target == this.stage){ if (this.stage == null){ return; }; H = this.stage.stageHeight; W = this.stage.stageWidth; X = 0; Y = 0; } else { t = (target as UISprite); if (t.forcedHeight){ H = t.forcedHeight; } else { H = t.height; }; if (t.forcedWidth){ W = t.forcedWidth; } else { W = t.width; }; X = 0; Y = 0; }; switch (alignement){ case Align.top: x = ((W / 2) - (forcedWidth / 2)); y = (Y + margin.top); break; case Align.bottom: x = ((W / 2) - (forcedWidth / 2)); y = (((Y + H) - forcedHeight) - margin.bottom); break; case Align.left: x = (X + margin.left); y = ((H / 2) - (forcedHeight / 2)); break; case Align.right: x = (((X + W) - forcedWidth) - margin.right); y = ((H / 2) - (forcedHeight / 2)); break; case Align.center: x = ((W / 2) - (forcedWidth / 2)); y = ((H / 2) - (forcedHeight / 2)); break; case Align.topLeft: x = (X + margin.left); y = (Y + margin.top); break; case Align.topRight: x = (((X + W) - forcedWidth) - margin.right); y = (Y + margin.top); break; case Align.bottomLeft: x = (X + margin.left); y = (((Y + H) - forcedHeight) - margin.bottom); break; case Align.bottomRight: x = (((X + W) - forcedWidth) - margin.right); y = (((Y + H) - forcedHeight) - margin.bottom); break; }; if (((!(listenResize)) && (!((alignement == Align.none))))){ target.addEventListener(Event.RESIZE, onResize, false, 0, true); listenResize = true; }; this.alignement = alignement; this.alignTarget = target; } public function get forcedWidth():uint{ if (_forcedWidth){ return (_forcedWidth); }; return (width); } protected function onResize(event:Event):void{ resize(); } private function _onRemovedFromStage(event:Event):void{ removeEventListener(Event.ADDED_TO_STAGE, _onAddedToStage); removeEventListener(Event.REMOVED_FROM_STAGE, _onRemovedFromStage); dispose(); } public function resize():void{ if (alignement != Align.none){ alignTo(alignement, alignTarget); }; } private function _onAddedToStage(event:Event):void{ layout(); resize(); } public function set forcedHeight(value:uint):void{ _forcedHeight = value; } public function set forcedWidth(value:uint):void{ _forcedWidth = value; } } }//package com.google.analytics.debug
Section 59
//Warning (com.google.analytics.debug.Warning) package com.google.analytics.debug { import flash.events.*; import flash.utils.*; public class Warning extends Label { private var _timer:Timer; public function Warning(text:String="", timeout:uint=3000){ super(text, "uiWarning", Style.warningColor, Align.top, false); margin.top = 32; if (timeout > 0){ _timer = new Timer(timeout, 1); _timer.start(); _timer.addEventListener(TimerEvent.TIMER_COMPLETE, onComplete, false, 0, true); }; } public function onComplete(event:TimerEvent):void{ close(); } override public function onLink(event:TextEvent):void{ switch (event.text){ case "hide": close(); break; }; } public function close():void{ if (parent != null){ parent.removeChild(this); }; } } }//package com.google.analytics.debug
Section 60
//VisualDebugMode (com.google.analytics.debug.VisualDebugMode) package com.google.analytics.debug { public class VisualDebugMode { private var _value:int; private var _name:String; public static const advanced:VisualDebugMode = new VisualDebugMode(1, "advanced"); ; public static const geek:VisualDebugMode = new VisualDebugMode(2, "geek"); ; public static const basic:VisualDebugMode = new VisualDebugMode(0, "basic"); ; public function VisualDebugMode(value:int=0, name:String=""){ super(); _value = value; _name = name; } public function valueOf():int{ return (_value); } public function toString():String{ return (_name); } } }//package com.google.analytics.debug
Section 61
//Item (com.google.analytics.ecommerce.Item) package com.google.analytics.ecommerce { import com.google.analytics.utils.*; public class Item { private var _id:String; private var _price:String; private var _sku:String; private var _category:String; private var _name:String; private var _quantity:String; public function Item(id:String, sku:String, name:String, category:String, price:String, quantity:String){ super(); this._id = id; this._sku = sku; this._name = name; this._category = category; this._price = price; this._quantity = quantity; } public function set category(value:String):void{ _category = value; } public function get name():String{ return (_name); } public function get price():String{ return (_price); } public function get quantity():String{ return (_quantity); } public function set name(value:String):void{ _name = value; } public function set price(value:String):void{ _price = value; } public function get id():String{ return (_id); } public function get sku():String{ return (_sku); } public function set quantity(value:String):void{ _quantity = value; } public function toGifParams():Variables{ var vars:Variables; vars = new Variables(); vars.URIencode = true; vars.post = ["utmt", "utmtid", "utmipc", "utmipn", "utmiva", "utmipr", "utmiqt"]; vars.utmt = "item"; vars.utmtid = _id; vars.utmipc = _sku; vars.utmipn = _name; vars.utmiva = _category; vars.utmipr = _price; vars.utmiqt = _quantity; return (vars); } public function set id(value:String):void{ _id = value; } public function set sku(value:String):void{ _sku = value; } public function get category():String{ return (_category); } } }//package com.google.analytics.ecommerce
Section 62
//Transaction (com.google.analytics.ecommerce.Transaction) package com.google.analytics.ecommerce { import com.google.analytics.utils.*; public class Transaction { private var _items:Array; private var _total:String; private var _vars:Variables; private var _shipping:String; private var _city:String; private var _state:String; private var _country:String; private var _tax:String; private var _affiliation:String; private var _id:String; public function Transaction(id:String, affiliation:String, total:String, tax:String, shipping:String, city:String, state:String, country:String){ super(); this._id = id; this._affiliation = affiliation; this._total = total; this._tax = tax; this._shipping = shipping; this._city = city; this._state = state; this._country = country; _items = new Array(); } public function get total():String{ return (_total); } public function getItemFromArray(i:Number):Item{ return (_items[i]); } public function getItem(sku:String):Item{ var i:Number; i = 0; while (i < _items.length) { if (_items[i].sku == sku){ return (_items[i]); }; i++; }; return (null); } public function set total(value:String):void{ _total = value; } public function getItemsLength():Number{ return (_items.length); } public function addItem(sku:String, name:String, category:String, price:String, quantity:String):void{ var newItem:Item; newItem = getItem(sku); if (newItem == null){ newItem = new Item(_id, sku, name, category, price, quantity); _items.push(newItem); } else { newItem.name = name; newItem.category = category; newItem.price = price; newItem.quantity = quantity; }; } public function set shipping(value:String):void{ _shipping = value; } public function get country():String{ return (_country); } public function get state():String{ return (_state); } public function set tax(value:String):void{ _tax = value; } public function set affiliation(value:String):void{ _affiliation = value; } public function set state(value:String):void{ _state = value; } public function get id():String{ return (_id); } public function get tax():String{ return (_tax); } public function toGifParams():Variables{ var vars:Variables; vars = new Variables(); vars.URIencode = true; vars.utmt = "tran"; vars.utmtid = id; vars.utmtst = affiliation; vars.utmtto = total; vars.utmttx = tax; vars.utmtsp = shipping; vars.utmtci = city; vars.utmtrg = state; vars.utmtco = country; vars.post = ["utmtid", "utmtst", "utmtto", "utmttx", "utmtsp", "utmtci", "utmtrg", "utmtco"]; return (vars); } public function get affiliation():String{ return (_affiliation); } public function get city():String{ return (_city); } public function get shipping():String{ return (_shipping); } public function set id(value:String):void{ _id = value; } public function set city(value:String):void{ _city = value; } public function set country(value:String):void{ _country = value; } } }//package com.google.analytics.ecommerce
Section 63
//AnalyticsEvent (com.google.analytics.events.AnalyticsEvent) package com.google.analytics.events { import flash.events.*; import com.google.analytics.*; public class AnalyticsEvent extends Event { public var tracker:AnalyticsTracker; public static const READY:String = "ready"; public function AnalyticsEvent(type:String, tracker:AnalyticsTracker, bubbles:Boolean=false, cancelable:Boolean=false){ super(type, bubbles, cancelable); this.tracker = tracker; } override public function clone():Event{ return (new AnalyticsEvent(type, tracker, bubbles, cancelable)); } } }//package com.google.analytics.events
Section 64
//AdSenseGlobals (com.google.analytics.external.AdSenseGlobals) package com.google.analytics.external { import com.google.analytics.debug.*; public class AdSenseGlobals extends JavascriptProxy { private var _gaGlobalVerified:Boolean;// = false public static var gaGlobal_js:XML = <script> <![CDATA[ function() { try { gaGlobal } catch(e) { gaGlobal = {} ; } } ]]> </script> ; public function AdSenseGlobals(debug:DebugConfiguration){ _gaGlobalVerified = false; super(debug); } public function set vid(value:String):void{ if (!isAvailable()){ return; }; _verify(); setProperty("gaGlobal.vid", value); } public function get hid():String{ if (!isAvailable()){ return (null); }; _verify(); return (getProperty("gaGlobal.hid")); } public function get dh():String{ if (!isAvailable()){ return (null); }; _verify(); return (getProperty("gaGlobal.dh")); } public function get gaGlobal():Object{ if (!isAvailable()){ return (null); }; _verify(); return (getProperty("gaGlobal")); } public function set hid(value:String):void{ if (!isAvailable()){ return; }; _verify(); setProperty("gaGlobal.hid", value); } public function get sid():String{ if (!isAvailable()){ return (null); }; _verify(); return (getProperty("gaGlobal.sid")); } private function _verify():void{ if (!_gaGlobalVerified){ executeBlock(gaGlobal_js); _gaGlobalVerified = true; }; } public function get vid():String{ if (!isAvailable()){ return (null); }; _verify(); return (getProperty("gaGlobal.vid")); } public function set sid(value:String):void{ if (!isAvailable()){ return; }; _verify(); setProperty("gaGlobal.sid", value); } } }//package com.google.analytics.external
Section 65
//HTMLDOM (com.google.analytics.external.HTMLDOM) package com.google.analytics.external { import com.google.analytics.debug.*; public class HTMLDOM extends JavascriptProxy { private var _referrer:String; private var _protocol:String; private var _host:String; private var _location:String; private var _pathname:String; private var _title:String; private var _characterSet:String; private var _search:String; private var _language:String; private var _colorDepth:String; public static var cache_properties_js:XML = <script> <![CDATA[ function() { var obj = {}; obj.host = document.location.host; obj.language = navigator.language ? navigator.language : navigator.browserLanguage; obj.characterSet = document.characterSet ? document.characterSet : document.charset; obj.colorDepth = window.screen.colorDepth; obj.location = document.location.toString(); obj.pathname = document.location.pathname; obj.protocol = document.location.protocol; obj.search = document.location.search; obj.referrer = document.referrer; obj.title = document.title; return obj; } ]]> </script> ; public function HTMLDOM(debug:DebugConfiguration){ super(debug); } public function get search():String{ if (_search){ return (_search); }; if (!isAvailable()){ return (null); }; _search = getProperty("document.location.search"); return (_search); } public function get location():String{ if (_location){ return (_location); }; if (!isAvailable()){ return (null); }; _location = getPropertyString("document.location"); return (_location); } public function get pathname():String{ if (_pathname){ return (_pathname); }; if (!isAvailable()){ return (null); }; _pathname = getProperty("document.location.pathname"); return (_pathname); } public function get referrer():String{ if (_referrer){ return (_referrer); }; if (!isAvailable()){ return (null); }; _referrer = getProperty("document.referrer"); return (_referrer); } public function get protocol():String{ if (_protocol){ return (_protocol); }; if (!isAvailable()){ return (null); }; _protocol = getProperty("document.location.protocol"); return (_protocol); } public function cacheProperties():void{ var obj:Object; if (!isAvailable()){ return; }; obj = call(cache_properties_js); if (obj){ _host = obj.host; _language = obj.language; _characterSet = obj.characterSet; _colorDepth = obj.colorDepth; _location = obj.location; _pathname = obj.pathname; _protocol = obj.protocol; _search = obj.search; _referrer = obj.referrer; _title = obj.title; }; } public function get colorDepth():String{ if (_colorDepth){ return (_colorDepth); }; if (!isAvailable()){ return (null); }; _colorDepth = getProperty("window.screen.colorDepth"); return (_colorDepth); } public function get title():String{ if (_title){ return (_title); }; if (!isAvailable()){ return (null); }; _title = getProperty("document.title"); return (_title); } public function get host():String{ if (_host){ return (_host); }; if (!isAvailable()){ return (null); }; _host = getProperty("document.location.host"); return (_host); } public function get characterSet():String{ var cs:String; if (_characterSet){ return (_characterSet); }; if (!isAvailable()){ return (null); }; cs = getProperty("document.characterSet"); if (cs == null){ cs = getProperty("document.charset"); }; _characterSet = cs; return (_characterSet); } public function get language():String{ var lang:String; if (_language){ return (_language); }; if (!isAvailable()){ return (null); }; lang = getProperty("navigator.language"); if (lang == null){ lang = getProperty("navigator.browserLanguage"); }; _language = lang; return (_language); } } }//package com.google.analytics.external
Section 66
//JavascriptProxy (com.google.analytics.external.JavascriptProxy) package com.google.analytics.external { import com.google.analytics.debug.*; import flash.system.*; import flash.external.*; public class JavascriptProxy { private var _notAvailableWarning:Boolean;// = true private var _debug:DebugConfiguration; public static var setProperty_js:XML = <script> <![CDATA[ function( path , value ) { var paths; var prop; if( path.indexOf(".") > 0 ) { paths = path.split("."); prop = paths.pop() ; } else { paths = []; prop = path; } var target = window ; var len = paths.length ; for( var i = 0 ; i < len ; i++ ) { target = target[ paths[i] ] ; } target[ prop ] = value ; } ]]> </script> ; public static var hasProperty_js:XML = <script> <![CDATA[ function( path ) { var paths; if( path.indexOf(".") > 0 ) { paths = path.split("."); } else { paths = [path]; } var target = window ; var len = paths.length ; for( var i = 0 ; i < len ; i++ ) { target = target[ paths[i] ] ; } if( target ) { return true; } else { return false; } } ]]> </script> ; public static var setPropertyRef_js:XML = <script> <![CDATA[ function( path , target ) { var paths; var prop; if( path.indexOf(".") > 0 ) { paths = path.split("."); prop = paths.pop() ; } else { paths = []; prop = path; } alert( "paths:"+paths.length+", prop:"+prop ); var targets; var name; if( target.indexOf(".") > 0 ) { targets = target.split("."); name = targets.pop(); } else { targets = []; name = target; } alert( "targets:"+targets.length+", name:"+name ); var root = window; var len = paths.length; for( var i = 0 ; i < len ; i++ ) { root = root[ paths[i] ] ; } var ref = window; var depth = targets.length; for( var j = 0 ; j < depth ; j++ ) { ref = ref[ targets[j] ] ; } root[ prop ] = ref[name] ; } ]]> </script> ; public function JavascriptProxy(debug:DebugConfiguration){ _notAvailableWarning = true; super(); _debug = debug; } public function getProperty(name:String){ return (call((name + ".valueOf"))); } public function hasProperty(path:String):Boolean{ return (call(hasProperty_js, path)); } public function setProperty(path:String, value):void{ call(setProperty_js, path, value); } public function executeBlock(data:String):void{ var data = data; if (isAvailable()){ ExternalInterface.call(data); //unresolved jump var _slot1 = e; if (_debug.javascript){ _debug.warning("ExternalInterface is not allowed.\nEnsure that allowScriptAccess is set to \"always\" in the Flash embed HTML."); }; //unresolved jump var _slot1 = e; if (_debug.javascript){ _debug.warning(("ExternalInterface failed to make the call\nreason: " + _slot1.message)); }; }; } public function getPropertyString(name:String):String{ return (call((name + ".toString"))); } public function setPropertyByReference(path:String, target:String):void{ call(setPropertyRef_js, path, target); } public function call(functionName:String, ... _args){ var output:String; var functionName = functionName; var args = _args; if (isAvailable()){ if (((_debug.javascript) && (_debug.verbose))){ output = ""; output = ("Flash->JS: " + functionName); output = (output + "( "); if (args.length > 0){ output = (output + args.join(",")); }; output = (output + " )"); _debug.info(output); }; args.unshift(functionName); return (ExternalInterface.call.apply(ExternalInterface, args)); //unresolved jump var _slot1 = e; if (_debug.javascript){ _debug.warning("ExternalInterface is not allowed.\nEnsure that allowScriptAccess is set to \"always\" in the Flash embed HTML."); }; //unresolved jump var _slot1 = e; if (_debug.javascript){ _debug.warning(("ExternalInterface failed to make the call\nreason: " + _slot1.message)); }; }; return (null); } public function isAvailable():Boolean{ var available:Boolean; available = ExternalInterface.available; if (((available) && ((Capabilities.playerType == "External")))){ available = false; }; if (((((!(available)) && (_debug.javascript))) && (_notAvailableWarning))){ _debug.warning("ExternalInterface is not available."); _notAvailableWarning = false; }; return (available); } } }//package com.google.analytics.external
Section 67
//Environment (com.google.analytics.utils.Environment) package com.google.analytics.utils { import com.google.analytics.core.*; import com.google.analytics.debug.*; import com.google.analytics.external.*; import flash.system.*; public class Environment { private var _dom:HTMLDOM; private var _appName:String; private var _debug:DebugConfiguration; private var _appVersion:Version; private var _url:String; private var _protocol:Protocols; private var _userAgent:UserAgent; public function Environment(url:String="", app:String="", version:String="", debug:DebugConfiguration=null, dom:HTMLDOM=null){ var v:Version; super(); if (app == ""){ if (isAIR()){ app = "AIR"; } else { app = "Flash"; }; }; if (version == ""){ v = flashVersion; } else { v = Version.fromString(version); }; _url = url; _appName = app; _appVersion = v; _debug = debug; _dom = dom; } public function isAIR():Boolean{ return ((((playerType == "Desktop")) && ((Security.sandboxType.toString() == "application")))); } public function get playerType():String{ return (Capabilities.playerType); } public function get locationSearch():String{ var _search:String; _search = _dom.search; if (_search){ return (_search); }; return (""); } public function get protocol():Protocols{ if (!_protocol){ _findProtocol(); }; return (_protocol); } public function get flashVersion():Version{ var v:Version; v = Version.fromString(Capabilities.version.split(" ")[1], ","); return (v); } public function get screenWidth():Number{ return (Capabilities.screenResolutionX); } public function get languageEncoding():String{ var _charset:String; if (System.useCodePage){ _charset = _dom.characterSet; if (_charset){ return (_charset); }; return ("-"); }; return ("UTF-8"); } public function get appName():String{ return (_appName); } public function get screenColorDepth():String{ var color:String; var _colorDepth:String; switch (Capabilities.screenColor){ case "bw": color = "1"; break; case "gray": color = "2"; break; case "color": default: color = "24"; }; _colorDepth = _dom.colorDepth; if (_colorDepth){ color = _colorDepth; }; return (color); } private function _findProtocol():void{ var p:Protocols; var _proto:String; var proto:String; var URL:String; var test:String; p = Protocols.none; if (_url != ""){ URL = _url.toLowerCase(); test = URL.substr(0, 5); switch (test){ case "file:": p = Protocols.file; break; case "http:": p = Protocols.HTTP; break; case "https": if (URL.charAt(5) == ":"){ p = Protocols.HTTPS; }; break; default: _protocol = Protocols.none; }; }; _proto = _dom.protocol; proto = (p.toString() + ":").toLowerCase(); if (((((_proto) && (!((_proto == proto))))) && (_debug))){ _debug.warning(((("Protocol mismatch: SWF=" + proto) + ", DOM=") + _proto)); }; _protocol = p; } public function get locationSWFPath():String{ return (_url); } public function get platform():String{ var p:String; p = Capabilities.manufacturer; return (p.split("Adobe ")[1]); } public function get operatingSystem():String{ return (Capabilities.os); } public function set appName(value:String):void{ _appName = value; userAgent.applicationProduct = value; } public function get userAgent():UserAgent{ if (!_userAgent){ _userAgent = new UserAgent(this, appName, appVersion.toString(4)); }; return (_userAgent); } ga_internal function set url(value:String):void{ _url = value; } public function get referrer():String{ var _referrer:String; _referrer = _dom.referrer; if (_referrer){ return (_referrer); }; if (protocol == Protocols.file){ return ("localhost"); }; return (""); } public function isInHTML():Boolean{ return ((Capabilities.playerType == "PlugIn")); } public function get language():String{ var _lang:String; var lang:String; _lang = _dom.language; lang = Capabilities.language; if (_lang){ if ((((_lang.length > lang.length)) && ((_lang.substr(0, lang.length) == lang)))){ lang = _lang; }; }; return (lang); } public function get domainName():String{ var URL:String; var str:String; var end:int; if ((((protocol == Protocols.HTTP)) || ((protocol == Protocols.HTTPS)))){ URL = _url.toLowerCase(); if (protocol == Protocols.HTTP){ str = URL.split("http://").join(""); } else { if (protocol == Protocols.HTTPS){ str = URL.split("https://").join(""); }; }; end = str.indexOf("/"); if (end > -1){ str = str.substring(0, end); }; return (str); }; if (protocol == Protocols.file){ return ("localhost"); }; return (""); } public function set userAgent(custom:UserAgent):void{ _userAgent = custom; } public function set appVersion(value:Version):void{ _appVersion = value; userAgent.applicationVersion = value.toString(4); } public function get screenHeight():Number{ return (Capabilities.screenResolutionY); } public function get locationPath():String{ var _pathname:String; _pathname = _dom.pathname; if (_pathname){ return (_pathname); }; return (""); } public function get documentTitle():String{ var _title:String; _title = _dom.title; if (_title){ return (_title); }; return (""); } public function get appVersion():Version{ return (_appVersion); } } }//package com.google.analytics.utils
Section 68
//Protocols (com.google.analytics.utils.Protocols) package com.google.analytics.utils { public class Protocols { private var _value:int; private var _name:String; public static const none:Protocols = new Protocols(0, "none"); ; public static const HTTPS:Protocols = new Protocols(3, "HTTPS"); ; public static const file:Protocols = new Protocols(1, "file"); ; public static const HTTP:Protocols = new Protocols(2, "HTTP"); ; public function Protocols(value:int=0, name:String=""){ super(); _value = value; _name = name; } public function valueOf():int{ return (_value); } public function toString():String{ return (_name); } } }//package com.google.analytics.utils
Section 69
//Timespan (com.google.analytics.utils.Timespan) package com.google.analytics.utils { public class Timespan { public static var sixmonths:Number = 15768000; public static var twoyears:Number = 63072000; public static var thirtyminutes:Number = 1800; public function Timespan(){ super(); } } }//package com.google.analytics.utils
Section 70
//URL (com.google.analytics.utils.URL) package com.google.analytics.utils { public class URL { private var _url:String; public function URL(url:String=""){ super(); _url = url.toLowerCase(); } public function get domain():String{ var parts:Array; if (((!((hostName == ""))) && ((hostName.indexOf(".") > -1)))){ parts = hostName.split("."); switch (parts.length){ case 2: return (hostName); case 3: if (parts[1] == "co"){ return (hostName); }; parts.shift(); return (parts.join(".")); case 4: parts.shift(); return (parts.join(".")); }; }; return (""); } public function get path():String{ var _path:String; _path = _url; if (_path.indexOf("://") > -1){ _path = _path.split("://")[1]; }; if (_path.indexOf(hostName) == 0){ _path = _path.substr(hostName.length); }; if (_path.indexOf("?") > -1){ _path = _path.split("?")[0]; }; if (_path.charAt(0) != "/"){ _path = ("/" + _path); }; return (_path); } public function get search():String{ var _search:String; _search = _url; if (_search.indexOf("://") > -1){ _search = _search.split("://")[1]; }; if (_search.indexOf(hostName) == 0){ _search = _search.substr(hostName.length); }; if (_search.indexOf("?") > -1){ _search = _search.split("?")[1]; } else { _search = ""; }; return (_search); } public function get subDomain():String{ if (((!((domain == ""))) && (!((domain == hostName))))){ return (hostName.split(("." + domain)).join("")); }; return (""); } public function get protocol():Protocols{ var proto:String; proto = _url.split("://")[0]; switch (proto){ case "file": return (Protocols.file); case "http": return (Protocols.HTTP); case "https": return (Protocols.HTTPS); default: return (Protocols.none); }; } public function get hostName():String{ var hostname:String; hostname = _url; if (hostname.indexOf("://") > -1){ hostname = hostname.split("://")[1]; }; if (hostname.indexOf("/") > -1){ hostname = hostname.split("/")[0]; }; if (hostname.indexOf("?") > -1){ hostname = hostname.split("?")[0]; }; if ((((protocol == Protocols.file)) || ((protocol == Protocols.none)))){ return (""); }; return (hostname); } } }//package com.google.analytics.utils
Section 71
//UserAgent (com.google.analytics.utils.UserAgent) package com.google.analytics.utils { import com.google.analytics.core.*; import flash.system.*; public class UserAgent { private var _version:Version; private var _localInfo:Environment; private var _applicationProduct:String; public static var minimal:Boolean = false; public function UserAgent(localInfo:Environment, product:String="", version:String=""){ super(); _localInfo = localInfo; applicationProduct = product; _version = Version.fromString(version); } public function get tamarinProductToken():String{ if (UserAgent.minimal){ return (""); }; if (System.vmVersion){ return (("Tamarin/" + Utils.trim(System.vmVersion, true))); }; return (""); } public function set applicationProduct(value:String):void{ _applicationProduct = value; } public function get applicationVersion():String{ return (_version.toString(2)); } public function get applicationProductToken():String{ var token:String; token = applicationProduct; if (applicationVersion != ""){ token = (token + ("/" + applicationVersion)); }; return (token); } public function get vendorProductToken():String{ var vp:String; vp = ""; if (_localInfo.isAIR()){ vp = (vp + "AIR"); } else { vp = (vp + "FlashPlayer"); }; vp = (vp + "/"); vp = (vp + _version.toString(3)); return (vp); } public function toString():String{ var UA:String; UA = ""; UA = (UA + applicationProductToken); if (applicationComment != ""){ UA = (UA + (" " + applicationComment)); }; if (tamarinProductToken != ""){ UA = (UA + (" " + tamarinProductToken)); }; if (vendorProductToken != ""){ UA = (UA + (" " + vendorProductToken)); }; return (UA); } public function get applicationComment():String{ var comment:Array; comment = []; comment.push(_localInfo.platform); comment.push(_localInfo.playerType); if (!UserAgent.minimal){ comment.push(_localInfo.operatingSystem); comment.push(_localInfo.language); }; if (Capabilities.isDebugger){ comment.push("DEBUG"); }; if (comment.length > 0){ return ((("(" + comment.join("; ")) + ")")); }; return (""); } public function set applicationVersion(value:String):void{ _version = Version.fromString(value); } public function get applicationProduct():String{ return (_applicationProduct); } } }//package com.google.analytics.utils
Section 72
//Variables (com.google.analytics.utils.Variables) package com.google.analytics.utils { import flash.net.*; public dynamic class Variables { public var post:Array; public var URIencode:Boolean; public var pre:Array; public var sort:Boolean;// = true public function Variables(source:String=null, pre:Array=null, post:Array=null){ pre = []; post = []; sort = true; super(); if (source){ decode(source); }; if (pre){ this.pre = pre; }; if (post){ this.post = post; }; } private function _join(vars:Variables):void{ var prop:String; if (!vars){ return; }; for (prop in vars) { this[prop] = vars[prop]; }; } public function join(... _args):void{ var l:int; var i:int; l = _args.length; i = 0; while (i < l) { if (!(_args[i] is Variables)){ } else { _join(_args[i]); }; i++; }; } public function toString():String{ var data:Array; var value:String; var p:String; var component:String; var i:int; var j:int; var priority:String; var last:String; data = []; for (p in this) { value = this[p]; if (URIencode){ value = encodeURI(value); }; data.push(((p + "=") + value)); }; if (sort){ data.sort(); }; if (pre.length > 0){ pre.reverse(); i = 0; while (i < pre.length) { priority = pre[i]; j = 0; while (j < data.length) { component = data[j]; if (component.indexOf(priority) == 0){ data.unshift(data.splice(j, 1)[0]); }; j++; }; i++; }; pre.reverse(); }; if (post.length > 0){ i = 0; while (i < post.length) { last = post[i]; j = 0; while (j < data.length) { component = data[j]; if (component.indexOf(last) == 0){ data.push(data.splice(j, 1)[0]); }; j++; }; i++; }; }; return (data.join("&")); } public function decode(source:String):void{ var data:Array; var prop:String; var name:String; var value:String; var tmp:Array; var i:int; if (source == ""){ return; }; if (source.charAt(0) == "?"){ source = source.substr(1, source.length); }; if (source.indexOf("&") > -1){ data = source.split("&"); } else { data = [source]; }; i = 0; while (i < data.length) { prop = data[i]; if (prop.indexOf("=") > -1){ tmp = prop.split("="); name = tmp[0]; value = decodeURI(tmp[1]); this[name] = value; }; i++; }; } public function toURLVariables():URLVariables{ var urlvars:URLVariables; var p:String; urlvars = new URLVariables(); for (p in this) { urlvars[p] = this[p]; }; return (urlvars); } } }//package com.google.analytics.utils
Section 73
//Version (com.google.analytics.utils.Version) package com.google.analytics.utils { public class Version { private var _maxBuild:uint;// = 0xFF private var _maxMinor:uint;// = 15 private var _maxMajor:uint;// = 15 private var _revision:uint; private var _separator:String;// = "." private var _maxRevision:uint;// = 0xFFFF private var _build:uint; private var _minor:uint; private var _major:uint; public function Version(major:uint=0, minor:uint=0, build:uint=0, revision:uint=0){ var v:Version; _maxMajor = 15; _maxMinor = 15; _maxBuild = 0xFF; _maxRevision = 0xFFFF; _separator = "."; super(); if ((((((((major > _maxMajor)) && ((minor == 0)))) && ((build == 0)))) && ((revision == 0)))){ v = Version.fromNumber(major); major = v.major; minor = v.minor; build = v.build; revision = v.revision; }; this.major = major; this.minor = minor; this.build = build; this.revision = revision; } public function toString(fields:int=0):String{ var arr:Array; if ((((fields <= 0)) || ((fields > 4)))){ fields = getFields(); }; switch (fields){ case 1: arr = [major]; break; case 2: arr = [major, minor]; break; case 3: arr = [major, minor, build]; break; case 4: default: arr = [major, minor, build, revision]; }; return (arr.join(_separator)); } public function get revision():uint{ return (_revision); } public function set build(value:uint):void{ _build = Math.min(value, _maxBuild); } public function set minor(value:uint):void{ _minor = Math.min(value, _maxMinor); } public function get build():uint{ return (_build); } public function set major(value:uint):void{ _major = Math.min(value, _maxMajor); } public function get minor():uint{ return (_minor); } public function valueOf():uint{ return (((((major << 28) | (minor << 24)) | (build << 16)) | revision)); } public function get major():uint{ return (_major); } public function set revision(value:uint):void{ _revision = Math.min(value, _maxRevision); } private function getFields():int{ var f:int; f = 4; if (revision == 0){ f--; }; if ((((f == 3)) && ((build == 0)))){ f--; }; if ((((f == 2)) && ((minor == 0)))){ f--; }; return (f); } public function equals(o):Boolean{ if (!(o is Version)){ return (false); }; if ((((((((o.major == major)) && ((o.minor == minor)))) && ((o.build == build)))) && ((o.revision == revision)))){ return (true); }; return (false); } public static function fromString(value:String="", separator:String="."):Version{ var v:Version; var values:Array; v = new (Version); if ((((value == "")) || ((value == null)))){ return (v); }; if (value.indexOf(separator) > -1){ values = value.split(separator); v.major = parseInt(values[0]); v.minor = parseInt(values[1]); v.build = parseInt(values[2]); v.revision = parseInt(values[3]); } else { v.major = parseInt(value); }; return (v); } public static function fromNumber(value:Number=0):Version{ var v:Version; v = new (Version); if (((((((((((isNaN(value)) || ((value == 0)))) || ((value < 0)))) || ((value == Number.MAX_VALUE)))) || ((value == Number.POSITIVE_INFINITY)))) || ((value == Number.NEGATIVE_INFINITY)))){ return (v); }; v.major = (value >>> 28); v.minor = ((value & 251658240) >>> 24); v.build = ((value & 0xFF0000) >>> 16); v.revision = (value & 0xFFFF); return (v); } } }//package com.google.analytics.utils
Section 74
//Bridge (com.google.analytics.v4.Bridge) package com.google.analytics.v4 { import com.google.analytics.core.*; import com.google.analytics.debug.*; import com.google.analytics.external.*; public class Bridge implements GoogleAnalyticsAPI { private var _debug:DebugConfiguration; private var _proxy:JavascriptProxy; private var _jsContainer:String;// = "_GATracker" private var _hasGATracker:Boolean;// = false private var _account:String; private static var _linkTrackingObject_js:XML = <script> <![CDATA[ function( container , target ) { var targets ; var name ; if( target.indexOf(".") > 0 ) { targets = target.split("."); name = targets.pop(); } else { targets = []; name = target; } var ref = window; var depth = targets.length; for( var j = 0 ; j < depth ; j++ ) { ref = ref[ targets[j] ] ; } window[container][target] = ref[name] ; } ]]> </script> ; private static var _createTrackingObject_js:XML = <script> <![CDATA[ function( acct ) { _GATracker[acct] = _gat._getTracker(acct); } ]]> </script> ; private static var _injectTrackingObject_js:XML = <script> <![CDATA[ function() { try { _GATracker } catch(e) { _GATracker = {}; } } ]]> </script> ; private static var _checkGAJS_js:XML = <script> <![CDATA[ function() { if( _gat && _gat._getTracker ) { return true; } return false; } ]]> </script> ; private static var _checkValidTrackingObject_js:XML = <script> <![CDATA[ function(acct) { if( _GATracker[acct] && (_GATracker[acct]._getAccount) ) { return true ; } else { return false; } } ]]> </script> ; public function Bridge(account:String, debug:DebugConfiguration, jsproxy:JavascriptProxy){ var msg0:String; var msg1:String; var msg2:String; _hasGATracker = false; _jsContainer = "_GATracker"; super(); _account = account; _debug = debug; _proxy = jsproxy; if (!_checkGAJS()){ msg0 = ""; msg0 = (msg0 + "ga.js not found, be sure to check if\n"); msg0 = (msg0 + "<script src=\"http://www.google-analytics.com/ga.js\"></script>\n"); msg0 = (msg0 + "is included in the HTML."); _debug.warning(msg0); throw (new Error(msg0)); }; if (!_hasGATracker){ if (((_debug.javascript) && (_debug.verbose))){ msg1 = ""; msg1 = (msg1 + "The Google Analytics tracking code was not found on the container page\n"); msg1 = (msg1 + "we create it"); _debug.info(msg1, VisualDebugMode.advanced); }; _injectTrackingObject(); }; if (Utils.validateAccount(account)){ _createTrackingObject(account); } else { if (_checkTrackingObject(account)){ _linkTrackingObject(account); } else { msg2 = ""; msg2 = (msg2 + (("JS Object \"" + account) + "\" doesn't exist in DOM\n")); msg2 = (msg2 + "Bridge object not created."); _debug.warning(msg2); throw (new Error(msg2)); }; }; } public function link(targetUrl:String, useHash:Boolean=false):void{ _debug.info((((("link( " + targetUrl) + ", ") + useHash) + " )")); _call("_link", targetUrl, useHash); } public function addOrganic(newOrganicEngine:String, newOrganicKeyword:String):void{ _debug.info((("addOrganic( " + [newOrganicEngine, newOrganicKeyword].join(", ")) + " )")); _call("_addOrganic", newOrganicEngine); } public function setAllowLinker(enable:Boolean):void{ _debug.info((("setAllowLinker( " + enable) + " )")); _call("_setAllowLinker", enable); } public function getLinkerUrl(url:String="", useHash:Boolean=false):String{ _debug.info((((("getLinkerUrl(" + url) + ", ") + useHash) + ")")); return (_call("_getLinkerUrl", url, useHash)); } private function _linkTrackingObject(path:String):void{ _proxy.call(_linkTrackingObject_js, _jsContainer, path); } public function setClientInfo(enable:Boolean):void{ _debug.info((("setClientInfo( " + enable) + " )")); _call("_setClientInfo", enable); } public function trackTrans():void{ _debug.info("trackTrans()"); _call("_trackTrans"); } public function trackPageview(pageURL:String=""):void{ _debug.info((("trackPageview( " + pageURL) + " )")); _call("_trackPageview", pageURL); } public function setCookieTimeout(newDefaultTimeout:int):void{ _debug.info((("setCookieTimeout( " + newDefaultTimeout) + " )")); _call("_setCookieTimeout", newDefaultTimeout); } public function trackEvent(category:String, action:String, label:String=null, value:Number=NaN):Boolean{ var param:int; param = 2; if (((label) && (!((label == ""))))){ param = 3; }; if ((((param == 3)) && (!(isNaN(value))))){ param = 4; }; switch (param){ case 4: _debug.info((("trackEvent( " + [category, action, label, value].join(", ")) + " )")); return (_call("_trackEvent", category, action, label, value)); case 3: _debug.info((("trackEvent( " + [category, action, label].join(", ")) + " )")); return (_call("_trackEvent", category, action, label)); case 2: default: _debug.info((("trackEvent( " + [category, action].join(", ")) + " )")); return (_call("_trackEvent", category, action)); }; } private function _checkValidTrackingObject(account:String):Boolean{ return (_proxy.call(_checkValidTrackingObject_js, account)); } private function _checkGAJS():Boolean{ return (_proxy.call(_checkGAJS_js)); } public function linkByPost(formObject:Object, useHash:Boolean=false):void{ _debug.warning((((("linkByPost( " + formObject) + ", ") + useHash) + " ) not implemented")); } private function _call(functionName:String, ... _args){ _args.unshift(((((("window." + _jsContainer) + "[\"") + _account) + "\"].") + functionName)); return (_proxy.call.apply(_proxy, _args)); } public function hasGAJS():Boolean{ return (_checkGAJS()); } private function _checkTrackingObject(account:String):Boolean{ var hasObj:Boolean; var isTracker:Boolean; hasObj = _proxy.hasProperty(account); isTracker = _proxy.hasProperty((account + "._getAccount")); return (((hasObj) && (isTracker))); } public function resetSession():void{ _debug.warning("resetSession() not implemented"); } public function setDetectFlash(enable:Boolean):void{ _debug.info((("setDetectFlash( " + enable) + " )")); _call("_setDetectFlash", enable); } public function getDetectTitle():Boolean{ _debug.info("getDetectTitle()"); return (_call("_getDetectTitle")); } public function getClientInfo():Boolean{ _debug.info("getClientInfo()"); return (_call("_getClientInfo")); } public function setCampNameKey(newCampNameKey:String):void{ _debug.info((("setCampNameKey( " + newCampNameKey) + " )")); _call("_setCampNameKey", newCampNameKey); } public function createEventTracker(objName:String):EventTracker{ _debug.info((("createEventTracker( " + objName) + " )")); return (new EventTracker(objName, this)); } public function addItem(item:String, sku:String, name:String, category:String, price:Number, quantity:int):void{ _debug.info((("addItem( " + [item, sku, name, category, price, quantity].join(", ")) + " )")); _call("_addItem", item, sku, name, category, price, quantity); } public function clearIgnoredOrganic():void{ _debug.info("clearIgnoredOrganic()"); _call("_clearIgnoreOrganic"); } public function setVar(newVal:String):void{ _debug.info((("setVar( " + newVal) + " )")); _call("_setVar", newVal); } public function setDomainName(newDomainName:String):void{ _debug.info((("setDomainName( " + newDomainName) + " )")); _call("_setDomainName", newDomainName); } public function hasTrackingAccount(account:String):Boolean{ if (Utils.validateAccount(account)){ return (_checkValidTrackingObject(account)); }; return (_checkTrackingObject(account)); } public function addTrans(orderId:String, affiliation:String, total:Number, tax:Number, shipping:Number, city:String, state:String, country:String):void{ _debug.info((("addTrans( " + [orderId, affiliation, total, tax, shipping, city, state, country].join(", ")) + " )")); _call("_addTrans", orderId, affiliation, total, tax, shipping, city, state, country); } public function setCampSourceKey(newCampSrcKey:String):void{ _debug.info((("setCampSourceKey( " + newCampSrcKey) + " )")); _call("_setCampSourceKey", newCampSrcKey); } public function setCampContentKey(newCampContentKey:String):void{ _debug.info((("setCampContentKey( " + newCampContentKey) + " )")); _call("_setCampContentKey", newCampContentKey); } public function clearIgnoredRef():void{ _debug.info("clearIgnoredRef()"); _call("_clearIgnoreRef"); } public function setLocalServerMode():void{ _debug.info("setLocalServerMode()"); _call("_setLocalServerMode"); } public function getLocalGifPath():String{ _debug.info("getLocalGifPath()"); return (_call("_getLocalGifPath")); } public function setAllowAnchor(enable:Boolean):void{ _debug.info((("setAllowAnchor( " + enable) + " )")); _call("_setAllowAnchor", enable); } public function setLocalGifPath(newLocalGifPath:String):void{ _debug.info((("setLocalGifPath( " + newLocalGifPath) + " )")); _call("_setLocalGifPath", newLocalGifPath); } public function getVersion():String{ _debug.info("getVersion()"); return (_call("_getVersion")); } private function _injectTrackingObject():void{ _proxy.executeBlock(_injectTrackingObject_js); _hasGATracker = true; } public function setCookiePath(newCookiePath:String):void{ _debug.info((("setCookiePath( " + newCookiePath) + " )")); _call("_setCookiePath", newCookiePath); } public function setSampleRate(newRate:Number):void{ _debug.info((("setSampleRate( " + newRate) + " )")); _call("_setSampleRate", newRate); } public function setAllowHash(enable:Boolean):void{ _debug.info((("setAllowHash( " + enable) + " )")); _call("_setAllowHash", enable); } public function addIgnoredOrganic(newIgnoredOrganicKeyword:String):void{ _debug.info((("addIgnoredOrganic( " + newIgnoredOrganicKeyword) + " )")); _call("_addIgnoredOrganic", newIgnoredOrganicKeyword); } public function setCampNOKey(newCampNOKey:String):void{ _debug.info((("setCampNOKey( " + newCampNOKey) + " )")); _call("_setCampNOKey", newCampNOKey); } public function cookiePathCopy(newPath:String):void{ _debug.info((("cookiePathCopy( " + newPath) + " )")); _call("_cookiePathCopy", newPath); } public function setLocalRemoteServerMode():void{ _debug.info("setLocalRemoteServerMode()"); _call("_setLocalRemoteServerMode"); } public function getServiceMode():ServerOperationMode{ _debug.info("getServiceMode()"); return (_call("_getServiceMode")); } public function setDetectTitle(enable:Boolean):void{ _debug.info((("setDetectTitle( " + enable) + " )")); _call("_setDetectTitle", enable); } public function setCampTermKey(newCampTermKey:String):void{ _debug.info((("setCampTermKey( " + newCampTermKey) + " )")); _call("_setCampTermKey", newCampTermKey); } private function _createTrackingObject(account:String):void{ _proxy.call(_createTrackingObject_js, account); } public function getDetectFlash():Boolean{ _debug.info("getDetectFlash()"); return (_call("_getDetectFlash")); } public function setCampaignTrack(enable:Boolean):void{ _debug.info((("setCampaignTrack( " + enable) + " )")); _call("_setCampaignTrack", enable); } public function clearOrganic():void{ _debug.info("clearOrganic()"); _call("_clearOrganic"); } public function addIgnoredRef(newIgnoredReferrer:String):void{ _debug.info((("addIgnoredRef( " + newIgnoredReferrer) + " )")); _call("_addIgnoredRef", newIgnoredReferrer); } public function setCampMediumKey(newCampMedKey:String):void{ _debug.info((("setCampMediumKey( " + newCampMedKey) + " )")); _call("_setCampMediumKey", newCampMedKey); } public function setSessionTimeout(newTimeout:int):void{ _debug.info((("setSessionTimeout( " + newTimeout) + " )")); _call("_setSessionTimeout", newTimeout); } public function setRemoteServerMode():void{ _debug.info("setRemoteServerMode()"); _call("_setRemoteServerMode"); } public function getAccount():String{ _debug.info("getAccount()"); return (_call("_getAccount")); } } }//package com.google.analytics.v4
Section 75
//Configuration (com.google.analytics.v4.Configuration) package com.google.analytics.v4 { import com.google.analytics.core.*; import com.google.analytics.debug.*; import com.google.analytics.utils.*; import com.google.analytics.campaign.*; public class Configuration { public var serverMode:ServerOperationMode; public var detectFlash:Boolean;// = true public var allowLocalTracking:Boolean;// = true public var secureRemoteGIFpath:String;// = "https://ssl.google-analytics.com/__utm.gif" public var hasSiteOverlay:Boolean;// = false private var _version:String;// = "4.3as" public var allowDomainHash:Boolean;// = true public var detectClientInfo:Boolean;// = true public var idleLoop:Number;// = 30 public var isTrackOutboundSubdomains:Boolean;// = false public var cookiePath:String;// = "/" public var transactionFieldDelim:String;// = "|" private var _organic:Organic; private var _cookieName:String;// = "analytics" public var campaignKey:CampaignKey; public var google:String;// = "google" public var googleCsePath:String;// = "cse" public var bucketCapacity:Number;// = 10 private var _sampleRate:Number;// = 1 public var remoteGIFpath:String;// = "http://www.google-analytics.com/__utm.gif" public var googleSearchParam:String;// = "q" public var allowLinker:Boolean;// = false public var maxOutboundLinkExamined:Number;// = 1000 private var _debug:DebugConfiguration; private var _trackingLimitPerSession:int;// = 500 private var _domain:Domain; public var allowAnchor:Boolean;// = false public var tokenCliff:int;// = 10 public var sessionTimeout:Number; public var idleTimeout:Number;// = 60 public var campaignTracking:Boolean;// = true public var domainName:String;// = "" public var detectTitle:Boolean;// = true public var tokenRate:Number;// = 0.2 public var conversionTimeout:Number; public var localGIFpath:String;// = "/__utm.gif" public function Configuration(debug:DebugConfiguration=null){ _version = "4.3as"; _sampleRate = 1; _trackingLimitPerSession = 500; _organic = new Organic(); googleCsePath = "cse"; googleSearchParam = "q"; google = "google"; _cookieName = "analytics"; allowDomainHash = true; allowAnchor = false; allowLinker = false; hasSiteOverlay = false; tokenRate = 0.2; conversionTimeout = Timespan.sixmonths; sessionTimeout = Timespan.thirtyminutes; idleLoop = 30; idleTimeout = 60; maxOutboundLinkExamined = 1000; tokenCliff = 10; bucketCapacity = 10; detectClientInfo = true; detectFlash = true; detectTitle = true; campaignKey = new CampaignKey(); campaignTracking = true; isTrackOutboundSubdomains = false; serverMode = ServerOperationMode.remote; localGIFpath = "/__utm.gif"; remoteGIFpath = "http://www.google-analytics.com/__utm.gif"; secureRemoteGIFpath = "https://ssl.google-analytics.com/__utm.gif"; cookiePath = "/"; transactionFieldDelim = "|"; domainName = ""; allowLocalTracking = true; super(); _debug = debug; _domain = new Domain(DomainNameMode.auto, "", _debug); serverMode = ServerOperationMode.remote; _initOrganicSources(); } public function get organic():Organic{ return (_organic); } public function get trackingLimitPerSession():int{ return (_trackingLimitPerSession); } private function _initOrganicSources():void{ addOrganicSource(google, googleSearchParam); addOrganicSource("yahoo", "p"); addOrganicSource("msn", "q"); addOrganicSource("aol", "query"); addOrganicSource("aol", "encquery"); addOrganicSource("lycos", "query"); addOrganicSource("ask", "q"); addOrganicSource("altavista", "q"); addOrganicSource("netscape", "query"); addOrganicSource("cnn", "query"); addOrganicSource("looksmart", "qt"); addOrganicSource("about", "terms"); addOrganicSource("mamma", "query"); addOrganicSource("alltheweb", "q"); addOrganicSource("gigablast", "q"); addOrganicSource("voila", "rdata"); addOrganicSource("virgilio", "qs"); addOrganicSource("live", "q"); addOrganicSource("baidu", "wd"); addOrganicSource("alice", "qs"); addOrganicSource("yandex", "text"); addOrganicSource("najdi", "q"); addOrganicSource("aol", "q"); addOrganicSource("club-internet", "q"); addOrganicSource("mama", "query"); addOrganicSource("seznam", "q"); addOrganicSource("search", "q"); addOrganicSource("wp", "szukaj"); addOrganicSource("onet", "qt"); addOrganicSource("netsprint", "q"); addOrganicSource("google.interia", "q"); addOrganicSource("szukacz", "q"); addOrganicSource("yam", "k"); addOrganicSource("pchome", "q"); addOrganicSource("kvasir", "searchExpr"); addOrganicSource("sesam", "q"); addOrganicSource("ozu", "q"); addOrganicSource("terra", "query"); addOrganicSource("nostrum", "query"); addOrganicSource("mynet", "q"); addOrganicSource("ekolay", "q"); addOrganicSource("search.ilse", "search_for"); } public function get sampleRate():Number{ return (_sampleRate); } public function get cookieName():String{ return (_cookieName); } public function addOrganicSource(engine:String, keyword:String):void{ var engine = engine; var keyword = keyword; _organic.addSource(engine, keyword); //unresolved jump var _slot1 = e; if (((_debug) && (_debug.active))){ _debug.warning(_slot1.message); }; } public function get domain():Domain{ return (_domain); } public function set sampleRate(value:Number):void{ if (value <= 0){ value = 0.1; }; if (value > 1){ value = 1; }; value = Number(value.toFixed(2)); _sampleRate = value; } public function get version():String{ return (_version); } } }//package com.google.analytics.v4
Section 76
//GoogleAnalyticsAPI (com.google.analytics.v4.GoogleAnalyticsAPI) package com.google.analytics.v4 { import com.google.analytics.core.*; public interface GoogleAnalyticsAPI { function setCampSourceKey(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function setCampContentKey(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function addOrganic(_arg1:String, _arg2:String):void; function setAllowLinker(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:Boolean):void; function getLinkerUrl(_arg1:String="", _arg2:Boolean=false):String; function getLocalGifPath():String; function clearIgnoredRef():void; function addTrans(_arg1:String, _arg2:String, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:String, _arg7:String, _arg8:String):void; function setCookieTimeout(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:int):void; function setAllowAnchor(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:Boolean):void; function trackTrans():void; function trackEvent(_arg1:String, _arg2:String, _arg3:String=null, _arg4:Number=NaN):Boolean; function trackPageview(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String=""):void; function setLocalGifPath(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function getVersion():String; function setLocalServerMode():void; function setClientInfo(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:Boolean):void; function setCookiePath(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function setSampleRate(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:Number):void; function linkByPost(_arg1:Object, _arg2:Boolean=false):void; function setDetectTitle(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:Boolean):void; function setLocalRemoteServerMode():void; function addIgnoredOrganic(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function setCampNOKey(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function setAllowHash(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:Boolean):void; function cookiePathCopy(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function getDetectTitle():Boolean; function getServiceMode():ServerOperationMode; function resetSession():void; function getClientInfo():Boolean; function setDetectFlash(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:Boolean):void; function setCampTermKey(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function setCampNameKey(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function addItem(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:Number, _arg6:int):void; function getDetectFlash():Boolean; function setCampaignTrack(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:Boolean):void; function createEventTracker(void:String):EventTracker; function clearOrganic():void; function addIgnoredRef(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function setVar(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function clearIgnoredOrganic():void; function setCampMediumKey(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function setSessionTimeout(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:int):void; function setRemoteServerMode():void; function setDomainName(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics\v4;GoogleAnalyticsAPI.as:String):void; function getAccount():String; function link(_arg1:String, _arg2:Boolean=false):void; } }//package com.google.analytics.v4
Section 77
//Tracker (com.google.analytics.v4.Tracker) package com.google.analytics.v4 { import com.google.analytics.core.*; import com.google.analytics.debug.*; import flash.net.*; import com.google.analytics.utils.*; import com.google.analytics.ecommerce.*; import com.google.analytics.data.*; import com.google.analytics.external.*; import com.google.analytics.campaign.*; public class Tracker implements GoogleAnalyticsAPI { private const EVENT_TRACKER_LABEL_KEY_NUM:int = 3; private const EVENT_TRACKER_VALUE_VALUE_NUM:int = 1; private const EVENT_TRACKER_PROJECT_ID:int = 5; private const EVENT_TRACKER_OBJECT_NAME_KEY_NUM:int = 1; private const EVENT_TRACKER_TYPE_KEY_NUM:int = 2; private var _adSense:AdSenseGlobals; private var _eventTracker:X10; private var _noSessionInformation:Boolean;// = false private var _browserInfo:BrowserInfo; private var _debug:DebugConfiguration; private var _isNewVisitor:Boolean;// = false private var _buffer:Buffer; private var _config:Configuration; private var _x10Module:X10; private var _campaign:CampaignManager; private var _formatedReferrer:String; private var _timeStamp:Number; private var _info:Environment; private var _domainHash:Number; private var _campaignInfo:CampaignInfo; private var _gifRequest:GIFRequest; private var _hasInitData:Boolean;// = false private var _ecom:Ecommerce; private var _account:String; public function Tracker(account:String, config:Configuration, debug:DebugConfiguration, info:Environment, buffer:Buffer, gifRequest:GIFRequest, adSense:AdSenseGlobals, ecom:Ecommerce){ var msg:String; _hasInitData = false; _isNewVisitor = false; _noSessionInformation = false; super(); _account = account; _config = config; _debug = debug; _info = info; _buffer = buffer; _gifRequest = gifRequest; _adSense = adSense; _ecom = ecom; if (!Utils.validateAccount(account)){ msg = (("Account \"" + account) + "\" is not valid."); _debug.warning(msg); throw (new Error(msg)); }; } private function _doTracking():Boolean{ if (((((!((_info.protocol == Protocols.file))) && (!((_info.protocol == Protocols.none))))) && (_isNotGoogleSearch()))){ return (true); }; if (_config.allowLocalTracking){ return (true); }; return (false); } public function addOrganic(newOrganicEngine:String, newOrganicKeyword:String):void{ _debug.info((("addOrganic( " + [newOrganicEngine, newOrganicKeyword].join(", ")) + " )")); _config.organic.addSource(newOrganicEngine, newOrganicKeyword); } public function setAllowLinker(enable:Boolean):void{ _config.allowLinker = enable; _debug.info((("setAllowLinker( " + _config.allowLinker) + " )")); } public function getLinkerUrl(targetUrl:String="", useHash:Boolean=false):String{ _initData(); _debug.info((((("getLinkerUrl( " + targetUrl) + ", ") + useHash.toString()) + " )")); return (_buffer.getLinkerUrl(targetUrl, useHash)); } public function trackPageview(pageURL:String=""):void{ _debug.info((("trackPageview( " + pageURL) + " )")); if (_doTracking()){ _initData(); _trackMetrics(pageURL); _noSessionInformation = false; } else { _debug.warning((("trackPageview( " + pageURL) + " ) failed")); }; } public function setCookieTimeout(newDefaultTimeout:int):void{ _config.conversionTimeout = newDefaultTimeout; _debug.info((("setCookieTimeout( " + _config.conversionTimeout) + " )")); } public function trackTrans():void{ var i:Number; var j:Number; var searchStrings:Array; var curTrans:Transaction; _initData(); searchStrings = new Array(); if (_takeSample()){ i = 0; while (i < _ecom.getTransLength()) { curTrans = _ecom.getTransFromArray(i); searchStrings.push(curTrans.toGifParams()); j = 0; while (j < curTrans.getItemsLength()) { searchStrings.push(curTrans.getItemFromArray(j).toGifParams()); j++; }; i++; }; i = 0; while (i < searchStrings.length) { _gifRequest.send(_account, searchStrings[i]); i++; }; }; } public function trackEvent(category:String, action:String, label:String=null, value:Number=NaN):Boolean{ var success:Boolean; var params:int; _initData(); success = true; params = 2; if (((!((category == ""))) && (!((action == ""))))){ _eventTracker.clearKey(EVENT_TRACKER_PROJECT_ID); _eventTracker.clearValue(EVENT_TRACKER_PROJECT_ID); success = _eventTracker.setKey(EVENT_TRACKER_PROJECT_ID, EVENT_TRACKER_OBJECT_NAME_KEY_NUM, category); success = _eventTracker.setKey(EVENT_TRACKER_PROJECT_ID, EVENT_TRACKER_TYPE_KEY_NUM, action); if (label){ success = _eventTracker.setKey(EVENT_TRACKER_PROJECT_ID, EVENT_TRACKER_LABEL_KEY_NUM, label); params = 3; }; if (!isNaN(value)){ success = _eventTracker.setValue(EVENT_TRACKER_PROJECT_ID, EVENT_TRACKER_VALUE_VALUE_NUM, value); params = 4; }; if (success){ _debug.info(((("valid event tracking call\ncategory: " + category) + "\naction: ") + action), VisualDebugMode.geek); _sendXEvent(_eventTracker); }; } else { _debug.warning(((("event tracking call is not valid, failed!\ncategory: " + category) + "\naction: ") + action), VisualDebugMode.geek); success = false; }; switch (params){ case 4: _debug.info((("trackEvent( " + [category, action, label, value].join(", ")) + " )")); break; case 3: _debug.info((("trackEvent( " + [category, action, label].join(", ")) + " )")); break; case 2: default: _debug.info((("trackEvent( " + [category, action].join(", ")) + " )")); }; return (success); } public function setClientInfo(enable:Boolean):void{ _config.detectClientInfo = enable; _debug.info((("setClientInfo( " + _config.detectClientInfo) + " )")); } public function linkByPost(formObject:Object, useHash:Boolean=false):void{ _debug.warning("linkByPost not implemented in AS3 mode"); } private function _initData():void{ var data0:String; var data:String; if (!_hasInitData){ _updateDomainName(); _domainHash = _getDomainHash(); _timeStamp = Math.round((new Date().getTime() / 1000)); if (_debug.verbose){ data0 = ""; data0 = (data0 + "_initData 0"); data0 = (data0 + ("\ndomain name: " + _config.domainName)); data0 = (data0 + ("\ndomain hash: " + _domainHash)); data0 = (data0 + (((("\ntimestamp: " + _timeStamp) + " (") + new Date((_timeStamp * 1000))) + ")")); _debug.info(data0, VisualDebugMode.geek); }; }; if (_doTracking()){ _handleCookie(); }; if (!_hasInitData){ if (_doTracking()){ _formatedReferrer = _formatReferrer(); _browserInfo = new BrowserInfo(_config, _info); _debug.info(("browserInfo: " + _browserInfo.toURLString()), VisualDebugMode.advanced); if (_config.campaignTracking){ _campaign = new CampaignManager(_config, _debug, _buffer, _domainHash, _formatedReferrer, _timeStamp); _campaignInfo = _campaign.getCampaignInformation(_info.locationSearch, _noSessionInformation); _debug.info(("campaignInfo: " + _campaignInfo.toURLString()), VisualDebugMode.advanced); _debug.info(("Search: " + _info.locationSearch)); _debug.info(("CampaignTrackig: " + _buffer.utmz.campaignTracking)); }; }; _x10Module = new X10(); _eventTracker = new X10(); _hasInitData = true; }; if (_config.hasSiteOverlay){ _debug.warning("Site Overlay is not supported"); }; if (_debug.verbose){ data = ""; data = (data + "_initData (misc)"); data = (data + ("\nflash version: " + _info.flashVersion.toString(4))); data = (data + ("\nprotocol: " + _info.protocol)); data = (data + (("\ndefault domain name (auto): \"" + _info.domainName) + "\"")); data = (data + ("\nlanguage: " + _info.language)); data = (data + ("\ndomain hash: " + _getDomainHash())); data = (data + ("\nuser-agent: " + _info.userAgent)); _debug.info(data, VisualDebugMode.geek); }; } public function getDetectTitle():Boolean{ _debug.info("getDetectTitle()"); return (_config.detectTitle); } public function resetSession():void{ _debug.info("resetSession()"); _buffer.resetCurrentSession(); } private function _sendXEvent(opt_xObj:X10=null):void{ var searchVariables:Variables; var eventInfo:EventInfo; var eventvars:Variables; var generalvars:Variables; if (_takeSample()){ searchVariables = new Variables(); searchVariables.URIencode = true; eventInfo = new EventInfo(true, _x10Module, opt_xObj); eventvars = eventInfo.toVariables(); generalvars = _renderMetricsSearchVariables(); searchVariables.join(eventvars, generalvars); _gifRequest.send(_account, searchVariables, false, true); }; } public function setDetectFlash(enable:Boolean):void{ _config.detectFlash = enable; _debug.info((("setDetectFlash( " + _config.detectFlash) + " )")); } public function setCampNameKey(newCampNameKey:String):void{ var msg:String; _config.campaignKey.UCCN = newCampNameKey; msg = (("setCampNameKey( " + _config.campaignKey.UCCN) + " )"); if (_debug.mode == VisualDebugMode.geek){ _debug.info((msg + " [UCCN]")); } else { _debug.info(msg); }; } private function _formatReferrer():String{ var referrer:String; var domainName:String; var ref:URL; var dom:URL; referrer = _info.referrer; if ((((referrer == "")) || ((referrer == "localhost")))){ referrer = "-"; } else { domainName = _info.domainName; ref = new URL(referrer); dom = new URL(("http://" + domainName)); if (ref.hostName == domainName){ return ("-"); }; if (dom.domain == ref.domain){ if (dom.subDomain != ref.subDomain){ referrer = "0"; }; }; if ((((referrer.charAt(0) == "[")) && (referrer.charAt((referrer.length - 1))))){ referrer = "-"; }; }; _debug.info(("formated referrer: " + referrer), VisualDebugMode.advanced); return (referrer); } private function _visitCode():Number{ if (_debug.verbose){ _debug.info(("visitCode: " + _buffer.utma.sessionId), VisualDebugMode.geek); }; return (_buffer.utma.sessionId); } public function createEventTracker(objName:String):EventTracker{ _debug.info((("createEventTracker( " + objName) + " )")); return (new EventTracker(objName, this)); } public function addItem(id:String, sku:String, name:String, category:String, price:Number, quantity:int):void{ var parentTrans:Transaction; parentTrans = _ecom.getTransaction(id); if (parentTrans == null){ parentTrans = _ecom.addTransaction(id, "", "", "", "", "", "", ""); }; parentTrans.addItem(sku, name, category, price.toString(), quantity.toString()); if (_debug.active){ _debug.info((("addItem( " + [id, sku, name, category, price, quantity].join(", ")) + " )")); }; } public function clearIgnoredOrganic():void{ _debug.info("clearIgnoredOrganic()"); _config.organic.clearIgnoredKeywords(); } public function setVar(newVal:String):void{ var variables:Variables; if (((!((newVal == ""))) && (_isNotGoogleSearch()))){ _initData(); _buffer.utmv.domainHash = _domainHash; _buffer.utmv.value = encodeURI(newVal); if (_debug.verbose){ _debug.info(_buffer.utmv.toString(), VisualDebugMode.geek); }; _debug.info((("setVar( " + newVal) + " )")); if (_takeSample()){ variables = new Variables(); variables.utmt = "var"; _gifRequest.send(_account, variables); }; } else { _debug.warning((("setVar \"" + newVal) + "\" is ignored")); }; } public function setDomainName(newDomainName:String):void{ if (newDomainName == "auto"){ _config.domain.mode = DomainNameMode.auto; } else { if (newDomainName == "none"){ _config.domain.mode = DomainNameMode.none; } else { _config.domain.mode = DomainNameMode.custom; _config.domain.name = newDomainName; }; }; _updateDomainName(); _debug.info((("setDomainName( " + _config.domainName) + " )")); } public function getClientInfo():Boolean{ _debug.info("getClientInfo()"); return (_config.detectClientInfo); } private function _updateDomainName():void{ var domainName:String; if (_config.domain.mode == DomainNameMode.auto){ domainName = _info.domainName; if (domainName.substring(0, 4) == "www."){ domainName = domainName.substring(4); }; _config.domain.name = domainName; }; _config.domainName = _config.domain.name.toLowerCase(); _debug.info(("domain name: " + _config.domainName), VisualDebugMode.advanced); } public function addTrans(orderId:String, affiliation:String, total:Number, tax:Number, shipping:Number, city:String, state:String, country:String):void{ _ecom.addTransaction(orderId, affiliation, total.toString(), tax.toString(), shipping.toString(), city, state, country); if (_debug.active){ _debug.info((("addTrans( " + [orderId, affiliation, total, tax, shipping, city, state, country].join(", ")) + " );")); }; } public function setCampContentKey(newCampContentKey:String):void{ var msg:String; _config.campaignKey.UCCT = newCampContentKey; msg = (("setCampContentKey( " + _config.campaignKey.UCCT) + " )"); if (_debug.mode == VisualDebugMode.geek){ _debug.info((msg + " [UCCT]")); } else { _debug.info(msg); }; } private function _handleCookie():void{ var data0:String; var data1:String; var vid:Array; var data2:String; if (_config.allowLinker){ }; _buffer.createSO(); if (((_buffer.hasUTMA()) && (!(_buffer.utma.isEmpty())))){ if (((!(_buffer.hasUTMB())) || (!(_buffer.hasUTMC())))){ _buffer.updateUTMA(_timeStamp); _noSessionInformation = true; }; if (_debug.verbose){ _debug.info(("from cookie " + _buffer.utma.toString()), VisualDebugMode.geek); }; } else { _debug.info("create a new utma", VisualDebugMode.advanced); _buffer.utma.domainHash = _domainHash; _buffer.utma.sessionId = _getUniqueSessionId(); _buffer.utma.firstTime = _timeStamp; _buffer.utma.lastTime = _timeStamp; _buffer.utma.currentTime = _timeStamp; _buffer.utma.sessionCount = 1; if (_debug.verbose){ _debug.info(_buffer.utma.toString(), VisualDebugMode.geek); }; _noSessionInformation = true; _isNewVisitor = true; }; if (((_adSense.gaGlobal) && ((_adSense.dh == String(_domainHash))))){ if (_adSense.sid){ _buffer.utma.currentTime = Number(_adSense.sid); if (_debug.verbose){ data0 = ""; data0 = (data0 + "AdSense sid found\n"); data0 = (data0 + (((("Override currentTime(" + _buffer.utma.currentTime) + ") from AdSense sid(") + Number(_adSense.sid)) + ")")); _debug.info(data0, VisualDebugMode.geek); }; }; if (_isNewVisitor){ if (_adSense.sid){ _buffer.utma.lastTime = Number(_adSense.sid); if (_debug.verbose){ data1 = ""; data1 = (data1 + "AdSense sid found (new visitor)\n"); data1 = (data1 + (((("Override lastTime(" + _buffer.utma.lastTime) + ") from AdSense sid(") + Number(_adSense.sid)) + ")")); _debug.info(data1, VisualDebugMode.geek); }; }; if (_adSense.vid){ vid = _adSense.vid.split("."); _buffer.utma.sessionId = Number(vid[0]); _buffer.utma.firstTime = Number(vid[1]); if (_debug.verbose){ data2 = ""; data2 = (data2 + "AdSense vid found (new visitor)\n"); data2 = (data2 + (((("Override sessionId(" + _buffer.utma.sessionId) + ") from AdSense vid(") + Number(vid[0])) + ")\n")); data2 = (data2 + (((("Override firstTime(" + _buffer.utma.firstTime) + ") from AdSense vid(") + Number(vid[1])) + ")")); _debug.info(data2, VisualDebugMode.geek); }; }; if (_debug.verbose){ _debug.info(("AdSense modified : " + _buffer.utma.toString()), VisualDebugMode.geek); }; }; }; _buffer.utmb.domainHash = _domainHash; if (isNaN(_buffer.utmb.trackCount)){ _buffer.utmb.trackCount = 0; }; if (isNaN(_buffer.utmb.token)){ _buffer.utmb.token = _config.tokenCliff; }; if (isNaN(_buffer.utmb.lastTime)){ _buffer.utmb.lastTime = _buffer.utma.currentTime; }; _buffer.utmc.domainHash = _domainHash; if (_debug.verbose){ _debug.info(_buffer.utmb.toString(), VisualDebugMode.advanced); _debug.info(_buffer.utmc.toString(), VisualDebugMode.advanced); }; } public function setLocalServerMode():void{ _config.serverMode = ServerOperationMode.local; _debug.info("setLocalServerMode()"); } private function _renderMetricsSearchVariables(pageURL:String=""):Variables{ var variables:Variables; var docInfo:DocumentInfo; var campvars:Variables; var browservars:Variables; variables = new Variables(); variables.URIencode = true; docInfo = new DocumentInfo(_config, _info, _formatedReferrer, pageURL, _adSense); _debug.info(("docInfo: " + docInfo.toURLString()), VisualDebugMode.geek); if (_config.campaignTracking){ campvars = _campaignInfo.toVariables(); }; browservars = _browserInfo.toVariables(); variables.join(docInfo.toVariables(), browservars, campvars); return (variables); } public function clearIgnoredRef():void{ _debug.info("clearIgnoredRef()"); _config.organic.clearIgnoredReferrals(); } public function setCampSourceKey(newCampSrcKey:String):void{ var msg:String; _config.campaignKey.UCSR = newCampSrcKey; msg = (("setCampSourceKey( " + _config.campaignKey.UCSR) + " )"); if (_debug.mode == VisualDebugMode.geek){ _debug.info((msg + " [UCSR]")); } else { _debug.info(msg); }; } public function getLocalGifPath():String{ _debug.info("getLocalGifPath()"); return (_config.localGIFpath); } public function setLocalGifPath(newLocalGifPath:String):void{ _config.localGIFpath = newLocalGifPath; _debug.info((("setLocalGifPath( " + _config.localGIFpath) + " )")); } public function getVersion():String{ _debug.info("getVersion()"); return (_config.version); } public function setAllowAnchor(enable:Boolean):void{ _config.allowAnchor = enable; _debug.info((("setAllowAnchor( " + _config.allowAnchor) + " )")); } private function _isNotGoogleSearch():Boolean{ var domainName:String; var g0:Boolean; var g1:Boolean; var g2:Boolean; var g4:Boolean; domainName = _config.domainName; g0 = (domainName.indexOf("www.google.") < 0); g1 = (domainName.indexOf(".google.") < 0); g2 = (domainName.indexOf("google.") < 0); g4 = (domainName.indexOf("google.org") > -1); return (((((((((g0) || (g1))) || (g2))) || (!((_config.cookiePath == "/"))))) || (g4))); } public function setSampleRate(newRate:Number):void{ if (newRate < 0){ _debug.warning("sample rate can not be negative, ignoring value."); } else { _config.sampleRate = newRate; }; _debug.info((("setSampleRate( " + _config.sampleRate) + " )")); } private function _takeSample():Boolean{ if (_debug.verbose){ _debug.info((((("takeSample: (" + (_visitCode() % 10000)) + ") < (") + (_config.sampleRate * 10000)) + ")"), VisualDebugMode.geek); }; return (((_visitCode() % 10000) < (_config.sampleRate * 10000))); } public function setCookiePath(newCookiePath:String):void{ _config.cookiePath = newCookiePath; _debug.info((("setCookiePath( " + _config.cookiePath) + " )")); } public function setAllowHash(enable:Boolean):void{ _config.allowDomainHash = enable; _debug.info((("setAllowHash( " + _config.allowDomainHash) + " )")); } private function _generateUserDataHash():Number{ var hash:String; hash = ""; hash = (hash + _info.appName); hash = (hash + _info.appVersion); hash = (hash + _info.language); hash = (hash + _info.platform); hash = (hash + _info.userAgent.toString()); hash = (hash + (((_info.screenWidth + "x") + _info.screenHeight) + _info.screenColorDepth)); hash = (hash + _info.referrer); return (Utils.generateHash(hash)); } public function addIgnoredOrganic(newIgnoredOrganicKeyword:String):void{ _debug.info((("addIgnoredOrganic( " + newIgnoredOrganicKeyword) + " )")); _config.organic.addIgnoredKeyword(newIgnoredOrganicKeyword); } public function setLocalRemoteServerMode():void{ _config.serverMode = ServerOperationMode.both; _debug.info("setLocalRemoteServerMode()"); } public function cookiePathCopy(newPath:String):void{ _debug.warning((("cookiePathCopy( " + newPath) + " ) not implemented")); } public function setDetectTitle(enable:Boolean):void{ _config.detectTitle = enable; _debug.info((("setDetectTitle( " + _config.detectTitle) + " )")); } public function setCampTermKey(newCampTermKey:String):void{ var msg:String; _config.campaignKey.UCTR = newCampTermKey; msg = (("setCampTermKey( " + _config.campaignKey.UCTR) + " )"); if (_debug.mode == VisualDebugMode.geek){ _debug.info((msg + " [UCTR]")); } else { _debug.info(msg); }; } public function getServiceMode():ServerOperationMode{ _debug.info("getServiceMode()"); return (_config.serverMode); } public function setCampNOKey(newCampNOKey:String):void{ var msg:String; _config.campaignKey.UCNO = newCampNOKey; msg = (("setCampNOKey( " + _config.campaignKey.UCNO) + " )"); if (_debug.mode == VisualDebugMode.geek){ _debug.info((msg + " [UCNO]")); } else { _debug.info(msg); }; } private function _trackMetrics(pageURL:String=""):void{ var searchVariables:Variables; var x10vars:Variables; var generalvars:Variables; var eventInfo:EventInfo; if (_takeSample()){ searchVariables = new Variables(); searchVariables.URIencode = true; if (((_x10Module) && (_x10Module.hasData()))){ eventInfo = new EventInfo(false, _x10Module); x10vars = eventInfo.toVariables(); }; generalvars = _renderMetricsSearchVariables(pageURL); searchVariables.join(x10vars, generalvars); _gifRequest.send(_account, searchVariables); }; } public function setCampaignTrack(enable:Boolean):void{ _config.campaignTracking = enable; _debug.info((("setCampaignTrack( " + _config.campaignTracking) + " )")); } public function addIgnoredRef(newIgnoredReferrer:String):void{ _debug.info((("addIgnoredRef( " + newIgnoredReferrer) + " )")); _config.organic.addIgnoredReferral(newIgnoredReferrer); } public function clearOrganic():void{ _debug.info("clearOrganic()"); _config.organic.clearEngines(); } public function getDetectFlash():Boolean{ _debug.info("getDetectFlash()"); return (_config.detectFlash); } public function setCampMediumKey(newCampMedKey:String):void{ var msg:String; _config.campaignKey.UCMD = newCampMedKey; msg = (("setCampMediumKey( " + _config.campaignKey.UCMD) + " )"); if (_debug.mode == VisualDebugMode.geek){ _debug.info((msg + " [UCMD]")); } else { _debug.info(msg); }; } private function _getUniqueSessionId():Number{ var sessionID:Number; sessionID = ((Utils.generate32bitRandom() ^ _generateUserDataHash()) * 2147483647); _debug.info(("Session ID: " + sessionID), VisualDebugMode.geek); return (sessionID); } private function _getDomainHash():Number{ if (((((!(_config.domainName)) || ((_config.domainName == "")))) || ((_config.domain.mode == DomainNameMode.none)))){ _config.domainName = ""; return (1); }; _updateDomainName(); if (_config.allowDomainHash){ return (Utils.generateHash(_config.domainName)); }; return (1); } public function setSessionTimeout(newTimeout:int):void{ _config.sessionTimeout = newTimeout; _debug.info((("setSessionTimeout( " + _config.sessionTimeout) + " )")); } public function getAccount():String{ _debug.info("getAccount()"); return (_account); } public function link(targetUrl:String, useHash:Boolean=false):void{ var out:String; var request:URLRequest; var targetUrl = targetUrl; var useHash = useHash; _initData(); out = _buffer.getLinkerUrl(targetUrl, useHash); request = new URLRequest(out); _debug.info((("link( " + [targetUrl, useHash].join(",")) + " )")); navigateToURL(request, "_top"); //unresolved jump var _slot1 = e; _debug.warning(("An error occured in link() msg: " + _slot1.message)); } public function setRemoteServerMode():void{ _config.serverMode = ServerOperationMode.remote; _debug.info("setRemoteServerMode()"); } } }//package com.google.analytics.v4
Section 78
//AnalyticsTracker (com.google.analytics.AnalyticsTracker) package com.google.analytics { import flash.events.*; import com.google.analytics.v4.*; import com.google.analytics.debug.*; public interface AnalyticsTracker extends GoogleAnalyticsAPI, IEventDispatcher { function set config(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics;AnalyticsTracker.as:Configuration):void; function isReady():Boolean; function get mode():String; function get account():String; function set mode(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics;AnalyticsTracker.as:String):void; function set debug(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics;AnalyticsTracker.as:DebugConfiguration):void; function get config():Configuration; function get debug():DebugConfiguration; function set account(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics;AnalyticsTracker.as:String):void; function get visualDebug():Boolean; function set visualDebug(C:\Documents and Settings\josh\My Documents\working_files\plod_gamezhero\Plod\flash;com\google\analytics;AnalyticsTracker.as:Boolean):void; } }//package com.google.analytics
Section 79
//API (com.google.analytics.API) package com.google.analytics { import com.google.analytics.utils.*; public class API { public static var version:Version = new Version(); public function API(){ super(); } version.major = 1; version.minor = 0; version.build = 1; version.revision = "$Rev: 319 $ ".split(" ")[1]; } }//package com.google.analytics
Section 80
//GATracker (com.google.analytics.GATracker) package com.google.analytics { import flash.events.*; import flash.display.*; import com.google.analytics.core.*; import com.google.analytics.v4.*; import com.google.analytics.debug.*; import com.google.analytics.utils.*; import com.google.analytics.external.*; import com.google.analytics.events.*; public class GATracker implements AnalyticsTracker { private var _adSense:AdSenseGlobals; private var _env:Environment; private var _visualDebug:Boolean; private var _idleTimer:IdleTimer; private var _debug:DebugConfiguration; private var _buffer:Buffer; private var _config:Configuration; private var _mode:String; private var _display:DisplayObject; private var _jsproxy:JavascriptProxy; private var _dom:HTMLDOM; private var _eventDispatcher:EventDispatcher; private var _ready:Boolean;// = false private var _gifRequest:GIFRequest; private var _ecom:Ecommerce; private var _account:String; private var _tracker:GoogleAnalyticsAPI; public static var version:Version = API.version; public static var autobuild:Boolean = true; public function GATracker(display:DisplayObject, account:String, mode:String="AS3", visualDebug:Boolean=false, config:Configuration=null, debug:DebugConfiguration=null){ _ready = false; super(); _display = display; _eventDispatcher = new EventDispatcher(this); _tracker = new TrackerCache(); this.account = account; this.mode = mode; this.visualDebug = visualDebug; if (!debug){ this.debug = new DebugConfiguration(); }; if (!config){ this.config = new Configuration(debug); }; if (autobuild){ _factory(); }; } public function link(targetUrl:String, useHash:Boolean=false):void{ _tracker.link(targetUrl, useHash); } public function addOrganic(newOrganicEngine:String, newOrganicKeyword:String):void{ _tracker.addOrganic(newOrganicEngine, newOrganicKeyword); } public function setAllowLinker(enable:Boolean):void{ _tracker.setAllowLinker(enable); } public function getLinkerUrl(url:String="", useHash:Boolean=false):String{ return (_tracker.getLinkerUrl(url, useHash)); } public function trackEvent(category:String, action:String, label:String=null, value:Number=NaN):Boolean{ return (_tracker.trackEvent(category, action, label, value)); } public function setCookieTimeout(newDefaultTimeout:int):void{ _tracker.setCookieTimeout(newDefaultTimeout); } public function trackTrans():void{ _tracker.trackTrans(); } public function trackPageview(pageURL:String=""):void{ _tracker.trackPageview(pageURL); } public function getClientInfo():Boolean{ return (_tracker.getClientInfo()); } public function setClientInfo(enable:Boolean):void{ _tracker.setClientInfo(enable); } public function get account():String{ return (_account); } public function linkByPost(formObject:Object, useHash:Boolean=false):void{ _tracker.linkByPost(formObject, useHash); } public function getDetectTitle():Boolean{ return (_tracker.getDetectTitle()); } public function dispatchEvent(event:Event):Boolean{ return (_eventDispatcher.dispatchEvent(event)); } public function get config():Configuration{ return (_config); } public function set mode(value:String):void{ _mode = value; } public function removeEventListener(type:String, listener:Function, useCapture:Boolean=false):void{ _eventDispatcher.removeEventListener(type, listener, useCapture); } public function setDetectFlash(enable:Boolean):void{ _tracker.setDetectFlash(enable); } public function resetSession():void{ _tracker.resetSession(); } public function setCampNameKey(newCampNameKey:String):void{ _tracker.setCampNameKey(newCampNameKey); } public function get debug():DebugConfiguration{ return (_debug); } public function addItem(item:String, sku:String, name:String, category:String, price:Number, quantity:int):void{ _tracker.addItem(item, sku, name, category, price, quantity); } private function _bridgeFactory():GoogleAnalyticsAPI{ debug.info(((("GATracker (Bridge) v" + version) + "\naccount: ") + account)); return (new Bridge(account, _debug, _jsproxy)); } public function addEventListener(type:String, listener:Function, useCapture:Boolean=false, priority:int=0, useWeakReference:Boolean=false):void{ _eventDispatcher.addEventListener(type, listener, useCapture, priority, useWeakReference); } public function clearIgnoredOrganic():void{ _tracker.clearIgnoredOrganic(); } public function set account(value:String):void{ _account = value; } public function setVar(newVal:String):void{ _tracker.setVar(newVal); } public function build():void{ if (!isReady()){ _factory(); }; } public function setDomainName(newDomainName:String):void{ _tracker.setDomainName(newDomainName); } public function createEventTracker(objName:String):EventTracker{ return (_tracker.createEventTracker(objName)); } public function set config(value:Configuration):void{ _config = value; } public function addTrans(orderId:String, affiliation:String, total:Number, tax:Number, shipping:Number, city:String, state:String, country:String):void{ _tracker.addTrans(orderId, affiliation, total, tax, shipping, city, state, country); } public function setCampSourceKey(newCampSrcKey:String):void{ _tracker.setCampSourceKey(newCampSrcKey); } public function setCampContentKey(newCampContentKey:String):void{ _tracker.setCampContentKey(newCampContentKey); } public function willTrigger(type:String):Boolean{ return (_eventDispatcher.willTrigger(type)); } public function setLocalServerMode():void{ _tracker.setLocalServerMode(); } public function isReady():Boolean{ return (_ready); } public function getLocalGifPath():String{ return (_tracker.getLocalGifPath()); } public function setAllowAnchor(enable:Boolean):void{ _tracker.setAllowAnchor(enable); } public function clearIgnoredRef():void{ _tracker.clearIgnoredRef(); } public function get mode():String{ return (_mode); } public function set debug(value:DebugConfiguration):void{ _debug = value; } public function setLocalGifPath(newLocalGifPath:String):void{ _tracker.setLocalGifPath(newLocalGifPath); } public function getVersion():String{ return (_tracker.getVersion()); } public function setSampleRate(newRate:Number):void{ _tracker.setSampleRate(newRate); } public function setCookiePath(newCookiePath:String):void{ _tracker.setCookiePath(newCookiePath); } public function setAllowHash(enable:Boolean):void{ _tracker.setAllowHash(enable); } public function setCampNOKey(newCampNOKey:String):void{ _tracker.setCampNOKey(newCampNOKey); } public function addIgnoredOrganic(newIgnoredOrganicKeyword:String):void{ _tracker.addIgnoredOrganic(newIgnoredOrganicKeyword); } public function setLocalRemoteServerMode():void{ _tracker.setLocalRemoteServerMode(); } public function cookiePathCopy(newPath:String):void{ _tracker.cookiePathCopy(newPath); } private function _factory():void{ var activeTracker:GoogleAnalyticsAPI; var cache:TrackerCache; _jsproxy = new JavascriptProxy(debug); if (visualDebug){ debug.layout = new Layout(debug, _display); debug.active = visualDebug; }; cache = (_tracker as TrackerCache); switch (mode){ case TrackerMode.BRIDGE: activeTracker = _bridgeFactory(); break; case TrackerMode.AS3: default: activeTracker = _trackerFactory(); }; if (!cache.isEmpty()){ cache.tracker = activeTracker; cache.flush(); }; _tracker = activeTracker; _ready = true; dispatchEvent(new AnalyticsEvent(AnalyticsEvent.READY, this)); } public function setCampTermKey(newCampTermKey:String):void{ _tracker.setCampTermKey(newCampTermKey); } private function _trackerFactory():GoogleAnalyticsAPI{ debug.info(((("GATracker (AS3) v" + version) + "\naccount: ") + account)); _adSense = new AdSenseGlobals(debug); _dom = new HTMLDOM(debug); _dom.cacheProperties(); _env = new Environment("", "", "", debug, _dom); _buffer = new Buffer(config, debug, false); _gifRequest = new GIFRequest(config, debug, _buffer, _env); _idleTimer = new IdleTimer(config, debug, _display, _buffer); _ecom = new Ecommerce(_debug); _env.url = _display.stage.loaderInfo.url; return (new Tracker(account, config, debug, _env, _buffer, _gifRequest, _adSense, _ecom)); } public function setDetectTitle(enable:Boolean):void{ _tracker.setDetectTitle(enable); } public function setCampaignTrack(enable:Boolean):void{ _tracker.setCampaignTrack(enable); } public function clearOrganic():void{ _tracker.clearOrganic(); } public function addIgnoredRef(newIgnoredReferrer:String):void{ _tracker.addIgnoredRef(newIgnoredReferrer); } public function getServiceMode():ServerOperationMode{ return (_tracker.getServiceMode()); } public function set visualDebug(value:Boolean):void{ _visualDebug = value; } public function setCampMediumKey(newCampMedKey:String):void{ _tracker.setCampMediumKey(newCampMedKey); } public function setSessionTimeout(newTimeout:int):void{ _tracker.setSessionTimeout(newTimeout); } public function getDetectFlash():Boolean{ return (_tracker.getDetectFlash()); } public function get visualDebug():Boolean{ return (_visualDebug); } public function getAccount():String{ return (_tracker.getAccount()); } public function hasEventListener(type:String):Boolean{ return (_eventDispatcher.hasEventListener(type)); } public function setRemoteServerMode():void{ _tracker.setRemoteServerMode(); } } var _local1:* = ServerOperationMode; return (_local1); }//package com.google.analytics
Section 81
//Sounds (com.sounds.Sounds) package com.sounds { import flash.display.*; import flash.media.*; public class Sounds extends Sprite { public static var coin2:Sound; public static var crate:Sound; public static var bounce:Sound; public static var gameover:Sound; public static var click:Sound; public static var coin:Sound; public static var explosion:Sound; private static var sound:SoundChannel = new SoundChannel(); public static var truncheon:Sound; public static var whistle:Sound; private static var soundTransform:SoundTransform; public static var bounceSmall:Sound; public static var music:Sound; public static var levelover:Sound; public static var collect:Sound; public static var tally:Sound; public static var jump:Sound; public static var snd:Sound; public static var chase:Sound; public function Sounds(){ super(); } public static function stopSound():void{ if (sound){ sound.stop(); }; } public static function playSound(snd:Sound, num:uint):void{ sound = snd.play(0, num, soundTransform); } public static function init():void{ jump = new sound_jump(); coin = new sound_coin(); coin2 = new sound_coin2(); collect = new sound_collect(); click = new sound_click(); bounce = new sound_bounce(); bounceSmall = new sound_bounceSmall(); truncheon = new sound_truncheon(); crate = new sound_crate(); explosion = new sound_explosion(); whistle = new sound_whistle(); tally = new sound_tally(); music = new sound_music(); levelover = new sound_endlevel(); chase = new sound_chase(); soundTransform = new SoundTransform(0.5); } } }//package com.sounds
Section 82
//FadeAway (com.Ui.FadeAway) package com.Ui { import gs.*; import flash.events.*; import flash.display.*; public class FadeAway extends Sprite { public function FadeAway():void{ super(); addEventListener(Event.ADDED_TO_STAGE, fademan, false, 0, true); } private function fademan(e:Event):void{ TweenLite.to(this, 1, {alpha:0, onComplete:killMe}); } private function killMe():void{ parent.removeChild(this); } } }//package com.Ui
Section 83
//GameIntro (com.Ui.GameIntro) package com.Ui { import gs.*; import flash.events.*; import flash.display.*; import flash.text.*; import net.*; import com.*; public class GameIntro extends Sprite { public var brick1:TilesMc; public var brick3:TilesMc; public var brick4:TilesMc; public var brick8:TilesMc; public var chiefText:MovieClip; public var brick5:TilesMc; public var brick6:TilesMc; public var s1:s1s; public var s6:s6s; public var brick7:TilesMc; public var brick16:TilesMc; public var brick2:TilesMc; public var s2:s2s; public var brick13:TilesMc; public var s8:s8a; public var level_txt:TextField; public var s3:s3s; public var s4:s4a; public var s5:s5a; public var brick9:TilesMc; public var brick15:TilesMc; public var brick12:TilesMc; public var s7:s7a; public var s9:s9s; public var brick10:TilesMc; public var brick11:TilesMc; public var callBack:Function; public var updateHud:Function; public var brick14:TilesMc; var timeBonusAmount:uint;// = 0 public var gamezheroBtn2:SimpleButton; public var s10:s10s; public var s11:s11s; public var s12:s12a; public var s13:s13a; public var s14:s14s; public var s15:s15s; public var s16:s16a; public var btn_next:btn_righto_; public function GameIntro():void{ var num:uint; var i:uint; var b:uint; timeBonusAmount = 0; super(); Globals.paused = true; gamezheroBtn2.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); btn_next.addEventListener(MouseEvent.CLICK, startLevel, false, 0, true); i = 0; while (i < 16) { num = (i + 1); this[("s" + num)].visible = false; this[("brick" + num)].gotoAndStop(1); i++; }; this[("s" + Globals.level)].visible = true; this[("s" + Globals.level)].addEventListener(MouseEvent.CLICK, startLevel, false, 0, true); b = 1; while (b < Globals.level) { this[("brick" + b)].gotoAndStop(2); b++; }; level_txt.text = ("Level " + Globals.level); chiefText.gotoAndStop(Globals.level); } public function startLevel(e:MouseEvent):void{ this.visible = false; removeEventListener(MouseEvent.CLICK, startLevel); this[("s" + Globals.level)].removeEventListener(MouseEvent.CLICK, startLevel); TweenLite.to(this, 0.3, {alpha:0, onComplete:killMe}); callBack(); } public function killMe():void{ Globals.paused = false; parent.removeChild(this); } public function init(_callBack:Function):void{ callBack = _callBack; } } }//package com.Ui
Section 84
//GameLosey (com.Ui.GameLosey) package com.Ui { import flash.events.*; import flash.display.*; import flash.text.*; import net.*; import com.gamezhero.api.as3.*; import com.sounds.*; import com.*; public class GameLosey extends MovieClip { public var btn_submitscore:btn_submitscore_; public var btn_replay:btn_replay_; public var gamezheroBtn2:SimpleButton; public var btn_mainMenu:btn_mainMenu_; public var score_txt:TextField; public var moreGamesBtn:btn_playmore_; public function GameLosey():void{ super(); btn_mainMenu.addEventListener(MouseEvent.CLICK, mainMenu, false, 0, true); btn_replay.addEventListener(MouseEvent.CLICK, replay, false, 0, true); btn_submitscore.addEventListener(MouseEvent.CLICK, submitscore, false, 0, true); moreGamesBtn.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); gamezheroBtn2.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); Sounds.stopSound(); Sounds.levelover.play(); score_txt.text = ("" + Globals.score); } private function errorFunction():void{ var levelPopUp:LevelPopUp; levelPopUp = new LevelPopUp(); levelPopUp.init("ERROR!"); addChild(levelPopUp); } private function submitFunction():void{ var levelPopUp:LevelPopUp; levelPopUp = new LevelPopUp(); levelPopUp.init("SCORE SUBMITTED"); parent.addChild(levelPopUp); } private function removeButtons():void{ btn_mainMenu.removeEventListener(MouseEvent.CLICK, mainMenu); btn_replay.removeEventListener(MouseEvent.CLICK, replay); btn_submitscore.removeEventListener(MouseEvent.CLICK, submitscore); moreGamesBtn.removeEventListener(MouseEvent.CLICK, URLCaller.goto); gamezheroBtn2.removeEventListener(MouseEvent.CLICK, URLCaller.goto); } private function submitscore(e:MouseEvent):void{ GamezheroApi.score(this, "204199211152219161203212168080148195157219215210208168197201148158198221203201215165129154153158155165166157168", Globals.score, 170, 140, submitFunction, mainMenu, errorFunction); } private function mainMenu(e:MouseEvent=null):void{ Globals.quit = true; parent.removeChild(this); } private function replay(e:MouseEvent):void{ Globals.quit = true; Globals.replay = true; Globals.level = Globals.levelStart; Globals.score = 0; Globals.lives = Globals.livesStart; parent.removeChild(this); } } }//package com.Ui
Section 85
//GameWin (com.Ui.GameWin) package com.Ui { import flash.events.*; import flash.display.*; import flash.text.*; import net.*; import com.gamezhero.api.as3.*; import com.sounds.*; import com.*; public class GameWin extends MovieClip { public var btn_submitscore:btn_submitscore_; public var btn_replay:btn_replay_; public var gamezheroBtn2:SimpleButton; public var btn_mainMenu:btn_mainMenu_; public var score_txt:TextField; public var moreGamesBtn:btn_playmore_; public function GameWin():void{ super(); btn_mainMenu.addEventListener(MouseEvent.CLICK, mainMenu, false, 0, true); btn_replay.addEventListener(MouseEvent.CLICK, replay, false, 0, true); btn_submitscore.addEventListener(MouseEvent.CLICK, submitscore, false, 0, true); moreGamesBtn.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); gamezheroBtn2.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); Sounds.stopSound(); score_txt.text = ("" + Globals.score); if (Globals.musicOn){ Sounds.levelover.play(); }; } private function errorFunction():void{ var levelPopUp:LevelPopUp; levelPopUp = new LevelPopUp(); levelPopUp.init("ERROR!"); addChild(levelPopUp); } private function submitFunction():void{ var levelPopUp:LevelPopUp; levelPopUp = new LevelPopUp(); levelPopUp.init("SCORE SUBMITTED"); parent.addChild(levelPopUp); } private function submitscore(e:MouseEvent):void{ GamezheroApi.score(this, "204199211152219161203212168080148195157219215210208168197201148158198221203201215165129154153158155165166157168", Globals.score, 170, 140, submitFunction, mainMenu, errorFunction); } private function mainMenu(e:MouseEvent=null):void{ Globals.quit = true; parent.removeChild(this); } private function replay(e:MouseEvent):void{ Globals.quit = true; Globals.replay = true; Globals.level = Globals.levelStart; Globals.score = 0; Globals.lives = Globals.livesStart; parent.removeChild(this); } } }//package com.Ui
Section 86
//Hud (com.Ui.Hud) package com.Ui { import flash.events.*; import flash.display.*; import flash.text.*; import net.*; import com.*; public class Hud extends Sprite { public var time_txt:TextField; public var level_txt:TextField; public var gamezheroBtn1:SimpleButton; public var lives_txt:TextField; public var pausedScreen:PausedScreen_; public var score_txt:TextField; public var btn_pause:btn_pausegame_; public var stars_txt:TextField; public var score:uint;// = 0 public var cupcakes_txt:TextField; public function Hud():void{ score = 0; super(); pausedScreen.visible = false; btn_pause.addEventListener(MouseEvent.CLICK, pauseGame, false, 0, true); gamezheroBtn1.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); } private function pauseGame(e:MouseEvent):void{ if (!Globals.paused){ Globals.paused = true; pausedScreen.visible = true; pausedScreen.scaleX = (pausedScreen.scaleX = 1); }; } public function init():void{ updateScore(); this.visible = true; } private function updateScore():void{ updateDisplay(); } public function addScore(num:uint):void{ Globals.score = (Globals.score + num); updateScore(); } public function updateDisplay():void{ level_txt.text = ("" + Globals.level); score_txt.text = ("" + Globals.score); if (Globals.totalBurglars == 0){ stars_txt.text = "???"; } else { stars_txt.text = ((Globals.burglars + "/") + Globals.totalBurglars); }; cupcakes_txt.text = ((Globals.clues + "/") + Globals.totalclues); lives_txt.text = ("x " + Globals.lives); time_txt.text = ("" + Globals.time); } } }//package com.Ui
Section 87
//Instructions (com.Ui.Instructions) package com.Ui { import flash.events.*; import flash.display.*; import net.*; public class Instructions extends Sprite { public var gamezheroBtn2:SimpleButton; public var btn_mainMenu:btn_mainMenu_; public var startGameFunction:Function; public var btn_start:btn_startGame; public function Instructions():void{ super(); btn_mainMenu.addEventListener(MouseEvent.CLICK, mainMenu, false, 0, true); btn_start.addEventListener(MouseEvent.CLICK, startGame, false, 0, true); gamezheroBtn2.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); } private function startGame(e:MouseEvent):void{ this.visible = false; startGameFunction(); parent.removeChild(this); } private function killMe():void{ btn_mainMenu.removeEventListener(MouseEvent.CLICK, mainMenu); btn_start.removeEventListener(MouseEvent.CLICK, startGame); gamezheroBtn2.removeEventListener(MouseEvent.CLICK, URLCaller.mainLink); } private function mainMenu(e:MouseEvent):void{ parent.removeChild(this); } } }//package com.Ui
Section 88
//LevelPopUp (com.Ui.LevelPopUp) package com.Ui { import gs.*; import flash.display.*; import flash.text.*; public class LevelPopUp extends Sprite { public var txt:TextField; public function LevelPopUp():void{ super(); } public function init(_txt:String):void{ txt.text = _txt; this.x = 325; this.y = 300; this.alpha = 0; TweenLite.to(this, 0.3, {delay:0.2, alpha:1, y:250, onComplete:PhaseTwo}); } private function KillMe():void{ parent.removeChild(this); } private function PhaseTwo():void{ TweenLite.to(this, 0.3, {delay:1, alpha:0, y:200, onComplete:KillMe}); } } }//package com.Ui
Section 89
//MyContextMenu (com.Ui.MyContextMenu) package com.Ui { import flash.events.*; import flash.display.*; import net.*; import com.gamezhero.api.as3.*; import flash.ui.*; public class MyContextMenu extends Sprite { public function MyContextMenu():void{ super(); } public function init(target):void{ var my_menu:ContextMenu; var my_sponsor:*; var my_sponsorMore:*; var my_notice:*; var my_viewScores:*; var my_download:*; var my_copyright:*; var my_cutie:*; my_menu = new ContextMenu(); my_menu.hideBuiltInItems(); my_sponsor = new ContextMenuItem("Sponsored by Gamezhero"); my_sponsorMore = new ContextMenuItem("More Games"); my_notice = new ContextMenuItem("Game by thistler"); my_viewScores = new ContextMenuItem("View Top Scores"); my_download = new ContextMenuItem("Download This Game For Your Site"); my_copyright = new ContextMenuItem("Copyright - thistler.net- 2009"); my_cutie = new ContextMenuItem("^_^"); my_sponsor.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, gotoGamezhero); my_sponsorMore.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, gotoGamezhero); my_viewScores.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, showHighScores); my_menu.customItems.push(my_sponsor, my_sponsorMore, my_viewScores, my_notice, my_copyright); target.contextMenu = my_menu; trace("ADDING CONTEXT MENU"); } function gotoSite(e:ContextMenuEvent):void{ URLCaller.mainLink(); } function gotoGamezhero(e:ContextMenuEvent):void{ GamezheroApi.linkMoreGames(); } function showHighScores(e:ContextMenuEvent):void{ GamezheroApi.linkTopScore(); } } }//package com.Ui
Section 90
//PausedScreen (com.Ui.PausedScreen) package com.Ui { import flash.events.*; import flash.display.*; import net.*; import com.sounds.*; import com.*; public class PausedScreen extends Sprite { public var moreGamesBtn:btn_playmore_; public var btn_quit:btn_quit_; public var btn_resume:btn_reume_; public var btn_music:btn_music_; public function PausedScreen():void{ super(); btn_resume.addEventListener(MouseEvent.CLICK, resumeGame, false, 0, true); btn_quit.addEventListener(MouseEvent.CLICK, quitGame, false, 0, true); moreGamesBtn.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); btn_music.addEventListener(MouseEvent.CLICK, MusicOnOff, false, 0, true); } private function MusicOnOff(e:MouseEvent):void{ if (Globals.musicOn){ Globals.musicOn = false; btn_music.txt.text = "MUSIC: OFF"; Sounds.stopSound(); } else { Globals.musicOn = true; btn_music.txt.text = "MUSIC: ON"; Sounds.playSound(Sounds.music, 1000); }; } private function resumeGame(e:MouseEvent):void{ this.visible = false; Globals.paused = false; } private function quitGame(e:MouseEvent):void{ Globals.quit = true; this.scaleX = (this.scaleX = 0); this.visible = false; } } }//package com.Ui
Section 91
//TallyScore (com.Ui.TallyScore) package com.Ui { import gs.*; import flash.events.*; import flash.display.*; import flash.text.*; import net.*; import com.sounds.*; import com.*; public class TallyScore extends Sprite { public var time_txt:TextField; public var star_txt:TextField; public var gamezheroBtn2:SimpleButton; public var score_txt:TextField; var timeBonusAmount:uint;// = 0 public var updateHud:Function; public var btn_next:Btn_next; public function TallyScore():void{ timeBonusAmount = 0; super(); Sounds.stopSound(); btn_next.addEventListener(MouseEvent.CLICK, nextLevel, false, 0, true); gamezheroBtn2.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); btn_next.visible = false; this.score_txt.text = ("" + Globals.score); if (Globals.evidence == Globals.totalevidence){ starBonus(); } else { star_txt.text = "0 - COLLECT ALL THE EVIDENCE TO GET A BONUS!"; timeBonus(); }; if (Globals.musicOn){ Sounds.levelover.play(); }; } private function timeBonus():void{ timeBonusAmount = (timeBonusAmount + Globals.timeBonusAmount); Globals.score = (Globals.score + Globals.timeBonusAmount); time_txt.text = ("" + timeBonusAmount); score_txt.text = ("" + Globals.score); if (Globals.time > 0){ TweenLite.to(this, 0.02, {onComplete:timeBonus}); } else { btn_next.visible = true; }; if (Globals.time > 0){ Globals.time--; }; Sounds.tally.play(); if (Globals.time == 0){ Sounds.jump.play(); }; if (updateHud){ updateHud(); }; } public function nextLevel(e:MouseEvent):void{ Globals.finishedLevel = false; Globals.startLevel = true; Globals.level++; removeEventListener(MouseEvent.CLICK, nextLevel); parent.removeChild(this); } private function starBonus():void{ Globals.score = (Globals.score + ((Globals.totalevidence * Globals.level) * 10)); star_txt.text = ("" + ((Globals.totalevidence * Globals.level) * 10)); score_txt.text = ("" + Globals.score); timeBonus(); } } }//package com.Ui
Section 92
//TitleScreen (com.Ui.TitleScreen) package com.Ui { import flash.events.*; import flash.display.*; import net.*; import com.*; public class TitleScreen extends Sprite { public var sendToFriendsBtn:btn_sendtofriends_; public var btn_startGame_:btn_startGame; public var gamezheroBtn1:SimpleButton; public var moreGamesBtn:btn_playmore_; private var startGame:Function; public var titleAnim:MovieClip; public var btn_instructions:btn_instructions_; var instructions:Instructions_; public var publishBtn:SimpleButton; public var btn_bythistler:MovieClip; public var topScoreBtn:btn_highscores_; public function TitleScreen():void{ super(); } public function init(_startGame:Function):void{ startGame = _startGame; btn_startGame_.addEventListener(MouseEvent.CLICK, startGameEvent, false, 0, true); topScoreBtn.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); moreGamesBtn.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); gamezheroBtn1.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); publishBtn.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); sendToFriendsBtn.addEventListener(MouseEvent.CLICK, URLCaller.goto, false, 0, true); btn_instructions.addEventListener(MouseEvent.CLICK, viewInstructions, false, 0, true); } private function startGameEvent(e:MouseEvent):void{ this.visible = false; Globals.lives = Globals.livesStart; Globals.level = Globals.levelStart; this.visible = false; titleAnim.stop(); startGame(); } private function viewInstructions(e:MouseEvent):void{ instructions = new Instructions_(); instructions.startGameFunction = startGame; addChild(instructions); } } }//package com.Ui
Section 93
//Globals (com.Globals) package com { import flash.display.*; public class Globals extends Sprite { public static var level:uint = 1; public static var lives:int = 10; public static var score:uint = 0; public static var startedBurglar:Boolean = false; public static var totalclues:uint = 0; public static var livesStart:int = 10; public static var totalevidence:uint = 0; public static var ID:uint = 1; public static var totalBurglars:uint = 0; public static var finishedLevel:Boolean = false; public static var paused:Boolean = true; public static var levelStart:uint = 1; public static var startLevel:Boolean = false; public static var starBonusAmount:uint = 150; public static var time:uint = 120; public static var timeBonusAmount:uint = 5; public static var totalLevels:uint = 17; public static var quit:Boolean = false; public static var evidence:uint = 0; public static var clues:uint = 0; public static var foundAllClues:Boolean = false; public static var startTime:uint = 120; public static var burglars:uint = 0; public static var replay:Boolean = false; public static var dead:Boolean = false; public static var musicOn:Boolean = true; public function Globals(){ super(); } } }//package com
Section 94
//Map (com.Map) package com { import flash.events.*; import flash.display.*; public class Map extends Sprite { public static var mapHeight:uint; public static var maps:Object; public static var mapWidth:uint; public function Map():void{ super(); } public static function init(_width, _height):void{ mapWidth = _width; mapHeight = _height; maps = new Object(); maps.test = [[1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 25, 25, 25, 25, 0, 0, 1], [1, 22, 22, 0, 0, 0, 0, 0, 0, 25, 25, 25, 25, 25, 25, 25, 25, 25, 0, 0, 0, 0, 25, 0, 1], [1, 22, 22, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 25, 1, 1], [1, 1, 1, 0, 0, 0, 0, 27, 0, 0, 0, 1, 21, 0, 0, 1, 22, 22, 0, 0, 0, 0, 1, 0, 1], [1, 0, 0, 0, 0, 0, 0, 4, 22, 22, 22, 1, 0, 0, 0, 1, 22, 22, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 27, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 1, 23, 0, 0, 0, 0, 0, 0, 1, 4, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 1], [1, 0, 22, 0, 1, 1, 1, 1, 1, 1, 0, 0, 1, 4, 4, 0, 0, 0, 0, 0, 3, 3, 3, 0, 1], [1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 0, 1, 1], [1, 22, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 25, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 27, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 22, 4, 0, 0, 0, 0, 0, 0, 0, 1, 22, 1, 24, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 5, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 27, 0, 0, 1, 1, 1, 25, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 25, 3, 3, 3, 25, 0, 0, 4, 0, 0, 1, 21, 25, 25, 1], [1, 26, 0, 0, 0, 0, 0, 2, 0, 0, 3, 3, 3, 3, 3, 0, 4, 4, 4, 0, 1, 23, 23, 2, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; maps.level1 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 22, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 22, 21, 1], [1, 0, 0, 0, 21, 0, 0, 0, 0, 0, 1, 1, 1], [1, 0, 0, 1, 1, 1, 0, 22, 22, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1], [1, 0, 0, 22, 22, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 27, 1], [1, 26, 0, 0, 0, 0, 0, 0, 22, 22, 0, 2, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; maps.level2 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 27, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 4, 4, 25, 0, 0, 0, 21, 0, 0, 0, 0, 0, 23, 0, 0, 0, 0, 25, 1], [1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 5, 1, 0, 0, 1, 1], [1, 0, 0, 0, 0, 23, 1, 25, 0, 0, 0, 0, 0, 23, 21, 1, 0, 0, 0, 1], [1, 0, 0, 0, 0, 5, 1, 23, 0, 0, 0, 25, 23, 4, 4, 1, 25, 0, 0, 1], [1, 25, 0, 0, 0, 0, 1, 1, 5, 1, 1, 1, 1, 1, 1, 1, 1, 5, 0, 1], [1, 5, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1], [1, 26, 1, 0, 0, 0, 0, 0, 2, 23, 23, 0, 0, 0, 0, 0, 25, 4, 4, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; maps.level3 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 27, 0, 0, 0, 0, 0, 0, 22, 22, 1], [1, 24, 24, 0, 0, 0, 22, 4, 4, 4, 4, 4, 4, 4, 22, 0, 0, 22, 22, 1], [1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1], [1, 22, 0, 0, 0, 0, 0, 0, 22, 22, 22, 1, 22, 22, 0, 0, 0, 1, 5, 1], [1, 22, 0, 0, 22, 0, 0, 0, 22, 22, 22, 1, 22, 22, 0, 0, 0, 1, 0, 1], [1, 1, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 5, 1], [1, 0, 21, 1, 1, 5, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 3, 1, 0, 1], [1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 24, 3, 24, 0, 0, 0, 3, 1, 5, 1], [1, 0, 0, 22, 1, 5, 0, 0, 0, 0, 3, 3, 3, 24, 0, 0, 3, 1, 0, 1], [1, 0, 0, 22, 1, 27, 0, 0, 0, 3, 3, 3, 3, 3, 0, 0, 3, 1, 5, 1], [1, 0, 0, 22, 1, 2, 0, 24, 3, 3, 3, 21, 3, 3, 3, 0, 3, 1, 0, 1], [1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 5, 1], [1, 26, 0, 0, 3, 3, 21, 3, 3, 3, 3, 3, 3, 24, 3, 3, 3, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; maps.level4 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 24, 25, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 4, 4, 21, 0, 0, 0, 0, 0, 0, 24, 0, 0, 0, 0, 25, 1], [1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 5, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 3, 25, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 3, 24, 0, 0, 0, 0, 0, 0, 0, 5, 1], [1, 0, 0, 0, 24, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 0, 0, 0, 25, 1], [1, 25, 0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 5, 1, 5, 1, 1, 1], [1, 1, 0, 0, 1, 24, 0, 0, 0, 0, 0, 0, 0, 0, 25, 1, 24, 0, 0, 1], [1, 0, 0, 0, 1, 4, 25, 0, 0, 0, 0, 0, 0, 0, 5, 1, 5, 0, 0, 1], [1, 0, 0, 5, 1, 1, 1, 0, 0, 0, 0, 21, 0, 0, 0, 1, 0, 0, 0, 1], [1, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1, 5, 0, 0, 1], [1, 0, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 25, 1, 25, 0, 0, 1], [1, 26, 0, 1, 21, 25, 24, 0, 3, 25, 0, 0, 27, 2, 24, 3, 2, 0, 21, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; maps.level5 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 25, 1], [1, 26, 0, 0, 0, 0, 0, 0, 0, 25, 25, 0, 25, 25, 0, 25, 25, 0, 25, 1], [1, 5, 1, 1, 1, 1, 25, 25, 25, 0, 0, 25, 0, 0, 25, 0, 0, 25, 21, 1], [1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 1, 0, 0, 1, 0, 0, 1, 1, 1], [1, 5, 0, 0, 3, 21, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1], [1, 0, 0, 22, 3, 3, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1], [1, 5, 0, 3, 3, 1, 1, 0, 22, 24, 27, 1, 0, 0, 1, 0, 0, 0, 0, 1], [1, 0, 0, 1, 1, 1, 0, 0, 22, 24, 4, 1, 22, 21, 1, 23, 23, 23, 0, 1], [1, 5, 0, 0, 0, 1, 21, 1, 1, 1, 1, 1, 22, 1, 1, 1, 1, 1, 0, 1], [1, 0, 0, 0, 0, 1, 22, 0, 0, 0, 22, 1, 22, 0, 1, 22, 0, 0, 22, 1], [1, 5, 0, 0, 0, 1, 0, 0, 5, 5, 0, 1, 22, 0, 1, 0, 0, 0, 0, 1], [1, 27, 0, 0, 23, 1, 0, 0, 0, 0, 0, 1, 22, 0, 1, 0, 0, 0, 0, 1], [1, 4, 0, 0, 3, 3, 3, 4, 4, 4, 22, 3, 2, 22, 3, 3, 4, 4, 22, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; maps.level6 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 26, 0, 0, 0, 21, 22, 3, 0, 0, 0, 0, 1, 0, 0, 0, 3, 24, 3, 1], [1, 24, 0, 0, 27, 22, 3, 3, 0, 25, 25, 23, 1, 0, 0, 0, 3, 3, 25, 1], [1, 5, 0, 0, 1, 1, 1, 1, 0, 0, 25, 23, 3, 23, 0, 27, 3, 3, 21, 1], [1, 23, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 5, 1, 1, 1, 1, 1], [1, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 23, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 22, 1], [1, 5, 0, 0, 22, 0, 0, 0, 0, 0, 0, 0, 5, 3, 3, 0, 0, 25, 22, 1], [1, 0, 0, 0, 22, 0, 0, 0, 0, 3, 23, 3, 3, 21, 3, 0, 27, 4, 4, 1], [1, 5, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 21, 0, 24, 25, 0, 0, 0, 22, 3, 21, 0, 0, 0, 0, 0, 0, 0, 23, 1], [1, 1, 1, 1, 1, 0, 0, 0, 24, 3, 3, 0, 0, 0, 0, 0, 0, 0, 25, 1], [1, 3, 3, 0, 0, 0, 0, 25, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 27, 1], [1, 24, 3, 0, 0, 0, 0, 3, 3, 3, 3, 2, 25, 24, 22, 23, 0, 4, 4, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; maps.level7 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 24, 24, 1, 0, 0, 0, 1, 22, 0, 0, 0, 22, 1, 0, 0, 1, 0, 0, 1], [1, 24, 24, 1, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 1], [1, 0, 0, 0, 0, 0, 23, 23, 3, 0, 26, 0, 3, 25, 25, 0, 1, 0, 0, 1], [1, 5, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 1], [1, 0, 0, 22, 0, 0, 0, 0, 22, 22, 3, 22, 22, 0, 0, 0, 3, 0, 0, 1], [1, 0, 0, 1, 27, 0, 0, 22, 1, 1, 1, 1, 1, 27, 0, 0, 3, 0, 0, 1], [1, 5, 0, 1, 4, 22, 22, 1, 0, 0, 1, 1, 1, 4, 22, 0, 1, 22, 0, 1], [1, 0, 0, 0, 1, 1, 1, 1, 0, 21, 3, 1, 0, 1, 5, 0, 1, 22, 0, 1], [1, 5, 0, 0, 0, 1, 1, 0, 0, 1, 3, 21, 0, 1, 22, 0, 0, 1, 22, 1], [1, 22, 22, 22, 0, 1, 1, 0, 5, 1, 1, 0, 0, 1, 1, 0, 0, 1, 22, 1], [1, 1, 1, 1, 0, 0, 1, 0, 22, 1, 1, 22, 0, 3, 1, 0, 1, 1, 22, 1], [1, 0, 0, 0, 0, 0, 3, 0, 1, 1, 1, 1, 0, 3, 3, 4, 0, 0, 22, 1], [1, 22, 22, 22, 2, 0, 1, 22, 1, 1, 1, 1, 22, 3, 3, 4, 22, 1, 22, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; maps.level8 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 3, 22, 25, 22, 22, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 27, 23, 21, 1], [1, 3, 3, 24, 21, 23, 0, 27, 0, 25, 24, 0, 3, 0, 0, 1, 1, 1, 5, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 23, 3, 0, 5, 25, 25, 0, 0, 0, 22, 1], [1, 0, 25, 24, 0, 0, 0, 24, 1, 1, 1, 0, 0, 5, 25, 0, 0, 0, 5, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 1], [1, 0, 0, 0, 5, 1, 1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 5, 1], [1, 23, 22, 27, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 23, 23, 0, 0, 25, 1], [1, 21, 4, 4, 23, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 0, 0, 0, 5, 1], [1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 23, 1], [1, 21, 22, 24, 1, 1, 0, 0, 0, 5, 23, 3, 24, 1, 4, 27, 0, 0, 5, 1], [1, 24, 22, 22, 0, 0, 0, 25, 0, 22, 3, 3, 25, 1, 1, 1, 1, 0, 0, 1], [1, 25, 0, 0, 0, 0, 0, 5, 0, 22, 3, 3, 23, 25, 3, 21, 1, 24, 0, 1], [1, 2, 0, 0, 0, 4, 4, 0, 0, 3, 3, 3, 3, 22, 3, 3, 1, 2, 26, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; maps.level9 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 25, 25, 25, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 1, 1, 1, 25, 25, 25, 25, 25, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 1, 22, 22, 1, 1, 1, 25, 0, 25, 25, 25, 25, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 21, 1, 22, 1, 1, 0, 0, 25, 25, 0, 0, 0, 1], [1, 27, 0, 0, 0, 0, 0, 0, 24, 22, 0, 0, 0, 21, 1, 1, 0, 25, 25, 1], [1, 4, 22, 22, 2, 22, 22, 22, 1, 0, 0, 0, 0, 0, 0, 0, 25, 0, 1, 1], [1, 1, 1, 1, 1, 1, 1, 23, 1, 0, 0, 0, 0, 25, 25, 25, 25, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 25, 25, 25, 0, 0, 1, 1, 0, 0, 1], [1, 21, 0, 0, 0, 0, 0, 0, 0, 25, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 25, 25, 25, 25, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 1], [1, 0, 0, 25, 25, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 3, 3, 23, 23, 1], [1, 0, 27, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 27, 3, 3, 21, 23, 1], [1, 26, 4, 22, 22, 22, 22, 22, 4, 4, 22, 22, 4, 22, 4, 3, 3, 3, 3, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; maps.level10 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 23, 22, 22, 22, 0, 0, 3, 3, 3, 0, 0, 0, 0, 0, 0, 25, 22, 22, 1], [1, 4, 21, 27, 22, 0, 0, 3, 21, 3, 25, 0, 0, 0, 0, 0, 4, 4, 27, 1], [1, 1, 1, 1, 1, 1, 0, 3, 1, 1, 24, 0, 1, 1, 1, 0, 1, 1, 1, 1], [1, 24, 24, 25, 25, 0, 0, 3, 0, 0, 0, 0, 0, 0, 3, 24, 25, 22, 22, 1], [1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 23, 0, 0, 0, 3, 3, 25, 23, 23, 1], [1, 0, 0, 0, 0, 23, 24, 0, 0, 1, 5, 0, 1, 1, 1, 1, 1, 1, 1, 1], [1, 27, 0, 0, 1, 1, 0, 0, 0, 1, 0, 24, 1, 0, 0, 0, 25, 25, 24, 1], [1, 2, 22, 22, 22, 22, 0, 0, 21, 1, 0, 5, 1, 0, 0, 0, 5, 22, 22, 1], [1, 1, 1, 1, 0, 0, 0, 0, 22, 1, 25, 0, 1, 0, 0, 0, 0, 0, 5, 1], [1, 0, 0, 0, 0, 0, 0, 3, 4, 1, 5, 0, 3, 3, 3, 3, 0, 0, 23, 1], [1, 0, 23, 22, 25, 1, 1, 1, 1, 1, 0, 22, 3, 21, 23, 3, 0, 0, 5, 1], [1, 0, 23, 0, 0, 3, 24, 3, 0, 0, 0, 5, 3, 3, 25, 3, 0, 0, 0, 1], [1, 26, 25, 0, 0, 3, 24, 3, 0, 0, 23, 23, 1, 3, 24, 3, 2, 27, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; maps.level11 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 0, 0, 0, 21, 1, 0, 0, 0, 0, 0], [1, 27, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0], [1, 2, 2, 2, 22, 22, 0, 1, 5, 5, 5, 22, 1, 0, 0, 0, 4, 4, 4, 1, 0, 0, 0, 0, 0], [1, 5, 1, 1, 1, 1, 0, 1, 22, 3, 3, 3, 1, 5, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 0, 0, 1, 3, 3, 3, 22, 1, 22, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0], [1, 5, 0, 0, 0, 0, 0, 1, 22, 3, 3, 3, 1, 1, 22, 22, 0, 22, 22, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 22, 0, 0, 1, 3, 3, 3, 22, 1, 24, 1, 1, 0, 22, 22, 1, 0, 0, 0, 0, 0], [1, 5, 0, 0, 1, 0, 0, 1, 23, 3, 3, 3, 1, 25, 25, 25, 0, 0, 22, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 0, 0, 1, 3, 3, 3, 23, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0], [1, 5, 0, 27, 0, 0, 0, 1, 23, 3, 3, 3, 1, 0, 0, 0, 0, 22, 0, 1, 0, 0, 0, 0, 0], [1, 1, 1, 4, 22, 0, 0, 1, 3, 3, 3, 23, 1, 0, 22, 0, 0, 1, 27, 1, 0, 0, 0, 0, 0], [1, 25, 25, 1, 1, 22, 22, 1, 25, 3, 3, 3, 1, 0, 1, 0, 0, 0, 4, 1, 0, 0, 0, 0, 0], [1, 25, 25, 0, 0, 1, 21, 1, 3, 3, 3, 25, 1, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0], [1, 25, 25, 0, 0, 25, 2, 1, 25, 3, 3, 3, 1, 2, 0, 0, 25, 25, 25, 1, 0, 0, 0, 0, 0], [1, 25, 1, 0, 25, 25, 1, 1, 3, 3, 3, 25, 1, 1, 0, 0, 0, 25, 25, 1, 0, 0, 0, 0, 0], [1, 0, 0, 25, 25, 1, 1, 1, 25, 1, 1, 1, 1, 1, 1, 22, 0, 1, 25, 1, 0, 0, 0, 0, 0], [1, 0, 25, 25, 3, 1, 21, 24, 0, 3, 3, 0, 24, 0, 1, 3, 22, 0, 27, 1, 0, 0, 0, 0, 0], [1, 4, 26, 3, 4, 1, 24, 24, 24, 3, 3, 23, 24, 23, 3, 3, 3, 0, 4, 1, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0]]; maps.level12 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 22, 0, 0, 0, 3, 21, 25, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0], [1, 0, 24, 0, 0, 4, 27, 25, 25, 3, 3, 25, 1, 0, 0, 0, 26, 0, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 23, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 22, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0], [1, 0, 23, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 22, 22, 0, 5, 1, 0, 0, 0, 0, 0], [1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 24, 23, 0, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 25, 25, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 25, 1, 0, 0, 0, 0, 0], [1, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 23, 1, 0, 0, 0, 0, 0], [1, 3, 24, 23, 0, 0, 0, 0, 0, 0, 22, 22, 0, 22, 1, 0, 0, 1, 5, 1, 0, 0, 0, 0, 0], [1, 5, 1, 1, 0, 0, 0, 1, 1, 1, 1, 3, 0, 25, 3, 0, 21, 0, 22, 1, 0, 0, 0, 0, 0], [1, 23, 22, 22, 0, 0, 0, 0, 25, 25, 1, 1, 0, 22, 3, 0, 25, 0, 5, 1, 0, 0, 0, 0, 0], [1, 4, 22, 23, 0, 0, 0, 0, 0, 23, 3, 3, 3, 1, 1, 0, 25, 23, 25, 1, 0, 0, 0, 0, 0], [1, 1, 1, 1, 0, 0, 0, 0, 23, 23, 3, 24, 24, 24, 1, 0, 25, 1, 1, 1, 0, 0, 0, 0, 0], [1, 24, 0, 0, 24, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 24, 25, 0, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 5, 0, 0, 22, 22, 22, 22, 25, 0, 27, 1, 5, 0, 0, 0, 1, 0, 0, 0, 0, 0], [1, 25, 0, 0, 22, 0, 0, 1, 1, 1, 1, 25, 0, 1, 1, 24, 0, 25, 27, 1, 0, 0, 0, 0, 0], [1, 3, 0, 22, 4, 0, 0, 23, 21, 3, 1, 25, 0, 0, 1, 2, 23, 3, 3, 1, 0, 0, 0, 0, 0], [1, 3, 4, 4, 4, 22, 0, 3, 23, 3, 1, 2, 23, 24, 1, 1, 1, 3, 23, 1, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0]]; maps.level13 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0], [1, 22, 22, 22, 22, 22, 25, 25, 0, 23, 23, 23, 23, 24, 24, 24, 24, 24, 25, 1, 0, 0, 0, 0, 0], [1, 22, 5, 5, 5, 22, 5, 25, 0, 23, 5, 5, 5, 23, 5, 5, 5, 24, 25, 1, 0, 0, 0, 0, 0], [1, 22, 5, 21, 5, 22, 5, 25, 0, 23, 5, 23, 5, 23, 5, 22, 22, 5, 24, 1, 0, 0, 0, 0, 0], [1, 22, 5, 5, 5, 22, 5, 25, 0, 23, 5, 23, 5, 23, 5, 22, 22, 5, 24, 1, 0, 0, 0, 0, 0], [1, 22, 5, 0, 0, 22, 5, 25, 27, 23, 5, 23, 5, 23, 5, 22, 22, 5, 24, 1, 0, 0, 0, 0, 0], [1, 22, 5, 0, 0, 22, 5, 25, 25, 25, 5, 23, 5, 23, 5, 22, 22, 5, 24, 1, 0, 0, 0, 0, 0], [1, 22, 5, 0, 0, 22, 5, 5, 5, 25, 5, 5, 5, 24, 5, 5, 5, 24, 25, 1, 0, 0, 0, 0, 0], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0], [1, 25, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0], [1, 1, 1, 0, 0, 0, 0, 0, 0, 3, 21, 2, 0, 0, 0, 0, 0, 0, 5, 1, 0, 0, 0, 0, 0], [1, 25, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0], [1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 25, 25, 25, 25, 25, 25, 0, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 21, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 0, 0, 0], [1, 1, 0, 0, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 24, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 26, 1, 4, 4, 0, 24, 21, 27, 0, 0, 0, 4, 4, 1, 27, 2, 1, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0]]; maps.level14 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0], [1, 25, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 25, 0, 0, 24, 0, 0, 0, 1, 0, 0, 0, 0, 0], [1, 5, 0, 22, 1, 0, 0, 22, 22, 22, 0, 23, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 22, 1, 0, 22, 24, 22, 22, 23, 1, 1, 0, 5, 5, 25, 0, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 5, 1, 0, 23, 5, 23, 23, 1, 1, 0, 0, 0, 0, 5, 0, 22, 1, 0, 0, 0, 0, 0], [1, 24, 0, 0, 1, 27, 25, 25, 25, 23, 1, 0, 0, 0, 0, 0, 21, 0, 5, 1, 0, 0, 0, 0, 0], [1, 5, 0, 0, 1, 3, 3, 22, 22, 1, 1, 0, 0, 0, 0, 0, 23, 0, 22, 1, 0, 0, 0, 0, 0], [1, 0, 0, 25, 1, 21, 3, 1, 1, 1, 0, 0, 0, 0, 0, 0, 23, 0, 5, 1, 0, 0, 0, 0, 0], [1, 0, 0, 5, 1, 1, 1, 1, 25, 0, 0, 0, 0, 0, 0, 0, 23, 0, 23, 1, 0, 0, 0, 0, 0], [1, 23, 0, 0, 1, 1, 1, 24, 25, 0, 0, 0, 0, 0, 5, 0, 24, 0, 5, 1, 0, 0, 0, 0, 0], [1, 5, 0, 0, 1, 0, 1, 1, 1, 22, 22, 0, 5, 0, 0, 0, 5, 0, 25, 1, 0, 0, 0, 0, 0], [1, 0, 0, 24, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 5, 1, 0, 0, 0, 0, 0], [1, 0, 0, 5, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0], [1, 22, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 5, 1, 0, 0, 0, 0, 0], [1, 5, 0, 0, 1, 0, 0, 25, 25, 25, 0, 1, 1, 0, 0, 0, 22, 0, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 25, 1, 0, 0, 25, 21, 25, 0, 0, 1, 27, 0, 0, 5, 0, 24, 1, 0, 0, 0, 0, 0], [1, 0, 0, 5, 1, 27, 0, 25, 25, 25, 0, 0, 1, 3, 25, 25, 25, 25, 24, 1, 0, 0, 0, 0, 0], [1, 26, 0, 23, 1, 4, 4, 0, 0, 0, 0, 0, 0, 3, 3, 22, 22, 4, 4, 1, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0]]; maps.level15 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0], [1, 0, 0, 25, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 25, 0, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 25, 0, 0, 1, 0, 25, 0, 0, 0, 25, 1, 21, 0, 25, 0, 0, 1, 0, 0, 0, 0, 0], [1, 0, 0, 4, 0, 0, 3, 0, 25, 0, 0, 0, 25, 1, 0, 0, 25, 0, 0, 1, 0, 0, 0, 0, 0], [1, 22, 1, 1, 1, 1, 1, 0, 25, 0, 0, 0, 25, 3, 22, 22, 4, 22, 0, 1, 0, 0, 0, 0, 0], [1, 22, 0, 0, 0, 1, 1, 1, 4, 22, 22, 22, 4, 1, 1, 1, 1, 1, 5, 1, 0, 0, 0, 0, 0], [1, 22, 0, 0, 0, 1, 24, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0], [1, 22, 0, 0, 21, 1, 25, 25, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 5, 1, 0, 0, 0, 0, 0], [1, 1, 1, 0, 1, 1, 1, 1, 27, 0, 0, 0, 3, 0, 0, 25, 25, 0, 0, 1, 0, 0, 0, 0, 0], [1, 1, 0, 0, 1, 23, 23, 1, 2, 0, 0, 1, 1, 0, 0, 25, 25, 0, 5, 1, 0, 0, 0, 0, 0], [1, 0, 0, 1, 24, 23, 24, 0, 1, 26, 0, 1, 1, 0, 0, 0, 0, 0, 27, 1, 0, 0, 0, 0, 0], [1, 0, 22, 1, 24, 25, 24, 0, 1, 1, 25, 25, 1, 23, 23, 23, 23, 23, 2, 1, 0, 0, 0, 0, 0], [1, 0, 22, 1, 1, 0, 1, 0, 0, 21, 1, 1, 1, 1, 1, 5, 1, 1, 1, 1, 0, 0, 0, 0, 0], [1, 22, 22, 22, 3, 0, 27, 0, 0, 0, 25, 0, 0, 0, 0, 3, 0, 0, 0, 1, 0, 0, 0, 0, 0], [1, 22, 22, 22, 3, 3, 2, 0, 25, 25, 1, 25, 25, 0, 1, 1, 1, 5, 0, 1, 0, 0, 0, 0, 0], [1, 5, 5, 1, 1, 1, 1, 1, 22, 22, 25, 22, 22, 1, 1, 1, 0, 22, 25, 1, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 1, 21, 1, 1, 5, 5, 5, 1, 1, 1, 0, 0, 1, 25, 1, 0, 0, 0, 0, 0], [1, 27, 1, 0, 0, 1, 0, 25, 0, 0, 0, 0, 25, 0, 1, 0, 0, 0, 25, 1, 0, 0, 0, 0, 0], [1, 2, 22, 22, 22, 3, 22, 4, 3, 3, 2, 3, 4, 22, 3, 22, 22, 22, 4, 1, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0]]; maps.level16 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 22, 22, 22, 22, 22, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 3, 0, 3, 0, 0, 0, 22, 22, 0, 0, 0, 0, 0, 22, 22, 0, 0, 0, 0, 22, 22, 0, 0, 1, 1, 24, 24, 1, 1, 1, 1, 0, 1], [1, 0, 0, 0, 1, 22, 1, 25, 1, 25, 1, 22, 1, 1, 1, 1, 25, 25, 25, 1, 1, 1, 1, 25, 25, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 22, 22, 22, 0, 1], [1, 0, 0, 22, 1, 0, 0, 25, 0, 25, 0, 0, 1, 22, 21, 1, 23, 23, 23, 1, 22, 22, 1, 23, 23, 1, 22, 22, 1, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 1], [1, 22, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 1, 5, 0, 1, 1, 1, 1, 1, 5, 0, 1, 1, 1, 1, 0, 0, 1, 0, 0, 1, 1, 1, 1, 22, 22, 22, 0, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 27, 1, 0, 0, 0, 0, 0, 0, 0, 27, 0, 0, 0, 0, 0, 0, 5, 1, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 1], [1, 22, 22, 22, 22, 22, 22, 0, 0, 0, 0, 4, 1, 4, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 25, 25, 0, 0, 24, 24, 0, 1], [1, 1, 1, 1, 1, 1, 1, 5, 1, 1, 1, 1, 1, 1, 1, 1, 22, 22, 22, 1, 1, 1, 0, 0, 0, 0, 25, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 27, 0, 0, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 25, 25, 25, 1, 0, 1, 0, 0, 1, 4, 22, 1, 0, 0, 0, 0, 1], [1, 25, 25, 0, 0, 0, 0, 4, 0, 0, 25, 25, 1, 25, 25, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 21, 1], [1, 1, 1, 22, 1, 1, 1, 1, 0, 1, 1, 1, 1, 25, 25, 0, 0, 0, 0, 22, 22, 22, 0, 0, 0, 0, 0, 0, 1, 23, 0, 0, 0, 25, 25, 0, 0, 0, 1, 1], [1, 25, 3, 3, 3, 0, 0, 1, 21, 1, 0, 0, 3, 25, 25, 0, 0, 0, 0, 22, 22, 22, 22, 0, 0, 0, 0, 0, 1, 0, 0, 0, 22, 4, 4, 22, 0, 0, 0, 1], [1, 25, 22, 2, 0, 0, 0, 1, 1, 1, 0, 0, 1, 1, 1, 0, 0, 25, 25, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 1], [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 1, 24, 0, 24, 0, 1, 22, 0, 0, 25, 1, 23, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1], [1, 0, 0, 0, 0, 0, 22, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 25, 0, 0, 1, 1, 0, 0, 25, 1, 1, 0, 0, 0, 0, 27, 0, 0, 0, 1, 1], [1, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 25, 3, 25, 0, 0, 1, 25, 0, 1, 1, 0, 0, 22, 22, 4, 4, 22, 22, 0, 0, 1], [1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 25, 0, 0, 0, 0, 25, 3, 3, 3, 25, 0, 1, 25, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 1], [1, 22, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 1, 25, 0, 0, 0, 25, 3, 3, 3, 3, 3, 25, 1, 1, 0, 25, 1, 23, 0, 0, 0, 0, 0, 0, 0, 0, 23, 1], [1, 1, 3, 3, 22, 22, 22, 22, 22, 22, 0, 0, 1, 25, 0, 0, 1, 3, 3, 3, 21, 3, 3, 3, 1, 0, 0, 25, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, 0, 1, 1, 0, 25, 1, 3, 3, 25, 25, 25, 3, 3, 1, 0, 0, 1, 1, 0, 0, 22, 22, 4, 4, 22, 22, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 25, 1, 3, 3, 25, 3, 25, 3, 3, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 1], [1, 1, 1, 1, 1, 1, 3, 0, 3, 1, 1, 1, 1, 0, 0, 1, 1, 3, 3, 25, 3, 25, 3, 3, 0, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 26, 22, 22, 22, 22, 22, 2, 22, 22, 22, 22, 1, 23, 0, 0, 0, 3, 3, 25, 3, 25, 3, 3, 0, 0, 0, 0, 0, 0, 0, 22, 25, 4, 4, 25, 22, 0, 2, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; } public static function GetBlankMap():Array{ var newMapArray:Array; var newLine:Array; var bottomLine:Array; var i:uint; newMapArray = new Array(); newLine = new Array(); bottomLine = new Array(); i = 0; while (i < mapWidth) { if ((((i == 0)) || ((i == (mapWidth - 1))))){ newLine.push(1); } else { newLine.push(0); }; i++; }; i = 0; while (i < mapWidth) { bottomLine.push(1); i++; }; i = 0; while (i < mapHeight) { if (i == (mapWidth - 1)){ newMapArray.push(bottomLine); } else { newMapArray.push(newLine); }; i++; }; return (newMapArray); } private static function mainloop(e:Event):void{ } } }//package com
Section 95
//TweenLite (gs.TweenLite) package gs { import flash.events.*; import flash.display.*; import flash.geom.*; import flash.utils.*; public class TweenLite { public var delay:Number; protected var _hasUpdate:Boolean; public var started:Boolean; protected var _subTweens:Array; public var initted:Boolean; public var active:Boolean; public var startTime:Number; public var target:Object; public var duration:Number; protected var _hst:Boolean; protected var _isDisplayObject:Boolean; public var gc:Boolean; public var vars:Object; public var ease:Function; public var tweens:Array; protected var _specialVars:Object; public var combinedTimeScale:Number; public var initTime:Number; private static var _timer:Timer = new Timer(2000); private static var _classInitted:Boolean; public static var defaultEase:Function = TweenLite.easeOut; public static var version:Number = 9.3; public static var masterList:Dictionary = new Dictionary(false); public static var currentTime:uint; public static var overwriteManager:Object; public static var killDelayedCallsTo:Function = TweenLite.killTweensOf; public static var timingSprite:Sprite = new Sprite(); public function TweenLite($target:Object, $duration:Number, $vars:Object){ var mode:int; super(); if ($target == null){ return; }; if (!_classInitted){ currentTime = getTimer(); timingSprite.addEventListener(Event.ENTER_FRAME, updateAll, false, 0, true); if (overwriteManager == null){ overwriteManager = {mode:1, enabled:false}; }; _timer.addEventListener("timer", killGarbage, false, 0, true); _timer.start(); _classInitted = true; }; this.vars = $vars; this.duration = (($duration) || (0.001)); this.delay = (($vars.delay) || (0)); this.combinedTimeScale = (($vars.timeScale) || (1)); this.active = Boolean(((($duration == 0)) && ((this.delay == 0)))); this.target = $target; _isDisplayObject = Boolean(((($target is DisplayObject)) || ($target.hasOwnProperty("isTweenProxy")))); if (!(this.vars.ease is Function)){ this.vars.ease = defaultEase; }; if (this.vars.easeParams != null){ this.vars.proxiedEase = this.vars.ease; this.vars.ease = easeProxy; }; this.ease = this.vars.ease; if (!isNaN(Number(this.vars.autoAlpha))){ this.vars.alpha = Number(this.vars.autoAlpha); this.vars.visible = Boolean((this.vars.alpha > 0)); }; _specialVars = ((this.vars.isTV)==true) ? this.vars.exposedProps : this.vars; this.tweens = []; _subTweens = []; _hst = (this.initted = false); this.initTime = currentTime; this.startTime = (this.initTime + (this.delay * 1000)); mode = (((($vars.overwrite == undefined)) || (((!(overwriteManager.enabled)) && (($vars.overwrite > 1)))))) ? overwriteManager.mode : int($vars.overwrite); if ((((masterList[$target] == undefined)) || (((!(($target == null))) && ((mode == 1)))))){ masterList[$target] = []; }; masterList[$target].push(this); if ((((((this.vars.runBackwards == true)) && (!((this.vars.renderOnStart == true))))) || (this.active))){ initTweenVals(); if (this.active){ render((this.startTime + 1)); } else { render(this.startTime); }; if (((((!((_specialVars.visible == null))) && ((this.vars.runBackwards == true)))) && (_isDisplayObject))){ this.target.visible = _specialVars.visible; }; }; } public function set enabled($b:Boolean):void{ var a:Array; var found:Boolean; var i:int; if ($b){ if (masterList[this.target] == undefined){ masterList[this.target] = [this]; } else { a = masterList[this.target]; i = (a.length - 1); while (i > -1) { if (a[i] == this){ found = true; break; }; i--; }; if (!found){ masterList[this.target].push(this); }; }; }; this.gc = ($b) ? false : true; if (this.gc){ this.active = false; } else { this.active = this.started; }; } public function render($t:uint):void{ var time:Number; var factor:Number; var tp:Object; var i:int; time = (($t - this.startTime) * 0.001); if (time >= this.duration){ time = this.duration; factor = ((((this.ease == this.vars.ease)) || ((this.duration == 0.001)))) ? 1 : 0; } else { factor = this.ease(time, 0, 1, this.duration); }; i = (this.tweens.length - 1); while (i > -1) { tp = this.tweens[i]; tp[0][tp[1]] = (tp[2] + (factor * tp[3])); i--; }; if (_hst){ i = (_subTweens.length - 1); while (i > -1) { _subTweens[i].proxy(_subTweens[i], time); i--; }; }; if (_hasUpdate){ this.vars.onUpdate.apply(null, this.vars.onUpdateParams); }; if (time == this.duration){ complete(true); }; } public function activate():void{ this.started = (this.active = true); if (!this.initted){ initTweenVals(); }; if (this.vars.onStart != null){ this.vars.onStart.apply(null, this.vars.onStartParams); }; if (this.duration == 0.001){ this.startTime = (this.startTime - 1); }; } public function clear():void{ this.tweens = []; _subTweens = []; this.vars = {}; _hst = (_hasUpdate = false); } protected function addSubTween($name:String, $proxy:Function, $target:Object, $props:Object, $info:Object=null):void{ var p:String; _subTweens[_subTweens.length] = {name:$name, proxy:$proxy, target:$target, info:$info}; for (p in $props) { if (typeof($props[p]) == "number"){ this.tweens[this.tweens.length] = [$target, p, $target[p], ($props[p] - $target[p]), $name]; } else { this.tweens[this.tweens.length] = [$target, p, $target[p], Number($props[p]), $name]; }; }; _hst = true; } public function initTweenVals($hrp:Boolean=false, $reservedProps:String=""):void{ var p:String; var i:int; var endArray:Array; var clr:ColorTransform; var endClr:ColorTransform; var tp:Object; if (((!($hrp)) && (overwriteManager.enabled))){ overwriteManager.manageOverwrites(this, masterList[this.target]); }; if ((this.target is Array)){ endArray = ((this.vars.endArray) || ([])); i = 0; while (i < endArray.length) { if (((!((this.target[i] == endArray[i]))) && (!((this.target[i] == undefined))))){ this.tweens[this.tweens.length] = [this.target, i.toString(), this.target[i], (endArray[i] - this.target[i]), i.toString()]; }; i++; }; } else { if (((((!((typeof(_specialVars.tint) == "undefined"))) || ((this.vars.removeTint == true)))) && (this.target.hasOwnProperty("transform")))){ clr = this.target.transform.colorTransform; endClr = new ColorTransform(); if (_specialVars.alpha != undefined){ endClr.alphaMultiplier = _specialVars.alpha; delete _specialVars.alpha; } else { endClr.alphaMultiplier = this.target.alpha; }; if (((!((this.vars.removeTint == true))) && (((((!((_specialVars.tint == null))) && (!((_specialVars.tint == ""))))) || ((_specialVars.tint == 0)))))){ endClr.color = _specialVars.tint; }; addSubTween("tint", tintProxy, {progress:0}, {progress:1}, {target:this.target, color:clr, endColor:endClr}); }; if (((!((_specialVars.frame == null))) && (_isDisplayObject))){ addSubTween("frame", frameProxy, {frame:this.target.currentFrame}, {frame:_specialVars.frame}, {target:this.target}); }; if (((!(isNaN(this.vars.volume))) && (this.target.hasOwnProperty("soundTransform")))){ addSubTween("volume", volumeProxy, this.target.soundTransform, {volume:this.vars.volume}, {target:this.target}); }; if (((!((_specialVars.visible == null))) && (_isDisplayObject))){ addSubTween("visible", visibleProxy, {}, {}, {tween:this}); }; for (p in _specialVars) { if ((((((((((((((((((((((((((((((((((((p == "ease")) || ((p == "delay")))) || ((p == "overwrite")))) || ((p == "onComplete")))) || ((p == "onCompleteParams")))) || ((p == "runBackwards")))) || ((p == "visible")))) || ((p == "autoOverwrite")))) || ((p == "persist")))) || ((p == "onUpdate")))) || ((p == "onUpdateParams")))) || ((p == "autoAlpha")))) || ((p == "onStart")))) || ((p == "onStartParams")))) || ((p == "renderOnStart")))) || ((p == "proxiedEase")))) || ((p == "easeParams")))) || ((($hrp) && (!(($reservedProps.indexOf(((" " + p) + " ")) == -1))))))){ } else { if (((!(((_isDisplayObject) && ((((((p == "tint")) || ((p == "removeTint")))) || ((p == "frame"))))))) && (!((((p == "volume")) && (this.target.hasOwnProperty("soundTransform"))))))){ if (typeof(_specialVars[p]) == "number"){ this.tweens[this.tweens.length] = [this.target, p, this.target[p], (_specialVars[p] - this.target[p]), p]; } else { this.tweens[this.tweens.length] = [this.target, p, this.target[p], Number(_specialVars[p]), p]; }; }; }; }; }; if (this.vars.runBackwards == true){ i = (this.tweens.length - 1); while (i > -1) { tp = this.tweens[i]; tp[2] = (tp[2] + tp[3]); tp[3] = (tp[3] * -1); i--; }; }; if (this.vars.onUpdate != null){ _hasUpdate = true; }; this.initted = true; } protected function easeProxy($t:Number, $b:Number, $c:Number, $d:Number):Number{ return (this.vars.proxiedEase.apply(null, arguments.concat(this.vars.easeParams))); } public function killVars($vars:Object):void{ if (overwriteManager.enabled){ overwriteManager.killVars($vars, this.vars, this.tweens, _subTweens, []); }; } public function get enabled():Boolean{ return ((this.gc) ? false : true); } public function complete($skipRender:Boolean=false):void{ if (!$skipRender){ if (!this.initted){ initTweenVals(); }; this.startTime = (currentTime - ((this.duration * 1000) / this.combinedTimeScale)); render(currentTime); return; }; if (this.vars.persist != true){ this.enabled = false; }; if (this.vars.onComplete != null){ this.vars.onComplete.apply(null, this.vars.onCompleteParams); }; } public static function frameProxy($o:Object, $time:Number=0):void{ $o.info.target.gotoAndStop(Math.round($o.target.frame)); } public static function removeTween($t:TweenLite, $clear:Boolean=true):void{ if ($t != null){ if ($clear){ $t.clear(); }; $t.enabled = false; }; } public static function visibleProxy($o:Object, $time:Number):void{ var t:TweenLite; t = $o.info.tween; if (t.duration == $time){ if (((!((t.vars.runBackwards == true))) && ((t.ease == t.vars.ease)))){ t.target.visible = t.vars.visible; }; } else { if (t.target.visible != true){ t.target.visible = true; }; }; } public static function killTweensOf($target:Object=null, $complete:Boolean=false):void{ var a:Array; var i:int; var tween:TweenLite; if (((!(($target == null))) && (!((masterList[$target] == undefined))))){ a = masterList[$target]; i = (a.length - 1); while (i > -1) { tween = a[i]; if ((($complete) && (!(tween.gc)))){ tween.complete(false); }; tween.clear(); i--; }; delete masterList[$target]; }; } public static function updateAll($e:Event=null):void{ var t:uint; var ml:Dictionary; var a:Array; var i:int; var tween:TweenLite; t = (currentTime = getTimer()); ml = masterList; for each (a in ml) { i = (a.length - 1); while (i > -1) { tween = a[i]; if (tween == null){ } else { if (tween.active){ tween.render(t); } else { if (tween.gc){ a.splice(i, 1); } else { if (t >= tween.startTime){ tween.activate(); tween.render(t); }; }; }; }; i--; }; }; } public static function delayedCall($delay:Number, $onComplete:Function, $onCompleteParams:Array=null):TweenLite{ return (new TweenLite($onComplete, 0, {delay:$delay, onComplete:$onComplete, onCompleteParams:$onCompleteParams, overwrite:0})); } public static function from($target:Object, $duration:Number, $vars:Object):TweenLite{ $vars.runBackwards = true; return (new TweenLite($target, $duration, $vars)); } public static function easeOut($t:Number, $b:Number, $c:Number, $d:Number):Number{ $t = ($t / $d); return ((((-($c) * $t) * ($t - 2)) + $b)); } public static function tintProxy($o:Object, $time:Number=0):void{ var n:Number; var r:Number; var sc:Object; var ec:Object; n = $o.target.progress; r = (1 - n); sc = $o.info.color; ec = $o.info.endColor; $o.info.target.transform.colorTransform = new ColorTransform(((sc.redMultiplier * r) + (ec.redMultiplier * n)), ((sc.greenMultiplier * r) + (ec.greenMultiplier * n)), ((sc.blueMultiplier * r) + (ec.blueMultiplier * n)), ((sc.alphaMultiplier * r) + (ec.alphaMultiplier * n)), ((sc.redOffset * r) + (ec.redOffset * n)), ((sc.greenOffset * r) + (ec.greenOffset * n)), ((sc.blueOffset * r) + (ec.blueOffset * n)), ((sc.alphaOffset * r) + (ec.alphaOffset * n))); } public static function volumeProxy($o:Object, $time:Number=0):void{ $o.info.target.soundTransform = $o.target; } protected static function killGarbage($e:TimerEvent):void{ var ml:Dictionary; var tgt:Object; var a:Array; ml = masterList; for (tgt in ml) { if (ml[tgt].length == 0){ delete ml[tgt]; }; }; } public static function to($target:Object, $duration:Number, $vars:Object):TweenLite{ return (new TweenLite($target, $duration, $vars)); } } }//package gs
Section 96
//URLCaller (net.URLCaller) package net { import flash.events.*; import flash.net.*; import com.gamezhero.api.as3.*; public class URLCaller { public function URLCaller(){ super(); } public static function getURL(url:String, window:String="_blank"):void{ navigateToURL(new URLRequest(url), window); } public static function submitScore(score:Number):void{ } public static function mainLink(e:MouseEvent=null):void{ getURL("http://www.thistler.net"); } public static function viewScores(e:MouseEvent=null):void{ getURL("http://www.yourwebsite.com/viewscorespage"); } public static function playMoreGames(e:MouseEvent=null):void{ getURL("http://www.yourwebsite.com"); } public static function notValid(e:MouseEvent=null):void{ getURL("http://www.thistler.net"); } public static function downloadGame(e:MouseEvent=null):void{ getURL("http://www.yourwebsite.com/downloadgame"); } public static function goto(event:MouseEvent):void{ switch (event.target.name){ case "gamezheroBtn1": GamezheroApi.linkZorroLogo(); break; case "gamezheroBtn2": GamezheroApi.linkZorroLogo(); break; case "topScoreBtn": GamezheroApi.linkTopScore(); break; case "sendToFriendsBtn": GamezheroApi.linkSendToFrined(); break; case "publishBtn": GamezheroApi.linkPublish(); break; case "moreGamesBtn": GamezheroApi.linkMoreGames(); break; default: GamezheroApi.linkMoreGames(); }; } public static function getGameForSite(e:MouseEvent=null):void{ getURL("http://www.yourwebsite.com/getgame"); } } }//package net
Section 97
//clips_3 (Plod_fla.clips_3) package Plod_fla { import flash.display.*; public dynamic class clips_3 extends MovieClip { public function clips_3(){ super(); addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package Plod_fla
Section 98
//crateBreak_135 (Plod_fla.crateBreak_135) package Plod_fla { import flash.display.*; public dynamic class crateBreak_135 extends MovieClip { public function crateBreak_135(){ super(); addFrameScript(15, frame16); } function frame16(){ stop(); } } }//package Plod_fla
Section 99
//gamezhero_z_2_161 (Plod_fla.gamezhero_z_2_161) package Plod_fla { import flash.display.*; public dynamic class gamezhero_z_2_161 extends MovieClip { public function gamezhero_z_2_161(){ super(); addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package Plod_fla
Section 100
//hit_203 (Plod_fla.hit_203) package Plod_fla { import flash.display.*; public dynamic class hit_203 extends MovieClip { public function hit_203(){ super(); addFrameScript(4, frame5); } function frame5(){ stop(); } } }//package Plod_fla
Section 101
//jumpup_202 (Plod_fla.jumpup_202) package Plod_fla { import flash.display.*; public dynamic class jumpup_202 extends MovieClip { public function jumpup_202(){ super(); addFrameScript(3, frame4); } function frame4(){ stop(); } } }//package Plod_fla
Section 102
//MainTimeline (Plod_fla.MainTimeline) package Plod_fla { import flash.events.*; import flash.display.*; import net.*; import com.gamezhero.api.as3.*; import com.Ui.*; public dynamic class MainTimeline extends MovieClip { public var urlEnd:Number; public var domainArray:Array; public var urlStart:Number; public var domEnd:Number; public var myContextMenu:MyContextMenu; public var i:uint; public var url:String; public var LastDot:Number; public var domain:String; public var isValid:Boolean; public function MainTimeline(){ super(); addFrameScript(0, frame1, 1, frame2); } public function nextStep():void{ gotoAndStop("gameplay"); } function frame1(){ stop(); GamezheroApi.ini("plod"); GamezheroApi.preloader(this, nextStep); stop(); myContextMenu = new MyContextMenu(); myContextMenu.init(this); stage.quality = "medium"; isValid = true; url = stage.loaderInfo.url; urlStart = (url.indexOf("://") + 3); urlEnd = url.indexOf("/", urlStart); domain = url.substring(urlStart, urlEnd); LastDot = (domain.lastIndexOf(".") - 1); domEnd = (domain.lastIndexOf(".", LastDot) + 1); domain = domain.substring(domEnd, domain.length); domainArray = ["thistler.net", "flashgamelicense.com", "localhost"]; i = 0; while (i < domainArray.length) { if (domain == domainArray[i]){ isValid = true; break; }; i++; }; if (!isValid){ URLCaller.notValid(); }; } function frame2(){ gotoAndStop(1); } public function gotoURLe(e:MouseEvent):void{ URLCaller.notValid(); } } }//package Plod_fla
Section 103
//music_2 (Plod_fla.music_2) package Plod_fla { import flash.display.*; public dynamic class music_2 extends MovieClip { public function music_2(){ super(); addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package Plod_fla
Section 104
//plod_hit_93 (Plod_fla.plod_hit_93) package Plod_fla { import flash.display.*; public dynamic class plod_hit_93 extends MovieClip { public function plod_hit_93(){ super(); addFrameScript(18, frame19); } function frame19(){ stop(); } } }//package Plod_fla
Section 105
//plod_jumping_92 (Plod_fla.plod_jumping_92) package Plod_fla { import flash.display.*; public dynamic class plod_jumping_92 extends MovieClip { public function plod_jumping_92(){ super(); addFrameScript(29, frame30); } function frame30(){ stop(); } } }//package Plod_fla
Section 106
//plod_swinging_94 (Plod_fla.plod_swinging_94) package Plod_fla { import flash.display.*; public dynamic class plod_swinging_94 extends MovieClip { public function plod_swinging_94(){ super(); addFrameScript(8, frame9); } function frame9(){ stop(); } } }//package Plod_fla
Section 107
//tired_206 (Plod_fla.tired_206) package Plod_fla { import flash.display.*; public dynamic class tired_206 extends MovieClip { public function tired_206(){ super(); addFrameScript(41, frame42); } function frame42(){ stop(); } } }//package Plod_fla
Section 108
//victory_205 (Plod_fla.victory_205) package Plod_fla { import flash.display.*; public dynamic class victory_205 extends MovieClip { public function victory_205(){ super(); addFrameScript(19, frame20); } function frame20(){ stop(); } } }//package Plod_fla
Section 109
//SWFConsole (rl.dev.SWFConsole) package rl.dev { import flash.events.*; import flash.display.*; import flash.text.*; import flash.utils.*; import flash.system.*; public class SWFConsole extends Sprite { private static const INPUT_BG_HEIGHT:int = 20; private static const _FPS_REFRESH_RATE:uint = 1000; private static const SCROLLHANDLE_COLOUR:int = 0xFFFFFF; private static const HEADER_HEIGHT:int = 20; private static const SCROLLHANDLE_WIDTH:int = 10; private static const TEXT_COLOUR:int = 0xFFFFFF; private static const HEADER_BG_ALPHA:Number = 0.6; private static const SCROLLTRACK_ALPHA:Number = 0.5; private static const SCROLLBUTTON_ALPHA:Number = 0.9; private static const _HISTORY_STATES:uint = 20; private static const BACKGROUND_HEIGHT:int = 200; private static const INPUTAREA_BG_HEIGHT:int = 30; private static const SCROLLHANDLE_HEIGHT:int = 60; private static const UPDATE_INTERVAL:int = 1000; private static const SCROLLTRACK_WIDTH:int = 10; private static const SCROLLTRACK_COLOUR:int = 0; private static const INPUT_BG_COLOUR:int = 0xFFFFFF; private static const SCROLLHANDLE_ALPHA:Number = 0.9; private static const VERSION:String = "1.0"; private static const INPUT_BG_ALPHA:Number = 0.2; private static const SHADOW_COLOUR:int = 0; private static const SCROLLBUTTON_COLOUR:int = 0xFFFFFF; private static const INPUTAREA_BG_ALPHA:Number = 0.7; private static const HEADER_BG_COLOUR:int = 0; private static const WELCOME_MESSAGE:String = "============================================================ New features: - Resource Monitor - type !resmon to activate ============================================================"; private static const BACKGROUND_ALPHA:Number = 0.7; private static const BACKGROUND_COLOUR:int = 0; private static const INPUTAREA_BG_COLOUR:int = 0; private static var _scrollButtonDown:Sprite; private static var _enabled:Boolean = false; private static var _stageHeight:Number; private static var _stageWidth:Number; private static var _headerText:TextField; private static var _percent:Number; private static var _text:TextField; private static var _lastcommands:Array; private static var _avg:Number = 0; private static var _traceEnabled:Boolean = false; private static var _textFormat:TextFormat; private static var _fpsBg:Shape; private static var _fps:Sprite; private static var _memUsage:Sprite; private static var _outputMask:Shape; private static var _scrollHandle:Sprite; private static var _fpsTimer:Timer; private static var _txt_avgfps:TextField; private static var _timer:Timer; private static var _txt_mem:TextField; public static var _activated:Boolean = false; private static var _history:Array; private static var _headerTextFormat:TextFormat; private static var _txt_fps:TextField; private static var _inputAreaBg:Shape; private static var _fpsValue:uint = 0; private static var _inputBg:Shape; private static var _headerTextShadow:TextField; private static var _scrollButtonUp:Sprite; private static var _scrollButtonDownShape:Shape; private static var _min:Number; private static var _max:Number; private static var _stageFrameRate:uint; private static var _scrollButtonUpShape:Shape; private static var _scrollTrack:Shape; private static var _offset:Number; private static var _inputText:TextField; private static var _scrollHandleShape:Shape; private static var _headerTextShadowFormat:TextFormat; private static var _frames:uint = 0; private static var _bg:Shape; private static var _headerbg:Shape; private static var _lastcommandsindex:Number; private static var _memBg:Shape; public function SWFConsole(stageWidth:Number, stageHeight:Number, traceEnabled=false){ super(); _stageWidth = stageWidth; _stageHeight = stageHeight; _traceEnabled = traceEnabled; if (stage){ _init(); } else { addEventListener(Event.ADDED_TO_STAGE, _init, false, 0, true); }; } private function _findChar(command:String, char:String):Boolean{ var i:*; i = 0; while (i < command.length) { if (command.charAt(i) == char){ return (true); }; i++; }; return (false); } private function _createScrollHandle():void{ _scrollHandleShape = new Shape(); _scrollHandleShape.graphics.beginFill(SCROLLHANDLE_COLOUR, SCROLLHANDLE_ALPHA); _scrollHandleShape.graphics.drawRect(0, 0, SCROLLHANDLE_WIDTH, SCROLLHANDLE_HEIGHT); _scrollHandleShape.graphics.endFill(); _scrollHandleShape.cacheAsBitmap = true; _scrollHandle = new Sprite(); _scrollHandle.addChild(_scrollHandleShape); _scrollHandle.x = (_scrollTrack.x - (SCROLLHANDLE_WIDTH - SCROLLTRACK_WIDTH)); _scrollHandle.y = _scrollTrack.y; addChild(_scrollHandle); } private function _processCommand(command:String):void{ output(("> " + command)); _lastcommands.push(command); _lastcommandsindex = (_lastcommands.length - 1); command = _removeWhitespace(command); if (command == ""){ return; }; if (command.charAt(0) == "!"){ _runCommand(command); } else { if (_findChar(command, "(")){ _runFunc(command); } else { _runProperty(command); }; }; } private function _recurseChildren(dispObj:Object, child:String):Object{ var target:Object; var i:*; if ((((((dispObj.hasOwnProperty("numChildren") == false)) || ((dispObj.numChildren == null)))) || ((dispObj.numChildren == 0)))){ return (target); }; i = 0; while (i < dispObj.numChildren) { if (dispObj.getChildAt(i).name == child){ return (dispObj.getChildAt(i)); }; if (target == null){ target = _recurseChildren((dispObj.getChildAt(i) as Object), child); }; i++; }; return (target); } private function _createScrollBar():void{ _createScrollTrack(); _createScrollButtons(); _createScrollHandle(); _scrollTrack.visible = false; _scrollButtonUp.visible = false; _scrollButtonDown.visible = false; _scrollHandle.visible = false; _min = _scrollTrack.y; _max = ((_scrollTrack.y + _scrollTrack.height) - _scrollHandle.height); _scrollHandle.buttonMode = true; _scrollHandle.addEventListener(MouseEvent.MOUSE_DOWN, _handleDown, false, 0, true); stage.addEventListener(MouseEvent.MOUSE_UP, _handleUp, false, 0, true); addEventListener(MouseEvent.MOUSE_WHEEL, _scrollWheel, false, 0, true); } private function _handleUp(e:MouseEvent):void{ stage.removeEventListener(MouseEvent.MOUSE_MOVE, _handleMove); } private function _createScrollTrack():void{ _scrollTrack = new Shape(); _scrollTrack.graphics.beginFill(SCROLLTRACK_COLOUR, SCROLLTRACK_ALPHA); _scrollTrack.graphics.drawRect(0, 0, SCROLLTRACK_WIDTH, (BACKGROUND_HEIGHT - 60)); _scrollTrack.graphics.endFill(); _scrollTrack.x = (stage.stageWidth - 30); _scrollTrack.y = (HEADER_HEIGHT + 30); _scrollTrack.cacheAsBitmap = true; addChild(_scrollTrack); } public function hide():void{ alpha = 0; visible = false; } private function _keyListener(e:KeyboardEvent):void{ if (_activated){ switch (e.keyCode){ case 192: if (_enabled){ hide(); } else { _inputText.text = ""; show(); stage.focus = _inputText; }; _enabled = !(_enabled); break; case 13: _processCommand(_inputText.text); _inputText.text = ""; break; case 38: if (_lastcommands.length > 0){ _inputText.text = _lastcommands[_lastcommandsindex]; _inputText.setSelection(_inputText.length, _inputText.length); _lastcommandsindex--; if (_lastcommandsindex < 0){ _lastcommandsindex = 0; }; }; break; }; }; } private function _calculateFPS(e:TimerEvent):void{ var i:uint; _fpsValue = ((_frames)>_stageFrameRate) ? _stageFrameRate : _frames; _txt_fps.text = ("FPS: " + String(_fpsValue)); _frames = 0; _history.unshift(_fpsValue); if (_history.length > _HISTORY_STATES){ _history.pop(); }; _avg = 0; i = 0; while (i < _history.length) { _avg = (_avg + _history[i]); i++; }; _txt_avgfps.text = ("AVG: " + String(Math.round((_avg / _history.length)))); } private function _removeWhitespace(str:String):String{ var tempStr:String; var i:*; tempStr = ""; i = 0; while (i < str.length) { if (str.charAt(i) != " "){ tempStr = (tempStr + str.charAt(i)); }; i++; }; return (tempStr); } private function _handleDown(e:MouseEvent):void{ stage.addEventListener(MouseEvent.MOUSE_MOVE, _handleMove, false, 0, true); _offset = (mouseY - _scrollHandle.y); } private function _createHeader():void{ _headerbg = new Shape(); _headerbg.graphics.beginFill(HEADER_BG_COLOUR, HEADER_BG_ALPHA); _headerbg.graphics.drawRect(0, 0, stage.stageWidth, HEADER_HEIGHT); _headerbg.graphics.endFill(); _headerbg.cacheAsBitmap = true; addChild(_headerbg); _headerTextShadowFormat = new TextFormat(); _headerTextShadowFormat.font = "_typewriter"; _headerTextShadowFormat.color = SHADOW_COLOUR; _headerTextShadowFormat.italic = true; _headerTextShadow = new TextField(); _headerTextShadow.x = 12; _headerTextShadow.y = 2; _headerTextShadow.height = HEADER_HEIGHT; _headerTextShadow.autoSize = TextFieldAutoSize.LEFT; _headerTextShadow.multiline = false; _headerTextShadow.defaultTextFormat = _headerTextShadowFormat; _headerTextShadow.text = ("SWFConsole v" + VERSION); _headerTextFormat = new TextFormat(); _headerTextFormat.font = "_typewriter"; _headerTextFormat.color = TEXT_COLOUR; _headerTextFormat.bold; _headerTextFormat.italic = true; _headerText = new TextField(); _headerText.x = 10; _headerText.height = HEADER_HEIGHT; _headerText.autoSize = TextFieldAutoSize.LEFT; _headerText.multiline = false; _headerText.defaultTextFormat = _headerTextFormat; _headerText.text = ("SWFConsole v" + VERSION); addChild(_headerTextShadow); addChild(_headerText); } private function _createScrollButtons():void{ _scrollButtonUpShape = new Shape(); _scrollButtonDownShape = new Shape(); _createScrollButtonShape(_scrollButtonUpShape); _createScrollButtonShape(_scrollButtonDownShape); _scrollButtonUp = new Sprite(); _scrollButtonUp.addChild(_scrollButtonUpShape); _scrollButtonUp.x = (stage.stageWidth - 30); _scrollButtonUp.y = 40; _scrollButtonUp.buttonMode = true; _scrollButtonUp.addEventListener(MouseEvent.MOUSE_DOWN, _scrollButtonUpDown, false, 0, true); addChild(_scrollButtonUp); _scrollButtonDown = new Sprite(); _scrollButtonDown.addChild(_scrollButtonDownShape); _scrollButtonDown.scaleY = -1; _scrollButtonDown.x = (stage.stageWidth - 30); _scrollButtonDown.y = ((_scrollTrack.y + _scrollTrack.height) + 10); _scrollButtonDown.buttonMode = true; _scrollButtonDown.addEventListener(MouseEvent.MOUSE_DOWN, _scrollButtonDownDown, false, 0, true); addChild(_scrollButtonDown); } private function _relocate(e:Event):void{ _headerbg.width = stage.stageWidth; _bg.width = stage.stageWidth; _text.width = (stage.stageWidth - 50); _outputMask.width = (stage.stageWidth - 50); _inputText.width = (stage.stageWidth - 50); _inputAreaBg.width = stage.stageWidth; _inputBg.width = (stage.stageWidth - 50); _scrollTrack.x = Math.ceil((stage.stageWidth - 30)); _scrollButtonUp.x = Math.ceil((stage.stageWidth - 30)); _scrollButtonDown.x = Math.ceil((stage.stageWidth - 30)); _scrollHandle.x = Math.ceil((stage.stageWidth - 30)); x = Math.ceil((-((stage.stageWidth - _stageWidth)) * 0.5)); y = Math.ceil((-((stage.stageHeight - _stageHeight)) * 0.5)); if (_fps){ _fps.x = Math.ceil(((-((stage.stageWidth - _stageWidth)) * 0.5) + (stage.stageWidth - _fps.width))); _fps.y = Math.ceil(((-((stage.stageHeight - _stageHeight)) * 0.5) + (stage.stageHeight - _fps.height))); }; if (_memUsage){ _memUsage.x = Math.ceil(((-((stage.stageWidth - _stageWidth)) * 0.5) + (stage.stageWidth - _memUsage.width))); _memUsage.y = Math.ceil((((-((stage.stageHeight - _stageHeight)) * 0.5) + (stage.stageHeight - _memUsage.height)) - 32)); }; } private function _createScrollButtonShape(container:Shape):void{ container.graphics.beginFill(SCROLLBUTTON_COLOUR, SCROLLBUTTON_ALPHA); container.graphics.moveTo(0, 0); container.graphics.lineTo(5, -8); container.graphics.lineTo(10, 0); container.graphics.lineTo(0, 0); container.graphics.endFill(); container.cacheAsBitmap = true; } private function _removeChar(str:String, char:String):String{ var tempStr:String; var i:*; tempStr = ""; i = 0; while (i < str.length) { if (str.charAt(i) != char){ tempStr = (tempStr + str.charAt(i)); }; i++; }; return (tempStr); } private function _createBackground():void{ _bg = new Shape(); _bg.graphics.beginFill(BACKGROUND_COLOUR, BACKGROUND_ALPHA); _bg.graphics.drawRect(0, 0, stage.stageWidth, BACKGROUND_HEIGHT); _bg.graphics.endFill(); _bg.cacheAsBitmap = true; _bg.y = HEADER_HEIGHT; addChild(_bg); } private function _createOutputArea():void{ _text = new TextField(); _text.width = (stage.stageWidth - 50); _text.x = 10; _text.y = HEADER_HEIGHT; _text.height = BACKGROUND_HEIGHT; _text.multiline = true; _text.wordWrap = true; _text.autoSize = TextFieldAutoSize.LEFT; _textFormat = new TextFormat(); _textFormat.color = TEXT_COLOUR; _textFormat.font = "_typewriter"; _text.defaultTextFormat = _textFormat; addChild(_text); _outputMask = new Shape(); _outputMask.graphics.beginFill(0xFF00FF); _outputMask.graphics.drawRect(0, 0, (stage.stageWidth - 50), BACKGROUND_HEIGHT); _outputMask.graphics.endFill(); _outputMask.x = 10; _outputMask.y = HEADER_HEIGHT; addChild(_outputMask); _text.mask = _outputMask; } private function _initFPS(){ var format:TextFormat; _fps = new Sprite(); stage.addChild(_fps); _stageFrameRate = stage.frameRate; _history = new Array(); _txt_fps = new TextField(); _txt_fps.width = 100; _txt_fps.height = 16; _txt_fps.border = false; _txt_fps.selectable = false; _txt_avgfps = new TextField(); _txt_avgfps.width = 100; _txt_avgfps.height = 16; _txt_avgfps.border = false; _txt_avgfps.selectable = false; format = new TextFormat(); format.font = "Verdana"; format.color = 0xFFCC00; format.size = 10; _txt_fps.defaultTextFormat = format; _txt_avgfps.defaultTextFormat = format; _txt_fps.text = ("FPS: " + _stageFrameRate); _txt_avgfps.text = ("AVG: " + _stageFrameRate); _txt_fps.x = (_txt_fps.width - _txt_avgfps.width); _txt_avgfps.x = 0; _txt_avgfps.y = _txt_fps.height; _fps.addChild(_txt_fps); _fps.addChild(_txt_avgfps); _fpsBg = new Shape(); _fpsBg.graphics.beginFill(0, 0.7); _fpsBg.graphics.drawRect(0, 0, _fps.width, _fps.height); _fpsBg.graphics.endFill(); _fps.addChildAt(_fpsBg, 0); _fps.x = Math.ceil(((-((stage.stageWidth - _stageWidth)) * 0.5) + (stage.stageWidth - _fps.width))); _fps.y = Math.ceil(((-((stage.stageHeight - _stageHeight)) * 0.5) + (stage.stageHeight - _fps.height))); _fpsTimer = new Timer(_FPS_REFRESH_RATE); _fpsTimer.addEventListener(TimerEvent.TIMER, _calculateFPS, false, 0, true); _fpsTimer.start(); addEventListener(Event.ENTER_FRAME, _updateFrames, false, 0, true); } private function _updateFrames(e:Event):void{ _frames++; } private function _runFunc(command:String):void{ var instanceSplit:Array; var functionSplit:Array; var parametersSplit:Array; var instance:Object; var command = command; if (_findChar(command, ".")){ instanceSplit = command.split("."); instance = _recurseChildren(stage, instanceSplit[0]); functionSplit = instanceSplit[1].split("("); parametersSplit = functionSplit[1].split(")"); if (instance){ if (instance.hasOwnProperty(functionSplit[0])){ if (parametersSplit[0] == ""){ output(instance[functionSplit[0]]()); } else { if (_findChar(parametersSplit[0], "\"")){ parametersSplit[0] = _removeChar(parametersSplit[0], "\""); }; output(instance[functionSplit[0]](parametersSplit[0])); }; //unresolved jump var _slot1 = e; output(_slot1); } else { output(((("Function " + functionSplit[0]) + " not found on ") + instanceSplit[0])); }; } else { output("Instance not found"); }; } else { functionSplit = command.split("("); parametersSplit = functionSplit[1].split(")"); if (stage.hasOwnProperty(functionSplit[0])){ if (parametersSplit[0] == ""){ output(stage[functionSplit[0]]()); } else { if (_findChar(parametersSplit[0], "\"")){ parametersSplit[0] = _removeChar(parametersSplit[0], "\""); }; output(stage[functionSplit[0]](parametersSplit[0])); }; //unresolved jump var _slot1 = e; output(_slot1); } else { output(((("Function " + functionSplit[0]) + " not found on ") + instanceSplit[0])); }; }; } private function _scrollButtonUpDown(e:MouseEvent):void{ _percent = (_percent - 0.1); if (_percent < 0){ _percent = 0; }; _text.y = (_headerbg.height + (-(_percent) * (_text.height - _outputMask.height))); _scrollHandle.y = (_min + ((_max - _min) * _percent)); } private function _createInputArea():void{ _inputAreaBg = new Shape(); _inputAreaBg.graphics.beginFill(INPUTAREA_BG_COLOUR, INPUTAREA_BG_ALPHA); _inputAreaBg.graphics.drawRect(0, 0, stage.stageWidth, INPUTAREA_BG_HEIGHT); _inputAreaBg.graphics.endFill(); _inputAreaBg.y = (HEADER_HEIGHT + BACKGROUND_HEIGHT); addChild(_inputAreaBg); _inputBg = new Shape(); _inputBg.graphics.beginFill(INPUT_BG_COLOUR, INPUT_BG_ALPHA); _inputBg.graphics.drawRect(0, 0, (stage.stageWidth - 50), INPUT_BG_HEIGHT); _inputBg.graphics.endFill(); _inputBg.x = 10; _inputBg.y = (_inputAreaBg.y + 5); addChild(_inputBg); _inputText = new TextField(); _inputText.width = (stage.stageWidth - 50); _inputText.x = 10; _inputText.y = (_inputAreaBg.y + 5); _inputText.height = INPUT_BG_HEIGHT; _inputText.multiline = false; _inputText.type = TextFieldType.INPUT; _inputText.restrict = "^`"; _inputText.defaultTextFormat = _textFormat; addChild(_inputText); } private function _runProperty(command:String):void{ var instanceSplit:Array; var propertySplit:Array; var instance:Object; var command = command; if (_findChar(command, "=")){ propertySplit = command.split("="); if (_findChar(propertySplit[0], ".")){ instanceSplit = propertySplit[0].split("."); instance = _recurseChildren(stage, instanceSplit[0]); if (instance){ if (instance.hasOwnProperty(instanceSplit[1])){ if (propertySplit[1] == "false"){ propertySplit[1] = false; }; instance[instanceSplit[1]] = propertySplit[1]; } else { output(((("Property " + instanceSplit[1]) + " not found on ") + instanceSplit[0])); }; } else { output("Instance not found"); }; } else { if (stage.hasOwnProperty(propertySplit[0])){ if (propertySplit[1] == "false"){ propertySplit[1] = false; }; stage[propertySplit[0]] = propertySplit[1]; //unresolved jump var _slot1 = e; output("*** ERROR: this property of stage cannot be set ***"); } else { output((("Property " + propertySplit[0]) + " not found on stage")); }; }; } else { if (_findChar(command, ".")){ instanceSplit = command.split("."); instance = _recurseChildren(stage, instanceSplit[0]); if (instance){ if (instance.hasOwnProperty(instanceSplit[1])){ output(((((instance.name + ".") + instanceSplit[1]) + " = ") + instance[instanceSplit[1]])); } else { output(((("Property " + instanceSplit[1]) + " not found on ") + instanceSplit[0])); }; } else { output("Instance not found"); }; } else { if (stage.hasOwnProperty(command)){ output(((("stage." + command) + " = ") + stage[command])); } else { output((("Property " + command) + " not found on stage")); }; }; }; } private function _scrollButtonDownDown(e:MouseEvent):void{ _percent = (_percent + 0.1); if (_percent > 1){ _percent = 1; }; _text.y = (_headerbg.height + (-(_percent) * (_text.height - _outputMask.height))); _scrollHandle.y = (_min + ((_max - _min) * _percent)); } private function _handleMove(e:MouseEvent):void{ _scrollHandle.y = (mouseY - _offset); if (_scrollHandle.y <= _min){ _scrollHandle.y = _min; }; if (_scrollHandle.y >= _max){ _scrollHandle.y = _max; }; _percent = ((_scrollHandle.y - _min) / (_max - _min)); if (_text.height > _outputMask.height){ _text.y = (_headerbg.height + (-(_percent) * (_text.height - _outputMask.height))); }; e.updateAfterEvent(); } private function _scrollWheel(e:MouseEvent):void{ if (_scrollButtonDown.visible){ if (e.delta > 0){ _percent = (_percent - 0.1); if (_percent < 0){ _percent = 0; }; } else { if (e.delta < 0){ _percent = (_percent + 0.1); if (_percent > 1){ _percent = 1; }; }; }; _text.y = (_headerbg.height + (-(_percent) * (_text.height - _outputMask.height))); _scrollHandle.y = (_min + ((_max - _min) * _percent)); }; } private function _initMemUsage():void{ var format:TextFormat; _memUsage = new Sprite(); stage.addChild(_memUsage); _txt_mem = new TextField(); _txt_mem.width = 100; _txt_mem.height = 16; _txt_mem.border = false; _txt_mem.selectable = false; format = new TextFormat(); format.font = "Verdana"; format.color = 6750054; format.size = 10; _txt_mem.defaultTextFormat = format; _txt_mem.text = "MEM: 0 MB"; _memUsage.addChild(_txt_mem); _memBg = new Shape(); _memBg.graphics.beginFill(0, 0.7); _memBg.graphics.drawRect(0, 0, _memUsage.width, _memUsage.height); _memBg.graphics.endFill(); _memUsage.addChildAt(_memBg, 0); _memUsage.x = Math.ceil(((-((stage.stageWidth - _stageWidth)) * 0.5) + (stage.stageWidth - _memUsage.width))); _memUsage.y = Math.ceil((((-((stage.stageHeight - _stageHeight)) * 0.5) + (stage.stageHeight - _memUsage.height)) - 32)); _timer = new Timer(UPDATE_INTERVAL); _timer.addEventListener(TimerEvent.TIMER, displayUsage, false, 0, true); _timer.start(); } private function _runCommand(command:String):void{ if (command.substr(0, 7).toLowerCase() == "!resmon"){ if (command.charAt(7) == "0"){ if (_fps != null){ _fps.visible = false; }; if (_memUsage != null){ _memUsage.visible = false; }; output("*** RESOURCE MONITOR DISABLED ***"); } else { if (_fps == null){ _initFPS(); } else { _fps.visible = true; }; if (_memUsage == null){ _initMemUsage(); } else { _memUsage.visible = true; }; output("*** RESOURCE MONITOR ENABLED ***"); }; return; }; output("Invalid command"); } private function _init(e:Event=null):void{ removeEventListener(Event.ADDED_TO_STAGE, _init); trace("SWFConsole Initialised - ( ` ) to activate"); hide(); _createHeader(); _createBackground(); _createOutputArea(); _createScrollBar(); _createInputArea(); x = -(Math.ceil(((stage.stageWidth - _stageWidth) * 0.5))); y = -(Math.ceil(((stage.stageHeight - _stageHeight) * 0.5))); _activated = true; _lastcommands = new Array(); _lastcommandsindex = 0; output(WELCOME_MESSAGE); stage.addEventListener(KeyboardEvent.KEY_UP, _keyListener, false, 0, true); stage.addEventListener(Event.RESIZE, _relocate, false, 0, true); } public function show():void{ alpha = 1; visible = true; stage.focus = _inputText; } private function displayUsage(e:TimerEvent):void{ _txt_mem.text = ("MEM: " + String((Number(((System.totalMemory / 0x0400) / 0x0400)).toFixed(2) + "MB"))); } public static function output(o:Object):void{ if (_activated){ _text.appendText((String(o) + "\n")); if (_text.height > _outputMask.height){ _text.y = (_headerbg.height - (_text.height - _outputMask.height)); _scrollHandle.y = _max; _percent = 1; if (!_scrollButtonDown.visible){ _scrollTrack.visible = true; _scrollButtonUp.visible = true; _scrollButtonDown.visible = true; _scrollHandle.visible = true; }; }; }; if (_traceEnabled){ trace(String(o)); }; } } }//package rl.dev
Section 110
//AdvancedButton (rl.display.AdvancedButton) package rl.display { import gs.*; import flash.events.*; import flash.text.*; import com.sounds.*; public class AdvancedButton extends AdvancedMovieClip { public var _rollOver:Boolean;// = true public var txt:TextField; public var selected:Boolean;// = false public function AdvancedButton(){ selected = false; _rollOver = true; super(); addEventListener(Event.ADDED, _init, false, 0, true); } protected function _buttonOut(e:MouseEvent):void{ if (((!(selected)) && ((this.totalFrames > 2)))){ TweenLite.to(this, 0.5, {frame:1}); } else { if (!selected){ this.gotoAndStop(1); }; }; } public function _setSelected(_b:Boolean):void{ this.selected = _b; if (this.selected == false){ TweenLite.to(this, 0.5, {delay:0.2, frame:1}); } else { TweenLite.to(this, 0.5, {delay:0.2, frame:this.totalFrames}); }; } private function _buttonClick(e:MouseEvent):void{ Sounds.click.play(); } protected function _buttonOver(e:MouseEvent):void{ if (((_rollOver) && ((this.totalFrames > 2)))){ TweenLite.to(this, (this.totalFrames / 30), {frame:this.totalFrames}); } else { if (_rollOver){ this.gotoAndStop(2); }; }; } private function _init(e:Event=null):void{ removeEventListener(Event.ADDED_TO_STAGE, _init); buttonMode = true; addEventListener(MouseEvent.ROLL_OVER, _buttonOver, false, 0, true); addEventListener(MouseEvent.ROLL_OUT, _buttonOut, false, 0, true); addEventListener(MouseEvent.CLICK, _buttonClick, false, 0, true); this.gotoAndStop(1); } override public function destroy():void{ removeEventListener(MouseEvent.ROLL_OVER, _buttonOver); removeEventListener(MouseEvent.ROLL_OUT, _buttonOut); super.destroy(); } } }//package rl.display
Section 111
//AdvancedMovieClip (rl.display.AdvancedMovieClip) package rl.display { import flash.display.*; public class AdvancedMovieClip extends MovieClip { private var _eventListeners:Array; public function AdvancedMovieClip(){ super(); stop(); _eventListeners = new Array(); } public function destroy():void{ var i:*; i = 0; while (i < _eventListeners.length) { removeEventListener(_eventListeners[i]._type, _eventListeners[i]._listener); i++; }; (parent as Object).removeChild(this); delete ??getglobalscope [this]; } override public function addEventListener(type:String, listener:Function, useCapture:Boolean=false, priority:int=0, useWeakReference:Boolean=false):void{ super.addEventListener(type, listener, useCapture, priority, useWeakReference); _eventListeners.push({_type:type, _listener:listener}); } public function hide():void{ visible = false; alpha = 0; } public function get o_parent():Object{ return ((parent as Object)); } public function show():void{ visible = true; alpha = 1; } } }//package rl.display
Section 112
//BurglarPopUp (th.GameFramework.Display.BurglarPopUp) package th.GameFramework.Display { import gs.*; import flash.display.*; import flash.geom.*; import com.sounds.*; public class BurglarPopUp extends Sprite { public function BurglarPopUp():void{ super(); } public function init(p:Point):void{ var newY:uint; this.x = p.x; this.y = p.y; newY = (y - 50); TweenLite.to(this, 0.3, {delay:2, y:newY, alpha:0.5, onComplete:killMe}); Sounds.whistle.play(); } private function killMe():void{ parent.removeChild(this); } } }//package th.GameFramework.Display
Section 113
//MyCamera (th.GameFramework.Display.MyCamera) package th.GameFramework.Display { import flash.display.*; import flash.geom.*; public class MyCamera extends Sprite { private static var stageH:uint; public static var screen; public static var p:Point; public static var target; private static var stageW:uint; public function MyCamera():void{ super(); } public static function snap(targ:Point):void{ var newX:int; var newY:int; newX = ((targ.x * -1) + (stageW / 2)); newY = ((targ.y * -1) + (stageH / 2)); if (newX > 0){ newX = 0; }; if (newX < ((p.x * -1) + stageW)){ newX = ((p.x * -1) + stageW); }; if (newY > 0){ newY = 0; }; if (newY < ((p.y * -1) + stageH)){ newY = ((p.y * -1) + stageH); }; screen.x = newX; screen.y = newY; } public static function init(_p:Point, _s:Point):void{ p = _p; stageH = _s.y; stageW = _s.x; } public static function mainloop():void{ var newX:int; var newY:int; newX = ((target.x * -1) + (stageW / 2)); newY = ((target.y * -1) + (stageH / 2)); if (newX > 0){ newX = 0; }; if (newX < ((p.x * -1) + stageW)){ newX = ((p.x * -1) + stageW); }; if (newY > 0){ newY = 0; }; if (newY < ((p.y * -1) + stageH)){ newY = ((p.y * -1) + stageH); }; screen.x = (screen.x + Math.floor(((newX - screen.x) / 10))); screen.y = (screen.y + Math.floor(((newY - screen.y) / 10))); } } }//package th.GameFramework.Display
Section 114
//ScorePopUp (th.GameFramework.Display.ScorePopUp) package th.GameFramework.Display { import gs.*; import flash.display.*; import flash.text.*; import flash.geom.*; public class ScorePopUp extends Sprite { public var score_txt:TextField; public function ScorePopUp():void{ super(); } public function init(p:Point, myText:String):void{ var newY:uint; this.score_txt.text = myText; this.x = p.x; this.y = p.y; newY = (y - 50); TweenLite.to(this, 2, {y:newY, alpha:0.5, onComplete:killMe}); } private function killMe():void{ parent.removeChild(this); } } }//package th.GameFramework.Display
Section 115
//TimePopUp (th.GameFramework.Display.TimePopUp) package th.GameFramework.Display { import gs.*; import flash.display.*; import flash.geom.*; import rl.dev.*; import com.sounds.*; import com.*; public class TimePopUp extends Sprite { public function TimePopUp():void{ super(); } public function init(p:Point):void{ var newY:uint; this.x = p.x; this.y = p.y; newY = (y - 50); TweenLite.to(this, 0.3, {delay:2, y:newY, alpha:0.5, onComplete:killMe}); Sounds.whistle.play(); } private function killMe():void{ if (Globals.lives < 0){ Globals.dead = true; Globals.quit = true; } else { Globals.replay = true; Globals.quit = true; }; SWFConsole.output("TIM EUP SATRT AGAIN"); parent.removeChild(this); } } }//package th.GameFramework.Display
Section 116
//BasicHitDetection (th.GameFramework.HitDetection.BasicHitDetection) package th.GameFramework.HitDetection { import flash.display.*; public class BasicHitDetection extends Sprite { public static var gameObjects:Array; public static var threshold:uint = 25; public function BasicHitDetection():void{ super(); } public static function init(_ar:Array):void{ gameObjects = _ar; } public static function checkHit(_myOb):Object{ var spriteOb:Object; var i:uint; i = 0; while (i < gameObjects.length) { spriteOb = gameObjects[i]; if (((!((spriteOb.type == _myOb.type))) && (!(spriteOb.hit)))){ if ((((((((_myOb.x > (spriteOb.x - threshold))) && ((_myOb.x < (spriteOb.x + threshold))))) && ((_myOb.y > (spriteOb.y - (threshold * 2)))))) && ((_myOb.y < (spriteOb.y + 1))))){ return (spriteOb); }; if ((((((((_myOb.x > (spriteOb.x - threshold))) && ((_myOb.x < (spriteOb.x + threshold))))) && (((_myOb.y - threshold) > (spriteOb.y - (threshold * 2)))))) && (((_myOb.y - threshold) < (spriteOb.y + 1))))){ return (spriteOb); }; }; i++; }; return (false); } public static function checkSwing(_myOb):Object{ var spriteOb:Object; var i:uint; i = 0; while (i < gameObjects.length) { spriteOb = gameObjects[i]; if (((!((spriteOb.type == _myOb.type))) && (!(spriteOb.hit)))){ if (((((((((_myOb.x + (25 * _myOb.dir)) > (spriteOb.x - threshold))) && (((_myOb.x + (25 * _myOb.dir)) < (spriteOb.x + threshold))))) && ((_myOb.y > (spriteOb.y - (threshold * 2)))))) && ((_myOb.y < (spriteOb.y + 1))))){ return (spriteOb); }; if (((((((((_myOb.x + (25 * _myOb.dir)) > (spriteOb.x - threshold))) && (((_myOb.x + (25 * _myOb.dir)) < (spriteOb.x + threshold))))) && (((_myOb.y - threshold) > (spriteOb.y - (threshold * 2)))))) && (((_myOb.y - threshold) < (spriteOb.y + 1))))){ return (spriteOb); }; }; i++; }; return (false); } } }//package th.GameFramework.HitDetection
Section 117
//Key (th.GameFramework.Key.Key) package th.GameFramework.Key { import flash.events.*; import flash.display.*; import rl.dev.*; public class Key extends Sprite { public static var traceKey:Boolean = false; public static var isDown:Object; public function Key():void{ super(); } public static function init(targ:Stage, _trace:Boolean=false):void{ traceKey = _trace; isDown = new Object(); targ.addEventListener(KeyboardEvent.KEY_DOWN, keyDownEvent, false, 0, true); targ.addEventListener(KeyboardEvent.KEY_UP, keyUpEvent, false, 0, true); } private static function keyUpEvent(e:KeyboardEvent):void{ isDown[("k_" + e.keyCode)] = false; if (traceKey){ SWFConsole.output(((e.keyCode + " = ") + isDown[("k_" + e.keyCode)])); }; } private static function keyDownEvent(e:KeyboardEvent):void{ isDown[("k_" + e.keyCode)] = true; if (traceKey){ SWFConsole.output(((e.keyCode + " = ") + isDown[("k_" + e.keyCode)])); }; } } }//package th.GameFramework.Key
Section 118
//Bomb (th.GameFramework.Platformer.Sprites.Bomb) package th.GameFramework.Platformer.Sprites { import gs.*; import flash.display.*; import rl.dev.*; import com.sounds.*; import th.GameFramework.Tiles.*; public class Bomb extends MovieClip { public var jumping:Boolean;// = false private var gravity:Number;// = 1.6 private var jumpTopSpeed:int;// = 20 public var p; private var bounce:uint;// = 0 public var type:String;// = "bomb" private var jumpSpeed:Number;// = -10 public var alive:Boolean;// = false private var jumpStartSpeed:Number;// = -18 public var ob:Object; public function Bomb():void{ gravity = 1.6; jumpTopSpeed = 20; jumpStartSpeed = -18; jumpSpeed = -10; jumping = false; bounce = 0; type = "bomb"; ob = new Object(); alive = false; super(); ob.height = 0; ob.width = 0; ob.shave = 0; ob.upleft = true; ob.downleft = true; ob.upright = true; ob.downright = true; ob.downY = 0; ob.upY = 0; ob.leftX = 0; ob.rightX = 0; } public function init(_type:String="clock"):void{ switch (_type){ case "clock": break; case "dynamite": jumping = true; jumpSpeed = -10; type = "dynamite"; break; }; } private function explodeMe():void{ addPuff(x, y); alive = true; jumping = false; gotoAndPlay("bang"); Sounds.explosion.play(); TweenLite.to(this, 0.3, {onComplete:killMe}); } private function killMe():void{ alive = false; parent.removeChild(this); } public function move():void{ var yy:int; var xx:int; var newY:int; if (jumping){ yy = y; xx = x; newY = (yy + jumpSpeed); Tile.getMyCorners(x, newY, ob); SWFConsole.output(("tile info - " + ob.downleft)); if ((((jumpSpeed > 0)) && (((!(ob.downleft)) || (!(ob.downright)))))){ bounce++; jumpSpeed = -5; if (bounce == 2){ explodeMe(); }; }; if (jumpSpeed < jumpTopSpeed){ jumpSpeed = (jumpSpeed + gravity); }; y = newY; }; } public function addPuff(xx:uint, yy:uint):void{ var puff:Puff; puff = new Puff(); puff.x = xx; puff.y = yy; parent.addChild(puff); TweenLite.to(puff, 0.5, {delay:0.1, scaleX:2, scaleY:2, alpha:0}); } } }//package th.GameFramework.Platformer.Sprites
Section 119
//Enemy (th.GameFramework.Platformer.Sprites.Enemy) package th.GameFramework.Platformer.Sprites { import gs.*; import flash.display.*; import flash.geom.*; import com.*; import th.GameFramework.Tiles.*; import th.utilities.*; public class Enemy extends Sprite { public var xx:int; private var spriteWidth:int; public var id:uint;// = 1 public var yy:int; private var canJump:Boolean;// = true private var jumping:Boolean;// = true public var type:String;// = "enemy" public var patrol:Boolean;// = true public var clip:MovieClip; public var shave:int;// = 20 private var gravity:Number;// = 1.6 private var speed:Number;// = 0 private var map:Object; public var headShave:int;// = 5 private var hitTimer:uint;// = 0 public var walking:Boolean;// = true public var marshie:MovieClip; public var score:uint;// = 200 var spriteArray:Array; private var run:Boolean;// = false public var dir:int;// = 1 private var jumpTopSpeed:int;// = 20 public var hit:Boolean;// = false private var jumpSpeed:Number;// = 0 public var alive:Boolean;// = true private var jumpStartSpeed:Number;// = -5 private var ob:Object; private var topRunSpeed:int;// = 4 private var topSpeed:int;// = 5 private var canThrow:Boolean;// = false public function Enemy():void{ alive = true; id = 1; score = 200; hitTimer = 0; type = "enemy"; hit = false; clip = new MovieClip(); marshie = new MovieClip(); dir = 1; shave = 20; headShave = 5; topSpeed = 5; topRunSpeed = 4; speed = 0; jumpTopSpeed = 20; jumpStartSpeed = -5; jumpSpeed = 0; canJump = true; run = false; gravity = 1.6; jumping = true; walking = true; patrol = true; canThrow = false; ob = new Object(); super(); } public function init(_map:Object, _stats:Object):void{ if (Globals.level > 20){ topSpeed = 5; } else { if (Globals.level > 12){ topSpeed = 3; }; }; spriteArray = _stats.spriteArray; map = _map; x = (xx = (_stats.x + 25)); y = (yy = (_stats.y + 50)); dir = _stats.dir; jumping = false; walking = true; spriteWidth = map.tileW; ob.height = (spriteWidth - headShave); ob.width = ((spriteWidth / 2) - shave); ob.shave = shave; ob.upleft = true; ob.downleft = true; ob.upright = true; ob.downright = true; ob.downY = 0; ob.upY = 0; ob.leftX = 0; ob.rightX = 0; clip = marshie; jump(); TweenLite.to(this, 3, {onComplete:throwReset}); } public function movePlayer():void{ var newX:int; var newY:int; var reduceSpeed:Number; var Testyy:*; var rnd:uint; if (!hit){ newX = xx; newY = yy; if (walking){ walk(dir); }; if (jumping){ newY = (yy + jumpSpeed); Tile.getMyCorners(xx, newY, ob); if ((((((jumpSpeed < 0)) && (((!(ob.upleft)) || (!(ob.upright)))))) && (!(Tile.isCloud(xx, (newY - map.tileW)))))){ jumpSpeed = 0; yy = (((Math.floor((newY / map.tileW)) * map.tileH) + ob.height) + 2); } else { yy = newY; if (jumpSpeed < jumpTopSpeed){ jumpSpeed = (jumpSpeed + gravity); }; gotoFrame(marshie, 2); }; Tile.getMyCorners(xx, newY, ob); if ((((((jumpSpeed > 0)) && (jumping))) && (((((!(ob.downleft)) || (!(ob.downright)))) || (Tile.isCloud(xx, newY)))))){ jumping = false; Testyy = (Math.floor((newY / map.tileW)) * map.tileW); if (Testyy < y){ jumping = true; } else { yy = Testyy; }; gotoFrame(marshie, 1); }; }; Tile.getMyCorners(xx, (yy + 1), ob); if (((((((((walking) && (!(jumping)))) && (ob.downleft))) && (ob.downright))) && (!(Tile.isCloud(xx, (yy + 1)))))){ rnd = (Math.random() * 100); if (rnd < 80){ rnd = (Math.random() * 100); if (rnd < 50){ jumpSpeed = -10; jumping = true; } else { jumpSpeed = 0; jumping = true; }; } else { dir = (dir * -1); xx = (xx + (dir * (8 + topSpeed))); speed = 0; }; }; reduceSpeed = 0.4; if (((((!(jumping)) && (!(walking)))) && ((Math.abs(speed) < 0.6)))){ speed = 0; }; if (((!(walking)) && ((((((speed < 0)) && ((dir == -1)))) || ((((speed > 0)) && ((dir == 1)))))))){ if (!walking){ walk(dir, false); }; reduceSpeed = 0.5; }; if (speed < 0){ speed = (speed + reduceSpeed); }; if (speed > 0){ speed = (speed - reduceSpeed); }; ob.xtile = Math.floor((xx / map.tileW)); ob.ytile = Math.floor((yy / map.tileH)); clip.scaleX = dir; rnd = (Math.random() * 100); if (((!(jumping)) && ((rnd < 10)))){ checkTileJump(); }; }; if (((hit) && (alive))){ hitTimer++; if (hitTimer > 20){ walking = true; killMe(); alive = false; } else { if (hitTimer > 5){ gotoFrame(marshie, 4); }; }; }; } public function lookForPlayer(player, ar:Array):void{ var dist:int; dist = GetDistance._get(new Point(x, y), new Point(player.x, player.y)); if ((((dist < 100)) && (canThrow))){ if ((((((((dir == 1)) && ((player.dir == -1)))) && ((x < player.x)))) || ((((((dir == -1)) && ((player.dir == 1)))) && ((x > player.x)))))){ dir = (dir * -1); throwBomb(new Point(x, y), ar); }; }; } public function jump():void{ if (((!(jumping)) && (canJump))){ gotoFrame(marshie, 2); jumping = true; canJump = false; jumpSpeed = jumpStartSpeed; if (Math.abs(speed) > 6){ jumpSpeed = (jumpStartSpeed - (Math.abs(speed) / 3)); }; }; } public function destroyMe():void{ removeChild(marshie); parent.removeChild(this); } private function throwReset():void{ canThrow = true; } private function checkTileJump():void{ var currentTilex:uint; var currentTiley:uint; currentTilex = Math.floor((x / 50)); currentTiley = Math.floor(((yy - 25) / 50)); if (Tile.ob[((("t_" + (currentTiley - 2)) + "_") + currentTilex)]){ if (((((((!(jumping)) && (Tile.ob[((("t_" + (currentTiley - 1)) + "_") + currentTilex)].walkable))) && (Tile.ob[((("t_" + (currentTiley - 2)) + "_") + currentTilex)].walkable))) && (Tile.ob[((("t_" + (currentTiley - 3)) + "_") + currentTilex)].walkable))){ if (((((Tile.ob[((("t_" + (currentTiley - 1)) + "_") + (currentTilex + (1 * dir)))].walkable) && (Tile.ob[((("t_" + (currentTiley - 2)) + "_") + (currentTilex + (1 * dir)))].walkable))) && (Tile.ob[((("t_" + (currentTiley - 3)) + "_") + (currentTilex + (1 * dir)))].walkable))){ if (((((!(Tile.ob[((("t_" + (currentTiley - 1)) + "_") + (currentTilex + (2 * dir)))].walkable)) || (!(Tile.ob[((("t_" + (currentTiley - 2)) + "_") + (currentTilex + (2 * dir)))].walkable)))) && (Tile.ob[((("t_" + (currentTiley - 3)) + "_") + (currentTilex + (2 * dir)))].walkable))){ jumpSpeed = -20; jumping = true; }; }; }; }; if (((!(jumping)) && (Tile.ob[((("t_" + (currentTiley - 1)) + "_") + currentTilex)].walkable))){ if (Tile.ob[((("t_" + (currentTiley - 1)) + "_") + (currentTilex + (1 * dir)))].walkable){ if (((Tile.ob[((("t_" + currentTiley) + "_") + (currentTilex + (1 * dir)))].cloud) || (!(Tile.ob[((("t_" + currentTiley) + "_") + (currentTilex + (1 * dir)))].walkable)))){ jumpSpeed = -15; jumping = true; }; }; }; if (Tile.ob[((("t_" + (currentTiley - 2)) + "_") + currentTilex)]){ if (((((!(jumping)) && (((Tile.ob[((("t_" + (currentTiley - 1)) + "_") + currentTilex)].walkable) || (Tile.ob[((("t_" + (currentTiley - 2)) + "_") + currentTilex)].walkable))))) && (((Tile.ob[((("t_" + (currentTiley + 1)) + "_") + currentTilex)].cloud) || (!(Tile.ob[((("t_" + (currentTiley + 1)) + "_") + currentTilex)].walkable)))))){ if (!Tile.ob[((("t_" + (currentTiley - 1)) + "_") + (currentTilex + (1 * dir)))].walkable){ jumpSpeed = -18; jumping = true; }; if (!Tile.ob[((("t_" + (currentTiley - 2)) + "_") + (currentTilex + (1 * dir)))].walkable){ jumpSpeed = -22; jumping = true; }; }; }; } public function killMe():void{ var i:uint; i = 0; while (i < spriteArray.lengthl) { if (spriteArray[i].name == this.name){ spriteArray.splice(i, 1); break; }; i++; }; parent.removeChild(this); } public function throwBomb(p:Point, ar:Array):void{ var bomb:BombClip; canThrow = false; bomb = new BombClip(); bomb.x = p.x; bomb.y = (p.y - 25); bomb.type = "dynamite"; bomb.jumping = true; parent.addChild(bomb); ar.push(bomb); TweenLite.to(this, 5, {onComplete:throwReset}); } public function walk(_dir:int=1, calculateSpeed:Boolean=true):void{ var newX:*; var canWalk:Boolean; var fastestSpeed:uint; var rnd:uint; if (!hit){ newX = xx; canWalk = false; fastestSpeed = topSpeed; if (run){ fastestSpeed = topRunSpeed; }; if (calculateSpeed){ walking = true; }; if (calculateSpeed){ if ((((speed < fastestSpeed)) && ((speed > (fastestSpeed * -1))))){ speed = (speed + (0.6 * dir)); }; }; newX = (xx + speed); Tile.getMyCorners(newX, (yy - 1), ob); if (dir == 1){ if (((ob.downright) && (ob.upright))){ xx = (xx + speed); } else { if (!jumping){ rnd = (Math.random() * 100); if (rnd < 100){ speed = 0; dir = -1; } else { xx = (xx - 10); jumpSpeed = -20; jumping = true; }; }; }; } else { if (dir == -1){ if (((ob.downleft) && (ob.upleft))){ xx = (xx + speed); } else { if (!jumping){ rnd = (Math.random() * 100); if (rnd < 100){ speed = 0; dir = 1; } else { xx = (xx + 10); jumpSpeed = -20; jumping = true; }; }; }; }; }; ob.xtile = Math.floor((xx / map.tileW)); ob.ytile = Math.floor((yy / map.tileH)); gotoFrame(marshie, 2); marshie.scaleX = dir; }; } private function gotoFrame(_clip:MovieClip, f:uint):void{ if (_clip.currentFrame != f){ _clip.gotoAndStop(f); }; } public function hitMe():void{ var scorePopUp:ScorePopUp; gotoFrame(marshie, 3); walking = false; jumping = false; hit = true; hitTimer = 0; scorePopUp = new ScorePopUp(); scorePopUp.init(new Point(x, y), (score + " pts")); parent.addChild(scorePopUp); } } }//package th.GameFramework.Platformer.Sprites
Section 120
//PickUp (th.GameFramework.Platformer.Sprites.PickUp) package th.GameFramework.Platformer.Sprites { import flash.display.*; import flash.geom.*; public class PickUp extends Sprite { public var type:String; public var score:uint;// = 10 public var hit:Boolean;// = false private var spriteArray:Array; public function PickUp(_type:String, p:Point, _ar:Array):void{ hit = false; score = 10; super(); if (_type == "cupcake"){ (score == 50); }; spriteArray = _ar; this.type = _type; this.x = p.x; this.y = p.y; } public function killMe():void{ var i:uint; hit = true; i = 0; while (i < spriteArray.lengthl) { if (spriteArray[i].name == this.name){ spriteArray.splice(i, 1); break; }; i++; }; this.visible = false; } } }//package th.GameFramework.Platformer.Sprites
Section 121
//Player (th.GameFramework.Platformer.Sprites.Player) package th.GameFramework.Platformer.Sprites { import gs.*; import flash.display.*; import flash.geom.*; import rl.dev.*; import com.sounds.*; import com.*; import th.GameFramework.Tiles.*; import th.utilities.*; import th.GameFramework.Key.*; public class Player extends Sprite { public var xx:int;// = 76 public var canSwing:Boolean;// = true private var spriteWidth:int; public var id:uint;// = 0 private var canJump:Boolean;// = true public var yy:int;// = 450 public var jumping:Boolean;// = true public var invincible:Boolean;// = true public var startY:int;// = 450 public var type:String;// = "player" public var startX:int;// = 76 public var shave:int;// = 20 private var gravity:Number;// = 1.6 private var speed:Number;// = 0 private var map:Object; private var startPoint:Point; public var headShave:int;// = 15 public var isSwinging:Boolean;// = false private var addScore:Function; private var updateHud:Function; public var isSwinging2:Boolean;// = false public var walking:Boolean;// = false private var bounce:uint;// = 0 public var hit:Boolean;// = false private var run:Boolean;// = false public var dir:int;// = 1 private var jumpTopSpeed:int;// = 20 private var jumpSpeed:Number; public var bunnyMc:MovieClip; private var jumpStartSpeed:Number;// = -18 private var ob:Object; private var invincibleCounter:uint;// = 0 private var topRunSpeed:int;// = 9 private var topSpeed:int;// = 6 public function Player():void{ canSwing = true; isSwinging = false; isSwinging2 = false; hit = false; id = 0; invincible = true; invincibleCounter = 0; type = "player"; bunnyMc = new MovieClip(); xx = 76; yy = 450; startX = 76; startY = 450; dir = 1; shave = 20; headShave = 15; topSpeed = 6; topRunSpeed = 9; speed = 0; jumpTopSpeed = 20; jumpStartSpeed = -18; canJump = true; run = false; gravity = 1.6; bounce = 0; jumping = true; walking = false; ob = new Object(); super(); } public function swing():Boolean{ if (((canSwing) && (!(isSwinging)))){ isSwinging = true; canSwing = false; bunnyMc.gotoAndStop(10); TweenLite.to(bunnyMc, 0.1, {onComplete:SwingPhase2}); TweenLite.to(this, 0.3, {onComplete:resetSwing}); SWFConsole.output(("can swing? ' = " + canSwing)); Sounds.truncheon.play(); speed = 0; return (true); }; return (false); } public function movePlayer():void{ var newX:int; var newY:int; var reduceSpeed:Number; var Testyy:*; checkPlayerFrame(); if (!Globals.paused){ newX = xx; newY = yy; if (jumping){ newY = (yy + jumpSpeed); Tile.getMyCorners(xx, newY, ob); if ((((((jumpSpeed < 0)) && (((!(ob.upleft)) || (!(ob.upright)))))) && (!(Tile.isCloud(xx, (newY - map.tileW)))))){ jumpSpeed = 0; yy = (((Math.floor((newY / map.tileW)) * map.tileH) + ob.height) + 2); } else { yy = newY; gotoFrame(bunnyMc, 3); }; if (jumpSpeed < jumpTopSpeed){ jumpSpeed = (jumpSpeed + gravity); }; Tile.getMyCorners(xx, newY, ob); if ((((((jumpSpeed > 0)) && (jumping))) && (((((!(ob.downleft)) || (!(ob.downright)))) || (Tile.isCloud(xx, newY)))))){ jumping = false; Testyy = (Math.floor((newY / map.tileW)) * map.tileW); if (Testyy < y){ jumping = true; } else { yy = Testyy; }; gotoFrame(bunnyMc, 1); }; }; Tile.getMyCorners(xx, (yy + 1), ob); if (((((((!(jumping)) && (ob.downleft))) && (ob.downright))) && (!(Tile.isCloud(xx, (yy + 1)))))){ jumpSpeed = -4.7; jumping = true; }; reduceSpeed = 0.6; if (((((((!(jumping)) && (!(walking)))) && ((speed < 0.7)))) && ((dir == 1)))){ speed = 0; }; if (((((((!(jumping)) && (!(walking)))) && ((speed > -0.7)))) && ((dir == -1)))){ speed = 0; }; if (((!(walking)) && ((((((speed < 0)) && ((dir == -1)))) || ((((speed > 0)) && ((dir == 1)))))))){ if (!walking){ walk(dir, false); }; reduceSpeed = 0.7; }; if (speed < 0){ speed = (speed + reduceSpeed); }; if (speed > 0){ speed = (speed - reduceSpeed); }; checkKeys(); ob.xtile = Math.floor((xx / map.tileW)); ob.ytile = Math.floor((yy / map.tileH)); bunnyMc.scaleX = dir; if (((invincible) && (!(Globals.paused)))){ doInvincible(); } else { this.visible = true; }; }; } public function hitByBomb():void{ var newY:uint; if (((((((!((Globals.burglars == Globals.totalBurglars))) && (!(hit)))) && (!(Globals.paused)))) && (!(invincible)))){ hit = true; Globals.paused = true; newY = (yy - 100); gotoFrame(bunnyMc, 4); TweenLite.to(this, 1, {yy:newY, onComplete:finishedHit}); addPuff(xx, yy); }; } public function init(_map:Object, stat:Object):void{ addScore = stat.scoreFunction; updateHud = stat.updateHud; map = _map; x = startX; y = startY; jumping = false; walking = false; spriteWidth = map.tileW; ob.height = ((spriteWidth - headShave) - 2); ob.width = ((spriteWidth / 2) - shave); ob.shave = shave; ob.upleft = true; ob.downleft = true; ob.upright = true; ob.downright = true; ob.downY = 0; ob.upY = 0; ob.leftX = 0; ob.rightX = 0; } private function checkKeys():void{ if (!Key.isDown["k_83"]){ canSwing = true; }; if (((!(Key.isDown["k_37"])) && (!(Key.isDown["k_39"])))){ walking = false; if (((!(jumping)) && (!(isSwinging)))){ gotoFrame(bunnyMc, 1); }; }; if (!Key.isDown["k_38"]){ if (jumpSpeed < 0){ jumpSpeed = (jumpSpeed + gravity); }; canJump = true; }; if (Key.isDown["k_16"]){ run = true; } else { run = false; }; } public function gotoStartPoint():void{ this.xx = (this.x = startPoint.x); this.yy = (this.y = startPoint.y); } private function doInvincible():void{ invincibleCounter++; if (OddOrEven.isEven(invincibleCounter)){ if (this.visible){ this.visible = false; } else { this.visible = true; }; }; if (invincibleCounter > 60){ invincible = false; this.visible = true; }; } public function destroyMe():void{ removeChild(bunnyMc); parent.removeChild(this); } public function jump():void{ if (((!(jumping)) && (canJump))){ Sounds.jump.play(); if (!isSwinging){ gotoFrame(bunnyMc, 3); }; jumping = true; canJump = false; jumpSpeed = jumpStartSpeed; if (Math.abs(speed) > 6){ jumpSpeed = (jumpStartSpeed - (Math.abs(speed) / 3)); }; jumpSpeed = (jumpSpeed - bounce); bounce = 0; }; } private function checkPlayerFrame():void{ if ((((bunnyMc.currentFrame == 10)) && (isSwinging))){ if (bunnyMc.clipo){ if (bunnyMc.clipo.currentFrame == 9){ }; }; }; } public function setStartPoint(p:Point){ startPoint = p; gotoStartPoint(); } public function finishLevel2():void{ Globals.finishedLevel = true; Globals.paused = false; } private function SwingPhase2():void{ isSwinging2 = true; } public function finishLevel1():void{ var newY:int; var levelPopUp:LevelPopUp_; Globals.paused = true; newY = (yy - 10); TweenLite.to(this, 2, {yy:newY, onComplete:finishLevel2}); levelPopUp = new LevelPopUp_(); levelPopUp.init("WELL DONE!"); parent.parent.addChild(levelPopUp); } private function finishedHit():void{ if (Globals.lives > 0){ Globals.lives--; updateHud(); hit = false; gotoStartPoint(); Globals.paused = false; resetInvincible(); bunnyMc.gotoAndStop(1); isSwinging = false; canSwing = true; } else { Globals.dead = true; }; } public function gotoFrame(clip:MovieClip, f:uint):void{ if (((!((clip.currentFrame == f))) && (!(isSwinging)))){ clip.gotoAndStop(f); }; } public function hitEnemy(hitOb:Object):void{ var scoreAdd:uint; var _local5:ScorePopUp; var newY:int; var levelPopUp:LevelPopUp_; scoreAdd = 200; switch (hitOb.type){ case "enemy": if (((isSwinging) && ((bunnyMc.currentFrame == 10)))){ if (bunnyMc.clipo){ if (bunnyMc.clipo.currentFrame < 5){ Globals.burglars++; jumpSpeed = -10; jumping = false; canJump = true; bounce = 10; jump(); addScore(hitOb.score); hitOb.hitMe(); Sounds.bounce.play(); Sounds.bounceSmall.play(); addPuff(xx, yy); TweenLite.killTweensOf(this, true); newY = (yy - 10); TweenLite.to(this, 0.3, {y:newY}); }; }; }; break; case "object": if (hitOb.name == "clue"){ scoreAdd = 1000; Globals.clues++; Sounds.coin2.play(); Sounds.coin.play(); if (Globals.clues != Globals.totalclues){ levelPopUp = new LevelPopUp_(); levelPopUp.init("FOUND A CLUE!"); }; if (Globals.clues == Globals.totalclues){ Globals.foundAllClues = true; } else { parent.parent.addChild(levelPopUp); }; } else { if (hitOb.name == "money"){ scoreAdd = 100; }; if (hitOb.name == "gold"){ scoreAdd = 200; }; if (hitOb.name == "painting"){ scoreAdd = 400; }; if (hitOb.name == "diamond"){ scoreAdd = 300; }; Sounds.coin.play(); Globals.evidence++; }; addScore(scoreAdd); _local5 = new ScorePopUp(); _local5.init(new Point(hitOb.x, hitOb.y), (scoreAdd + " pts")); parent.addChild(_local5); hitOb.killMe(); break; }; } public function resetInvincible():void{ invincible = true; invincibleCounter = 0; } public function walk(_dir:int=1, calculateSpeed:Boolean=true):void{ var newX:*; var canWalk:Boolean; var fastestSpeed:uint; newX = xx; canWalk = false; fastestSpeed = topSpeed; if (run){ fastestSpeed = topRunSpeed; }; if (calculateSpeed){ walking = true; }; dir = _dir; if (calculateSpeed){ if ((((speed < fastestSpeed)) && ((speed > (fastestSpeed * -1))))){ speed = (speed + (1 * dir)); }; }; newX = (xx + speed); Tile.getMyCorners(newX, (yy - 1), ob); if (dir == 1){ if (((((ob.downright) && (ob.upright))) && (ob.downleft))){ xx = (xx + speed); } else { speed = 0; }; }; if (dir == -1){ if (((((ob.downleft) && (ob.upleft))) && (ob.downright))){ xx = (xx + speed); } else { speed = 0; }; }; ob.xtile = Math.floor((xx / map.tileW)); ob.ytile = Math.floor((yy / map.tileH)); if (!jumping){ gotoFrame(bunnyMc, 2); }; } private function checkHitWall(xxx, yyy):Boolean{ var tempx:uint; var tempy:uint; var tileName:String; tempx = (xxx / map.tileW); tempy = (yyy / map.tileW); tileName = ((("t_" + tempx) + "_") + tempy); if (Tile.ob[tileName]){ if (Tile.ob[tileName].walkable){ return (true); }; }; return (false); } public function addPuff(xx:uint, yy:uint):void{ var puff:Puff; puff = new Puff(); puff.x = xx; puff.y = yy; parent.addChild(puff); TweenLite.to(puff, 0.5, {delay:0.1, scaleX:2, scaleY:2, alpha:0}); } public function resetSwing():void{ if (isSwinging){ isSwinging = false; isSwinging2 = false; gotoFrame(bunnyMc, 1); }; } } }//package th.GameFramework.Platformer.Sprites
Section 122
//Shrapnel (th.GameFramework.Platformer.Sprites.Shrapnel) package th.GameFramework.Platformer.Sprites { import gs.*; import flash.display.*; public class Shrapnel extends Sprite { var alive:Boolean;// = true public function Shrapnel(xx, yy):void{ var newX:uint; var newY:uint; alive = true; super(); x = xx; y = yy; newX = (xx + ((Math.random() * 200) - 100)); newY = (yy + ((Math.random() * 200) - 100)); TweenLite.to(this, 0.3, {alpha:0.5, x:newX, y:newY, onComplete:killMe}); } private function killMe():void{ alive = false; this.removeChild(getChildAt(0)); parent.removeChild(this); } } }//package th.GameFramework.Platformer.Sprites
Section 123
//Platformer (th.GameFramework.Platformer.Platformer) package th.GameFramework.Platformer { import flash.display.*; import flash.geom.*; import rl.dev.*; public class Platformer extends Sprite { var map:Object; public var newSprite:Sprite; public var barrels:Array; public var boxes:Array; var backgroundImage:Bitmap; var tilesArray:Array; public var alive:Boolean;// = false public function Platformer():void{ tilesArray = new Array(); newSprite = new Sprite(); boxes = new Array(); barrels = new Array(); alive = false; super(); } public function init(_map:Object, _type:String):void{ map = _map; SWFConsole.output("loaded platformer engine"); switch (_type){ case "bitmap": generateTilesArray(); generateMap(map); break; case "mc": generateMapMcs(map); break; }; alive = true; } private function generateTilesArray():void{ } public function disposeBitmap():void{ alive = false; removeChild(newSprite); } private function generateMapMcs(map:Object):void{ var tileImage:TilesMc; var rnd:uint; var i:uint; var j:uint; i = 0; while (i < map.mapArray[0].length) { j = 0; while (j < map.mapArray.length) { switch (map.mapArray[j][i]){ case 1: tileImage = new TilesMc(); tileImage.x = (i * map.tileW); tileImage.y = (j * map.tileW); tileImage.name = ((("t_" + (i * map.tileW)) + "_") + (j * map.tileW)); tileImage.gotoAndStop(2); newSprite.addChild(tileImage); break; case 2: tileImage = new TilesMc(); tileImage.x = (i * map.tileW); tileImage.y = (j * map.tileW); tileImage.name = ((("t_" + (i * map.tileW)) + "_") + (j * map.tileW)); tileImage.gotoAndStop(4); newSprite.addChild(tileImage); break; case 3: tileImage = new TilesMc(); tileImage.x = (i * map.tileW); tileImage.y = (j * map.tileW); tileImage.i = i; tileImage.j = j; tileImage.name = ((("t_" + (i * map.tileW)) + "_") + (j * map.tileW)); tileImage.gotoAndStop(3); tileImage.box = true; newSprite.addChild(tileImage); boxes.push(tileImage); break; case 4: tileImage = new TilesMc(); tileImage.x = (i * map.tileW); tileImage.y = (j * map.tileW); tileImage.name = ((("t_" + (i * map.tileW)) + "_") + (j * map.tileW)); tileImage.gotoAndStop(5); newSprite.addChild(tileImage); barrels.push(tileImage); break; case 5: tileImage = new TilesMc(); tileImage.x = (i * map.tileW); tileImage.y = (j * map.tileW); tileImage.name = ((("t_" + (i * map.tileW)) + "_") + (j * map.tileW)); tileImage.gotoAndStop(6); newSprite.addChild(tileImage); break; }; j++; }; i++; }; newSprite.cacheAsBitmap = true; addChild(newSprite); } private function generateMap(map:Object):void{ var backgroundData:BitmapData; var scrollx:int; var scrolly:int; var myMatrix:Matrix; var i:uint; var j:uint; backgroundData = new BitmapData((map.mapArray[0].length * map.tileW), (map.mapArray.length * map.tileW), true, 0xFFFFFF); backgroundImage = new Bitmap(backgroundData); i = 0; while (i < map.mapArray[0].length) { j = 0; while (j < map.mapArray.length) { if (map.mapArray[j][i] < 21){ scrollx = (i * map.tileW); scrolly = (j * map.tileW); myMatrix = new Matrix(); myMatrix.tx = scrollx; myMatrix.ty = scrolly; backgroundImage.bitmapData.draw(tilesArray[map.mapArray[j][i]], myMatrix); }; j++; }; i++; }; addChild(backgroundImage); } } }//package th.GameFramework.Platformer
Section 124
//Tile (th.GameFramework.Tiles.Tile) package th.GameFramework.Tiles { import flash.display.*; public class Tile extends Sprite { public static var ob:Object; public static var map:Object; public function Tile():void{ super(); } public static function generateTiles(_map:Object):void{ var xx:uint; var yy:uint; var i:uint; var j:uint; ob = new Object(); map = _map; i = 0; while (i < map.mapArray[0].length) { j = 0; while (j < map.mapArray.length) { xx = i; yy = j; createTileObject(((("t_" + yy) + "_") + xx), map.mapArray[j][i]); j++; }; i++; }; } public static function getMyCorners(xx, yy, _ob){ _ob.downY = Math.floor((yy / map.tileH)); _ob.upY = Math.floor(((yy - _ob.height) / map.tileH)); _ob.leftX = Math.floor(((xx - _ob.width) / map.tileH)); _ob.rightX = Math.floor(((xx + _ob.width) / map.tileH)); if (ob[((("t_" + _ob.upY) + "_") + _ob.leftX)]){ _ob.upleft = ob[((("t_" + _ob.upY) + "_") + _ob.leftX)].walkable; }; if (ob[((("t_" + _ob.downY) + "_") + _ob.leftX)]){ _ob.downleft = ob[((("t_" + _ob.downY) + "_") + _ob.leftX)].walkable; }; if (ob[((("t_" + _ob.upY) + "_") + _ob.rightX)]){ _ob.upright = ob[((("t_" + _ob.upY) + "_") + _ob.rightX)].walkable; }; if (ob[((("t_" + _ob.downY) + "_") + _ob.rightX)]){ _ob.downright = ob[((("t_" + _ob.downY) + "_") + _ob.rightX)].walkable; }; } private static function createTileObject(str:String, num:uint):void{ ob[str] = new Object(); ob[str].num = num; ob[str].walkable = false; ob[str].cloud = false; if ((((num == 0)) || ((num > 20)))){ ob[str].walkable = true; }; if ((((((num == 2)) || ((num == 4)))) || ((num == 5)))){ ob[str].cloud = true; ob[str].walkable = true; }; } public static function isCloud(xx, yy):Boolean{ if (ob[((("t_" + Math.floor((yy / map.tileW))) + "_") + Math.floor((xx / map.tileW)))]){ if (ob[((("t_" + Math.floor((yy / map.tileW))) + "_") + Math.floor((xx / map.tileW)))].cloud){ return (true); }; }; return (false); } } }//package th.GameFramework.Tiles
Section 125
//GetDistance (th.utilities.GetDistance) package th.utilities { import flash.display.*; import flash.geom.*; public class GetDistance extends Sprite { public function GetDistance(){ super(); } public static function _get(p1:Point, p2:Point):Number{ var dist:*; var dx:*; var dy:Number; dx = (p2.x - p1.x); dy = (p2.y - p1.y); dist = Math.sqrt(((dx * dx) + (dy * dy))); return (dist); } } }//package th.utilities
Section 126
//LoadSwf (th.utilities.LoadSwf) package th.utilities { import flash.events.*; import flash.display.*; import flash.net.*; import rl.dev.*; public class LoadSwf extends Sprite { public static var callBack:Function; private static var targetClip:String; private static var targ:Object; private static var fileString:String; private static var swfLoader:Loader; public static var loadedSwf:MovieClip = new MovieClip(); public function LoadSwf():void{ super(); } private static function onIOError(e:IOErrorEvent):void{ trace(e); SWFConsole.output(e); } public static function load(swf:String, _targ:Object, _targetClip:String, _callBack:Function):void{ var imagePath:String; var file:String; targ = _targ; targetClip = _targetClip; callBack = _callBack; imagePath = ""; file = (swf + ".swf"); fileString = file; swfLoader = new Loader(); swfLoader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, onIOError, false, 0, true); swfLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, onSwfLoad, false, 0, true); swfLoader.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS, swfProgress, false, 0, true); swfLoader.load(new URLRequest((imagePath + file))); } public static function gotoFrame(f:uint):void{ if (loadedSwf.currentFrame != f){ loadedSwf.gotoAndStop(f); }; } private static function swfProgress(e:ProgressEvent):void{ var goFrame:int; goFrame = (100 * (e.bytesLoaded / e.bytesTotal)); } public static function init(swf:String):void{ } private static function onSwfLoad(e:Event=null, swfOb:Object=null):void{ var swfCard:Object; var targOb:LoaderInfo; swfLoader.contentLoaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, onIOError); swfLoader.contentLoaderInfo.removeEventListener(Event.COMPLETE, onSwfLoad); swfLoader.contentLoaderInfo.removeEventListener(ProgressEvent.PROGRESS, swfProgress); targOb = (e.target as LoaderInfo); swfCard = targOb.content; swfCard[targetClip].x = (swfCard[targetClip].y = 0); swfCache._push(fileString, targOb); targ.addChild(swfCard[targetClip]); targ[targetClip] = swfCard[targetClip]; if (callBack != null){ callBack(); }; } } }//package th.utilities
Section 127
//OddOrEven (th.utilities.OddOrEven) package th.utilities { import flash.display.*; public class OddOrEven extends Sprite { public function OddOrEven(){ super(); } public function OddOrEvent():void{ } public static function isEven(n:Number):Boolean{ var myModulo:Number; myModulo = (n % 2); if (myModulo == 1){ return (true); }; return (false); } } }//package th.utilities
Section 128
//swfCache (th.utilities.swfCache) package th.utilities { import flash.display.*; import rl.dev.*; public class swfCache extends Sprite { public static var cacheArray:Array; public function swfCache():void{ super(); } public static function init():void{ cacheArray = new Array(); } public static function _get(file:String):Object{ var newOb:Object; var i:uint; newOb = new Object(); i = 0; while (i < cacheArray.length) { if (cacheArray[i].file == file){ return (cacheArray[i].swf); }; i++; }; SWFConsole.output((("didnt find your file:" + file) + " in swfcache")); return (newOb); } public static function _check(file:String):Boolean{ var i:uint; i = 0; while (i < cacheArray.length) { if (cacheArray[i].file == file){ return (true); }; SWFConsole.output((" ------------------ cache file = " + cacheArray[i].file)); i++; }; return (false); } public static function _push(file:String, swf:Object):void{ var cacheOb:Object; cacheOb = new Object(); cacheOb.file = file; cacheOb.swf = swf; cacheArray.push(cacheOb); SWFConsole.output((" ------------------ cache file pushed = " + file)); } } }//package th.utilities
Section 129
//BombClip (BombClip) package { import th.GameFramework.Platformer.Sprites.*; public dynamic class BombClip extends Bomb { public function BombClip(){ super(); addFrameScript(0, frame1, 4, frame5); } function frame1(){ stop(); } function frame5(){ stop(); } } }//package
Section 130
//btn_highscores_ (btn_highscores_) package { import rl.display.*; public dynamic class btn_highscores_ extends AdvancedButton { public function btn_highscores_(){ super(); } } }//package
Section 131
//btn_instructions_ (btn_instructions_) package { import rl.display.*; public dynamic class btn_instructions_ extends AdvancedButton { public function btn_instructions_(){ super(); } } }//package
Section 132
//btn_logolink_ (btn_logolink_) package { import rl.display.*; public dynamic class btn_logolink_ extends AdvancedButton { public function btn_logolink_(){ super(); } } }//package
Section 133
//btn_logolink_smaller_ (btn_logolink_smaller_) package { import rl.display.*; public dynamic class btn_logolink_smaller_ extends AdvancedButton { public function btn_logolink_smaller_(){ super(); } } }//package
Section 134
//btn_mainMenu_ (btn_mainMenu_) package { import rl.display.*; public dynamic class btn_mainMenu_ extends AdvancedButton { public function btn_mainMenu_(){ super(); } } }//package
Section 135
//btn_music_ (btn_music_) package { import rl.display.*; public dynamic class btn_music_ extends AdvancedButton { public function btn_music_(){ super(); } } }//package
Section 136
//Btn_next (Btn_next) package { import rl.display.*; public dynamic class Btn_next extends AdvancedButton { public function Btn_next(){ super(); } } }//package
Section 137
//btn_pausegame_ (btn_pausegame_) package { import rl.display.*; public dynamic class btn_pausegame_ extends AdvancedButton { public function btn_pausegame_(){ super(); } } }//package
Section 138
//btn_playmore_ (btn_playmore_) package { import rl.display.*; public dynamic class btn_playmore_ extends AdvancedButton { public function btn_playmore_(){ super(); } } }//package
Section 139
//btn_quit_ (btn_quit_) package { import rl.display.*; public dynamic class btn_quit_ extends AdvancedButton { public function btn_quit_(){ super(); } } }//package
Section 140
//btn_replay_ (btn_replay_) package { import rl.display.*; public dynamic class btn_replay_ extends AdvancedButton { public function btn_replay_(){ super(); } } }//package
Section 141
//btn_reume_ (btn_reume_) package { import rl.display.*; public dynamic class btn_reume_ extends AdvancedButton { public function btn_reume_(){ super(); } } }//package
Section 142
//btn_righto_ (btn_righto_) package { import rl.display.*; public dynamic class btn_righto_ extends AdvancedButton { public function btn_righto_(){ super(); } } }//package
Section 143
//btn_sendtofriends_ (btn_sendtofriends_) package { import rl.display.*; public dynamic class btn_sendtofriends_ extends AdvancedButton { public function btn_sendtofriends_(){ super(); } } }//package
Section 144
//btn_startGame (btn_startGame) package { import rl.display.*; public dynamic class btn_startGame extends AdvancedButton { public function btn_startGame(){ super(); } } }//package
Section 145
//btn_submitscore_ (btn_submitscore_) package { import rl.display.*; public dynamic class btn_submitscore_ extends AdvancedButton { public function btn_submitscore_(){ super(); } } }//package
Section 146
//bunnycharacter (bunnycharacter) package { import flash.display.*; public dynamic class bunnycharacter extends MovieClip { public function bunnycharacter(){ super(); addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package
Section 147
//Burglar (Burglar) package { import flash.display.*; public dynamic class Burglar extends MovieClip { public var clip:MovieClip; public function Burglar(){ super(); addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package
Section 148
//BurglarPopUp (BurglarPopUp) package { import th.GameFramework.Display.*; public dynamic class BurglarPopUp extends BurglarPopUp { public function BurglarPopUp(){ super(); } } }//package
Section 149
//CrateShard (CrateShard) package { import flash.display.*; public dynamic class CrateShard extends MovieClip { public var shard:MovieClip; public function CrateShard(){ super(); } } }//package
Section 150
//FadeAway (FadeAway) package { import com.Ui.*; public dynamic class FadeAway extends FadeAway { public function FadeAway(){ super(); } } }//package
Section 151
//GameFrameWork (GameFrameWork) package { import gs.*; import flash.events.*; import flash.display.*; import flash.net.*; import flash.geom.*; import th.GameFramework.Display.*; import rl.dev.*; import th.GameFramework.Platformer.*; import th.GameFramework.Platformer.Sprites.*; import com.sounds.*; import com.*; import th.GameFramework.Tiles.*; import th.utilities.*; import th.GameFramework.Key.*; import th.GameFramework.HitDetection.*; public class GameFrameWork extends MovieClip { var sharedObject:SharedObject; public var hud:Hud; var gameLose:GameLose_; var titleScreen:TitleScreen; var map:Object; var _output:SWFConsole; var starContainer:Sprite; var puffContainer:Sprite; var gameWin:GameWin_; var container:Sprite; var tallyScore:TallyScore; public var enemy:Enemy; var platformer:Platformer; var gameIntro:GameIntro_; var levelPopUp:LevelPopUp_; var gameContainer:Sprite; var spritesArray:Array; var ob:Object; public var player:Player; var timeInt:uint;// = 0 public function GameFrameWork():void{ gameContainer = new Sprite(); container = new Sprite(); starContainer = new Sprite(); puffContainer = new Sprite(); platformer = new Platformer(); spritesArray = new Array(); map = new Object(); ob = new Object(); timeInt = 0; super(); hud.visible = false; init(); } private function clearObject(ob:Object):void{ var num:uint; var mc:MovieClip; var i:uint; num = ob.numChildren; i = 0; while (i < num) { ob.removeChildAt(0); i++; }; } public function init(e:Event=null):void{ addEventListener(Event.ENTER_FRAME, mainLoop, false, 0, true); gameContainer = new Sprite(); titleScreen = new TitleScreen(); titleScreen.init(startLevel); addChild(titleScreen); addChild(gameContainer); swfCache.init(); _output = new SWFConsole(640, 500, true); addChild(_output); Key.init(stage); Sounds.init(); } private function startBurglar():void{ var barrel:MovieClip; var randomBarrel:uint; var dir:int; Globals.totalBurglars++; randomBarrel = (Math.random() * platformer.barrels.length); dir = 1; if ((Math.random() * 100) < 50){ dir = -1; }; barrel = platformer.barrels[randomBarrel]; createEnemy(new Point((barrel.x + 25), barrel.y), dir); } private function checkKeys():void{ if (((Key.isDown["k_37"]) && (Key.isDown["k_39"]))){ walkFalse(); } else { if (Key.isDown["k_37"]){ player.walk(-1); } else { if (Key.isDown["k_39"]){ player.walk(1); }; }; }; if (Key.isDown["k_38"]){ player.jump(); }; if (Key.isDown["k_83"]){ if (player.swing()){ checkSmashBox(); }; }; } public function testCallBack():void{ SWFConsole.output("CALLBACK"); container.focusRect = false; container.stage.focus = container; levelPopUp = new LevelPopUp_(); levelPopUp.init(("LEVEL " + Globals.level)); addChild(levelPopUp); if (Globals.musicOn){ Sounds.playSound(Sounds.music, 100); }; } public function GC():void{ var lc1:LocalConnection; var lc2:LocalConnection; lc1 = new LocalConnection(); lc2 = new LocalConnection(); lc1.connect("name"); lc2.connect("name"); //unresolved jump var _slot1 = e; } private function createEnemy(p:Point, dir:int):void{ var enemy1:Enemy; var rnd:*; var newInstance:Burglar; Globals.totalBurglars++; enemy1 = new Enemy(); enemy1.init(map, {x:p.x, y:p.y, dir:dir, patrol:true, spriteArray:spritesArray}); enemy1.x = p.x; enemy1.y = p.y; container.addChild(enemy1); rnd = (Math.random() * 100); newInstance = new Burglar(); enemy1.addChild(newInstance); enemy1.marshie = newInstance; enemy1.marshie.x = (enemy1.marshie.y = 0); spritesArray.push(enemy1); } private function checkFinishedLevel():void{ if (((Globals.finishedLevel) && (!(player.jumping)))){ Globals.paused = true; tallyScore = new TallyScore(); tallyScore.updateHud = hud.updateDisplay; addChild(tallyScore); TweenLite.to(container, 0.3, {alpha:0}); }; } private function addShrapnel(xx:uint, yy:uint, _type:String):void{ var shrap:Shrapnel; var crateShard:*; var num:uint; var i:uint; num = 10; if (_type == "puff"){ num = 5; }; xx = ((xx * 50) + 25); yy = ((yy * 50) + 25); i = 0; while (i < num) { shrap = new Shrapnel(xx, yy); if (_type == "crate"){ crateShard = new CrateShard(); }; if (_type == "puff"){ crateShard = new Puff(); }; crateShard.shard.rotation = (Math.random() * 360); shrap.addChild(crateShard); puffContainer.addChild(shrap); SWFConsole.output("adding shard"); i++; }; } private function clearLevel():void{ spritesArray = []; timeInt = 0; Globals.time = Globals.startTime; if (player){ player.bunnyMc.gotoAndStop(1); }; if (platformer.alive){ platformer.disposeBitmap(); clearObject(platformer); container.removeChild(platformer); }; clearObject(starContainer); clearObject(puffContainer); clearObject(container); clearObject(gameContainer); Sounds.stopSound(); titleScreen.titleAnim.play(); GC(); } private function loadStars():void{ } private function updateSprites():void{ var spriteOb:Object; var i:uint; i = 0; while (i < spritesArray.length) { spriteOb = spritesArray[i]; if (spriteOb.type == "player"){ if (((BasicHitDetection.checkHit(spriteOb)) && (!(spriteOb.hit)))){ spriteOb.hitEnemy(BasicHitDetection.checkHit(spriteOb)); }; if (player.isSwinging2){ if (((BasicHitDetection.checkSwing(spriteOb)) && (!(spriteOb.hit)))){ spriteOb.hitEnemy(BasicHitDetection.checkSwing(spriteOb)); }; }; }; if (spriteOb.type == "player"){ spriteOb.movePlayer(); spriteOb.x = spriteOb.xx; spriteOb.y = spriteOb.yy; }; if (spriteOb.type == "enemy"){ spriteOb.movePlayer(); spriteOb.x = spriteOb.xx; spriteOb.y = spriteOb.yy; if (spriteOb.alive){ spriteOb.lookForPlayer(player, spritesArray); }; }; if (spriteOb.type == "dynamite"){ if (spriteOb.jumping){ spriteOb.move(); }; if (spriteOb.alive){ checkHitBomb(spriteOb); }; }; i++; }; } private function timeUp():void{ var timeUpPopUp:TimeUpPopUp; Globals.lives--; player.bunnyMc.gotoAndStop(4); timeUpPopUp = new TimeUpPopUp(); timeUpPopUp.init(new Point(325, 250)); addChild(timeUpPopUp); Globals.paused = true; player.addPuff(player.xx, player.yy); } private function loadObjects(map):void{ var xx:uint; var yy:uint; var i:uint; var j:uint; trace("LOAD OBJECTS"); i = 0; while (i < map.mapArray[0].length) { j = 0; while (j < map.mapArray.length) { xx = ((i * 50) + 25); yy = ((j * 50) + 50); if (map.mapArray[j][i] > 20){ addObject(new Point(xx, yy), map.mapArray[j][i]); }; j++; }; i++; }; } private function checkSmashBox():void{ var box:MovieClip; var i:uint; var yy:*; var xx:*; var scoreAdd:uint; var scorePopUp:ScorePopUp; i = 0; while (i < platformer.boxes.length) { box = platformer.boxes[i]; if (GetDistance._get(new Point((player.x + (25 * player.dir)), (player.y - 25)), new Point((box.x + 25), (box.y + 25))) < 30){ box.gotoAndStop(10); yy = box.j; xx = box.i; Tile.ob[((("t_" + yy) + "_") + xx)].walkable = true; Tile.ob[((("t_" + yy) + "_") + xx)].cloud = false; clearObject(puffContainer); platformer.boxes.splice(i, 1); Sounds.crate.play(); scoreAdd = 50; hud.addScore(scoreAdd); scorePopUp = new ScorePopUp(); scorePopUp.init(new Point((box.x + 25), (box.y + 25)), (scoreAdd + " pts")); container.addChild(scorePopUp); break; }; i++; }; } private function startLevel(e:MouseEvent=null, clr:Boolean=true):void{ var mapLevel:uint; var bunnyMc:Plod; SWFConsole.output("starting level creation"); titleScreen.visible = false; if (clr){ clearLevel(); }; mapLevel = Globals.level; Globals.evidence = 0; Globals.clues = 0; Globals.totalclues = 0; Globals.totalBurglars = 0; Globals.burglars = 0; Globals.totalevidence = 0; Globals.startedBurglar = false; Globals.foundAllClues = false; Globals.finishedLevel = false; Globals.paused = true; container.visible = false; container.addChild(starContainer); spritesArray = new Array(); map.mapArray = [[1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1], [1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 2, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1], [1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 2, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]]; map.tileW = (map.tileH = 50); Map.init(40, 40); map.mapArray = Map.maps[("level" + mapLevel)]; removeEventListener(Event.ADDED_TO_STAGE, init); SWFConsole.output("gotcha"); platformer = new Platformer(); platformer.init(map, "mc"); container.addChild(platformer); Tile.generateTiles(map); ob.height = 4; player = new Player(); player.init(map, {scoreFunction:hud.addScore, updateHud:hud.updateDisplay}); player.id = 0; container.addChild(player); container.x = 0; container.y = 0; spritesArray.push(player); setChildIndex(hud, (numChildren - 1)); bunnyMc = new Plod(); player.addChild(bunnyMc); player.bunnyMc = bunnyMc; BasicHitDetection.init(spritesArray); MyCamera.init(new Point(container.width, container.height), new Point(650, 500)); MyCamera.screen = container; MyCamera.target = player; gameContainer.addChild(container); if (Globals.level > 1){ container.focusRect = false; container.stage.focus = container; }; titleScreen.titleAnim.stop(); loadObjects(map); hud.init(); gameIntro = new GameIntro_(); gameIntro.callBack = testCallBack; addChild(gameIntro); MyCamera.snap(new Point(player.xx, player.yy)); container.alpha = 0; container.visible = true; TweenLite.to(container, 0.3, {alpha:1}); } public function loadSprite(ob):void{ LoadSwf.load("bunnytemp", ob, "marshie", null); } private function createEnemies():void{ var xx:int; var yy:int; var dir:int; var i:uint; var j:uint; i = 0; while (i < map.mapArray[0].length) { j = 0; while (j < map.mapArray.length) { xx = (i * 50); yy = (j * 50); if (xx < player.xx){ dir = -1; } else { dir = 1; }; if (map.mapArray[j][i] == 27){ createEnemy(new Point(xx, yy), dir); }; j++; }; i++; }; Globals.time = Globals.startTime; } private function addGameOver():void{ gameLose = new GameLose_(); addChild(gameLose); } private function walkFalse():void{ player.walking = false; } private function addStar(p:Point):void{ } private function addGameFinished():void{ gameWin = new GameWin_(); addChild(gameWin); } private function addCupCake(p:Point):void{ } private function addObject(p:Point, num:uint):void{ var obname:String; var star:PickUp; var ob:Objects; obname = "object"; switch (num){ case 21: obname = "clue"; break; case 22: obname = "money"; break; case 23: obname = "gold"; break; case 24: obname = "painting"; break; case 25: obname = "diamond"; break; case 26: player.setStartPoint(p); return; }; if (obname == "clue"){ Globals.totalclues++; } else { Globals.totalevidence++; }; star = new PickUp("object", p, spritesArray); ob = new Objects(); ob.gotoAndStop((num - 20)); star.name = obname; star.addChild(ob); starContainer.addChild(star); ob.cacheAsBitmap = true; spritesArray.push(star); } private function checkHitBomb(bombOb:Object):void{ SWFConsole.output("CHECK HIT BOMB"); if (GetDistance._get(new Point(bombOb.x, bombOb.y), new Point(player.x, (player.y - 25))) < 80){ player.hitByBomb(); }; } private function checkTile(pnt:Point):void{ var xx:uint; var yy:uint; var tileName:String; xx = (pnt.x / map.tileW); yy = (pnt.y / map.tileW); tileName = ((("t_" + xx) + "_") + yy); Tile.getMyCorners(mouseX, mouseY, ob); } private function quitGame():void{ hud.visible = false; titleScreen.visible = true; } private function mainLoop(e:Event):void{ var burglarPopUp:BurglarPopUp; if (Globals.quit){ Globals.quit = false; if (Globals.replay){ Globals.replay = false; startLevel(null, true); } else { quitGame(); if (!Globals.dead){ Globals.lives = Globals.livesStart; Globals.level = Globals.levelStart; Globals.score = 0; }; clearLevel(); }; }; if (!Globals.paused){ checkKeys(); updateSprites(); MyCamera.mainloop(); checkFinishedLevel(); timeInt++; if (timeInt == 30){ if (Globals.time == 0){ timeUp(); }; timeInt = 0; if (Globals.time > 0){ Globals.time--; }; hud.updateDisplay(); }; if (((((!((Globals.totalBurglars == 0))) && ((Globals.burglars == Globals.totalBurglars)))) && (!(Globals.finishedLevel)))){ player.finishLevel1(); }; }; if (Globals.dead){ Globals.paused = true; clearLevel(); addGameOver(); Globals.dead = false; }; if (Globals.startLevel){ Globals.startLevel = false; if (Globals.level < Globals.totalLevels){ startLevel(); } else { addGameFinished(); }; }; if (((Globals.foundAllClues) && (!(Globals.startedBurglar)))){ Globals.startedBurglar = true; createEnemies(); hud.updateDisplay(); Sounds.stopSound(); burglarPopUp = new BurglarPopUp(); burglarPopUp.init(new Point(325, 250)); addChild(burglarPopUp); if (Globals.musicOn){ Sounds.playSound(Sounds.chase, 100); }; }; } } }//package
Section 152
//GameFrameWork_ (GameFrameWork_) package { public dynamic class GameFrameWork_ extends GameFrameWork { public function GameFrameWork_(){ super(); } } }//package
Section 153
//GameIntro_ (GameIntro_) package { import com.Ui.*; public dynamic class GameIntro_ extends GameIntro { public function GameIntro_(){ super(); } } }//package
Section 154
//GameLose_ (GameLose_) package { import com.Ui.*; public dynamic class GameLose_ extends GameLosey { public function GameLose_(){ super(); } } }//package
Section 155
//GameWin_ (GameWin_) package { import com.Ui.*; public dynamic class GameWin_ extends GameWin { public function GameWin_(){ super(); } } }//package
Section 156
//Hud (Hud) package { import com.Ui.*; public dynamic class Hud extends Hud { public function Hud(){ super(); } } }//package
Section 157
//Instructions_ (Instructions_) package { import com.Ui.*; public dynamic class Instructions_ extends Instructions { public function Instructions_(){ super(); } } }//package
Section 158
//LevelPopUp_ (LevelPopUp_) package { import com.Ui.*; public dynamic class LevelPopUp_ extends LevelPopUp { public function LevelPopUp_(){ super(); } } }//package
Section 159
//music_gameover (music_gameover) package { import flash.media.*; public dynamic class music_gameover extends Sound { public function music_gameover(){ super(); } } }//package
Section 160
//Objects (Objects) package { import flash.display.*; public dynamic class Objects extends MovieClip { public function Objects(){ super(); } } }//package
Section 161
//PausedScreen_ (PausedScreen_) package { import com.Ui.*; public dynamic class PausedScreen_ extends PausedScreen { public function PausedScreen_(){ super(); } } }//package
Section 162
//Plod (Plod) package { import flash.display.*; public dynamic class Plod extends MovieClip { public var clipo:MovieClip; public function Plod(){ super(); addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package
Section 163
//Puff (Puff) package { import flash.display.*; public dynamic class Puff extends MovieClip { public var shard:MovieClip; public function Puff(){ super(); } } }//package
Section 164
//s10s (s10s) package { import rl.display.*; public dynamic class s10s extends AdvancedButton { public function s10s(){ super(); } } }//package
Section 165
//s11s (s11s) package { import rl.display.*; public dynamic class s11s extends AdvancedButton { public function s11s(){ super(); } } }//package
Section 166
//s12a (s12a) package { import rl.display.*; public dynamic class s12a extends AdvancedButton { public function s12a(){ super(); } } }//package
Section 167
//s13a (s13a) package { import rl.display.*; public dynamic class s13a extends AdvancedButton { public function s13a(){ super(); } } }//package
Section 168
//s14s (s14s) package { import rl.display.*; public dynamic class s14s extends AdvancedButton { public function s14s(){ super(); } } }//package
Section 169
//s15s (s15s) package { import rl.display.*; public dynamic class s15s extends AdvancedButton { public function s15s(){ super(); } } }//package
Section 170
//s16a (s16a) package { import rl.display.*; public dynamic class s16a extends AdvancedButton { public function s16a(){ super(); } } }//package
Section 171
//s1s (s1s) package { import rl.display.*; public dynamic class s1s extends AdvancedButton { public function s1s(){ super(); } } }//package
Section 172
//s2s (s2s) package { import rl.display.*; public dynamic class s2s extends AdvancedButton { public function s2s(){ super(); } } }//package
Section 173
//s3s (s3s) package { import rl.display.*; public dynamic class s3s extends AdvancedButton { public function s3s(){ super(); } } }//package
Section 174
//s4a (s4a) package { import rl.display.*; public dynamic class s4a extends AdvancedButton { public function s4a(){ super(); } } }//package
Section 175
//s5a (s5a) package { import rl.display.*; public dynamic class s5a extends AdvancedButton { public function s5a(){ super(); } } }//package
Section 176
//s6s (s6s) package { import rl.display.*; public dynamic class s6s extends AdvancedButton { public function s6s(){ super(); } } }//package
Section 177
//s7a (s7a) package { import rl.display.*; public dynamic class s7a extends AdvancedButton { public function s7a(){ super(); } } }//package
Section 178
//s8a (s8a) package { import rl.display.*; public dynamic class s8a extends AdvancedButton { public function s8a(){ super(); } } }//package
Section 179
//s9s (s9s) package { import rl.display.*; public dynamic class s9s extends AdvancedButton { public function s9s(){ super(); } } }//package
Section 180
//ScorePopUp (ScorePopUp) package { import th.GameFramework.Display.*; public dynamic class ScorePopUp extends ScorePopUp { public function ScorePopUp(){ super(); } } }//package
Section 181
//sound_bounce (sound_bounce) package { import flash.media.*; public dynamic class sound_bounce extends Sound { public function sound_bounce(){ super(); } } }//package
Section 182
//sound_bounceSmall (sound_bounceSmall) package { import flash.media.*; public dynamic class sound_bounceSmall extends Sound { public function sound_bounceSmall(){ super(); } } }//package
Section 183
//sound_chase (sound_chase) package { import flash.media.*; public dynamic class sound_chase extends Sound { public function sound_chase(){ super(); } } }//package
Section 184
//sound_click (sound_click) package { import flash.media.*; public dynamic class sound_click extends Sound { public function sound_click(){ super(); } } }//package
Section 185
//sound_clickClose (sound_clickClose) package { import flash.media.*; public dynamic class sound_clickClose extends Sound { public function sound_clickClose(){ super(); } } }//package
Section 186
//sound_coin (sound_coin) package { import flash.media.*; public dynamic class sound_coin extends Sound { public function sound_coin(){ super(); } } }//package
Section 187
//sound_coin2 (sound_coin2) package { import flash.media.*; public dynamic class sound_coin2 extends Sound { public function sound_coin2(){ super(); } } }//package
Section 188
//sound_collect (sound_collect) package { import flash.media.*; public dynamic class sound_collect extends Sound { public function sound_collect(){ super(); } } }//package
Section 189
//sound_crate (sound_crate) package { import flash.media.*; public dynamic class sound_crate extends Sound { public function sound_crate(){ super(); } } }//package
Section 190
//sound_endlevel (sound_endlevel) package { import flash.media.*; public dynamic class sound_endlevel extends Sound { public function sound_endlevel(){ super(); } } }//package
Section 191
//sound_explosion (sound_explosion) package { import flash.media.*; public dynamic class sound_explosion extends Sound { public function sound_explosion(){ super(); } } }//package
Section 192
//sound_jump (sound_jump) package { import flash.media.*; public dynamic class sound_jump extends Sound { public function sound_jump(){ super(); } } }//package
Section 193
//sound_music (sound_music) package { import flash.media.*; public dynamic class sound_music extends Sound { public function sound_music(){ super(); } } }//package
Section 194
//sound_tally (sound_tally) package { import flash.media.*; public dynamic class sound_tally extends Sound { public function sound_tally(){ super(); } } }//package
Section 195
//sound_truncheon (sound_truncheon) package { import flash.media.*; public dynamic class sound_truncheon extends Sound { public function sound_truncheon(){ super(); } } }//package
Section 196
//sound_whistle (sound_whistle) package { import flash.media.*; public dynamic class sound_whistle extends Sound { public function sound_whistle(){ super(); } } }//package
Section 197
//TallyScore (TallyScore) package { import com.Ui.*; public dynamic class TallyScore extends TallyScore { public function TallyScore(){ super(); } } }//package
Section 198
//TilesMc (TilesMc) package { import flash.display.*; public dynamic class TilesMc extends MovieClip { public function TilesMc(){ super(); addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package
Section 199
//TimeUpPopUp (TimeUpPopUp) package { import th.GameFramework.Display.*; public dynamic class TimeUpPopUp extends TimePopUp { public function TimeUpPopUp(){ super(); } } }//package
Section 200
//TitleScreen (TitleScreen) package { import com.Ui.*; public dynamic class TitleScreen extends TitleScreen { public function TitleScreen(){ super(); } } }//package

Library Items

Symbol 1 BitmapUsed by:2
Symbol 2 GraphicUses:1Used by:9
Symbol 3 BitmapUsed by:4
Symbol 4 GraphicUses:3Used by:9
Symbol 5 BitmapUsed by:6
Symbol 6 GraphicUses:5Used by:9
Symbol 7 BitmapUsed by:8
Symbol 8 GraphicUses:7Used by:9
Symbol 9 MovieClipUses:2 4 6 8Used by:112
Symbol 10 BitmapUsed by:11
Symbol 11 GraphicUses:10Used by:26
Symbol 12 BitmapUsed by:13
Symbol 13 GraphicUses:12Used by:26
Symbol 14 BitmapUsed by:15
Symbol 15 GraphicUses:14Used by:26
Symbol 16 BitmapUsed by:17
Symbol 17 GraphicUses:16Used by:26
Symbol 18 BitmapUsed by:19
Symbol 19 GraphicUses:18Used by:26
Symbol 20 BitmapUsed by:21
Symbol 21 GraphicUses:20Used by:26
Symbol 22 BitmapUsed by:23
Symbol 23 GraphicUses:22Used by:26
Symbol 24 BitmapUsed by:25
Symbol 25 GraphicUses:24Used by:26
Symbol 26 MovieClipUses:11 13 15 17 19 21 23 25Used by:112
Symbol 27 BitmapUsed by:28
Symbol 28 GraphicUses:27Used by:31
Symbol 29 BitmapUsed by:30
Symbol 30 GraphicUses:29Used by:31
Symbol 31 MovieClip {Plod_fla.jumpup_202}Uses:28 30Used by:112
Symbol 32 BitmapUsed by:33
Symbol 33 GraphicUses:32Used by:34
Symbol 34 MovieClipUses:33Used by:35
Symbol 35 MovieClip {Plod_fla.hit_203}Uses:34Used by:112
Symbol 36 BitmapUsed by:37
Symbol 37 GraphicUses:36Used by:68
Symbol 38 BitmapUsed by:39
Symbol 39 GraphicUses:38Used by:68
Symbol 40 BitmapUsed by:41
Symbol 41 GraphicUses:40Used by:68
Symbol 42 BitmapUsed by:43
Symbol 43 GraphicUses:42Used by:68
Symbol 44 BitmapUsed by:45
Symbol 45 GraphicUses:44Used by:68
Symbol 46 BitmapUsed by:47
Symbol 47 GraphicUses:46Used by:68
Symbol 48 BitmapUsed by:49
Symbol 49 GraphicUses:48Used by:68
Symbol 50 BitmapUsed by:51
Symbol 51 GraphicUses:50Used by:68
Symbol 52 BitmapUsed by:53
Symbol 53 GraphicUses:52Used by:68
Symbol 54 BitmapUsed by:55
Symbol 55 GraphicUses:54Used by:68
Symbol 56 BitmapUsed by:57
Symbol 57 GraphicUses:56Used by:68
Symbol 58 BitmapUsed by:59
Symbol 59 GraphicUses:58Used by:68
Symbol 60 BitmapUsed by:61
Symbol 61 GraphicUses:60Used by:68
Symbol 62 BitmapUsed by:63
Symbol 63 GraphicUses:62Used by:68
Symbol 64 BitmapUsed by:65
Symbol 65 GraphicUses:64Used by:68
Symbol 66 BitmapUsed by:67
Symbol 67 GraphicUses:66Used by:68
Symbol 68 MovieClip {Plod_fla.victory_205}Uses:37 39 41 43 45 47 49 51 53 55 57 59 61 63 65 67Used by:112
Symbol 69 BitmapUsed by:70
Symbol 70 GraphicUses:69Used by:111
Symbol 71 BitmapUsed by:72
Symbol 72 GraphicUses:71Used by:111
Symbol 73 BitmapUsed by:74
Symbol 74 GraphicUses:73Used by:111
Symbol 75 BitmapUsed by:76
Symbol 76 GraphicUses:75Used by:111
Symbol 77 BitmapUsed by:78
Symbol 78 GraphicUses:77Used by:111
Symbol 79 BitmapUsed by:80
Symbol 80 GraphicUses:79Used by:111
Symbol 81 BitmapUsed by:82
Symbol 82 GraphicUses:81Used by:111
Symbol 83 BitmapUsed by:84
Symbol 84 GraphicUses:83Used by:111
Symbol 85 BitmapUsed by:86
Symbol 86 GraphicUses:85Used by:111
Symbol 87 BitmapUsed by:88
Symbol 88 GraphicUses:87Used by:111
Symbol 89 BitmapUsed by:90
Symbol 90 GraphicUses:89Used by:111
Symbol 91 BitmapUsed by:92
Symbol 92 GraphicUses:91Used by:111
Symbol 93 BitmapUsed by:94
Symbol 94 GraphicUses:93Used by:111
Symbol 95 BitmapUsed by:96
Symbol 96 GraphicUses:95Used by:111
Symbol 97 BitmapUsed by:98
Symbol 98 GraphicUses:97Used by:111
Symbol 99 BitmapUsed by:100
Symbol 100 GraphicUses:99Used by:111
Symbol 101 BitmapUsed by:102
Symbol 102 GraphicUses:101Used by:111
Symbol 103 BitmapUsed by:104
Symbol 104 GraphicUses:103Used by:111
Symbol 105 BitmapUsed by:106
Symbol 106 GraphicUses:105Used by:111
Symbol 107 BitmapUsed by:108
Symbol 108 GraphicUses:107Used by:111
Symbol 109 BitmapUsed by:110
Symbol 110 GraphicUses:109Used by:111
Symbol 111 MovieClip {Plod_fla.tired_206}Uses:70 72 74 76 78 80 82 84 86 88 90 92 94 96 98 100 102 104 106 108 110Used by:112
Symbol 112 MovieClip {bunnycharacter}Uses:9 26 31 35 68 111
Symbol 113 GraphicUsed by:114  Timeline
Symbol 114 MovieClip {FadeAway}Uses:113Used by:Timeline
Symbol 115 FontUsed by:116 212 241 242 251 252 253 254 255 256 258 268 269 270 274 276 278 280 321 325 327 329 331 333 335 337 339 341 343 345 347 349 351 353 394 396 399 400 403 405 407 409 411 413 416 418 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 488 489 490 492 493 494 495 498 499 500 501 502 508 509 510 549 550 551 552 553 554 555 557 581
Symbol 116 TextUses:115Used by:117
Symbol 117 MovieClip {btn_sendtofriends_}Uses:116Used by:582
Symbol 118 GraphicUsed by:119
Symbol 119 MovieClipUses:118Used by:487 491 496 548 556 582  Timeline
Symbol 120 GraphicUsed by:138
Symbol 121 Sound {sound_chase}Used by:138
Symbol 122 Sound {sound_endlevel}Used by:138
Symbol 123 Sound {sound_music}Used by:138
Symbol 124 Sound {sound_bounce}Used by:138
Symbol 125 Sound {sound_coin}Used by:138
Symbol 126 Sound {sound_coin2}Used by:138
Symbol 127 Sound {sound_click}Used by:138
Symbol 128 Sound {sound_crate}Used by:138
Symbol 129 Sound {sound_explosion}Used by:138
Symbol 130 Sound {sound_collect}Used by:138
Symbol 131 Sound {sound_jump}Used by:138
Symbol 132 Sound {sound_clickClose}Used by:138
Symbol 133 Sound {sound_bounceSmall}Used by:138
Symbol 134 Sound {sound_whistle}Used by:138
Symbol 135 Sound {sound_tally}Used by:138
Symbol 136 Sound {sound_truncheon}Used by:138
Symbol 137 Sound {music_gameover}Used by:138
Symbol 138 MovieClip {Plod_fla.music_2}Uses:120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137Used by:Timeline
Symbol 139 GraphicUsed by:584
Symbol 140 GraphicUsed by:584
Symbol 141 GraphicUsed by:142
Symbol 142 MovieClipUses:141Used by:159
Symbol 143 GraphicUsed by:144
Symbol 144 MovieClipUses:143Used by:159
Symbol 145 GraphicUsed by:146
Symbol 146 MovieClipUses:145Used by:159
Symbol 147 GraphicUsed by:148
Symbol 148 MovieClipUses:147Used by:159
Symbol 149 GraphicUsed by:150
Symbol 150 MovieClipUses:149Used by:159 560
Symbol 151 GraphicUsed by:152
Symbol 152 MovieClipUses:151Used by:159 560
Symbol 153 GraphicUsed by:154
Symbol 154 MovieClipUses:153Used by:159 560
Symbol 155 GraphicUsed by:156
Symbol 156 MovieClipUses:155Used by:159 548
Symbol 157 GraphicUsed by:158
Symbol 158 MovieClipUses:157Used by:159
Symbol 159 MovieClip {BombClip}Uses:142 144 146 148 150 152 154 156 158Used by:584
Symbol 160 GraphicUsed by:161
Symbol 161 MovieClipUses:160Used by:174 297 567
Symbol 162 GraphicUsed by:163
Symbol 163 MovieClipUses:162Used by:174 202 567
Symbol 164 GraphicUsed by:165
Symbol 165 MovieClipUses:164Used by:174 202 567
Symbol 166 GraphicUsed by:167
Symbol 167 MovieClipUses:166Used by:174 297 567
Symbol 168 GraphicUsed by:169
Symbol 169 MovieClipUses:168Used by:174 297 567
Symbol 170 GraphicUsed by:171
Symbol 171 MovieClipUses:170Used by:174 567
Symbol 172 GraphicUsed by:173
Symbol 173 MovieClipUses:172Used by:174 548 567 583
Symbol 174 MovieClipUses:161 163 165 167 169 171 173Used by:204 205 206 208 564
Symbol 175 GraphicUsed by:176
Symbol 176 MovieClipUses:175Used by:181 203 567
Symbol 177 GraphicUsed by:178
Symbol 178 MovieClipUses:177Used by:181 203 567
Symbol 179 GraphicUsed by:180
Symbol 180 MovieClipUses:179Used by:181 203 567
Symbol 181 MovieClipUses:176 178 180Used by:204 205 206 208 564
Symbol 182 GraphicUsed by:183
Symbol 183 MovieClipUses:182Used by:186 567
Symbol 184 GraphicUsed by:185
Symbol 185 MovieClipUses:184Used by:186 567
Symbol 186 MovieClipUses:183 185Used by:204 205 206 208 564
Symbol 187 GraphicUsed by:188
Symbol 188 MovieClipUses:187Used by:199 207 243 567
Symbol 189 GraphicUsed by:190
Symbol 190 MovieClipUses:189Used by:199 207 243 567
Symbol 191 GraphicUsed by:192
Symbol 192 MovieClipUses:191Used by:199 207 243 259 487 496 556 560 567
Symbol 193 GraphicUsed by:194
Symbol 194 MovieClipUses:193Used by:199 207 243 567
Symbol 195 GraphicUsed by:196
Symbol 196 MovieClipUses:195Used by:199 207 243 567
Symbol 197 GraphicUsed by:198
Symbol 198 MovieClipUses:197Used by:199 207 243 567
Symbol 199 MovieClipUses:188 190 192 194 196 198Used by:204 205 206 284 548 564
Symbol 200 GraphicUsed by:201
Symbol 201 MovieClipUses:200Used by:202 567
Symbol 202 MovieClipUses:201 163 165Used by:204 205 206 208 564
Symbol 203 MovieClipUses:176 178 180Used by:204 205 206 208 564
Symbol 204 MovieClipUses:174 181 186 199 202 203Used by:209
Symbol 205 MovieClipUses:174 181 186 199 202 203Used by:209
Symbol 206 MovieClipUses:174 181 186 199 202 203Used by:209
Symbol 207 MovieClipUses:188 190 192 194 196 198Used by:208
Symbol 208 MovieClipUses:174 181 186 203 202 207Used by:209
Symbol 209 MovieClip {Burglar}Uses:204 205 206 208Used by:584
Symbol 210 GraphicUsed by:211
Symbol 211 MovieClipUses:210Used by:243 412 487 496 548 560
Symbol 212 TextUses:115Used by:243
Symbol 213 GraphicUsed by:214
Symbol 214 MovieClipUses:213Used by:243 259 487 556 567
Symbol 215 GraphicUsed by:216
Symbol 216 MovieClipUses:215Used by:243 259 487 556 567
Symbol 217 GraphicUsed by:218
Symbol 218 MovieClipUses:217Used by:243
Symbol 219 GraphicUsed by:220
Symbol 220 MovieClipUses:219Used by:243
Symbol 221 GraphicUsed by:222
Symbol 222 MovieClipUses:221Used by:243
Symbol 223 GraphicUsed by:224
Symbol 224 MovieClipUses:223Used by:243 259 487 556 567
Symbol 225 GraphicUsed by:226
Symbol 226 MovieClipUses:225Used by:243
Symbol 227 GraphicUsed by:228
Symbol 228 MovieClipUses:227Used by:243 259 487 556 567
Symbol 229 GraphicUsed by:230
Symbol 230 MovieClipUses:229Used by:243 259 487 556 567
Symbol 231 GraphicUsed by:232
Symbol 232 MovieClipUses:231Used by:243 259 487 556 567
Symbol 233 GraphicUsed by:234
Symbol 234 MovieClipUses:233Used by:243 259 487 496 556 560 567
Symbol 235 GraphicUsed by:236
Symbol 236 MovieClipUses:235Used by:243
Symbol 237 GraphicUsed by:238
Symbol 238 MovieClipUses:237Used by:243 548
Symbol 239 FontUsed by:240 507
Symbol 240 TextUses:239Used by:243 548
Symbol 241 TextUses:115Used by:243
Symbol 242 TextUses:115Used by:243
Symbol 243 MovieClip {BurglarPopUp}Uses:211 212 188 190 192 194 196 198 214 216 218 220 222 224 226 228 230 232 234 236 238 240 241 242Used by:584
Symbol 244 GraphicUsed by:245
Symbol 245 MovieClipUses:244Used by:246
Symbol 246 MovieClip {CrateShard}Uses:245Used by:392 584
Symbol 247 BitmapUsed by:248
Symbol 248 GraphicUses:247Used by:249
Symbol 249 MovieClipUses:248Used by:284
Symbol 250 FontUsed by:251 252 253 254 255 268 270 278 282 418 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 488 492 549 551 553
Symbol 251 EditableTextUses:115 250Used by:284
Symbol 252 EditableTextUses:115 250Used by:284
Symbol 253 EditableTextUses:115 250Used by:284
Symbol 254 EditableTextUses:115 250Used by:284
Symbol 255 EditableTextUses:115 250Used by:284
Symbol 256 TextUses:115Used by:257
Symbol 257 MovieClip {btn_pausegame_}Uses:256Used by:284 584
Symbol 258 TextUses:115Used by:284
Symbol 259 MovieClipUses:216 192 224 214 228 230 232 234Used by:284 306 309 310 311 314 548 564
Symbol 260 GraphicUsed by:261
Symbol 261 MovieClipUses:260Used by:284 548 583
Symbol 262 GraphicUsed by:263
Symbol 263 MovieClipUses:262Used by:284 548 583
Symbol 264 GraphicUsed by:265
Symbol 265 MovieClipUses:264Used by:284 548 583
Symbol 266 GraphicUsed by:267
Symbol 267 MovieClipUses:266Used by:284 548 583
Symbol 268 EditableTextUses:115 250Used by:284
Symbol 269 TextUses:115Used by:284
Symbol 270 EditableTextUses:115 250Used by:284
Symbol 271 GraphicUsed by:272
Symbol 272 ButtonUses:271Used by:284 582
Symbol 273 GraphicUsed by:283
Symbol 274 TextUses:115Used by:275
Symbol 275 MovieClip {btn_playmore_}Uses:274Used by:283 491 496 582 584
Symbol 276 TextUses:115Used by:277
Symbol 277 MovieClip {btn_quit_}Uses:276Used by:283 584
Symbol 278 EditableTextUses:115 250Used by:279
Symbol 279 MovieClip {btn_music_}Uses:278Used by:283 584
Symbol 280 TextUses:115Used by:281
Symbol 281 MovieClip {btn_reume_}Uses:280Used by:283 584
Symbol 282 TextUses:250Used by:283
Symbol 283 MovieClip {PausedScreen_}Uses:273 275 277 279 281 282Used by:284 584
Symbol 284 MovieClip {Hud}Uses:249 251 252 253 254 255 257 258 259 261 263 265 267 199 268 269 270 272 283Used by:285 584
Symbol 285 MovieClip {GameFrameWork_}Uses:284Used by:584  Timeline
Symbol 286 GraphicUsed by:287
Symbol 287 MovieClipUses:286Used by:290 567
Symbol 288 GraphicUsed by:289
Symbol 289 MovieClipUses:288Used by:290 567
Symbol 290 MovieClipUses:287 289Used by:306 309 310 311 314 564
Symbol 291 GraphicUsed by:292
Symbol 292 MovieClipUses:291Used by:297 305 567
Symbol 293 GraphicUsed by:294
Symbol 294 MovieClipUses:293Used by:297 305 567
Symbol 295 GraphicUsed by:296
Symbol 296 MovieClipUses:295Used by:297 567
Symbol 297 MovieClipUses:161 292 294 296 169 167Used by:306 309 310 311 314 548 564
Symbol 298 GraphicUsed by:299
Symbol 299 MovieClipUses:298Used by:302 567
Symbol 300 GraphicUsed by:301
Symbol 301 MovieClipUses:300Used by:302 567
Symbol 302 MovieClipUses:299 301Used by:306 309 310 311 314 564
Symbol 303 GraphicUsed by:304
Symbol 304 MovieClipUses:303Used by:305 567
Symbol 305 MovieClipUses:304 292 294Used by:306 309 310 311 314 564
Symbol 306 MovieClipUses:290 297 302 259 305Used by:315
Symbol 307 SoundUsed by:309
Symbol 308 SoundUsed by:309
Symbol 309 MovieClipUses:290 297 302 259 305 307 308Used by:315
Symbol 310 MovieClip {Plod_fla.plod_jumping_92}Uses:290 297 302 259 305Used by:315
Symbol 311 MovieClip {Plod_fla.plod_hit_93}Uses:290 297 302 259 305Used by:315
Symbol 312 GraphicUsed by:313
Symbol 313 MovieClipUses:312Used by:314
Symbol 314 MovieClip {Plod_fla.plod_swinging_94}Uses:290 297 302 313 259 305Used by:315
Symbol 315 MovieClip {Plod}Uses:306 309 310 311 314Used by:584
Symbol 316 GraphicUsed by:319
Symbol 317 GraphicUsed by:318
Symbol 318 MovieClipUses:317Used by:319
Symbol 319 MovieClipUses:316 318Used by:320
Symbol 320 MovieClip {Puff}Uses:319Used by:392 584
Symbol 321 TextUses:115Used by:324
Symbol 322 GraphicUsed by:323
Symbol 323 MovieClipUses:322Used by:324 326 328 330 332 334 336 338 340 342 344 346 348 350 352 354
Symbol 324 MovieClip {s1s}Uses:321 323Used by:487 584
Symbol 325 TextUses:115Used by:326
Symbol 326 MovieClip {s2s}Uses:325 323Used by:487 584
Symbol 327 TextUses:115Used by:328
Symbol 328 MovieClip {s3s}Uses:327 323Used by:487 584
Symbol 329 TextUses:115Used by:330
Symbol 330 MovieClip {s4a}Uses:329 323Used by:487 584
Symbol 331 TextUses:115Used by:332
Symbol 332 MovieClip {s5a}Uses:331 323Used by:487 584
Symbol 333 TextUses:115Used by:334
Symbol 334 MovieClip {s6s}Uses:333 323Used by:487 584
Symbol 335 TextUses:115Used by:336
Symbol 336 MovieClip {s7a}Uses:335 323Used by:487 584
Symbol 337 TextUses:115Used by:338
Symbol 338 MovieClip {s8a}Uses:337 323Used by:487 584
Symbol 339 TextUses:115Used by:340
Symbol 340 MovieClip {s9s}Uses:339 323Used by:487 584
Symbol 341 TextUses:115Used by:342
Symbol 342 MovieClip {s10s}Uses:341 323Used by:487 584
Symbol 343 TextUses:115Used by:344
Symbol 344 MovieClip {s11s}Uses:343 323Used by:487 584
Symbol 345 TextUses:115Used by:346
Symbol 346 MovieClip {s12a}Uses:345 323Used by:487 584
Symbol 347 TextUses:115Used by:348
Symbol 348 MovieClip {s13a}Uses:347 323Used by:487 584
Symbol 349 TextUses:115Used by:350
Symbol 350 MovieClip {s14s}Uses:349 323Used by:487 584
Symbol 351 TextUses:115Used by:352
Symbol 352 MovieClip {s15s}Uses:351 323Used by:487 584
Symbol 353 TextUses:115Used by:354
Symbol 354 MovieClip {s16a}Uses:353 323Used by:487 584
Symbol 355 GraphicUsed by:356
Symbol 356 MovieClipUses:355Used by:393 567
Symbol 357 GraphicUsed by:358
Symbol 358 MovieClipUses:357Used by:393 564 567
Symbol 359 GraphicUsed by:360
Symbol 360 MovieClipUses:359Used by:393 567
Symbol 361 GraphicUsed by:362
Symbol 362 MovieClipUses:361Used by:393 567
Symbol 363 GraphicUsed by:364
Symbol 364 MovieClipUses:363Used by:393
Symbol 365 GraphicUsed by:366
Symbol 366 MovieClipUses:365Used by:393
Symbol 367 GraphicUsed by:368
Symbol 368 MovieClipUses:367Used by:393
Symbol 369 GraphicUsed by:370
Symbol 370 MovieClipUses:369Used by:393
Symbol 371 GraphicUsed by:372
Symbol 372 MovieClipUses:371Used by:393
Symbol 373 GraphicUsed by:374
Symbol 374 MovieClipUses:373Used by:393
Symbol 375 GraphicUsed by:376
Symbol 376 MovieClipUses:375Used by:393
Symbol 377 GraphicUsed by:378
Symbol 378 MovieClipUses:377Used by:393
Symbol 379 GraphicUsed by:380
Symbol 380 MovieClipUses:379Used by:393
Symbol 381 GraphicUsed by:382
Symbol 382 MovieClipUses:381Used by:393
Symbol 383 GraphicUsed by:384
Symbol 384 MovieClipUses:383Used by:393
Symbol 385 GraphicUsed by:386
Symbol 386 MovieClipUses:385Used by:393
Symbol 387 GraphicUsed by:388
Symbol 388 MovieClipUses:387Used by:393
Symbol 389 GraphicUsed by:390
Symbol 390 MovieClipUses:389Used by:393
Symbol 391 GraphicUsed by:392
Symbol 392 MovieClip {Plod_fla.crateBreak_135}Uses:391 246 320Used by:393
Symbol 393 MovieClip {TilesMc}Uses:356 358 360 362 364 366 368 370 372 374 376 378 380 382 384 386 388 390 392Used by:487 584
Symbol 394 TextUses:115Used by:395
Symbol 395 MovieClip {btn_highscores_}Uses:394Used by:582 584
Symbol 396 TextUses:115Used by:397
Symbol 397 MovieClip {btn_instructions_}Uses:396Used by:582 584
Symbol 398 GraphicUsed by:401
Symbol 399 TextUses:115Used by:401
Symbol 400 TextUses:115Used by:401
Symbol 401 MovieClip {btn_logolink_}Uses:398 399 400Used by:584
Symbol 402 GraphicUsed by:404
Symbol 403 TextUses:115Used by:404
Symbol 404 MovieClip {btn_logolink_smaller_}Uses:402 403Used by:584
Symbol 405 TextUses:115Used by:406
Symbol 406 MovieClip {btn_mainMenu_}Uses:405Used by:491 496 548 584
Symbol 407 TextUses:115Used by:408
Symbol 408 MovieClip {Btn_next}Uses:407Used by:556 584
Symbol 409 TextUses:115Used by:410
Symbol 410 MovieClip {btn_replay_}Uses:409Used by:491 496 584
Symbol 411 TextUses:115Used by:412
Symbol 412 MovieClip {btn_righto_}Uses:211 411Used by:487 584
Symbol 413 TextUses:115Used by:414
Symbol 414 MovieClipUses:413Used by:415
Symbol 415 MovieClip {btn_startGame}Uses:414Used by:548 582 584
Symbol 416 TextUses:115Used by:417
Symbol 417 MovieClip {btn_submitscore_}Uses:416Used by:491 496 584
Symbol 418 EditableTextUses:115 250Used by:419
Symbol 419 MovieClip {LevelPopUp_}Uses:418Used by:584
Symbol 420 FontUsed by:421
Symbol 421 EditableTextUses:420Used by:422
Symbol 422 MovieClip {ScorePopUp}Uses:421Used by:584
Symbol 423 GraphicUsed by:487 491 496 556 582
Symbol 424 GraphicUsed by:425
Symbol 425 MovieClipUses:424Used by:487 496 560
Symbol 426 GraphicUsed by:427
Symbol 427 MovieClipUses:426Used by:487 496 560
Symbol 428 GraphicUsed by:429
Symbol 429 MovieClipUses:428Used by:487 496 560
Symbol 430 GraphicUsed by:431
Symbol 431 MovieClipUses:430Used by:487 496
Symbol 432 GraphicUsed by:433
Symbol 433 MovieClipUses:432Used by:487 496 560
Symbol 434 GraphicUsed by:435
Symbol 435 MovieClipUses:434Used by:487 496 560
Symbol 436 GraphicUsed by:437
Symbol 437 MovieClipUses:436Used by:487 496 560
Symbol 438 GraphicUsed by:487 496 560
Symbol 439 GraphicUsed by:440
Symbol 440 MovieClipUses:439Used by:487 496 560
Symbol 441 GraphicUsed by:442
Symbol 442 MovieClipUses:441Used by:487
Symbol 443 TextUses:115Used by:487
Symbol 444 TextUses:115Used by:487
Symbol 445 TextUses:115Used by:487
Symbol 446 TextUses:115Used by:487
Symbol 447 TextUses:115Used by:487
Symbol 448 TextUses:115Used by:487
Symbol 449 TextUses:115Used by:487
Symbol 450 TextUses:115Used by:487
Symbol 451 TextUses:115Used by:487
Symbol 452 TextUses:115Used by:487
Symbol 453 TextUses:115Used by:487
Symbol 454 TextUses:115Used by:487
Symbol 455 TextUses:115Used by:487
Symbol 456 TextUses:115Used by:487
Symbol 457 TextUses:115Used by:487
Symbol 458 TextUses:115Used by:487
Symbol 459 EditableTextUses:115Used by:487
Symbol 460 GraphicUsed by:461 469
Symbol 461 MovieClipUses:460Used by:469
Symbol 462 GraphicUsed by:463 469
Symbol 463 MovieClipUses:462Used by:464
Symbol 464 MovieClip {Plod_fla.gamezhero_z_2_161}Uses:463Used by:469
Symbol 465 GraphicUsed by:468 469
Symbol 466 ShapeTweeningUsed by:468 469
Symbol 467 GraphicUsed by:468
Symbol 468 MovieClipUses:465 466 467Used by:469
Symbol 469 ButtonUses:461 464 468 460 462 465 466Used by:487 491 496 548 556
Symbol 470 TextUses:250Used by:487
Symbol 471 TextUses:250Used by:486
Symbol 472 TextUses:250Used by:486
Symbol 473 TextUses:250Used by:486
Symbol 474 TextUses:250Used by:486
Symbol 475 TextUses:250Used by:486
Symbol 476 TextUses:250Used by:486
Symbol 477 TextUses:250Used by:486
Symbol 478 TextUses:250Used by:486
Symbol 479 TextUses:250Used by:486
Symbol 480 TextUses:250Used by:486
Symbol 481 TextUses:250Used by:486
Symbol 482 TextUses:250Used by:486
Symbol 483 TextUses:250Used by:486
Symbol 484 TextUses:250Used by:486
Symbol 485 TextUses:250Used by:486
Symbol 486 MovieClipUses:471 472 473 474 475 476 477 478 479 480 481 482 483 484 485Used by:487
Symbol 487 MovieClip {GameIntro_}Uses:423 119 211 425 427 429 431 433 435 437 234 438 192 440 442 393 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 324 326 328 330 332 334 336 338 340 342 344 346 348 350 352 354 469 470 412 216 224 214 228 230 232 486Used by:584
Symbol 488 EditableTextUses:115 250Used by:491
Symbol 489 TextUses:115Used by:491
Symbol 490 TextUses:115Used by:491
Symbol 491 MovieClip {GameLose_}Uses:423 119 275 417 406 410 488 489 490 469Used by:584
Symbol 492 EditableTextUses:115 250Used by:496
Symbol 493 TextUses:115Used by:496
Symbol 494 TextUses:115Used by:496
Symbol 495 TextUses:115Used by:496
Symbol 496 MovieClip {GameWin_}Uses:423 119 275 406 410 417 492 493 494 211 425 427 429 431 433 435 437 234 438 192 440 495 469Used by:584
Symbol 497 GraphicUsed by:548
Symbol 498 TextUses:115Used by:548
Symbol 499 TextUses:115Used by:548
Symbol 500 TextUses:115Used by:548
Symbol 501 TextUses:115Used by:548
Symbol 502 TextUses:115Used by:548
Symbol 503 GraphicUsed by:548
Symbol 504 GraphicUsed by:548
Symbol 505 GraphicUsed by:548
Symbol 506 GraphicUsed by:548
Symbol 507 TextUses:239Used by:548
Symbol 508 TextUses:115Used by:548
Symbol 509 TextUses:115Used by:548
Symbol 510 TextUses:115Used by:548
Symbol 511 FontUsed by:512
Symbol 512 TextUses:511Used by:548
Symbol 513 GraphicUsed by:514
Symbol 514 MovieClipUses:513Used by:548 583
Symbol 515 GraphicUsed by:516
Symbol 516 MovieClipUses:515Used by:548 583
Symbol 517 GraphicUsed by:518
Symbol 518 MovieClipUses:517Used by:548 583
Symbol 519 GraphicUsed by:520
Symbol 520 MovieClipUses:519Used by:548 583
Symbol 521 GraphicUsed by:522
Symbol 522 MovieClipUses:521Used by:548 583
Symbol 523 GraphicUsed by:524
Symbol 524 MovieClipUses:523Used by:548 583
Symbol 525 GraphicUsed by:526
Symbol 526 MovieClipUses:525Used by:548 583
Symbol 527 GraphicUsed by:528
Symbol 528 MovieClipUses:527Used by:548 583
Symbol 529 GraphicUsed by:548 583
Symbol 530 GraphicUsed by:531
Symbol 531 MovieClipUses:530Used by:548 583
Symbol 532 GraphicUsed by:533
Symbol 533 MovieClipUses:532Used by:548 583
Symbol 534 GraphicUsed by:535
Symbol 535 MovieClipUses:534Used by:548 583
Symbol 536 GraphicUsed by:537
Symbol 537 MovieClipUses:536Used by:548 583
Symbol 538 GraphicUsed by:539
Symbol 539 MovieClipUses:538Used by:548 583
Symbol 540 GraphicUsed by:541
Symbol 541 MovieClipUses:540Used by:548 583
Symbol 542 GraphicUsed by:543
Symbol 543 MovieClipUses:542Used by:548 583
Symbol 544 GraphicUsed by:545
Symbol 545 MovieClipUses:544Used by:548 583
Symbol 546 GraphicUsed by:547
Symbol 547 MovieClipUses:546Used by:548 583
Symbol 548 MovieClip {Instructions_}Uses:497 119 211 406 415 469 498 156 499 500 501 502 238 503 504 505 240 506 507 508 509 510 512 261 263 265 267 199 514 516 518 520 522 524 526 528 529 531 533 535 537 539 541 543 545 547 173 297 259Used by:584
Symbol 549 EditableTextUses:115 250Used by:556
Symbol 550 TextUses:115Used by:556
Symbol 551 EditableTextUses:115 250Used by:556
Symbol 552 TextUses:115Used by:556
Symbol 553 EditableTextUses:115 250Used by:556
Symbol 554 TextUses:115Used by:556
Symbol 555 TextUses:115Used by:556
Symbol 556 MovieClip {TallyScore}Uses:423 119 549 408 550 551 552 553 554 216 192 224 214 228 230 232 234 555 469Used by:584
Symbol 557 TextUses:115Used by:560
Symbol 558 GraphicUsed by:559
Symbol 559 MovieClipUses:558Used by:560
Symbol 560 MovieClip {TimeUpPopUp}Uses:211 557 150 152 154 425 427 429 559 433 435 437 234 438 192 440Used by:584
Symbol 561 GraphicUsed by:564
Symbol 562 ShapeTweeningUsed by:564
Symbol 563 GraphicUsed by:564
Symbol 564 MovieClipUses:561 174 181 186 199 202 203 562 358 290 297 302 259 305 563Used by:582
Symbol 565 GraphicUsed by:566
Symbol 566 MovieClipUses:565Used by:567
Symbol 567 MovieClipUses:566 176 178 180 161 201 163 165 183 188 190 192 194 196 198 185 167 169 171 173 356 358 360 362 287 292 294 289 299 304 301 216 224 214 228 230 232 234 296Used by:582
Symbol 568 GraphicUsed by:569
Symbol 569 MovieClipUses:568Used by:582
Symbol 570 FontUsed by:571
Symbol 571 TextUses:570Used by:574
Symbol 572 FontUsed by:573
Symbol 573 TextUses:572Used by:574
Symbol 574 MovieClipUses:571 573Used by:582
Symbol 575 GraphicUsed by:580
Symbol 576 GraphicUsed by:580
Symbol 577 GraphicUsed by:578 580
Symbol 578 MovieClipUses:577Used by:580
Symbol 579 GraphicUsed by:580
Symbol 580 ButtonUses:575 576 578 579 577Used by:582
Symbol 581 TextUses:115Used by:582
Symbol 582 MovieClip {TitleScreen}Uses:423 119 564 567 569 415 397 395 275 574 580 272 581 117Used by:584
Symbol 583 MovieClip {Objects}Uses:261 263 265 267 514 516 518 520 522 524 526 528 529 531 533 535 537 539 541 543 545 547 173Used by:584
Symbol 584 MovieClip {Plod_fla.clips_3}Uses:139 140 159 209 243 246 285 315 320 324 326 328 330 332 334 336 338 340 342 344 346 348 350 352 354 393 395 397 401 404 406 279 408 257 275 277 410 281 412 415 417 284 419 422 487 491 496 548 283 556 560 582 583Used by:Timeline

Instance Names

"clip"Symbol 209 MovieClip {Burglar} Frame 3Symbol 206 MovieClip
"clip"Symbol 209 MovieClip {Burglar} Frame 4Symbol 208 MovieClip
"shard"Symbol 246 MovieClip {CrateShard} Frame 1Symbol 245 MovieClip
"txt"Symbol 279 MovieClip {btn_music_} Frame 1Symbol 278 EditableText
"moreGamesBtn"Symbol 283 MovieClip {PausedScreen_} Frame 1Symbol 275 MovieClip {btn_playmore_}
"btn_quit"Symbol 283 MovieClip {PausedScreen_} Frame 1Symbol 277 MovieClip {btn_quit_}
"btn_music"Symbol 283 MovieClip {PausedScreen_} Frame 1Symbol 279 MovieClip {btn_music_}
"btn_resume"Symbol 283 MovieClip {PausedScreen_} Frame 1Symbol 281 MovieClip {btn_reume_}
"score_txt"Symbol 284 MovieClip {Hud} Frame 1Symbol 251 EditableText
"stars_txt"Symbol 284 MovieClip {Hud} Frame 1Symbol 252 EditableText
"cupcakes_txt"Symbol 284 MovieClip {Hud} Frame 1Symbol 253 EditableText
"lives_txt"Symbol 284 MovieClip {Hud} Frame 1Symbol 254 EditableText
"time_txt"Symbol 284 MovieClip {Hud} Frame 1Symbol 255 EditableText
"btn_pause"Symbol 284 MovieClip {Hud} Frame 1Symbol 257 MovieClip {btn_pausegame_}
"level_txt"Symbol 284 MovieClip {Hud} Frame 1Symbol 268 EditableText
"score_txt"Symbol 284 MovieClip {Hud} Frame 1Symbol 270 EditableText
"gamezheroBtn1"Symbol 284 MovieClip {Hud} Frame 1Symbol 272 Button
"pausedScreen"Symbol 284 MovieClip {Hud} Frame 1Symbol 283 MovieClip {PausedScreen_}
"hud"Symbol 285 MovieClip {GameFrameWork_} Frame 1Symbol 284 MovieClip {Hud}
"clipo"Symbol 315 MovieClip {Plod} Frame 10Symbol 314 MovieClip {Plod_fla.plod_swinging_94}
"shard"Symbol 320 MovieClip {Puff} Frame 1Symbol 319 MovieClip
"txt"Symbol 419 MovieClip {LevelPopUp_} Frame 1Symbol 418 EditableText
"score_txt"Symbol 422 MovieClip {ScorePopUp} Frame 1Symbol 421 EditableText
"brick1"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick2"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick3"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick4"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick5"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick6"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick7"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick8"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick9"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick10"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick11"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick12"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick13"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick14"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick15"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"brick16"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 393 MovieClip {TilesMc}
"level_txt"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 459 EditableText
"s1"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 324 MovieClip {s1s}
"s2"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 326 MovieClip {s2s}
"s3"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 328 MovieClip {s3s}
"s4"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 330 MovieClip {s4a}
"s5"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 332 MovieClip {s5a}
"s6"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 334 MovieClip {s6s}
"s7"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 336 MovieClip {s7a}
"s8"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 338 MovieClip {s8a}
"s9"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 340 MovieClip {s9s}
"s10"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 342 MovieClip {s10s}
"s11"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 344 MovieClip {s11s}
"s12"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 346 MovieClip {s12a}
"s13"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 348 MovieClip {s13a}
"s14"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 350 MovieClip {s14s}
"s15"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 352 MovieClip {s15s}
"s16"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 354 MovieClip {s16a}
"gamezheroBtn2"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 469 Button
"btn_next"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 412 MovieClip {btn_righto_}
"chiefText"Symbol 487 MovieClip {GameIntro_} Frame 1Symbol 486 MovieClip
"moreGamesBtn"Symbol 491 MovieClip {GameLose_} Frame 1Symbol 275 MovieClip {btn_playmore_}
"btn_submitscore"Symbol 491 MovieClip {GameLose_} Frame 1Symbol 417 MovieClip {btn_submitscore_}
"btn_mainMenu"Symbol 491 MovieClip {GameLose_} Frame 1Symbol 406 MovieClip {btn_mainMenu_}
"btn_replay"Symbol 491 MovieClip {GameLose_} Frame 1Symbol 410 MovieClip {btn_replay_}
"score_txt"Symbol 491 MovieClip {GameLose_} Frame 1Symbol 488 EditableText
"gamezheroBtn2"Symbol 491 MovieClip {GameLose_} Frame 1Symbol 469 Button
"moreGamesBtn"Symbol 496 MovieClip {GameWin_} Frame 1Symbol 275 MovieClip {btn_playmore_}
"btn_mainMenu"Symbol 496 MovieClip {GameWin_} Frame 1Symbol 406 MovieClip {btn_mainMenu_}
"btn_replay"Symbol 496 MovieClip {GameWin_} Frame 1Symbol 410 MovieClip {btn_replay_}
"btn_submitscore"Symbol 496 MovieClip {GameWin_} Frame 1Symbol 417 MovieClip {btn_submitscore_}
"score_txt"Symbol 496 MovieClip {GameWin_} Frame 1Symbol 492 EditableText
"gamezheroBtn2"Symbol 496 MovieClip {GameWin_} Frame 1Symbol 469 Button
"btn_mainMenu"Symbol 548 MovieClip {Instructions_} Frame 1Symbol 406 MovieClip {btn_mainMenu_}
"btn_start"Symbol 548 MovieClip {Instructions_} Frame 1Symbol 415 MovieClip {btn_startGame}
"gamezheroBtn2"Symbol 548 MovieClip {Instructions_} Frame 1Symbol 469 Button
"score_txt"Symbol 556 MovieClip {TallyScore} Frame 1Symbol 549 EditableText
"btn_next"Symbol 556 MovieClip {TallyScore} Frame 1Symbol 408 MovieClip {Btn_next}
"time_txt"Symbol 556 MovieClip {TallyScore} Frame 1Symbol 551 EditableText
"star_txt"Symbol 556 MovieClip {TallyScore} Frame 1Symbol 553 EditableText
"gamezheroBtn2"Symbol 556 MovieClip {TallyScore} Frame 1Symbol 469 Button
"titleAnim"Symbol 582 MovieClip {TitleScreen} Frame 1Symbol 564 MovieClip
"btn_bythistler"Symbol 582 MovieClip {TitleScreen} Frame 1Symbol 569 MovieClip
"btn_startGame_"Symbol 582 MovieClip {TitleScreen} Frame 1Symbol 415 MovieClip {btn_startGame}
"btn_instructions"Symbol 582 MovieClip {TitleScreen} Frame 1Symbol 397 MovieClip {btn_instructions_}
"topScoreBtn"Symbol 582 MovieClip {TitleScreen} Frame 1Symbol 395 MovieClip {btn_highscores_}
"moreGamesBtn"Symbol 582 MovieClip {TitleScreen} Frame 1Symbol 275 MovieClip {btn_playmore_}
"publishBtn"Symbol 582 MovieClip {TitleScreen} Frame 1Symbol 580 Button
"gamezheroBtn1"Symbol 582 MovieClip {TitleScreen} Frame 1Symbol 272 Button
"sendToFriendsBtn"Symbol 582 MovieClip {TitleScreen} Frame 1Symbol 117 MovieClip {btn_sendtofriends_}

Special Tags

FileAttributes (69)Timeline Frame 1Access local files only, Metadata not present, AS3.
Protect (24)Timeline Frame 131 bytes "..$1$dz$hX8EkTwNiKGePWBq.QGOc.."
EnableDebugger2 (64)Timeline Frame 131 bytes "..$1$2W$9WePXMfU4AYViIxn9faI1.."

Labels

"gameplay"Frame 3
"bang"Symbol 159 MovieClip {BombClip} Frame 2
"start"Symbol 206 MovieClip Frame 1
"end"Symbol 206 MovieClip Frame 7
"dsf"Symbol 206 MovieClip Frame 8
"dcf"Symbol 314 MovieClip {Plod_fla.plod_swinging_94} Frame 1
"ende"Symbol 314 MovieClip {Plod_fla.plod_swinging_94} Frame 9




http://swfchan.com/25/124748/info.shtml
Created: 1/3 -2019 02:32:36 Last modified: 1/3 -2019 02:32:36 Server time: 26/04 -2024 10:27:03