Section 1
//Cookie (code.data.Cookie)
package code.data {
import flash.net.*;
import code.logic.*;
public class Cookie {
private const id:String = "Develish_Stylist";
private static var so:SharedObject;
public static var da:Object;
public function Cookie():void{
super();
initSo();
initData();
}
private function initData():void{
var temp:Array;
var Achievement:Object;
da = so.data;
if (da["help"] == null){
da["help"] = true;
};
if (da["Levelarr"] == null){
trace("初始化Cookie数据");
temp = new Array({cup:PlayerStar.NoStar.value, level:PlayerStar.BronzeStar.value}, {cup:PlayerStar.WinStar.value, level:PlayerStar.BronzeStar.value}, {cup:PlayerStar.WinStar.value, level:PlayerStar.BronzeStar.value}, {cup:PlayerStar.WinStar.value, level:PlayerStar.BronzeStar.value}, {cup:PlayerStar.WinStar.value, level:PlayerStar.BronzeStar.value}, {cup:PlayerStar.WinStar.value, level:PlayerStar.BronzeStar.value}, {cup:PlayerStar.WinStar.value, level:PlayerStar.BronzeStar.value}, {cup:PlayerStar.WinStar.value, level:PlayerStar.BronzeStar.value}, {cup:PlayerStar.WinStar.value, level:PlayerStar.BronzeStar.value}, {cup:PlayerStar.WinStar.value, level:PlayerStar.BronzeStar.value});
da["Levelarr"] = temp;
};
if (da["Achievement"] == null){
Achievement = {DogLover:[true, "DogLover"], CatLover:[true, "CatLover"], DevilNovice:[true, "DevilNovice"], WannabeAngel:[true, "WannabeAngel"], SuperDevil:[true, "SuperDevil"]};
da["Achievement"] = Achievement;
};
if (da["CurrLevel"] == null){
da["CurrLevel"] = 0;
};
if (da["effect"] == null){
da["effect"] = true;
};
if (da["endGame"] == null){
da["endGame"] = false;
};
}
private function initSo():void{
so = SharedObject.getLocal(id, "/");
}
public function del():void{
so.close();
}
public static function flush():void{
so.flush();
}
}
}//package code.data
Section 2
//CountryCookie (code.data.CountryCookie)
package code.data {
import flash.net.*;
public class CountryCookie {
private static const countryName:String = "savedLang";
private static const name:String = "spilgames_language_v100";
public static const nameGroup:Array = ["en_us", "cn", "nl", "fr", "de", "pl", "se", "it", "es", "br", "id", "ru", "en_uk", "tr", "my", "pt", "jp", "ar"];
private static var so:SharedObject;
public function CountryCookie():void{
super();
so = SharedObject.getLocal(name, "/");
}
private static function mathCountryNameToLanguagerNum(name:String):int{
var num:int = nameGroup.indexOf(name);
if (num == -1){
return (1);
};
return ((num + 1));
}
public static function set country(_value:int):void{
so.data[countryName] = mathLanguagerNumToCountryName(_value);
}
private static function mathLanguagerNumToCountryName(num:int):String{
if ((((num < 1)) || ((num > nameGroup.length)))){
return ("en_us");
};
return (nameGroup[(num - 1)]);
}
public static function get country():int{
if (so.data[countryName] == null){
return (1);
};
return (mathCountryNameToLanguagerNum(so.data[countryName]));
}
}
}//package code.data
Section 3
//Data (code.data.Data)
package code.data {
public class Data {
public static const Hair:String = "hair";
public static const LevelMaxNum:int = 10;
public static const AngerActionSplashwashArr:Array = new Array("splashwash");
public static const AngerActionmagazinesArr:Array = new Array("magazines_1", "magazines_2", "magazines_3", "magazines_4", "magazines_5");
public static const LevelFaildMC1:String = "BeCatchMC";
public static const LevelFaildMC2:String = "TimeOverMC";
public static const AngerActionArr:Array = new Array(Phone, Magazines, Coffee, Hair, Scissors, Splashwash);
public static const LevelWarnMC:String = "POPMC";
public static const AngleActionTurnHeadOdds:Number = 0.15;
public static const DevilSuperStateHappenSeatMaxLengthToEnd:Number = 0.05;
public static const MainMC:String = "MainMC";
public static const AngerActionPhoneArr:Array = new Array("phone_1", "phone_2", "phone_3", "phone_4", "phone_5", "phone_6", "phone_7");
public static const AngleActionMinTime:Number = 3;
public static const Scissors:String = "scissors";
public static const Magazines:String = "magazines";
public static const AngleThinKAndToDoOdds:Number = 0.85;
public static const isProtect:Boolean = false;
public static const AngleSuperStateHappenSeatMaxLengthToEnd:Number = 0.8;
public static const Phone:String = "phone";
public static const AngleActionMaxTime:Number = 10;
public static const MenuMC:String = "MenuMC";
public static const NPGArr:Array = new Array("CuteSchoolKid", "GothicBoy", "TeenageGirl", "Sweet16Girl", "Toddler", "ToughAfroGuy", "Motherwithbaby", "NerdMan", "BusinessWoman", "OldLady");
public static const AngleSuperStateEffectLength:Number = 1;
public static const AngerActionCutHairArr:Array = new Array("hair_1", "hair_2");
public static const stageWidth:Number = 660;
public static const LostGameMC:String = "";
public static const AngleFakeTurnHeadDoOdds:Number = 0.02;
public static const LevelPreMC:String = "";
public static const HowToPlayMC:String = "HowToPlayMC";
public static const DevilSuperSpeed:Number = 1;
public static const AngerActionScissorsArr:Array = new Array("scissors");
public static const CreditsMC:String = "CreditsMC";
public static const AngerActioncoffeeArr:Array = new Array("coffee_01", "coffee_02", "coffee_03", "coffee_04");
public static const AchiMC:String = "AchievementMC";
public static const AngleSuperSpeed:Number = 0.6;
public static const DevilNormalSpeed:Number = 0.5;
public static const AngleCutHaitMinTime:Number = 1;
public static const AngleSuperStateOdds:Number = 0.1;
public static const Splashwash:String = "splashwash";
public static const logoArr:Array = new Array("controlListMC_levelMap_logo", "controlListMC_Main_logo", "controlListMC_LevelPass_logo", "controlListMC_TimerOver_logo", "controlListMC_BeCatch_logo", "controlListMC_Transition_logo", "controlListMC_Achievement_logo", "controlListMC_Credit_logo");
public static const AngleCutHaitMaxTime:Number = 2;
public static const stageHeight:Number = 480;
public static const loadingMC:String = "LoadingMC";
public static const isTest:Boolean = false;
public static const WinGameMC:String = "";
public static const LevelPassMC:String = "LevelCompleteMC";
public static const Coffee:String = "coffee";
public static const AngleNormalSpeed:Number = 0.2;
public static const LevelMapMC:String = "LevelmapMC";
public static const SetAsAvatarMC:String = "UI_set_loading";
public static const FpsNum:int = 30;
public static const HairArr:Array = new Array("hair", "scissors", "splashwash");
public static var pash:Boolean = true;
public static var MusicEable:Boolean = true;
public static var debug:Boolean = false;
public static var HasNewAchievement:Boolean = false;
public static var SoundEable:Boolean = true;
public static var QualityType:Number = 1;
public static var DevilCatchNum:int = 0;
public static var googleIsShow:Boolean = false;
public static var LevelCurrNum:int;
public function Data(){
super();
}
}
}//package code.data
Section 4
//Action (code.logic.Action)
package code.logic {
import flash.display.*;
import code.tool.*;
import code.data.*;
public class Action {
public function Action(){
super();
}
private function getRadomActionList(mc:MovieClip, action:String, time:int):Object{
var label:FrameLabel;
var index:int;
var lableName:String;
var i:int;
var nextLabel:FrameLabel;
var currframeNum:int;
var tempArr:Array = new Array();
var actionList:Array = getActionList(action);
var labels:Array = mc.currentLabels;
var count:int;
var begian:int = getBegian(action);
while (time > count) {
index = Math.floor((Math.random() * actionList.length));
lableName = actionList[index];
i = begian;
while (i < labels.length) {
label = labels[i];
if (lableName == label.name){
if (lableName == Data.Scissors){
count = (count + 68);
} else {
if (lableName == Data.Splashwash){
count = (count + 40);
} else {
nextLabel = labels[(i + 1)];
currframeNum = (nextLabel.frame - label.frame);
count = (count + currframeNum);
};
};
tempArr.push(label);
break;
};
i++;
};
};
return ({Action:action, ActionList:tempArr, Time:count});
}
public function Angel(angle:Angle, bar:MyselfMC, action:String=null):Object{
var arr:Array = offsetProbability(bar.currFrame, bar.totalFrame);
if (action == null){
action = radomAction(arr);
};
var time:int = actionTime(action);
var obj:Object = getRadomActionList(angle.display, action, time);
return (obj);
}
private function offsetProbability(min:int, max:int):Array{
var pre:Number = (min / max);
var currCutHairAction:String = Data.HairArr[int((Math.random() * Data.HairArr.length))];
return (Probability.offsetProbability(currCutHairAction, int((Data.LevelCurrNum * pre)), Data.AngerActionArr));
}
private function actionTime(action:String, offset:Number=1):int{
var min = 2;
var max:int = (Data.AngleActionMaxTime * offset);
if ((((((action == Data.Scissors)) || ((action == Data.Hair)))) || ((action == Data.Splashwash)))){
min = Data.AngleCutHaitMinTime;
max = Data.AngleCutHaitMaxTime;
} else {
min = Data.AngleActionMinTime;
max = Data.AngleActionMaxTime;
};
var minus:int = Math.abs(((max - min) + 1));
var num:int = (Math.floor((Math.random() * minus)) + min);
return ((num * Data.FpsNum));
}
public function AngelFly(mc:MovieClip, currLableName:String, count:int=1):Object{
var label:FrameLabel;
var j:int;
var labels:Array = mc.currentLabels;
var len:int = labels.length;
var tempArr:Array = [];
tempArr.push(getLabel("surprise", labels));
var i:int = (len - 1);
while (i > 0) {
label = labels[i];
if (label.name == currLableName){
j = 0;
while (j < count) {
tempArr.push(label);
j++;
};
return ({Action:Data.Scissors, ActionList:tempArr, Time:count});
};
i--;
};
return ({Action:Data.Scissors, ActionList:tempArr, Time:count});
}
public function devil():void{
}
private function radomAction(actionArr:Array):String{
var index:int = Math.floor((Math.random() * actionArr.length));
return (actionArr[index]);
}
private function getActionList(action:String):Array{
var tempArr:Array;
switch (action){
case Data.Phone:
tempArr = Data.AngerActionPhoneArr.concat();
break;
case Data.Magazines:
tempArr = Data.AngerActionmagazinesArr.concat();
break;
case Data.Coffee:
tempArr = Data.AngerActioncoffeeArr.concat();
break;
case Data.Hair:
tempArr = Data.AngerActionCutHairArr.concat();
break;
case Data.Scissors:
tempArr = Data.AngerActionScissorsArr.concat();
break;
case Data.Splashwash:
tempArr = Data.AngerActionSplashwashArr.concat();
break;
default:
tempArr = new Array();
};
return (tempArr);
}
private function getLabel(labelName:String, labels:Array):FrameLabel{
var label:FrameLabel;
var i:int;
while (i < labels.length) {
label = labels[i];
if (labelName == label.name){
return (label);
};
i++;
};
return (null);
}
private function getBegian(action:String):int{
var i:int;
switch (action){
case Data.Phone:
i = 0;
break;
case Data.Coffee:
i = (Data.AngerActionPhoneArr.length - 1);
break;
case Data.Magazines:
i = ((Data.AngerActionPhoneArr.length + Data.AngerActioncoffeeArr.length) - 1);
break;
case Data.Hair:
i = (((Data.AngerActionPhoneArr.length + Data.AngerActioncoffeeArr.length) + Data.AngerActionmagazinesArr.length) - 1);
break;
case Data.Scissors:
i = (((Data.AngerActionPhoneArr.length + Data.AngerActioncoffeeArr.length) + Data.AngerActionmagazinesArr.length) + 7);
break;
case Data.Splashwash:
i = (((Data.AngerActionPhoneArr.length + Data.AngerActioncoffeeArr.length) + Data.AngerActionmagazinesArr.length) + 8);
break;
default:
i = 0;
};
return (i);
}
}
}//package code.logic
Section 5
//ActionPlay (code.logic.ActionPlay)
package code.logic {
import flash.display.*;
import code.tool.*;
import code.data.*;
public class ActionPlay {
private var _colsedEye:int;
private var _currlabel:FrameLabel;
private var _openEye:int;
private var _nextLabel:FrameLabel;
private var _actionAngleList:Array;
private var _isGo:Boolean;// = false
private var _angle:Angle;
private var _currLabelEndFram:int;
private var _main:MainLogic;
private var _labels:Array;
private var _currPlayNum:Number;
private var _start:Boolean;// = false
private var choosuond:ChooseSound;
private var _angleAction:String;
private var _startAngle:Boolean;// = false
private var _currSound:String;
public function ActionPlay(){
super();
}
private function getAngleTurnBack(actionAngle:String):FrameLabel{
var action:String;
var label:FrameLabel;
switch (actionAngle){
case Data.Phone:
action = "tel_huitou";
break;
case Data.Magazines:
action = "book_huitou";
break;
case Data.Coffee:
action = "coffee_huitou";
break;
default:
action = MainLogic.currCutHairAction;
break;
};
var i:int;
while (i < _labels.length) {
label = _labels[i];
if (label.name == action){
return (label);
};
i++;
};
return (null);
}
public function step():void{
if (_start){
if (((_startAngle) && (!((_angle == null))))){
isAngle();
};
};
}
private function getNextLabel(currLable:FrameLabel):FrameLabel{
var label:FrameLabel;
var nextLabel:FrameLabel;
var i:int;
while (i < _labels.length) {
label = _labels[i];
if (currLable.name == label.name){
nextLabel = _labels[(i + 1)];
};
i++;
};
return (nextLabel);
}
private function AngleEndActionfun():void{
initAngle();
if (_isGo){
_main.start();
} else {
_main.angleCutHair();
};
}
public function clearFrameScript(frame:int=0):void{
if (frame == 0){
frame = (_angle.currentFrame - 1);
};
_angle.display.addFrameScript(frame, null);
}
private function fakeBack():void{
if (_currPlayNum < _actionAngleList.length){
start();
clearFrameScript();
} else {
AngleEndActionfun();
};
}
public function closeEyeTimefun():void{
_angle.display.gotoAndPlay(_openEye);
clearFrameScript();
}
private function isAngle():void{
player();
}
public function angelplay(main:MainLogic):void{
choosuond = new ChooseSound();
_main = main;
_angle = _main.angle;
_actionAngleList = _angle.action["ActionList"];
_angleAction = _angle.action["Action"];
if ((((((_angleAction == Data.Scissors)) || ((_angleAction == Data.Hair)))) || ((_angleAction == Data.Splashwash)))){
_angle.isCutHair = true;
_isGo = true;
} else {
_angle.isCutHair = false;
_isGo = false;
};
_currPlayNum = 0;
_labels = _angle.display.currentLabels;
_start = true;
_startAngle = true;
start();
}
private function start():void{
_currlabel = _actionAngleList[_currPlayNum];
if (_angle.display != null){
_angle.changeFace(_currlabel.name);
};
_nextLabel = getNextLabel(_currlabel);
_currPlayNum++;
_currLabelEndFram = MCPlayer.getCurrLabelFinalFrame(_angle.display, _currlabel.name);
var obj:Object = choosuond.check(_currlabel.name);
if (obj != null){
_currSound = obj["name"];
};
choosuond.play(_angle.display, obj);
}
private function initAngle():void{
_actionAngleList = new Array();
_angleAction = null;
_currlabel = null;
_nextLabel = null;
_start = false;
_startAngle = false;
clearFrameScript();
_angle = null;
}
private function onRandomBackFun():Boolean{
if (Math.random() < (Data.AngleFakeTurnHeadDoOdds + ((Math.sqrt((Data.LevelCurrNum / (Data.LevelMaxNum - 1))) / 10) * 7))){
return (false);
};
return (true);
}
private function player():void{
if (_angle.currentFrame == _currLabelEndFram){
if (_currSound != null){
SoundsManager.stopSound(_currSound);
};
if (_currPlayNum >= _actionAngleList.length){
AngleGotoBackfun(false);
} else {
if ((((((_angleAction == Data.Hair)) || ((_angleAction == Data.Scissors)))) || ((_angleAction == Data.Splashwash)))){
start();
} else {
if (Math.random() < ((Data.AngleActionTurnHeadOdds + ((Math.sqrt((Data.LevelCurrNum / (Data.LevelMaxNum - 1))) / 10) * 4)) + (_main.seat / 5))){
AngleGotoBackfun(true);
} else {
start();
};
};
};
};
}
private function AngleGotoBackfun(isRandomBack:Boolean=false):void{
var isActionOver:Boolean;
var label:FrameLabel = getAngleTurnBack(_angleAction);
_angle.changeFace(label.name);
_colsedEye = int((label.frame + 10));
_openEye = int(((_colsedEye + (5 * Main.lostFramePre)) + 2));
if (isRandomBack){
isActionOver = onRandomBackFun();
} else {
isActionOver = true;
};
if (isActionOver){
_angle.display.addFrameScript(_colsedEye, closeEyeTimefun);
_angle.display.addFrameScript((_colsedEye + 6), AngleEndActionfun);
} else {
_angle.display.addFrameScript((_colsedEye + 3), fakeBack);
};
}
}
}//package code.logic
Section 6
//Angle (code.logic.Angle)
package code.logic {
import flash.display.*;
import code.tool.*;
import code.data.*;
public class Angle extends Character {
private var _speed:Number;
private var _isthink:Boolean;
private var _action:Object;
public function Angle(){
super();
}
override public function stop():void{
super.stop();
if (display["cutMC"] != null){
(display["cutMC"] as MovieClip).stop();
};
}
public function step(prossBar:MyselfMC):void{
var offset:Number;
if (((isCutHair) && (!(_isthink)))){
if (display.currentLabel == "hairfly"){
_speed = -(Data.AngleSuperSpeed);
} else {
_speed = -(Data.AngleNormalSpeed);
};
offset = (prossBar.barCurrFrame / prossBar.totalFrame);
prossBar.barCurrFrame = (prossBar.barCurrFrame + (_speed * offset));
prossBar.jumpFrame();
};
}
public function get isthink():Boolean{
return (_isthink);
}
override public function play():void{
super.play();
if (display["cutMC"] != null){
(display["cutMC"] as MovieClip).play();
};
if (_isthink){
think();
};
}
public function get action():Object{
return (_action);
}
public function set isthink(bool:Boolean):void{
_isthink = bool;
}
public function think():void{
this.changeFace("think");
display.addFrameScript(MCPlayer.getCurrLabelBegianFrame(display, "think"), changeMindFun);
}
public function set action(obj:Object):void{
_action = obj;
}
private function changeMindFun():void{
var mc:MovieClip = (display.getChildByName("managerMC") as MovieClip);
switch (action["Action"]){
case Data.Phone:
mc.gotoAndStop(1);
break;
case Data.Magazines:
mc.gotoAndStop(2);
break;
default:
mc.gotoAndStop(3);
};
}
}
}//package code.logic
Section 7
//Character (code.logic.Character)
package code.logic {
import flash.display.*;
import flash.utils.*;
import code.tool.*;
public class Character {
private var __display:MovieClip;
private var _isCuthair:Boolean;
public function Character():void{
super();
}
public function setDisplay(mc:MovieClip):void{
display = mc;
if (getQualifiedClassName(this) == "code.logic::Character"){
display.addFrameScript((MCPlayer.getCurrLabelBegianFrame(display, "devil") - 2), rePalyFun);
display.addFrameScript(112, clondFun);
display.addFrameScript((display.totalFrames - 1), stopDevilFun);
};
}
public function get currentFrame():int{
return (display.currentFrame);
}
public function stop():void{
var mc:MovieClip;
display.stop();
var i:int = (display.numChildren - 1);
while (i > 0) {
mc = (display.getChildAt(i) as MovieClip);
if (mc != null){
mc.stop();
};
i--;
};
}
private function clondFun():void{
var mc:MovieClip;
var i:Number = 1;
while (i < 4) {
mc = (display.getChildByName(("clound" + i)) as MovieClip);
if (mc != null){
mc.visible = false;
};
i++;
};
}
public function get totalFrames():int{
return (display.totalFrames);
}
public function del():void{
if (__display != null){
__display.parent.removeChild(__display);
__display = null;
};
}
public function set isCutHair(bool:Boolean):void{
_isCuthair = bool;
}
public function changeFace(frame:Object, isPlay:Boolean=true):void{
if (__display != null){
if (isPlay){
__display.gotoAndPlay(frame);
} else {
__display.gotoAndStop(frame);
};
} else {
trace(("Null" + frame));
};
}
private function rePalyFun():void{
display.gotoAndPlay(1);
}
private function stopDevilFun():void{
display.stop();
}
public function get display():MovieClip{
return (__display);
}
public function play():void{
var mc:MovieClip;
display.play();
var i:int = (display.numChildren - 1);
while (i > 0) {
mc = (display.getChildAt(i) as MovieClip);
if (((!((mc == null))) && (!((mc.name == "managerMC"))))){
mc.play();
};
i--;
};
}
public function get isCutHair():Boolean{
return (_isCuthair);
}
public function set display(mc:MovieClip):void{
__display = mc;
}
}
}//package code.logic
Section 8
//ChooseSound (code.logic.ChooseSound)
package code.logic {
import flash.display.*;
import code.tool.*;
public class ChooseSound {
public function ChooseSound(){
super();
}
public function check(labelName:String):Object{
var sound:Object;
if (labelName == "hair1"){
sound = "";
};
trace((labelName + " 当前播放动作的声音"));
switch (labelName){
case "hair_1":
sound = {name:"rules", seatArr:[783]};
break;
case "scissors":
sound = {name:"scissors", seatArr:[1294, 1322, 1346]};
break;
case "splashwash":
sound = {name:"splashwash", seatArr:[1357, 1370, 1386]};
break;
case "hair_2":
sound = {name:("whistle" + Math.floor((Math.random() * 3))), seatArr:null, start:825, end:891};
break;
case "coffee_01":
sound = {name:"churnUp", seatArr:[350]};
break;
case "coffee_02":
sound = {name:"churnUp", seatArr:[393]};
break;
case "coffee_04":
sound = {name:"sweet", seatArr:[474, 482, 490]};
break;
case "magazines_2":
sound = {name:"chuckBook", seatArr:[582, 615, 490]};
break;
case "magazines_5":
sound = {name:"chuckBook", seatArr:[746]};
break;
case "magazines_1":
sound = {name:"pickBook", seatArr:[498]};
break;
case "magazines_3":
sound = {name:"pickBook", seatArr:[633]};
break;
case "magazines_4":
sound = {name:"smail", seatArr:[716]};
break;
case "phone_1":
sound = {name:("talk" + Math.floor((Math.random() * 2))), seatArr:[1]};
break;
case "phone_2":
sound = {name:("talk" + Math.floor((Math.random() * 2))), seatArr:[91]};
break;
case "phone_3":
sound = {name:("talk" + Math.floor((Math.random() * 2))), seatArr:[136]};
break;
case "phone_4":
sound = {name:("fadie" + Math.floor((Math.random() * 3))), seatArr:[169]};
break;
case "phone_5":
sound = {name:("talk" + Math.floor((Math.random() * 2))), seatArr:[0x0101]};
break;
case "phone_6":
sound = {name:"smail", seatArr:[290]};
break;
case "phone_7":
sound = {name:("talk" + Math.floor((Math.random() * 2))), seatArr:[317]};
break;
case "hairfly":
sound = {name:"flyCutHair", seatArr:[1225]};
break;
default:
sound = null;
};
return (sound);
}
public function play(mc:MovieClip, sound:Object):void{
var seat:int;
var i:int;
if (sound == null){
return;
};
var seatArr:Array = sound["seatArr"];
var name:String = sound["name"];
if (mc != null){
if (seatArr == null){
mc.addFrameScript(sound["start"], startFun(name, mc));
} else {
i = 0;
while (i < seatArr.length) {
seat = seatArr[i];
mc.addFrameScript(seat, startFun(name, mc));
i++;
};
};
if (mc.currentLabel == "coffee_04"){
mc.addFrameScript(466, startFun("find", mc));
};
} else {
trace("this mc is null !");
};
}
private function startFun(name:String, mc:MovieClip):Function{
var fun:Function;
var name = name;
var mc = mc;
fun = function ():void{
SoundsManager.playSound(name);
mc.addFrameScript((mc.currentFrame - 1), null);
};
return (fun);
}
}
}//package code.logic
Section 9
//ControlList (code.logic.ControlList)
package code.logic {
import flash.display.*;
import flash.events.*;
import code.ui.*;
import code.tool.*;
import code.data.*;
public class ControlList extends UI {
private var _soundBtnOff:McButton;
private var _helpBtn:McButton;
private var _soundBtnOn:McButton;
private var _effectBtnSend:MovieClip;
private var _pashBtn:McButton;
private var _homeBtn:McButton;
public function ControlList(mc:Sprite, uim:UIManager=null, unactive:Boolean=true){
super(uim);
display = mc;
init();
if (unactive){
setBtnUnactive();
} else {
_homeBtn.visible = false;
if (display.name == "controlListMC_Main"){
};
};
checkSound();
displayLogo();
}
public function setAllBtnActiveeable(unactive:Boolean=true):void{
_helpBtn.unactive(unactive);
_pashBtn.unactive(unactive);
_homeBtn.unactive(unactive);
_soundBtnOn.unactive(unactive);
_soundBtnOff.unactive(unactive);
}
private function onMouseOverFun(e:MouseEvent):void{
if (((e.target as Sprite).parent as MovieClip).currentFrame != 4){
SoundsManager.playSound("menu_touch");
};
}
private function checkSound():void{
if (((Data.SoundEable) || (Data.MusicEable))){
_soundBtnOff.visible = false;
} else {
_soundBtnOn.visible = false;
};
}
override public function initEvent():void{
_soundBtnOn.addEventListener(MouseEvent.CLICK, onClickFun);
_soundBtnOff.addEventListener(MouseEvent.CLICK, onClickFun);
_pashBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_helpBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_homeBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_soundBtnOn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_soundBtnOff.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_pashBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_helpBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_homeBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
private function displayLogo():void{
var i:Number = 0;
while (i < Data.logoArr.length) {
display[Data.logoArr[i]].visible = false;
i++;
};
display[(display.name + "_logo")].visible = true;
}
private function onClickFun(e:MouseEvent):void{
if (((e.target as Sprite).parent as MovieClip).currentFrame != 4){
SoundsManager.playSound("menu_press");
};
if (e.target == _soundBtnOn.getChildByName("HitMC")){
Data.SoundEable = false;
Data.MusicEable = false;
SoundsManager.pause(true);
_soundBtnOn.visible = false;
_soundBtnOff.visible = true;
} else {
if (e.target == _soundBtnOff.getChildByName("HitMC")){
Data.SoundEable = true;
Data.MusicEable = true;
SoundsManager.pause(false);
_soundBtnOn.visible = true;
_soundBtnOff.visible = false;
} else {
if (e.target == _pashBtn.getChildByName("HitMC")){
display.dispatchEvent(new Event("Pash_ConTrolList"));
} else {
if (e.target == _helpBtn.getChildByName("HitMC")){
display.dispatchEvent(new Event("Help_ConTrolList"));
} else {
if (e.target == _homeBtn.getChildByName("HitMC")){
display.dispatchEvent(new Event("HomePage_ConTrolList"));
};
};
};
};
};
}
public function setEffectShow():void{
if (_effectBtnSend != null){
_effectBtnSend.visible = true;
};
}
override public function initMC():void{
_soundBtnOn = (display.getChildByName("soundBtn_on") as McButton);
_soundBtnOff = (display.getChildByName("soundBtn_off") as McButton);
_pashBtn = (display.getChildByName("pashBtn") as McButton);
_helpBtn = (display.getChildByName("helpBtn") as McButton);
_homeBtn = (display.getChildByName("homeBtn") as McButton);
}
private function setBtnUnactive():void{
if ((((((display.name == "controlListMC_TimerOver")) || ((display.name == "controlListMC_BeCatch")))) || ((display.name == "controlListMC_Achievement")))){
_pashBtn.visible = false;
} else {
_homeBtn.visible = false;
_pashBtn.unactive();
_pashBtn.buttonMode = false;
};
_helpBtn.unactive();
_helpBtn.buttonMode = false;
if (display.name == "controlListMC_levelMap"){
if ((((Data.LevelCurrNum < 1)) && (Cookie.da["effect"]))){
} else {
if ((((Cookie.da["Levelarr"][0]["cup"] > PlayerStar.NoStar.value)) && (Cookie.da["effect"]))){
};
};
};
}
override public function removeEvent():void{
_soundBtnOn.removeEventListener(MouseEvent.CLICK, onClickFun);
_soundBtnOff.removeEventListener(MouseEvent.CLICK, onClickFun);
_pashBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_helpBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_homeBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_soundBtnOn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_soundBtnOff.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_pashBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_helpBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_homeBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
}
}//package code.logic
Section 10
//Devil (code.logic.Devil)
package code.logic {
import flash.display.*;
import flash.events.*;
import code.tool.*;
import code.data.*;
public class Devil extends Character {
private var _smokeMC:Sprite;
private var _speed:Number;// = 1
private var _speedDevil:Number;
private var _currSpeed:Number;
public function Devil(){
super();
_speedDevil = Data.DevilNormalSpeed;
}
override public function setDisplay(mc:MovieClip):void{
super.setDisplay(mc);
}
public function initSeed():void{
_speedDevil = Data.DevilNormalSpeed;
}
public function removeSmoke():void{
if (_smokeMC != null){
if (display.parent.getChildIndex(_smokeMC) != -1){
_smokeMC.parent.removeChild(_smokeMC);
};
_smokeMC = null;
};
}
public function addSmoke(smokeName:String, x:int=0, y:int=0, seat:int=0):void{
if (((!((display == null))) && (!((display.parent == null))))){
if (_smokeMC == null){
_smokeMC = Attach.getSprite(smokeName);
};
_smokeMC.x = x;
_smokeMC.y = (y + 200);
display.parent.addChildAt(_smokeMC, seat);
};
}
private function checkSuperSate(prossBar:MovieClip):void{
var seat:int = int((prossBar.totalFrames * (1 - Data.DevilSuperStateHappenSeatMaxLengthToEnd)));
if (prossBar.currentFrame == seat){
SoundsManager.playSound("fullSate", true, int.MAX_VALUE);
_speedDevil = Data.DevilSuperSpeed;
this.display.dispatchEvent(new Event("AddSpeed"));
};
}
public function step(prossBar:MyselfMC, bg:MovieClip):void{
if (isCutHair){
checkSuperSate(bg);
_currSpeed = (_speed * _speedDevil);
prossBar.barCurrFrame = (prossBar.barCurrFrame + _currSpeed);
prossBar.jumpFrame();
};
}
public function get speed():Number{
return (((_currSpeed > 1)) ? _currSpeed : 1);
}
}
}//package code.logic
Section 11
//LManager (code.logic.LManager)
package code.logic {
import flash.events.*;
import zlong.spilSystemTool.*;
import code.ui.*;
import code.tool.*;
import code.data.*;
public class LManager {
private var _achievement:String;
private var _main:MainLogic;
private var _uim:UIManager;
public function LManager(uim:UIManager){
super();
_uim = uim;
init();
}
private function checkDog():Boolean{
if (Cookie.da["Levelarr"][0]["cup"] != PlayerStar.GoldStar.value){
return (false);
};
if (Cookie.da["Levelarr"][2]["cup"] != PlayerStar.GoldStar.value){
return (false);
};
if (Cookie.da["Levelarr"][3]["cup"] != PlayerStar.GoldStar.value){
return (false);
};
if (Cookie.da["Levelarr"][4]["cup"] != PlayerStar.GoldStar.value){
return (false);
};
if (Cookie.da["Levelarr"][6]["cup"] != PlayerStar.GoldStar.value){
return (false);
};
if (Cookie.da["Levelarr"][8]["cup"] != PlayerStar.GoldStar.value){
return (false);
};
if (Cookie.da["Levelarr"][9]["cup"] != PlayerStar.GoldStar.value){
return (false);
};
return (true);
}
public function start():void{
_uim.levelMap();
}
private function onCatchFun(e:Event):void{
endMain();
_uim.levelFaild(true);
}
private function CheckAllachievement():Boolean{
var i:*;
var temp:Array = new Array();
temp.push(Cookie.da["Achievement"]["CatLover"][0]);
temp.push(Cookie.da["Achievement"]["DogLover"][0]);
temp.push(Cookie.da["Achievement"]["DevilNovice"][0]);
temp.push(Cookie.da["Achievement"]["WannabeAngel"][0]);
for (i in temp) {
if (temp[i] == true){
return (false);
};
};
return (true);
}
private function onHelpFun(e:Event):void{
_uim.howToPlay(_main.pashFun);
}
private function checkAchievement():void{
_achievement = null;
if (Data.LevelCurrNum == 0){
if (Cookie.da["Achievement"]["DevilNovice"][0]){
trace("发送成就1");
Award_HighScore.instance.submitAchievement("award1");
Cookie.da["Achievement"]["DevilNovice"][0] = false;
};
};
if (Data.LevelCurrNum == 9){
trace(("Data.DevilCatchNum1: " + Data.DevilCatchNum));
if (Cookie.da["Achievement"]["WannabeAngel"][0]){
trace("发送成就WANNABEANGEL");
Award_HighScore.instance.submitAchievement("award2");
_achievement = "WannabeAngel";
Cookie.da["Achievement"]["WannabeAngel"][0] = false;
};
};
if (achievement(PlayerStar.GoldStar, 10)){
Tracker.end();
if (Cookie.da["Achievement"]["SuperDevil"][0]){
trace("发送成就SUPERDEVIL");
Award_HighScore.instance.submitAchievement("award5");
_achievement = "SuperDevil";
Cookie.da["Achievement"]["SuperDevil"][0] = false;
};
};
if (checkCat()){
if (Cookie.da["Achievement"]["CatLover"][0]){
trace("发送成就CATLOVER");
Award_HighScore.instance.submitAchievement("award4");
_achievement = "CatLover";
Cookie.da["Achievement"]["CatLover"][0] = false;
};
};
if (checkDog()){
if (Cookie.da["Achievement"]["DogLover"][0]){
trace("发送成就DOGLOVER");
Award_HighScore.instance.submitAchievement("award3");
_achievement = "DogLover";
Cookie.da["Achievement"]["DogLover"][0] = false;
};
};
trace(("Data.DevilCatchNum2: " + Data.DevilCatchNum));
}
public function playGameFun():void{
_main.playGameFun();
_main.start();
}
public function stopGameFun():void{
_main.stopGameFun();
}
private function onNoPassLevelFun(e:Event):void{
endMain();
_uim.levelFaild(false);
}
private function checkCat():Boolean{
if (Cookie.da["Levelarr"][1]["cup"] != PlayerStar.SilverStar.value){
return (false);
};
if (Cookie.da["Levelarr"][5]["cup"] != PlayerStar.SilverStar.value){
return (false);
};
if (Cookie.da["Levelarr"][7]["cup"] != PlayerStar.SilverStar.value){
return (false);
};
return (true);
}
public function reStart():void{
_uim.transition(_uim.delLevelFaild);
}
private function init():void{
Data.LevelCurrNum = Cookie.da["CurrLevel"];
start();
}
private function onPassLevelFun(e:Event):void{
var star:int = Cookie.da["Levelarr"][Data.LevelCurrNum]["cup"];
if (star < _main.star.value){
Cookie.da["Levelarr"][Data.LevelCurrNum]["cup"] = _main.star.value;
};
if (_main.star.value < PlayerStar.GoldStar.value){
Cookie.da["Levelarr"][Data.LevelCurrNum]["level"] = (_main.star.value + 1);
};
checkAchievement();
if (Data.LevelCurrNum == 0){
Tracker.level1();
};
Data.LevelCurrNum++;
if (Data.LevelCurrNum < Data.LevelMaxNum){
if (Cookie.da["CurrLevel"] < Data.LevelCurrNum){
Cookie.da["Levelarr"][Data.LevelCurrNum]["cup"] = PlayerStar.NoStar.value;
Cookie.da["CurrLevel"] = Data.LevelCurrNum;
};
Cookie.flush();
};
_uim.passLevel(_main.star, _achievement);
}
public function checkGameEnd():void{
if (CheckAllachievement()){
} else {
_uim.keepInGame();
};
}
private function achievement(star:PlayerStar, starNum:int=1):Boolean{
var starHas:int;
var count:int;
var i:int;
while (i < Cookie.da["Levelarr"].length) {
starHas = Cookie.da["Levelarr"][i]["cup"];
if (starHas >= star.value){
count++;
};
if (count == starNum){
return (true);
};
i++;
};
return (false);
}
public function main():void{
_main = new MainLogic(_uim.mc);
_main.display.addEventListener("Catch", onCatchFun);
_main.display.addEventListener("NoPassLevel", onNoPassLevelFun);
_main.display.addEventListener("PassLevel", onPassLevelFun);
_main.display.addEventListener("Help_Main", onHelpFun);
}
public function endMain():void{
_main.display.removeEventListener("Catch", onPassLevelFun);
_main.display.removeEventListener("NoPassLevel", onNoPassLevelFun);
_main.display.removeEventListener("PassLevel", onPassLevelFun);
_main.del();
_main = null;
}
public function initGameFun():void{
if (Cookie.da["help"]){
Cookie.da["help"] = false;
Cookie.flush();
_uim.howToPlay(playGameFun);
SoundsManager.playMusic("tutorial_music");
} else {
playGameFun();
};
}
}
}//package code.logic
Section 12
//MainLogic (code.logic.MainLogic)
package code.logic {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import code.tool.*;
import code.data.*;
public class MainLogic {
private var _timeText:TextField;
private var _level:String;
private var __Pmc:Sprite;
private var _controlBar:ControlList;
private var _actionPlayer:ActionPlay;
private var _timeOver:Boolean;
private var _angleActionTimeCount:Number;// = 0
private var _timeCount:int;
private var _angleCutHairTimeCount:Number;// = 0
private var _action:Action;
private var _guest:Character;
private var _angle:Angle;
private var _prossBar:MyselfMC;
private var _backGround:MovieClip;
private var _musicPosition:Number;// = 0
private var _hitMC:Sprite;
private var _pash:Boolean;
private var __mc:MovieClip;
private var _devil:Devil;
public static var currCutHairAction:String;
public static var currPre:Number;
public function MainLogic(Pmc:Sprite){
super();
__Pmc = Pmc;
init();
if (Data.isTest){
addTestFun();
};
playMusic();
}
private function onMouseUpFun(e:MouseEvent):void{
if (((((_pash) && (Data.pash))) && (!(_timeOver)))){
__mc.gotoAndStop(_level);
_devil.isCutHair = false;
_devil.changeFace("normal");
playMusic();
};
_devil.initSeed();
_devil.removeSmoke();
stopSpund();
}
private function offsetHairflyFun(seat:Number):Number{
if (seat < (Data.AngleSuperStateHappenSeatMaxLengthToEnd / 3)){
seat = 3;
} else {
if (seat < (Data.AngleSuperStateHappenSeatMaxLengthToEnd / 2)){
seat = 2;
} else {
if (seat < Data.AngleSuperStateHappenSeatMaxLengthToEnd){
seat = 1;
};
};
};
return ((Data.AngleSuperStateEffectLength * ((Math.random())<((Math.sqrt((Data.LevelCurrNum / (Data.LevelMaxNum - 1))) / 10) * 8)) ? 2 : 1));
}
private function initData():void{
Data.pash = true;
_pash = true;
_timeCount = ((1.5 * 60) * Data.FpsNum);
_actionPlayer = new ActionPlay();
_action = new Action();
}
public function del():void{
if (Data.isTest){
removeTestFun();
};
SoundsManager.memoryRelease();
Data.pash = false;
removeEvent();
removeMC();
}
private function getPre():Number{
var pre:Number;
var currLevel:int = Cookie.da["Levelarr"][Data.LevelCurrNum]["level"];
if (currLevel == PlayerStar.GoldStar.value){
pre = 0.6;
} else {
if (currLevel == PlayerStar.SilverStar.value){
pre = 0.8;
} else {
if (currLevel == PlayerStar.BronzeStar.value){
pre = 1;
} else {
pre = 0.6;
};
};
};
return (pre);
}
private function init():void{
initData();
initMC();
initEvent();
}
private function levelPassFun():void{
_angle.display.stop();
__mc.dispatchEvent(new Event("PassLevel"));
}
private function checkCatch():void{
if (((_angle.isCutHair) && (_devil.isCutHair))){
Data.DevilCatchNum++;
levelFaildAction();
SoundsManager.memoryRelease();
SoundsManager.playSound("angre");
SoundsManager.playSound("beCatch");
SoundsManager.playMusic("failed_music", 0);
};
}
public function get seat():Number{
return ((_prossBar.currFrame / _prossBar.totalFrame));
}
private function onMouseDownFun(e:MouseEvent):void{
if (((((_pash) && (Data.pash))) && (!(_timeOver)))){
__mc.gotoAndPlay(_level);
_devil.changeFace("cutsissiors");
_devil.isCutHair = true;
_devil.addSmoke("SmokeMC", _guest.display.x, (_guest.display.y - _guest.display.height), __mc.getChildIndex(_hitMC));
SoundsManager.playSound("devilCutHair", true, int.MAX_VALUE);
SoundsManager.playSound("damageup");
playMusic(true);
};
}
public function pashFun(bool:Boolean=true):void{
Data.pash = bool;
if (Data.pash){
playGameFun();
} else {
stopGameFun();
};
SoundsManager.pause(!(Data.pash));
}
private function removeMC():void{
__mc.parent.removeChild(__mc);
__mc = null;
}
private function stopSpund():void{
SoundsManager.stopSound("devilCutHair");
SoundsManager.stopSound("damageup");
SoundsManager.stopSound("fullSate");
}
private function onHelpFun(e:Event):void{
helpFun();
SoundsManager.playMusic("tutorial_music");
}
private function checkOppositeAction(currCutHairAction:String):void{
if (currCutHairAction == "hair"){
MainLogic.currCutHairAction = "hair_1";
} else {
MainLogic.currCutHairAction = currCutHairAction;
};
}
private function initMC():void{
var mc:MovieClip;
__mc = Attach.getMovieClip("MainMC");
__mc.stop();
__Pmc.addChild(__mc);
checkTarget();
_hitMC = (__mc.getChildByName("hitMC") as Sprite);
if (_hitMC == null){
creatHitMC();
};
mc = Attach.getMovieClip("angleMC");
mc.x = 520;
mc.y = 440;
__mc.addChildAt(mc, 0);
_angle = new Angle();
_angle.isCutHair = true;
_angle.setDisplay(mc);
_angle.changeFace("hair_1", false);
mc = Attach.getMovieClip("devilMC");
mc.x = 150;
mc.y = 430;
__mc.addChildAt(mc, 0);
_devil = new Devil();
_devil.isCutHair = false;
_devil.setDisplay(mc);
_devil.changeFace("normal");
mc = Attach.getMovieClip(Data.NPGArr[Data.LevelCurrNum]);
__mc.addChildAt(mc, 0);
mc.x = 330;
mc.y = 440;
_guest = new Character();
_guest.setDisplay(mc);
_backGround = Attach.getMovieClip("backGroundMC");
_backGround.name = "backGroundMC";
_backGround.stop();
__mc.addChildAt(_backGround, 0);
var contrlListMC:Sprite = (__mc.getChildByName("controlListMC_Main") as Sprite);
_controlBar = new ControlList(contrlListMC, null, false);
}
private function onEnterFrameFun(e:Event):void{
if (Data.pash){
step();
};
}
private function timeOverFun():void{
_prossBar.barCurrFrame--;
_prossBar.jumpFrame();
if (_prossBar.currFrame == 1){
_pash = false;
_timeOver = false;
__mc.dispatchEvent(new Event("NoPassLevel"));
};
}
private function checkTarget():void{
MainLogic.currPre = getPre();
switch (MainLogic.currPre){
case 0.6:
_level = "LV3";
break;
case 0.8:
_level = "LV2";
break;
case 1:
_level = "LV1";
break;
};
__mc.gotoAndStop(_level);
__mc.addFrameScript((MCPlayer.getCurrLabelBegianFrame(__mc, _level) - 1), initLevel);
}
private function onPashFun(e:Event):void{
Data.pash = !(Data.pash);
var mc:Sprite = Attach.getSprite("UIPAUSEMC");
mc.name = "pashMC";
__mc.addChild(mc);
mc.addEventListener(MouseEvent.CLICK, onClickPashMCFun);
pashFun(Data.pash);
}
private function addTestFun():void{
DebugTest.getoneDebugTest().init(__mc.stage, [32], new Array(levelPassAction));
}
private function levelFaildAction():void{
__mc.gotoAndStop(_level);
_pash = false;
_devil.removeSmoke();
_devil.changeFace("be catched");
_angle.changeFace("cought");
_guest.changeFace((MCPlayer.getCurrLabelBegianFrame(_guest.display, "devil") - 1), false);
var currLabelFinalframe:int = MCPlayer.getCurrLabelFinalFrame(_angle.display);
_angle.display.addFrameScript(currLabelFinalframe, catchFun);
MCPlayer.stopMC(_backGround);
}
private function timeOut():void{
var mc:MovieClip = (__mc.getChildByName("time") as MovieClip);
mc.stop();
__mc.gotoAndStop(_level);
_devil.changeFace("be catched");
_devil.removeSmoke();
_devil.isCutHair = false;
_angle.stop();
_guest.changeFace((MCPlayer.getCurrLabelBegianFrame(_guest.display, "devil") - 1), false);
_timeOver = true;
stopSpund();
SoundsManager.playMusic("failed_music", 0);
MCPlayer.stopMC(_backGround);
}
private function onKeyUp(event:KeyboardEvent):void{
trace("作弊");
if (Data.debug){
switch (event.keyCode){
case 49:
__mc.dispatchEvent(new Event("PassLevel"));
trace("作弊:", "PassLevel");
break;
case 50:
__mc.dispatchEvent(new Event("NoPassLevel"));
trace("作弊:", "NoPassLevel");
break;
case 51:
__mc.dispatchEvent(new Event("Catch"));
trace("作弊:", "Catch");
break;
default:
break;
};
};
}
private function catchFun():void{
_angle.display.stop();
__mc.dispatchEvent(new Event("Catch"));
}
private function GameIimeCount():void{
var mc:MovieClip;
_timeCount--;
_timeText.text = Time.getTime(_timeCount);
if ((_timeCount / Data.FpsNum) == 0){
timeOut();
} else {
if (_timeCount <= (10 * Data.FpsNum)){
mc = (__mc.getChildByName("time") as MovieClip);
mc.play();
};
};
}
private function initLevel():void{
var mc:MovieClip = (__mc.getChildByName("time") as MovieClip);
mc.stop();
var textMC:MovieClip = (mc.getChildByName("timeTextMC") as MovieClip);
_timeText = (textMC.getChildByName("timeText") as TextField);
_timeText.selectable = false;
_timeText.mouseEnabled = false;
_timeText.text = Time.getTime(_timeCount);
mc = (__mc.getChildByName("prossBar") as MovieClip);
_prossBar = new MyselfMC();
_prossBar.setDisplay(mc);
__mc.addFrameScript((__mc.currentFrame - 1), null);
}
private function checkPlayTime():void{
var obj:Object;
if (_angle.action != null){
obj = _angle.action;
if ((((((obj["Action"] == Data.Hair)) || ((obj["Action"] == Data.Scissors)))) || ((obj["Action"] == Data.Splashwash)))){
_angleCutHairTimeCount = (_angleCutHairTimeCount + obj["Time"]);
} else {
_angleActionTimeCount = (_angleActionTimeCount + obj["Time"]);
};
};
if (_angleCutHairTimeCount >= (Data.AngleCutHaitMaxTime * Data.FpsNum)){
_angleCutHairTimeCount = 0;
do {
_angle.action = _action.Angel(_angle, _prossBar);
} while ((((((_angle.action["Action"] == Data.Hair)) || ((_angle.action["Action"] == Data.Scissors)))) || ((_angle.action["Action"] == Data.Splashwash))));
} else {
if (_angleActionTimeCount >= (Data.AngleActionMaxTime * Data.FpsNum)){
_angleActionTimeCount = 0;
do {
_angle.action = _action.Angel(_angle, _prossBar);
} while (((((!((_angle.action["Action"] == Data.Hair))) && (!((_angle.action["Action"] == Data.Scissors))))) && (!((_angle.action["Action"] == Data.Splashwash)))));
};
};
}
public function stopGameFun():void{
Data.pash = false;
_controlBar.setAllBtnActiveeable();
_guest.display.stop();
_angle.stop();
_devil.stop();
(_backGround["maskMC"] as MovieClip).stop();
}
private function step():void{
if (_pash){
_actionPlayer.step();
_devil.step(_prossBar, _backGround);
_angle.step(_prossBar);
changeaBackGroundFrame();
checkCatch();
if (_pash){
checkBar();
};
if (_pash){
if (_timeOver){
timeOverFun();
} else {
GameIimeCount();
};
};
};
}
private function changeaBackGroundFrame():void{
var frame:int;
var mc:MovieClip;
var currFrame:int = _backGround.currentFrame;
var totalFrame:int = _backGround.totalFrames;
if (_devil.isCutHair){
if (currFrame < totalFrame){
frame = int((currFrame + _devil.speed));
_backGround.gotoAndStop(((frame > totalFrame)) ? totalFrame : frame);
mc = (_backGround["maskMC"] as MovieClip);
if (mc != null){
mc.gotoAndStop((((mc.currentFrame - 1) > 1)) ? (mc.currentFrame - 1) : mc.totalFrames);
};
};
} else {
if (currFrame > 1){
_backGround.gotoAndStop((((_backGround.currentFrame - 10) > 1)) ? (_backGround.currentFrame - 10) : 1);
};
};
}
public function get angle():Angle{
return (_angle);
}
private function onAnglePlayFun():void{
_angle.display.stop();
if (Math.random() < Data.AngleThinKAndToDoOdds){
_angle.isCutHair = false;
_angle.isthink = false;
_actionPlayer.angelplay(this);
} else {
_angle.isCutHair = true;
_angle.isthink = false;
_angleActionTimeCount = (_angleActionTimeCount - _angle.action["Time"]);
angleCutHair();
};
_angle.display.addFrameScript((_angle.currentFrame - 1), null);
}
private function playMusic(isDevil:Boolean=false):void{
var num:int;
if ((Data.LevelCurrNum % 2) == 0){
num = 1;
} else {
num = 2;
};
if (isDevil){
_musicPosition = SoundsManager.getMusicPosition((("angel_" + num) + "_music"));
SoundsManager.playMusic((("devil_" + num) + "_music"), int.MAX_VALUE, 1, 1);
} else {
SoundsManager.playMusic((("angel_" + num) + "_music"), int.MAX_VALUE, 1, 1, _musicPosition);
};
}
private function creatHitMC():void{
_hitMC = new Sprite();
MyDrawSprite.draw(_hitMC, MyDrawSprite.Rect, Data.stageWidth, Data.stageHeight, 0);
_hitMC.x = (Data.stageWidth / 2);
_hitMC.y = (Data.stageHeight / 2);
var index:int = __mc.getChildIndex(__mc.getChildByName("controlBar"));
__mc.addChildAt(_hitMC, index);
}
private function devilAddSpeedFun(e:Event):void{
__mc.gotoAndPlay((_level + " super"));
}
public function start():void{
_angle.isCutHair = true;
var pre:Number = (_prossBar.currFrame / _prossBar.totalFrame);
if ((((pre > Data.AngleSuperStateHappenSeatMaxLengthToEnd)) && ((Math.random() < Data.AngleSuperStateOdds)))){
pre = offsetHairflyFun(pre);
_angle.action = _action.AngelFly(_angle.display, "hairfly", pre);
} else {
_angle.action = _action.Angel(_angle, _prossBar);
};
checkPlayTime();
if ((((((_angle.action["Action"] == Data.Hair)) || ((_angle.action["Action"] == Data.Scissors)))) || ((_angle.action["Action"] == Data.Splashwash)))){
checkOppositeAction(_angle.action["Action"]);
_angleActionTimeCount = 0;
_actionPlayer.angelplay(this);
} else {
_angleCutHairTimeCount = 0;
_angle.isthink = true;
_angle.think();
SoundsManager.playSound("think0");
_angle.display.addFrameScript(MCPlayer.getCurrLabelFinalFrame(_angle.display, "think"), onAnglePlayFun);
};
}
private function levelPassAction():void{
__mc.gotoAndStop(_level);
_pash = false;
_devil.changeFace("win");
_devil.removeSmoke();
_angle.changeFace("gamefinish");
_guest.changeFace(MCPlayer.getCurrLabelBegianFrame(_guest.display, "devil"));
var currLabelFinalframe:int = (MCPlayer.getCurrLabelFinalFrame(_angle.display) - 1);
_angle.display.addFrameScript(currLabelFinalframe, levelPassFun);
SoundsManager.memoryRelease();
SoundsManager.playSound("winSound");
SoundsManager.playMusic("complete_music", 0);
}
public function get display():Sprite{
return (__mc);
}
public function playGameFun():void{
Data.pash = true;
_controlBar.setAllBtnActiveeable(false);
_guest.display.play();
_angle.play();
_devil.play();
if (_devil.isCutHair){
playMusic(true);
} else {
playMusic();
};
}
private function removeTestFun():void{
DebugTest.getoneDebugTest().del();
}
private function initEvent():void{
__mc.stage.addEventListener(Event.ENTER_FRAME, onEnterFrameFun);
_hitMC.addEventListener(MouseEvent.MOUSE_DOWN, onMouseDownFun);
_hitMC.stage.addEventListener(MouseEvent.MOUSE_UP, onMouseUpFun);
_controlBar.display.addEventListener("Help_ConTrolList", onHelpFun);
_controlBar.display.addEventListener("Pash_ConTrolList", onPashFun);
_devil.display.addEventListener("AddSpeed", devilAddSpeedFun);
}
private function checkBar():void{
if (_prossBar.checkOver()){
levelPassAction();
};
}
public function angleCutHair():void{
var pre:Number = (_prossBar.currFrame / _prossBar.totalFrame);
if ((((pre > Data.AngleSuperStateHappenSeatMaxLengthToEnd)) && ((Math.random() < Math.sqrt((Data.AngleSuperStateOdds + (((Data.LevelCurrNum / (Data.LevelMaxNum - 1)) / 10) * 5))))))){
pre = offsetHairflyFun(pre);
_angle.action = _action.AngelFly(_angle.display, "hairfly", pre);
} else {
_angle.action = _action.Angel(_angle, _prossBar, Data.HairArr[int((Math.random() * Data.HairArr.length))]);
};
_angle.isCutHair = true;
checkOppositeAction(_angle.action["Action"]);
_angleCutHairTimeCount = (_angleCutHairTimeCount + _angle.action["Time"]);
_actionPlayer.angelplay(this);
}
private function onClickPashMCFun(e:MouseEvent):void{
var mc:Sprite = (__mc.getChildByName("pashMC") as Sprite);
if (mc != null){
__mc.removeChild(mc);
};
pashFun(true);
}
private function removeEvent():void{
__mc.stage.removeEventListener(Event.ENTER_FRAME, onEnterFrameFun);
_hitMC.removeEventListener(MouseEvent.MOUSE_DOWN, onMouseDownFun);
_hitMC.stage.removeEventListener(MouseEvent.MOUSE_UP, onMouseUpFun);
_controlBar.display.removeEventListener("Help_ConTrolList", onHelpFun);
_controlBar.display.removeEventListener("Pash_ConTrolList", onPashFun);
_devil.display.removeEventListener("AddSpeed", devilAddSpeedFun);
}
private function helpFun():void{
Data.pash = false;
stopGameFun();
__mc.dispatchEvent(new Event("Help_Main"));
}
public function get star():PlayerStar{
if (_level == "LV3"){
return (PlayerStar.GoldStar);
};
if (_level == "LV2"){
return (PlayerStar.SilverStar);
};
if (_level == "LV1"){
return (PlayerStar.BronzeStar);
};
return (PlayerStar.NoStar);
}
}
}//package code.logic
Section 13
//MyselfMC (code.logic.MyselfMC)
package code.logic {
import flash.display.*;
public class MyselfMC {
private var _left:Number;
private var _barCurrFrame:Number;
private var __bar:Sprite;
private var __mc:MovieClip;
private var __scissor:Sprite;
private var _right:Number;
public function MyselfMC(){
super();
}
public function setDisplay(mc:MovieClip):void{
__mc = mc;
_barCurrFrame = 1;
__mc.gotoAndStop(int(_barCurrFrame));
__scissor = (__mc.getChildByName("scissor") as Sprite);
__bar = (__mc.getChildByName("bar") as Sprite);
if (__bar != null){
_left = __bar.getBounds(__mc).left;
_right = __bar.getBounds(__mc).right;
trace(((("left :" + _left) + " right :") + _right));
};
}
public function checkOver():Boolean{
var pre:Number = 0.99;
var winFrame:int = (__mc.totalFrames * pre);
if (__mc.currentFrame >= winFrame){
return (true);
};
return (false);
}
public function get barCurrFrame():Number{
return (_barCurrFrame);
}
public function get totalFrame():int{
return (__mc.totalFrames);
}
public function get currFrame():int{
return (__mc.currentFrame);
}
public function set barCurrFrame(i:Number):void{
_barCurrFrame = i;
}
public function getLocalCurrFrame(mc:MovieClip):int{
var i:int = int(((__mc.currentFrame / __mc.totalFrames) * mc.totalFrames));
return (i);
}
public function checkScissorSeat():PlayerStar{
var min:Number;
var max:Number;
var pre:Number;
if (((!((__scissor == null))) && (!((__bar == null))))){
min = (__scissor.x - __bar.getBounds(__mc).left);
max = __bar.width;
} else {
min = barCurrFrame;
max = totalFrame;
};
pre = (min / max);
if (pre >= 1){
return (PlayerStar.GoldStar);
};
if (pre >= 0.8){
return (PlayerStar.SilverStar);
};
if (pre >= 0.6){
return (PlayerStar.BronzeStar);
};
return (PlayerStar.NoStar);
}
public function jumpFrame():void{
if (__mc != null){
if (((!((__scissor == null))) && (!((__bar == null))))){
if (_barCurrFrame < _left){
_barCurrFrame = int(_left);
} else {
if (_barCurrFrame > _right){
_barCurrFrame = int(_right);
};
};
__scissor.x = _barCurrFrame;
} else {
if (_barCurrFrame < 1){
_barCurrFrame = 1;
} else {
if (_barCurrFrame > __mc.totalFrames){
_barCurrFrame = __mc.totalFrames;
};
};
__mc.gotoAndStop(int(_barCurrFrame));
};
};
}
}
}//package code.logic
Section 14
//PlayerStar (code.logic.PlayerStar)
package code.logic {
public class PlayerStar {
private var _value:int;
public static const GoldStar:PlayerStar = new PlayerStar(5);
;
public static const NoStar:PlayerStar = new PlayerStar(2);
;
public static const WinStar:PlayerStar = new PlayerStar(1);
;
public static const BronzeStar:PlayerStar = new PlayerStar(3);
;
public static const SilverStar:PlayerStar = new PlayerStar(4);
;
public function PlayerStar(value:int){
super();
_value = value;
}
public function get value():int{
return (_value);
}
public function upStar(star:PlayerStar):PlayerStar{
if (star == GoldStar){
return (GoldStar);
};
if (star == GoldStar){
return (GoldStar);
};
if (star == SilverStar){
return (SilverStar);
};
if (star == BronzeStar){
return (BronzeStar);
};
return (GoldStar);
}
}
}//package code.logic
Section 15
//Attach (code.tool.Attach)
package code.tool {
import flash.display.*;
import flash.media.*;
import flash.utils.*;
public class Attach {
public function Attach(){
super();
}
public static function getSound(s:String):Sound{
var temp:Class = (getDefinitionByName(s) as Class);
var returnObj:Sound = new (temp);
return (returnObj);
}
public static function getMovieClip(s:String):MovieClip{
var temp:Class = (getDefinitionByName(s) as Class);
var returnObj:MovieClip = new (temp);
return (returnObj);
}
public static function getSprite(s:String):Sprite{
var temp:Class = (getDefinitionByName(s) as Class);
var returnObj:Sprite = new (temp);
return (returnObj);
}
public static function getBitmapData(s:String):BitmapData{
var temp:Class = (getDefinitionByName(s) as Class);
var returnObj:BitmapData = new temp(null, null);
return (returnObj);
}
}
}//package code.tool
Section 16
//DebugTest (code.tool.DebugTest)
package code.tool {
import flash.display.*;
import flash.events.*;
public class DebugTest {
public var funArr:Array;
public var keyArr:Array;
public var stage:Stage;
private static var _oneDebugTest:DebugTest;
public function DebugTest(){
super();
}
public function init(stage:Stage, keyArr:Array, funArr:Array):void{
this.stage = stage;
this.funArr = funArr;
this.keyArr = keyArr;
this.stage.addEventListener(KeyboardEvent.KEY_DOWN, onKeyDown, false, 0, false);
}
private function onKeyDown(event:KeyboardEvent):void{
var i:int;
while (i < keyArr.length) {
if (event.keyCode == keyArr[i]){
var _local3 = funArr;
_local3[i]();
return;
};
i++;
};
}
public function del():void{
if (_oneDebugTest == null){
return;
};
if (_oneDebugTest.stage == null){
return;
};
if (!_oneDebugTest.stage.hasEventListener(KeyboardEvent.KEY_DOWN)){
return;
};
_oneDebugTest.stage.removeEventListener(KeyboardEvent.KEY_DOWN, onKeyDown);
_oneDebugTest.stage = null;
_oneDebugTest.funArr = null;
_oneDebugTest.keyArr = null;
_oneDebugTest = null;
}
public static function getoneDebugTest():DebugTest{
if (_oneDebugTest != null){
return (_oneDebugTest);
};
_oneDebugTest = new (DebugTest);
return (_oneDebugTest);
}
}
}//package code.tool
Section 17
//Fillter (code.tool.Fillter)
package code.tool {
import flash.display.*;
import flash.filters.*;
public class Fillter {
public function Fillter(){
super();
}
public static function delLight(mc:Sprite):void{
var myFilters:Array = mc.filters;
myFilters = null;
mc.filters = myFilters;
}
public static function light(mc:Sprite, num:Number=20, color:uint=0xFFFFFF):void{
var fil:GlowFilter = new GlowFilter(color, 1, num, num, 2, 1, false, false);
var myFilters:Array = mc.filters;
myFilters[0] = fil;
mc.filters = myFilters;
}
}
}//package code.tool
Section 18
//FpsCounter (code.tool.FpsCounter)
package code.tool {
import flash.display.*;
import flash.text.*;
import flash.utils.*;
import code.data.*;
import flash.system.*;
public class FpsCounter extends Sprite {
private const timer:int = 30;
private var oldT:uint;
private var mfpsCount:int;// = 0
private var textBox2:TextField;
private var textBox3:TextField;
private var textBox4:TextField;
private var textBox:TextField;
private var avgCount:int;
private var _averageFps:int;
private var avgCount2:int;// = 30
private var _visable:Boolean;
private var mfpsCount2:int;// = 0
public function FpsCounter(visable:Boolean=true){
super();
_visable = visable;
var seat:Number = Data.stageWidth;
textBox = new TextField();
textBox.text = "fps average";
textBox.textColor = 11145540;
textBox.selectable = false;
textBox.x = (seat - 100);
textBox.autoSize = "right";
textBox2 = new TextField();
textBox2.text = "fps (physics)";
textBox2.textColor = 11145540;
textBox2.selectable = false;
textBox2.y = 15;
textBox2.x = (seat - 100);
textBox2.autoSize = "right";
textBox3 = new TextField();
textBox3.text = "memory wasted";
textBox3.textColor = 11145540;
textBox3.selectable = false;
textBox3.y = 30;
textBox3.x = (seat - 100);
textBox3.autoSize = "right";
textBox4 = new TextField();
textBox4.text = "x: |y: ";
textBox4.textColor = 11145540;
textBox4.selectable = false;
textBox4.y = 45;
textBox4.x = (seat - 100);
textBox4.autoSize = "right";
avgCount = timer;
oldT = getTimer();
if (_visable){
addChild(textBox);
addChild(textBox2);
addChild(textBox3);
addChild(textBox4);
};
}
public function updatePhys(oldT2:uint):void{
var newT:uint = getTimer();
var f1:uint = (newT - oldT2);
mfpsCount2 = (mfpsCount2 + f1);
if (avgCount2 < 1){
textBox2.text = String((Math.round((1000 / (mfpsCount2 / 30))) + " fps (physics)"));
avgCount2 = 30;
mfpsCount2 = 0;
};
avgCount2--;
}
public function update():void{
var newT:uint = getTimer();
var f1:uint = (newT - oldT);
mfpsCount = (mfpsCount + f1);
if (avgCount < 1){
_averageFps = Math.round((1000 / (mfpsCount / timer)));
textBox.text = (String(_averageFps) + " fps average");
avgCount = timer;
mfpsCount = 0;
};
avgCount--;
oldT = getTimer();
textBox3.text = (Math.round((System.totalMemory / (0x0400 * 0x0400))) + " MB used");
textBox4.text = (((("x:" + stage.mouseX) + "| ") + "y:") + stage.mouseY);
}
public function get averageFps():Number{
return (_averageFps);
}
public function updateEnd():void{
}
}
}//package code.tool
Section 19
//GetGameURL (code.tool.GetGameURL)
package code.tool {
import flash.external.*;
public class GetGameURL {
public function GetGameURL(){
super();
}
public static function codeToString(code:String):String{
return (Encrypt(decodeURI(code)));
}
public static function stringToCode(str:String):String{
return (encodeURI(Encrypt(str)));
}
public static function getMyselfURL(myStr:String="&code="):String{
var codeStr:String;
var end:Number;
var url:String = GetGameURL.getCurrentURL();
var start:Number = url.indexOf(myStr);
if (start == -1){
return ("");
};
url = url.substring((start + myStr.length));
end = url.indexOf("&");
if (end == -1){
codeStr = url;
} else {
codeStr = url.substring(0, end);
};
return (codeStr);
}
public static function getCurrentURL():String{
var loc:Object;
loc = ExternalInterface.call("window.location.href.toString");
//unresolved jump
var _slot1 = e;
return ("");
if (loc == null){
return ("");
};
if (String(loc).indexOf(".swf") != -1){
return ("");
};
return (String(loc));
}
private static function Encrypt(decryptString:String):String{
var encryptString:String = "";
var i:int;
while (i < decryptString.length) {
encryptString = (encryptString + String.fromCharCode((decryptString.charCodeAt(i) ^ 0xFF)));
i++;
};
return (encryptString);
}
}
}//package code.tool
Section 20
//InterNet (code.tool.InterNet)
package code.tool {
import flash.net.*;
public class InterNet {
public function InterNet(){
super();
}
public static function getNewURL(url:String=null):void{
if (url == null){
url = "http://www.gameportal.net";
};
var request:URLRequest = new URLRequest(url);
navigateToURL(request);
}
}
}//package code.tool
Section 21
//McButton (code.tool.McButton)
package code.tool {
import flash.display.*;
import flash.events.*;
public class McButton extends MovieClip {
private var newHitMc:Sprite;
public function McButton(){
super();
this.stop();
setHandUse(true);
newHitMc = (this.getChildByName("mc") as Sprite);
if (newHitMc == null){
createHitMc();
};
newHitMc.name = "HitMC";
newHitMc.addEventListener(MouseEvent.ROLL_OVER, rollOverFun, false, 0, true);
newHitMc.addEventListener(MouseEvent.MOUSE_DOWN, mouseDownFun, false, 0, true);
newHitMc.addEventListener(MouseEvent.MOUSE_UP, mouseUpFun, false, 0, true);
newHitMc.addEventListener(MouseEvent.ROLL_OUT, rollOutFun, false, 0, true);
}
public function get HitMc():Sprite{
return (newHitMc);
}
private function rollOutFun(evt:MouseEvent):void{
if (this.currentFrame != 4){
this.gotoAndStop(1);
this.addChild(newHitMc);
};
}
public function setHandUse(t:Boolean):void{
this.buttonMode = t;
}
public function unactive(unactive:Boolean=true):void{
if (unactive){
setHandUse(false);
this.gotoAndStop(4);
} else {
this.gotoAndStop(1);
};
}
private function mouseDownFun(evt:MouseEvent):void{
if (this.currentFrame != 4){
this.gotoAndStop(3);
this.addChild(newHitMc);
};
}
public function del():void{
newHitMc.removeEventListener(MouseEvent.ROLL_OVER, rollOverFun);
newHitMc.removeEventListener(MouseEvent.MOUSE_DOWN, mouseDownFun);
newHitMc.removeEventListener(MouseEvent.MOUSE_UP, mouseUpFun);
newHitMc.removeEventListener(MouseEvent.ROLL_OUT, rollOutFun);
}
private function createHitMc():void{
newHitMc = new Sprite();
this.addChild(newHitMc);
newHitMc.graphics.lineStyle(0, 0, 0);
newHitMc.graphics.beginFill(0, 0);
newHitMc.graphics.drawRect((-(this.width) / 2), (-(this.height) / 2), this.width, this.height);
newHitMc.graphics.endFill();
}
private function rollOverFun(evt:MouseEvent):void{
if (this.currentFrame != 4){
this.gotoAndStop(2);
this.addChild(newHitMc);
};
}
private function mouseUpFun(evt:MouseEvent):void{
if (this.currentFrame != 4){
this.gotoAndStop(2);
this.addChild(newHitMc);
};
}
}
}//package code.tool
Section 22
//MCPlayer (code.tool.MCPlayer)
package code.tool {
import flash.display.*;
public class MCPlayer {
public function MCPlayer(){
super();
}
public static function stopMC(mc:Sprite):void{
var i:int;
var newc:MovieClip;
if ((mc is MovieClip)){
(mc as MovieClip).stop();
};
if ((mc is Sprite)){
i = (mc.numChildren - 1);
while (i >= 0) {
newc = (mc.getChildAt(i) as MovieClip);
stopMC(newc);
i--;
};
};
}
public static function playMC(mc:Sprite):void{
var i:int;
var newmc:MovieClip;
if ((mc is MovieClip)){
(mc as MovieClip).play();
};
if ((mc is Sprite)){
i = (mc.numChildren - 1);
while (i >= 0) {
newmc = (mc.getChildAt(i) as MovieClip);
playMC(newmc);
i--;
};
};
}
public static function getCurrLabelFinalFrame(mc:MovieClip, currLabel:String=null):int{
var label:FrameLabel;
if (currLabel == null){
currLabel = mc.currentLabel;
};
var totalLabels:Array = mc.currentLabels;
var len:int = totalLabels.length;
var i:int;
while (i < len) {
if ((totalLabels[i] is FrameLabel)){
label = totalLabels[i];
if (label.name == currLabel){
if (i < (len - 1)){
return (((totalLabels[(i + 1)] as FrameLabel).frame - 1));
};
return ((mc.totalFrames - 1));
};
};
i++;
};
return (-1);
}
public static function getCurrLabelBegianFrame(mc:MovieClip, currLabel:String=null):int{
var label:FrameLabel;
if (currLabel == null){
currLabel = mc.currentLabel;
};
var totalLabels:Array = mc.currentLabels;
var len:int = totalLabels.length;
var i:int;
while (i < len) {
if ((totalLabels[i] is FrameLabel)){
label = totalLabels[i];
if (label.name == currLabel){
return (label.frame);
};
};
i++;
};
return (-1);
}
}
}//package code.tool
Section 23
//MyDispatcher (code.tool.MyDispatcher)
package code.tool {
import flash.events.*;
public class MyDispatcher {
static const LANGUAGE_CHANGED:String = "languageChanged";
static var dispatcher:EventDispatcher = new EventDispatcher();
public function MyDispatcher(){
super();
}
public static function removeLangChangedListener(fun:Function):void{
dispatcher.removeEventListener(LANGUAGE_CHANGED, fun);
}
static function langChanged():void{
dispatcher.dispatchEvent(new Event(LANGUAGE_CHANGED));
}
public static function addLangChangedListener(fun:Function):void{
dispatcher.addEventListener(LANGUAGE_CHANGED, fun);
}
}
}//package code.tool
Section 24
//MyDrawSprite (code.tool.MyDrawSprite)
package code.tool {
import flash.display.*;
public class MyDrawSprite {
public static const Rect:String = "rect";
public static const Cyc:String = "cyc";
public function MyDrawSprite(){
super();
}
public static function draw(mc:Sprite, shape:String, w:Number=20, h:Number=20, alpha:Number=1, color:uint=0):void{
mc.graphics.lineStyle(1, color, alpha);
mc.graphics.beginFill(color, alpha);
if (shape == Rect){
mc.graphics.drawRect((-(w) / 2), (-(h) / 2), w, h);
} else {
if (shape == Cyc){
mc.graphics.drawCircle((-(w) / 2), (-(w) / 2), w);
};
};
mc.graphics.endFill();
}
}
}//package code.tool
Section 25
//PictureTransition (code.tool.PictureTransition)
package code.tool {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import fl.transitions.*;
import fl.transitions.easing.*;
public class PictureTransition {
public function PictureTransition(){
super();
}
private function showDsiplay(mc:MovieClip, mc2:MovieClip):void{
mc.gotoAndStop((((mc.currentFrame + 1) > mc.totalFrames)) ? 1 : (mc.currentFrame + 1));
mc2.stop();
TransitionManager.start(mc, {type:Fade, direction:Transition.IN, duration:1, easing:None.easeNone});
}
private function changDisplay(mc:MovieClip, mc2:MovieClip):void{
mc2.gotoAndStop((((mc2.currentFrame + 1) > mc2.totalFrames)) ? 1 : (mc2.currentFrame + 1));
TransitionManager.start(mc, {type:Fade, direction:Transition.OUT, duration:1, easing:None.easeNone});
TransitionManager.start(mc2, {type:Fade, direction:Transition.IN, duration:1, easing:None.easeNone});
setTimeout(getFunction(showDsiplay, mc, mc2), 1000);
}
private function getFunction(fun:Function, mc:MovieClip, mc2:MovieClip, bool:Boolean=true):Function{
var f:Function;
var fun = fun;
var mc = mc;
var mc2 = mc2;
var bool = bool;
if (bool){
f = function ():void{
fun(mc, mc2);
};
} else {
f = function (e:TimerEvent):void{
fun(mc, mc2);
};
};
return (f);
}
public function pixelDissolve(mc:MovieClip, mc2:MovieClip):void{
showDsiplay(mc, mc2);
var myTimer:Timer = new Timer(3000, int.MAX_VALUE);
myTimer.addEventListener("timer", getFunction(changDisplay, mc, mc2, false));
myTimer.start();
}
public static function oneObject():PictureTransition{
return (new (PictureTransition));
}
}
}//package code.tool
Section 26
//Probability (code.tool.Probability)
package code.tool {
public class Probability {
public function Probability(){
super();
}
public static function offsetProbability(cha:Object, num:int, sampleArr:Array):Array{
var temp:Array = new Array();
var i:int;
while (i < num) {
trace("what's the fuck");
temp.push(cha);
i++;
};
return (sampleArr.concat(temp));
}
}
}//package code.tool
Section 27
//SoundsManager (code.tool.SoundsManager)
package code.tool {
import flash.events.*;
import flash.media.*;
import flash.utils.*;
public class SoundsManager {
private static const SOUNDSLINK:Array = ["splashwash", "scissors", "rules", "churnUp", "sweet", "chuckBook", "pickBook", "whistle0", "whistle1", "whistle2", "devilCutHair", "damageup", "fullSate", "winSound", "camera", "jumpwindow", "menu_back", "menu_press", "menu_touch", "other_press", "other_touch", "pagego", "pageback", "window_press", "window_touch", "smail", "beCatch", "fadie0", "fadie1", "fadie2", "angre", "think1", "think2", "find", "person", "talk0", "talk1", "think0", "flyCutHair", "achievements_music", "angel_1_music", "angel_2_music", "complete_music", "devil_1_music", "devil_2_music", "failed_music", "mainscreen_music", "tutorial_music"];
private static const VOLUME_SOUND:Number = 0.95;
private static const VOLUME_MUSIC:Number = 0.8;
private static var curMusicVolume:Number;
private static var TmepFun:Function;
private static var curMusicArr:Array;
private static var curSoundVolume:Number;
private static var fadeTimer:Timer;
private static var soundsArr:Array;
public function SoundsManager(){
super();
}
private static function timerFun(evt:Event):void{
fadeMusic();
}
public static function stopMusic(fadeStop:Boolean=false):void{
var i:*;
if (!fadeStop){
for (i in curMusicArr) {
if (soundsArr[curMusicArr[i].name].channel[0] != null){
soundsArr[curMusicArr[i].name].channel[0].stop();
};
};
curMusicArr = new Array();
};
}
private static function fadeMusic():void{
var curMusicChannel:SoundChannel;
var per:Number;
var transform:SoundTransform;
var len:int = curMusicArr.length;
if (len > 0){
curMusicChannel = soundsArr[curMusicArr[0].name].channel[0];
if (!curMusicChannel){
trace("fadeMusicErr");
return;
};
if (len == 1){
if (curMusicChannel.soundTransform.volume < curMusicVolume){
per = (100 / curMusicArr[0].delayStart);
if (per > 1){
per = 1;
};
transform = curMusicChannel.soundTransform;
transform.volume = (curMusicChannel.soundTransform.volume + per);
curMusicChannel.soundTransform = transform;
} else {
fadeTimer.stop();
};
} else {
if (len > 1){
if (curMusicChannel.soundTransform.volume > 0){
per = (100 / curMusicArr[0].delayEnd);
if (per > 1){
per = 1;
};
transform = curMusicChannel.soundTransform;
transform.volume = (curMusicChannel.soundTransform.volume - per);
curMusicChannel.soundTransform = transform;
};
if (curMusicChannel.soundTransform.volume <= 0){
curMusicChannel.stop();
curMusicArr.splice(0, (len - 1));
startMusic(curMusicArr[0].name, curMusicArr[0].times, curMusicArr[0].initVol, curMusicArr[0].startTime);
};
};
};
};
}
public static function modifyMusicVolume(volume:Number=-1):void{
var i:*;
var temp:SoundTransform;
if (volume < 0){
curMusicVolume = VOLUME_MUSIC;
} else {
curMusicVolume = volume;
};
for (i in curMusicArr) {
if (soundsArr[curMusicArr[i].name].channel[0] != null){
temp = soundsArr[curMusicArr[i].name].channel[0].soundTransform;
temp.volume = curMusicVolume;
soundsArr[curMusicArr[i].name].channel[0].soundTransform = temp;
};
};
}
public static function memoryRelease():void{
var s:*;
var obj:Object;
var num:*;
for (s in soundsArr) {
obj = soundsArr[s];
if (!obj["music"]){
for (num in obj["channel"]) {
if (obj["channel"][num] != null){
obj["channel"][num].stop();
delete obj["channel"][num];
};
};
obj["channel"] = [];
};
};
}
public static function pause(p:Boolean):void{
if (p){
modifySoundsVolume(0);
modifyMusicVolume(0);
} else {
modifySoundsVolume();
modifyMusicVolume();
};
}
public static function init():void{
var name:String;
var temp_sound:Sound;
var obj:Object;
curMusicVolume = VOLUME_MUSIC;
curSoundVolume = VOLUME_SOUND;
soundsArr = new Array();
var i:int;
while (i < SOUNDSLINK.length) {
name = SOUNDSLINK[i];
temp_sound = getSound(name);
obj = {name:name, sound:temp_sound, channel:[], music:false, loop:false};
soundsArr[name] = obj;
i++;
};
curMusicArr = new Array();
fadeTimer = new Timer(100);
fadeTimer.addEventListener("timer", timerFun, false, 0, true);
fadeTimer.stop();
}
public static function playMusic(name:String, times:int=2147483647, delayStart:int=10, delayEnd:int=100, startTime:Number=0):void{
var initVol:Number = 0;
if (delayStart < 100){
initVol = curMusicVolume;
};
var obj:Object = {name:name, times:times, delayStart:delayStart, delayEnd:delayEnd, initVol:initVol, startTime:startTime};
if (soundsArr[name] != null){
soundsArr[name].music = true;
if (curMusicArr.length == 0){
startMusic(name, times, initVol, startTime);
fadeMusic();
};
if (!(((curMusicArr.length > 0)) && ((curMusicArr[(curMusicArr.length - 1)].name == name)))){
curMusicArr.push(obj);
fadeMusic();
fadeTimer.start();
};
} else {
trace((("Music \"" + name) + "\" is not exist!"));
};
}
private static function onPlayFun(s:String, times:int, initVol:Number):void{
if (soundsArr[s].channel[0] != null){
soundsArr[s].channel[0].removeEventListener(Event.SOUND_COMPLETE, TmepFun);
soundsArr[s].channel[0].stop();
soundsArr[s].channel[0] = soundsArr[s].sound.play(0, times, new SoundTransform(initVol));
};
}
private static function getOnPlayFun(s:String, times:int, initVol:Number):Function{
var fun:Function;
var s = s;
var times = times;
var initVol = initVol;
fun = function (e:Event):void{
onPlayFun(s, times, initVol);
};
return (fun);
}
public static function modifySoundsVolume(volume:Number=-1):void{
var i:*;
var j:*;
var temp:SoundTransform;
if (volume < 0){
curSoundVolume = VOLUME_SOUND;
} else {
curSoundVolume = volume;
};
for (i in soundsArr) {
if (!soundsArr[i].music){
for (j in soundsArr[i].channel) {
if (soundsArr[i].channel[j] != null){
temp = soundsArr[i].channel[j].soundTransform;
temp.volume = curSoundVolume;
soundsArr[i].channel[j].soundTransform = temp;
};
};
};
};
}
private static function startMusic(s:String, times:int=2147483647, initVol:Number=0, startTime:Number=0):void{
var channel:SoundChannel;
if (s != null){
if (soundsArr[s] != null){
if (soundsArr[s].channel[0] != null){
soundsArr[s].channel[0].stop();
};
if (startTime == 0){
channel = soundsArr[s].sound.play(startTime, times, new SoundTransform(initVol));
} else {
channel = soundsArr[s].sound.play(startTime, 0, new SoundTransform(initVol));
};
if (!channel){
trace("startMusicErr");
return;
};
soundsArr[s].channel[0] = channel;
soundsArr[s].music = true;
if (((!((startTime == 0))) && ((times > 0)))){
TmepFun = getOnPlayFun(s, (times - 1), initVol);
if (channel){
channel.addEventListener(Event.SOUND_COMPLETE, TmepFun);
};
};
} else {
trace((("Music \"" + s) + "\" is not exist!"));
};
};
}
public static function playSoundFromStop(s:String, num:int=0):void{
var obj:Object;
if (soundsArr[s] != null){
obj = soundsArr[s];
if (!obj["music"]){
if (obj["channel"][num] != null){
obj["channel"][num].play();
} else {
playSound(s);
};
};
};
}
private static function getSound(s:String):Sound{
var temp:Class = (getDefinitionByName(s) as Class);
var returnObj:Sound = new (temp);
return (returnObj);
}
public static function stopSound(s:String, num:int=0):void{
var obj:Object;
if (soundsArr[s] != null){
obj = soundsArr[s];
if (!obj["music"]){
if (obj["channel"][num] != null){
obj["channel"][num].stop();
delete obj["channel"][num];
};
};
};
}
public static function getMusicPosition(s:String, num:int=0):Number{
var obj:Object;
var position:Number = 0;
if (soundsArr[s] != null){
obj = soundsArr[s];
if (obj["music"]){
if (obj["channel"][num] != null){
position = obj["channel"][num].position;
} else {
trace((("the Music " + s) + " is not playing"));
};
} else {
trace((("the vedio " + s) + " is not Music !"));
};
} else {
trace((("the vedio " + s) + " is not exit !"));
};
return (position);
}
public static function playSound(name:String, canBeOverlap:Boolean=true, times:int=0, volume:Number=-1):int{
var channel:SoundChannel;
if (soundsArr[name] != null){
if (times > 0){
soundsArr[name].loop = true;
};
if ((((volume == -1)) || ((curSoundVolume == 0)))){
volume = curSoundVolume;
};
if (soundsArr[name].channel[0] != null){
soundsArr[name].channel[0].stop();
};
channel = soundsArr[name].sound.play(0, times, new SoundTransform(volume));
if (!channel){
trace("playSoundErr");
return (null);
};
if (!canBeOverlap){
soundsArr[name].channel.push(channel);
return ((soundsArr[name].channel.length - 1));
};
soundsArr[name].channel[0] = channel;
return (0);
} else {
trace((("Sound \"" + name) + "\" is not exist!"));
};
return (-1);
}
}
}//package code.tool
Section 28
//Time (code.tool.Time)
package code.tool {
public class Time {
public function Time(){
super();
}
public static function getTime(TimeCount:int):String{
var text:String;
var min:int;
var sec:int;
var ms:String;
var ss:String;
if (TimeCount >= 0){
min = ((TimeCount / 30) / 60);
sec = ((TimeCount / 30) % 60);
ms = min.toString();
ss = sec.toString();
if (min < 10){
ms = ("0" + min);
};
if (sec < 10){
ss = ("0" + sec);
};
text = ((ms + ":") + ss);
} else {
text = "00:00";
};
return (text);
}
public static function getZeroNumberChar(n:uint):String{
var char:String = n.toString();
if ((((n >= 0)) && ((n < 10)))){
char = ("0000" + char);
};
if ((((n >= 10)) && ((n < 100)))){
char = ("000" + char);
};
if ((((n >= 100)) && ((n < 1000)))){
char = ("00" + char);
};
if ((((n >= 1000)) && ((n < 10000)))){
char = ("0" + char);
};
return (char);
}
}
}//package code.tool
Section 29
//Tracker (code.tool.Tracker)
package code.tool {
import zlong.spilSystemTool.*;
public class Tracker {
private static var isEnd:Boolean = true;
private static var isSend:Boolean = true;
private static var islevel1:Boolean = true;
private static var isBegian:Boolean = true;
private static var isHalf:Boolean = true;
public function Tracker(){
super();
}
public static function send():void{
if (isSend){
isSend = false;
GoogleEvent.instance.gaTrackEvent("send_to_friend landing page");
};
}
public static function level1():void{
if (islevel1){
islevel1 = false;
GoogleEvent.instance.gaTrackEvent("level 1 completed");
};
}
public static function init(doc:Root):void{
}
public static function half():void{
if (isHalf){
isHalf = false;
GoogleEvent.instance.gaTrackEvent("game completed");
};
}
public static function shop(isUK:Boolean=true):void{
if (isUK){
GoogleEvent.instance.gaTrackEvent("uk_shop");
} else {
GoogleEvent.instance.gaTrackEvent("us_shop");
};
}
public static function begian():void{
if (isBegian){
isBegian = false;
GoogleEvent.instance.gaTrackEvent("mainscreen viewed");
};
}
public static function end():void{
if (isEnd){
isEnd = false;
GoogleEvent.instance.gaTrackEvent("all achievements completed");
};
}
}
}//package code.tool
Section 30
//Achievement (code.ui.Achievement)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.logic.*;
import flash.utils.*;
import code.tool.*;
import code.data.*;
public class Achievement extends UI {
var _mainMenuBtn:Sprite;
private var _controlBar:ControlList;
private var _cupNameArr:Array;
private var _cupArr:Array;
private var _helpMC:MovieClip;
private var _myTimer:Timer;
public function Achievement(uim:UIManager){
super(uim);
init();
if (Data.isTest){
addTestFun();
};
}
private function initCup():void{
var mc:Sprite;
_cupArr = new Array();
var i:int;
while (i < _cupNameArr.length) {
mc = (display.getChildByName(_cupNameArr[i]) as Sprite);
mc.buttonMode = true;
mc.mouseChildren = false;
if (Cookie.da["Achievement"][_cupNameArr[i]][0]){
(mc as MovieClip).gotoAndStop(3);
} else {
(mc as MovieClip).gotoAndStop(1);
};
_cupArr.push(mc);
i++;
};
if (Data.HasNewAchievement){
checkMaxHighCup();
};
Data.HasNewAchievement = false;
}
private function onClickFun(e:MouseEvent):void{
SoundsManager.playSound("menu_press");
uim.delAchievement();
uim.levelMap();
}
private function addAllCup():void{
var mc:MovieClip;
var i:int;
while (i < _cupArr.length) {
mc = _cupArr[i];
mc.gotoAndStop(2);
i++;
};
}
private function checkMaxHighCup():void{
var mc:MovieClip;
var i:int = (_cupNameArr.length - 1);
while (i >= 0) {
if (!Cookie.da["Achievement"][_cupNameArr[i]][0]){
mc = _cupArr[i];
mc.gotoAndStop(2);
break;
};
i--;
};
}
private function onMouseOverFun(e:MouseEvent):void{
SoundsManager.playSound("menu_touch");
}
override public function initMC():void{
var arr:Array;
_cupNameArr = new Array("DogLover", "CatLover", "DevilNovice", "WannabeAngel", "SuperDevil");
if (Data.AchiMC == ""){
arr = _cupNameArr.concat("mainMenuBtn");
drawMC(arr);
} else {
setMC(Data.AchiMC);
};
_mainMenuBtn = (display.getChildByName("mainMenuBtn") as Sprite);
_helpMC = (display.getChildByName("insturctionMC") as MovieClip);
_helpMC.stop();
_helpMC.visible = false;
initCup();
var contrlListMC:Sprite = (display.getChildByName("controlListMC_Achievement") as Sprite);
_controlBar = new ControlList(contrlListMC);
}
private function onMouseRollOverFun(e:MouseEvent):void{
SoundsManager.playSound("other_touch");
var index:int = _cupArr.indexOf(e.target);
var mc:Sprite = _cupArr[index];
_helpMC.gotoAndStop((index + 1));
_helpMC.x = mc.x;
_helpMC.y = 150;
_helpMC.gotoAndStop((index + 1));
_myTimer = new Timer(500, 1);
_myTimer.addEventListener(TimerEvent.TIMER, onTimerFun);
_myTimer.start();
}
private function removeTestFun():void{
DebugTest.getoneDebugTest().del();
}
override public function initEvent():void{
var mc:Sprite;
_mainMenuBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_mainMenuBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
var i:int;
while (i < _cupArr.length) {
mc = _cupArr[i];
mc.mouseChildren = false;
mc.addEventListener(MouseEvent.ROLL_OVER, onMouseRollOverFun);
mc.addEventListener(MouseEvent.ROLL_OUT, onMouseOutFun);
i++;
};
}
private function onMouseOutFun(e:MouseEvent):void{
if (_myTimer != null){
_myTimer.stop();
};
_helpMC.visible = false;
}
private function onTimerFun(e:TimerEvent):void{
_helpMC.visible = true;
}
private function addTestFun():void{
DebugTest.getoneDebugTest().init(display.stage, [32], new Array(addAllCup));
}
override public function removeEvent():void{
if (Data.isTest){
removeTestFun();
};
}
}
}//package code.ui
Section 31
//CreditsClass (code.ui.CreditsClass)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.logic.*;
import code.tool.*;
import code.data.*;
public class CreditsClass extends UI {
private var _controlBar:ControlList;
private var _levelBtn:Sprite;
private var _photo:MovieClip;
private var _photo2:MovieClip;
public function CreditsClass(uim:UIManager){
super(uim);
init();
}
private function initPhoto():void{
PictureTransition.oneObject().pixelDissolve(_photo, _photo2);
if ((((Data.LevelCurrNum >= Data.LevelMaxNum)) && (!(Cookie.da["endGame"])))){
_photo.addFrameScript((_photo.totalFrames - 1), onEndMCFun);
Cookie.da["endGame"] = true;
Cookie.flush();
Data.LevelCurrNum = 0;
};
}
private function onMouseOverFun(e:MouseEvent):void{
}
override public function initEvent():void{
_levelBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_levelBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
override public function initMC():void{
setMC(Data.CreditsMC);
_levelBtn = (display.getChildByName("levelMapBtn") as Sprite);
if (Data.LevelCurrNum >= Data.LevelMaxNum){
_levelBtn.visible = false;
};
_photo = (display.getChildByName("photoMC") as MovieClip);
_photo.gotoAndStop(_photo.totalFrames);
_photo2 = (display.getChildByName("photoMC2") as MovieClip);
_photo2.gotoAndStop(1);
initPhoto();
var contrlListMC:Sprite = (display.getChildByName("controlListMC_Credit") as Sprite);
_controlBar = new ControlList(contrlListMC);
}
private function onEndMCFun():void{
_photo.stop();
uim.delCredits();
uim.GM.checkGameEnd();
_photo.addFrameScript((_photo.currentFrame - 1), null);
}
override public function removeEvent():void{
_levelBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
}
private function onClickFun(e:MouseEvent):void{
uim.pageChange(true);
}
}
}//package code.ui
Section 32
//FromFriend (code.ui.FromFriend)
package code.ui {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import code.tool.*;
public class FromFriend extends UI {
private var _output:TextField;
private var _startGameBtn:Sprite;
private var _moreGameBtn:Sprite;
private var _photo:MovieClip;
private var _friend:TextField;
public function FromFriend(m:UIManager){
super(m);
init();
initOutput();
}
private function onMouseClickFun(e:MouseEvent):void{
SoundsManager.playSound("menu_press");
if (e.target == _startGameBtn.getChildByName("HitMC")){
uim.delFromFriend();
uim.menu();
};
}
private function onMouseOverFun(e:MouseEvent):void{
SoundsManager.playSound("menu_touch");
}
override public function initMC():void{
this.setMC("FromFriendMC");
initDis();
}
override public function initEvent():void{
_startGameBtn.addEventListener(MouseEvent.CLICK, onMouseClickFun);
_startGameBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_moreGameBtn.addEventListener(MouseEvent.CLICK, onMouseClickFun);
_moreGameBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
private function initOutput():void{
var codeStr:String = GetGameURL.getMyselfURL("code=");
_output.text = GetGameURL.codeToString(codeStr);
var friendStr:String = GetGameURL.getMyselfURL("friend=");
_friend.text = GetGameURL.codeToString(friendStr);
var frameStr:String = GetGameURL.getMyselfURL("&frame=");
frameStr = GetGameURL.codeToString(frameStr);
_photo.gotoAndStop(int(frameStr));
}
override public function removeEvent():void{
_startGameBtn.removeEventListener(MouseEvent.CLICK, onMouseClickFun);
}
private function initDis():void{
_output = (display.getChildByName("outputText") as TextField);
_output.selectable = false;
_output.tabEnabled = false;
_friend = (display.getChildByName("friendText") as TextField);
_friend.selectable = false;
_friend.tabEnabled = false;
_startGameBtn = (display.getChildByName("startGameBtn") as Sprite);
_moreGameBtn = (display.getChildByName("moreGameBtn_fromFriendMC") as Sprite);
_photo = (display.getChildByName("photo") as MovieClip);
_photo.stop();
}
}
}//package code.ui
Section 33
//GameOption (code.ui.GameOption)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.tool.*;
import code.data.*;
public class GameOption {
private var _soundBtn:MovieClip;
private var __mc:Sprite;
private var _qualityBtn:MovieClip;
private var _musicBtn:MovieClip;
public function GameOption(mc:Sprite){
super();
__mc = mc;
initGameOption();
}
private function changeSound():void{
if (Data.SoundEable){
_soundBtn.gotoAndStop(1);
Data.SoundEable = true;
SoundsManager.modifySoundsVolume();
} else {
_soundBtn.gotoAndStop(3);
Data.SoundEable = false;
SoundsManager.modifySoundsVolume(0);
};
}
private function onMouseOverFun(e:MouseEvent):void{
SoundsManager.playSound("other_touch");
}
private function initMC():void{
_qualityBtn = (__mc.getChildByName("qualityBtn") as MovieClip);
_qualityBtn.buttonMode = true;
changeQuality();
_soundBtn = (__mc.getChildByName("soundBtn") as MovieClip);
_soundBtn.buttonMode = true;
changeSound();
_musicBtn = (__mc.getChildByName("musicBtn") as MovieClip);
_musicBtn.buttonMode = true;
changeMusic();
}
private function onMouseDown(event:MouseEvent):void{
switch (event.target){
case _qualityBtn:
SoundsManager.playSound("other_press");
Data.QualityType++;
if (Data.QualityType > 3){
Data.QualityType = 1;
};
changeQuality();
break;
case _musicBtn:
SoundsManager.playSound("other_press");
Data.MusicEable = !(Data.MusicEable);
changeMusic();
break;
case _soundBtn:
SoundsManager.playSound("other_press");
Data.SoundEable = !(Data.SoundEable);
changeSound();
break;
};
}
private function initEvent():void{
__mc.addEventListener(MouseEvent.MOUSE_DOWN, onMouseDown);
_qualityBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_musicBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_soundBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
public function del():void{
removeEvent();
removeMC();
}
private function removeEvent():void{
__mc.removeEventListener(MouseEvent.MOUSE_DOWN, onMouseDown);
}
private function changeQuality():void{
switch (Data.QualityType){
case 1:
__mc.stage.quality = StageQuality.BEST;
_qualityBtn.gotoAndStop(1);
Data.QualityType = 1;
break;
case 2:
__mc.stage.quality = StageQuality.MEDIUM;
_qualityBtn.gotoAndStop(2);
Data.QualityType = 2;
break;
case 3:
__mc.stage.quality = StageQuality.LOW;
_qualityBtn.gotoAndStop(3);
Data.QualityType = 3;
break;
};
}
private function changeMusic():void{
if (Data.MusicEable){
_musicBtn.gotoAndStop(1);
Data.MusicEable = true;
SoundsManager.modifyMusicVolume();
} else {
_musicBtn.gotoAndStop(3);
Data.MusicEable = false;
SoundsManager.modifyMusicVolume(0);
};
}
private function initGameOption():void{
initMC();
initEvent();
}
private function removeMC():void{
}
}
}//package code.ui
Section 34
//HowToPlay (code.ui.HowToPlay)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.tool.*;
import code.data.*;
public class HowToPlay extends UI {
private var _nextBtn:Sprite;
private var _backBtn:Sprite;
private var _skipBtn:Sprite;
public function HowToPlay(uim:UIManager, fun:Function=null){
super(uim);
init();
addClickStartBtnFun(fun);
}
private function onMouseOverFun(e:MouseEvent):void{
SoundsManager.playSound("window_touch");
}
override public function initMC():void{
var btnArr:Array;
if (Data.HowToPlayMC == ""){
btnArr = new Array("backBtn");
drawMC(btnArr);
} else {
setMC(Data.HowToPlayMC);
};
display.name = "howToPlayMC";
(display as MovieClip).addFrameScript(((display as MovieClip).totalFrames - 3), initBtn);
}
private function onClickSkipBtnFun(e:MouseEvent):void{
SoundsManager.playSound("window_press");
display.dispatchEvent(new Event("ClickStartBtn"));
uim.delHowToPlay();
}
private function addClickStartBtnFun(fun:Function):void{
var ClickStartBtnFun:Function;
var fun = fun;
if (fun != null){
ClickStartBtnFun = function (e:Event):void{
fun();
};
display.addEventListener("ClickStartBtn", ClickStartBtnFun);
};
}
private function onClickBackBtnFun(e:MouseEvent):void{
SoundsManager.playSound("window_press");
var curr:int = displayMC.currentFrame;
var total:int = displayMC.totalFrames;
if (curr <= (total - 2)){
displayMC.gotoAndStop(total);
} else {
displayMC.gotoAndStop((curr - 1));
};
}
private function addEvent():void{
_backBtn.addEventListener(MouseEvent.CLICK, onClickBackBtnFun);
_nextBtn.addEventListener(MouseEvent.CLICK, onClickNextBtnFun);
_skipBtn.addEventListener(MouseEvent.CLICK, onClickSkipBtnFun);
_backBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_nextBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_skipBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
private function initBtn():void{
displayMC.stop();
_backBtn = (display.getChildByName("BackBtn") as Sprite);
_nextBtn = (display.getChildByName("NextBtn") as Sprite);
_skipBtn = (display.getChildByName("SkipBtn") as Sprite);
addEvent();
displayMC.addFrameScript((displayMC.currentFrame - 1), null);
}
private function onClickNextBtnFun(e:MouseEvent):void{
SoundsManager.playSound("window_press");
var curr:int = displayMC.currentFrame;
var total:int = displayMC.totalFrames;
if (curr >= total){
displayMC.gotoAndStop((total - 2));
} else {
displayMC.gotoAndStop((curr + 1));
};
}
}
}//package code.ui
Section 35
//KeepInGame (code.ui.KeepInGame)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.tool.*;
public class KeepInGame extends UI {
private var _startGameBtn:Sprite;
private var _merchdiseBtn:MovieClip;
private var _mainMenuBtn:Sprite;
private var _moreGameBtn:Sprite;
public function KeepInGame(uim:UIManager){
super(uim);
init();
}
private function onMouseOverFun(e:MouseEvent):void{
SoundsManager.playSound("menu_touch");
}
override public function initMC():void{
setMC("KeepInGameMC");
_startGameBtn = (display.getChildByName("startGameBtn") as Sprite);
_mainMenuBtn = (display.getChildByName("mainMenuBtn") as Sprite);
_moreGameBtn = (display.getChildByName("moreGameBtn_KeepInGame") as Sprite);
_merchdiseBtn = (display.getChildByName("merchdiseBtn") as MovieClip);
_merchdiseBtn.addFrameScript(1, showTextFun);
}
private function onClickMerchdiseBtnFun(e:MouseEvent):void{
var url:String;
var bool:Boolean;
SoundsManager.playSound("menu_press");
if (url != null){
InterNet.getNewURL(url);
};
Tracker.shop(bool);
}
override public function initEvent():void{
_startGameBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_mainMenuBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_merchdiseBtn.addEventListener(MouseEvent.CLICK, onClickMerchdiseBtnFun);
_merchdiseBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_startGameBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_mainMenuBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
private function showTextFun():void{
var mc:MovieClip = (_merchdiseBtn.getChildByName("mc") as MovieClip);
mc.gotoAndStop(2);
}
private function onClickFun(e:MouseEvent):void{
SoundsManager.playSound("menu_press");
if (e.target == _startGameBtn.getChildByName("HitMC")){
uim.delKeepInGame();
uim.levelMap();
} else {
if (e.target == _mainMenuBtn.getChildByName("HitMC")){
uim.delKeepInGame();
uim.menu();
};
};
}
override public function removeEvent():void{
_startGameBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_mainMenuBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_merchdiseBtn.removeEventListener(MouseEvent.CLICK, onClickMerchdiseBtnFun);
_merchdiseBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_startGameBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_mainMenuBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
}
}//package code.ui
Section 36
//LevelFaild (code.ui.LevelFaild)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.logic.*;
import code.tool.*;
import code.data.*;
public class LevelFaild extends UI {
private var _mainMenuBtn:Sprite;
private var _isCatch:Boolean;
private var _controlBar:ControlList;
private var _rePalyBtn:Sprite;
public function LevelFaild(uim:UIManager, isCatch:Boolean=true){
super(uim);
_isCatch = isCatch;
init();
}
private function onHomePageFun(e:Event):void{
uim.delLevelFaild();
uim.menu();
}
private function onRePalyBtnClickFun(e:MouseEvent):void{
SoundsManager.playSound("menu_press");
uim.GM.reStart();
}
override public function initMC():void{
var contrlListMC:Sprite;
var btnArr:Array;
var btnArr2:Array;
if (_isCatch){
if (Data.LevelFaildMC1 == ""){
btnArr = new Array("rePalyBtn", "mainMenuBtn");
drawMC(btnArr);
} else {
setMC(Data.LevelFaildMC1);
};
contrlListMC = (display.getChildByName("controlListMC_BeCatch") as Sprite);
SoundsManager.playSound("person");
} else {
if (Data.LevelFaildMC2 == ""){
btnArr2 = new Array("rePalyBtn", "mainMenuBtn");
drawMC(btnArr2);
} else {
setMC(Data.LevelFaildMC2);
};
contrlListMC = (display.getChildByName("controlListMC_TimerOver") as Sprite);
};
_rePalyBtn = (display.getChildByName("rePalyBtn") as Sprite);
_mainMenuBtn = (display.getChildByName("mainMenuBtn") as Sprite);
_controlBar = new ControlList(contrlListMC);
}
private function onMouseOverFun(e:MouseEvent):void{
SoundsManager.playSound("menu_touch");
}
override public function initEvent():void{
_rePalyBtn.addEventListener(MouseEvent.CLICK, onRePalyBtnClickFun);
_mainMenuBtn.addEventListener(MouseEvent.CLICK, onMainMenuBtnClickFun);
_controlBar.display.addEventListener("HomePage_ConTrolList", onHomePageFun);
_rePalyBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_mainMenuBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
private function onMainMenuBtnClickFun(e:MouseEvent):void{
SoundsManager.playSound("menu_press");
uim.delLevelFaild();
uim.levelMap();
}
}
}//package code.ui
Section 37
//LevelMap (code.ui.LevelMap)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.logic.*;
import code.tool.*;
import code.data.*;
public class LevelMap extends UI {
private var _hasBtn:Boolean;
private var _merchdiseBtn:MovieClip;
private var _achievementBtn:MovieClip;
private var _controlBar:ControlList;
private var _levelArr:Array;
private var _creditBtn:Sprite;
public function LevelMap(uim:UIManager, hasBtn:Boolean=false){
super(uim);
_hasBtn = hasBtn;
init();
}
private function onClickMerchdiseBtnFun(e:MouseEvent):void{
var url:String;
var bool:Boolean;
if (url != null){
InterNet.getNewURL(url);
};
Tracker.shop(bool);
}
private function onClickFun(e:MouseEvent):void{
SoundsManager.playSound("other_press");
uim.delLevelMap();
uim.sendToFriend();
}
private function onLevelFun(e:MouseEvent):void{
SoundsManager.playSound("other_press");
var mc:Sprite = (e.target as Sprite);
var index:int = _levelArr.indexOf(mc.parent);
Data.LevelCurrNum = index;
uim.isSure();
}
private function getBtnArr():Array{
var arr:Array = new Array();
var i:int;
while (i < Data.LevelMaxNum) {
arr.push(("Level" + i));
i++;
};
return (arr);
}
private function mouseOutFun(event:MouseEvent):void{
_achievementBtn.gotoAndStop(_achievementBtn.totalFrames);
}
private function onClickCreditBtnFun(e:MouseEvent):void{
SoundsManager.playSound("other_press");
uim.pageChange();
}
override public function initMC():void{
var btnArr:Array;
if (Data.LevelMapMC == ""){
btnArr = getBtnArr();
drawMC(btnArr);
} else {
setMC(Data.LevelMapMC);
};
var mc:MovieClip = (display.getChildByName("mc") as MovieClip);
MCPlayer.stopMC(mc);
_creditBtn = (display.getChildByName("creditBtn") as Sprite);
_creditBtn.mouseChildren = false;
if (Cookie.da["Levelarr"][(Data.LevelMaxNum - 1)]["cup"] > PlayerStar.NoStar.value){
_creditBtn.visible = true;
} else {
_creditBtn.visible = false;
};
_achievementBtn = (display.getChildByName("achievementBtn") as MovieClip);
_achievementBtn.mouseChildren = false;
_achievementBtn.buttonMode = true;
_achievementBtn.gotoAndStop(_achievementBtn.totalFrames);
_merchdiseBtn = (display.getChildByName("merchdiseBtn") as MovieClip);
_merchdiseBtn.mouseChildren = false;
initLevelBtn();
var contrlListMC:Sprite = (display.getChildByName("controlListMC_levelMap") as Sprite);
_controlBar = new ControlList(contrlListMC);
}
private function initLevelBtn():void{
var star:int;
var ms:Sprite;
var mc:MovieClip;
var btn:Sprite;
_levelArr = new Array();
var i:int;
while (i < Data.LevelMaxNum) {
star = Cookie.da["Levelarr"][i]["cup"];
if (Data.LevelMapMC == ""){
ms = (display.getChildByName(("Level" + i)) as Sprite);
ms.buttonMode = true;
} else {
mc = (display.getChildByName(("Level" + i)) as MovieClip);
if (_hasBtn){
btn = (display.getChildByName(("LevelBtn" + i)) as Sprite);
} else {
mc.buttonMode = true;
};
};
if (i > Cookie.da["CurrLevel"]){
if (Data.LevelMapMC == ""){
ms.alpha = 0.1;
} else {
mc.gotoAndStop(1);
};
} else {
if (i < Cookie.da["CurrLevel"]){
if (Data.LevelMapMC == ""){
ms.alpha = 1;
ms.scaleX = star;
ms.addEventListener(MouseEvent.CLICK, onLevelFun);
} else {
mc.gotoAndStop(star);
if (_hasBtn){
btn.addEventListener(MouseEvent.CLICK, onLevelFun);
btn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
} else {
mc.addEventListener(MouseEvent.CLICK, onLevelFun);
mc.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
};
};
} else {
if (Data.LevelMapMC == ""){
ms.alpha = 1;
ms.addEventListener(MouseEvent.CLICK, onLevelFun);
} else {
mc.gotoAndStop(star);
trace("cao ta mabide zhe me chou de nan de ");
Fillter.light(mc, 30, 0xFF0000);
if (_hasBtn){
btn.addEventListener(MouseEvent.CLICK, onLevelFun);
btn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
} else {
mc.addEventListener(MouseEvent.CLICK, onLevelFun);
mc.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
};
};
};
};
if (Data.LevelMapMC == ""){
_levelArr.push(ms);
} else {
if (!_hasBtn){
_levelArr.push(mc);
} else {
_levelArr.push(btn);
};
};
i++;
};
}
private function onMerchdiseBtnMouseOverFun(e:MouseEvent):void{
_achievementBtn.gotoAndPlay(1);
SoundsManager.playSound("other_touch");
}
private function onMouseOverFun(e:MouseEvent):void{
SoundsManager.playSound("other_touch");
}
public function setEffectShow():void{
}
override public function initEvent():void{
_achievementBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_creditBtn.addEventListener(MouseEvent.CLICK, onClickCreditBtnFun);
_merchdiseBtn.addEventListener(MouseEvent.CLICK, onClickMerchdiseBtnFun);
_achievementBtn.addEventListener(MouseEvent.MOUSE_OVER, onMerchdiseBtnMouseOverFun);
_achievementBtn.addEventListener(MouseEvent.MOUSE_OUT, mouseOutFun);
}
override public function removeEvent():void{
_achievementBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_creditBtn.addEventListener(MouseEvent.CLICK, onClickCreditBtnFun);
_merchdiseBtn.removeEventListener(MouseEvent.CLICK, onClickMerchdiseBtnFun);
_achievementBtn.removeEventListener(MouseEvent.MOUSE_OUT, mouseOutFun);
_achievementBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMerchdiseBtnMouseOverFun);
_creditBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_merchdiseBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
}
}//package code.ui
Section 38
//LevelPass (code.ui.LevelPass)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.logic.*;
import code.tool.*;
import code.data.*;
public class LevelPass extends UI {
private var _starMC:MovieClip;
private var _geustMC:MovieClip;
private var _achievement:String;
private var _star:PlayerStar;
private var _controlBar:ControlList;
public function LevelPass(uim:UIManager, star:PlayerStar=null, achievement:String=null){
super(uim);
_star = star;
_achievement = achievement;
init();
}
private function onChangeStarFun():void{
_starMC = (display.getChildByName("starMC") as MovieClip);
if (_star == PlayerStar.GoldStar){
_starMC.gotoAndStop(3);
} else {
if (_star == PlayerStar.SilverStar){
_starMC.gotoAndStop(2);
} else {
if (_star == PlayerStar.BronzeStar){
_starMC.gotoAndStop(1);
};
};
};
}
override public function initMC():void{
var btnArr:Array;
if (Data.LevelPassMC == ""){
btnArr = new Array("againBtn", "mainMenuBtn");
drawMC(btnArr);
} else {
setMC(Data.LevelPassMC);
};
display.name = "levelPass";
displayMC.buttonMode = true;
displayMC.mouseChildren = false;
displayMC.addFrameScript(7, onDelMainFun);
displayMC.addFrameScript(6, onChangeGuestFun);
displayMC.addFrameScript(24, onChangeStarFun);
displayMC.addFrameScript(33, onCuPWarinFun);
displayMC.addFrameScript((displayMC.totalFrames - 1), onNextLevelFun);
var contrlListMC:Sprite = (display.getChildByName("controlListMC_LevelPass") as Sprite);
_controlBar = new ControlList(contrlListMC);
}
private function onNextLevelFun():void{
displayMC.stop();
display.stage.addEventListener(MouseEvent.CLICK, onClickFun);
}
private function onChangeGuestFun():void{
_geustMC = (display.getChildByName("photoMC") as MovieClip);
_geustMC.gotoAndStop(Data.LevelCurrNum);
}
private function onCuPWarinFun():void{
var mc:MovieClip = (display.getChildByName("cupWarningMC") as MovieClip);
if (_achievement == null){
mc.stop();
mc.visible = false;
} else {
Data.HasNewAchievement = true;
};
}
private function onDelMainFun():void{
uim.GM.endMain();
uim.levelMap(false);
uim.mc.swapChildrenAt(0, (uim.mc.numChildren - 1));
}
private function onClickFun(e:MouseEvent):void{
SoundsManager.playSound("other_press");
display.stage.removeEventListener(MouseEvent.CLICK, onClickFun);
uim.delPassLevel();
SoundsManager.playMusic("mainscreen_music");
if (Data.LevelCurrNum < Data.LevelMaxNum){
} else {
if (!Cookie.da["endGame"]){
uim.pageChange();
};
};
}
}
}//package code.ui
Section 39
//Loading (code.ui.Loading)
package code.ui {
import flash.display.*;
import flash.events.*;
import zlong.Template.*;
import flash.text.*;
import zlong.breathxue.utils.*;
public class Loading extends AbstractLoadingClass {
private var _mc_perBar:MovieClip;
private var _mc_perText:TextField;
private var _mc:Sprite;
private static const MC_CLASS_NAME:String = "LoadingMC";
public function Loading(pmc:Sprite){
super(pmc);
initDis(pmc);
initEvent();
}
private function delDis():void{
_mc.parent.removeChild(_mc);
}
private function initEvent():void{
_mc.addEventListener(Event.ENTER_FRAME, enterFrameHandler);
}
private function delEvent():void{
_mc.removeEventListener(Event.ENTER_FRAME, enterFrameHandler);
}
override public function destroy():void{
delEvent();
delDis();
}
private function enterFrameHandler(et:Event):void{
var percentSWF:Number = (_mc.root.loaderInfo.bytesLoaded / _mc.root.loaderInfo.bytesTotal);
_mc_perBar.gotoAndStop(int((percentSWF * 100)));
_mc_perText.text = (int(((percentSWF * 10000) / 100)) + "");
}
private function initDis(pmc:Sprite):void{
trace(Attach);
trace(Attach.getMovieClip(MC_CLASS_NAME));
_mc = Attach.getMovieClip(MC_CLASS_NAME);
pmc.addChild(_mc);
_mc_perBar = (_mc.getChildByName("loadingMc") as MovieClip);
_mc_perText = (_mc.getChildByName("percentText") as TextField);
}
}
}//package code.ui
Section 40
//Menu (code.ui.Menu)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.tool.*;
import code.data.*;
public class Menu extends UI {
private var _merchdiseBtn:MovieClip;
private var _gameOption:GameOption;
private var _startGameBtn:Sprite;
private var _moreGameBtn:Sprite;
private var _howToPlayBtn:Sprite;
private var _spillGameBtn:Sprite;
public function Menu(uim:UIManager){
super(uim);
init();
}
override public function removeEvent():void{
_startGameBtn.removeEventListener(MouseEvent.CLICK, onClickStartGameBtnFun);
_howToPlayBtn.removeEventListener(MouseEvent.CLICK, onClickHowToPlayBtnFun);
_spillGameBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_merchdiseBtn.removeEventListener(MouseEvent.CLICK, onClickMerchdiseBtnFun);
_moreGameBtn.removeEventListener(MouseEvent.CLICK, onClickMoreGameBtnFun);
_startGameBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_howToPlayBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_spillGameBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_merchdiseBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_moreGameBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
MyDispatcher.removeLangChangedListener(merchdiseFun);
}
private function merchdiseFun(e:Event):void{
}
private function onClickMoreGameBtnFun(e:MouseEvent):void{
SoundsManager.playSound("menu_press");
}
override public function initMC():void{
var btnArr:Array;
if (Data.MenuMC == ""){
btnArr = new Array("sartGameBtn", "howToPlayBtn", "moreGameBtn_menu");
drawMC(btnArr);
} else {
setMC(Data.MenuMC);
};
_startGameBtn = (display.getChildByName("sartGameBtn") as Sprite);
_howToPlayBtn = (display.getChildByName("howToPlayBtn") as Sprite);
_moreGameBtn = (display.getChildByName("moreGameBtn_menu") as Sprite);
_spillGameBtn = (display.getChildByName("spillGameBtn") as Sprite);
_merchdiseBtn = (display.getChildByName("merchdiseBtn") as MovieClip);
_merchdiseBtn.addFrameScript(1, showTextFun);
_gameOption = new GameOption(display);
}
private function onClickFun(e:MouseEvent):void{
SoundsManager.playSound("menu_press");
InterNet.getNewURL();
}
private function onClickMerchdiseBtnFun(e:MouseEvent):void{
var url:String;
var bool:Boolean;
SoundsManager.playSound("menu_press");
if (url != null){
InterNet.getNewURL(url);
};
Tracker.shop(bool);
}
override public function initEvent():void{
_startGameBtn.addEventListener(MouseEvent.CLICK, onClickStartGameBtnFun);
_howToPlayBtn.addEventListener(MouseEvent.CLICK, onClickHowToPlayBtnFun);
_spillGameBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_merchdiseBtn.addEventListener(MouseEvent.CLICK, onClickMerchdiseBtnFun);
_moreGameBtn.addEventListener(MouseEvent.CLICK, onClickMoreGameBtnFun);
_startGameBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_howToPlayBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_spillGameBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_merchdiseBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_moreGameBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
MyDispatcher.addLangChangedListener(merchdiseFun);
}
private function onMouseOverFun(e:MouseEvent):void{
SoundsManager.playSound("menu_touch");
}
private function showTextFun():void{
var mc:MovieClip = (_merchdiseBtn.getChildByName("mc") as MovieClip);
mc.gotoAndStop(1);
}
private function onClickHowToPlayBtnFun(e:MouseEvent):void{
SoundsManager.playSound("menu_press");
uim.howToPlay();
}
private function onClickStartGameBtnFun(e:MouseEvent):void{
SoundsManager.playSound("menu_press");
uim.delMenu();
uim.start();
}
}
}//package code.ui
Section 41
//MyTransition (code.ui.MyTransition)
package code.ui {
import flash.display.*;
import code.logic.*;
public class MyTransition extends UI {
private var _controlBar:ControlList;
private var _romvePreFun:Function;
public function MyTransition(uim:UIManager, fun:Function=null){
super(uim);
init();
setRemovePreFun(fun);
}
private function transitionFun():void{
_romvePreFun();
uim.GM.main();
uim.GM.stopGameFun();
uim.mc.swapChildrenAt(0, (uim.mc.numChildren - 1));
}
private function setRemovePreFun(fun:Function=null):void{
if (fun == null){
_romvePreFun = uim.delLevelMap;
} else {
_romvePreFun = fun;
};
}
private function endFun():void{
displayMC.stop();
uim.delTransition();
uim.initGame();
}
override public function initMC():void{
setMC("TransitionMC");
displayMC.addFrameScript(19, transitionFun);
displayMC.addFrameScript((displayMC.totalFrames - 1), endFun);
var contrlListMC:Sprite = (display.getChildByName("controlListMC_Transition") as Sprite);
_controlBar = new ControlList(contrlListMC);
_controlBar.setAllBtnActiveeable();
}
}
}//package code.ui
Section 42
//PageChange (code.ui.PageChange)
package code.ui {
import flash.events.*;
public class PageChange extends UI {
private var _isPre:Boolean;
public function PageChange(uim:UIManager, isPre:Boolean=false){
super(uim);
_isPre = isPre;
init();
}
private function addNextPage():void{
uim.delLevelMap();
uim.credits();
uim.mc.swapChildrenAt(0, (uim.mc.numChildren - 1));
}
override public function removeEvent():void{
display.removeEventListener(Event.ENTER_FRAME, run);
}
private function addPrePage():void{
uim.delCredits();
uim.levelMap();
uim.mc.swapChildrenAt(0, (uim.mc.numChildren - 1));
}
override public function initEvent():void{
display.addEventListener(Event.ENTER_FRAME, run);
}
private function remove():void{
displayMC.stop();
uim.delPageChange();
}
override public function initMC():void{
setMC("ChangePageMC");
var total:int = (displayMC.totalFrames - 1);
if (_isPre){
displayMC.addFrameScript(10, addPrePage);
displayMC.addFrameScript(1, remove);
} else {
displayMC.addFrameScript(10, addNextPage);
displayMC.addFrameScript(total, remove);
};
}
private function run(e:Event):void{
if (_isPre){
displayMC.gotoAndStop((((displayMC.currentFrame - 1) > 0)) ? (displayMC.currentFrame - 1) : displayMC.totalFrames);
};
}
}
}//package code.ui
Section 43
//SetAsAvatar (code.ui.SetAsAvatar)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.logic.*;
import code.tool.*;
import fl.transitions.*;
import code.data.*;
import fl.transitions.easing.*;
public class SetAsAvatar extends UI {
private const _photoNameArr:Array;
private var _btnArr:Array;
private var _controlBar:ControlList;
private var _backBTn:Sprite;
private var _preBtn:Sprite;
private var _seatArr:Array;
private var _avatarafter:MovieClip;
private var _currPhotoNum:Number;// = 0
private var _nextBtn:Sprite;
private var _frame:int;// = 1
private var _photoArr:Array;
private var _avatarbefore:MovieClip;
public function SetAsAvatar(m:UIManager){
_photoNameArr = new Array("PhotoAlbum_photo02_01", "PhotoAlbum_photo02_02", "PhotoAlbum_photo02_03", "PhotoAlbum_photo02_04", "PhotoAlbum_photo02_05", "PhotoAlbum_photo02_06", "PhotoAlbum_photo02_07", "PhotoAlbum_photo02_08", "PhotoAlbum_photo02_09", "PhotoAlbum_photo02_10", "PhotoAlbum_photo02_11", "PhotoAlbum_photo02_12");
super(m);
init();
}
override public function initEvent():void{
_preBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_preBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_nextBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_nextBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_backBTn.addEventListener(MouseEvent.CLICK, onClickFun);
_backBTn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverOverFun);
_avatarbefore.addEventListener(MouseEvent.CLICK, onClickFun);
_avatarbefore.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverOverFun);
_avatarafter.addEventListener(MouseEvent.CLICK, onClickFun);
_avatarafter.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverOverFun);
_controlBar.display.addEventListener("HomePage_ConTrolList", homeBtClick);
}
private function onClickFun(e:MouseEvent):void{
switch (e.target){
case _backBTn.getChildByName("HitMC"):
SoundsManager.playSound("menu_press");
uim.delSentToFriend();
uim.levelMap();
break;
case _nextBtn.getChildByName("HitMC"):
SoundsManager.playSound("other_press");
changeRim();
break;
case _preBtn.getChildByName("HitMC"):
SoundsManager.playSound("other_press");
changeRim(false);
break;
case _avatarbefore.getChildByName("HitMC"):
SoundsManager.playSound("other_press");
uim.setAsAvatar("beforeavatar", _frame);
break;
case _avatarafter.getChildByName("HitMC"):
SoundsManager.playSound("other_press");
uim.setAsAvatar("afteravatar", _frame);
break;
};
}
override public function removeEvent():void{
_preBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_preBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_nextBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_nextBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_backBTn.removeEventListener(MouseEvent.CLICK, onClickFun);
_backBTn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverOverFun);
_avatarbefore.removeEventListener(MouseEvent.CLICK, onClickFun);
_avatarbefore.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverOverFun);
_avatarafter.removeEventListener(MouseEvent.CLICK, onClickFun);
_avatarafter.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverOverFun);
_controlBar.display.removeEventListener("HomePage_ConTrolList", homeBtClick);
}
private function changeRim(bool:Boolean=true):void{
if (bool){
_currPhotoNum++;
if (_currPhotoNum >= _photoNameArr.length){
_currPhotoNum = 0;
};
} else {
_currPhotoNum--;
if (_currPhotoNum < 0){
_currPhotoNum = (_photoNameArr.length - 1);
};
};
getNewPhoto();
}
private function homeBtClick(e:Event):void{
uim.delSentToFriend();
uim.menu();
}
private function initDis():void{
_preBtn = (display.getChildByName("preBtn") as Sprite);
_nextBtn = (display.getChildByName("nextBtn") as Sprite);
_backBTn = (display.getChildByName("backBtn") as Sprite);
_avatarbefore = (display.getChildByName("avatarbefore") as MovieClip);
_avatarafter = (display.getChildByName("avatarafter") as MovieClip);
display["makeupbefore"].gotoAndStop(1);
display["makeupafter"].gotoAndStop(1);
var contrlListMC:Sprite = (display.getChildByName("controlListMC_Achievement") as Sprite);
_controlBar = new ControlList(contrlListMC);
}
private function changePhoto():void{
var photo:MovieClip;
var index:int;
_photoArr = new Array();
var i:int;
while (i < _seatArr.length) {
index = offsetCurrPhotoNum((_currPhotoNum + i));
photo = Attach.getMovieClip(_photoNameArr[index]);
photo.x = _seatArr[i][0];
photo.y = _seatArr[i][1];
photo.name = _photoNameArr[index];
display.addChildAt(photo, _seatArr[i][2]);
if (index < 2){
photo.gotoAndStop(1);
} else {
if (checkOpen(index)){
photo.gotoAndStop(1);
} else {
photo.gotoAndStop(2);
};
};
_photoArr.push(photo);
TransitionManager.start(photo, {type:Fade, direction:Transition.IN, duration:1, easing:None.easeNone});
i++;
};
}
override public function initMC():void{
this.setMC("SendtofriendMC");
initDis();
initPhone();
}
private function getNewPhoto():void{
var mc:MovieClip;
var i:int;
while (i < _photoArr.length) {
mc = _photoArr[i];
display.removeChild(mc);
i++;
};
changePhoto();
}
private function checkOpen(index:Number):Boolean{
var opposite:Number = (index - 2);
if (Cookie.da["Levelarr"][opposite]["cup"] > 2){
return (true);
};
return (false);
}
private function onMouseOverFun(e:MouseEvent):void{
SoundsManager.playSound("other_touch");
}
private function onClickPhotoFun(e:MouseEvent):void{
SoundsManager.playSound("other_press");
var index:int = _btnArr.indexOf((e.target as Sprite).parent);
_frame = (offsetCurrPhotoNum((_currPhotoNum + index)) + 1);
trace(_frame);
if ((display.getChildByName(_photoNameArr[(_frame - 1)]) as MovieClip).currentFrame == 1){
display["makeupbefore"].gotoAndStop(_frame);
display["makeupafter"].gotoAndStop(_frame);
};
}
private function onMouseOverOverFun(e:MouseEvent):void{
SoundsManager.playSound("menu_touch");
}
private function offsetCurrPhotoNum(num:int):int{
var index:int = num;
if (index < 0){
index = (index + _photoNameArr.length);
};
if (index >= _photoNameArr.length){
index = (index - _photoNameArr.length);
};
return (index);
}
private function initPhone():void{
var mc:Sprite;
var index:int;
var photo:MovieClip;
_btnArr = new Array();
_seatArr = new Array();
_photoArr = new Array();
var i:int;
while (i < 3) {
mc = (display.getChildByName(("photo" + (i + 1).toString())) as Sprite);
mc.addEventListener(MouseEvent.CLICK, onClickPhotoFun);
mc.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_btnArr.push(mc);
index = display.getChildIndex(mc);
photo = Attach.getMovieClip(_photoNameArr[(_currPhotoNum + i)]);
photo.x = mc.x;
photo.y = mc.y;
photo.name = _photoNameArr[(_currPhotoNum + i)];
display.addChildAt(photo, index);
if ((_currPhotoNum + i) < 2){
photo.gotoAndStop(1);
} else {
if (checkOpen((_currPhotoNum + i))){
photo.gotoAndStop(1);
} else {
photo.gotoAndStop(2);
};
};
_photoArr.push(photo);
_seatArr.push(new Array(mc.x, mc.y, index));
i++;
};
}
}
}//package code.ui
Section 44
//SetAsAvatarLoading (code.ui.SetAsAvatarLoading)
package code.ui {
import flash.display.*;
import flash.events.*;
import zlong.spilSystemTool.*;
import code.logic.*;
import code.tool.*;
import code.data.*;
public class SetAsAvatarLoading extends UI {
private var _afterOrBefore:String;
private var _gs:GamatarSender;
private var _bigPicBmd:BitmapData;
private var _controlBar:ControlList;
private var _sign:int;
private var _tryagain:Sprite;
private var _photo:MovieClip;
private var _smallPicBmd:BitmapData;
private var _backBt:Sprite;
private var _displayTime:int;// = 60
public function SetAsAvatarLoading(uim:UIManager, afterOrBefore:String, sign:int){
super(uim);
_afterOrBefore = afterOrBefore;
_sign = sign;
initGs();
init();
}
private function upload():void{
var isUpload:Boolean = _gs.sendAvatar(_smallPicBmd, _bigPicBmd);
if (isUpload){
trace("执行了一次");
} else {
uploadFailedDisplay();
};
}
private function uploadFailedDisplay():void{
display["signuptext"].visible = false;
display["loadingbar"].visible = false;
display["loadingtext"].gotoAndStop(3);
_backBt.visible = true;
_tryagain.visible = true;
initUploadingLoadingBtEvent();
}
private function clickTryAgain(event:MouseEvent):void{
SoundsManager.playSound("window_press");
upload();
}
private function delayForDisplaySuccess(event:Event):void{
_displayTime--;
if (_displayTime == 0){
display.removeEventListener(Event.ENTER_FRAME, delayForDisplaySuccess);
uim.delSetAsAvatar();
};
}
private function clickBack(event:MouseEvent):void{
SoundsManager.playSound("window_press");
uim.delSetAsAvatar();
}
private function uploadComplete(event:GamatarSender):void{
display["signuptext"].visible = false;
display["loadingbar"].visible = false;
display["loadingtext"].gotoAndStop(2);
display.addEventListener(Event.ENTER_FRAME, delayForDisplaySuccess);
}
private function initGs():void{
_gs = new GamatarSender();
_gs.addEventListener(GamatarSender.GAMATAR_SENT_COMPLETE, uploadComplete);
_gs.addEventListener(GamatarSender.GAMATAR_SENT_ERROR, uploadFailed);
}
private function createBMD():void{
_bigPicBmd = createPicBmd(150);
_smallPicBmd = createPicBmd(50);
}
private function uploadFailed(event:GamatarSender):void{
uploadFailedDisplay();
}
override public function removeMC():void{
_gs = null;
display.parent.removeChild(display);
display = null;
}
private function onMouseOverFun(event:MouseEvent):void{
SoundsManager.playSound("window_touch");
}
private function createPicBmd(dimetricWidth:Number):BitmapData{
_photo.width = dimetricWidth;
_photo.height = dimetricWidth;
var temp:Sprite = new Sprite();
temp.addChild(_photo);
var bmd:BitmapData = new BitmapData(dimetricWidth, dimetricWidth, true, 0xFFFF);
bmd.draw(temp);
return (bmd);
}
private function initBtn():void{
(display as MovieClip).stop();
_backBt = (display.getChildByName("back") as Sprite);
_tryagain = (display.getChildByName("tryagain") as Sprite);
_backBt.visible = false;
_tryagain.visible = false;
display["loadingtext"].gotoAndStop(1);
upload();
}
override public function initMC():void{
var btnArr:Array;
_photo = Attach.getMovieClip(((_afterOrBefore + "_") + _sign));
trace(_photo);
if (Data.SetAsAvatarMC == ""){
btnArr = new Array("tryagain", "back");
drawMC(btnArr);
} else {
setMC(Data.SetAsAvatarMC);
(display as MovieClip).addFrameScript(((display as MovieClip).totalFrames - 1), initBtn);
display.name = Data.SetAsAvatarMC;
};
createBMD();
}
override public function initEvent():void{
}
override public function removeEvent():void{
_backBt.removeEventListener(MouseEvent.CLICK, clickBack);
_tryagain.removeEventListener(MouseEvent.CLICK, clickTryAgain);
_gs.removeEventListener(GamatarSender.GAMATAR_SENT_COMPLETE, uploadComplete);
_gs.removeEventListener(GamatarSender.GAMATAR_SENT_ERROR, uploadFailed);
}
private function initUploadingLoadingBtEvent():void{
_backBt.addEventListener(MouseEvent.CLICK, clickBack);
_tryagain.addEventListener(MouseEvent.CLICK, clickTryAgain);
_backBt.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_tryagain.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
}
}//package code.ui
Section 45
//SiteLock (code.ui.SiteLock)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.tool.*;
public class SiteLock extends UI {
private var _startGameBtn:Sprite;
public function SiteLock(uim:UIManager){
super(uim);
init();
}
private function onClickFun(e:MouseEvent):void{
SoundsManager.playSound("menu_press");
}
override public function removeEvent():void{
_startGameBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
}
override public function initEvent():void{
_startGameBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_startGameBtn.addEventListener(MouseEvent.ROLL_OVER, oRollOverFun);
}
override public function initMC():void{
setMC("SiteLockMC");
_startGameBtn = (display.getChildByName("startGameBtn_AddUI") as Sprite);
}
private function oRollOverFun(e:MouseEvent):void{
SoundsManager.playSound("menu_touch");
}
}
}//package code.ui
Section 46
//SureMC (code.ui.SureMC)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.tool.*;
import code.data.*;
public class SureMC extends UI {
private var _starMC:MovieClip;
private var _playBrn:Sprite;
private var _backBtn:Sprite;
public function SureMC(uim:UIManager){
super(uim);
init();
}
private function initStarFun():void{
_starMC = (display.getChildByName("starMC") as MovieClip);
var frame:int = (Cookie.da["Levelarr"][Data.LevelCurrNum]["cup"] - 1);
if (frame <= 0){
frame = 1;
};
_starMC.gotoAndStop(frame);
}
private function onMouseOverFun(e:MouseEvent):void{
SoundsManager.playSound("window_touch");
}
override public function initMC():void{
setMC("POPMC");
displayMC.addFrameScript((displayMC.totalFrames - 1), initBtn);
}
public function initBtn():void{
displayMC.stop();
_playBrn = (display.getChildByName("playBrn") as Sprite);
_backBtn = (display.getChildByName("backBtn") as Sprite);
initStarFun();
addEvent();
}
private function onClickFun(e:MouseEvent):void{
SoundsManager.playSound("window_press");
if (e.target == _playBrn.getChildByName("HitMC")){
uim.delSure();
uim.transition();
} else {
if (e.target == _backBtn.getChildByName("HitMC")){
uim.delSure();
};
};
}
private function addEvent():void{
_playBrn.addEventListener(MouseEvent.CLICK, onClickFun);
_backBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_playBrn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_backBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
override public function removeEvent():void{
_playBrn.removeEventListener(MouseEvent.CLICK, onClickFun);
_backBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_playBrn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_backBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
}
}//package code.ui
Section 47
//UI (code.ui.UI)
package code.ui {
import flash.display.*;
import code.tool.*;
import code.data.*;
public class UI {
private var _uim:UIManager;
private var __mc:Sprite;
public function UI(uim:UIManager){
super();
_uim = uim;
}
public function removeMC():void{
__mc.parent.removeChild(__mc);
__mc = null;
}
public function get display():Sprite{
return (__mc);
}
public function set display(mc:Sprite):void{
__mc = mc;
}
public function initMC():void{
}
public function initEvent():void{
}
public function del():void{
removeEvent();
removeMC();
}
public function init():void{
initMC();
initEvent();
}
public function setMC(s:String):void{
__mc = Attach.getSprite(s);
_uim.mc.addChild(__mc);
}
public function get uim():UIManager{
return (_uim);
}
public function drawMC(btnArr:Array=null):void{
var i:int;
var mc:Sprite;
__mc = new Sprite();
MyDrawSprite.draw(__mc, MyDrawSprite.Rect, Data.stageWidth, Data.stageHeight);
__mc.x = (Data.stageWidth / 2);
__mc.y = (Data.stageHeight / 2);
_uim.mc.addChild(__mc);
if (btnArr != null){
i = 0;
while (i < btnArr.length) {
mc = new Sprite();
mc.name = btnArr[i];
MyDrawSprite.draw(mc, MyDrawSprite.Rect, 80, 20);
mc.x = 0;
mc.y = (-200 + (40 * i));
display.addChild(mc);
i++;
};
};
}
public function removeEvent():void{
}
public function get displayMC():MovieClip{
return ((__mc as MovieClip));
}
}
}//package code.ui
Section 48
//UIManager (code.ui.UIManager)
package code.ui {
import flash.display.*;
import zlong.spilSystemTool.*;
import code.logic.*;
import code.tool.*;
public class UIManager {
private var _lManager:LManager;
private var _levelFaild:LevelFaild;
private var _sureMC:SureMC;
private var _fromFriend:FromFriend;
private var _levelMap:LevelMap;
private var _sendToFriend:SetAsAvatar;
private var _levelPass:LevelPass;
private var _pageChange:PageChange;
private var _howToPlay:HowToPlay;
private var _menu:Menu;
private var _keepGameInGame:KeepInGame;
private var _credits:CreditsClass;
private var _setAsAvatar:SetAsAvatarLoading;
private var _achievement:Achievement;
private var _transition:MyTransition;
private var __mc:Sprite;
public function UIManager(Pmc:Sprite){
super();
__mc = new Sprite();
__mc.name = "Game";
Pmc.addChild(__mc);
menu();
}
public function delHowToPlay():void{
_howToPlay.del();
_howToPlay = null;
}
public function delMenu():void{
_menu.del();
_menu = null;
}
public function delPageChange():void{
_pageChange.del();
_pageChange = null;
}
public function keepInGame():void{
_keepGameInGame = new KeepInGame(this);
Tracker.half();
}
public function get mc():Sprite{
return (__mc);
}
public function delCredits():void{
_credits.del();
_credits = null;
}
public function delKeepInGame():void{
_keepGameInGame.del();
_keepGameInGame = null;
}
public function credits():void{
_credits = new CreditsClass(this);
}
public function delAchievement():void{
_achievement.del();
_achievement = null;
}
public function pageChange(isPree:Boolean=false):void{
_pageChange = new PageChange(this, isPree);
if (isPree){
SoundsManager.playSound("pageback");
} else {
SoundsManager.playSound("pagego");
};
}
public function delPassLevel():void{
_levelPass.del();
_levelPass = null;
}
public function initGame():void{
_lManager.initGameFun();
}
public function setAsAvatar(afterOrBefore:String, sign:int):void{
_setAsAvatar = new SetAsAvatarLoading(this, afterOrBefore, sign);
}
public function achievement():void{
_achievement = new Achievement(this);
SoundsManager.playMusic("achievements_music");
}
public function setEffectShow():void{
}
public function delSetAsAvatar():void{
_setAsAvatar.del();
_setAsAvatar = null;
}
public function levelMap(addMusic:Boolean=true):void{
_levelMap = new LevelMap(this, true);
if (addMusic){
SoundsManager.playMusic("mainscreen_music");
};
}
public function sendToFriend():void{
_sendToFriend = new SetAsAvatar(this);
SoundsManager.playMusic("mainscreen_music");
}
public function howToPlay(fun:Function=null):void{
_howToPlay = new HowToPlay(this, fun);
SoundsManager.playSound("jumpwindow");
}
public function delSure():void{
_sureMC.del();
}
public function delTransition():void{
_transition.del();
}
public function delFromFriend():void{
_fromFriend.del();
_fromFriend = null;
}
public function delLevelFaild():void{
_levelFaild.del();
_levelFaild = null;
SoundsManager.stopMusic();
}
public function transition(fun:Function=null):void{
_transition = new MyTransition(this, fun);
SoundsManager.playSound("camera");
}
public function protect():void{
new SiteLock(this);
}
public function menu():void{
_menu = new Menu(this);
SoundsManager.playMusic("mainscreen_music");
GoogleEvent.instance.gaTrackEvent("mainscreen viewed");
}
public function levelFaild(isCatch:Boolean):void{
_levelFaild = new LevelFaild(this, isCatch);
SoundsManager.playMusic("failed_music");
}
public function delLevelMap():void{
_levelMap.del();
_levelMap = null;
}
public function isSure():void{
_sureMC = new SureMC(this);
SoundsManager.playSound("jumpwindow");
}
public function start():void{
_lManager = new LManager(this);
}
public function delSentToFriend():void{
_sendToFriend.del();
_sendToFriend = null;
}
public function get GM():LManager{
return (_lManager);
}
public function passLevel(star:PlayerStar=null, achievement:String=null):void{
_levelPass = new LevelPass(this, star, achievement);
SoundsManager.playSound("camera");
}
}
}//package code.ui
Section 49
//BitString (com.adobe.images.BitString)
package com.adobe.images {
public class BitString {
public var val:int;// = 0
public var len:int;// = 0
public function BitString(){
super();
}
}
}//package com.adobe.images
Section 50
//JPGEncoder (com.adobe.images.JPGEncoder)
package com.adobe.images {
import flash.display.*;
import flash.utils.*;
import flash.geom.*;
public class JPGEncoder {
private var fdtbl_UV:Array;
private var std_ac_chrominance_values:Array;
private var std_dc_chrominance_values:Array;
private var ZigZag:Array;
private var YDC_HT:Array;
private var YAC_HT:Array;
private var bytenew:int;// = 0
private var fdtbl_Y:Array;
private var std_ac_chrominance_nrcodes:Array;
private var DU:Array;
private var std_ac_luminance_values:Array;
private var std_dc_chrominance_nrcodes:Array;
private var UVTable:Array;
private var YDU:Array;
private var UDU:Array;
private var byteout:ByteArray;
private var UVAC_HT:Array;
private var UVDC_HT:Array;
private var bytepos:int;// = 7
private var VDU:Array;
private var std_ac_luminance_nrcodes:Array;
private var std_dc_luminance_values:Array;
private var YTable:Array;
private var std_dc_luminance_nrcodes:Array;
private var bitcode:Array;
private var category:Array;
public function JPGEncoder(quality:Number=50){
this.ZigZag = [0, 1, 5, 6, 14, 15, 27, 28, 2, 4, 7, 13, 16, 26, 29, 42, 3, 8, 12, 17, 25, 30, 41, 43, 9, 11, 18, 24, 31, 40, 44, 53, 10, 19, 23, 32, 39, 45, 52, 54, 20, 22, 33, 38, 46, 51, 55, 60, 21, 34, 37, 47, 50, 56, 59, 61, 35, 36, 48, 49, 57, 58, 62, 63];
this.YTable = new Array(64);
this.UVTable = new Array(64);
this.fdtbl_Y = new Array(64);
this.fdtbl_UV = new Array(64);
this.std_dc_luminance_nrcodes = [0, 0, 1, 5, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0];
this.std_dc_luminance_values = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11];
this.std_ac_luminance_nrcodes = [0, 0, 2, 1, 3, 3, 2, 4, 3, 5, 5, 4, 4, 0, 0, 1, 125];
this.std_ac_luminance_values = [1, 2, 3, 0, 4, 17, 5, 18, 33, 49, 65, 6, 19, 81, 97, 7, 34, 113, 20, 50, 129, 145, 161, 8, 35, 66, 177, 193, 21, 82, 209, 240, 36, 51, 98, 114, 130, 9, 10, 22, 23, 24, 25, 26, 37, 38, 39, 40, 41, 42, 52, 53, 54, 55, 56, 57, 58, 67, 68, 69, 70, 71, 72, 73, 74, 83, 84, 85, 86, 87, 88, 89, 90, 99, 100, 101, 102, 103, 104, 105, 106, 115, 116, 117, 118, 119, 120, 121, 122, 131, 132, 133, 134, 135, 136, 137, 138, 146, 147, 148, 149, 150, 151, 152, 153, 154, 162, 163, 164, 165, 166, 167, 168, 169, 170, 178, 179, 180, 181, 182, 183, 184, 185, 186, 194, 195, 196, 197, 198, 199, 200, 201, 202, 210, 211, 212, 213, 214, 215, 216, 217, 218, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 241, 242, 243, 244, 245, 246, 247, 248, 249, 250];
this.std_dc_chrominance_nrcodes = [0, 0, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0];
this.std_dc_chrominance_values = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11];
this.std_ac_chrominance_nrcodes = [0, 0, 2, 1, 2, 4, 4, 3, 4, 7, 5, 4, 4, 0, 1, 2, 119];
this.std_ac_chrominance_values = [0, 1, 2, 3, 17, 4, 5, 33, 49, 6, 18, 65, 81, 7, 97, 113, 19, 34, 50, 129, 8, 20, 66, 145, 161, 177, 193, 9, 35, 51, 82, 240, 21, 98, 114, 209, 10, 22, 36, 52, 225, 37, 241, 23, 24, 25, 26, 38, 39, 40, 41, 42, 53, 54, 55, 56, 57, 58, 67, 68, 69, 70, 71, 72, 73, 74, 83, 84, 85, 86, 87, 88, 89, 90, 99, 100, 101, 102, 103, 104, 105, 106, 115, 116, 117, 118, 119, 120, 121, 122, 130, 131, 132, 133, 134, 135, 136, 137, 138, 146, 147, 148, 149, 150, 151, 152, 153, 154, 162, 163, 164, 165, 166, 167, 168, 169, 170, 178, 179, 180, 181, 182, 183, 184, 185, 186, 194, 195, 196, 197, 198, 199, 200, 201, 202, 210, 211, 212, 213, 214, 215, 216, 217, 218, 226, 227, 228, 229, 230, 231, 232, 233, 234, 242, 243, 244, 245, 246, 247, 248, 249, 250];
this.bitcode = new Array(0xFFFF);
this.category = new Array(0xFFFF);
this.DU = new Array(64);
this.YDU = new Array(64);
this.UDU = new Array(64);
this.VDU = new Array(64);
super();
if (quality <= 0){
quality = 1;
};
if (quality > 100){
quality = 100;
};
var sf:int;
if (quality < 50){
sf = int((5000 / quality));
} else {
sf = int((200 - (quality * 2)));
};
this.initHuffmanTbl();
this.initCategoryNumber();
this.initQuantTables(sf);
}
private function initHuffmanTbl():void{
this.YDC_HT = this.computeHuffmanTbl(this.std_dc_luminance_nrcodes, this.std_dc_luminance_values);
this.UVDC_HT = this.computeHuffmanTbl(this.std_dc_chrominance_nrcodes, this.std_dc_chrominance_values);
this.YAC_HT = this.computeHuffmanTbl(this.std_ac_luminance_nrcodes, this.std_ac_luminance_values);
this.UVAC_HT = this.computeHuffmanTbl(this.std_ac_chrominance_nrcodes, this.std_ac_chrominance_values);
}
private function RGB2YUV(img:BitmapData, xpos:int, ypos:int):void{
var x:int;
var P:uint;
var R:Number;
var G:Number;
var B:Number;
var pos:int;
var y:int;
while (y < 8) {
x = 0;
while (x < 8) {
P = img.getPixel32((xpos + x), (ypos + y));
R = Number(((P >> 16) & 0xFF));
G = Number(((P >> 8) & 0xFF));
B = Number((P & 0xFF));
this.YDU[pos] = ((((0.299 * R) + (0.587 * G)) + (0.114 * B)) - 128);
this.UDU[pos] = (((-0.16874 * R) + (-0.33126 * G)) + (0.5 * B));
this.VDU[pos] = (((0.5 * R) + (-0.41869 * G)) + (-0.08131 * B));
pos++;
x++;
};
y++;
};
}
private function writeBits(bs:BitString):void{
var value:int = bs.val;
var posval:int = (bs.len - 1);
while (posval >= 0) {
if ((value & uint((1 << posval)))){
this.bytenew = (this.bytenew | uint((1 << this.bytepos)));
};
posval--;
this.bytepos--;
if (this.bytepos < 0){
if (this.bytenew == 0xFF){
this.writeByte(0xFF);
this.writeByte(0);
} else {
this.writeByte(this.bytenew);
};
this.bytepos = 7;
this.bytenew = 0;
};
};
}
private function writeWord(value:int):void{
this.writeByte(((value >> 8) & 0xFF));
this.writeByte((value & 0xFF));
}
private function writeByte(value:int):void{
this.byteout.writeByte(value);
}
private function writeDHT():void{
var i:int;
this.writeWord(65476);
this.writeWord(418);
this.writeByte(0);
i = 0;
while (i < 16) {
this.writeByte(this.std_dc_luminance_nrcodes[(i + 1)]);
i++;
};
i = 0;
while (i <= 11) {
this.writeByte(this.std_dc_luminance_values[i]);
i++;
};
this.writeByte(16);
i = 0;
while (i < 16) {
this.writeByte(this.std_ac_luminance_nrcodes[(i + 1)]);
i++;
};
i = 0;
while (i <= 161) {
this.writeByte(this.std_ac_luminance_values[i]);
i++;
};
this.writeByte(1);
i = 0;
while (i < 16) {
this.writeByte(this.std_dc_chrominance_nrcodes[(i + 1)]);
i++;
};
i = 0;
while (i <= 11) {
this.writeByte(this.std_dc_chrominance_values[i]);
i++;
};
this.writeByte(17);
i = 0;
while (i < 16) {
this.writeByte(this.std_ac_chrominance_nrcodes[(i + 1)]);
i++;
};
i = 0;
while (i <= 161) {
this.writeByte(this.std_ac_chrominance_values[i]);
i++;
};
}
public function encode(image:BitmapData):ByteArray{
var xpos:int;
var fillbits:BitString;
this.byteout = new ByteArray();
this.bytenew = 0;
this.bytepos = 7;
this.writeWord(65496);
this.writeAPP0();
this.writeDQT();
this.writeSOF0(image.width, image.height);
this.writeDHT();
this.writeSOS();
var DCY:Number = 0;
var DCU:Number = 0;
var DCV:Number = 0;
this.bytenew = 0;
this.bytepos = 7;
var ypos:int;
while (ypos < image.height) {
xpos = 0;
while (xpos < image.width) {
this.RGB2YUV(image, xpos, ypos);
DCY = this.processDU(this.YDU, this.fdtbl_Y, DCY, this.YDC_HT, this.YAC_HT);
DCU = this.processDU(this.UDU, this.fdtbl_UV, DCU, this.UVDC_HT, this.UVAC_HT);
DCV = this.processDU(this.VDU, this.fdtbl_UV, DCV, this.UVDC_HT, this.UVAC_HT);
xpos = (xpos + 8);
};
ypos = (ypos + 8);
};
if (this.bytepos >= 0){
fillbits = new BitString();
fillbits.len = (this.bytepos + 1);
fillbits.val = ((1 << (this.bytepos + 1)) - 1);
this.writeBits(fillbits);
};
this.writeWord(65497);
return (this.byteout);
}
private function initCategoryNumber():void{
var nr:int;
var nrlower = 1;
var nrupper = 2;
var cat = 1;
while (cat <= 15) {
nr = nrlower;
while (nr < nrupper) {
this.category[(32767 + nr)] = cat;
this.bitcode[(32767 + nr)] = new BitString();
this.bitcode[(32767 + nr)].len = cat;
this.bitcode[(32767 + nr)].val = nr;
nr++;
};
nr = -((nrupper - 1));
while (nr <= -(nrlower)) {
this.category[(32767 + nr)] = cat;
this.bitcode[(32767 + nr)] = new BitString();
this.bitcode[(32767 + nr)].len = cat;
this.bitcode[(32767 + nr)].val = ((nrupper - 1) + nr);
nr++;
};
nrlower = (nrlower << 1);
nrupper = (nrupper << 1);
cat++;
};
}
private function writeDQT():void{
var i:int;
this.writeWord(65499);
this.writeWord(132);
this.writeByte(0);
i = 0;
while (i < 64) {
this.writeByte(this.YTable[i]);
i++;
};
this.writeByte(1);
i = 0;
while (i < 64) {
this.writeByte(this.UVTable[i]);
i++;
};
}
private function writeAPP0():void{
this.writeWord(65504);
this.writeWord(16);
this.writeByte(74);
this.writeByte(70);
this.writeByte(73);
this.writeByte(70);
this.writeByte(0);
this.writeByte(1);
this.writeByte(1);
this.writeByte(0);
this.writeWord(1);
this.writeWord(1);
this.writeByte(0);
this.writeByte(0);
}
private function writeSOS():void{
this.writeWord(65498);
this.writeWord(12);
this.writeByte(3);
this.writeByte(1);
this.writeByte(0);
this.writeByte(2);
this.writeByte(17);
this.writeByte(3);
this.writeByte(17);
this.writeByte(0);
this.writeByte(63);
this.writeByte(0);
}
private function processDU(CDU:Array, fdtbl:Array, DC:Number, HTDC:Array, HTAC:Array):Number{
var i:int;
var startpos:int;
var nrzeroes:int;
var nrmarker:int;
var EOB:BitString = HTAC[0];
var M16zeroes:BitString = HTAC[240];
var DU_DCT:Array = this.fDCTQuant(CDU, fdtbl);
i = 0;
while (i < 64) {
this.DU[this.ZigZag[i]] = DU_DCT[i];
i++;
};
var Diff:int = (this.DU[0] - DC);
DC = this.DU[0];
if (Diff == 0){
this.writeBits(HTDC[0]);
} else {
this.writeBits(HTDC[this.category[(32767 + Diff)]]);
this.writeBits(this.bitcode[(32767 + Diff)]);
};
var end0pos = 63;
while ((((end0pos > 0)) && ((this.DU[end0pos] == 0)))) {
end0pos--;
};
if (end0pos == 0){
this.writeBits(EOB);
return (DC);
};
i = 1;
while (i <= end0pos) {
startpos = i;
while ((((this.DU[i] == 0)) && ((i <= end0pos)))) {
i++;
};
nrzeroes = (i - startpos);
if (nrzeroes >= 16){
nrmarker = 1;
while (nrmarker <= (nrzeroes / 16)) {
this.writeBits(M16zeroes);
nrmarker++;
};
nrzeroes = int((nrzeroes & 15));
};
this.writeBits(HTAC[((nrzeroes * 16) + this.category[(32767 + this.DU[i])])]);
this.writeBits(this.bitcode[(32767 + this.DU[i])]);
i++;
};
if (end0pos != 63){
this.writeBits(EOB);
};
return (DC);
}
private function initQuantTables(sf:int):void{
var i:int;
var t:Number;
var col:int;
var YQT:Array = [16, 11, 10, 16, 24, 40, 51, 61, 12, 12, 14, 19, 26, 58, 60, 55, 14, 13, 16, 24, 40, 57, 69, 56, 14, 17, 22, 29, 51, 87, 80, 62, 18, 22, 37, 56, 68, 109, 103, 77, 24, 35, 55, 64, 81, 104, 113, 92, 49, 64, 78, 87, 103, 121, 120, 101, 72, 92, 95, 98, 112, 100, 103, 99];
i = 0;
while (i < 64) {
t = Math.floor((((YQT[i] * sf) + 50) / 100));
if (t < 1){
t = 1;
} else {
if (t > 0xFF){
t = 0xFF;
};
};
this.YTable[this.ZigZag[i]] = t;
i++;
};
var UVQT:Array = [17, 18, 24, 47, 99, 99, 99, 99, 18, 21, 26, 66, 99, 99, 99, 99, 24, 26, 56, 99, 99, 99, 99, 99, 47, 66, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99];
i = 0;
while (i < 64) {
t = Math.floor((((UVQT[i] * sf) + 50) / 100));
if (t < 1){
t = 1;
} else {
if (t > 0xFF){
t = 0xFF;
};
};
this.UVTable[this.ZigZag[i]] = t;
i++;
};
var aasf:Array = [1, 1.387039845, 1.306562965, 1.175875602, 1, 0.785694958, 0.5411961, 0.275899379];
i = 0;
var row:int;
while (row < 8) {
col = 0;
while (col < 8) {
this.fdtbl_Y[i] = (1 / (((this.YTable[this.ZigZag[i]] * aasf[row]) * aasf[col]) * 8));
this.fdtbl_UV[i] = (1 / (((this.UVTable[this.ZigZag[i]] * aasf[row]) * aasf[col]) * 8));
i++;
col++;
};
row++;
};
}
private function writeSOF0(width:int, height:int):void{
this.writeWord(65472);
this.writeWord(17);
this.writeByte(8);
this.writeWord(height);
this.writeWord(width);
this.writeByte(3);
this.writeByte(1);
this.writeByte(17);
this.writeByte(0);
this.writeByte(2);
this.writeByte(17);
this.writeByte(1);
this.writeByte(3);
this.writeByte(17);
this.writeByte(1);
}
private function computeHuffmanTbl(nrcodes:Array, std_table:Array):Array{
var j:int;
var codevalue:int;
var pos_in_table:int;
var HT:Array = new Array();
var k = 1;
while (k <= 16) {
j = 1;
while (j <= nrcodes[k]) {
HT[std_table[pos_in_table]] = new BitString();
HT[std_table[pos_in_table]].val = codevalue;
HT[std_table[pos_in_table]].len = k;
pos_in_table++;
codevalue++;
j++;
};
codevalue = (codevalue * 2);
k++;
};
return (HT);
}
private function fDCTQuant(data:Array, fdtbl:Array):Array{
var tmp0:Number;
var tmp1:Number;
var tmp2:Number;
var tmp3:Number;
var tmp4:Number;
var tmp5:Number;
var tmp6:Number;
var tmp7:Number;
var tmp10:Number;
var tmp11:Number;
var tmp12:Number;
var tmp13:Number;
var z1:Number;
var z2:Number;
var z3:Number;
var z4:Number;
var z5:Number;
var z11:Number;
var z13:Number;
var i:int;
var dataOff:int;
i = 0;
while (i < 8) {
tmp0 = (data[(dataOff + 0)] + data[(dataOff + 7)]);
tmp7 = (data[(dataOff + 0)] - data[(dataOff + 7)]);
tmp1 = (data[(dataOff + 1)] + data[(dataOff + 6)]);
tmp6 = (data[(dataOff + 1)] - data[(dataOff + 6)]);
tmp2 = (data[(dataOff + 2)] + data[(dataOff + 5)]);
tmp5 = (data[(dataOff + 2)] - data[(dataOff + 5)]);
tmp3 = (data[(dataOff + 3)] + data[(dataOff + 4)]);
tmp4 = (data[(dataOff + 3)] - data[(dataOff + 4)]);
tmp10 = (tmp0 + tmp3);
tmp13 = (tmp0 - tmp3);
tmp11 = (tmp1 + tmp2);
tmp12 = (tmp1 - tmp2);
data[(dataOff + 0)] = (tmp10 + tmp11);
data[(dataOff + 4)] = (tmp10 - tmp11);
z1 = ((tmp12 + tmp13) * 0.707106781);
data[(dataOff + 2)] = (tmp13 + z1);
data[(dataOff + 6)] = (tmp13 - z1);
tmp10 = (tmp4 + tmp5);
tmp11 = (tmp5 + tmp6);
tmp12 = (tmp6 + tmp7);
z5 = ((tmp10 - tmp12) * 0.382683433);
z2 = ((0.5411961 * tmp10) + z5);
z4 = ((1.306562965 * tmp12) + z5);
z3 = (tmp11 * 0.707106781);
z11 = (tmp7 + z3);
z13 = (tmp7 - z3);
data[(dataOff + 5)] = (z13 + z2);
data[(dataOff + 3)] = (z13 - z2);
data[(dataOff + 1)] = (z11 + z4);
data[(dataOff + 7)] = (z11 - z4);
dataOff = (dataOff + 8);
i++;
};
dataOff = 0;
i = 0;
while (i < 8) {
tmp0 = (data[(dataOff + 0)] + data[(dataOff + 56)]);
tmp7 = (data[(dataOff + 0)] - data[(dataOff + 56)]);
tmp1 = (data[(dataOff + 8)] + data[(dataOff + 48)]);
tmp6 = (data[(dataOff + 8)] - data[(dataOff + 48)]);
tmp2 = (data[(dataOff + 16)] + data[(dataOff + 40)]);
tmp5 = (data[(dataOff + 16)] - data[(dataOff + 40)]);
tmp3 = (data[(dataOff + 24)] + data[(dataOff + 32)]);
tmp4 = (data[(dataOff + 24)] - data[(dataOff + 32)]);
tmp10 = (tmp0 + tmp3);
tmp13 = (tmp0 - tmp3);
tmp11 = (tmp1 + tmp2);
tmp12 = (tmp1 - tmp2);
data[(dataOff + 0)] = (tmp10 + tmp11);
data[(dataOff + 32)] = (tmp10 - tmp11);
z1 = ((tmp12 + tmp13) * 0.707106781);
data[(dataOff + 16)] = (tmp13 + z1);
data[(dataOff + 48)] = (tmp13 - z1);
tmp10 = (tmp4 + tmp5);
tmp11 = (tmp5 + tmp6);
tmp12 = (tmp6 + tmp7);
z5 = ((tmp10 - tmp12) * 0.382683433);
z2 = ((0.5411961 * tmp10) + z5);
z4 = ((1.306562965 * tmp12) + z5);
z3 = (tmp11 * 0.707106781);
z11 = (tmp7 + z3);
z13 = (tmp7 - z3);
data[(dataOff + 40)] = (z13 + z2);
data[(dataOff + 24)] = (z13 - z2);
data[(dataOff + 8)] = (z11 + z4);
data[(dataOff + 56)] = (z11 - z4);
dataOff++;
i++;
};
i = 0;
while (i < 64) {
data[i] = Math.round((data[i] * fdtbl[i]));
i++;
};
return (data);
}
}
}//package com.adobe.images
Section 51
//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(_arg1:Boolean=true, _arg2:Boolean=false){
_empty = _arg1;
_new = _arg2;
}
public function isEmpty():Boolean{
return (_empty);
}
public function toURLString():String{
var _local1:Variables;
_local1 = toVariables();
return (_local1.toString());
}
public function toVariables():Variables{
var _local1:Variables;
_local1 = new Variables();
_local1.URIencode = true;
if (((!(isEmpty())) && (isNew()))){
_local1.utmcn = utmcn;
};
if (((!(isEmpty())) && (!(isNew())))){
_local1.utmcr = utmcr;
};
return (_local1);
}
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 52
//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(){
super();
}
}
}//package com.google.analytics.campaign
Section 53
//CampaignManager (com.google.analytics.campaign.CampaignManager)
package com.google.analytics.campaign {
import com.google.analytics.v4.*;
import com.google.analytics.debug.*;
import com.google.analytics.core.*;
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(_arg1:Configuration, _arg2:DebugConfiguration, _arg3:Buffer, _arg4:Number, _arg5:String, _arg6:Number){
_config = _arg1;
_debug = _arg2;
_buffer = _arg3;
_domainHash = _arg4;
_referrer = _arg5;
_timeStamp = _arg6;
}
public function hasNoOverride(_arg1:String):Boolean{
var _local2:CampaignKey;
var _local3:Variables;
var _local4:String;
_local2 = _config.campaignKey;
if (_arg1 == ""){
return (false);
};
_local3 = new Variables(_arg1);
_local4 = "";
if (_local3.hasOwnProperty(_local2.UCNO)){
_local4 = _local3[_local2.UCNO];
switch (_local4){
case "1":
return (true);
case "":
case "0":
default:
return (false);
};
};
return (false);
}
public function getCampaignInformation(_arg1:String, _arg2:Boolean):CampaignInfo{
var _local3:CampaignInfo;
var _local4:CampaignTracker;
var _local5:Boolean;
var _local6:Boolean;
var _local7:int;
var _local8:CampaignTracker;
var _local9:int;
_local3 = new CampaignInfo();
_local5 = false;
_local6 = false;
_local7 = 0;
if (((_config.allowLinker) && (_buffer.isGenuine()))){
if (!_buffer.hasUTMZ()){
return (_local3);
};
};
_local4 = getTrackerFromSearchString(_arg1);
if (isValid(_local4)){
_local6 = hasNoOverride(_arg1);
if (((_local6) && (!(_buffer.hasUTMZ())))){
return (_local3);
};
};
if (!isValid(_local4)){
_local4 = getOrganicCampaign();
if (((!(_buffer.hasUTMZ())) && (isIgnoredKeyword(_local4)))){
return (_local3);
};
};
if (((!(isValid(_local4))) && (_arg2))){
_local4 = getReferrerCampaign();
if (((!(_buffer.hasUTMZ())) && (isIgnoredReferral(_local4)))){
return (_local3);
};
};
if (!isValid(_local4)){
if (((!(_buffer.hasUTMZ())) && (_arg2))){
_local4 = getDirectCampaign();
};
};
if (!isValid(_local4)){
return (_local3);
};
if (((_buffer.hasUTMZ()) && (!(_buffer.utmz.isEmpty())))){
_local8 = new CampaignTracker();
_local8.fromTrackerString(_buffer.utmz.campaignTracking);
_local5 = (_local8.toTrackerString() == _local4.toTrackerString());
_local7 = _buffer.utmz.responseCount;
};
if (((!(_local5)) || (_arg2))){
_local9 = _buffer.utma.sessionCount;
_local7++;
if (_local9 == 0){
_local9 = 1;
};
_buffer.utmz.domainHash = _domainHash;
_buffer.utmz.campaignCreation = _timeStamp;
_buffer.utmz.campaignSessions = _local9;
_buffer.utmz.responseCount = _local7;
_buffer.utmz.campaignTracking = _local4.toTrackerString();
_debug.info(_buffer.utmz.toString(), VisualDebugMode.geek);
_local3 = new CampaignInfo(false, true);
} else {
_local3 = new CampaignInfo(false, false);
};
return (_local3);
}
public function isValid(_arg1:CampaignTracker):Boolean{
if (((_arg1) && (_arg1.isValid()))){
return (true);
};
return (false);
}
public function getTrackerFromSearchString(_arg1:String):CampaignTracker{
var _local2:CampaignTracker;
var _local3:CampaignTracker;
var _local4:CampaignKey;
var _local5:Variables;
_local2 = getOrganicCampaign();
_local3 = new CampaignTracker();
_local4 = _config.campaignKey;
if (_arg1 == ""){
return (_local3);
};
_local5 = new Variables(_arg1);
if (_local5.hasOwnProperty(_local4.UCID)){
_local3.id = _local5[_local4.UCID];
};
if (_local5.hasOwnProperty(_local4.UCSR)){
_local3.source = _local5[_local4.UCSR];
};
if (_local5.hasOwnProperty(_local4.UGCLID)){
_local3.clickId = _local5[_local4.UGCLID];
};
if (_local5.hasOwnProperty(_local4.UCCN)){
_local3.name = _local5[_local4.UCCN];
} else {
_local3.name = "(not set)";
};
if (_local5.hasOwnProperty(_local4.UCMD)){
_local3.medium = _local5[_local4.UCMD];
} else {
_local3.medium = "(not set)";
};
if (_local5.hasOwnProperty(_local4.UCTR)){
_local3.term = _local5[_local4.UCTR];
} else {
if (((_local2) && (!((_local2.term == ""))))){
_local3.term = _local2.term;
};
};
if (_local5.hasOwnProperty(_local4.UCCT)){
_local3.content = _local5[_local4.UCCT];
};
return (_local3);
}
public function getOrganicCampaign():CampaignTracker{
var _local1:CampaignTracker;
var _local2:URL;
var _local3:String;
var _local4:Array;
var _local5:OrganicReferrer;
var _local6:String;
if (((isInvalidReferrer(_referrer)) || (isFromGoogleCSE(_referrer, _config)))){
return (_local1);
};
_local2 = new URL(_referrer);
_local3 = "";
if (_local2.hostName != ""){
if (_local2.hostName.indexOf(".") > -1){
_local4 = _local2.hostName.split(".");
switch (_local4.length){
case 2:
_local3 = _local4[0];
break;
case 3:
_local3 = _local4[1];
break;
};
};
};
if (_config.organic.match(_local3)){
_local5 = _config.organic.getReferrerByName(_local3);
_local6 = _config.organic.getKeywordValue(_local5, _local2.search);
_local1 = new CampaignTracker();
_local1.source = _local5.engine;
_local1.name = "(organic)";
_local1.medium = "organic";
_local1.term = _local6;
};
return (_local1);
}
public function isIgnoredReferral(_arg1:CampaignTracker):Boolean{
if (((_arg1) && ((_arg1.medium == "referral")))){
return (_config.organic.isIgnoredReferral(_arg1.source));
};
return (false);
}
public function getDirectCampaign():CampaignTracker{
var _local1:CampaignTracker;
_local1 = new CampaignTracker();
_local1.source = "(direct)";
_local1.name = "(direct)";
_local1.medium = "(none)";
return (_local1);
}
public function isIgnoredKeyword(_arg1:CampaignTracker):Boolean{
if (((_arg1) && ((_arg1.medium == "organic")))){
return (_config.organic.isIgnoredKeyword(_arg1.term));
};
return (false);
}
public function getReferrerCampaign():CampaignTracker{
var _local1:CampaignTracker;
var _local2:URL;
var _local3:String;
var _local4:String;
if (((isInvalidReferrer(_referrer)) || (isFromGoogleCSE(_referrer, _config)))){
return (_local1);
};
_local2 = new URL(_referrer);
_local3 = _local2.hostName;
_local4 = _local2.path;
if (_local3.indexOf("www.") == 0){
_local3 = _local3.substr(4);
};
_local1 = new CampaignTracker();
_local1.source = _local3;
_local1.name = "(referral)";
_local1.medium = "referral";
_local1.content = _local4;
return (_local1);
}
public static function isInvalidReferrer(_arg1:String):Boolean{
var _local2:URL;
if ((((((_arg1 == "")) || ((_arg1 == "-")))) || ((_arg1 == "0")))){
return (true);
};
if (_arg1.indexOf("://") > -1){
_local2 = new URL(_arg1);
if ((((_local2.protocol == Protocols.file)) || ((_local2.protocol == Protocols.none)))){
return (true);
};
};
return (false);
}
public static function isFromGoogleCSE(_arg1:String, _arg2:Configuration):Boolean{
var _local3:URL;
_local3 = new URL(_arg1);
if (_local3.hostName.indexOf(_arg2.google) > -1){
if (_local3.search.indexOf((_arg2.googleSearchParam + "=")) > -1){
if (_local3.path == ("/" + _arg2.googleCsePath)){
return (true);
};
};
};
return (false);
}
}
}//package com.google.analytics.campaign
Section 54
//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 source:String;
public var clickId:String;
public var name:String;
public var term:String;
public var medium:String;
public var id: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 isValid():Boolean{
if (((((!((id == ""))) || (!((source == ""))))) || (!((clickId == ""))))){
return (true);
};
return (false);
}
public function toTrackerString():String{
var data:Array = [];
_addIfNotEmpty(data, "utmcsr=", source);
_addIfNotEmpty(data, "utmccn=", name);
_addIfNotEmpty(data, "utmcmd=", medium);
_addIfNotEmpty(data, "utmctr=", term);
_addIfNotEmpty(data, "utmcct=", content);
_addIfNotEmpty(data, "utmcid=", id);
_addIfNotEmpty(data, "utmgclid=", clickId);
return (data.join(CampaignManager.trackingDelimiter));
}
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 = tracker.split(CampaignManager.trackingDelimiter).join("&");
var vars:Variables = 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 55
//FlashTracker (com.google.analytics.components.FlashTracker)
package com.google.analytics.components {
import flash.display.*;
import flash.events.*;
import com.google.analytics.v4.*;
import com.google.analytics.debug.*;
import com.google.analytics.core.*;
import com.google.analytics.utils.*;
import com.google.analytics.external.*;
import com.google.analytics.*;
import flash.utils.*;
import com.google.analytics.events.*;
public class FlashTracker extends Sprite implements AnalyticsTracker {
private var _adSense:AdSenseGlobals;
private var _env:Environment;
protected var _height:Number;// = 18
private var _idleTimer:IdleTimer;
private var _config:Configuration;
private var _mode:String;// = "AS3"
private var _dom:HTMLDOM;
private var _ready:Boolean;// = false
protected var _width:Number;// = 18
private var _account:String;// = ""
protected var _componentInspectorSetting:Boolean;
private var _visualDebug:Boolean;// = false
public var boundingBox_mc:DisplayObject;
private var _debug:DebugConfiguration;
private var _buffer:Buffer;
private var _display:DisplayObject;
protected var livePreviewHeight:Number;
private var _jsproxy:JavascriptProxy;
protected var isLivePreview:Boolean;
protected var preview:MovieClip;
private var _gifRequest:GIFRequest;
protected var livePreviewWidth:Number;
private var _tracker:GoogleAnalyticsAPI;
public static var version:Version = API.version;
public function FlashTracker(){
_ready = false;
_account = "";
_mode = TrackerMode.AS3;
_visualDebug = false;
_width = 18;
_height = 18;
super();
_tracker = new TrackerCache();
isLivePreview = _checkLivePreview();
_componentInspectorSetting = false;
if (boundingBox_mc){
boundingBox_mc.visible = false;
removeChild(boundingBox_mc);
boundingBox_mc = null;
};
if (isLivePreview){
_createLivePreview();
};
addEventListener(Event.ENTER_FRAME, _factory);
}
public function trackEvent(_arg1:String, _arg2:String, _arg3:String=null, _arg4:Number=NaN):Boolean{
return (_tracker.trackEvent(_arg1, _arg2, _arg3, _arg4));
}
public function trackTrans():void{
_tracker.trackTrans();
}
private function _createLivePreview():void{
var _local1:Graphics;
var _local2:Class;
preview = new MovieClip();
_local1 = preview.graphics;
_local1.beginFill(0xFFFFFF);
_local1.moveTo(0, 0);
_local1.lineTo(0, _width);
_local1.lineTo(_width, _height);
_local1.lineTo(_height, 0);
_local1.lineTo(0, 0);
_local1.endFill();
_local2 = (getDefinitionByName("com.google.analytics.components::Icon") as Class);
preview.icon_mc = new (_local2);
preview.icon_mc.name = "icon_mc";
preview.addChild(preview.icon_mc);
addChild(preview);
}
public function trackPageview(_arg1:String=""):void{
_tracker.trackPageview(_arg1);
}
public function get account():String{
return (_account);
}
public function linkByPost(_arg1:Object, _arg2:Boolean=false):void{
_tracker.linkByPost(_arg1, _arg2);
}
public function getDetectTitle():Boolean{
return (_tracker.getDetectTitle());
}
public function setCampNameKey(_arg1:String):void{
_tracker.setCampNameKey(_arg1);
}
public function resetSession():void{
_tracker.resetSession();
}
public function set account(_arg1:String):void{
_account = _arg1;
}
public function get debug():DebugConfiguration{
if (!_debug){
_createDebugAndConfig();
};
return (_debug);
}
public function createEventTracker(_arg1:String):EventTracker{
return (_tracker.createEventTracker(_arg1));
}
public function set config(_arg1:Configuration):void{
_config = _arg1;
}
public function addTrans(_arg1:String, _arg2:String, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:String, _arg7:String, _arg8:String):Object{
return (_tracker.addTrans(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7, _arg8));
}
public function setLocalServerMode():void{
_tracker.setLocalServerMode();
}
public function getLocalGifPath():String{
return (_tracker.getLocalGifPath());
}
public function clearIgnoredRef():void{
_tracker.clearIgnoredRef();
}
public function isReady():Boolean{
return (_ready);
}
public function set debug(_arg1:DebugConfiguration):void{
_debug = _arg1;
}
public function getVersion():String{
return (_tracker.getVersion());
}
public function setLocalRemoteServerMode():void{
_tracker.setLocalRemoteServerMode();
}
public function setCampNOKey(_arg1:String):void{
_tracker.setCampNOKey(_arg1);
}
public function addIgnoredOrganic(_arg1:String):void{
_tracker.addIgnoredOrganic(_arg1);
}
public function setCookiePath(_arg1:String):void{
_tracker.setCookiePath(_arg1);
}
public function setCampTermKey(_arg1:String):void{
_tracker.setCampTermKey(_arg1);
}
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);
_env.url = _display.stage.loaderInfo.url;
return (new Tracker(account, config, debug, _env, _buffer, _gifRequest, _adSense));
}
public function setCampaignTrack(_arg1:Boolean):void{
_tracker.setCampaignTrack(_arg1);
}
public function getServiceMode():ServerOperationMode{
return (_tracker.getServiceMode());
}
public function set componentInspectorSetting(_arg1:Boolean):void{
_componentInspectorSetting = _arg1;
}
public function setSessionTimeout(_arg1:int):void{
_tracker.setSessionTimeout(_arg1);
}
public function setRemoteServerMode():void{
_tracker.setRemoteServerMode();
}
public function get visualDebug():Boolean{
return (_visualDebug);
}
public function addOrganic(_arg1:String, _arg2:String):void{
_tracker.addOrganic(_arg1, _arg2);
}
public function setCookieTimeout(_arg1:int):void{
_tracker.setCookieTimeout(_arg1);
}
public function getClientInfo():Boolean{
return (_tracker.getClientInfo());
}
public function setAllowLinker(_arg1:Boolean):void{
_tracker.setAllowLinker(_arg1);
}
public function setClientInfo(_arg1:Boolean):void{
_tracker.setClientInfo(_arg1);
}
private function _bridgeFactory():GoogleAnalyticsAPI{
debug.info(((("GATracker (Bridge) v" + version) + "\naccount: ") + account));
return (new Bridge(account, _debug, _jsproxy));
}
public function get config():Configuration{
if (!_config){
_createDebugAndConfig();
};
return (_config);
}
public function set mode(_arg1:String):void{
_mode = _arg1;
}
public function setDetectFlash(_arg1:Boolean):void{
_tracker.setDetectFlash(_arg1);
}
public function addItem(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:Number, _arg6:int):void{
_tracker.addItem(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6);
}
public function setVar(_arg1:String):void{
_tracker.setVar(_arg1);
}
public function clearIgnoredOrganic():void{
_tracker.clearIgnoredOrganic();
}
public function setDomainName(_arg1:String):void{
_tracker.setDomainName(_arg1);
}
private function _checkLivePreview():Boolean{
if (((!((parent == null))) && ((getQualifiedClassName(parent) == "fl.livepreview::LivePreviewParent")))){
return (true);
};
return (false);
}
public function setCampSourceKey(_arg1:String):void{
_tracker.setCampSourceKey(_arg1);
}
public function setCampContentKey(_arg1:String):void{
_tracker.setCampContentKey(_arg1);
}
public function setSize(_arg1:Number, _arg2:Number):void{
}
public function setAllowAnchor(_arg1:Boolean):void{
_tracker.setAllowAnchor(_arg1);
}
public function setLocalGifPath(_arg1:String):void{
_tracker.setLocalGifPath(_arg1);
}
public function get mode():String{
return (_mode);
}
public function setSampleRate(_arg1:Number):void{
_tracker.setSampleRate(_arg1);
}
public function setAllowHash(_arg1:Boolean):void{
_tracker.setAllowHash(_arg1);
}
public function setDetectTitle(_arg1:Boolean):void{
_tracker.setDetectTitle(_arg1);
}
public function cookiePathCopy(_arg1:String):void{
_tracker.cookiePathCopy(_arg1);
}
private function _factory(_arg1:Event):void{
var _local2:GoogleAnalyticsAPI;
var _local3:TrackerCache;
removeEventListener(Event.ENTER_FRAME, _factory);
if (isLivePreview){
return;
};
_display = this;
_createDebugAndConfig();
if (visualDebug){
debug.layout = new Layout(debug, _display);
debug.active = visualDebug;
};
_jsproxy = new JavascriptProxy(debug);
_local3 = (_tracker as TrackerCache);
switch (mode){
case TrackerMode.BRIDGE:
_local2 = _bridgeFactory();
break;
case TrackerMode.AS3:
default:
_local2 = _trackerFactory();
};
if (!_local3.isEmpty()){
_local3.tracker = _local2;
_local3.flush();
};
_tracker = _local2;
_ready = true;
dispatchEvent(new AnalyticsEvent(AnalyticsEvent.READY, this));
}
public function getDetectFlash():Boolean{
return (_tracker.getDetectFlash());
}
public function clearOrganic():void{
_tracker.clearOrganic();
}
private function _createDebugAndConfig():void{
if (!_debug){
this.debug = new DebugConfiguration();
};
if (!_config){
this.config = new Configuration(debug);
};
}
public function addIgnoredRef(_arg1:String):void{
_tracker.addIgnoredRef(_arg1);
}
public function set visualDebug(_arg1:Boolean):void{
_visualDebug = _arg1;
}
public function setCampMediumKey(_arg1:String):void{
_tracker.setCampMediumKey(_arg1);
}
public function getAccount():String{
return (_tracker.getAccount());
}
public function link(_arg1:String, _arg2:Boolean=false):void{
_tracker.link(_arg1, _arg2);
}
}
var _local1:* = ServerOperationMode;
return (_local1);
}//package com.google.analytics.components
Section 56
//Icon (com.google.analytics.components.Icon)
package com.google.analytics.components {
import flash.display.*;
public dynamic class Icon extends MovieClip {
}
}//package com.google.analytics.components
Section 57
//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(_arg1:Configuration, _arg2:Environment){
_config = _arg1;
_info = _arg2;
}
public function get utmul():String{
return (_info.language.toLowerCase());
}
public function get utmje():String{
return ("0");
}
public function toURLString():String{
var _local1:Variables;
_local1 = toVariables();
return (_local1.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 _local1:Version;
if (_config.detectFlash){
_local1 = _info.flashVersion;
return (((((_local1.major + ".") + _local1.minor) + " r") + _local1.build));
};
return ("-");
}
public function toVariables():Variables{
var _local1:Variables;
_local1 = new Variables();
_local1.URIencode = true;
_local1.utmcs = utmcs;
_local1.utmsr = utmsr;
_local1.utmsc = utmsc;
_local1.utmul = utmul;
_local1.utmje = utmje;
_local1.utmfl = utmfl;
return (_local1);
}
public function get utmsc():String{
return ((_info.screenColorDepth + "-bit"));
}
}
}//package com.google.analytics.core
Section 58
//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 _SO:SharedObject;
private var _OBJ:Object;
private var _utma:UTMA;
private var _utmb:UTMB;
private var _utmc:UTMC;
private var _debug:DebugConfiguration;
private var _utmk:UTMK;
private var _config:Configuration;
private var _utmv:UTMV;
private var _utmz:UTMZ;
private var _volatile:Boolean;
public function Buffer(config:Configuration, debug:DebugConfiguration, volatile:Boolean=false, data:Object=null){
var saveSO:Boolean;
var prop:String;
super();
_config = config;
_debug = debug;
UTMB.defaultTimespan = _config.sessionTimeout;
UTMZ.defaultTimespan = _config.conversionTimeout;
if (!volatile){
_SO = SharedObject.getLocal(_config.cookieName, _config.cookiePath);
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 (_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();
};
} else {
_OBJ = new Object();
if (data){
for (prop in data) {
_OBJ[prop] = data[prop];
};
};
};
_volatile = volatile;
}
public function clearCookies():void{
utma.reset();
utmb.reset();
utmc.reset();
utmz.reset();
utmv.reset();
utmk.reset();
}
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 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 hasUTMC():Boolean{
if (_utmc){
return (true);
};
return (false);
}
public function isGenuine():Boolean{
if (!hasUTMK()){
return (true);
};
return ((utmk.hash == generateCookiesHash()));
}
public function resetCurrentSession():void{
_clearUTMB();
_clearUTMC();
save();
}
public function hasUTMK():Boolean{
if (_utmk){
return (true);
};
return (false);
}
public function generateCookiesHash():Number{
var value:String = "";
value = (value + utma.valueOf());
value = (value + utmb.valueOf());
value = (value + utmc.valueOf());
value = (value + utmz.valueOf());
value = (value + utmv.valueOf());
return (Utils.generateHash(value));
}
private function _createUMTB():void{
_utmb = new UTMB();
_utmb.proxy = this;
}
private function _createUMTC():void{
_utmc = new UTMC();
}
private function _createUMTA():void{
_utma = new UTMA();
_utma.proxy = this;
}
public function hasUTMV():Boolean{
if (_utmv){
return (true);
};
return (false);
}
private function _createUMTK():void{
_utmk = new UTMK();
_utmk.proxy = this;
}
public function hasUTMZ():Boolean{
if (_utmz){
return (true);
};
return (false);
}
private function _createUMTV():void{
_utmv = new UTMV();
_utmv.proxy = this;
}
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);
}
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;
};
}
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;
};
}
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 59
//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(_arg1:Configuration, _arg2:Environment, _arg3:String, _arg4:String=null, _arg5:AdSenseGlobals=null){
_config = _arg1;
_info = _arg2;
_utmr = _arg3;
_pageURL = _arg4;
_adSense = _arg5;
}
public function get utmr():String{
if (!_utmr){
return ("-");
};
return (_utmr);
}
public function toURLString():String{
var _local1:Variables;
_local1 = toVariables();
return (_local1.toString());
}
private function _renderPageURL(_arg1:String=""):String{
var _local2:String;
var _local3:String;
_local2 = _info.locationPath;
_local3 = _info.locationSearch;
if (((!(_arg1)) || ((_arg1 == "")))){
_arg1 = (_local2 + unescape(_local3));
};
return (_arg1);
}
public function get utmp():String{
return (_renderPageURL(_pageURL));
}
private function _generateHitId():Number{
var _local1:Number;
if (((_adSense.hid) && (!((_adSense.hid == ""))))){
_local1 = Number(_adSense.hid);
} else {
_local1 = Math.round((Math.random() * 2147483647));
_adSense.hid = String(_local1);
};
return (_local1);
}
public function get utmhid():String{
return (String(_generateHitId()));
}
public function toVariables():Variables{
var _local1:Variables;
_local1 = new Variables();
_local1.URIencode = true;
if (((_config.detectTitle) && (!((utmdt == ""))))){
_local1.utmdt = utmdt;
};
_local1.utmhid = utmhid;
_local1.utmr = utmr;
_local1.utmp = utmp;
return (_local1);
}
public function get utmdt():String{
return (_info.documentTitle);
}
}
}//package com.google.analytics.core
Section 60
//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 _debug:DebugConfiguration;
private var _name:String;
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 61
//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(_arg1:int=0, _arg2:String=""){
_value = _arg1;
_name = _arg2;
}
public function valueOf():int{
return (_value);
}
public function toString():String{
return (_name);
}
}
}//package com.google.analytics.core
Section 62
//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(_arg1:Boolean, _arg2:X10, _arg3:X10=null){
_isEventHit = _arg1;
_x10 = _arg2;
_ext10 = _arg3;
}
public function toURLString():String{
var _local1:Variables;
_local1 = toVariables();
return (_local1.toString());
}
public function get utmt():String{
return ("event");
}
public function get utme():String{
return (_x10.renderMergedUrlString(_ext10));
}
public function toVariables():Variables{
var _local1:Variables;
_local1 = new Variables();
_local1.URIencode = true;
if (_isEventHit){
_local1.utmt = utmt;
};
_local1.utme = utme;
return (_local1);
}
}
}//package com.google.analytics.core
Section 63
//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(_arg1:String, _arg2:GoogleAnalyticsAPI){
this.name = _arg1;
_parent = _arg2;
}
public function trackEvent(_arg1:String, _arg2:String=null, _arg3:Number=NaN):Boolean{
return (_parent.trackEvent(name, _arg1, _arg2, _arg3));
}
}
}//package com.google.analytics.core
Section 64
//ga_internal (com.google.analytics.core.ga_internal)
package com.google.analytics.core {
public namespace ga_internal;
}//package com.google.analytics.core
Section 65
//GIFRequest (com.google.analytics.core.GIFRequest)
package com.google.analytics.core {
import flash.display.*;
import flash.events.*;
import com.google.analytics.v4.*;
import com.google.analytics.debug.*;
import com.google.analytics.utils.*;
import flash.net.*;
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 = _lastRequest.url;
var id:String = String((_requests.length - 1));
var 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 = [];
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 request = request;
var loader:Loader = new Loader();
loader.name = String(_count++);
var context:LoaderContext = 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 tokenDelta:Number;
var timestamp:Number = 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);
};
};
}
public function get utmhn():String{
return (_info.domainName);
}
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);
}
private function _debugSend(request:URLRequest):void{
var _local3:String;
var data:String = "";
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 = event.target.loader.name;
_requests[id].complete();
var msg = (("Gif Request #" + id) + " sent");
var url:String = _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 66
//IdleTimer (com.google.analytics.core.IdleTimer)
package com.google.analytics.core {
import flash.display.*;
import flash.events.*;
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(_arg1:Configuration, _arg2:DebugConfiguration, _arg3:DisplayObject, _arg4:Buffer){
var _local5:Number;
var _local6:Number;
var _local7:Number;
super();
_local5 = _arg1.idleLoop;
_local6 = _arg1.idleTimeout;
_local7 = _arg1.sessionTimeout;
_loop = new Timer((_local5 * 1000));
_session = new Timer((_local7 * 1000), 1);
_debug = _arg2;
_stage = _arg3.stage;
_buffer = _arg4;
_lastMove = getTimer();
_inactivity = (_local6 * 1000);
_loop.addEventListener(TimerEvent.TIMER, checkForIdle);
_session.addEventListener(TimerEvent.TIMER_COMPLETE, endSession);
_stage.addEventListener(MouseEvent.MOUSE_MOVE, onMouseMove);
_debug.info(((((("delay: " + _local5) + "sec , inactivity: ") + _local6) + "sec, sessionTimeout: ") + _local7), VisualDebugMode.geek);
_loop.start();
}
private function onMouseMove(_arg1:MouseEvent):void{
_lastMove = getTimer();
if (_session.running){
_debug.info("session timer reset", VisualDebugMode.geek);
_session.reset();
};
}
public function endSession(_arg1: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(_arg1:TimerEvent):void{
var _local2:int;
_local2 = getTimer();
if ((_local2 - _lastMove) >= _inactivity){
if (!_session.running){
_debug.info("session timer start", VisualDebugMode.geek);
_session.start();
};
};
}
}
}//package com.google.analytics.core
Section 67
//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(){
_sources = [];
_sourcesCache = [];
_sourcesEngine = [];
_ignoredReferrals = [];
_ignoredReferralsCache = {};
_ignoredKeywords = [];
_ignoredKeywordsCache = {};
}
public function getKeywordValue(_arg1:OrganicReferrer, _arg2:String):String{
var _local3:String;
_local3 = _arg1.keyword;
return (getKeywordValueFromPath(_local3, _arg2));
}
public function isIgnoredKeyword(_arg1:String):Boolean{
if (_ignoredKeywordsCache.hasOwnProperty(_arg1)){
return (true);
};
return (false);
}
public function isIgnoredReferral(_arg1:String):Boolean{
if (_ignoredReferralsCache.hasOwnProperty(_arg1)){
return (true);
};
return (false);
}
public function clear():void{
clearEngines();
clearIgnoredReferrals();
clearIgnoredKeywords();
}
public function get ignoredKeywordsCount():int{
return (_ignoredKeywords.length);
}
public function match(_arg1:String):Boolean{
if (_arg1 == ""){
return (false);
};
_arg1 = _arg1.toLowerCase();
if (_sourcesEngine[_arg1] != undefined){
return (true);
};
return (false);
}
public function get count():int{
return (_sources.length);
}
public function addSource(_arg1:String, _arg2:String):void{
var _local3:OrganicReferrer;
_local3 = new OrganicReferrer(_arg1, _arg2);
if (_sourcesCache[_local3.toString()] == undefined){
_sources.push(_local3);
_sourcesCache[_local3.toString()] = (_sources.length - 1);
if (_sourcesEngine[_local3.engine] == undefined){
_sourcesEngine[_local3.engine] = [(_sources.length - 1)];
} else {
_sourcesEngine[_local3.engine].push((_sources.length - 1));
};
} else {
if (throwErrors){
throw (new Error((_local3.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(_arg1:String):void{
if (_ignoredReferralsCache[_arg1] == undefined){
_ignoredReferrals.push(_arg1);
_ignoredReferralsCache[_arg1] = (_ignoredReferrals.length - 1);
} else {
if (throwErrors){
throw (new Error((("\"" + _arg1) + "\" already exists, we don't add it.")));
};
};
}
public function clearIgnoredReferrals():void{
_ignoredReferrals = [];
_ignoredReferralsCache = {};
}
public function getReferrerByName(_arg1:String):OrganicReferrer{
var _local2:int;
if (match(_arg1)){
_local2 = _sourcesEngine[_arg1][0];
return (_sources[_local2]);
};
return (null);
}
public function addIgnoredKeyword(_arg1:String):void{
if (_ignoredKeywordsCache[_arg1] == undefined){
_ignoredKeywords.push(_arg1);
_ignoredKeywordsCache[_arg1] = (_ignoredKeywords.length - 1);
} else {
if (throwErrors){
throw (new Error((("\"" + _arg1) + "\" already exists, we don't add it.")));
};
};
}
public function get sources():Array{
return (_sources);
}
public static function getKeywordValueFromPath(_arg1:String, _arg2:String):String{
var _local3:String;
var _local4:Variables;
if (_arg2.indexOf((_arg1 + "=")) > -1){
if (_arg2.charAt(0) == "?"){
_arg2 = _arg2.substr(1);
};
_arg2 = _arg2.split("+").join("%20");
_local4 = new Variables(_arg2);
_local3 = _local4[_arg1];
};
return (_local3);
}
}
}//package com.google.analytics.core
Section 68
//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(_arg1:String, _arg2:String){
this.engine = _arg1;
this.keyword = _arg2;
}
public function set engine(_arg1:String):void{
_engine = _arg1.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(_arg1:String):void{
_keyword = _arg1.toLowerCase();
}
}
}//package com.google.analytics.core
Section 69
//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(_arg1:URLRequest){
start = getTimer();
this.request = _arg1;
}
public function toString():String{
var _local1:Array;
_local1 = [];
_local1.push((("duration: " + duration) + "ms"));
_local1.push(("url: " + request.url));
return ((("{ " + _local1.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 70
//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 71
//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 trackEvent(category:String, action:String, label:String=null, value:Number=NaN):Boolean{
enqueue("trackEvent", category, action, label, value);
return (true);
}
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 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 setVar(newVal:String):void{
enqueue("setVar", newVal);
}
public function clearIgnoredOrganic():void{
enqueue("clearIgnoredOrganic");
}
public function setDomainName(newDomainName:String):void{
enqueue("setDomainName", newDomainName);
}
public function setCampSourceKey(newCampSrcKey:String):void{
enqueue("setCampSourceKey", newCampSrcKey);
}
public function addTrans(orderId:String, affiliation:String, total:Number, tax:Number, shipping:Number, city:String, state:String, country:String):Object{
if (CACHE_THROW_ERROR){
throw (new IllegalOperationError("The tracker is not ready and you can use the 'addTrans' method for the moment."));
};
return (null);
}
public function setCampContentKey(newCampContentKey:String):void{
enqueue("setCampContentKey", newCampContentKey);
}
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 clearIgnoredRef():void{
enqueue("clearIgnoredRef");
}
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 setDetectTitle(enable:Boolean):void{
enqueue("setDetectTitle", enable);
}
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 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 72
//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";
}
}//package com.google.analytics.core
Section 73
//Utils (com.google.analytics.core.Utils)
package com.google.analytics.core {
public class Utils {
public static function trim(_arg1:String, _arg2:Boolean=false):String{
var _local3:Array;
var _local4:String;
var _local5:int;
var _local6:int;
var _local7:int;
if (_arg1 == ""){
return ("");
};
_local3 = [" ", "\n", "\r", "\t"];
_local4 = _arg1;
if (_arg2){
_local5 = 0;
while ((((_local5 < _local3.length)) && ((_local4.indexOf(_local3[_local5]) > -1)))) {
_local4 = _local4.split(_local3[_local5]).join("");
_local5++;
};
} else {
_local6 = 0;
while ((((_local6 < _local4.length)) && ((_local3.indexOf(_local4.charAt(_local6)) > -1)))) {
_local6++;
};
_local4 = _local4.substr(_local6);
_local7 = (_local4.length - 1);
while ((((_local7 >= 0)) && ((_local3.indexOf(_local4.charAt(_local7)) > -1)))) {
_local7--;
};
_local4 = _local4.substring(0, (_local7 + 1));
};
return (_local4);
}
public static function generateHash(_arg1:String):int{
var _local2:int;
var _local3:int;
var _local4:int;
var _local5:int;
_local2 = 1;
_local3 = 0;
if (((!((_arg1 == null))) && (!((_arg1 == ""))))){
_local2 = 0;
_local4 = (_arg1.length - 1);
while (_local4 >= 0) {
_local5 = _arg1.charCodeAt(_local4);
_local2 = ((((_local2 << 6) & 268435455) + _local5) + (_local5 << 14));
_local3 = (_local2 & 266338304);
if (_local3 != 0){
_local2 = (_local2 ^ (_local3 >> 21));
};
_local4--;
};
};
return (_local2);
}
public static function generate32bitRandom():int{
return (Math.round((Math.random() * 2147483647)));
}
public static function validateAccount(_arg1:String):Boolean{
var _local2:RegExp;
_local2 = /^UA-[0-9]*-[0-9]*$/;
return (_local2.test(_arg1));
}
}
}//package com.google.analytics.core
Section 74
//Cookie (com.google.analytics.data.Cookie)
package com.google.analytics.data {
public interface Cookie {
function fromSharedObject(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/data;Cookie.as:Object):void;
function toURLString():String;
function get creation():Date;
function toSharedObject():Object;
function isExpired():Boolean;
function set creation(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/data;Cookie.as:Date):void;
function set expiration(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/data;Cookie.as:Date):void;
function get expiration():Date;
}
}//package com.google.analytics.data
Section 75
//UTMA (com.google.analytics.data.UTMA)
package com.google.analytics.data {
import com.google.analytics.utils.*;
public class UTMA extends UTMCookie {
private var _sessionId:Number;
private var _domainHash:Number;
private var _firstTime:Number;
private var _currentTime: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 set currentTime(value:Number):void{
_currentTime = value;
update();
}
public function get sessionId():Number{
return (_sessionId);
}
public function get sessionCount():Number{
return (_sessionCount);
}
public function get firstTime():Number{
return (_firstTime);
}
public function get currentTime():Number{
return (_currentTime);
}
public function set domainHash(value:Number):void{
_domainHash = value;
update();
}
public function set sessionId(value:Number):void{
_sessionId = value;
update();
}
public function set sessionCount(value:Number):void{
_sessionCount = value;
update();
}
public function get domainHash():Number{
return (_domainHash);
}
public function set firstTime(value:Number):void{
_firstTime = value;
update();
}
}
}//package com.google.analytics.data
Section 76
//UTMB (com.google.analytics.data.UTMB)
package com.google.analytics.data {
import com.google.analytics.utils.*;
public class UTMB extends UTMCookie {
private var _trackCount:Number;
private var _lastTime:Number;
private var _domainHash: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 set token(value:Number):void{
_token = value;
update();
}
public function set trackCount(value:Number):void{
_trackCount = value;
update();
}
public function get lastTime():Number{
return (_lastTime);
}
public function set domainHash(value:Number):void{
_domainHash = value;
update();
}
public function set lastTime(value:Number):void{
_lastTime = value;
update();
}
public function get domainHash():Number{
return (_domainHash);
}
public function get token():Number{
return (_token);
}
public function get trackCount():Number{
return (_trackCount);
}
}
}//package com.google.analytics.data
Section 77
//UTMC (com.google.analytics.data.UTMC)
package com.google.analytics.data {
public class UTMC extends UTMCookie {
private var _domainHash:Number;
public function UTMC(_arg1:Number=NaN){
super("utmc", "__utmc", ["domainHash"]);
this.domainHash = _arg1;
}
public function set domainHash(_arg1:Number):void{
_domainHash = _arg1;
update();
}
public function get domainHash():Number{
return (_domainHash);
}
}
}//package com.google.analytics.data
Section 78
//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(_arg1:String, _arg2:String, _arg3:Array, _arg4:Number=0){
this.name = _arg1;
this.inURL = _arg2;
this.fields = _arg3;
_timestamp(_arg4);
}
public function isEmpty():Boolean{
var _local1:int;
var _local2:String;
var _local3:int;
_local1 = 0;
_local3 = 0;
while (_local3 < fields.length) {
_local2 = fields[_local3];
if ((((this[_local2] is Number)) && (isNaN(this[_local2])))){
_local1++;
} else {
if ((((this[_local2] is String)) && ((this[_local2] == "")))){
_local1++;
};
};
_local3++;
};
if (_local1 == fields.length){
return (true);
};
return (false);
}
protected function update():void{
resetTimestamp();
if (proxy){
proxy.update(name, toSharedObject());
};
}
public function fromSharedObject(_arg1:Object):void{
var _local2:String;
var _local3:int;
var _local4:int;
_local3 = fields.length;
_local4 = 0;
while (_local4 < _local3) {
_local2 = fields[_local4];
if (_arg1[_local2]){
this[_local2] = _arg1[_local2];
};
_local4++;
};
if (_arg1.creation){
this.creation = _arg1.creation;
};
if (_arg1.expiration){
this.expiration = _arg1.expiration;
};
}
private function _timestamp(_arg1:Number):void{
creation = new Date();
_timespan = _arg1;
if (_arg1 > 0){
expiration = new Date((creation.valueOf() + _arg1));
};
}
public function isExpired():Boolean{
var _local1:Date;
var _local2:Number;
_local1 = new Date();
_local2 = (expiration.valueOf() - _local1.valueOf());
if (_local2 <= 0){
return (true);
};
return (false);
}
public function set expiration(_arg1:Date):void{
_expiration = _arg1;
}
public function get creation():Date{
return (_creation);
}
public function reset():void{
var _local1:String;
var _local2:int;
_local2 = 0;
while (_local2 < fields.length) {
_local1 = fields[_local2];
if ((this[_local1] is Number)){
this[_local1] = NaN;
} else {
if ((this[_local1] is String)){
this[_local1] = "";
};
};
_local2++;
};
resetTimestamp();
update();
}
public function valueOf():String{
var _local1:Array;
var _local2:String;
var _local3:*;
var _local4:int;
_local1 = [];
_local4 = 0;
while (_local4 < fields.length) {
_local2 = fields[_local4];
_local3 = this[_local2];
if ((_local3 is String)){
if (_local3 == ""){
_local3 = "-";
_local1.push(_local3);
} else {
_local1.push(_local3);
};
} else {
if ((_local3 is Number)){
if (_local3 == 0){
_local1.push(_local3);
} else {
if (isNaN(_local3)){
_local3 = "-";
_local1.push(_local3);
} else {
_local1.push(_local3);
};
};
};
};
_local4++;
};
return (("" + _local1.join(".")));
}
public function resetTimestamp(_arg1:Number=NaN):void{
if (!isNaN(_arg1)){
_timespan = _arg1;
};
_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 _local1:Object;
var _local2:String;
var _local3:*;
var _local4:int;
_local1 = {};
_local4 = 0;
for (;_local4 < fields.length;_local4++) {
_local2 = fields[_local4];
_local3 = this[_local2];
if ((_local3 is String)){
_local1[_local2] = _local3;
} else {
if (_local3 == 0){
_local1[_local2] = _local3;
} else {
if (isNaN(_local3)){
continue;
} else {
_local1[_local2] = _local3;
};
};
};
};
_local1.creation = creation;
_local1.expiration = expiration;
return (_local1);
}
public function toString(_arg1:Boolean=false):String{
var _local2:Array;
var _local3:String;
var _local4:*;
var _local5:int;
var _local6:int;
var _local7:String;
_local2 = [];
_local5 = fields.length;
_local6 = 0;
for (;_local6 < _local5;_local6++) {
_local3 = fields[_local6];
_local4 = this[_local3];
if ((_local4 is String)){
_local2.push((((_local3 + ": \"") + _local4) + "\""));
} else {
if (_local4 == 0){
_local2.push(((_local3 + ": ") + _local4));
} else {
if (isNaN(_local4)){
continue;
} else {
_local2.push(((_local3 + ": ") + _local4));
};
};
};
};
_local7 = (((name.toUpperCase() + " {") + _local2.join(", ")) + "}");
if (_arg1){
_local7 = (_local7 + (((" creation:" + creation) + ", expiration:") + expiration));
};
return (_local7);
}
public function set creation(_arg1:Date):void{
_creation = _arg1;
}
}
}//package com.google.analytics.data
Section 79
//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 set hash(value:Number):void{
_hash = value;
update();
}
public function get hash():Number{
return (_hash);
}
}
}//package com.google.analytics.data
Section 80
//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;
}
override public function toURLString():String{
return (((inURL + "=") + encodeURI(valueOf())));
}
public function get value():String{
return (_value);
}
public function get domainHash():Number{
return (_domainHash);
}
public function set domainHash(value:Number):void{
_domainHash = value;
update();
}
public function set value(value:String):void{
_value = value;
update();
}
}
}//package com.google.analytics.data
Section 81
//UTMZ (com.google.analytics.data.UTMZ)
package com.google.analytics.data {
import com.google.analytics.utils.*;
public class UTMZ extends UTMCookie {
private var _campaignTracking:String;
private var _campaignCreation:Number;
private var _responseCount:Number;
private var _domainHash:Number;
private var _campaignSessions: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 set responseCount(value:Number):void{
_responseCount = value;
update();
}
public function set domainHash(value:Number):void{
_domainHash = value;
update();
}
public function set campaignCreation(value:Number):void{
_campaignCreation = value;
update();
}
public function get campaignTracking():String{
return (_campaignTracking);
}
public function get campaignSessions():Number{
return (_campaignSessions);
}
public function get domainHash():Number{
return (_domainHash);
}
public function get responseCount():Number{
return (_responseCount);
}
public function get campaignCreation():Number{
return (_campaignCreation);
}
public function set campaignSessions(value:Number):void{
_campaignSessions = value;
update();
}
public function set campaignTracking(value:String):void{
_campaignTracking = value;
update();
}
}
}//package com.google.analytics.data
Section 82
//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(_arg1:Number, _arg2:String):void{
var _local3:Boolean;
var _local4:int;
var _local5:int;
if (((hasProject(_arg1)) && (!((_projectData[_arg1][_arg2] == undefined))))){
_projectData[_arg1][_arg2] = undefined;
_local3 = true;
_local5 = _set.length;
_local4 = 0;
while (_local4 < _local5) {
if (_projectData[_arg1][_set[_local4]] != undefined){
_local3 = false;
break;
};
_local4++;
};
if (_local3){
_projectData[_arg1] = undefined;
_hasData = (_hasData - 1);
};
};
}
public function hasData():Boolean{
return ((_hasData > 0));
}
private function _setInternal(_arg1:Number, _arg2:String, _arg3:Number, _arg4:String):void{
if (!hasProject(_arg1)){
_projectData[_arg1] = {};
};
if (_projectData[_arg1][_arg2] == undefined){
_projectData[_arg1][_arg2] = [];
};
_projectData[_arg1][_arg2][_arg3] = _arg4;
_hasData = (_hasData + 1);
}
public function hasProject(_arg1:Number):Boolean{
return (_projectData[_arg1]);
}
public function clearKey(_arg1:Number):void{
_clearInternal(_arg1, _key);
}
private function _renderDataType(_arg1:Array):String{
var _local2:Array;
var _local3:String;
var _local4:int;
_local2 = [];
_local4 = 0;
while (_local4 < _arg1.length) {
if (_arg1[_local4] != undefined){
_local3 = "";
if (((!((_local4 == _minimum))) && ((_arg1[(_local4 - 1)] == undefined)))){
_local3 = (_local3 + _local4.toString());
_local3 = (_local3 + _delimNumValue);
};
_local3 = (_local3 + _escapeExtensibleValue(_arg1[_local4]));
_local2.push(_local3);
};
_local4++;
};
return (((_delimBegin + _local2.join(_delimSet)) + _delimEnd));
}
public function getKey(_arg1:Number, _arg2:Number):String{
return ((_getInternal(_arg1, _key, _arg2) as String));
}
public function clearValue(_arg1:Number):void{
_clearInternal(_arg1, _value);
}
public function renderMergedUrlString(_arg1:X10=null):String{
var _local2:Array;
var _local3:String;
if (!_arg1){
return (renderUrlString());
};
_local2 = [_arg1.renderUrlString()];
for (_local3 in _projectData) {
if (((hasProject(Number(_local3))) && (!(_arg1.hasProject(Number(_local3)))))){
_local2.push((_local3 + _renderProject(_projectData[_local3])));
};
};
return (_local2.join(""));
}
public function setValue(_arg1:Number, _arg2:Number, _arg3:Number):Boolean{
if (((((!((Math.round(_arg3) == _arg3))) || (isNaN(_arg3)))) || ((_arg3 == Infinity)))){
return (false);
};
_setInternal(_arg1, _value, _arg2, _arg3.toString());
return (true);
}
public function renderUrlString():String{
var _local1:Array;
var _local2:String;
_local1 = [];
for (_local2 in _projectData) {
if (hasProject(Number(_local2))){
_local1.push((_local2 + _renderProject(_projectData[_local2])));
};
};
return (_local1.join(""));
}
private function _getInternal(_arg1:Number, _arg2:String, _arg3:Number):Object{
if (((hasProject(_arg1)) && (!((_projectData[_arg1][_arg2] == undefined))))){
return (_projectData[_arg1][_arg2][_arg3]);
};
return (undefined);
}
public function setKey(_arg1:Number, _arg2:Number, _arg3:String):Boolean{
_setInternal(_arg1, _key, _arg2, _arg3);
return (true);
}
public function getValue(_arg1:Number, _arg2:Number){
var _local3:*;
_local3 = _getInternal(_arg1, _value, _arg2);
if (_local3 == null){
return (null);
};
return (Number(_local3));
}
private function _renderProject(_arg1:Object):String{
var _local2:String;
var _local3:Boolean;
var _local4:int;
var _local5:Array;
var _local6:int;
_local2 = "";
_local3 = false;
_local6 = _set.length;
_local4 = 0;
while (_local4 < _local6) {
_local5 = _arg1[_set[_local4]];
if (_local5){
if (_local3){
_local2 = (_local2 + _set[_local4]);
};
_local2 = (_local2 + _renderDataType(_local5));
_local3 = false;
} else {
_local3 = true;
};
_local4++;
};
return (_local2);
}
private function _escapeExtensibleValue(_arg1:String):String{
var _local2:String;
var _local3:int;
var _local4:String;
var _local5:String;
_local2 = "";
_local3 = 0;
while (_local3 < _arg1.length) {
_local4 = _arg1.charAt(_local3);
_local5 = _escapeCharMap[_local4];
if (_local5){
_local2 = (_local2 + _local5);
} else {
_local2 = (_local2 + _local4);
};
_local3++;
};
return (_local2);
}
}
}//package com.google.analytics.data
Section 83
//_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(){
_sheet = new StyleSheet();
_loader = new URLLoader();
_init();
}
private function _parseSheet(_arg1:String):void{
_sheet.parseCSS(_arg1);
}
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 84
//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(_arg1:String, _arg2:Array, _arg3:String="uiAlert", _arg4:uint=0, _arg5:Align=null, _arg6:Boolean=false, _arg7:Boolean=true){
var _local8:int;
autoClose = true;
actionOnNextLine = true;
if (_arg4 == 0){
_arg4 = Style.alertColor;
};
if (_arg5 == null){
_arg5 = Align.center;
};
super(_arg1, _arg3, _arg4, _arg5, _arg6);
this.selectable = true;
super.mouseChildren = true;
this.buttonMode = true;
this.mouseEnabled = true;
this.useHandCursor = true;
this.actionOnNextLine = _arg7;
_actions = [];
_local8 = 0;
while (_local8 < _arg2.length) {
_arg2[_local8].container = this;
_actions.push(_arg2[_local8]);
_local8++;
};
}
protected function getAction(_arg1:String):AlertAction{
var _local2:int;
_local2 = 0;
while (_local2 < _actions.length) {
if (_arg1 == _actions[_local2].activator){
return (_actions[_local2]);
};
_local2++;
};
return (null);
}
override protected function layout():void{
super.layout();
_defineActions();
}
protected function spaces(_arg1:int):String{
var _local2:String;
var _local3:String;
var _local4:int;
_local2 = "";
_local3 = " ";
_local4 = 0;
while (_local4 < (_arg1 + 1)) {
_local2 = (_local2 + _local3);
_local4++;
};
return (_local2);
}
override public function onLink(_arg1:TextEvent):void{
var _local2:AlertAction;
if (isValidAction(_arg1.text)){
_local2 = getAction(_arg1.text);
if (_local2){
_local2.execute();
};
};
if (autoClose){
close();
};
}
protected function isValidAction(_arg1:String):Boolean{
var _local2:int;
_local2 = 0;
while (_local2 < _actions.length) {
if (_arg1 == _actions[_local2].activator){
return (true);
};
_local2++;
};
return (false);
}
private function _defineActions():void{
var _local1:String;
var _local2:Array;
var _local3:AlertAction;
var _local4:int;
_local1 = "";
if (actionOnNextLine){
_local1 = (_local1 + "\n");
} else {
_local1 = (_local1 + " |");
};
_local1 = (_local1 + " ");
_local2 = [];
_local4 = 0;
while (_local4 < _actions.length) {
_local3 = _actions[_local4];
_local2.push((((("<a href=\"event:" + _local3.activator) + "\">") + _local3.name) + "</a>"));
_local4++;
};
_local1 = (_local1 + _local2.join(" | "));
appendText(_local1, "uiAlertAction");
}
public function close():void{
if (parent != null){
parent.removeChild(this);
};
}
}
}//package com.google.analytics.debug
Section 85
//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(_arg1:String, _arg2:String, _arg3){
this.name = _arg1;
this.activator = _arg2;
_callback = _arg3;
}
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 86
//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(_arg1:int=0, _arg2:String=""){
_value = _arg1;
_name = _arg2;
}
public function valueOf():int{
return (_value);
}
public function toString():String{
return (_name);
}
}
}//package com.google.analytics.debug
Section 87
//Background (com.google.analytics.debug.Background)
package com.google.analytics.debug {
import flash.display.*;
public class Background {
public static function drawRounded(_arg1, _arg2:Graphics, _arg3:uint=0, _arg4:uint=0):void{
var _local5:uint;
var _local6:uint;
var _local7:uint;
_local7 = Style.roundedCorner;
if ((((_arg3 > 0)) && ((_arg4 > 0)))){
_local5 = _arg3;
_local6 = _arg4;
} else {
_local5 = _arg1.width;
_local6 = _arg1.height;
};
if (((_arg1.stickToEdge) && (!((_arg1.alignement == Align.none))))){
switch (_arg1.alignement){
case Align.top:
_arg2.drawRoundRectComplex(0, 0, _local5, _local6, 0, 0, _local7, _local7);
break;
case Align.topLeft:
_arg2.drawRoundRectComplex(0, 0, _local5, _local6, 0, 0, 0, _local7);
break;
case Align.topRight:
_arg2.drawRoundRectComplex(0, 0, _local5, _local6, 0, 0, _local7, 0);
break;
case Align.bottom:
_arg2.drawRoundRectComplex(0, 0, _local5, _local6, _local7, _local7, 0, 0);
break;
case Align.bottomLeft:
_arg2.drawRoundRectComplex(0, 0, _local5, _local6, 0, _local7, 0, 0);
break;
case Align.bottomRight:
_arg2.drawRoundRectComplex(0, 0, _local5, _local6, _local7, 0, 0, 0);
break;
case Align.left:
_arg2.drawRoundRectComplex(0, 0, _local5, _local6, 0, _local7, 0, _local7);
break;
case Align.right:
_arg2.drawRoundRectComplex(0, 0, _local5, _local6, _local7, 0, _local7, 0);
break;
case Align.center:
_arg2.drawRoundRect(0, 0, _local5, _local6, _local7, _local7);
break;
};
} else {
_arg2.drawRoundRect(0, 0, _local5, _local6, _local7, _local7);
};
}
}
}//package com.google.analytics.debug
Section 88
//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
private var _linediff:int;// = 0
public var maxLines:uint;// = 16
public static var count:uint = 0;
public function Debug(color:uint=0, alignement:Align=null, stickToEdge:Boolean=false){
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 writeBold(message:String):void{
write(message, true);
}
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);
}
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");
}
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!);
}
public function write(message:String, bold:Boolean=false):void{
var inputLines:Array;
if (message.indexOf("") > -1){
inputLines = message.split("\n");
} else {
inputLines = [message];
};
var pre:String = "";
var post:String = "";
if (bold){
pre = "<b>";
post = "</b>";
};
var i:int;
while (i < inputLines.length) {
_lines.push(((pre + inputLines[i]) + post));
i++;
};
var lines:Array = _getLinesToDisplay();
text = lines.join("\n");
}
public function close():void{
dispose();
}
override protected function dispose():void{
removeEventListener(KeyboardEvent.KEY_DOWN, onKey);
super.dispose();
}
}
}//package com.google.analytics.debug
Section 89
//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 showInfos:Boolean;// = true
public var infoTimeout:Number;// = 1000
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(){
_mode = VisualDebugMode.basic;
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 msgs:Array;
var j:int;
var messages:Array = [];
var pre0:String = "";
var pre1:String = "";
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));
};
var len:int = messages.length;
var i:int;
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 90
//FailureAlert (com.google.analytics.debug.FailureAlert)
package com.google.analytics.debug {
public class FailureAlert extends Alert {
public function FailureAlert(_arg1:DebugConfiguration, _arg2:String, _arg3:Array){
var _local4:Align;
var _local5:Boolean;
var _local6:Boolean;
_local4 = Align.bottomLeft;
_local5 = true;
_local6 = false;
if (_arg1.verbose){
_arg2 = ((("<u><span class=\"uiAlertTitle\">Failure</span>" + spaces(18)) + "</u>\n\n") + _arg2);
_local4 = Align.center;
_local5 = false;
_local6 = true;
};
super(_arg2, _arg3, "uiFailure", Style.failureColor, _local4, _local5, _local6);
}
}
}//package com.google.analytics.debug
Section 91
//GIFRequestAlert (com.google.analytics.debug.GIFRequestAlert)
package com.google.analytics.debug {
public class GIFRequestAlert extends Alert {
public function GIFRequestAlert(_arg1:String, _arg2:Array){
super(_arg1, _arg2);
}
}
}//package com.google.analytics.debug
Section 92
//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(_arg1:String):void;
function addToStage(_arg1:DisplayObject):void;
function createGIFRequestAlert(_arg1:String, _arg2:URLRequest, _arg3:GIFRequest):void;
function createPanel(_arg1:String, _arg2:uint, _arg3:uint):void;
function createInfo(_arg1:String):void;
function createFailureAlert(_arg1:String):void;
function addToPanel(_arg1:String, _arg2:DisplayObject):void;
function init():void;
function createSuccessAlert(_arg1:String):void;
function createVisualDebug():void;
function createAlert(_arg1:String):void;
function destroy():void;
function bringToFront(_arg1:DisplayObject):void;
function isAvailable():Boolean;
}
}//package com.google.analytics.debug
Section 93
//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(_arg1:String="", _arg2:uint=3000){
super(_arg1, "uiInfo", Style.infoColor, Align.top, true);
if (_arg2 > 0){
_timer = new Timer(_arg2, 1);
_timer.start();
_timer.addEventListener(TimerEvent.TIMER_COMPLETE, onComplete, false, 0, true);
};
}
public function onComplete(_arg1:TimerEvent):void{
close();
}
override public function onLink(_arg1:TextEvent):void{
switch (_arg1.text){
case "hide":
close();
break;
};
}
public function close():void{
if (parent != null){
parent.removeChild(this);
};
}
}
}//package com.google.analytics.debug
Section 94
//Label (com.google.analytics.debug.Label)
package com.google.analytics.debug {
import flash.display.*;
import flash.events.*;
import flash.text.*;
public class Label extends UISprite {
private var _color:uint;
private var _background:Shape;
private var _textField:TextField;
public var stickToEdge:Boolean;
private var _text:String;
protected var selectable:Boolean;
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);
}
public function get tag():String{
return (_tag);
}
private function _draw():void{
var g:Graphics = _background.graphics;
g.clear();
g.beginFill(_color);
var W:uint = _textField.width;
var H:uint = _textField.height;
if (forcedWidth > 0){
W = forcedWidth;
};
Background.drawRounded(this, g, W, H);
g.endFill();
}
public function get text():String{
return (_textField.text);
}
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 set text(value:String):void{
if (value == ""){
value = _text;
};
_textField.htmlText = (((("<span class=\"" + tag) + "\">") + value) + "</span>");
_text = value;
_draw();
resize();
}
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 set tag(value:String):void{
_tag = value;
text = "";
}
public function onLink(event:TextEvent):void{
}
override protected function dispose():void{
_textField.removeEventListener(TextEvent.LINK, onLink);
super.dispose();
}
}
}//package com.google.analytics.debug
Section 95
//Layout (com.google.analytics.debug.Layout)
package com.google.analytics.debug {
import flash.display.*;
import flash.events.*;
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){
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 createWarning(message:String):void{
if (((_hasWarning) || (!(isAvailable())))){
_warningQueue.push(message);
return;
};
message = _filterMaxChars(message);
_hasWarning = true;
var w:Warning = new Warning(message, _debug.warningTimeout);
addToPanel("analytics", w);
w.addEventListener(Event.REMOVED_FROM_STAGE, _clearWarning, false, 0, true);
if (_hasDebug){
visualDebug.writeBold(message);
};
}
public function bringToFront(visual:DisplayObject):void{
_display.stage.setChildIndex(visual, (_display.stage.numChildren - 1));
}
public function createFailureAlert(message:String):void{
var actionClose:AlertAction;
if (_debug.verbose){
message = _filterMaxChars(message);
actionClose = new AlertAction("Close", "close", "close");
} else {
actionClose = new AlertAction("X", "close", "close");
};
var fa:Alert = 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 = 10;
var W:uint = (_display.stage.stageWidth - (spaces * 2));
var H:uint = (_display.stage.stageHeight - (spaces * 2));
var mp:Panel = 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 panel:Panel;
var d:DisplayObject = _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 line:String;
var CRLF:String = "\n";
var output:Array = [];
var lines:Array = message.split(CRLF);
if (maxCharPerLine == 0){
maxCharPerLine = _maxCharPerLine;
};
var i:int;
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));
}
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;
if (_debug.verbose){
message = _filterMaxChars(message);
actionClose = new AlertAction("Close", "close", "close");
} else {
actionClose = new AlertAction("X", "close", "close");
};
var sa:Alert = 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{
message = _filterMaxChars(message);
var a:Alert = new Alert(message, [new AlertAction("Close", "close", "close")]);
addToPanel("analytics", a);
if (_hasDebug){
visualDebug.writeBold(message);
};
}
public function createInfo(message:String):void{
if (((_hasInfo) || (!(isAvailable())))){
_infoQueue.push(message);
return;
};
message = _filterMaxChars(message);
_hasInfo = true;
var i:Info = 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 message = message;
var request = request;
var ref = ref;
if (_hasGRAlert){
_GRAlertQueue.push([message, request, ref]);
return;
};
_hasGRAlert = true;
var f:Function = function ():void{
ref.sendRequest(request);
};
message = _filterMaxChars(message);
var gra:GIFRequestAlert = 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 = 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 96
//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(_arg1:int=0, _arg2:int=0, _arg3:int=0, _arg4:int=0){
this.top = _arg1;
this.bottom = _arg2;
this.left = _arg3;
this.right = _arg4;
}
}
}//package com.google.analytics.debug
Section 97
//Panel (com.google.analytics.debug.Panel)
package com.google.analytics.debug {
import flash.display.*;
import flash.events.*;
public class Panel extends UISprite {
private var _savedH:uint;
private var _data:UISprite;
private var _mask:Sprite;
private var _background:Shape;
private var _savedW:uint;
private var _stickToEdge:Boolean;
private var _border:Shape;
private var _borderColor:uint;
protected var baseAlpha:Number;
private var _backgroundColor:uint;
private var _title:Label;
private var _colapsed:Boolean;
private var _name:String;
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 get stickToEdge():Boolean{
return (_stickToEdge);
}
public function onToggle(event:MouseEvent=null):void{
if (_colapsed){
_data.visible = true;
} else {
_data.visible = false;
};
_colapsed = !(_colapsed);
_update();
resize();
}
public function set stickToEdge(value:Boolean):void{
_stickToEdge = value;
_title.stickToEdge = value;
}
override protected function dispose():void{
_title.removeEventListener(MouseEvent.CLICK, onToggle);
super.dispose();
}
private function _draw():void{
var W:uint;
var H:uint;
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;
};
var g0:Graphics = _background.graphics;
g0.clear();
g0.beginFill(_backgroundColor);
Background.drawRounded(this, g0, W, H);
g0.endFill();
var g01:Graphics = _data.graphics;
g01.clear();
g01.beginFill(_backgroundColor, 0);
Background.drawRounded(this, g01, W, H);
g01.endFill();
var g1:Graphics = _border.graphics;
g1.clear();
g1.lineStyle(0.1, _borderColor);
Background.drawRounded(this, g1, W, H);
g1.endFill();
var g2:Graphics = _mask.graphics;
g2.clear();
g2.beginFill(_backgroundColor);
Background.drawRounded(this, g2, (W + 1), (H + 1));
g2.endFill();
}
public function get title():String{
return (_title.text);
}
private function _update():void{
_draw();
if (baseAlpha < 1){
_background.alpha = baseAlpha;
_border.alpha = baseAlpha;
};
}
public function addData(child:DisplayObject):void{
_data.addChild(child);
}
override protected function layout():void{
_update();
addChild(_background);
addChild(_data);
addChild(_title);
addChild(_border);
addChild(_mask);
mask = _mask;
}
public function set title(value:String):void{
_title.text = value;
}
public function close():void{
dispose();
if (parent != null){
parent.removeChild(this);
};
}
}
}//package com.google.analytics.debug
Section 98
//Style (com.google.analytics.debug.Style)
package com.google.analytics.debug {
public const Style:_Style = new _Style();
}//package com.google.analytics.debug
Section 99
//SuccessAlert (com.google.analytics.debug.SuccessAlert)
package com.google.analytics.debug {
public class SuccessAlert extends Alert {
public function SuccessAlert(_arg1:DebugConfiguration, _arg2:String, _arg3:Array){
var _local4:Align;
var _local5:Boolean;
var _local6:Boolean;
_local4 = Align.bottomLeft;
_local5 = true;
_local6 = false;
if (_arg1.verbose){
_arg2 = ((("<u><span class=\"uiAlertTitle\">Success</span>" + spaces(18)) + "</u>\n\n") + _arg2);
_local4 = Align.center;
_local5 = false;
_local6 = true;
};
super(_arg2, _arg3, "uiSuccess", Style.successColor, _local4, _local5, _local6);
}
}
}//package com.google.analytics.debug
Section 100
//UISprite (com.google.analytics.debug.UISprite)
package com.google.analytics.debug {
import flash.display.*;
import flash.events.*;
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(_arg1:DisplayObject=null){
listenResize = false;
alignement = Align.none;
this.alignTarget = _arg1;
margin = new Margin();
addEventListener(Event.ADDED_TO_STAGE, _onAddedToStage);
addEventListener(Event.REMOVED_FROM_STAGE, _onRemovedFromStage);
}
protected function dispose():void{
var _local1:DisplayObject;
var _local2:int;
_local2 = 0;
while (_local2 < numChildren) {
_local1 = getChildAt(_local2);
if (_local1){
removeChild(_local1);
};
_local2++;
};
}
protected function layout():void{
}
public function get forcedHeight():uint{
if (_forcedHeight){
return (_forcedHeight);
};
return (height);
}
public function alignTo(_arg1:Align, _arg2:DisplayObject=null):void{
var _local3:uint;
var _local4:uint;
var _local5:uint;
var _local6:uint;
var _local7:UISprite;
if (_arg2 == null){
if ((parent is Stage)){
_arg2 = this.stage;
} else {
_arg2 = parent;
};
};
if (_arg2 == this.stage){
if (this.stage == null){
return;
};
_local3 = this.stage.stageHeight;
_local4 = this.stage.stageWidth;
_local5 = 0;
_local6 = 0;
} else {
_local7 = (_arg2 as UISprite);
if (_local7.forcedHeight){
_local3 = _local7.forcedHeight;
} else {
_local3 = _local7.height;
};
if (_local7.forcedWidth){
_local4 = _local7.forcedWidth;
} else {
_local4 = _local7.width;
};
_local5 = 0;
_local6 = 0;
};
switch (_arg1){
case Align.top:
x = ((_local4 / 2) - (forcedWidth / 2));
y = (_local6 + margin.top);
break;
case Align.bottom:
x = ((_local4 / 2) - (forcedWidth / 2));
y = (((_local6 + _local3) - forcedHeight) - margin.bottom);
break;
case Align.left:
x = (_local5 + margin.left);
y = ((_local3 / 2) - (forcedHeight / 2));
break;
case Align.right:
x = (((_local5 + _local4) - forcedWidth) - margin.right);
y = ((_local3 / 2) - (forcedHeight / 2));
break;
case Align.center:
x = ((_local4 / 2) - (forcedWidth / 2));
y = ((_local3 / 2) - (forcedHeight / 2));
break;
case Align.topLeft:
x = (_local5 + margin.left);
y = (_local6 + margin.top);
break;
case Align.topRight:
x = (((_local5 + _local4) - forcedWidth) - margin.right);
y = (_local6 + margin.top);
break;
case Align.bottomLeft:
x = (_local5 + margin.left);
y = (((_local6 + _local3) - forcedHeight) - margin.bottom);
break;
case Align.bottomRight:
x = (((_local5 + _local4) - forcedWidth) - margin.right);
y = (((_local6 + _local3) - forcedHeight) - margin.bottom);
break;
};
if (((!(listenResize)) && (!((_arg1 == Align.none))))){
_arg2.addEventListener(Event.RESIZE, onResize, false, 0, true);
listenResize = true;
};
this.alignement = _arg1;
this.alignTarget = _arg2;
}
public function get forcedWidth():uint{
if (_forcedWidth){
return (_forcedWidth);
};
return (width);
}
protected function onResize(_arg1:Event):void{
resize();
}
private function _onRemovedFromStage(_arg1: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(_arg1:Event):void{
layout();
resize();
}
public function set forcedHeight(_arg1:uint):void{
_forcedHeight = _arg1;
}
public function set forcedWidth(_arg1:uint):void{
_forcedWidth = _arg1;
}
}
}//package com.google.analytics.debug
Section 101
//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(_arg1:String="", _arg2:uint=3000){
super(_arg1, "uiWarning", Style.warningColor, Align.top, false);
margin.top = 32;
if (_arg2 > 0){
_timer = new Timer(_arg2, 1);
_timer.start();
_timer.addEventListener(TimerEvent.TIMER_COMPLETE, onComplete, false, 0, true);
};
}
public function onComplete(_arg1:TimerEvent):void{
close();
}
override public function onLink(_arg1:TextEvent):void{
switch (_arg1.text){
case "hide":
close();
break;
};
}
public function close():void{
if (parent != null){
parent.removeChild(this);
};
}
}
}//package com.google.analytics.debug
Section 102
//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(_arg1:int=0, _arg2:String=""){
_value = _arg1;
_name = _arg2;
}
public function valueOf():int{
return (_value);
}
public function toString():String{
return (_name);
}
}
}//package com.google.analytics.debug
Section 103
//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(_arg1:String, _arg2:AnalyticsTracker, _arg3:Boolean=false, _arg4:Boolean=false){
super(_arg1, _arg3, _arg4);
this.tracker = _arg2;
}
override public function clone():Event{
return (new AnalyticsEvent(type, tracker, bubbles, cancelable));
}
}
}//package com.google.analytics.events
Section 104
//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(_arg1:DebugConfiguration){
_gaGlobalVerified = false;
super(_arg1);
}
public function set vid(_arg1:String):void{
if (!isAvailable()){
return;
};
_verify();
setProperty("gaGlobal.vid", _arg1);
}
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(_arg1:String):void{
if (!isAvailable()){
return;
};
_verify();
setProperty("gaGlobal.hid", _arg1);
}
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(_arg1:String):void{
if (!isAvailable()){
return;
};
_verify();
setProperty("gaGlobal.sid", _arg1);
}
}
}//package com.google.analytics.external
Section 105
//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(_arg1:DebugConfiguration){
super(_arg1);
}
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 _local1:Object;
if (!isAvailable()){
return;
};
_local1 = call(cache_properties_js);
if (_local1){
_host = _local1.host;
_language = _local1.language;
_characterSet = _local1.characterSet;
_colorDepth = _local1.colorDepth;
_location = _local1.location;
_pathname = _local1.pathname;
_protocol = _local1.protocol;
_search = _local1.search;
_referrer = _local1.referrer;
_title = _local1.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 _local1:String;
if (_characterSet){
return (_characterSet);
};
if (!isAvailable()){
return (null);
};
_local1 = getProperty("document.characterSet");
if (_local1 == null){
_local1 = getProperty("document.charset");
};
_characterSet = _local1;
return (_characterSet);
}
public function get language():String{
var _local1:String;
if (_language){
return (_language);
};
if (!isAvailable()){
return (null);
};
_local1 = getProperty("navigator.language");
if (_local1 == null){
_local1 = getProperty("navigator.browserLanguage");
};
_language = _local1;
return (_language);
}
}
}//package com.google.analytics.external
Section 106
//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(_arg1:DebugConfiguration){
_notAvailableWarning = true;
super();
_debug = _arg1;
}
public function getProperty(_arg1:String){
return (call((_arg1 + ".valueOf")));
}
public function hasProperty(_arg1:String):Boolean{
return (call(hasProperty_js, _arg1));
}
public function setProperty(_arg1:String, _arg2):void{
call(setProperty_js, _arg1, _arg2);
}
public function executeBlock(_arg1:String):void{
var data = _arg1;
if (isAvailable()){
try {
ExternalInterface.call(data);
} catch(e:SecurityError) {
if (_debug.javascript){
_debug.warning("ExternalInterface is not allowed.\nEnsure that allowScriptAccess is set to \"always\" in the Flash embed HTML.");
};
} catch(e:Error) {
if (_debug.javascript){
_debug.warning(("ExternalInterface failed to make the call\nreason: " + e.message));
};
};
};
}
public function getPropertyString(_arg1:String):String{
return (call((_arg1 + ".toString")));
}
public function setPropertyByReference(_arg1:String, _arg2:String):void{
call(setPropertyRef_js, _arg1, _arg2);
}
public function call(_arg1:String, ... _args){
var output:String;
var functionName = _arg1;
var args = _args;
if (isAvailable()){
try {
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));
} catch(e:SecurityError) {
if (_debug.javascript){
_debug.warning("ExternalInterface is not allowed.\nEnsure that allowScriptAccess is set to \"always\" in the Flash embed HTML.");
};
} catch(e:Error) {
if (_debug.javascript){
_debug.warning(("ExternalInterface failed to make the call\nreason: " + e.message));
};
};
};
return (null);
}
public function isAvailable():Boolean{
var _local1:Boolean;
_local1 = ExternalInterface.available;
if (((_local1) && ((Capabilities.playerType == "External")))){
_local1 = false;
};
if (((((!(_local1)) && (_debug.javascript))) && (_notAvailableWarning))){
_debug.warning("ExternalInterface is not available.");
_notAvailableWarning = false;
};
return (_local1);
}
}
}//package com.google.analytics.external
Section 107
//Environment (com.google.analytics.utils.Environment)
package com.google.analytics.utils {
import com.google.analytics.debug.*;
import com.google.analytics.core.*;
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(_arg1:String="", _arg2:String="", _arg3:String="", _arg4:DebugConfiguration=null, _arg5:HTMLDOM=null){
var _local6:Version;
super();
if (_arg2 == ""){
if (isAIR()){
_arg2 = "AIR";
} else {
_arg2 = "Flash";
};
};
if (_arg3 == ""){
_local6 = flashVersion;
} else {
_local6 = Version.fromString(_arg3);
};
_url = _arg1;
_appName = _arg2;
_appVersion = _local6;
_debug = _arg4;
_dom = _arg5;
}
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 _local1:String;
_local1 = _dom.search;
if (_local1){
return (_local1);
};
return ("");
}
public function get protocol():Protocols{
if (!_protocol){
_findProtocol();
};
return (_protocol);
}
public function get flashVersion():Version{
var _local1:Version;
_local1 = Version.fromString(Capabilities.version.split(" ")[1], ",");
return (_local1);
}
public function get screenWidth():Number{
return (Capabilities.screenResolutionX);
}
public function get languageEncoding():String{
var _local1:String;
if (System.useCodePage){
_local1 = _dom.characterSet;
if (_local1){
return (_local1);
};
return ("-");
};
return ("UTF-8");
}
public function get appName():String{
return (_appName);
}
public function get screenColorDepth():String{
var _local1:String;
var _local2:String;
switch (Capabilities.screenColor){
case "bw":
_local1 = "1";
break;
case "gray":
_local1 = "2";
break;
case "color":
default:
_local1 = "24";
};
_local2 = _dom.colorDepth;
if (_local2){
_local1 = _local2;
};
return (_local1);
}
private function _findProtocol():void{
var _local1:Protocols;
var _local2:String;
var _local3:String;
var _local4:String;
var _local5:String;
_local1 = Protocols.none;
if (_url != ""){
_local4 = _url.toLowerCase();
_local5 = _local4.substr(0, 5);
switch (_local5){
case "file:":
_local1 = Protocols.file;
break;
case "http:":
_local1 = Protocols.HTTP;
break;
case "https":
if (_local4.charAt(5) == ":"){
_local1 = Protocols.HTTPS;
};
break;
default:
_protocol = Protocols.none;
};
};
_local2 = _dom.protocol;
_local3 = (_local1.toString() + ":").toLowerCase();
if (((((_local2) && (!((_local2 == _local3))))) && (_debug))){
_debug.warning(((("Protocol mismatch: SWF=" + _local3) + ", DOM=") + _local2));
};
_protocol = _local1;
}
public function get locationSWFPath():String{
return (_url);
}
public function get platform():String{
var _local1:String;
_local1 = Capabilities.manufacturer;
return (_local1.split("Adobe ")[1]);
}
public function get operatingSystem():String{
return (Capabilities.os);
}
public function set appName(_arg1:String):void{
_appName = _arg1;
userAgent.applicationProduct = _arg1;
}
public function get userAgent():UserAgent{
if (!_userAgent){
_userAgent = new UserAgent(this, appName, appVersion.toString(4));
};
return (_userAgent);
}
ga_internal function set url(_arg1:String):void{
_url = _arg1;
}
public function get referrer():String{
var _local1:String;
_local1 = _dom.referrer;
if (_local1){
return (_local1);
};
if (protocol == Protocols.file){
return ("localhost");
};
return ("");
}
public function isInHTML():Boolean{
return ((Capabilities.playerType == "PlugIn"));
}
public function get language():String{
var _local1:String;
var _local2:String;
_local1 = _dom.language;
_local2 = Capabilities.language;
if (_local1){
if ((((_local1.length > _local2.length)) && ((_local1.substr(0, _local2.length) == _local2)))){
_local2 = _local1;
};
};
return (_local2);
}
public function get domainName():String{
var _local1:String;
var _local2:String;
var _local3:int;
if ((((protocol == Protocols.HTTP)) || ((protocol == Protocols.HTTPS)))){
_local1 = _url.toLowerCase();
if (protocol == Protocols.HTTP){
_local2 = _local1.split("http://").join("");
} else {
if (protocol == Protocols.HTTPS){
_local2 = _local1.split("https://").join("");
};
};
_local3 = _local2.indexOf("/");
if (_local3 > -1){
_local2 = _local2.substring(0, _local3);
};
return (_local2);
};
if (protocol == Protocols.file){
return ("localhost");
};
return ("");
}
public function set userAgent(_arg1:UserAgent):void{
_userAgent = _arg1;
}
public function set appVersion(_arg1:Version):void{
_appVersion = _arg1;
userAgent.applicationVersion = _arg1.toString(4);
}
public function get screenHeight():Number{
return (Capabilities.screenResolutionY);
}
public function get locationPath():String{
var _local1:String;
_local1 = _dom.pathname;
if (_local1){
return (_local1);
};
return ("");
}
public function get documentTitle():String{
var _local1:String;
_local1 = _dom.title;
if (_local1){
return (_local1);
};
return ("");
}
public function get appVersion():Version{
return (_appVersion);
}
}
}//package com.google.analytics.utils
Section 108
//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(_arg1:int=0, _arg2:String=""){
_value = _arg1;
_name = _arg2;
}
public function valueOf():int{
return (_value);
}
public function toString():String{
return (_name);
}
}
}//package com.google.analytics.utils
Section 109
//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 110
//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 = _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 protocol():Protocols{
var proto:String = _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 = _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);
}
public function get subDomain():String{
if (((!((domain == ""))) && (!((domain == hostName))))){
return (hostName.split(("." + domain)).join(""));
};
return ("");
}
public function get search():String{
var _search:String = _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);
}
}
}//package com.google.analytics.utils
Section 111
//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(_arg1:Environment, _arg2:String="", _arg3:String=""){
_localInfo = _arg1;
applicationProduct = _arg2;
_version = Version.fromString(_arg3);
}
public function get tamarinProductToken():String{
if (UserAgent.minimal){
return ("");
};
if (System.vmVersion){
return (("Tamarin/" + Utils.trim(System.vmVersion, true)));
};
return ("");
}
public function set applicationProduct(_arg1:String):void{
_applicationProduct = _arg1;
}
public function get applicationVersion():String{
return (_version.toString(2));
}
public function get applicationProductToken():String{
var _local1:String;
_local1 = applicationProduct;
if (applicationVersion != ""){
_local1 = (_local1 + ("/" + applicationVersion));
};
return (_local1);
}
public function get vendorProductToken():String{
var _local1:String;
_local1 = "";
if (_localInfo.isAIR()){
_local1 = (_local1 + "AIR");
} else {
_local1 = (_local1 + "FlashPlayer");
};
_local1 = (_local1 + "/");
_local1 = (_local1 + _version.toString(3));
return (_local1);
}
public function toString():String{
var _local1:String;
_local1 = "";
_local1 = (_local1 + applicationProductToken);
if (applicationComment != ""){
_local1 = (_local1 + (" " + applicationComment));
};
if (tamarinProductToken != ""){
_local1 = (_local1 + (" " + tamarinProductToken));
};
if (vendorProductToken != ""){
_local1 = (_local1 + (" " + vendorProductToken));
};
return (_local1);
}
public function get applicationComment():String{
var _local1:Array;
_local1 = [];
_local1.push(_localInfo.platform);
_local1.push(_localInfo.playerType);
if (!UserAgent.minimal){
_local1.push(_localInfo.operatingSystem);
_local1.push(_localInfo.language);
};
if (Capabilities.isDebugger){
_local1.push("DEBUG");
};
if (_local1.length > 0){
return ((("(" + _local1.join("; ")) + ")"));
};
return ("");
}
public function set applicationVersion(_arg1:String):void{
_version = Version.fromString(_arg1);
}
public function get applicationProduct():String{
return (_applicationProduct);
}
}
}//package com.google.analytics.utils
Section 112
//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 = [];
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 = _args.length;
var i:int;
while (i < l) {
if (!(_args[i] is Variables)){
} else {
_join(_args[i]);
};
i++;
};
}
public function toString():String{
var value:String;
var p:String;
var component:String;
var i:int;
var j:int;
var priority:String;
var last:String;
var data:Array = [];
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;
if (source == ""){
return;
};
if (source.indexOf("&") > -1){
data = source.split("&");
} else {
data = [source];
};
var i:int;
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 p:String;
var urlvars:URLVariables = new URLVariables();
for (p in this) {
urlvars[p] = this[p];
};
return (urlvars);
}
}
}//package com.google.analytics.utils
Section 113
//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(_arg1:uint=0, _arg2:uint=0, _arg3:uint=0, _arg4:uint=0){
var _local5:Version;
_maxMajor = 15;
_maxMinor = 15;
_maxBuild = 0xFF;
_maxRevision = 0xFFFF;
_separator = ".";
super();
if ((((((((_arg1 > _maxMajor)) && ((_arg2 == 0)))) && ((_arg3 == 0)))) && ((_arg4 == 0)))){
_local5 = Version.fromNumber(_arg1);
_arg1 = _local5.major;
_arg2 = _local5.minor;
_arg3 = _local5.build;
_arg4 = _local5.revision;
};
this.major = _arg1;
this.minor = _arg2;
this.build = _arg3;
this.revision = _arg4;
}
public function toString(_arg1:int=0):String{
var _local2:Array;
if ((((_arg1 <= 0)) || ((_arg1 > 4)))){
_arg1 = getFields();
};
switch (_arg1){
case 1:
_local2 = [major];
break;
case 2:
_local2 = [major, minor];
break;
case 3:
_local2 = [major, minor, build];
break;
case 4:
default:
_local2 = [major, minor, build, revision];
};
return (_local2.join(_separator));
}
public function get revision():uint{
return (_revision);
}
public function set build(_arg1:uint):void{
_build = Math.min(_arg1, _maxBuild);
}
public function set minor(_arg1:uint):void{
_minor = Math.min(_arg1, _maxMinor);
}
public function get build():uint{
return (_build);
}
public function set major(_arg1:uint):void{
_major = Math.min(_arg1, _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(_arg1:uint):void{
_revision = Math.min(_arg1, _maxRevision);
}
private function getFields():int{
var _local1:int;
_local1 = 4;
if (revision == 0){
_local1--;
};
if ((((_local1 == 3)) && ((build == 0)))){
_local1--;
};
if ((((_local1 == 2)) && ((minor == 0)))){
_local1--;
};
return (_local1);
}
public function equals(_arg1):Boolean{
if (!(_arg1 is Version)){
return (false);
};
if ((((((((_arg1.major == major)) && ((_arg1.minor == minor)))) && ((_arg1.build == build)))) && ((_arg1.revision == revision)))){
return (true);
};
return (false);
}
public static function fromString(_arg1:String="", _arg2:String="."):Version{
var _local3:Version;
var _local4:Array;
_local3 = new (Version);
if ((((_arg1 == "")) || ((_arg1 == null)))){
return (_local3);
};
if (_arg1.indexOf(_arg2) > -1){
_local4 = _arg1.split(_arg2);
_local3.major = parseInt(_local4[0]);
_local3.minor = parseInt(_local4[1]);
_local3.build = parseInt(_local4[2]);
_local3.revision = parseInt(_local4[3]);
} else {
_local3.major = parseInt(_arg1);
};
return (_local3);
}
public static function fromNumber(_arg1:Number=0):Version{
var _local2:Version;
_local2 = new (Version);
if (((((((((((isNaN(_arg1)) || ((_arg1 == 0)))) || ((_arg1 < 0)))) || ((_arg1 == Number.MAX_VALUE)))) || ((_arg1 == Number.POSITIVE_INFINITY)))) || ((_arg1 == Number.NEGATIVE_INFINITY)))){
return (_local2);
};
_local2.major = (_arg1 >>> 28);
_local2.minor = ((_arg1 & 251658240) >>> 24);
_local2.build = ((_arg1 & 0xFF0000) >>> 16);
_local2.revision = (_arg1 & 0xFFFF);
return (_local2);
}
}
}//package com.google.analytics.utils
Section 114
//Bridge (com.google.analytics.v4.Bridge)
package com.google.analytics.v4 {
import com.google.analytics.debug.*;
import com.google.analytics.core.*;
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;
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);
}
private function _linkTrackingObject(path:String):void{
_proxy.call(_linkTrackingObject_js, _jsContainer, path);
}
public function trackEvent(category:String, action:String, label:String=null, value:Number=NaN):Boolean{
var 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));
};
}
public function setClientInfo(enable:Boolean):void{
_debug.info((("setClientInfo( " + enable) + " )"));
_call("_setClientInfo", enable);
}
public function trackTrans():void{
_debug.info("trackTrans()");
_call("_trackTrans");
}
public function setCookieTimeout(newDefaultTimeout:int):void{
_debug.info((("setCookieTimeout( " + newDefaultTimeout) + " )"));
_call("_setCookieTimeout", newDefaultTimeout);
}
public function trackPageview(pageURL:String=""):void{
_debug.info((("trackPageview( " + pageURL) + " )"));
_call("_trackPageview", pageURL);
}
public function getClientInfo():Boolean{
_debug.info("getClientInfo()");
return (_call("_getClientInfo"));
}
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 = _proxy.hasProperty(account);
var isTracker:Boolean = _proxy.hasProperty((account + "._getAccount"));
return (((hasObj) && (isTracker)));
}
public function resetSession():void{
_debug.warning("resetSession() not implemented");
}
public function getDetectTitle():Boolean{
_debug.info("getDetectTitle()");
return (_call("_getDetectTitle"));
}
public function setCampNameKey(newCampNameKey:String):void{
_debug.info((("setCampNameKey( " + newCampNameKey) + " )"));
_call("_setCampNameKey", newCampNameKey);
}
public function setDetectFlash(enable:Boolean):void{
_debug.info((("setDetectFlash( " + enable) + " )"));
_call("_setDetectFlash", enable);
}
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 setCampSourceKey(newCampSrcKey:String):void{
_debug.info((("setCampSourceKey( " + newCampSrcKey) + " )"));
_call("_setCampSourceKey", newCampSrcKey);
}
public function addTrans(orderId:String, affiliation:String, total:Number, tax:Number, shipping:Number, city:String, state:String, country:String):Object{
_debug.info((("addTrans( " + [orderId, affiliation, total, tax, shipping, city, state, country].join(", ")) + " )"));
_call("_addTrans", orderId, affiliation, total, tax, shipping, city, state, country);
return (null);
}
public function setCampContentKey(newCampContentKey:String):void{
_debug.info((("setCampContentKey( " + newCampContentKey) + " )"));
_call("_setCampContentKey", newCampContentKey);
}
public function setLocalServerMode():void{
_debug.info("setLocalServerMode()");
_call("_setLocalServerMode");
}
public function getLocalGifPath():String{
_debug.info("getLocalGifPath()");
return (_call("_getLocalGifPath"));
}
public function clearIgnoredRef():void{
_debug.info("clearIgnoredRef()");
_call("_clearIgnoreRef");
}
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);
}
private function _createTrackingObject(account:String):void{
_proxy.call(_createTrackingObject_js, account);
}
public function setCampaignTrack(enable:Boolean):void{
_debug.info((("setCampaignTrack( " + enable) + " )"));
_call("_setCampaignTrack", enable);
}
public function clearOrganic():void{
_debug.info("clearOrganic()");
_call("_clearOrganic");
}
public function setCampTermKey(newCampTermKey:String):void{
_debug.info((("setCampTermKey( " + newCampTermKey) + " )"));
_call("_setCampTermKey", newCampTermKey);
}
public function getDetectFlash():Boolean{
_debug.info("getDetectFlash()");
return (_call("_getDetectFlash"));
}
public function setCampMediumKey(newCampMedKey:String):void{
_debug.info((("setCampMediumKey( " + newCampMedKey) + " )"));
_call("_setCampMediumKey", newCampMedKey);
}
public function addIgnoredRef(newIgnoredReferrer:String):void{
_debug.info((("addIgnoredRef( " + newIgnoredReferrer) + " )"));
_call("_addIgnoredRef", newIgnoredReferrer);
}
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 115
//Configuration (com.google.analytics.v4.Configuration)
package com.google.analytics.v4 {
import com.google.analytics.debug.*;
import com.google.analytics.core.*;
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(_arg1: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 = _arg1;
_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(_arg1:String, _arg2:String):void{
var engine = _arg1;
var keyword = _arg2;
try {
_organic.addSource(engine, keyword);
} catch(e:Error) {
if (((_debug) && (_debug.active))){
_debug.warning(e.message);
};
};
}
public function get domain():Domain{
return (_domain);
}
public function set sampleRate(_arg1:Number):void{
if (_arg1 <= 0){
_arg1 = 0.1;
};
if (_arg1 > 1){
_arg1 = 1;
};
_arg1 = Number(_arg1.toFixed(2));
_sampleRate = _arg1;
}
public function get version():String{
return (_version);
}
}
}//package com.google.analytics.v4
Section 116
//GoogleAnalyticsAPI (com.google.analytics.v4.GoogleAnalyticsAPI)
package com.google.analytics.v4 {
import com.google.analytics.core.*;
public interface GoogleAnalyticsAPI {
function setCampSourceKey(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function getServiceMode():ServerOperationMode;
function resetSession():void;
function setLocalServerMode():void;
function setCampContentKey(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function addOrganic(_arg1:String, _arg2:String):void;
function setDetectFlash(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:Boolean):void;
function addTrans(_arg1:String, _arg2:String, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:String, _arg7:String, _arg8:String):Object;
function trackEvent(_arg1:String, _arg2:String, _arg3:String=null, _arg4:Number=NaN):Boolean;
function setCampTermKey(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function setCampNameKey(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function addIgnoredOrganic(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function addItem(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:Number, _arg6:int):void;
function setAllowLinker(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:Boolean):void;
function getClientInfo():Boolean;
function getDetectFlash():Boolean;
function setCampaignTrack(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:Boolean):void;
function createEventTracker(void:String):EventTracker;
function setCookieTimeout(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:int):void;
function setAllowAnchor(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:Boolean):void;
function trackTrans():void;
function clearOrganic():void;
function trackPageview(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String=""):void;
function setLocalGifPath(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function getVersion():String;
function getLocalGifPath():String;
function setVar(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function clearIgnoredOrganic():void;
function setCampMediumKey(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function addIgnoredRef(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function setClientInfo(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:Boolean):void;
function setCookiePath(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function setSampleRate(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:Number):void;
function setSessionTimeout(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:int):void;
function setRemoteServerMode():void;
function clearIgnoredRef():void;
function setDomainName(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function setDetectTitle(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:Boolean):void;
function setAllowHash(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:Boolean):void;
function getAccount():String;
function linkByPost(_arg1:Object, _arg2:Boolean=false):void;
function link(_arg1:String, _arg2:Boolean=false):void;
function setCampNOKey(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function setLocalRemoteServerMode():void;
function cookiePathCopy(/buRRRn/projects/GAforFlash/GA_AS3/build/tmp;com/google/analytics/v4;GoogleAnalyticsAPI.as:String):void;
function getDetectTitle():Boolean;
}
}//package com.google.analytics.v4
Section 117
//Tracker (com.google.analytics.v4.Tracker)
package com.google.analytics.v4 {
import com.google.analytics.debug.*;
import com.google.analytics.core.*;
import com.google.analytics.utils.*;
import com.google.analytics.external.*;
import com.google.analytics.data.*;
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 _account:String;
public function Tracker(account:String, config:Configuration, debug:DebugConfiguration, info:Environment, buffer:Buffer, gifRequest:GIFRequest, adSense:AdSenseGlobals){
var msg:String;
super();
_account = account;
_config = config;
_debug = debug;
_info = info;
_buffer = buffer;
_gifRequest = gifRequest;
_adSense = adSense;
if (!Utils.validateAccount(account)){
msg = (("Account \"" + account) + "\" is not valid.");
_debug.warning(msg);
throw (new Error(msg));
};
_initData();
}
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 trackEvent(category:String, action:String, label:String=null, value:Number=NaN):Boolean{
var success:Boolean;
var 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) && (!((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 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{
_debug.warning("trackTrans() not implemented");
}
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( " + [formObject, useHash].join(", ")) + " ) not implemented"));
}
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);
};
};
_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();
}
public function getClientInfo():Boolean{
_debug.info("getClientInfo()");
return (_config.detectClientInfo);
}
private function _sendXEvent(opt_xObj:X10=null):void{
var searchVariables:Variables;
var eventInfo:EventInfo;
var eventvars:Variables;
var generalvars:Variables;
_initData();
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{
_config.campaignKey.UCCN = newCampNameKey;
var msg = (("setCampNameKey( " + _config.campaignKey.UCCN) + " )");
if (_debug.mode == VisualDebugMode.geek){
_debug.info((msg + " [UCCN]"));
} else {
_debug.info(msg);
};
}
private function _formatReferrer():String{
var domainName:String;
var ref:URL;
var dom:URL;
var referrer:String = _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(item:String, sku:String, name:String, category:String, price:Number, quantity:int):void{
_debug.warning((("addItem( " + [item, sku, name, category, price, quantity].join(", ")) + " ) not implemented"));
}
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 = 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) + " )"));
}
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):Object{
_debug.warning((("addTrans( " + [orderId, affiliation, total, tax, shipping, city, state, country].join(", ")) + " ) not implemented"));
return (null);
}
private function _renderMetricsSearchVariables(pageURL:String=""):Variables{
var campvars:Variables;
var variables:Variables = new Variables();
variables.URIencode = true;
var docInfo:DocumentInfo = new DocumentInfo(_config, _info, _formatedReferrer, pageURL, _adSense);
_debug.info(("docInfo: " + docInfo.toURLString()), VisualDebugMode.geek);
if (_config.campaignTracking){
campvars = _campaignInfo.toVariables();
};
var browservars:Variables = _browserInfo.toVariables();
variables.join(docInfo.toVariables(), browservars, campvars);
return (variables);
}
public function setCampContentKey(newCampContentKey:String):void{
_config.campaignKey.UCCT = newCampContentKey;
var 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){
};
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()");
}
public function clearIgnoredRef():void{
_debug.info("clearIgnoredRef()");
_config.organic.clearIgnoredReferrals();
}
public function setCampSourceKey(newCampSrcKey:String):void{
_config.campaignKey.UCSR = newCampSrcKey;
var 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 = _config.domainName;
var g0 = (domainName.indexOf("www.google.") < 0);
var g1 = (domainName.indexOf(".google.") < 0);
var g2 = (domainName.indexOf("google.") < 0);
var 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 + _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 setCampNOKey(newCampNOKey:String):void{
_config.campaignKey.UCNO = newCampNOKey;
var msg = (("setCampNOKey( " + _config.campaignKey.UCNO) + " )");
if (_debug.mode == VisualDebugMode.geek){
_debug.info((msg + " [UCNO]"));
} else {
_debug.info(msg);
};
}
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{
_config.campaignKey.UCTR = newCampTermKey;
var 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);
}
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{
_config.campaignKey.UCMD = newCampMedKey;
var 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 = ((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{
_debug.warning((("link( " + [targetUrl, useHash].join(", ")) + " ) not implemented"));
}
public function setRemoteServerMode():void{
_config.serverMode = ServerOperationMode.remote;
_debug.info("setRemoteServerMode()");
}
}
}//package com.google.analytics.v4
Section 118
//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(_arg1:Configuration):void;
function isReady():Boolean;
function get mode():String;
function set debug(_arg1:DebugConfiguration):void;
function get account():String;
function set mode(_arg1:String):void;
function get config():Configuration;
function get debug():DebugConfiguration;
function set account(_arg1:String):void;
function get visualDebug():Boolean;
function set visualDebug(_arg1:Boolean):void;
}
}//package com.google.analytics
Section 119
//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 120
//GATracker (com.google.analytics.GATracker)
package com.google.analytics {
import flash.display.*;
import flash.events.*;
import com.google.analytics.v4.*;
import com.google.analytics.debug.*;
import com.google.analytics.core.*;
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 _account:String;
private var _tracker:GoogleAnalyticsAPI;
public static var version:Version = API.version;
public static var autobuild:Boolean = true;
public function GATracker(_arg1:DisplayObject, _arg2:String, _arg3:String="AS3", _arg4:Boolean=false, _arg5:Configuration=null, _arg6:DebugConfiguration=null){
_ready = false;
super();
_display = _arg1;
_eventDispatcher = new EventDispatcher(this);
_tracker = new TrackerCache();
this.account = _arg2;
this.mode = _arg3;
this.visualDebug = _arg4;
if (!_arg6){
this.debug = new DebugConfiguration();
};
if (!_arg5){
this.config = new Configuration(_arg6);
};
if (autobuild){
_factory();
};
}
public function link(_arg1:String, _arg2:Boolean=false):void{
_tracker.link(_arg1, _arg2);
}
public function addOrganic(_arg1:String, _arg2:String):void{
_tracker.addOrganic(_arg1, _arg2);
}
public function setAllowLinker(_arg1:Boolean):void{
_tracker.setAllowLinker(_arg1);
}
public function trackEvent(_arg1:String, _arg2:String, _arg3:String=null, _arg4:Number=NaN):Boolean{
return (_tracker.trackEvent(_arg1, _arg2, _arg3, _arg4));
}
public function setCookieTimeout(_arg1:int):void{
_tracker.setCookieTimeout(_arg1);
}
public function trackTrans():void{
_tracker.trackTrans();
}
public function trackPageview(_arg1:String=""):void{
_tracker.trackPageview(_arg1);
}
public function getClientInfo():Boolean{
return (_tracker.getClientInfo());
}
public function setClientInfo(_arg1:Boolean):void{
_tracker.setClientInfo(_arg1);
}
public function get account():String{
return (_account);
}
public function linkByPost(_arg1:Object, _arg2:Boolean=false):void{
_tracker.linkByPost(_arg1, _arg2);
}
public function getDetectTitle():Boolean{
return (_tracker.getDetectTitle());
}
public function dispatchEvent(_arg1:Event):Boolean{
return (_eventDispatcher.dispatchEvent(_arg1));
}
public function get config():Configuration{
return (_config);
}
public function set mode(_arg1:String):void{
_mode = _arg1;
}
public function removeEventListener(_arg1:String, _arg2:Function, _arg3:Boolean=false):void{
_eventDispatcher.removeEventListener(_arg1, _arg2, _arg3);
}
public function setDetectFlash(_arg1:Boolean):void{
_tracker.setDetectFlash(_arg1);
}
public function resetSession():void{
_tracker.resetSession();
}
public function setCampNameKey(_arg1:String):void{
_tracker.setCampNameKey(_arg1);
}
public function get debug():DebugConfiguration{
return (_debug);
}
public function addItem(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:Number, _arg6:int):void{
_tracker.addItem(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6);
}
private function _bridgeFactory():GoogleAnalyticsAPI{
debug.info(((("GATracker (Bridge) v" + version) + "\naccount: ") + account));
return (new Bridge(account, _debug, _jsproxy));
}
public function addEventListener(_arg1:String, _arg2:Function, _arg3:Boolean=false, _arg4:int=0, _arg5:Boolean=false):void{
_eventDispatcher.addEventListener(_arg1, _arg2, _arg3, _arg4, _arg5);
}
public function clearIgnoredOrganic():void{
_tracker.clearIgnoredOrganic();
}
public function set account(_arg1:String):void{
_account = _arg1;
}
public function setVar(_arg1:String):void{
_tracker.setVar(_arg1);
}
public function build():void{
if (!isReady()){
_factory();
};
}
public function setDomainName(_arg1:String):void{
_tracker.setDomainName(_arg1);
}
public function createEventTracker(_arg1:String):EventTracker{
return (_tracker.createEventTracker(_arg1));
}
public function set config(_arg1:Configuration):void{
_config = _arg1;
}
public function addTrans(_arg1:String, _arg2:String, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:String, _arg7:String, _arg8:String):Object{
return (_tracker.addTrans(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7, _arg8));
}
public function setCampSourceKey(_arg1:String):void{
_tracker.setCampSourceKey(_arg1);
}
public function setCampContentKey(_arg1:String):void{
_tracker.setCampContentKey(_arg1);
}
public function willTrigger(_arg1:String):Boolean{
return (_eventDispatcher.willTrigger(_arg1));
}
public function setLocalServerMode():void{
_tracker.setLocalServerMode();
}
public function isReady():Boolean{
return (_ready);
}
public function getLocalGifPath():String{
return (_tracker.getLocalGifPath());
}
public function setAllowAnchor(_arg1:Boolean):void{
_tracker.setAllowAnchor(_arg1);
}
public function clearIgnoredRef():void{
_tracker.clearIgnoredRef();
}
public function get mode():String{
return (_mode);
}
public function set debug(_arg1:DebugConfiguration):void{
_debug = _arg1;
}
public function setLocalGifPath(_arg1:String):void{
_tracker.setLocalGifPath(_arg1);
}
public function getVersion():String{
return (_tracker.getVersion());
}
public function setSampleRate(_arg1:Number):void{
_tracker.setSampleRate(_arg1);
}
public function setCookiePath(_arg1:String):void{
_tracker.setCookiePath(_arg1);
}
public function setAllowHash(_arg1:Boolean):void{
_tracker.setAllowHash(_arg1);
}
public function setCampNOKey(_arg1:String):void{
_tracker.setCampNOKey(_arg1);
}
public function addIgnoredOrganic(_arg1:String):void{
_tracker.addIgnoredOrganic(_arg1);
}
public function setLocalRemoteServerMode():void{
_tracker.setLocalRemoteServerMode();
}
public function cookiePathCopy(_arg1:String):void{
_tracker.cookiePathCopy(_arg1);
}
private function _factory():void{
var _local1:GoogleAnalyticsAPI;
var _local2:TrackerCache;
_jsproxy = new JavascriptProxy(debug);
if (visualDebug){
debug.layout = new Layout(debug, _display);
debug.active = visualDebug;
};
_local2 = (_tracker as TrackerCache);
switch (mode){
case TrackerMode.BRIDGE:
_local1 = _bridgeFactory();
break;
case TrackerMode.AS3:
default:
_local1 = _trackerFactory();
};
if (!_local2.isEmpty()){
_local2.tracker = _local1;
_local2.flush();
};
_tracker = _local1;
_ready = true;
dispatchEvent(new AnalyticsEvent(AnalyticsEvent.READY, this));
}
public function setCampTermKey(_arg1:String):void{
_tracker.setCampTermKey(_arg1);
}
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);
_env.url = _display.stage.loaderInfo.url;
return (new Tracker(account, config, debug, _env, _buffer, _gifRequest, _adSense));
}
public function setDetectTitle(_arg1:Boolean):void{
_tracker.setDetectTitle(_arg1);
}
public function getServiceMode():ServerOperationMode{
return (_tracker.getServiceMode());
}
public function clearOrganic():void{
_tracker.clearOrganic();
}
public function setCampaignTrack(_arg1:Boolean):void{
_tracker.setCampaignTrack(_arg1);
}
public function addIgnoredRef(_arg1:String):void{
_tracker.addIgnoredRef(_arg1);
}
public function set visualDebug(_arg1:Boolean):void{
_visualDebug = _arg1;
}
public function setCampMediumKey(_arg1:String):void{
_tracker.setCampMediumKey(_arg1);
}
public function setSessionTimeout(_arg1:int):void{
_tracker.setSessionTimeout(_arg1);
}
public function getDetectFlash():Boolean{
return (_tracker.getDetectFlash());
}
public function get visualDebug():Boolean{
return (_visualDebug);
}
public function getAccount():String{
return (_tracker.getAccount());
}
public function hasEventListener(_arg1:String):Boolean{
return (_eventDispatcher.hasEventListener(_arg1));
}
public function setRemoteServerMode():void{
_tracker.setRemoteServerMode();
}
}
var _local1:* = ServerOperationMode;
return (_local1);
}//package com.google.analytics
Section 121
//SpilGamesServices (com.spilgames.api.SpilGamesServices)
package com.spilgames.api {
import flash.events.*;
import flash.display.*;
import flash.net.*;
import flash.system.*;
public class SpilGamesServices extends MovieClip {
private var _connected:Boolean;// = false
private var ERR_LOADCOMP:String;// = "Failed to load Spil Social Component."
private var _loader:Loader;
private var ERR_DOWNLOAD:String;// = "Failed downloading Spil Games Social configurator component."
private var _connecting:Boolean;// = false
private var DEFAULT_CONNECTION_LOCATION:String;// = "http://www8.agame.com/games/flash/services/ServicesConnection.swf"
private var ERR_INITCOMP:String;// = "Failed to communication with a Spil Social Component."
private var ERR_SPILCALL:String;// = "Failed processing a Spil call."
private var ERR_NOPARENT:String;// = "Failed creating Spil Games connector: No parent provided."
private var _showDebug:Boolean;// = false
private var _servicesConnection;// = null
private var _alwaysInFront:Boolean;// = false
public static const INVALID_TYPE:int = -1;
public static const INVALID_ID:int = -1;
private static var _instance:SpilGamesServices = null;
public function SpilGamesServices(){
if (_instance){
throw (new Error("Only a single instance can be created."));
};
_instance = this;
}
private function handleServicesFailed(_arg1:ErrorEvent):void{
_servicesConnection.removeEventListener(Event.COMPLETE, handleServicesReady);
_servicesConnection.removeEventListener(ErrorEvent.ERROR, handleServicesFailed);
_servicesConnection.removeEventListener("serviceError", handleServiceError);
_servicesConnection = null;
if (hasEventListener("servicesFailed")){
dispatchEvent(new ErrorEvent("servicesFailed", false, false, _arg1.text));
};
}
private function handleLoadComplete(_arg1:Event):void{
_loader.contentLoaderInfo.removeEventListener(Event.COMPLETE, handleLoadComplete);
_loader.contentLoaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, handleIOError);
_servicesConnection = LoaderInfo(_arg1.target).content;
_servicesConnection.addEventListener(Event.COMPLETE, handleServicesReady);
_servicesConnection.addEventListener(ErrorEvent.ERROR, handleServicesFailed);
_servicesConnection.addEventListener("serviceError", handleServiceError);
addChild(_servicesConnection);
}
public function send(_arg1:String, _arg2:String, _arg3:Function, _arg4:Object=null):int{
if (_connected){
return (_servicesConnection.send(_arg1, _arg2, _arg3, _arg4));
};
return (INVALID_ID);
}
public function get connected():Boolean{
return (_connected);
}
public function showErrorMessage(_arg1:String):void{
if (((_servicesConnection) && (_servicesConnection.hasOwnProperty("showErrorMessage")))){
_servicesConnection.showErrorMessage(_arg1);
};
}
public function isSWFReady():Boolean{
return (isReady());
}
public function getSiteID():int{
if (_servicesConnection != null){
return (_servicesConnection.getSiteID());
};
return (INVALID_ID);
}
public function isReady():Boolean{
return (((!((_servicesConnection == null))) && (_servicesConnection.isReady())));
}
private function handleServiceError(_arg1:Event):void{
var _local2 = "";
if ((_arg1 is ErrorEvent)){
_local2 = ErrorEvent(_arg1).text;
} else {
_local2 = _arg1.toString();
};
if (hasEventListener("serviceError")){
dispatchEvent(new ErrorEvent("serviceError", false, false, _local2));
};
}
public function disconnect():void{
if (_connected){
_servicesConnection.removeEventListener();
_servicesConnection.removeEventListener();
_servicesConnection.removeEventListener();
_servicesConnection.disconnect();
_servicesConnection = null;
};
if (_loader){
try {
_loader.close();
} catch(e:Error) {
} finally {
_loader.contentLoaderInfo.removeEventListener(Event.COMPLETE, handleLoadComplete);
_loader.contentLoaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, handleIOError);
};
};
removeEventListener(Event.ENTER_FRAME, bringToFront);
if (parent){
parent.removeChild(this);
};
}
private function handleServicesReady(_arg1:Event):void{
_loader.contentLoaderInfo.removeEventListener(Event.COMPLETE, handleLoadComplete);
_loader.contentLoaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, handleIOError);
_connected = true;
_connecting = false;
dispatchEvent(new Event("servicesReady"));
}
public function getChannelID():int{
if (_servicesConnection != null){
return (_servicesConnection.getChannelID());
};
return (INVALID_ID);
}
public function set showDebug(_arg1:Boolean):void{
if (_showDebug != _arg1){
_showDebug = _arg1;
if (_showDebug){
bringToFront();
};
};
}
public function hasValidUserData():Boolean{
return (isGuest());
}
public function isDomainAllowed():Boolean{
return (((!((_servicesConnection == null))) && (_servicesConnection.isDomainValid())));
}
public function isGuest():Boolean{
var _local1:Object;
if (_servicesConnection != null){
return (_servicesConnection.isGuest());
};
trace("WARNING: SpilGamesServices connection not ready yet");
if (root.loaderInfo != null){
_local1 = root.loaderInfo.parameters;
return (((((((!(_local1.username)) || ((_local1.username == "")))) || (!(_local1.hash)))) || ((_local1.hash == ""))));
};
return (false);
}
public function get showDebug():Boolean{
return (_showDebug);
}
private function handleIOError(_arg1:IOErrorEvent):void{
_loader.contentLoaderInfo.removeEventListener(Event.COMPLETE, handleLoadComplete);
_loader.contentLoaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, handleIOError);
if (hasEventListener(_arg1.type)){
dispatchEvent(_arg1);
};
}
public function getItemType():int{
if (_servicesConnection != null){
return (_servicesConnection.getItemType());
};
return (INVALID_TYPE);
}
public function set alwaysInFront(_arg1:Boolean):void{
if (_alwaysInFront != _arg1){
_alwaysInFront = _arg1;
if (_alwaysInFront){
addEventListener(Event.ENTER_FRAME, bringToFront);
} else {
removeEventListener(Event.ENTER_FRAME, bringToFront);
};
};
}
public function getItemID():int{
if (_servicesConnection != null){
return (_servicesConnection.getItemID());
};
return (INVALID_ID);
}
public function getUserName():String{
if (_servicesConnection != null){
return (_servicesConnection.getUserName());
};
return ("");
}
public function allowDomain(_arg1:String):void{
Security.allowDomain("*");
Security.allowInsecureDomain("*");
}
public function getUserHash():String{
if (_servicesConnection != null){
return (_servicesConnection.getUserHash());
};
return ("");
}
public function connect(_arg1:DisplayObjectContainer):void{
var _local2:String;
var _local3:URLRequest;
if (((!(_connecting)) && (!(_connected)))){
if (!_arg1.stage){
trace("ERROR: The given clip must be present in the display list (added to stage)");
return;
};
_connecting = true;
_arg1.stage.addChild(this);
_local2 = DEFAULT_CONNECTION_LOCATION;
if (((root.loaderInfo.parameters["servicesLoc"]) && ((root.loaderInfo.parameters["servicesLoc"].length > 0)))){
_local2 = root.loaderInfo.parameters["servicesLoc"];
};
allowDomain(_local2);
_loader = new Loader();
_loader.contentLoaderInfo.addEventListener(Event.COMPLETE, handleLoadComplete);
_loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, handleIOError);
_local3 = new URLRequest(_local2);
_loader.load(_local3);
};
}
public function get alwaysInFront():Boolean{
return (_alwaysInFront);
}
public function bringToFront(_arg1:Event=null):void{
var e = _arg1;
if (parent){
try {
parent.setChildIndex(this, (parent.numChildren - 1));
} catch(e:Error) {
removeEventListener(Event.ENTER_FRAME, bringToFront);
};
};
}
public static function getInstance():SpilGamesServices{
if (!_instance){
_instance = new (SpilGamesServices);
};
return (_instance);
}
}
}//package com.spilgames.api
Section 122
//a10_com_logo_187 (export_fla.a10_com_logo_187)
package export_fla {
import flash.display.*;
public dynamic class a10_com_logo_187 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 123
//effect_02_209 (export_fla.effect_02_209)
package export_fla {
import flash.display.*;
public dynamic class effect_02_209 extends MovieClip {
public function effect_02_209(){
addFrameScript(16, frame17);
}
function frame17(){
stop();
}
}
}//package export_fla
Section 124
//girlsgogames_172 (export_fla.girlsgogames_172)
package export_fla {
import flash.display.*;
public dynamic class girlsgogames_172 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 125
//girlsgogames_173 (export_fla.girlsgogames_173)
package export_fla {
import flash.display.*;
public dynamic class girlsgogames_173 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 126
//girlsgogames_174 (export_fla.girlsgogames_174)
package export_fla {
import flash.display.*;
public dynamic class girlsgogames_174 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 127
//girlsgogames_175 (export_fla.girlsgogames_175)
package export_fla {
import flash.display.*;
public dynamic class girlsgogames_175 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 128
//girlsgogames_176 (export_fla.girlsgogames_176)
package export_fla {
import flash.display.*;
public dynamic class girlsgogames_176 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 129
//girlsgogames_177 (export_fla.girlsgogames_177)
package export_fla {
import flash.display.*;
public dynamic class girlsgogames_177 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 130
//girlsgogames_178 (export_fla.girlsgogames_178)
package export_fla {
import flash.display.*;
public dynamic class girlsgogames_178 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 131
//girlsgogames_180 (export_fla.girlsgogames_180)
package export_fla {
import flash.display.*;
public dynamic class girlsgogames_180 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 132
//girlsgogames_181 (export_fla.girlsgogames_181)
package export_fla {
import flash.display.*;
public dynamic class girlsgogames_181 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 133
//girlsgogames_182 (export_fla.girlsgogames_182)
package export_fla {
import flash.display.*;
public dynamic class girlsgogames_182 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 134
//girlsgogames_183 (export_fla.girlsgogames_183)
package export_fla {
import flash.display.*;
public dynamic class girlsgogames_183 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 135
//juegosdechicas_179 (export_fla.juegosdechicas_179)
package export_fla {
import flash.display.*;
public dynamic class juegosdechicas_179 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 136
//label_311 (export_fla.label_311)
package export_fla {
import flash.display.*;
public dynamic class label_311 extends MovieClip {
public var flag:MovieClip;
}
}//package export_fla
Section 137
//LanguageSelectPopup_310 (export_fla.LanguageSelectPopup_310)
package export_fla {
import flash.display.*;
public dynamic class LanguageSelectPopup_310 extends MovieClip {
public var l_se:MovieClip;
public var l_ar:MovieClip;
public var l_arg:MovieClip;
public var l_br:MovieClip;
public var l_cn:MovieClip;
public var l_in:MovieClip;
public var l_tr:MovieClip;
public var l_de:MovieClip;
public var l_my:MovieClip;
public var _blank:MovieClip;
public var l_es:MovieClip;
public var l_en_uk:MovieClip;
public var l_mx:MovieClip;
public var l_fr:MovieClip;
public var l_en_us:MovieClip;
public var l_pl:MovieClip;
public var l_pt:MovieClip;
public var l_ph:MovieClip;
public var l_nl:MovieClip;
public var l_id:MovieClip;
public var l_it:MovieClip;
public var l_jp:MovieClip;
public var l_ru:MovieClip;
}
}//package export_fla
Section 138
//logo_asoyun_com_158 (export_fla.logo_asoyun_com_158)
package export_fla {
import flash.display.*;
public dynamic class logo_asoyun_com_158 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 139
//logo_game_135 (export_fla.logo_game_135)
package export_fla {
import flash.display.*;
public dynamic class logo_game_135 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 140
//logo_game_com_my_159 (export_fla.logo_game_com_my_159)
package export_fla {
import flash.display.*;
public dynamic class logo_game_com_my_159 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 141
//logo_giocaregratis_it_147 (export_fla.logo_giocaregratis_it_147)
package export_fla {
import flash.display.*;
public dynamic class logo_giocaregratis_it_147 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 142
//logo_laro_com_ph_185 (export_fla.logo_laro_com_ph_185)
package export_fla {
import flash.display.*;
public dynamic class logo_laro_com_ph_185 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 143
//logo_minigry_pl_157 (export_fla.logo_minigry_pl_157)
package export_fla {
import flash.display.*;
public dynamic class logo_minigry_pl_157 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 144
//logo_my_games_co_uk_150 (export_fla.logo_my_games_co_uk_150)
package export_fla {
import flash.display.*;
public dynamic class logo_my_games_co_uk_150 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 145
//logo_oyunlar123_com_171 (export_fla.logo_oyunlar123_com_171)
package export_fla {
import flash.display.*;
public dynamic class logo_oyunlar123_com_171 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 146
//new_agame_com_132 (export_fla.new_agame_com_132)
package export_fla {
import flash.display.*;
public dynamic class new_agame_com_132 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 147
//new_clickjogos_com_145 (export_fla.new_clickjogos_com_145)
package export_fla {
import flash.display.*;
public dynamic class new_clickjogos_com_145 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 148
//new_flashgames_ru_151 (export_fla.new_flashgames_ru_151)
package export_fla {
import flash.display.*;
public dynamic class new_flashgames_ru_151 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 149
//new_game_co_in_153 (export_fla.new_game_co_in_153)
package export_fla {
import flash.display.*;
public dynamic class new_game_co_in_153 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 150
//new_games_co_id_155 (export_fla.new_games_co_id_155)
package export_fla {
import flash.display.*;
public dynamic class new_games_co_id_155 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 151
//new_jeu_fr_141 (export_fla.new_jeu_fr_141)
package export_fla {
import flash.display.*;
public dynamic class new_jeu_fr_141 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 152
//new_spel_se_148 (export_fla.new_spel_se_148)
package export_fla {
import flash.display.*;
public dynamic class new_spel_se_148 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 153
//new_spielen_com_143 (export_fla.new_spielen_com_143)
package export_fla {
import flash.display.*;
public dynamic class new_spielen_com_143 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 154
//new_zapjuegos_com_137 (export_fla.new_zapjuegos_com_137)
package export_fla {
import flash.display.*;
public dynamic class new_zapjuegos_com_137 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 155
//newagame_co_uk_189 (export_fla.newagame_co_uk_189)
package export_fla {
import flash.display.*;
public dynamic class newagame_co_uk_189 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 156
//newspel_nl_139 (export_fla.newspel_nl_139)
package export_fla {
import flash.display.*;
public dynamic class newspel_nl_139 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package export_fla
Section 157
//UI_bar_122 (export_fla.UI_bar_122)
package export_fla {
import flash.display.*;
public dynamic class UI_bar_122 extends MovieClip {
public var txt_test:TXT_PlayMoreNaughtyGamesAt;
public var controlListMC_levelMap_logo:Logo;
public var controlListMC_Main_logo:Logo;
public var controlListMC_TimerOver_logo:Logo;
public var soundBtn_off:Btn_sound;
public var controlListMC_Credit_logo:Logo;
public var helpBtn:Btn_005;
public var pashBtn:Btn_006;
public var controlListMC_BeCatch_logo:Logo;
public var soundBtn_on:Btn_004;
public var controlListMC_Transition_logo:Logo;
public var controlListMC_LevelPass_logo:Logo;
public var controlListMC_Achievement_logo:Logo;
public var homeBtn:Btn_home;
public function UI_bar_122(){
addFrameScript(0, frame1);
__setProp_controlListMC_Transition_logo_UI_bar_otherUI_1();
__setProp_controlListMC_BeCatch_logo_UI_bar_otherUI_1();
__setProp_controlListMC_Achievement_logo_UI_bar_otherUI_1();
__setProp_controlListMC_LevelPass_logo_UI_bar_otherUI_1();
__setProp_controlListMC_TimerOver_logo_UI_bar_otherUI_1();
__setProp_controlListMC_Credit_logo_UI_bar_otherUI_1();
__setProp_controlListMC_Main_logo_UI_bar_otherUI_1();
__setProp_controlListMC_levelMap_logo_UI_bar_otherUI_1();
}
function __setProp_controlListMC_TimerOver_logo_UI_bar_otherUI_1(){
try {
controlListMC_TimerOver_logo["componentInspectorSetting"] = true;
} catch(e:Error) {
};
controlListMC_TimerOver_logo.alignHorizontal = "Center";
controlListMC_TimerOver_logo.alignVertical = "Center";
controlListMC_TimerOver_logo.maxHeight = 40;
controlListMC_TimerOver_logo.maxWidth = 150;
controlListMC_TimerOver_logo.position = "logo_timeOver_levelFailed";
try {
controlListMC_TimerOver_logo["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
function __setProp_controlListMC_Transition_logo_UI_bar_otherUI_1(){
try {
controlListMC_Transition_logo["componentInspectorSetting"] = true;
} catch(e:Error) {
};
controlListMC_Transition_logo.alignHorizontal = "Center";
controlListMC_Transition_logo.alignVertical = "Center";
controlListMC_Transition_logo.maxHeight = 40;
controlListMC_Transition_logo.maxWidth = 150;
controlListMC_Transition_logo.position = "logo_translationScreen";
try {
controlListMC_Transition_logo["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
function __setProp_controlListMC_LevelPass_logo_UI_bar_otherUI_1(){
try {
controlListMC_LevelPass_logo["componentInspectorSetting"] = true;
} catch(e:Error) {
};
controlListMC_LevelPass_logo.alignHorizontal = "Center";
controlListMC_LevelPass_logo.alignVertical = "Center";
controlListMC_LevelPass_logo.maxHeight = 40;
controlListMC_LevelPass_logo.maxWidth = 150;
controlListMC_LevelPass_logo.position = "defaultValue";
try {
controlListMC_LevelPass_logo["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
function __setProp_controlListMC_Achievement_logo_UI_bar_otherUI_1(){
try {
controlListMC_Achievement_logo["componentInspectorSetting"] = true;
} catch(e:Error) {
};
controlListMC_Achievement_logo.alignHorizontal = "Center";
controlListMC_Achievement_logo.alignVertical = "Center";
controlListMC_Achievement_logo.maxHeight = 40;
controlListMC_Achievement_logo.maxWidth = 150;
controlListMC_Achievement_logo.position = "logo_setAsAvatarScreen";
try {
controlListMC_Achievement_logo["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
function __setProp_controlListMC_BeCatch_logo_UI_bar_otherUI_1(){
try {
controlListMC_BeCatch_logo["componentInspectorSetting"] = true;
} catch(e:Error) {
};
controlListMC_BeCatch_logo.alignHorizontal = "Center";
controlListMC_BeCatch_logo.alignVertical = "Center";
controlListMC_BeCatch_logo.maxHeight = 40;
controlListMC_BeCatch_logo.maxWidth = 150;
controlListMC_BeCatch_logo.position = "logo_beCatched_levelFailed";
try {
controlListMC_BeCatch_logo["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
function __setProp_controlListMC_Main_logo_UI_bar_otherUI_1(){
try {
controlListMC_Main_logo["componentInspectorSetting"] = true;
} catch(e:Error) {
};
controlListMC_Main_logo.alignHorizontal = "Center";
controlListMC_Main_logo.alignVertical = "Center";
controlListMC_Main_logo.maxHeight = 40;
controlListMC_Main_logo.maxWidth = 150;
controlListMC_Main_logo.position = "logo_gameScreen";
try {
controlListMC_Main_logo["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
function frame1(){
txt_test.buttonMode = true;
}
function __setProp_controlListMC_levelMap_logo_UI_bar_otherUI_1(){
try {
controlListMC_levelMap_logo["componentInspectorSetting"] = true;
} catch(e:Error) {
};
controlListMC_levelMap_logo.alignHorizontal = "Center";
controlListMC_levelMap_logo.alignVertical = "Center";
controlListMC_levelMap_logo.maxHeight = 40;
controlListMC_levelMap_logo.maxWidth = 150;
controlListMC_levelMap_logo.position = "logo_levelselect";
try {
controlListMC_levelMap_logo["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
function __setProp_controlListMC_Credit_logo_UI_bar_otherUI_1(){
try {
controlListMC_Credit_logo["componentInspectorSetting"] = true;
} catch(e:Error) {
};
controlListMC_Credit_logo.alignHorizontal = "Center";
controlListMC_Credit_logo.alignVertical = "Center";
controlListMC_Credit_logo.maxHeight = 40;
controlListMC_Credit_logo.maxWidth = 150;
controlListMC_Credit_logo.position = "logo_credits";
try {
controlListMC_Credit_logo["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package export_fla
Section 158
//UI_InGame_02_01_120 (export_fla.UI_InGame_02_01_120)
package export_fla {
import flash.display.*;
import flash.text.*;
public dynamic class UI_InGame_02_01_120 extends MovieClip {
public var timeText:TextField;
}
}//package export_fla
Section 159
//UI_InGame_02_119 (export_fla.UI_InGame_02_119)
package export_fla {
import flash.display.*;
public dynamic class UI_InGame_02_119 extends MovieClip {
public var timeTextMC:MovieClip;
public function UI_InGame_02_119(){
addFrameScript(12, frame13);
}
function frame13(){
gotoAndPlay(1);
}
}
}//package export_fla
Section 160
//UI_InGame_05_205 (export_fla.UI_InGame_05_205)
package export_fla {
import flash.display.*;
public dynamic class UI_InGame_05_205 extends MovieClip {
public var mc:UI_InGame_05_01;
public function UI_InGame_05_205(){
addFrameScript(20, frame21);
}
function frame21(){
stop();
}
}
}//package export_fla
Section 161
//UI_LevelComplete_02_236 (export_fla.UI_LevelComplete_02_236)
package export_fla {
import flash.display.*;
public dynamic class UI_LevelComplete_02_236 extends MovieClip {
public function UI_LevelComplete_02_236(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package export_fla
Section 162
//UI_LevelComplete_04_238 (export_fla.UI_LevelComplete_04_238)
package export_fla {
import flash.display.*;
public dynamic class UI_LevelComplete_04_238 extends MovieClip {
public function UI_LevelComplete_04_238(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package export_fla
Section 163
//UI_levelmap_011_277 (export_fla.UI_levelmap_011_277)
package export_fla {
import flash.display.*;
public dynamic class UI_levelmap_011_277 extends MovieClip {
public function UI_levelmap_011_277(){
addFrameScript(49, frame50);
}
function frame50(){
gotoAndPlay(1);
}
}
}//package export_fla
Section 164
//UI_levelmap_012_260 (export_fla.UI_levelmap_012_260)
package export_fla {
import flash.display.*;
public dynamic class UI_levelmap_012_260 extends MovieClip {
public function UI_levelmap_012_260(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package export_fla
Section 165
//LivePreviewParent (fl.livepreview.LivePreviewParent)
package fl.livepreview {
import flash.display.*;
import flash.utils.*;
import flash.external.*;
public class LivePreviewParent extends MovieClip {
public var myInstance:DisplayObject;
public function LivePreviewParent(){
super();
stage.align = StageAlign.TOP_LEFT;
stage.scaleMode = StageScaleMode.NO_SCALE;
myInstance = getChildAt(0);
onResize(stage.width, stage.height);
if (ExternalInterface.available){
ExternalInterface.addCallback("onResize", onResize);
ExternalInterface.addCallback("onUpdate", onUpdate);
};
//unresolved jump
var _slot1 = e;
}
public function onUpdate(... _args):void{
var name:String;
var value:*;
var updateArray = _args;
var i:int;
for (;(i + 1) < updateArray.length;(i = (i + 2))) {
name = String(updateArray[i]);
value = updateArray[(i + 1)];
if ((((typeof(value) == "object")) && (value.__treatAsCollectionSpecialSauce__))){
updateCollection(value, name);
} else {
myInstance[name] = value;
};
continue;
var _slot1 = e;
};
}
public function onResize(width:Number, height:Number):void{
var width = width;
var height = height;
var setSizeFn:Function;
setSizeFn = myInstance["setSize"];
//unresolved jump
var _slot1 = e;
setSizeFn = null;
if (setSizeFn != null){
setSizeFn(width, height);
} else {
myInstance.width = width;
myInstance.height = height;
};
}
private function updateCollection(collDesc:Object, index:String):void{
var itemObj:Object;
var collProp:Object;
var j:*;
var CollectionClass:Class = Class(getDefinitionByName(collDesc.collectionClass));
var CollectionItemClass:Class = Class(getDefinitionByName(collDesc.collectionItemClass));
var collObj:Object = new (CollectionClass);
var i:int;
while (i < collDesc.collectionArray.length) {
itemObj = new (CollectionItemClass);
collProp = collDesc.collectionArray[i];
for (j in collProp) {
itemObj[j] = collProp[j];
};
collObj.addItem(itemObj);
i++;
};
myInstance[index] = (collObj as CollectionClass);
}
}
}//package fl.livepreview
Section 166
//None (fl.transitions.easing.None)
package fl.transitions.easing {
public class None {
public function None(){
super();
}
public static function easeOut(t:Number, b:Number, c:Number, d:Number):Number{
return ((((c * t) / d) + b));
}
public static function easeIn(t:Number, b:Number, c:Number, d:Number):Number{
return ((((c * t) / d) + b));
}
public static function easeInOut(t:Number, b:Number, c:Number, d:Number):Number{
return ((((c * t) / d) + b));
}
public static function easeNone(t:Number, b:Number, c:Number, d:Number):Number{
return ((((c * t) / d) + b));
}
}
}//package fl.transitions.easing
Section 167
//Fade (fl.transitions.Fade)
package fl.transitions {
import flash.display.*;
public class Fade extends Transition {
protected var _alphaFinal:Number;
public function Fade(content:MovieClip, transParams:Object, manager:TransitionManager){
super(content, transParams, manager);
this._alphaFinal = this.manager.contentAppearance.alpha;
}
override public function get type():Class{
return (Fade);
}
override protected function _render(p:Number):void{
this._content.alpha = (this._alphaFinal * p);
}
}
}//package fl.transitions
Section 168
//Transition (fl.transitions.Transition)
package fl.transitions {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
public class Transition extends EventDispatcher {
protected var _direction:uint;// = 0
protected var _height:Number;// = NAN
protected var _easing:Function;
protected var _twn:Tween;
protected var _width:Number;// = NAN
protected var _outerBounds:Rectangle;
protected var _progress:Number;
public var ID:int;
protected var _innerBounds:Rectangle;
protected var _manager:TransitionManager;
protected var _duration:Number;// = 2
protected var _content:MovieClip;
public static const IN:uint = 0;
public static const OUT:uint = 1;
public function Transition(content:MovieClip, transParams:Object, manager:TransitionManager){
super();
this.content = content;
this.direction = transParams.direction;
this.duration = transParams.duration;
this.easing = transParams.easing;
this.manager = manager;
this._innerBounds = this.manager._innerBounds;
this._outerBounds = this.manager._outerBounds;
this._width = this.manager._width;
this._height = this.manager._height;
this._resetTween();
}
public function get type():Class{
return (Transition);
}
public function cleanUp():void{
this.removeEventListener("transitionInDone", this._manager.transitionInDone);
this.removeEventListener("transitionOutDone", this._manager.transitionOutDone);
this.stop();
}
public function stop():void{
this._twn.fforward();
this._twn.stop();
}
public function onMotionFinished(src:Object):void{
if (this.direction == Transition.OUT){
this.dispatchEvent(new Event("transitionOutDone"));
} else {
this.dispatchEvent(new Event("transitionInDone"));
};
}
public function set easing(e:Function):void{
this._easing = e;
if (this._twn){
this._twn.func = e;
};
}
public function set manager(mgr:TransitionManager):void{
if (this._manager){
this.removeEventListener("transitionInDone", this._manager.transitionInDone);
this.removeEventListener("transitionOutDone", this._manager.transitionOutDone);
};
this._manager = mgr;
this.addEventListener("transitionInDone", this._manager.transitionInDone);
this.addEventListener("transitionOutDone", this._manager.transitionOutDone);
}
private function _resetTween():void{
if (this._twn){
this._twn.stop();
this._twn.removeEventListener(TweenEvent.MOTION_FINISH, this.onMotionFinished);
};
this._twn = new Tween(this, "", this.easing, 0, 1, this.duration, true);
this._twn.stop();
this._twn.prop = "progress";
this._twn.addEventListener(TweenEvent.MOTION_FINISH, this.onMotionFinished, false, 0, true);
}
public function drawBox(mc:MovieClip, x:Number, y:Number, w:Number, h:Number):void{
mc.graphics.moveTo(x, y);
mc.graphics.lineTo((x + w), y);
mc.graphics.lineTo((x + w), (y + h));
mc.graphics.lineTo(x, (y + h));
mc.graphics.lineTo(x, y);
}
public function set progress(p:Number):void{
if (this._progress == p){
return;
};
this._progress = p;
if (this._direction){
this._render((1 - p));
} else {
this._render(p);
};
this.dispatchEvent(new Event("transitionProgress"));
}
public function get duration():Number{
return (this._duration);
}
public function set duration(d:Number):void{
if (d){
this._duration = d;
if (this._twn){
this._twn.duration = d;
};
};
}
public function start():void{
this.content.visible = true;
this._twn.start();
}
public function get easing():Function{
return (this._easing);
}
public function get manager():TransitionManager{
return (this._manager);
}
public function set content(c:MovieClip):void{
if (c){
this._content = c;
if (this._twn){
this._twn.obj = c;
};
};
}
protected function _render(p:Number):void{
}
public function get content():MovieClip{
return (this._content);
}
public function drawCircle(mc:MovieClip, x:Number, y:Number, r:Number):void{
mc.graphics.moveTo((x + r), y);
mc.graphics.curveTo((r + x), ((Math.tan((Math.PI / 8)) * r) + y), ((Math.sin((Math.PI / 4)) * r) + x), ((Math.sin((Math.PI / 4)) * r) + y));
mc.graphics.curveTo(((Math.tan((Math.PI / 8)) * r) + x), (r + y), x, (r + y));
mc.graphics.curveTo(((-(Math.tan((Math.PI / 8))) * r) + x), (r + y), ((-(Math.sin((Math.PI / 4))) * r) + x), ((Math.sin((Math.PI / 4)) * r) + y));
mc.graphics.curveTo((-(r) + x), ((Math.tan((Math.PI / 8)) * r) + y), (-(r) + x), y);
mc.graphics.curveTo((-(r) + x), ((-(Math.tan((Math.PI / 8))) * r) + y), ((-(Math.sin((Math.PI / 4))) * r) + x), ((-(Math.sin((Math.PI / 4))) * r) + y));
mc.graphics.curveTo(((-(Math.tan((Math.PI / 8))) * r) + x), (-(r) + y), x, (-(r) + y));
mc.graphics.curveTo(((Math.tan((Math.PI / 8)) * r) + x), (-(r) + y), ((Math.sin((Math.PI / 4)) * r) + x), ((-(Math.sin((Math.PI / 4))) * r) + y));
mc.graphics.curveTo((r + x), ((-(Math.tan((Math.PI / 8))) * r) + y), (r + x), y);
}
public function get progress():Number{
return (this._progress);
}
private function _noEase(t:Number, b:Number, c:Number, d:Number):Number{
return ((((c * t) / d) + b));
}
public function set direction(direction:Number):void{
this._direction = (direction) ? 1 : 0;
}
public function get direction():Number{
return (this._direction);
}
}
}//package fl.transitions
Section 169
//TransitionManager (fl.transitions.TransitionManager)
package fl.transitions {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
public class TransitionManager extends EventDispatcher {
public var type:Object;
public var _width:Number;// = NAN
public var _height:Number;// = NAN
public var _outerBounds:Rectangle;
private var _visualPropList:Object;
private var _triggerEvent:String;
public var className:String;// = "TransitionManager"
public var _innerBounds:Rectangle;
private var _content:MovieClip;
private var _contentAppearance:Object;
private var _transitions:Object;
private static var IDCount:int = 0;
public function TransitionManager(content:MovieClip){
type = TransitionManager;
_visualPropList = {x:null, y:null, scaleX:null, scaleY:null, alpha:null, rotation:null};
super();
this.content = content;
this._transitions = {};
}
public function removeTransition(trans:Transition):Boolean{
if (((((!(trans)) || (!(this._transitions)))) || (!(this._transitions[trans.ID])))){
return (false);
};
trans.cleanUp();
return (delete this._transitions[trans.ID]);
}
public function saveContentAppearance():void{
var a:Object;
var i:String;
var c:MovieClip = this._content;
if (!this._contentAppearance){
a = (this._contentAppearance = {});
for (i in this._visualPropList) {
a[i] = c[i];
};
a.colorTransform = c.transform.colorTransform;
};
this._innerBounds = c.getBounds(c);
this._outerBounds = c.getBounds(c.parent);
this._width = c.width;
this._height = c.height;
}
public function removeAllTransitions():void{
var t:Transition;
for each (t in this._transitions) {
t.cleanUp();
this.removeTransition(t);
};
}
function transitionInDone(e:Object):void{
var wasVisible:Boolean;
this.removeTransition(e.target);
if (this.numInTransitions == 0){
wasVisible = this._content.visible;
if ((((this._triggerEvent == "hide")) || ((this._triggerEvent == "hideChild")))){
this._content.visible = false;
};
if (wasVisible){
this.dispatchEvent(new Event("allTransitionsInDone"));
};
};
}
public function addTransition(trans:Transition):Transition{
trans.ID = ++TransitionManager.IDCount;
this._transitions[trans.ID] = trans;
return (trans);
}
public function startTransition(transParams:Object):Transition{
this.removeTransition(this.findTransition(transParams));
var theClass:Class = transParams.type;
var t:Transition = new theClass(this._content, transParams, this);
this.addTransition(t);
t.start();
return (t);
}
function transitionOutDone(e:Object):void{
var wasVisible:Boolean;
this.removeTransition(e.target);
if (this.numOutTransitions == 0){
this.restoreContentAppearance();
wasVisible = this._content.visible;
if (((wasVisible) && ((((_triggerEvent == "hide")) || ((_triggerEvent == "hideChild")))))){
this._content.visible = false;
};
if (wasVisible){
this.dispatchEvent(new Event("allTransitionsOutDone"));
};
};
}
public function restoreContentAppearance():void{
var i:String;
var c:MovieClip = this._content;
var a:Object = this._contentAppearance;
for (i in this._visualPropList) {
c[i] = a[i];
};
c.transform.colorTransform = a.colorTransform;
}
public function get numTransitions():Number{
var t:Transition;
var n:Number = 0;
for each (t in this._transitions) {
n++;
};
return (n);
}
public function findTransition(transParams:Object):Transition{
var t:Transition;
for each (t in this._transitions) {
if (t.type == transParams.type){
return (t);
};
};
return (null);
}
public function set content(c:MovieClip):void{
this._content = c;
this.saveContentAppearance();
}
public function get numInTransitions():Number{
var t:Transition;
var n:Number = 0;
var ts:Object = this._transitions;
for each (t in ts) {
if (!t.direction){
n++;
};
};
return (n);
}
public function get numOutTransitions():Number{
var t:Transition;
var n:Number = 0;
var ts:Object = this._transitions;
for each (t in ts) {
if (t.direction){
n++;
};
};
return (n);
}
public function get content():MovieClip{
return (this._content);
}
public function get transitionsList():Object{
return (this._transitions);
}
public function get contentAppearance():Object{
return (this._contentAppearance);
}
public static function start(content:MovieClip, transParams:Object):Transition{
if (!content.__transitionManager){
content.__transitionManager = new TransitionManager(content);
};
if (transParams.direction == 1){
content.__transitionManager._triggerEvent = "hide";
} else {
content.__transitionManager._triggerEvent = "reveal";
};
return (content.__transitionManager.startTransition(transParams));
}
}
}//package fl.transitions
Section 170
//Tween (fl.transitions.Tween)
package fl.transitions {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
public class Tween extends EventDispatcher {
private var _position:Number;// = NAN
public var prevTime:Number;// = NAN
public var prevPos:Number;// = NAN
public var isPlaying:Boolean;// = false
private var _fps:Number;// = NAN
private var _time:Number;// = NAN
public var begin:Number;// = NAN
private var _finish:Number;// = NAN
public var change:Number;// = NAN
public var looping:Boolean;// = false
private var _intervalID:uint;// = 0
public var func:Function;
private var _timer:Timer;// = null
private var _startTime:Number;// = NAN
public var prop:String;// = ""
private var _duration:Number;// = NAN
public var obj:Object;// = null
public var useSeconds:Boolean;// = false
protected static var _mc:MovieClip = new MovieClip();
public function Tween(obj:Object, prop:String, func:Function, begin:Number, finish:Number, duration:Number, useSeconds:Boolean=false){
func = function (t:Number, b:Number, c:Number, d:Number):Number{
return ((((c * t) / d) + b));
};
super();
if (!arguments.length){
return;
};
this.obj = obj;
this.prop = prop;
this.begin = begin;
this.position = begin;
this.duration = duration;
this.useSeconds = useSeconds;
if ((func is Function)){
this.func = func;
};
this.finish = finish;
this._timer = new Timer(100);
this.start();
}
public function continueTo(finish:Number, duration:Number):void{
this.begin = this.position;
this.finish = finish;
if (!isNaN(duration)){
this.duration = duration;
};
this.start();
}
protected function startEnterFrame():void{
var milliseconds:Number;
if (isNaN(this._fps)){
_mc.addEventListener(Event.ENTER_FRAME, this.onEnterFrame, false, 0, true);
} else {
milliseconds = (1000 / this._fps);
this._timer.delay = milliseconds;
this._timer.addEventListener(TimerEvent.TIMER, this.timerHandler, false, 0, true);
this._timer.start();
};
this.isPlaying = true;
}
public function stop():void{
this.stopEnterFrame();
this.dispatchEvent(new TweenEvent(TweenEvent.MOTION_STOP, this._time, this._position));
}
private function fixTime():void{
if (this.useSeconds){
this._startTime = (getTimer() - (this._time * 1000));
};
}
public function set FPS(fps:Number):void{
var oldIsPlaying:Boolean = this.isPlaying;
this.stopEnterFrame();
this._fps = fps;
if (oldIsPlaying){
this.startEnterFrame();
};
}
public function get finish():Number{
return ((this.begin + this.change));
}
public function get duration():Number{
return (this._duration);
}
protected function stopEnterFrame():void{
if (isNaN(this._fps)){
_mc.removeEventListener(Event.ENTER_FRAME, this.onEnterFrame);
} else {
this._timer.stop();
};
this.isPlaying = false;
}
public function set time(t:Number):void{
this.prevTime = this._time;
if (t > this.duration){
if (this.looping){
this.rewind((t - this._duration));
this.update();
this.dispatchEvent(new TweenEvent(TweenEvent.MOTION_LOOP, this._time, this._position));
} else {
if (this.useSeconds){
this._time = this._duration;
this.update();
};
this.stop();
this.dispatchEvent(new TweenEvent(TweenEvent.MOTION_FINISH, this._time, this._position));
};
} else {
if (t < 0){
this.rewind();
this.update();
} else {
this._time = t;
this.update();
};
};
}
public function getPosition(t:Number=NaN):Number{
if (isNaN(t)){
t = this._time;
};
return (this.func(t, this.begin, this.change, this._duration));
}
public function set finish(value:Number):void{
this.change = (value - this.begin);
}
public function set duration(d:Number):void{
this._duration = ((d)<=0) ? Infinity : d;
}
public function get position():Number{
return (this.getPosition(this._time));
}
public function setPosition(p:Number):void{
this.prevPos = this._position;
if (this.prop.length){
this.obj[this.prop] = (this._position = p);
};
this.dispatchEvent(new TweenEvent(TweenEvent.MOTION_CHANGE, this._time, this._position));
}
public function resume():void{
this.fixTime();
this.startEnterFrame();
this.dispatchEvent(new TweenEvent(TweenEvent.MOTION_RESUME, this._time, this._position));
}
public function fforward():void{
this.time = this._duration;
this.fixTime();
}
protected function onEnterFrame(event:Event):void{
this.nextFrame();
}
public function yoyo():void{
this.continueTo(this.begin, this.time);
}
public function nextFrame():void{
if (this.useSeconds){
this.time = ((getTimer() - this._startTime) / 1000);
} else {
this.time = (this._time + 1);
};
}
protected function timerHandler(timerEvent:TimerEvent):void{
this.nextFrame();
timerEvent.updateAfterEvent();
}
public function get FPS():Number{
return (this._fps);
}
public function rewind(t:Number=0):void{
this._time = t;
this.fixTime();
this.update();
}
public function set position(p:Number):void{
this.setPosition(p);
}
public function get time():Number{
return (this._time);
}
private function update():void{
this.setPosition(this.getPosition(this._time));
}
public function start():void{
this.rewind();
this.startEnterFrame();
this.dispatchEvent(new TweenEvent(TweenEvent.MOTION_START, this._time, this._position));
}
public function prevFrame():void{
if (!this.useSeconds){
this.time = (this._time - 1);
};
}
}
}//package fl.transitions
Section 171
//TweenEvent (fl.transitions.TweenEvent)
package fl.transitions {
import flash.events.*;
public class TweenEvent extends Event {
public var position:Number;// = NAN
public var time:Number;// = NAN
public static const MOTION_START:String = "motionStart";
public static const MOTION_STOP:String = "motionStop";
public static const MOTION_LOOP:String = "motionLoop";
public static const MOTION_CHANGE:String = "motionChange";
public static const MOTION_FINISH:String = "motionFinish";
public static const MOTION_RESUME:String = "motionResume";
public function TweenEvent(type:String, time:Number, position:Number, bubbles:Boolean=false, cancelable:Boolean=false){
super(type, bubbles, cancelable);
this.time = time;
this.position = position;
}
override public function clone():Event{
return (new TweenEvent(this.type, this.time, this.position, this.bubbles, this.cancelable));
}
}
}//package fl.transitions
Section 172
//Stats (net.hires.debug.Stats)
package net.hires.debug {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
import flash.geom.*;
import flash.system.*;
public class Stats extends Sprite {
protected const WIDTH:uint = 70;
protected const HEIGHT:uint = 100;
protected var xml:XML;
protected var text:TextField;
protected var style:StyleSheet;
protected var timer:uint;
protected var fps:uint;
protected var ms:uint;
protected var ms_prev:uint;
protected var mem:Number;
protected var mem_max:Number;
protected var graph:Bitmap;
protected var rectangle:Rectangle;
protected var fps_graph:uint;
protected var mem_graph:uint;
protected var mem_max_graph:uint;
protected var theme:Object;
public function Stats(_theme:Object=null):void{
this.theme = {bg:51, fps:0xFFFF00, ms:0xFF00, mem:0xFFFF, memmax:0xFF0070};
super();
this.mouseChildren = false;
this.mouseEnabled = false;
if (_theme){
if (_theme.bg != null){
this.theme.bg = _theme.bg;
};
if (_theme.fps != null){
this.theme.fps = _theme.fps;
};
if (_theme.ms != null){
this.theme.ms = _theme.ms;
};
if (_theme.mem != null){
this.theme.mem = _theme.mem;
};
if (_theme.memmax != null){
this.theme.memmax = _theme.memmax;
};
};
this.mem_max = 0;
this.xml = <xml><fps>FPS:</fps><ms>MS:</ms><mem>MEM:</mem><memMax>MAX:</memMax></xml>
;
this.style = new StyleSheet();
this.style.setStyle("xml", {fontSize:"9px", fontFamily:"_sans", leading:"-2px"});
this.style.setStyle("fps", {color:this.hex2css(this.theme.fps)});
this.style.setStyle("ms", {color:this.hex2css(this.theme.ms)});
this.style.setStyle("mem", {color:this.hex2css(this.theme.mem)});
this.style.setStyle("memMax", {color:this.hex2css(this.theme.memmax)});
this.text = new TextField();
this.text.width = this.WIDTH;
this.text.height = 50;
this.text.styleSheet = this.style;
this.text.condenseWhite = true;
this.text.selectable = false;
this.text.mouseEnabled = false;
this.graph = new Bitmap();
this.graph.alpha = 0.3;
this.graph.y = 50;
this.rectangle = new Rectangle((this.WIDTH - 1), 0, 1, (this.HEIGHT - 50));
addEventListener(Event.ADDED_TO_STAGE, this.init, false, 0, true);
addEventListener(Event.REMOVED_FROM_STAGE, this.destroy, false, 0, true);
}
private function init(e:Event):void{
graphics.beginFill(this.theme.bg, 0.3);
graphics.drawRect(0, 0, this.WIDTH, this.HEIGHT);
graphics.endFill();
addChild(this.text);
this.graph.bitmapData = new BitmapData(this.WIDTH, (this.HEIGHT - 50), false, this.theme.bg);
addChild(this.graph);
addEventListener(Event.ENTER_FRAME, this.update);
}
private function destroy(e:Event):void{
graphics.clear();
while (numChildren > 0) {
removeChildAt(0);
};
this.graph.bitmapData.dispose();
removeEventListener(Event.ENTER_FRAME, this.update);
}
private function update(e:Event):void{
this.timer = getTimer();
if ((this.timer - 1000) > this.ms_prev){
this.ms_prev = this.timer;
this.mem = Number((System.totalMemory * 9.54E-7).toFixed(3));
this.mem_max = ((this.mem_max > this.mem)) ? this.mem_max : this.mem;
this.fps_graph = Math.min(this.graph.height, ((this.fps / stage.frameRate) * this.graph.height));
this.mem_graph = (Math.min(this.graph.height, Math.sqrt(Math.sqrt((this.mem * 5000)))) - 2);
this.mem_max_graph = (Math.min(this.graph.height, Math.sqrt(Math.sqrt((this.mem_max * 5000)))) - 2);
this.graph.bitmapData.scroll(-1, 0);
this.graph.bitmapData.fillRect(this.rectangle, this.theme.bg);
this.graph.bitmapData.setPixel((this.graph.width - 1), (this.graph.height - this.fps_graph), this.theme.fps);
this.graph.bitmapData.setPixel((this.graph.width - 1), (this.graph.height - ((this.timer - this.ms) >> 1)), this.theme.ms);
this.graph.bitmapData.setPixel((this.graph.width - 1), (this.graph.height - this.mem_graph), this.theme.mem);
this.graph.bitmapData.setPixel((this.graph.width - 1), (this.graph.height - this.mem_max_graph), this.theme.memmax);
this.xml.fps = ((("FPS: " + this.fps) + " / ") + stage.frameRate);
this.xml.mem = ("MEM: " + this.mem);
this.xml.memMax = ("MAX: " + this.mem_max);
this.fps = 0;
};
this.fps++;
this.xml.ms = ("MS: " + (this.timer - this.ms));
this.ms = this.timer;
this.text.htmlText = this.xml;
}
private function onClick(e:MouseEvent):void{
if (((mouseY / height) > 0.5)){
stage.frameRate--;
} else {
stage.frameRate++;
};
this.xml.fps = ((("FPS: " + this.fps) + " / ") + stage.frameRate);
this.text.htmlText = this.xml;
}
private function hex2css(color:int):String{
return (("#" + color.toString(16)));
}
}
}//package net.hires.debug
Section 173
//MultipartURLLoaderEvent (ru.inspirit.net.events.MultipartURLLoaderEvent)
package ru.inspirit.net.events {
import flash.events.*;
public class MultipartURLLoaderEvent extends Event {
public var bytesTotal:uint;// = 0
public var bytesWritten:uint;// = 0
public static const DATA_PREPARE_PROGRESS:String = "dataPrepareProgress";
public static const DATA_PREPARE_COMPLETE:String = "dataPrepareComplete";
public function MultipartURLLoaderEvent(type:String, w:uint=0, t:uint=0){
super(type);
this.bytesTotal = t;
this.bytesWritten = w;
}
}
}//package ru.inspirit.net.events
Section 174
//MultipartURLLoader (ru.inspirit.net.MultipartURLLoader)
package ru.inspirit.net {
import flash.events.*;
import flash.net.*;
import flash.utils.*;
import ru.inspirit.net.events.*;
import flash.errors.*;
public class MultipartURLLoader extends EventDispatcher {
private var _path:String;
private var asyncFilePointer:uint;// = 0
private var _variables:Dictionary;
private var _boundary:String;
private var _data:ByteArray;
private var writtenBytes:uint;// = 0
private var _prepared:Boolean;// = false
private var _fileNames:Array;
private var _variableNames:Array;
private var _loader:URLLoader;
private var totalFilesSize:uint;// = 0
private var asyncWriteTimeoutId:Number;
private var _files:Dictionary;
private var _async:Boolean;// = false
public var requestHeaders:Array;
public static var BLOCK_SIZE:uint = 65536;
public function MultipartURLLoader(){
super();
this._fileNames = new Array();
this._files = new Dictionary();
this._variableNames = new Array();
this._variables = new Dictionary();
this._loader = new URLLoader();
this.requestHeaders = new Array();
}
public function set dataFormat(format:String):void{
if (((((!((format == URLLoaderDataFormat.BINARY))) && (!((format == URLLoaderDataFormat.TEXT))))) && (!((format == URLLoaderDataFormat.VARIABLES))))){
throw (new IllegalOperationError("Illegal URLLoader Data Format"));
};
this._loader.dataFormat = format;
}
private function constructFilesPart(postData:ByteArray):ByteArray{
var i:uint;
var bytes:String;
var name:String;
if (this._fileNames.length){
for each (name in this._fileNames) {
postData = this.getFilePartHeader(postData, (this._files[name] as FilePart));
postData = this.getFilePartData(postData, (this._files[name] as FilePart));
postData = this.LINEBREAK(postData);
};
postData = this.closeFilePartsData(postData);
};
return (postData);
}
private function nextAsyncLoop():void{
var fp:FilePart;
if (this.asyncFilePointer < this._fileNames.length){
fp = (this._files[this._fileNames[this.asyncFilePointer]] as FilePart);
this._data = this.getFilePartHeader(this._data, fp);
this.asyncWriteTimeoutId = setTimeout(this.writeChunkLoop, 10, this._data, fp.fileContent, 0);
this.asyncFilePointer++;
} else {
this._data = this.closeFilePartsData(this._data);
this._data = this.closeDataObject(this._data);
this._prepared = true;
dispatchEvent(new MultipartURLLoaderEvent(MultipartURLLoaderEvent.DATA_PREPARE_PROGRESS, this.totalFilesSize, this.totalFilesSize));
dispatchEvent(new MultipartURLLoaderEvent(MultipartURLLoaderEvent.DATA_PREPARE_COMPLETE));
};
}
public function get loader():URLLoader{
return (this._loader);
}
private function onSecurityError(event:SecurityErrorEvent):void{
this.removeListener();
dispatchEvent(event);
}
private function constructPostDataAsync():void{
clearInterval(this.asyncWriteTimeoutId);
this._data = new ByteArray();
this._data.endian = Endian.BIG_ENDIAN;
this._data = this.constructVariablesPart(this._data);
this.asyncFilePointer = 0;
this.writtenBytes = 0;
this._prepared = false;
if (this._fileNames.length){
this.nextAsyncLoop();
} else {
this._data = this.closeDataObject(this._data);
this._prepared = true;
dispatchEvent(new MultipartURLLoaderEvent(MultipartURLLoaderEvent.DATA_PREPARE_COMPLETE));
};
}
public function dispose():void{
clearInterval(this.asyncWriteTimeoutId);
this.removeListener();
this.close();
this._loader = null;
this._boundary = null;
this._variableNames = null;
this._variables = null;
this._fileNames = null;
this._files = null;
this.requestHeaders = null;
this._data = null;
}
public function getBoundary():String{
var i:int;
if (this._boundary == null){
this._boundary = "";
i = 0;
while (i < 32) {
this._boundary = (this._boundary + String.fromCharCode(int((97 + (Math.random() * 25)))));
i++;
};
};
return (this._boundary);
}
private function closeDataObject(postData:ByteArray):ByteArray{
postData = this.BOUNDARY(postData);
postData = this.DOUBLEDASH(postData);
return (postData);
}
public function clearVariables():void{
this._variableNames = new Array();
this._variables = new Dictionary();
this._prepared = false;
}
private function onProgress(event:ProgressEvent):void{
dispatchEvent(event);
}
public function clearFiles():void{
var name:String;
for each (name in this._fileNames) {
(this._files[name] as FilePart).dispose();
};
this._fileNames = new Array();
this._files = new Dictionary();
this.totalFilesSize = 0;
this._prepared = false;
}
private function doSend(type:String):void{
var urlRequest:URLRequest = new URLRequest();
urlRequest.url = this._path;
urlRequest.contentType = ("multipart/form-data; boundary=" + this.getBoundary());
if (type == "POST"){
urlRequest.method = URLRequestMethod.POST;
} else {
if (type == "GET"){
urlRequest.method = URLRequestMethod.GET;
};
};
urlRequest.data = this._data;
if (((this.requestHeaders.length) && (!((this.requestHeaders == null))))){
urlRequest.requestHeaders = this.requestHeaders.concat();
};
this.addListener();
this._loader.load(urlRequest);
}
public function addVariable(name:String, value:Object=""):void{
if (this._variableNames.indexOf(name) == -1){
this._variableNames.push(name);
};
this._variables[name] = value;
this._prepared = false;
}
private function onComplete(event:Event):void{
this.removeListener();
dispatchEvent(event);
}
private function onHTTPStatus(event:HTTPStatusEvent):void{
dispatchEvent(event);
}
public function get dataFormat():String{
return (this._loader.dataFormat);
}
private function BOUNDARY(p:ByteArray):ByteArray{
var l:int = this.getBoundary().length;
p = this.DOUBLEDASH(p);
var i:int;
while (i < l) {
p.writeByte(this._boundary.charCodeAt(i));
i++;
};
return (p);
}
private function onIOError(event:IOErrorEvent):void{
this.removeListener();
dispatchEvent(event);
}
public function addFile(fileContent:ByteArray, fileName:String, dataField:String="Filedata", contentType:String="application/octet-stream"):void{
var f:FilePart;
if (this._fileNames.indexOf(fileName) == -1){
this._fileNames.push(fileName);
this._files[fileName] = new FilePart(fileContent, fileName, dataField, contentType);
this.totalFilesSize = (this.totalFilesSize + fileContent.length);
} else {
f = (this._files[fileName] as FilePart);
this.totalFilesSize = (this.totalFilesSize - f.fileContent.length);
f.fileContent = fileContent;
f.fileName = fileName;
f.dataField = dataField;
f.contentType = contentType;
this.totalFilesSize = (this.totalFilesSize + fileContent.length);
};
this._prepared = false;
}
private function QUOTATIONMARK(p:ByteArray):ByteArray{
p.writeByte(34);
return (p);
}
private function writeChunkLoop(dest:ByteArray, data:ByteArray, p:uint=0):void{
var len:uint = Math.min(BLOCK_SIZE, (data.length - p));
dest.writeBytes(data, p, len);
if ((((len < BLOCK_SIZE)) || (((p + len) >= data.length)))){
dest = this.LINEBREAK(dest);
this.nextAsyncLoop();
return;
};
p = (p + len);
this.writtenBytes = (this.writtenBytes + len);
if (((this.writtenBytes % BLOCK_SIZE) * 2) == 0){
dispatchEvent(new MultipartURLLoaderEvent(MultipartURLLoaderEvent.DATA_PREPARE_PROGRESS, this.writtenBytes, this.totalFilesSize));
};
this.asyncWriteTimeoutId = setTimeout(this.writeChunkLoop, 10, dest, data, p);
}
public function get PREPARED():Boolean{
return (this._prepared);
}
private function getFilePartData(postData:ByteArray, part:FilePart):ByteArray{
postData.writeBytes(part.fileContent, 0, part.fileContent.length);
return (postData);
}
public function prepareData():void{
this.constructPostDataAsync();
}
private function removeListener():void{
this._loader.removeEventListener(Event.COMPLETE, this.onComplete);
this._loader.removeEventListener(ProgressEvent.PROGRESS, this.onProgress);
this._loader.removeEventListener(IOErrorEvent.IO_ERROR, this.onIOError);
this._loader.removeEventListener(HTTPStatusEvent.HTTP_STATUS, this.onHTTPStatus);
this._loader.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, this.onSecurityError);
}
public function get ASYNC():Boolean{
return (this._async);
}
private function constructPostData():ByteArray{
var postData:ByteArray = new ByteArray();
postData.endian = Endian.BIG_ENDIAN;
postData = this.constructVariablesPart(postData);
postData = this.constructFilesPart(postData);
postData = this.closeDataObject(postData);
return (postData);
}
private function DOUBLEDASH(p:ByteArray):ByteArray{
p.writeShort(0x2D2D);
return (p);
}
public function load(path:String, type:String="POST", async:Boolean=false):void{
if ((((path == null)) || ((path == "")))){
throw (new IllegalOperationError("You cant load without specifing PATH"));
};
this._path = path;
this._async = async;
if (this._async){
if (!this._prepared){
this.constructPostDataAsync();
} else {
this.doSend(type);
};
} else {
this._data = this.constructPostData();
this.doSend(type);
};
}
public function startLoad(type:String="POST"):void{
if ((((((this._path == null)) || ((this._path == "")))) || ((this._async == false)))){
throw (new IllegalOperationError("You can use this method only if loading asynchronous."));
};
if (((!(this._prepared)) && (this._async))){
throw (new IllegalOperationError("You should prepare data before sending when using asynchronous."));
};
this.doSend(type);
}
private function LINEBREAK(p:ByteArray):ByteArray{
p.writeShort(3338);
return (p);
}
private function getFilePartHeader(postData:ByteArray, part:FilePart):ByteArray{
var i:uint;
var bytes:String;
postData = this.BOUNDARY(postData);
postData = this.LINEBREAK(postData);
bytes = "Content-Disposition: form-data; name=\"Filename\"";
i = 0;
while (i < bytes.length) {
postData.writeByte(bytes.charCodeAt(i));
i++;
};
postData = this.LINEBREAK(postData);
postData = this.LINEBREAK(postData);
postData.writeUTFBytes(part.fileName);
postData = this.LINEBREAK(postData);
postData = this.BOUNDARY(postData);
postData = this.LINEBREAK(postData);
bytes = (("Content-Disposition: form-data; name=\"" + part.dataField) + "\"; filename=\"");
i = 0;
while (i < bytes.length) {
postData.writeByte(bytes.charCodeAt(i));
i++;
};
postData.writeUTFBytes(part.fileName);
postData = this.QUOTATIONMARK(postData);
postData = this.LINEBREAK(postData);
bytes = ("Content-Type: " + part.contentType);
i = 0;
while (i < bytes.length) {
postData.writeByte(bytes.charCodeAt(i));
i++;
};
postData = this.LINEBREAK(postData);
postData = this.LINEBREAK(postData);
return (postData);
}
private function constructVariablesPart(postData:ByteArray):ByteArray{
var i:uint;
var bytes:String;
var name:String;
for each (name in this._variableNames) {
postData = this.BOUNDARY(postData);
postData = this.LINEBREAK(postData);
bytes = (("Content-Disposition: form-data; name=\"" + name) + "\"");
i = 0;
while (i < bytes.length) {
postData.writeByte(bytes.charCodeAt(i));
i++;
};
postData = this.LINEBREAK(postData);
postData = this.LINEBREAK(postData);
postData.writeUTFBytes(this._variables[name]);
postData = this.LINEBREAK(postData);
};
return (postData);
}
private function addListener():void{
this._loader.addEventListener(Event.COMPLETE, this.onComplete, false, 0, false);
this._loader.addEventListener(ProgressEvent.PROGRESS, this.onProgress, false, 0, false);
this._loader.addEventListener(IOErrorEvent.IO_ERROR, this.onIOError, false, 0, false);
this._loader.addEventListener(HTTPStatusEvent.HTTP_STATUS, this.onHTTPStatus, false, 0, false);
this._loader.addEventListener(SecurityErrorEvent.SECURITY_ERROR, this.onSecurityError, false, 0, false);
}
private function closeFilePartsData(postData:ByteArray):ByteArray{
var i:uint;
var bytes:String;
postData = this.LINEBREAK(postData);
postData = this.BOUNDARY(postData);
postData = this.LINEBREAK(postData);
bytes = "Content-Disposition: form-data; name=\"Upload\"";
i = 0;
while (i < bytes.length) {
postData.writeByte(bytes.charCodeAt(i));
i++;
};
postData = this.LINEBREAK(postData);
postData = this.LINEBREAK(postData);
bytes = "Submit Query";
i = 0;
while (i < bytes.length) {
postData.writeByte(bytes.charCodeAt(i));
i++;
};
postData = this.LINEBREAK(postData);
return (postData);
}
public function close():void{
this._loader.close();
//unresolved jump
var _slot1 = e;
}
}
}//package ru.inspirit.net
import flash.utils.*;
class FilePart {
public var dataField:String;
public var contentType:String;
public var fileName:String;
public var fileContent:ByteArray;
private function FilePart(fileContent:ByteArray, fileName:String, dataField:String="Filedata", contentType:String="application/octet-stream"){
super();
this.fileContent = fileContent;
this.fileName = fileName;
this.dataField = dataField;
this.contentType = contentType;
}
public function dispose():void{
this.fileContent = null;
this.fileName = null;
this.dataField = null;
this.contentType = null;
}
}
Section 175
//a10_com_logo_141 (soundMC_fla.a10_com_logo_141)
package soundMC_fla {
import flash.display.*;
public dynamic class a10_com_logo_141 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 176
//girlsgogames_126 (soundMC_fla.girlsgogames_126)
package soundMC_fla {
import flash.display.*;
public dynamic class girlsgogames_126 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 177
//girlsgogames_127 (soundMC_fla.girlsgogames_127)
package soundMC_fla {
import flash.display.*;
public dynamic class girlsgogames_127 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 178
//girlsgogames_128 (soundMC_fla.girlsgogames_128)
package soundMC_fla {
import flash.display.*;
public dynamic class girlsgogames_128 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 179
//girlsgogames_129 (soundMC_fla.girlsgogames_129)
package soundMC_fla {
import flash.display.*;
public dynamic class girlsgogames_129 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 180
//girlsgogames_130 (soundMC_fla.girlsgogames_130)
package soundMC_fla {
import flash.display.*;
public dynamic class girlsgogames_130 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 181
//girlsgogames_131 (soundMC_fla.girlsgogames_131)
package soundMC_fla {
import flash.display.*;
public dynamic class girlsgogames_131 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 182
//girlsgogames_132 (soundMC_fla.girlsgogames_132)
package soundMC_fla {
import flash.display.*;
public dynamic class girlsgogames_132 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 183
//girlsgogames_134 (soundMC_fla.girlsgogames_134)
package soundMC_fla {
import flash.display.*;
public dynamic class girlsgogames_134 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 184
//girlsgogames_135 (soundMC_fla.girlsgogames_135)
package soundMC_fla {
import flash.display.*;
public dynamic class girlsgogames_135 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 185
//girlsgogames_136 (soundMC_fla.girlsgogames_136)
package soundMC_fla {
import flash.display.*;
public dynamic class girlsgogames_136 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 186
//girlsgogames_137 (soundMC_fla.girlsgogames_137)
package soundMC_fla {
import flash.display.*;
public dynamic class girlsgogames_137 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 187
//juegosdechicas_133 (soundMC_fla.juegosdechicas_133)
package soundMC_fla {
import flash.display.*;
public dynamic class juegosdechicas_133 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 188
//logo_asoyun_com_112 (soundMC_fla.logo_asoyun_com_112)
package soundMC_fla {
import flash.display.*;
public dynamic class logo_asoyun_com_112 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 189
//logo_game_89 (soundMC_fla.logo_game_89)
package soundMC_fla {
import flash.display.*;
public dynamic class logo_game_89 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 190
//logo_game_com_my_113 (soundMC_fla.logo_game_com_my_113)
package soundMC_fla {
import flash.display.*;
public dynamic class logo_game_com_my_113 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 191
//logo_giocaregratis_it_101 (soundMC_fla.logo_giocaregratis_it_101)
package soundMC_fla {
import flash.display.*;
public dynamic class logo_giocaregratis_it_101 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 192
//logo_laro_com_ph_139 (soundMC_fla.logo_laro_com_ph_139)
package soundMC_fla {
import flash.display.*;
public dynamic class logo_laro_com_ph_139 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 193
//logo_minigry_pl_111 (soundMC_fla.logo_minigry_pl_111)
package soundMC_fla {
import flash.display.*;
public dynamic class logo_minigry_pl_111 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 194
//logo_my_games_co_uk_104 (soundMC_fla.logo_my_games_co_uk_104)
package soundMC_fla {
import flash.display.*;
public dynamic class logo_my_games_co_uk_104 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 195
//logo_oyunlar123_com_125 (soundMC_fla.logo_oyunlar123_com_125)
package soundMC_fla {
import flash.display.*;
public dynamic class logo_oyunlar123_com_125 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 196
//new_agame_com_86 (soundMC_fla.new_agame_com_86)
package soundMC_fla {
import flash.display.*;
public dynamic class new_agame_com_86 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 197
//new_clickjogos_com_99 (soundMC_fla.new_clickjogos_com_99)
package soundMC_fla {
import flash.display.*;
public dynamic class new_clickjogos_com_99 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 198
//new_flashgames_ru_105 (soundMC_fla.new_flashgames_ru_105)
package soundMC_fla {
import flash.display.*;
public dynamic class new_flashgames_ru_105 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 199
//new_game_co_in_107 (soundMC_fla.new_game_co_in_107)
package soundMC_fla {
import flash.display.*;
public dynamic class new_game_co_in_107 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 200
//new_games_co_id_109 (soundMC_fla.new_games_co_id_109)
package soundMC_fla {
import flash.display.*;
public dynamic class new_games_co_id_109 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 201
//new_jeu_fr_95 (soundMC_fla.new_jeu_fr_95)
package soundMC_fla {
import flash.display.*;
public dynamic class new_jeu_fr_95 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 202
//new_spel_se_102 (soundMC_fla.new_spel_se_102)
package soundMC_fla {
import flash.display.*;
public dynamic class new_spel_se_102 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 203
//new_spielen_com_97 (soundMC_fla.new_spielen_com_97)
package soundMC_fla {
import flash.display.*;
public dynamic class new_spielen_com_97 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 204
//new_zapjuegos_com_91 (soundMC_fla.new_zapjuegos_com_91)
package soundMC_fla {
import flash.display.*;
public dynamic class new_zapjuegos_com_91 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 205
//newagame_co_uk_143 (soundMC_fla.newagame_co_uk_143)
package soundMC_fla {
import flash.display.*;
public dynamic class newagame_co_uk_143 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 206
//newspel_nl_93 (soundMC_fla.newspel_nl_93)
package soundMC_fla {
import flash.display.*;
public dynamic class newspel_nl_93 extends MovieClip {
public var displayArea_mc:MovieClip;
}
}//package soundMC_fla
Section 207
//Submitter (Spill.Components.Submitter)
package Spill.Components {
import flash.display.*;
public dynamic class Submitter extends MovieClip {
}
}//package Spill.Components
Section 208
//com (www.spilgames.com)
package www.spilgames {
import code.tool.*;
public dynamic class com extends McButton {
}
}//package www.spilgames
Section 209
//AbstractEffect (zlong.breathxue.utils.animationEffect.AbstractEffect)
package zlong.breathxue.utils.animationEffect {
import flash.display.*;
import flash.utils.*;
public class AbstractEffect {
protected var _mc:DisplayObject;
protected var _id:uint;
protected var _isMerge:Boolean;
protected var _runframe:uint;
protected var _stepframe:uint;
breathxue_utils_internal static const VERSION:String = "v1.10.201004261516";
public function AbstractEffect(){
super();
if (getQualifiedClassName(this) == "zlong::breathxue::utils::animationEffect::AbstractEffect"){
throw (new ArgumentError("can't be constructed"));
};
}
protected function initAbSet(id:uint, mc:DisplayObject, runframe:uint, isMerge:Boolean):void{
this._id = id;
this._mc = mc;
this._isMerge = isMerge;
this._runframe = runframe;
this._stepframe = 0;
if (this._mc == null){
throw (new ArgumentError("mc can't = null"));
};
}
function checkFinish():Boolean{
return (true);
}
function step():void{
}
function dispatchEvent():void{
}
protected function delMe():void{
var _local1 = getDefinitionByName(getQualifiedClassName(this));
_local1["del"](this._id);
this.dispatchEvent();
}
function get mc():DisplayObject{
return (this._mc);
}
function get isMerge():Boolean{
return (this._isMerge);
}
function get id():uint{
return (this._id);
}
}
}//package zlong.breathxue.utils.animationEffect
Section 210
//EffectManager (zlong.breathxue.utils.animationEffect.EffectManager)
package zlong.breathxue.utils.animationEffect {
import flash.display.*;
import flash.events.*;
import zlong.breathxue.utils.animationEffect.*;
class EffectManager {
public var IdCount:uint;
private var _arr:Array;
private var _listenerMc:DisplayObject;
breathxue_utils_internal static const VERSION:String = "v1.10.201004261516";
function EffectManager():void{
super();
this.IdCount = 0;
this._arr = new Array();
}
public function push(effect:AbstractEffect):uint{
this._arr.push(effect);
if (((!(this._listenerMc)) && ((this._arr.length > 0)))){
this._listenerMc = new Sprite();
this._listenerMc.addEventListener(Event.ENTER_FRAME, this.run);
};
return (this.IdCount++);
}
function findAndDeleteSameMcEffect(mc:DisplayObject, isMerge:Boolean):AbstractEffect{
var tempEffect:AbstractEffect;
var i:int = (this._arr.length - 1);
while (i >= 0) {
tempEffect = this._arr[i];
if (tempEffect.mc == mc){
if (((isMerge) && (tempEffect.isMerge))){
return (tempEffect);
};
this._arr.splice(i, 1);
};
i--;
};
return (null);
}
private function run(event:Event):void{
var tempEffect:AbstractEffect;
var tmc:AbstractEffect;
var i:int;
while (i < this._arr.length) {
tempEffect = this._arr[i];
if (tempEffect.checkFinish()){
tmc = (this._arr[i] as AbstractEffect);
this._arr.splice(i, 1);
tmc.dispatchEvent();
i--;
if (this._arr.length <= 0){
this._listenerMc.removeEventListener(Event.ENTER_FRAME, this.run);
this._listenerMc = null;
};
} else {
tempEffect.step();
};
i++;
};
}
public function del(id:uint):void{
var i:int;
while (i < this._arr.length) {
if ((this._arr[i] as AbstractEffect).id == id){
this._arr.splice(i, 1);
if (this._arr.length <= 0){
this._listenerMc.removeEventListener(Event.ENTER_FRAME, this.run);
this._listenerMc = null;
};
return;
};
i++;
};
}
public function delByMc(mc:DisplayObject):void{
var temp:AbstractEffect;
var i:int = (this._arr.length - 1);
while (i >= 0) {
temp = this._arr[i];
if (temp.mc == mc){
this._arr.splice(i, 1);
};
i--;
};
}
public function delAll():void{
this._arr = new Array();
if (this._listenerMc){
this._listenerMc.removeEventListener(Event.ENTER_FRAME, this.run);
this._listenerMc = null;
};
}
public function pauseAll():void{
this._listenerMc.removeEventListener(Event.ENTER_FRAME, this.run);
}
public function reStartAll():void{
this._listenerMc.addEventListener(Event.ENTER_FRAME, this.run);
}
}
}//package zlong.breathxue.utils.animationEffect
Section 211
//MoveEffect (zlong.breathxue.utils.animationEffect.MoveEffect)
package zlong.breathxue.utils.animationEffect {
import flash.display.*;
import flash.events.*;
import zlong.breathxue.utils.math.*;
import zlong.breathxue.utils.*;
public class MoveEffect extends AbstractEffect {
private var _position:mVector;
private var _EndPoint:mVector;
private var _stepVector:mVector;
breathxue_utils_internal static const VERSION:String = "v1.10.201004261516";
public static const Move_EFFECT_FINISH:String = "Move_EFFECT_FINISH";
private static var _effectManager:EffectManager = new EffectManager();
private function initSet(id:uint, mc:DisplayObject, StartPoint:mVector, EndPoint:mVector, stepDistance:Number, runframe:uint=0, stepVector:mVector=null, isMerge:Boolean=false, sameMcEffect:AbstractEffect=null):void{
super.initAbSet(id, mc, runframe, isMerge);
this._EndPoint = EndPoint;
this._stepVector = stepVector;
if ((((stepDistance == 0)) && ((runframe == 0)))){
throw (new ArgumentError("one of stepDistance or runframe need be setting"));
};
if (((!(this._EndPoint)) && (((!(stepVector)) || ((_runframe == 0)))))){
throw (new ArgumentError("if EndAlpha == NaN,then stepVector and runframe must be setting"));
};
if (StartPoint == null){
StartPoint = new mVector(_mc.x, _mc.y);
};
if (((isMerge) && (sameMcEffect))){
this._position = (sameMcEffect as MoveEffect)._position;
} else {
this._position = new mVector();
_mc.x = (this._position.x = StartPoint.x);
_mc.y = (this._position.y = StartPoint.y);
};
if (!this._EndPoint){
FrameTimer.push(new FrameTimer(_runframe), delMe);
} else {
this._stepVector = this._EndPoint.minus(this._position);
if (_runframe > 0){
this._stepVector.multEquals((1 / (_runframe - _stepframe)));
} else {
this._stepVector.length = Math.abs(stepDistance);
};
};
}
override function step():void{
var tempStepDistance:Number;
if (this._EndPoint){
if (_runframe > 0){
this._stepVector = this._EndPoint.minus(this._position);
this._stepVector.multEquals((1 / (_runframe - _stepframe)));
_stepframe++;
} else {
tempStepDistance = this._stepVector.length;
this._stepVector = this._EndPoint.minus(this._position);
this._stepVector.length = Math.abs(tempStepDistance);
};
};
_mc.x = (this._position.x = (this._position.x + this._stepVector.x));
_mc.y = (this._position.y = (this._position.y + this._stepVector.y));
}
override function checkFinish():Boolean{
if (((this._EndPoint) && ((((((_runframe > 0)) && ((_stepframe >= _runframe)))) || ((this._EndPoint.minus(this._position).length <= Math.abs(this._stepVector.length))))))){
_mc.x = (this._position.x = this._EndPoint.x);
_mc.y = (this._position.y = this._EndPoint.y);
return (true);
};
return (false);
}
override function dispatchEvent():void{
_mc.dispatchEvent(new Event(Move_EFFECT_FINISH));
}
public static function push(mc:DisplayObject, StartPoint:mVector, EndPoint:mVector, stepDistance:Number, runframe:uint=0, stepVector:mVector=null, isMerge:Boolean=false):uint{
var sameMcEffect:AbstractEffect = _effectManager.findAndDeleteSameMcEffect(mc, isMerge);
var tempMoveEffect:MoveEffect = new (MoveEffect);
tempMoveEffect.initSet(_effectManager.IdCount, mc, StartPoint, EndPoint, stepDistance, runframe, stepVector, isMerge, sameMcEffect);
return (_effectManager.push(tempMoveEffect));
}
public static function del(id:uint):void{
_effectManager.del(id);
}
public static function delByMc(mc:DisplayObject):void{
_effectManager.delByMc(mc);
}
public static function delAll():void{
_effectManager.delAll();
}
public static function pauseAll():void{
_effectManager.pauseAll();
}
public static function reStartAll():void{
_effectManager.reStartAll();
}
}
}//package zlong.breathxue.utils.animationEffect
Section 212
//TC (zlong.breathxue.utils.debug.TC)
package zlong.breathxue.utils.debug {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import zlong.breathxue.utils.math.*;
import zlong.breathxue.utils.animationEffect.*;
import zlong.breathxue.utils.*;
public class TC {
breathxue_utils_internal static const VERSION:String = "v1.10.201004261516";
private static const TITLE_HEIGHT:int = 20;
private static var _MC:Sprite;
private static var _showMc:Sprite;
private static var _smallMc:Sprite;
private static var _Text:TextField;
private static var _move:Boolean;
private static var _nowEffect:Boolean;
public static function InitTC(mc:Sprite, width:int=0, height:int=0):void{
if (mc.stage == null){
return;
};
TcShow = true;
if (width == 0){
width = ((mc.stage.stageWidth / 3) * 2);
};
if (height == 0){
height = ((mc.stage.stageHeight / 3) * 2);
};
_MC = new Sprite();
mc.addChild(_MC);
_MC.alpha = 0.5;
_move = false;
createShow(width, height);
createSmall(width);
}
private static function createShow(width:int, height:int):void{
_showMc = new Sprite();
_MC.addChild(_showMc);
_showMc.addChild(maketitle(width));
_showMc.graphics.lineStyle(1, 11187199);
_showMc.graphics.drawRect(0, 0, width, height);
_Text = new TextField();
_Text.x = 0;
_Text.y = TITLE_HEIGHT;
_Text.width = width;
_Text.height = (height - TITLE_HEIGHT);
_showMc.addChild(_Text);
_Text.multiline = true;
_Text.mouseWheelEnabled = true;
_Text.wordWrap = true;
_Text.background = true;
_Text.backgroundColor = 14541311;
_Text.stage.addEventListener(KeyboardEvent.KEY_DOWN, openAndClose);
}
private static function maketitle(w:int):DisplayObject{
var handMc:Sprite = new Sprite();
handMc.graphics.beginFill(11187199);
handMc.graphics.drawRect(0, 0, w, TITLE_HEIGHT);
handMc.graphics.endFill();
handMc.doubleClickEnabled = true;
var titleText:TextField = new TextField();
titleText.text = "Debug Text ('ctrl + d' open and close it)";
titleText.width = w;
titleText.height = TITLE_HEIGHT;
titleText.mouseEnabled = false;
titleText.selectable = false;
handMc.addChild(titleText);
var closeButton:Sprite = new Sprite();
closeButton.graphics.beginFill(0, 0);
closeButton.graphics.drawRect(0, 0, 18, 18);
closeButton.graphics.endFill();
closeButton.graphics.lineStyle(2, 11187199);
closeButton.graphics.moveTo(6, 6);
closeButton.graphics.lineTo(12, 12);
closeButton.graphics.moveTo(12, 6);
closeButton.graphics.lineTo(6, 12);
closeButton.x = (w - 19);
closeButton.y = 1;
handMc.addChild(closeButton);
closeButton.addEventListener(MouseEvent.CLICK, openAndClose);
handMc.addEventListener(MouseEvent.DOUBLE_CLICK, openAndClose);
handMc.addEventListener(MouseEvent.MOUSE_DOWN, startMove);
handMc.addEventListener(MouseEvent.MOUSE_UP, endMove);
return (handMc);
}
private static function createSmall(w:int):void{
_smallMc = new Sprite();
_smallMc.y = -20;
var handMc:Sprite = new Sprite();
handMc.y = 0;
handMc.graphics.beginFill(11187199);
handMc.graphics.drawRect(0, 0, (w / 2), TITLE_HEIGHT);
handMc.graphics.endFill();
handMc.doubleClickEnabled = true;
var titleText:TextField = new TextField();
titleText.text = "Debug Text";
titleText.width = (w / 2);
titleText.height = TITLE_HEIGHT;
titleText.mouseEnabled = false;
titleText.selectable = false;
handMc.addChild(titleText);
_smallMc.addChild(handMc);
handMc.addEventListener(MouseEvent.DOUBLE_CLICK, openAndClose);
}
private static function openAndClose(event:Event):void{
var e:KeyboardEvent = (event as KeyboardEvent);
if (((!(_nowEffect)) && (((!(e)) || (((e.ctrlKey) && ((e.keyCode == 68)))))))){
if (_showMc.parent == null){
MoveEffect.push(_smallMc, new mVector(0, -20), new mVector(_showMc.x, _showMc.y), 0, 5);
_smallMc.addEventListener(MoveEffect.Move_EFFECT_FINISH, EffectFinish);
_nowEffect = true;
} else {
_showMc.visible = false;
_MC.addChild(_smallMc);
MoveEffect.push(_smallMc, new mVector(_showMc.x, _showMc.y), new mVector(0, -20), 0, 5);
_smallMc.addEventListener(MoveEffect.Move_EFFECT_FINISH, EffectFinish);
_nowEffect = true;
};
};
}
private static function EffectFinish(event:Event):void{
_smallMc.removeEventListener(MoveEffect.Move_EFFECT_FINISH, EffectFinish);
_nowEffect = false;
if (_showMc.parent == null){
_showMc.visible = true;
_MC.addChild(_showMc);
_MC.removeChild(_smallMc);
} else {
_MC.removeChild(_showMc);
};
}
private static function endMove(event:MouseEvent):void{
_showMc.stopDrag();
}
private static function startMove(event:MouseEvent):void{
_showMc.startDrag();
}
public static function SHOW(... _args):void{
var t:int;
if (_MC){
t = _Text.scrollV;
_Text.appendText((((Tools.getNowTimeAndMileSecond_1() + ": ") + _args.join(" ")) + "\n"));
if (_Text.length != _Text.selectionEndIndex){
_Text.scrollV = t;
} else {
_Text.scrollV = _Text.numLines;
};
_MC.parent.setChildIndex(_MC, (_MC.parent.numChildren - 1));
};
}
}
}//package zlong.breathxue.utils.debug
Section 213
//TcShow (zlong.breathxue.utils.debug.TcShow)
package zlong.breathxue.utils.debug {
public var TcShow:Boolean = false;
}//package zlong.breathxue.utils.debug
Section 214
//mVector (zlong.breathxue.utils.math.mVector)
package zlong.breathxue.utils.math {
public class mVector {
private var m_x:Number;
private var m_y:Number;
breathxue_utils_internal static const VERSION:String = "v1.10.201004261516";
public function mVector(px:Number=0, py:Number=0){
super();
this.m_x = px;
this.m_y = py;
}
public function setTo(px:Number, py:Number):void{
this.m_x = px;
this.m_y = py;
}
public function copyFrom(v:mVector):void{
this.m_x = v.m_x;
this.m_y = v.m_y;
}
public function toString():String{
var rx:Number = (Math.round((this.m_x * 1000)) / 1000);
var ry:Number = (Math.round((this.m_y * 1000)) / 1000);
return ((((("[" + rx) + ", ") + ry) + "]"));
}
public function clone():mVector{
return (new mVector(this.m_x, this.m_y));
}
public function plus(v:mVector):mVector{
return (new mVector((this.m_x + v.m_x), (this.m_y + v.m_y)));
}
public function plusEquals(v:mVector):mVector{
this.m_x = (this.m_x + v.m_x);
this.m_y = (this.m_y + v.m_y);
return (this);
}
public function minus(v:mVector):mVector{
return (new mVector((this.m_x - v.m_x), (this.m_y - v.m_y)));
}
public function minusEquals(v:mVector):mVector{
this.m_x = (this.m_x - v.m_x);
this.m_y = (this.m_y - v.m_y);
return (this);
}
public function negate():mVector{
return (new mVector(-(this.m_x), -(this.m_y)));
}
public function negateEquals():void{
this.m_x = -(this.m_x);
this.m_y = -(this.m_y);
}
public function mult(s:Number):mVector{
return (new mVector((this.m_x * s), (this.m_y * s)));
}
public function multEquals(s:Number):mVector{
this.m_x = (this.m_x * s);
this.m_y = (this.m_y * s);
return (this);
}
public function rotate(ang:Number):mVector{
var v:mVector = new mVector(this.m_x, this.m_y);
v.rotateEquals(ang);
return (v);
}
public function rotateEquals(ang:Number):void{
var ca:Number = TF_Class.cosD(ang);
var sa:Number = TF_Class.sinD(ang);
var rx:Number = ((this.m_x * ca) - (this.m_y * sa));
var ry:Number = ((this.m_x * sa) + (this.m_y * ca));
this.m_x = rx;
this.m_y = ry;
}
public function dot(v:mVector):Number{
return (((this.m_x * v.m_x) + (this.m_y * v.m_y)));
}
public function cross(v:mVector):Number{
return (((this.m_x * v.m_y) - (this.m_y * v.m_x)));
}
public function times(v:mVector):mVector{
return (new mVector((this.m_x * v.m_x), (this.m_y * v.m_y)));
}
public function divEquals(s:Number):mVector{
if (s == 0){
s = 0.0001;
};
this.m_x = (this.m_x / s);
this.m_y = (this.m_y / s);
return (this);
}
public function distance(v:mVector):Number{
var delta:mVector = this.minus(v);
return (delta.length);
}
public function normalize():mVector{
var m:Number = this.length;
if (m == 0){
m = 0.0001;
};
return (this.mult((1 / m)));
}
public function getNormal():mVector{
return (new mVector(-(this.m_y), this.m_x));
}
public function isNormalTo(v:mVector):Boolean{
return ((this.dot(v) == 0));
}
public function angleBetween(v:mVector):Number{
var dp:Number = this.dot(v);
var cosAngle:Number = (dp / (this.length * v.length));
return (TF_Class.acosD(cosAngle));
}
public function get length():Number{
return (Math.sqrt(((this.m_x * this.m_x) + (this.m_y * this.m_y))));
}
public function set length(len:Number):void{
var r:Number = this.length;
if (r){
this.multEquals((len / r));
} else {
this.m_x = len;
};
}
public function set angle(ang:Number):void{
var r:Number = this.length;
this.m_x = (r * TF_Class.cosD(ang));
this.m_y = (r * TF_Class.sinD(ang));
}
public function get angle():Number{
return (TF_Class.atan2D(this.m_y, this.m_x));
}
public function set x(x:Number):void{
this.m_x = x;
}
public function get x():Number{
return (this.m_x);
}
public function set y(y:Number):void{
this.m_y = y;
}
public function get y():Number{
return (this.m_y);
}
}
}//package zlong.breathxue.utils.math
Section 215
//TF_Class (zlong.breathxue.utils.math.TF_Class)
package zlong.breathxue.utils.math {
public class TF_Class {
breathxue_utils_internal static const VERSION:String = "v1.10.201004261516";
public static function sinD(angle:Number):Number{
return (Math.sin((angle * (Math.PI / 180))));
}
public static function cosD(angle:Number):Number{
return (Math.cos((angle * (Math.PI / 180))));
}
public static function tanD(angle:Number):Number{
return (Math.tan((angle * (Math.PI / 180))));
}
public static function asinD(ratio:Number):Number{
return ((Math.asin(ratio) * (180 / Math.PI)));
}
public static function acosD(ratio:Number):Number{
return ((Math.acos(ratio) * (180 / Math.PI)));
}
public static function atanD(ratio:Number):Number{
return ((Math.atan(ratio) * (180 / Math.PI)));
}
public static function atan2D(y:Number, x:Number):Number{
return ((Math.atan2(y, x) * (180 / Math.PI)));
}
public static function distance(x1:Number, y1:Number, x2:Number, y2:Number):Number{
var dx:Number = (x2 - x1);
var dy:Number = (y2 - y1);
return (Math.sqrt(((dx * dx) + (dy * dy))));
}
public static function angleOfLine(x1:Number, y1:Number, x2:Number, y2:Number):Number{
return (atan2D((y2 - y1), (x2 - x1)));
}
public static function degreesToRadians(angle:Number):Number{
return ((angle * (Math.PI / 180)));
}
public static function radiansToDegrees(angle:Number):Number{
return ((angle * (180 / Math.PI)));
}
public static function fixAngle(angle:Number):Number{
angle = (angle % 360);
return (((angle)<0) ? (angle + 360) : angle);
}
public static function cartesianToPolar(p:mVector):Object{
var radius:Number = Math.sqrt(((p.x * p.x) + (p.y * p.y)));
var theta:Number = atan2D(p.y, p.x);
return ({r:radius, t:theta});
}
public static function FormatAngle(r:Number):Number{
r = (r % 360);
if (r > 180){
r = (r - 360);
};
if (r < -180){
r = (r + 360);
};
return (r);
}
public static function FormatAngle90(r:Number):Number{
r = (r % 180);
if (r > 90){
r = (180 - r);
};
if (r < -90){
r = (r + 180);
};
return (r);
}
}
}//package zlong.breathxue.utils.math
Section 216
//Attach (zlong.breathxue.utils.Attach)
package zlong.breathxue.utils {
import flash.display.*;
import flash.media.*;
import flash.utils.*;
public class Attach {
breathxue_utils_internal static const VERSION:String = "v1.10.201004261516";
public static function getDisplayObject(s:String):DisplayObject{
var temp:Class = (getDefinitionByName(s) as Class);
var returnObj:DisplayObject = new (temp);
return (returnObj);
}
public static function getSprite(s:String):Sprite{
var temp:Class = (getDefinitionByName(s) as Class);
var returnObj:Sprite = new (temp);
return (returnObj);
}
public static function getMovieClip(s:String):MovieClip{
var temp:Class = (getDefinitionByName(s) as Class);
var returnObj:MovieClip = new (temp);
return (returnObj);
}
public static function getBitmapData(s:String):BitmapData{
var temp:Class = (getDefinitionByName(s) as Class);
var returnObj:BitmapData = new temp(null, null);
return (returnObj);
}
public static function getSound(s:String):Sound{
var temp:Class = (getDefinitionByName(s) as Class);
var returnObj:Sound = new (temp);
return (returnObj);
}
}
}//package zlong.breathxue.utils
Section 217
//breathxue_utils_internal (zlong.breathxue.utils.breathxue_utils_internal)
package zlong.breathxue.utils {
public namespace breathxue_utils_internal = "http://www.zlonggames.com/flash/breathxue/utils/internal";
}//package zlong.breathxue.utils
Section 218
//FrameTimer (zlong.breathxue.utils.FrameTimer)
package zlong.breathxue.utils {
import flash.display.*;
import flash.events.*;
public class FrameTimer implements IEventDispatcher {
private var _ED:EventDispatcher;
private var _runframe:uint;
private var _cycleNum:uint;
private var _step:uint;
private var _id:uint;
private var _returnFunctionAlarm:Function;
private var _returnFunctionFinish:Function;
breathxue_utils_internal static const VERSION:String = "v1.10.201004261516";
public static const FRAMETIMER_ALARM:String = "FRAMETIMER_ALARM";
public static const FRAMETIMER_FINISH:String = "FRAMETIMER_FINISH";
private static var IdCount:uint = 0;
private static var _arr:Array = new Array();
private static var _listenerMc:DisplayObject;
public function FrameTimer(runframe:uint, cycleNum:uint=0, Millisecond:uint=0, mc:DisplayObject=null){
super();
this._step = 0;
this._runframe = runframe;
this._cycleNum = cycleNum;
this._ED = new EventDispatcher(this);
if ((((Millisecond > 0)) && (mc))){
if (!mc.stage){
throw (new ArgumentError("mc didn`t connect stage"));
};
this._runframe = uint(((Millisecond / 1000) * mc.stage.frameRate));
};
this._id = FrameTimer.add(this);
}
public function addEventListener(type:String, listener:Function, useCapture:Boolean=false, priority:int=0, useWeakReference:Boolean=false):void{
this._ED.addEventListener(type, listener, useCapture, priority, useWeakReference);
}
public function removeEventListener(type:String, listener:Function, useCapture:Boolean=false):void{
this._ED.removeEventListener(type, listener, useCapture);
}
public function dispatchEvent(event:Event):Boolean{
return (this._ED.dispatchEvent(event));
}
public function hasEventListener(type:String):Boolean{
return (this._ED.hasEventListener(type));
}
public function willTrigger(type:String):Boolean{
return (this._ED.willTrigger(type));
}
public function del():void{
FrameTimer.delById(this._id);
}
public function get id():uint{
return (this._id);
}
public static function push(fTimer:FrameTimer, returnFunctionAlarm:Function=null, returnFunctionFinish:Function=null):uint{
fTimer._returnFunctionAlarm = returnFunctionAlarm;
fTimer._returnFunctionFinish = returnFunctionFinish;
return (fTimer._id);
}
private static function add(fTimer:FrameTimer, returnFunctionAlarm:Function=null, returnFunctionFinish:Function=null):uint{
_arr.push(fTimer);
if (!_listenerMc){
_listenerMc = new Sprite();
_listenerMc.addEventListener(Event.ENTER_FRAME, run);
};
return (IdCount++);
}
private static function run(event:Event):void{
var tempFrameTimer:FrameTimer;
var i:int;
while (i < _arr.length) {
tempFrameTimer = _arr[i];
if (tempFrameTimer._step >= tempFrameTimer._runframe){
tempFrameTimer._ED.dispatchEvent(new Event(FRAMETIMER_ALARM));
if (tempFrameTimer._returnFunctionAlarm != null){
tempFrameTimer._returnFunctionAlarm();
};
tempFrameTimer._step = 0;
tempFrameTimer._step++;
if (tempFrameTimer._cycleNum <= 0){
tempFrameTimer._ED.dispatchEvent(new Event(FRAMETIMER_FINISH));
if (tempFrameTimer._returnFunctionFinish != null){
tempFrameTimer._returnFunctionFinish();
};
_arr.splice(i, 1);
i--;
if (_arr.length <= 0){
_listenerMc.removeEventListener(Event.ENTER_FRAME, run);
_listenerMc = null;
};
} else {
tempFrameTimer._cycleNum--;
};
} else {
tempFrameTimer._step++;
};
i++;
};
}
public static function delById(id:uint):void{
var i:int;
while (i < _arr.length) {
if ((_arr[i] as FrameTimer)._id == id){
_arr.splice(i, 1);
if (_arr.length <= 0){
_listenerMc.removeEventListener(Event.ENTER_FRAME, run);
_listenerMc = null;
};
return;
};
i++;
};
}
public static function delAll():void{
_arr = new Array();
if (_listenerMc){
_listenerMc.removeEventListener(Event.ENTER_FRAME, run);
_listenerMc = null;
};
}
public static function pauseAll():void{
_listenerMc.removeEventListener(Event.ENTER_FRAME, run);
}
public static function reStartAll():void{
_listenerMc.addEventListener(Event.ENTER_FRAME, run);
}
}
}//package zlong.breathxue.utils
Section 219
//Tools (zlong.breathxue.utils.Tools)
package zlong.breathxue.utils {
import flash.display.*;
import flash.geom.*;
public class Tools {
breathxue_utils_internal static const VERSION:String = "v1.10.201004261516";
public static function getNowTimeAndMileSecond_1():String{
var time:Date = new Date();
var h:int = time.getHours();
var m:int = time.getMinutes();
var s:int = time.getSeconds();
var ms:int = time.getMilliseconds();
return (((((((((h < 10)) ? ("0" + h) : h + ":") + ((m < 10)) ? ("0" + m) : m) + ":") + ((s < 10)) ? ("0" + s) : s) + ":") + ((ms < 10)) ? ("00" + ms) : ((ms < 100)) ? ("0" + ms) : ms));
}
public static function cutBmp(_mc:DisplayObject, _bmpDataWidth:int, _bmpDataHeight:int, _cutStartX:int, _cutStartY:int, _cutBmpWidth:int, _cutBmpHeight:int):BitmapData{
var bitmapData:BitmapData;
var rectangle:Rectangle;
var matrix:Matrix = new Matrix();
matrix.tx = -(_cutStartX);
matrix.ty = -(_cutStartY);
rectangle = new Rectangle(0, 0, _cutBmpWidth, _cutBmpHeight);
bitmapData = new BitmapData(_bmpDataWidth, _bmpDataHeight, true, 0);
bitmapData.draw(_mc, matrix, null, null, rectangle, true);
return (bitmapData);
}
}
}//package zlong.breathxue.utils
Section 220
//Countries (zlong.country.Countries)
package zlong.country {
import zlong.country.*;
import zlong.*;
class Countries {
private var _countries:Object;
private var _portal:String;
private var _portalGroup:Array;
private var _country:String;
private var _countryGroup:Array;
localComponent_internal static const VERSION:String = "v1.03.201005181759";
function Countries(){
super();
this.initPortalGroup();
}
function set portal(gameType:String):void{
if (!this.inArray(gameType, this._portalGroup)){
throw (new ArgumentError(("Please set portal with value : " + this._portalGroup.toString())));
};
this._portal = gameType;
this.initCountries();
if (((!((this._country == null))) && (!(this.inArray(this._country, this._countryGroup))))){
throw (new ArgumentError(("Please reset country with value : " + this._countryGroup.toString())));
};
}
function get portal():String{
return (this._portal);
}
function set country(name:String):void{
if (((!((this._countryGroup == null))) && (!(this.inArray(name, this._countryGroup))))){
this._country = this._countryGroup[0];
trace(("Error in the country value,set country with default value : " + this._countryGroup[0]));
trace(("Please set country with value : " + this._countryGroup.toString()));
} else {
this._country = name;
};
}
function get current():CountryItem{
if (this._portal == null){
throw (new ArgumentError("Please set portal"));
};
if (this._country == null){
throw (new ArgumentError("Please set country"));
};
return (this._countries[this._country]);
}
function get countryGroup():Array{
if (this._countryGroup == null){
throw (new ArgumentError("Please set portal"));
};
return (this._countryGroup);
}
private function initCountries():void{
var countryItem:CountryItem;
var name:String;
var domain:String;
var game:String;
var language:int;
this._countries = new Object();
this._countryGroup = new Array();
var i:int;
while (i < CountriesData.DATA[this._portal]["country"].length()) {
name = CountriesData.DATA[this._portal]["country"][i].@name;
domain = CountriesData.DATA[this._portal]["country"][i].@domain;
game = CountriesData.DATA[this._portal]["country"][i].@game;
language = int(CountriesData.DATA[this._portal]["country"][i].@language);
countryItem = new CountryItem();
countryItem.name = name;
countryItem.domain = domain;
countryItem.game = game;
countryItem.language = language;
this._countries[countryItem.name] = countryItem;
this._countryGroup.push(name);
i++;
};
}
private function initPortalGroup():void{
this._portalGroup = new Array();
var i:int;
while (i < CountriesData.DATA.children().length()) {
this._portalGroup.push(CountriesData.DATA.children()[i].name());
i++;
};
}
private function inArray(str:String, arr:Array):Boolean{
var i:int;
while (i < arr.length) {
if (str == arr[i]){
return (true);
};
i++;
};
return (false);
}
}
}//package zlong.country
Section 221
//CountriesData (zlong.country.CountriesData)
package zlong.country {
import zlong.*;
class CountriesData {
localComponent_internal static const VERSION:String = "v1.03.201005181759";
static const DATA:XML = <data>
<family>
<!-- new -->
<country name="arg" domain="www.juegos.com.ar" game="game" language="6"/><!-- Argentina -->
<country name="mx" domain="www.juegos.mx" game="game" language="6"/><!-- Mexico -->
<country name="ar" domain="www.dailygame.com" game="game" language="1"/><!-- Arabic(English US) 2009.07.14-->
<country name="br" domain="www.ojogos.com.br" game="jogo" language="7"/><!-- Brazillian -->
<country name="cn" domain="www.game.com.cn" game="moregames" language="17"/><!-- Chinese -->
<country name="de" domain="www.jetztspielen.de" game="spiel" language="5"/><!-- German -->
<country name="es" domain="www.juegos.com" game="juego" language="6"/><!-- Spanish -->
<country name="fr" domain="www.jeux.fr" game="jeu" language="4"/><!-- French -->
<country name="id" domain="www.games.co.id" game="permainanme" language="14"/><!-- Indonesian -->
<country name="in" domain="www.game.co.in" game="game" language="2"/><!-- English UK -->
<country name="it" domain="www.gioco.it" game="gioco" language="9"/><!-- Italian -->
<country name="jp" domain="www.egames.jp" game="game" language="16"/><!-- Japanese -->
<country name="nl" domain="www.spelletjes.nl" game="spel" language="3"/><!-- Dutch -->
<country name="pl" domain="www.gry.pl" game="gra" language="11"/><!-- Polish -->
<country name="pt" domain="www.ojogos.pt" game="jogo" language="8"/><!-- Portuguese -->
<country name="ru" domain="www.ourgames.ru" game="igra" language="12"/><!-- Russian -->
<country name="se" domain="www.spela.se" game="spel_" language="10"/><!-- Swedish -->
<country name="en_uk" domain="www.games.co.uk" game="game" language="2"/><!-- English UK -->
<country name="en_us" domain="www.gamesgames.com" game="game" language="1"/><!-- English US -->
<!-- removed -->
<!-- country name="ph" domain="www.laro.com.ph" game="game" language="2"/ --><!-- English UK -->
<!-- country name="tr" domain="www.asoyun.com" game="oyun" language="13"/ --><!-- Turkish -->
<!-- country name="my" domain="www.game.com.my" game="permainan_" language="15"/ --><!-- Malaysian -->
</family>
<tween>
<!-- new -->
<country name="arg" domain="www.juegos.com.ar" game="game" language="6"/><!-- Argentina -->
<country name="mx" domain="www.juegos.mx" game="game" language="6"/><!-- Mexico -->
<country name="ar" domain="www.dailygame.com" game="game" language="1"/><!-- Arabic(English US) 2009.07.14 -->
<country name="br" domain="www.clickjogos.com" game="jogo" language="7"/><!-- Brazillian -->
<country name="cn" domain="www.game.com.cn" game="moregames" language="17"/><!-- Chinese -->
<country name="de" domain="www.spielen.com" game="spiel" language="5"/><!-- German -->
<country name="es" domain="www.zapjuegos.com" game="juego" language="6"/><!-- Spanish -->
<country name="fr" domain="www.jeu.fr" game="jeu" language="4"/><!-- French -->
<country name="id" domain="www.games.co.id" game="permainanme" language="14"/><!-- Indonesian -->
<country name="in" domain="www.game.co.in" game="game" language="2"/><!-- English UK -->
<country name="it" domain="www.gioco.it" game="gioco" language="9"/><!-- Italian 2009.08.10 -->
<country name="jp" domain="www.egames.jp" game="game" language="16"/><!-- Japanese -->
<country name="nl" domain="www.spel.nl" game="spel" language="3"/><!-- Dutch -->
<country name="pl" domain="www.gry.pl" game="gra" language="11"/><!-- Polish 2009.08.10-->
<country name="pt" domain="www.ojogos.pt" game="jogo" language="8"/><!-- Portuguese -->
<country name="ru" domain="www.flashgames.ru" game="igra" language="12"/><!-- Russian -->
<country name="se" domain="www.spel.se" game="spel_" language="10"/><!-- Swedish -->
<country name="en_uk" domain="www.agame.com" game="game" language="2"/><!-- English UK 2009.08.28-->
<country name="en_us" domain="www.agame.com" game="game" language="1"/><!-- English US -->
<!-- removed -->
<!-- country name="ph" domain="www.laro.com.ph" game="game" language="2"/ --><!-- English UK -->
<!-- country name="tr" domain="www.asoyun.com" game="oyun" language="13"/ --><!-- Turkish -->
<!-- country name="my" domain="www.game.com.my" game="permainan_" language="15"/ --><!-- Malaysian -->
</tween>
<girl>
<!-- new -->
<country name="arg" domain="www.juegosdechicas.com.ar" game="game" language="6"/><!-- Argentina -->
<country name="mx" domain="www.juegosdechicas.mx" game="game" language="6"/><!-- Mexico -->
<country name="ar" domain="www.dailygame.com" game="game" language="1"/><!-- Arabic(English US) 2009.07.14-->
<country name="br" domain="www.girlsgogames.com.br" game="jogo" language="7"/><!-- Brazillian -->
<country name="cn" domain="www.game.com.cn" game="moregames" language="17"/><!-- Chinese -->
<country name="de" domain="www.girlsgogames.de" game="spiel" language="5"/><!-- German -->
<country name="es" domain="www.girlsgogames.es" game="juego" language="6"/><!-- Spanish -->
<country name="fr" domain="www.girlsgogames.fr" game="jeu" language="4"/><!-- French -->
<country name="id" domain="www.games.co.id" game="permainanme" language="14"/><!-- Indonesian -->
<country name="in" domain="www.game.co.in" game="game" language="2"/><!-- English UK -->
<country name="it" domain="www.girlsgogames.it" game="gioco" language="9"/><!-- Italian -->
<country name="jp" domain="www.egames.jp" game="game" language="16"/><!-- Japanese -->
<country name="nl" domain="www.girlsgogames.nl" game="spel" language="3"/><!-- Dutch -->
<country name="pl" domain="www.girlsgogames.pl" game="gra" language="11"/><!-- Polish -->
<country name="pt" domain="www.ojogos.pt" game="jogo" language="8"/><!-- Portuguese -->
<country name="ru" domain="www.girlsgogames.ru" game="igra" language="12"/><!-- Russian -->
<country name="se" domain="www.girlsgogames.se" game="spel_" language="10"/><!-- Swedish -->
<country name="en_uk" domain="www.girlsgogames.co.uk" game="game" language="2"/><!-- English UK -->
<country name="en_us" domain="www.girlsgogames.com" game="game" language="1"/><!-- English US -->
<!-- removed -->
<!-- country name="ph" domain="www.laro.com.ph" game="game" language="2"/ --><!-- English UK -->
<!-- country name="tr" domain="www.girlsgogamestr.com" game="oyun" language="13"/ --><!-- Turkish -->
<!-- country name="my" domain="www.game.com.my" game="permainan_" language="15"/ --><!-- Malaysian -->
</girl>
<teen>
<!-- new -->
<!--country name="arg" domain="www.juegosdechicas.com.ar" game="game" language="6"/ --><!-- Argentina -->
<!--country name="mx" domain="www.juegosdechicas.mx" game="game" language="6"/ --><!-- Mexico -->
<!--country name="ar" domain="www.dailygame.com" game="game" language="1"/ --><!-- Arabic(English US) 2009.07.14-->
<!--country name="br" domain="www.a10.com" game="jogo" language="7"/ --><!-- Brazillian -->
<!--country name="cn" domain="www.game.com.cn" game="moregames" language="17"/ --><!-- Chinese -->
<!--country name="de" domain="www.a10.com" game="spiel" language="5"/ --><!-- German -->
<!--country name="es" domain="www.a10.com" game="juego" language="6"/ --><!-- Spanish -->
<!--country name="fr" domain="www.a10.com" game="jeu" language="4"/ --><!-- French -->
<!--country name="id" domain="www.a10.com" game="permainanme" language="14"/ --><!-- Indonesian -->
<!--country name="in" domain="www.a10.com" game="game" language="2"/ --><!-- English UK -->
<!--country name="it" domain="www.a10.com" game="gioco" language="9"/ --><!-- Italian -->
<!--country name="jp" domain="www.a10.com" game="game" language="16"/ --><!-- Japanese -->
<!--country name="nl" domain="www.a10.com" game="spel" language="3"/ --><!-- Dutch -->
<!--country name="pl" domain="www.a10.com" game="gra" language="11"/ --><!-- Polish -->
<!--country name="pt" domain="www.a10.com" game="jogo" language="8"/ --><!-- Portuguese -->
<!--country name="ru" domain="www.a10.com" game="igra" language="12"/ --><!-- Russian -->
<!--country name="se" domain="www.a10.com" game="spel_" language="10"/ --><!-- Swedish -->
<!--country name="en_uk" domain="www.a10.com" game="game" language="2"/ --><!-- English UK -->
<country name="en_us" domain="www.a10.com" game="game" language="1"/><!-- English US -->
<!-- removed -->
<!-- country name="ph" domain="www.a10.com" game="game" language="2"/ --><!-- English UK -->
<!-- country name="tr" domain="www.a10.com" game="oyun" language="13"/ --><!-- Turkish -->
<!-- country name="my" domain="www.a10.com" game="permainan_" language="15"/ --><!-- Malaysian -->
</teen>
<zapapa>
<!-- new -->
<country name="arg" domain="www.zapapa.com" game="game" language="6"/><!-- Argentina -->
<country name="mx" domain="www.zapapa.com" game="game" language="6"/><!-- Mexico -->
<country name="ar" domain="www.zapapa.com" game="game" language="1"/><!-- Arabic(English US) 2009.07.14-->
<country name="br" domain="www.zapapa.com" game="game" language="7"/><!-- Brazillian -->
<country name="cn" domain="www.zapapa.com" game="game" language="17"/><!-- Chinese -->
<country name="de" domain="www.zapapa.com" game="game" language="5"/><!-- German -->
<country name="es" domain="www.zapapa.com" game="game" language="6"/><!-- Spanish -->
<country name="fr" domain="www.zapapa.com" game="game" language="4"/><!-- French -->
<country name="id" domain="www.zapapa.com" game="game" language="14"/><!-- Indonesian -->
<country name="in" domain="www.zapapa.com" game="game" language="2"/><!-- English UK -->
<country name="it" domain="www.zapapa.com" game="game" language="9"/><!-- Italian -->
<country name="jp" domain="www.zapapa.com" game="game" language="16"/><!-- Japanese -->
<country name="nl" domain="www.zapapa.com" game="game" language="3"/><!-- Dutch -->
<country name="pl" domain="www.zapapa.com" game="game" language="11"/><!-- Polish -->
<country name="pt" domain="www.zapapa.com" game="game" language="8"/><!-- Portuguese -->
<country name="ru" domain="www.zapapa.com" game="game" language="12"/><!-- Russian -->
<country name="se" domain="www.zapapa.com" game="game" language="10"/><!-- Swedish -->
<country name="en_uk" domain="www.zapapa.com" game="game" language="2"/><!-- English UK -->
<country name="en_us" domain="www.zapapa.com" game="game" language="1"/><!-- English US -->
</zapapa>
<hyves>
<!-- new -->
<country name="nl" domain="www.zapapa.nl" game="game" language="3"/><!-- Dutch -->
</hyves>
</data>
;
}
}//package zlong.country
Section 222
//CountryInfo (zlong.country.CountryInfo)
package zlong.country {
import zlong.domain.*;
import zlong.*;
import zlong.data.*;
public class CountryInfo {
private var countries:Countries;
localComponent_internal static const VERSION:String = "v1.03.201005181759";
private static var _instance:CountryInfo;
public function CountryInfo(){
super();
this.countries = new Countries();
}
public function set portal(portal:String):void{
this.countries.portal = portal;
}
public function get portal():String{
return (this.countries.portal);
}
public function set country(country:String):void{
this.countries.country = country;
}
public function get country():String{
return (this.countries.current.name);
}
public function get domain():String{
return (this.countries.current.domain);
}
public function get language():int{
return (this.countries.current.language);
}
public function get countryGroup():Array{
return (this.countries.countryGroup);
}
public function get moreGameLink():String{
var str:String;
str = ("http://" + this.domain);
if (this.countries.current.name != "cn"){
str = (str + "/");
str = (str + ("?utm_medium=brandedgames_" + (DomainInfo.instance.allowed) ? "internal" : "external"));
str = (str + ("&utm_campaign=" + GameInfo.name));
str = (str + ("&utm_source=" + DomainInfo.instance.domainAb));
} else {
str = (str + "/");
str = (str + "moregames");
str = (str + "/");
};
return (str);
}
public function get thisGameLink():String{
var str:String;
str = ("http://" + this.domain);
str = (str + ((("/" + this.countries.current.game) + "/") + GameInfo.html));
if (this.countries.current.name != "cn"){
str = (str + ("?utm_medium=brandedgames_" + (DomainInfo.instance.allowed) ? "internal" : "external"));
str = (str + ("&utm_campaign=" + GameInfo.name));
str = (str + ("&utm_source=" + DomainInfo.instance.domainAb));
};
return (str);
}
public function get sendToFriendLink():String{
var str:String = this.thisGameLink;
if (this.countries.current.name != "cn"){
str = (str + "&utm_content=send_to_friend");
};
return (str);
}
public static function get instance():CountryInfo{
if (_instance == null){
_instance = new (CountryInfo);
};
return (_instance);
}
}
}//package zlong.country
Section 223
//CountryItem (zlong.country.CountryItem)
package zlong.country {
import zlong.*;
final class CountryItem {
var name:String;
var domain:String;
var game:String;
var language:int;
localComponent_internal static const VERSION:String = "v1.03.201005181759";
}
}//package zlong.country
Section 224
//CountryCookie (zlong.data.CountryCookie)
package zlong.data {
import flash.net.*;
import zlong.*;
public class CountryCookie {
localComponent_internal static const VERSION:String = "v1.03.201005181759";
private static const name:String = "spilgames_language_v100";
private static const countryName:String = "savedLang";
private static var so:SharedObject;
public function CountryCookie():void{
super();
so = SharedObject.getLocal(name, "/");
}
localComponent_internal static function set country(_value:String):void{
so.data[countryName] = _value;
}
localComponent_internal static function get country():String{
return (so.data[countryName]);
}
}
}//package zlong.data
Section 225
//GameInfo (zlong.data.GameInfo)
package zlong.data {
import zlong.*;
public class GameInfo {
localComponent_internal static const VERSION:String = "v1.03.201005181759";
localComponent_internal static var cnversion:Boolean = false;
localComponent_internal static var portal:String = "family";
localComponent_internal static var name:String = "game_name";
localComponent_internal static var html:String = "Game-Name.html";
localComponent_internal static var width:int = 550;
localComponent_internal static var height:int = 400;
}
}//package zlong.data
Section 226
//AbstractBindingDisplay (zlong.display.AbstractBindingDisplay)
package zlong.display {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
public class AbstractBindingDisplay extends MovieClip {
localComponent_internal static const VERSION:String = "v1.03.201005181759";
public function AbstractBindingDisplay(){
super();
if (getQualifiedClassName(this) == "zlong::display::AbstractBindingDisplay"){
throw (new ArgumentError("can't be constructed"));
};
}
public function initEvent(e:Event=null):void{
}
public function delEvent(e:Event=null):void{
}
}
}//package zlong.display
Section 227
//BindingDisplayEvent (zlong.display.BindingDisplayEvent)
package zlong.display {
import flash.events.*;
public class BindingDisplayEvent extends Event {
private var _BD:AbstractBindingDisplay;
private var _displayType:String;
localComponent_internal static const VERSION:String = "v1.03.201005181759";
public static const BINDING_DISPLAY_INIT:String = "BINDING_DISPLAY_INIT";
public static const BINDING_DISPLAY_DEL_EVENT:String = "BINDING_DISPLAY_DEL_EVENT";
public static const BINDING_DISPLAY_ADDED_TO_STAGE:String = "BINDING_DISPLAY_ADDED_TO_STAGE";
public static const BINDING_DISPLAY_REMOVE_TO_STAGE:String = "BINDING_DISPLAY_REMOVE_TO_STAGE";
public function BindingDisplayEvent(type:String, BD:AbstractBindingDisplay, displayType:String, bubbles:Boolean=false, cancelable:Boolean=false){
super(type, bubbles, cancelable);
this._BD = BD;
this._displayType = displayType;
}
public function get bindingDisplay():AbstractBindingDisplay{
return (this._BD);
}
public function get displayType():String{
return (this._displayType);
}
}
}//package zlong.display
Section 228
//BindingDisplayManager (zlong.display.BindingDisplayManager)
package zlong.display {
import flash.events.*;
public class BindingDisplayManager extends EventDispatcher {
localComponent_internal static const VERSION:String = "v1.03.201005181759";
private static var _instance:BindingDisplayManager;
public function BindingDisplayManager():void{
super();
}
public static function get Instance():BindingDisplayManager{
if (_instance == null){
_instance = new (BindingDisplayManager);
};
return (_instance);
}
}
}//package zlong.display
Section 229
//CountriesBox (zlong.display.CountriesBox)
package zlong.display {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import zlong.data.*;
import zlong.country.*;
public class CountriesBox extends AbstractBindingDisplay {
private var i:uint;
private var mul:int;// = 1
private var baseX:Number;// = 0
private var baseY:Number;// = 0
private var nameGroup:Array;
private var obj:Object;
private var pop:Sprite;
private var flagMc:MovieClip;
private var selectBox:MovieClip;
private var country_name:MovieClip;
localComponent_internal static const VERSION:String = "v1.03.201005181759";
public function CountriesBox(){
this.nameGroup = [];
super();
addEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler);
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_INIT, this, "CountriesBox"));
}
private function addToStageHandler(e:Event):void{
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_ADDED_TO_STAGE, this, "CountriesBox"));
this.initEvent();
}
private function removeFromStageHandler(e:Event):void{
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_REMOVE_TO_STAGE, this, "CountriesBox"));
this.delEvent();
}
override public function initEvent(e:Event=null):void{
if (this.hasEventListener(Event.ADDED_TO_STAGE)){
removeEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler);
};
this.initShow();
addEventListener(Event.REMOVED_FROM_STAGE, this.removeFromStageHandler);
}
override public function delEvent(e:Event=null):void{
removeEventListener(MouseEvent.ROLL_OVER, this.overHandler);
removeEventListener(MouseEvent.ROLL_OUT, this.outHandler);
removeEventListener(MouseEvent.CLICK, this.clickHandler);
if (this.hasEventListener(Event.ADDED_TO_STAGE)){
removeEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler);
};
if (this.hasEventListener(Event.REMOVED_FROM_STAGE)){
removeEventListener(Event.REMOVED_FROM_STAGE, this.removeFromStageHandler);
};
this.delPoPEvent();
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_DEL_EVENT, this, "CountriesBox"));
}
private function initShow():void{
this.obj = new Object();
this.initPos();
this.setFlag();
this.setPop();
this.initFlagEvent();
this.initPoPEvent();
if (GameInfo.cnversion){
this.visible = false;
this.setLanguage("cn");
};
}
private function initPos():void{
var p:Point = new Point();
p = this.parent.localToGlobal(new Point(x, y));
if (p.y > (GameInfo.height / 2)){
this.mul = 1;
} else {
this.mul = -1;
};
}
private function setFlag():void{
this.country_name = (getChildByName("countryName") as MovieClip);
this.flagMc = (getChildByName("flag") as MovieClip);
this.flagMc.gotoAndStop(CountryInfo.instance.country);
this.country_name.gotoAndStop(CountryInfo.instance.country);
}
private function setPop():void{
var unitW:Number;
var unitH:Number;
var pop_flag:MovieClip;
var _name:String;
var pop_flag_flag:MovieClip;
var dx:Number = 0;
var dy:Number = 0;
this.pop = (getChildByName("popList") as Sprite);
this.selectBox = (getChildByName("selectbox") as MovieClip);
unitW = this.pop.getChildByName("_blank").width;
unitH = (this.pop.getChildByName("_blank").height - 1);
this.baseX = this.selectBox.x;
this.nameGroup = CountryInfo.instance.countryGroup;
var len:int = this.nameGroup.length;
if (this.mul == 1){
this.baseY = ((this.selectBox.y - (Math.round((len / 2)) * unitH)) + unitH);
} else {
this.baseY = ((this.selectBox.y + this.selectBox.height) + unitH);
};
this.pop.y = this.baseY;
this.pop.visible = false;
this.pop.getChildByName("_blank").visible = false;
this.i = 0;
while (this.i < len) {
_name = this.nameGroup[this.i];
if (this.pop.getChildByName(("l_" + _name)) != null){
pop_flag = (this.pop.getChildByName(("l_" + _name)) as MovieClip);
pop_flag.mouseChildren = false;
pop_flag.buttonMode = true;
pop_flag.stop();
pop_flag_flag = (pop_flag.getChildByName("flag") as MovieClip);
pop_flag_flag.mouseEnabled = false;
pop_flag_flag.mouseChildren = false;
pop_flag_flag.gotoAndStop(_name);
this.obj[("l_" + _name)] = true;
dx = (((this.i % 2) == 0)) ? 0 : 1;
pop_flag.x = ((unitW * (this.i % 2)) - dx);
pop_flag.y = ((unitH * Math.floor((this.i / 2))) - unitH);
};
this.i++;
};
this.i = 0;
while (this.i < this.pop.numChildren) {
if (this.pop.getChildAt(this.i).name.indexOf("l_") != -1){
if (this.obj[this.pop.getChildAt(this.i).name] == undefined){
this.pop.getChildAt(this.i).visible = false;
};
};
this.i++;
};
if ((this.nameGroup.length % 2) == 0){
this.pop.getChildByName("_blank").visible = false;
} else {
this.pop.getChildByName("_blank").visible = true;
this.pop.getChildByName("_blank").x = (unitW - 1);
this.pop.getChildByName("_blank").y = (((unitH * Math.floor((this.nameGroup.length / 2))) - unitH) - dy);
};
}
private function initFlagEvent():void{
addEventListener(MouseEvent.ROLL_OVER, this.overHandler, false, 0, true);
addEventListener(MouseEvent.ROLL_OUT, this.outHandler, false, 0, true);
addEventListener(MouseEvent.CLICK, this.clickHandler, false, 0, true);
}
private function clickHandler(e:MouseEvent):void{
var _flag:MovieClip;
var _name:String = e.target["name"];
if (_name == "_blank"){
return;
};
if (_name.indexOf("l_") != -1){
_flag = (e.target["getChildByName"]("flag") as MovieClip);
this.flagMc.gotoAndStop(_name.substr(2));
this.country_name.gotoAndStop(_flag.currentFrame);
this.setLanguage(_name.substr(2));
this.pop.visible = false;
};
}
private function setLanguage(_cnm:String):void{
CountryInfo.instance.country = _cnm;
CountryCookie.country = _cnm;
Dispatcher.langChanged();
}
private function overHandler(e:MouseEvent):void{
this.pop.visible = true;
}
private function outHandler(e:MouseEvent):void{
this.pop.visible = false;
}
private function initPoPEvent():void{
this.pop.addEventListener(MouseEvent.MOUSE_OVER, this.overPoPHandler);
this.pop.addEventListener(MouseEvent.MOUSE_OUT, this.outPoPHandler);
}
private function delPoPEvent():void{
this.pop.removeEventListener(MouseEvent.MOUSE_OVER, this.overPoPHandler);
this.pop.removeEventListener(MouseEvent.MOUSE_OUT, this.outPoPHandler);
}
private function overPoPHandler(e:MouseEvent):void{
var _local2 = e.target;
_local2["gotoAndStop"](2);
}
private function outPoPHandler(e:MouseEvent):void{
var _local2 = e.target;
_local2["gotoAndStop"](1);
}
}
}//package zlong.display
Section 230
//Dispatcher (zlong.display.Dispatcher)
package zlong.display {
import flash.events.*;
import zlong.*;
class Dispatcher {
localComponent_internal static const VERSION:String = "v1.03.201005181759";
static const LANGUAGE_CHANGED:String = "languageChanged";
static var dispatcher:EventDispatcher = new EventDispatcher();
static function langChanged():void{
dispatcher.dispatchEvent(new Event(LANGUAGE_CHANGED));
}
}
}//package zlong.display
Section 231
//ExtButton (zlong.display.ExtButton)
package zlong.display {
import flash.events.*;
import zlong.navigate.*;
public class ExtButton extends AbstractBindingDisplay {
private var _type:String;// = "moregames"
private var _position:String;// = "button_preloader"
localComponent_internal static const VERSION:String = "v1.03.201005181759";
public function ExtButton(){
super();
this.gotoAndStop(1);
this.buttonMode = true;
this.mouseChildren = false;
addEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler);
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_INIT, this, "ExtButton"));
}
private function addToStageHandler(e:Event):void{
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_ADDED_TO_STAGE, this, "ExtButton"));
this.initEvent();
}
private function removeFromStageHandler(e:Event):void{
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_REMOVE_TO_STAGE, this, "ExtButton"));
this.delEvent();
}
override public function initEvent(e:Event=null):void{
if (this.hasEventListener(Event.ADDED_TO_STAGE)){
removeEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler);
};
this.addEventListener(MouseEvent.CLICK, this.clickHandler);
this.addEventListener(MouseEvent.ROLL_OVER, this.rollOverHandler);
this.addEventListener(MouseEvent.MOUSE_DOWN, this.mouseDownHandler);
this.addEventListener(MouseEvent.MOUSE_UP, this.mouseUpHandler);
this.addEventListener(MouseEvent.ROLL_OUT, this.rollOutHandler);
this.addEventListener(Event.REMOVED_FROM_STAGE, this.removeFromStageHandler);
}
override public function delEvent(e:Event=null):void{
this.removeEventListener(MouseEvent.CLICK, this.clickHandler);
this.removeEventListener(MouseEvent.ROLL_OVER, this.rollOverHandler);
this.removeEventListener(MouseEvent.MOUSE_DOWN, this.mouseDownHandler);
this.removeEventListener(MouseEvent.MOUSE_UP, this.mouseUpHandler);
this.removeEventListener(MouseEvent.ROLL_OUT, this.rollOutHandler);
if (this.hasEventListener(Event.ADDED_TO_STAGE)){
removeEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler);
};
if (this.hasEventListener(Event.REMOVED_FROM_STAGE)){
removeEventListener(Event.REMOVED_FROM_STAGE, this.removeFromStageHandler);
};
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_DEL_EVENT, this, "ExtButton"));
}
public function set position(_str:String):void{
this._position = _str;
}
public function set type(_str:String):void{
this._type = _str;
}
private function clickHandler(e:MouseEvent):void{
if (this._type == "moregames"){
Handler.click_moregames(this._position);
} else {
Handler.click_thisgame(this._position);
};
}
private function rollOverHandler(evt:MouseEvent):void{
this.gotoAndStop(2);
}
private function mouseDownHandler(evt:MouseEvent):void{
this.gotoAndStop(3);
}
private function mouseUpHandler(evt:MouseEvent):void{
this.gotoAndStop(2);
}
private function rollOutHandler(evt:MouseEvent):void{
this.gotoAndStop(1);
}
}
}//package zlong.display
Section 232
//HyvesLoading (zlong.display.HyvesLoading)
package zlong.display {
import flash.display.*;
import zlong.country.*;
import zlong.*;
public class HyvesLoading extends Sprite {
public function HyvesLoading(){
super();
if (CountryInfo.instance.portal != GameSetting.PORTAL_TYPE_HYVES){
this.visible = false;
};
}
}
}//package zlong.display
Section 233
//Logo (zlong.display.Logo)
package zlong.display {
import flash.display.*;
import flash.events.*;
import zlong.country.*;
import zlong.navigate.*;
public class Logo extends AbstractBindingDisplay {
private const MAX_WIDTH:int = 200;
private const Max_HEIGHT:int = 50;
private var _hitArea:Sprite;
private var _position:String;// = "logo_preloader"
private var _alignHorizontal:String;// = "Center"
private var _alignVertical:String;// = "Center"
private var _maxWidth:Number;// = 150
private var _maxHeight:Number;// = 40
localComponent_internal static const VERSION:String = "v1.03.201005181759";
public function Logo(){
super();
this.initDis();
addEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler, false, 0, true);
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_INIT, this, "Logo"));
}
private function addToStageHandler(e:Event):void{
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_ADDED_TO_STAGE, this, "Logo"));
this.initEvent();
}
private function removeFromStageHandler(e:Event):void{
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_REMOVE_TO_STAGE, this, "Logo"));
this.delEvent();
}
override public function initEvent(e:Event=null):void{
gotoAndStop(CountryInfo.instance.domain);
if (this.hasEventListener(Event.ADDED_TO_STAGE)){
removeEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler);
};
this.addEventListener(Event.REMOVED_FROM_STAGE, this.removeFromStageHandler);
this.addEventListener(MouseEvent.CLICK, this.clickHandler);
Dispatcher.dispatcher.addEventListener(Dispatcher.LANGUAGE_CHANGED, this.langChangeHandler);
this.updateView();
}
override public function delEvent(e:Event=null):void{
this.delDis();
if (this.hasEventListener(Event.ADDED_TO_STAGE)){
removeEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler);
};
if (this.hasEventListener(Event.REMOVED_FROM_STAGE)){
removeEventListener(Event.REMOVED_FROM_STAGE, this.removeFromStageHandler);
};
this.removeEventListener(MouseEvent.CLICK, this.clickHandler);
Dispatcher.dispatcher.removeEventListener(Dispatcher.LANGUAGE_CHANGED, this.langChangeHandler);
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_DEL_EVENT, this, "Logo"));
}
public function set position(_str:String):void{
this._position = _str;
}
public function set alignHorizontal(str:String):void{
this._alignHorizontal = str;
}
public function set alignVertical(str:String):void{
this._alignVertical = str;
}
public function set maxWidth(value:Number):void{
if (value < 0){
value = 0;
} else {
if (value > this.MAX_WIDTH){
value = this.MAX_WIDTH;
};
};
this._maxWidth = value;
}
public function set maxHeight(value:Number):void{
if (value < 0){
value = 0;
} else {
if (value > this.Max_HEIGHT){
value = this.Max_HEIGHT;
};
};
this._maxHeight = value;
}
private function updateView():void{
var scale1:Number;
var scale2:Number;
var scale:Number;
var temp:Sprite = (this.getChildAt(0) as Sprite);
if (!temp){
return;
};
temp.scaleX = 1;
temp.scaleY = 1;
if ((((temp.height > 0)) && ((temp.width > 0)))){
scale1 = (this._maxHeight / temp.height);
scale2 = (this._maxWidth / temp.width);
scale = ((scale1 > scale2)) ? scale2 : scale1;
temp.scaleX = scale;
temp.scaleY = scale;
};
if (this._alignHorizontal){
switch (this._alignHorizontal){
case "Left":
temp.x = 0;
break;
case "Right":
temp.x = (this.MAX_WIDTH - temp.width);
break;
case "Center":
temp.x = ((this.MAX_WIDTH - temp.width) / 2);
break;
};
};
if (this._alignVertical){
switch (this._alignVertical){
case "Up":
temp.y = 0;
break;
case "Down":
temp.y = (this.Max_HEIGHT - temp.height);
break;
case "Center":
temp.y = ((this.Max_HEIGHT - temp.height) / 2);
break;
};
};
this._hitArea.width = temp.width;
this._hitArea.height = temp.height;
this._hitArea.x = temp.x;
this._hitArea.y = temp.y;
}
private function initDis():void{
buttonMode = true;
this._hitArea = new Sprite();
this.addChild(this._hitArea);
this._hitArea.graphics.beginFill(3368601, 0);
this._hitArea.graphics.drawRect(0, 0, 10, 10);
this._hitArea.graphics.endFill();
this.getChildByName("displayArea_mc").visible = false;
var i:int;
while (i < this.totalFrames) {
this.addFrameScript(i, this.updateView);
i++;
};
}
private function delDis():void{
stop();
}
private function clickHandler(e:MouseEvent):void{
Handler.click_moregames(this._position);
}
private function langChangeHandler(e:Event):void{
gotoAndStop(CountryInfo.instance.domain);
}
}
}//package zlong.display
Section 234
//Menu (zlong.display.Menu)
package zlong.display {
import flash.events.*;
import flash.display.*;
import zlong.country.*;
import zlong.*;
import flash.ui.*;
import zlong.navigate.*;
public class Menu {
private var displayObject:InteractiveObject;
private var menu:ContextMenu;
private var item:ContextMenuItem;
localComponent_internal static const VERSION:String = "v1.03.201005181759";
public function Menu(doc:InteractiveObject){
super();
this.displayObject = doc;
this.init();
this.initEvent();
}
private function init():void{
this.menu = new ContextMenu();
this.menu.hideBuiltInItems();
var defaultItems:ContextMenuBuiltInItems = this.menu.builtInItems;
defaultItems.print = true;
defaultItems.zoom = true;
defaultItems.quality = true;
this.item = new ContextMenuItem(("MoreGame: " + CountryInfo.instance.domain));
this.menu.customItems.push(this.item);
this.displayObject.contextMenu = this.menu;
}
private function initEvent():void{
this.item.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, this.clickItemHandler);
Dispatcher.dispatcher.addEventListener(Dispatcher.LANGUAGE_CHANGED, this.changeLang);
}
private function changeLang(e:Event):void{
this.item.caption = CountryInfo.instance.domain;
}
private function clickItemHandler(e:ContextMenuEvent):void{
Handler.click_moregames("Contex_Menu");
}
}
}//package zlong.display
Section 235
//TranText (zlong.display.TranText)
package zlong.display {
import flash.events.*;
import zlong.country.*;
public class TranText extends AbstractBindingDisplay {
private var isChange:Boolean;// = true
localComponent_internal static const VERSION:String = "v1.03.201005181759";
public function TranText(){
super();
addEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler, false, 0, true);
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_INIT, this, "TranText"));
}
private function addToStageHandler(e:Event):void{
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_ADDED_TO_STAGE, this, "TranText"));
this.initEvent();
}
private function removeFromStageHandler(e:Event):void{
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_REMOVE_TO_STAGE, this, "TranText"));
this.delEvent();
}
override public function initEvent(e:Event=null):void{
this.changeLang();
if (this.hasEventListener(Event.ADDED_TO_STAGE)){
removeEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler);
};
addEventListener(Event.REMOVED_FROM_STAGE, this.removeFromStageHandler);
Dispatcher.dispatcher.addEventListener(Dispatcher.LANGUAGE_CHANGED, this.langChangeHandler);
}
override public function delEvent(e:Event=null):void{
if (this.hasEventListener(Event.ADDED_TO_STAGE)){
removeEventListener(Event.ADDED_TO_STAGE, this.addToStageHandler);
};
if (this.hasEventListener(Event.REMOVED_FROM_STAGE)){
removeEventListener(Event.REMOVED_FROM_STAGE, this.removeFromStageHandler);
};
Dispatcher.dispatcher.removeEventListener(Dispatcher.LANGUAGE_CHANGED, this.langChangeHandler);
BindingDisplayManager.Instance.dispatchEvent(new BindingDisplayEvent(BindingDisplayEvent.BINDING_DISPLAY_DEL_EVENT, this, "TranText"));
}
public function set change(_v:Boolean):void{
this.isChange = _v;
}
private function changeLang():void{
gotoAndStop(CountryInfo.instance.language);
}
private function langChangeHandler(e:Event):void{
if (this.isChange){
this.changeLang();
};
}
}
}//package zlong.display
Section 236
//DomainData (zlong.domain.DomainData)
package zlong.domain {
import zlong.*;
final class DomainData {
localComponent_internal static const VERSION:String = "v1.03.201005181759";
static const allowedDomain:Array = ["www8.agame.com", "www.zlonggamestest.com", "gamedev.dev.spilgames.com"];
}
}//package zlong.domain
Section 237
//DomainInfo (zlong.domain.DomainInfo)
package zlong.domain {
import flash.net.*;
import zlong.*;
public final class DomainInfo {
private var _allowed:Boolean;
private var _domain:String;
private var _domainAb:String;
localComponent_internal static const VERSION:String = "v1.03.201005181759";
private static var _instance:DomainInfo;
public function DomainInfo(){
super();
this._domain = new LocalConnection().domain;
this.initAllowed();
this.initAb();
}
localComponent_internal function get allowed():Boolean{
return (this._allowed);
}
localComponent_internal function get domain():String{
return (this._domain);
}
localComponent_internal function get domainAb():String{
return (this._domainAb);
}
private function initAllowed():void{
var i:int;
while (i < DomainData.allowedDomain.length) {
if (this._domain == DomainData.allowedDomain[i]){
this._allowed = true;
break;
};
i++;
};
}
private function initAb():void{
var temp:Array;
var extention:int;
var name:int;
if (this._domain != "localhost"){
temp = this._domain.split(".");
extention = (temp.length - 1);
name = (temp.length - 2);
this._domainAb = ((temp[name] + ".") + temp[extention]);
} else {
this._domainAb = "offline_play";
};
}
public static function get instance():DomainInfo{
if (_instance == null){
_instance = new (DomainInfo);
};
return (_instance);
}
}
}//package zlong.domain
Section 238
//Handler (zlong.navigate.Handler)
package zlong.navigate {
import flash.events.*;
import zlong.country.*;
import flash.net.*;
import zlong.*;
import flash.external.*;
public class Handler {
localComponent_internal static const VERSION:String = "v1.03.201005181759";
public static function click_gamecn(e:Event=null):void{
var request:URLRequest = new URLRequest("http://www.game.com.cn");
navigateToURL(request, "_blank");
}
public static function click_copyright(e:Event=null):void{
var request:URLRequest;
if (CountryInfo.instance.country == "cn"){
request = new URLRequest("http://www.game.com.cn");
} else {
request = new URLRequest("http://www.gameportal.net");
};
navigateToURL(request, "_blank");
}
public static function refurbish(e:Event=null):void{
var e = e;
ExternalInterface.call("location.reload");
navigateToURL(new URLRequest(ExternalInterface.call("window.location.href.toString")), "_top");
//unresolved jump
var _slot1 = myError;
}
public static function click_thisgame(_position:String):void{
var request:URLRequest;
if (CountryInfo.instance.country == "cn"){
request = new URLRequest(CountryInfo.instance.moreGameLink);
} else {
request = new URLRequest(((CountryInfo.instance.thisGameLink + "&utm_content=") + _position));
};
navigateToURL(request, "_blank");
}
public static function click_moregames(_position:String):void{
var request:URLRequest;
if (CountryInfo.instance.country == "cn"){
request = new URLRequest(CountryInfo.instance.moreGameLink);
} else {
request = new URLRequest(((CountryInfo.instance.moreGameLink + "&utm_content=") + _position));
};
navigateToURL(request, "_blank");
}
}
}//package zlong.navigate
Section 239
//LocalSiteDataLoader (zlong.site.LocalSiteDataLoader)
package zlong.site {
import flash.events.*;
import flash.net.*;
import zlong.*;
public class LocalSiteDataLoader {
private var _localSiteDataLoader:URLLoader;
localComponent_internal static const VERSION:String = "v1.03.201005181759";
private static var _localSiteDataLoaderFinish:Boolean = true;
public function LocalSiteDataLoader(){
super();
_localSiteDataLoaderFinish = false;
this._localSiteDataLoader = new URLLoader();
this._localSiteDataLoader.dataFormat = URLLoaderDataFormat.TEXT;
this._localSiteDataLoader.addEventListener(IOErrorEvent.IO_ERROR, this.errorHandler);
this._localSiteDataLoader.addEventListener(SecurityErrorEvent.SECURITY_ERROR, this.errorHandler);
this._localSiteDataLoader.addEventListener(Event.COMPLETE, this.LocalSiteDataLoaderFinish);
this._localSiteDataLoader.load(new URLRequest(SiteData.URL));
//unresolved jump
var _slot1 = e;
errorHandler();
}
private function LocalSiteDataLoaderFinish(event:Event):void{
SiteData.allowedSite = new XML(this._localSiteDataLoader.data);
_localSiteDataLoaderFinish = true;
this.delLocalSiteDataLoader();
}
private function errorHandler(e:Event=null):void{
SiteData.allowedSite = <sites></sites>
;
_localSiteDataLoaderFinish = true;
this.delLocalSiteDataLoader();
}
private function delLocalSiteDataLoader():void{
this._localSiteDataLoader.removeEventListener(IOErrorEvent.IO_ERROR, this.errorHandler);
this._localSiteDataLoader.removeEventListener(Event.COMPLETE, this.LocalSiteDataLoaderFinish);
this._localSiteDataLoader.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, this.errorHandler);
this._localSiteDataLoader = null;
}
public static function get localSiteDataLoaderFinish():Boolean{
return (_localSiteDataLoaderFinish);
}
}
}//package zlong.site
Section 240
//SiteData (zlong.site.SiteData)
package zlong.site {
import zlong.*;
public final class SiteData {
localComponent_internal static const VERSION:String = "v1.03.201005181759";
public static const URL:String = "http://www8.agame.com/games/sitelock/sites.xml";
public static var allowedSite:XML;
}
}//package zlong.site
Section 241
//Award_HighScore (zlong.spilSystemTool.Award_HighScore)
package zlong.spilSystemTool {
import flash.events.*;
import flash.display.*;
import zlong.Template.*;
import Spill.Components.*;
import zlong.*;
public class Award_HighScore implements IEventDispatcher {
private var _sub:Submitter;
private var _debug:Boolean;
private var _mc:DisplayObject;
framework_internal static const VERSION:String = "v1.09.201005271521";
public static const AWORD_HIGHSCORE_TOOL_INITIALIZED_COMPONENT:String = "AWORD_HIGHSCORE_TOOL_INITIALIZED_COMPONENT";
public static const AWORD_HIGHSCORE_TOOL_INITIALIZED_FAILED:String = "AWORD_HIGHSCORE_TOOL_INITIALIZED_FAILED";
public static const SCORE_LOAD_ERROR:String = "ScoreLoadError";
public static const SCORE_LOAD_TIME_COMPLETE:String = "ScoreLoadTimeComplete";
public static const SCORE_LOAD_SUBMET_COMPLETE:String = "ScoreLoadSubmitComplete";
public static const SCORE_LOAD_LIST_COMPLETE:String = "ScoreLoadListComplete";
public static const ACHIEV_LOAD_ERROW:String = "AchievLoadError";
public static const ACHIEV_LOAD_TIME_COMPLETE:String = "AchievLoadTimeComplete";
public static const ACHIEV_LOAD_LIST_COMPLETE:String = "AchievLoadListComplete";
public static const ACHIEV_LOADINFO_COMPLETE:String = "AchievLoadInfoComplete";
public static const ACHIEV_LOADGRANT_COMPLETE:String = "AchievLoadGrantComplete";
private static var _instance:Award_HighScore;
private static var _initialized_finish:Boolean = true;
public function Award_HighScore(){
super();
_initialized_finish = false;
this._sub = new Submitter();
this._sub.addEventListener(Event.COMPLETE, this.SubmiterComponentInitialized);
this._sub.addEventListener(IOErrorEvent.IO_ERROR, this.FailedToLoadSubmitter);
this._sub.addEventListener(SecurityErrorEvent.SECURITY_ERROR, this.FailedToLoadSubmitter);
this._sub.addEventListener("LoadingFailed", this.FailedToLoadSubmitter);
}
public function init(gameName:String, container:DisplayObject, debug:Boolean=false, isLive:Boolean=true):void{
this._debug = debug;
this._mc = container;
if (container.stage == null){
throw (new ArgumentError("container need be added in stage"));
};
if (this._sub){
this._sub._O0000Ol01(container, AbstractRootClass.cutGameName(gameName), (AbstractRootClass.cutGameName(gameName, "-", true) + ".html"), 0, "normal", "", 0, 0, 1, debug);
};
}
private function SubmiterComponentInitialized(e:Event):void{
if (this._debug){
Trace(("Award_HighScore_Tool_Initialized_Component" + e));
if (this._mc){
this._mc.stage.addEventListener(KeyboardEvent.KEY_DOWN, this.keyBoardSendAwards);
};
};
_initialized_finish = true;
this._sub.removeEventListener(Event.COMPLETE, this.SubmiterComponentInitialized);
this._sub.removeEventListener(IOErrorEvent.IO_ERROR, this.FailedToLoadSubmitter);
this._sub.removeEventListener("LoadingFailed", this.FailedToLoadSubmitter);
this._sub.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, this.FailedToLoadSubmitter);
if (this._debug){
this._sub.addEventListener(SCORE_LOAD_ERROR, this.eventHandlerScore);
this._sub.addEventListener(SCORE_LOAD_TIME_COMPLETE, this.eventHandlerScore);
this._sub.addEventListener(SCORE_LOAD_SUBMET_COMPLETE, this.eventHandlerScore);
this._sub.addEventListener(SCORE_LOAD_LIST_COMPLETE, this.eventHandlerScore);
this._sub.addEventListener(ACHIEV_LOAD_ERROW, this.eventHandlerAchiev);
this._sub.addEventListener(ACHIEV_LOAD_TIME_COMPLETE, this.eventHandlerAchiev);
this._sub.addEventListener(ACHIEV_LOAD_LIST_COMPLETE, this.eventHandlerAchiev);
this._sub.addEventListener(ACHIEV_LOADINFO_COMPLETE, this.eventHandlerAchiev);
this._sub.addEventListener(ACHIEV_LOADGRANT_COMPLETE, this.eventHandlerAchiev);
};
this.dispatchEvent(new Event(AWORD_HIGHSCORE_TOOL_INITIALIZED_COMPONENT));
}
private function keyBoardSendAwards(event:Event):void{
var e:KeyboardEvent = (event as KeyboardEvent);
if (((((e.ctrlKey) && ((e.keyCode > 48)))) && ((e.keyCode < 58)))){
this.submitAchievement(("award" + String.fromCharCode(e.keyCode)));
};
}
private function FailedToLoadSubmitter(e:Event):void{
if (this._debug){
Trace(("Award_HighScore_Tool_Initialized_Failed" + e));
};
_initialized_finish = true;
this._sub.removeEventListener(Event.COMPLETE, this.SubmiterComponentInitialized);
this._sub.removeEventListener("LoadingFailed", this.FailedToLoadSubmitter);
this._sub.removeEventListener(IOErrorEvent.IO_ERROR, this.FailedToLoadSubmitter);
this._sub.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, this.FailedToLoadSubmitter);
this.dispatchEvent(new Event(AWORD_HIGHSCORE_TOOL_INITIALIZED_FAILED));
this._sub = null;
}
private function eventHandlerScore(e:Event):void{
if (e.currentTarget.OO00OO1l1l.O0l00l0O0 != null){
Trace(("SCORE_EVENT" + e.currentTarget.OO00OO1l1l.O0l00l0O0.toString()));
} else {
Trace(("SCORE_EVENT" + e.type));
};
}
private function eventHandlerAchiev(e:Event):void{
if (e.currentTarget.OO00OO1l1l.O1OlOO00O != null){
Trace(("ACHIEV_EVENT" + e.currentTarget.OO00OO1l1l.O1OlOO00O.toString()));
} else {
Trace(("ACHIEV_EVENT" + e.type));
};
}
public function requestAchievementList():void{
if (this._sub){
this._sub._O1OlO10OO();
};
}
public function requestAchievementInfo(id:int):void{
if (this._sub){
this._sub._OOlOOOll1(id);
};
}
public function requestHighScoreList():void{
if (this._sub){
this._sub._O110l10ll();
};
}
public function requestUserHighScoreList(target_username:String):void{
if (this._sub){
this._sub._O11lll1OO0(target_username);
};
}
public function submitScore(score):void{
if (this._sub){
if (this.isDomainAllowed()){
this._sub._O01lOO10O(score);
} else {
Trace("No...DomainAllowed");
};
};
}
public function submitAchievement(achievement):void{
if (this._sub){
if (this.isDomainAllowed()){
this._sub._O00OOl1Ol(achievement);
} else {
Trace("No...DomainAllowed");
};
};
}
public function isComponentInitialized():Boolean{
if (this._sub){
return (this._sub._O0O1l0OO0);
};
return (false);
}
public function isDomainAllowed():Boolean{
if (this._sub){
return (this._sub._O0Olll0lO);
};
return (false);
}
public function destroy():void{
if (this._sub){
if (this._debug){
if (this._sub.hasEventListener("ScoreLoadError")){
this._sub.removeEventListener("ScoreLoadError", this.eventHandlerScore);
};
if (this._sub.hasEventListener("ScoreLoadTimeComplete")){
this._sub.removeEventListener("ScoreLoadTimeComplete", this.eventHandlerScore);
};
if (this._sub.hasEventListener("ScoreLoadSubmitComplete")){
this._sub.removeEventListener("ScoreLoadSubmitComplete", this.eventHandlerScore);
};
if (this._sub.hasEventListener("ScoreLoadListComplete")){
this._sub.removeEventListener("ScoreLoadListComplete", this.eventHandlerScore);
};
if (this._sub.hasEventListener("AchievLoadError")){
this._sub.removeEventListener("AchievLoadError", this.eventHandlerAchiev);
};
if (this._sub.hasEventListener("AchievLoadTimeComplete")){
this._sub.removeEventListener("AchievLoadTimeComplete", this.eventHandlerAchiev);
};
if (this._sub.hasEventListener("AchievLoadListComplete")){
this._sub.removeEventListener("AchievLoadListComplete", this.eventHandlerAchiev);
};
if (this._sub.hasEventListener("AchievLoadInfoComplete")){
this._sub.removeEventListener("AchievLoadInfoComplete", this.eventHandlerAchiev);
};
if (this._sub.hasEventListener("AchievLoadGrantComplete")){
this._sub.removeEventListener("AchievLoadGrantComplete", this.eventHandlerAchiev);
};
if (((this._mc) && (this._mc.stage.hasEventListener(KeyboardEvent.KEY_DOWN)))){
this._mc.stage.addEventListener(KeyboardEvent.KEY_DOWN, this.keyBoardSendAwards);
};
};
this._sub._O010ll111();
};
this._sub = null;
}
public function dispatchEvent(event:Event):Boolean{
if (this._sub){
return (this._sub.dispatchEvent(event));
};
return (false);
}
public function hasEventListener(type:String):Boolean{
if (this._sub){
return (this._sub.hasEventListener(type));
};
return (false);
}
public function willTrigger(type:String):Boolean{
if (this._sub){
return (this._sub.willTrigger(type));
};
return (false);
}
public function removeEventListener(type:String, listener:Function, useCapture:Boolean=false):void{
if (this._sub){
this._sub.removeEventListener(type, listener, useCapture);
};
}
public function addEventListener(type:String, listener:Function, useCapture:Boolean=false, priority:int=0, useWeakReference:Boolean=false):void{
if (this._sub){
this._sub.addEventListener(type, listener, useCapture, priority, useWeakReference);
};
}
public static function get instance():Award_HighScore{
if (_instance == null){
_instance = new (Award_HighScore);
};
return (_instance);
}
public static function get initializedFinish():Boolean{
return (_initialized_finish);
}
}
}//package zlong.spilSystemTool
Section 242
//GamatarSender (zlong.spilSystemTool.GamatarSender)
package zlong.spilSystemTool {
import flash.display.*;
import flash.events.*;
import flash.net.*;
import flash.utils.*;
import com.adobe.images.*;
import ru.inspirit.net.*;
public class GamatarSender {
private var _uploader:MultipartURLLoader;
private var _gamatarid:String;
private var _gamatartype:String;
private var _returnXml:XML;
private var _eventDispatcher:EventDispatcher;
private var _isAvatar:Boolean;
framework_internal static const VERSION:String = "v1.09.201005271521";
private static const liveUrl:String = "http://api.gamatar.org/";
private static const devUrl:String = "http://api.gamatar.dev.spilgames.com/";
private static const POST:String = "POST";
private static const GET:String = "GET";
public static const GAMATAR_SENT_COMPLETE:String = "GAMATAR_SENT_COMPLETE";
public static const GAMATAR_SENT_ERROR:String = "GAMATAR_SENT_ERROR";
private static var _isDebug:Boolean;
private static var _gameName:String;
public function GamatarSender():void{
super();
this._isAvatar = false;
this._eventDispatcher = new EventDispatcher();
}
public function sendAvatar(picPreview:BitmapData, picRendering:BitmapData):Boolean{
var url:String;
if (!SpilSetting.instance.siteId){
Trace("Can`t get siteId from html");
return (false);
};
if (!SpilSetting.instance.checkUserLogin()){
SpilSetting.instance.callUpdateAvatarFailedToJS("UNKNOWN_USER");
return (false);
};
this._uploader = new MultipartURLLoader();
this._uploader.dataFormat = URLLoaderDataFormat.TEXT;
this._uploader.addVariable("username", SpilSetting.instance.username);
this._uploader.addVariable("hash", SpilSetting.instance.hash);
this._uploader.addVariable("outputtype", "xml");
var byteArrayPreview:ByteArray = new JPGEncoder(100).encode(picPreview);
var byteArrayRendering:ByteArray = new JPGEncoder(100).encode(picRendering);
this._uploader.addFile(byteArrayPreview, "avatar_thumb.jpg", "preview");
this._uploader.addFile(byteArrayRendering, "avatar_normal.jpg", "rendering");
if (_isDebug){
url = ((devUrl + "gm/pb/1/add/1/") + SpilSetting.instance.siteId);
} else {
url = ((liveUrl + "gm/pb/1/add/1/") + SpilSetting.instance.siteId);
};
this._uploader.load(url, POST);
this._uploader.addEventListener(Event.COMPLETE, this.onReady);
this._uploader.addEventListener(IOErrorEvent.IO_ERROR, this.onError);
this._uploader.addEventListener(HTTPStatusEvent.HTTP_STATUS, this.onStatus);
this._uploader.addEventListener(ProgressEvent.PROGRESS, this.onProgress, false, 0, false);
this._uploader.addEventListener(SecurityErrorEvent.SECURITY_ERROR, this.onSecurityError, false, 0, false);
this._isAvatar = true;
return (true);
}
public function send(picPreview:BitmapData, picRendering:BitmapData, encodeQuality:Number=100, title:String=null, description:String=null):Boolean{
var url:String;
if (!SpilSetting.instance.siteId){
Trace("Can`t get siteId from html");
return (false);
};
if (!SpilSetting.instance.itemId){
Trace("Can`t get itemId from html");
return (false);
};
if (!SpilSetting.instance.checkUserLogin()){
SpilSetting.instance.callUpdateGalleryFailedToJS("UNKNOWN_USER");
return (false);
};
this._uploader = new MultipartURLLoader();
this._uploader.dataFormat = URLLoaderDataFormat.TEXT;
if (title){
this._uploader.addVariable("title", title);
};
if (description){
this._uploader.addVariable("description", description);
};
this._uploader.addVariable("username", SpilSetting.instance.username);
this._uploader.addVariable("hash", SpilSetting.instance.hash);
this._uploader.addVariable("outputtype", "xml");
var byteArrayPreview:ByteArray = new JPGEncoder(encodeQuality).encode(picPreview);
var byteArrayRendering:ByteArray = new JPGEncoder(encodeQuality).encode(picRendering);
this._uploader.addFile(byteArrayPreview, (_gameName + "_thumb.jpg"), "preview");
this._uploader.addFile(byteArrayRendering, (_gameName + "_normal.jpg"), "rendering");
if (_isDebug){
url = ((((devUrl + "gm/pb/1/add/2/") + SpilSetting.instance.siteId) + "/1/") + SpilSetting.instance.itemId);
} else {
url = ((((liveUrl + "gm/pb/1/add/2/") + SpilSetting.instance.siteId) + "/1/") + SpilSetting.instance.itemId);
};
this._uploader.load(url, POST);
this._uploader.addEventListener(Event.COMPLETE, this.onReady);
this._uploader.addEventListener(IOErrorEvent.IO_ERROR, this.onError);
this._uploader.addEventListener(HTTPStatusEvent.HTTP_STATUS, this.onStatus);
this._uploader.addEventListener(ProgressEvent.PROGRESS, this.onProgress, false, 0, false);
this._uploader.addEventListener(SecurityErrorEvent.SECURITY_ERROR, this.onSecurityError, false, 0, false);
this._isAvatar = false;
return (true);
}
private function onSecurityError(event:SecurityErrorEvent):void{
Trace(("onSecurityError" + event.toString()));
this._eventDispatcher.dispatchEvent(new Event(GAMATAR_SENT_ERROR));
}
private function onProgress(event:ProgressEvent):void{
this._eventDispatcher.dispatchEvent(event.clone());
}
private function onStatus(event:HTTPStatusEvent):void{
this._eventDispatcher.dispatchEvent(event.clone());
}
private function onError(event:IOErrorEvent):void{
Trace(("IOError" + event.toString()));
this._eventDispatcher.dispatchEvent(new Event(GAMATAR_SENT_ERROR));
}
private function onReady(event:Event):void{
this.getIdTypeFromResponse(event);
this.submitPortal();
}
public function addEventListener(type:String, listener:Function, useCapture:Boolean=false, priority:int=0, useWeakReference:Boolean=false):void{
this._eventDispatcher.addEventListener(type, listener, useCapture, priority, useWeakReference);
}
public function removeEventListener(type:String, listener:Function, useCapture:Boolean=false):void{
this._eventDispatcher.removeEventListener(type, listener, useCapture);
}
public function del():void{
this._uploader.removeEventListener(Event.COMPLETE, this.onReady);
this._uploader.removeEventListener(IOErrorEvent.IO_ERROR, this.onError);
this._uploader.removeEventListener(HTTPStatusEvent.HTTP_STATUS, this.onStatus);
this._uploader.removeEventListener(ProgressEvent.PROGRESS, this.onProgress);
this._uploader.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, this.onSecurityError);
this._uploader = null;
}
private function getIdTypeFromResponse(e:Event):void{
var loader:URLLoader = MultipartURLLoader(e.currentTarget).loader;
var xml:XML = new XML(loader.data);
this._gamatarid = xml.result.id;
this._gamatartype = xml.result.type;
this._returnXml = xml;
if (_isDebug){
Trace(xml);
};
}
private function submitPortal():void{
if ((((this._gamatarid == "")) && ((this._gamatartype == "")))){
if (this._isAvatar){
SpilSetting.instance.callUpdateAvatarFailedToJS(String(this._returnXml.message));
} else {
SpilSetting.instance.callUpdateGalleryFailedToJS(String(this._returnXml.message));
};
Trace(("UpdateFailed" + String(this._returnXml.message)));
this._eventDispatcher.dispatchEvent(new Event(GAMATAR_SENT_ERROR));
} else {
if (this._isAvatar){
SpilSetting.instance.callUpdateAvatarToJs(this._gamatarid, this._gamatartype);
} else {
SpilSetting.instance.callUpdateGalleryToJs(this._gamatarid, this._gamatartype);
};
Trace("UpdateGallery", this._gamatarid, this._gamatartype);
this._eventDispatcher.dispatchEvent(new Event(GAMATAR_SENT_COMPLETE));
};
}
public function get renderingUrl():String{
if (this._gamatarid){
if (_isDebug){
return (((devUrl + "gm/pb/1/rendering/") + this._gamatarid));
};
return (((liveUrl + "gm/pb/1/rendering/") + this._gamatarid));
};
return (null);
}
public function get previewUrl():String{
if (this._gamatarid){
if (_isDebug){
return (((devUrl + "gm/pb/1/preview/") + this._gamatarid));
};
return (((liveUrl + "gm/pb/1/preview/") + this._gamatarid));
};
return (null);
}
public static function init(disObj:DisplayObject, gameName:String, isDebug:Boolean=false):void{
_isDebug = isDebug;
_gameName = gameName;
if (!SpilSetting._instance){
SpilSetting.instance.init(disObj, gameName, isDebug);
};
}
}
}//package zlong.spilSystemTool
Section 243
//GoogleEvent (zlong.spilSystemTool.GoogleEvent)
package zlong.spilSystemTool {
import flash.display.*;
import flash.net.*;
import com.google.analytics.*;
import zlong.utils.*;
public class GoogleEvent {
private var _gaGameName:String;
private var _gaTracker:GATracker;
private var _gaEventArr:Array;
private var _gaSharedObject:SharedObject;
framework_internal static const VERSION:String = "v1.09.201005271521";
private static var _instance:GoogleEvent;
public function GoogleEvent():void{
super();
}
public function init(gameName:String, display:DisplayObject, debug:Boolean):void{
var k:String;
this._gaGameName = gameName;
this._gaTracker = new GATracker(display, "UA-6695967-1", "AS3", debug);
this._gaEventArr = new Array();
this._gaSharedObject = SharedObjectUtil.getLocal("googleEvent");
for (k in this._gaSharedObject.data) {
this._gaEventArr.push(k);
};
}
public function gaTrackEvent(eventName:String, isRepeatedInOneGame:Boolean=false, isRepeatedInOnePC:Boolean=true):void{
var i:int;
if (((!(isRepeatedInOnePC)) || (!(isRepeatedInOneGame)))){
i = 0;
while (i < this._gaEventArr.length) {
if (eventName == this._gaEventArr[i]){
return;
};
i++;
};
if (!isRepeatedInOnePC){
this._gaSharedObject.data[eventName] = 1;
SharedObjectUtil.save(this._gaSharedObject);
};
this._gaEventArr.push(eventName);
};
this._gaTracker.trackEvent(this._gaGameName, eventName, "per session", 0);
}
public static function get instance():GoogleEvent{
if (_instance == null){
_instance = new (GoogleEvent);
};
return (_instance);
}
}
}//package zlong.spilSystemTool
Section 244
//SpilSetting (zlong.spilSystemTool.SpilSetting)
package zlong.spilSystemTool {
import flash.display.*;
import flash.system.*;
import flash.external.*;
public class SpilSetting {
private var _username:String;
private var _hash:String;
private var _siteId:String;
private var _itemId:String;
private var _isDebug:Boolean;
private var _mc:DisplayObject;
framework_internal static const VERSION:String = "v1.09.201005271521";
static var _instance:SpilSetting;
public function SpilSetting(){
super();
this._username = null;
this._hash = null;
this._siteId = null;
this._itemId = null;
}
public function init(disObj:DisplayObject, gameName:String, isDebug:Boolean=false):void{
this._mc = disObj;
this._isDebug = isDebug;
this.getHtmlParameters();
this.initJsCallBackFunction();
if (!this._siteId){
Trace("Can`t get siteId from html");
};
if (!this._itemId){
Trace("Can`t get itemId from html");
};
if (!this.checkUserLogin()){
callUnknowUserToJS(gameName);
};
}
private function getHtmlParameters():void{
this._username = this._mc.root.loaderInfo.parameters["username"];
if (this._username){
this._username = decodeURIComponent(this._username);
};
this._hash = this._mc.root.loaderInfo.parameters["hash"];
if (this._hash){
this._hash = decodeURIComponent(this._hash);
};
this._siteId = this._mc.root.loaderInfo.parameters["siteId"];
if (this._siteId){
this._siteId = decodeURIComponent(this._siteId);
};
this._itemId = this._mc.root.loaderInfo.parameters["itemId"];
if (this._itemId){
this._itemId = decodeURIComponent(this._itemId);
};
}
public function checkUserLogin():Boolean{
if (((this._username) && (this._hash))){
return (true);
};
return (false);
}
private function initJsCallBackFunction():void{
Security.allowDomain("*");
ExternalInterface.addCallback("UPDATE_USER", this.updateUser);
//unresolved jump
var _slot1 = e;
Trace("ExternalInterface.addCallback");
}
private function updateUser(username:String, hash:String):void{
if (this._isDebug){
Trace("Function updateUser!!");
};
this._username = username;
this._hash = hash;
}
function callUpdateGalleryToJs(id:String, type:String):void{
var id = id;
var type = type;
var Data:Object = {call:"UPDATE_GALLERY", params:{id:id, type:type}};
ExternalInterface.call("SWFtoJS", Data);
//unresolved jump
var _slot1 = e;
Trace("callUpdateGalleryToJs");
}
function callUpdateAvatarToJs(id:String, type:String):void{
var id = id;
var type = type;
var Data:Object = {call:"UPDATE_AVATAR", params:{id:id, type:type}};
ExternalInterface.call("SWFtoJS", Data);
//unresolved jump
var _slot1 = e;
Trace("callUpdateGalleryToJs");
}
function callUpdateGalleryFailedToJS(msg:String):void{
var msg = msg;
var Data:Object = {call:"UPDATE_GALLERY_FAILED", params:{message:msg}};
ExternalInterface.call("SWFtoJS", Data);
//unresolved jump
var _slot1 = e;
Trace("callUpdateFailedToJS");
}
function callUpdateAvatarFailedToJS(msg:String):void{
var msg = msg;
var Data:Object = {call:"UPDATE_AVATAR_FAILED", params:{message:msg}};
ExternalInterface.call("SWFtoJS", Data);
//unresolved jump
var _slot1 = e;
Trace("callUpdateFailedToJS");
}
public function get itemId():String{
return (this._itemId);
}
public function get siteId():String{
return (this._siteId);
}
public function get username():String{
return (this._username);
}
public function get hash():String{
return (this._hash);
}
public static function get instance():SpilSetting{
if (_instance == null){
_instance = new (SpilSetting);
};
return (_instance);
}
static function callUnknowUserToJS(id:String):void{
var id = id;
var Data:Object = {call:"UNKNOWN_USER", params:{id:id}};
ExternalInterface.call("SWFtoJS", Data);
//unresolved jump
var _slot1 = e;
Trace("callUnknowUserToJS");
}
}
}//package zlong.spilSystemTool
Section 245
//AbstractLoadingClass (zlong.Template.AbstractLoadingClass)
package zlong.Template {
import flash.display.*;
import flash.utils.*;
public class AbstractLoadingClass {
framework_internal static const VERSION:String = "v1.09.201005271521";
public function AbstractLoadingClass(pmc:Sprite){
super();
if (getQualifiedClassName(this) == "zlong::Template::AbstractLoadingClass"){
throw (new ArgumentError("can't be constructed"));
};
}
public function destroy():void{
throw (new ArgumentError("function destroy must be override"));
}
}
}//package zlong.Template
Section 246
//AbstractMainClass (zlong.Template.AbstractMainClass)
package zlong.Template {
import flash.display.*;
import flash.text.*;
import zlong.spilSystemTool.*;
import flash.utils.*;
import net.hires.debug.*;
import zlong.utils.*;
public class AbstractMainClass {
private var __mainMc:Sprite;
protected var __GameMc:Sprite;
private var _childClass:Class;
framework_internal static const VERSION:String = "v1.09.201005271521";
public function AbstractMainClass(mainMc:Sprite){
super();
if (getQualifiedClassName(this) == "zlong::Template::AbstractMainClass"){
throw (new ArgumentError("can't be constructed"));
};
this._childClass = (getDefinitionByName(getQualifiedClassName(this)) as Class);
this.__mainMc = mainMc;
this.__GameMc = new Sprite();
this.__GameMc.name = "GameMc";
this.__mainMc.addChild(this.__GameMc);
this.initGameSetting();
}
protected function initGameSetting():void{
SpilSetting.instance.init(this.__mainMc.root, this.gameNameUnderline, AbstractRootClass.instance._childClass["__debug__"]);
SharedObjectUtil.init(this.gameNameUnderline);
GoogleEvent.instance.init(this.gameNameUnderline, this.__mainMc.root, AbstractRootClass.instance._childClass["__debug__"]);
}
protected function showVersion(v:String):void{
var tempMc:Sprite;
tempMc = new Sprite();
tempMc.name = "VersionMc";
tempMc.mouseEnabled = false;
this.__mainMc.addChild(tempMc);
var _tf:TextField = new TextField();
_tf.selectable = false;
_tf.mouseEnabled = false;
_tf.defaultTextFormat = new TextFormat("_san", 12, 0);
_tf.width = 200;
_tf.height = 50;
_tf.x = 0;
_tf.y = 0;
_tf.text = v;
tempMc.addChild(_tf);
}
protected function showFPS():void{
this.__mainMc.addChild(new Stats());
}
public function get gameNameUnderline():String{
return (AbstractRootClass.cutGameName((AbstractRootClass.instance._childClass["GAME_NAME"] as String)));
}
}
}//package zlong.Template
Section 247
//AbstractRootClass (zlong.Template.AbstractRootClass)
package zlong.Template {
import flash.events.*;
import flash.display.*;
import zlong.spilSystemTool.*;
import zlong.site.*;
import zlong.*;
import flash.utils.*;
import flash.geom.*;
public class AbstractRootClass extends MovieClip {
var _childClass:Class;
private var __mainMc:Sprite;
private var _game:Object;
private var _realLoaderUI:Object;
private var _textLoaderUI:TextLoader;
private var _loadingComplete:Boolean;
framework_internal static const VERSION:String = "v1.09.201005271521";
static var instance:AbstractRootClass;
public function AbstractRootClass(){
super();
instance = this;
this._loadingComplete = false;
this.stop();
if (getQualifiedClassName(this) == "zlong::Template::AbstractRootClass"){
throw (new ArgumentError("can't be constructed"));
};
this._childClass = (getDefinitionByName(getQualifiedClassName(this)) as Class);
if (!(this._childClass["GAME_FRAMERATE"] is int)){
throw (new ArgumentError("Class Root need static const Int 'GAME_FRAMERATE'"));
};
if (!(this._childClass["GAME_NAME"] is String)){
throw (new ArgumentError("Class Root need static const String 'GAME_NAME'"));
};
if (!(this._childClass["STAGE_WIGHT"] is int)){
throw (new ArgumentError("Class Root need static const Int 'STAGE_WIGHT'"));
};
if (!(this._childClass["STAGE_HEIGHT"] is int)){
throw (new ArgumentError("Class Root need static const Int 'STAGE_HEIGHT'"));
};
if (!(this._childClass["PORTAL_TYPE"] is String)){
throw (new ArgumentError("Class Root need static const String 'PORTAL_TYPE'"));
};
if (!(this._childClass["LOADING_CLASS_NAME"] is String)){
throw (new ArgumentError("Class Root need static const String 'LOADING_CLASS_NAME'"));
};
if (!(this._childClass["GAME_CLASS_NAME"] is String)){
throw (new ArgumentError("Class Root need static const String 'GAME_CLASS_NAME'"));
};
if (!(this._childClass["VERSION_NUM"] is String)){
throw (new ArgumentError("Class Root need static const String 'VERSION_NUM'"));
};
if (!(this._childClass["__debug__"] is Boolean)){
throw (new ArgumentError("Class Root need static const Boolean '__debug__'"));
};
stage.frameRate = this._childClass["GAME_FRAMERATE"];
this.__mainMc = new Sprite();
this.__mainMc.name = "__mainMc";
this.addChild(this.__mainMc);
if (!this._childClass["__debug__"]){
this.scrollRect = new Rectangle(0, 0, this._childClass["STAGE_WIGHT"], this._childClass["STAGE_HEIGHT"]);
};
this.addFrameScript(0, this.s0);
this.addFrameScript(1, this.s1);
this.addFrameScript(2, this.s2);
}
private function s0():void{
this.script0();
this.stop();
this.initSettingBeforeLoading();
this.initTextloader();
this.initLoading();
}
private function s1():void{
var realLoadingClass:Class;
this.script1();
this.stop();
this._childClass["LOADING_CLASS_NAME"];
realLoadingClass = (getDefinitionByName(this._childClass["LOADING_CLASS_NAME"]) as Class);
//unresolved jump
var _slot1 = e;
throw (new ArgumentError(("can`t found the Loading Class " + _childClass["LOADING_CLASS_NAME"])));
return;
this._realLoaderUI = new realLoadingClass(this.__mainMc);
if (!(this._realLoaderUI is (getDefinitionByName("zlong.Template.AbstractLoadingClass") as Class))){
throw (new ArgumentError("the Loading Class mush extends Class AbstractLoadingClass"));
};
}
private function s2():void{
var mainClass:Class;
this.script2();
this.stop();
mainClass = (getDefinitionByName(this._childClass["GAME_CLASS_NAME"]) as Class);
//unresolved jump
var _slot1 = e;
throw (new ArgumentError(("can`t found the Main Class " + _childClass["GAME_CLASS_NAME"])));
return;
this._game = new mainClass(this.__mainMc);
if (!(this._game is (getDefinitionByName("zlong.Template.AbstractMainClass") as Class))){
throw (new ArgumentError("the Main Class mush extends Class AbstractMainClass"));
};
}
private function initLoading():void{
this.addEventListener(Event.ENTER_FRAME, this.updateLoading);
this.loaderInfo.addEventListener(Event.COMPLETE, this.LoadingComplete);
}
private function LoadingComplete(event:Event):void{
this._loadingComplete = true;
}
private function updateLoading(event:Event):void{
if (this.framesLoaded == 1){
this._textLoaderUI.update();
};
if ((((this.currentFrame == 1)) && ((this.framesLoaded >= 2)))){
this.realLoaderLoadingFinish();
};
if ((((((((this.currentFrame == 2)) && (((this._loadingComplete) || ((this.totalFrames == this.framesLoaded)))))) && (LocalSiteDataLoader.localSiteDataLoaderFinish))) && (Award_HighScore.initializedFinish))){
this.loadingFinish();
this.delLoading();
};
}
private function delLoading():void{
this.removeEventListener(Event.ENTER_FRAME, this.updateLoading);
}
private function initTextloader():void{
this._textLoaderUI = new TextLoader(this.__mainMc, this._childClass["STAGE_WIGHT"], this._childClass["STAGE_HEIGHT"]);
}
protected function delTextLoader():void{
if (this._textLoaderUI){
this._textLoaderUI.del();
this._textLoaderUI = null;
};
}
protected function delRealLoadingUI():void{
if (this._realLoaderUI){
var _local1 = this._realLoaderUI;
_local1["destroy"]();
};
}
protected function initSettingBeforeLoading():void{
new GameSetting(this, false, this._childClass["PORTAL_TYPE"], cutGameName((this._childClass["GAME_NAME"] as String)), (cutGameName((this._childClass["GAME_NAME"] as String), "-", true) + ".html"), this._childClass["STAGE_WIGHT"], this._childClass["STAGE_HEIGHT"]);
Award_HighScore.instance.init(cutGameName((this._childClass["GAME_NAME"] as String)), this, this._childClass["__debug__"], this._childClass["__debug__"]);
}
protected function realLoaderLoadingFinish():void{
this.delTextLoader();
this.gotoAndStop(2);
}
protected function loadingFinish():void{
this.delRealLoadingUI();
this.gotoAndStop(3);
}
protected function script0():void{
}
protected function script1():void{
}
protected function script2():void{
}
public static function cutGameName(gamename:String, delim:String="_", initialToUpperCase:Boolean=false):String{
var re:RegExp = /[-| |_]/;
var gameNamePartArr:Array = gamename.split(re);
var paraName:String = "";
var paraNamePart:String = "";
var i:int;
while (i < gameNamePartArr.length) {
paraNamePart = ((gameNamePartArr[i] as String).toLowerCase() + delim);
if (initialToUpperCase){
paraName = (paraName + (paraNamePart.charAt(0).toUpperCase() + paraNamePart.substr(1)));
} else {
paraName = (paraName + paraNamePart);
};
i++;
};
paraName = paraName.substr(0, (paraName.length - 1));
return (paraName);
}
}
}//package zlong.Template
Section 248
//TextLoader (zlong.Template.TextLoader)
package zlong.Template {
import flash.display.*;
import flash.text.*;
import zlong.*;
public class TextLoader {
private var _tf:TextField;
private var _loaderInfo:LoaderInfo;
private var _width:Number;
private var _height:Number;
private var _pmc:Sprite;
framework_internal static const VERSION:String = "v1.09.201005271521";
public function TextLoader(pmc:Sprite, width:Number, height:Number){
super();
this._pmc = pmc;
this._width = width;
this._height = height;
this._loaderInfo = pmc.root.loaderInfo;
this._tf = new TextField();
this._tf.autoSize = TextFieldAutoSize.LEFT;
this._tf.defaultTextFormat = new TextFormat("_sans", 16, 0, true);
this._tf.height = 30;
this._pmc.addChild(this._tf);
}
function update():void{
this._tf.text = (("Loading... " + Math.floor(((100 * this._loaderInfo.bytesLoaded) / this._loaderInfo.bytesTotal))) + "%");
this._tf.x = ((this._width - this._tf.width) / 2);
this._tf.y = ((this._height - this._tf.height) / 2);
}
function del():void{
this._pmc.removeChild(this._tf);
this._tf = null;
this._loaderInfo = null;
this._pmc = null;
}
}
}//package zlong.Template
Section 249
//SharedObjectUtil (zlong.utils.SharedObjectUtil)
package zlong.utils {
import flash.events.*;
import flash.net.*;
public class SharedObjectUtil {
framework_internal static const VERSION:String = "v1.09.201005271521";
private static const PREFIX:String = "SpilGames";
private static const GLOBAL:String = "global";
private static var gameName:String;
private static var operatedSharedObject:SharedObject;
public static function init(gameName:String):void{
}
public static function getGlobal(name:String):SharedObject{
var so:SharedObject;
var name = name;
so = SharedObject.getLocal(((((PREFIX + "_") + GLOBAL) + "_") + name), "/");
//unresolved jump
var _slot1 = err;
trace("create error");
return (so);
}
public static function getLocal(name:String):SharedObject{
var so:SharedObject;
var name = name;
so = SharedObject.getLocal(((((PREFIX + "_") + gameName) + "_") + name), "/");
//unresolved jump
var _slot1 = err;
trace("create error");
return (so);
}
public static function save(sharedObject:SharedObject):void{
var flushResult:String;
var sharedObject = sharedObject;
operatedSharedObject = sharedObject;
flushResult = operatedSharedObject.flush();
if (flushResult == SharedObjectFlushStatus.PENDING){
operatedSharedObject.addEventListener(NetStatusEvent.NET_STATUS, statusHandler);
} else {
operatedSharedObject = null;
};
//unresolved jump
var _slot1 = err;
}
private static function statusHandler(event:NetStatusEvent):void{
if (event.info["code"] == "SharedObject.Flush.Failed"){
} else {
if (event.info["code"] == "SharedObject.Flush.Success"){
trace("save successed");
};
};
operatedSharedObject.removeEventListener(NetStatusEvent.NET_STATUS, statusHandler);
operatedSharedObject = null;
}
}
}//package zlong.utils
Section 250
//framework_internal (zlong.framework_internal)
package zlong {
public namespace framework_internal = "http://www.zlonggames.com/flash/framework/internal";
}//package zlong
Section 251
//GameSetting (zlong.GameSetting)
package zlong {
import flash.display.*;
import zlong.country.*;
import zlong.site.*;
import zlong.data.*;
import zlong.display.*;
public class GameSetting {
private var _XMLLoader:LocalSiteDataLoader;
localComponent_internal static const VERSION:String = "v1.03.201005181759";
public static const PORTAL_TYPE_FAMILY:String = "family";
public static const PORTAL_TYPE_TWEEN:String = "tween";
public static const PORTAL_TYPE_GIRL:String = "girl";
public static const PORTAL_TYPE_TEEN:String = "teen";
public static const PORTAL_TYPE_ZAPAPA:String = "zapapa";
public static const PORTAL_TYPE_HYVES:String = "hyves";
public function GameSetting(displayObject:InteractiveObject, cnversion:Boolean, portal:String, name:String, html:String, width:int, height:int){
super();
GameInfo.cnversion = cnversion;
GameInfo.portal = portal;
GameInfo.name = name;
GameInfo.html = html;
GameInfo.width = width;
GameInfo.height = height;
this._XMLLoader = new LocalSiteDataLoader();
this.init();
this.initMenu(displayObject);
}
private function init():void{
new CountryCookie();
CountryInfo.instance.portal = GameInfo.portal;
if (CountryCookie.country == null){
CountryInfo.instance.country = "en_us";
} else {
CountryInfo.instance.country = String(CountryCookie.country);
};
}
private function initMenu(p:InteractiveObject):void{
new Menu(p);
}
}
}//package zlong
Section 252
//localComponent_internal (zlong.localComponent_internal)
package zlong {
public namespace localComponent_internal = "http://www.zlonggames.com/flash/localComponent/internal";
}//package zlong
Section 253
//achievements_music (achievements_music)
package {
import flash.media.*;
public dynamic class achievements_music extends Sound {
}
}//package
Section 254
//afteravatar_1 (afteravatar_1)
package {
import flash.display.*;
public dynamic class afteravatar_1 extends MovieClip {
}
}//package
Section 255
//afteravatar_10 (afteravatar_10)
package {
import flash.display.*;
public dynamic class afteravatar_10 extends MovieClip {
}
}//package
Section 256
//afteravatar_11 (afteravatar_11)
package {
import flash.display.*;
public dynamic class afteravatar_11 extends MovieClip {
}
}//package
Section 257
//afteravatar_12 (afteravatar_12)
package {
import flash.display.*;
public dynamic class afteravatar_12 extends MovieClip {
}
}//package
Section 258
//afteravatar_2 (afteravatar_2)
package {
import flash.display.*;
public dynamic class afteravatar_2 extends MovieClip {
}
}//package
Section 259
//afteravatar_3 (afteravatar_3)
package {
import flash.display.*;
public dynamic class afteravatar_3 extends MovieClip {
}
}//package
Section 260
//afteravatar_4 (afteravatar_4)
package {
import flash.display.*;
public dynamic class afteravatar_4 extends MovieClip {
}
}//package
Section 261
//afteravatar_5 (afteravatar_5)
package {
import flash.display.*;
public dynamic class afteravatar_5 extends MovieClip {
}
}//package
Section 262
//afteravatar_6 (afteravatar_6)
package {
import flash.display.*;
public dynamic class afteravatar_6 extends MovieClip {
}
}//package
Section 263
//afteravatar_7 (afteravatar_7)
package {
import flash.display.*;
public dynamic class afteravatar_7 extends MovieClip {
}
}//package
Section 264
//afteravatar_8 (afteravatar_8)
package {
import flash.display.*;
public dynamic class afteravatar_8 extends MovieClip {
}
}//package
Section 265
//afteravatar_9 (afteravatar_9)
package {
import flash.display.*;
public dynamic class afteravatar_9 extends MovieClip {
}
}//package
Section 266
//angel_1_music (angel_1_music)
package {
import flash.media.*;
public dynamic class angel_1_music extends Sound {
}
}//package
Section 267
//angel_2_music (angel_2_music)
package {
import flash.media.*;
public dynamic class angel_2_music extends Sound {
}
}//package
Section 268
//angleMC (angleMC)
package {
import flash.display.*;
public dynamic class angleMC extends MovieClip {
public var managerMC:MovieClip;
public var cutMC:MovieClip;
public var musicMC:MovieClip;
}
}//package
Section 269
//angre (angre)
package {
import flash.media.*;
public dynamic class angre extends Sound {
}
}//package
Section 270
//backGroundMC (backGroundMC)
package {
import flash.display.*;
public dynamic class backGroundMC extends MovieClip {
public var maskMC:MovieClip;
}
}//package
Section 271
//beCatch (beCatch)
package {
import flash.media.*;
public dynamic class beCatch extends Sound {
}
}//package
Section 272
//BeCatchMC (BeCatchMC)
package {
import flash.display.*;
public dynamic class BeCatchMC extends MovieClip {
public var controlListMC_BeCatch:MovieClip;
public var mainMenuBtn:Btn_008;
public var rePalyBtn:Btn_007;
public function BeCatchMC(){
addFrameScript(60, frame61);
}
function frame61(){
stop();
}
}
}//package
Section 273
//beforeavatar_1 (beforeavatar_1)
package {
import flash.display.*;
public dynamic class beforeavatar_1 extends MovieClip {
}
}//package
Section 274
//beforeavatar_10 (beforeavatar_10)
package {
import flash.display.*;
public dynamic class beforeavatar_10 extends MovieClip {
}
}//package
Section 275
//beforeavatar_11 (beforeavatar_11)
package {
import flash.display.*;
public dynamic class beforeavatar_11 extends MovieClip {
}
}//package
Section 276
//beforeavatar_12 (beforeavatar_12)
package {
import flash.display.*;
public dynamic class beforeavatar_12 extends MovieClip {
}
}//package
Section 277
//beforeavatar_2 (beforeavatar_2)
package {
import flash.display.*;
public dynamic class beforeavatar_2 extends MovieClip {
}
}//package
Section 278
//beforeavatar_3 (beforeavatar_3)
package {
import flash.display.*;
public dynamic class beforeavatar_3 extends MovieClip {
}
}//package
Section 279
//beforeavatar_4 (beforeavatar_4)
package {
import flash.display.*;
public dynamic class beforeavatar_4 extends MovieClip {
}
}//package
Section 280
//beforeavatar_5 (beforeavatar_5)
package {
import flash.display.*;
public dynamic class beforeavatar_5 extends MovieClip {
}
}//package
Section 281
//beforeavatar_6 (beforeavatar_6)
package {
import flash.display.*;
public dynamic class beforeavatar_6 extends MovieClip {
}
}//package
Section 282
//beforeavatar_7 (beforeavatar_7)
package {
import flash.display.*;
public dynamic class beforeavatar_7 extends MovieClip {
}
}//package
Section 283
//beforeavatar_8 (beforeavatar_8)
package {
import flash.display.*;
public dynamic class beforeavatar_8 extends MovieClip {
}
}//package
Section 284
//beforeavatar_9 (beforeavatar_9)
package {
import flash.display.*;
public dynamic class beforeavatar_9 extends MovieClip {
}
}//package
Section 285
//Btn_004 (Btn_004)
package {
import code.tool.*;
public dynamic class Btn_004 extends McButton {
public function Btn_004(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package
Section 286
//Btn_005 (Btn_005)
package {
import code.tool.*;
public dynamic class Btn_005 extends McButton {
}
}//package
Section 287
//Btn_006 (Btn_006)
package {
import code.tool.*;
public dynamic class Btn_006 extends McButton {
public function Btn_006(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package
Section 288
//Btn_007 (Btn_007)
package {
import code.tool.*;
public dynamic class Btn_007 extends McButton {
}
}//package
Section 289
//Btn_008 (Btn_008)
package {
import code.tool.*;
public dynamic class Btn_008 extends McButton {
}
}//package
Section 290
//Btn_009 (Btn_009)
package {
import code.tool.*;
public dynamic class Btn_009 extends McButton {
}
}//package
Section 291
//Btn_010 (Btn_010)
package {
import code.tool.*;
public dynamic class Btn_010 extends McButton {
}
}//package
Section 292
//Btn_011 (Btn_011)
package {
import code.tool.*;
public dynamic class Btn_011 extends McButton {
public function Btn_011(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package
Section 293
//Btn_012 (Btn_012)
package {
import code.tool.*;
public dynamic class Btn_012 extends McButton {
}
}//package
Section 294
//Btn_014 (Btn_014)
package {
import code.tool.*;
public dynamic class Btn_014 extends McButton {
}
}//package
Section 295
//Btn_015 (Btn_015)
package {
import code.tool.*;
public dynamic class Btn_015 extends McButton {
}
}//package
Section 296
//Btn_016 (Btn_016)
package {
import code.tool.*;
public dynamic class Btn_016 extends McButton {
}
}//package
Section 297
//Btn_017 (Btn_017)
package {
import code.tool.*;
public dynamic class Btn_017 extends McButton {
}
}//package
Section 298
//Btn_018 (Btn_018)
package {
import code.tool.*;
public dynamic class Btn_018 extends McButton {
}
}//package
Section 299
//Btn_021 (Btn_021)
package {
import code.tool.*;
public dynamic class Btn_021 extends McButton {
}
}//package
Section 300
//Btn_021_02 (Btn_021_02)
package {
import code.tool.*;
public dynamic class Btn_021_02 extends McButton {
}
}//package
Section 301
//Btn_022 (Btn_022)
package {
import code.tool.*;
public dynamic class Btn_022 extends McButton {
}
}//package
Section 302
//Btn_024 (Btn_024)
package {
import code.tool.*;
public dynamic class Btn_024 extends McButton {
}
}//package
Section 303
//Btn_025 (Btn_025)
package {
import code.tool.*;
public dynamic class Btn_025 extends McButton {
}
}//package
Section 304
//Btn_027 (Btn_027)
package {
import code.tool.*;
public dynamic class Btn_027 extends McButton {
}
}//package
Section 305
//Btn_back (Btn_back)
package {
import code.tool.*;
public dynamic class Btn_back extends McButton {
}
}//package
Section 306
//Btn_home (Btn_home)
package {
import code.tool.*;
public dynamic class Btn_home extends McButton {
public function Btn_home(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package
Section 307
//Btn_sound (Btn_sound)
package {
import code.tool.*;
public dynamic class Btn_sound extends McButton {
}
}//package
Section 308
//Btnback (Btnback)
package {
import code.tool.*;
public dynamic class Btnback extends McButton {
}
}//package
Section 309
//BusinessWoman (BusinessWoman)
package {
import flash.display.*;
public dynamic class BusinessWoman extends MovieClip {
public var clound:MovieClip;
}
}//package
Section 310
//camera (camera)
package {
import flash.media.*;
public dynamic class camera extends Sound {
}
}//package
Section 311
//ChangePageMC (ChangePageMC)
package {
import flash.display.*;
public dynamic class ChangePageMC extends MovieClip {
}
}//package
Section 312
//chuckBook (chuckBook)
package {
import flash.media.*;
public dynamic class chuckBook extends Sound {
}
}//package
Section 313
//churnUp (churnUp)
package {
import flash.media.*;
public dynamic class churnUp extends Sound {
}
}//package
Section 314
//complete_music (complete_music)
package {
import flash.media.*;
public dynamic class complete_music extends Sound {
}
}//package
Section 315
//CountriesBox (CountriesBox)
package {
import zlong.display.*;
public dynamic class CountriesBox extends CountriesBox {
}
}//package
Section 316
//CreditsMC (CreditsMC)
package {
import flash.display.*;
public dynamic class CreditsMC extends MovieClip {
public var levelMapBtn:Btn_022;
public var photoMC:MovieClip;
public var mc:MovieClip;
public var controlListMC_Credit:MovieClip;
public var photoMC2:MovieClip;
}
}//package
Section 317
//CuteSchoolKid (CuteSchoolKid)
package {
import flash.display.*;
public dynamic class CuteSchoolKid extends MovieClip {
public var clound:MovieClip;
}
}//package
Section 318
//cutHair (cutHair)
package {
import flash.media.*;
public dynamic class cutHair extends Sound {
}
}//package
Section 319
//damageup (damageup)
package {
import flash.media.*;
public dynamic class damageup extends Sound {
}
}//package
Section 320
//devil_1_music (devil_1_music)
package {
import flash.media.*;
public dynamic class devil_1_music extends Sound {
}
}//package
Section 321
//devil_2_music (devil_2_music)
package {
import flash.media.*;
public dynamic class devil_2_music extends Sound {
}
}//package
Section 322
//devilCutHair (devilCutHair)
package {
import flash.media.*;
public dynamic class devilCutHair extends Sound {
}
}//package
Section 323
//devilMC (devilMC)
package {
import flash.display.*;
public dynamic class devilMC extends MovieClip {
public var cutMC:MovieClip;
public function devilMC(){
addFrameScript(25, frame26, 126, frame127, 371, frame372, 476, frame477, 513, frame514, 603, frame604, 713, frame714);
}
function frame714(){
gotoAndPlay("cutsissiors");
}
function frame604(){
gotoAndPlay("odorator");
}
function frame26(){
gotoAndPlay("hair");
}
function frame477(){
stop();
}
function frame514(){
gotoAndPlay("haircut");
}
function frame127(){
stop();
}
function frame372(){
gotoAndPlay("normal");
}
}
}//package
Section 324
//export (export)
package {
import flash.display.*;
public dynamic class export extends MovieClip {
}
}//package
Section 325
//fadie0 (fadie0)
package {
import flash.media.*;
public dynamic class fadie0 extends Sound {
}
}//package
Section 326
//fadie1 (fadie1)
package {
import flash.media.*;
public dynamic class fadie1 extends Sound {
}
}//package
Section 327
//fadie2 (fadie2)
package {
import flash.media.*;
public dynamic class fadie2 extends Sound {
}
}//package
Section 328
//failed_music (failed_music)
package {
import flash.media.*;
public dynamic class failed_music extends Sound {
}
}//package
Section 329
//find (find)
package {
import flash.media.*;
public dynamic class find extends Sound {
}
}//package
Section 330
//flyCutHair (flyCutHair)
package {
import flash.media.*;
public dynamic class flyCutHair extends Sound {
}
}//package
Section 331
//FromFriendMC (FromFriendMC)
package {
import flash.display.*;
import flash.text.*;
public dynamic class FromFriendMC extends MovieClip {
public var friendText:TextField;
public var photo:MovieClip;
public var startGameBtn:Btn_009;
public var moreGameBtn_fromFriendMC:Btn_012;
public var mc:MovieClip;
public var outputText:TextField;
}
}//package
Section 332
//fullSate (fullSate)
package {
import flash.media.*;
public dynamic class fullSate extends Sound {
}
}//package
Section 333
//GothicBoy (GothicBoy)
package {
import flash.display.*;
public dynamic class GothicBoy extends MovieClip {
public var clound:MovieClip;
}
}//package
Section 334
//HideConsole (HideConsole)
package {
public var HideConsole:Boolean;
HideConsole = false;
}//package
Section 335
//HowToPlayMC (HowToPlayMC)
package {
import flash.display.*;
public dynamic class HowToPlayMC extends MovieClip {
public var SkipBtn:Btn_018;
public var NextBtn:Btn_011;
public var BackBtn:Btn_011;
public function HowToPlayMC(){
addFrameScript(24, frame25);
}
function frame25(){
stop();
}
}
}//package
Section 336
//HyvesLoading (HyvesLoading)
package {
import zlong.display.*;
public dynamic class HyvesLoading extends HyvesLoading {
}
}//package
Section 337
//ingame_logo (ingame_logo)
package {
import zlong.display.*;
public dynamic class ingame_logo extends TranText {
}
}//package
Section 338
//jumpwindow (jumpwindow)
package {
import flash.media.*;
public dynamic class jumpwindow extends Sound {
}
}//package
Section 339
//KeepInGameMC (KeepInGameMC)
package {
import flash.display.*;
public dynamic class KeepInGameMC extends MovieClip {
public var startGameBtn:Btn_017;
public var moreGameBtn_KeepInGame:MoreGamesLogocopy;
public var mainMenuBtn:Btn_016;
public var merchdiseBtn:Btn_024;
public function KeepInGameMC(){
__setProp_moreGameBtn_KeepInGame_UI_KeepOn__1();
}
function __setProp_moreGameBtn_KeepInGame_UI_KeepOn__1(){
try {
moreGameBtn_KeepInGame["componentInspectorSetting"] = true;
} catch(e:Error) {
};
moreGameBtn_KeepInGame.position = "button_keepingame_moregames";
moreGameBtn_KeepInGame.type = "moregames";
try {
moreGameBtn_KeepInGame["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package
Section 340
//LevelCompleteMC (LevelCompleteMC)
package {
import flash.display.*;
public dynamic class LevelCompleteMC extends MovieClip {
public var photoMC:MovieClip;
public var controlListMC_LevelPass:MovieClip;
public var starMC:MovieClip;
public var cupWarningMC:MovieClip;
}
}//package
Section 341
//LevelmapMC (LevelmapMC)
package {
import flash.display.*;
public dynamic class LevelmapMC extends MovieClip {
public var LevelBtn0:UI_levelmap_000;
public var LevelBtn4:UI_levelmap_000;
public var Level0:MovieClip;
public var Level4:MovieClip;
public var Level2:MovieClip;
public var Level8:MovieClip;
public var Level5:MovieClip;
public var Level6:MovieClip;
public var Level7:MovieClip;
public var Level9:MovieClip;
public var Level3:MovieClip;
public var controlListMC_levelMap:MovieClip;
public var mc:MovieClip;
public var Level1:MovieClip;
public var merchdiseBtn:Btn_025;
public var creditBtn:Btn_021;
public var achievementBtn:MovieClip;
public var LevelBtn1:UI_levelmap_000;
public var LevelBtn2:UI_levelmap_000;
public var LevelBtn3:UI_levelmap_000;
public var LevelBtn5:UI_levelmap_000;
public var LevelBtn6:UI_levelmap_000;
public var LevelBtn8:UI_levelmap_000;
public var LevelBtn9:UI_levelmap_000;
public var LevelBtn7:UI_levelmap_000;
}
}//package
Section 342
//loadinglogo (loadinglogo)
package {
import zlong.display.*;
public dynamic class loadinglogo extends TranText {
}
}//package
Section 343
//LoadingMC (LoadingMC)
package {
import flash.display.*;
import flash.text.*;
public dynamic class LoadingMC extends MovieClip {
public var percentText:TextField;
public var __id0_:Logo;
public var loadingMc:MovieClip;
public function LoadingMC(){
__setProp___id0__UI_loading__1();
}
function __setProp___id0__UI_loading__1(){
try {
__id0_["componentInspectorSetting"] = true;
} catch(e:Error) {
};
__id0_.alignHorizontal = "Center";
__id0_.alignVertical = "Center";
__id0_.maxHeight = 40;
__id0_.maxWidth = 150;
__id0_.position = "logo_preloader";
try {
__id0_["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package
Section 344
//localization (localization)
package {
import flash.display.*;
public dynamic class localization extends MovieClip {
}
}//package
Section 345
//Logo (Logo)
package {
import zlong.display.*;
public dynamic class Logo extends Logo {
}
}//package
Section 346
//Main (Main)
package {
import flash.display.*;
import flash.events.*;
import zlong.spilSystemTool.*;
import code.ui.*;
import code.tool.*;
import zlong.Template.*;
import code.data.*;
import zlong.breathxue.utils.debug.*;
public class Main extends AbstractMainClass {
public static var _fpsCounter:FpsCounter;
private static var _instance:Main;
public function Main(mainMc:Sprite){
_instance = this;
super(mainMc);
showVersion(Root.VERSION_NUM);
if (Root.__debug__){
TC.InitTC(__GameMc);
showFPS();
};
gameStart();
}
private function gameStart():void{
GamatarSender.init(__GameMc, "Devilish Stylish", false);
new Cookie();
new CountryCookie();
SoundsManager.init();
new UIManager(__GameMc);
initGameData();
}
private function initGameData():void{
_fpsCounter = new FpsCounter(false);
__GameMc.addChild(_fpsCounter);
__GameMc.addEventListener(Event.ENTER_FRAME, updateFPS);
}
private function updateFPS(event:Event):void{
_fpsCounter.update();
}
public static function get instance():Main{
return (_instance);
}
public static function get lostFramePre():Number{
return ((1 - (_fpsCounter.averageFps / Data.FpsNum)));
}
}
}//package
Section 347
//main_logo (main_logo)
package {
import zlong.display.*;
public dynamic class main_logo extends TranText {
}
}//package
Section 348
//MainMC (MainMC)
package {
import flash.display.*;
public dynamic class MainMC extends MovieClip {
public var prossBar:MovieClip;
public var speed:MovieClip;
public var hitMC:MovieClip;
public var time:MovieClip;
public var controlListMC_Main:MovieClip;
public function MainMC(){
addFrameScript(18, frame19, 36, frame37, 55, frame56, 73, frame74, 92, frame93, 110, frame111);
}
function frame74(){
gotoAndPlay("LV2 super");
}
function frame19(){
gotoAndPlay("LV3");
}
function frame111(){
gotoAndPlay("LV1 super");
}
function frame37(){
gotoAndPlay("LV3 super");
}
function frame93(){
gotoAndPlay("LV1");
}
function frame56(){
gotoAndPlay("LV2");
}
}
}//package
Section 349
//mainscreen_music (mainscreen_music)
package {
import flash.media.*;
public dynamic class mainscreen_music extends Sound {
}
}//package
Section 350
//menu_back (menu_back)
package {
import flash.media.*;
public dynamic class menu_back extends Sound {
}
}//package
Section 351
//menu_press (menu_press)
package {
import flash.media.*;
public dynamic class menu_press extends Sound {
}
}//package
Section 352
//menu_touch (menu_touch)
package {
import flash.media.*;
public dynamic class menu_touch extends Sound {
}
}//package
Section 353
//MenuMC (MenuMC)
package {
import flash.display.*;
import www.spilgames.*;
public dynamic class MenuMC extends MovieClip {
public var musicBtn:MovieClip;
public var howToPlayBtn:Btn_010;
public var spillGameBtn:com;
public var moreGameBtn_menu:MoreGamesLogocopy;
public var merchdiseBtn:Btn_024;
public var soundBtn:MovieClip;
public var sartGameBtn:Btn_009;
public var qualityBtn:MovieClip;
public function MenuMC(){
__setProp_moreGameBtn_menu_UI_main__1();
}
function __setProp_moreGameBtn_menu_UI_main__1(){
try {
moreGameBtn_menu["componentInspectorSetting"] = true;
} catch(e:Error) {
};
moreGameBtn_menu.position = "button_mainscreen_moregames";
moreGameBtn_menu.type = "moregames";
try {
moreGameBtn_menu["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package
Section 354
//MoreGamesLogocopy (MoreGamesLogocopy)
package {
import zlong.display.*;
public dynamic class MoreGamesLogocopy extends ExtButton {
public var __id1_:Logo;
public function MoreGamesLogocopy(){
__setProp___id1__MoreGamesLogocopy_Layer8_1();
}
function __setProp___id1__MoreGamesLogocopy_Layer8_1(){
try {
__id1_["componentInspectorSetting"] = true;
} catch(e:Error) {
};
__id1_.alignHorizontal = "Center";
__id1_.alignVertical = "Down";
__id1_.maxHeight = 20;
__id1_.maxWidth = 150;
__id1_.position = "logo_preloader";
try {
__id1_["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package
Section 355
//Motherwithbaby (Motherwithbaby)
package {
import flash.display.*;
public dynamic class Motherwithbaby extends MovieClip {
public var clound:MovieClip;
}
}//package
Section 356
//NerdMan (NerdMan)
package {
import flash.display.*;
public dynamic class NerdMan extends MovieClip {
public var clound:MovieClip;
}
}//package
Section 357
//OldLady (OldLady)
package {
import flash.display.*;
public dynamic class OldLady extends MovieClip {
public var clound:MovieClip;
}
}//package
Section 358
//other_press (other_press)
package {
import flash.media.*;
public dynamic class other_press extends Sound {
}
}//package
Section 359
//other_touch (other_touch)
package {
import flash.media.*;
public dynamic class other_touch extends Sound {
}
}//package
Section 360
//pageback (pageback)
package {
import flash.media.*;
public dynamic class pageback extends Sound {
}
}//package
Section 361
//pagego (pagego)
package {
import flash.media.*;
public dynamic class pagego extends Sound {
}
}//package
Section 362
//person (person)
package {
import flash.media.*;
public dynamic class person extends Sound {
}
}//package
Section 363
//PhotoAlbum_photo02_01 (PhotoAlbum_photo02_01)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_01 extends MovieClip {
}
}//package
Section 364
//PhotoAlbum_photo02_02 (PhotoAlbum_photo02_02)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_02 extends MovieClip {
}
}//package
Section 365
//PhotoAlbum_photo02_03 (PhotoAlbum_photo02_03)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_03 extends MovieClip {
}
}//package
Section 366
//PhotoAlbum_photo02_04 (PhotoAlbum_photo02_04)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_04 extends MovieClip {
}
}//package
Section 367
//PhotoAlbum_photo02_05 (PhotoAlbum_photo02_05)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_05 extends MovieClip {
}
}//package
Section 368
//PhotoAlbum_photo02_06 (PhotoAlbum_photo02_06)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_06 extends MovieClip {
}
}//package
Section 369
//PhotoAlbum_photo02_07 (PhotoAlbum_photo02_07)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_07 extends MovieClip {
}
}//package
Section 370
//PhotoAlbum_photo02_08 (PhotoAlbum_photo02_08)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_08 extends MovieClip {
}
}//package
Section 371
//PhotoAlbum_photo02_09 (PhotoAlbum_photo02_09)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_09 extends MovieClip {
}
}//package
Section 372
//PhotoAlbum_photo02_10 (PhotoAlbum_photo02_10)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_10 extends MovieClip {
}
}//package
Section 373
//PhotoAlbum_photo02_11 (PhotoAlbum_photo02_11)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_11 extends MovieClip {
}
}//package
Section 374
//PhotoAlbum_photo02_12 (PhotoAlbum_photo02_12)
package {
import flash.display.*;
public dynamic class PhotoAlbum_photo02_12 extends MovieClip {
}
}//package
Section 375
//pickBook (pickBook)
package {
import flash.media.*;
public dynamic class pickBook extends Sound {
}
}//package
Section 376
//POPMC (POPMC)
package {
import flash.display.*;
public dynamic class POPMC extends MovieClip {
public var backBtn:Btn_015;
public var playBrn:Btn_014;
public var starMC:MovieClip;
public function POPMC(){
addFrameScript(24, frame25);
}
function frame25(){
stop();
}
}
}//package
Section 377
//Root (Root)
package {
import zlong.spilSystemTool.*;
import zlong.Template.*;
import zlong.*;
public class Root extends AbstractRootClass {
public static const STAGE_WIGHT:int = 660;
public static const GAME_CLASS_NAME:String = "Main";
public static const STAGE_HEIGHT:int = 480;
public static const PORTAL_TYPE:String = "girl";
public static const VERSION_NUM:String = "v. 1.00";
public static const __debug__:Boolean = false;
public static const LOADING_CLASS_NAME:String = "code.ui.Loading";
public static const GAME_FRAMERATE:int = 30;
public static const GAME_NAME:String = "Devilish Stylist";
public function Root(){
super();
}
override protected function initSettingBeforeLoading():void{
new GameSetting(this, false, PORTAL_TYPE, cutGameName(GAME_NAME), (cutGameName(GAME_NAME, "-", true) + ".html"), STAGE_WIGHT, STAGE_HEIGHT);
Award_HighScore.instance.init(cutGameName(GAME_NAME), this, __debug__, __debug__);
}
override protected function script0():void{
Trace("script0");
}
override protected function script1():void{
Trace("script1");
}
override protected function script2():void{
Trace("script2");
}
}
}//package
Section 378
//rules (rules)
package {
import flash.media.*;
public dynamic class rules extends Sound {
}
}//package
Section 379
//scissors (scissors)
package {
import flash.media.*;
public dynamic class scissors extends Sound {
}
}//package
Section 380
//sendtofriend_logo (sendtofriend_logo)
package {
import zlong.display.*;
public dynamic class sendtofriend_logo extends TranText {
}
}//package
Section 381
//SendtofriendMC (SendtofriendMC)
package {
import flash.display.*;
public dynamic class SendtofriendMC extends MovieClip {
public var backBtn:Btnback;
public var avatarafter:Btn_027;
public var avatarbefore:Btn_027;
public var photo3:UI_levelmap_000;
public var controlListMC_Achievement:MovieClip;
public var photo1:UI_levelmap_000;
public var nextBtn:Btn_011;
public var photo2:UI_levelmap_000;
public var makeupafter:MovieClip;
public var mc:MovieClip;
public var preBtn:Btn_011;
public var makeupbefore:MovieClip;
}
}//package
Section 382
//SiteLockMC (SiteLockMC)
package {
import flash.display.*;
public dynamic class SiteLockMC extends MovieClip {
public var startGameBtn_AddUI:MoreGamesLogocopy;
public function SiteLockMC(){
__setProp_startGameBtn_AddUI_UI_Sitelock__1();
}
function __setProp_startGameBtn_AddUI_UI_Sitelock__1(){
try {
startGameBtn_AddUI["componentInspectorSetting"] = true;
} catch(e:Error) {
};
startGameBtn_AddUI.position = "button_sitelock_moregames";
startGameBtn_AddUI.type = "moregames";
try {
startGameBtn_AddUI["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package
Section 383
//smail (smail)
package {
import flash.media.*;
public dynamic class smail extends Sound {
}
}//package
Section 384
//SmokeMC (SmokeMC)
package {
import flash.display.*;
public dynamic class SmokeMC extends MovieClip {
}
}//package
Section 385
//soundMC (soundMC)
package {
import flash.display.*;
public dynamic class soundMC extends MovieClip {
}
}//package
Section 386
//splashwash (splashwash)
package {
import flash.media.*;
public dynamic class splashwash extends Sound {
}
}//package
Section 387
//SubmitterProxy (SubmitterProxy)
package {
import flash.events.*;
import flash.display.*;
import com.spilgames.api.*;
import flash.system.*;
public class SubmitterProxy extends MovieClip {
public var m_scoreXMLData:XML;
public var m_achievXMLData:XML;
private var parentObj;
public var m_scoreServerTimeXMLData:XML;
private static var _failed:Boolean = false;
private static var _loading:Boolean = false;
private static var _initialised:Boolean = false;
private static var SpilComp:SpilGamesServices;
public function SubmitterProxy():void{
var cld:*;
super();
Security.allowDomain("*");
parentObj = this.parent;
parentObj.stop();
var i:int = (parentObj.numChildren - 1);
while (i >= 0) {
cld = parentObj.getChildAt(i);
if ((cld is MovieClip)){
cld.visible = false;
} else {
if (cld != null){
parentObj.removeChild(cld);
};
};
i = (i - 1);
};
try {
parentObj["setLoader"] = setLoader;
parentObj["isDomainAllowed"] = isDomainAllowed;
parentObj["hasUserData"] = hasUserData;
parentObj["_O0000Ol01"] = setLoader;
parentObj["_O0Olll0lO"] = isDomainAllowed;
} catch(e:Error) {
trace(e);
};
}
private function SpilConfiguratorFailedToInitialise(_arg1:Event):void{
if (SpilComp){
SpilComp.removeEventListener("servicesReady", SpilConfiguratorReady);
SpilComp.removeEventListener(IOErrorEvent.IO_ERROR, SpilConfiguratorFailedToLoad);
SpilComp.removeEventListener("servicesFailed", SpilConfiguratorFailedToInitialise);
};
_failed = true;
_loading = false;
parentObj.dispatchEvent(new Event("LoadingFailed"));
}
public function SpilCallback(_arg1:int, _arg2:Object):void{
}
private function onLoadDone():void{
parentObj["isSWFReady"] = isSWFReady;
parentObj["setServerSelect"] = setServerSelect;
parentObj["requestScoreServerTime"] = requestScoreServerTime;
parentObj["getScoreServerTime"] = getScoreServerTime;
parentObj["submitScore"] = submitScore;
parentObj["requestHighscoreList"] = requestHighscoreList;
parentObj["requestUserHighscoreList"] = requestUserHighscoreList;
parentObj["submitGrantAward"] = submitGrantAward;
parentObj["requestAwardList"] = requestAwardList;
parentObj["requestAwardInfo"] = requestAwardInfo;
parentObj["destroy"] = destroy;
parentObj["getSpilGamesConnector"] = getSpilGamesConnector;
parentObj["_O0O1l0OO0"] = isSWFReady;
parentObj["_O0lOO010l"] = requestScoreServerTime;
parentObj["_O01Ol1O1O"] = getScoreServerTime;
parentObj["_O01lOO10O"] = submitScore;
parentObj["_O110l10ll"] = requestHighscoreList;
parentObj["_O11lll1OO0"] = requestUserHighscoreList;
parentObj["_O00OOl1Ol"] = submitGrantAward;
parentObj["_O1OlO10OO"] = requestAwardList;
parentObj["_OOlOOOll1"] = requestAwardInfo;
parentObj["_O010ll111"] = destroy;
parentObj["OO00OO1l1l"] = OO00OO1l1l();
}
private function processTimeResults(_arg1:int, _arg2:Object):void{
if (_arg2){
if (_arg2.errorMessage){
} else {
if (_arg2.xml){
m_scoreServerTimeXMLData = _arg2.xml;
};
};
} else {
m_scoreServerTimeXMLData = new XML("<hyscore><time>123456789</time></hyscore>");
};
}
private function isSWFReady():Boolean{
return (((SpilComp) && (SpilComp.isSWFReady())));
}
private function requestAwardList():void{
if (SpilComp){
SpilComp.send("Awards", "getAwardList", processAwardResults, {userName:SpilComp.getUserName(), userHash:SpilComp.getUserHash()});
};
}
public function set O1lll0ll0(_arg1:XML):void{
m_scoreServerTimeXMLData = _arg1;
}
public function OO00OO1l1l():SubmitterProxy{
return (this);
}
private function hasUserData():Boolean{
return (!(SpilComp.hasValidUserData()));
}
public function get O0l00l0O0():XML{
return (m_scoreXMLData);
}
private function destroy():void{
parentObj = null;
m_scoreXMLData = null;
m_achievXMLData = null;
}
private function requestScoreServerTime():void{
if (SpilComp){
SpilComp.send("Score", "checkServerTime", processTimeResults);
};
}
private function requestUserHighscoreList(_arg1:String):void{
if (SpilComp){
SpilComp.send("Score", "getUserRankList", processScoreResults, {targetUserName:_arg1});
};
}
public function get O1OlOO00O():XML{
return (m_achievXMLData);
}
private function submitGrantAward(_arg1:String):void{
if (SpilComp){
SpilComp.send("Awards", "submitAward", processAwardResults, {tag:_arg1, userName:SpilComp.getUserName(), userHash:SpilComp.getUserHash()});
};
}
private function setLoader(_arg1=null, _arg2:String="default", _arg3="", _arg4:int=0, _arg5:String="normal", _arg6:String="", _arg7:int=0, _arg8:int=0, _arg9:int=1, _arg10:Boolean=false, _arg11:int=1):void{
if (!_initialised){
trace("Initialising for the first time");
_initialised = true;
if (_arg1){
SpilComp = SpilGamesServices.getInstance();
SpilComp.addEventListener("servicesReady", SpilConfiguratorReady);
SpilComp.addEventListener(IOErrorEvent.IO_ERROR, SpilConfiguratorFailedToLoad);
SpilComp.addEventListener("servicesFailed", SpilConfiguratorFailedToInitialise);
_loading = true;
SpilComp.connect(_arg1);
} else {
throw (new Error("'container' cannot be null"));
};
} else {
trace("Initialisation called multiple times");
if (!_loading){
trace("Ready with loading");
if (!_failed){
trace("Simulate Submitter complete");
onLoadDone();
parentObj.dispatchEvent(new Event(Event.COMPLETE));
} else {
trace("Simulate Submitter LoadingFailed");
parentObj.dispatchEvent(new Event("LoadingFailed"));
};
} else {
trace("Still loading");
};
};
}
private function requestHighscoreList():void{
if (SpilComp){
SpilComp.send("Score", "getRankingList", processScoreResults, null);
};
}
public function set O0l00l0O0(_arg1:XML):void{
m_scoreXMLData = _arg1;
}
private function setServerSelect(_arg1:int):void{
if (SpilComp){
};
}
private function requestAwardInfo(_arg1:int):void{
if (SpilComp){
SpilComp.send("Awards", "getAward", SpilCallback, {awardID:_arg1});
};
}
public function set O1OlOO00O(_arg1:XML):void{
m_achievXMLData = _arg1;
}
private function processAwardResults(_arg1:int, _arg2:Object):void{
if (_arg2){
m_achievXMLData = _arg2.xml;
} else {
m_achievXMLData = new XML("<hyscor><awardid>147</awardid></hyscor>");
};
}
public function getSpilGamesConnector(){
return (SpilComp);
}
public function get O1lll0ll0():XML{
return (m_scoreServerTimeXMLData);
}
private function processScoreResults(_arg1:int, _arg2:Object):void{
if (_arg2){
m_scoreXMLData = _arg2.xml;
} else {
m_scoreXMLData = <hyscor><resultset>
<group>daily</group>
<result>
<position>1</position>
<timestamp>1271247768</timestamp>
<username>noot</username>
<authenticated>1</authenticated>
<score>2</score>
<gamelevel>0</gamelevel>
<country>NL</country>
</result>
</resultset>
<resultset>
<group>weekly</group>
<result>
<position>1</position>
<timestamp>1271247768</timestamp>
<username>noot</username>
<authenticated>1</authenticated>
<score>2</score>
<gamelevel>0</gamelevel>
<country>NL</country>
</result>
</resultset>
<resultset>
<group>monthly</group>
<result>
<position>1</position>
<timestamp>1271247768</timestamp>
<username>noot</username>
<authenticated>1</authenticated>
<score>2</score>
<gamelevel>0</gamelevel>
<country>NL</country>
</result>
</resultset>
</hyscor>
;
};
}
private function getScoreServerTime():void{
if (SpilComp){
SpilComp.send("Score", "getLatestTimeCheck", processTimeResults);
};
}
private function SpilConfiguratorReady(_arg1:Event):void{
if (SpilComp){
SpilComp.removeEventListener("servicesReady", SpilConfiguratorReady);
SpilComp.removeEventListener(IOErrorEvent.IO_ERROR, SpilConfiguratorFailedToLoad);
SpilComp.removeEventListener("servicesFailed", SpilConfiguratorFailedToInitialise);
};
_loading = false;
onLoadDone();
parentObj.dispatchEvent(new Event(Event.COMPLETE));
}
private function doCommTest():String{
if (SpilComp){
return ("y");
};
return (("FAILED " + SpilComp));
}
private function submitScore(_arg1:int):void{
if (SpilComp){
SpilComp.send("Score", "submitScore", processScoreResults, {score:_arg1, userName:SpilComp.getUserName(), userHash:SpilComp.getUserHash()});
};
}
private function SpilConfiguratorFailedToLoad(_arg1:Event):void{
if (SpilComp){
SpilComp.removeEventListener("servicesReady", SpilConfiguratorReady);
SpilComp.removeEventListener(IOErrorEvent.IO_ERROR, SpilConfiguratorFailedToLoad);
SpilComp.removeEventListener("servicesFailed", SpilConfiguratorFailedToInitialise);
};
trace("SpilConfiguratorFailedToLoad", _arg1.toString());
_failed = true;
_loading = false;
if (parentObj.hasEventListener(IOErrorEvent.IO_ERROR)){
parentObj.dispatchEvent(new IOErrorEvent(IOErrorEvent.IO_ERROR));
};
}
private function onLegacyEvent(_arg1:Event):void{
dispatchEvent(_arg1);
}
private function isDomainAllowed(_arg1:Boolean=false):Boolean{
return (SpilComp.isDomainAllowed());
}
private function setLoader2(_arg1=null, _arg2:String="default", _arg3:int=1, _arg4="", _arg5:int=0, _arg6:String="normal", _arg7:String="", _arg8:int=0, _arg9:int=0, _arg10:int=1, _arg11:Boolean=false, _arg12:int=1):void{
setLoader(_arg1, _arg2, _arg4, _arg5, _arg6, _arg7, _arg8, _arg9, _arg10, _arg11, _arg12);
}
}
}//package
Section 388
//sweet (sweet)
package {
import flash.media.*;
public dynamic class sweet extends Sound {
}
}//package
Section 389
//Sweet16Girl (Sweet16Girl)
package {
import flash.display.*;
public dynamic class Sweet16Girl extends MovieClip {
public var clound:MovieClip;
}
}//package
Section 390
//talk0 (talk0)
package {
import flash.media.*;
public dynamic class talk0 extends Sound {
}
}//package
Section 391
//talk1 (talk1)
package {
import flash.media.*;
public dynamic class talk1 extends Sound {
}
}//package
Section 392
//TeenageGirl (TeenageGirl)
package {
import flash.display.*;
public dynamic class TeenageGirl extends MovieClip {
public var clound:MovieClip;
}
}//package
Section 393
//think0 (think0)
package {
import flash.media.*;
public dynamic class think0 extends Sound {
}
}//package
Section 394
//think1 (think1)
package {
import flash.media.*;
public dynamic class think1 extends Sound {
}
}//package
Section 395
//think2 (think2)
package {
import flash.media.*;
public dynamic class think2 extends Sound {
}
}//package
Section 396
//TimeOverMC (TimeOverMC)
package {
import flash.display.*;
public dynamic class TimeOverMC extends MovieClip {
public var controlListMC_TimerOver:MovieClip;
public var mainMenuBtn:Btn_008;
public var rePalyBtn:Btn_007;
public function TimeOverMC(){
addFrameScript(59, frame60);
}
function frame60(){
stop();
}
}
}//package
Section 397
//Toddler (Toddler)
package {
import flash.display.*;
public dynamic class Toddler extends MovieClip {
public var clound:MovieClip;
}
}//package
Section 398
//ToughAfroGuy (ToughAfroGuy)
package {
import flash.display.*;
public dynamic class ToughAfroGuy extends MovieClip {
public var clound:MovieClip;
}
}//package
Section 399
//Trace (Trace)
package {
import zlong.breathxue.utils.debug.*;
import flash.utils.*;
public function Trace(... _args):void{
var TcClass:Class;
var args = _args;
if (!HideConsole){
trace(args);
};
if (TcShow){
TcClass = (getDefinitionByName("zlong.breathxue.utils.debug.TC") as Class);
//unresolved jump
var _slot1 = e;
TcShow = false;
if (TcClass){
var _local3 = TcClass;
_local3["SHOW"](args);
};
};
}
}//package
Section 400
//TransitionMC (TransitionMC)
package {
import flash.display.*;
public dynamic class TransitionMC extends MovieClip {
public var controlListMC_Transition:MovieClip;
}
}//package
Section 401
//tutorial_music (tutorial_music)
package {
import flash.media.*;
public dynamic class tutorial_music extends Sound {
}
}//package
Section 402
//txt_1ItsFailed (txt_1ItsFailed)
package {
import zlong.display.*;
public dynamic class txt_1ItsFailed extends TranText {
}
}//package
Section 403
//txt_1Loading (txt_1Loading)
package {
import zlong.display.*;
public dynamic class txt_1Loading extends TranText {
}
}//package
Section 404
//txt_1Successfull (txt_1Successfull)
package {
import zlong.display.*;
public dynamic class txt_1Successfull extends TranText {
}
}//package
Section 405
//TXT_After (TXT_After)
package {
import zlong.display.*;
public dynamic class TXT_After extends TranText {
}
}//package
Section 406
//TXT_Angel_Prison_is_your_destiny_now (TXT_Angel_Prison_is_your_destiny_now)
package {
import zlong.display.*;
public dynamic class TXT_Angel_Prison_is_your_destiny_now extends TranText {
}
}//package
Section 407
//TXT_Another_Devilish_Haircut (TXT_Another_Devilish_Haircut)
package {
import zlong.display.*;
public dynamic class TXT_Another_Devilish_Haircut extends TranText {
}
}//package
Section 408
//TXT_Areyousureyouarearealdevil (TXT_Areyousureyouarearealdevil)
package {
import zlong.display.*;
public dynamic class TXT_Areyousureyouarearealdevil extends TranText {
}
}//package
Section 409
//TXT_Art_Design (TXT_Art_Design)
package {
import zlong.display.*;
public dynamic class TXT_Art_Design extends TranText {
}
}//package
Section 410
//TXT_Back (TXT_Back)
package {
import zlong.display.*;
public dynamic class TXT_Back extends TranText {
}
}//package
Section 411
//TXT_back2 (TXT_back2)
package {
import zlong.display.*;
public dynamic class TXT_back2 extends TranText {
}
}//package
Section 412
//TXT_breathxue (TXT_breathxue)
package {
import zlong.display.*;
public dynamic class TXT_breathxue extends TranText {
}
}//package
Section 413
//TXT_Buy_Devilish_styling_stuff (TXT_Buy_Devilish_styling_stuff)
package {
import zlong.display.*;
public dynamic class TXT_Buy_Devilish_styling_stuff extends TranText {
}
}//package
Section 414
//TXT_CLICK_TO_RESUME (TXT_CLICK_TO_RESUME)
package {
import zlong.display.*;
public dynamic class TXT_CLICK_TO_RESUME extends TranText {
}
}//package
Section 415
//TXT_ClickOnAPhototoStartHairdressing (TXT_ClickOnAPhototoStartHairdressing)
package {
import zlong.display.*;
public dynamic class TXT_ClickOnAPhototoStartHairdressing extends TranText {
}
}//package
Section 416
//TXT_Clicktoconiuse (TXT_Clicktoconiuse)
package {
import zlong.display.*;
public dynamic class TXT_Clicktoconiuse extends TranText {
}
}//package
Section 417
//TXT_credit (TXT_credit)
package {
import zlong.display.*;
public dynamic class TXT_credit extends TranText {
}
}//package
Section 418
//TXT_Credits_title (TXT_Credits_title)
package {
import zlong.display.*;
public dynamic class TXT_Credits_title extends TranText {
}
}//package
Section 419
//TXT_Game_Concept (TXT_Game_Concept)
package {
import zlong.display.*;
public dynamic class TXT_Game_Concept extends TranText {
}
}//package
Section 420
//TXT_Game_Design (TXT_Game_Design)
package {
import zlong.display.*;
public dynamic class TXT_Game_Design extends TranText {
}
}//package
Section 421
//TXT_Game_Testing (TXT_Game_Testing)
package {
import zlong.display.*;
public dynamic class TXT_Game_Testing extends TranText {
}
}//package
Section 422
//TXT_How_to_play_title (TXT_How_to_play_title)
package {
import zlong.display.*;
public dynamic class TXT_How_to_play_title extends TranText {
}
}//package
Section 423
//TXT_How_to_play01 (TXT_How_to_play01)
package {
import zlong.display.*;
public dynamic class TXT_How_to_play01 extends TranText {
}
}//package
Section 424
//TXT_How_to_play02 (TXT_How_to_play02)
package {
import zlong.display.*;
public dynamic class TXT_How_to_play02 extends TranText {
}
}//package
Section 425
//TXT_How_to_play03 (TXT_How_to_play03)
package {
import zlong.display.*;
public dynamic class TXT_How_to_play03 extends TranText {
}
}//package
Section 426
//TXT_How_to_play04 (TXT_How_to_play04)
package {
import zlong.display.*;
public dynamic class TXT_How_to_play04 extends TranText {
}
}//package
Section 427
//TXT_How_to_play05 (TXT_How_to_play05)
package {
import zlong.display.*;
public dynamic class TXT_How_to_play05 extends TranText {
}
}//package
Section 428
//TXT_How_to_play06 (TXT_How_to_play06)
package {
import zlong.display.*;
public dynamic class TXT_How_to_play06 extends TranText {
}
}//package
Section 429
//TXT_Howtoplay (TXT_Howtoplay)
package {
import zlong.display.*;
public dynamic class TXT_Howtoplay extends TranText {
}
}//package
Section 430
//TXT_jiaminyan (TXT_jiaminyan)
package {
import zlong.display.*;
public dynamic class TXT_jiaminyan extends TranText {
}
}//package
Section 431
//Txt_justamoment (Txt_justamoment)
package {
import zlong.display.*;
public dynamic class Txt_justamoment extends TranText {
}
}//package
Section 432
//TXT_KeepOn (TXT_KeepOn)
package {
import zlong.display.*;
public dynamic class TXT_KeepOn extends TranText {
}
}//package
Section 433
//TXT_Levelmap (TXT_Levelmap)
package {
import zlong.display.*;
public dynamic class TXT_Levelmap extends TranText {
}
}//package
Section 434
//TXT_liuxiao (TXT_liuxiao)
package {
import zlong.display.*;
public dynamic class TXT_liuxiao extends TranText {
}
}//package
Section 435
//TXT_Love_this_game (TXT_Love_this_game)
package {
import zlong.display.*;
public dynamic class TXT_Love_this_game extends TranText {
}
}//package
Section 436
//TXT_Mainmenu (TXT_Mainmenu)
package {
import zlong.display.*;
public dynamic class TXT_Mainmenu extends TranText {
}
}//package
Section 437
//TXT_maliyong (TXT_maliyong)
package {
import zlong.display.*;
public dynamic class TXT_maliyong extends TranText {
}
}//package
Section 438
//TXT_Merchandise (TXT_Merchandise)
package {
import zlong.display.*;
public dynamic class TXT_Merchandise extends TranText {
}
}//package
Section 439
//TXT_Merchandise2 (TXT_Merchandise2)
package {
import zlong.display.*;
public dynamic class TXT_Merchandise2 extends TranText {
}
}//package
Section 440
//TXT_MoreFreeOnlineGamesA (TXT_MoreFreeOnlineGamesA)
package {
import zlong.display.*;
public dynamic class TXT_MoreFreeOnlineGamesA extends TranText {
}
}//package
Section 441
//TXT_MoreGame (TXT_MoreGame)
package {
import zlong.display.*;
public dynamic class TXT_MoreGame extends TranText {
}
}//package
Section 442
//TXT_Music_Sound_Effect (TXT_Music_Sound_Effect)
package {
import zlong.display.*;
public dynamic class TXT_Music_Sound_Effect extends TranText {
}
}//package
Section 443
//TXT_My_Devilish_Haircut (TXT_My_Devilish_Haircut)
package {
import zlong.display.*;
public dynamic class TXT_My_Devilish_Haircut extends TranText {
}
}//package
Section 444
//TXT_OK (TXT_OK)
package {
import zlong.display.*;
public dynamic class TXT_OK extends TranText {
}
}//package
Section 445
//TXT_PAUSE (TXT_PAUSE)
package {
import zlong.display.*;
public dynamic class TXT_PAUSE extends TranText {
}
}//package
Section 446
//TXT_PhotoAlbum (TXT_PhotoAlbum)
package {
import zlong.display.*;
public dynamic class TXT_PhotoAlbum extends TranText {
}
}//package
Section 447
//TXT_Pick_a_picture (TXT_Pick_a_picture)
package {
import zlong.display.*;
public dynamic class TXT_Pick_a_picture extends TranText {
}
}//package
Section 448
//TXT_Play (TXT_Play)
package {
import zlong.display.*;
public dynamic class TXT_Play extends TranText {
}
}//package
Section 449
//TXT_PlayMoreNaughtyGamesAt (TXT_PlayMoreNaughtyGamesAt)
package {
import zlong.display.*;
public dynamic class TXT_PlayMoreNaughtyGamesAt extends TranText {
}
}//package
Section 450
//txt_PLEASEWAITAMOMENT (txt_PLEASEWAITAMOMENT)
package {
import flash.display.*;
public dynamic class txt_PLEASEWAITAMOMENT extends MovieClip {
}
}//package
Section 451
//TXT_POP (TXT_POP)
package {
import zlong.display.*;
public dynamic class TXT_POP extends TranText {
}
}//package
Section 452
//TXT_Producer (TXT_Producer)
package {
import zlong.display.*;
public dynamic class TXT_Producer extends TranText {
}
}//package
Section 453
//TXT_Programming (TXT_Programming)
package {
import zlong.display.*;
public dynamic class TXT_Programming extends TranText {
}
}//package
Section 454
//TXT_Project_Management (TXT_Project_Management)
package {
import zlong.display.*;
public dynamic class TXT_Project_Management extends TranText {
}
}//package
Section 455
//TXT_rico (TXT_rico)
package {
import zlong.display.*;
public dynamic class TXT_rico extends TranText {
}
}//package
Section 456
//TXT_Set_As_Avatar (TXT_Set_As_Avatar)
package {
import zlong.display.*;
public dynamic class TXT_Set_As_Avatar extends TranText {
}
}//package
Section 457
//TXT_Shop_for_merchandise (TXT_Shop_for_merchandise)
package {
import zlong.display.*;
public dynamic class TXT_Shop_for_merchandise extends TranText {
}
}//package
Section 458
//TXT_star (TXT_star)
package {
import zlong.display.*;
public dynamic class TXT_star extends TranText {
}
}//package
Section 459
//TXT_Start_Game (TXT_Start_Game)
package {
import zlong.display.*;
public dynamic class TXT_Start_Game extends TranText {
}
}//package
Section 460
//TXT_sunxin (TXT_sunxin)
package {
import zlong.display.*;
public dynamic class TXT_sunxin extends TranText {
}
}//package
Section 461
//TXT_Timesup (TXT_Timesup)
package {
import zlong.display.*;
public dynamic class TXT_Timesup extends TranText {
}
}//package
Section 462
//TXT_tryagain (TXT_tryagain)
package {
import zlong.display.*;
public dynamic class TXT_tryagain extends TranText {
}
}//package
Section 463
//TXT_Well_Done (TXT_Well_Done)
package {
import zlong.display.*;
public dynamic class TXT_Well_Done extends TranText {
}
}//package
Section 464
//TXT_You_got_a_bronze_Star (TXT_You_got_a_bronze_Star)
package {
import zlong.display.*;
public dynamic class TXT_You_got_a_bronze_Star extends TranText {
}
}//package
Section 465
//TXT_You_got_a_Gold_Star (TXT_You_got_a_Gold_Star)
package {
import zlong.display.*;
public dynamic class TXT_You_got_a_Gold_Star extends TranText {
}
}//package
Section 466
//TXT_You_got_a_silver_Star (TXT_You_got_a_silver_Star)
package {
import zlong.display.*;
public dynamic class TXT_You_got_a_silver_Star extends TranText {
}
}//package
Section 467
//TXT_You_got_caught (TXT_You_got_caught)
package {
import zlong.display.*;
public dynamic class TXT_You_got_caught extends TranText {
}
}//package
Section 468
//UI_InGame_05_01 (UI_InGame_05_01)
package {
import zlong.display.*;
public dynamic class UI_InGame_05_01 extends TranText {
}
}//package
Section 469
//UI_levelmap_000 (UI_levelmap_000)
package {
import code.tool.*;
public dynamic class UI_levelmap_000 extends McButton {
}
}//package
Section 470
//UI_loading_001 (UI_loading_001)
package {
import zlong.display.*;
public dynamic class UI_loading_001 extends TranText {
}
}//package
Section 471
//UI_set_loading (UI_set_loading)
package {
import flash.display.*;
public dynamic class UI_set_loading extends MovieClip {
public var signuptext:txt_PLEASEWAITAMOMENT;
public var loadingbar:MovieClip;
public var loadingtext:MovieClip;
public var tryagain:Btn_007;
public var back:Btn_back;
public function UI_set_loading(){
addFrameScript(24, frame25);
}
function frame25(){
stop();
}
}
}//package
Section 472
//UIPAUSEMC (UIPAUSEMC)
package {
import flash.display.*;
public dynamic class UIPAUSEMC extends MovieClip {
}
}//package
Section 473
//whistle0 (whistle0)
package {
import flash.media.*;
public dynamic class whistle0 extends Sound {
}
}//package
Section 474
//whistle1 (whistle1)
package {
import flash.media.*;
public dynamic class whistle1 extends Sound {
}
}//package
Section 475
//whistle2 (whistle2)
package {
import flash.media.*;
public dynamic class whistle2 extends Sound {
}
}//package
Section 476
//window_press (window_press)
package {
import flash.media.*;
public dynamic class window_press extends Sound {
}
}//package
Section 477
//window_touch (window_touch)
package {
import flash.media.*;
public dynamic class window_touch extends Sound {
}
}//package
Section 478
//winSound (winSound)
package {
import flash.media.*;
public dynamic class winSound extends Sound {
}
}//package